@faststore/core 2.0.121-alpha.0 → 2.0.122-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 (247) hide show
  1. package/.next/BUILD_ID +1 -0
  2. package/.next/build-manifest.json +120 -0
  3. package/.next/cache/.tsbuildinfo +1 -0
  4. package/.next/cache/config.json +7 -0
  5. package/.next/cache/eslint/.cache_1gneedd +1 -0
  6. package/.next/cache/next-server.js.nft.json +1 -0
  7. package/.next/cache/webpack/client-production/0.pack +0 -0
  8. package/.next/cache/webpack/client-production/index.pack +0 -0
  9. package/.next/cache/webpack/server-production/0.pack +0 -0
  10. package/.next/cache/webpack/server-production/index.pack +0 -0
  11. package/.next/export-marker.json +1 -0
  12. package/.next/images-manifest.json +1 -0
  13. package/.next/next-server.js.nft.json +1 -0
  14. package/.next/package.json +1 -0
  15. package/.next/prerender-manifest.json +1 -0
  16. package/.next/react-loadable-manifest.json +52 -0
  17. package/.next/required-server-files.json +1 -0
  18. package/.next/routes-manifest.json +1 -0
  19. package/.next/server/chunks/104.js +255 -0
  20. package/.next/server/chunks/120.js +435 -0
  21. package/.next/server/chunks/123.js +58 -0
  22. package/.next/server/chunks/143.js +106 -0
  23. package/.next/server/chunks/154.js +206 -0
  24. package/.next/server/chunks/183.js +80 -0
  25. package/.next/server/chunks/247.js +61 -0
  26. package/.next/server/chunks/254.js +159 -0
  27. package/.next/server/chunks/256.js +1787 -0
  28. package/.next/server/chunks/280.js +322 -0
  29. package/.next/server/chunks/287.js +58 -0
  30. package/.next/server/chunks/312.js +674 -0
  31. package/.next/server/chunks/336.js +820 -0
  32. package/.next/server/chunks/350.js +142 -0
  33. package/.next/server/chunks/398.js +132 -0
  34. package/.next/server/chunks/401.js +7241 -0
  35. package/.next/server/chunks/431.js +7241 -0
  36. package/.next/server/chunks/502.js +603 -0
  37. package/.next/server/chunks/554.js +264 -0
  38. package/.next/server/chunks/557.js +135 -0
  39. package/.next/server/chunks/576.js +80 -0
  40. package/.next/server/chunks/597.js +169 -0
  41. package/.next/server/chunks/608.js +515 -0
  42. package/.next/server/chunks/664.js +3401 -0
  43. package/.next/server/chunks/676.js +32 -0
  44. package/.next/server/chunks/74.js +2606 -0
  45. package/.next/server/chunks/746.js +249 -0
  46. package/.next/server/chunks/82.js +371 -0
  47. package/.next/server/chunks/854.js +72 -0
  48. package/.next/server/chunks/859.js +959 -0
  49. package/.next/server/chunks/872.js +358 -0
  50. package/.next/server/chunks/886.js +120 -0
  51. package/.next/server/chunks/98.js +124 -0
  52. package/.next/server/chunks/font-manifest.json +1 -0
  53. package/.next/server/font-manifest.json +1 -0
  54. package/.next/server/middleware-build-manifest.js +1 -0
  55. package/.next/server/middleware-manifest.json +6 -0
  56. package/.next/server/middleware-react-loadable-manifest.js +1 -0
  57. package/.next/server/pages/404.js +414 -0
  58. package/.next/server/pages/404.js.nft.json +1 -0
  59. package/.next/server/pages/500.js +384 -0
  60. package/.next/server/pages/500.js.nft.json +1 -0
  61. package/.next/server/pages/[...slug].js +700 -0
  62. package/.next/server/pages/[...slug].js.nft.json +1 -0
  63. package/.next/server/pages/[slug]/p.js +2338 -0
  64. package/.next/server/pages/[slug]/p.js.nft.json +1 -0
  65. package/.next/server/pages/_app.js +368 -0
  66. package/.next/server/pages/_app.js.nft.json +1 -0
  67. package/.next/server/pages/_document.js +304 -0
  68. package/.next/server/pages/_document.js.nft.json +1 -0
  69. package/.next/server/pages/_error.js +164 -0
  70. package/.next/server/pages/_error.js.nft.json +1 -0
  71. package/.next/server/pages/account.js +370 -0
  72. package/.next/server/pages/account.js.nft.json +1 -0
  73. package/.next/server/pages/api/graphql.js +315 -0
  74. package/.next/server/pages/api/graphql.js.nft.json +1 -0
  75. package/.next/server/pages/api/preview.js +118 -0
  76. package/.next/server/pages/api/preview.js.nft.json +1 -0
  77. package/.next/server/pages/checkout.js +370 -0
  78. package/.next/server/pages/checkout.js.nft.json +1 -0
  79. package/.next/server/pages/en-US/404.html +81 -0
  80. package/.next/server/pages/en-US/404.json +1 -0
  81. package/.next/server/pages/en-US/500.html +81 -0
  82. package/.next/server/pages/en-US/500.json +1 -0
  83. package/.next/server/pages/en-US/account.html +81 -0
  84. package/.next/server/pages/en-US/account.json +1 -0
  85. package/.next/server/pages/en-US/checkout.html +81 -0
  86. package/.next/server/pages/en-US/checkout.json +1 -0
  87. package/.next/server/pages/en-US/login.html +81 -0
  88. package/.next/server/pages/en-US/login.json +1 -0
  89. package/.next/server/pages/en-US/s.html +81 -0
  90. package/.next/server/pages/en-US/s.json +1 -0
  91. package/.next/server/pages/en-US.html +81 -0
  92. package/.next/server/pages/en-US.json +1 -0
  93. package/.next/server/pages/index.js +580 -0
  94. package/.next/server/pages/index.js.nft.json +1 -0
  95. package/.next/server/pages/login.js +396 -0
  96. package/.next/server/pages/login.js.nft.json +1 -0
  97. package/.next/server/pages/s.js +438 -0
  98. package/.next/server/pages/s.js.nft.json +1 -0
  99. package/.next/server/pages-manifest.json +16 -0
  100. package/.next/server/webpack-api-runtime.js +229 -0
  101. package/.next/server/webpack-runtime.js +229 -0
  102. package/.next/static/chunks/143.dd8a556e6957baa1.js +1 -0
  103. package/.next/static/chunks/170.b45293edb4f089c8.js +1 -0
  104. package/.next/static/chunks/226.b57e10ad9932f88c.js +1 -0
  105. package/.next/static/chunks/336.84e96cd7aa2412bc.js +1 -0
  106. package/.next/static/chunks/419-274b5b8beee8c7b2.js +1 -0
  107. package/.next/static/chunks/495.e6b60941cc3e82e4.js +1 -0
  108. package/.next/static/chunks/54.1d3e6cb43b5b1626.js +1 -0
  109. package/.next/static/chunks/597.d0da2018cc312352.js +1 -0
  110. package/.next/static/chunks/608.59e69b83f35d9c44.js +1 -0
  111. package/.next/static/chunks/651.7142f31ce1e052b3.js +1 -0
  112. package/.next/static/chunks/706-abfba2e18f084aed.js +1 -0
  113. package/.next/static/chunks/741.52f7fb873418346f.js +1 -0
  114. package/.next/static/chunks/832-99f4667bdaf092f8.js +1 -0
  115. package/.next/static/chunks/861-d1a326525092ab9c.js +1 -0
  116. package/.next/static/chunks/98.97381d2021f86cd9.js +1 -0
  117. package/.next/static/chunks/framework-dfd14d7ce6600b03.js +1 -0
  118. package/.next/static/chunks/main-9746772201fe3ac1.js +1 -0
  119. package/.next/static/chunks/pages/404-ac22e12eb22b9c50.js +1 -0
  120. package/.next/static/chunks/pages/500-7b708e8b89389d0e.js +1 -0
  121. package/.next/static/chunks/pages/[...slug]-3aaeeabdb9564d0f.js +1 -0
  122. package/.next/static/chunks/pages/[slug]/p-b269ba68926617dd.js +1 -0
  123. package/.next/static/chunks/pages/_app-b601536188b9a919.js +1 -0
  124. package/.next/static/chunks/pages/_error-a7a0c1d9bfbb4f38.js +1 -0
  125. package/.next/static/chunks/pages/account-04a0a6c07709c50e.js +1 -0
  126. package/.next/static/chunks/pages/checkout-2ed6b828bb6ed7e6.js +1 -0
  127. package/.next/static/chunks/pages/index-c2b6dfd205dc6cc2.js +1 -0
  128. package/.next/static/chunks/pages/login-3bb40d77e6ee120a.js +1 -0
  129. package/.next/static/chunks/pages/s-8fec20c40a2bd7da.js +1 -0
  130. package/.next/static/chunks/polyfills-c67a75d1b6f99dc8.js +1 -0
  131. package/.next/static/chunks/webpack-426a37879992164d.js +1 -0
  132. package/.next/static/css/025f924b9633ecd3.css +1 -0
  133. package/.next/static/css/2253644409b99b98.css +1 -0
  134. package/.next/static/css/364c439adafef5c8.css +1 -0
  135. package/.next/static/css/4b7b7b64ae6afe67.css +1 -0
  136. package/.next/static/css/4e0fc649e912b30f.css +1 -0
  137. package/.next/static/css/501cb58eaa378545.css +1 -0
  138. package/.next/static/css/587c27bbda64e700.css +1 -0
  139. package/.next/static/css/5f1b35b69b2ba1f7.css +1 -0
  140. package/.next/static/css/7a8417de90d11c60.css +1 -0
  141. package/.next/static/css/7df2581c69fe96b4.css +1 -0
  142. package/.next/static/media/brandless-neutral.76ddf63a.png +0 -0
  143. package/.next/static/z81uKE37lBbYBn8W-39Mb/_buildManifest.js +1 -0
  144. package/.next/static/z81uKE37lBbYBn8W-39Mb/_ssgManifest.js +1 -0
  145. package/.next/trace +65 -0
  146. package/.turbo/turbo-build.log +15 -16
  147. package/CHANGELOG.md +6 -0
  148. package/package.json +4 -4
  149. package/public/~partytown/debug/partytown-atomics.js +556 -0
  150. package/public/~partytown/debug/partytown-media.js +374 -0
  151. package/public/~partytown/debug/partytown-sandbox-sw.js +543 -0
  152. package/public/~partytown/debug/partytown-sw.js +59 -0
  153. package/public/~partytown/debug/partytown-ww-atomics.js +1789 -0
  154. package/public/~partytown/debug/partytown-ww-sw.js +1781 -0
  155. package/public/~partytown/debug/partytown.js +72 -0
  156. package/public/~partytown/partytown-atomics.js +2 -0
  157. package/public/~partytown/partytown-media.js +2 -0
  158. package/public/~partytown/partytown-sw.js +2 -0
  159. package/public/~partytown/partytown.js +2 -0
  160. package/src/components/cart/CartSidebar/CartSidebar.tsx +6 -2
  161. package/src/components/cart/CartSidebar/section.module.scss +21 -0
  162. package/src/components/cms/GlobalSections.tsx +6 -6
  163. package/src/components/common/Alert/Alert.tsx +8 -3
  164. package/src/components/common/Alert/section.module.scss +9 -0
  165. package/src/components/common/Footer/Footer.tsx +87 -89
  166. package/src/components/common/Footer/FooterLinks.tsx +4 -6
  167. package/src/components/common/Footer/section.module.scss +12 -0
  168. package/src/components/common/RegionBar/RegionBar.tsx +17 -0
  169. package/src/components/common/RegionBar/index.ts +1 -0
  170. package/src/components/common/RegionBar/section.module.scss +8 -0
  171. package/src/components/navigation/Navbar/Navbar.tsx +62 -61
  172. package/src/components/navigation/Navbar/section.module.scss +26 -0
  173. package/src/components/navigation/NavbarLinks/NavbarLinks.tsx +0 -1
  174. package/src/components/navigation/NavbarSlider/NavbarSlider.tsx +11 -7
  175. package/src/components/navigation/NavbarSlider/section.module.scss +26 -0
  176. package/src/components/product/ProductGrid/ProductGrid.tsx +2 -4
  177. package/src/components/region/RegionModal/RegionModal.tsx +6 -1
  178. package/src/components/region/RegionModal/section.module.scss +13 -0
  179. package/src/components/search/Filter/Filter.tsx +6 -3
  180. package/src/components/search/Filter/FilterSlider.tsx +5 -0
  181. package/src/components/search/Filter/section.module.scss +22 -0
  182. package/src/components/sections/BannerNewsletter/BannerNewsletter.tsx +5 -3
  183. package/src/components/sections/BannerNewsletter/section.module.scss +8 -0
  184. package/src/components/sections/BannerText/BannerText.tsx +4 -2
  185. package/src/components/sections/BannerText/section.module.scss +8 -0
  186. package/src/components/sections/Breadcrumb/Breadcrumb.tsx +4 -2
  187. package/src/components/sections/Breadcrumb/section.module.scss +9 -0
  188. package/src/components/sections/Hero/Hero.tsx +5 -9
  189. package/src/components/sections/Hero/section.module.scss +9 -0
  190. package/src/components/sections/{Incentives → IncentivesHeader}/IncentivesHeader.tsx +3 -2
  191. package/src/components/sections/IncentivesHeader/index.ts +1 -0
  192. package/src/components/sections/IncentivesHeader/section.module.scss +8 -0
  193. package/src/components/sections/Newsletter/Newsletter.tsx +68 -69
  194. package/src/components/sections/Newsletter/section.module.scss +11 -0
  195. package/src/components/sections/ProducDetailsContent/ProductDetailsContent.tsx +2 -4
  196. package/src/components/sections/ProductDetails/ProductDetails.tsx +44 -43
  197. package/src/components/sections/ProductDetails/section.module.scss +27 -0
  198. package/src/components/sections/ProductGallery/ProductGallery.tsx +121 -119
  199. package/src/components/sections/ProductGallery/section.module.scss +28 -0
  200. package/src/components/sections/ProductShelf/ProductShelf.tsx +8 -4
  201. package/src/components/sections/ProductShelf/section.module.scss +17 -0
  202. package/src/components/sections/ProductTiles/ProductTiles.tsx +9 -4
  203. package/src/components/sections/ProductTiles/section.module.scss +17 -0
  204. package/src/components/sections/ScrollToTopButton/ScrollToTopButton.tsx +3 -3
  205. package/src/components/sections/ScrollToTopButton/section.module.scss +11 -0
  206. package/src/components/skeletons/FilterSkeleton/FilterSkeleton.tsx +1 -2
  207. package/src/components/skeletons/ProductCardSkeleton/ProductCardSkeleton.tsx +0 -3
  208. package/src/components/skeletons/ProductShelfSkeleton/ProductShelfSkeleton.tsx +2 -2
  209. package/src/components/skeletons/ProductTilesSkeleton/ProductTileSkeleton/ProductTileSkeleton.tsx +0 -3
  210. package/src/components/ui/BannerText/BannerText.tsx +0 -3
  211. package/src/components/ui/Button/ButtonSignIn/ButtonSignIn.tsx +1 -2
  212. package/src/components/{sections → ui}/Incentives/Incentives.tsx +0 -3
  213. package/src/components/ui/Incentives/incentivesMock.ts +27 -0
  214. package/src/components/ui/Logo/Logo.tsx +1 -10
  215. package/src/components/ui/Tiles/Tiles.tsx +1 -6
  216. package/src/pages/[slug]/p.tsx +1 -1
  217. package/src/pages/_app.tsx +2 -2
  218. package/src/pages/index.tsx +2 -2
  219. package/src/styles/global/components.scss +8 -0
  220. package/src/styles/themes/midnight.scss +1 -1
  221. package/src/components/common/Footer/Footer.stories.mdx +0 -158
  222. package/src/components/common/Footer/footer.module.scss +0 -220
  223. package/src/components/sections/BannerNewsletter/banner-newsletter.module.scss +0 -23
  224. package/src/components/sections/Incentives/Incentives.stories.mdx +0 -159
  225. package/src/components/sections/Incentives/IncentivesFooter.tsx +0 -8
  226. package/src/components/sections/Incentives/incentives.module.scss +0 -122
  227. package/src/components/sections/Incentives/incentivesMock.ts +0 -55
  228. package/src/components/sections/Newsletter/Newsletter.stories.mdx +0 -139
  229. package/src/components/sections/Newsletter/newsletter.module.scss +0 -135
  230. package/src/components/sections/ProductDetails/product-details.module.scss +0 -185
  231. package/src/components/sections/ProductGallery/product-gallery.module.scss +0 -184
  232. package/src/components/sections/ScrollToTopButton/scroll-to-top-button.module.scss +0 -12
  233. package/src/components/skeletons/FilterSkeleton/FilterSkeleton.stories.mdx +0 -97
  234. package/src/components/skeletons/FilterSkeleton/filter-skeleton.module.scss +0 -51
  235. package/src/components/skeletons/ProductCardSkeleton/ProductCardSkeleton.stories.mdx +0 -113
  236. package/src/components/skeletons/ProductCardSkeleton/product-card-skeleton.module.scss +0 -58
  237. package/src/components/skeletons/ProductTilesSkeleton/ProductTileSkeleton/product-tile-skeleton.module.scss +0 -81
  238. package/src/components/ui/BannerText/BannerText.stories.mdx +0 -270
  239. package/src/components/ui/BannerText/banner-text.module.scss +0 -127
  240. package/src/components/ui/Button/Button.stories.mdx +0 -643
  241. package/src/components/ui/Button/button.module.scss +0 -11
  242. package/src/components/ui/Carousel/Carousel.stories.mdx +0 -201
  243. package/src/components/ui/Carousel/carousel.module.scss +0 -147
  244. package/src/components/ui/Logo/logo.module.scss +0 -12
  245. package/src/components/ui/Tiles/Tiles.stories.mdx +0 -151
  246. package/src/components/ui/Tiles/tiles.module.scss +0 -58
  247. /package/src/components/{sections → ui}/Incentives/index.ts +0 -0
