@shohojdhara/atomix 0.3.7 → 0.3.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +19 -1
- package/dist/atomix.css +77 -0
- package/dist/atomix.css.map +1 -1
- package/dist/atomix.min.css +77 -0
- package/dist/atomix.min.css.map +1 -1
- package/dist/charts.js.map +1 -1
- package/dist/core.js.map +1 -1
- package/dist/forms.js.map +1 -1
- package/dist/heavy.js.map +1 -1
- package/dist/index.d.ts +578 -515
- package/dist/index.esm.js +3150 -2632
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +10485 -9973
- package/dist/index.js.map +1 -1
- package/dist/index.min.js +1 -1
- package/dist/index.min.js.map +1 -1
- package/dist/theme.d.ts +237 -420
- package/dist/theme.js +1616 -1701
- package/dist/theme.js.map +1 -1
- package/package.json +1 -1
- package/src/components/DataTable/DataTable.stories.tsx +238 -0
- package/src/components/DataTable/DataTable.test.tsx +450 -0
- package/src/components/DataTable/DataTable.tsx +384 -61
- package/src/components/DatePicker/DatePicker.tsx +29 -38
- package/src/components/Upload/Upload.tsx +539 -40
- package/src/lib/composables/useDataTable.ts +355 -15
- package/src/lib/composables/useDatePicker.ts +19 -0
- package/src/lib/constants/components.ts +10 -0
- package/src/lib/theme/adapters/cssVariableMapper.ts +29 -14
- package/src/lib/theme/adapters/index.ts +1 -4
- package/src/lib/theme/config/configLoader.ts +53 -35
- package/src/lib/theme/core/composeTheme.ts +22 -30
- package/src/lib/theme/core/createTheme.ts +49 -26
- package/src/lib/theme/core/index.ts +0 -1
- package/src/lib/theme/generators/generateCSSNested.ts +4 -3
- package/src/lib/theme/generators/generateCSSVariables.ts +24 -16
- package/src/lib/theme/index.ts +10 -17
- package/src/lib/theme/runtime/ThemeApplicator.ts +6 -109
- package/src/lib/theme/runtime/ThemeErrorBoundary.tsx +3 -3
- package/src/lib/theme/runtime/ThemeProvider.tsx +205 -64
- package/src/lib/theme/runtime/useTheme.ts +1 -1
- package/src/lib/theme/runtime/useThemeTokens.ts +7 -16
- package/src/lib/theme/test/testTheme.ts +2 -1
- package/src/lib/theme/types.ts +14 -14
- package/src/lib/theme/utils/componentTheming.ts +35 -27
- package/src/lib/theme/utils/domUtils.ts +57 -15
- package/src/lib/theme/utils/injectCSS.ts +0 -1
- package/src/lib/theme/utils/themeHelpers.ts +1 -39
- package/src/lib/theme/utils/themeUtils.ts +1 -170
- package/src/lib/types/components.ts +145 -0
- package/src/lib/utils/dataTableExport.ts +143 -0
- package/src/styles/06-components/_components.data-table.scss +95 -0
- package/src/lib/hooks/useThemeTokens.ts +0 -105
package/dist/index.d.ts
CHANGED
|
@@ -2539,6 +2539,41 @@ interface DataTableColumn {
|
|
|
2539
2539
|
* Width of the column (CSS value)
|
|
2540
2540
|
*/
|
|
2541
2541
|
width?: string;
|
|
2542
|
+
/**
|
|
2543
|
+
* Minimum width for resizable columns (CSS value)
|
|
2544
|
+
*/
|
|
2545
|
+
minWidth?: string;
|
|
2546
|
+
/**
|
|
2547
|
+
* Maximum width for resizable columns (CSS value)
|
|
2548
|
+
*/
|
|
2549
|
+
maxWidth?: string;
|
|
2550
|
+
/**
|
|
2551
|
+
* Whether the column is resizable
|
|
2552
|
+
*/
|
|
2553
|
+
resizable?: boolean;
|
|
2554
|
+
/**
|
|
2555
|
+
* Whether the column is visible by default
|
|
2556
|
+
*/
|
|
2557
|
+
visible?: boolean;
|
|
2558
|
+
/**
|
|
2559
|
+
* Whether the column can be reordered
|
|
2560
|
+
*/
|
|
2561
|
+
reorderable?: boolean;
|
|
2562
|
+
/**
|
|
2563
|
+
* Custom filter function for column-specific filtering
|
|
2564
|
+
*/
|
|
2565
|
+
filterFunction?: (value: any, filterValue: string) => boolean;
|
|
2566
|
+
/**
|
|
2567
|
+
* Filter type for column-specific filtering
|
|
2568
|
+
*/
|
|
2569
|
+
filterType?: 'text' | 'select' | 'date' | 'number' | 'custom';
|
|
2570
|
+
/**
|
|
2571
|
+
* Options for select-type filters
|
|
2572
|
+
*/
|
|
2573
|
+
filterOptions?: Array<{
|
|
2574
|
+
label: string;
|
|
2575
|
+
value: any;
|
|
2576
|
+
}>;
|
|
2542
2577
|
}
|
|
2543
2578
|
/**
|
|
2544
2579
|
* Sort configuration
|
|
@@ -2553,6 +2588,14 @@ interface SortConfig {
|
|
|
2553
2588
|
*/
|
|
2554
2589
|
direction: 'asc' | 'desc';
|
|
2555
2590
|
}
|
|
2591
|
+
/**
|
|
2592
|
+
* Row selection mode
|
|
2593
|
+
*/
|
|
2594
|
+
type SelectionMode = 'single' | 'multiple' | 'none';
|
|
2595
|
+
/**
|
|
2596
|
+
* Export format
|
|
2597
|
+
*/
|
|
2598
|
+
type ExportFormat = 'csv' | 'excel' | 'json';
|
|
2556
2599
|
/**
|
|
2557
2600
|
* DataTable component properties
|
|
2558
2601
|
*/
|
|
@@ -2614,6 +2657,82 @@ interface DataTableProps extends BaseComponentProps {
|
|
|
2614
2657
|
* Can be a boolean to enable with default settings, or an object with AtomixGlassProps to customize the effect
|
|
2615
2658
|
*/
|
|
2616
2659
|
glass?: AtomixGlassProps | boolean;
|
|
2660
|
+
/**
|
|
2661
|
+
* Row selection mode ('single', 'multiple', or 'none')
|
|
2662
|
+
*/
|
|
2663
|
+
selectionMode?: SelectionMode;
|
|
2664
|
+
/**
|
|
2665
|
+
* Selected row IDs (for controlled selection)
|
|
2666
|
+
*/
|
|
2667
|
+
selectedRowIds?: (string | number)[];
|
|
2668
|
+
/**
|
|
2669
|
+
* Callback when selection changes
|
|
2670
|
+
*/
|
|
2671
|
+
onSelectionChange?: (selectedRows: any[], selectedIds: (string | number)[]) => void;
|
|
2672
|
+
/**
|
|
2673
|
+
* Key to use as unique identifier for rows (defaults to 'id')
|
|
2674
|
+
*/
|
|
2675
|
+
rowKey?: string | ((row: any) => string | number);
|
|
2676
|
+
/**
|
|
2677
|
+
* Whether columns are resizable
|
|
2678
|
+
*/
|
|
2679
|
+
resizable?: boolean;
|
|
2680
|
+
/**
|
|
2681
|
+
* Whether columns can be reordered
|
|
2682
|
+
*/
|
|
2683
|
+
reorderable?: boolean;
|
|
2684
|
+
/**
|
|
2685
|
+
* Callback when column order changes
|
|
2686
|
+
*/
|
|
2687
|
+
onColumnReorder?: (columnKeys: string[]) => void;
|
|
2688
|
+
/**
|
|
2689
|
+
* Whether to show column visibility toggle
|
|
2690
|
+
*/
|
|
2691
|
+
showColumnVisibility?: boolean;
|
|
2692
|
+
/**
|
|
2693
|
+
* Callback when column visibility changes
|
|
2694
|
+
*/
|
|
2695
|
+
onColumnVisibilityChange?: (visibleColumns: string[]) => void;
|
|
2696
|
+
/**
|
|
2697
|
+
* Whether to enable sticky headers
|
|
2698
|
+
*/
|
|
2699
|
+
stickyHeader?: boolean;
|
|
2700
|
+
/**
|
|
2701
|
+
* Offset from top for sticky headers (CSS value)
|
|
2702
|
+
*/
|
|
2703
|
+
stickyHeaderOffset?: string;
|
|
2704
|
+
/**
|
|
2705
|
+
* Whether to enable virtual scrolling for large datasets
|
|
2706
|
+
*/
|
|
2707
|
+
virtualScrolling?: boolean;
|
|
2708
|
+
/**
|
|
2709
|
+
* Estimated row height for virtual scrolling (in pixels)
|
|
2710
|
+
*/
|
|
2711
|
+
estimatedRowHeight?: number;
|
|
2712
|
+
/**
|
|
2713
|
+
* Number of rows to render outside visible area (overscan)
|
|
2714
|
+
*/
|
|
2715
|
+
overscan?: number;
|
|
2716
|
+
/**
|
|
2717
|
+
* Whether to enable export functionality
|
|
2718
|
+
*/
|
|
2719
|
+
exportable?: boolean;
|
|
2720
|
+
/**
|
|
2721
|
+
* Export formats available
|
|
2722
|
+
*/
|
|
2723
|
+
exportFormats?: ExportFormat[];
|
|
2724
|
+
/**
|
|
2725
|
+
* Custom export filename
|
|
2726
|
+
*/
|
|
2727
|
+
exportFilename?: string;
|
|
2728
|
+
/**
|
|
2729
|
+
* Callback for custom export logic
|
|
2730
|
+
*/
|
|
2731
|
+
onExport?: (format: ExportFormat, data: any[]) => void;
|
|
2732
|
+
/**
|
|
2733
|
+
* Whether to show column-specific filters
|
|
2734
|
+
*/
|
|
2735
|
+
columnFilters?: boolean;
|
|
2617
2736
|
}
|
|
2618
2737
|
/**
|
|
2619
2738
|
* Pagination component properties
|
|
@@ -8226,6 +8345,7 @@ type __lib_types_EdgePanelPosition = EdgePanelPosition;
|
|
|
8226
8345
|
type __lib_types_EdgePanelProps = EdgePanelProps;
|
|
8227
8346
|
type __lib_types_ElementRefs = ElementRefs;
|
|
8228
8347
|
type __lib_types_ElevationCardProps = ElevationCardProps;
|
|
8348
|
+
type __lib_types_ExportFormat = ExportFormat;
|
|
8229
8349
|
type __lib_types_FooterLayout = FooterLayout;
|
|
8230
8350
|
type __lib_types_FooterLinkProps = FooterLinkProps;
|
|
8231
8351
|
type __lib_types_FooterProps = FooterProps;
|
|
@@ -8271,6 +8391,7 @@ type __lib_types_RadioProps = RadioProps;
|
|
|
8271
8391
|
type __lib_types_RatingProps = RatingProps;
|
|
8272
8392
|
type __lib_types_SelectOption = SelectOption;
|
|
8273
8393
|
type __lib_types_SelectProps = SelectProps;
|
|
8394
|
+
type __lib_types_SelectionMode = SelectionMode;
|
|
8274
8395
|
type __lib_types_SideMenuItemProps = SideMenuItemProps;
|
|
8275
8396
|
type __lib_types_SideMenuListProps = SideMenuListProps;
|
|
8276
8397
|
type __lib_types_SideMenuProps = SideMenuProps;
|
|
@@ -8308,7 +8429,7 @@ type __lib_types_VideoQuality = VideoQuality;
|
|
|
8308
8429
|
type __lib_types_VideoSubtitle = VideoSubtitle;
|
|
8309
8430
|
type __lib_types_listvariant = listvariant;
|
|
8310
8431
|
declare namespace __lib_types {
|
|
8311
|
-
export type { AccordionProps$1 as AccordionProps, __lib_types_AccordionState as AccordionState, __lib_types_AtomixGlassProps as AtomixGlassProps, __lib_types_AvatarGroupProps as AvatarGroupProps, __lib_types_AvatarProps as AvatarProps, __lib_types_AvatarSize as AvatarSize, __lib_types_BadgeProps as BadgeProps, __lib_types_BaseComponentProps as BaseComponentProps, __lib_types_BreadcrumbInstance as BreadcrumbInstance, BreadcrumbItem$1 as BreadcrumbItem, BreadcrumbOptions$1 as BreadcrumbOptions, __lib_types_ButtonGroupProps as ButtonGroupProps, __lib_types_ButtonProps as ButtonProps, __lib_types_CalloutProps as CalloutProps, __lib_types_CardProps as CardProps, ChartAxis$1 as ChartAxis, ChartConfig$1 as ChartConfig, ChartDataPoint$1 as ChartDataPoint, ChartDataset$1 as ChartDataset, ChartProps$1 as ChartProps, ChartSize$1 as ChartSize, ChartType$1 as ChartType, __lib_types_CheckboxProps as CheckboxProps, __lib_types_CodeBlockProps as CodeBlockProps, __lib_types_DataTableColumn as DataTableColumn, __lib_types_DataTableProps as DataTableProps, __lib_types_DisplacementMode as DisplacementMode, __lib_types_DropdownDividerProps as DropdownDividerProps, __lib_types_DropdownHeaderProps as DropdownHeaderProps, __lib_types_DropdownItemProps as DropdownItemProps, __lib_types_DropdownPlacement as DropdownPlacement, __lib_types_DropdownProps as DropdownProps, __lib_types_DropdownTrigger as DropdownTrigger, __lib_types_EdgePanelMode as EdgePanelMode, __lib_types_EdgePanelPosition as EdgePanelPosition, __lib_types_EdgePanelProps as EdgePanelProps, __lib_types_ElementRefs as ElementRefs, __lib_types_ElevationCardProps as ElevationCardProps, __lib_types_FooterLayout as FooterLayout, __lib_types_FooterLinkProps as FooterLinkProps, __lib_types_FooterProps as FooterProps, __lib_types_FooterSectionProps as FooterSectionProps, __lib_types_FooterSocialLinkProps as FooterSocialLinkProps, __lib_types_FormGroupProps as FormGroupProps, __lib_types_FormProps as FormProps, __lib_types_GlassContainerProps as GlassContainerProps, __lib_types_GlassMode as GlassMode, __lib_types_GlassSize as GlassSize, __lib_types_HeroAlignment as HeroAlignment, __lib_types_HeroBackgroundSlide as HeroBackgroundSlide, __lib_types_HeroBackgroundSliderConfig as HeroBackgroundSliderConfig, __lib_types_HeroProps as HeroProps, __lib_types_IconPosition as IconPosition, IconSize$1 as IconSize, IconWeight$1 as IconWeight, __lib_types_ImageType as ImageType, __lib_types_InputProps as InputProps, ListGroupProps$1 as ListGroupProps, __lib_types_ListProps as ListProps, __lib_types_MegaMenuColumnProps as MegaMenuColumnProps, __lib_types_MegaMenuLinkProps as MegaMenuLinkProps, __lib_types_MegaMenuProps as MegaMenuProps, __lib_types_MenuItemProps as MenuItemProps, __lib_types_MenuProps as MenuProps, __lib_types_MessageItem as MessageItem, __lib_types_MessagesProps as MessagesProps, __lib_types_ModalProps as ModalProps, __lib_types_MousePosition as MousePosition, __lib_types_NavAlignment as NavAlignment, __lib_types_NavDropdownProps as NavDropdownProps, __lib_types_NavItemProps as NavItemProps, __lib_types_NavProps as NavProps, __lib_types_NavVariant as NavVariant, __lib_types_NavbarPosition as NavbarPosition, __lib_types_NavbarProps as NavbarProps, __lib_types_OverLightConfig as OverLightConfig, __lib_types_OverLightObjectConfig as OverLightObjectConfig, __lib_types_PaginationProps as PaginationProps, PhosphorIconsType$1 as PhosphorIconsType, __lib_types_PhotoViewerProps as PhotoViewerProps, __lib_types_PopoverProps as PopoverProps, __lib_types_PopoverTriggerProps as PopoverTriggerProps, __lib_types_ProgressProps as ProgressProps, __lib_types_RadioProps as RadioProps, __lib_types_RatingProps as RatingProps, __lib_types_SelectOption as SelectOption, __lib_types_SelectProps as SelectProps, __lib_types_SideMenuItemProps as SideMenuItemProps, __lib_types_SideMenuListProps as SideMenuListProps, __lib_types_SideMenuProps as SideMenuProps, __lib_types_Size as Size, __lib_types_SliderAutoplay as SliderAutoplay, __lib_types_SliderBreakpoint as SliderBreakpoint, __lib_types_SliderEffect as SliderEffect, __lib_types_SliderLazy as SliderLazy, __lib_types_SliderNavigation as SliderNavigation, __lib_types_SliderPagination as SliderPagination, __lib_types_SliderProps as SliderProps, __lib_types_SliderRefs as SliderRefs, __lib_types_SliderScrollbar as SliderScrollbar, __lib_types_SliderSlide as SliderSlide, __lib_types_SliderState as SliderState, __lib_types_SliderThumbs as SliderThumbs, __lib_types_SliderVirtual as SliderVirtual, __lib_types_SliderZoom as SliderZoom, __lib_types_SocialLink as SocialLink, __lib_types_SocialPlatform as SocialPlatform, __lib_types_SortConfig as SortConfig, __lib_types_SpinnerProps as SpinnerProps, __lib_types_StateModifier as StateModifier, __lib_types_TextareaProps as TextareaProps, __lib_types_ThemeColor as ThemeColor, __lib_types_ThemeName as ThemeName, __lib_types_TodoItem as TodoItem, __lib_types_TodoProps as TodoProps, __lib_types_UseCardOptions as UseCardOptions, __lib_types_UseCardReturn as UseCardReturn, __lib_types_Variant as Variant, __lib_types_VideoChapter as VideoChapter, __lib_types_VideoPlayerProps as VideoPlayerProps, __lib_types_VideoQuality as VideoQuality, __lib_types_VideoSubtitle as VideoSubtitle, __lib_types_listvariant as listvariant };
|
|
8432
|
+
export type { AccordionProps$1 as AccordionProps, __lib_types_AccordionState as AccordionState, __lib_types_AtomixGlassProps as AtomixGlassProps, __lib_types_AvatarGroupProps as AvatarGroupProps, __lib_types_AvatarProps as AvatarProps, __lib_types_AvatarSize as AvatarSize, __lib_types_BadgeProps as BadgeProps, __lib_types_BaseComponentProps as BaseComponentProps, __lib_types_BreadcrumbInstance as BreadcrumbInstance, BreadcrumbItem$1 as BreadcrumbItem, BreadcrumbOptions$1 as BreadcrumbOptions, __lib_types_ButtonGroupProps as ButtonGroupProps, __lib_types_ButtonProps as ButtonProps, __lib_types_CalloutProps as CalloutProps, __lib_types_CardProps as CardProps, ChartAxis$1 as ChartAxis, ChartConfig$1 as ChartConfig, ChartDataPoint$1 as ChartDataPoint, ChartDataset$1 as ChartDataset, ChartProps$1 as ChartProps, ChartSize$1 as ChartSize, ChartType$1 as ChartType, __lib_types_CheckboxProps as CheckboxProps, __lib_types_CodeBlockProps as CodeBlockProps, __lib_types_DataTableColumn as DataTableColumn, __lib_types_DataTableProps as DataTableProps, __lib_types_DisplacementMode as DisplacementMode, __lib_types_DropdownDividerProps as DropdownDividerProps, __lib_types_DropdownHeaderProps as DropdownHeaderProps, __lib_types_DropdownItemProps as DropdownItemProps, __lib_types_DropdownPlacement as DropdownPlacement, __lib_types_DropdownProps as DropdownProps, __lib_types_DropdownTrigger as DropdownTrigger, __lib_types_EdgePanelMode as EdgePanelMode, __lib_types_EdgePanelPosition as EdgePanelPosition, __lib_types_EdgePanelProps as EdgePanelProps, __lib_types_ElementRefs as ElementRefs, __lib_types_ElevationCardProps as ElevationCardProps, __lib_types_ExportFormat as ExportFormat, __lib_types_FooterLayout as FooterLayout, __lib_types_FooterLinkProps as FooterLinkProps, __lib_types_FooterProps as FooterProps, __lib_types_FooterSectionProps as FooterSectionProps, __lib_types_FooterSocialLinkProps as FooterSocialLinkProps, __lib_types_FormGroupProps as FormGroupProps, __lib_types_FormProps as FormProps, __lib_types_GlassContainerProps as GlassContainerProps, __lib_types_GlassMode as GlassMode, __lib_types_GlassSize as GlassSize, __lib_types_HeroAlignment as HeroAlignment, __lib_types_HeroBackgroundSlide as HeroBackgroundSlide, __lib_types_HeroBackgroundSliderConfig as HeroBackgroundSliderConfig, __lib_types_HeroProps as HeroProps, __lib_types_IconPosition as IconPosition, IconSize$1 as IconSize, IconWeight$1 as IconWeight, __lib_types_ImageType as ImageType, __lib_types_InputProps as InputProps, ListGroupProps$1 as ListGroupProps, __lib_types_ListProps as ListProps, __lib_types_MegaMenuColumnProps as MegaMenuColumnProps, __lib_types_MegaMenuLinkProps as MegaMenuLinkProps, __lib_types_MegaMenuProps as MegaMenuProps, __lib_types_MenuItemProps as MenuItemProps, __lib_types_MenuProps as MenuProps, __lib_types_MessageItem as MessageItem, __lib_types_MessagesProps as MessagesProps, __lib_types_ModalProps as ModalProps, __lib_types_MousePosition as MousePosition, __lib_types_NavAlignment as NavAlignment, __lib_types_NavDropdownProps as NavDropdownProps, __lib_types_NavItemProps as NavItemProps, __lib_types_NavProps as NavProps, __lib_types_NavVariant as NavVariant, __lib_types_NavbarPosition as NavbarPosition, __lib_types_NavbarProps as NavbarProps, __lib_types_OverLightConfig as OverLightConfig, __lib_types_OverLightObjectConfig as OverLightObjectConfig, __lib_types_PaginationProps as PaginationProps, PhosphorIconsType$1 as PhosphorIconsType, __lib_types_PhotoViewerProps as PhotoViewerProps, __lib_types_PopoverProps as PopoverProps, __lib_types_PopoverTriggerProps as PopoverTriggerProps, __lib_types_ProgressProps as ProgressProps, __lib_types_RadioProps as RadioProps, __lib_types_RatingProps as RatingProps, __lib_types_SelectOption as SelectOption, __lib_types_SelectProps as SelectProps, __lib_types_SelectionMode as SelectionMode, __lib_types_SideMenuItemProps as SideMenuItemProps, __lib_types_SideMenuListProps as SideMenuListProps, __lib_types_SideMenuProps as SideMenuProps, __lib_types_Size as Size, __lib_types_SliderAutoplay as SliderAutoplay, __lib_types_SliderBreakpoint as SliderBreakpoint, __lib_types_SliderEffect as SliderEffect, __lib_types_SliderLazy as SliderLazy, __lib_types_SliderNavigation as SliderNavigation, __lib_types_SliderPagination as SliderPagination, __lib_types_SliderProps as SliderProps, __lib_types_SliderRefs as SliderRefs, __lib_types_SliderScrollbar as SliderScrollbar, __lib_types_SliderSlide as SliderSlide, __lib_types_SliderState as SliderState, __lib_types_SliderThumbs as SliderThumbs, __lib_types_SliderVirtual as SliderVirtual, __lib_types_SliderZoom as SliderZoom, __lib_types_SocialLink as SocialLink, __lib_types_SocialPlatform as SocialPlatform, __lib_types_SortConfig as SortConfig, __lib_types_SpinnerProps as SpinnerProps, __lib_types_StateModifier as StateModifier, __lib_types_TextareaProps as TextareaProps, __lib_types_ThemeColor as ThemeColor, __lib_types_ThemeName as ThemeName, __lib_types_TodoItem as TodoItem, __lib_types_TodoProps as TodoProps, __lib_types_UseCardOptions as UseCardOptions, __lib_types_UseCardReturn as UseCardReturn, __lib_types_Variant as Variant, __lib_types_VideoChapter as VideoChapter, __lib_types_VideoPlayerProps as VideoPlayerProps, __lib_types_VideoQuality as VideoQuality, __lib_types_VideoSubtitle as VideoSubtitle, __lib_types_listvariant as listvariant };
|
|
8312
8433
|
}
|
|
8313
8434
|
|
|
8314
8435
|
/**
|
|
@@ -8906,21 +9027,31 @@ declare const DATA_TABLE_CLASSES: {
|
|
|
8906
9027
|
header: string;
|
|
8907
9028
|
headerCell: string;
|
|
8908
9029
|
headerContent: string;
|
|
9030
|
+
headerActions: string;
|
|
8909
9031
|
sortable: string;
|
|
8910
9032
|
sortIcon: string;
|
|
8911
9033
|
row: string;
|
|
9034
|
+
rowSelected: string;
|
|
8912
9035
|
cell: string;
|
|
9036
|
+
selectionCell: string;
|
|
8913
9037
|
loadingCell: string;
|
|
8914
9038
|
loadingIndicator: string;
|
|
8915
9039
|
emptyCell: string;
|
|
8916
9040
|
toolbar: string;
|
|
9041
|
+
toolbarLeft: string;
|
|
9042
|
+
toolbarRight: string;
|
|
8917
9043
|
search: string;
|
|
8918
9044
|
searchInput: string;
|
|
9045
|
+
columnFilter: string;
|
|
8919
9046
|
pagination: string;
|
|
8920
9047
|
striped: string;
|
|
8921
9048
|
bordered: string;
|
|
8922
9049
|
dense: string;
|
|
8923
9050
|
loading: string;
|
|
9051
|
+
stickyHeader: string;
|
|
9052
|
+
dragging: string;
|
|
9053
|
+
dragOver: string;
|
|
9054
|
+
resizeHandle: string;
|
|
8924
9055
|
open: string;
|
|
8925
9056
|
};
|
|
8926
9057
|
/**
|
|
@@ -11010,6 +11141,38 @@ interface UseDataTableProps {
|
|
|
11010
11141
|
* Initial sort configuration
|
|
11011
11142
|
*/
|
|
11012
11143
|
initialSortConfig?: SortConfig;
|
|
11144
|
+
/**
|
|
11145
|
+
* Row selection mode
|
|
11146
|
+
*/
|
|
11147
|
+
selectionMode?: SelectionMode;
|
|
11148
|
+
/**
|
|
11149
|
+
* Selected row IDs (controlled)
|
|
11150
|
+
*/
|
|
11151
|
+
selectedRowIds?: (string | number)[];
|
|
11152
|
+
/**
|
|
11153
|
+
* Callback when selection changes
|
|
11154
|
+
*/
|
|
11155
|
+
onSelectionChange?: (selectedRows: any[], selectedIds: (string | number)[]) => void;
|
|
11156
|
+
/**
|
|
11157
|
+
* Key to use as unique identifier for rows
|
|
11158
|
+
*/
|
|
11159
|
+
rowKey?: string | ((row: any) => string | number);
|
|
11160
|
+
/**
|
|
11161
|
+
* Column-specific filters
|
|
11162
|
+
*/
|
|
11163
|
+
columnFilters?: boolean;
|
|
11164
|
+
/**
|
|
11165
|
+
* Whether columns can be reordered
|
|
11166
|
+
*/
|
|
11167
|
+
reorderable?: boolean;
|
|
11168
|
+
/**
|
|
11169
|
+
* Callback when column order changes
|
|
11170
|
+
*/
|
|
11171
|
+
onColumnReorder?: (columnKeys: string[]) => void;
|
|
11172
|
+
/**
|
|
11173
|
+
* Callback when column visibility changes
|
|
11174
|
+
*/
|
|
11175
|
+
onColumnVisibilityChange?: (visibleColumns: string[]) => void;
|
|
11013
11176
|
}
|
|
11014
11177
|
interface UseDataTableReturn {
|
|
11015
11178
|
/**
|
|
@@ -11040,11 +11203,63 @@ interface UseDataTableReturn {
|
|
|
11040
11203
|
* Handle search input
|
|
11041
11204
|
*/
|
|
11042
11205
|
handleSearch: (query: string) => void;
|
|
11206
|
+
/**
|
|
11207
|
+
* Selected row IDs
|
|
11208
|
+
*/
|
|
11209
|
+
selectedRowIds: (string | number)[];
|
|
11210
|
+
/**
|
|
11211
|
+
* Selected rows data
|
|
11212
|
+
*/
|
|
11213
|
+
selectedRows: any[];
|
|
11214
|
+
/**
|
|
11215
|
+
* Handle row selection
|
|
11216
|
+
*/
|
|
11217
|
+
handleRowSelect: (rowId: string | number, selected: boolean) => void;
|
|
11218
|
+
/**
|
|
11219
|
+
* Handle select all
|
|
11220
|
+
*/
|
|
11221
|
+
handleSelectAll: (selected: boolean) => void;
|
|
11222
|
+
/**
|
|
11223
|
+
* Whether all rows are selected
|
|
11224
|
+
*/
|
|
11225
|
+
isAllSelected: boolean;
|
|
11226
|
+
/**
|
|
11227
|
+
* Whether some rows are selected
|
|
11228
|
+
*/
|
|
11229
|
+
isIndeterminate: boolean;
|
|
11230
|
+
/**
|
|
11231
|
+
* Column order
|
|
11232
|
+
*/
|
|
11233
|
+
columnOrder: string[];
|
|
11234
|
+
/**
|
|
11235
|
+
* Visible columns
|
|
11236
|
+
*/
|
|
11237
|
+
visibleColumns: DataTableColumn[];
|
|
11238
|
+
/**
|
|
11239
|
+
* Column visibility map
|
|
11240
|
+
*/
|
|
11241
|
+
columnVisibility: Record<string, boolean>;
|
|
11242
|
+
/**
|
|
11243
|
+
* Handle column visibility toggle
|
|
11244
|
+
*/
|
|
11245
|
+
handleColumnVisibilityToggle: (columnKey: string) => void;
|
|
11246
|
+
/**
|
|
11247
|
+
* Column-specific filter values
|
|
11248
|
+
*/
|
|
11249
|
+
columnFilterValues: Record<string, string>;
|
|
11250
|
+
/**
|
|
11251
|
+
* Handle column filter change
|
|
11252
|
+
*/
|
|
11253
|
+
handleColumnFilterChange: (columnKey: string, value: string) => void;
|
|
11254
|
+
/**
|
|
11255
|
+
* Clear all column filters
|
|
11256
|
+
*/
|
|
11257
|
+
clearColumnFilters: () => void;
|
|
11043
11258
|
}
|
|
11044
11259
|
/**
|
|
11045
11260
|
* Hook for managing DataTable state and behavior
|
|
11046
11261
|
*/
|
|
11047
|
-
declare function useDataTable({ data, columns, sortable, paginated, pageSize, onSort, initialSortConfig, }: UseDataTableProps): UseDataTableReturn;
|
|
11262
|
+
declare function useDataTable({ data, columns, sortable, paginated, pageSize, onSort, initialSortConfig, selectionMode, selectedRowIds: controlledSelectedRowIds, onSelectionChange, rowKey, columnFilters, reorderable, onColumnReorder, onColumnVisibilityChange, }: UseDataTableProps): UseDataTableReturn;
|
|
11048
11263
|
|
|
11049
11264
|
interface UseModalProps {
|
|
11050
11265
|
/**
|
|
@@ -11518,7 +11733,7 @@ interface CountdownProps {
|
|
|
11518
11733
|
declare const Countdown: React__default.FC<CountdownProps>;
|
|
11519
11734
|
|
|
11520
11735
|
/**
|
|
11521
|
-
* DataTable - A flexible and accessible data table component
|
|
11736
|
+
* DataTable - A flexible and accessible data table component with advanced features
|
|
11522
11737
|
*
|
|
11523
11738
|
* @example
|
|
11524
11739
|
* ```tsx
|
|
@@ -11526,6 +11741,7 @@ declare const Countdown: React__default.FC<CountdownProps>;
|
|
|
11526
11741
|
* data={users}
|
|
11527
11742
|
* columns={columns}
|
|
11528
11743
|
* sortable={true}
|
|
11744
|
+
* selectionMode="multiple"
|
|
11529
11745
|
* onRowClick={handleRowClick}
|
|
11530
11746
|
* />
|
|
11531
11747
|
* ```
|
|
@@ -12277,6 +12493,38 @@ interface UploadProps {
|
|
|
12277
12493
|
* Icon component or class name
|
|
12278
12494
|
*/
|
|
12279
12495
|
icon?: React__default.ReactNode;
|
|
12496
|
+
/**
|
|
12497
|
+
* Upload endpoint URL. If not provided, upload will be simulated.
|
|
12498
|
+
*/
|
|
12499
|
+
uploadEndpoint?: string;
|
|
12500
|
+
/**
|
|
12501
|
+
* HTTP method for upload request
|
|
12502
|
+
*/
|
|
12503
|
+
uploadMethod?: 'POST' | 'PUT' | 'PATCH';
|
|
12504
|
+
/**
|
|
12505
|
+
* Additional headers to include in upload request
|
|
12506
|
+
*/
|
|
12507
|
+
uploadHeaders?: Record<string, string>;
|
|
12508
|
+
/**
|
|
12509
|
+
* Additional form data fields to include in upload
|
|
12510
|
+
*/
|
|
12511
|
+
uploadData?: Record<string, string>;
|
|
12512
|
+
/**
|
|
12513
|
+
* Chunk size in MB for chunked uploads (0 = no chunking)
|
|
12514
|
+
*/
|
|
12515
|
+
chunkSizeInMB?: number;
|
|
12516
|
+
/**
|
|
12517
|
+
* Maximum number of retry attempts for failed uploads
|
|
12518
|
+
*/
|
|
12519
|
+
maxRetries?: number;
|
|
12520
|
+
/**
|
|
12521
|
+
* Delay in milliseconds between retry attempts
|
|
12522
|
+
*/
|
|
12523
|
+
retryDelay?: number;
|
|
12524
|
+
/**
|
|
12525
|
+
* Whether to automatically upload files after selection
|
|
12526
|
+
*/
|
|
12527
|
+
autoUpload?: boolean;
|
|
12280
12528
|
/**
|
|
12281
12529
|
* Called when files are selected
|
|
12282
12530
|
*/
|
|
@@ -12288,11 +12536,15 @@ interface UploadProps {
|
|
|
12288
12536
|
/**
|
|
12289
12537
|
* Called when file upload is complete
|
|
12290
12538
|
*/
|
|
12291
|
-
onFileUploadComplete?: (file: File) => void;
|
|
12539
|
+
onFileUploadComplete?: (file: File, response?: any) => void;
|
|
12292
12540
|
/**
|
|
12293
12541
|
* Called on file upload errors
|
|
12294
12542
|
*/
|
|
12295
12543
|
onFileUploadError?: (file: File, error: string) => void;
|
|
12544
|
+
/**
|
|
12545
|
+
* Called when upload is cancelled
|
|
12546
|
+
*/
|
|
12547
|
+
onUploadCancel?: (file: File) => void;
|
|
12296
12548
|
/**
|
|
12297
12549
|
* Additional CSS class
|
|
12298
12550
|
*/
|
|
@@ -12606,109 +12858,306 @@ declare const defaultTokens: DesignTokens;
|
|
|
12606
12858
|
declare function createTokens(overrides?: Partial<DesignTokens>): DesignTokens;
|
|
12607
12859
|
|
|
12608
12860
|
/**
|
|
12609
|
-
*
|
|
12861
|
+
* CSS Variable Generator
|
|
12610
12862
|
*
|
|
12611
|
-
*
|
|
12612
|
-
*/
|
|
12613
|
-
/**
|
|
12614
|
-
* Theme metadata interface matching themes.config.js structure
|
|
12863
|
+
* Generates CSS custom properties from design tokens.
|
|
12615
12864
|
*/
|
|
12616
|
-
|
|
12617
|
-
/** Display name of the theme */
|
|
12618
|
-
name: string;
|
|
12619
|
-
/** Unique identifier/class name for the theme */
|
|
12620
|
-
class?: string;
|
|
12621
|
-
/** Theme description */
|
|
12622
|
-
description?: string;
|
|
12623
|
-
/** Theme author */
|
|
12624
|
-
author?: string;
|
|
12625
|
-
/** Theme version (semver) */
|
|
12626
|
-
version?: string;
|
|
12627
|
-
/** Theme tags for categorization */
|
|
12628
|
-
tags?: string[];
|
|
12629
|
-
/** Whether the theme supports dark mode */
|
|
12630
|
-
supportsDarkMode?: boolean;
|
|
12631
|
-
/** Theme status: stable, beta, experimental, deprecated */
|
|
12632
|
-
status?: 'stable' | 'beta' | 'experimental' | 'deprecated';
|
|
12633
|
-
/** Accessibility information */
|
|
12634
|
-
a11y?: {
|
|
12635
|
-
/** Target contrast ratio */
|
|
12636
|
-
contrastTarget?: number;
|
|
12637
|
-
/** Supported color modes */
|
|
12638
|
-
modes?: string[];
|
|
12639
|
-
};
|
|
12640
|
-
/** Primary theme color (for UI display) */
|
|
12641
|
-
color?: string;
|
|
12642
|
-
/** Theme features list */
|
|
12643
|
-
features?: string[];
|
|
12644
|
-
/** Theme dependencies (other themes required) */
|
|
12645
|
-
dependencies?: string[];
|
|
12646
|
-
}
|
|
12865
|
+
|
|
12647
12866
|
/**
|
|
12648
|
-
*
|
|
12867
|
+
* Options for CSS variable generation
|
|
12649
12868
|
*/
|
|
12650
|
-
interface
|
|
12651
|
-
/**
|
|
12652
|
-
|
|
12653
|
-
/**
|
|
12654
|
-
|
|
12655
|
-
/** Theme object (for JS themes) */
|
|
12656
|
-
themeObject?: Theme | null;
|
|
12657
|
-
/** Timestamp of the change */
|
|
12658
|
-
timestamp: number;
|
|
12659
|
-
/** Whether the change was from user action or system */
|
|
12660
|
-
source: 'user' | 'system' | 'storage';
|
|
12869
|
+
interface GenerateCSSVariablesOptions {
|
|
12870
|
+
/** CSS selector for the variables (default: ':root') */
|
|
12871
|
+
selector?: string;
|
|
12872
|
+
/** Prefix for CSS variables (default: 'atomix') */
|
|
12873
|
+
prefix?: string;
|
|
12661
12874
|
}
|
|
12662
12875
|
/**
|
|
12663
|
-
*
|
|
12876
|
+
* Generate CSS variables from tokens
|
|
12877
|
+
*
|
|
12878
|
+
* Converts flat token object to CSS custom properties.
|
|
12879
|
+
*
|
|
12880
|
+
* @param tokens - Design tokens object
|
|
12881
|
+
* @param options - Generation options
|
|
12882
|
+
* @returns CSS string with custom properties
|
|
12883
|
+
*
|
|
12884
|
+
* @example
|
|
12885
|
+
* ```typescript
|
|
12886
|
+
* const tokens = {
|
|
12887
|
+
* 'primary': '#7c3aed',
|
|
12888
|
+
* 'spacing-4': '1rem',
|
|
12889
|
+
* };
|
|
12890
|
+
*
|
|
12891
|
+
* const css = generateCSSVariables(tokens);
|
|
12892
|
+
* // Returns: ":root {\n --atomix-primary: #7c3aed;\n --atomix-spacing-4: 1rem;\n}"
|
|
12893
|
+
* ```
|
|
12664
12894
|
*/
|
|
12665
|
-
|
|
12666
|
-
/** Force reload even if already loaded */
|
|
12667
|
-
force?: boolean;
|
|
12668
|
-
/** Preload without applying */
|
|
12669
|
-
preload?: boolean;
|
|
12670
|
-
/** Remove previous theme CSS */
|
|
12671
|
-
removePrevious?: boolean;
|
|
12672
|
-
/** Custom CSS path override */
|
|
12673
|
-
customPath?: string;
|
|
12674
|
-
/** Fallback to default theme on error */
|
|
12675
|
-
fallbackOnError?: boolean;
|
|
12676
|
-
}
|
|
12895
|
+
declare function generateCSSVariables(tokens: DesignTokens, options?: GenerateCSSVariablesOptions): string;
|
|
12677
12896
|
/**
|
|
12678
|
-
*
|
|
12897
|
+
* Generate CSS variables with custom selector
|
|
12898
|
+
*
|
|
12899
|
+
* Useful for theme-specific selectors like `[data-theme="dark"]`
|
|
12900
|
+
*
|
|
12901
|
+
* @param tokens - Design tokens object
|
|
12902
|
+
* @param selector - CSS selector (e.g., '[data-theme="dark"]')
|
|
12903
|
+
* @param prefix - CSS variable prefix
|
|
12904
|
+
* @returns CSS string
|
|
12905
|
+
*
|
|
12906
|
+
* @example
|
|
12907
|
+
* ```typescript
|
|
12908
|
+
* const css = generateCSSVariablesForSelector(
|
|
12909
|
+
* tokens,
|
|
12910
|
+
* '[data-theme="dark"]',
|
|
12911
|
+
* 'atomix'
|
|
12912
|
+
* );
|
|
12913
|
+
* ```
|
|
12679
12914
|
*/
|
|
12680
|
-
|
|
12681
|
-
|
|
12682
|
-
valid: boolean;
|
|
12683
|
-
/** Validation errors */
|
|
12684
|
-
errors: string[];
|
|
12685
|
-
/** Validation warnings */
|
|
12686
|
-
warnings: string[];
|
|
12687
|
-
}
|
|
12915
|
+
declare function generateCSSVariablesForSelector(tokens: DesignTokens, selector: string, prefix?: string): string;
|
|
12916
|
+
|
|
12688
12917
|
/**
|
|
12689
|
-
*
|
|
12918
|
+
* Core Theme Functions
|
|
12919
|
+
*
|
|
12920
|
+
* Simplified theme system using DesignTokens only.
|
|
12921
|
+
* Config-first approach: loads from atomix.config.ts when no input is provided.
|
|
12690
12922
|
*/
|
|
12691
|
-
|
|
12692
|
-
/** Current theme name */
|
|
12693
|
-
theme: string;
|
|
12694
|
-
/** Current active theme object (for JS themes) */
|
|
12695
|
-
activeTheme: Theme | null;
|
|
12696
|
-
/** Function to change theme (supports string, Theme, or DesignTokens) */
|
|
12697
|
-
setTheme: (theme: string | Theme | DesignTokens | Partial<DesignTokens>, options?: ThemeLoadOptions) => Promise<void>;
|
|
12698
|
-
/** Available themes */
|
|
12699
|
-
availableThemes: ThemeMetadata$1[];
|
|
12700
|
-
/** Whether a theme is currently loading */
|
|
12701
|
-
isLoading: boolean;
|
|
12702
|
-
/** Current error, if any */
|
|
12703
|
-
error: Error | null;
|
|
12704
|
-
/** Whether a specific theme is loaded */
|
|
12705
|
-
isThemeLoaded: (themeName: string) => boolean;
|
|
12706
|
-
/** Preload a theme */
|
|
12707
|
-
preloadTheme: (themeName: string) => Promise<void>;
|
|
12708
|
-
}
|
|
12923
|
+
|
|
12709
12924
|
/**
|
|
12710
|
-
*
|
|
12711
|
-
|
|
12925
|
+
* Create theme CSS from DesignTokens
|
|
12926
|
+
*
|
|
12927
|
+
* **Config-First Approach**: If no input is provided, loads from `atomix.config.ts`.
|
|
12928
|
+
*
|
|
12929
|
+
* @param input - DesignTokens (partial) or undefined (loads from config)
|
|
12930
|
+
* @param options - CSS generation options (prefix is automatically read from config if not provided)
|
|
12931
|
+
* @returns CSS string with custom properties
|
|
12932
|
+
* @throws Error if config loading fails when no input is provided
|
|
12933
|
+
*
|
|
12934
|
+
* @example
|
|
12935
|
+
* ```typescript
|
|
12936
|
+
* // Loads from atomix.config.ts
|
|
12937
|
+
* const css = createTheme();
|
|
12938
|
+
*
|
|
12939
|
+
* // Using DesignTokens
|
|
12940
|
+
* const css = createTheme({
|
|
12941
|
+
* 'primary': '#7c3aed',
|
|
12942
|
+
* 'spacing-4': '1rem',
|
|
12943
|
+
* });
|
|
12944
|
+
*
|
|
12945
|
+
* // With custom options
|
|
12946
|
+
* const css = createTheme(undefined, { prefix: 'myapp', selector: ':root' });
|
|
12947
|
+
* ```
|
|
12948
|
+
*/
|
|
12949
|
+
declare function createTheme(input?: Partial<DesignTokens>, options?: GenerateCSSVariablesOptions): string;
|
|
12950
|
+
|
|
12951
|
+
/**
|
|
12952
|
+
* Theme Composition Utilities
|
|
12953
|
+
*
|
|
12954
|
+
* Simplified utilities for composing and merging DesignTokens.
|
|
12955
|
+
*/
|
|
12956
|
+
/**
|
|
12957
|
+
* Deep merge multiple objects
|
|
12958
|
+
* Later objects override earlier ones
|
|
12959
|
+
*/
|
|
12960
|
+
declare function deepMerge<T extends Record<string, unknown>>(...objects: Partial<T>[]): T;
|
|
12961
|
+
|
|
12962
|
+
/**
|
|
12963
|
+
* Merge multiple DesignTokens objects into a single DesignTokens object
|
|
12964
|
+
*
|
|
12965
|
+
* @param tokens - DesignTokens objects to merge
|
|
12966
|
+
* @returns Merged DesignTokens object
|
|
12967
|
+
*
|
|
12968
|
+
* @example
|
|
12969
|
+
* ```typescript
|
|
12970
|
+
* const baseTokens = { 'primary': '#000', 'spacing-4': '1rem' };
|
|
12971
|
+
* const customTokens = { 'secondary': '#fff', 'spacing-4': '1.5rem' };
|
|
12972
|
+
* const merged = mergeTheme(baseTokens, customTokens);
|
|
12973
|
+
* // Returns: { 'primary': '#000', 'secondary': '#fff', 'spacing-4': '1.5rem' }
|
|
12974
|
+
* ```
|
|
12975
|
+
*/
|
|
12976
|
+
declare function mergeTheme(...tokens: Partial<DesignTokens>[]): Partial<DesignTokens>;
|
|
12977
|
+
/**
|
|
12978
|
+
* Extend DesignTokens with additional tokens
|
|
12979
|
+
*
|
|
12980
|
+
* @param baseTokens - Base DesignTokens to extend
|
|
12981
|
+
* @param extension - Additional DesignTokens to merge
|
|
12982
|
+
* @returns Extended DesignTokens object
|
|
12983
|
+
*
|
|
12984
|
+
* @example
|
|
12985
|
+
* ```typescript
|
|
12986
|
+
* const base = { 'primary': '#000' };
|
|
12987
|
+
* const extended = extendTheme(base, { 'secondary': '#fff' });
|
|
12988
|
+
* // Returns: { 'primary': '#000', 'secondary': '#fff' }
|
|
12989
|
+
* ```
|
|
12990
|
+
*/
|
|
12991
|
+
declare function extendTheme(baseTokens: Partial<DesignTokens>, extension: Partial<DesignTokens>): Partial<DesignTokens>;
|
|
12992
|
+
|
|
12993
|
+
/**
|
|
12994
|
+
* Theme Metadata interface
|
|
12995
|
+
*/
|
|
12996
|
+
interface ThemeMetadata$1 {
|
|
12997
|
+
name: string;
|
|
12998
|
+
class: string;
|
|
12999
|
+
description?: string;
|
|
13000
|
+
version?: string;
|
|
13001
|
+
[key: string]: any;
|
|
13002
|
+
}
|
|
13003
|
+
/**
|
|
13004
|
+
* Theme Registry type - a record of theme IDs to metadata
|
|
13005
|
+
*/
|
|
13006
|
+
type ThemeRegistry = Record<string, ThemeMetadata$1>;
|
|
13007
|
+
/**
|
|
13008
|
+
* Create a new theme registry
|
|
13009
|
+
*/
|
|
13010
|
+
declare function createThemeRegistry(): ThemeRegistry;
|
|
13011
|
+
/**
|
|
13012
|
+
* Register a theme
|
|
13013
|
+
* @param registry - Theme registry object
|
|
13014
|
+
* @param id - Theme identifier
|
|
13015
|
+
* @param metadata - Theme metadata
|
|
13016
|
+
*/
|
|
13017
|
+
declare function registerTheme(registry: ThemeRegistry, id: string, metadata: ThemeMetadata$1): void;
|
|
13018
|
+
/**
|
|
13019
|
+
* Unregister a theme
|
|
13020
|
+
* @param registry - Theme registry object
|
|
13021
|
+
* @param id - Theme identifier
|
|
13022
|
+
*/
|
|
13023
|
+
declare function unregisterTheme(registry: ThemeRegistry, id: string): boolean;
|
|
13024
|
+
/**
|
|
13025
|
+
* Check if a theme is registered
|
|
13026
|
+
* @param registry - Theme registry object
|
|
13027
|
+
* @param id - Theme identifier
|
|
13028
|
+
*/
|
|
13029
|
+
declare function hasTheme(registry: ThemeRegistry, id: string): boolean;
|
|
13030
|
+
/**
|
|
13031
|
+
* Get theme metadata
|
|
13032
|
+
* @param registry - Theme registry object
|
|
13033
|
+
* @param id - Theme identifier
|
|
13034
|
+
*/
|
|
13035
|
+
declare function getTheme(registry: ThemeRegistry, id: string): ThemeMetadata$1 | undefined;
|
|
13036
|
+
/**
|
|
13037
|
+
* Get all registered theme metadata
|
|
13038
|
+
* @param registry - Theme registry object
|
|
13039
|
+
*/
|
|
13040
|
+
declare function getAllThemes(registry: ThemeRegistry): ThemeMetadata$1[];
|
|
13041
|
+
/**
|
|
13042
|
+
* Get all registered theme IDs
|
|
13043
|
+
* @param registry - Theme registry object
|
|
13044
|
+
*/
|
|
13045
|
+
declare function getThemeIds(registry: ThemeRegistry): string[];
|
|
13046
|
+
/**
|
|
13047
|
+
* Clear all registered themes
|
|
13048
|
+
* @param registry - Theme registry object
|
|
13049
|
+
*/
|
|
13050
|
+
declare function clearThemes(registry: ThemeRegistry): void;
|
|
13051
|
+
/**
|
|
13052
|
+
* Get the number of registered themes
|
|
13053
|
+
* @param registry - Theme registry object
|
|
13054
|
+
*/
|
|
13055
|
+
declare function getThemeCount(registry: ThemeRegistry): number;
|
|
13056
|
+
|
|
13057
|
+
/**
|
|
13058
|
+
* Theme Manager Type Definitions
|
|
13059
|
+
*
|
|
13060
|
+
* TypeScript types and interfaces for the Atomix Design System theme management system.
|
|
13061
|
+
*/
|
|
13062
|
+
/**
|
|
13063
|
+
* Theme metadata interface matching themes.config.js structure
|
|
13064
|
+
*/
|
|
13065
|
+
interface ThemeMetadata {
|
|
13066
|
+
/** Display name of the theme */
|
|
13067
|
+
name: string;
|
|
13068
|
+
/** Unique identifier/class name for the theme */
|
|
13069
|
+
class?: string;
|
|
13070
|
+
/** Theme description */
|
|
13071
|
+
description?: string;
|
|
13072
|
+
/** Theme author */
|
|
13073
|
+
author?: string;
|
|
13074
|
+
/** Theme version (semver) */
|
|
13075
|
+
version?: string;
|
|
13076
|
+
/** Theme tags for categorization */
|
|
13077
|
+
tags?: string[];
|
|
13078
|
+
/** Whether the theme supports dark mode */
|
|
13079
|
+
supportsDarkMode?: boolean;
|
|
13080
|
+
/** Theme status: stable, beta, experimental, deprecated */
|
|
13081
|
+
status?: 'stable' | 'beta' | 'experimental' | 'deprecated';
|
|
13082
|
+
/** Accessibility information */
|
|
13083
|
+
a11y?: {
|
|
13084
|
+
/** Target contrast ratio */
|
|
13085
|
+
contrastTarget?: number;
|
|
13086
|
+
/** Supported color modes */
|
|
13087
|
+
modes?: string[];
|
|
13088
|
+
};
|
|
13089
|
+
/** Primary theme color (for UI display) */
|
|
13090
|
+
color?: string;
|
|
13091
|
+
/** Theme features list */
|
|
13092
|
+
features?: string[];
|
|
13093
|
+
/** Theme dependencies (other themes required) */
|
|
13094
|
+
dependencies?: string[];
|
|
13095
|
+
}
|
|
13096
|
+
/**
|
|
13097
|
+
* Theme change event payload
|
|
13098
|
+
*/
|
|
13099
|
+
interface ThemeChangeEvent {
|
|
13100
|
+
/** Previous theme name */
|
|
13101
|
+
previousTheme: string | null;
|
|
13102
|
+
/** New theme name */
|
|
13103
|
+
currentTheme: string;
|
|
13104
|
+
/** DesignTokens if using tokens-based theme */
|
|
13105
|
+
tokens?: DesignTokens | null;
|
|
13106
|
+
/** Timestamp of the change */
|
|
13107
|
+
timestamp: number;
|
|
13108
|
+
/** Whether the change was from user action or system */
|
|
13109
|
+
source: 'user' | 'system' | 'storage';
|
|
13110
|
+
}
|
|
13111
|
+
/**
|
|
13112
|
+
* Theme load options
|
|
13113
|
+
*/
|
|
13114
|
+
interface ThemeLoadOptions {
|
|
13115
|
+
/** Force reload even if already loaded */
|
|
13116
|
+
force?: boolean;
|
|
13117
|
+
/** Preload without applying */
|
|
13118
|
+
preload?: boolean;
|
|
13119
|
+
/** Remove previous theme CSS */
|
|
13120
|
+
removePrevious?: boolean;
|
|
13121
|
+
/** Custom CSS path override */
|
|
13122
|
+
customPath?: string;
|
|
13123
|
+
/** Fallback to default theme on error */
|
|
13124
|
+
fallbackOnError?: boolean;
|
|
13125
|
+
}
|
|
13126
|
+
/**
|
|
13127
|
+
* Theme validation result
|
|
13128
|
+
*/
|
|
13129
|
+
interface ThemeValidationResult {
|
|
13130
|
+
/** Whether the theme is valid */
|
|
13131
|
+
valid: boolean;
|
|
13132
|
+
/** Validation errors */
|
|
13133
|
+
errors: string[];
|
|
13134
|
+
/** Validation warnings */
|
|
13135
|
+
warnings: string[];
|
|
13136
|
+
}
|
|
13137
|
+
/**
|
|
13138
|
+
* React hook return type for useTheme
|
|
13139
|
+
*/
|
|
13140
|
+
interface UseThemeReturn {
|
|
13141
|
+
/** Current theme name */
|
|
13142
|
+
theme: string;
|
|
13143
|
+
/** Current active DesignTokens (if using tokens-based theme) */
|
|
13144
|
+
activeTokens: DesignTokens | null;
|
|
13145
|
+
/** Function to change theme (supports string or DesignTokens) */
|
|
13146
|
+
setTheme: (theme: string | DesignTokens | Partial<DesignTokens>, options?: ThemeLoadOptions) => Promise<void>;
|
|
13147
|
+
/** Available themes */
|
|
13148
|
+
availableThemes: ThemeMetadata[];
|
|
13149
|
+
/** Whether a theme is currently loading */
|
|
13150
|
+
isLoading: boolean;
|
|
13151
|
+
/** Current error, if any */
|
|
13152
|
+
error: Error | null;
|
|
13153
|
+
/** Whether a specific theme is loaded */
|
|
13154
|
+
isThemeLoaded: (themeName: string) => boolean;
|
|
13155
|
+
/** Preload a theme */
|
|
13156
|
+
preloadTheme: (themeName: string) => Promise<void>;
|
|
13157
|
+
}
|
|
13158
|
+
/**
|
|
13159
|
+
* Component-level theme override configuration
|
|
13160
|
+
*/
|
|
12712
13161
|
interface ComponentThemeOverride {
|
|
12713
13162
|
/** CSS variable overrides for the component */
|
|
12714
13163
|
cssVars?: Record<string, string | number>;
|
|
@@ -12762,10 +13211,10 @@ interface ThemeComponentOverrides {
|
|
|
12762
13211
|
interface ThemeProviderProps {
|
|
12763
13212
|
/** Child components */
|
|
12764
13213
|
children: React.ReactNode;
|
|
12765
|
-
/** Default theme */
|
|
12766
|
-
defaultTheme?: string |
|
|
13214
|
+
/** Default theme (string name or DesignTokens) */
|
|
13215
|
+
defaultTheme?: string | DesignTokens | Partial<DesignTokens>;
|
|
12767
13216
|
/** Available themes */
|
|
12768
|
-
themes?: Record<string, ThemeMetadata
|
|
13217
|
+
themes?: Record<string, ThemeMetadata>;
|
|
12769
13218
|
/** Base path for theme CSS */
|
|
12770
13219
|
basePath?: string;
|
|
12771
13220
|
/** CDN path for theme CSS */
|
|
@@ -12783,7 +13232,7 @@ interface ThemeProviderProps {
|
|
|
12783
13232
|
/** Use minified CSS */
|
|
12784
13233
|
useMinified?: boolean;
|
|
12785
13234
|
/** Callback when theme changes */
|
|
12786
|
-
onThemeChange?: (theme: string |
|
|
13235
|
+
onThemeChange?: (theme: string | DesignTokens) => void;
|
|
12787
13236
|
/** Callback on error */
|
|
12788
13237
|
onError?: (error: Error, themeName: string) => void;
|
|
12789
13238
|
}
|
|
@@ -12793,12 +13242,12 @@ interface ThemeProviderProps {
|
|
|
12793
13242
|
interface ThemeContextValue {
|
|
12794
13243
|
/** Current theme name */
|
|
12795
13244
|
theme: string;
|
|
12796
|
-
/** Current active
|
|
12797
|
-
|
|
12798
|
-
/** Set theme function (supports string
|
|
12799
|
-
setTheme: (theme: string |
|
|
13245
|
+
/** Current active DesignTokens (if using tokens-based theme) */
|
|
13246
|
+
activeTokens: DesignTokens | null;
|
|
13247
|
+
/** Set theme function (supports string or DesignTokens) */
|
|
13248
|
+
setTheme: (theme: string | DesignTokens | Partial<DesignTokens>, options?: ThemeLoadOptions) => Promise<void>;
|
|
12800
13249
|
/** Available themes */
|
|
12801
|
-
availableThemes: ThemeMetadata
|
|
13250
|
+
availableThemes: ThemeMetadata[];
|
|
12802
13251
|
/** Loading state */
|
|
12803
13252
|
isLoading: boolean;
|
|
12804
13253
|
/** Error state */
|
|
@@ -12821,36 +13270,6 @@ interface PaletteColor {
|
|
|
12821
13270
|
/** Contrast text color (auto-generated if not provided) */
|
|
12822
13271
|
contrastText?: string;
|
|
12823
13272
|
}
|
|
12824
|
-
/**
|
|
12825
|
-
* Palette configuration options for createTheme
|
|
12826
|
-
*/
|
|
12827
|
-
interface PaletteOptions {
|
|
12828
|
-
/** Primary color configuration */
|
|
12829
|
-
primary?: Partial<PaletteColor> | string;
|
|
12830
|
-
/** Secondary color configuration */
|
|
12831
|
-
secondary?: Partial<PaletteColor> | string;
|
|
12832
|
-
/** Error color configuration */
|
|
12833
|
-
error?: Partial<PaletteColor> | string;
|
|
12834
|
-
/** Warning color configuration */
|
|
12835
|
-
warning?: Partial<PaletteColor> | string;
|
|
12836
|
-
/** Info color configuration */
|
|
12837
|
-
info?: Partial<PaletteColor> | string;
|
|
12838
|
-
/** Success color configuration */
|
|
12839
|
-
success?: Partial<PaletteColor> | string;
|
|
12840
|
-
/** Background colors */
|
|
12841
|
-
background?: {
|
|
12842
|
-
default?: string;
|
|
12843
|
-
subtle?: string;
|
|
12844
|
-
};
|
|
12845
|
-
/** Text colors */
|
|
12846
|
-
text?: {
|
|
12847
|
-
primary?: string;
|
|
12848
|
-
secondary?: string;
|
|
12849
|
-
disabled?: string;
|
|
12850
|
-
};
|
|
12851
|
-
/** Additional custom colors */
|
|
12852
|
-
[key: string]: any;
|
|
12853
|
-
}
|
|
12854
13273
|
/**
|
|
12855
13274
|
* Typography configuration options for createTheme
|
|
12856
13275
|
*/
|
|
@@ -12920,10 +13339,6 @@ interface TypographyOptions {
|
|
|
12920
13339
|
* Spacing function type
|
|
12921
13340
|
*/
|
|
12922
13341
|
type SpacingFunction = (...values: number[]) => string;
|
|
12923
|
-
/**
|
|
12924
|
-
* Spacing configuration options for createTheme
|
|
12925
|
-
*/
|
|
12926
|
-
type SpacingOptions = number | number[] | SpacingFunction;
|
|
12927
13342
|
/**
|
|
12928
13343
|
* Breakpoint values configuration
|
|
12929
13344
|
*/
|
|
@@ -12935,15 +13350,6 @@ interface BreakpointValues {
|
|
|
12935
13350
|
xl?: number;
|
|
12936
13351
|
[key: string]: number | undefined;
|
|
12937
13352
|
}
|
|
12938
|
-
/**
|
|
12939
|
-
* Breakpoints configuration options for createTheme
|
|
12940
|
-
*/
|
|
12941
|
-
interface BreakpointsOptions {
|
|
12942
|
-
/** Breakpoint values in pixels */
|
|
12943
|
-
values?: BreakpointValues;
|
|
12944
|
-
/** Unit for breakpoints (default: 'px') */
|
|
12945
|
-
unit?: string;
|
|
12946
|
-
}
|
|
12947
13353
|
/**
|
|
12948
13354
|
* Shadow configuration
|
|
12949
13355
|
*/
|
|
@@ -13021,35 +13427,11 @@ interface BorderRadiusOptions {
|
|
|
13021
13427
|
interface ThemeCustomProperties {
|
|
13022
13428
|
[key: string]: any;
|
|
13023
13429
|
}
|
|
13024
|
-
/**
|
|
13025
|
-
* Theme configuration options for createTheme
|
|
13026
|
-
* Extends ThemeMetadata to support both CSS and JS theme properties
|
|
13027
|
-
*/
|
|
13028
|
-
interface ThemeOptions extends Partial<ThemeMetadata$1> {
|
|
13029
|
-
/** Color palette configuration */
|
|
13030
|
-
palette?: PaletteOptions;
|
|
13031
|
-
/** Typography configuration */
|
|
13032
|
-
typography?: TypographyOptions;
|
|
13033
|
-
/** Spacing configuration */
|
|
13034
|
-
spacing?: SpacingOptions;
|
|
13035
|
-
/** Breakpoints configuration */
|
|
13036
|
-
breakpoints?: BreakpointsOptions;
|
|
13037
|
-
/** Shadow configuration */
|
|
13038
|
-
shadows?: ShadowOptions;
|
|
13039
|
-
/** Transition configuration */
|
|
13040
|
-
transitions?: TransitionOptions;
|
|
13041
|
-
/** Z-index configuration */
|
|
13042
|
-
zIndex?: ZIndexOptions;
|
|
13043
|
-
/** Border radius configuration */
|
|
13044
|
-
borderRadius?: BorderRadiusOptions;
|
|
13045
|
-
/** Custom properties */
|
|
13046
|
-
custom?: ThemeCustomProperties;
|
|
13047
|
-
}
|
|
13048
13430
|
/**
|
|
13049
13431
|
* Complete theme object with computed values
|
|
13050
13432
|
* Generated by createTheme function
|
|
13051
13433
|
*/
|
|
13052
|
-
interface Theme extends ThemeMetadata
|
|
13434
|
+
interface Theme extends ThemeMetadata {
|
|
13053
13435
|
/** Color palette with computed values */
|
|
13054
13436
|
palette: {
|
|
13055
13437
|
primary: PaletteColor;
|
|
@@ -13115,241 +13497,6 @@ interface Theme extends ThemeMetadata$1 {
|
|
|
13115
13497
|
__isJSTheme: true;
|
|
13116
13498
|
}
|
|
13117
13499
|
|
|
13118
|
-
/**
|
|
13119
|
-
* CSS Variable Generator
|
|
13120
|
-
*
|
|
13121
|
-
* Generates CSS custom properties from design tokens.
|
|
13122
|
-
*/
|
|
13123
|
-
|
|
13124
|
-
/**
|
|
13125
|
-
* Options for CSS variable generation
|
|
13126
|
-
*/
|
|
13127
|
-
interface GenerateCSSVariablesOptions {
|
|
13128
|
-
/** CSS selector for the variables (default: ':root') */
|
|
13129
|
-
selector?: string;
|
|
13130
|
-
/** Prefix for CSS variables (default: 'atomix') */
|
|
13131
|
-
prefix?: string;
|
|
13132
|
-
}
|
|
13133
|
-
/**
|
|
13134
|
-
* Generate CSS variables from tokens
|
|
13135
|
-
*
|
|
13136
|
-
* Converts flat token object to CSS custom properties.
|
|
13137
|
-
*
|
|
13138
|
-
* @param tokens - Design tokens object
|
|
13139
|
-
* @param options - Generation options
|
|
13140
|
-
* @returns CSS string with custom properties
|
|
13141
|
-
*
|
|
13142
|
-
* @example
|
|
13143
|
-
* ```typescript
|
|
13144
|
-
* const tokens = {
|
|
13145
|
-
* 'primary': '#7c3aed',
|
|
13146
|
-
* 'spacing-4': '1rem',
|
|
13147
|
-
* };
|
|
13148
|
-
*
|
|
13149
|
-
* const css = generateCSSVariables(tokens);
|
|
13150
|
-
* // Returns: ":root {\n --atomix-primary: #7c3aed;\n --atomix-spacing-4: 1rem;\n}"
|
|
13151
|
-
* ```
|
|
13152
|
-
*/
|
|
13153
|
-
declare function generateCSSVariables(tokens: DesignTokens, options?: GenerateCSSVariablesOptions): string;
|
|
13154
|
-
/**
|
|
13155
|
-
* Generate CSS variables with custom selector
|
|
13156
|
-
*
|
|
13157
|
-
* Useful for theme-specific selectors like `[data-theme="dark"]`
|
|
13158
|
-
*
|
|
13159
|
-
* @param tokens - Design tokens object
|
|
13160
|
-
* @param selector - CSS selector (e.g., '[data-theme="dark"]')
|
|
13161
|
-
* @param prefix - CSS variable prefix
|
|
13162
|
-
* @returns CSS string
|
|
13163
|
-
*
|
|
13164
|
-
* @example
|
|
13165
|
-
* ```typescript
|
|
13166
|
-
* const css = generateCSSVariablesForSelector(
|
|
13167
|
-
* tokens,
|
|
13168
|
-
* '[data-theme="dark"]',
|
|
13169
|
-
* 'atomix'
|
|
13170
|
-
* );
|
|
13171
|
-
* ```
|
|
13172
|
-
*/
|
|
13173
|
-
declare function generateCSSVariablesForSelector(tokens: DesignTokens, selector: string, prefix?: string): string;
|
|
13174
|
-
|
|
13175
|
-
/**
|
|
13176
|
-
* Core Theme Functions
|
|
13177
|
-
*
|
|
13178
|
-
* Simplified theme system that handles both DesignTokens and Theme objects.
|
|
13179
|
-
* Config-first approach: loads from atomix.config.ts when no input is provided.
|
|
13180
|
-
* Config file is required for automatic loading.
|
|
13181
|
-
*/
|
|
13182
|
-
|
|
13183
|
-
/**
|
|
13184
|
-
* Create theme CSS from tokens or Theme object
|
|
13185
|
-
*
|
|
13186
|
-
* **Config-First Approach**: If no input is provided, loads from `atomix.config.ts`.
|
|
13187
|
-
* Config file is required for automatic loading.
|
|
13188
|
-
*
|
|
13189
|
-
* @param input - DesignTokens (partial), Theme object, or undefined (loads from config)
|
|
13190
|
-
* @param options - CSS generation options (prefix is automatically read from config if not provided)
|
|
13191
|
-
* @returns CSS string with custom properties
|
|
13192
|
-
* @throws Error if config loading fails when no input is provided
|
|
13193
|
-
*
|
|
13194
|
-
* @example
|
|
13195
|
-
* ```typescript
|
|
13196
|
-
* // Loads from atomix.config.ts (config file required)
|
|
13197
|
-
* const css = createTheme();
|
|
13198
|
-
*
|
|
13199
|
-
* // Using DesignTokens
|
|
13200
|
-
* const css = createTheme({
|
|
13201
|
-
* 'primary': '#7c3aed',
|
|
13202
|
-
* 'spacing-4': '1rem',
|
|
13203
|
-
* });
|
|
13204
|
-
*
|
|
13205
|
-
* // Using Theme object
|
|
13206
|
-
* const theme = createThemeObject({ palette: { primary: { main: '#7c3aed' } } });
|
|
13207
|
-
* const css = createTheme(theme);
|
|
13208
|
-
*
|
|
13209
|
-
* // With custom options
|
|
13210
|
-
* const css = createTheme(undefined, { prefix: 'myapp', selector: ':root' });
|
|
13211
|
-
* ```
|
|
13212
|
-
*/
|
|
13213
|
-
declare function createTheme(input?: Partial<DesignTokens> | Theme, options?: GenerateCSSVariablesOptions): string;
|
|
13214
|
-
|
|
13215
|
-
/**
|
|
13216
|
-
* createThemeObject - Create a theme object with computed values
|
|
13217
|
-
*
|
|
13218
|
-
* Similar to Material-UI's createTheme, this function accepts theme configuration
|
|
13219
|
-
* options and returns a complete theme object with computed values.
|
|
13220
|
-
*
|
|
13221
|
-
* NOTE: For most use cases, use the simple theme system's `createTheme` instead,
|
|
13222
|
-
* which generates CSS from DesignTokens. This function is for advanced use cases
|
|
13223
|
-
* that need the full Theme object structure.
|
|
13224
|
-
*
|
|
13225
|
-
* @example
|
|
13226
|
-
* ```typescript
|
|
13227
|
-
* const theme = createThemeObject({
|
|
13228
|
-
* palette: {
|
|
13229
|
-
* primary: { main: '#7AFFD7' },
|
|
13230
|
-
* secondary: { main: '#FF5733' },
|
|
13231
|
-
* },
|
|
13232
|
-
* typography: {
|
|
13233
|
-
* fontFamily: 'Inter, sans-serif',
|
|
13234
|
-
* },
|
|
13235
|
-
* });
|
|
13236
|
-
* ```
|
|
13237
|
-
*/
|
|
13238
|
-
|
|
13239
|
-
/**
|
|
13240
|
-
* Create a theme object with computed values
|
|
13241
|
-
*
|
|
13242
|
-
* @param options - Theme configuration options
|
|
13243
|
-
* @returns Complete theme object
|
|
13244
|
-
*/
|
|
13245
|
-
declare function createThemeObject(...options: ThemeOptions[]): Theme;
|
|
13246
|
-
|
|
13247
|
-
/**
|
|
13248
|
-
* Theme Composition Utilities
|
|
13249
|
-
*
|
|
13250
|
-
* Simplified utilities for composing, merging, and extending themes.
|
|
13251
|
-
*/
|
|
13252
|
-
|
|
13253
|
-
/**
|
|
13254
|
-
* Deep merge multiple objects
|
|
13255
|
-
* Later objects override earlier ones
|
|
13256
|
-
*/
|
|
13257
|
-
declare function deepMerge<T extends Record<string, unknown>>(...objects: Partial<T>[]): T;
|
|
13258
|
-
/**
|
|
13259
|
-
* Merge multiple theme options into a single theme options object
|
|
13260
|
-
*
|
|
13261
|
-
* @param themes - Theme options to merge
|
|
13262
|
-
* @returns Merged theme options
|
|
13263
|
-
*
|
|
13264
|
-
* @example
|
|
13265
|
-
* ```typescript
|
|
13266
|
-
* const baseTheme = { palette: { primary: { main: '#000' } } };
|
|
13267
|
-
* const customTheme = { palette: { secondary: { main: '#fff' } } };
|
|
13268
|
-
* const merged = mergeTheme(baseTheme, customTheme);
|
|
13269
|
-
* ```
|
|
13270
|
-
*/
|
|
13271
|
-
declare function mergeTheme(...themes: ThemeOptions[]): ThemeOptions;
|
|
13272
|
-
/**
|
|
13273
|
-
* Extend an existing theme with new options
|
|
13274
|
-
*
|
|
13275
|
-
* @param baseTheme - Base theme to extend (can be Theme or ThemeOptions)
|
|
13276
|
-
* @param extension - Theme options to extend with
|
|
13277
|
-
* @returns New theme with extended options
|
|
13278
|
-
*
|
|
13279
|
-
* @example
|
|
13280
|
-
* ```typescript
|
|
13281
|
-
* const base = createTheme({ palette: { primary: { main: '#000' } } });
|
|
13282
|
-
* const extended = extendTheme(base, {
|
|
13283
|
-
* palette: { secondary: { main: '#fff' } }
|
|
13284
|
-
* });
|
|
13285
|
-
* ```
|
|
13286
|
-
*/
|
|
13287
|
-
declare function extendTheme(baseTheme: Theme | ThemeOptions, extension: ThemeOptions): Theme;
|
|
13288
|
-
|
|
13289
|
-
/**
|
|
13290
|
-
* Theme Metadata interface
|
|
13291
|
-
*/
|
|
13292
|
-
interface ThemeMetadata {
|
|
13293
|
-
name: string;
|
|
13294
|
-
class: string;
|
|
13295
|
-
description?: string;
|
|
13296
|
-
version?: string;
|
|
13297
|
-
[key: string]: any;
|
|
13298
|
-
}
|
|
13299
|
-
/**
|
|
13300
|
-
* Theme Registry type - a record of theme IDs to metadata
|
|
13301
|
-
*/
|
|
13302
|
-
type ThemeRegistry = Record<string, ThemeMetadata>;
|
|
13303
|
-
/**
|
|
13304
|
-
* Create a new theme registry
|
|
13305
|
-
*/
|
|
13306
|
-
declare function createThemeRegistry(): ThemeRegistry;
|
|
13307
|
-
/**
|
|
13308
|
-
* Register a theme
|
|
13309
|
-
* @param registry - Theme registry object
|
|
13310
|
-
* @param id - Theme identifier
|
|
13311
|
-
* @param metadata - Theme metadata
|
|
13312
|
-
*/
|
|
13313
|
-
declare function registerTheme(registry: ThemeRegistry, id: string, metadata: ThemeMetadata): void;
|
|
13314
|
-
/**
|
|
13315
|
-
* Unregister a theme
|
|
13316
|
-
* @param registry - Theme registry object
|
|
13317
|
-
* @param id - Theme identifier
|
|
13318
|
-
*/
|
|
13319
|
-
declare function unregisterTheme(registry: ThemeRegistry, id: string): boolean;
|
|
13320
|
-
/**
|
|
13321
|
-
* Check if a theme is registered
|
|
13322
|
-
* @param registry - Theme registry object
|
|
13323
|
-
* @param id - Theme identifier
|
|
13324
|
-
*/
|
|
13325
|
-
declare function hasTheme(registry: ThemeRegistry, id: string): boolean;
|
|
13326
|
-
/**
|
|
13327
|
-
* Get theme metadata
|
|
13328
|
-
* @param registry - Theme registry object
|
|
13329
|
-
* @param id - Theme identifier
|
|
13330
|
-
*/
|
|
13331
|
-
declare function getTheme(registry: ThemeRegistry, id: string): ThemeMetadata | undefined;
|
|
13332
|
-
/**
|
|
13333
|
-
* Get all registered theme metadata
|
|
13334
|
-
* @param registry - Theme registry object
|
|
13335
|
-
*/
|
|
13336
|
-
declare function getAllThemes(registry: ThemeRegistry): ThemeMetadata[];
|
|
13337
|
-
/**
|
|
13338
|
-
* Get all registered theme IDs
|
|
13339
|
-
* @param registry - Theme registry object
|
|
13340
|
-
*/
|
|
13341
|
-
declare function getThemeIds(registry: ThemeRegistry): string[];
|
|
13342
|
-
/**
|
|
13343
|
-
* Clear all registered themes
|
|
13344
|
-
* @param registry - Theme registry object
|
|
13345
|
-
*/
|
|
13346
|
-
declare function clearThemes(registry: ThemeRegistry): void;
|
|
13347
|
-
/**
|
|
13348
|
-
* Get the number of registered themes
|
|
13349
|
-
* @param registry - Theme registry object
|
|
13350
|
-
*/
|
|
13351
|
-
declare function getThemeCount(registry: ThemeRegistry): number;
|
|
13352
|
-
|
|
13353
13500
|
/**
|
|
13354
13501
|
* Naming Utilities
|
|
13355
13502
|
*
|
|
@@ -13386,13 +13533,14 @@ declare function themePropertyToCSSVar(propertyPath: string, prefix?: string): s
|
|
|
13386
13533
|
* Component Theming Utilities
|
|
13387
13534
|
*
|
|
13388
13535
|
* Provides consistent patterns for applying theme values to components
|
|
13536
|
+
* using DesignTokens and CSS variables
|
|
13389
13537
|
*/
|
|
13390
13538
|
|
|
13391
13539
|
interface ComponentThemeOptions {
|
|
13392
13540
|
component: string;
|
|
13393
13541
|
variant?: string;
|
|
13394
13542
|
size?: string;
|
|
13395
|
-
|
|
13543
|
+
tokens?: Partial<DesignTokens>;
|
|
13396
13544
|
}
|
|
13397
13545
|
/**
|
|
13398
13546
|
* Get a theme value for a specific component using CSS variables
|
|
@@ -13400,17 +13548,17 @@ interface ComponentThemeOptions {
|
|
|
13400
13548
|
*/
|
|
13401
13549
|
declare function getComponentThemeValue(component: string, property: string, variant?: string, size?: string): string;
|
|
13402
13550
|
/**
|
|
13403
|
-
* Generate component-specific CSS variables from
|
|
13551
|
+
* Generate component-specific CSS variables from DesignTokens
|
|
13404
13552
|
*/
|
|
13405
|
-
declare function generateComponentCSSVars(component: string,
|
|
13553
|
+
declare function generateComponentCSSVars(component: string, tokens?: Partial<DesignTokens>, variant?: string, size?: string): Record<string, string>;
|
|
13406
13554
|
/**
|
|
13407
|
-
* Apply consistent theme to component style object
|
|
13555
|
+
* Apply consistent theme to component style object using DesignTokens
|
|
13408
13556
|
*/
|
|
13409
|
-
declare function applyComponentTheme(component: string, style?: React.CSSProperties, variant?: string, size?: string,
|
|
13557
|
+
declare function applyComponentTheme(component: string, style?: React.CSSProperties, variant?: string, size?: string, tokens?: Partial<DesignTokens>): React.CSSProperties;
|
|
13410
13558
|
/**
|
|
13411
13559
|
* Create a hook for consistent component theming
|
|
13412
13560
|
*/
|
|
13413
|
-
declare function useComponentTheme(component: string, variant?: string, size?: string,
|
|
13561
|
+
declare function useComponentTheme(component: string, variant?: string, size?: string, tokens?: Partial<DesignTokens>): (property: string) => string;
|
|
13414
13562
|
|
|
13415
13563
|
/**
|
|
13416
13564
|
* CSS Injection Utilities
|
|
@@ -13498,7 +13646,7 @@ declare function loadThemeFromConfig(options?: {
|
|
|
13498
13646
|
* React context provider for theme management with separated concerns.
|
|
13499
13647
|
* Simplified version focusing on core functionality:
|
|
13500
13648
|
* - String-based themes (CSS files)
|
|
13501
|
-
* -
|
|
13649
|
+
* - DesignTokens (dynamic themes)
|
|
13502
13650
|
* - Persistence via localStorage
|
|
13503
13651
|
*
|
|
13504
13652
|
* Falls back to 'default' theme if no configuration is found.
|
|
@@ -13537,14 +13685,13 @@ declare function useTheme(): UseThemeReturn;
|
|
|
13537
13685
|
/**
|
|
13538
13686
|
* Standardized hook for accessing theme tokens in components
|
|
13539
13687
|
*
|
|
13540
|
-
* Provides consistent access to theme values
|
|
13541
|
-
*
|
|
13688
|
+
* Provides consistent access to theme values using CSS custom properties
|
|
13689
|
+
* and DesignTokens.
|
|
13542
13690
|
*/
|
|
13543
13691
|
type ThemeTokens$1 = {
|
|
13544
13692
|
theme: string;
|
|
13545
|
-
|
|
13693
|
+
activeTokens: DesignTokens | null;
|
|
13546
13694
|
getToken: (tokenName: string, fallback?: string) => string;
|
|
13547
|
-
getThemeValue: (path: string, fallback?: any) => any;
|
|
13548
13695
|
colors: {
|
|
13549
13696
|
primary: string;
|
|
13550
13697
|
secondary: string;
|
|
@@ -13639,35 +13786,16 @@ declare class ThemeApplicator {
|
|
|
13639
13786
|
private styleId;
|
|
13640
13787
|
constructor(root?: HTMLElement);
|
|
13641
13788
|
/**
|
|
13642
|
-
* Apply a complete theme configuration
|
|
13789
|
+
* Apply a complete theme configuration using DesignTokens
|
|
13643
13790
|
*
|
|
13644
|
-
* Uses the unified theme system to
|
|
13791
|
+
* Uses the unified theme system to generate and inject CSS.
|
|
13645
13792
|
* Automatically respects atomix.config.ts when using DesignTokens.
|
|
13646
13793
|
*/
|
|
13647
|
-
applyTheme(
|
|
13794
|
+
applyTheme(tokens: Partial<DesignTokens>): void;
|
|
13648
13795
|
/**
|
|
13649
|
-
* Apply
|
|
13650
|
-
*
|
|
13651
|
-
* Uses createTheme() which automatically loads from atomix.config.ts
|
|
13652
|
-
* if no tokens are provided, ensuring config is always respected.
|
|
13653
|
-
*/
|
|
13654
|
-
private applyDesignTokens;
|
|
13655
|
-
/**
|
|
13656
|
-
* Check if object is DesignTokens
|
|
13657
|
-
*/
|
|
13658
|
-
private isDesignTokens;
|
|
13659
|
-
/**
|
|
13660
|
-
* Apply global CSS variables (for component overrides)
|
|
13796
|
+
* Apply global CSS variables
|
|
13661
13797
|
*/
|
|
13662
13798
|
private applyGlobalCSSVars;
|
|
13663
|
-
/**
|
|
13664
|
-
* Apply component-level overrides
|
|
13665
|
-
*/
|
|
13666
|
-
private applyComponentOverrides;
|
|
13667
|
-
/**
|
|
13668
|
-
* Apply override for a specific component
|
|
13669
|
-
*/
|
|
13670
|
-
private applyComponentOverride;
|
|
13671
13799
|
/**
|
|
13672
13800
|
* Clear all applied CSS variables
|
|
13673
13801
|
*/
|
|
@@ -13688,7 +13816,7 @@ declare function getThemeApplicator(): ThemeApplicator;
|
|
|
13688
13816
|
/**
|
|
13689
13817
|
* Apply theme using global applicator
|
|
13690
13818
|
*/
|
|
13691
|
-
declare function applyTheme(
|
|
13819
|
+
declare function applyTheme(tokens: Partial<DesignTokens>): void;
|
|
13692
13820
|
|
|
13693
13821
|
/**
|
|
13694
13822
|
* Theme Preview Component
|
|
@@ -13857,7 +13985,7 @@ declare class ThemeValidator {
|
|
|
13857
13985
|
/**
|
|
13858
13986
|
* Validate theme
|
|
13859
13987
|
*/
|
|
13860
|
-
validate(theme: Theme, metadata?: ThemeMetadata
|
|
13988
|
+
validate(theme: Theme, metadata?: ThemeMetadata): ValidationResult;
|
|
13861
13989
|
/**
|
|
13862
13990
|
* Validate palette
|
|
13863
13991
|
*/
|
|
@@ -13953,22 +14081,6 @@ declare function useHistory<T>(options?: UseHistoryOptions): UseHistoryReturn<T>
|
|
|
13953
14081
|
* Converts between Theme objects and DesignTokens.
|
|
13954
14082
|
*/
|
|
13955
14083
|
|
|
13956
|
-
/**
|
|
13957
|
-
* Convert Theme object to DesignTokens
|
|
13958
|
-
*
|
|
13959
|
-
* Extracts values from a Theme object and converts them to flat DesignTokens format.
|
|
13960
|
-
*
|
|
13961
|
-
* @param theme - Theme object to convert
|
|
13962
|
-
* @returns Partial DesignTokens object
|
|
13963
|
-
*
|
|
13964
|
-
* @example
|
|
13965
|
-
* ```typescript
|
|
13966
|
-
* const theme = createTheme({ palette: { primary: { main: '#7c3aed' } } });
|
|
13967
|
-
* const tokens = themeToDesignTokens(theme);
|
|
13968
|
-
* // Returns: { 'primary': '#7c3aed', ... }
|
|
13969
|
-
* ```
|
|
13970
|
-
*/
|
|
13971
|
-
declare function themeToDesignTokens(theme: Theme): Partial<DesignTokens>;
|
|
13972
14084
|
/**
|
|
13973
14085
|
* Convert DesignTokens to Theme-compatible CSS variables
|
|
13974
14086
|
*
|
|
@@ -13976,22 +14088,6 @@ declare function themeToDesignTokens(theme: Theme): Partial<DesignTokens>;
|
|
|
13976
14088
|
* @returns CSS variables object compatible with Theme.cssVars
|
|
13977
14089
|
*/
|
|
13978
14090
|
declare function designTokensToCSSVars(tokens: Partial<DesignTokens>): Record<string, string>;
|
|
13979
|
-
/**
|
|
13980
|
-
* Create DesignTokens from Theme with defaults
|
|
13981
|
-
*
|
|
13982
|
-
* Converts a Theme to DesignTokens and merges with default tokens.
|
|
13983
|
-
*
|
|
13984
|
-
* @param theme - Theme object to convert
|
|
13985
|
-
* @returns Complete DesignTokens object
|
|
13986
|
-
*/
|
|
13987
|
-
declare function createDesignTokensFromTheme(theme: Theme): DesignTokens;
|
|
13988
|
-
/**
|
|
13989
|
-
* Create a minimal Theme object from DesignTokens
|
|
13990
|
-
*
|
|
13991
|
-
* @param tokens - DesignTokens to convert
|
|
13992
|
-
* @returns Minimal Theme object with cssVars populated
|
|
13993
|
-
*/
|
|
13994
|
-
declare function designTokensToTheme(tokens: Partial<DesignTokens>): Partial<Theme>;
|
|
13995
14091
|
|
|
13996
14092
|
/**
|
|
13997
14093
|
* CSS Variable Mapper
|
|
@@ -14037,8 +14133,8 @@ declare function mapSCSSTokensToCSSVars(tokens: Record<string, any>, options?: C
|
|
|
14037
14133
|
/**
|
|
14038
14134
|
* Apply CSS variables to an element
|
|
14039
14135
|
*
|
|
14040
|
-
* @param element - Target element (defaults to document.documentElement)
|
|
14041
14136
|
* @param vars - CSS variables to apply
|
|
14137
|
+
* @param element - Target element (defaults to document.documentElement)
|
|
14042
14138
|
*/
|
|
14043
14139
|
declare function applyCSSVariables(vars: Record<string, string | number>, element?: HTMLElement): void;
|
|
14044
14140
|
/**
|
|
@@ -14086,27 +14182,9 @@ declare function extractComponentName(varName: string, prefix?: string): string
|
|
|
14086
14182
|
/**
|
|
14087
14183
|
* Theme Helper Functions
|
|
14088
14184
|
*
|
|
14089
|
-
* Utility functions for working with
|
|
14185
|
+
* Utility functions for working with DesignTokens
|
|
14090
14186
|
*/
|
|
14091
14187
|
|
|
14092
|
-
/**
|
|
14093
|
-
* Get DesignTokens from current theme
|
|
14094
|
-
*
|
|
14095
|
-
* Converts a Theme object to DesignTokens. Useful when you need to
|
|
14096
|
-
* work with DesignTokens but have a Theme object.
|
|
14097
|
-
*
|
|
14098
|
-
* @param theme - Theme object to convert
|
|
14099
|
-
* @returns DesignTokens object
|
|
14100
|
-
*
|
|
14101
|
-
* @example
|
|
14102
|
-
* ```typescript
|
|
14103
|
-
* // If you have a Theme object, convert it to DesignTokens
|
|
14104
|
-
* const tokens = getDesignTokensFromTheme(theme);
|
|
14105
|
-
* // Now you can use tokens with unified theme system
|
|
14106
|
-
* const css = createTheme(tokens);
|
|
14107
|
-
* ```
|
|
14108
|
-
*/
|
|
14109
|
-
declare function getDesignTokensFromTheme(theme: Theme | null): DesignTokens | null;
|
|
14110
14188
|
/**
|
|
14111
14189
|
* Check if a value is DesignTokens
|
|
14112
14190
|
*
|
|
@@ -14116,15 +14194,6 @@ declare function getDesignTokensFromTheme(theme: Theme | null): DesignTokens | n
|
|
|
14116
14194
|
* @returns True if value is DesignTokens
|
|
14117
14195
|
*/
|
|
14118
14196
|
declare function isDesignTokens(value: unknown): value is DesignTokens;
|
|
14119
|
-
/**
|
|
14120
|
-
* Check if a value is a Theme object
|
|
14121
|
-
*
|
|
14122
|
-
* Type guard to check if an object is a Theme.
|
|
14123
|
-
*
|
|
14124
|
-
* @param value - Value to check
|
|
14125
|
-
* @returns True if value is Theme
|
|
14126
|
-
*/
|
|
14127
|
-
declare function isThemeObject(value: unknown): value is Theme;
|
|
14128
14197
|
|
|
14129
14198
|
/**
|
|
14130
14199
|
* RTL (Right-to-Left) Support Utilities
|
|
@@ -14228,13 +14297,13 @@ declare class RTLManager {
|
|
|
14228
14297
|
/**
|
|
14229
14298
|
* Theme System Exports
|
|
14230
14299
|
*
|
|
14231
|
-
*
|
|
14300
|
+
* Simplified theme system using DesignTokens only.
|
|
14232
14301
|
*
|
|
14233
14302
|
* @example
|
|
14234
14303
|
* ```typescript
|
|
14235
14304
|
* import { createTheme, injectTheme } from '@shohojdhara/atomix/theme';
|
|
14236
14305
|
*
|
|
14237
|
-
* // Using DesignTokens
|
|
14306
|
+
* // Using DesignTokens
|
|
14238
14307
|
* const css = createTheme({ 'primary': '#7AFFD7', 'spacing-4': '1rem' });
|
|
14239
14308
|
* injectTheme(css);
|
|
14240
14309
|
*
|
|
@@ -14302,16 +14371,13 @@ declare const themeImport_applyComponentTheme: typeof applyComponentTheme;
|
|
|
14302
14371
|
declare const themeImport_applyTheme: typeof applyTheme;
|
|
14303
14372
|
declare const themeImport_camelToKebab: typeof camelToKebab;
|
|
14304
14373
|
declare const themeImport_clearThemes: typeof clearThemes;
|
|
14305
|
-
declare const themeImport_createDesignTokensFromTheme: typeof createDesignTokensFromTheme;
|
|
14306
14374
|
declare const themeImport_createTheme: typeof createTheme;
|
|
14307
|
-
declare const themeImport_createThemeObject: typeof createThemeObject;
|
|
14308
14375
|
declare const themeImport_createThemeRegistry: typeof createThemeRegistry;
|
|
14309
14376
|
declare const themeImport_createTokens: typeof createTokens;
|
|
14310
14377
|
declare const themeImport_cssVarsToStyle: typeof cssVarsToStyle;
|
|
14311
14378
|
declare const themeImport_deepMerge: typeof deepMerge;
|
|
14312
14379
|
declare const themeImport_defaultTokens: typeof defaultTokens;
|
|
14313
14380
|
declare const themeImport_designTokensToCSSVars: typeof designTokensToCSSVars;
|
|
14314
|
-
declare const themeImport_designTokensToTheme: typeof designTokensToTheme;
|
|
14315
14381
|
declare const themeImport_extendTheme: typeof extendTheme;
|
|
14316
14382
|
declare const themeImport_extractComponentName: typeof extractComponentName;
|
|
14317
14383
|
declare const themeImport_generateCSSVariableName: typeof generateCSSVariableName;
|
|
@@ -14322,7 +14388,6 @@ declare const themeImport_generateComponentCSSVars: typeof generateComponentCSSV
|
|
|
14322
14388
|
declare const themeImport_getAllThemes: typeof getAllThemes;
|
|
14323
14389
|
declare const themeImport_getCSSVariable: typeof getCSSVariable;
|
|
14324
14390
|
declare const themeImport_getComponentThemeValue: typeof getComponentThemeValue;
|
|
14325
|
-
declare const themeImport_getDesignTokensFromTheme: typeof getDesignTokensFromTheme;
|
|
14326
14391
|
declare const themeImport_getTheme: typeof getTheme;
|
|
14327
14392
|
declare const themeImport_getThemeApplicator: typeof getThemeApplicator;
|
|
14328
14393
|
declare const themeImport_getThemeCount: typeof getThemeCount;
|
|
@@ -14332,7 +14397,6 @@ declare const themeImport_injectCSS: typeof injectCSS;
|
|
|
14332
14397
|
declare const themeImport_injectTheme: typeof injectTheme;
|
|
14333
14398
|
declare const themeImport_isCSSInjected: typeof isCSSInjected;
|
|
14334
14399
|
declare const themeImport_isDesignTokens: typeof isDesignTokens;
|
|
14335
|
-
declare const themeImport_isThemeObject: typeof isThemeObject;
|
|
14336
14400
|
declare const themeImport_isValidCSSVariableName: typeof isValidCSSVariableName;
|
|
14337
14401
|
declare const themeImport_loadThemeFromConfig: typeof loadThemeFromConfig;
|
|
14338
14402
|
declare const themeImport_loadThemeFromConfigSync: typeof loadThemeFromConfigSync;
|
|
@@ -14346,14 +14410,13 @@ declare const themeImport_removeCSSVariables: typeof removeCSSVariables;
|
|
|
14346
14410
|
declare const themeImport_removeTheme: typeof removeTheme;
|
|
14347
14411
|
declare const themeImport_saveTheme: typeof saveTheme;
|
|
14348
14412
|
declare const themeImport_themePropertyToCSSVar: typeof themePropertyToCSSVar;
|
|
14349
|
-
declare const themeImport_themeToDesignTokens: typeof themeToDesignTokens;
|
|
14350
14413
|
declare const themeImport_unregisterTheme: typeof unregisterTheme;
|
|
14351
14414
|
declare const themeImport_useComponentTheme: typeof useComponentTheme;
|
|
14352
14415
|
declare const themeImport_useHistory: typeof useHistory;
|
|
14353
14416
|
declare const themeImport_useTheme: typeof useTheme;
|
|
14354
14417
|
declare const themeImport_useThemeTokens: typeof useThemeTokens;
|
|
14355
14418
|
declare namespace themeImport {
|
|
14356
|
-
export { themeImport_RTLManager as RTLManager, themeImport_ThemeApplicator as ThemeApplicator, themeImport_ThemeComparator as ThemeComparator, themeImport_ThemeContext as ThemeContext, themeImport_ThemeErrorBoundary as ThemeErrorBoundary, themeImport_ThemeInspector as ThemeInspector, themeImport_ThemeLiveEditor as ThemeLiveEditor, themeImport_ThemePreview as ThemePreview, themeImport_ThemeProvider as ThemeProvider, themeImport_ThemeValidator as ThemeValidator, themeImport_applyCSSVariables as applyCSSVariables, themeImport_applyComponentTheme as applyComponentTheme, themeImport_applyTheme as applyTheme, themeImport_camelToKebab as camelToKebab, themeImport_clearThemes as clearThemes,
|
|
14419
|
+
export { themeImport_RTLManager as RTLManager, themeImport_ThemeApplicator as ThemeApplicator, themeImport_ThemeComparator as ThemeComparator, themeImport_ThemeContext as ThemeContext, themeImport_ThemeErrorBoundary as ThemeErrorBoundary, themeImport_ThemeInspector as ThemeInspector, themeImport_ThemeLiveEditor as ThemeLiveEditor, themeImport_ThemePreview as ThemePreview, themeImport_ThemeProvider as ThemeProvider, themeImport_ThemeValidator as ThemeValidator, themeImport_applyCSSVariables as applyCSSVariables, themeImport_applyComponentTheme as applyComponentTheme, themeImport_applyTheme as applyTheme, themeImport_camelToKebab as camelToKebab, themeImport_clearThemes as clearThemes, themeImport_createTheme as createTheme, themeImport_createThemeRegistry as createThemeRegistry, themeImport_createTokens as createTokens, themeImport_cssVarsToStyle as cssVarsToStyle, themeImport_deepMerge as deepMerge, themeImport_defaultTokens as defaultTokens, themeImport_designTokensToCSSVars as designTokensToCSSVars, themeImport_extendTheme as extendTheme, themeImport_extractComponentName as extractComponentName, themeImport_generateCSSVariableName as generateCSSVariableName, themeImport_generateCSSVariables as generateCSSVariables, themeImport_generateCSSVariablesForSelector as generateCSSVariablesForSelector, themeImport_generateClassName as generateClassName, themeImport_generateComponentCSSVars as generateComponentCSSVars, themeImport_getAllThemes as getAllThemes, themeImport_getCSSVariable as getCSSVariable, themeImport_getComponentThemeValue as getComponentThemeValue, themeImport_getTheme as getTheme, themeImport_getThemeApplicator as getThemeApplicator, themeImport_getThemeCount as getThemeCount, themeImport_getThemeIds as getThemeIds, themeImport_hasTheme as hasTheme, themeImport_injectCSS as injectCSS, themeImport_injectTheme as injectTheme, themeImport_isCSSInjected as isCSSInjected, themeImport_isDesignTokens as isDesignTokens, themeImport_isValidCSSVariableName as isValidCSSVariableName, themeImport_loadThemeFromConfig as loadThemeFromConfig, themeImport_loadThemeFromConfigSync as loadThemeFromConfigSync, themeImport_mapSCSSTokensToCSSVars as mapSCSSTokensToCSSVars, themeImport_mergeCSSVars as mergeCSSVars, themeImport_mergeTheme as mergeTheme, themeImport_normalizeThemeTokens as normalizeThemeTokens, themeImport_registerTheme as registerTheme, themeImport_removeCSS as removeCSS, themeImport_removeCSSVariables as removeCSSVariables, themeImport_removeTheme as removeTheme, themeImport_saveTheme as saveTheme, themeImport_themePropertyToCSSVar as themePropertyToCSSVar, themeImport_unregisterTheme as unregisterTheme, themeImport_useComponentTheme as useComponentTheme, themeImport_useHistory as useHistory, themeImport_useTheme as useTheme, themeImport_useThemeTokens as useThemeTokens };
|
|
14357
14420
|
export type { themeImport_A11yIssue as A11yIssue, themeImport_CSSVariableConfig as CSSVariableConfig, themeImport_CSSVariableNamingOptions as CSSVariableNamingOptions, themeImport_ComponentThemeOptions as ComponentThemeOptions, themeImport_ComponentThemeOverride as ComponentThemeOverride, themeImport_DesignTokens as DesignTokens, themeImport_GenerateCSSVariablesOptions as GenerateCSSVariablesOptions, themeImport_NamingOptions as NamingOptions, themeImport_RTLConfig as RTLConfig, themeImport_Theme as Theme, themeImport_ThemeChangeEvent as ThemeChangeEvent, themeImport_ThemeComparatorProps as ThemeComparatorProps, themeImport_ThemeComponentOverrides as ThemeComponentOverrides, themeImport_ThemeContextValue as ThemeContextValue, themeImport_ThemeErrorBoundaryProps as ThemeErrorBoundaryProps, themeImport_ThemeInspectorProps as ThemeInspectorProps, themeImport_ThemeLiveEditorProps as ThemeLiveEditorProps, themeImport_ThemeLoadOptions as ThemeLoadOptions, themeImport_ThemePreviewProps as ThemePreviewProps, themeImport_ThemeProviderProps as ThemeProviderProps, themeImport_ThemeValidationResult as ThemeValidationResult, themeImport_UseHistoryOptions as UseHistoryOptions, themeImport_UseHistoryReturn as UseHistoryReturn, themeImport_UseThemeReturn as UseThemeReturn, themeImport_ValidationResult as ValidationResult };
|
|
14358
14421
|
}
|
|
14359
14422
|
|
|
@@ -15109,5 +15172,5 @@ declare const atomix: {
|
|
|
15109
15172
|
VideoPlayer: React$1.ForwardRefExoticComponent<VideoPlayerProps & React$1.RefAttributes<HTMLVideoElement>>;
|
|
15110
15173
|
};
|
|
15111
15174
|
|
|
15112
|
-
export { ACCORDION, ATOMIX_GLASS, AVATAR, AVATAR_GROUP, Accordion, AnimatedChart, AreaChart, AtomixGlass, AtomixLogo, Avatar, AvatarGroup, BADGE, BADGE_CSS_VARS, BLOCK, BREADCRUMB, BUTTON, BUTTON_CSS_VARS, BUTTON_GROUP, Badge, BarChart, Block, Breadcrumb, BubbleChart, Button, ButtonGroup, CALLOUT, CARD, CARD_CSS_VARS, CHART, CHECKBOX_CSS_VARS, CLASS_PREFIX, CODE_SNIPPET, COMPONENT_CSS_VARS, COUNTDOWN, Callout, CandlestickChart, Card, Chart, ChartRenderer, Checkbox, ColorModeToggle, Container, Countdown, DATA_TABLE_CLASSES, DATA_TABLE_SELECTORS, DATEPICKER, DEFAULT_ATOMIX_FONTS, DOTS, DROPDOWN, DROPDOWN_CSS_VARS, DataTable, DatePicker, DonutChart, Dropdown, EDGE_PANEL, EdgePanel, ElevationCard, FOOTER, FORM, FORM_GROUP, Footer, FooterLink, FooterSection, FooterSocialLink, Form, FormGroup, FunnelChart, GLASS_CONTAINER, GaugeChart, Grid, GridCol, HERO, HeatmapChart, Hero, INPUT, INPUT_CSS_VARS, Icon, Input, LIST, LIST_GROUP, LineChart, List, ListGroup, MESSAGES, MODAL, MODAL_CSS_VARS, MasonryGrid, MasonryGridItem, MegaMenu, MegaMenuColumn, MegaMenuLink, Menu, MenuDivider, MenuItem, Messages, Modal, MultiAxisChart, NAV, NAVBAR, Nav, NavDropdown, NavItem, Navbar, PAGINATION_DEFAULTS, PHOTOVIEWER, POPOVER, PROGRESS, PROGRESS_CSS_VARS, Pagination, PhotoViewer, PieChart, Popover, ProductReview, Progress, RADIO, RADIO_CSS_VARS, RATING, RIVER, RTLManager, RadarChart, Radio, Rating, River, Row, SECTION_INTRO, SELECT, SIDE_MENU, SIZES, SLIDER, SPINNER, STEPS, ScatterChart, SectionIntro, Select, SideMenu, SideMenuItem, SideMenuList, Slider, Spinner, Steps, TAB, TABS_CSS_VARS, TESTIMONIAL, TEXTAREA, THEME_COLORS, THEME_NAMING, TODO, TOGGLE, TOOLTIP, TOOLTIP_CSS_VARS, Tabs, Testimonial, Textarea, ThemeApplicator, ThemeComparator, ThemeContext, ThemeErrorBoundary, ThemeInspector, ThemeLiveEditor, ThemePreview, ThemeProvider, ThemeValidator, Todo, Toggle, Tooltip, TreemapChart, UPLOAD, Upload, VIDEO_PLAYER, VideoPlayer, WaterfallChart, applyCSSVariables, applyCSSVarsToStyle, applyComponentTheme, applyPartStyles, applyTheme, camelToKebab, clearThemes, composables, constants, createCSSVarStyle, createDebugAttrs,
|
|
15113
|
-
export type { A11yIssue, AccordionParts, AccordionProps$1 as AccordionProps, AccordionState, AnimatedChartProps, AreaChartProps, AtomixConfig, AtomixGlassProps, AtomixLogoProps, AvatarGroupProps, AvatarParts, AvatarProps, AvatarSize, BadgeCSSVariable, BadgeParts, BadgeProps, BarChartOptions, BarChartProps, BarDimensions, BaseComponentProps, BlockProps, BreadcrumbInstance, BreadcrumbItem$1 as BreadcrumbItem, BreadcrumbOptions$1 as BreadcrumbOptions, BreadcrumbProps, BubbleChartProps, BubbleDataPoint, BuildConfig, ButtonCSSVariable, ButtonGroupProps, ButtonIconSlotProps, ButtonLabelSlotProps, ButtonParts, ButtonProps, ButtonRootSlotProps, ButtonSpinnerSlotProps, CSSThemeDefinition, CSSVariableConfig, CSSVariableNamingOptions, CalloutProps, CandlestickChartProps, CandlestickDataPoint, CardBodySlotProps, CardCSSVariable, CardFooterSlotProps, CardHeaderSlotProps, CardParts, CardProps, CardRootSlotProps, ChartAxis$1 as ChartAxis, ChartConfig$1 as ChartConfig, ChartDataPoint$1 as ChartDataPoint, ChartDataset$1 as ChartDataset, ChartProps$1 as ChartProps, ChartSize$1 as ChartSize, ChartType$1 as ChartType, CheckboxCSSVariable, CheckboxParts, CheckboxProps, CodeBlockProps, ColorModeToggleProps, ColorScale, ComponentCSSVariables, ComponentCustomization, ComponentName, ComponentParts, ComponentPartsMap, ComponentThemeOptions, ComponentThemeOverride, ContainerProps, CountdownProps, CustomizableComponentProps, DataTableColumn, DataTableParts, DataTableProps, DatePickerProps, DesignTokens, DisplacementMode, DonutChartProps, DropdownCSSVariable, DropdownDividerProps, DropdownHeaderProps, DropdownItemProps, DropdownMenuSlotProps, DropdownParts, DropdownPlacement, DropdownProps, DropdownRootSlotProps, DropdownToggleSlotProps, DropdownTrigger, EdgePanelMode, EdgePanelPosition, EdgePanelProps, ElementRefs, ElevationCardProps, FontPreloadConfig, FooterLayout, FooterLinkProps, FooterProps, FooterSectionProps, FooterSocialLinkProps, FormGroupParts, FormGroupProps, FormProps, FunnelChartProps, FunnelDataPoint, GaugeChartProps, GenerateCSSVariablesOptions, GlassContainerProps, GlassMode, GlassSize, GridColProps, GridProps, HeatmapChartProps, HeatmapDataPoint, HeroAlignment, HeroBackgroundSlide, HeroBackgroundSliderConfig, HeroProps, IconPosition, IconProps, IconSize$1 as IconSize, IconWeight$1 as IconWeight, ImageType, InputCSSVariable, InputElementSlotProps, InputParts, InputProps, InputRootSlotProps, IntegrationConfig, JSThemeDefinition, LineChartOptions, LineChartProps, ListGroupProps$1 as ListGroupProps, ListParts, ListProps, MasonryGridItemProps, MasonryGridProps, MegaMenuColumnProps, MegaMenuLinkProps, MegaMenuProps, MenuDividerProps, MenuItemProps, MenuProps, MergePropsOptions, MessageItem, MessagesProps, ModalBackdropSlotProps, ModalCSSVariable, ModalContentSlotProps, ModalDialogSlotProps, ModalParts, ModalProps, ModalRootSlotProps, MousePosition, MultiAxisChartProps, NamingOptions, NavAlignment, NavDropdownProps, NavItemProps, NavProps, NavVariant, NavbarParts, NavbarPosition, NavbarProps, OverLightConfig, OverLightObjectConfig, PaginationProps, PaletteColorOptions, PartStyleProps, PhosphorIconsType$1 as PhosphorIconsType, PhotoViewerProps, PieChartOptions, PieChartProps, PieSlice, PopoverProps, PopoverTriggerProps, ProductReviewProps, ProgressCSSVariable, ProgressParts, ProgressProps, RTLConfig, RadarChartProps, RadioCSSVariable, RadioParts, RadioProps, RatingProps, RiverContentColumn, RiverProps, RowProps, RuntimeConfig, ScatterChartProps, ScatterDataPoint, SectionIntroProps, SelectOption, SelectParts, SelectProps, SideMenuItemProps, SideMenuListProps, SideMenuProps, Size, SliderAutoplay, SliderBreakpoint, SliderEffect, SliderLazy, SliderNavigation, SliderPagination, SliderProps, SliderRefs, SliderScrollbar, SliderSlide, SliderState, SliderThumbs, SliderVirtual, SliderZoom, SlotProps, SocialLink, SocialPlatform, SortConfig, SpinnerProps, StateModifier, StepsProps, TabsCSSVariable, TabsParts, TabsProps, TestimonialProps, TextareaParts, TextareaProps, Theme, ThemeChangeEvent, ThemeColor, ThemeComparatorProps, ThemeComponentOverrides, ThemeContextValue, ThemeDefinition, ThemeErrorBoundaryProps, ThemeInspectorProps, ThemeLiveEditorProps, ThemeLoadOptions, ThemeName, ThemePreviewProps, ThemeProviderProps, ThemeTokens, ThemeValidationResult, TodoItem, TodoProps, ToggleProps, TooltipCSSVariable, TooltipParts, TooltipProps, TreemapChartProps, TreemapDataPoint, TreemapNode, UploadProps, UseBlockOptions, UseBlockReturn, UseCardOptions, UseCardReturn, UseDataTableProps, UseDataTableReturn, UseHistoryOptions, UseHistoryReturn, UseModalProps, UseModalReturn, UseSliderOptions, UseSliderReturn, UseThemeReturn, ValidationResult, Variant, VideoChapter, VideoPlayerProps, VideoQuality, VideoSubtitle, WaterfallChartProps, WaterfallDataPoint, listvariant };
|
|
15175
|
+
export { ACCORDION, ATOMIX_GLASS, AVATAR, AVATAR_GROUP, Accordion, AnimatedChart, AreaChart, AtomixGlass, AtomixLogo, Avatar, AvatarGroup, BADGE, BADGE_CSS_VARS, BLOCK, BREADCRUMB, BUTTON, BUTTON_CSS_VARS, BUTTON_GROUP, Badge, BarChart, Block, Breadcrumb, BubbleChart, Button, ButtonGroup, CALLOUT, CARD, CARD_CSS_VARS, CHART, CHECKBOX_CSS_VARS, CLASS_PREFIX, CODE_SNIPPET, COMPONENT_CSS_VARS, COUNTDOWN, Callout, CandlestickChart, Card, Chart, ChartRenderer, Checkbox, ColorModeToggle, Container, Countdown, DATA_TABLE_CLASSES, DATA_TABLE_SELECTORS, DATEPICKER, DEFAULT_ATOMIX_FONTS, DOTS, DROPDOWN, DROPDOWN_CSS_VARS, DataTable, DatePicker, DonutChart, Dropdown, EDGE_PANEL, EdgePanel, ElevationCard, FOOTER, FORM, FORM_GROUP, Footer, FooterLink, FooterSection, FooterSocialLink, Form, FormGroup, FunnelChart, GLASS_CONTAINER, GaugeChart, Grid, GridCol, HERO, HeatmapChart, Hero, INPUT, INPUT_CSS_VARS, Icon, Input, LIST, LIST_GROUP, LineChart, List, ListGroup, MESSAGES, MODAL, MODAL_CSS_VARS, MasonryGrid, MasonryGridItem, MegaMenu, MegaMenuColumn, MegaMenuLink, Menu, MenuDivider, MenuItem, Messages, Modal, MultiAxisChart, NAV, NAVBAR, Nav, NavDropdown, NavItem, Navbar, PAGINATION_DEFAULTS, PHOTOVIEWER, POPOVER, PROGRESS, PROGRESS_CSS_VARS, Pagination, PhotoViewer, PieChart, Popover, ProductReview, Progress, RADIO, RADIO_CSS_VARS, RATING, RIVER, RTLManager, RadarChart, Radio, Rating, River, Row, SECTION_INTRO, SELECT, SIDE_MENU, SIZES, SLIDER, SPINNER, STEPS, ScatterChart, SectionIntro, Select, SideMenu, SideMenuItem, SideMenuList, Slider, Spinner, Steps, TAB, TABS_CSS_VARS, TESTIMONIAL, TEXTAREA, THEME_COLORS, THEME_NAMING, TODO, TOGGLE, TOOLTIP, TOOLTIP_CSS_VARS, Tabs, Testimonial, Textarea, ThemeApplicator, ThemeComparator, ThemeContext, ThemeErrorBoundary, ThemeInspector, ThemeLiveEditor, ThemePreview, ThemeProvider, ThemeValidator, Todo, Toggle, Tooltip, TreemapChart, UPLOAD, Upload, VIDEO_PLAYER, VideoPlayer, WaterfallChart, applyCSSVariables, applyCSSVarsToStyle, applyComponentTheme, applyPartStyles, applyTheme, camelToKebab, clearThemes, composables, constants, createCSSVarStyle, createDebugAttrs, createFontPreloadLink, createPartProps, createSlotComponent, createSlotProps, createTheme, createThemeRegistry, createTokens, cssVarsToStyle, deepMerge, atomix as default, defaultTokens, defineConfig, designTokensToCSSVars, extendTheme, extractComponentName, extractYouTubeId, generateCSSVariableName, generateCSSVariables, generateCSSVariablesForSelector, generateClassName, generateComponentCSSVars, generateFontPreloadTags, generateUUID, getAllThemes, getCSSVariable, getComponentCSSVars, getComponentThemeValue, getPartStyles, getTheme, getThemeApplicator, getThemeCount, getThemeIds, hasCustomization, hasTheme, injectCSS, injectTheme, isCSSInjected, isDesignTokens, isSlot, isValidCSSVariableName, isYouTubeUrl, loadAtomixConfig, loadThemeFromConfig, loadThemeFromConfigSync, mapSCSSTokensToCSSVars, mergeCSSVars, mergeClassNames, mergeComponentProps, mergePartStyles, mergeSlots, mergeTheme, normalizeThemeTokens, preloadFonts, registerTheme, removeCSS, removeCSSVariables, removeTheme, renderSlot, resolveConfigPath, saveTheme, sliderConstants, theme, themePropertyToCSSVar, types, unregisterTheme, useAccordion, useAtomixGlass, useBadge, useBarChart, useBlock, useBreadcrumb, useButton, useCard, useChartData, useChartInteraction, useChartScale, useCheckbox, useComponentCustomization, useComponentDefaultProps, useComponentTheme, useDataTable, useEdgePanel, useForm, useFormGroup, useGlassContainer, useHero, useHistory, useInput, useLineChart, useMergedProps, useModal, useNav, useNavDropdown, useNavItem, useNavbar, usePagination, usePieChart, useRadio, useRiver, useSelect, useSideMenu, useSideMenuItem, useSlider, useSlot, useSpinner, useTextarea, useTheme, useThemeTokens, useTodo, utils };
|
|
15176
|
+
export type { A11yIssue, AccordionParts, AccordionProps$1 as AccordionProps, AccordionState, AnimatedChartProps, AreaChartProps, AtomixConfig, AtomixGlassProps, AtomixLogoProps, AvatarGroupProps, AvatarParts, AvatarProps, AvatarSize, BadgeCSSVariable, BadgeParts, BadgeProps, BarChartOptions, BarChartProps, BarDimensions, BaseComponentProps, BlockProps, BreadcrumbInstance, BreadcrumbItem$1 as BreadcrumbItem, BreadcrumbOptions$1 as BreadcrumbOptions, BreadcrumbProps, BubbleChartProps, BubbleDataPoint, BuildConfig, ButtonCSSVariable, ButtonGroupProps, ButtonIconSlotProps, ButtonLabelSlotProps, ButtonParts, ButtonProps, ButtonRootSlotProps, ButtonSpinnerSlotProps, CSSThemeDefinition, CSSVariableConfig, CSSVariableNamingOptions, CalloutProps, CandlestickChartProps, CandlestickDataPoint, CardBodySlotProps, CardCSSVariable, CardFooterSlotProps, CardHeaderSlotProps, CardParts, CardProps, CardRootSlotProps, ChartAxis$1 as ChartAxis, ChartConfig$1 as ChartConfig, ChartDataPoint$1 as ChartDataPoint, ChartDataset$1 as ChartDataset, ChartProps$1 as ChartProps, ChartSize$1 as ChartSize, ChartType$1 as ChartType, CheckboxCSSVariable, CheckboxParts, CheckboxProps, CodeBlockProps, ColorModeToggleProps, ColorScale, ComponentCSSVariables, ComponentCustomization, ComponentName, ComponentParts, ComponentPartsMap, ComponentThemeOptions, ComponentThemeOverride, ContainerProps, CountdownProps, CustomizableComponentProps, DataTableColumn, DataTableParts, DataTableProps, DatePickerProps, DesignTokens, DisplacementMode, DonutChartProps, DropdownCSSVariable, DropdownDividerProps, DropdownHeaderProps, DropdownItemProps, DropdownMenuSlotProps, DropdownParts, DropdownPlacement, DropdownProps, DropdownRootSlotProps, DropdownToggleSlotProps, DropdownTrigger, EdgePanelMode, EdgePanelPosition, EdgePanelProps, ElementRefs, ElevationCardProps, ExportFormat, FontPreloadConfig, FooterLayout, FooterLinkProps, FooterProps, FooterSectionProps, FooterSocialLinkProps, FormGroupParts, FormGroupProps, FormProps, FunnelChartProps, FunnelDataPoint, GaugeChartProps, GenerateCSSVariablesOptions, GlassContainerProps, GlassMode, GlassSize, GridColProps, GridProps, HeatmapChartProps, HeatmapDataPoint, HeroAlignment, HeroBackgroundSlide, HeroBackgroundSliderConfig, HeroProps, IconPosition, IconProps, IconSize$1 as IconSize, IconWeight$1 as IconWeight, ImageType, InputCSSVariable, InputElementSlotProps, InputParts, InputProps, InputRootSlotProps, IntegrationConfig, JSThemeDefinition, LineChartOptions, LineChartProps, ListGroupProps$1 as ListGroupProps, ListParts, ListProps, MasonryGridItemProps, MasonryGridProps, MegaMenuColumnProps, MegaMenuLinkProps, MegaMenuProps, MenuDividerProps, MenuItemProps, MenuProps, MergePropsOptions, MessageItem, MessagesProps, ModalBackdropSlotProps, ModalCSSVariable, ModalContentSlotProps, ModalDialogSlotProps, ModalParts, ModalProps, ModalRootSlotProps, MousePosition, MultiAxisChartProps, NamingOptions, NavAlignment, NavDropdownProps, NavItemProps, NavProps, NavVariant, NavbarParts, NavbarPosition, NavbarProps, OverLightConfig, OverLightObjectConfig, PaginationProps, PaletteColorOptions, PartStyleProps, PhosphorIconsType$1 as PhosphorIconsType, PhotoViewerProps, PieChartOptions, PieChartProps, PieSlice, PopoverProps, PopoverTriggerProps, ProductReviewProps, ProgressCSSVariable, ProgressParts, ProgressProps, RTLConfig, RadarChartProps, RadioCSSVariable, RadioParts, RadioProps, RatingProps, RiverContentColumn, RiverProps, RowProps, RuntimeConfig, ScatterChartProps, ScatterDataPoint, SectionIntroProps, SelectOption, SelectParts, SelectProps, SelectionMode, SideMenuItemProps, SideMenuListProps, SideMenuProps, Size, SliderAutoplay, SliderBreakpoint, SliderEffect, SliderLazy, SliderNavigation, SliderPagination, SliderProps, SliderRefs, SliderScrollbar, SliderSlide, SliderState, SliderThumbs, SliderVirtual, SliderZoom, SlotProps, SocialLink, SocialPlatform, SortConfig, SpinnerProps, StateModifier, StepsProps, TabsCSSVariable, TabsParts, TabsProps, TestimonialProps, TextareaParts, TextareaProps, Theme, ThemeChangeEvent, ThemeColor, ThemeComparatorProps, ThemeComponentOverrides, ThemeContextValue, ThemeDefinition, ThemeErrorBoundaryProps, ThemeInspectorProps, ThemeLiveEditorProps, ThemeLoadOptions, ThemeName, ThemePreviewProps, ThemeProviderProps, ThemeTokens, ThemeValidationResult, TodoItem, TodoProps, ToggleProps, TooltipCSSVariable, TooltipParts, TooltipProps, TreemapChartProps, TreemapDataPoint, TreemapNode, UploadProps, UseBlockOptions, UseBlockReturn, UseCardOptions, UseCardReturn, UseDataTableProps, UseDataTableReturn, UseHistoryOptions, UseHistoryReturn, UseModalProps, UseModalReturn, UseSliderOptions, UseSliderReturn, UseThemeReturn, ValidationResult, Variant, VideoChapter, VideoPlayerProps, VideoQuality, VideoSubtitle, WaterfallChartProps, WaterfallDataPoint, listvariant };
|