import type { Theme as ReactUITheme } from '@skbkontur/react-ui/lib/theming/Theme'; import type { Emotion } from '@emotion/css/create-instance'; import type { AddonsTheme } from './ThemeTypes.js'; type ReactUIOrAddonsTheme = (ReactUITheme | AddonsTheme) & { [key: string]: unknown; }; /** * Creates AddonsTheme out of ReactUI's Theme. * * Inserts Addons vars in the theme, puts them over ReactUI's vars, * but respects these Addons vars values that might have been specified in ReactUI's theme before that. * * This allows inserting Addons vars in the theme on the fly * (without need for users to do it manually in their apps), * and using ReactUI's ThemeContext.Provider for overriding them. */ export declare const createAddonsTheme: (theme: ReactUIOrAddonsTheme) => AddonsTheme; export declare const getAddonsTheme: (arg: Readonly | Readonly) => Readonly; export interface StylesObject { [className: string]: (() => string) | ((t: AddonsTheme) => string); } export type StylesGetter = (emotion: Emotion) => S; export declare const memoizeStyle: (styles: S) => S; export declare const memoizeGetStyles: (getStyles: StylesGetter) => StylesGetter; export type { Emotion };