@dropins/tools 0.21.1 → 0.21.2-alpha2
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/components/Accordion/Accordion.d.ts +25 -0
- package/components/Accordion/Accordion.d.ts.map +1 -0
- package/components/Accordion/Accordion.jsx +59 -0
- package/components/Accordion/Accordion.stories.d.ts +22 -0
- package/components/Accordion/Accordion.stories.d.ts.map +1 -0
- package/components/Accordion/Accordion.stories.jsx +320 -0
- package/components/Accordion/Accordion.test.d.ts +3 -0
- package/components/Accordion/Accordion.test.d.ts.map +1 -0
- package/components/Accordion/Accordion.test.jsx +79 -0
- package/components/Accordion/index.d.ts +3 -0
- package/components/Accordion/index.d.ts.map +1 -0
- package/components/Accordion/index.js +2 -0
- package/components/ActionButton/ActionButton.d.ts +11 -0
- package/components/ActionButton/ActionButton.d.ts.map +1 -0
- package/components/ActionButton/ActionButton.jsx +14 -0
- package/components/ActionButton/ActionButton.stories.d.ts +16 -0
- package/components/ActionButton/ActionButton.stories.d.ts.map +1 -0
- package/components/ActionButton/ActionButton.stories.jsx +119 -0
- package/components/ActionButton/ActionButton.test.d.ts +3 -0
- package/components/ActionButton/ActionButton.test.d.ts.map +1 -0
- package/components/ActionButton/ActionButton.test.jsx +47 -0
- package/components/ActionButton/index.d.ts +2 -0
- package/components/ActionButton/index.d.ts.map +1 -0
- package/components/ActionButton/index.js +1 -0
- package/components/ActionButtonGroup/ActionButtonGroup.d.ts +20 -0
- package/components/ActionButtonGroup/ActionButtonGroup.d.ts.map +1 -0
- package/components/ActionButtonGroup/ActionButtonGroup.jsx +39 -0
- package/components/ActionButtonGroup/ActionButtonGroup.stories.d.ts +16 -0
- package/components/ActionButtonGroup/ActionButtonGroup.stories.d.ts.map +1 -0
- package/components/ActionButtonGroup/ActionButtonGroup.stories.jsx +72 -0
- package/components/ActionButtonGroup/ActionButtonGroup.test.d.ts +3 -0
- package/components/ActionButtonGroup/ActionButtonGroup.test.d.ts.map +1 -0
- package/components/ActionButtonGroup/ActionButtonGroup.test.jsx +78 -0
- package/components/ActionButtonGroup/index.d.ts +2 -0
- package/components/ActionButtonGroup/index.d.ts.map +1 -0
- package/components/ActionButtonGroup/index.js +1 -0
- package/components/AlertBanner/AlertBanner.d.ts +15 -0
- package/components/AlertBanner/AlertBanner.d.ts.map +1 -0
- package/components/AlertBanner/AlertBanner.jsx +30 -0
- package/components/AlertBanner/AlertBanner.stories.d.ts +17 -0
- package/components/AlertBanner/AlertBanner.stories.d.ts.map +1 -0
- package/components/AlertBanner/AlertBanner.stories.jsx +128 -0
- package/components/AlertBanner/AlertBanner.test.d.ts +3 -0
- package/components/AlertBanner/AlertBanner.test.d.ts.map +1 -0
- package/components/AlertBanner/AlertBanner.test.jsx +40 -0
- package/components/AlertBanner/index.d.ts +3 -0
- package/components/AlertBanner/index.d.ts.map +1 -0
- package/components/AlertBanner/index.js +2 -0
- package/components/Breadcrumbs/Breadcrumbs.d.ts +9 -0
- package/components/Breadcrumbs/Breadcrumbs.d.ts.map +1 -0
- package/components/Breadcrumbs/Breadcrumbs.jsx +26 -0
- package/components/Breadcrumbs/Breadcrumbs.stories.d.ts +15 -0
- package/components/Breadcrumbs/Breadcrumbs.stories.d.ts.map +1 -0
- package/components/Breadcrumbs/Breadcrumbs.stories.jsx +110 -0
- package/components/Breadcrumbs/Breadcrumbs.test.d.ts +3 -0
- package/components/Breadcrumbs/Breadcrumbs.test.d.ts.map +1 -0
- package/components/Breadcrumbs/Breadcrumbs.test.jsx +67 -0
- package/components/Breadcrumbs/index.d.ts +3 -0
- package/components/Breadcrumbs/index.d.ts.map +1 -0
- package/components/Breadcrumbs/index.js +2 -0
- package/components/Button/Button.d.ts +15 -0
- package/components/Button/Button.d.ts.map +1 -0
- package/components/Button/Button.jsx +59 -0
- package/components/Button/Button.stories.d.ts +135 -0
- package/components/Button/Button.stories.d.ts.map +1 -0
- package/components/Button/Button.stories.jsx +354 -0
- package/components/Button/Button.test.d.ts +2 -0
- package/components/Button/Button.test.d.ts.map +1 -0
- package/components/Button/Button.test.jsx +134 -0
- package/components/Button/index.d.ts +3 -0
- package/components/Button/index.d.ts.map +1 -0
- package/components/Button/index.js +2 -0
- package/components/Card/Card.d.ts +9 -0
- package/components/Card/Card.d.ts.map +1 -0
- package/components/Card/Card.jsx +7 -0
- package/components/Card/Card.stories.d.ts +16 -0
- package/components/Card/Card.stories.d.ts.map +1 -0
- package/components/Card/Card.stories.jsx +47 -0
- package/components/Card/Card.test.d.ts +3 -0
- package/components/Card/Card.test.d.ts.map +1 -0
- package/components/Card/Card.test.jsx +26 -0
- package/components/Card/index.d.ts +2 -0
- package/components/Card/index.d.ts.map +1 -0
- package/components/Card/index.js +1 -0
- package/components/CartItem/CartItem.d.ts +25 -0
- package/components/CartItem/CartItem.d.ts.map +1 -0
- package/components/CartItem/CartItem.jsx +124 -0
- package/components/CartItem/CartItem.stories.d.ts +54 -0
- package/components/CartItem/CartItem.stories.d.ts.map +1 -0
- package/components/CartItem/CartItem.stories.jsx +309 -0
- package/components/CartItem/CartItem.test.d.ts +3 -0
- package/components/CartItem/CartItem.test.d.ts.map +1 -0
- package/components/CartItem/CartItem.test.jsx +71 -0
- package/components/CartItem/CartItemSkeleton.d.ts +3 -0
- package/components/CartItem/CartItemSkeleton.d.ts.map +1 -0
- package/components/CartItem/CartItemSkeleton.jsx +25 -0
- package/components/CartItem/CartItemSkeleton.test.d.ts +3 -0
- package/components/CartItem/CartItemSkeleton.test.d.ts.map +1 -0
- package/components/CartItem/CartItemSkeleton.test.jsx +11 -0
- package/components/CartItem/index.d.ts +4 -0
- package/components/CartItem/index.d.ts.map +1 -0
- package/components/CartItem/index.js +3 -0
- package/components/CartList/CartList.d.ts +7 -0
- package/components/CartList/CartList.d.ts.map +1 -0
- package/components/CartList/CartList.jsx +14 -0
- package/components/CartList/CartList.stories.d.ts +17 -0
- package/components/CartList/CartList.stories.d.ts.map +1 -0
- package/components/CartList/CartList.stories.jsx +54 -0
- package/components/CartList/CartList.test.d.ts +3 -0
- package/components/CartList/CartList.test.d.ts.map +1 -0
- package/components/CartList/CartList.test.jsx +12 -0
- package/components/CartList/index.d.ts +3 -0
- package/components/CartList/index.d.ts.map +1 -0
- package/components/CartList/index.js +2 -0
- package/components/Checkbox/Checkbox.d.ts +13 -0
- package/components/Checkbox/Checkbox.d.ts.map +1 -0
- package/components/Checkbox/Checkbox.jsx +51 -0
- package/components/Checkbox/Checkbox.stories.d.ts +22 -0
- package/components/Checkbox/Checkbox.stories.d.ts.map +1 -0
- package/components/Checkbox/Checkbox.stories.jsx +157 -0
- package/components/Checkbox/Checkbox.test.d.ts +3 -0
- package/components/Checkbox/Checkbox.test.d.ts.map +1 -0
- package/components/Checkbox/Checkbox.test.jsx +136 -0
- package/components/Checkbox/index.d.ts +2 -0
- package/components/Checkbox/index.d.ts.map +1 -0
- package/components/Checkbox/index.js +1 -0
- package/components/ColorSwatch/ColorSwatch.d.ts +20 -0
- package/components/ColorSwatch/ColorSwatch.d.ts.map +1 -0
- package/components/ColorSwatch/ColorSwatch.jsx +57 -0
- package/components/ColorSwatch/ColorSwatch.stories.d.ts +20 -0
- package/components/ColorSwatch/ColorSwatch.stories.d.ts.map +1 -0
- package/components/ColorSwatch/ColorSwatch.stories.jsx +206 -0
- package/components/ColorSwatch/ColorSwatch.test.d.ts +3 -0
- package/components/ColorSwatch/ColorSwatch.test.d.ts.map +1 -0
- package/components/ColorSwatch/ColorSwatch.test.jsx +87 -0
- package/components/ColorSwatch/index.d.ts +3 -0
- package/components/ColorSwatch/index.d.ts.map +1 -0
- package/components/ColorSwatch/index.js +2 -0
- package/components/Divider/Divider.d.ts +8 -0
- package/components/Divider/Divider.d.ts.map +1 -0
- package/components/Divider/Divider.jsx +9 -0
- package/components/Divider/Divider.stories.d.ts +11 -0
- package/components/Divider/Divider.stories.d.ts.map +1 -0
- package/components/Divider/Divider.stories.jsx +43 -0
- package/components/Divider/Divider.test.d.ts +2 -0
- package/components/Divider/Divider.test.d.ts.map +1 -0
- package/components/Divider/Divider.test.jsx +19 -0
- package/components/Divider/index.d.ts +3 -0
- package/components/Divider/index.d.ts.map +1 -0
- package/components/Divider/index.js +2 -0
- package/components/Field/Field.d.ts +14 -0
- package/components/Field/Field.d.ts.map +1 -0
- package/components/Field/Field.jsx +29 -0
- package/components/Field/Field.stories.d.ts +37 -0
- package/components/Field/Field.stories.d.ts.map +1 -0
- package/components/Field/Field.stories.jsx +174 -0
- package/components/Field/Field.test.d.ts +3 -0
- package/components/Field/Field.test.d.ts.map +1 -0
- package/components/Field/Field.test.jsx +91 -0
- package/components/Field/index.d.ts +2 -0
- package/components/Field/index.d.ts.map +1 -0
- package/components/Field/index.js +1 -0
- package/components/Icon/Icon.d.ts +11 -0
- package/components/Icon/Icon.d.ts.map +1 -0
- package/components/Icon/Icon.jsx +57 -0
- package/components/Icon/Icon.stories.d.ts +16 -0
- package/components/Icon/Icon.stories.d.ts.map +1 -0
- package/components/Icon/Icon.stories.helpers.d.ts +4 -0
- package/components/Icon/Icon.stories.helpers.d.ts.map +1 -0
- package/components/Icon/Icon.stories.helpers.jsx +7 -0
- package/components/Icon/Icon.stories.jsx +48 -0
- package/components/Icon/Icon.test.d.ts +3 -0
- package/components/Icon/Icon.test.d.ts.map +1 -0
- package/components/Icon/Icon.test.jsx +67 -0
- package/components/Icon/index.d.ts +2 -0
- package/components/Icon/index.d.ts.map +1 -0
- package/components/Icon/index.js +1 -0
- package/components/IllustratedMessage/IllustratedMessage.d.ts +13 -0
- package/components/IllustratedMessage/IllustratedMessage.d.ts.map +1 -0
- package/components/IllustratedMessage/IllustratedMessage.jsx +21 -0
- package/components/IllustratedMessage/IllustratedMessage.stories.d.ts +10 -0
- package/components/IllustratedMessage/IllustratedMessage.stories.d.ts.map +1 -0
- package/components/IllustratedMessage/IllustratedMessage.stories.jsx +90 -0
- package/components/IllustratedMessage/IllustratedMessage.test.d.ts +3 -0
- package/components/IllustratedMessage/IllustratedMessage.test.d.ts.map +1 -0
- package/components/IllustratedMessage/IllustratedMessage.test.jsx +42 -0
- package/components/IllustratedMessage/index.d.ts +3 -0
- package/components/IllustratedMessage/index.d.ts.map +1 -0
- package/components/IllustratedMessage/index.js +2 -0
- package/components/Image/Image.d.ts +11 -0
- package/components/Image/Image.d.ts.map +1 -0
- package/components/Image/Image.jsx +26 -0
- package/components/Image/Image.stories.d.ts +11 -0
- package/components/Image/Image.stories.d.ts.map +1 -0
- package/components/Image/Image.stories.jsx +66 -0
- package/components/Image/Image.test.d.ts +3 -0
- package/components/Image/Image.test.d.ts.map +1 -0
- package/components/Image/Image.test.jsx +82 -0
- package/components/Image/index.d.ts +2 -0
- package/components/Image/index.d.ts.map +1 -0
- package/components/Image/index.js +1 -0
- package/components/ImageSwatch/ImageSwatch.d.ts +20 -0
- package/components/ImageSwatch/ImageSwatch.d.ts.map +1 -0
- package/components/ImageSwatch/ImageSwatch.jsx +49 -0
- package/components/ImageSwatch/ImageSwatch.stories.d.ts +20 -0
- package/components/ImageSwatch/ImageSwatch.stories.d.ts.map +1 -0
- package/components/ImageSwatch/ImageSwatch.stories.jsx +206 -0
- package/components/ImageSwatch/ImageSwatch.test.d.ts +3 -0
- package/components/ImageSwatch/ImageSwatch.test.d.ts.map +1 -0
- package/components/ImageSwatch/ImageSwatch.test.jsx +64 -0
- package/components/ImageSwatch/index.d.ts +3 -0
- package/components/ImageSwatch/index.d.ts.map +1 -0
- package/components/ImageSwatch/index.js +2 -0
- package/components/InLineAlert/InLineAlert.d.ts +16 -0
- package/components/InLineAlert/InLineAlert.d.ts.map +1 -0
- package/components/InLineAlert/InLineAlert.jsx +38 -0
- package/components/InLineAlert/InLineAlert.stories.d.ts +86 -0
- package/components/InLineAlert/InLineAlert.stories.d.ts.map +1 -0
- package/components/InLineAlert/InLineAlert.stories.jsx +193 -0
- package/components/InLineAlert/InLineAlert.test.d.ts +3 -0
- package/components/InLineAlert/InLineAlert.test.d.ts.map +1 -0
- package/components/InLineAlert/InLineAlert.test.jsx +77 -0
- package/components/InLineAlert/index.d.ts +3 -0
- package/components/InLineAlert/index.d.ts.map +1 -0
- package/components/InLineAlert/index.js +2 -0
- package/components/Incrementer/Incrementer.d.ts +17 -0
- package/components/Incrementer/Incrementer.d.ts.map +1 -0
- package/components/Incrementer/Incrementer.jsx +87 -0
- package/components/Incrementer/Incrementer.stories.d.ts +10 -0
- package/components/Incrementer/Incrementer.stories.d.ts.map +1 -0
- package/components/Incrementer/Incrementer.stories.jsx +68 -0
- package/components/Incrementer/Incrementer.test.d.ts +3 -0
- package/components/Incrementer/Incrementer.test.d.ts.map +1 -0
- package/components/Incrementer/Incrementer.test.jsx +112 -0
- package/components/Incrementer/index.d.ts +2 -0
- package/components/Incrementer/index.d.ts.map +1 -0
- package/components/Incrementer/index.js +1 -0
- package/components/Input/Input.d.ts +19 -0
- package/components/Input/Input.d.ts.map +1 -0
- package/components/Input/Input.jsx +73 -0
- package/components/Input/Input.stories.d.ts +11 -0
- package/components/Input/Input.stories.d.ts.map +1 -0
- package/components/Input/Input.stories.jsx +115 -0
- package/components/Input/Input.test.d.ts +3 -0
- package/components/Input/Input.test.d.ts.map +1 -0
- package/components/Input/Input.test.jsx +111 -0
- package/components/Input/index.d.ts +3 -0
- package/components/Input/index.d.ts.map +1 -0
- package/components/Input/index.js +2 -0
- package/components/Modal/Modal.d.ts +15 -0
- package/components/Modal/Modal.d.ts.map +1 -0
- package/components/Modal/Modal.jsx +93 -0
- package/components/Modal/Modal.stories.d.ts +56 -0
- package/components/Modal/Modal.stories.d.ts.map +1 -0
- package/components/Modal/Modal.stories.jsx +189 -0
- package/components/Modal/Modal.test.d.ts +3 -0
- package/components/Modal/Modal.test.d.ts.map +1 -0
- package/components/Modal/Modal.test.jsx +85 -0
- package/components/Modal/index.d.ts +2 -0
- package/components/Modal/index.d.ts.map +1 -0
- package/components/Modal/index.js +14 -0
- package/components/Picker/Picker.d.ts +26 -0
- package/components/Picker/Picker.d.ts.map +1 -0
- package/components/Picker/Picker.jsx +81 -0
- package/components/Picker/Picker.stories.d.ts +22 -0
- package/components/Picker/Picker.stories.d.ts.map +1 -0
- package/components/Picker/Picker.stories.jsx +236 -0
- package/components/Picker/Picker.test.d.ts +2 -0
- package/components/Picker/Picker.test.d.ts.map +1 -0
- package/components/Picker/Picker.test.jsx +190 -0
- package/components/Picker/index.d.ts +2 -0
- package/components/Picker/index.d.ts.map +1 -0
- package/components/Picker/index.js +1 -0
- package/components/Price/Price.d.ts +17 -0
- package/components/Price/Price.d.ts.map +1 -0
- package/components/Price/Price.jsx +24 -0
- package/components/Price/Price.stories.d.ts +17 -0
- package/components/Price/Price.stories.d.ts.map +1 -0
- package/components/Price/Price.stories.jsx +78 -0
- package/components/Price/Price.test.d.ts +3 -0
- package/components/Price/Price.test.d.ts.map +1 -0
- package/components/Price/Price.test.jsx +68 -0
- package/components/Price/index.d.ts +2 -0
- package/components/Price/index.d.ts.map +1 -0
- package/components/Price/index.js +1 -0
- package/components/PriceRange/PriceRange.d.ts +17 -0
- package/components/PriceRange/PriceRange.d.ts.map +1 -0
- package/components/PriceRange/PriceRange.jsx +75 -0
- package/components/PriceRange/PriceRange.stories.d.ts +107 -0
- package/components/PriceRange/PriceRange.stories.d.ts.map +1 -0
- package/components/PriceRange/PriceRange.stories.jsx +210 -0
- package/components/PriceRange/PriceRange.test.d.ts +3 -0
- package/components/PriceRange/PriceRange.test.d.ts.map +1 -0
- package/components/PriceRange/PriceRange.test.jsx +188 -0
- package/components/PriceRange/index.d.ts +3 -0
- package/components/PriceRange/index.d.ts.map +1 -0
- package/components/PriceRange/index.js +2 -0
- package/components/PriceSummary/PriceSummary.d.ts +43 -0
- package/components/PriceSummary/PriceSummary.d.ts.map +1 -0
- package/components/PriceSummary/PriceSummary.jsx +228 -0
- package/components/PriceSummary/PriceSummary.stories.d.ts +127 -0
- package/components/PriceSummary/PriceSummary.stories.d.ts.map +1 -0
- package/components/PriceSummary/PriceSummary.stories.jsx +456 -0
- package/components/PriceSummary/PriceSummary.test.d.ts +3 -0
- package/components/PriceSummary/PriceSummary.test.d.ts.map +1 -0
- package/components/PriceSummary/PriceSummary.test.jsx +275 -0
- package/components/PriceSummary/index.d.ts +3 -0
- package/components/PriceSummary/index.d.ts.map +1 -0
- package/components/PriceSummary/index.js +2 -0
- package/components/ProgressSpinner/ProgressSpinner.d.ts +14 -0
- package/components/ProgressSpinner/ProgressSpinner.d.ts.map +1 -0
- package/components/ProgressSpinner/ProgressSpinner.jsx +31 -0
- package/components/ProgressSpinner/ProgressSpinner.stories.d.ts +19 -0
- package/components/ProgressSpinner/ProgressSpinner.stories.d.ts.map +1 -0
- package/components/ProgressSpinner/ProgressSpinner.stories.jsx +195 -0
- package/components/ProgressSpinner/ProgressSpinner.test.d.ts +3 -0
- package/components/ProgressSpinner/ProgressSpinner.test.d.ts.map +1 -0
- package/components/ProgressSpinner/ProgressSpinner.test.jsx +40 -0
- package/components/ProgressSpinner/index.d.ts +3 -0
- package/components/ProgressSpinner/index.d.ts.map +1 -0
- package/components/ProgressSpinner/index.js +2 -0
- package/components/RadioButton/RadioButton.d.ts +15 -0
- package/components/RadioButton/RadioButton.d.ts.map +1 -0
- package/components/RadioButton/RadioButton.jsx +31 -0
- package/components/RadioButton/RadioButton.stories.d.ts +15 -0
- package/components/RadioButton/RadioButton.stories.d.ts.map +1 -0
- package/components/RadioButton/RadioButton.stories.jsx +92 -0
- package/components/RadioButton/RadioButton.test.d.ts +3 -0
- package/components/RadioButton/RadioButton.test.d.ts.map +1 -0
- package/components/RadioButton/RadioButton.test.jsx +62 -0
- package/components/RadioButton/index.d.ts +3 -0
- package/components/RadioButton/index.d.ts.map +1 -0
- package/components/RadioButton/index.js +2 -0
- package/components/Skeleton/Skeleton.d.ts +17 -0
- package/components/Skeleton/Skeleton.d.ts.map +1 -0
- package/components/Skeleton/Skeleton.jsx +52 -0
- package/components/Skeleton/Skeleton.stories.d.ts +67 -0
- package/components/Skeleton/Skeleton.stories.d.ts.map +1 -0
- package/components/Skeleton/Skeleton.stories.jsx +184 -0
- package/components/Skeleton/Skeleton.test.d.ts +3 -0
- package/components/Skeleton/Skeleton.test.d.ts.map +1 -0
- package/components/Skeleton/Skeleton.test.jsx +62 -0
- package/components/Skeleton/index.d.ts +2 -0
- package/components/Skeleton/index.d.ts.map +1 -0
- package/components/Skeleton/index.js +1 -0
- package/components/TextSwatch/TextSwatch.d.ts +18 -0
- package/components/TextSwatch/TextSwatch.d.ts.map +1 -0
- package/components/TextSwatch/TextSwatch.jsx +56 -0
- package/components/TextSwatch/TextSwatch.stories.d.ts +21 -0
- package/components/TextSwatch/TextSwatch.stories.d.ts.map +1 -0
- package/components/TextSwatch/TextSwatch.stories.jsx +211 -0
- package/components/TextSwatch/TextSwatch.test.d.ts +3 -0
- package/components/TextSwatch/TextSwatch.test.d.ts.map +1 -0
- package/components/TextSwatch/TextSwatch.test.jsx +85 -0
- package/components/TextSwatch/index.d.ts +3 -0
- package/components/TextSwatch/index.d.ts.map +1 -0
- package/components/TextSwatch/index.js +2 -0
- package/components/UIProvider/UIProvider.d.ts +18 -0
- package/components/UIProvider/UIProvider.d.ts.map +1 -0
- package/components/UIProvider/UIProvider.jsx +26 -0
- package/components/UIProvider/UIProvider.test.d.ts +2 -0
- package/components/UIProvider/UIProvider.test.d.ts.map +1 -0
- package/components/UIProvider/UIProvider.test.jsx +9 -0
- package/components/UIProvider/index.d.ts +2 -0
- package/components/UIProvider/index.d.ts.map +1 -0
- package/components/UIProvider/index.js +1 -0
- package/components/index.d.ts +34 -0
- package/components/index.d.ts.map +1 -0
- package/components/index.js +33 -0
- package/docs/Design/designBlocks.d.ts +21 -0
- package/docs/Design/designBlocks.d.ts.map +1 -0
- package/docs/Design/designBlocks.jsx +59 -0
- package/docs/Design/getTokenData.d.ts +7 -0
- package/docs/Design/getTokenData.d.ts.map +1 -0
- package/docs/Design/getTokenData.js +18 -0
- package/docs/Design/getTokenData.test.d.ts +2 -0
- package/docs/Design/getTokenData.test.d.ts.map +1 -0
- package/docs/Design/getTokenData.test.js +92 -0
- package/event-bus.js +49 -1
- package/fetch-graphql.js +62 -1
- package/i18n/en_US.json +112 -0
- package/i18n/index.d.ts +341 -0
- package/i18n/index.d.ts.map +1 -0
- package/i18n/index.js +12 -0
- package/i18n/index.test.d.ts +2 -0
- package/i18n/index.test.d.ts.map +1 -0
- package/i18n/index.test.js +11 -0
- package/icons/index.d.ts +35 -0
- package/icons/index.d.ts.map +1 -0
- package/icons/index.js +34 -0
- package/initializer.js +61 -1
- package/lib/classes.d.ts +5 -0
- package/lib/classes.d.ts.map +1 -0
- package/lib/classes.js +16 -0
- package/lib/classes.test.d.ts +2 -0
- package/lib/classes.test.d.ts.map +1 -0
- package/lib/classes.test.js +18 -0
- package/lib/config.d.ts +7 -0
- package/lib/config.d.ts.map +1 -0
- package/lib/config.js +12 -0
- package/lib/config.test.d.ts +2 -0
- package/lib/config.test.d.ts.map +1 -0
- package/lib/config.test.js +12 -0
- package/lib/debounce.d.ts +2 -0
- package/lib/debounce.d.ts.map +1 -0
- package/lib/debounce.js +7 -0
- package/lib/debounce.test.d.ts +2 -0
- package/lib/debounce.test.d.ts.map +1 -0
- package/lib/debounce.test.js +40 -0
- package/lib/deepmerge.d.ts +2 -0
- package/lib/deepmerge.d.ts.map +1 -0
- package/lib/deepmerge.js +1 -0
- package/lib/form-values.d.ts +5 -0
- package/lib/form-values.d.ts.map +1 -0
- package/lib/form-values.js +17 -0
- package/lib/form-values.test.d.ts +2 -0
- package/lib/form-values.test.d.ts.map +1 -0
- package/lib/form-values.test.jsx +29 -0
- package/lib/i18n.d.ts +8 -0
- package/lib/i18n.d.ts.map +1 -0
- package/lib/i18n.js +9 -0
- package/lib/i18n.test.d.ts +2 -0
- package/lib/i18n.test.d.ts.map +1 -0
- package/lib/i18n.test.jsx +8 -0
- package/lib/image-params-keymap.d.ts +4 -0
- package/lib/image-params-keymap.d.ts.map +1 -0
- package/lib/image-params-keymap.js +19 -0
- package/lib/image-params-keymap.test.d.ts +2 -0
- package/lib/image-params-keymap.test.d.ts.map +1 -0
- package/lib/image-params-keymap.test.js +7 -0
- package/lib/index.d.ts +14 -0
- package/lib/index.d.ts.map +1 -0
- package/lib/index.js +13 -0
- package/lib/initializer.d.ts +78 -0
- package/lib/initializer.d.ts.map +1 -0
- package/lib/initializer.js +93 -0
- package/lib/initializer.test.d.ts +2 -0
- package/lib/initializer.test.d.ts.map +1 -0
- package/lib/initializer.test.js +64 -0
- package/lib/render.d.ts +10 -0
- package/lib/render.d.ts.map +1 -0
- package/lib/render.jsx +34 -0
- package/lib/render.test.d.ts +2 -0
- package/lib/render.test.d.ts.map +1 -0
- package/lib/render.test.jsx +70 -0
- package/lib/resolve-image.d.ts +10 -0
- package/lib/resolve-image.d.ts.map +1 -0
- package/lib/resolve-image.js +57 -0
- package/lib/resolve-image.test.d.ts +2 -0
- package/lib/resolve-image.test.d.ts.map +1 -0
- package/lib/resolve-image.test.jsx +146 -0
- package/lib/slot.d.ts +43 -0
- package/lib/slot.d.ts.map +1 -0
- package/lib/slot.jsx +184 -0
- package/lib/slot.test.d.ts +2 -0
- package/lib/slot.test.d.ts.map +1 -0
- package/lib/slot.test.jsx +325 -0
- package/lib/tests.d.ts +4 -0
- package/lib/tests.d.ts.map +1 -0
- package/lib/tests.jsx +19 -0
- package/lib/tests.test.d.ts +2 -0
- package/lib/tests.test.d.ts.map +1 -0
- package/lib/tests.test.jsx +13 -0
- package/lib/types.d.ts +9 -0
- package/lib/types.d.ts.map +1 -0
- package/lib/types.js +1 -0
- package/lib/vcomponent.d.ts +8 -0
- package/lib/vcomponent.d.ts.map +1 -0
- package/lib/vcomponent.jsx +27 -0
- package/lib/vcomponent.test.d.ts +2 -0
- package/lib/vcomponent.test.d.ts.map +1 -0
- package/lib/vcomponent.test.jsx +51 -0
- package/package.json +1 -1
- package/preact-compat.js +93 -1
- package/preact-hooks.js +40 -1
- package/preact-jsx-runtime.js +35 -1
- package/preact.js +21 -1
- package/runtime.js +69 -1
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { FunctionComponent, VNode } from 'preact';
|
|
2
|
+
import { HTMLAttributes } from 'preact/compat';
|
|
3
|
+
import '@adobe/elsie/components/CartItem/CartItem.css';
|
|
4
|
+
export interface CartItemProps extends Omit<HTMLAttributes<HTMLDivElement>, 'title' | 'loading'> {
|
|
5
|
+
ariaLabel?: string;
|
|
6
|
+
image: VNode;
|
|
7
|
+
title: VNode;
|
|
8
|
+
price: VNode;
|
|
9
|
+
taxIncluded?: boolean;
|
|
10
|
+
total: VNode;
|
|
11
|
+
sku: VNode;
|
|
12
|
+
quantity?: number;
|
|
13
|
+
description?: VNode;
|
|
14
|
+
configurations?: {
|
|
15
|
+
[key: string]: any;
|
|
16
|
+
};
|
|
17
|
+
warning?: VNode;
|
|
18
|
+
alert?: VNode;
|
|
19
|
+
loading?: boolean;
|
|
20
|
+
updating?: boolean;
|
|
21
|
+
onRemove?: () => void;
|
|
22
|
+
onQuantity?: (value: number) => void;
|
|
23
|
+
}
|
|
24
|
+
export declare const CartItem: FunctionComponent<CartItemProps>;
|
|
25
|
+
//# sourceMappingURL=CartItem.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CartItem.d.ts","sourceRoot":"","sources":["../../../src/components/CartItem/CartItem.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,KAAK,EAAE,MAAM,QAAQ,CAAC;AAClD,OAAO,EAAE,cAAc,EAAc,MAAM,eAAe,CAAC;AAa3D,OAAO,+CAA+C,CAAC;AAEvD,MAAM,WAAW,aACf,SAAQ,IAAI,CAAC,cAAc,CAAC,cAAc,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;IACjE,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,KAAK,CAAC;IACb,KAAK,EAAE,KAAK,CAAC;IACb,KAAK,EAAE,KAAK,CAAC;IACb,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,KAAK,EAAE,KAAK,CAAC;IACb,GAAG,EAAE,KAAK,CAAC;IACX,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,WAAW,CAAC,EAAE,KAAK,CAAC;IACpB,cAAc,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;KAAE,CAAC;IACxC,OAAO,CAAC,EAAE,KAAK,CAAC;IAChB,KAAK,CAAC,EAAE,KAAK,CAAC;IACd,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAC;IACtB,UAAU,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;CACtC;AAED,eAAO,MAAM,QAAQ,EAAE,iBAAiB,CAAC,aAAa,CA+OrD,CAAC"}
|
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
import { useContext } from 'preact/compat';
|
|
2
|
+
import { classes, VComponent } from '@adobe/elsie/lib';
|
|
3
|
+
import { Button, CartItemSkeleton, Icon, Incrementer, UIContext, ProgressSpinner, } from '@adobe/elsie/components';
|
|
4
|
+
import { useText } from '@adobe/elsie/i18n';
|
|
5
|
+
import { Trash } from '@adobe/elsie/icons';
|
|
6
|
+
import '@adobe/elsie/components/CartItem/CartItem.css';
|
|
7
|
+
export const CartItem = ({ className, children, ariaLabel, image, title, price, taxIncluded = false, total, sku, configurations, warning, alert, quantity = 1, description, loading = false, updating = false, onQuantity, onRemove, ...props }) => {
|
|
8
|
+
const { locale } = useContext(UIContext);
|
|
9
|
+
const labels = useText({
|
|
10
|
+
each: 'Dropin.CartItem.each.label',
|
|
11
|
+
quantity: 'Dropin.CartItem.quantity.label',
|
|
12
|
+
remove: 'Dropin.CartItem.remove.label',
|
|
13
|
+
removeDefault: 'Dropin.CartItem.removeDefault.label',
|
|
14
|
+
taxIncluded: 'Dropin.CartItem.taxIncluded.label',
|
|
15
|
+
updating: 'Dropin.CartItem.updating.label',
|
|
16
|
+
updatingDefault: 'Dropin.ProgressSpinner.updating.label',
|
|
17
|
+
});
|
|
18
|
+
if (loading)
|
|
19
|
+
return <CartItemSkeleton />;
|
|
20
|
+
return (<div {...props} className={classes([
|
|
21
|
+
'dropin-cart-item',
|
|
22
|
+
['dropin-cart-item--updating', updating],
|
|
23
|
+
className,
|
|
24
|
+
])}>
|
|
25
|
+
{updating && (<ProgressSpinner className={classes(['dropin-cart-item__spinner'])} ariaLabel={ariaLabel
|
|
26
|
+
? labels.updating?.replace('{product}', ariaLabel)
|
|
27
|
+
: labels.updatingDefault}/>)}
|
|
28
|
+
<div className="dropin-cart-item__wrapper">
|
|
29
|
+
{/* Image */}
|
|
30
|
+
<VComponent node={image} className={classes(['dropin-cart-item__image'])}/>
|
|
31
|
+
|
|
32
|
+
{/* Title */}
|
|
33
|
+
<VComponent node={title} className={classes([
|
|
34
|
+
'dropin-cart-item__title',
|
|
35
|
+
['dropin-cart-item__title--edit', !!onQuantity || !!onRemove],
|
|
36
|
+
])}/>
|
|
37
|
+
|
|
38
|
+
{/* Description */}
|
|
39
|
+
{description && (<VComponent node={description} className={classes(['dropin-cart-item__description'])}/>)}
|
|
40
|
+
|
|
41
|
+
{/* SKU */}
|
|
42
|
+
<VComponent node={sku} className={classes(['dropin-cart-item__sku'])}/>
|
|
43
|
+
{/* Configurations */}
|
|
44
|
+
{configurations && (<ul className={classes(['dropin-cart-item__configurations'])}>
|
|
45
|
+
{Object.entries(configurations).map(([key, value]) => (<li key={key} className={classes(['dropin-cart-item__configurations__item'])}>
|
|
46
|
+
{key}:{' '}
|
|
47
|
+
<strong className={classes([
|
|
48
|
+
'dropin-cart-item__configurations__item__value',
|
|
49
|
+
])}>
|
|
50
|
+
{value}
|
|
51
|
+
</strong>
|
|
52
|
+
</li>))}
|
|
53
|
+
</ul>)}
|
|
54
|
+
|
|
55
|
+
{/* Price */}
|
|
56
|
+
<span className={classes(['dropin-cart-item__price'])}>
|
|
57
|
+
{!onQuantity && (<span className="dropin-cart-item__price__quantity">
|
|
58
|
+
{quantity.toLocaleString(locale)} x{' '}
|
|
59
|
+
</span>)}
|
|
60
|
+
|
|
61
|
+
<VComponent node={price} role="text"/>
|
|
62
|
+
|
|
63
|
+
{quantity > 1 && (<>
|
|
64
|
+
|
|
65
|
+
{labels.each}
|
|
66
|
+
</>)}
|
|
67
|
+
|
|
68
|
+
{taxIncluded && (<span data-testid="tax-message" className="dropin-cart-item__price-tax-message">
|
|
69
|
+
|
|
70
|
+
{labels.taxIncluded}
|
|
71
|
+
</span>)}
|
|
72
|
+
</span>
|
|
73
|
+
|
|
74
|
+
{/* Quantity */}
|
|
75
|
+
<div className={classes([
|
|
76
|
+
'dropin-cart-item__quantity',
|
|
77
|
+
['dropin-cart-item__quantity--edit', !!onQuantity],
|
|
78
|
+
])}>
|
|
79
|
+
{onQuantity ? (<Incrementer className={classes(['dropin-cart-item__quantity__incrementer'])} value={quantity} min={1} onValue={(value) => onQuantity?.(Number(value))} name="quantity" aria-label={labels.quantity} disabled={updating}/>) : (<span className={classes(['dropin-cart-item__quantity__value'])}>
|
|
80
|
+
{labels.quantity}:{' '}
|
|
81
|
+
<strong className="dropin-cart-item__quantity__number">
|
|
82
|
+
{Number(quantity).toLocaleString(locale)}
|
|
83
|
+
</strong>
|
|
84
|
+
</span>)}
|
|
85
|
+
|
|
86
|
+
{/* Warning */}
|
|
87
|
+
{warning && (<VComponent node={warning} className={classes([
|
|
88
|
+
'dropin-cart-item__warning',
|
|
89
|
+
'dropin-cart-item__warning--quantity',
|
|
90
|
+
])}/>)}
|
|
91
|
+
|
|
92
|
+
{/* Alert */}
|
|
93
|
+
{alert && (<VComponent node={alert} className={classes([
|
|
94
|
+
'dropin-cart-item__alert',
|
|
95
|
+
'dropin-cart-item__alert--quantity',
|
|
96
|
+
])}/>)}
|
|
97
|
+
</div>
|
|
98
|
+
|
|
99
|
+
{/* Warning */}
|
|
100
|
+
{warning && (<VComponent node={warning} className={classes(['dropin-cart-item__warning'])}/>)}
|
|
101
|
+
|
|
102
|
+
{/* Alert */}
|
|
103
|
+
{alert && (<VComponent node={alert} className={classes(['dropin-cart-item__alert'])}/>)}
|
|
104
|
+
|
|
105
|
+
{/* Total */}
|
|
106
|
+
<div className={classes([
|
|
107
|
+
'dropin-cart-item__total',
|
|
108
|
+
['dropin-cart-item__total--edit', !!onRemove],
|
|
109
|
+
])}>
|
|
110
|
+
<VComponent node={total} role="text"/>
|
|
111
|
+
|
|
112
|
+
{taxIncluded && (<span data-testid="tax-message" className={classes(['dropin-cart-item__total-tax-message'])}>
|
|
113
|
+
|
|
114
|
+
{labels.taxIncluded}
|
|
115
|
+
</span>)}
|
|
116
|
+
</div>
|
|
117
|
+
</div>
|
|
118
|
+
|
|
119
|
+
{/* Remove Item */}
|
|
120
|
+
{onRemove && (<Button className={classes(['dropin-cart-item__remove'])} variant="tertiary" onClick={() => onRemove?.()} icon={<Icon source={Trash} size="24" stroke="2" viewBox="0 0 24 24" aria-label={ariaLabel
|
|
121
|
+
? labels.remove?.replace('{product}', ariaLabel)
|
|
122
|
+
: labels.removeDefault}/>} disabled={updating}/>)}
|
|
123
|
+
</div>);
|
|
124
|
+
};
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from '@storybook/preact';
|
|
2
|
+
import { CartItemProps } from '@adobe/elsie/components';
|
|
3
|
+
/**
|
|
4
|
+
* Use CartItems to display a product item in Cart.
|
|
5
|
+
*/
|
|
6
|
+
declare const meta: Meta<CartItemProps>;
|
|
7
|
+
export default meta;
|
|
8
|
+
type Story = StoryObj<CartItemProps>;
|
|
9
|
+
/**
|
|
10
|
+
* ```tsx
|
|
11
|
+
* <CartItem
|
|
12
|
+
* ariaLabel="Short Name"
|
|
13
|
+
* image={<Image src="https://picsum.photos/132/184" width="132" height="184" alt="Some alternative text" loading="lazy" />}
|
|
14
|
+
* title={<div>Product Name</div>}
|
|
15
|
+
* description={<div>Secondary product information such as brand name, description, etc.</div>}
|
|
16
|
+
* sku={<div>SKU: 59YK7</div>}
|
|
17
|
+
* quantity={1}
|
|
18
|
+
* price={<Price amount={53.99} weight="normal" />}
|
|
19
|
+
* total={<>
|
|
20
|
+
* <Price amount={59.98} variant="strikethrough" />
|
|
21
|
+
* <Price amount={55.95} sale />
|
|
22
|
+
* </>}
|
|
23
|
+
* warning={<span> Only 5 left!</span>}
|
|
24
|
+
* alert={<span><Icon source={WarningWithCircle} size={'16'} /> Out of stock!</span>}
|
|
25
|
+
* configurations={{ Color: 'Blue', Size: 'L' }}
|
|
26
|
+
* onRemove={() => console.log('onRemove')}
|
|
27
|
+
* onQuantity={(value) => console.log('onQuantity', value)}
|
|
28
|
+
* />
|
|
29
|
+
* ```
|
|
30
|
+
*/
|
|
31
|
+
export declare const CartItem: Story;
|
|
32
|
+
/**
|
|
33
|
+
* ```tsx
|
|
34
|
+
* <CartItem
|
|
35
|
+
* ariaLabel="Short Name"
|
|
36
|
+
* image={<Image src="https://picsum.photos/132/184" width="132" height="184" alt="Some alternative text" loading="lazy" />}
|
|
37
|
+
* title={<div>Product Name</div>}
|
|
38
|
+
* description={<div>Secondary product information such as brand name, description, etc.</div>}
|
|
39
|
+
* sku={<div>SKU: 59YK7</div>}
|
|
40
|
+
* quantity={1}
|
|
41
|
+
* price={<Price amount={53.99} weight="normal" />}
|
|
42
|
+
* total={<>
|
|
43
|
+
* <Price amount={59.98} variant="strikethrough" />
|
|
44
|
+
* <Price amount={55.95} sale />
|
|
45
|
+
* </>}
|
|
46
|
+
* warning={<span> Only 5 left!</span>}
|
|
47
|
+
* alert={<span><Icon source={WarningWithCircle} size={'16'} /> Out of stock!</span>}
|
|
48
|
+
* configurations={{ Color: 'Blue', Size: 'L' }}
|
|
49
|
+
* />
|
|
50
|
+
* ```
|
|
51
|
+
*/
|
|
52
|
+
export declare const ReadOnly: Story;
|
|
53
|
+
export declare const Skeleton: Story;
|
|
54
|
+
//# sourceMappingURL=CartItem.stories.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CartItem.stories.d.ts","sourceRoot":"","sources":["../../../src/components/CartItem/CartItem.stories.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAIxD,OAAO,EAIL,aAAa,EAGd,MAAM,yBAAyB,CAAC;AAGjC;;GAEG;AACH,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,aAAa,CAyM7B,CAAC;AAEF,eAAe,IAAI,CAAC;AAEpB,KAAK,KAAK,GAAG,QAAQ,CAAC,aAAa,CAAC,CAAC;AAErC;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,eAAO,MAAM,QAAQ,EAAE,KAsEtB,CAAC;AAEF;;;;;;;;;;;;;;;;;;;GAmBG;AACH,eAAO,MAAM,QAAQ,EAAE,KAqBtB,CAAC;AAEF,eAAO,MAAM,QAAQ,EAAE,KAEtB,CAAC"}
|
|
@@ -0,0 +1,309 @@
|
|
|
1
|
+
import { within, userEvent } from '@storybook/testing-library';
|
|
2
|
+
import { expect } from '@storybook/jest';
|
|
3
|
+
import { Price, Image, CartItem as component, CartItemSkeleton, Icon, } from '@adobe/elsie/components';
|
|
4
|
+
import { WarningWithCircle } from '@adobe/elsie/icons';
|
|
5
|
+
/**
|
|
6
|
+
* Use CartItems to display a product item in Cart.
|
|
7
|
+
*/
|
|
8
|
+
const meta = {
|
|
9
|
+
title: 'Components/CartItem',
|
|
10
|
+
component,
|
|
11
|
+
parameters: {
|
|
12
|
+
layout: 'padded', // centered | fullscreen
|
|
13
|
+
},
|
|
14
|
+
argTypes: {
|
|
15
|
+
image: {
|
|
16
|
+
control: {
|
|
17
|
+
type: 'select',
|
|
18
|
+
labels: {
|
|
19
|
+
Image: 'Image',
|
|
20
|
+
},
|
|
21
|
+
},
|
|
22
|
+
description: 'Product image.',
|
|
23
|
+
options: ['Image'],
|
|
24
|
+
mapping: {
|
|
25
|
+
Image: (<Image src="https://picsum.photos/132/184" width="132" height="184" alt="Some alternative text" loading="lazy"/>),
|
|
26
|
+
},
|
|
27
|
+
table: { defaultValue: { summary: 'null' } },
|
|
28
|
+
},
|
|
29
|
+
title: {
|
|
30
|
+
control: {
|
|
31
|
+
type: 'select',
|
|
32
|
+
labels: {
|
|
33
|
+
Short: 'Short Name',
|
|
34
|
+
Long: 'Long Name',
|
|
35
|
+
},
|
|
36
|
+
},
|
|
37
|
+
description: 'A title of the product.',
|
|
38
|
+
options: ['Short', 'Long'],
|
|
39
|
+
mapping: {
|
|
40
|
+
Short: <div>Short Name</div>,
|
|
41
|
+
Long: <div>Product with an extremely extremely long name</div>,
|
|
42
|
+
},
|
|
43
|
+
table: { defaultValue: { summary: 'null' } },
|
|
44
|
+
},
|
|
45
|
+
description: {
|
|
46
|
+
control: {
|
|
47
|
+
type: 'select',
|
|
48
|
+
labels: {
|
|
49
|
+
Description: 'Description',
|
|
50
|
+
},
|
|
51
|
+
},
|
|
52
|
+
description: 'Description of the product.',
|
|
53
|
+
options: ['Description'],
|
|
54
|
+
mapping: {
|
|
55
|
+
Description: (<div>
|
|
56
|
+
Secondary product information such as brand name, description, etc.
|
|
57
|
+
</div>),
|
|
58
|
+
},
|
|
59
|
+
table: { defaultValue: { summary: 'null' } },
|
|
60
|
+
},
|
|
61
|
+
sku: {
|
|
62
|
+
control: {
|
|
63
|
+
type: 'select',
|
|
64
|
+
labels: {
|
|
65
|
+
none: 'none',
|
|
66
|
+
Sku: 'SKU: 59YK7',
|
|
67
|
+
},
|
|
68
|
+
},
|
|
69
|
+
description: 'A sku of the product.',
|
|
70
|
+
options: ['none', 'Sku'],
|
|
71
|
+
mapping: {
|
|
72
|
+
none: null,
|
|
73
|
+
Sku: <div>SKU: 59YK7</div>,
|
|
74
|
+
},
|
|
75
|
+
table: { defaultValue: { summary: 'null' } },
|
|
76
|
+
},
|
|
77
|
+
quantity: {
|
|
78
|
+
control: {
|
|
79
|
+
type: 'number',
|
|
80
|
+
},
|
|
81
|
+
description: 'The quantity of the product.',
|
|
82
|
+
table: { defaultValue: { summary: '1' } },
|
|
83
|
+
},
|
|
84
|
+
price: {
|
|
85
|
+
control: {
|
|
86
|
+
type: 'select',
|
|
87
|
+
labels: {
|
|
88
|
+
Price: 'Item Price',
|
|
89
|
+
},
|
|
90
|
+
},
|
|
91
|
+
description: 'The price of each item.',
|
|
92
|
+
options: ['Price'],
|
|
93
|
+
mapping: {
|
|
94
|
+
Price: <Price amount={53.99} weight="normal"/>,
|
|
95
|
+
},
|
|
96
|
+
table: { defaultValue: { summary: 'null' } },
|
|
97
|
+
},
|
|
98
|
+
total: {
|
|
99
|
+
control: {
|
|
100
|
+
type: 'select',
|
|
101
|
+
labels: {
|
|
102
|
+
Total: 'Total',
|
|
103
|
+
},
|
|
104
|
+
},
|
|
105
|
+
description: 'The total price of the product.',
|
|
106
|
+
options: ['Total'],
|
|
107
|
+
mapping: {
|
|
108
|
+
Total: (<>
|
|
109
|
+
<Price amount={59.98} variant="strikethrough"/>
|
|
110
|
+
<Price amount={55.95} sale/>
|
|
111
|
+
</>),
|
|
112
|
+
},
|
|
113
|
+
table: { defaultValue: { summary: 'null' } },
|
|
114
|
+
},
|
|
115
|
+
taxIncluded: {
|
|
116
|
+
control: {
|
|
117
|
+
type: 'boolean',
|
|
118
|
+
},
|
|
119
|
+
description: 'Render tax included message.',
|
|
120
|
+
table: { defaultValue: { summary: 'false' } },
|
|
121
|
+
},
|
|
122
|
+
configurations: {},
|
|
123
|
+
warning: {
|
|
124
|
+
control: {
|
|
125
|
+
type: 'select',
|
|
126
|
+
labels: {
|
|
127
|
+
none: 'none',
|
|
128
|
+
RunningOut: 'Only 1 left in stock',
|
|
129
|
+
},
|
|
130
|
+
},
|
|
131
|
+
description: 'A warning message.',
|
|
132
|
+
options: ['none', 'RunningOut'],
|
|
133
|
+
mapping: {
|
|
134
|
+
none: null,
|
|
135
|
+
RunningOut: <span> Only 5 left!</span>,
|
|
136
|
+
},
|
|
137
|
+
table: { defaultValue: { summary: 'null' } },
|
|
138
|
+
},
|
|
139
|
+
alert: {
|
|
140
|
+
control: {
|
|
141
|
+
type: 'select',
|
|
142
|
+
labels: {
|
|
143
|
+
none: 'none',
|
|
144
|
+
RunningOut: 'Out of stock',
|
|
145
|
+
},
|
|
146
|
+
},
|
|
147
|
+
description: 'Alert message.',
|
|
148
|
+
options: ['none', 'RunningOut'],
|
|
149
|
+
mapping: {
|
|
150
|
+
none: null,
|
|
151
|
+
RunningOut: (<span>
|
|
152
|
+
<Icon source={WarningWithCircle} size={'16'} aria-hidden={true}/>{' '}
|
|
153
|
+
Out of stock!
|
|
154
|
+
</span>),
|
|
155
|
+
},
|
|
156
|
+
table: { defaultValue: { summary: 'null' } },
|
|
157
|
+
},
|
|
158
|
+
loading: {
|
|
159
|
+
control: {
|
|
160
|
+
type: 'boolean',
|
|
161
|
+
},
|
|
162
|
+
description: 'Loading state.',
|
|
163
|
+
table: { defaultValue: { summary: 'false' } },
|
|
164
|
+
},
|
|
165
|
+
updating: {
|
|
166
|
+
control: {
|
|
167
|
+
type: 'boolean',
|
|
168
|
+
},
|
|
169
|
+
description: 'Updating state.',
|
|
170
|
+
table: { defaultValue: { summary: 'false' } },
|
|
171
|
+
},
|
|
172
|
+
onQuantity: {
|
|
173
|
+
description: 'Quantity update handler.',
|
|
174
|
+
table: {
|
|
175
|
+
type: { summary: 'function' },
|
|
176
|
+
},
|
|
177
|
+
action: 'onQuantity',
|
|
178
|
+
},
|
|
179
|
+
onRemove: {
|
|
180
|
+
description: 'Add a remove handler.',
|
|
181
|
+
table: {
|
|
182
|
+
type: { summary: 'function' },
|
|
183
|
+
},
|
|
184
|
+
action: 'onRemove',
|
|
185
|
+
},
|
|
186
|
+
ariaLabel: {
|
|
187
|
+
control: {
|
|
188
|
+
type: 'text',
|
|
189
|
+
},
|
|
190
|
+
description: 'Name for the component.',
|
|
191
|
+
table: { defaultValue: { summary: 'null' } },
|
|
192
|
+
},
|
|
193
|
+
},
|
|
194
|
+
};
|
|
195
|
+
export default meta;
|
|
196
|
+
/**
|
|
197
|
+
* ```tsx
|
|
198
|
+
* <CartItem
|
|
199
|
+
* ariaLabel="Short Name"
|
|
200
|
+
* image={<Image src="https://picsum.photos/132/184" width="132" height="184" alt="Some alternative text" loading="lazy" />}
|
|
201
|
+
* title={<div>Product Name</div>}
|
|
202
|
+
* description={<div>Secondary product information such as brand name, description, etc.</div>}
|
|
203
|
+
* sku={<div>SKU: 59YK7</div>}
|
|
204
|
+
* quantity={1}
|
|
205
|
+
* price={<Price amount={53.99} weight="normal" />}
|
|
206
|
+
* total={<>
|
|
207
|
+
* <Price amount={59.98} variant="strikethrough" />
|
|
208
|
+
* <Price amount={55.95} sale />
|
|
209
|
+
* </>}
|
|
210
|
+
* warning={<span> Only 5 left!</span>}
|
|
211
|
+
* alert={<span><Icon source={WarningWithCircle} size={'16'} /> Out of stock!</span>}
|
|
212
|
+
* configurations={{ Color: 'Blue', Size: 'L' }}
|
|
213
|
+
* onRemove={() => console.log('onRemove')}
|
|
214
|
+
* onQuantity={(value) => console.log('onQuantity', value)}
|
|
215
|
+
* />
|
|
216
|
+
* ```
|
|
217
|
+
*/
|
|
218
|
+
export const CartItem = {
|
|
219
|
+
args: {
|
|
220
|
+
ariaLabel: 'Short Name',
|
|
221
|
+
image: 'Image',
|
|
222
|
+
title: 'Short',
|
|
223
|
+
price: 'Price',
|
|
224
|
+
total: 'Total',
|
|
225
|
+
sku: 'Sku',
|
|
226
|
+
quantity: 1,
|
|
227
|
+
description: 'Description',
|
|
228
|
+
warning: 'none',
|
|
229
|
+
alert: 'none',
|
|
230
|
+
loading: false,
|
|
231
|
+
updating: false,
|
|
232
|
+
configurations: {
|
|
233
|
+
Color: 'Blue',
|
|
234
|
+
Size: 'L',
|
|
235
|
+
Multiple: '1, 2, 3',
|
|
236
|
+
},
|
|
237
|
+
},
|
|
238
|
+
play: async () => {
|
|
239
|
+
const canvasElement = document.querySelector('#storybook-root');
|
|
240
|
+
const canvas = within(canvasElement);
|
|
241
|
+
const itemImage = document.querySelector('.dropin-cart-item__image');
|
|
242
|
+
expect(itemImage).toBeVisible();
|
|
243
|
+
const itemTitle = document.querySelector('.dropin-cart-item__title');
|
|
244
|
+
expect(itemTitle).toBeVisible();
|
|
245
|
+
const itemSku = document.querySelector('.dropin-cart-item__sku');
|
|
246
|
+
expect(itemSku).toBeVisible();
|
|
247
|
+
const itemConfigurations = document.querySelector('.dropin-cart-item__configurations');
|
|
248
|
+
expect(itemConfigurations).toBeVisible();
|
|
249
|
+
const itemPrice = document.querySelector('.dropin-cart-item__price');
|
|
250
|
+
expect(itemPrice).toBeVisible();
|
|
251
|
+
const quantityStepper = document.querySelector('.dropin-cart-item__quantity');
|
|
252
|
+
expect(quantityStepper).toBeVisible();
|
|
253
|
+
const itemTotal = document.querySelector('.dropin-cart-item__total');
|
|
254
|
+
expect(itemTotal).toBeVisible();
|
|
255
|
+
const increaseButton = document.querySelector('button[aria-label="Increase Quantity"]');
|
|
256
|
+
const decreaseButton = document.querySelector('button[aria-label="Decrease Quantity"]');
|
|
257
|
+
// Without this wait test failing intermittently as click event is triggerning before even element fully loaded
|
|
258
|
+
await new Promise((resolve) => setTimeout(resolve, 500));
|
|
259
|
+
await userEvent.click(increaseButton);
|
|
260
|
+
await expect(await canvas.findByDisplayValue('2')).toBeTruthy();
|
|
261
|
+
await userEvent.click(decreaseButton);
|
|
262
|
+
await expect(await canvas.findByDisplayValue('1')).toBeTruthy();
|
|
263
|
+
},
|
|
264
|
+
};
|
|
265
|
+
/**
|
|
266
|
+
* ```tsx
|
|
267
|
+
* <CartItem
|
|
268
|
+
* ariaLabel="Short Name"
|
|
269
|
+
* image={<Image src="https://picsum.photos/132/184" width="132" height="184" alt="Some alternative text" loading="lazy" />}
|
|
270
|
+
* title={<div>Product Name</div>}
|
|
271
|
+
* description={<div>Secondary product information such as brand name, description, etc.</div>}
|
|
272
|
+
* sku={<div>SKU: 59YK7</div>}
|
|
273
|
+
* quantity={1}
|
|
274
|
+
* price={<Price amount={53.99} weight="normal" />}
|
|
275
|
+
* total={<>
|
|
276
|
+
* <Price amount={59.98} variant="strikethrough" />
|
|
277
|
+
* <Price amount={55.95} sale />
|
|
278
|
+
* </>}
|
|
279
|
+
* warning={<span> Only 5 left!</span>}
|
|
280
|
+
* alert={<span><Icon source={WarningWithCircle} size={'16'} /> Out of stock!</span>}
|
|
281
|
+
* configurations={{ Color: 'Blue', Size: 'L' }}
|
|
282
|
+
* />
|
|
283
|
+
* ```
|
|
284
|
+
*/
|
|
285
|
+
export const ReadOnly = {
|
|
286
|
+
args: {
|
|
287
|
+
ariaLabel: 'Short Name',
|
|
288
|
+
image: 'Image',
|
|
289
|
+
title: 'Short',
|
|
290
|
+
price: 'Price',
|
|
291
|
+
total: 'Total',
|
|
292
|
+
sku: 'Sku',
|
|
293
|
+
quantity: 1,
|
|
294
|
+
description: 'Description',
|
|
295
|
+
warning: 'none',
|
|
296
|
+
alert: 'none',
|
|
297
|
+
loading: false,
|
|
298
|
+
updating: false,
|
|
299
|
+
configurations: {
|
|
300
|
+
Color: 'Blue',
|
|
301
|
+
Size: 'L',
|
|
302
|
+
},
|
|
303
|
+
onQuantity: undefined,
|
|
304
|
+
onRemove: undefined,
|
|
305
|
+
},
|
|
306
|
+
};
|
|
307
|
+
export const Skeleton = {
|
|
308
|
+
render: () => <CartItemSkeleton />,
|
|
309
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CartItem.test.d.ts","sourceRoot":"","sources":["../../../src/components/CartItem/CartItem.test.tsx"],"names":[],"mappings":"AAAA,6DAA6D"}
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
/** https://preactjs.com/guide/v10/preact-testing-library/ */
|
|
2
|
+
import { fireEvent, render, screen } from '@adobe/elsie/lib/tests';
|
|
3
|
+
import { CartItem } from '@adobe/elsie/components/CartItem';
|
|
4
|
+
jest.useFakeTimers();
|
|
5
|
+
describe('Base/Components/CartItem', () => {
|
|
6
|
+
test('renders', () => {
|
|
7
|
+
const { container } = render(<CartItem image={<img />} title={<div>Title</div>} price={<div>$9.99</div>} total={<div>$9.99</div>} sku={<div>SKU</div>}/>);
|
|
8
|
+
expect(container.innerHTML).toMatchInlineSnapshot(`"<div class=\\"dropin-design\\"><div class=\\"dropin-cart-item\\"><div class=\\"dropin-cart-item__wrapper\\"><img class=\\"dropin-cart-item__image\\"><div class=\\"dropin-cart-item__title\\">Title</div><div class=\\"dropin-cart-item__sku\\">SKU</div><span class=\\"dropin-cart-item__price\\"><span class=\\"dropin-cart-item__price__quantity\\">1 x </span><div role=\\"text\\">$9.99</div></span><div class=\\"dropin-cart-item__quantity\\"><span class=\\"dropin-cart-item__quantity__value\\">Quantity: <strong class=\\"dropin-cart-item__quantity__number\\">1</strong></span></div><div class=\\"dropin-cart-item__total\\"><div role=\\"text\\">$9.99</div></div></div></div></div>"`);
|
|
9
|
+
});
|
|
10
|
+
test('renders with configurations', () => {
|
|
11
|
+
const { container } = render(<CartItem image={<img />} title={<div>Title</div>} price={<div>$9.99</div>} total={<div>$9.99</div>} sku={<div>SKU</div>} configurations={{ Color: 'Blue', size: 'L' }}/>);
|
|
12
|
+
const $configurations = container.querySelector('.dropin-cart-item__configurations');
|
|
13
|
+
expect($configurations?.innerHTML).toMatchInlineSnapshot(`"<li class=\\"dropin-cart-item__configurations__item\\">Color: <strong class=\\"dropin-cart-item__configurations__item__value\\">Blue</strong></li><li class=\\"dropin-cart-item__configurations__item\\">size: <strong class=\\"dropin-cart-item__configurations__item__value\\">L</strong></li>"`);
|
|
14
|
+
});
|
|
15
|
+
test('renders with description', () => {
|
|
16
|
+
const { container } = render(<CartItem image={<img />} title={<div>Title</div>} price={<div>$9.99</div>} total={<div>$9.99</div>} sku={<div>SKU</div>} description={<div>Description</div>}/>);
|
|
17
|
+
const $description = container.querySelector('.dropin-cart-item__description');
|
|
18
|
+
expect($description?.innerHTML).toMatchInlineSnapshot(`"Description"`);
|
|
19
|
+
});
|
|
20
|
+
test('onQuantity', () => {
|
|
21
|
+
const onQuantity = jest.fn();
|
|
22
|
+
const { container } = render(<CartItem image={<img />} title={<div>Title</div>} price={<div>$9.99</div>} total={<div>$9.99</div>} sku={<div>SKU</div>} onQuantity={onQuantity}/>);
|
|
23
|
+
const increase = container.querySelector('.dropin-incrementer__increase-button');
|
|
24
|
+
expect(increase).toBeTruthy();
|
|
25
|
+
fireEvent.click(increase);
|
|
26
|
+
jest.runAllTimers();
|
|
27
|
+
expect(onQuantity).toHaveBeenCalledWith(2);
|
|
28
|
+
});
|
|
29
|
+
test('onRemove', () => {
|
|
30
|
+
const onRemove = jest.fn();
|
|
31
|
+
const { container } = render(<CartItem image={<img />} title={<div>Title</div>} price={<div>$9.99</div>} total={<div>$9.99</div>} sku={<div>SKU</div>} onRemove={onRemove}/>);
|
|
32
|
+
const remove = container.querySelector('.dropin-cart-item__remove');
|
|
33
|
+
expect(remove).toBeTruthy();
|
|
34
|
+
fireEvent.click(remove);
|
|
35
|
+
expect(onRemove).toHaveBeenCalled();
|
|
36
|
+
});
|
|
37
|
+
test('renders with warning', () => {
|
|
38
|
+
const { container } = render(<CartItem image={<img />} title={<div>Title</div>} price={<div>$9.99</div>} total={<div>$9.99</div>} sku={<div>SKU</div>} warning={<span>warning</span>}/>);
|
|
39
|
+
const $warning = container.querySelectorAll('.dropin-cart-item__warning');
|
|
40
|
+
expect($warning.length).toBe(2);
|
|
41
|
+
expect($warning[0]?.innerHTML).toMatchInlineSnapshot(`"warning"`);
|
|
42
|
+
});
|
|
43
|
+
test('renders with alert', () => {
|
|
44
|
+
const { container } = render(<CartItem image={<img />} title={<div>Title</div>} price={<div>$9.99</div>} total={<div>$9.99</div>} sku={<div>SKU</div>} alert={<span>alert</span>}/>);
|
|
45
|
+
const $alert = container.querySelectorAll('.dropin-cart-item__alert');
|
|
46
|
+
expect($alert.length).toBe(2);
|
|
47
|
+
expect($alert[0]?.innerHTML).toMatchInlineSnapshot(`"alert"`);
|
|
48
|
+
});
|
|
49
|
+
test('renders skeleton', () => {
|
|
50
|
+
const { container } = render(<CartItem image={<img />} title={<div>Title</div>} price={<div>$9.99</div>} total={<div>$9.99</div>} sku={<div>SKU</div>} warning={<span>warning</span>} loading/>);
|
|
51
|
+
expect(container.innerHTML).toMatchInlineSnapshot(`"<div class=\\"dropin-design\\"><div class=\\"dropin-cart-item dropin-cart-item-skeleton\\"><div style=\\"--row-gap-spacing: var(--spacing-medium);\\" role=\\"status\\" aria-label=\\"Loading...\\" class=\\"dropin-skeleton dropin-cart-item__skeleton dropin-cart-item__wrapper\\"><div class=\\"dropin-cart-item__image\\"><div class=\\"dropin-skeleton-row dropin-skeleton--row__content dropin-skeleton-row__row dropin-skeleton-row__row-small dropin-cart-item__skeleton__item\\"></div></div><div class=\\"dropin-cart-item__title\\"><div class=\\"dropin-skeleton-row dropin-skeleton--row__content dropin-skeleton-row__row dropin-skeleton-row__row-small dropin-cart-item__skeleton__item\\"></div></div><div class=\\"dropin-cart-item__sku\\"><div class=\\"dropin-skeleton-row dropin-skeleton--row__content dropin-skeleton-row__row dropin-skeleton-row__row-small dropin-cart-item__skeleton__item\\"></div></div><div class=\\"dropin-cart-item__price\\"><div class=\\"dropin-skeleton-row dropin-skeleton--row__content dropin-skeleton-row__row dropin-skeleton-row__row-small dropin-cart-item__skeleton__item\\"></div></div><div class=\\"dropin-cart-item__quantity\\"><div class=\\"dropin-skeleton-row dropin-skeleton--row__content dropin-skeleton-row__row dropin-skeleton-row__row-small dropin-cart-item__skeleton__item\\"></div></div><div class=\\"dropin-cart-item__total\\"><div class=\\"dropin-skeleton-row dropin-skeleton--row__content dropin-skeleton-row__row dropin-skeleton-row__row-small dropin-cart-item__skeleton__item\\"></div></div></div></div></div>"`);
|
|
52
|
+
});
|
|
53
|
+
test('renders messages with taxIncluded', () => {
|
|
54
|
+
render(<CartItem image={<img />} title={<div>Title</div>} price={<div>$9.99</div>} total={<div>$9.99</div>} sku={<div>SKU</div>} taxIncluded/>);
|
|
55
|
+
const $taxIncluded = screen.getAllByTestId('tax-message');
|
|
56
|
+
expect($taxIncluded.length).toBe(2);
|
|
57
|
+
});
|
|
58
|
+
test('renders "each" label', () => {
|
|
59
|
+
const { container } = render(<CartItem image={<img />} title={<div>Title</div>} price={<div>$9.99</div>} total={<div>$9.99</div>} sku={<div>SKU</div>} quantity={2}/>);
|
|
60
|
+
const $each = container.querySelector('.dropin-cart-item__price');
|
|
61
|
+
expect($each?.innerHTML).toMatchInlineSnapshot(`"<span class=\\"dropin-cart-item__price__quantity\\">2 x </span><div role=\\"text\\">$9.99</div> each"`);
|
|
62
|
+
});
|
|
63
|
+
test('renders progress spinner when updating', () => {
|
|
64
|
+
const { container } = render(<CartItem image={<img />} title={<div>Title</div>} price={<div>$9.99</div>} total={<div>$9.99</div>} sku={<div>SKU</div>} updating/>);
|
|
65
|
+
expect(container.innerHTML).toMatchInlineSnapshot(`"<div class=\\"dropin-design\\"><div class=\\"dropin-cart-item dropin-cart-item--updating\\"><div aria-live=\\"polite\\" role=\\"status\\" aria-label=\\"Item is updating\\" class=\\"dropin-cart-item__spinner dropin-progress-spinner dropin-progress-spinner--shape-size-small dropin-progress-spinner--shape-stroke-4\\"></div><div class=\\"dropin-cart-item__wrapper\\"><img class=\\"dropin-cart-item__image\\"><div class=\\"dropin-cart-item__title\\">Title</div><div class=\\"dropin-cart-item__sku\\">SKU</div><span class=\\"dropin-cart-item__price\\"><span class=\\"dropin-cart-item__price__quantity\\">1 x </span><div role=\\"text\\">$9.99</div></span><div class=\\"dropin-cart-item__quantity\\"><span class=\\"dropin-cart-item__quantity__value\\">Quantity: <strong class=\\"dropin-cart-item__quantity__number\\">1</strong></span></div><div class=\\"dropin-cart-item__total\\"><div role=\\"text\\">$9.99</div></div></div></div></div>"`);
|
|
66
|
+
});
|
|
67
|
+
test('renders with aria-label', () => {
|
|
68
|
+
const { container } = render(<CartItem ariaLabel={'Cart Item'} image={<img />} title={<div>Title</div>} price={<div>$9.99</div>} total={<div>$9.99</div>} sku={<div>SKU</div>}/>);
|
|
69
|
+
expect(container.innerHTML).toMatchInlineSnapshot(`"<div class=\\"dropin-design\\"><div class=\\"dropin-cart-item\\"><div class=\\"dropin-cart-item__wrapper\\"><img class=\\"dropin-cart-item__image\\"><div class=\\"dropin-cart-item__title\\">Title</div><div class=\\"dropin-cart-item__sku\\">SKU</div><span class=\\"dropin-cart-item__price\\"><span class=\\"dropin-cart-item__price__quantity\\">1 x </span><div role=\\"text\\">$9.99</div></span><div class=\\"dropin-cart-item__quantity\\"><span class=\\"dropin-cart-item__quantity__value\\">Quantity: <strong class=\\"dropin-cart-item__quantity__number\\">1</strong></span></div><div class=\\"dropin-cart-item__total\\"><div role=\\"text\\">$9.99</div></div></div></div></div>"`);
|
|
70
|
+
});
|
|
71
|
+
});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CartItemSkeleton.d.ts","sourceRoot":"","sources":["../../../src/components/CartItem/CartItemSkeleton.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,QAAQ,CAAC;AAG3C,eAAO,MAAM,gBAAgB,EAAE,iBAyB9B,CAAC"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { Skeleton, SkeletonRow } from '@adobe/elsie/components';
|
|
2
|
+
export const CartItemSkeleton = () => {
|
|
3
|
+
return (<div className="dropin-cart-item dropin-cart-item-skeleton">
|
|
4
|
+
<Skeleton className="dropin-cart-item__skeleton dropin-cart-item__wrapper">
|
|
5
|
+
<div className="dropin-cart-item__image">
|
|
6
|
+
<SkeletonRow className="dropin-cart-item__skeleton__item"/>
|
|
7
|
+
</div>
|
|
8
|
+
<div className="dropin-cart-item__title">
|
|
9
|
+
<SkeletonRow className="dropin-cart-item__skeleton__item"/>
|
|
10
|
+
</div>
|
|
11
|
+
<div className="dropin-cart-item__sku">
|
|
12
|
+
<SkeletonRow className="dropin-cart-item__skeleton__item"/>
|
|
13
|
+
</div>
|
|
14
|
+
<div className="dropin-cart-item__price">
|
|
15
|
+
<SkeletonRow className="dropin-cart-item__skeleton__item"/>
|
|
16
|
+
</div>
|
|
17
|
+
<div className="dropin-cart-item__quantity">
|
|
18
|
+
<SkeletonRow className="dropin-cart-item__skeleton__item"/>
|
|
19
|
+
</div>
|
|
20
|
+
<div className="dropin-cart-item__total">
|
|
21
|
+
<SkeletonRow className="dropin-cart-item__skeleton__item"/>
|
|
22
|
+
</div>
|
|
23
|
+
</Skeleton>
|
|
24
|
+
</div>);
|
|
25
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CartItemSkeleton.test.d.ts","sourceRoot":"","sources":["../../../src/components/CartItem/CartItemSkeleton.test.tsx"],"names":[],"mappings":"AAAA,6DAA6D"}
|