@faststore/core 2.0.121-alpha.0 → 2.0.123-alpha.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.
Files changed (91) hide show
  1. package/.turbo/turbo-build.log +15 -16
  2. package/CHANGELOG.md +12 -0
  3. package/package.json +4 -4
  4. package/src/components/cart/CartSidebar/CartSidebar.tsx +6 -2
  5. package/src/components/cart/CartSidebar/section.module.scss +21 -0
  6. package/src/components/cms/GlobalSections.tsx +6 -6
  7. package/src/components/common/Alert/Alert.tsx +8 -3
  8. package/src/components/common/Alert/section.module.scss +9 -0
  9. package/src/components/common/Footer/Footer.tsx +87 -89
  10. package/src/components/common/Footer/FooterLinks.tsx +4 -6
  11. package/src/components/common/Footer/section.module.scss +12 -0
  12. package/src/components/common/RegionBar/RegionBar.tsx +17 -0
  13. package/src/components/common/RegionBar/index.ts +1 -0
  14. package/src/components/common/RegionBar/section.module.scss +8 -0
  15. package/src/components/navigation/Navbar/Navbar.tsx +62 -61
  16. package/src/components/navigation/Navbar/section.module.scss +26 -0
  17. package/src/components/navigation/NavbarLinks/NavbarLinks.tsx +0 -1
  18. package/src/components/navigation/NavbarSlider/NavbarSlider.tsx +11 -7
  19. package/src/components/navigation/NavbarSlider/section.module.scss +26 -0
  20. package/src/components/product/ProductGrid/ProductGrid.tsx +2 -4
  21. package/src/components/region/RegionModal/RegionModal.tsx +6 -1
  22. package/src/components/region/RegionModal/section.module.scss +13 -0
  23. package/src/components/search/Filter/Filter.tsx +6 -3
  24. package/src/components/search/Filter/FilterSlider.tsx +5 -0
  25. package/src/components/search/Filter/section.module.scss +22 -0
  26. package/src/components/sections/BannerNewsletter/BannerNewsletter.tsx +5 -3
  27. package/src/components/sections/BannerNewsletter/section.module.scss +8 -0
  28. package/src/components/sections/BannerText/BannerText.tsx +4 -2
  29. package/src/components/sections/BannerText/section.module.scss +8 -0
  30. package/src/components/sections/Breadcrumb/Breadcrumb.tsx +4 -2
  31. package/src/components/sections/Breadcrumb/section.module.scss +9 -0
  32. package/src/components/sections/Hero/Hero.tsx +5 -9
  33. package/src/components/sections/Hero/section.module.scss +9 -0
  34. package/src/components/sections/{Incentives → IncentivesHeader}/IncentivesHeader.tsx +3 -2
  35. package/src/components/sections/IncentivesHeader/index.ts +1 -0
  36. package/src/components/sections/IncentivesHeader/section.module.scss +8 -0
  37. package/src/components/sections/Newsletter/Newsletter.tsx +68 -69
  38. package/src/components/sections/Newsletter/section.module.scss +11 -0
  39. package/src/components/sections/ProducDetailsContent/ProductDetailsContent.tsx +2 -4
  40. package/src/components/sections/ProductDetails/ProductDetails.tsx +44 -43
  41. package/src/components/sections/ProductDetails/section.module.scss +27 -0
  42. package/src/components/sections/ProductGallery/ProductGallery.tsx +121 -119
  43. package/src/components/sections/ProductGallery/section.module.scss +28 -0
  44. package/src/components/sections/ProductShelf/ProductShelf.tsx +8 -4
  45. package/src/components/sections/ProductShelf/section.module.scss +17 -0
  46. package/src/components/sections/ProductTiles/ProductTiles.tsx +9 -4
  47. package/src/components/sections/ProductTiles/section.module.scss +17 -0
  48. package/src/components/sections/ScrollToTopButton/ScrollToTopButton.tsx +3 -3
  49. package/src/components/sections/ScrollToTopButton/section.module.scss +11 -0
  50. package/src/components/skeletons/FilterSkeleton/FilterSkeleton.tsx +1 -2
  51. package/src/components/skeletons/ProductCardSkeleton/ProductCardSkeleton.tsx +0 -3
  52. package/src/components/skeletons/ProductShelfSkeleton/ProductShelfSkeleton.tsx +2 -2
  53. package/src/components/skeletons/ProductTilesSkeleton/ProductTileSkeleton/ProductTileSkeleton.tsx +0 -3
  54. package/src/components/ui/BannerText/BannerText.tsx +0 -3
  55. package/src/components/ui/Button/ButtonSignIn/ButtonSignIn.tsx +1 -2
  56. package/src/components/{sections → ui}/Incentives/Incentives.tsx +0 -3
  57. package/src/components/ui/Incentives/incentivesMock.ts +27 -0
  58. package/src/components/ui/Logo/Logo.tsx +1 -10
  59. package/src/components/ui/Tiles/Tiles.tsx +1 -6
  60. package/src/pages/[slug]/p.tsx +1 -1
  61. package/src/pages/_app.tsx +2 -2
  62. package/src/pages/index.tsx +2 -2
  63. package/src/styles/global/components.scss +8 -0
  64. package/src/styles/themes/midnight.scss +1 -1
  65. package/src/components/common/Footer/Footer.stories.mdx +0 -158
  66. package/src/components/common/Footer/footer.module.scss +0 -220
  67. package/src/components/sections/BannerNewsletter/banner-newsletter.module.scss +0 -23
  68. package/src/components/sections/Incentives/Incentives.stories.mdx +0 -159
  69. package/src/components/sections/Incentives/IncentivesFooter.tsx +0 -8
  70. package/src/components/sections/Incentives/incentives.module.scss +0 -122
  71. package/src/components/sections/Incentives/incentivesMock.ts +0 -55
  72. package/src/components/sections/Newsletter/Newsletter.stories.mdx +0 -139
  73. package/src/components/sections/Newsletter/newsletter.module.scss +0 -135
  74. package/src/components/sections/ProductDetails/product-details.module.scss +0 -185
  75. package/src/components/sections/ProductGallery/product-gallery.module.scss +0 -184
  76. package/src/components/sections/ScrollToTopButton/scroll-to-top-button.module.scss +0 -12
  77. package/src/components/skeletons/FilterSkeleton/FilterSkeleton.stories.mdx +0 -97
  78. package/src/components/skeletons/FilterSkeleton/filter-skeleton.module.scss +0 -51
  79. package/src/components/skeletons/ProductCardSkeleton/ProductCardSkeleton.stories.mdx +0 -113
  80. package/src/components/skeletons/ProductCardSkeleton/product-card-skeleton.module.scss +0 -58
  81. package/src/components/skeletons/ProductTilesSkeleton/ProductTileSkeleton/product-tile-skeleton.module.scss +0 -81
  82. package/src/components/ui/BannerText/BannerText.stories.mdx +0 -270
  83. package/src/components/ui/BannerText/banner-text.module.scss +0 -127
  84. package/src/components/ui/Button/Button.stories.mdx +0 -643
  85. package/src/components/ui/Button/button.module.scss +0 -11
  86. package/src/components/ui/Carousel/Carousel.stories.mdx +0 -201
  87. package/src/components/ui/Carousel/carousel.module.scss +0 -147
  88. package/src/components/ui/Logo/logo.module.scss +0 -12
  89. package/src/components/ui/Tiles/Tiles.stories.mdx +0 -151
  90. package/src/components/ui/Tiles/tiles.module.scss +0 -58
  91. /package/src/components/{sections → ui}/Incentives/index.ts +0 -0
