@shohojdhara/atomix 0.3.14 → 0.4.0
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 +20 -0
- package/build-tools/EXAMPLES.md +372 -0
- package/build-tools/README.md +242 -0
- package/build-tools/__tests__/error-handler.test.js +230 -0
- package/build-tools/__tests__/index.test.js +141 -0
- package/build-tools/__tests__/rollup-plugin.test.js +194 -0
- package/build-tools/__tests__/utils.test.js +161 -0
- package/build-tools/__tests__/vite-plugin.test.js +129 -0
- package/build-tools/__tests__/webpack-loader.test.js +190 -0
- package/build-tools/error-handler.js +308 -0
- package/build-tools/index.d.ts +44 -0
- package/build-tools/index.js +88 -0
- package/build-tools/package.json +50 -0
- package/build-tools/rollup-plugin.js +236 -0
- package/build-tools/types.d.ts +163 -0
- package/build-tools/utils.js +203 -0
- package/build-tools/vite-plugin.js +161 -0
- package/build-tools/webpack-loader.js +123 -0
- package/dist/atomix.css +21044 -2618
- package/dist/atomix.css.map +1 -1
- package/dist/atomix.min.css +77 -3
- package/dist/atomix.min.css.map +1 -1
- package/dist/build-tools/EXAMPLES.md +372 -0
- package/dist/build-tools/README.md +242 -0
- package/dist/build-tools/__tests__/error-handler.test.js +230 -0
- package/dist/build-tools/__tests__/index.test.js +141 -0
- package/dist/build-tools/__tests__/rollup-plugin.test.js +194 -0
- package/dist/build-tools/__tests__/utils.test.js +161 -0
- package/dist/build-tools/__tests__/vite-plugin.test.js +129 -0
- package/dist/build-tools/__tests__/webpack-loader.test.js +190 -0
- package/dist/build-tools/error-handler.js +308 -0
- package/dist/build-tools/index.d.ts +44 -0
- package/dist/build-tools/index.js +88 -0
- package/dist/build-tools/package.json +50 -0
- package/dist/build-tools/rollup-plugin.js +236 -0
- package/dist/build-tools/types.d.ts +163 -0
- package/dist/build-tools/utils.js +203 -0
- package/dist/build-tools/vite-plugin.js +161 -0
- package/dist/build-tools/webpack-loader.js +123 -0
- package/dist/charts.d.ts +1 -1
- package/dist/charts.js +86 -57
- package/dist/charts.js.map +1 -1
- package/dist/core.d.ts +1 -1
- package/dist/core.js +136 -112
- package/dist/core.js.map +1 -1
- package/dist/forms.d.ts +2 -5
- package/dist/forms.js +140 -128
- package/dist/forms.js.map +1 -1
- package/dist/heavy.d.ts +1 -1
- package/dist/heavy.js +136 -112
- package/dist/heavy.js.map +1 -1
- package/dist/index.d.ts +152 -78
- package/dist/index.esm.js +346 -340
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +359 -353
- package/dist/index.js.map +1 -1
- package/dist/index.min.js +1 -1
- package/dist/index.min.js.map +1 -1
- package/dist/layout.js.map +1 -1
- package/dist/theme.d.ts +9 -9
- package/dist/theme.js.map +1 -1
- package/package.json +23 -8
- package/scripts/atomix-cli.js +170 -73
- package/scripts/cli/__tests__/README.md +81 -0
- package/scripts/cli/__tests__/basic.test.js +115 -0
- package/scripts/cli/__tests__/component-generator.test.js +332 -0
- package/scripts/cli/__tests__/integration.test.js +327 -0
- package/scripts/cli/__tests__/test-setup.js +133 -0
- package/scripts/cli/__tests__/token-manager.test.js +251 -0
- package/scripts/cli/__tests__/utils.test.js +161 -0
- package/scripts/cli/component-generator.js +253 -299
- package/scripts/cli/dependency-checker.js +355 -0
- package/scripts/cli/interactive-init.js +46 -5
- package/scripts/cli/template-manager.js +0 -2
- package/scripts/cli/templates/common-templates.js +636 -0
- package/scripts/cli/templates/composable-templates.js +148 -126
- package/scripts/cli/templates/index.js +23 -16
- package/scripts/cli/templates/project-templates.js +151 -23
- package/scripts/cli/templates/react-templates.js +280 -210
- package/scripts/cli/templates/scss-templates.js +90 -91
- package/scripts/cli/templates/testing-templates.js +206 -27
- package/scripts/cli/templates/testing-utils.js +278 -0
- package/scripts/cli/templates/types-templates.js +70 -56
- package/scripts/cli/theme-bridge.js +8 -2
- package/scripts/cli/token-manager.js +318 -206
- package/scripts/cli/utils.js +0 -1
- package/src/components/Accordion/Accordion.stories.tsx +358 -850
- package/src/components/Accordion/Accordion.test.tsx +70 -50
- package/src/components/Accordion/Accordion.tsx +99 -94
- package/src/components/AtomixGlass/AtomixGlass.test.tsx +1 -1
- package/src/components/AtomixGlass/AtomixGlass.tsx +80 -39
- package/src/components/AtomixGlass/AtomixGlassContainer.tsx +103 -81
- package/src/components/AtomixGlass/GlassFilter.tsx +9 -16
- package/src/components/AtomixGlass/__snapshots__/AtomixGlass.test.tsx.snap +8 -7
- package/src/components/AtomixGlass/glass-utils.ts +6 -5
- package/src/components/AtomixGlass/shader-utils.ts +133 -52
- package/src/components/AtomixGlass/stories/Customization.stories.tsx +131 -0
- package/src/components/AtomixGlass/stories/Examples.stories.tsx +2957 -2853
- package/src/components/AtomixGlass/stories/Modes.stories.tsx +1 -1
- package/src/components/AtomixGlass/stories/Overview.stories.tsx +348 -0
- package/src/components/AtomixGlass/stories/Performance.stories.tsx +103 -0
- package/src/components/AtomixGlass/stories/Playground.stories.tsx +51 -36
- package/src/components/AtomixGlass/stories/{ShaderVariants.stories.tsx → Shaders.stories.tsx} +2 -2
- package/src/components/AtomixGlass/stories/shared-components.tsx +90 -190
- package/src/components/Avatar/Avatar.stories.tsx +195 -0
- package/src/components/Avatar/Avatar.tsx +58 -56
- package/src/components/Badge/Badge.stories.tsx +122 -352
- package/src/components/Badge/Badge.test.tsx +41 -41
- package/src/components/Badge/Badge.tsx +64 -62
- package/src/components/Block/Block.stories.tsx +30 -11
- package/src/components/Breadcrumb/Breadcrumb.stories.tsx +142 -23
- package/src/components/Breadcrumb/Breadcrumb.tsx +62 -60
- package/src/components/Button/Button.stories.tsx +454 -1126
- package/src/components/Button/Button.test.tsx +123 -0
- package/src/components/Button/Button.tsx +88 -60
- package/src/components/Button/ButtonGroup.stories.tsx +376 -215
- package/src/components/Button/ButtonGroup.tsx +4 -15
- package/src/components/Callout/Callout.stories.tsx +316 -568
- package/src/components/Card/Card.stories.tsx +292 -81
- package/src/components/Card/Card.tsx +30 -14
- package/src/components/Chart/AreaChart.tsx +1 -1
- package/src/components/Chart/CandlestickChart.tsx +23 -16
- package/src/components/Chart/Chart.stories.tsx +153 -16
- package/src/components/Chart/Chart.tsx +40 -44
- package/src/components/Chart/ChartRenderer.tsx +39 -12
- package/src/components/Chart/ChartToolbar.tsx +21 -5
- package/src/components/Chart/DonutChart.tsx +1 -1
- package/src/components/Chart/FunnelChart.tsx +4 -1
- package/src/components/Chart/GaugeChart.tsx +3 -1
- package/src/components/Chart/HeatmapChart.tsx +50 -37
- package/src/components/Chart/LineChart.tsx +3 -2
- package/src/components/Chart/MultiAxisChart.tsx +24 -16
- package/src/components/Chart/RadarChart.tsx +19 -17
- package/src/components/Chart/ScatterChart.tsx +29 -21
- package/src/components/ColorModeToggle/ColorModeToggle.stories.tsx +152 -66
- package/src/components/ColorModeToggle/ColorModeToggle.tsx +15 -3
- package/src/components/Countdown/Countdown.stories.tsx +114 -7
- package/src/components/DataTable/DataTable.stories.tsx +349 -144
- package/src/components/DataTable/DataTable.test.tsx +26 -148
- package/src/components/DataTable/DataTable.tsx +485 -456
- package/src/components/DatePicker/DatePicker.stories.tsx +310 -1066
- package/src/components/DatePicker/DatePicker.tsx +31 -26
- package/src/components/Dropdown/Dropdown.stories.tsx +153 -36
- package/src/components/Dropdown/Dropdown.tsx +313 -299
- package/src/components/EdgePanel/EdgePanel.stories.tsx +221 -25
- package/src/components/EdgePanel/EdgePanel.tsx +1 -3
- package/src/components/Footer/Footer.stories.tsx +396 -327
- package/src/components/Footer/Footer.tsx +130 -128
- package/src/components/Footer/FooterLink.tsx +2 -2
- package/src/components/Form/Checkbox.stories.tsx +140 -6
- package/src/components/Form/Checkbox.test.tsx +63 -0
- package/src/components/Form/Checkbox.tsx +122 -78
- package/src/components/Form/Form.stories.tsx +110 -19
- package/src/components/Form/FormGroup.stories.tsx +127 -4
- package/src/components/Form/Input.stories.tsx +22 -39
- package/src/components/Form/Input.test.tsx +38 -44
- package/src/components/Form/Radio.stories.tsx +146 -17
- package/src/components/Form/Radio.tsx +68 -66
- package/src/components/Form/Select.stories.tsx +140 -8
- package/src/components/Form/Select.tsx +184 -182
- package/src/components/Form/Textarea.stories.tsx +149 -6
- package/src/components/Form/Textarea.test.tsx +27 -32
- package/src/components/Hero/Hero.stories.tsx +372 -38
- package/src/components/Hero/Hero.tsx +201 -55
- package/src/components/Icon/index.ts +7 -1
- package/src/components/List/List.stories.tsx +141 -3
- package/src/components/List/List.tsx +19 -23
- package/src/components/Modal/Modal.stories.tsx +183 -43
- package/src/components/Modal/Modal.tsx +130 -127
- package/src/components/Navigation/Menu/MegaMenu.tsx +70 -70
- package/src/components/Navigation/Nav/NavDropdown.tsx +1 -5
- package/src/components/Navigation/SideMenu/SideMenu.stories.tsx +128 -28
- package/src/components/Navigation/SideMenu/SideMenu.tsx +5 -7
- package/src/components/Navigation/SideMenu/SideMenuItem.tsx +4 -5
- package/src/components/Pagination/Pagination.stories.tsx +7 -4
- package/src/components/Pagination/Pagination.tsx +199 -202
- package/src/components/PhotoViewer/PhotoViewer.tsx +4 -1
- package/src/components/Popover/Popover.stories.tsx +354 -97
- package/src/components/Popover/Popover.tsx +41 -37
- package/src/components/Progress/Progress.stories.tsx +160 -7
- package/src/components/River/River.stories.tsx +3 -2
- package/src/components/SectionIntro/SectionIntro.stories.tsx +239 -47
- package/src/components/Slider/Slider.stories.tsx +12 -4
- package/src/components/Spinner/Spinner.stories.tsx +104 -8
- package/src/components/Spinner/Spinner.test.tsx +23 -23
- package/src/components/Spinner/Spinner.tsx +43 -46
- package/src/components/Steps/Steps.stories.tsx +173 -42
- package/src/components/Tabs/Tabs.stories.tsx +141 -12
- package/src/components/Tabs/Tabs.tsx +74 -72
- package/src/components/Testimonial/Testimonial.stories.tsx +120 -3
- package/src/components/Todo/Todo.stories.tsx +198 -9
- package/src/components/Toggle/Toggle.stories.tsx +137 -36
- package/src/components/Toggle/Toggle.test.tsx +65 -70
- package/src/components/Toggle/Toggle.tsx +4 -1
- package/src/components/Tooltip/Tooltip.stories.tsx +194 -100
- package/src/components/Tooltip/Tooltip.tsx +104 -106
- package/src/components/Upload/Upload.stories.tsx +241 -150
- package/src/components/Upload/Upload.tsx +287 -283
- package/src/components/VideoPlayer/VideoPlayer.tsx +6 -1
- package/src/components/index.ts +13 -2
- package/src/layouts/Grid/Grid.stories.tsx +9 -3
- package/src/layouts/MasonryGrid/MasonryGrid.tsx +5 -1
- package/src/lib/README.md +2 -2
- package/src/lib/__tests__/theme-tools.test.ts +219 -0
- package/src/lib/composables/index.ts +2 -2
- package/src/lib/composables/shared-mouse-tracker.ts +13 -14
- package/src/lib/composables/useAtomixGlass.ts +126 -97
- package/src/lib/composables/useChartExport.ts +3 -8
- package/src/lib/composables/useDataTable.ts +72 -43
- package/src/lib/composables/useHero.ts +58 -14
- package/src/lib/composables/useHeroBackgroundSlider.ts +2 -9
- package/src/lib/composables/useInput.ts +10 -8
- package/src/lib/composables/useSideMenu.ts +6 -5
- package/src/lib/composables/useTooltip.ts +1 -2
- package/src/lib/composables/useVideoPlayer.ts +44 -35
- package/src/lib/config/index.ts +154 -154
- package/src/lib/constants/components.ts +9 -32
- package/src/lib/constants/cssVariables.ts +29 -29
- package/src/lib/hooks/__tests__/useComponentCustomization.test.ts +2 -6
- package/src/lib/hooks/index.ts +1 -1
- package/src/lib/hooks/useComponentCustomization.ts +11 -17
- package/src/lib/hooks/usePerformanceMonitor.ts +6 -7
- package/src/lib/patterns/__tests__/slots.test.ts +1 -1
- package/src/lib/patterns/index.ts +1 -1
- package/src/lib/patterns/slots.tsx +8 -13
- package/src/lib/storybook/InteractiveDemo.tsx +13 -18
- package/src/lib/storybook/PreviewContainer.tsx +1 -1
- package/src/lib/storybook/VariantsGrid.tsx +3 -7
- package/src/lib/storybook/index.ts +1 -1
- package/src/lib/theme/adapters/cssVariableMapper.ts +47 -74
- package/src/lib/theme/adapters/index.ts +3 -9
- package/src/lib/theme/adapters/themeAdapter.ts +41 -26
- package/src/lib/theme/config/index.ts +1 -1
- package/src/lib/theme/config/types.ts +2 -2
- package/src/lib/theme/config/validator.ts +10 -5
- package/src/lib/theme/constants/constants.ts +2 -2
- package/src/lib/theme/constants/index.ts +1 -2
- package/src/lib/theme/core/__tests__/createTheme.test.ts +20 -22
- package/src/lib/theme/core/composeTheme.ts +32 -26
- package/src/lib/theme/core/createTheme.ts +1 -1
- package/src/lib/theme/core/createThemeObject.ts +308 -301
- package/src/lib/theme/core/index.ts +3 -3
- package/src/lib/theme/devtools/CLI.ts +107 -105
- package/src/lib/theme/devtools/Comparator.tsx +50 -32
- package/src/lib/theme/devtools/DesignTokensCustomizer.stories.tsx +50 -48
- package/src/lib/theme/devtools/DesignTokensCustomizer.tsx +257 -63
- package/src/lib/theme/devtools/Inspector.tsx +75 -60
- package/src/lib/theme/devtools/LiveEditor.tsx +97 -76
- package/src/lib/theme/devtools/Preview.tsx +150 -106
- package/src/lib/theme/devtools/ThemeValidator.ts +29 -21
- package/src/lib/theme/devtools/index.ts +3 -9
- package/src/lib/theme/devtools/useHistory.ts +23 -21
- package/src/lib/theme/errors/errors.ts +12 -11
- package/src/lib/theme/errors/index.ts +2 -7
- package/src/lib/theme/generators/generateCSS.ts +9 -13
- package/src/lib/theme/generators/generateCSSNested.ts +1 -6
- package/src/lib/theme/generators/generateCSSVariables.ts +673 -630
- package/src/lib/theme/generators/index.ts +1 -4
- package/src/lib/theme/i18n/index.ts +1 -1
- package/src/lib/theme/i18n/rtl.ts +13 -13
- package/src/lib/theme/index.ts +7 -16
- package/src/lib/theme/runtime/ThemeApplicator.ts +4 -4
- package/src/lib/theme/runtime/ThemeContext.tsx +1 -1
- package/src/lib/theme/runtime/ThemeErrorBoundary.tsx +19 -23
- package/src/lib/theme/runtime/ThemeProvider.tsx +230 -239
- package/src/lib/theme/runtime/__tests__/ThemeProvider.integration.test.tsx +1 -1
- package/src/lib/theme/runtime/__tests__/ThemeProvider.test.tsx +24 -29
- package/src/lib/theme/runtime/index.ts +2 -5
- package/src/lib/theme/runtime/useTheme.ts +18 -18
- package/src/lib/theme/runtime/useThemeTokens.ts +22 -22
- package/src/lib/theme/test/testTheme.ts +15 -16
- package/src/lib/theme/tokens/index.ts +2 -7
- package/src/lib/theme/tokens/tokens.ts +25 -24
- package/src/lib/theme/types.ts +428 -411
- package/src/lib/theme/utils/__tests__/themeValidation.test.ts +3 -3
- package/src/lib/theme/utils/componentTheming.ts +18 -18
- package/src/lib/theme/utils/domUtils.ts +277 -289
- package/src/lib/theme/utils/index.ts +1 -2
- package/src/lib/theme/utils/injectCSS.ts +10 -14
- package/src/lib/theme/utils/naming.ts +20 -16
- package/src/lib/theme/utils/themeHelpers.ts +10 -12
- package/src/lib/theme/utils/themeUtils.ts +85 -86
- package/src/lib/theme/utils/themeValidation.ts +82 -33
- package/src/lib/theme-tools.ts +8 -6
- package/src/lib/types/components.ts +172 -71
- package/src/lib/types/partProps.ts +1 -1
- package/src/lib/utils/__tests__/csv.test.ts +45 -0
- package/src/lib/utils/componentUtils.ts +8 -12
- package/src/lib/utils/csv.ts +19 -0
- package/src/lib/utils/dataTableExport.ts +2 -15
- package/src/lib/utils/fontPreloader.ts +10 -19
- package/src/lib/utils/icons.ts +4 -1
- package/src/lib/utils/index.ts +2 -6
- package/src/lib/utils/memoryMonitor.ts +10 -8
- package/src/lib/utils/themeNaming.ts +2 -2
- package/src/styles/01-settings/_index.scss +1 -1
- package/src/styles/01-settings/_settings.accordion.scss +28 -7
- package/src/styles/01-settings/_settings.colors.scss +11 -11
- package/src/styles/01-settings/_settings.design-tokens.scss +61 -50
- package/src/styles/01-settings/_settings.navbar.scss +1 -1
- package/src/styles/01-settings/_settings.spacing.scss +3 -4
- package/src/styles/01-settings/_settings.tooltip.scss +1 -1
- package/src/styles/01-settings/_settings.typography.scss +4 -4
- package/src/styles/02-tools/_tools.button.scss +51 -21
- package/src/styles/02-tools/_tools.utility-api.scss +38 -12
- package/src/styles/03-generic/_generic.root.scss +4 -3
- package/src/styles/06-components/_components.accordion.scss +56 -14
- package/src/styles/06-components/_components.atomix-glass.scss +13 -9
- package/src/styles/06-components/_components.button.scss +16 -4
- package/src/styles/06-components/_components.callout.scss +27 -21
- package/src/styles/06-components/_components.card.scss +5 -14
- package/src/styles/06-components/_components.chart.scss +22 -19
- package/src/styles/06-components/_components.checkbox.scss +25 -17
- package/src/styles/06-components/_components.color-mode-toggle.scss +3 -1
- package/src/styles/06-components/_components.edge-panel.scss +9 -2
- package/src/styles/06-components/_components.footer.scss +1 -1
- package/src/styles/06-components/_components.side-menu.scss +5 -5
- package/src/styles/06-components/_components.toggle.scss +18 -0
- package/src/styles/06-components/_index.scss +1 -1
- package/src/styles/06-components/old.chart.styles.scss +0 -2
- package/src/styles/99-utilities/_index.scss +2 -0
- package/src/styles/99-utilities/_utilities.border.scss +69 -27
- package/src/styles/99-utilities/_utilities.display.scss +1 -1
- package/src/styles/99-utilities/_utilities.opacity.scss +10 -0
- package/src/styles/99-utilities/_utilities.position.scss +16 -9
- package/src/styles/99-utilities/_utilities.scss +2 -0
- package/src/styles/99-utilities/_utilities.sizes.scss +47 -18
- package/src/styles/99-utilities/_utilities.spacing.scss +118 -66
- package/src/styles/99-utilities/_utilities.text-gradient.scss +45 -0
- package/src/styles/99-utilities/_utilities.text.scss +67 -46
- package/themes/dark-complementary/README.md +98 -0
- package/themes/dark-complementary/index.scss +158 -0
- package/themes/default-light/README.md +81 -0
- package/themes/default-light/index.scss +154 -0
- package/themes/high-contrast/README.md +105 -0
- package/themes/high-contrast/index.scss +172 -0
- package/themes/test-theme/README.md +38 -0
- package/themes/test-theme/index.scss +47 -0
- package/scripts/cli/templates-original-backup.js +0 -1655
- package/scripts/cli/templates_backup.js +0 -684
- package/src/components/AtomixGlass/stories/AtomixGlass.stories.tsx +0 -1438
- package/src/lib/composables/useButton.ts +0 -93
- package/src/lib/composables/useCheckbox.ts +0 -70
|
@@ -3,141 +3,193 @@
|
|
|
3
3
|
|
|
4
4
|
// Define utilities for spacing
|
|
5
5
|
$utilities-spacing: (
|
|
6
|
-
'margin': (
|
|
6
|
+
'margin': (
|
|
7
|
+
responsive: true,
|
|
7
8
|
property: margin,
|
|
8
9
|
class: u-m,
|
|
9
|
-
values: map.merge(
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
10
|
+
values: map.merge(
|
|
11
|
+
$spacing-sizes,
|
|
12
|
+
(
|
|
13
|
+
auto: auto,
|
|
14
|
+
)
|
|
15
|
+
),
|
|
16
|
+
),
|
|
17
|
+
'margin-x': (
|
|
18
|
+
responsive: true,
|
|
14
19
|
property: margin-inline,
|
|
15
20
|
class: u-mx,
|
|
16
|
-
values: map.merge(
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
+
values: map.merge(
|
|
22
|
+
$spacing-sizes,
|
|
23
|
+
(
|
|
24
|
+
auto: auto,
|
|
25
|
+
)
|
|
26
|
+
),
|
|
27
|
+
),
|
|
28
|
+
'margin-y': (
|
|
29
|
+
responsive: true,
|
|
21
30
|
property: margin-block,
|
|
22
31
|
class: u-my,
|
|
23
|
-
values: map.merge(
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
32
|
+
values: map.merge(
|
|
33
|
+
$spacing-sizes,
|
|
34
|
+
(
|
|
35
|
+
auto: auto,
|
|
36
|
+
)
|
|
37
|
+
),
|
|
38
|
+
),
|
|
39
|
+
'margin-top': (
|
|
40
|
+
responsive: true,
|
|
28
41
|
property: margin-top,
|
|
29
42
|
class: u-mt,
|
|
30
|
-
values: map.merge(
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
43
|
+
values: map.merge(
|
|
44
|
+
$spacing-sizes,
|
|
45
|
+
(
|
|
46
|
+
auto: auto,
|
|
47
|
+
)
|
|
48
|
+
),
|
|
49
|
+
),
|
|
50
|
+
'margin-end': (
|
|
51
|
+
responsive: true,
|
|
35
52
|
property: margin-inline-end,
|
|
36
53
|
class: u-me,
|
|
37
|
-
values: map.merge(
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
54
|
+
values: map.merge(
|
|
55
|
+
$spacing-sizes,
|
|
56
|
+
(
|
|
57
|
+
auto: auto,
|
|
58
|
+
)
|
|
59
|
+
),
|
|
60
|
+
),
|
|
61
|
+
'margin-bottom': (
|
|
62
|
+
responsive: true,
|
|
42
63
|
property: margin-bottom,
|
|
43
64
|
class: u-mb,
|
|
44
|
-
values: map.merge(
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
65
|
+
values: map.merge(
|
|
66
|
+
$spacing-sizes,
|
|
67
|
+
(
|
|
68
|
+
auto: auto,
|
|
69
|
+
)
|
|
70
|
+
),
|
|
71
|
+
),
|
|
72
|
+
'margin-start': (
|
|
73
|
+
responsive: true,
|
|
49
74
|
property: margin-inline-start,
|
|
50
75
|
class: u-ms,
|
|
51
|
-
values: map.merge(
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
76
|
+
values: map.merge(
|
|
77
|
+
$spacing-sizes,
|
|
78
|
+
(
|
|
79
|
+
auto: auto,
|
|
80
|
+
)
|
|
81
|
+
),
|
|
82
|
+
),
|
|
83
|
+
// Negative margin utilities — only generated when $enable-negative-margins is true
|
|
84
|
+
'negative-margin': (
|
|
85
|
+
responsive: true,
|
|
86
|
+
property: margin,
|
|
87
|
+
class: u-m,
|
|
88
|
+
values: $negative-spacers,
|
|
89
|
+
generated: $enable-negative-margins,
|
|
90
|
+
),
|
|
91
|
+
'negative-margin-x': (
|
|
92
|
+
responsive: true,
|
|
62
93
|
property: margin-inline,
|
|
63
94
|
class: u-mx,
|
|
64
95
|
values: $negative-spacers,
|
|
96
|
+
generated: $enable-negative-margins,
|
|
65
97
|
),
|
|
66
|
-
'negative-margin-y': (
|
|
98
|
+
'negative-margin-y': (
|
|
99
|
+
responsive: true,
|
|
67
100
|
property: margin-block,
|
|
68
101
|
class: u-my,
|
|
69
102
|
values: $negative-spacers,
|
|
103
|
+
generated: $enable-negative-margins,
|
|
70
104
|
),
|
|
71
|
-
'negative-margin-top': (
|
|
105
|
+
'negative-margin-top': (
|
|
106
|
+
responsive: true,
|
|
72
107
|
property: margin-top,
|
|
73
108
|
class: u-mt,
|
|
74
109
|
values: $negative-spacers,
|
|
110
|
+
generated: $enable-negative-margins,
|
|
75
111
|
),
|
|
76
|
-
'negative-margin-end': (
|
|
112
|
+
'negative-margin-end': (
|
|
113
|
+
responsive: true,
|
|
77
114
|
property: margin-inline-end,
|
|
78
115
|
class: u-me,
|
|
79
116
|
values: $negative-spacers,
|
|
117
|
+
generated: $enable-negative-margins,
|
|
80
118
|
),
|
|
81
|
-
'negative-margin-bottom': (
|
|
119
|
+
'negative-margin-bottom': (
|
|
120
|
+
responsive: true,
|
|
82
121
|
property: margin-bottom,
|
|
83
122
|
class: u-mb,
|
|
84
123
|
values: $negative-spacers,
|
|
124
|
+
generated: $enable-negative-margins,
|
|
85
125
|
),
|
|
86
|
-
'negative-margin-start': (
|
|
126
|
+
'negative-margin-start': (
|
|
127
|
+
responsive: true,
|
|
87
128
|
property: margin-inline-start,
|
|
88
129
|
class: u-ms,
|
|
89
130
|
values: $negative-spacers,
|
|
131
|
+
generated: $enable-negative-margins,
|
|
90
132
|
),
|
|
91
133
|
// Padding utilities
|
|
92
|
-
'padding': (
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
134
|
+
'padding': (
|
|
135
|
+
responsive: true,
|
|
136
|
+
property: padding,
|
|
137
|
+
class: u-p,
|
|
138
|
+
values: $spacing-sizes,
|
|
139
|
+
),
|
|
140
|
+
'padding-x': (
|
|
141
|
+
responsive: true,
|
|
98
142
|
property: padding-inline,
|
|
99
143
|
class: u-px,
|
|
100
144
|
values: $spacing-sizes,
|
|
101
145
|
),
|
|
102
|
-
'padding-y': (
|
|
146
|
+
'padding-y': (
|
|
147
|
+
responsive: true,
|
|
103
148
|
property: padding-block,
|
|
104
149
|
class: u-py,
|
|
105
150
|
values: $spacing-sizes,
|
|
106
151
|
),
|
|
107
|
-
'padding-top': (
|
|
152
|
+
'padding-top': (
|
|
153
|
+
responsive: true,
|
|
108
154
|
property: padding-top,
|
|
109
155
|
class: u-pt,
|
|
110
156
|
values: $spacing-sizes,
|
|
111
157
|
),
|
|
112
|
-
'padding-end': (
|
|
158
|
+
'padding-end': (
|
|
159
|
+
responsive: true,
|
|
113
160
|
property: padding-inline-end,
|
|
114
161
|
class: u-pe,
|
|
115
162
|
values: $spacing-sizes,
|
|
116
163
|
),
|
|
117
|
-
'padding-bottom': (
|
|
164
|
+
'padding-bottom': (
|
|
165
|
+
responsive: true,
|
|
118
166
|
property: padding-bottom,
|
|
119
167
|
class: u-pb,
|
|
120
168
|
values: $spacing-sizes,
|
|
121
169
|
),
|
|
122
|
-
'padding-start': (
|
|
170
|
+
'padding-start': (
|
|
171
|
+
responsive: true,
|
|
123
172
|
property: padding-inline-start,
|
|
124
173
|
class: u-ps,
|
|
125
174
|
values: $spacing-sizes,
|
|
126
175
|
),
|
|
127
176
|
// Gap utility
|
|
128
|
-
'gap': (
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
177
|
+
'gap': (
|
|
178
|
+
responsive: true,
|
|
179
|
+
property: gap,
|
|
180
|
+
class: u-gap,
|
|
181
|
+
values: $spacing-sizes,
|
|
182
|
+
),
|
|
183
|
+
'row-gap': (
|
|
184
|
+
responsive: true,
|
|
134
185
|
property: row-gap,
|
|
135
186
|
class: u-row-gap,
|
|
136
187
|
values: $spacing-sizes,
|
|
137
188
|
),
|
|
138
|
-
'column-gap': (
|
|
189
|
+
'column-gap': (
|
|
190
|
+
responsive: true,
|
|
139
191
|
property: column-gap,
|
|
140
192
|
class: u-column-gap,
|
|
141
193
|
values: $spacing-sizes,
|
|
142
194
|
),
|
|
143
|
-
);
|
|
195
|
+
);
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
// Text gradient utilities - requires special CSS properties
|
|
2
|
+
// These utilities apply gradient colors to text using background-clip technique
|
|
3
|
+
// Using utility generator system with advanced best practices
|
|
4
|
+
|
|
5
|
+
@use 'sass:map';
|
|
6
|
+
@use '../01-settings/settings.design-tokens' as *;
|
|
7
|
+
|
|
8
|
+
// Define utilities for text gradients
|
|
9
|
+
$utilities-text-gradient: (
|
|
10
|
+
// Base text gradient utility - applies the core text gradient properties
|
|
11
|
+
'text-gradient': (
|
|
12
|
+
property: null,
|
|
13
|
+
// No specific CSS property, we're only using local-vars
|
|
14
|
+
class: u-text-gradient,
|
|
15
|
+
values: (
|
|
16
|
+
null: null,
|
|
17
|
+
),
|
|
18
|
+
local-vars: (
|
|
19
|
+
'background-clip': text,
|
|
20
|
+
'-webkit-background-clip': text,
|
|
21
|
+
'-webkit-text-fill-color': transparent,
|
|
22
|
+
),
|
|
23
|
+
),
|
|
24
|
+
|
|
25
|
+
// Text gradient color variations using existing CSS gradient tokens
|
|
26
|
+
'text-gradient-colors': (
|
|
27
|
+
property: background-image,
|
|
28
|
+
class: u-text-gradient,
|
|
29
|
+
values: (
|
|
30
|
+
primary: var(--atomix-primary-gradient),
|
|
31
|
+
secondary: var(--atomix-secondary-gradient),
|
|
32
|
+
success: var(--atomix-success-gradient),
|
|
33
|
+
warning: var(--atomix-warning-gradient),
|
|
34
|
+
error: var(--atomix-error-gradient),
|
|
35
|
+
info: var(--atomix-info-gradient),
|
|
36
|
+
light: var(--atomix-light-gradient),
|
|
37
|
+
dark: var(--atomix-dark-gradient),
|
|
38
|
+
),
|
|
39
|
+
local-vars: (
|
|
40
|
+
'background-clip': text,
|
|
41
|
+
'-webkit-background-clip': text,
|
|
42
|
+
'-webkit-text-fill-color': transparent,
|
|
43
|
+
),
|
|
44
|
+
)
|
|
45
|
+
);
|
|
@@ -6,59 +6,73 @@
|
|
|
6
6
|
|
|
7
7
|
// Define utilities for text
|
|
8
8
|
$utilities-text: (
|
|
9
|
-
'font-size': (
|
|
9
|
+
'font-size': (
|
|
10
|
+
rfs: true,
|
|
10
11
|
property: font-size,
|
|
11
|
-
class: u-
|
|
12
|
-
values: map.merge(
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
12
|
+
class: u-fs,
|
|
13
|
+
values: map.merge(
|
|
14
|
+
color-maps.$font-sizes-extended,
|
|
15
|
+
(
|
|
16
|
+
xs: map.get(color-maps.$font-sizes-extended, 'xs'),
|
|
17
|
+
sm: map.get(color-maps.$font-sizes-extended, 'sm'),
|
|
18
|
+
base: map.get(color-maps.$font-sizes-extended, 'base'),
|
|
19
|
+
lg: map.get(color-maps.$font-sizes-extended, 'lg'),
|
|
20
|
+
xl: map.get(color-maps.$font-sizes-extended, 'xl'),
|
|
21
|
+
'2xl': map.get(color-maps.$font-sizes-extended, '2xl'),
|
|
22
|
+
'3xl': map.get(color-maps.$font-sizes-extended, '3xl'),
|
|
23
|
+
'4xl': map.get(color-maps.$font-sizes-extended, '4xl'),
|
|
24
|
+
'5xl': map.get(color-maps.$font-sizes-extended, '5xl'),
|
|
25
|
+
'6xl': map.get(color-maps.$font-sizes-extended, '6xl'),
|
|
26
|
+
1: map.get(color-maps.$font-sizes-extended, 'h1'),
|
|
27
|
+
2: map.get(color-maps.$font-sizes-extended, 'h2'),
|
|
28
|
+
3: map.get(color-maps.$font-sizes-extended, 'h3'),
|
|
29
|
+
4: map.get(color-maps.$font-sizes-extended, 'h4'),
|
|
30
|
+
5: map.get(color-maps.$font-sizes-extended, 'h5'),
|
|
31
|
+
6: map.get(color-maps.$font-sizes-extended, 'h6'),
|
|
32
|
+
)
|
|
33
|
+
),
|
|
30
34
|
),
|
|
31
|
-
'font-style': (
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
+
'font-style': (
|
|
36
|
+
property: font-style,
|
|
37
|
+
class: u,
|
|
38
|
+
values: (
|
|
39
|
+
italic: italic,
|
|
40
|
+
not-italic: normal,
|
|
35
41
|
),
|
|
36
42
|
),
|
|
37
|
-
'font-weight': (
|
|
43
|
+
'font-weight': (
|
|
44
|
+
property: font-weight,
|
|
38
45
|
class: u-font,
|
|
39
46
|
values: color-maps.$theme-font-weight,
|
|
40
47
|
),
|
|
41
|
-
'line-height': (
|
|
48
|
+
'line-height': (
|
|
49
|
+
property: line-height,
|
|
42
50
|
class: u-leading,
|
|
43
|
-
values: map.merge(
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
51
|
+
values: map.merge(
|
|
52
|
+
color-maps.$line-heights,
|
|
53
|
+
(
|
|
54
|
+
none: 1,
|
|
55
|
+
tight: 1.25,
|
|
56
|
+
snug: 1.375,
|
|
57
|
+
normal: 1.5,
|
|
58
|
+
relaxed: 1.625,
|
|
59
|
+
loose: 2,
|
|
60
|
+
1: 1,
|
|
61
|
+
)
|
|
62
|
+
),
|
|
52
63
|
),
|
|
53
|
-
'text-align': (
|
|
64
|
+
'text-align': (
|
|
65
|
+
responsive: true,
|
|
54
66
|
property: text-align,
|
|
55
67
|
class: u-text,
|
|
56
|
-
values: (
|
|
68
|
+
values: (
|
|
69
|
+
start: start,
|
|
57
70
|
end: end,
|
|
58
71
|
center: center,
|
|
59
72
|
),
|
|
60
73
|
),
|
|
61
|
-
'text-decoration': (
|
|
74
|
+
'text-decoration': (
|
|
75
|
+
property: text-decoration,
|
|
62
76
|
class: u,
|
|
63
77
|
values: (
|
|
64
78
|
'underline': underline,
|
|
@@ -66,28 +80,35 @@ $utilities-text: (
|
|
|
66
80
|
'no-underline': none,
|
|
67
81
|
),
|
|
68
82
|
),
|
|
69
|
-
'text-transform': (
|
|
83
|
+
'text-transform': (
|
|
84
|
+
property: text-transform,
|
|
70
85
|
class: u-text,
|
|
71
86
|
values: lowercase uppercase capitalize,
|
|
72
87
|
),
|
|
73
|
-
'white-space': (
|
|
88
|
+
'white-space': (
|
|
89
|
+
property: white-space,
|
|
74
90
|
class: u-text,
|
|
75
|
-
values: (
|
|
91
|
+
values: (
|
|
92
|
+
wrap: normal,
|
|
76
93
|
nowrap: nowrap,
|
|
77
94
|
),
|
|
78
95
|
),
|
|
79
|
-
'word-wrap': (
|
|
96
|
+
'word-wrap': (
|
|
97
|
+
property: word-wrap word-break,
|
|
80
98
|
class: u-text,
|
|
81
|
-
values: (
|
|
99
|
+
values: (
|
|
100
|
+
break: break-word,
|
|
82
101
|
),
|
|
83
102
|
rtl: false,
|
|
84
103
|
),
|
|
85
|
-
'color': (
|
|
104
|
+
'color': (
|
|
105
|
+
property: color,
|
|
86
106
|
class: u-text,
|
|
87
107
|
values: color-maps.$utilities-text-colors,
|
|
88
108
|
),
|
|
89
|
-
'text-emphasis-color': (
|
|
109
|
+
'text-emphasis-color': (
|
|
110
|
+
property: color,
|
|
90
111
|
class: u-text,
|
|
91
112
|
values: color-maps.$utilities-text-emphasis-colors,
|
|
92
113
|
),
|
|
93
|
-
);
|
|
114
|
+
);
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
# dark-complementary Theme
|
|
2
|
+
|
|
3
|
+
## Description
|
|
4
|
+
|
|
5
|
+
The dark-complementary theme provides a modern dark theme with complementary colors optimized for low-light environments and reduced eye strain. This theme maintains excellent readability while providing a sophisticated dark aesthetic.
|
|
6
|
+
|
|
7
|
+
## Usage
|
|
8
|
+
|
|
9
|
+
### CSS Theme
|
|
10
|
+
|
|
11
|
+
```scss
|
|
12
|
+
@import 'themes/dark-complementary';
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
### JavaScript Theme
|
|
16
|
+
|
|
17
|
+
```typescript
|
|
18
|
+
import { darkComplementaryTheme } from './themes/dark-complementary';
|
|
19
|
+
import { ThemeProvider } from '@shohojdhara/atomix/theme';
|
|
20
|
+
|
|
21
|
+
function App() {
|
|
22
|
+
return (
|
|
23
|
+
<ThemeProvider theme={darkComplementaryTheme}>
|
|
24
|
+
{/* Your app */}
|
|
25
|
+
</ThemeProvider>
|
|
26
|
+
);
|
|
27
|
+
}
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
## Customization
|
|
31
|
+
|
|
32
|
+
Edit the theme variables in `index.scss` to customize colors, typography, spacing, and more. The theme uses CSS custom properties for easy customization.
|
|
33
|
+
|
|
34
|
+
### Color Customization
|
|
35
|
+
|
|
36
|
+
```scss
|
|
37
|
+
:root[data-theme='dark-complementary'] {
|
|
38
|
+
--atomix-color-primary: #your-primary-color;
|
|
39
|
+
--atomix-color-background: #your-background-color;
|
|
40
|
+
// ... other variables
|
|
41
|
+
}
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
### Background Customization
|
|
45
|
+
|
|
46
|
+
For dark themes, consider the background hierarchy:
|
|
47
|
+
|
|
48
|
+
```scss
|
|
49
|
+
:root[data-theme='dark-complementary'] {
|
|
50
|
+
--atomix-color-background: #1a1a1a; // Main background
|
|
51
|
+
--atomix-color-background-paper: #2d2d2d; // Card/surface backgrounds
|
|
52
|
+
--atomix-color-background-subtle: #404040; // Hover states, subtle elements
|
|
53
|
+
}
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
## Features
|
|
57
|
+
|
|
58
|
+
- **Dark Mode Optimized**: Reduced blue light for better eye comfort
|
|
59
|
+
- **High Contrast**: Maintained readability in low-light conditions
|
|
60
|
+
- **Complementary Colors**: Brighter, more vibrant color palette for dark backgrounds
|
|
61
|
+
- **Modern Design**: Clean aesthetic with enhanced shadows for depth
|
|
62
|
+
- **Accessible**: Meets WCAG 2.1 AA standards with proper contrast ratios
|
|
63
|
+
|
|
64
|
+
## Build
|
|
65
|
+
|
|
66
|
+
```bash
|
|
67
|
+
atomix build-theme themes/dark-complementary
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
## Color Palette
|
|
71
|
+
|
|
72
|
+
- **Primary**: Light Blue (#4dabf7) - Brighter blue for dark backgrounds
|
|
73
|
+
- **Secondary**: Light Gray (#868e96) - Muted for secondary elements
|
|
74
|
+
- **Success**: Bright Green (#51cf66) - Highly visible success states
|
|
75
|
+
- **Error**: Bright Red (#ff6b6b) - Attention-grabbing error states
|
|
76
|
+
- **Warning**: Bright Yellow (#ffd43b) - Noticeable warning states
|
|
77
|
+
- **Info**: Bright Cyan (#74c0fc) - Clear informational elements
|
|
78
|
+
|
|
79
|
+
## Typography
|
|
80
|
+
|
|
81
|
+
- **Base Font**: Inter (system font stack fallback)
|
|
82
|
+
- **Mono Font**: Fira Code (for code elements)
|
|
83
|
+
- **Font Sizes**: Responsive scale from xs to 5xl
|
|
84
|
+
- **Font Weights**: Light (300) to Extra Bold (800)
|
|
85
|
+
- **Text Colors**: White primary (#ffffff), Light gray secondary (#cccccc)
|
|
86
|
+
|
|
87
|
+
## Background Hierarchy
|
|
88
|
+
|
|
89
|
+
- **Main Background**: Dark gray (#1a1a1a)
|
|
90
|
+
- **Paper/Surface**: Medium dark gray (#2d2d2d)
|
|
91
|
+
- **Subtle Elements**: Light medium gray (#404040)
|
|
92
|
+
|
|
93
|
+
## Shadows
|
|
94
|
+
|
|
95
|
+
Enhanced shadow definitions for better depth perception in dark themes:
|
|
96
|
+
|
|
97
|
+
- Inner shadows use white tints for subtle highlights
|
|
98
|
+
- Outer shadows use increased opacity for better definition
|