Flutter docs
Default skin

ConfigProvider

Provide a uniform configuration support for components.

When to use

Provide a uniform configuration support for components.

Examples

Locale

Components which need localization support are listed here, you can toggle the language in the demo.

Direction

Components which support rtl direction are listed here, you can toggle the direction in the demo.

Component size

Config component default size.

Theme

Modify theme by theme prop.

Custom Wave

Wave effect brings dynamic. Use component to determine which component use it. You can also use HappyProvider from @ant-design/happy-work-theme to implement dynamic wave effect.

Static function

Use holderRender to set the Provider for the static methods message,modal,notification.

API

ConfigProvider, ConfigProvider.config, and ConfigProvider.useConfig are exported from @ceebee/ui/client.

ConfigProvider

PropertyDescriptionTypeDefaultVersion
componentDisabledConfig antd component disabledboolean-4.21.0
componentSizeConfig antd component sizesmall | medium | large-—
cspSet Content Security Policy config{ nonce: string }-—
directionSet direction of layout. See demoltr | rtlltr—
getPopupContainerTo set the container of the popup element. The default is to create a div element in body(trigger?: HTMLElement) => HTMLElement | ShadowRoot() => document.body—
getTargetContainerConfig Affix, Anchor scroll target container() => HTMLElement | Window | ShadowRoot() => window4.2.0
iconPrefixClsSet icon prefix classNamestringanticon4.11.0
localeLanguage package setting, you can find the packages in antd/localeobject-—
popupMatchSelectWidthDetermine whether the dropdown menu and the select input are the same width. Default set min-width same as input. Will ignore when value less than select width. false will disable virtual scrollboolean | number-5.5.0
popupOverflowSelect like component popup logic. Can set to show in viewport or follow window scroll'viewport' | 'scroll' <InlinePopover previewURL="https://user-images.githubusercontent.com/5378891/230344474-5b9f7e09-0a5d-49e8-bae8-7d2abed6c837.png"></InlinePopover>'viewport'5.5.0
prefixClsSet prefix classNamestringant—
renderEmptySet empty content of components. Ref Emptyfunction(componentName: string): ReactNode-—
themeSet theme, ref Customize ThemeTheme-5.0.0
variantSet variant of data entry componentsoutlined | filled | borderless-5.19.0
virtualDisable virtual scroll when set to falseboolean-4.3.0
warningConfig warning level, when strict is false, it will aggregate deprecated information into a single message{ strict: boolean }-5.10.0
autoInsertSpaceInButtonButton auto spacing config, please use button={{ autoInsertSpace: boolean }} insteadboolean--
dropdownMatchSelectWidthDetermine whether the dropdown menu and the select input are the same width, please use popupMatchSelectWidth insteadboolean--

ConfigProvider.useConfig() <Badge>5.3.0+</Badge> {#useconfig}

PropertyDescriptionTypeDefaultVersion
componentDisabledantd component disabled stateboolean-5.3.0
componentSizeantd component size statesmall | medium | large-5.3.0

WaveConfig

PropertyDescriptionTypeDefaultVersion
disabledWhether to disable wave effectbooleanfalse—
showEffectCustomized wave effect(node: HTMLElement, info: { className, token, component }) => void-—
triggerTypeThe event that triggers wave effectclick | pointerdown | pointerup | mousedown | mouseupclick6.4.0