colibri-ui 0.8.1 → 0.8.3
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/{src/components/Accordion/Accordion.module.scss → Accordion/Accordion.module.css} +7 -9
- package/Accordion/index.d.ts +9 -0
- package/Accordion/index.js +67 -0
- package/Accordion/package.json +6 -0
- package/{src/components/Avatar/Avatar.module.scss → Avatar/Avatar.module.css} +3 -4
- package/Avatar/assets/org-circle.svg.js +64 -0
- package/Avatar/assets/user-circle.svg.js +43 -0
- package/Avatar/constants.d.ts +7 -0
- package/Avatar/constants.js +10 -0
- package/Avatar/index.d.ts +4 -0
- package/Avatar/index.js +49 -0
- package/Avatar/index.props.d.ts +15 -0
- package/Avatar/index.props.js +7 -0
- package/Avatar/package.json +6 -0
- package/{src/components/Badge/Badge.module.scss → Badge/Badge.module.css} +13 -16
- package/{src/components/Badge/Control/Control.module.scss → Badge/Control/Control.module.css} +1 -1
- package/Badge/Control/index.d.ts +3 -0
- package/Badge/Control/index.js +23 -0
- package/{src/components/Badge/Control/index.props.ts → Badge/Control/index.props.d.ts} +1 -1
- package/Badge/index.d.ts +4 -0
- package/Badge/index.js +48 -0
- package/Badge/index.props.d.ts +11 -0
- package/Badge/package.json +6 -0
- package/Button/Button.module.css +225 -0
- package/Button/index.d.ts +4 -0
- package/Button/index.js +56 -0
- package/Button/index.props.d.ts +14 -0
- package/Button/package.json +6 -0
- package/Calendar/components/ContinueButton/index.d.ts +10 -0
- package/Calendar/components/ContinueButton/index.js +45 -0
- package/Calendar/components/ContinueButton/index.module.css +4 -0
- package/Calendar/components/Month/Month.d.ts +17 -0
- package/Calendar/components/Month/Month.js +144 -0
- package/{src/components/Calendar/components/Month/index.module.scss → Calendar/components/Month/index.module.css} +48 -62
- package/Calendar/components/Presets/index.d.ts +19 -0
- package/Calendar/components/Presets/index.js +68 -0
- package/{src/components/Calendar/components/Presets/index.module.scss → Calendar/components/Presets/index.module.css} +11 -14
- package/Calendar/index.d.ts +4 -0
- package/Calendar/index.js +222 -0
- package/{src/components/Calendar/index.module.scss → Calendar/index.module.css} +37 -51
- package/Calendar/index.props.d.ts +21 -0
- package/Calendar/package.json +6 -0
- package/Calendar/utils/getMonthWeeks.d.ts +20 -0
- package/Calendar/utils/getMonthWeeks.js +81 -0
- package/Calendar/utils/getNumberOfMonthsBetweenDates.d.ts +4 -0
- package/Calendar/utils/getNumberOfMonthsBetweenDates.js +21 -0
- package/Calendar/utils/getPresets.d.ts +10 -0
- package/Calendar/utils/getStartMonth.d.ts +6 -0
- package/Calendar/utils/getStartMonth.js +15 -0
- package/Checkbox/Checkbox.module.css +89 -0
- package/Checkbox/index.d.ts +4 -0
- package/Checkbox/index.js +59 -0
- package/Checkbox/index.props.d.ts +17 -0
- package/Checkbox/package.json +6 -0
- package/Chip/Chip.module.css +83 -0
- package/Chip/index.d.ts +4 -0
- package/Chip/index.js +56 -0
- package/Chip/index.props.d.ts +10 -0
- package/Chip/package.json +6 -0
- package/ClickOutside/index.d.ts +5 -0
- package/ClickOutside/index.js +36 -0
- package/ClickOutside/package.json +6 -0
- package/{src/components/Counter/Counter.module.scss → Counter/Counter.module.css} +7 -9
- package/Counter/index.d.ts +4 -0
- package/Counter/index.js +71 -0
- package/Counter/index.props.d.ts +9 -0
- package/Counter/package.json +6 -0
- package/{src/components/Datepicker/Datepicker.module.scss → Datepicker/Datepicker.module.css} +1 -1
- package/Datepicker/components/DatePicker/index.d.ts +4 -0
- package/Datepicker/components/DatePicker/index.js +74 -0
- package/{src/components/Datepicker/components/DatePicker/index.module.scss → Datepicker/components/DatePicker/index.module.css} +0 -2
- package/Datepicker/components/DatePicker/index.props.d.ts +5 -0
- package/Datepicker/components/TimePicker/Label/index.d.ts +8 -0
- package/Datepicker/components/TimePicker/Label/index.js +27 -0
- package/Datepicker/components/TimePicker/helpers.d.ts +12 -0
- package/Datepicker/components/TimePicker/helpers.js +41 -0
- package/Datepicker/components/TimePicker/index.d.ts +4 -0
- package/Datepicker/components/TimePicker/index.js +67 -0
- package/{src/components/Datepicker/components/TimePicker/index.module.scss → Datepicker/components/TimePicker/index.module.css} +1 -1
- package/Datepicker/components/TimePicker/index.props.d.ts +8 -0
- package/Datepicker/index.d.ts +4 -0
- package/Datepicker/index.js +35 -0
- package/Datepicker/index.props.d.ts +7 -0
- package/Datepicker/package.json +6 -0
- package/{src/components/DotsLoader/DotsLoader.module.scss → DotsLoader/DotsLoader.module.css} +12 -19
- package/DotsLoader/index.d.ts +5 -0
- package/DotsLoader/index.js +55 -0
- package/DotsLoader/package.json +6 -0
- package/{src/components/Dropdown/Dropdown.module.scss → Dropdown/Dropdown.module.css} +1 -1
- package/Dropdown/index.d.ts +4 -0
- package/Dropdown/index.js +165 -0
- package/Dropdown/index.props.d.ts +20 -0
- package/Dropdown/package.json +6 -0
- package/{src/components/Grid/Grid.module.scss → Grid/Grid.module.css} +1 -2
- package/{src/components/Grid/Item/Grid-Item.module.scss → Grid/Item/Grid-Item.module.css} +2 -2
- package/Grid/Item/index.d.ts +4 -0
- package/Grid/Item/index.js +28 -0
- package/{src/components/Grid/Item/index.props.ts → Grid/Item/index.props.d.ts} +3 -4
- package/Grid/index.d.ts +4 -0
- package/Grid/index.js +34 -0
- package/Grid/index.props.d.ts +6 -0
- package/Grid/package.json +6 -0
- package/Icons/ArrowNext.d.ts +4 -0
- package/Icons/ArrowNext.js +36 -0
- package/Icons/Cart.d.ts +4 -0
- package/Icons/Cart.js +34 -0
- package/Icons/Check.d.ts +4 -0
- package/Icons/Check.js +42 -0
- package/Icons/Chevron.d.ts +4 -0
- package/Icons/Chevron.js +37 -0
- package/Icons/Close.d.ts +4 -0
- package/Icons/Close.js +35 -0
- package/Icons/CrossFill.d.ts +4 -0
- package/Icons/CrossFill.js +33 -0
- package/Icons/Edit.d.ts +4 -0
- package/Icons/Edit.js +35 -0
- package/Icons/Exit.d.ts +4 -0
- package/Icons/Exit.js +36 -0
- package/Icons/EyeClosed.d.ts +4 -0
- package/Icons/EyeClosed.js +34 -0
- package/Icons/EyeOpen.d.ts +4 -0
- package/Icons/EyeOpen.js +41 -0
- package/Icons/Help.d.ts +4 -0
- package/Icons/Help.js +34 -0
- package/Icons/Info.d.ts +4 -0
- package/Icons/Info.js +35 -0
- package/Icons/Minus.d.ts +4 -0
- package/Icons/Minus.js +35 -0
- package/Icons/More.d.ts +4 -0
- package/Icons/More.js +44 -0
- package/Icons/Plus.d.ts +4 -0
- package/Icons/Plus.js +34 -0
- package/Icons/Setting.d.ts +4 -0
- package/Icons/Setting.js +43 -0
- package/Icons/Trash.d.ts +4 -0
- package/Icons/Trash.js +37 -0
- package/Icons/User.d.ts +4 -0
- package/Icons/User.js +42 -0
- package/Icons/index.js +39 -0
- package/{src/components/Icons/index.props.ts → Icons/index.props.d.ts} +4 -5
- package/Icons/package.json +6 -0
- package/Image/Image.module.css +14 -0
- package/Image/index.d.ts +4 -0
- package/Image/index.js +72 -0
- package/Image/index.props.d.ts +10 -0
- package/Image/package.json +6 -0
- package/Input/index.d.ts +4 -0
- package/Input/index.js +55 -0
- package/Input/index.props.d.ts +16 -0
- package/Input/package.json +6 -0
- package/InputRadio/InputRadio.module.css +95 -0
- package/InputRadio/index.d.ts +23 -0
- package/InputRadio/index.js +80 -0
- package/InputRadio/package.json +6 -0
- package/{src/components/Menu/Menu.module.scss → Menu/Menu.module.css} +1 -1
- package/Menu/components/MenuItem/MenuItem.module.css +35 -0
- package/Menu/components/MenuItem/index.d.ts +5 -0
- package/Menu/components/MenuItem/index.js +43 -0
- package/Menu/components/MenuItem/index.props.d.ts +10 -0
- package/Menu/index.d.ts +4 -0
- package/Menu/index.js +48 -0
- package/Menu/index.props.d.ts +11 -0
- package/Menu/package.json +6 -0
- package/{src/components/Modal/Modal.module.scss → Modal/Modal.module.css} +12 -14
- package/{src/components/Modal/components/Close/Close.module.scss → Modal/components/Close/Close.module.css} +1 -1
- package/Modal/components/Close/index.d.ts +5 -0
- package/Modal/components/Close/index.js +29 -0
- package/{src/components/Modal/components/Content/Content.module.scss → Modal/components/Content/Content.module.css} +1 -1
- package/Modal/components/Content/index.d.ts +3 -0
- package/Modal/components/Content/index.js +23 -0
- package/{src/components/Modal/components/Title/Title.module.scss → Modal/components/Title/Title.module.css} +1 -1
- package/Modal/components/Title/index.d.ts +3 -0
- package/Modal/components/Title/index.js +29 -0
- package/Modal/index.d.ts +4 -0
- package/Modal/index.js +71 -0
- package/Modal/index.props.d.ts +5 -0
- package/Modal/package.json +6 -0
- package/MultiSelect/components/MenuOverlay/index.d.ts +19 -0
- package/MultiSelect/components/MenuOverlay/index.js +103 -0
- package/{src/components/MultiSelect/components/MenuOverlay/index.module.scss → MultiSelect/components/MenuOverlay/index.module.css} +1 -1
- package/MultiSelect/components/MenuOverlayItem/index.d.ts +13 -0
- package/MultiSelect/components/MenuOverlayItem/index.js +28 -0
- package/MultiSelect/index.d.ts +4 -0
- package/MultiSelect/index.js +169 -0
- package/{src/components/MultiSelect/index.module.scss → MultiSelect/index.module.css} +6 -9
- package/MultiSelect/index.props.d.ts +32 -0
- package/MultiSelect/package.json +6 -0
- package/MultiSelect/utils/index.d.ts +1 -0
- package/MultiSelect/utils/index.js +7 -0
- package/Portal/index.d.ts +5 -0
- package/Portal/index.js +24 -0
- package/Portal/package.json +6 -0
- package/RadioGroup/Radio.d.ts +19 -0
- package/RadioGroup/Radio.js +45 -0
- package/RadioGroup/RadioGroup.module.css +31 -0
- package/RadioGroup/index.d.ts +26 -0
- package/RadioGroup/index.js +65 -0
- package/RadioGroup/package.json +6 -0
- package/Select/components/MenuOverlay/index.d.ts +11 -0
- package/Select/components/MenuOverlay/index.js +65 -0
- package/{src/components/Select/components/MenuOverlay/index.module.scss → Select/components/MenuOverlay/index.module.css} +1 -1
- package/Select/components/MenuOverlayItem/index.d.ts +14 -0
- package/Select/components/MenuOverlayItem/index.js +47 -0
- package/Select/index.d.ts +4 -0
- package/Select/index.js +108 -0
- package/{src/components/Select/index.module.scss → Select/index.module.css} +11 -15
- package/Select/index.props.d.ts +28 -0
- package/Select/package.json +6 -0
- package/{src/components/Separator/Separator.module.scss → Separator/Separator.module.css} +1 -1
- package/Separator/index.d.ts +6 -0
- package/Separator/index.js +22 -0
- package/Separator/package.json +6 -0
- package/Skeleton/Skeleton.module.css +33 -0
- package/Skeleton/index.d.ts +4 -0
- package/Skeleton/index.js +41 -0
- package/Skeleton/index.props.d.ts +11 -0
- package/Skeleton/package.json +6 -0
- package/Status/index.d.ts +5 -0
- package/Status/index.js +28 -0
- package/Status/index.module.css +45 -0
- package/Status/index.props.d.ts +12 -0
- package/Status/package.json +6 -0
- package/{src/components/Switch/Switch.module.scss → Switch/Switch.module.css} +15 -21
- package/Switch/index.d.ts +4 -0
- package/Switch/index.js +40 -0
- package/Switch/index.props.d.ts +6 -0
- package/Switch/package.json +6 -0
- package/TabsMenu/Tab/Tab.d.ts +4 -0
- package/TabsMenu/Tab/Tab.js +39 -0
- package/TabsMenu/Tab/Tab.module.css +66 -0
- package/TabsMenu/Tab/Tab.props.d.ts +14 -0
- package/{src/components/TabsMenu/TabsMenu.module.scss → TabsMenu/TabsMenu.module.css} +1 -1
- package/TabsMenu/index.d.ts +4 -0
- package/TabsMenu/index.js +93 -0
- package/TabsMenu/index.props.d.ts +11 -0
- package/TabsMenu/package.json +6 -0
- package/TabsPanes/Pane/Pane.d.ts +3 -0
- package/TabsPanes/Pane/Pane.js +22 -0
- package/TabsPanes/Pane/index.props.d.ts +7 -0
- package/TabsPanes/index.d.ts +4 -0
- package/TabsPanes/index.js +35 -0
- package/{src/components/TabsPanes/index.props.ts → TabsPanes/index.props.d.ts} +4 -5
- package/TabsPanes/package.json +6 -0
- package/{src/components/TextArea/TextArea.module.scss → TextArea/TextArea.module.css} +3 -4
- package/TextArea/index.d.ts +4 -0
- package/TextArea/index.js +62 -0
- package/TextArea/index.props.d.ts +13 -0
- package/TextArea/package.json +6 -0
- package/Theme/breakpoints.d.ts +18 -0
- package/Theme/breakpoints.js +38 -0
- package/Theme/colors/common.d.ts +39 -0
- package/Theme/colors/common.js +34 -0
- package/Theme/colors/index.d.ts +64 -0
- package/Theme/colors/index.js +12 -0
- package/Theme/colors/theme_buenos_aires.d.ts +69 -0
- package/Theme/colors/theme_buenos_aires.js +53 -0
- package/Theme/colors/theme_default.d.ts +47 -0
- package/Theme/colors/theme_default.js +40 -0
- package/Theme/global.css +50 -0
- package/Theme/index.d.ts +296 -0
- package/Theme/index.js +11 -0
- package/Theme/package.json +6 -0
- package/Theme/themes/buenos_aires.d.ts +152 -0
- package/Theme/themes/buenos_aires.js +159 -0
- package/Theme/themes/default.d.ts +144 -0
- package/Theme/themes/default.js +151 -0
- package/TimeSelect/Label/index.d.ts +8 -0
- package/TimeSelect/Label/index.js +27 -0
- package/TimeSelect/helpers.d.ts +9 -0
- package/TimeSelect/helpers.js +41 -0
- package/TimeSelect/index.d.ts +11 -0
- package/TimeSelect/index.js +53 -0
- package/TimeSelect/index.props.d.ts +4 -0
- package/TimeSelect/package.json +6 -0
- package/Tooltip/Tooltip.module.css +122 -0
- package/Tooltip/index.d.ts +4 -0
- package/Tooltip/index.js +116 -0
- package/Tooltip/index.props.d.ts +11 -0
- package/Tooltip/package.json +6 -0
- package/Typography/Typography.module.css +64 -0
- package/Typography/index.d.ts +4 -0
- package/Typography/index.js +34 -0
- package/Typography/index.props.d.ts +13 -0
- package/Typography/package.json +6 -0
- package/{src/components/base/BaseInput/BaseInput.module.scss → base/BaseInput/BaseInput.module.css} +3 -4
- package/base/BaseInput/index.d.ts +4 -0
- package/base/BaseInput/index.js +31 -0
- package/base/BaseInput/index.props.d.ts +5 -0
- package/base/FormField/FormField.module.css +11 -0
- package/base/FormField/index.d.ts +4 -0
- package/base/FormField/index.js +37 -0
- package/base/FormField/index.props.d.ts +10 -0
- package/base/InputRoot/InputRoot.module.css +76 -0
- package/base/InputRoot/index.d.ts +4 -0
- package/base/InputRoot/index.js +41 -0
- package/base/InputRoot/index.props.d.ts +15 -0
- package/esm/Accordion/Accordion.module.css +51 -0
- package/esm/Accordion/index.d.ts +9 -0
- package/esm/Accordion/index.js +57 -0
- package/esm/Avatar/Avatar.module.css +15 -0
- package/esm/Avatar/assets/org-circle.svg.js +39 -0
- package/esm/Avatar/assets/user-circle.svg.js +18 -0
- package/esm/Avatar/constants.d.ts +7 -0
- package/esm/Avatar/constants.js +10 -0
- package/esm/Avatar/index.d.ts +4 -0
- package/esm/Avatar/index.js +39 -0
- package/esm/Avatar/index.props.d.ts +15 -0
- package/esm/Avatar/index.props.js +7 -0
- package/esm/Badge/Badge.module.css +30 -0
- package/esm/Badge/Control/Control.module.css +6 -0
- package/esm/Badge/Control/index.d.ts +3 -0
- package/esm/Badge/Control/index.js +15 -0
- package/esm/Badge/Control/index.props.d.ts +3 -0
- package/esm/Badge/index.d.ts +4 -0
- package/esm/Badge/index.js +38 -0
- package/esm/Badge/index.props.d.ts +11 -0
- package/esm/Button/Button.module.css +225 -0
- package/esm/Button/index.d.ts +4 -0
- package/esm/Button/index.js +46 -0
- package/esm/Button/index.props.d.ts +14 -0
- package/esm/Calendar/components/ContinueButton/index.d.ts +10 -0
- package/esm/Calendar/components/ContinueButton/index.js +37 -0
- package/esm/Calendar/components/ContinueButton/index.module.css +4 -0
- package/esm/Calendar/components/Month/Month.d.ts +17 -0
- package/esm/Calendar/components/Month/Month.js +118 -0
- package/esm/Calendar/components/Month/index.module.css +143 -0
- package/esm/Calendar/components/Presets/index.d.ts +19 -0
- package/esm/Calendar/components/Presets/index.js +42 -0
- package/esm/Calendar/components/Presets/index.module.css +28 -0
- package/esm/Calendar/index.d.ts +4 -0
- package/esm/Calendar/index.js +212 -0
- package/esm/Calendar/index.module.css +92 -0
- package/esm/Calendar/index.props.d.ts +21 -0
- package/esm/Calendar/utils/getMonthWeeks.d.ts +20 -0
- package/esm/Calendar/utils/getMonthWeeks.js +79 -0
- package/esm/Calendar/utils/getNumberOfMonthsBetweenDates.d.ts +4 -0
- package/esm/Calendar/utils/getNumberOfMonthsBetweenDates.js +19 -0
- package/esm/Calendar/utils/getPresets.d.ts +10 -0
- package/esm/Calendar/utils/getStartMonth.d.ts +6 -0
- package/esm/Calendar/utils/getStartMonth.js +13 -0
- package/esm/Checkbox/Checkbox.module.css +89 -0
- package/esm/Checkbox/index.d.ts +4 -0
- package/esm/Checkbox/index.js +49 -0
- package/esm/Checkbox/index.props.d.ts +17 -0
- package/esm/Chip/Chip.module.css +83 -0
- package/esm/Chip/index.d.ts +4 -0
- package/esm/Chip/index.js +46 -0
- package/esm/Chip/index.props.d.ts +10 -0
- package/esm/ClickOutside/index.d.ts +5 -0
- package/esm/ClickOutside/index.js +27 -0
- package/esm/Counter/Counter.module.css +34 -0
- package/esm/Counter/index.d.ts +4 -0
- package/esm/Counter/index.js +61 -0
- package/esm/Counter/index.props.d.ts +9 -0
- package/esm/Datepicker/Datepicker.module.css +4 -0
- package/esm/Datepicker/components/DatePicker/index.d.ts +4 -0
- package/esm/Datepicker/components/DatePicker/index.js +64 -0
- package/esm/Datepicker/components/DatePicker/index.module.css +56 -0
- package/esm/Datepicker/components/DatePicker/index.props.d.ts +5 -0
- package/esm/Datepicker/components/TimePicker/Label/index.d.ts +8 -0
- package/esm/Datepicker/components/TimePicker/Label/index.js +19 -0
- package/esm/Datepicker/components/TimePicker/helpers.d.ts +12 -0
- package/esm/Datepicker/components/TimePicker/helpers.js +35 -0
- package/esm/Datepicker/components/TimePicker/index.d.ts +4 -0
- package/esm/Datepicker/components/TimePicker/index.js +57 -0
- package/esm/Datepicker/components/TimePicker/index.module.css +58 -0
- package/esm/Datepicker/components/TimePicker/index.props.d.ts +8 -0
- package/esm/Datepicker/index.d.ts +4 -0
- package/esm/Datepicker/index.js +25 -0
- package/esm/Datepicker/index.props.d.ts +7 -0
- package/esm/DotsLoader/DotsLoader.module.css +39 -0
- package/esm/DotsLoader/index.d.ts +5 -0
- package/esm/DotsLoader/index.js +45 -0
- package/esm/Dropdown/Dropdown.module.css +14 -0
- package/esm/Dropdown/index.d.ts +4 -0
- package/esm/Dropdown/index.js +155 -0
- package/esm/Dropdown/index.props.d.ts +20 -0
- package/esm/Grid/Grid.module.css +15 -0
- package/esm/Grid/Item/Grid-Item.module.css +9 -0
- package/esm/Grid/Item/index.d.ts +4 -0
- package/esm/Grid/Item/index.js +18 -0
- package/esm/Grid/Item/index.props.d.ts +6 -0
- package/esm/Grid/index.d.ts +4 -0
- package/esm/Grid/index.js +24 -0
- package/esm/Grid/index.props.d.ts +6 -0
- package/esm/Icons/ArrowNext.d.ts +4 -0
- package/esm/Icons/ArrowNext.js +28 -0
- package/esm/Icons/Cart.d.ts +4 -0
- package/esm/Icons/Cart.js +26 -0
- package/esm/Icons/Check.d.ts +4 -0
- package/esm/Icons/Check.js +34 -0
- package/esm/Icons/Chevron.d.ts +4 -0
- package/esm/Icons/Chevron.js +29 -0
- package/esm/Icons/Close.d.ts +4 -0
- package/esm/Icons/Close.js +27 -0
- package/esm/Icons/CrossFill.d.ts +4 -0
- package/esm/Icons/CrossFill.js +25 -0
- package/esm/Icons/Edit.d.ts +4 -0
- package/esm/Icons/Edit.js +27 -0
- package/esm/Icons/Exit.d.ts +4 -0
- package/esm/Icons/Exit.js +28 -0
- package/esm/Icons/EyeClosed.d.ts +4 -0
- package/esm/Icons/EyeClosed.js +26 -0
- package/esm/Icons/EyeOpen.d.ts +4 -0
- package/esm/Icons/EyeOpen.js +33 -0
- package/esm/Icons/Help.d.ts +4 -0
- package/esm/Icons/Help.js +26 -0
- package/esm/Icons/Info.d.ts +4 -0
- package/esm/Icons/Info.js +27 -0
- package/esm/Icons/Minus.d.ts +4 -0
- package/esm/Icons/Minus.js +27 -0
- package/esm/Icons/More.d.ts +4 -0
- package/esm/Icons/More.js +36 -0
- package/esm/Icons/Plus.d.ts +4 -0
- package/esm/Icons/Plus.js +26 -0
- package/esm/Icons/Setting.d.ts +4 -0
- package/esm/Icons/Setting.js +35 -0
- package/esm/Icons/Trash.d.ts +4 -0
- package/esm/Icons/Trash.js +29 -0
- package/esm/Icons/User.d.ts +4 -0
- package/esm/Icons/User.js +34 -0
- package/esm/Icons/index.d.ts +17 -0
- package/esm/Icons/index.js +17 -0
- package/esm/Icons/index.props.d.ts +7 -0
- package/esm/Image/Image.module.css +14 -0
- package/esm/Image/index.d.ts +4 -0
- package/esm/Image/index.js +62 -0
- package/esm/Image/index.props.d.ts +10 -0
- package/esm/Input/index.d.ts +4 -0
- package/esm/Input/index.js +46 -0
- package/esm/Input/index.props.d.ts +16 -0
- package/esm/InputRadio/InputRadio.module.css +95 -0
- package/esm/InputRadio/index.d.ts +23 -0
- package/esm/InputRadio/index.js +70 -0
- package/esm/Menu/Menu.module.css +8 -0
- package/esm/Menu/components/MenuItem/MenuItem.module.css +35 -0
- package/esm/Menu/components/MenuItem/index.d.ts +5 -0
- package/esm/Menu/components/MenuItem/index.js +33 -0
- package/esm/Menu/components/MenuItem/index.props.d.ts +10 -0
- package/esm/Menu/index.d.ts +4 -0
- package/esm/Menu/index.js +38 -0
- package/esm/Menu/index.props.d.ts +11 -0
- package/esm/Modal/Modal.module.css +51 -0
- package/esm/Modal/components/Close/Close.module.css +4 -0
- package/esm/Modal/components/Close/index.d.ts +5 -0
- package/esm/Modal/components/Close/index.js +19 -0
- package/esm/Modal/components/Content/Content.module.css +6 -0
- package/esm/Modal/components/Content/index.d.ts +3 -0
- package/esm/Modal/components/Content/index.js +13 -0
- package/esm/Modal/components/Title/Title.module.css +9 -0
- package/esm/Modal/components/Title/index.d.ts +3 -0
- package/esm/Modal/components/Title/index.js +19 -0
- package/esm/Modal/index.d.ts +4 -0
- package/esm/Modal/index.js +61 -0
- package/esm/Modal/index.props.d.ts +5 -0
- package/esm/MultiSelect/components/MenuOverlay/index.d.ts +19 -0
- package/esm/MultiSelect/components/MenuOverlay/index.js +93 -0
- package/esm/MultiSelect/components/MenuOverlay/index.module.css +9 -0
- package/esm/MultiSelect/components/MenuOverlayItem/index.d.ts +13 -0
- package/esm/MultiSelect/components/MenuOverlayItem/index.js +20 -0
- package/esm/MultiSelect/index.d.ts +4 -0
- package/esm/MultiSelect/index.js +159 -0
- package/esm/MultiSelect/index.module.css +49 -0
- package/esm/MultiSelect/index.props.d.ts +32 -0
- package/esm/MultiSelect/utils/index.d.ts +1 -0
- package/esm/MultiSelect/utils/index.js +5 -0
- package/esm/Portal/index.d.ts +5 -0
- package/esm/Portal/index.js +16 -0
- package/esm/RadioGroup/Radio.d.ts +19 -0
- package/esm/RadioGroup/Radio.js +37 -0
- package/esm/RadioGroup/RadioGroup.module.css +31 -0
- package/esm/RadioGroup/index.d.ts +26 -0
- package/esm/RadioGroup/index.js +55 -0
- package/esm/Select/components/MenuOverlay/index.d.ts +11 -0
- package/esm/Select/components/MenuOverlay/index.js +55 -0
- package/esm/Select/components/MenuOverlay/index.module.css +4 -0
- package/esm/Select/components/MenuOverlayItem/index.d.ts +14 -0
- package/esm/Select/components/MenuOverlayItem/index.js +39 -0
- package/esm/Select/index.d.ts +4 -0
- package/esm/Select/index.js +98 -0
- package/esm/Select/index.module.css +37 -0
- package/esm/Select/index.props.d.ts +28 -0
- package/esm/Separator/Separator.module.css +5 -0
- package/esm/Separator/index.d.ts +6 -0
- package/esm/Separator/index.js +12 -0
- package/esm/Skeleton/Skeleton.module.css +33 -0
- package/esm/Skeleton/index.d.ts +4 -0
- package/esm/Skeleton/index.js +32 -0
- package/esm/Skeleton/index.props.d.ts +11 -0
- package/esm/Status/index.d.ts +5 -0
- package/esm/Status/index.js +18 -0
- package/esm/Status/index.module.css +45 -0
- package/esm/Status/index.props.d.ts +12 -0
- package/esm/Switch/Switch.module.css +56 -0
- package/esm/Switch/index.d.ts +4 -0
- package/esm/Switch/index.js +30 -0
- package/esm/Switch/index.props.d.ts +6 -0
- package/esm/TabsMenu/Tab/Tab.d.ts +4 -0
- package/esm/TabsMenu/Tab/Tab.js +29 -0
- package/esm/TabsMenu/Tab/Tab.module.css +66 -0
- package/esm/TabsMenu/Tab/Tab.props.d.ts +14 -0
- package/esm/TabsMenu/TabsMenu.module.css +8 -0
- package/esm/TabsMenu/index.d.ts +4 -0
- package/esm/TabsMenu/index.js +83 -0
- package/esm/TabsMenu/index.props.d.ts +11 -0
- package/esm/TabsPanes/Pane/Pane.d.ts +3 -0
- package/esm/TabsPanes/Pane/Pane.js +15 -0
- package/esm/TabsPanes/Pane/index.props.d.ts +7 -0
- package/esm/TabsPanes/index.d.ts +4 -0
- package/esm/TabsPanes/index.js +26 -0
- package/esm/TabsPanes/index.props.d.ts +8 -0
- package/esm/TextArea/TextArea.module.css +16 -0
- package/esm/TextArea/index.d.ts +4 -0
- package/esm/TextArea/index.js +51 -0
- package/esm/TextArea/index.props.d.ts +13 -0
- package/esm/Theme/breakpoints.d.ts +18 -0
- package/esm/Theme/breakpoints.js +34 -0
- package/esm/Theme/colors/common.d.ts +39 -0
- package/esm/Theme/colors/common.js +26 -0
- package/esm/Theme/colors/index.d.ts +64 -0
- package/esm/Theme/colors/index.js +8 -0
- package/esm/Theme/colors/theme_buenos_aires.d.ts +69 -0
- package/{src/components/Theme/colors/theme_buenos_aires.ts → esm/Theme/colors/theme_buenos_aires.js} +14 -23
- package/esm/Theme/colors/theme_default.d.ts +47 -0
- package/{src/components/Theme/colors/theme_default.ts → esm/Theme/colors/theme_default.js} +12 -19
- package/esm/Theme/global.css +50 -0
- package/esm/Theme/index.d.ts +296 -0
- package/esm/Theme/index.js +9 -0
- package/esm/Theme/themes/buenos_aires.d.ts +152 -0
- package/{src/components/Theme/themes/buenos_aires.ts → esm/Theme/themes/buenos_aires.js} +5 -18
- package/esm/Theme/themes/default.d.ts +144 -0
- package/{src/components/Theme/themes/default.ts → esm/Theme/themes/default.js} +5 -17
- package/esm/TimeSelect/Label/index.d.ts +8 -0
- package/esm/TimeSelect/Label/index.js +19 -0
- package/esm/TimeSelect/helpers.d.ts +9 -0
- package/esm/TimeSelect/helpers.js +35 -0
- package/esm/TimeSelect/index.d.ts +11 -0
- package/esm/TimeSelect/index.js +45 -0
- package/esm/TimeSelect/index.props.d.ts +4 -0
- package/esm/Tooltip/Tooltip.module.css +122 -0
- package/esm/Tooltip/index.d.ts +4 -0
- package/esm/Tooltip/index.js +106 -0
- package/esm/Tooltip/index.props.d.ts +11 -0
- package/esm/Typography/Typography.module.css +64 -0
- package/esm/Typography/index.d.ts +4 -0
- package/esm/Typography/index.js +24 -0
- package/esm/Typography/index.props.d.ts +13 -0
- package/esm/base/BaseInput/BaseInput.module.css +13 -0
- package/esm/base/BaseInput/index.d.ts +4 -0
- package/esm/base/BaseInput/index.js +21 -0
- package/esm/base/BaseInput/index.props.d.ts +5 -0
- package/esm/base/FormField/FormField.module.css +11 -0
- package/esm/base/FormField/index.d.ts +4 -0
- package/esm/base/FormField/index.js +27 -0
- package/esm/base/FormField/index.props.d.ts +10 -0
- package/esm/base/InputRoot/InputRoot.module.css +76 -0
- package/esm/base/InputRoot/index.d.ts +4 -0
- package/esm/base/InputRoot/index.js +31 -0
- package/esm/base/InputRoot/index.props.d.ts +15 -0
- package/esm/helpers/date/index.d.ts +12 -0
- package/esm/helpers/date/index.js +73 -0
- package/esm/helpers/generateUniqID.d.ts +2 -0
- package/esm/helpers/on.d.ts +1 -0
- package/esm/helpers/on.js +10 -0
- package/esm/hooks/useMediaSizes/index.d.ts +5 -0
- package/esm/hooks/useMediaSizes/index.js +36 -0
- package/esm/hooks/useOnClickOutside/index.d.ts +3 -0
- package/esm/hooks/useOnClickOutside/index.js +28 -0
- package/esm/hooks/useScrollLock/index.d.ts +2 -0
- package/esm/hooks/useScrollLock/index.js +22 -0
- package/esm/hooks/useTrapFocus/index.d.ts +3 -0
- package/esm/hooks/useTrapFocus/index.js +30 -0
- package/esm/index.js +54 -0
- package/esm/lib/keyboard.d.ts +4 -0
- package/esm/lib/keyboard.js +25 -0
- package/esm/libs/numbers/leadingZeros.d.ts +4 -0
- package/{src/components/libs/numbers/leadingZeros.ts → esm/libs/numbers/leadingZeros.js} +4 -4
- package/esm/libs/requestIdleCallback/index.d.ts +5 -0
- package/{src/components/libs/requestIdleCallback/index.ts → esm/libs/requestIdleCallback/index.js} +3 -5
- package/esm/theme_ba_variables.css +151 -0
- package/esm/theme_default_variables.css +143 -0
- package/helpers/date/index.d.ts +12 -0
- package/helpers/date/index.js +84 -0
- package/helpers/generateUniqID.d.ts +2 -0
- package/helpers/on.d.ts +1 -0
- package/helpers/on.js +12 -0
- package/hooks/useMediaSizes/index.d.ts +5 -0
- package/hooks/useMediaSizes/index.js +40 -0
- package/hooks/useOnClickOutside/index.d.ts +3 -0
- package/hooks/useOnClickOutside/index.js +32 -0
- package/hooks/useScrollLock/index.d.ts +2 -0
- package/hooks/useScrollLock/index.js +26 -0
- package/hooks/useTrapFocus/index.d.ts +3 -0
- package/hooks/useTrapFocus/index.js +34 -0
- package/index.d.ts +37 -0
- package/index.js +113 -0
- package/lib/keyboard.d.ts +4 -0
- package/lib/keyboard.js +28 -0
- package/libs/numbers/leadingZeros.d.ts +4 -0
- package/libs/numbers/leadingZeros.js +14 -0
- package/libs/requestIdleCallback/index.d.ts +5 -0
- package/libs/requestIdleCallback/index.js +13 -0
- package/package.json +4 -86
- package/theme_ba_variables.css +151 -0
- package/theme_default_variables.css +143 -0
- package/.babelrc +0 -7
- package/.config/jest/__mocks__/noop.js +0 -1
- package/.config/jest/jest.config.ts +0 -207
- package/.config/jest/jest.setup.ts +0 -4
- package/.prettierignore +0 -5
- package/.prettierrc +0 -8
- package/.storybook/AddonThemesSwitcher/constants.ts +0 -7
- package/.storybook/AddonThemesSwitcher/index.ts +0 -45
- package/.storybook/AddonThemesSwitcher/register.tsx +0 -79
- package/.storybook/main.ts +0 -18
- package/.storybook/manager.tsx +0 -1
- package/.storybook/preview-head.html +0 -19
- package/.storybook/preview.tsx +0 -14
- package/.stylelintrc.json +0 -17
- package/@types/image.d.ts +0 -5
- package/@types/typings.d.ts +0 -2
- package/eslint.config.mjs +0 -83
- package/rollup.config.js +0 -81
- package/scripts/buildSass.js +0 -23
- package/scripts/copyFiles.js +0 -32
- package/scripts/postbuild.js +0 -52
- package/scripts/transformCSS.js +0 -35
- package/scripts/updateImports.js +0 -16
- package/scripts/variables.ts +0 -29
- package/src/components/Accordion/Accordion.stories.tsx +0 -47
- package/src/components/Accordion/index.tsx +0 -71
- package/src/components/Avatar/assets/org-circle.svg +0 -1
- package/src/components/Avatar/assets/user-circle.svg +0 -1
- package/src/components/Avatar/constants.ts +0 -7
- package/src/components/Avatar/index.props.ts +0 -17
- package/src/components/Avatar/index.stories.tsx +0 -36
- package/src/components/Avatar/index.tsx +0 -49
- package/src/components/Badge/Control/index.tsx +0 -16
- package/src/components/Badge/__tests__/Badge.test.tsx +0 -27
- package/src/components/Badge/__tests__/__snapshots__/Badge.test.tsx.snap +0 -28
- package/src/components/Badge/index.props.ts +0 -12
- package/src/components/Badge/index.stories.tsx +0 -68
- package/src/components/Badge/index.tsx +0 -60
- package/src/components/Button/Button.module.scss +0 -265
- package/src/components/Button/index.props.ts +0 -23
- package/src/components/Button/index.stories.tsx +0 -109
- package/src/components/Button/index.tsx +0 -50
- package/src/components/Calendar/components/ContinueButton/index.module.scss +0 -6
- package/src/components/Calendar/components/ContinueButton/index.tsx +0 -45
- package/src/components/Calendar/components/Month/Month.tsx +0 -172
- package/src/components/Calendar/components/Presets/index.tsx +0 -48
- package/src/components/Calendar/index.props.ts +0 -34
- package/src/components/Calendar/index.stories.tsx +0 -45
- package/src/components/Calendar/index.tsx +0 -251
- package/src/components/Calendar/utils/__tests__/getNumberOfMonthsBetweenDates.test.ts +0 -27
- package/src/components/Calendar/utils/getMonthWeeks.ts +0 -135
- package/src/components/Calendar/utils/getNumberOfMonthsBetweenDates.ts +0 -28
- package/src/components/Calendar/utils/getPresets.ts +0 -114
- package/src/components/Calendar/utils/getStartMonth.ts +0 -19
- package/src/components/Checkbox/Checkbox.module.scss +0 -106
- package/src/components/Checkbox/index.props.ts +0 -18
- package/src/components/Checkbox/index.stories.tsx +0 -76
- package/src/components/Checkbox/index.tsx +0 -61
- package/src/components/Chip/Chip.module.scss +0 -93
- package/src/components/Chip/index.props.ts +0 -10
- package/src/components/Chip/index.stories.tsx +0 -97
- package/src/components/Chip/index.tsx +0 -52
- package/src/components/ClickOutside/index.tsx +0 -36
- package/src/components/Counter/index.props.ts +0 -9
- package/src/components/Counter/index.stories.tsx +0 -40
- package/src/components/Counter/index.tsx +0 -67
- package/src/components/Datepicker/components/DatePicker/index.props.ts +0 -5
- package/src/components/Datepicker/components/DatePicker/index.tsx +0 -75
- package/src/components/Datepicker/components/TimePicker/Label/index.tsx +0 -20
- package/src/components/Datepicker/components/TimePicker/helpers.ts +0 -42
- package/src/components/Datepicker/components/TimePicker/index.props.ts +0 -8
- package/src/components/Datepicker/components/TimePicker/index.tsx +0 -60
- package/src/components/Datepicker/index.props.ts +0 -7
- package/src/components/Datepicker/index.stories.tsx +0 -29
- package/src/components/Datepicker/index.tsx +0 -23
- package/src/components/DotsLoader/index.stories.tsx +0 -26
- package/src/components/DotsLoader/index.tsx +0 -29
- package/src/components/Dropdown/__tests__/Dropdown.test.tsx +0 -75
- package/src/components/Dropdown/index.props.ts +0 -27
- package/src/components/Dropdown/index.stories.tsx +0 -40
- package/src/components/Dropdown/index.tsx +0 -210
- package/src/components/Grid/Item/index.tsx +0 -21
- package/src/components/Grid/index.props.ts +0 -6
- package/src/components/Grid/index.stories.tsx +0 -56
- package/src/components/Grid/index.tsx +0 -26
- package/src/components/Icons/ArrowNext.tsx +0 -27
- package/src/components/Icons/Cart.tsx +0 -23
- package/src/components/Icons/Check.tsx +0 -32
- package/src/components/Icons/Chevron.tsx +0 -27
- package/src/components/Icons/Close.tsx +0 -21
- package/src/components/Icons/CrossFill.tsx +0 -22
- package/src/components/Icons/Edit.tsx +0 -25
- package/src/components/Icons/Exit.tsx +0 -26
- package/src/components/Icons/EyeClosed.tsx +0 -22
- package/src/components/Icons/EyeOpen.tsx +0 -30
- package/src/components/Icons/Help.tsx +0 -20
- package/src/components/Icons/Info.tsx +0 -25
- package/src/components/Icons/Minus.tsx +0 -26
- package/src/components/Icons/More.tsx +0 -24
- package/src/components/Icons/Plus.tsx +0 -25
- package/src/components/Icons/Setting.tsx +0 -28
- package/src/components/Icons/Trash.tsx +0 -27
- package/src/components/Icons/User.tsx +0 -33
- package/src/components/Icons/index.stories.tsx +0 -71
- package/src/components/Image/Image.module.scss +0 -16
- package/src/components/Image/index.props.ts +0 -14
- package/src/components/Image/index.stories.tsx +0 -23
- package/src/components/Image/index.tsx +0 -67
- package/src/components/Input/index.props.ts +0 -25
- package/src/components/Input/index.stories.tsx +0 -70
- package/src/components/Input/index.tsx +0 -49
- package/src/components/InputRadio/InputRadio.module.scss +0 -117
- package/src/components/InputRadio/index.tsx +0 -108
- package/src/components/Menu/__tests__/Menu.test.tsx +0 -46
- package/src/components/Menu/components/MenuItem/MenuItem.module.scss +0 -44
- package/src/components/Menu/components/MenuItem/index.props.ts +0 -11
- package/src/components/Menu/components/MenuItem/index.tsx +0 -41
- package/src/components/Menu/index.props.ts +0 -13
- package/src/components/Menu/index.stories.tsx +0 -36
- package/src/components/Menu/index.tsx +0 -49
- package/src/components/Modal/components/Close/index.tsx +0 -12
- package/src/components/Modal/components/Content/index.tsx +0 -10
- package/src/components/Modal/components/Title/index.tsx +0 -15
- package/src/components/Modal/index.props.ts +0 -5
- package/src/components/Modal/index.stories.tsx +0 -32
- package/src/components/Modal/index.tsx +0 -76
- package/src/components/MultiSelect/components/MenuOverlay/index.tsx +0 -120
- package/src/components/MultiSelect/components/MenuOverlayItem/index.tsx +0 -28
- package/src/components/MultiSelect/index.props.ts +0 -37
- package/src/components/MultiSelect/index.stories.tsx +0 -62
- package/src/components/MultiSelect/index.tsx +0 -171
- package/src/components/MultiSelect/utils/index.ts +0 -6
- package/src/components/Portal/index.tsx +0 -18
- package/src/components/RadioGroup/Radio.tsx +0 -56
- package/src/components/RadioGroup/RadioGroup.module.scss +0 -37
- package/src/components/RadioGroup/RadioGroup.stories.tsx +0 -101
- package/src/components/RadioGroup/index.tsx +0 -92
- package/src/components/Select/__tests__/Select.test.tsx +0 -37
- package/src/components/Select/components/MenuOverlay/index.tsx +0 -66
- package/src/components/Select/components/MenuOverlayItem/index.tsx +0 -53
- package/src/components/Select/index.props.ts +0 -32
- package/src/components/Select/index.stories.tsx +0 -52
- package/src/components/Select/index.tsx +0 -106
- package/src/components/Separator/Separator.stories.tsx +0 -12
- package/src/components/Separator/index.tsx +0 -14
- package/src/components/Skeleton/Skeleton.module.scss +0 -39
- package/src/components/Skeleton/index.props.ts +0 -12
- package/src/components/Skeleton/index.stories.tsx +0 -45
- package/src/components/Skeleton/index.tsx +0 -24
- package/src/components/Status/index.module.scss +0 -54
- package/src/components/Status/index.props.ts +0 -14
- package/src/components/Status/index.stories.tsx +0 -42
- package/src/components/Status/index.tsx +0 -22
- package/src/components/Switch/index.props.ts +0 -8
- package/src/components/Switch/index.stories.tsx +0 -27
- package/src/components/Switch/index.tsx +0 -40
- package/src/components/TabsMenu/Tab/Tab.module.scss +0 -78
- package/src/components/TabsMenu/Tab/Tab.props.ts +0 -20
- package/src/components/TabsMenu/Tab/Tab.tsx +0 -40
- package/src/components/TabsMenu/index.props.ts +0 -13
- package/src/components/TabsMenu/index.stories.tsx +0 -40
- package/src/components/TabsMenu/index.tsx +0 -110
- package/src/components/TabsPanes/Pane/Pane.tsx +0 -14
- package/src/components/TabsPanes/Pane/index.props.ts +0 -8
- package/src/components/TabsPanes/__tests__/TabsPanes.test.tsx +0 -39
- package/src/components/TabsPanes/__tests__/__snapshots__/TabsPanes.test.tsx.snap +0 -189
- package/src/components/TabsPanes/index.stories.tsx +0 -29
- package/src/components/TabsPanes/index.tsx +0 -37
- package/src/components/TextArea/index.props.ts +0 -23
- package/src/components/TextArea/index.stories.tsx +0 -33
- package/src/components/TextArea/index.tsx +0 -56
- package/src/components/Theme/breakpoints.ts +0 -52
- package/src/components/Theme/colors/common.ts +0 -31
- package/src/components/Theme/colors/index.ts +0 -9
- package/src/components/Theme/global.scss +0 -59
- package/src/components/Theme/index.stories.tsx +0 -70
- package/src/components/Theme/index.tsx +0 -7
- package/src/components/TimeSelect/Label/index.tsx +0 -20
- package/src/components/TimeSelect/helpers.ts +0 -37
- package/src/components/TimeSelect/index.props.ts +0 -4
- package/src/components/TimeSelect/index.stories.tsx +0 -64
- package/src/components/TimeSelect/index.tsx +0 -66
- package/src/components/Tooltip/Tooltip.module.scss +0 -148
- package/src/components/Tooltip/__tests__/Tooltip.test.tsx +0 -55
- package/src/components/Tooltip/index.props.ts +0 -27
- package/src/components/Tooltip/index.stories.tsx +0 -50
- package/src/components/Tooltip/index.tsx +0 -151
- package/src/components/Typography/Typography.module.scss +0 -83
- package/src/components/Typography/index.props.ts +0 -37
- package/src/components/Typography/index.stories.tsx +0 -70
- package/src/components/Typography/index.tsx +0 -35
- package/src/components/base/BaseInput/index.props.ts +0 -7
- package/src/components/base/BaseInput/index.tsx +0 -21
- package/src/components/base/FormField/FormField.module.scss +0 -12
- package/src/components/base/FormField/index.props.ts +0 -11
- package/src/components/base/FormField/index.tsx +0 -36
- package/src/components/base/InputRoot/InputRoot.module.scss +0 -93
- package/src/components/base/InputRoot/index.props.ts +0 -18
- package/src/components/base/InputRoot/index.tsx +0 -39
- package/src/components/helpers/__tests__/generateUniqID.test.ts +0 -7
- package/src/components/helpers/date/index.ts +0 -76
- package/src/components/helpers/generateUniqID.ts +0 -6
- package/src/components/helpers/on.ts +0 -13
- package/src/components/hooks/useMediaSizes/index.ts +0 -50
- package/src/components/hooks/useOnClickOutside/index.ts +0 -39
- package/src/components/hooks/useScrollLock/index.ts +0 -26
- package/src/components/hooks/useTrapFocus/index.ts +0 -49
- package/src/components/lib/keyboard.ts +0 -46
- package/src/components/libs/numbers/__tests__/leadingZeros.test.ts +0 -10
- package/tsconfig.json +0 -49
- /package/{src/components/Icons/index.tsx → Icons/index.d.ts} +0 -0
- /package/{src/components/index.ts → esm/index.d.ts} +0 -0
|
@@ -1,207 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* For a detailed explanation regarding each configuration property, visit:
|
|
3
|
-
* https://jestjs.io/docs/configuration
|
|
4
|
-
*/
|
|
5
|
-
|
|
6
|
-
import { resolve } from "path";
|
|
7
|
-
import type { Config } from "jest";
|
|
8
|
-
|
|
9
|
-
const config: Config = {
|
|
10
|
-
rootDir: resolve(__dirname, "../.."),
|
|
11
|
-
// All imported modules in your tests should be mocked automatically
|
|
12
|
-
// automock: false,
|
|
13
|
-
|
|
14
|
-
// Stop running tests after `n` failures
|
|
15
|
-
// bail: 0,
|
|
16
|
-
|
|
17
|
-
// The directory where Jest should store its cached dependency information
|
|
18
|
-
// cacheDirectory: "/tmp/jest_rs",
|
|
19
|
-
|
|
20
|
-
// Automatically clear mock calls, instances, contexts and results before every test
|
|
21
|
-
clearMocks: true,
|
|
22
|
-
|
|
23
|
-
// Indicates whether the coverage information should be collected while executing the test
|
|
24
|
-
collectCoverage: true,
|
|
25
|
-
|
|
26
|
-
// An array of glob patterns indicating a set of files for which coverage information should be collected
|
|
27
|
-
// collectCoverageFrom: undefined,
|
|
28
|
-
|
|
29
|
-
// The directory where Jest should output its coverage files
|
|
30
|
-
coverageDirectory: ".coverage",
|
|
31
|
-
|
|
32
|
-
// An array of regexp pattern strings used to skip coverage collection
|
|
33
|
-
// coveragePathIgnorePatterns: [
|
|
34
|
-
// "/node_modules/"
|
|
35
|
-
// ],
|
|
36
|
-
|
|
37
|
-
// Indicates which provider should be used to instrument code for coverage
|
|
38
|
-
// coverageProvider: "babel",
|
|
39
|
-
|
|
40
|
-
// A list of reporter names that Jest uses when writing coverage reports
|
|
41
|
-
// coverageReporters: [
|
|
42
|
-
// "json",
|
|
43
|
-
// "text",
|
|
44
|
-
// "lcov",
|
|
45
|
-
// "clover"
|
|
46
|
-
// ],
|
|
47
|
-
|
|
48
|
-
// An object that configures minimum threshold enforcement for coverage results
|
|
49
|
-
// coverageThreshold: undefined,
|
|
50
|
-
|
|
51
|
-
// A path to a custom dependency extractor
|
|
52
|
-
// dependencyExtractor: undefined,
|
|
53
|
-
|
|
54
|
-
// Make calling deprecated APIs throw helpful error messages
|
|
55
|
-
// errorOnDeprecated: false,
|
|
56
|
-
|
|
57
|
-
// The default configuration for fake timers
|
|
58
|
-
// fakeTimers: {
|
|
59
|
-
// "enableGlobally": false
|
|
60
|
-
// },
|
|
61
|
-
|
|
62
|
-
// Force coverage collection from ignored files using an array of glob patterns
|
|
63
|
-
// forceCoverageMatch: [],
|
|
64
|
-
|
|
65
|
-
// A path to a module which exports an async function that is triggered once before all test suites
|
|
66
|
-
// globalSetup: undefined,
|
|
67
|
-
|
|
68
|
-
// A path to a module which exports an async function that is triggered once after all test suites
|
|
69
|
-
// globalTeardown: undefined,
|
|
70
|
-
|
|
71
|
-
// A set of global variables that need to be available in all test environments
|
|
72
|
-
// globals: {},
|
|
73
|
-
|
|
74
|
-
// The maximum amount of workers used to run your tests. Can be specified as % or a number. E.g. maxWorkers: 10% will use 10% of your CPU amount + 1 as the maximum worker number. maxWorkers: 2 will use a maximum of 2 workers.
|
|
75
|
-
// maxWorkers: "50%",
|
|
76
|
-
|
|
77
|
-
// An array of directory names to be searched recursively up from the requiring module's location
|
|
78
|
-
// moduleDirectories: [
|
|
79
|
-
// "node_modules"
|
|
80
|
-
// ],
|
|
81
|
-
|
|
82
|
-
// An array of file extensions your modules use
|
|
83
|
-
// moduleFileExtensions: [
|
|
84
|
-
// "js",
|
|
85
|
-
// "mjs",
|
|
86
|
-
// "cjs",
|
|
87
|
-
// "jsx",
|
|
88
|
-
// "ts",
|
|
89
|
-
// "tsx",
|
|
90
|
-
// "json",
|
|
91
|
-
// "node"
|
|
92
|
-
// ],
|
|
93
|
-
|
|
94
|
-
// A map from regular expressions to module names or to arrays of module names that allow to stub out resources with a single module
|
|
95
|
-
moduleNameMapper: {
|
|
96
|
-
"^.+\\.module\\.(css|sass|scss)$": "identity-obj-proxy",
|
|
97
|
-
"^.+\\.(css|sass|scss)$": "<rootDir>/.config/jest/__mocks__/noop.js",
|
|
98
|
-
"^.+\\.(png|jpg|jpeg|gif|webp|avif|ico|bmp|svg)$": `<rootDir>/.config/jest/__mocks__/noop.js`,
|
|
99
|
-
},
|
|
100
|
-
|
|
101
|
-
// An array of regexp pattern strings, matched against all module paths before considered 'visible' to the module loader
|
|
102
|
-
// modulePathIgnorePatterns: [],
|
|
103
|
-
|
|
104
|
-
// Activates notifications for test results
|
|
105
|
-
// notify: false,
|
|
106
|
-
|
|
107
|
-
// An enum that specifies notification mode. Requires { notify: true }
|
|
108
|
-
// notifyMode: "failure-change",
|
|
109
|
-
|
|
110
|
-
// A preset that is used as a base for Jest's configuration
|
|
111
|
-
// preset: undefined,
|
|
112
|
-
|
|
113
|
-
// Run tests from one or more projects
|
|
114
|
-
// projects: undefined,
|
|
115
|
-
|
|
116
|
-
// Use this configuration option to add custom reporters to Jest
|
|
117
|
-
// reporters: undefined,
|
|
118
|
-
|
|
119
|
-
// Automatically reset mock state before every test
|
|
120
|
-
// resetMocks: false,
|
|
121
|
-
|
|
122
|
-
// Reset the module registry before running each individual test
|
|
123
|
-
// resetModules: false,
|
|
124
|
-
|
|
125
|
-
// A path to a custom resolver
|
|
126
|
-
// resolver: undefined,
|
|
127
|
-
|
|
128
|
-
// Automatically restore mock state and implementation before every test
|
|
129
|
-
// restoreMocks: false,
|
|
130
|
-
|
|
131
|
-
// The root directory that Jest should scan for tests and modules within
|
|
132
|
-
// rootDir: undefined,
|
|
133
|
-
|
|
134
|
-
// A list of paths to directories that Jest should use to search for files in
|
|
135
|
-
// roots: [
|
|
136
|
-
// "<rootDir>"
|
|
137
|
-
// ],
|
|
138
|
-
|
|
139
|
-
// Allows you to use a custom runner instead of Jest's default test runner
|
|
140
|
-
// runner: "jest-runner",
|
|
141
|
-
|
|
142
|
-
// The paths to modules that run some code to configure or set up the testing environment before each test
|
|
143
|
-
// setupFiles: [],
|
|
144
|
-
|
|
145
|
-
// A list of paths to modules that run some code to configure or set up the testing framework before each test
|
|
146
|
-
setupFilesAfterEnv: ["<rootDir>/.config/jest/jest.setup.ts"],
|
|
147
|
-
|
|
148
|
-
// The number of seconds after which a test is considered as slow and reported as such in the results.
|
|
149
|
-
// slowTestThreshold: 5,
|
|
150
|
-
|
|
151
|
-
// A list of paths to snapshot serializer modules Jest should use for snapshot testing
|
|
152
|
-
// snapshotSerializers: [],
|
|
153
|
-
|
|
154
|
-
// The test environment that will be used for testing
|
|
155
|
-
testEnvironment: "jsdom",
|
|
156
|
-
|
|
157
|
-
// Options that will be passed to the testEnvironment
|
|
158
|
-
// testEnvironmentOptions: {},
|
|
159
|
-
|
|
160
|
-
// Adds a location field to test results
|
|
161
|
-
// testLocationInResults: false,
|
|
162
|
-
|
|
163
|
-
// The glob patterns Jest uses to detect test files
|
|
164
|
-
// testMatch: [
|
|
165
|
-
// "**/__tests__/**/*.[jt]s?(x)",
|
|
166
|
-
// "**/?(*.)+(spec|test).[tj]s?(x)"
|
|
167
|
-
// ],
|
|
168
|
-
|
|
169
|
-
// An array of regexp pattern strings that are matched against all test paths, matched tests are skipped
|
|
170
|
-
testPathIgnorePatterns: ["<rootDir>/node_modules/"],
|
|
171
|
-
|
|
172
|
-
// The regexp pattern or array of patterns that Jest uses to detect test files
|
|
173
|
-
// testRegex: [],
|
|
174
|
-
|
|
175
|
-
// This option allows the use of a custom results processor
|
|
176
|
-
// testResultsProcessor: undefined,
|
|
177
|
-
|
|
178
|
-
// This option allows use of a custom test runner
|
|
179
|
-
// testRunner: "jest-circus/runner",
|
|
180
|
-
|
|
181
|
-
// A map from regular expressions to paths to transformers
|
|
182
|
-
transform: {
|
|
183
|
-
// Use babel-jest to transpile tests with the next/babel preset
|
|
184
|
-
// https://jestjs.io/docs/configuration#transform-objectstring-pathtotransformer--pathtotransformer-object
|
|
185
|
-
"^.+\\.(js|jsx|ts|tsx)$": "babel-jest",
|
|
186
|
-
},
|
|
187
|
-
|
|
188
|
-
// An array of regexp pattern strings that are matched against all source file paths, matched files will skip transformation
|
|
189
|
-
transformIgnorePatterns: [
|
|
190
|
-
"<rootDir>/node_modules/",
|
|
191
|
-
"^.+\\.module\\.(css|sass|scss)$",
|
|
192
|
-
],
|
|
193
|
-
|
|
194
|
-
// An array of regexp pattern strings that are matched against all modules before the module loader will automatically return a mock for them
|
|
195
|
-
// unmockedModulePathPatterns: undefined,
|
|
196
|
-
|
|
197
|
-
// Indicates whether each individual test should be reported during the run
|
|
198
|
-
// verbose: undefined,
|
|
199
|
-
|
|
200
|
-
// An array of regexp patterns that are matched against all source file paths before re-running tests in watch mode
|
|
201
|
-
// watchPathIgnorePatterns: [],
|
|
202
|
-
|
|
203
|
-
// Whether to use watchman for file crawling
|
|
204
|
-
// watchman: true,
|
|
205
|
-
};
|
|
206
|
-
|
|
207
|
-
export default config;
|
package/.prettierignore
DELETED
package/.prettierrc
DELETED
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
import { addons, makeDecorator } from "@storybook/preview-api";
|
|
2
|
-
|
|
3
|
-
import { THEMES } from "../../src/components/Theme";
|
|
4
|
-
import { events, THEME_COOKIE } from "./constants";
|
|
5
|
-
|
|
6
|
-
const getThemeByName = (name) => {
|
|
7
|
-
switch (name) {
|
|
8
|
-
case "BA":
|
|
9
|
-
return THEMES.BA;
|
|
10
|
-
case "DEFAULT":
|
|
11
|
-
return THEMES.DEFAULT;
|
|
12
|
-
default:
|
|
13
|
-
return THEMES.DEFAULT;
|
|
14
|
-
}
|
|
15
|
-
};
|
|
16
|
-
|
|
17
|
-
export const withThemesDecorator = makeDecorator({
|
|
18
|
-
name: "withThemes",
|
|
19
|
-
parameterName: "theme",
|
|
20
|
-
skipIfNoParametersOrOptions: false,
|
|
21
|
-
wrapper: (getStory, context) => {
|
|
22
|
-
const channel = addons.getChannel();
|
|
23
|
-
|
|
24
|
-
channel.on(events.CHANGE, ({ name }) => {
|
|
25
|
-
const theme = getThemeByName(name);
|
|
26
|
-
|
|
27
|
-
// set CSS variables
|
|
28
|
-
Object.entries(theme).forEach(([key, value]) => {
|
|
29
|
-
document.documentElement.style.setProperty(`--${key}`, value);
|
|
30
|
-
});
|
|
31
|
-
|
|
32
|
-
document.cookie = `${THEME_COOKIE}=${name || "DEFAULT"}`;
|
|
33
|
-
});
|
|
34
|
-
|
|
35
|
-
const name = new Map(
|
|
36
|
-
document.cookie.split("; ").map((keyValue) => keyValue.split("=")),
|
|
37
|
-
).get(THEME_COOKIE);
|
|
38
|
-
|
|
39
|
-
channel.emit(events.CHANGE, { name });
|
|
40
|
-
|
|
41
|
-
return getStory(context);
|
|
42
|
-
},
|
|
43
|
-
});
|
|
44
|
-
|
|
45
|
-
export default withThemesDecorator;
|
|
@@ -1,79 +0,0 @@
|
|
|
1
|
-
import React, { useState, useCallback, useEffect } from "react";
|
|
2
|
-
import { addons, types, useParameter } from "@storybook/manager-api";
|
|
3
|
-
import {
|
|
4
|
-
IconButton,
|
|
5
|
-
TooltipLinkList,
|
|
6
|
-
WithTooltip,
|
|
7
|
-
} from "@storybook/components";
|
|
8
|
-
import { PhotoIcon } from "@storybook/icons";
|
|
9
|
-
|
|
10
|
-
import { ADDON_ID, PARAM_KEY, events } from "./constants";
|
|
11
|
-
|
|
12
|
-
interface ColoredIconProps {
|
|
13
|
-
background: string;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
const ColoredIcon = ({ background }: ColoredIconProps): JSX.Element => (
|
|
17
|
-
<div
|
|
18
|
-
style={{
|
|
19
|
-
background,
|
|
20
|
-
borderRadius: "1rem",
|
|
21
|
-
display: "block",
|
|
22
|
-
height: "1rem",
|
|
23
|
-
width: "1rem",
|
|
24
|
-
}}
|
|
25
|
-
/>
|
|
26
|
-
);
|
|
27
|
-
|
|
28
|
-
const ThemeSelect = ({ channel }): JSX.Element => {
|
|
29
|
-
const [activeTheme, setActiveTheme] = useState();
|
|
30
|
-
|
|
31
|
-
const handleSelect = useCallback(
|
|
32
|
-
(name) => {
|
|
33
|
-
channel.emit(events.CHANGE, { name });
|
|
34
|
-
window.location.reload();
|
|
35
|
-
},
|
|
36
|
-
[activeTheme],
|
|
37
|
-
);
|
|
38
|
-
|
|
39
|
-
useEffect(() => {
|
|
40
|
-
const handleChange = ({ name }) => setActiveTheme(name);
|
|
41
|
-
channel.on(events.CHANGE, handleChange);
|
|
42
|
-
|
|
43
|
-
return () => {
|
|
44
|
-
channel.off(events.CHANGE, handleChange);
|
|
45
|
-
};
|
|
46
|
-
}, []);
|
|
47
|
-
|
|
48
|
-
const themes = useParameter(PARAM_KEY) || [];
|
|
49
|
-
const links = themes.map(({ name, color }) => ({
|
|
50
|
-
active: activeTheme === name,
|
|
51
|
-
id: name,
|
|
52
|
-
onClick: () => handleSelect(name),
|
|
53
|
-
right: color ? <ColoredIcon background={color} /> : undefined,
|
|
54
|
-
title: name,
|
|
55
|
-
value: name,
|
|
56
|
-
}));
|
|
57
|
-
|
|
58
|
-
return (
|
|
59
|
-
<WithTooltip
|
|
60
|
-
placement="top"
|
|
61
|
-
tooltip={<TooltipLinkList links={links} />}
|
|
62
|
-
trigger="click"
|
|
63
|
-
>
|
|
64
|
-
<IconButton key="theme" active={true} title="">
|
|
65
|
-
<PhotoIcon />
|
|
66
|
-
</IconButton>
|
|
67
|
-
</WithTooltip>
|
|
68
|
-
);
|
|
69
|
-
};
|
|
70
|
-
|
|
71
|
-
addons.register(ADDON_ID, () => {
|
|
72
|
-
const channel = addons.getChannel();
|
|
73
|
-
|
|
74
|
-
addons.add(ADDON_ID, {
|
|
75
|
-
title: "Themes",
|
|
76
|
-
type: types.TOOL,
|
|
77
|
-
render: () => <ThemeSelect channel={channel} />,
|
|
78
|
-
});
|
|
79
|
-
});
|
package/.storybook/main.ts
DELETED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import type { StorybookConfig } from "@storybook/react-webpack5";
|
|
2
|
-
const config: StorybookConfig = {
|
|
3
|
-
stories: ["../src/**/*.stories.@(ts|tsx)"],
|
|
4
|
-
addons: [
|
|
5
|
-
"@storybook/addon-webpack5-compiler-swc",
|
|
6
|
-
"@storybook/addon-links",
|
|
7
|
-
"@storybook/addon-essentials",
|
|
8
|
-
"@storybook/addon-interactions",
|
|
9
|
-
"storybook-addon-sass-postcss",
|
|
10
|
-
"storybook-css-modules",
|
|
11
|
-
],
|
|
12
|
-
framework: {
|
|
13
|
-
name: "@storybook/react-webpack5",
|
|
14
|
-
options: {},
|
|
15
|
-
},
|
|
16
|
-
staticDirs: ["../static"],
|
|
17
|
-
};
|
|
18
|
-
export default config;
|
package/.storybook/manager.tsx
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import "./AddonThemesSwitcher/register";
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
2
|
-
<link rel="preconnect" href="https://fonts.googleapis.com">
|
|
3
|
-
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
|
4
|
-
<link
|
|
5
|
-
href="https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap"
|
|
6
|
-
rel="stylesheet">
|
|
7
|
-
<style>
|
|
8
|
-
*,
|
|
9
|
-
*::before,
|
|
10
|
-
*::after {
|
|
11
|
-
box-sizing: inherit;
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
body {
|
|
15
|
-
font-family: "Roboto", Arial, sans-serif;
|
|
16
|
-
font-weight: 400;
|
|
17
|
-
font-style: normal;
|
|
18
|
-
}
|
|
19
|
-
</style>
|
package/.storybook/preview.tsx
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import withTheme from "./AddonThemesSwitcher";
|
|
2
|
-
import type { Preview } from "@storybook/react";
|
|
3
|
-
|
|
4
|
-
const preview: Preview = {
|
|
5
|
-
parameters: {
|
|
6
|
-
themes: [
|
|
7
|
-
{ name: "BA", color: "#ffdc82" },
|
|
8
|
-
{ name: "DEFAULT", color: "#ccc", default: true },
|
|
9
|
-
],
|
|
10
|
-
},
|
|
11
|
-
decorators: [withTheme],
|
|
12
|
-
};
|
|
13
|
-
|
|
14
|
-
export default preview;
|
package/.stylelintrc.json
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"extends": "stylelint-config-standard",
|
|
3
|
-
"plugins": [
|
|
4
|
-
"stylelint-scss",
|
|
5
|
-
"stylelint-order",
|
|
6
|
-
"stylelint-prettier"
|
|
7
|
-
],
|
|
8
|
-
"rules": {
|
|
9
|
-
"order/properties-alphabetical-order": true,
|
|
10
|
-
"at-rule-no-unknown": null,
|
|
11
|
-
"scss/at-rule-no-unknown": true,
|
|
12
|
-
"block-no-empty": true,
|
|
13
|
-
"color-no-invalid-hex": true,
|
|
14
|
-
"prettier/prettier": true,
|
|
15
|
-
"selector-class-pattern": "^[a-z0-9_-]+$"
|
|
16
|
-
}
|
|
17
|
-
}
|
package/@types/image.d.ts
DELETED
package/@types/typings.d.ts
DELETED
package/eslint.config.mjs
DELETED
|
@@ -1,83 +0,0 @@
|
|
|
1
|
-
import globals from "globals";
|
|
2
|
-
import pluginJs from "@eslint/js";
|
|
3
|
-
import tseslint from "typescript-eslint";
|
|
4
|
-
import pluginReactConfig from "eslint-plugin-react/configs/recommended.js";
|
|
5
|
-
import eslintPluginPrettierRecommended from "eslint-plugin-prettier/recommended";
|
|
6
|
-
import eslintPluginImportOrder from "eslint-plugin-import";
|
|
7
|
-
import eslintPluginReactHooks from "eslint-plugin-react-hooks";
|
|
8
|
-
import eslintPluginJSXA11Y from "eslint-plugin-jsx-a11y";
|
|
9
|
-
|
|
10
|
-
export default [
|
|
11
|
-
{ languageOptions: { globals: globals.browser } },
|
|
12
|
-
pluginJs.configs.recommended,
|
|
13
|
-
...tseslint.configs.recommended,
|
|
14
|
-
pluginReactConfig,
|
|
15
|
-
eslintPluginPrettierRecommended,
|
|
16
|
-
{
|
|
17
|
-
plugins: {
|
|
18
|
-
import: eslintPluginImportOrder,
|
|
19
|
-
"react-hooks": eslintPluginReactHooks,
|
|
20
|
-
"jsx-a11y": eslintPluginJSXA11Y,
|
|
21
|
-
},
|
|
22
|
-
rules: {
|
|
23
|
-
"@typescript-eslint/consistent-type-imports": "error",
|
|
24
|
-
"react/display-name": "off",
|
|
25
|
-
"react/prop-types": "off",
|
|
26
|
-
"react/react-in-jsx-scope": "off",
|
|
27
|
-
"import/order": [
|
|
28
|
-
"error",
|
|
29
|
-
{
|
|
30
|
-
groups: [
|
|
31
|
-
["builtin", "external"],
|
|
32
|
-
"internal",
|
|
33
|
-
"parent",
|
|
34
|
-
"sibling",
|
|
35
|
-
"index",
|
|
36
|
-
"object",
|
|
37
|
-
"type",
|
|
38
|
-
],
|
|
39
|
-
},
|
|
40
|
-
],
|
|
41
|
-
"max-len": [
|
|
42
|
-
"error",
|
|
43
|
-
{
|
|
44
|
-
code: 100,
|
|
45
|
-
comments: 130,
|
|
46
|
-
ignoreUrls: true,
|
|
47
|
-
ignoreStrings: true,
|
|
48
|
-
ignoreTemplateLiterals: true,
|
|
49
|
-
ignoreRegExpLiterals: true,
|
|
50
|
-
ignoreTrailingComments: true,
|
|
51
|
-
},
|
|
52
|
-
],
|
|
53
|
-
"import/no-extraneous-dependencies": "error",
|
|
54
|
-
"react-hooks/exhaustive-deps": "error",
|
|
55
|
-
"@typescript-eslint/ban-ts-comment": "error",
|
|
56
|
-
"@typescript-eslint/no-use-before-define": "error",
|
|
57
|
-
"@typescript-eslint/no-explicit-any": "error",
|
|
58
|
-
"@typescript-eslint/no-shadow": "error",
|
|
59
|
-
"react-hooks/rules-of-hooks": "error",
|
|
60
|
-
"react/no-unused-prop-types": "error",
|
|
61
|
-
"jsx-a11y/no-static-element-interactions": "error",
|
|
62
|
-
"jsx-a11y/click-events-have-key-events": "error",
|
|
63
|
-
"arrow-body-style": ["error", "as-needed"],
|
|
64
|
-
"jsx-a11y/label-has-associated-control": "error",
|
|
65
|
-
"no-console": "error",
|
|
66
|
-
},
|
|
67
|
-
},
|
|
68
|
-
{
|
|
69
|
-
ignores: [
|
|
70
|
-
".git/*",
|
|
71
|
-
"dist/*",
|
|
72
|
-
".storybook",
|
|
73
|
-
"scripts/*",
|
|
74
|
-
"node_modules/*",
|
|
75
|
-
"storybook-static/*",
|
|
76
|
-
"**/*.stories.tsx",
|
|
77
|
-
"src/**/*.test.ts",
|
|
78
|
-
"src/**/*.test.tsx",
|
|
79
|
-
".config",
|
|
80
|
-
"rollup.config.js",
|
|
81
|
-
],
|
|
82
|
-
},
|
|
83
|
-
];
|
package/rollup.config.js
DELETED
|
@@ -1,81 +0,0 @@
|
|
|
1
|
-
import typescript from "@rollup/plugin-typescript";
|
|
2
|
-
import babel from "@rollup/plugin-babel";
|
|
3
|
-
import url from "@rollup/plugin-url";
|
|
4
|
-
import { nodeResolve } from "@rollup/plugin-node-resolve";
|
|
5
|
-
import commonjs from "@rollup/plugin-commonjs";
|
|
6
|
-
import svgr from "@svgr/rollup";
|
|
7
|
-
import { DEFAULT_EXTENSIONS } from "@babel/core";
|
|
8
|
-
|
|
9
|
-
const external = (id) =>
|
|
10
|
-
(!id.startsWith(".") && !id.startsWith("/")) || id.endsWith(".scss");
|
|
11
|
-
|
|
12
|
-
const getBabelOptions = ({ value }) => ({
|
|
13
|
-
babelrc: false,
|
|
14
|
-
presets: [
|
|
15
|
-
["@babel/preset-env", { modules: false }],
|
|
16
|
-
"@babel/preset-react",
|
|
17
|
-
"@babel/preset-typescript",
|
|
18
|
-
],
|
|
19
|
-
plugins: [["@babel/transform-runtime", { useESModules: value }]],
|
|
20
|
-
babelHelpers: "runtime",
|
|
21
|
-
exclude: "/node_modules/**",
|
|
22
|
-
extensions: [...DEFAULT_EXTENSIONS, ".ts", ".tsx"],
|
|
23
|
-
});
|
|
24
|
-
|
|
25
|
-
export default [
|
|
26
|
-
{
|
|
27
|
-
input: "./src/components/index.ts",
|
|
28
|
-
output: [
|
|
29
|
-
{
|
|
30
|
-
dir: "dist/esm",
|
|
31
|
-
format: "esm",
|
|
32
|
-
preserveModules: true,
|
|
33
|
-
preserveModulesRoot: "src/components",
|
|
34
|
-
interop: "auto",
|
|
35
|
-
},
|
|
36
|
-
],
|
|
37
|
-
external,
|
|
38
|
-
treeshake: false,
|
|
39
|
-
plugins: [
|
|
40
|
-
url(),
|
|
41
|
-
svgr(),
|
|
42
|
-
nodeResolve({
|
|
43
|
-
preferBuiltins: true,
|
|
44
|
-
extensions: [".ts", ".tsx"],
|
|
45
|
-
}),
|
|
46
|
-
typescript(),
|
|
47
|
-
commonjs({
|
|
48
|
-
include: "node_modules/**",
|
|
49
|
-
}),
|
|
50
|
-
babel(getBabelOptions(true)),
|
|
51
|
-
],
|
|
52
|
-
},
|
|
53
|
-
{
|
|
54
|
-
input: "./src/components/index.ts",
|
|
55
|
-
output: [
|
|
56
|
-
{
|
|
57
|
-
dir: "dist",
|
|
58
|
-
format: "cjs",
|
|
59
|
-
preserveModules: true,
|
|
60
|
-
preserveModulesRoot: "src/components",
|
|
61
|
-
exports: "named",
|
|
62
|
-
interop: "auto",
|
|
63
|
-
},
|
|
64
|
-
],
|
|
65
|
-
external,
|
|
66
|
-
treeshake: false,
|
|
67
|
-
plugins: [
|
|
68
|
-
url(),
|
|
69
|
-
svgr(),
|
|
70
|
-
nodeResolve({
|
|
71
|
-
preferBuiltins: true,
|
|
72
|
-
extensions: [".ts", ".tsx"],
|
|
73
|
-
}),
|
|
74
|
-
typescript({ outDir: "dist", declarationDir: "dist" }),
|
|
75
|
-
commonjs({
|
|
76
|
-
include: "node_modules/**",
|
|
77
|
-
}),
|
|
78
|
-
babel(getBabelOptions(false)),
|
|
79
|
-
],
|
|
80
|
-
},
|
|
81
|
-
];
|
package/scripts/buildSass.js
DELETED
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
const { writeFile, mkdir } = require('fs-extra');
|
|
2
|
-
const { relative, join, dirname } = require("path");
|
|
3
|
-
const fg = require("fast-glob");
|
|
4
|
-
const sass = require('sass')
|
|
5
|
-
|
|
6
|
-
const inputDir = './src';
|
|
7
|
-
const distPaths = ["dist", "dist/esm"];
|
|
8
|
-
|
|
9
|
-
async function compileSass() {
|
|
10
|
-
const files = await fg(`${inputDir}/**/*.scss`);
|
|
11
|
-
files.forEach(async (fileName) => {
|
|
12
|
-
const relativePath = relative(`${inputDir}/components`, fileName);
|
|
13
|
-
const result = sass.compile(fileName);
|
|
14
|
-
|
|
15
|
-
for (const outputDir of distPaths) {
|
|
16
|
-
const outputFilePath = join(outputDir, relativePath.replace(/\.scss$/, '.css'));
|
|
17
|
-
await mkdir(dirname(outputFilePath), { recursive: true });
|
|
18
|
-
await writeFile(outputFilePath, result.css);
|
|
19
|
-
}
|
|
20
|
-
})
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
compileSass().catch(err => console.error(err));
|
package/scripts/copyFiles.js
DELETED
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
const path = require("path");
|
|
2
|
-
const { existsSync, writeFileSync } = require("fs");
|
|
3
|
-
const { execSync } = require("child_process");
|
|
4
|
-
|
|
5
|
-
const existPackageJson = existsSync("package.json");
|
|
6
|
-
const existReadme = existsSync("README.md");
|
|
7
|
-
|
|
8
|
-
if (existPackageJson) {
|
|
9
|
-
try {
|
|
10
|
-
execSync("cp package.json dist", { stdio: "inherit" });
|
|
11
|
-
const packageJsonPath = path.join(
|
|
12
|
-
path.resolve(__dirname, "../dist"),
|
|
13
|
-
"package.json",
|
|
14
|
-
);
|
|
15
|
-
const packageJson = require(packageJsonPath);
|
|
16
|
-
packageJson.scripts = {};
|
|
17
|
-
packageJson.devDependencies = {};
|
|
18
|
-
writeFileSync(packageJsonPath, JSON.stringify(packageJson, null, 2));
|
|
19
|
-
} catch (err) {
|
|
20
|
-
throw new Error(
|
|
21
|
-
`Could not copy package.json file because of an error: ${err}`,
|
|
22
|
-
);
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
if (existReadme) {
|
|
27
|
-
try {
|
|
28
|
-
execSync("cp README.md dist", { stdio: "inherit" });
|
|
29
|
-
} catch (err) {
|
|
30
|
-
throw new Error(`Could not copy .npmrc file because of an error: ${err}`);
|
|
31
|
-
}
|
|
32
|
-
}
|