For AI agents: the complete documentation index is available at https://ifhover.github.io/leaf-ui/en/llms.txt, the full documentation bundle is available at https://ifhover.github.io/leaf-ui/en/llms-full.txt, and this page is available as Markdown at https://ifhover.github.io/leaf-ui/en/api/component-defaults.md.

Component defaults

Use components on ConfigProvider to set shared default props. See component defaults for examples, naming rules and inheritance.

LeafComponentDefaults

All entries are optional. Each entry accepts the props listed below or null to clear inherited defaults. Follow a linked props type for the meaning and built-in default of each prop. Required props, mode-dependent values, generic data and imperative refs remain on instances.

PropertyTypeDescription
AffixPartial<Omit<AffixProps, 'key' | 'ref'>> | nullConfigure affix.
AlertPartial<Omit<AlertProps, 'key' | 'ref' | 'title'>> | nullConfigure alert.
AnchorPartial<Omit<AnchorProps, 'key' | 'ref' | 'items'>> | nullConfigure anchor.
AppBarPartial<Omit<AppBarProps, 'key' | 'ref'>> | nullConfigure app bar.
AutoCompletePartial<Omit<AutoCompleteProps, 'key' | 'ref' | 'options'>> | nullConfigure auto complete.
AvatarPartial<Omit<AvatarProps, 'key' | 'ref'>> | nullConfigure avatar.
AvatarGroupPartial<Omit<AvatarGroupProps, 'key' | 'ref'>> | nullConfigure avatar group.
BackTopPartial<Omit<BackTopProps, 'key' | 'ref'>> | nullConfigure back top.
BadgePartial<Omit<BadgeProps, 'key' | 'ref'>> | nullConfigure badge.
BottomNavigationPartial<Omit<BottomNavigationProps, 'key' | 'ref' | 'items'>> | nullConfigure bottom navigation.
BreadcrumbPartial<Omit<BreadcrumbProps, 'key' | 'ref' | 'items'>> | nullConfigure breadcrumb.
ButtonPartial<Omit<ButtonProps, 'key' | 'ref'>> | nullDefault button props.
ButtonGroupPartial<Omit<ButtonGroupProps, 'key' | 'ref'>> | nullConfigure button group.
CalendarPartial<Omit<CalendarProps, 'key' | 'ref'>> | nullConfigure calendar.
CardPartial<Omit<CardProps, 'key' | 'ref'>> | nullConfigure card.
CardTitlePartial<Omit<CardTitleProps, 'key' | 'ref'>> | nullConfigure card title.
CarouselPartial<Omit<CarouselProps, 'key' | 'ref'>> | nullConfigure carousel.
CascaderPartial< Omit< CascaderProps, 'key' | 'ref' | 'options' | 'multiple' | 'value' | 'defaultValue' | 'onChange' > > | nullConfigure cascader.
CheckableTagPartial<Omit<CheckableTagProps, 'key' | 'ref'>> | nullConfigure checkable tag.
CheckboxPartial<Omit<CheckboxProps, 'key' | 'ref'>> | nullConfigure checkbox.
CheckboxGroupPartial<Omit<CheckboxGroupProps, 'key' | 'ref' | 'options'>> | nullConfigure checkbox group.
ColPartial<Omit<ColProps, 'key' | 'ref'>> | nullConfigure col.
CollapsePartial<Omit<CollapseProps, 'key' | 'ref' | 'items'>> | nullConfigure collapse.
ColorPickerPartial<Omit<ColorPickerProps, 'key' | 'ref'>> | nullConfigure color picker.
CommandPalettePartial<Omit<CommandPaletteProps, 'key' | 'ref' | 'items'>> | nullConfigure command palette.
ConfirmPartial<Omit<ConfirmOptions, 'key' | 'ref'>> | nullConfigure confirm.
CountdownPartial<Omit<CountdownProps, 'key' | 'ref' | 'value'>> | nullConfigure countdown.
DataTablePartial<Omit<DataTablePresentationProps, 'tableRef'>> | nullConfigure data table.
DataTableColumnVisibilityPartial<Omit<DataTableColumnVisibilityProps, 'key' | 'ref'>> | nullConfigure data table column visibility.
DataTableContentPartial<Omit<DataTableContentProps, 'key' | 'ref'>> | nullConfigure data table content.
DataTableFooterPartial<Omit<HTMLAttributes<HTMLDivElement>, 'key' | 'ref'>> | nullConfigure data table footer.
DataTablePaginationPartial<Omit<DataTablePaginationProps, 'key' | 'ref'>> | nullConfigure data table pagination.
DataTableSearchPartial<Omit<DataTableSearchProps, 'key' | 'ref'>> | nullConfigure data table search.
DataTableToolbarPartial<Omit<HTMLAttributes<HTMLDivElement>, 'key' | 'ref'>> | nullConfigure data table toolbar.
DatePickerPartial< Omit<DatePickerProps, 'key' | 'ref' | 'multiple' | 'value' | 'defaultValue' | 'onChange'> > | nullConfigure date picker.
DateRangePickerPartial<Omit<DateRangePickerProps, 'key' | 'ref'>> | nullConfigure date range picker.
DateTimePickerPartial<Omit<DateTimePickerProps, 'key' | 'ref'>> | nullConfigure date time picker.
DescriptionsPartial<Omit<DescriptionsProps, 'key' | 'ref' | 'items'>> | nullConfigure descriptions.
DividerPartial<Omit<DividerProps, 'key' | 'ref'>> | nullConfigure divider.
DrawerPartial<Omit<DrawerProps, 'key' | 'ref' | 'open'>> | nullConfigure drawer.
DropdownPartial<Omit<DropdownProps, 'key' | 'ref' | 'items' | 'children'>> | nullConfigure dropdown.
EmptyPartial<Omit<EmptyProps, 'key' | 'ref'>> | nullConfigure empty.
ErrorBoundaryPartial<Omit<ErrorBoundaryProps, 'key' | 'ref'>> | nullConfigure error boundary.
FileListPartial<Omit<FileListProps, 'key' | 'ref' | 'items'>> | nullConfigure file list.
FlexPartial<Omit<FlexProps, 'key' | 'ref'>> | nullConfigure flex.
FloatButtonPartial<Omit<FloatButtonProps, 'key' | 'ref'>> | nullConfigure float button.
FloatButtonGroupPartial<Omit<FloatButtonGroupProps, 'key' | 'ref' | 'actions'>> | nullConfigure float button group.
FormPartial<Omit<FormProps, 'key' | 'ref'>> | nullConfigure form.
FormErrorSummaryPartial<Omit<FormErrorSummaryProps, 'key' | 'ref'>> | nullConfigure form error summary.
FormFieldPartial<Omit<FormFieldProps, 'key' | 'ref'>> | nullConfigure form field.
FormGroupPartial<Omit<FormGroupProps, 'key' | 'ref'>> | nullConfigure form group.
FormListPartial< Omit< FormListProps<unknown>, 'name' | 'children' | 'value' | 'defaultValue' | 'onChange' | 'itemKey' > > | nullConfigure form list.
GridPartial<Omit<GridProps, 'key' | 'ref'>> | nullConfigure grid.
ImagePartial<Omit<ImageProps, 'key' | 'ref'>> | nullConfigure image.
ImagePreviewPartial< Omit<ImagePreviewProps, 'key' | 'ref' | 'items' | 'open' | 'onClose'> > | nullConfigure image preview.
ImagePreviewGroupPartial<Omit<ImagePreviewGroupProps, 'key' | 'ref'>> | nullConfigure image preview group.
InfiniteScrollPartial< Omit<InfiniteScrollProps, 'key' | 'ref' | 'dataLength' | 'hasMore' | 'onLoadMore'> > | nullConfigure infinite scroll.
InputPartial<Omit<InputProps, 'key' | 'ref'>> | nullDefault input props, also inherited by InputSearch.
InputGroupPartial<Omit<InputGroupProps, 'key' | 'ref'>> | nullConfigure input group.
InputMaskPartial<Omit<InputMaskProps, 'key' | 'ref' | 'mask'>> | nullConfigure input mask.
InputNumberPartial< Omit< InputNumberProps, 'key' | 'ref' | 'stringMode' | 'value' | 'defaultValue' | 'onChange' | 'min' | 'max' | 'step' > > | nullConfigure input number.
InputOTPPartial<Omit<InputOTPProps, 'key' | 'ref'>> | nullConfigure input otp.
InputSearchPartial<Omit<InputSearchProps, 'key' | 'ref'>> | nullSearch input defaults, overriding Input defaults.
LayoutPartial<Omit<LayoutProps, 'key' | 'ref'>> | nullConfigure layout.
LayoutContentPartial<Omit<HTMLAttributes<HTMLElement>, 'key' | 'ref'>> | nullConfigure layout content.
LayoutFooterPartial<Omit<HTMLAttributes<HTMLElement>, 'key' | 'ref'>> | nullConfigure layout footer.
LayoutHeaderPartial<Omit<HTMLAttributes<HTMLElement>, 'key' | 'ref'>> | nullConfigure layout header.
LayoutSiderPartial<Omit<LayoutSiderProps, 'key' | 'ref'>> | nullConfigure layout sider.
LinkPartial<Omit<LinkProps, 'key' | 'ref'>> | nullConfigure link.
LoadingPartial<Omit<LoadingProps, 'key' | 'ref'>> | nullConfigure loading.
LoadingBarPartial<Omit<LoadingBarProps, 'key' | 'ref' | 'active' | 'progress'>> | nullConfigure loading bar.
MasonryPartial<Omit<MasonryProps, 'key' | 'ref'>> | nullConfigure masonry.
MentionsPartial<Omit<MentionsProps, 'key' | 'ref' | 'options'>> | nullConfigure mentions.
MenuPartial<Omit<MenuProps, 'key' | 'ref' | 'items'>> | nullConfigure menu.
MenuGroupPartial<Omit<MenuGroupProps, 'key' | 'ref' | 'title'>> | nullConfigure menu group.
MessagePartial<Omit<MessageOptions, 'key' | 'content'>> | nullConfigure message.
ModalPartial<Omit<ModalProps, 'key' | 'ref' | 'open'>> | nullDefault modal props.
NotificationPartial<Omit<NotificationOptions, 'key' | 'title'>> | nullConfigure notification.
PaginationPartial<Omit<PaginationProps, 'key' | 'ref' | 'total'>> | nullConfigure pagination.
ParagraphPartial<Omit<ParagraphProps, 'key' | 'ref'>> | nullConfigure paragraph.
PopconfirmPartial<Omit<PopconfirmProps, 'key' | 'ref' | 'children' | 'title'>> | nullConfigure popconfirm.
PopoverPartial<Omit<PopoverProps, 'key' | 'ref' | 'children' | 'content'>> | nullConfigure popover.
ProgressPartial<Omit<ProgressProps, 'key' | 'ref'>> | nullConfigure progress.
QRCodePartial<Omit<QRCodeProps, 'key' | 'ref' | 'value'>> | nullConfigure qrcode.
RadioPartial<Omit<RadioProps, 'key' | 'ref'>> | nullConfigure radio.
RadioGroupPartial<Omit<RadioGroupProps, 'key' | 'ref' | 'options'>> | nullConfigure radio group.
RatePartial<Omit<RateProps, 'key' | 'ref'>> | nullConfigure rate.
ResultPartial<Omit<ResultProps, 'key' | 'ref'>> | nullConfigure result.
RowPartial<Omit<RowProps, 'key' | 'ref'>> | nullConfigure row.
ScrollAreaPartial<Omit<ScrollAreaProps, 'key' | 'ref'>> | nullConfigure scroll area.
ScrollbarPartial<Omit<ScrollbarProps, 'key' | 'ref'>> | nullConfigure scrollbar.
SelectPartial< Omit< SelectProps, 'key' | 'ref' | 'options' | 'multiple' | 'value' | 'defaultValue' | 'onChange' > > | nullSelect defaults; mode, values and change callbacks stay on the instance.
SkeletonPartial<Omit<SkeletonProps, 'key' | 'ref'>> | nullConfigure skeleton.
SliderPartial< Omit<SliderProps, 'key' | 'ref' | 'range' | 'value' | 'defaultValue' | 'onChange'> > | nullConfigure slider.
SpacePartial<Omit<SpaceProps, 'key' | 'ref'>> | nullConfigure space.
SplitButtonPartial<Omit<SplitButtonProps, 'key' | 'ref' | 'items'>> | nullConfigure split button.
SplitterPartial<Omit<SplitterProps, 'key' | 'ref' | 'panels'>> | nullConfigure splitter.
StatisticPartial<Omit<StatisticProps, 'key' | 'ref' | 'value'>> | nullConfigure statistic.
StepsPartial<Omit<StepsProps, 'key' | 'ref' | 'items'>> | nullConfigure steps.
SwitchPartial<Omit<SwitchProps, 'key' | 'ref'>> | nullConfigure switch.
TabsPartial<Omit<TabsProps, 'key' | 'ref' | 'items'>> | nullConfigure tabs.
TagPartial<Omit<TagProps, 'key' | 'ref'>> | nullConfigure tag.
TagGroupPartial<Omit<TagGroupProps, 'key' | 'ref' | 'options'>> | nullConfigure tag group.
TextPartial<Omit<TextProps, 'key' | 'ref'>> | nullConfigure text.
TextareaPartial<Omit<TextareaProps, 'key' | 'ref'>> | nullConfigure textarea.
TimelinePartial<Omit<TimelineProps, 'key' | 'ref' | 'items'>> | nullConfigure timeline.
TimePickerPartial<Omit<TimePickerProps, 'key' | 'ref'>> | nullConfigure time picker.
TimeRangePickerPartial<Omit<TimeRangePickerProps, 'key' | 'ref'>> | nullConfigure time range picker.
TitlePartial<Omit<TitleProps, 'key' | 'ref'>> | nullConfigure title.
ToolbarPartial<Omit<ToolbarProps, 'key' | 'ref'>> | nullConfigure toolbar.
TooltipPartial<Omit<TooltipProps, 'key' | 'ref' | 'content' | 'children'>> | nullConfigure tooltip.
TourPartial<Omit<TourProps, 'key' | 'ref' | 'open' | 'steps'>> | nullConfigure tour.
TransferPartial<Omit<TransferProps, 'key' | 'ref' | 'items'>> | nullConfigure transfer.
TreePartial<Omit<TreeProps, 'key' | 'ref' | 'data'>> | nullConfigure tree.
TreeSelectPartial< Omit< TreeSelectProps, | 'key' | 'ref' | 'options' | 'multiple' | 'treeCheckable' | 'value' | 'defaultValue' | 'onChange' > > | nullConfigure tree select.
TypographyPartial<Omit<TypographyProps, 'key' | 'ref'>> | nullConfigure typography.
UploadPartial<Omit<UploadProps, 'key' | 'ref'>> | nullConfigure upload.
VirtualList(Partial< Omit<VirtualListProps<unknown>, 'items' | 'itemKey' | 'renderItem' | 'estimateSize'> > & { estimateSize?: number }) | nullConfigure virtual list.

Type import

import type { LeafComponentDefaults } from '@ifhover/leaf-ui';

const components = {
  Button: { variant: 'outline' },
  Confirm: { confirmText: 'Continue', cancelText: 'Back' },
} satisfies LeafComponentDefaults;

Pass this object to <ConfigProvider components={components}>. Instance props and individual service calls still take precedence.