@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
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { Meta, StoryObj } from '@storybook/react';
|
|
3
|
+
import { fn } from '@storybook/test';
|
|
3
4
|
import { Footer } from './Footer';
|
|
4
5
|
import { FooterSection } from './FooterSection';
|
|
5
6
|
import { FooterLink } from './FooterLink';
|
|
@@ -12,43 +13,229 @@ const meta = {
|
|
|
12
13
|
layout: 'fullscreen',
|
|
13
14
|
docs: {
|
|
14
15
|
description: {
|
|
15
|
-
component:
|
|
16
|
-
|
|
16
|
+
component: `
|
|
17
|
+
# Footer
|
|
18
|
+
|
|
19
|
+
## Overview
|
|
20
|
+
|
|
21
|
+
Footer provides a comprehensive footer section for websites with multiple layout variants, sections, links, and optional features like newsletter signup and back-to-top buttons. Footers support various color variants, sizes, and can be sticky. Essential for site navigation, branding, and additional information display.
|
|
22
|
+
|
|
23
|
+
## Features
|
|
24
|
+
|
|
25
|
+
- Multiple layout variants (columns, centered, minimal, stacked, flexible, sidebar, wide)
|
|
26
|
+
- Color and size variants
|
|
27
|
+
- Newsletter signup option
|
|
28
|
+
- Back-to-top button
|
|
29
|
+
- Social media links
|
|
30
|
+
- Divider options
|
|
31
|
+
- Sticky positioning
|
|
32
|
+
- Responsive design
|
|
33
|
+
- Glass effect option
|
|
34
|
+
|
|
35
|
+
## Accessibility
|
|
36
|
+
|
|
37
|
+
- Screen reader: Footer content and links announced properly
|
|
38
|
+
- ARIA support: Proper landmarks and roles for footer section
|
|
39
|
+
- Keyboard support: All interactive elements accessible via keyboard
|
|
40
|
+
- Focus management: Visible focus indicators for navigation
|
|
41
|
+
|
|
42
|
+
## Usage Examples
|
|
43
|
+
|
|
44
|
+
### Basic Usage
|
|
45
|
+
|
|
46
|
+
\`\`\`tsx
|
|
47
|
+
<Footer>
|
|
48
|
+
<FooterSection title="Products">
|
|
49
|
+
<FooterLink href="/products">Our Products</FooterLink>
|
|
50
|
+
</FooterSection>
|
|
51
|
+
</Footer>
|
|
52
|
+
\`\`\`
|
|
53
|
+
|
|
54
|
+
### With Newsletter
|
|
55
|
+
|
|
56
|
+
\`\`\`tsx
|
|
57
|
+
<Footer showNewsletter={true}>
|
|
58
|
+
<FooterSection title="Products">
|
|
59
|
+
<FooterLink href="/products">Our Products</FooterLink>
|
|
60
|
+
</FooterSection>
|
|
61
|
+
</Footer>
|
|
62
|
+
\`\`\`
|
|
63
|
+
|
|
64
|
+
## API Reference
|
|
65
|
+
|
|
66
|
+
### Props
|
|
67
|
+
|
|
68
|
+
| Prop | Type | Default | Description |
|
|
69
|
+
| ---- | ---- | ------- | ----------- |
|
|
70
|
+
| layout | 'columns' \\| 'centered' \\| 'minimal' \\| 'stacked' \\| 'flexible' \\| 'sidebar' \\| 'wide' | 'columns' | Footer layout variant |
|
|
71
|
+
| variant | ThemeColor | 'secondary' | Color variant |
|
|
72
|
+
| size | 'sm' \\| 'md' \\| 'lg' | 'md' | Size variant |
|
|
73
|
+
| showNewsletter | boolean | false | Whether to show newsletter signup |
|
|
74
|
+
| showBackToTop | boolean | false | Whether to show back to top button |
|
|
75
|
+
| showDivider | boolean | false | Whether to show divider above bottom section |
|
|
76
|
+
| sticky | boolean | false | Whether footer should be sticky |
|
|
77
|
+
| socialLinks | SocialLink[] | [] | Array of social media links |
|
|
78
|
+
| onBackToTopClick | () => void | - | Callback when back to top button is clicked |
|
|
79
|
+
| brand | ReactNode | - | Brand name or logo |
|
|
80
|
+
| brandLogo | string \\| ReactNode | - | Brand logo (image URL or React element) |
|
|
81
|
+
| brandDescription | ReactNode | - | Brand description text |
|
|
82
|
+
| copyright | ReactNode | - | Copyright text |
|
|
83
|
+
| newsletterTitle | string | 'Stay Updated' | Newsletter section title |
|
|
84
|
+
| newsletterDescription | string | 'Subscribe...' | Newsletter section description |
|
|
85
|
+
| newsletterPlaceholder | string | 'Enter your email' | Newsletter input placeholder |
|
|
86
|
+
| newsletterButtonText | string | 'Subscribe' | Newsletter submit button text |
|
|
87
|
+
| onNewsletterSubmit | (email: string) => void | - | Newsletter submit handler |
|
|
88
|
+
| glass | boolean | - | Whether footer should have glass effect |
|
|
89
|
+
`,
|
|
17
90
|
},
|
|
18
91
|
},
|
|
19
92
|
},
|
|
20
93
|
tags: ['autodocs'],
|
|
21
94
|
argTypes: {
|
|
22
95
|
layout: {
|
|
23
|
-
control: 'select',
|
|
96
|
+
control: { type: 'select' },
|
|
24
97
|
options: ['columns', 'centered', 'minimal', 'stacked', 'flexible', 'sidebar', 'wide'],
|
|
25
98
|
description: 'Footer layout variant',
|
|
99
|
+
table: {
|
|
100
|
+
type: {
|
|
101
|
+
summary:
|
|
102
|
+
'"columns" | "centered" | "minimal" | "stacked" | "flexible" | "sidebar" | "wide"',
|
|
103
|
+
},
|
|
104
|
+
defaultValue: { summary: 'columns' },
|
|
105
|
+
},
|
|
26
106
|
},
|
|
27
107
|
variant: {
|
|
28
|
-
control: 'select',
|
|
108
|
+
control: { type: 'select' },
|
|
29
109
|
options: THEME_COLORS,
|
|
30
110
|
description: 'Color variant',
|
|
111
|
+
table: {
|
|
112
|
+
type: { summary: 'ThemeColor' },
|
|
113
|
+
defaultValue: { summary: 'primary' },
|
|
114
|
+
},
|
|
31
115
|
},
|
|
32
116
|
size: {
|
|
33
|
-
control: 'select',
|
|
117
|
+
control: { type: 'select' },
|
|
34
118
|
options: SIZES,
|
|
35
119
|
description: 'Size variant',
|
|
120
|
+
table: {
|
|
121
|
+
type: { summary: '"sm" | "md" | "lg"' },
|
|
122
|
+
defaultValue: { summary: 'md' },
|
|
123
|
+
},
|
|
36
124
|
},
|
|
37
125
|
showNewsletter: {
|
|
38
126
|
control: 'boolean',
|
|
39
127
|
description: 'Whether to show newsletter signup',
|
|
128
|
+
table: {
|
|
129
|
+
type: { summary: 'boolean' },
|
|
130
|
+
defaultValue: { summary: false },
|
|
131
|
+
},
|
|
40
132
|
},
|
|
41
133
|
showBackToTop: {
|
|
42
134
|
control: 'boolean',
|
|
43
135
|
description: 'Whether to show back to top button',
|
|
136
|
+
table: {
|
|
137
|
+
type: { summary: 'boolean' },
|
|
138
|
+
defaultValue: { summary: false },
|
|
139
|
+
},
|
|
44
140
|
},
|
|
45
141
|
showDivider: {
|
|
46
142
|
control: 'boolean',
|
|
47
143
|
description: 'Whether to show divider above bottom section',
|
|
144
|
+
table: {
|
|
145
|
+
type: { summary: 'boolean' },
|
|
146
|
+
defaultValue: { summary: true },
|
|
147
|
+
},
|
|
48
148
|
},
|
|
49
149
|
sticky: {
|
|
50
150
|
control: 'boolean',
|
|
51
151
|
description: 'Whether footer should be sticky',
|
|
152
|
+
table: {
|
|
153
|
+
type: { summary: 'boolean' },
|
|
154
|
+
defaultValue: { summary: false },
|
|
155
|
+
},
|
|
156
|
+
},
|
|
157
|
+
socialLinks: {
|
|
158
|
+
control: 'object',
|
|
159
|
+
description: 'Array of social media links',
|
|
160
|
+
table: {
|
|
161
|
+
type: { summary: 'SocialLink[]' },
|
|
162
|
+
defaultValue: { summary: '[]' },
|
|
163
|
+
},
|
|
164
|
+
},
|
|
165
|
+
onBackToTop: {
|
|
166
|
+
action: 'back to top clicked',
|
|
167
|
+
description: 'Callback when back to top button is clicked',
|
|
168
|
+
},
|
|
169
|
+
onNewsletterSubmit: {
|
|
170
|
+
action: 'newsletter submitted',
|
|
171
|
+
description: 'Callback when newsletter is submitted',
|
|
172
|
+
},
|
|
173
|
+
brand: {
|
|
174
|
+
control: 'text',
|
|
175
|
+
description: 'Brand name',
|
|
176
|
+
table: {
|
|
177
|
+
type: { summary: 'ReactNode' },
|
|
178
|
+
},
|
|
179
|
+
},
|
|
180
|
+
brandLogo: {
|
|
181
|
+
control: 'text',
|
|
182
|
+
description: 'Brand logo URL',
|
|
183
|
+
table: {
|
|
184
|
+
type: { summary: 'string | ReactNode' },
|
|
185
|
+
},
|
|
186
|
+
},
|
|
187
|
+
brandDescription: {
|
|
188
|
+
control: 'text',
|
|
189
|
+
description: 'Brand description',
|
|
190
|
+
table: {
|
|
191
|
+
type: { summary: 'ReactNode' },
|
|
192
|
+
},
|
|
193
|
+
},
|
|
194
|
+
copyright: {
|
|
195
|
+
control: 'text',
|
|
196
|
+
description: 'Copyright text',
|
|
197
|
+
table: {
|
|
198
|
+
type: { summary: 'ReactNode' },
|
|
199
|
+
},
|
|
200
|
+
},
|
|
201
|
+
newsletterTitle: {
|
|
202
|
+
control: 'text',
|
|
203
|
+
description: 'Title for newsletter section',
|
|
204
|
+
table: {
|
|
205
|
+
type: { summary: 'string' },
|
|
206
|
+
defaultValue: { summary: 'Stay Updated' },
|
|
207
|
+
},
|
|
208
|
+
},
|
|
209
|
+
newsletterDescription: {
|
|
210
|
+
control: 'text',
|
|
211
|
+
description: 'Description for newsletter section',
|
|
212
|
+
table: {
|
|
213
|
+
type: { summary: 'string' },
|
|
214
|
+
defaultValue: { summary: 'Subscribe to our newsletter for the latest updates.' },
|
|
215
|
+
},
|
|
216
|
+
},
|
|
217
|
+
newsletterPlaceholder: {
|
|
218
|
+
control: 'text',
|
|
219
|
+
description: 'Placeholder for newsletter input',
|
|
220
|
+
table: {
|
|
221
|
+
type: { summary: 'string' },
|
|
222
|
+
defaultValue: { summary: 'Enter your email' },
|
|
223
|
+
},
|
|
224
|
+
},
|
|
225
|
+
newsletterButtonText: {
|
|
226
|
+
control: 'text',
|
|
227
|
+
description: 'Text for newsletter button',
|
|
228
|
+
table: {
|
|
229
|
+
type: { summary: 'string' },
|
|
230
|
+
defaultValue: { summary: 'Subscribe' },
|
|
231
|
+
},
|
|
232
|
+
},
|
|
233
|
+
glass: {
|
|
234
|
+
control: 'boolean',
|
|
235
|
+
description: 'Whether to apply glass effect',
|
|
236
|
+
table: {
|
|
237
|
+
type: { summary: 'boolean' },
|
|
238
|
+
},
|
|
52
239
|
},
|
|
53
240
|
},
|
|
54
241
|
} satisfies Meta<typeof Footer>;
|
|
@@ -82,56 +269,38 @@ const SampleFooterContent = () => (
|
|
|
82
269
|
<FooterLink href="/contact">Contact</FooterLink>
|
|
83
270
|
</FooterSection>
|
|
84
271
|
|
|
85
|
-
<FooterSection title="
|
|
86
|
-
<FooterLink href="/
|
|
87
|
-
<FooterLink href="/
|
|
88
|
-
<FooterLink href="/
|
|
89
|
-
<FooterLink href="/
|
|
272
|
+
<FooterSection title="Resources">
|
|
273
|
+
<FooterLink href="/docs">Documentation</FooterLink>
|
|
274
|
+
<FooterLink href="/tutorials">Tutorials</FooterLink>
|
|
275
|
+
<FooterLink href="/support">Support</FooterLink>
|
|
276
|
+
<FooterLink href="/community">Community</FooterLink>
|
|
90
277
|
</FooterSection>
|
|
91
278
|
|
|
92
|
-
<FooterSection title="
|
|
93
|
-
<FooterLink href="/
|
|
94
|
-
<FooterLink href="/
|
|
95
|
-
<FooterLink href="/
|
|
96
|
-
<FooterLink href="/
|
|
279
|
+
<FooterSection title="Legal">
|
|
280
|
+
<FooterLink href="/privacy">Privacy Policy</FooterLink>
|
|
281
|
+
<FooterLink href="/terms">Terms of Service</FooterLink>
|
|
282
|
+
<FooterLink href="/cookies">Cookie Policy</FooterLink>
|
|
283
|
+
<FooterLink href="/gdpr">GDPR Compliance</FooterLink>
|
|
97
284
|
</FooterSection>
|
|
98
285
|
</>
|
|
99
286
|
);
|
|
100
287
|
|
|
101
|
-
const
|
|
288
|
+
export const BasicUsage: Story = {
|
|
102
289
|
args: {
|
|
103
290
|
brand: 'Atomix',
|
|
104
|
-
brandDescription: 'A modern design system for building accessible
|
|
105
|
-
copyright: '© 2024 Atomix
|
|
106
|
-
layout: 'columns',
|
|
107
|
-
variant: 'primary',
|
|
108
|
-
size: 'md',
|
|
109
|
-
showNewsletter: false,
|
|
110
|
-
showBackToTop: false,
|
|
111
|
-
showDivider: true,
|
|
112
|
-
sticky: false,
|
|
291
|
+
brandDescription: 'A modern design system for building beautiful, accessible websites.',
|
|
292
|
+
copyright: '© 2024 Atomix. All rights reserved.',
|
|
113
293
|
socialLinks: sampleSocialLinks,
|
|
114
294
|
},
|
|
115
|
-
render:
|
|
116
|
-
<
|
|
117
|
-
<
|
|
118
|
-
|
|
119
|
-
<p>This is sample page content to demonstrate the footer in context.</p>
|
|
120
|
-
</div>
|
|
121
|
-
<Footer {...args}>
|
|
122
|
-
<SampleFooterContent />
|
|
123
|
-
</Footer>
|
|
124
|
-
</div>
|
|
295
|
+
render: args => (
|
|
296
|
+
<Footer {...args}>
|
|
297
|
+
<SampleFooterContent />
|
|
298
|
+
</Footer>
|
|
125
299
|
),
|
|
126
|
-
};
|
|
127
|
-
|
|
128
|
-
export const Default: Story = {
|
|
129
|
-
...LayoutTemplate,
|
|
130
300
|
parameters: {
|
|
131
301
|
docs: {
|
|
132
302
|
description: {
|
|
133
|
-
story:
|
|
134
|
-
'Default footer configuration with modern styling, design tokens, and enhanced visual effects.',
|
|
303
|
+
story: 'Basic footer with sample content and default layout.',
|
|
135
304
|
},
|
|
136
305
|
},
|
|
137
306
|
},
|
|
@@ -139,377 +308,277 @@ export const Default: Story = {
|
|
|
139
308
|
|
|
140
309
|
export const WithNewsletter: Story = {
|
|
141
310
|
args: {
|
|
142
|
-
|
|
311
|
+
brand: 'Atomix',
|
|
312
|
+
brandDescription: 'A modern design system for building beautiful, accessible websites.',
|
|
313
|
+
copyright: '© 2024 Atomix. All rights reserved.',
|
|
143
314
|
showNewsletter: true,
|
|
144
|
-
newsletterTitle: 'Stay
|
|
145
|
-
newsletterDescription:
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
315
|
+
newsletterTitle: 'Stay Updated',
|
|
316
|
+
newsletterDescription: 'Subscribe to our newsletter for the latest updates and news.',
|
|
317
|
+
newsletterPlaceholder: 'Enter your email address',
|
|
318
|
+
newsletterButtonText: 'Subscribe Now',
|
|
319
|
+
onNewsletterSubmit: fn(),
|
|
320
|
+
socialLinks: sampleSocialLinks,
|
|
321
|
+
},
|
|
322
|
+
render: args => (
|
|
323
|
+
<Footer {...args}>
|
|
324
|
+
<SampleFooterContent />
|
|
325
|
+
</Footer>
|
|
326
|
+
),
|
|
327
|
+
parameters: {
|
|
328
|
+
docs: {
|
|
329
|
+
description: {
|
|
330
|
+
story: 'Footer with newsletter signup form.',
|
|
331
|
+
},
|
|
149
332
|
},
|
|
150
333
|
},
|
|
151
|
-
render: Default.render,
|
|
152
334
|
};
|
|
153
335
|
|
|
154
336
|
export const WithBackToTop: Story = {
|
|
155
337
|
args: {
|
|
156
|
-
|
|
338
|
+
brand: 'Atomix',
|
|
339
|
+
brandDescription: 'A modern design system for building beautiful, accessible websites.',
|
|
340
|
+
copyright: '© 2024 Atomix. All rights reserved.',
|
|
157
341
|
showBackToTop: true,
|
|
158
342
|
backToTopText: 'Back to Top',
|
|
159
|
-
onBackToTop: ()
|
|
160
|
-
|
|
343
|
+
onBackToTop: fn(),
|
|
344
|
+
socialLinks: sampleSocialLinks,
|
|
345
|
+
},
|
|
346
|
+
render: args => (
|
|
347
|
+
<Footer {...args}>
|
|
348
|
+
<SampleFooterContent />
|
|
349
|
+
</Footer>
|
|
350
|
+
),
|
|
351
|
+
parameters: {
|
|
352
|
+
docs: {
|
|
353
|
+
description: {
|
|
354
|
+
story: 'Footer with back to top button and social links.',
|
|
355
|
+
},
|
|
161
356
|
},
|
|
162
357
|
},
|
|
163
|
-
render: Default.render,
|
|
164
358
|
};
|
|
165
359
|
|
|
166
|
-
export const
|
|
167
|
-
...LayoutTemplate,
|
|
360
|
+
export const CenteredLayout: Story = {
|
|
168
361
|
args: {
|
|
169
|
-
...LayoutTemplate.args,
|
|
170
362
|
layout: 'centered',
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
export const Minimal: Story = {
|
|
177
|
-
...LayoutTemplate,
|
|
178
|
-
args: {
|
|
179
|
-
...LayoutTemplate.args,
|
|
180
|
-
layout: 'minimal',
|
|
181
|
-
variant: 'light',
|
|
182
|
-
size: 'sm',
|
|
183
|
-
socialLinks: sampleSocialLinks.slice(0, 3),
|
|
184
|
-
showDivider: false,
|
|
185
|
-
showNewsletter: false,
|
|
363
|
+
brand: 'Atomix',
|
|
364
|
+
brandDescription: 'A modern design system for building beautiful, accessible websites.',
|
|
365
|
+
copyright: '© 2024 Atomix. All rights reserved.',
|
|
366
|
+
socialLinks: sampleSocialLinks,
|
|
186
367
|
},
|
|
187
|
-
render:
|
|
188
|
-
<
|
|
189
|
-
<
|
|
190
|
-
|
|
191
|
-
<p>This is sample page content with a minimal footer.</p>
|
|
192
|
-
</div>
|
|
193
|
-
<Footer {...args}>
|
|
194
|
-
<FooterSection title="Quick Links">
|
|
195
|
-
<FooterLink href="/about">About</FooterLink>
|
|
196
|
-
<FooterLink href="/contact">Contact</FooterLink>
|
|
197
|
-
<FooterLink href="/privacy">Privacy</FooterLink>
|
|
198
|
-
</FooterSection>
|
|
199
|
-
</Footer>
|
|
200
|
-
</div>
|
|
368
|
+
render: args => (
|
|
369
|
+
<Footer {...args}>
|
|
370
|
+
<SampleFooterContent />
|
|
371
|
+
</Footer>
|
|
201
372
|
),
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
layout: 'stacked',
|
|
209
|
-
showNewsletter: true,
|
|
210
|
-
showBackToTop: true,
|
|
211
|
-
},
|
|
212
|
-
};
|
|
213
|
-
|
|
214
|
-
export const DarkVariant: Story = {
|
|
215
|
-
args: {
|
|
216
|
-
...Default.args,
|
|
217
|
-
variant: 'dark',
|
|
218
|
-
showNewsletter: true,
|
|
219
|
-
showBackToTop: true,
|
|
220
|
-
},
|
|
221
|
-
render: Default.render,
|
|
222
|
-
};
|
|
223
|
-
|
|
224
|
-
export const LargeSize: Story = {
|
|
225
|
-
args: {
|
|
226
|
-
...Default.args,
|
|
227
|
-
size: 'lg',
|
|
228
|
-
showNewsletter: true,
|
|
229
|
-
showBackToTop: true,
|
|
373
|
+
parameters: {
|
|
374
|
+
docs: {
|
|
375
|
+
description: {
|
|
376
|
+
story: 'Footer with centered layout variant.',
|
|
377
|
+
},
|
|
378
|
+
},
|
|
230
379
|
},
|
|
231
|
-
render: Default.render,
|
|
232
380
|
};
|
|
233
381
|
|
|
234
|
-
export const
|
|
382
|
+
export const MinimalLayout: Story = {
|
|
235
383
|
args: {
|
|
236
|
-
...Default.args,
|
|
237
|
-
size: 'sm',
|
|
238
384
|
layout: 'minimal',
|
|
385
|
+
brand: 'Atomix',
|
|
386
|
+
brandLogo: 'https://via.placeholder.com/150x50.png?text=LOGO',
|
|
387
|
+
copyright: '© 2024 Atomix. All rights reserved.',
|
|
388
|
+
socialLinks: sampleSocialLinks,
|
|
239
389
|
},
|
|
240
|
-
render:
|
|
241
|
-
}
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
390
|
+
render: args => (
|
|
391
|
+
<Footer {...args}>
|
|
392
|
+
<SampleFooterContent />
|
|
393
|
+
</Footer>
|
|
394
|
+
),
|
|
395
|
+
parameters: {
|
|
396
|
+
docs: {
|
|
397
|
+
description: {
|
|
398
|
+
story: 'Footer with minimal layout variant.',
|
|
399
|
+
},
|
|
400
|
+
},
|
|
248
401
|
},
|
|
249
|
-
render: Default.render,
|
|
250
402
|
};
|
|
251
403
|
|
|
252
|
-
export const
|
|
404
|
+
export const StackedLayout: Story = {
|
|
253
405
|
args: {
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
406
|
+
layout: 'stacked',
|
|
407
|
+
brand: 'Atomix',
|
|
408
|
+
brandDescription: 'A modern design system for building beautiful, accessible websites.',
|
|
409
|
+
copyright: '© 2024 Atomix. All rights reserved.',
|
|
410
|
+
socialLinks: sampleSocialLinks,
|
|
258
411
|
},
|
|
259
|
-
render:
|
|
260
|
-
<
|
|
261
|
-
<
|
|
262
|
-
|
|
263
|
-
<p>This page is tall enough to demonstrate the sticky footer behavior.</p>
|
|
264
|
-
{Array.from({ length: 20 }, (_, i) => (
|
|
265
|
-
<p key={i}>
|
|
266
|
-
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed do eiusmod tempor
|
|
267
|
-
incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud
|
|
268
|
-
exercitation ullamco laboris.
|
|
269
|
-
</p>
|
|
270
|
-
))}
|
|
271
|
-
</div>
|
|
272
|
-
<Footer {...args}>
|
|
273
|
-
<SampleFooterContent />
|
|
274
|
-
</Footer>
|
|
275
|
-
</div>
|
|
412
|
+
render: args => (
|
|
413
|
+
<Footer {...args}>
|
|
414
|
+
<SampleFooterContent />
|
|
415
|
+
</Footer>
|
|
276
416
|
),
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
417
|
+
parameters: {
|
|
418
|
+
docs: {
|
|
419
|
+
description: {
|
|
420
|
+
story: 'Footer with stacked layout variant.',
|
|
421
|
+
},
|
|
422
|
+
},
|
|
283
423
|
},
|
|
284
|
-
render: (args: any) => (
|
|
285
|
-
<div style={{ minHeight: '100vh', display: 'flex', flexDirection: 'column' }}>
|
|
286
|
-
<div style={{ flex: 1, backgroundColor: 'var(--atomix-brand-bg-subtle)' }}>
|
|
287
|
-
<h1>Collapsible Footer Sections</h1>
|
|
288
|
-
<p>Resize the window to mobile size to see collapsible sections.</p>
|
|
289
|
-
</div>
|
|
290
|
-
<Footer {...args}>
|
|
291
|
-
<FooterSection title="Products" collapsible defaultCollapsed>
|
|
292
|
-
<FooterLink href="/product1">Web Development</FooterLink>
|
|
293
|
-
<FooterLink href="/product2">Mobile Apps</FooterLink>
|
|
294
|
-
<FooterLink href="/product3">UI/UX Design</FooterLink>
|
|
295
|
-
</FooterSection>
|
|
296
|
-
|
|
297
|
-
<FooterSection title="Company" collapsible>
|
|
298
|
-
<FooterLink href="/about">About Us</FooterLink>
|
|
299
|
-
<FooterLink href="/careers">Careers</FooterLink>
|
|
300
|
-
<FooterLink href="/blog">Blog</FooterLink>
|
|
301
|
-
</FooterSection>
|
|
302
|
-
</Footer>
|
|
303
|
-
</div>
|
|
304
|
-
),
|
|
305
424
|
};
|
|
306
425
|
|
|
307
|
-
export const
|
|
426
|
+
export const FlexibleLayout: Story = {
|
|
308
427
|
args: {
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
{ platform: 'discord' as const, url: 'https://discord.gg/company' },
|
|
315
|
-
],
|
|
428
|
+
layout: 'flexible',
|
|
429
|
+
brand: 'Atomix',
|
|
430
|
+
brandDescription: 'A modern design system for building beautiful, accessible websites.',
|
|
431
|
+
copyright: '© 2024 Atomix. All rights reserved.',
|
|
432
|
+
socialLinks: sampleSocialLinks,
|
|
316
433
|
},
|
|
317
|
-
render:
|
|
318
|
-
<
|
|
319
|
-
<
|
|
320
|
-
|
|
321
|
-
<p>Footer with enhanced social platforms and modern styling.</p>
|
|
322
|
-
</div>
|
|
323
|
-
<Footer {...args}>
|
|
324
|
-
<FooterSection title="External Resources">
|
|
325
|
-
<FooterLink href="https://github.com" external>
|
|
326
|
-
GitHub
|
|
327
|
-
</FooterLink>
|
|
328
|
-
<FooterLink href="https://stackoverflow.com" external>
|
|
329
|
-
Stack Overflow
|
|
330
|
-
</FooterLink>
|
|
331
|
-
<FooterLink href="https://developer.mozilla.org" external>
|
|
332
|
-
MDN Docs
|
|
333
|
-
</FooterLink>
|
|
334
|
-
</FooterSection>
|
|
335
|
-
|
|
336
|
-
<FooterSection title="Internal Links">
|
|
337
|
-
<FooterLink href="/about">About Us</FooterLink>
|
|
338
|
-
<FooterLink href="/contact">Contact</FooterLink>
|
|
339
|
-
<FooterLink href="/blog" active>
|
|
340
|
-
Blog
|
|
341
|
-
</FooterLink>
|
|
342
|
-
<FooterLink href="/disabled" disabled>
|
|
343
|
-
Disabled Link
|
|
344
|
-
</FooterLink>
|
|
345
|
-
</FooterSection>
|
|
346
|
-
</Footer>
|
|
347
|
-
</div>
|
|
434
|
+
render: args => (
|
|
435
|
+
<Footer {...args}>
|
|
436
|
+
<SampleFooterContent />
|
|
437
|
+
</Footer>
|
|
348
438
|
),
|
|
439
|
+
parameters: {
|
|
440
|
+
docs: {
|
|
441
|
+
description: {
|
|
442
|
+
story: 'Footer with flexible layout variant.',
|
|
443
|
+
},
|
|
444
|
+
},
|
|
445
|
+
},
|
|
349
446
|
};
|
|
350
447
|
|
|
351
|
-
export const
|
|
448
|
+
export const SidebarLayout: Story = {
|
|
352
449
|
args: {
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
450
|
+
layout: 'sidebar',
|
|
451
|
+
brand: 'Atomix',
|
|
452
|
+
brandDescription: 'A modern design system for building beautiful, accessible websites.',
|
|
453
|
+
copyright: '© 2024 Atomix. All rights reserved.',
|
|
357
454
|
socialLinks: sampleSocialLinks,
|
|
358
455
|
},
|
|
359
|
-
render:
|
|
360
|
-
<
|
|
361
|
-
<
|
|
362
|
-
|
|
363
|
-
flex: 1,
|
|
364
|
-
padding: '2rem',
|
|
365
|
-
background: 'linear-gradient(135deg, #667eea 0%, #764ba2 100%)',
|
|
366
|
-
}}
|
|
367
|
-
>
|
|
368
|
-
<h1 style={{ color: 'white' }}>Modern Design</h1>
|
|
369
|
-
<p style={{ color: 'white' }}>Showcasing modern gradients and enhanced visual effects.</p>
|
|
370
|
-
</div>
|
|
371
|
-
<Footer {...args}>
|
|
372
|
-
<SampleFooterContent />
|
|
373
|
-
</Footer>
|
|
374
|
-
</div>
|
|
456
|
+
render: args => (
|
|
457
|
+
<Footer {...args}>
|
|
458
|
+
<SampleFooterContent />
|
|
459
|
+
</Footer>
|
|
375
460
|
),
|
|
461
|
+
parameters: {
|
|
462
|
+
docs: {
|
|
463
|
+
description: {
|
|
464
|
+
story: 'Footer with sidebar layout variant.',
|
|
465
|
+
},
|
|
466
|
+
},
|
|
467
|
+
},
|
|
376
468
|
};
|
|
377
469
|
|
|
378
|
-
export const
|
|
470
|
+
export const WideLayout: Story = {
|
|
379
471
|
args: {
|
|
380
|
-
|
|
381
|
-
brand: '
|
|
382
|
-
brandDescription:
|
|
383
|
-
|
|
384
|
-
showNewsletter: true,
|
|
385
|
-
showBackToTop: true,
|
|
472
|
+
layout: 'wide',
|
|
473
|
+
brand: 'Atomix',
|
|
474
|
+
brandDescription: 'A modern design system for building beautiful, accessible websites.',
|
|
475
|
+
copyright: '© 2024 Atomix. All rights reserved.',
|
|
386
476
|
socialLinks: sampleSocialLinks,
|
|
387
477
|
},
|
|
478
|
+
render: args => (
|
|
479
|
+
<Footer {...args}>
|
|
480
|
+
<SampleFooterContent />
|
|
481
|
+
</Footer>
|
|
482
|
+
),
|
|
388
483
|
parameters: {
|
|
389
484
|
docs: {
|
|
390
485
|
description: {
|
|
391
|
-
story:
|
|
392
|
-
'Demonstrates the use of design tokens for consistent styling, enhanced hover effects, modern gradients, and improved accessibility features.',
|
|
486
|
+
story: 'Footer with wide layout variant.',
|
|
393
487
|
},
|
|
394
488
|
},
|
|
395
489
|
},
|
|
396
|
-
render: (args: any) => (
|
|
397
|
-
<div style={{ minHeight: '100vh', display: 'flex', flexDirection: 'column' }}>
|
|
398
|
-
<div style={{ flex: 1, backgroundColor: 'var(--atomix-brand-bg-subtle)' }}>
|
|
399
|
-
<h1>Design Token Integration</h1>
|
|
400
|
-
<p>
|
|
401
|
-
This footer demonstrates consistent use of design tokens for colors, spacing, shadows, and
|
|
402
|
-
typography. Hover over elements to see enhanced visual effects.
|
|
403
|
-
</p>
|
|
404
|
-
<ul>
|
|
405
|
-
<li>✨ Global CSS variables for box shadows</li>
|
|
406
|
-
<li>🎨 Design token-based colors and opacity</li>
|
|
407
|
-
<li>📏 Consistent spacing using rem() function</li>
|
|
408
|
-
<li>🔄 Smooth transitions and hover effects</li>
|
|
409
|
-
<li>♿ Enhanced accessibility features</li>
|
|
410
|
-
</ul>
|
|
411
|
-
</div>
|
|
412
|
-
<Footer {...args}>
|
|
413
|
-
<FooterSection title="Design System">
|
|
414
|
-
<FooterLink href="/tokens">Design Tokens</FooterLink>
|
|
415
|
-
<FooterLink href="/components">Components</FooterLink>
|
|
416
|
-
<FooterLink href="/guidelines">Guidelines</FooterLink>
|
|
417
|
-
<FooterLink href="/accessibility">Accessibility</FooterLink>
|
|
418
|
-
</FooterSection>
|
|
419
|
-
|
|
420
|
-
<FooterSection title="Development">
|
|
421
|
-
<FooterLink href="/scss">SCSS Architecture</FooterLink>
|
|
422
|
-
<FooterLink href="/css-vars">CSS Variables</FooterLink>
|
|
423
|
-
<FooterLink href="/responsive">Responsive Design</FooterLink>
|
|
424
|
-
<FooterLink href="/performance">Performance</FooterLink>
|
|
425
|
-
</FooterSection>
|
|
426
|
-
</Footer>
|
|
427
|
-
</div>
|
|
428
|
-
),
|
|
429
490
|
};
|
|
430
491
|
|
|
431
|
-
export const
|
|
492
|
+
export const DarkVariant: Story = {
|
|
432
493
|
args: {
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
494
|
+
variant: 'dark',
|
|
495
|
+
brand: 'Atomix',
|
|
496
|
+
brandDescription: 'A modern design system for building beautiful, accessible websites.',
|
|
497
|
+
copyright: '© 2024 Atomix. All rights reserved.',
|
|
498
|
+
socialLinks: sampleSocialLinks,
|
|
436
499
|
},
|
|
437
|
-
render:
|
|
438
|
-
<
|
|
439
|
-
<
|
|
440
|
-
|
|
441
|
-
<p>Tab through the footer elements to see enhanced focus states and keyboard navigation.</p>
|
|
442
|
-
</div>
|
|
443
|
-
<Footer {...args}>
|
|
444
|
-
<SampleFooterContent />
|
|
445
|
-
</Footer>
|
|
446
|
-
</div>
|
|
500
|
+
render: args => (
|
|
501
|
+
<Footer {...args}>
|
|
502
|
+
<SampleFooterContent />
|
|
503
|
+
</Footer>
|
|
447
504
|
),
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
showNewsletter: true,
|
|
455
|
-
showBackToTop: true,
|
|
505
|
+
parameters: {
|
|
506
|
+
docs: {
|
|
507
|
+
description: {
|
|
508
|
+
story: 'Footer with dark color variant.',
|
|
509
|
+
},
|
|
510
|
+
},
|
|
456
511
|
},
|
|
457
|
-
render: (args: any) => (
|
|
458
|
-
<div style={{ minHeight: '100vh', display: 'flex', flexDirection: 'column' }}>
|
|
459
|
-
<div style={{ flex: 1, backgroundColor: 'var(--atomix-brand-bg-subtle)' }}>
|
|
460
|
-
<h1>Responsive Design</h1>
|
|
461
|
-
<p>Resize the viewport to see responsive grid layouts and collapsible sections.</p>
|
|
462
|
-
</div>
|
|
463
|
-
<Footer {...args}>
|
|
464
|
-
<SampleFooterContent />
|
|
465
|
-
</Footer>
|
|
466
|
-
</div>
|
|
467
|
-
),
|
|
468
512
|
};
|
|
469
513
|
|
|
470
|
-
export const
|
|
471
|
-
...LayoutTemplate,
|
|
514
|
+
export const LargeSize: Story = {
|
|
472
515
|
args: {
|
|
473
|
-
|
|
474
|
-
|
|
516
|
+
size: 'lg',
|
|
517
|
+
brand: 'Atomix',
|
|
518
|
+
brandDescription: 'A modern design system for building beautiful, accessible websites.',
|
|
519
|
+
copyright: '© 2024 Atomix. All rights reserved.',
|
|
520
|
+
socialLinks: sampleSocialLinks,
|
|
475
521
|
},
|
|
522
|
+
render: args => (
|
|
523
|
+
<Footer {...args}>
|
|
524
|
+
<SampleFooterContent />
|
|
525
|
+
</Footer>
|
|
526
|
+
),
|
|
476
527
|
parameters: {
|
|
477
528
|
docs: {
|
|
478
529
|
description: {
|
|
479
|
-
story:
|
|
480
|
-
'Flexible layout that automatically adapts to content width and screen size. Perfect for dynamic content scenarios.',
|
|
530
|
+
story: 'Footer with large size variant.',
|
|
481
531
|
},
|
|
482
532
|
},
|
|
483
533
|
},
|
|
484
534
|
};
|
|
485
535
|
|
|
486
|
-
export const
|
|
487
|
-
...LayoutTemplate,
|
|
536
|
+
export const WithGlassEffect: Story = {
|
|
488
537
|
args: {
|
|
489
|
-
|
|
490
|
-
|
|
538
|
+
brand: 'Atomix',
|
|
539
|
+
brandDescription: 'A modern design system for building beautiful, accessible websites.',
|
|
540
|
+
copyright: '© 2024 Atomix. All rights reserved.',
|
|
541
|
+
socialLinks: sampleSocialLinks,
|
|
542
|
+
glass: true,
|
|
491
543
|
},
|
|
544
|
+
render: args => (
|
|
545
|
+
<Footer {...args}>
|
|
546
|
+
<SampleFooterContent />
|
|
547
|
+
</Footer>
|
|
548
|
+
),
|
|
492
549
|
parameters: {
|
|
493
550
|
docs: {
|
|
494
551
|
description: {
|
|
495
|
-
story:
|
|
496
|
-
'Sidebar layout with brand and newsletter in a left sidebar and content sections in the main area.',
|
|
552
|
+
story: 'Footer with glass effect enabled.',
|
|
497
553
|
},
|
|
498
554
|
},
|
|
499
555
|
},
|
|
500
556
|
};
|
|
501
557
|
|
|
502
|
-
export const
|
|
503
|
-
...LayoutTemplate,
|
|
558
|
+
export const StickyFooter: Story = {
|
|
504
559
|
args: {
|
|
505
|
-
|
|
506
|
-
|
|
560
|
+
sticky: true,
|
|
561
|
+
brand: 'Atomix',
|
|
562
|
+
brandDescription: 'A modern design system for building beautiful, accessible websites.',
|
|
563
|
+
copyright: '© 2024 Atomix. All rights reserved.',
|
|
564
|
+
socialLinks: sampleSocialLinks,
|
|
507
565
|
},
|
|
566
|
+
render: args => (
|
|
567
|
+
<div style={{ minHeight: '200vh' }}>
|
|
568
|
+
<div
|
|
569
|
+
style={{ height: '100vh', display: 'flex', alignItems: 'center', justifyContent: 'center' }}
|
|
570
|
+
>
|
|
571
|
+
<p>Scroll down to see the sticky footer</p>
|
|
572
|
+
</div>
|
|
573
|
+
<Footer {...args}>
|
|
574
|
+
<SampleFooterContent />
|
|
575
|
+
</Footer>
|
|
576
|
+
</div>
|
|
577
|
+
),
|
|
508
578
|
parameters: {
|
|
509
579
|
docs: {
|
|
510
580
|
description: {
|
|
511
|
-
story:
|
|
512
|
-
'Wide layout optimized for large screens with generous spacing and extended content areas.',
|
|
581
|
+
story: 'Sticky footer that stays at the bottom of the viewport.',
|
|
513
582
|
},
|
|
514
583
|
},
|
|
515
584
|
},
|