@@ -1,81 +0,0 @@
1
- @import "src/styles/scaffold";
2
-
3
- .fs-product-tile-skeleton {
4
- // --------------------------------------------------------
5
- // Design Tokens for Product Tile Skeleton
6
- // --------------------------------------------------------
7
-
8
- // Default properties
9
- --fs-product-tile-skeleton-gap : var(--fs-spacing-1);
10
-
11
- // Content
12
- --fs-product-tile-skeleton-content-padding : var(--fs-spacing-3);
13
-
14
- // Wide
15
- --fs-product-tile-skeleton-wide-padding : var(--fs-spacing-2) var(--fs-spacing-3) var(--fs-spacing-3);
16
- --fs-product-tile-skeleton-wide-bkg-color : var(--fs-color-neutral-bkg);
17
-
18
- // --------------------------------------------------------
19
- // Structural Styles
20
- // --------------------------------------------------------
21
-
22
- position: relative;
23
- display: flex;
24
- flex-direction: column;
25
- width: 100%;
26
- height: 100%;
27
- padding: 0;
28
- overflow: hidden;
29
-
30
- @include media(">=tablet") {
31
- display: grid;
32
- grid-auto-rows: 62% auto;
33
- [data-fs-product-card-image] { height: 100%; }
34
- }
35
-
36
- @include media(">=notebook") { grid-auto-rows: 80% auto; }
37
-
38
- [data-fs-product-tile-skeleton-content] {
39
- display: flex;
40
- flex-direction: column;
41
- row-gap: var(--fs-product-tile-skeleton-gap);
42
- padding: var(--fs-product-tile-skeleton-content-padding);
43
- background-color: var(--fs-product-tile-skeleton-wide-bkg-color);
44
-
45
- @include media(">=notebook") {
46
- flex-direction: row;
47
- justify-content: space-between;
48
- height: 100%;
49
- }
50
- }
51
-
52
- [data-fs-product-tile-skeleton-heading] {
53
- display: flex;
54
- flex-direction: column;
55
- row-gap: var(--fs-product-tile-skeleton-gap);
56
- width: 100%;
57
- }
58
-
59
- [data-fs-product-tile-skeleton-badge] {
60
- max-width: 100%;
61
- }
62
-
63
- [data-fs-product-tile-skeleton-image] {
64
- width: 100%;
65
- aspect-ratio: var(--fs-product-tile-skeleton-image-aspect-ratio);
66
- overflow: hidden;
67
-
68
- [data-fs-skeleton-variant="image"] { border-radius: 0; }
69
-
70
- @include media(">=tablet") { height: 100%; }
71
- }
72
-
73
- [data-fs-product-tile-skeleton-image],
74
- [data-fs-product-tile-skeleton-badge] {
75
- [data-fs-skeleton-wrapper],
76
- [data-fs-skeleton] {
77
- width: 100%;
78
- height: 100%;
79
- }
80
- }
81
- }
@@ -1,270 +0,0 @@
1
- import { ArgsTable, Canvas, Meta, Story } from '@storybook/addon-docs'
2
-
3
- import BannerText from '.'
4
-
5
- import { TokenTable, TokenRow } from 'src/../.storybook/components'
6
-
7
- <Meta
8
- title="Organisms/BannerText"
9
- argTypes={{
10
- actionPath: { table: { disable: true } },
11
- }}
12
- component={BannerText}
13
- />
14
-
15
- export const Template = (args) => <BannerText {...args} />
16
-
17
- <header>
18
-
19
- # Banner Text
20
-
21
- Banners are used for advertising brands, products, and/or collections. They comprise a title, some description (only available for the `Secondary` variation), and a call-to-action button.
22
-
23
- </header>
24
-
25
- ## Overview
26
-
27
- The `BannerText` component uses [FastStore UI Banner](https://www.faststore.dev/reference/ui/molecules/Banner) as base.
28
-
29
- ---
30
-
31
- ## Usage
32
-
33
- `import BannerText from 'src/components/sections/BannerText'`
34
-
35
- <Canvas>
36
- <Story
37
- name="BannerText"
38
- args={{
39
- title:
40
- "The sun has set on our Summer Sale! Save up to 50% off. Don't miss out!",
41
- actionPath: '/',
42
- actionLabel: 'Call to action',
43
- colorVariant: 'accent',
44
- }}
45
- >
46
- {Template.bind({})}
47
- </Story>
48
- </Canvas>
49
-
50
- <ArgsTable story="BannerText" />
51
-
52
- <TokenTable>
53
- <TokenRow token="--fs-banner-padding-mobile" value="var(--fs-spacing-6) 5%" />
54
- <TokenRow
55
- token="--fs-banner-padding-desktop"
56
- value="var(--fs-spacing-9) 15%"
57
- />
58
- </TokenTable>
59
-
60
- ## Nested Elements
61
-
62
- ### Link
63
-
64
- <TokenTable>
65
- <TokenRow token="--fs-banner-link-min-width" value="11.25rem" />
66
- <TokenRow token="--fs-banner-link-margin-top" value="var(--fs-spacing-6)" />
67
- </TokenTable>
68
-
69
- ### Title
70
-
71
- <TokenTable>
72
- <TokenRow token="--fs-banner-title-size" value="var(--fs-text-size-lead)" />
73
- <TokenRow
74
- token="--fs-banner-title-weight"
75
- value="var(--fs-text-weight-bold)"
76
- />
77
- <TokenRow token="--fs-banner-title-line-height" value="1.2" />
78
- </TokenTable>
79
-
80
- ---
81
-
82
- ## Hierarchy
83
-
84
- ### Primary
85
-
86
- <Canvas>
87
- <Story
88
- name="Primary"
89
- args={{
90
- title:
91
- "The sun has set on our Summer Sale! Save up to 50% off. Don't miss out!",
92
- actionPath: '/',
93
- actionLabel: 'Call to action',
94
- }}
95
- >
96
- {Template.bind({})}
97
- </Story>
98
- </Canvas>
99
-
100
- <TokenTable>
101
- <TokenRow
102
- token="--fs-banner-primary-title-size"
103
- value="var(--fs-text-size-title-page)"
104
- />
105
- </TokenTable>
106
-
107
- ### Secondary
108
-
109
- <Canvas>
110
- <Story
111
- name="Secondary"
112
- args={{
113
- variant: 'secondary',
114
- title: 'The sun has set on our Summer Sale!',
115
- caption: "Save up to 50% off. Don't miss out!",
116
- actionPath: '/',
117
- actionLabel: 'Call to action',
118
- colorVariant: 'main',
119
- }}
120
- >
121
- {Template.bind({})}
122
- </Story>
123
- </Canvas>
124
-
125
- <TokenTable>
126
- <TokenRow
127
- token="--fs-banner-secondary-title-size"
128
- value="var(--fs-text-size-4)"
129
- />
130
- <TokenRow
131
- token="--fs-banner-secondary-caption-size"
132
- value="var(--fs-text-size-base)"
133
- />
134
- <TokenRow
135
- token="--fs-banner-secondary-caption-weight"
136
- value="var(--fs-text-weight-regular)"
137
- />
138
- <TokenRow token="--fs-banner-secondary-line-height" value="1.5" />
139
- </TokenTable>
140
-
141
- ---
142
-
143
- ## Variants
144
-
145
- ### Main
146
-
147
- <Canvas isColumn>
148
- <Story
149
- name="Main"
150
- args={{
151
- title: 'The sun has set on our Summer Sale!',
152
- caption: "Save up to 50% off. Don't miss out!",
153
- actionPath: '/',
154
- actionLabel: 'Call to action',
155
- }}
156
- >
157
- {Template.bind({})}
158
- </Story>
159
- <Story
160
- name="Secondary Main"
161
- args={{
162
- variant: 'secondary',
163
- title: 'The sun has set on our Summer Sale!',
164
- caption: "Save up to 50% off. Don't miss out!",
165
- actionPath: '/',
166
- actionLabel: 'Call to action',
167
- }}
168
- >
169
- {Template.bind({})}
170
- </Story>
171
- </Canvas>
172
-
173
- <TokenTable>
174
- <TokenRow
175
- token="--fs-banner-main-bkg-color"
176
- value="var(--fs-color-primary-bkg)"
177
- isColor
178
- />
179
- <TokenRow
180
- token="--fs-banner-main-text-color"
181
- value="var(--fs-color-primary-text)"
182
- isColor
183
- />
184
- </TokenTable>
185
-
186
- ### Light
187
-
188
- <Canvas isColumn>
189
- <Story
190
- name="Light"
191
- args={{
192
- title: 'The sun has set on our Summer Sale!',
193
- caption: "Save up to 50% off. Don't miss out!",
194
- actionPath: '/',
195
- actionLabel: 'Call to action',
196
- colorVariant: 'light',
197
- }}
198
- >
199
- {Template.bind({})}
200
- </Story>
201
- <Story
202
- name="Secondary Light"
203
- args={{
204
- variant: 'secondary',
205
- title: 'The sun has set on our Summer Sale!',
206
- caption: "Save up to 50% off. Don't miss out!",
207
- actionPath: '/',
208
- actionLabel: 'Call to action',
209
- colorVariant: 'light',
210
- }}
211
- >
212
- {Template.bind({})}
213
- </Story>
214
- </Canvas>
215
-
216
- <TokenTable>
217
- <TokenRow
218
- token="--fs-banner-light-bkg-color"
219
- value="var(--fs-color-secondary-bkg-light)"
220
- isColor
221
- />
222
- <TokenRow
223
- token="--fs-banner-light-text-color"
224
- value="var(--fs-color-text-display)"
225
- isColor
226
- />
227
- </TokenTable>
228
-
229
- ### Accent
230
-
231
- <Canvas isColumn>
232
- <Story
233
- name="Accent"
234
- args={{
235
- title: 'The sun has set on our Summer Sale!',
236
- caption: "Save up to 50% off. Don't miss out!",
237
- actionPath: '/',
238
- actionLabel: 'Call to action',
239
- colorVariant: 'accent',
240
- }}
241
- >
242
- {Template.bind({})}
243
- </Story>
244
- <Story
245
- name="Secondary Accent"
246
- args={{
247
- variant: 'secondary',
248
- title: 'The sun has set on our Summer Sale!',
249
- caption: "Save up to 50% off. Don't miss out!",
250
- actionPath: '/',
251
- actionLabel: 'Call to action',
252
- colorVariant: 'accent',
253
- }}
254
- >
255
- {Template.bind({})}
256
- </Story>
257
- </Canvas>
258
-
259
- <TokenTable>
260
- <TokenRow
261
- token="--fs-banner-accent-bkg-color"
262
- value="var(--fs-color-highlighted-bkg)"
263
- isColor
264
- />
265
- <TokenRow
266
- token="--fs-banner-accent-text-color"
267
- value="var(--fs-banner-light-text-color)"
268
- isColor
269
- />
270
- </TokenTable>
@@ -1,127 +0,0 @@
1
- @import "src/styles/scaffold";
2
-
3
- .fs-banner-text {
4
- // --------------------------------------------------------
5
- // Design Tokens for Banner Text
6
- // --------------------------------------------------------
7
-
8
- // Default properties
9
- --fs-banner-padding-mobile : var(--fs-spacing-6) 5%;
10
- --fs-banner-padding-desktop : var(--fs-spacing-9) 15%;
11
-
12
- // Button Link
13
- --fs-banner-button-link-min-width : 11.25rem;
14
- --fs-banner-button-link-margin-top : var(--fs-spacing-6);
15
-
16
- // Title
17
- --fs-banner-title-size : var(--fs-text-size-lead);
18
- --fs-banner-title-weight : var(--fs-text-weight-bold);
19
- --fs-banner-title-line-height : 1.2;
20
-
21
- // Primary
22
- --fs-banner-primary-title-size : var(--fs-text-size-title-page);
23
-
24
- // Secondary
25
- --fs-banner-secondary-title-size : var(--fs-text-size-4);
26
- --fs-banner-secondary-caption-size : var(--fs-text-size-base);
27
- --fs-banner-secondary-caption-weight : var(--fs-text-weight-regular);
28
- --fs-banner-secondary-caption-line-height : 1.5;
29
-
30
- // Main
31
- --fs-banner-main-bkg-color : var(--fs-color-primary-bkg);
32
- --fs-banner-main-text-color : var(--fs-color-primary-text);
33
-
34
- // Light
35
- --fs-banner-light-bkg-color : var(--fs-color-secondary-bkg-light);
36
- --fs-banner-light-text-color : var(--fs-color-text-display);
37
-
38
- // Accent
39
- --fs-banner-accent-bkg-color : var(--fs-color-highlighted-bkg);
40
- --fs-banner-accent-text-color : var(--fs-banner-light-text-color);
41
-
42
- // --------------------------------------------------------
43
- // Structural Styles
44
- // --------------------------------------------------------
45
-
46
- height: 100%;
47
- padding: var(--fs-banner-padding-mobile);
48
- text-align: center;
49
-
50
- @include media(">=notebook") {
51
- padding: var(--fs-banner-padding-desktop);
52
- }
53
-
54
- [data-fs-banner-text-content] {
55
- display: flex;
56
- flex-direction: column;
57
- align-items: center;
58
- justify-content: center;
59
- height: 100%;
60
- }
61
-
62
- [data-fs-banner-text-link] [data-fs-link-button] {
63
- min-width: var(--fs-banner-button-link-min-width);
64
- margin-top: var(--fs-banner-button-link-margin-top);
65
- }
66
-
67
- // --------------------------------------------------------
68
- // Variants Styles
69
- // --------------------------------------------------------
70
-
71
- &[data-fs-banner-text-variant="primary"] {
72
- h2 {
73
- font-size: var(--fs-banner-title-size);
74
- font-weight: var(--fs-banner-title-weight);
75
- line-height: var(--fs-banner-title-line-height);
76
-
77
- @include media(">=notebook") {
78
- display: block;
79
- font-size: var(--fs-banner-primary-title-size);
80
- }
81
- }
82
- }
83
-
84
- &[data-fs-banner-text-variant="secondary"] {
85
- h2 {
86
- margin-bottom: var(--fs-spacing-2);
87
- font-size: var(--fs-banner-title-size);
88
- font-weight: var(--fs-banner-title-weight);
89
- line-height: var(--fs-banner-title-line-height);
90
-
91
- @include media(">=notebook") {
92
- display: block;
93
- font-size: var(--fs-banner-secondary-title-size);
94
- }
95
- }
96
-
97
- p {
98
- font-size: var(--fs-banner-secondary-caption-size);
99
- font-weight: var(--fs-banner-secondary-caption-weight);
100
- line-height: var(--fs-banner-secondary-caption-line-height);
101
- }
102
- }
103
-
104
- &[data-fs-banner-text-color-variant="main"] {
105
- background-color: var(--fs-banner-main-bkg-color);
106
-
107
- [data-fs-banner-text-heading] {
108
- color: var(--fs-banner-main-text-color);
109
- }
110
- }
111
-
112
- &[data-fs-banner-text-color-variant="light"] {
113
- background-color: var(--fs-banner-light-bkg-color);
114
-
115
- [data-fs-banner-text-heading] {
116
- color: var(--fs-banner-light-text-color);
117
- }
118
- }
119
-
120
- &[data-fs-banner-text-color-variant="accent"] {
121
- background-color: var(--fs-banner-accent-bkg-color);
122
-
123
- [data-fs-banner-text-heading] {
124
- color: var(--fs-banner-accent-text-color);
125
- }
126
- }
127
- }