@@ -1,643 +0,0 @@
1
- import { ArgsTable, Canvas, Meta, Story } from '@storybook/addon-docs'
2
-
3
- import { Button, BuyButton, LinkButton } from '@faststore/ui'
4
- import Icon from 'src/components/ui/Icon'
5
-
6
- import {
7
- TokenTable,
8
- TokenRow,
9
- TokenDivider,
10
- SectionList,
11
- SectionItem,
12
- BestPractices,
13
- BestPracticesRule,
14
- } from 'src/../.storybook/components'
15
-
16
- <Meta
17
- argTypes={{
18
- icon: { control: { disable: true } },
19
- }}
20
- component={Button}
21
- title="Atoms/Button"
22
- />
23
-
24
- export const Template = (args) => <Button {...args}>Button</Button>
25
- export const TemplateIcon = (args) => <Button {...args} />
26
-
27
- <header>
28
-
29
- # Button
30
-
31
- This component allows users to take actions, make choices or trigger an event with a single tap.
32
-
33
- </header>
34
-
35
- - [Overview](#overview)
36
- - [Usage](#usage)
37
- - [Nested Elements](#nested-elements)
38
- - [Hierarchy](#hierarchy)
39
- - [Variants](#variants)
40
- - [Related Components](#related-components)
41
-
42
- ## Overview <a id="overview" />
43
-
44
- The `Button` component uses [FastStore UI Button](https://www.faststore.dev/reference/ui/atoms/Button) as base.
45
-
46
- <Canvas>
47
- <Story name="Overview">
48
- <Button variant="primary">Primary Button</Button>
49
- <Button variant="secondary" style={{ marginLeft: 20 }}>
50
- Secondary Button
51
- </Button>
52
- <Button variant="tertiary" style={{ marginLeft: 20 }}>
53
- Tertiary Button
54
- </Button>
55
- </Story>
56
- </Canvas>
57
-
58
- ---
59
-
60
- ## Usage <a id="usage" />
61
-
62
- `import Button from 'src/components/ui/Button'`
63
-
64
- export const Usage = ({ inverse, ...args }) => {
65
- return inverse ? (
66
- <div style={{ marginBottom: 10, padding: 10, backgroundColor: '#171a1c' }}>
67
- <Button inverse {...args}>
68
- Button
69
- </Button>
70
- </div>
71
- ) : (
72
- <Button {...args}>Button</Button>
73
- )
74
- }
75
-
76
- <Canvas>
77
- <Story
78
- name="Button"
79
- args={{
80
- variant: 'primary',
81
- iconPosition: 'right',
82
- icon: <Icon name="ShoppingCart" width="18" height="18" weight="bold" />,
83
- }}
84
- >
85
- {Usage.bind({})}
86
- </Story>
87
- </Canvas>
88
-
89
- <ArgsTable story="Button" />
90
-
91
- <TokenTable>
92
- <TokenRow
93
- token="--fs-button-padding"
94
- value="calc(var(--fs-spacing-1) - (var(--fs-button-border-width) * 2)) var(--fs-spacing-3)"
95
- />
96
- <TokenRow token="--fs-button-height" value="var(--fs-control-tap-size)" />
97
- <TokenRow token="--fs-button-gap" value="var(--fs-spacing-2)" />
98
- <TokenDivider />
99
- <TokenRow token="--fs-button-shadow" value="var(--fs-shadow)" />
100
- <TokenRow token="--fs-button-shadow-hover" value="var(--fs-button-shadow)" />
101
- <TokenDivider />
102
- <TokenRow token="--fs-button-border-radius" value="var(--fs-border-radius)" />
103
- <TokenRow
104
- token="--fs-button-border-width"
105
- value="var(--fs-border-width-thick)"
106
- />
107
- <TokenRow token="--fs-button-border-color" value="transparent" isColor />
108
- <TokenDivider />
109
- <TokenRow token="--fs-button-text-size" value="var(--fs-text-size-base)" />
110
- <TokenRow
111
- token="--fs-button-text-weight"
112
- value="var(--fs-text-weight-bold)"
113
- />
114
- <TokenDivider />
115
- <TokenRow
116
- token="--fs-button-transition-function"
117
- value="var(--fs-transition-function)"
118
- />
119
- <TokenRow
120
- token="--fs-button-transition-property"
121
- value="var(--fs-transition-property)"
122
- />
123
- <TokenRow
124
- token="--fs-button-transition-timing"
125
- value="var(--fs-transition-timing)"
126
- />
127
- </TokenTable>
128
-
129
- ---
130
-
131
- ## Nested Elements <a id="nested-elements" />
132
-
133
- ### Icon
134
-
135
- <Canvas>
136
- <Story
137
- name="Icon"
138
- args={{
139
- variant: 'primary',
140
- iconPosition: 'right',
141
- icon: <Icon name="User" width="18" height="18" weight="bold" />,
142
- }}
143
- >
144
- {Template.bind({})}
145
- </Story>
146
- </Canvas>
147
-
148
- <TokenTable>
149
- <TokenRow token="--fs-button-icon-padding" value="0 var(--fs-spacing-1)" />
150
- </TokenTable>
151
-
152
- ---
153
-
154
- ## Hierarchy <a id="hierarchy" />
155
-
156
- ### Primary
157
-
158
- <Canvas>
159
- <Story name="Primary" args={{ variant: 'primary' }}>
160
- {Template.bind({})}
161
- </Story>
162
- </Canvas>
163
-
164
- <TokenTable>
165
- <TokenRow
166
- token="--fs-button-primary-text-color"
167
- value="var(--fs-color-primary-text)"
168
- isColor
169
- />
170
- <TokenRow
171
- token="--fs-button-primary-text-color-hover"
172
- value="var(--fs-button-primary-text-color)"
173
- isColor
174
- globalValue="var(--fs-color-primary-text)"
175
- />
176
- <TokenRow
177
- token="--fs-button-primary-text-color-active"
178
- value="var(--fs-button-primary-text-color)"
179
- isColor
180
- globalValue="var(--fs-color-primary-text)"
181
- />
182
- <TokenRow
183
- token="--fs-button-primary-bkg-color"
184
- value="var(--fs-color-primary-bkg)"
185
- isColor
186
- />
187
- <TokenRow
188
- token="--fs-button-primary-bkg-color-hover"
189
- value="var(--fs-color-primary-bkg-hover)"
190
- isColor
191
- />
192
- <TokenRow
193
- token="--fs-button-primary-bkg-color-active"
194
- value="var(--fs-color-primary-bkg-active)"
195
- isColor
196
- />
197
- <TokenRow
198
- token="--fs-button-primary-border-color"
199
- value="transparent"
200
- isColor
201
- />
202
- <TokenRow
203
- token="--fs-button-primary-border-color-hover"
204
- value="var(--fs-button-primary-border-color)"
205
- isColor
206
- />
207
- <TokenRow
208
- token="--fs-button-primary-border-color-active"
209
- value="var(--fs-button-primary-border-color)"
210
- isColor
211
- />
212
- <TokenRow
213
- token="--fs-button-primary-shadow-hover"
214
- value="var(--fs-button-shadow-hover)"
215
- />
216
- </TokenTable>
217
-
218
- ### Primary Inverse
219
-
220
- <Canvas style={{ backgroundColor: '#171a1c' }}>
221
- <Story name="Primary Inverse" args={{ inverse: true, variant: 'primary' }}>
222
- {Template.bind({})}
223
- </Story>
224
- </Canvas>
225
-
226
- <TokenTable>
227
- <TokenRow
228
- token="--fs-button-primary-inverse-text-color"
229
- value="var(--fs-button-primary-bkg-color)"
230
- isColor
231
- globalValue="var(--fs-color-primary-bkg)"
232
- />
233
- <TokenRow
234
- token="--fs-button-primary-inverse-text-color-hover"
235
- value="var(--fs-button-primary-bkg-color)"
236
- isColor
237
- globalValue="var(--fs-color-primary-bkg)"
238
- />
239
- <TokenRow
240
- token="--fs-button-primary-inverse-text-color-active"
241
- value="var(--fs-button-primary-bkg-color)"
242
- isColor
243
- globalValue="var(--fs-color-primary-bkg)"
244
- />
245
- <TokenRow
246
- token="--fs-button-primary-inverse-bkg-color"
247
- value="var(--fs-button-primary-text-color)"
248
- isColor
249
- globalValue="var(--fs-color-primary-text)"
250
- />
251
- <TokenRow
252
- token="--fs-button-primary-inverse-bkg-color-hover"
253
- value="var(--fs-color-primary-bkg-light)"
254
- isColor
255
- />
256
- <TokenRow
257
- token="--fs-button-primary-inverse-bkg-color-active"
258
- value="var(--fs-color-primary-bkg-light-active)"
259
- isColor
260
- />
261
- <TokenRow
262
- token="--fs-button-primary-inverse-border-color"
263
- value="var(--fs-button-primary-border-color)"
264
- isColor
265
- />
266
- <TokenRow
267
- token="--fs-button-primary-inverse-border-color-hover"
268
- value="var(--fs-button-primary-border-color)"
269
- isColor
270
- />
271
- <TokenRow
272
- token="--fs-button-primary-inverse-border-color-active"
273
- value="var(--fs-button-primary-border-color)"
274
- isColor
275
- />
276
- <TokenRow
277
- token="--fs-button-primary-inverse-shadow-hover"
278
- value="var(--fs-button-shadow-hover)"
279
- />
280
- </TokenTable>
281
-
282
- ### Secondary
283
-
284
- <Canvas>
285
- <Story name="Secondary" args={{ variant: 'secondary' }}>
286
- {Template.bind({})}
287
- </Story>
288
- </Canvas>
289
-
290
- <TokenTable>
291
- <TokenRow
292
- token="--fs-button-secondary-text-color"
293
- value="var(--fs-color-secondary-text)"
294
- isColor
295
- />
296
- <TokenRow
297
- token="--fs-button-secondary-text-color-hover"
298
- value="var(--fs-color-text-inverse)"
299
- isColor
300
- />
301
- <TokenRow
302
- token="--fs-button-secondary-text-color-active"
303
- value="var(--fs-button-secondary-text-color-hover)"
304
- isColor
305
- globalValue="var(--fs-color-text-inverse)"
306
- />
307
- <TokenRow
308
- token="--fs-button-secondary-bkg-color"
309
- value="var(--fs-color-secondary-bkg)"
310
- isColor
311
- />
312
- <TokenRow
313
- token="--fs-button-secondary-bkg-color-hover"
314
- value="var(--fs-color-secondary-bkg-hover)"
315
- isColor
316
- />
317
- <TokenRow
318
- token="--fs-button-secondary-bkg-color-active"
319
- value="var(--fs-color-secondary-bkg-active)"
320
- isColor
321
- />
322
- <TokenRow
323
- token="--fs-button-secondary-border-color"
324
- value="var(--fs-button-secondary-text-color)"
325
- isColor
326
- globalValue="var(--fs-color-secondary-text)"
327
- />
328
- <TokenRow
329
- token="--fs-button-secondary-border-color-hover"
330
- value="var(--fs-button-secondary-bkg-color-hover)"
331
- isColor
332
- globalValue="var(--fs-color-secondary-bkg-hover)"
333
- />
334
- <TokenRow
335
- token="--fs-button-secondary-border-color-active"
336
- value="var(--fs-button-secondary-bkg-color-active)"
337
- isColor
338
- globalValue="var(--fs-color-secondary-bkg-active)"
339
- />
340
- <TokenRow
341
- token="--fs-button-secondary-shadow-hover"
342
- value="var(--fs-button-shadow-hover)"
343
- />
344
- </TokenTable>
345
-
346
- ### Secondary Inverse
347
-
348
- <Canvas style={{ backgroundColor: '#171a1c' }}>
349
- <Story
350
- name="Secondary Inverse"
351
- args={{ inverse: true, variant: 'secondary' }}
352
- >
353
- {Template.bind({})}
354
- </Story>
355
- </Canvas>
356
-
357
- <TokenTable>
358
- <TokenRow
359
- token="--fs-button-secondary-inverse-text-color"
360
- value="var(--fs-button-secondary-text-color-hover)"
361
- isColor
362
- globalValue="var(--fs-color-text-inverse)"
363
- />
364
- <TokenRow
365
- token="--fs-button-secondary-inverse-text-color-hover"
366
- value="var(--fs-button-secondary-text-color)"
367
- isColor
368
- globalValue="var(--fs-color-secondary-text)"
369
- />
370
- <TokenRow
371
- token="--fs-button-secondary-inverse-text-color-active"
372
- value="var(--fs-button-secondary-inverse-text-color-hover)"
373
- isColor
374
- globalValue="var(--fs-color-secondary-text)"
375
- />
376
- <TokenRow
377
- token="--fs-button-secondary-inverse-bkg-color"
378
- value="var(--fs-button-secondary-bkg-color)"
379
- isColor
380
- globalValue="var(--fs-color-secondary-bkg)"
381
- />
382
- <TokenRow
383
- token="--fs-button-secondary-inverse-bkg-color-hover"
384
- value="var(--fs-button-secondary-text-color-hover)"
385
- isColor
386
- globalValue="var(--fs-color-text-inverse)"
387
- />
388
- <TokenRow
389
- token="--fs-button-secondary-inverse-bkg-color-active"
390
- value="var(--fs-color-secondary-bkg-light)"
391
- isColor
392
- />
393
- <TokenRow
394
- token="--fs-button-secondary-inverse-border-color"
395
- value="var(--fs-button-secondary-inverse-text-color)"
396
- isColor
397
- globalValue="var(--fs-color-text-inverse)"
398
- />
399
- <TokenRow
400
- token="--fs-button-secondary-inverse-border-color-hover"
401
- value="var(--fs-button-secondary-inverse-bkg-color-hover)"
402
- isColor
403
- globalValue="var(--fs-color-text-inverse)"
404
- />
405
- <TokenRow
406
- token="--fs-button-secondary-inverse-border-color-active"
407
- value="var(--fs-button-secondary-inverse-bkg-color-hover)"
408
- isColor
409
- globalValue="var(--fs-color-secondary-bkg-light)"
410
- />
411
- <TokenRow
412
- token="--fs-button-secondary-inverse-shadow-hover"
413
- value="var(--fs-button-shadow-hover)"
414
- />
415
- </TokenTable>
416
-
417
- ### Tertiary
418
-
419
- <Canvas>
420
- <Story name="Tertiary" args={{ variant: 'tertiary' }}>
421
- {Template.bind({})}
422
- </Story>
423
- </Canvas>
424
-
425
- <TokenTable>
426
- <TokenRow
427
- token="--fs-button-tertiary-text-color"
428
- value="var(--fs-color-tertiary-text)"
429
- isColor
430
- />
431
- <TokenRow
432
- token="--fs-button-tertiary-text-color-hover"
433
- value="var(--fs-button-tertiary-text-color)"
434
- isColor
435
- globalValue="var(--fs-color-tertiary-text)"
436
- />
437
- <TokenRow
438
- token="--fs-button-tertiary-text-color-active"
439
- value="var(--fs-button-primary-bkg-color)"
440
- isColor
441
- globalValue="var(--fs-color-primary-bkg)"
442
- />
443
- <TokenRow
444
- token="--fs-button-tertiary-bkg-color"
445
- value="var(--fs-color-tertiary-bkg)"
446
- isColor
447
- />
448
- <TokenRow
449
- token="--fs-button-tertiary-bkg-color-hover"
450
- value="var(--fs-color-tertiary-bkg-hover)"
451
- isColor
452
- />
453
- <TokenRow
454
- token="--fs-button-tertiary-bkg-color-active"
455
- value="var(--fs-color-tertiary-bkg-active)"
456
- isColor
457
- />
458
- <TokenRow
459
- token="--fs-button-tertiary-border-color"
460
- value="transparent"
461
- isColor
462
- />
463
- <TokenRow
464
- token="--fs-button-tertiary-border-color-hover"
465
- value="var(--fs-button-tertiary-border-color)"
466
- isColor
467
- />
468
- <TokenRow
469
- token="--fs-button-tertiary-border-color-active"
470
- value="var(--fs-button-tertiary-border-color)"
471
- isColor
472
- />
473
- <TokenRow
474
- token="--fs-button-tertiary-shadow-hover"
475
- value="var(--fs-button-shadow-hover)"
476
- />
477
- </TokenTable>
478
-
479
- ### Tertiary Inverse
480
-
481
- <Canvas style={{ backgroundColor: '#171a1c' }}>
482
- <Story name="Tertiary Inverse" args={{ inverse: true, variant: 'tertiary' }}>
483
- {Template.bind({})}
484
- </Story>
485
- </Canvas>
486
-
487
- <TokenTable>
488
- <TokenRow
489
- token="--fs-button-tertiary-inverse-text-color"
490
- value="var(--fs-button-secondary-text-color-hover)"
491
- isColor
492
- globalValue="var(--fs-color-text-inverse)"
493
- />
494
- <TokenRow
495
- token="--fs-button-tertiary-inverse-text-color-hover"
496
- value="var(--fs-button-secondary-text-color-hover)"
497
- isColor
498
- globalValue="var(--fs-color-text-inverse)"
499
- />
500
- <TokenRow
501
- token="--fs-button-tertiary-inverse-text-color-active"
502
- value="var(--fs-button-secondary-text-color-hover)"
503
- isColor
504
- globalValue="var(--fs-color-text-inverse)"
505
- />
506
- <TokenRow
507
- token="--fs-button-tertiary-inverse-bkg-color"
508
- value="var(--fs-button-secondary-inverse-bkg-color)"
509
- isColor
510
- globalValue="var(--fs-color-secondary-bkg)"
511
- />
512
- <TokenRow
513
- token="--fs-button-tertiary-inverse-bkg-color-hover"
514
- value="var(--fs-button-primary-bkg-color-hover)"
515
- isColor
516
- globalValue="var(--fs-color-primary-bkg-hover)"
517
- />
518
- <TokenRow
519
- token="--fs-button-tertiary-inverse-bkg-color-active"
520
- value="var(--fs-button-primary-bkg-color-active)"
521
- isColor
522
- globalValue="var(--fs-color-primary-bkg-active)"
523
- />
524
- <TokenRow
525
- token="--fs-button-tertiary-inverse-border-color"
526
- value="var(--fs-button-tertiary-border-color)"
527
- isColor
528
- />
529
- <TokenRow
530
- token="--fs-button-tertiary-inverse-border-color-hover"
531
- value="var(--fs-button-tertiary-border-color)"
532
- isColor
533
- />
534
- <TokenRow
535
- token="--fs-button-tertiary-inverse-border-color-active"
536
- value="var(--fs-button-tertiary-border-color)"
537
- isColor
538
- />
539
- <TokenRow
540
- token="--fs-button-tertiary-inverse-shadow-hover"
541
- value="var(--fs-button-shadow-hover)"
542
- />
543
- </TokenTable>
544
-
545
- ---
546
-
547
- ## Variants <a id="variants" />
548
-
549
- ### Disabled
550
-
551
- <Canvas>
552
- <Story name="Disabled" args={{ variant: 'primary', disabled: true }}>
553
- {Template.bind({})}
554
- </Story>
555
- </Canvas>
556
-
557
- <TokenTable>
558
- <TokenRow
559
- token="--fs-button-disabled-bkg-color"
560
- value="var(--fs-color-disabled-bkg)"
561
- isColor
562
- />
563
- <TokenRow
564
- token="--fs-button-disabled-text-color"
565
- value="var(--fs-color-disabled-text)"
566
- isColor
567
- />
568
- </TokenTable>
569
-
570
- ### Small
571
-
572
- <Canvas>
573
- <Story name="Small" args={{ size: 'small', variant: 'primary' }}>
574
- {Template.bind({})}
575
- </Story>
576
- </Canvas>
577
-
578
- <TokenTable>
579
- <TokenRow
580
- token="--fs-button-small-padding"
581
- value="var(--fs-spacing-0) var(--fs-spacing-1)"
582
- />
583
- <TokenRow token="--fs-button-small-min-height" value="var(--fs-spacing-5)" />
584
- <TokenRow token="--fs-button-small-gap" value="var(--fs-spacing-1)" />
585
- </TokenTable>
586
-
587
- ---
588
-
589
- ## Related Components <a id="related-components" />
590
-
591
- <SectionList grid="grid">
592
- <SectionItem
593
- title="Button Icon"
594
- description="A button which content is only an icon, without any label."
595
- >
596
- <div data-fs-button style={{ backgroundColor: 'white', borderRadius: 2 }}>
597
- <Button
598
- aria-label="Set location"
599
- icon={<Icon name="MapPin" width={32} height={32} color="black" />}
600
- />
601
- </div>
602
- </SectionItem>
603
- <SectionItem
604
- title="Button Buy"
605
- description="A button with the intent of directly sending the user to the checkout/cart step."
606
- >
607
- <BuyButton>Button Buy</BuyButton>
608
- </SectionItem>
609
- <SectionItem
610
- title="Button Link"
611
- description="A button that acts as a link to navigate users between pages."
612
- >
613
- <LinkButton href="/">Button Link</LinkButton>
614
- </SectionItem>
615
- </SectionList>
616
-
617
- ---
618
-
619
- <BestPractices>
620
- <BestPracticesRule
621
- recommendedUsage={
622
- <div data-fs-button style={{ backgroundColor: 'white', borderRadius: 2 }}>
623
- <Button
624
- aria-label="Open menu"
625
- icon={<Icon name="List" width={32} height={32} color="black" />}
626
- />
627
- </div>
628
- }
629
- recommendedDescription={
630
- <>
631
- For cases when the button doesn't have label, use{' '}
632
- <code>aria-label</code> to describe its action for accessibility
633
- purposes.
634
- </>
635
- }
636
- discouragedUsage={<Button variant="primary">Button</Button>}
637
- discouragedDescription={
638
- <>
639
- Avoid using <code>aria-label</code> when the button already has a label.
640
- </>
641
- }
642
- />
643
- </BestPractices>
@@ -1,11 +0,0 @@
1
- .fs-button {
2
- // --------------------------------------------------------
3
- // Design Tokens for Buttons
4
- // --------------------------------------------------------
5
-
6
- &[data-fs-button-link] {
7
- &:hover { text-decoration: none; }
8
-
9
- &[data-button-disabled="true"] { pointer-events: none; }
10
- }
11
- }