UNPKG

linkmore-design

Version:

🌈 πŸš€lmη»„δ»ΆεΊ“γ€‚πŸš€

68 lines (67 loc) β€’ 2.53 kB
import type { ValidateMessages } from 'rc-field-form/lib/interface'; import * as React from 'react'; import type { RequiredMark } from '../form/Form'; import type { Locale } from '../locale-provider'; import type { Theme } from './context'; import { ConfigConsumer, ConfigContext } from './context'; import type { ConfigConsumerProps, DirectionType, CSPConfig } from './context'; import type { RenderEmptyHandler } from './defaultRenderEmpty'; import type { SizeType } from './SizeContext'; import SizeContext from './SizeContext'; export { RenderEmptyHandler, ConfigContext, ConfigConsumer, CSPConfig, DirectionType, ConfigConsumerProps, }; export declare const configConsumerProps: string[]; export interface ConfigProviderProps { getTargetContainer?: () => HTMLElement | Window; getPopupContainer?: (triggerNode?: HTMLElement) => HTMLElement; prefixCls?: string; iconPrefixCls?: string; children?: React.ReactNode; renderEmpty?: RenderEmptyHandler; csp?: CSPConfig; autoInsertSpaceInButton?: boolean; form?: { validateMessages?: ValidateMessages; requiredMark?: RequiredMark; colon?: boolean; }; input?: { autoComplete?: string; }; pagination?: { showSizeChanger?: boolean; }; locale?: Locale; pageHeader?: { ghost: boolean; }; componentSize?: SizeType; componentDisabled?: boolean; direction?: DirectionType; space?: { size?: SizeType | number; }; virtual?: boolean; dropdownMatchSelectWidth?: boolean; } export interface ProviderChildrenProps extends ConfigProviderProps { parentContext: ConfigConsumerProps; legacyLocale: Locale; iconUrl?: string | Array<string>; } export declare const defaultPrefixCls = "ant"; export declare const defaultIconPrefixCls = "anticon"; declare function getGlobalIconPrefixCls(): string; declare const setGlobalConfig: ({ prefixCls, iconPrefixCls, theme, }: Pick<ConfigProviderProps, "prefixCls" | "iconPrefixCls"> & { theme?: Theme; }) => void; export declare const globalConfig: () => { getPrefixCls: (suffixCls?: string, customizePrefixCls?: string) => string; getIconPrefixCls: typeof getGlobalIconPrefixCls; getRootPrefixCls: (rootPrefixCls?: string, customizePrefixCls?: string) => string; }; declare const ConfigProvider: React.FC<ConfigProviderProps> & { ConfigContext: typeof ConfigContext; SizeContext: typeof SizeContext; config: typeof setGlobalConfig; }; export default ConfigProvider;