@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
package/i18n/index.d.ts
ADDED
|
@@ -0,0 +1,341 @@
|
|
|
1
|
+
export type Lang = 'en_US';
|
|
2
|
+
export declare const definition: {
|
|
3
|
+
default: {
|
|
4
|
+
Dropin: {
|
|
5
|
+
ExampleComponentName: {
|
|
6
|
+
item: {
|
|
7
|
+
label: string;
|
|
8
|
+
};
|
|
9
|
+
};
|
|
10
|
+
Incrementer: {
|
|
11
|
+
decreaseLabel: string;
|
|
12
|
+
increaseLabel: string;
|
|
13
|
+
label: string;
|
|
14
|
+
};
|
|
15
|
+
Modal: {
|
|
16
|
+
Close: {
|
|
17
|
+
label: string;
|
|
18
|
+
};
|
|
19
|
+
};
|
|
20
|
+
InlineAlert: {
|
|
21
|
+
dismissLabel: string;
|
|
22
|
+
};
|
|
23
|
+
PriceSummary: {
|
|
24
|
+
subTotal: {
|
|
25
|
+
label: string;
|
|
26
|
+
withTaxes: string;
|
|
27
|
+
};
|
|
28
|
+
shipping: {
|
|
29
|
+
label: string;
|
|
30
|
+
editZipAction: string;
|
|
31
|
+
estimated: string;
|
|
32
|
+
estimatedDestination: string;
|
|
33
|
+
destinationLinkAriaLabel: string;
|
|
34
|
+
zipPlaceholder: string;
|
|
35
|
+
withTaxes: string;
|
|
36
|
+
alternateField: {
|
|
37
|
+
zip: string;
|
|
38
|
+
state: string;
|
|
39
|
+
};
|
|
40
|
+
};
|
|
41
|
+
taxes: {
|
|
42
|
+
total: string;
|
|
43
|
+
totalOnly: string;
|
|
44
|
+
breakdown: string;
|
|
45
|
+
showBreakdown: string;
|
|
46
|
+
hideBreakdown: string;
|
|
47
|
+
estimated: string;
|
|
48
|
+
};
|
|
49
|
+
total: {
|
|
50
|
+
estimated: string;
|
|
51
|
+
label: string;
|
|
52
|
+
withoutTax: string;
|
|
53
|
+
};
|
|
54
|
+
};
|
|
55
|
+
ProgressSpinner: {
|
|
56
|
+
updating: {
|
|
57
|
+
label: string;
|
|
58
|
+
};
|
|
59
|
+
updatingChildren: {
|
|
60
|
+
label: string;
|
|
61
|
+
};
|
|
62
|
+
};
|
|
63
|
+
PriceRange: {
|
|
64
|
+
from: {
|
|
65
|
+
label: string;
|
|
66
|
+
};
|
|
67
|
+
to: {
|
|
68
|
+
label: string;
|
|
69
|
+
};
|
|
70
|
+
asLowAs: {
|
|
71
|
+
label: string;
|
|
72
|
+
};
|
|
73
|
+
};
|
|
74
|
+
Swatches: {
|
|
75
|
+
outOfStock: {
|
|
76
|
+
label: string;
|
|
77
|
+
};
|
|
78
|
+
selected: {
|
|
79
|
+
label: string;
|
|
80
|
+
};
|
|
81
|
+
swatch: {
|
|
82
|
+
label: string;
|
|
83
|
+
};
|
|
84
|
+
};
|
|
85
|
+
Accordion: {
|
|
86
|
+
open: {
|
|
87
|
+
label: string;
|
|
88
|
+
};
|
|
89
|
+
close: {
|
|
90
|
+
label: string;
|
|
91
|
+
};
|
|
92
|
+
};
|
|
93
|
+
CartItem: {
|
|
94
|
+
each: {
|
|
95
|
+
label: string;
|
|
96
|
+
};
|
|
97
|
+
quantity: {
|
|
98
|
+
label: string;
|
|
99
|
+
};
|
|
100
|
+
remove: {
|
|
101
|
+
label: string;
|
|
102
|
+
};
|
|
103
|
+
removeDefault: {
|
|
104
|
+
label: string;
|
|
105
|
+
};
|
|
106
|
+
taxIncluded: {
|
|
107
|
+
label: string;
|
|
108
|
+
};
|
|
109
|
+
updating: {
|
|
110
|
+
label: string;
|
|
111
|
+
};
|
|
112
|
+
};
|
|
113
|
+
};
|
|
114
|
+
};
|
|
115
|
+
en_US: {
|
|
116
|
+
Dropin: {
|
|
117
|
+
ExampleComponentName: {
|
|
118
|
+
item: {
|
|
119
|
+
label: string;
|
|
120
|
+
};
|
|
121
|
+
};
|
|
122
|
+
Incrementer: {
|
|
123
|
+
decreaseLabel: string;
|
|
124
|
+
increaseLabel: string;
|
|
125
|
+
label: string;
|
|
126
|
+
};
|
|
127
|
+
Modal: {
|
|
128
|
+
Close: {
|
|
129
|
+
label: string;
|
|
130
|
+
};
|
|
131
|
+
};
|
|
132
|
+
InlineAlert: {
|
|
133
|
+
dismissLabel: string;
|
|
134
|
+
};
|
|
135
|
+
PriceSummary: {
|
|
136
|
+
subTotal: {
|
|
137
|
+
label: string;
|
|
138
|
+
withTaxes: string;
|
|
139
|
+
};
|
|
140
|
+
shipping: {
|
|
141
|
+
label: string;
|
|
142
|
+
editZipAction: string;
|
|
143
|
+
estimated: string;
|
|
144
|
+
estimatedDestination: string;
|
|
145
|
+
destinationLinkAriaLabel: string;
|
|
146
|
+
zipPlaceholder: string;
|
|
147
|
+
withTaxes: string;
|
|
148
|
+
alternateField: {
|
|
149
|
+
zip: string;
|
|
150
|
+
state: string;
|
|
151
|
+
};
|
|
152
|
+
};
|
|
153
|
+
taxes: {
|
|
154
|
+
total: string;
|
|
155
|
+
totalOnly: string;
|
|
156
|
+
breakdown: string;
|
|
157
|
+
showBreakdown: string;
|
|
158
|
+
hideBreakdown: string;
|
|
159
|
+
estimated: string;
|
|
160
|
+
};
|
|
161
|
+
total: {
|
|
162
|
+
estimated: string;
|
|
163
|
+
label: string;
|
|
164
|
+
withoutTax: string;
|
|
165
|
+
};
|
|
166
|
+
};
|
|
167
|
+
ProgressSpinner: {
|
|
168
|
+
updating: {
|
|
169
|
+
label: string;
|
|
170
|
+
};
|
|
171
|
+
updatingChildren: {
|
|
172
|
+
label: string;
|
|
173
|
+
};
|
|
174
|
+
};
|
|
175
|
+
PriceRange: {
|
|
176
|
+
from: {
|
|
177
|
+
label: string;
|
|
178
|
+
};
|
|
179
|
+
to: {
|
|
180
|
+
label: string;
|
|
181
|
+
};
|
|
182
|
+
asLowAs: {
|
|
183
|
+
label: string;
|
|
184
|
+
};
|
|
185
|
+
};
|
|
186
|
+
Swatches: {
|
|
187
|
+
outOfStock: {
|
|
188
|
+
label: string;
|
|
189
|
+
};
|
|
190
|
+
selected: {
|
|
191
|
+
label: string;
|
|
192
|
+
};
|
|
193
|
+
swatch: {
|
|
194
|
+
label: string;
|
|
195
|
+
};
|
|
196
|
+
};
|
|
197
|
+
Accordion: {
|
|
198
|
+
open: {
|
|
199
|
+
label: string;
|
|
200
|
+
};
|
|
201
|
+
close: {
|
|
202
|
+
label: string;
|
|
203
|
+
};
|
|
204
|
+
};
|
|
205
|
+
CartItem: {
|
|
206
|
+
each: {
|
|
207
|
+
label: string;
|
|
208
|
+
};
|
|
209
|
+
quantity: {
|
|
210
|
+
label: string;
|
|
211
|
+
};
|
|
212
|
+
remove: {
|
|
213
|
+
label: string;
|
|
214
|
+
};
|
|
215
|
+
removeDefault: {
|
|
216
|
+
label: string;
|
|
217
|
+
};
|
|
218
|
+
taxIncluded: {
|
|
219
|
+
label: string;
|
|
220
|
+
};
|
|
221
|
+
updating: {
|
|
222
|
+
label: string;
|
|
223
|
+
};
|
|
224
|
+
};
|
|
225
|
+
};
|
|
226
|
+
};
|
|
227
|
+
};
|
|
228
|
+
export * from 'preact-i18n';
|
|
229
|
+
export declare const getDefinitionByLanguage: (lang: Lang) => {
|
|
230
|
+
Dropin: {
|
|
231
|
+
ExampleComponentName: {
|
|
232
|
+
item: {
|
|
233
|
+
label: string;
|
|
234
|
+
};
|
|
235
|
+
};
|
|
236
|
+
Incrementer: {
|
|
237
|
+
decreaseLabel: string;
|
|
238
|
+
increaseLabel: string;
|
|
239
|
+
label: string;
|
|
240
|
+
};
|
|
241
|
+
Modal: {
|
|
242
|
+
Close: {
|
|
243
|
+
label: string;
|
|
244
|
+
};
|
|
245
|
+
};
|
|
246
|
+
InlineAlert: {
|
|
247
|
+
dismissLabel: string;
|
|
248
|
+
};
|
|
249
|
+
PriceSummary: {
|
|
250
|
+
subTotal: {
|
|
251
|
+
label: string;
|
|
252
|
+
withTaxes: string;
|
|
253
|
+
};
|
|
254
|
+
shipping: {
|
|
255
|
+
label: string;
|
|
256
|
+
editZipAction: string;
|
|
257
|
+
estimated: string;
|
|
258
|
+
estimatedDestination: string;
|
|
259
|
+
destinationLinkAriaLabel: string;
|
|
260
|
+
zipPlaceholder: string;
|
|
261
|
+
withTaxes: string;
|
|
262
|
+
alternateField: {
|
|
263
|
+
zip: string;
|
|
264
|
+
state: string;
|
|
265
|
+
};
|
|
266
|
+
};
|
|
267
|
+
taxes: {
|
|
268
|
+
total: string;
|
|
269
|
+
totalOnly: string;
|
|
270
|
+
breakdown: string;
|
|
271
|
+
showBreakdown: string;
|
|
272
|
+
hideBreakdown: string;
|
|
273
|
+
estimated: string;
|
|
274
|
+
};
|
|
275
|
+
total: {
|
|
276
|
+
estimated: string;
|
|
277
|
+
label: string;
|
|
278
|
+
withoutTax: string;
|
|
279
|
+
};
|
|
280
|
+
};
|
|
281
|
+
ProgressSpinner: {
|
|
282
|
+
updating: {
|
|
283
|
+
label: string;
|
|
284
|
+
};
|
|
285
|
+
updatingChildren: {
|
|
286
|
+
label: string;
|
|
287
|
+
};
|
|
288
|
+
};
|
|
289
|
+
PriceRange: {
|
|
290
|
+
from: {
|
|
291
|
+
label: string;
|
|
292
|
+
};
|
|
293
|
+
to: {
|
|
294
|
+
label: string;
|
|
295
|
+
};
|
|
296
|
+
asLowAs: {
|
|
297
|
+
label: string;
|
|
298
|
+
};
|
|
299
|
+
};
|
|
300
|
+
Swatches: {
|
|
301
|
+
outOfStock: {
|
|
302
|
+
label: string;
|
|
303
|
+
};
|
|
304
|
+
selected: {
|
|
305
|
+
label: string;
|
|
306
|
+
};
|
|
307
|
+
swatch: {
|
|
308
|
+
label: string;
|
|
309
|
+
};
|
|
310
|
+
};
|
|
311
|
+
Accordion: {
|
|
312
|
+
open: {
|
|
313
|
+
label: string;
|
|
314
|
+
};
|
|
315
|
+
close: {
|
|
316
|
+
label: string;
|
|
317
|
+
};
|
|
318
|
+
};
|
|
319
|
+
CartItem: {
|
|
320
|
+
each: {
|
|
321
|
+
label: string;
|
|
322
|
+
};
|
|
323
|
+
quantity: {
|
|
324
|
+
label: string;
|
|
325
|
+
};
|
|
326
|
+
remove: {
|
|
327
|
+
label: string;
|
|
328
|
+
};
|
|
329
|
+
removeDefault: {
|
|
330
|
+
label: string;
|
|
331
|
+
};
|
|
332
|
+
taxIncluded: {
|
|
333
|
+
label: string;
|
|
334
|
+
};
|
|
335
|
+
updating: {
|
|
336
|
+
label: string;
|
|
337
|
+
};
|
|
338
|
+
};
|
|
339
|
+
};
|
|
340
|
+
};
|
|
341
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/i18n/index.ts"],"names":[],"mappings":"AAGA,MAAM,MAAM,IAAI,GAAG,OAAO,CAAC;AAE3B,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAGtB,CAAC;AAIF,cAAc,aAAa,CAAC;AAE5B,eAAO,MAAM,uBAAuB,SAAU,IAAI;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAEjD,CAAC"}
|
package/i18n/index.js
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { deepmerge } from '@adobe/elsie/lib';
|
|
2
|
+
import en_US from '@adobe/elsie/i18n/en_US.json';
|
|
3
|
+
export const definition = {
|
|
4
|
+
default: en_US,
|
|
5
|
+
en_US,
|
|
6
|
+
};
|
|
7
|
+
// https://github.com/synacor/preact-i18n
|
|
8
|
+
// eslint-disable-next-line no-restricted-imports
|
|
9
|
+
export * from 'preact-i18n';
|
|
10
|
+
export const getDefinitionByLanguage = (lang) => {
|
|
11
|
+
return deepmerge(definition.default, definition[lang] || {});
|
|
12
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.test.d.ts","sourceRoot":"","sources":["../../src/i18n/index.test.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { getDefinitionByLanguage, definition } from './';
|
|
2
|
+
describe('getDefinitionByLanguage()', () => {
|
|
3
|
+
test('returns the default definition when there is not match', () => {
|
|
4
|
+
const selected = getDefinitionByLanguage('not_found');
|
|
5
|
+
expect(selected).toMatchObject(definition.default);
|
|
6
|
+
});
|
|
7
|
+
test('returns the selected definition', () => {
|
|
8
|
+
const selected = getDefinitionByLanguage('en_US');
|
|
9
|
+
expect(selected).toMatchObject(definition.en_US);
|
|
10
|
+
});
|
|
11
|
+
});
|
package/icons/index.d.ts
ADDED
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
export { default as Add } from './Add.svg';
|
|
2
|
+
export { default as Bulk } from './Bulk.svg';
|
|
3
|
+
export { default as Burger } from './Burger.svg';
|
|
4
|
+
export { default as Cart } from './Cart.svg';
|
|
5
|
+
export { default as Check } from './Check.svg';
|
|
6
|
+
export { default as ChevronDown } from './ChevronDown.svg';
|
|
7
|
+
export { default as ChevronUp } from './ChevronUp.svg';
|
|
8
|
+
export { default as ChevronRight } from './ChevronRight.svg';
|
|
9
|
+
export { default as Close } from './Close.svg';
|
|
10
|
+
export { default as Heart } from './Heart.svg';
|
|
11
|
+
export { default as Minus } from './Minus.svg';
|
|
12
|
+
export { default as Placeholder } from './Placeholder.svg';
|
|
13
|
+
export { default as PlaceholderFilled } from './PlaceholderFilled.svg';
|
|
14
|
+
export { default as Search } from './Search.svg';
|
|
15
|
+
export { default as SearchFilled } from './SearchFilled.svg';
|
|
16
|
+
export { default as Sort } from './Sort.svg';
|
|
17
|
+
export { default as Star } from './Star.svg';
|
|
18
|
+
export { default as View } from './View.svg';
|
|
19
|
+
export { default as User } from './User.svg';
|
|
20
|
+
export { default as Warning } from './Warning.svg';
|
|
21
|
+
export { default as Locker } from './Locker.svg';
|
|
22
|
+
export { default as Wallet } from './Wallet.svg';
|
|
23
|
+
export { default as Card } from './Card.svg';
|
|
24
|
+
export { default as Order } from './Order.svg';
|
|
25
|
+
export { default as Delivery } from './Delivery.svg';
|
|
26
|
+
export { default as OrderError } from './OrderError.svg';
|
|
27
|
+
export { default as OrderSuccess } from './OrderSuccess.svg';
|
|
28
|
+
export { default as PaymentError } from './PaymentError.svg';
|
|
29
|
+
export { default as CheckWithCircle } from './CheckWithCircle.svg';
|
|
30
|
+
export { default as WarningWithCircle } from './WarningWithCircle.svg';
|
|
31
|
+
export { default as WarningFilled } from './WarningFilled.svg';
|
|
32
|
+
export { default as InfoFilled } from './InfoFilled.svg';
|
|
33
|
+
export { default as HeartFilled } from './HeartFilled.svg';
|
|
34
|
+
export { default as Trash } from './Trash.svg';
|
|
35
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/icons/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,GAAG,EAAE,MAAM,WAAW,CAAC;AAC3C,OAAO,EAAE,OAAO,IAAI,IAAI,EAAE,MAAM,YAAY,CAAC;AAC7C,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,cAAc,CAAC;AACjD,OAAO,EAAE,OAAO,IAAI,IAAI,EAAE,MAAM,YAAY,CAAC;AAC7C,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAC3D,OAAO,EAAE,OAAO,IAAI,SAAS,EAAE,MAAM,iBAAiB,CAAC;AACvD,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAC7D,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAC3D,OAAO,EAAE,OAAO,IAAI,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AACvE,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,cAAc,CAAC;AACjD,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAC7D,OAAO,EAAE,OAAO,IAAI,IAAI,EAAE,MAAM,YAAY,CAAC;AAC7C,OAAO,EAAE,OAAO,IAAI,IAAI,EAAE,MAAM,YAAY,CAAC;AAC7C,OAAO,EAAE,OAAO,IAAI,IAAI,EAAE,MAAM,YAAY,CAAC;AAC7C,OAAO,EAAE,OAAO,IAAI,IAAI,EAAE,MAAM,YAAY,CAAC;AAC7C,OAAO,EAAE,OAAO,IAAI,OAAO,EAAE,MAAM,eAAe,CAAC;AACnD,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,cAAc,CAAC;AACjD,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,cAAc,CAAC;AACjD,OAAO,EAAE,OAAO,IAAI,IAAI,EAAE,MAAM,YAAY,CAAC;AAC7C,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AACrD,OAAO,EAAE,OAAO,IAAI,UAAU,EAAE,MAAM,kBAAkB,CAAC;AACzD,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAC7D,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAC7D,OAAO,EAAE,OAAO,IAAI,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACnE,OAAO,EAAE,OAAO,IAAI,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AACvE,OAAO,EAAE,OAAO,IAAI,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAC/D,OAAO,EAAE,OAAO,IAAI,UAAU,EAAE,MAAM,kBAAkB,CAAC;AACzD,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAC3D,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,aAAa,CAAC"}
|
package/icons/index.js
ADDED
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
export { default as Add } from './Add.svg';
|
|
2
|
+
export { default as Bulk } from './Bulk.svg';
|
|
3
|
+
export { default as Burger } from './Burger.svg';
|
|
4
|
+
export { default as Cart } from './Cart.svg';
|
|
5
|
+
export { default as Check } from './Check.svg';
|
|
6
|
+
export { default as ChevronDown } from './ChevronDown.svg';
|
|
7
|
+
export { default as ChevronUp } from './ChevronUp.svg';
|
|
8
|
+
export { default as ChevronRight } from './ChevronRight.svg';
|
|
9
|
+
export { default as Close } from './Close.svg';
|
|
10
|
+
export { default as Heart } from './Heart.svg';
|
|
11
|
+
export { default as Minus } from './Minus.svg';
|
|
12
|
+
export { default as Placeholder } from './Placeholder.svg';
|
|
13
|
+
export { default as PlaceholderFilled } from './PlaceholderFilled.svg';
|
|
14
|
+
export { default as Search } from './Search.svg';
|
|
15
|
+
export { default as SearchFilled } from './SearchFilled.svg';
|
|
16
|
+
export { default as Sort } from './Sort.svg';
|
|
17
|
+
export { default as Star } from './Star.svg';
|
|
18
|
+
export { default as View } from './View.svg';
|
|
19
|
+
export { default as User } from './User.svg';
|
|
20
|
+
export { default as Warning } from './Warning.svg';
|
|
21
|
+
export { default as Locker } from './Locker.svg';
|
|
22
|
+
export { default as Wallet } from './Wallet.svg';
|
|
23
|
+
export { default as Card } from './Card.svg';
|
|
24
|
+
export { default as Order } from './Order.svg';
|
|
25
|
+
export { default as Delivery } from './Delivery.svg';
|
|
26
|
+
export { default as OrderError } from './OrderError.svg';
|
|
27
|
+
export { default as OrderSuccess } from './OrderSuccess.svg';
|
|
28
|
+
export { default as PaymentError } from './PaymentError.svg';
|
|
29
|
+
export { default as CheckWithCircle } from './CheckWithCircle.svg';
|
|
30
|
+
export { default as WarningWithCircle } from './WarningWithCircle.svg';
|
|
31
|
+
export { default as WarningFilled } from './WarningFilled.svg';
|
|
32
|
+
export { default as InfoFilled } from './InfoFilled.svg';
|
|
33
|
+
export { default as HeartFilled } from './HeartFilled.svg';
|
|
34
|
+
export { default as Trash } from './Trash.svg';
|
package/initializer.js
CHANGED
|
@@ -1 +1,61 @@
|
|
|
1
|
-
export const id=865;export const ids=[865];export const modules={
|
|
1
|
+
export const id=865;export const ids=[865];export const modules={
|
|
2
|
+
/***/173:
|
|
3
|
+
/***/(t,e,r)=>{
|
|
4
|
+
// EXPORTS
|
|
5
|
+
r.d(e,{H:()=>/* binding */f,W:()=>/* binding */m});// CONCATENATED MODULE: ./lib/config.ts
|
|
6
|
+
class i{constructor(t){this.config=t}getConfig(){return this.config}setConfig(t){this.config=t}}var n=new// CONCATENATED MODULE: ./lib/image-params-keymap.ts
|
|
7
|
+
class{get map(){return this._map}set map(t){this._map=t}getMethods(){return{setMap:t=>{this.map=t},getMap:()=>this.map}}},{setMap:s,getMap:a}=n.getMethods(),o=["imageParamsKeyMap"];function l(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,i)}return r}function c(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?l(Object(r),!0).forEach((function(e){p(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):l(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function u(t,e){if(null==t)return{};var r,i,n=function(t,e){if(null==t)return{};var r,i,n={},s=Object.keys(t);for(i=0;i<s.length;i++)r=s[i],e.indexOf(r)>=0||(n[r]=t[r]);return n}(t,e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);for(i=0;i<s.length;i++)r=s[i],e.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(t,r)&&(n[r]=t[r])}return n}function p(t,e,r){var i;return(e="symbol"==typeof(i=function(t,e){if("object"!=typeof t||!t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var i=r.call(t,e||"default");if("object"!=typeof i)return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}
|
|
8
|
+
/**
|
|
9
|
+
* `Initializer` is a class that represents an initializer.
|
|
10
|
+
* An initializer is responsible for setting up event listeners and initializing a module.
|
|
11
|
+
*
|
|
12
|
+
* @class
|
|
13
|
+
*
|
|
14
|
+
* @property {Function} listeners - A method that accepts a config object and returns an array of listeners.
|
|
15
|
+
* @property {Function} init - A method that initializes the module. It accepts an options object.
|
|
16
|
+
* @property {Config} config - A Config object that stores the configuration for the module.
|
|
17
|
+
*
|
|
18
|
+
* @method constructor - Constructs a new Initializer. Accepts an options object with `init` and `listeners` properties.
|
|
19
|
+
*/(e,"string"))?i:String(i))in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}class f{
|
|
20
|
+
/**
|
|
21
|
+
* Constructs a new Initializer.
|
|
22
|
+
*
|
|
23
|
+
* @param {Object} options - The options for the Initializer.
|
|
24
|
+
* @param {Function} options.listeners - A function that accepts a config object and returns an array of listeners.
|
|
25
|
+
* @param {Function} options.init - A function that initializes the module. It accepts an options object.
|
|
26
|
+
*/
|
|
27
|
+
constructor(t){var{init:e,listeners:r}=t;p(this,"_listeners",[]),p(this,"config",new i({})),this.listeners=t=>(
|
|
28
|
+
// Unbind existing listeners
|
|
29
|
+
this._listeners.forEach((t=>t.off())),this._listeners=r(t)),this.init=t=>{var r=t,{imageParamsKeyMap:i}=r,n=u(r,o);return this.config.setConfig(c(c({},this.config.getConfig()),n)),s(i),e(t)}}}
|
|
30
|
+
/**
|
|
31
|
+
* Class representing initializers.
|
|
32
|
+
*
|
|
33
|
+
* @class
|
|
34
|
+
*
|
|
35
|
+
* @method register - Registers a new initializer. If the initializers have already been mounted, it also immediately binds the event listeners and initializes the API for the new initializer.
|
|
36
|
+
* @method mount - Mounts all registered initializers. This involves binding the event listeners and initializing the APIs for each initializer, in that order.
|
|
37
|
+
* @method setImageParamKeys - Sets the image parameter keys. These keys are used when initializing the APIs for the initializers.
|
|
38
|
+
*/class m{
|
|
39
|
+
/**
|
|
40
|
+
* Registers a new initializer.
|
|
41
|
+
*
|
|
42
|
+
* @param initializer - The initializer to register. This should be an object with `listeners` and `init` methods.
|
|
43
|
+
* @param options - An optional object with additional options. These options are passed to the `listeners` and `init` methods of the initializer.
|
|
44
|
+
*/
|
|
45
|
+
static register(t,e){var r,i;m._mounted&&(null===(r=t.listeners)||void 0===r||r.call(t,e),null===(i=t.init)||void 0===i||i.call(t,e));m._initializers.push([t,e])}
|
|
46
|
+
/**
|
|
47
|
+
* Mounts all registered initializers.
|
|
48
|
+
*/static mount(){var t,e;m._mounted=!0,
|
|
49
|
+
// In this specific order
|
|
50
|
+
// 1. Bind events
|
|
51
|
+
null===(t=m._initializers)||void 0===t||t.forEach((t=>{var e,[r,i]=t;null===(e=r.listeners)||void 0===e||e.call(r,i)})),
|
|
52
|
+
// 2. Initialize APIs
|
|
53
|
+
null===(e=m._initializers)||void 0===e||e.forEach((t=>{var e,[r,i]=t;null===(e=r.init)||void 0===e||e.call(r,c({imageParamsKeyMap:m._imageParamsKeyMap},i))}))}
|
|
54
|
+
/**
|
|
55
|
+
* Sets the image parameter keys.
|
|
56
|
+
*
|
|
57
|
+
* @param params - An object mapping keys to values.
|
|
58
|
+
*/static setImageParamKeys(t){m._imageParamsKeyMap=t}}p(m,"_initializers",[]),p(m,"_mounted",!1),p(m,"_imageParamsKeyMap",void 0)}
|
|
59
|
+
/***/};
|
|
60
|
+
// load runtime
|
|
61
|
+
import t from"./runtime.js";import*as e from"./initializer.js";t.C(e);var r,i=(r=173,t(t.s=r)),n=i.H,s=i.W;export{n as Initializer,s as initializers};
|
package/lib/classes.d.ts
ADDED
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { JSXInternal } from 'preact/src/jsx';
|
|
2
|
+
type ClassName = string | JSXInternal.SignalLike<string | undefined>;
|
|
3
|
+
export declare const classes: (classes: Array<ClassName | [ClassName, boolean] | undefined>) => string;
|
|
4
|
+
export {};
|
|
5
|
+
//# sourceMappingURL=classes.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"classes.d.ts","sourceRoot":"","sources":["../../src/lib/classes.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7C,KAAK,SAAS,GAAG,MAAM,GAAG,WAAW,CAAC,UAAU,CAAC,MAAM,GAAG,SAAS,CAAC,CAAC;AAErE,eAAO,MAAM,OAAO,YACT,MAAM,SAAS,GAAG,CAAC,SAAS,EAAE,OAAO,CAAC,GAAG,SAAS,CAAC,WAkB7D,CAAC"}
|
package/lib/classes.js
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export const classes = (classes) => {
|
|
2
|
+
const result = classes.reduce((result, item) => {
|
|
3
|
+
if (!item)
|
|
4
|
+
return result;
|
|
5
|
+
if (typeof item === 'string')
|
|
6
|
+
result += ` ${item}`;
|
|
7
|
+
if (Array.isArray(item)) {
|
|
8
|
+
const [className, isActive] = item;
|
|
9
|
+
if (className && isActive) {
|
|
10
|
+
result += ` ${className}`;
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
return result;
|
|
14
|
+
}, '');
|
|
15
|
+
return result.trim();
|
|
16
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"classes.test.d.ts","sourceRoot":"","sources":["../../src/lib/classes.test.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { classes } from './classes';
|
|
2
|
+
describe('classes()', () => {
|
|
3
|
+
test('returns a string of space separated entries from an array of strings', () => {
|
|
4
|
+
const classList = ['class-1', 'class-2', 'class-3'];
|
|
5
|
+
const result = classes(classList);
|
|
6
|
+
expect(result).toMatchInlineSnapshot(`"class-1 class-2 class-3"`);
|
|
7
|
+
});
|
|
8
|
+
test('omits strings inside arrays that have a false value as its second entry', () => {
|
|
9
|
+
const classList = [
|
|
10
|
+
'class-1',
|
|
11
|
+
['class-2', true],
|
|
12
|
+
['class-3', false],
|
|
13
|
+
'class-4',
|
|
14
|
+
];
|
|
15
|
+
const result = classes(classList);
|
|
16
|
+
expect(result).toMatchInlineSnapshot(`"class-1 class-2 class-4"`);
|
|
17
|
+
});
|
|
18
|
+
});
|
package/lib/config.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../src/lib/config.ts"],"names":[],"mappings":"AAAA,qBAAa,MAAM,CAAC,CAAC;IACnB,OAAO,CAAC,MAAM,CAAI;gBAEN,aAAa,EAAE,CAAC;IAI5B,SAAS,IAAI,CAAC;IAId,SAAS,CAAC,SAAS,EAAE,CAAC,GAAG,IAAI;CAG9B"}
|
package/lib/config.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"config.test.d.ts","sourceRoot":"","sources":["../../src/lib/config.test.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Config } from './config';
|
|
2
|
+
describe('Config', () => {
|
|
3
|
+
test('setConfig', () => {
|
|
4
|
+
const config = new Config({ foo: 'bar' });
|
|
5
|
+
config.setConfig({ foo: 'baz' });
|
|
6
|
+
expect(config.getConfig()).toEqual({ foo: 'baz' });
|
|
7
|
+
});
|
|
8
|
+
test('getConfig', () => {
|
|
9
|
+
const config = new Config({ foo: 'bar' });
|
|
10
|
+
expect(config.getConfig()).toEqual({ foo: 'bar' });
|
|
11
|
+
});
|
|
12
|
+
});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"debounce.d.ts","sourceRoot":"","sources":["../../src/lib/debounce.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,QAAQ,OAAQ,QAAQ,MAAM,MAAM,YAExB,GAAG,WAAW,GAAG,EAAE,SAI3C,CAAC"}
|
package/lib/debounce.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"debounce.test.d.ts","sourceRoot":"","sources":["../../src/lib/debounce.test.ts"],"names":[],"mappings":""}
|