@faststore/ui 2.0.2-alpha.0 → 2.0.4-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.
- package/CHANGELOG.md +18 -0
- package/dist/assets/ShoppingCart.d.ts +2 -2
- package/dist/assets/ShoppingCart.js.map +1 -1
- package/dist/assets/X.d.ts +2 -2
- package/dist/assets/X.js.map +1 -1
- package/package.json +30 -37
- package/src/assets/ShoppingCart.tsx +50 -0
- package/src/assets/X.tsx +38 -0
- package/src/base/layout.scss +78 -0
- package/src/base/tokens.scss +274 -0
- package/src/base/typography.scss +64 -0
- package/src/components/atoms/Badge/Badge.stories.mdx +156 -0
- package/src/components/atoms/Badge/styles.scss +209 -0
- package/src/components/atoms/Button/Button.stories.mdx +110 -0
- package/src/components/atoms/Button/styles.scss +316 -0
- package/src/components/atoms/Checkbox/styles.scss +155 -0
- package/src/{atoms → components/atoms}/Incentive/Incentive.tsx +0 -0
- package/src/{atoms → components/atoms}/Incentive/index.tsx +0 -0
- package/src/{atoms → components/atoms}/Incentive/stories/Incentive.mdx +0 -0
- package/src/{atoms → components/atoms}/Incentive/stories/Incentive.stories.tsx +0 -0
- package/src/{atoms → components/atoms}/Incentive/stories/assets/Icons.tsx +0 -0
- package/src/{atoms → components/atoms}/Input/Input.tsx +0 -0
- package/src/{atoms → components/atoms}/Input/index.ts +0 -0
- package/src/{atoms → components/atoms}/Input/stories/Input.mdx +0 -0
- package/src/{atoms → components/atoms}/Input/stories/Input.stories.tsx +1 -1
- package/src/components/atoms/Label/Label.stories.mdx +65 -0
- package/src/{atoms → components/atoms}/Link/Link.tsx +1 -1
- package/src/{atoms → components/atoms}/Link/index.tsx +0 -0
- package/src/{atoms → components/atoms}/Link/stories/Link.mdx +0 -0
- package/src/{atoms → components/atoms}/Link/stories/Link.stories.tsx +0 -0
- package/src/{atoms → components/atoms}/List/List.tsx +0 -0
- package/src/{atoms → components/atoms}/List/index.ts +0 -0
- package/src/{atoms → components/atoms}/List/stories/List.mdx +0 -0
- package/src/{atoms → components/atoms}/List/stories/List.stories.tsx +1 -1
- package/src/{atoms → components/atoms}/Overlay/Overlay.tsx +0 -0
- package/src/{atoms → components/atoms}/Overlay/index.ts +0 -0
- package/src/{atoms → components/atoms}/Overlay/stories/Overlay.mdx +0 -0
- package/src/{atoms → components/atoms}/Overlay/stories/Overlay.stories.tsx +1 -1
- package/src/{atoms → components/atoms}/Popover/Popover.tsx +0 -0
- package/src/{atoms → components/atoms}/Popover/index.ts +0 -0
- package/src/{atoms → components/atoms}/Popover/stories/Popover.mdx +0 -0
- package/src/{atoms → components/atoms}/Popover/stories/Popover.stories.tsx +1 -1
- package/src/{atoms → components/atoms}/Price/Price.tsx +0 -0
- package/src/{atoms → components/atoms}/Price/index.ts +0 -0
- package/src/{atoms → components/atoms}/Price/stories/Price.mdx +0 -0
- package/src/{atoms → components/atoms}/Price/stories/Price.stories.tsx +1 -1
- package/src/components/atoms/Radio/Radio.stories.mdx +101 -0
- package/src/components/atoms/Radio/styles.scss +108 -0
- package/src/{atoms → components/atoms}/Select/Select.tsx +0 -0
- package/src/{atoms → components/atoms}/Select/index.ts +0 -0
- package/src/{atoms → components/atoms}/Select/stories/Select.mdx +0 -0
- package/src/{atoms → components/atoms}/Select/stories/Select.stories.tsx +1 -1
- package/src/{atoms → components/atoms}/Skeleton/Skeleton.tsx +0 -0
- package/src/{atoms → components/atoms}/Skeleton/index.ts +0 -0
- package/src/{atoms → components/atoms}/Skeleton/stories/Skeleton.mdx +0 -0
- package/src/{atoms → components/atoms}/Skeleton/stories/Skeleton.stories.tsx +0 -0
- package/src/{atoms → components/atoms}/Slider/Slider.tsx +0 -0
- package/src/{atoms → components/atoms}/Slider/index.ts +0 -0
- package/src/{atoms → components/atoms}/Slider/stories/Slider.mdx +0 -0
- package/src/{atoms → components/atoms}/Slider/stories/Slider.stories.tsx +1 -1
- package/src/{atoms → components/atoms}/Spinner/Spinner.tsx +0 -0
- package/src/{atoms → components/atoms}/Spinner/index.tsx +0 -0
- package/src/{atoms → components/atoms}/Spinner/stories/Spinner.mdx +0 -0
- package/src/{atoms → components/atoms}/Spinner/stories/Spinner.stories.tsx +0 -0
- package/src/{atoms → components/atoms}/TextArea/TextArea.tsx +0 -0
- package/src/{atoms → components/atoms}/TextArea/index.ts +0 -0
- package/src/{atoms → components/atoms}/TextArea/stories/TextArea.mdx +0 -0
- package/src/{atoms → components/atoms}/TextArea/stories/TextArea.stories.tsx +1 -1
- package/src/{molecules → components/molecules}/Accordion/Accordion.tsx +0 -0
- package/src/{molecules → components/molecules}/Accordion/AccordionButton.tsx +4 -4
- package/src/{molecules → components/molecules}/Accordion/AccordionItem.tsx +1 -1
- package/src/{molecules → components/molecules}/Accordion/AccordionPanel.tsx +0 -0
- package/src/{molecules → components/molecules}/Accordion/index.ts +0 -0
- package/src/{molecules → components/molecules}/Accordion/stories/Accordion.mdx +0 -0
- package/src/{molecules → components/molecules}/Accordion/stories/Accordion.stories.tsx +1 -1
- package/src/{molecules → components/molecules}/AggregateRating/AggregateRating.tsx +0 -0
- package/src/{molecules → components/molecules}/AggregateRating/index.ts +0 -0
- package/src/{molecules → components/molecules}/AggregateRating/stories/AggregateRating.mdx +0 -0
- package/src/{molecules → components/molecules}/AggregateRating/stories/AggregateRating.stories.tsx +1 -1
- package/src/{molecules → components/molecules}/Alert/Alert.tsx +0 -0
- package/src/{molecules → components/molecules}/Alert/index.ts +0 -0
- package/src/{molecules → components/molecules}/Alert/stories/Alert.mdx +0 -0
- package/src/{molecules → components/molecules}/Alert/stories/Alert.stories.tsx +3 -3
- package/src/{molecules → components/molecules}/Banner/Banner.tsx +0 -0
- package/src/{molecules → components/molecules}/Banner/BannerContent.tsx +0 -0
- package/src/{molecules → components/molecules}/Banner/BannerImage.tsx +0 -0
- package/src/{molecules → components/molecules}/Banner/BannerLink.tsx +0 -0
- package/src/{molecules → components/molecules}/Banner/index.ts +0 -0
- package/src/{molecules → components/molecules}/Banner/stories/Banner.mdx +0 -0
- package/src/{molecules → components/molecules}/Banner/stories/Banner.stories.tsx +1 -1
- package/src/{molecules → components/molecules}/Breadcrumb/Breadcrumb.tsx +0 -0
- package/src/{molecules → components/molecules}/Breadcrumb/index.ts +0 -0
- package/src/{molecules → components/molecules}/Breadcrumb/stories/Breadcrumb.mdx +0 -0
- package/src/{molecules → components/molecules}/Breadcrumb/stories/Breadcrumb.stories.tsx +1 -1
- package/src/{molecules → components/molecules}/Bullets/Bullets.tsx +1 -1
- package/src/{molecules → components/molecules}/Bullets/index.ts +0 -0
- package/src/{molecules → components/molecules}/Bullets/stories/Bullets.mdx +0 -0
- package/src/{molecules → components/molecules}/Bullets/stories/Bullets.stories.tsx +1 -1
- package/src/{molecules → components/molecules}/Card/Card.tsx +0 -0
- package/src/{molecules → components/molecules}/Card/CardActions.tsx +0 -0
- package/src/{molecules → components/molecules}/Card/CardContent.tsx +0 -0
- package/src/{molecules → components/molecules}/Card/CardImage.tsx +0 -0
- package/src/{molecules → components/molecules}/Card/index.tsx +0 -0
- package/src/{molecules → components/molecules}/Card/stories/Card.mdx +0 -0
- package/src/{molecules → components/molecules}/Card/stories/Card.stories.tsx +5 -5
- package/src/{molecules → components/molecules}/Carousel/Arrows.tsx +0 -0
- package/src/{molecules → components/molecules}/Carousel/Carousel.tsx +2 -2
- package/src/{molecules → components/molecules}/Carousel/CarouselItem.tsx +1 -1
- package/src/{molecules → components/molecules}/Carousel/hooks/useSlideVisibility.ts +0 -0
- package/src/{molecules → components/molecules}/Carousel/index.ts +0 -0
- package/src/{molecules → components/molecules}/Carousel/stories/Carousel.mdx +0 -0
- package/src/{molecules → components/molecules}/Carousel/stories/Carousel.stories.tsx +1 -1
- package/src/{molecules → components/molecules}/CartItem/CartItem.tsx +0 -0
- package/src/{molecules → components/molecules}/CartItem/CartItemActions.tsx +0 -0
- package/src/{molecules → components/molecules}/CartItem/CartItemContent.tsx +0 -0
- package/src/{molecules → components/molecules}/CartItem/CartItemImage.tsx +0 -0
- package/src/{molecules → components/molecules}/CartItem/CartItemPrices.tsx +0 -0
- package/src/{molecules → components/molecules}/CartItem/CartItemSummary.tsx +0 -0
- package/src/{molecules → components/molecules}/CartItem/CartItemTitle.tsx +0 -0
- package/src/{molecules → components/molecules}/CartItem/index.tsx +0 -0
- package/src/{molecules → components/molecules}/CartItem/stories/CartItem.mdx +0 -0
- package/src/{molecules → components/molecules}/CartItem/stories/CartItem.stories.tsx +1 -1
- package/src/components/molecules/CheckboxField/CheckboxField.stories.mdx +38 -0
- package/src/components/molecules/CheckboxField/styles.scss +12 -0
- package/src/{molecules → components/molecules}/Dropdown/Dropdown.tsx +0 -0
- package/src/{molecules → components/molecules}/Dropdown/DropdownButton.tsx +0 -0
- package/src/{molecules → components/molecules}/Dropdown/DropdownItem.tsx +0 -0
- package/src/{molecules → components/molecules}/Dropdown/DropdownMenu.tsx +0 -0
- package/src/{molecules → components/molecules}/Dropdown/contexts/DropdownContext.ts +0 -0
- package/src/{molecules → components/molecules}/Dropdown/hooks/useDropdown.ts +0 -0
- package/src/{molecules → components/molecules}/Dropdown/hooks/useDropdownPosition.ts +0 -0
- package/src/{molecules → components/molecules}/Dropdown/index.ts +0 -0
- package/src/{molecules → components/molecules}/Dropdown/stories/Dropdown.mdx +0 -0
- package/src/{molecules → components/molecules}/Dropdown/stories/Dropdown.stories.tsx +1 -1
- package/src/{molecules → components/molecules}/Dropdown/stories/assets/Caret.tsx +0 -0
- package/src/{molecules → components/molecules}/Form/Form.tsx +0 -0
- package/src/{molecules → components/molecules}/Form/index.ts +0 -0
- package/src/{molecules → components/molecules}/Form/stories/Form.mdx +0 -0
- package/src/{molecules → components/molecules}/Form/stories/Form.stories.tsx +2 -1
- package/src/{molecules → components/molecules}/Gift/Gift.tsx +2 -3
- package/src/{molecules → components/molecules}/Gift/GiftContent.tsx +0 -0
- package/src/{molecules → components/molecules}/Gift/GiftImage.tsx +0 -0
- package/src/{molecules → components/molecules}/Gift/index.tsx +0 -0
- package/src/{molecules → components/molecules}/Gift/stories/Gift.mdx +0 -0
- package/src/{molecules → components/molecules}/Gift/stories/Gift.stories.tsx +1 -1
- package/src/components/molecules/IconButton/IconButton.stories.mdx +47 -0
- package/src/{molecules → components/molecules}/LoadingButton/LoadingButton.tsx +3 -8
- package/src/{molecules → components/molecules}/LoadingButton/index.tsx +0 -0
- package/src/{molecules → components/molecules}/LoadingButton/stories/LoadingButton.mdx +0 -0
- package/src/{molecules → components/molecules}/LoadingButton/stories/LoadingButton.stories.tsx +1 -1
- package/src/{molecules → components/molecules}/Modal/Modal.tsx +0 -0
- package/src/{molecules → components/molecules}/Modal/ModalContent.tsx +0 -0
- package/src/{molecules → components/molecules}/Modal/index.tsx +0 -0
- package/src/{molecules → components/molecules}/Modal/stories/Modal.mdx +0 -0
- package/src/{molecules → components/molecules}/Modal/stories/Modal.stories.tsx +1 -1
- package/src/{molecules → components/molecules}/Modal/useTrapFocus.ts +0 -0
- package/src/{molecules → components/molecules}/OrderSummary/OrderSummary.tsx +0 -0
- package/src/{molecules → components/molecules}/OrderSummary/index.tsx +0 -0
- package/src/{molecules → components/molecules}/OrderSummary/stories/OrderSummary.mdx +0 -0
- package/src/{molecules → components/molecules}/OrderSummary/stories/OrderSummary.stories.tsx +0 -0
- package/src/{molecules → components/molecules}/PaymentMethods/PaymentMethods.tsx +0 -0
- package/src/{molecules → components/molecules}/PaymentMethods/index.tsx +0 -0
- package/src/{molecules → components/molecules}/PaymentMethods/stories/PaymentMethods.mdx +0 -0
- package/src/{molecules → components/molecules}/PaymentMethods/stories/PaymentMethods.stories.tsx +0 -0
- package/src/{molecules → components/molecules}/PaymentMethods/stories/assets/Icons.tsx +0 -0
- package/src/{molecules → components/molecules}/PriceRange/PriceRange.tsx +0 -0
- package/src/{molecules → components/molecules}/PriceRange/index.ts +0 -0
- package/src/{molecules → components/molecules}/PriceRange/stories/PriceRange.mdx +0 -0
- package/src/{molecules → components/molecules}/PriceRange/stories/PriceRange.stories.tsx +1 -1
- package/src/{molecules → components/molecules}/ProductCard/ProductCard.tsx +0 -0
- package/src/{molecules → components/molecules}/ProductCard/ProductCardActions.tsx +0 -0
- package/src/{molecules → components/molecules}/ProductCard/ProductCardContent.tsx +0 -0
- package/src/{molecules → components/molecules}/ProductCard/ProductCardImage.tsx +0 -0
- package/src/{molecules → components/molecules}/ProductCard/index.tsx +0 -0
- package/src/{molecules → components/molecules}/ProductCard/stories/ProductCard.mdx +0 -0
- package/src/{molecules → components/molecules}/ProductCard/stories/ProductCard.stories.tsx +1 -2
- package/src/{molecules → components/molecules}/ProductTitle/ProductTitle.tsx +0 -0
- package/src/{molecules → components/molecules}/ProductTitle/index.tsx +0 -0
- package/src/{molecules → components/molecules}/ProductTitle/stories/ProductTitle.mdx +0 -0
- package/src/{molecules → components/molecules}/ProductTitle/stories/ProductTitle.stories.tsx +3 -3
- package/src/{molecules → components/molecules}/QuantitySelector/QuantitySelector.tsx +2 -2
- package/src/{molecules → components/molecules}/QuantitySelector/index.ts +0 -0
- package/src/{molecules → components/molecules}/QuantitySelector/stories/QuantitySelector.mdx +0 -0
- package/src/{molecules → components/molecules}/QuantitySelector/stories/QuantitySelector.stories.tsx +0 -0
- package/src/{molecules → components/molecules}/QuantitySelector/stories/assets/Icons.tsx +0 -0
- package/src/components/molecules/RadioField/RadioField.stories.mdx +38 -0
- package/src/components/molecules/RadioField/styles.scss +12 -0
- package/src/{molecules → components/molecules}/RadioGroup/RadioGroup.tsx +0 -0
- package/src/{molecules → components/molecules}/RadioGroup/RadioOption.tsx +1 -1
- package/src/{molecules → components/molecules}/RadioGroup/index.tsx +0 -0
- package/src/{molecules → components/molecules}/RadioGroup/stories/RadioGroup.mdx +0 -0
- package/src/{molecules → components/molecules}/RadioGroup/stories/RadioGroup.stories.tsx +0 -0
- package/src/{molecules → components/molecules}/RadioGroup/useRadioGroup.ts +0 -0
- package/src/{molecules → components/molecules}/SearchInput/SearchInput.tsx +2 -3
- package/src/{molecules → components/molecules}/SearchInput/index.ts +0 -0
- package/src/{molecules → components/molecules}/SearchInput/stories/SearchInput.mdx +0 -0
- package/src/{molecules → components/molecules}/SearchInput/stories/SearchInput.stories.tsx +1 -1
- package/src/{molecules → components/molecules}/SearchInput/stories/assets/CustomIcon.tsx +0 -0
- package/src/{molecules → components/molecules}/SkuSelector/SkuSelector.tsx +3 -2
- package/src/{molecules → components/molecules}/SkuSelector/index.tsx +0 -0
- package/src/{molecules → components/molecules}/SkuSelector/stories/SkuSelector.mdx +0 -0
- package/src/{molecules → components/molecules}/SkuSelector/stories/SkuSelector.stories.tsx +1 -1
- package/src/{molecules → components/molecules}/Table/Table.tsx +0 -0
- package/src/{molecules → components/molecules}/Table/TableBody.tsx +0 -0
- package/src/{molecules → components/molecules}/Table/TableCell.tsx +0 -0
- package/src/{molecules → components/molecules}/Table/TableFooter.tsx +0 -0
- package/src/{molecules → components/molecules}/Table/TableHead.tsx +0 -0
- package/src/{molecules → components/molecules}/Table/TableRow.tsx +0 -0
- package/src/{molecules → components/molecules}/Table/index.ts +0 -0
- package/src/{molecules → components/molecules}/Table/stories/Table.mdx +0 -0
- package/src/{molecules → components/molecules}/Table/stories/Table.stories.tsx +0 -0
- package/src/components/molecules/Tag/Tag.stories.mdx +31 -0
- package/src/components/molecules/Tag/styles.scss +99 -0
- package/src/{organisms → components/organisms}/Hero/Hero.tsx +0 -0
- package/src/{organisms → components/organisms}/Hero/HeroHeading.tsx +0 -0
- package/src/{organisms → components/organisms}/Hero/HeroImage.tsx +0 -0
- package/src/{organisms → components/organisms}/Hero/index.tsx +0 -0
- package/src/{organisms → components/organisms}/Hero/stories/Hero.mdx +0 -0
- package/src/{organisms → components/organisms}/Hero/stories/Hero.stories.tsx +1 -1
- package/src/{organisms → components/organisms}/OutOfStock/OutOfStock.tsx +0 -0
- package/src/{organisms → components/organisms}/OutOfStock/OutOfStockMessage.tsx +0 -0
- package/src/{organisms → components/organisms}/OutOfStock/OutOfStockTitle.tsx +0 -0
- package/src/{organisms → components/organisms}/OutOfStock/index.tsx +0 -0
- package/src/{organisms → components/organisms}/OutOfStock/stories/OutOfStock.mdx +0 -0
- package/src/{organisms → components/organisms}/OutOfStock/stories/OutOfStock.stories.tsx +1 -1
- package/src/{organisms → components/organisms}/Tiles/Tile.tsx +0 -0
- package/src/{organisms → components/organisms}/Tiles/Tiles.tsx +0 -0
- package/src/{organisms → components/organisms}/Tiles/index.ts +0 -0
- package/src/{organisms → components/organisms}/Tiles/stories/Tiles.mdx +0 -0
- package/src/{organisms → components/organisms}/Tiles/stories/Tiles.stories.tsx +0 -0
- package/src/index.ts +97 -99
- package/src/styles/base.scss +3 -0
- package/src/styles/components.scss +10 -0
- package/src/styles/global.scss +4 -0
- package/src/styles/reset.scss +54 -0
- package/src/styles/utilities.scss +75 -0
- package/src/typings/utils.d.ts +2 -2
- package/dist/assets/index.d.ts +0 -2
- package/dist/assets/index.js +0 -3
- package/dist/assets/index.js.map +0 -1
- package/src/atoms/Badge/Badge.test.tsx +0 -23
- package/src/atoms/Badge/Badge.tsx +0 -23
- package/src/atoms/Badge/index.ts +0 -2
- package/src/atoms/Badge/stories/Badge.mdx +0 -18
- package/src/atoms/Badge/stories/Badge.stories.tsx +0 -37
- package/src/atoms/Button/Button.test.tsx +0 -12
- package/src/atoms/Button/Button.tsx +0 -23
- package/src/atoms/Button/index.ts +0 -2
- package/src/atoms/Button/stories/Button.mdx +0 -18
- package/src/atoms/Button/stories/Button.stories.tsx +0 -36
- package/src/atoms/Checkbox/Checkbox.test.tsx +0 -65
- package/src/atoms/Checkbox/Checkbox.tsx +0 -27
- package/src/atoms/Checkbox/index.ts +0 -2
- package/src/atoms/Checkbox/stories/Checkbox.mdx +0 -18
- package/src/atoms/Checkbox/stories/Checkbox.stories.tsx +0 -65
- package/src/atoms/Icon/Icon.test.tsx +0 -43
- package/src/atoms/Icon/Icon.tsx +0 -26
- package/src/atoms/Icon/index.ts +0 -2
- package/src/atoms/Icon/stories/Icon.mdx +0 -18
- package/src/atoms/Icon/stories/Icon.stories.tsx +0 -40
- package/src/atoms/Icon/stories/assets/ShoppingCart.tsx +0 -23
- package/src/atoms/Incentive/Incentive.test.tsx +0 -36
- package/src/atoms/Input/Input.test.tsx +0 -73
- package/src/atoms/Label/Label.test.tsx +0 -71
- package/src/atoms/Label/Label.tsx +0 -22
- package/src/atoms/Label/index.ts +0 -2
- package/src/atoms/Label/stories/Label.mdx +0 -18
- package/src/atoms/Label/stories/Label.stories.tsx +0 -30
- package/src/atoms/Link/Link.test.tsx +0 -53
- package/src/atoms/List/List.test.tsx +0 -195
- package/src/atoms/Overlay/Overlay.test.tsx +0 -23
- package/src/atoms/Popover/Popover.test.tsx +0 -39
- package/src/atoms/Price/Price.test.tsx +0 -63
- package/src/atoms/Radio/Radio.test.tsx +0 -59
- package/src/atoms/Radio/Radio.tsx +0 -24
- package/src/atoms/Radio/index.ts +0 -2
- package/src/atoms/Radio/stories/Radio.mdx +0 -18
- package/src/atoms/Radio/stories/Radio.stories.tsx +0 -41
- package/src/atoms/Select/Select.test.tsx +0 -71
- package/src/atoms/Skeleton/Skeleton.test.tsx +0 -13
- package/src/atoms/Slider/Slider.test.tsx +0 -32
- package/src/atoms/Spinner/Spinner.test.tsx +0 -12
- package/src/atoms/TextArea/TextArea.test.tsx +0 -77
- package/src/hooks/useSlider/useSlider.test.ts +0 -176
- package/src/molecules/Accordion/Accordion.test.tsx +0 -226
- package/src/molecules/AggregateRating/AggregateRating.test.tsx +0 -87
- package/src/molecules/Alert/Alert.test.tsx +0 -23
- package/src/molecules/Banner/Banner.test.tsx +0 -67
- package/src/molecules/Breadcrumb/Breadcrumb.test.tsx +0 -124
- package/src/molecules/Bullets/Bullets.test.tsx +0 -128
- package/src/molecules/Card/Card.test.tsx +0 -68
- package/src/molecules/Carousel/Carousel.test.tsx +0 -587
- package/src/molecules/Carousel/hooks/hooks.test.ts +0 -109
- package/src/molecules/CartItem/CartItem.test.tsx +0 -79
- package/src/molecules/Dropdown/Dropdown.test.tsx +0 -275
- package/src/molecules/Form/Form.test.tsx +0 -61
- package/src/molecules/Gift/Gift.test.tsx +0 -53
- package/src/molecules/IconButton/IconButton.test.tsx +0 -31
- package/src/molecules/IconButton/IconButton.tsx +0 -35
- package/src/molecules/IconButton/index.tsx +0 -2
- package/src/molecules/IconButton/stories/IconButton.mdx +0 -27
- package/src/molecules/IconButton/stories/IconButton.stories.tsx +0 -35
- package/src/molecules/LoadingButton/LoadingButton.test.tsx +0 -14
- package/src/molecules/Modal/Modal.test.tsx +0 -241
- package/src/molecules/OrderSummary/OrderSummary.test.tsx +0 -103
- package/src/molecules/PaymentMethods/PaymentMethods.test.tsx +0 -37
- package/src/molecules/PriceRange/PriceRange.test.tsx +0 -70
- package/src/molecules/ProductCard/ProductCard.test.tsx +0 -75
- package/src/molecules/QuantitySelector/QuantitySelector.test.tsx +0 -93
- package/src/molecules/RadioGroup/RadioGroup.test.tsx +0 -107
- package/src/molecules/SearchInput/SearchInput.test.tsx +0 -34
- package/src/molecules/SkuSelector/SkuSelector.test.tsx +0 -42
- package/src/molecules/Table/Table.test.tsx +0 -233
- package/src/organisms/Hero/Hero.test.tsx +0 -60
- package/src/organisms/OutOfStock/OutOfStock.test.tsx +0 -122
- package/src/setupTests.ts +0 -7
- package/src/utils/toHaveNoIncomplete.ts +0 -76
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,24 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [2.0.4-alpha.0](https://github.com/vtex/faststore/compare/v2.0.3-alpha.0...v2.0.4-alpha.0) (2022-12-07)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Chores
|
|
10
|
+
|
|
11
|
+
* config faststore ui ([#1495](https://github.com/vtex/faststore/issues/1495)) ([ed5aa8f](https://github.com/vtex/faststore/commit/ed5aa8f83ab3d929dd47f30b1e171240e1c3c459))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
## 2.0.3-alpha.0 (2022-11-30)
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
### Chores
|
|
19
|
+
|
|
20
|
+
* Change from `patch` to `prepatch` release (alpha) ([#1523](https://github.com/vtex/faststore/issues/1523)) ([2f2c5b7](https://github.com/vtex/faststore/commit/2f2c5b77d2d71f887dad64a9488fabc4e6a29e07))
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
|
|
6
24
|
## [1.12.23](https://github.com/vtex/faststore/compare/v1.12.22...v1.12.23) (2022-11-04)
|
|
7
25
|
|
|
8
26
|
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
declare const ShoppingCart:
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
declare const ShoppingCart: () => JSX.Element;
|
|
3
3
|
export default ShoppingCart;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ShoppingCart.js","sourceRoot":"","sources":["../../src/assets/ShoppingCart.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;
|
|
1
|
+
{"version":3,"file":"ShoppingCart.js","sourceRoot":"","sources":["../../src/assets/ShoppingCart.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,2BAA2B;AAC3B,MAAM,YAAY,GAAG,GAAG,EAAE,CAAC,CACzB,6BACE,EAAE,EAAC,cAAc,EACjB,KAAK,EAAC,4BAA4B,EAClC,IAAI,EAAC,cAAc,EACnB,OAAO,EAAC,aAAa,EACrB,WAAW,EAAC,IAAI,EAChB,KAAK,EAAE,EAAE,EACT,MAAM,EAAE,EAAE;IAEV,8BAAM,KAAK,EAAC,KAAK,EAAC,MAAM,EAAC,KAAK,EAAC,IAAI,EAAC,MAAM,GAAQ;IAClD,8BACE,CAAC,EAAC,8DAA8D,EAChE,IAAI,EAAC,MAAM,EACX,MAAM,EAAC,cAAc,EACrB,aAAa,EAAC,OAAO,EACrB,cAAc,EAAC,OAAO,GAChB;IACR,gCACE,EAAE,EAAC,IAAI,EACP,EAAE,EAAC,KAAK,EACR,CAAC,EAAC,IAAI,EACN,IAAI,EAAC,MAAM,EACX,MAAM,EAAC,cAAc,EACrB,aAAa,EAAC,OAAO,EACrB,cAAc,EAAC,OAAO,GACd;IACV,gCACE,EAAE,EAAC,KAAK,EACR,EAAE,EAAC,KAAK,EACR,CAAC,EAAC,IAAI,EACN,IAAI,EAAC,MAAM,EACX,MAAM,EAAC,cAAc,EACrB,aAAa,EAAC,OAAO,EACrB,cAAc,EAAC,OAAO,GACd;IACV,8BACE,CAAC,EAAC,iEAAiE,EACnE,IAAI,EAAC,MAAM,EACX,MAAM,EAAC,cAAc,EACrB,aAAa,EAAC,OAAO,EACrB,cAAc,EAAC,OAAO,GAChB,CACJ,CACP,CAAA;AAED,eAAe,YAAY,CAAA"}
|
package/dist/assets/X.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
declare const X:
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
declare const X: () => JSX.Element;
|
|
3
3
|
export default X;
|
package/dist/assets/X.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"X.js","sourceRoot":"","sources":["../../src/assets/X.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;
|
|
1
|
+
{"version":3,"file":"X.js","sourceRoot":"","sources":["../../src/assets/X.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,2BAA2B;AAC3B,MAAM,CAAC,GAAG,GAAG,EAAE,CAAC,CACd,6BACE,EAAE,EAAC,GAAG,EACN,KAAK,EAAC,4BAA4B,EAClC,IAAI,EAAC,cAAc,EACnB,OAAO,EAAC,aAAa,EACrB,WAAW,EAAC,IAAI,EAChB,KAAK,EAAE,EAAE,EACT,MAAM,EAAE,EAAE;IAEV,8BAAM,KAAK,EAAC,KAAK,EAAC,MAAM,EAAC,KAAK,EAAC,IAAI,EAAC,MAAM,GAAQ;IAClD,8BACE,EAAE,EAAC,KAAK,EACR,EAAE,EAAC,IAAI,EACP,EAAE,EAAC,IAAI,EACP,EAAE,EAAC,KAAK,EACR,IAAI,EAAC,MAAM,EACX,MAAM,EAAC,cAAc,EACrB,aAAa,EAAC,OAAO,EACrB,cAAc,EAAC,OAAO,GAChB;IACR,8BACE,EAAE,EAAC,KAAK,EACR,EAAE,EAAC,KAAK,EACR,EAAE,EAAC,IAAI,EACP,EAAE,EAAC,IAAI,EACP,IAAI,EAAC,MAAM,EACX,MAAM,EAAC,cAAc,EACrB,aAAa,EAAC,OAAO,EACrB,cAAc,EAAC,OAAO,GAChB,CACJ,CACP,CAAA;AAED,eAAe,CAAC,CAAA"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@faststore/ui",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.4-alpha.0",
|
|
4
4
|
"description": "A lightweight, framework agnostic component library for React",
|
|
5
5
|
"author": "emersonlaurentino",
|
|
6
6
|
"license": "MIT",
|
|
@@ -24,21 +24,10 @@
|
|
|
24
24
|
"develop": "tsc --watch",
|
|
25
25
|
"build": "tsc",
|
|
26
26
|
"lint": "eslint src/**/*.{ts,tsx}",
|
|
27
|
-
"
|
|
28
|
-
"storybook": "start-storybook -p 6006 --no-manager-cache",
|
|
27
|
+
"storybook": "start-storybook -p 6006",
|
|
29
28
|
"size": "size-limit",
|
|
30
|
-
"analyze": "size-limit --why"
|
|
31
|
-
|
|
32
|
-
"jest": {
|
|
33
|
-
"collectCoverageFrom": [
|
|
34
|
-
"src/**/*.{ts,tsx}"
|
|
35
|
-
],
|
|
36
|
-
"setupFilesAfterEnv": [
|
|
37
|
-
"<rootDir>/src/setupTests.ts"
|
|
38
|
-
],
|
|
39
|
-
"modulePaths": [
|
|
40
|
-
"<rootDir>/src"
|
|
41
|
-
]
|
|
29
|
+
"analyze": "size-limit --why",
|
|
30
|
+
"build-storybook": "build-storybook"
|
|
42
31
|
},
|
|
43
32
|
"size-limit": [
|
|
44
33
|
{
|
|
@@ -47,8 +36,10 @@
|
|
|
47
36
|
}
|
|
48
37
|
],
|
|
49
38
|
"dependencies": {
|
|
39
|
+
"@faststore/components": "*",
|
|
50
40
|
"@reach/popover": "^0.16.0",
|
|
51
|
-
"
|
|
41
|
+
"include-media": "^1.4.10",
|
|
42
|
+
"modern-normalize": "^1.1.0",
|
|
52
43
|
"react-swipeable": "^7.0.0",
|
|
53
44
|
"tabbable": "^5.2.1"
|
|
54
45
|
},
|
|
@@ -57,33 +48,35 @@
|
|
|
57
48
|
"react-dom": "^17.0.2"
|
|
58
49
|
},
|
|
59
50
|
"devDependencies": {
|
|
60
|
-
"@
|
|
61
|
-
"@faststore/
|
|
51
|
+
"@babel/core": "^7.19.6",
|
|
52
|
+
"@faststore/shared": "^2.0.3-alpha.0",
|
|
53
|
+
"@faststore/styles": "^2.0.4-alpha.0",
|
|
62
54
|
"@size-limit/preset-small-lib": "^7.0.8",
|
|
63
|
-
"@storybook/addon-
|
|
64
|
-
"@storybook/addon-
|
|
65
|
-
"@storybook/addon-essentials": "^6.
|
|
66
|
-
"@storybook/addon-
|
|
67
|
-
"@storybook/
|
|
68
|
-
"@storybook/
|
|
69
|
-
"@
|
|
70
|
-
"@
|
|
71
|
-
"@
|
|
72
|
-
"@testing-library
|
|
73
|
-
"@types/axe-core": "^2.0.7",
|
|
74
|
-
"@types/jest-axe": "^3.5.3",
|
|
55
|
+
"@storybook/addon-a11y": "^6.5.13",
|
|
56
|
+
"@storybook/addon-actions": "^6.5.13",
|
|
57
|
+
"@storybook/addon-essentials": "^6.5.13",
|
|
58
|
+
"@storybook/addon-interactions": "^6.5.13",
|
|
59
|
+
"@storybook/addon-links": "^6.5.13",
|
|
60
|
+
"@storybook/builder-webpack5": "^6.5.13",
|
|
61
|
+
"@storybook/manager-webpack5": "^6.5.13",
|
|
62
|
+
"@storybook/preset-scss": "^1.0.3",
|
|
63
|
+
"@storybook/react": "^6.5.13",
|
|
64
|
+
"@storybook/testing-library": "^0.0.13",
|
|
75
65
|
"@types/tabbable": "^3.1.1",
|
|
76
|
-
"
|
|
77
|
-
"
|
|
78
|
-
"jest-axe": "^5.0.1",
|
|
79
|
-
"jest-matcher-utils": "^27.4.2",
|
|
66
|
+
"babel-loader": "^8.2.5",
|
|
67
|
+
"css-loader": "^6.7.1",
|
|
80
68
|
"react": "^17.0.2",
|
|
81
|
-
"react-docgen-typescript-loader": "^3.7.2",
|
|
82
69
|
"react-dom": "^17.0.2",
|
|
70
|
+
"sass": "^1.55.0",
|
|
71
|
+
"sass-loader": "^13.1.0",
|
|
83
72
|
"size-limit": "^7.0.8",
|
|
84
73
|
"storybook-addon-themes": "^6.1.0",
|
|
85
|
-
"
|
|
74
|
+
"style-loader": "^3.3.1",
|
|
86
75
|
"typescript": "^4.2.4"
|
|
87
76
|
},
|
|
88
|
-
"
|
|
77
|
+
"volta": {
|
|
78
|
+
"node": "16.18.0",
|
|
79
|
+
"yarn": "1.19.1"
|
|
80
|
+
},
|
|
81
|
+
"gitHead": "e15f55dc806232292a13e286bf91fe527fcc3a32"
|
|
89
82
|
}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
|
|
3
|
+
// Icon from Phosphor Icons
|
|
4
|
+
const ShoppingCart = () => (
|
|
5
|
+
<svg
|
|
6
|
+
id="ShoppingCart"
|
|
7
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
8
|
+
fill="currentColor"
|
|
9
|
+
viewBox="0 0 256 256"
|
|
10
|
+
strokeWidth="16"
|
|
11
|
+
width={24}
|
|
12
|
+
height={24}
|
|
13
|
+
>
|
|
14
|
+
<rect width="256" height="256" fill="none"></rect>
|
|
15
|
+
<path
|
|
16
|
+
d="M184,184H69.81818L41.92162,30.56892A8,8,0,0,0,34.05066,24H16"
|
|
17
|
+
fill="none"
|
|
18
|
+
stroke="currentColor"
|
|
19
|
+
strokeLinecap="round"
|
|
20
|
+
strokeLinejoin="round"
|
|
21
|
+
></path>
|
|
22
|
+
<circle
|
|
23
|
+
cx="80"
|
|
24
|
+
cy="204"
|
|
25
|
+
r="20"
|
|
26
|
+
fill="none"
|
|
27
|
+
stroke="currentColor"
|
|
28
|
+
strokeLinecap="round"
|
|
29
|
+
strokeLinejoin="round"
|
|
30
|
+
></circle>
|
|
31
|
+
<circle
|
|
32
|
+
cx="184"
|
|
33
|
+
cy="204"
|
|
34
|
+
r="20"
|
|
35
|
+
fill="none"
|
|
36
|
+
stroke="currentColor"
|
|
37
|
+
strokeLinecap="round"
|
|
38
|
+
strokeLinejoin="round"
|
|
39
|
+
></circle>
|
|
40
|
+
<path
|
|
41
|
+
d="M62.54543,144H188.10132a16,16,0,0,0,15.74192-13.13783L216,64H48"
|
|
42
|
+
fill="none"
|
|
43
|
+
stroke="currentColor"
|
|
44
|
+
strokeLinecap="round"
|
|
45
|
+
strokeLinejoin="round"
|
|
46
|
+
></path>
|
|
47
|
+
</svg>
|
|
48
|
+
)
|
|
49
|
+
|
|
50
|
+
export default ShoppingCart
|
package/src/assets/X.tsx
ADDED
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import React from 'react'
|
|
2
|
+
|
|
3
|
+
// Icon from Phosphor Icons
|
|
4
|
+
const X = () => (
|
|
5
|
+
<svg
|
|
6
|
+
id="X"
|
|
7
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
8
|
+
fill="currentColor"
|
|
9
|
+
viewBox="0 0 256 256"
|
|
10
|
+
strokeWidth="16"
|
|
11
|
+
width={24}
|
|
12
|
+
height={24}
|
|
13
|
+
>
|
|
14
|
+
<rect width="256" height="256" fill="none"></rect>
|
|
15
|
+
<line
|
|
16
|
+
x1="200"
|
|
17
|
+
y1="56"
|
|
18
|
+
x2="56"
|
|
19
|
+
y2="200"
|
|
20
|
+
fill="none"
|
|
21
|
+
stroke="currentColor"
|
|
22
|
+
strokeLinecap="round"
|
|
23
|
+
strokeLinejoin="round"
|
|
24
|
+
></line>
|
|
25
|
+
<line
|
|
26
|
+
x1="200"
|
|
27
|
+
y1="200"
|
|
28
|
+
x2="56"
|
|
29
|
+
y2="56"
|
|
30
|
+
fill="none"
|
|
31
|
+
stroke="currentColor"
|
|
32
|
+
strokeLinecap="round"
|
|
33
|
+
strokeLinejoin="round"
|
|
34
|
+
></line>
|
|
35
|
+
</svg>
|
|
36
|
+
)
|
|
37
|
+
|
|
38
|
+
export default X
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
// ----------------------------------------------------------
|
|
2
|
+
// STORE STYLES
|
|
3
|
+
// Layout
|
|
4
|
+
// ----------------------------------------------------------
|
|
5
|
+
|
|
6
|
+
body {
|
|
7
|
+
--fs-body-bkg: var(--fs-color-body-bkg);
|
|
8
|
+
|
|
9
|
+
min-height: 100vh;
|
|
10
|
+
color: var(--fs-color-text);
|
|
11
|
+
background: var(--fs-body-bkg);
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
main,
|
|
15
|
+
.layout__main {
|
|
16
|
+
display: flex;
|
|
17
|
+
flex-wrap: wrap;
|
|
18
|
+
background: var(--fs-body-bkg);
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.layout__section {
|
|
22
|
+
padding-bottom: var(--fs-spacing-4);
|
|
23
|
+
margin-top: var(--fs-spacing-4);
|
|
24
|
+
|
|
25
|
+
@include media(">=notebook") {
|
|
26
|
+
padding-bottom: var(--fs-grid-padding);
|
|
27
|
+
margin-top: var(--fs-grid-padding);
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.layout__content-full {
|
|
32
|
+
width: 100%;
|
|
33
|
+
padding-top: var(--fs-spacing-4);
|
|
34
|
+
padding-bottom: var(--fs-spacing-4);
|
|
35
|
+
|
|
36
|
+
@include media(">=notebook") {
|
|
37
|
+
padding-top: var(--fs-grid-padding);
|
|
38
|
+
padding-bottom: var(--fs-grid-padding);
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
.layout__content {
|
|
43
|
+
box-sizing: border-box;
|
|
44
|
+
width: 100%;
|
|
45
|
+
max-width: var(--fs-grid-breakpoint-notebook);
|
|
46
|
+
padding-right: var(--fs-grid-padding);
|
|
47
|
+
padding-left: var(--fs-grid-padding);
|
|
48
|
+
margin-right: auto;
|
|
49
|
+
margin-left: auto;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
.no-scroll {
|
|
53
|
+
overflow: hidden;
|
|
54
|
+
touch-action: none;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
// Helper class
|
|
58
|
+
.display-mobile {
|
|
59
|
+
@include media(">=notebook") {
|
|
60
|
+
display: none;
|
|
61
|
+
visibility: hidden;
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
// Helper class
|
|
66
|
+
.hidden-mobile {
|
|
67
|
+
@include media("<notebook") {
|
|
68
|
+
display: none;
|
|
69
|
+
visibility: hidden;
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
// Image
|
|
74
|
+
[data-fs-image] {
|
|
75
|
+
width: 100%;
|
|
76
|
+
height: 100%;
|
|
77
|
+
object-fit: cover;
|
|
78
|
+
}
|
|
@@ -0,0 +1,274 @@
|
|
|
1
|
+
// ----------------------------------------------------------
|
|
2
|
+
// STORE TOKENS
|
|
3
|
+
// Base Store Theme
|
|
4
|
+
// ----------------------------------------------------------
|
|
5
|
+
|
|
6
|
+
body {
|
|
7
|
+
// --------------------------------------------------------
|
|
8
|
+
// Colors (Branding Core)
|
|
9
|
+
// --------------------------------------------------------
|
|
10
|
+
|
|
11
|
+
// PALETTE
|
|
12
|
+
// Tone values must range from lightest to darkest.
|
|
13
|
+
// `0` is more suitable for backgrounds, and `4` for texts.
|
|
14
|
+
--fs-color-main-0 : #f1f2f3;
|
|
15
|
+
--fs-color-main-1 : #dbdbdb;
|
|
16
|
+
--fs-color-main-2 : #00419e;
|
|
17
|
+
--fs-color-main-3 : #002c71;
|
|
18
|
+
--fs-color-main-4 : #002155;
|
|
19
|
+
|
|
20
|
+
--fs-color-accent-0 : #e3e6e8;
|
|
21
|
+
--fs-color-accent-1 : #e3e6e8;
|
|
22
|
+
--fs-color-accent-2 : #74808b;
|
|
23
|
+
--fs-color-accent-3 : #5d666f;
|
|
24
|
+
--fs-color-accent-4 : #171a1c;
|
|
25
|
+
|
|
26
|
+
--fs-color-neutral-0 : #ffffff;
|
|
27
|
+
--fs-color-neutral-1 : #f1f2f3;
|
|
28
|
+
--fs-color-neutral-2 : #e3e6e8;
|
|
29
|
+
--fs-color-neutral-3 : #c7ccd1;
|
|
30
|
+
--fs-color-neutral-4 : #9099a2;
|
|
31
|
+
--fs-color-neutral-5 : #74808b;
|
|
32
|
+
--fs-color-neutral-6 : #5d666f;
|
|
33
|
+
--fs-color-neutral-7 : #171a1c;
|
|
34
|
+
|
|
35
|
+
// HIERARCHY
|
|
36
|
+
--fs-color-primary-text : var(--fs-color-text-inverse);
|
|
37
|
+
--fs-color-primary-bkg : var(--fs-color-main-2);
|
|
38
|
+
--fs-color-primary-bkg-hover : var(--fs-color-main-3);
|
|
39
|
+
--fs-color-primary-bkg-active : var(--fs-color-main-4);
|
|
40
|
+
--fs-color-primary-bkg-light : var(--fs-color-main-0);
|
|
41
|
+
--fs-color-primary-bkg-light-active : var(--fs-color-main-1);
|
|
42
|
+
|
|
43
|
+
--fs-color-secondary-text : var(--fs-color-primary-bkg);
|
|
44
|
+
--fs-color-secondary-bkg : transparent;
|
|
45
|
+
--fs-color-secondary-bkg-hover : var(--fs-color-primary-bkg);
|
|
46
|
+
--fs-color-secondary-bkg-active : var(--fs-color-main-3);
|
|
47
|
+
--fs-color-secondary-bkg-light : var(--fs-color-main-0);
|
|
48
|
+
--fs-color-secondary-bkg-light-active: var(--fs-color-secondary-bkg-light);
|
|
49
|
+
|
|
50
|
+
--fs-color-tertiary-text : var(--fs-color-link);
|
|
51
|
+
--fs-color-tertiary-bkg : transparent;
|
|
52
|
+
--fs-color-tertiary-bkg-hover : var(--fs-color-main-0);
|
|
53
|
+
--fs-color-tertiary-bkg-active : var(--fs-color-main-1);
|
|
54
|
+
--fs-color-tertiary-bkg-light : var(--fs-color-neutral-0);
|
|
55
|
+
--fs-color-tertiary-bkg-light-active : var(--fs-color-tertiary-bkg-light);
|
|
56
|
+
|
|
57
|
+
// COMPONENTS & STATES
|
|
58
|
+
--fs-color-body-bkg : var(--fs-color-neutral-0);
|
|
59
|
+
|
|
60
|
+
--fs-color-action-text : var(--fs-color-text-inverse);
|
|
61
|
+
--fs-color-action-bkg : var(--fs-color-accent-4);
|
|
62
|
+
--fs-color-action-bkg-hover : var(--fs-color-accent-3);
|
|
63
|
+
--fs-color-action-bkg-active : var(--fs-color-accent-2);
|
|
64
|
+
--fs-color-action-bkg-light : var(--fs-color-neutral-0);
|
|
65
|
+
--fs-color-action-bkg-light-active : var(--fs-color-tertiary-bkg-light);
|
|
66
|
+
|
|
67
|
+
--fs-color-link : var(--fs-color-main-2);
|
|
68
|
+
--fs-color-link-hover : var(--fs-color-main-2);
|
|
69
|
+
--fs-color-link-active : var(--fs-color-main-4);
|
|
70
|
+
--fs-color-link-visited : #6058ba;
|
|
71
|
+
--fs-color-link-inverse : var(--fs-color-neutral-0);
|
|
72
|
+
|
|
73
|
+
--fs-color-text : var(--fs-color-neutral-7);
|
|
74
|
+
--fs-color-text-light : var(--fs-color-neutral-6);
|
|
75
|
+
--fs-color-text-inverse : var(--fs-color-neutral-0);
|
|
76
|
+
--fs-color-text-display : var(--fs-color-neutral-7);
|
|
77
|
+
|
|
78
|
+
--fs-color-focus-ring : #8db6fa;
|
|
79
|
+
--fs-color-focus-ring-outline : #8db6fa80;
|
|
80
|
+
--fs-color-focus-ring-danger : #e1adad;
|
|
81
|
+
|
|
82
|
+
// SITUATIONS
|
|
83
|
+
--fs-color-success-text : #1e493b;
|
|
84
|
+
--fs-color-success-bkg : #b3ebd5;
|
|
85
|
+
--fs-color-success-border : var(--fs-color-success-text);
|
|
86
|
+
|
|
87
|
+
--fs-color-warning-text : var(--fs-color-text);
|
|
88
|
+
--fs-color-warning-bkg : #fdec8d;
|
|
89
|
+
--fs-color-warning-border : var(--fs-color-warning-text);
|
|
90
|
+
|
|
91
|
+
--fs-color-danger-text : #cb4242;
|
|
92
|
+
--fs-color-danger-bkg : var(--fs-color-focus-ring-danger);
|
|
93
|
+
--fs-color-danger-border : var(--fs-color-danger-text);
|
|
94
|
+
|
|
95
|
+
--fs-color-info-text : var(--fs-color-text);
|
|
96
|
+
--fs-color-info-bkg : var(--fs-color-main-1);
|
|
97
|
+
|
|
98
|
+
--fs-color-highlighted-text : var(--fs-color-text-display);
|
|
99
|
+
--fs-color-highlighted-bkg : var(--fs-color-accent-0);
|
|
100
|
+
|
|
101
|
+
--fs-color-neutral-text : var(--fs-color-text);
|
|
102
|
+
--fs-color-neutral-bkg : var(--fs-color-neutral-1);
|
|
103
|
+
|
|
104
|
+
--fs-color-disabled-text : var(--fs-color-neutral-6);
|
|
105
|
+
--fs-color-disabled-bkg : var(--fs-color-neutral-2);
|
|
106
|
+
|
|
107
|
+
// --------------------------------------------------------
|
|
108
|
+
// Typography (Branding Core)
|
|
109
|
+
// --------------------------------------------------------
|
|
110
|
+
|
|
111
|
+
// FACE
|
|
112
|
+
--fs-text-face-body : -apple-system, system-ui, BlinkMacSystemFont, sans-serif;
|
|
113
|
+
--fs-text-face-title : var(--fs-text-face-body);
|
|
114
|
+
|
|
115
|
+
// WEIGHT
|
|
116
|
+
--fs-text-weight-light : 300;
|
|
117
|
+
--fs-text-weight-regular : 400;
|
|
118
|
+
--fs-text-weight-bold : 700;
|
|
119
|
+
--fs-text-weight-black : 900;
|
|
120
|
+
|
|
121
|
+
// MAX LINES
|
|
122
|
+
--fs-text-max-lines : 2;
|
|
123
|
+
|
|
124
|
+
// TYPOGRAPHY SCALE
|
|
125
|
+
// Use a type scale to add rhythm to your typography and
|
|
126
|
+
// ensure consistency throughout the project.
|
|
127
|
+
// Access https://type-scale.com and pick a scale that
|
|
128
|
+
// suits the store's branding.
|
|
129
|
+
--fs-text-scale-mobile : 1.13;
|
|
130
|
+
--fs-text-scale-desktop : 1.25;
|
|
131
|
+
|
|
132
|
+
--fs-scale : var(--fs-text-scale-mobile);
|
|
133
|
+
|
|
134
|
+
@include media(">=notebook") {
|
|
135
|
+
--fs-scale : var(--fs-text-scale-desktop);
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
// NUMERIC SCALE
|
|
139
|
+
--fs-text-size-base : 16px; // 1rem
|
|
140
|
+
|
|
141
|
+
--fs-text-size-0 : 12px; // Smallest
|
|
142
|
+
--fs-text-size-1 : 14px; // Smaller // Mobile Desktop
|
|
143
|
+
--fs-text-size-2 : var(--fs-text-size-base); // 16px 16px
|
|
144
|
+
--fs-text-size-3 : calc(var(--fs-text-size-2) * var(--fs-scale)); // 18px 20px
|
|
145
|
+
--fs-text-size-4 : calc(var(--fs-text-size-3) * var(--fs-scale)); // 20px 25px
|
|
146
|
+
--fs-text-size-5 : calc(var(--fs-text-size-4) * var(--fs-scale)); // 23px 31px
|
|
147
|
+
--fs-text-size-6 : calc(var(--fs-text-size-5) * var(--fs-scale)); // 26px 39px
|
|
148
|
+
--fs-text-size-7 : calc(var(--fs-text-size-6) * var(--fs-scale)); // 29px 48px
|
|
149
|
+
--fs-text-size-8 : calc(var(--fs-text-size-7) * var(--fs-scale)); // 33px 61px
|
|
150
|
+
|
|
151
|
+
// HIERARCHY SCALE
|
|
152
|
+
--fs-text-size-title-huge : var(--fs-text-size-7);
|
|
153
|
+
--fs-text-size-title-page : var(--fs-text-size-6);
|
|
154
|
+
--fs-text-size-title-product : var(--fs-text-size-4);
|
|
155
|
+
--fs-text-size-title-section : var(--fs-text-size-4);
|
|
156
|
+
--fs-text-size-title-subsection : var(--fs-text-size-4);
|
|
157
|
+
--fs-text-size-title-mini : var(--fs-text-size-4);
|
|
158
|
+
--fs-text-size-lead : var(--fs-text-size-3);
|
|
159
|
+
--fs-text-size-menu : var(--fs-text-size-base);
|
|
160
|
+
--fs-text-size-body : var(--fs-text-size-base);
|
|
161
|
+
--fs-text-size-legend : var(--fs-text-size-1);
|
|
162
|
+
--fs-text-size-tiny : var(--fs-text-size-0);
|
|
163
|
+
|
|
164
|
+
// --------------------------------------------------------
|
|
165
|
+
// Spacing (UI Essentials)
|
|
166
|
+
// --------------------------------------------------------
|
|
167
|
+
|
|
168
|
+
// NUMERIC SCALE
|
|
169
|
+
--fs-spacing-0 : .25rem; // 4px
|
|
170
|
+
--fs-spacing-1 : .5rem; // 8px
|
|
171
|
+
--fs-spacing-2 : .75rem; // 12px
|
|
172
|
+
--fs-spacing-3 : 1rem; // 16px (--fs-text-size-base)
|
|
173
|
+
--fs-spacing-4 : 1.5rem; // 24px
|
|
174
|
+
--fs-spacing-5 : 2rem; // 32px
|
|
175
|
+
--fs-spacing-6 : 2.5rem; // 40px
|
|
176
|
+
--fs-spacing-7 : 3rem; // 48px
|
|
177
|
+
--fs-spacing-8 : 3.5rem; // 56px
|
|
178
|
+
--fs-spacing-9 : 4rem; // 64px
|
|
179
|
+
--fs-spacing-10 : 4.5rem; // 72px
|
|
180
|
+
--fs-spacing-11 : 5rem; // 80px
|
|
181
|
+
--fs-spacing-12 : 5.5rem; // 88px
|
|
182
|
+
--fs-spacing-13 : 6rem; // 96px
|
|
183
|
+
|
|
184
|
+
// --------------------------------------------------------
|
|
185
|
+
// Grid & Layout (UI Essentials)
|
|
186
|
+
// --------------------------------------------------------
|
|
187
|
+
|
|
188
|
+
// PADDING
|
|
189
|
+
--fs-grid-padding : var(--fs-spacing-3);
|
|
190
|
+
|
|
191
|
+
@include media(">=tablet") {
|
|
192
|
+
--fs-grid-padding : var(--fs-spacing-4);
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
@include media(">=notebook") {
|
|
196
|
+
--fs-grid-padding : var(--fs-spacing-5);
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
// Z-INDEX
|
|
200
|
+
--fs-z-index-below : -1;
|
|
201
|
+
--fs-z-index-default : 0;
|
|
202
|
+
--fs-z-index-top : 1;
|
|
203
|
+
--fs-z-index-high : 2;
|
|
204
|
+
--fs-z-index-highest : 3;
|
|
205
|
+
|
|
206
|
+
// CONTAINER
|
|
207
|
+
--fs-grid-max-width : var(--fs-grid-breakpoint-notebook);
|
|
208
|
+
|
|
209
|
+
// GAPS
|
|
210
|
+
--fs-grid-gap-0 : var(--fs-spacing-1);
|
|
211
|
+
--fs-grid-gap-1 : var(--fs-spacing-2);
|
|
212
|
+
--fs-grid-gap-2 : var(--fs-spacing-3);
|
|
213
|
+
--fs-grid-gap-3 : var(--fs-spacing-4);
|
|
214
|
+
--fs-grid-gap-4 : var(--fs-spacing-5);
|
|
215
|
+
|
|
216
|
+
// BREAKPOINTS
|
|
217
|
+
--fs-grid-breakpoint-phone : #{map-get($breakpoints, "phone")};
|
|
218
|
+
--fs-grid-breakpoint-phonemid : #{map-get($breakpoints, "phonemid")};
|
|
219
|
+
--fs-grid-breakpoint-tablet : #{map-get($breakpoints, "tablet")};
|
|
220
|
+
--fs-grid-breakpoint-notebook : #{map-get($breakpoints, "notebook")};
|
|
221
|
+
--fs-grid-breakpoint-desktop : #{map-get($breakpoints, "desktop")};
|
|
222
|
+
|
|
223
|
+
// --------------------------------------------------------
|
|
224
|
+
// Interactive Controls (UI Essentials)
|
|
225
|
+
// --------------------------------------------------------
|
|
226
|
+
|
|
227
|
+
// TAP
|
|
228
|
+
--fs-control-tap-size : var(--fs-spacing-7); // 3rem = 48px
|
|
229
|
+
--fs-control-tap-size-smallest : calc(var(--fs-control-tap-size) / 2);
|
|
230
|
+
--fs-control-min-height : var(--fs-control-tap-size);
|
|
231
|
+
|
|
232
|
+
@include media(">=notebook") {
|
|
233
|
+
--fs-control-tap-size : var(--fs-spacing-7); // This value can be smaller on desktops
|
|
234
|
+
}
|
|
235
|
+
|
|
236
|
+
// STATES
|
|
237
|
+
--fs-control-bkg : var(--fs-color-neutral-0);
|
|
238
|
+
--fs-control-bkg-disabled : var(--fs-color-disabled-bkg);
|
|
239
|
+
|
|
240
|
+
// --------------------------------------------------------
|
|
241
|
+
// Refinements
|
|
242
|
+
// --------------------------------------------------------
|
|
243
|
+
|
|
244
|
+
// TRANSITION
|
|
245
|
+
--fs-transition-timing : .2s;
|
|
246
|
+
--fs-transition-property : all;
|
|
247
|
+
--fs-transition-function : ease-in-out;
|
|
248
|
+
|
|
249
|
+
// BORDERS
|
|
250
|
+
--fs-border-radius-small : 1px;
|
|
251
|
+
--fs-border-radius : 2px;
|
|
252
|
+
--fs-border-radius-medium : 8px;
|
|
253
|
+
--fs-border-radius-pill : 100px;
|
|
254
|
+
--fs-border-radius-circle : 100%;
|
|
255
|
+
|
|
256
|
+
--fs-border-width : 1px;
|
|
257
|
+
--fs-border-width-thick : 2px;
|
|
258
|
+
--fs-border-width-thickest : 3px;
|
|
259
|
+
|
|
260
|
+
--fs-border-color : var(--fs-color-neutral-4);
|
|
261
|
+
--fs-border-color-hover : var(--fs-color-main-3);
|
|
262
|
+
--fs-border-color-active : var(--fs-color-main-2);
|
|
263
|
+
--fs-border-color-disabled : var(--fs-color-neutral-6);
|
|
264
|
+
|
|
265
|
+
--fs-border-color-light : var(--fs-color-neutral-2);
|
|
266
|
+
--fs-border-color-light-hover : var(--fs-color-neutral-3);
|
|
267
|
+
--fs-border-color-light-active : var(--fs-color-neutral-3);
|
|
268
|
+
--fs-border-color-light-disabled : var(--fs-color-neutral-5);
|
|
269
|
+
|
|
270
|
+
// SHADOW
|
|
271
|
+
--fs-shadow : none;
|
|
272
|
+
--fs-shadow-darker : 0 0 10px rgb(0 0 0 / 20%);
|
|
273
|
+
--fs-shadow-hover : 0 0 0 1px var(--fs-color-main-4);
|
|
274
|
+
}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
// ----------------------------------------------------------
|
|
2
|
+
// STORE STYLES
|
|
3
|
+
// Typography (Text)
|
|
4
|
+
// ----------------------------------------------------------
|
|
5
|
+
|
|
6
|
+
body {
|
|
7
|
+
font-family: var(--fs-text-face-body);
|
|
8
|
+
font-size: var(--fs-text-size-base);
|
|
9
|
+
letter-spacing: .01em;
|
|
10
|
+
-webkit-font-smoothing: antialiased;
|
|
11
|
+
-moz-osx-font-smoothing: grayscale;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
h1, h2, h3, h4, h5, h6, p, ul {
|
|
15
|
+
padding: 0;
|
|
16
|
+
margin: 0;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
.text__title-section {
|
|
20
|
+
font-size: var(--fs-text-size-4);
|
|
21
|
+
font-weight: var(--fs-text-weight-bold);
|
|
22
|
+
line-height: 1.16;
|
|
23
|
+
|
|
24
|
+
@include media(">=notebook") { font-size: var(--fs-text-size-5); }
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
.text__title-subsection {
|
|
28
|
+
font-size: var(--fs-text-size-3);
|
|
29
|
+
font-weight: var(--fs-text-weight-bold);
|
|
30
|
+
line-height: 1.2;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
.text__title-mini {
|
|
34
|
+
font-size: var(--fs-text-size-2);
|
|
35
|
+
font-weight: var(--fs-text-weight-bold);
|
|
36
|
+
line-height: 1.25;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
// TODO: Can we replace this with `.text__body`?
|
|
40
|
+
.text__title-mini-alt {
|
|
41
|
+
font-size: var(--fs-text-size-2);
|
|
42
|
+
line-height: 1.25;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
.text__lead {
|
|
46
|
+
font-size: var(--fs-text-size-4);
|
|
47
|
+
font-weight: var(--fs-text-weight-bold);
|
|
48
|
+
line-height: 1.12;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
.text__body {
|
|
52
|
+
font-size: var(--fs-text-size-2);
|
|
53
|
+
line-height: 1.5;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
.text__legend {
|
|
57
|
+
font-size: var(--fs-text-size-1);
|
|
58
|
+
line-height: 1.7;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
.text__tiny {
|
|
62
|
+
font-size: var(--fs-text-size-0);
|
|
63
|
+
line-height: 1.5;
|
|
64
|
+
}
|