@indico-data/design-system 3.22.1 → 3.23.0-beta.1
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/lib/assets/fonts/mulish/a.woff2 +0 -0
- package/lib/assets/fonts/mulish/b.woff2 +0 -0
- package/lib/assets/fonts/mulish/c.woff2 +0 -0
- package/lib/assets/fonts/mulish/d.woff2 +0 -0
- package/lib/assets/fonts/mulish/mulish.css +98 -0
- package/lib/build/generated/iconTypes.d.ts +2 -0
- package/lib/components/alert/Alert.d.ts +2 -0
- package/lib/components/alert/Alert.stories.d.ts +15 -0
- package/lib/components/alert/__tests__/Alert.test.d.ts +1 -0
- package/lib/components/alert/index.d.ts +2 -0
- package/lib/components/alert/types.d.ts +26 -0
- package/lib/components/floatUI/FloatUI.test.d.ts +1 -0
- package/lib/components/forms/timePicker/constants.d.ts +13 -0
- package/lib/components/index.d.ts +1 -0
- package/lib/components/pill/Pill.d.ts +1 -1
- package/lib/components/pill/Pill.stories.d.ts +3 -0
- package/lib/components/pill/types.d.ts +4 -0
- package/lib/components/tanstackTable/TanstakTable.d.ts +4 -0
- package/lib/index.css +214 -30
- package/lib/index.d.ts +34 -2
- package/lib/index.esm.css +214 -30
- package/lib/index.esm.js +41 -5
- package/lib/index.esm.js.map +1 -1
- package/lib/index.js +40 -3
- package/lib/index.js.map +1 -1
- package/lib/legacy/components/Accordion/Accordion.d.ts +9 -0
- package/lib/legacy/components/Accordion/Accordion.stories.d.ts +25 -0
- package/lib/legacy/components/Accordion/Accordion.styles.d.ts +1 -0
- package/lib/legacy/components/Accordion/index.d.ts +1 -0
- package/lib/legacy/components/ListTable/Header/Header.d.ts +21 -0
- package/lib/legacy/components/ListTable/Header/Header.styles.d.ts +1 -0
- package/lib/legacy/components/ListTable/Header/index.d.ts +1 -0
- package/lib/legacy/components/ListTable/ListTable.d.ts +41 -0
- package/lib/legacy/components/ListTable/ListTable.stories.d.ts +54 -0
- package/lib/legacy/components/ListTable/ListTable.styles.d.ts +1 -0
- package/lib/legacy/components/ListTable/index.d.ts +1 -0
- package/lib/legacy/components/ListTable/mock-data/index.d.ts +1 -0
- package/lib/legacy/components/ListTable/mock-data/mock-data.d.ts +54 -0
- package/lib/legacy/components/LoadingAwareContainer/LoadingAwareContainer.d.ts +15 -0
- package/lib/legacy/components/LoadingAwareContainer/LoadingAwareContainer.stories.d.ts +22 -0
- package/lib/legacy/components/LoadingAwareContainer/LoadingAwareContainer.styles.d.ts +2 -0
- package/lib/legacy/components/LoadingAwareContainer/index.d.ts +1 -0
- package/lib/legacy/components/Pagination/Pagination.d.ts +18 -0
- package/lib/legacy/components/Pagination/Pagination.stories.d.ts +18 -0
- package/lib/legacy/components/Pagination/Pagination.styles.d.ts +1 -0
- package/lib/legacy/components/Pagination/index.d.ts +1 -0
- package/lib/legacy/components/Toggle/Toggle.d.ts +12 -0
- package/lib/legacy/components/Toggle/Toggle.stories.d.ts +21 -0
- package/lib/legacy/components/Toggle/Toggle.styles.d.ts +1 -0
- package/lib/legacy/components/Toggle/index.d.ts +1 -0
- package/lib/legacy/components/Tooltip/Tooltip.d.ts +15 -0
- package/lib/legacy/components/Tooltip/Tooltip.stories.d.ts +9 -0
- package/lib/legacy/components/Tooltip/Tooltip.styles.d.ts +1 -0
- package/lib/legacy/components/Tooltip/index.d.ts +1 -0
- package/lib/legacy/components/basic-section/Section/Section.d.ts +8 -0
- package/lib/legacy/components/basic-section/Section/Section.stories.d.ts +13 -0
- package/lib/legacy/components/basic-section/Section/Section.styles.d.ts +1 -0
- package/lib/legacy/components/basic-section/Section/index.d.ts +1 -0
- package/lib/legacy/components/basic-section/SectionBlock/SectionBlock.d.ts +9 -0
- package/lib/legacy/components/basic-section/SectionBlock/SectionBlock.styles.d.ts +1 -0
- package/lib/legacy/components/basic-section/SectionBlock/index.d.ts +1 -0
- package/lib/legacy/components/basic-section/SectionBody/SectionBody.d.ts +7 -0
- package/lib/legacy/components/basic-section/SectionBody/SectionBody.stories.d.ts +10 -0
- package/lib/legacy/components/basic-section/SectionBody/SectionBody.styles.d.ts +1 -0
- package/lib/legacy/components/basic-section/SectionBody/index.d.ts +1 -0
- package/lib/legacy/components/basic-section/SectionHeader/SectionHeader.d.ts +8 -0
- package/lib/legacy/components/basic-section/SectionHeader/SectionHeader.stories.d.ts +14 -0
- package/lib/legacy/components/basic-section/SectionHeader/SectionHeader.styles.d.ts +1 -0
- package/lib/legacy/components/basic-section/SectionHeader/index.d.ts +1 -0
- package/lib/legacy/components/basic-section/SectionTable/SectionTable.d.ts +1 -0
- package/lib/legacy/components/basic-section/SectionTable/SectionTable.styles.d.ts +1 -0
- package/lib/legacy/components/basic-section/SectionTable/index.d.ts +1 -0
- package/lib/legacy/components/basic-section/index.d.ts +5 -0
- package/lib/legacy/components/buttons/Button/Button.d.ts +21 -0
- package/lib/legacy/components/buttons/Button/Button.stories.d.ts +25 -0
- package/lib/legacy/components/buttons/Button/Button.styles.d.ts +1 -0
- package/lib/legacy/components/buttons/Button/index.d.ts +1 -0
- package/lib/legacy/components/buttons/IconButton/IconButton.d.ts +32 -0
- package/lib/legacy/components/buttons/IconButton/IconButton.stories.d.ts +43 -0
- package/lib/legacy/components/buttons/IconButton/IconButton.styles.d.ts +5 -0
- package/lib/legacy/components/buttons/IconButton/index.d.ts +1 -0
- package/lib/legacy/components/buttons/commonStyles.d.ts +9 -0
- package/lib/legacy/components/buttons/index.d.ts +2 -0
- package/lib/legacy/components/buttons/types.d.ts +3 -0
- package/lib/legacy/components/dropdowns/BorderSelect/BorderSelect.d.ts +19 -0
- package/lib/legacy/components/dropdowns/BorderSelect/BorderSelect.stories.d.ts +31 -0
- package/lib/legacy/components/dropdowns/BorderSelect/BorderSelect.styles.d.ts +2 -0
- package/lib/legacy/components/dropdowns/BorderSelect/index.d.ts +1 -0
- package/lib/legacy/components/dropdowns/MultiCombobox/MultiCombobox.d.ts +23 -0
- package/lib/legacy/components/dropdowns/MultiCombobox/MultiCombobox.stories.d.ts +46 -0
- package/lib/legacy/components/dropdowns/MultiCombobox/MultiCombobox.styles.d.ts +4 -0
- package/lib/legacy/components/dropdowns/MultiCombobox/index.d.ts +1 -0
- package/lib/legacy/components/dropdowns/Select/Select.d.ts +19 -0
- package/lib/legacy/components/dropdowns/Select/Select.stories.d.ts +34 -0
- package/lib/legacy/components/dropdowns/Select/Select.styles.d.ts +1 -0
- package/lib/legacy/components/dropdowns/Select/index.d.ts +1 -0
- package/lib/legacy/components/dropdowns/SingleCombobox/SingleCombobox.d.ts +20 -0
- package/lib/legacy/components/dropdowns/SingleCombobox/SingleCombobox.stories.d.ts +31 -0
- package/lib/legacy/components/dropdowns/SingleCombobox/SingleCombobox.styles.d.ts +4 -0
- package/lib/legacy/components/dropdowns/SingleCombobox/index.d.ts +1 -0
- package/lib/legacy/components/dropdowns/commonStyles.d.ts +1 -0
- package/lib/legacy/components/dropdowns/index.d.ts +4 -0
- package/lib/legacy/components/dropdowns/types.d.ts +45 -0
- package/lib/legacy/components/dropdowns/useCombobox.d.ts +25 -0
- package/lib/legacy/components/dropdowns/utils.d.ts +20 -0
- package/lib/legacy/components/index.d.ts +2 -0
- package/lib/legacy/components/inputs/EditableInput/EditableInput.d.ts +13 -0
- package/lib/legacy/components/inputs/EditableInput/EditableInput.stories.d.ts +14 -0
- package/lib/legacy/components/inputs/EditableInput/EditableInput.styles.d.ts +1 -0
- package/lib/legacy/components/inputs/EditableInput/index.d.ts +1 -0
- package/lib/legacy/components/inputs/NumberInput/NumberInput.d.ts +23 -0
- package/lib/legacy/components/inputs/NumberInput/NumberInput.stories.d.ts +28 -0
- package/lib/legacy/components/inputs/NumberInput/NumberInput.styles.d.ts +1 -0
- package/lib/legacy/components/inputs/NumberInput/index.d.ts +1 -0
- package/lib/legacy/components/inputs/RadioButtons/RadioButtons.d.ts +25 -0
- package/lib/legacy/components/inputs/RadioButtons/RadioButtons.stories.d.ts +15 -0
- package/lib/legacy/components/inputs/RadioButtons/RadioButtons.styles.d.ts +13 -0
- package/lib/legacy/components/inputs/RadioButtons/index.d.ts +1 -0
- package/lib/legacy/components/inputs/RadioGroup/RadioGroup.d.ts +27 -0
- package/lib/legacy/components/inputs/RadioGroup/RadioGroup.stories.d.ts +16 -0
- package/lib/legacy/components/inputs/RadioGroup/RadioGroup.styles.d.ts +1 -0
- package/lib/legacy/components/inputs/RadioGroup/index.d.ts +1 -0
- package/lib/legacy/components/inputs/SearchInput/SearchInput.d.ts +17 -0
- package/lib/legacy/components/inputs/SearchInput/SearchInput.stories.d.ts +30 -0
- package/lib/legacy/components/inputs/SearchInput/SearchInput.styles.d.ts +1 -0
- package/lib/legacy/components/inputs/SearchInput/index.d.ts +1 -0
- package/lib/legacy/components/inputs/TextInput/TextInput.d.ts +24 -0
- package/lib/legacy/components/inputs/TextInput/TextInput.stories.d.ts +62 -0
- package/lib/legacy/components/inputs/TextInput/TextInput.styles.d.ts +2 -0
- package/lib/legacy/components/inputs/TextInput/index.d.ts +1 -0
- package/lib/legacy/components/inputs/index.d.ts +6 -0
- package/lib/legacy/components/inputs/inputsCommon.styles.d.ts +4 -0
- package/lib/legacy/components/loading-indicators/BarSpinner/BarSpinner.d.ts +7 -0
- package/lib/legacy/components/loading-indicators/BarSpinner/BarSpinner.stories.d.ts +10 -0
- package/lib/legacy/components/loading-indicators/BarSpinner/BarSpinner.styles.d.ts +1 -0
- package/lib/legacy/components/loading-indicators/BarSpinner/index.d.ts +1 -0
- package/lib/legacy/components/loading-indicators/CirclePulse/CirclePulse.d.ts +10 -0
- package/lib/legacy/components/loading-indicators/CirclePulse/CirclePulse.stories.d.ts +12 -0
- package/lib/legacy/components/loading-indicators/CirclePulse/CirclePulse.styles.d.ts +7 -0
- package/lib/legacy/components/loading-indicators/CirclePulse/index.d.ts +1 -0
- package/lib/legacy/components/loading-indicators/CircleSpinner/CircleSpinner.d.ts +10 -0
- package/lib/legacy/components/loading-indicators/CircleSpinner/CircleSpinner.stories.d.ts +10 -0
- package/lib/legacy/components/loading-indicators/CircleSpinner/index.d.ts +1 -0
- package/lib/legacy/components/loading-indicators/LoadingIndicator/LoadingIndicator.d.ts +10 -0
- package/lib/legacy/components/loading-indicators/LoadingIndicator/LoadingIndicator.stories.d.ts +11 -0
- package/lib/legacy/components/loading-indicators/LoadingIndicator/LoadingIndicator.styles.d.ts +7 -0
- package/lib/legacy/components/loading-indicators/LoadingIndicator/index.d.ts +1 -0
- package/lib/legacy/components/loading-indicators/LoadingList/LoadingList.d.ts +1 -0
- package/lib/legacy/components/loading-indicators/LoadingList/LoadingList.stories.d.ts +10 -0
- package/lib/legacy/components/loading-indicators/LoadingList/LoadingList.styles.d.ts +1 -0
- package/lib/legacy/components/loading-indicators/LoadingList/index.d.ts +1 -0
- package/lib/legacy/components/loading-indicators/PercentageRing/PercentageRing.d.ts +12 -0
- package/lib/legacy/components/loading-indicators/PercentageRing/PercentageRing.stories.d.ts +10 -0
- package/lib/legacy/components/loading-indicators/PercentageRing/PercentageRing.styles.d.ts +1 -0
- package/lib/legacy/components/loading-indicators/PercentageRing/index.d.ts +1 -0
- package/lib/legacy/components/loading-indicators/RandomLoadingMessage/RandomLoadingMessage.d.ts +1 -0
- package/lib/legacy/components/loading-indicators/RandomLoadingMessage/RandomLoadingMessage.stories.d.ts +10 -0
- package/lib/legacy/components/loading-indicators/RandomLoadingMessage/index.d.ts +1 -0
- package/lib/legacy/components/loading-indicators/RandomLoadingMessage/random-messages.d.ts +2 -0
- package/lib/legacy/components/loading-indicators/index.d.ts +3 -0
- package/lib/legacy/components/modals/ConfirmModal/ConfirmModal.d.ts +17 -0
- package/lib/legacy/components/modals/ConfirmModal/ConfirmModal.stories.d.ts +44 -0
- package/lib/legacy/components/modals/ConfirmModal/ConfirmModal.styles.d.ts +1 -0
- package/lib/legacy/components/modals/ConfirmModal/index.d.ts +1 -0
- package/lib/legacy/components/modals/ModalBase/ModalBase.d.ts +26 -0
- package/lib/legacy/components/modals/ModalBase/ModalBase.stories.d.ts +9 -0
- package/lib/legacy/components/modals/ModalBase/ModalBase.styles.d.ts +4 -0
- package/lib/legacy/components/modals/ModalBase/index.d.ts +2 -0
- package/lib/legacy/components/modals/index.d.ts +2 -0
- package/lib/legacy/components/text-truncate/TextTruncate.d.ts +8 -0
- package/lib/legacy/components/text-truncate/TextTruncate.stories.d.ts +6 -0
- package/lib/legacy/components/text-truncate/TextTruncate.styles.d.ts +1 -0
- package/lib/legacy/components/text-truncate/TextTruncate.test.d.ts +1 -0
- package/lib/legacy/components/text-truncate/index.d.ts +1 -0
- package/lib/legacy/components/user-feedback/Shrug/Shrug.d.ts +14 -0
- package/lib/legacy/components/user-feedback/Shrug/Shrug.stories.d.ts +31 -0
- package/lib/legacy/components/user-feedback/Shrug/Shrug.styles.d.ts +1 -0
- package/lib/legacy/components/user-feedback/Shrug/index.d.ts +1 -0
- package/lib/legacy/components/user-feedback/index.d.ts +1 -0
- package/lib/legacy/styles/globals/buttons.d.ts +1 -0
- package/lib/legacy/styles/globals/forms.d.ts +1 -0
- package/lib/legacy/styles/globals/index.d.ts +1 -0
- package/lib/legacy/styles/globals/layout.d.ts +1 -0
- package/lib/legacy/styles/globals/lists.d.ts +1 -0
- package/lib/legacy/styles/globals/margin-padding.d.ts +1 -0
- package/lib/legacy/styles/globals/media.d.ts +1 -0
- package/lib/legacy/styles/globals/tables.d.ts +1 -0
- package/lib/legacy/styles/globals/typography.d.ts +1 -0
- package/lib/legacy/styles/globals/utility-classes.d.ts +1 -0
- package/lib/legacy/styles/index.d.ts +1 -0
- package/lib/legacy/tokens/animation.d.ts +4 -0
- package/lib/legacy/tokens/breakpoints.d.ts +10 -0
- package/lib/legacy/tokens/colors.d.ts +144 -0
- package/lib/legacy/tokens/index.d.ts +8 -0
- package/lib/legacy/tokens/margin.d.ts +4 -0
- package/lib/legacy/tokens/numbers.d.ts +10 -0
- package/lib/legacy/tokens/padding.d.ts +4 -0
- package/lib/legacy/tokens/spacings.d.ts +5 -0
- package/lib/legacy/tokens/typography.d.ts +61 -0
- package/lib/legacy/utils/color.d.ts +21 -0
- package/lib/legacy/utils/index.d.ts +4 -0
- package/lib/legacy/utils/number.d.ts +21 -0
- package/lib/legacy/utils/string.d.ts +12 -0
- package/lib/src/components/button/Button.d.ts +3 -0
- package/lib/src/components/button/Button.stories.d.ts +23 -0
- package/lib/src/components/button/__tests__/Button.test.d.ts +1 -0
- package/lib/src/components/button/enums.d.ts +5 -0
- package/lib/src/components/button/index.d.ts +1 -0
- package/lib/src/components/button/types.d.ts +23 -0
- package/lib/src/components/card/Card.d.ts +10 -0
- package/lib/src/components/card/Card.stories.d.ts +6 -0
- package/lib/src/components/card/__tests__/Card.test.d.ts +1 -0
- package/lib/src/components/card/index.d.ts +1 -0
- package/lib/src/components/floatUI/FloatUI.d.ts +2 -0
- package/lib/src/components/floatUI/FloatUI.stories.d.ts +8 -0
- package/lib/src/components/floatUI/FloatUI.test.d.ts +1 -0
- package/lib/src/components/floatUI/index.d.ts +1 -0
- package/lib/src/components/floatUI/types.d.ts +13 -0
- package/lib/src/components/forms/checkbox/Checkbox.d.ts +13 -0
- package/lib/src/components/forms/checkbox/Checkbox.stories.d.ts +7 -0
- package/lib/src/components/forms/checkbox/__tests__/Checkbox.test.d.ts +1 -0
- package/lib/src/components/forms/checkbox/index.d.ts +1 -0
- package/lib/src/components/forms/form/Form.d.ts +14 -0
- package/lib/src/components/forms/form/Form.stories.d.ts +8 -0
- package/lib/src/components/forms/form/__tests__/Form.test.d.ts +1 -0
- package/lib/src/components/forms/form/index.d.ts +1 -0
- package/lib/src/components/forms/input/Input.d.ts +19 -0
- package/lib/src/components/forms/input/Input.stories.d.ts +12 -0
- package/lib/src/components/forms/input/__tests__/Input.test.d.ts +1 -0
- package/lib/src/components/forms/input/index.d.ts +1 -0
- package/lib/src/components/forms/numberInput/NumberInput.d.ts +12 -0
- package/lib/src/components/forms/numberInput/NumberInput.stories.d.ts +12 -0
- package/lib/src/components/forms/numberInput/__tests__/NumberInput.test.d.ts +1 -0
- package/lib/src/components/forms/numberInput/index.d.ts +1 -0
- package/lib/src/components/forms/passwordInput/PasswordInput.d.ts +15 -0
- package/lib/src/components/forms/passwordInput/PasswordInput.stories.d.ts +11 -0
- package/lib/src/components/forms/passwordInput/__tests__/PasswordInput.test.d.ts +1 -0
- package/lib/src/components/forms/passwordInput/index.d.ts +1 -0
- package/lib/src/components/forms/radio/Radio.d.ts +12 -0
- package/lib/src/components/forms/radio/Radio.stories.d.ts +6 -0
- package/lib/src/components/forms/radio/__tests__/Radio.test.d.ts +1 -0
- package/lib/src/components/forms/radio/index.d.ts +1 -0
- package/lib/src/components/forms/select/Select.d.ts +6 -0
- package/lib/src/components/forms/select/Select.stories.d.ts +7 -0
- package/lib/src/components/forms/select/__tests__/Select.test.d.ts +1 -0
- package/lib/src/components/forms/select/index.d.ts +1 -0
- package/lib/src/components/forms/select/types.d.ts +6 -0
- package/lib/src/components/forms/subcomponents/DisplayFormError.d.ts +5 -0
- package/lib/src/components/forms/subcomponents/ErrorList.d.ts +6 -0
- package/lib/src/components/forms/subcomponents/Label.d.ts +9 -0
- package/lib/src/components/forms/subcomponents/__tests__/ErrorList.test.d.ts +1 -0
- package/lib/src/components/forms/subcomponents/__tests__/Label.test.d.ts +1 -0
- package/lib/src/components/forms/textarea/Textarea.d.ts +21 -0
- package/lib/src/components/forms/textarea/Textarea.stories.d.ts +11 -0
- package/lib/src/components/forms/textarea/__tests__/Textarea.test.d.ts +1 -0
- package/lib/src/components/forms/textarea/index.d.ts +1 -0
- package/lib/src/components/forms/toggle/Toggle.d.ts +13 -0
- package/lib/src/components/forms/toggle/Toggle.stories.d.ts +6 -0
- package/lib/src/components/forms/toggle/__tests__/Toggle.test.d.ts +1 -0
- package/lib/src/components/forms/toggle/index.d.ts +1 -0
- package/lib/src/components/grid/col/Col.d.ts +2 -0
- package/lib/src/components/grid/col/Col.stories.d.ts +6 -0
- package/lib/src/components/grid/container/Container.d.ts +2 -0
- package/lib/src/components/grid/container/Container.stories.d.ts +10 -0
- package/lib/src/components/grid/index.d.ts +3 -0
- package/lib/src/components/grid/row/Row.d.ts +2 -0
- package/lib/src/components/grid/row/Row.stories.d.ts +6 -0
- package/lib/src/components/icons/Icon.d.ts +2 -0
- package/lib/src/components/icons/Icon.stories.d.ts +10 -0
- package/lib/src/components/icons/__tests__/Icon.test.d.ts +1 -0
- package/lib/src/components/icons/index.d.ts +1 -0
- package/lib/src/components/icons/indicons.d.ts +148 -0
- package/lib/src/components/icons/types.d.ts +10 -0
- package/lib/src/components/index.d.ts +16 -0
- package/lib/src/components/menu/Menu.d.ts +5 -0
- package/lib/src/components/menu/Menu.stories.d.ts +6 -0
- package/lib/src/components/menu/Menu.test.d.ts +1 -0
- package/lib/src/components/menu/index.d.ts +1 -0
- package/lib/src/components/pill/Pill.d.ts +2 -0
- package/lib/src/components/pill/Pill.stories.d.ts +8 -0
- package/lib/src/components/pill/__tests__/Pill.test.d.ts +1 -0
- package/lib/src/components/pill/index.d.ts +1 -0
- package/lib/src/components/pill/types.d.ts +10 -0
- package/lib/src/components/popper/Popper.d.ts +2 -0
- package/lib/src/components/popper/Popper.stories.d.ts +8 -0
- package/lib/src/components/popper/Popper.test.d.ts +1 -0
- package/lib/src/components/popper/PopperContext.d.ts +12 -0
- package/lib/src/components/popper/index.d.ts +1 -0
- package/lib/src/components/popper/types.d.ts +9 -0
- package/lib/src/components/skeleton/Skeleton.d.ts +9 -0
- package/lib/src/components/skeleton/Skeleton.stories.d.ts +9 -0
- package/lib/src/components/skeleton/__tests__/Skeleton.test.d.ts +1 -0
- package/lib/src/components/skeleton/index.d.ts +1 -0
- package/lib/src/components/table/LoadingComponent.d.ts +1 -0
- package/lib/src/components/table/SkeletonTable.d.ts +7 -0
- package/lib/src/components/table/Table.d.ts +2 -0
- package/lib/src/components/table/Table.stories.d.ts +7 -0
- package/lib/src/components/table/index.d.ts +1 -0
- package/lib/src/components/table/sampleData.d.ts +9 -0
- package/lib/src/components/table/types.d.ts +10 -0
- package/lib/src/components/tables/table/LoadingComponent.d.ts +1 -0
- package/lib/src/components/tables/table/Table.d.ts +78 -0
- package/lib/src/components/tables/table/Table.stories.d.ts +6 -0
- package/lib/src/components/tables/table/index.d.ts +1 -0
- package/lib/src/components/tables/table/sampleData.d.ts +8 -0
- package/lib/src/hooks/useClickOutside.d.ts +2 -0
- package/lib/src/index.d.ts +23 -0
- package/lib/src/legacy/components/Accordion/Accordion.d.ts +9 -0
- package/lib/src/legacy/components/Accordion/Accordion.stories.d.ts +25 -0
- package/lib/src/legacy/components/Accordion/Accordion.styles.d.ts +1 -0
- package/lib/src/legacy/components/Accordion/index.d.ts +1 -0
- package/lib/src/legacy/components/ListTable/Header/Header.d.ts +21 -0
- package/lib/src/legacy/components/ListTable/Header/Header.styles.d.ts +1 -0
- package/lib/src/legacy/components/ListTable/Header/index.d.ts +1 -0
- package/lib/src/legacy/components/ListTable/ListTable.d.ts +41 -0
- package/lib/src/legacy/components/ListTable/ListTable.stories.d.ts +54 -0
- package/lib/src/legacy/components/ListTable/ListTable.styles.d.ts +1 -0
- package/lib/src/legacy/components/ListTable/index.d.ts +1 -0
- package/lib/src/legacy/components/ListTable/mock-data/index.d.ts +1 -0
- package/lib/src/legacy/components/ListTable/mock-data/mock-data.d.ts +54 -0
- package/lib/src/legacy/components/LoadingAwareContainer/LoadingAwareContainer.d.ts +15 -0
- package/lib/src/legacy/components/LoadingAwareContainer/LoadingAwareContainer.stories.d.ts +22 -0
- package/lib/src/legacy/components/LoadingAwareContainer/LoadingAwareContainer.styles.d.ts +2 -0
- package/lib/src/legacy/components/LoadingAwareContainer/index.d.ts +1 -0
- package/lib/src/legacy/components/Navigation/Drawer/Drawer.d.ts +16 -0
- package/lib/src/legacy/components/Navigation/Drawer/Drawer.stories.d.ts +6 -0
- package/lib/src/legacy/components/Navigation/Drawer/DrawerLinkList.d.ts +9 -0
- package/lib/src/legacy/components/Navigation/Drawer/DrawerLinkList.styles.d.ts +2 -0
- package/lib/src/legacy/components/Navigation/Drawer/__mocks__/mocks.d.ts +3 -0
- package/lib/src/legacy/components/Navigation/Drawer/__tests__/DrawerLinkList.test.d.ts +1 -0
- package/lib/src/legacy/components/Navigation/Drawer/index.d.ts +1 -0
- package/lib/src/legacy/components/Navigation/Drawer/types.d.ts +7 -0
- package/lib/src/legacy/components/Navigation/index.d.ts +1 -0
- package/lib/src/legacy/components/Pagination/Pagination.d.ts +18 -0
- package/lib/src/legacy/components/Pagination/Pagination.stories.d.ts +18 -0
- package/lib/src/legacy/components/Pagination/Pagination.styles.d.ts +1 -0
- package/lib/src/legacy/components/Pagination/index.d.ts +1 -0
- package/lib/src/legacy/components/Toggle/Toggle.d.ts +12 -0
- package/lib/src/legacy/components/Toggle/Toggle.stories.d.ts +21 -0
- package/lib/src/legacy/components/Toggle/Toggle.styles.d.ts +1 -0
- package/lib/src/legacy/components/Toggle/index.d.ts +1 -0
- package/lib/src/legacy/components/Tooltip/Tooltip.d.ts +15 -0
- package/lib/src/legacy/components/Tooltip/Tooltip.stories.d.ts +9 -0
- package/lib/src/legacy/components/Tooltip/Tooltip.styles.d.ts +1 -0
- package/lib/src/legacy/components/Tooltip/index.d.ts +1 -0
- package/lib/src/legacy/components/basic-section/Section/Section.d.ts +8 -0
- package/lib/src/legacy/components/basic-section/Section/Section.stories.d.ts +13 -0
- package/lib/src/legacy/components/basic-section/Section/Section.styles.d.ts +1 -0
- package/lib/src/legacy/components/basic-section/Section/index.d.ts +1 -0
- package/lib/src/legacy/components/basic-section/SectionBlock/SectionBlock.d.ts +9 -0
- package/lib/src/legacy/components/basic-section/SectionBlock/SectionBlock.styles.d.ts +1 -0
- package/lib/src/legacy/components/basic-section/SectionBlock/index.d.ts +1 -0
- package/lib/src/legacy/components/basic-section/SectionBody/SectionBody.d.ts +7 -0
- package/lib/src/legacy/components/basic-section/SectionBody/SectionBody.stories.d.ts +10 -0
- package/lib/src/legacy/components/basic-section/SectionBody/SectionBody.styles.d.ts +1 -0
- package/lib/src/legacy/components/basic-section/SectionBody/index.d.ts +1 -0
- package/lib/src/legacy/components/basic-section/SectionHeader/SectionHeader.d.ts +8 -0
- package/lib/src/legacy/components/basic-section/SectionHeader/SectionHeader.stories.d.ts +14 -0
- package/lib/src/legacy/components/basic-section/SectionHeader/SectionHeader.styles.d.ts +1 -0
- package/lib/src/legacy/components/basic-section/SectionHeader/index.d.ts +1 -0
- package/lib/src/legacy/components/basic-section/SectionTable/SectionTable.d.ts +1 -0
- package/lib/src/legacy/components/basic-section/SectionTable/SectionTable.styles.d.ts +1 -0
- package/lib/src/legacy/components/basic-section/SectionTable/index.d.ts +1 -0
- package/lib/src/legacy/components/basic-section/index.d.ts +5 -0
- package/lib/src/legacy/components/buttons/Button/Button.d.ts +21 -0
- package/lib/src/legacy/components/buttons/Button/Button.stories.d.ts +25 -0
- package/lib/src/legacy/components/buttons/Button/Button.styles.d.ts +1 -0
- package/lib/src/legacy/components/buttons/Button/index.d.ts +1 -0
- package/lib/src/legacy/components/buttons/IconButton/IconButton.d.ts +32 -0
- package/lib/src/legacy/components/buttons/IconButton/IconButton.stories.d.ts +43 -0
- package/lib/src/legacy/components/buttons/IconButton/IconButton.styles.d.ts +5 -0
- package/lib/src/legacy/components/buttons/IconButton/index.d.ts +1 -0
- package/lib/src/legacy/components/buttons/commonStyles.d.ts +9 -0
- package/lib/src/legacy/components/buttons/index.d.ts +2 -0
- package/lib/src/legacy/components/buttons/types.d.ts +3 -0
- package/lib/src/legacy/components/dropdowns/BorderSelect/BorderSelect.d.ts +19 -0
- package/lib/src/legacy/components/dropdowns/BorderSelect/BorderSelect.stories.d.ts +31 -0
- package/lib/src/legacy/components/dropdowns/BorderSelect/BorderSelect.styles.d.ts +2 -0
- package/lib/src/legacy/components/dropdowns/BorderSelect/index.d.ts +1 -0
- package/lib/src/legacy/components/dropdowns/MultiCombobox/MultiCombobox.d.ts +23 -0
- package/lib/src/legacy/components/dropdowns/MultiCombobox/MultiCombobox.stories.d.ts +46 -0
- package/lib/src/legacy/components/dropdowns/MultiCombobox/MultiCombobox.styles.d.ts +4 -0
- package/lib/src/legacy/components/dropdowns/MultiCombobox/index.d.ts +1 -0
- package/lib/src/legacy/components/dropdowns/Select/Select.d.ts +19 -0
- package/lib/src/legacy/components/dropdowns/Select/Select.stories.d.ts +34 -0
- package/lib/src/legacy/components/dropdowns/Select/Select.styles.d.ts +1 -0
- package/lib/src/legacy/components/dropdowns/Select/index.d.ts +1 -0
- package/lib/src/legacy/components/dropdowns/SingleCombobox/SingleCombobox.d.ts +20 -0
- package/lib/src/legacy/components/dropdowns/SingleCombobox/SingleCombobox.stories.d.ts +31 -0
- package/lib/src/legacy/components/dropdowns/SingleCombobox/SingleCombobox.styles.d.ts +4 -0
- package/lib/src/legacy/components/dropdowns/SingleCombobox/index.d.ts +1 -0
- package/lib/src/legacy/components/dropdowns/commonStyles.d.ts +1 -0
- package/lib/src/legacy/components/dropdowns/index.d.ts +4 -0
- package/lib/src/legacy/components/dropdowns/types.d.ts +45 -0
- package/lib/src/legacy/components/dropdowns/useCombobox.d.ts +25 -0
- package/lib/src/legacy/components/dropdowns/utils.d.ts +20 -0
- package/lib/src/legacy/components/index.d.ts +14 -0
- package/lib/src/legacy/components/inputs/DatePicker/DatePicker.d.ts +15 -0
- package/lib/src/legacy/components/inputs/DatePicker/DatePicker.stories.d.ts +6 -0
- package/lib/src/legacy/components/inputs/DatePicker/DatePicker.styles.d.ts +1 -0
- package/lib/src/legacy/components/inputs/DatePicker/index.d.ts +1 -0
- package/lib/src/legacy/components/inputs/EditableInput/EditableInput.d.ts +13 -0
- package/lib/src/legacy/components/inputs/EditableInput/EditableInput.stories.d.ts +14 -0
- package/lib/src/legacy/components/inputs/EditableInput/EditableInput.styles.d.ts +1 -0
- package/lib/src/legacy/components/inputs/EditableInput/index.d.ts +1 -0
- package/lib/src/legacy/components/inputs/NoInputDatePicker/NoInputDatePicker.d.ts +21 -0
- package/lib/src/legacy/components/inputs/NoInputDatePicker/NoInputDatePicker.stories.d.ts +7 -0
- package/lib/src/legacy/components/inputs/NoInputDatePicker/NoInputDatePicker.styles.d.ts +1 -0
- package/lib/src/legacy/components/inputs/NoInputDatePicker/index.d.ts +1 -0
- package/lib/src/legacy/components/inputs/NumberInput/NumberInput.d.ts +23 -0
- package/lib/src/legacy/components/inputs/NumberInput/NumberInput.stories.d.ts +28 -0
- package/lib/src/legacy/components/inputs/NumberInput/NumberInput.styles.d.ts +1 -0
- package/lib/src/legacy/components/inputs/NumberInput/index.d.ts +1 -0
- package/lib/src/legacy/components/inputs/RadioButtons/RadioButtons.d.ts +25 -0
- package/lib/src/legacy/components/inputs/RadioButtons/RadioButtons.stories.d.ts +15 -0
- package/lib/src/legacy/components/inputs/RadioButtons/RadioButtons.styles.d.ts +13 -0
- package/lib/src/legacy/components/inputs/RadioButtons/index.d.ts +1 -0
- package/lib/src/legacy/components/inputs/RadioGroup/RadioGroup.d.ts +27 -0
- package/lib/src/legacy/components/inputs/RadioGroup/RadioGroup.stories.d.ts +16 -0
- package/lib/src/legacy/components/inputs/RadioGroup/RadioGroup.styles.d.ts +1 -0
- package/lib/src/legacy/components/inputs/RadioGroup/index.d.ts +1 -0
- package/lib/src/legacy/components/inputs/SearchInput/SearchInput.d.ts +17 -0
- package/lib/src/legacy/components/inputs/SearchInput/SearchInput.stories.d.ts +30 -0
- package/lib/src/legacy/components/inputs/SearchInput/SearchInput.styles.d.ts +1 -0
- package/lib/src/legacy/components/inputs/SearchInput/index.d.ts +1 -0
- package/lib/src/legacy/components/inputs/TextInput/TextInput.d.ts +24 -0
- package/lib/src/legacy/components/inputs/TextInput/TextInput.stories.d.ts +62 -0
- package/lib/src/legacy/components/inputs/TextInput/TextInput.styles.d.ts +2 -0
- package/lib/src/legacy/components/inputs/TextInput/index.d.ts +1 -0
- package/lib/src/legacy/components/inputs/index.d.ts +8 -0
- package/lib/src/legacy/components/inputs/inputsCommon.styles.d.ts +4 -0
- package/lib/src/legacy/components/loading-indicators/BarSpinner/BarSpinner.d.ts +7 -0
- package/lib/src/legacy/components/loading-indicators/BarSpinner/BarSpinner.stories.d.ts +10 -0
- package/lib/src/legacy/components/loading-indicators/BarSpinner/BarSpinner.styles.d.ts +1 -0
- package/lib/src/legacy/components/loading-indicators/BarSpinner/index.d.ts +1 -0
- package/lib/src/legacy/components/loading-indicators/CirclePulse/CirclePulse.d.ts +10 -0
- package/lib/src/legacy/components/loading-indicators/CirclePulse/CirclePulse.stories.d.ts +12 -0
- package/lib/src/legacy/components/loading-indicators/CirclePulse/CirclePulse.styles.d.ts +7 -0
- package/lib/src/legacy/components/loading-indicators/CirclePulse/index.d.ts +1 -0
- package/lib/src/legacy/components/loading-indicators/CircleSpinner/CircleSpinner.d.ts +10 -0
- package/lib/src/legacy/components/loading-indicators/CircleSpinner/CircleSpinner.stories.d.ts +10 -0
- package/lib/src/legacy/components/loading-indicators/CircleSpinner/index.d.ts +1 -0
- package/lib/src/legacy/components/loading-indicators/LoadingIndicator/LoadingIndicator.d.ts +10 -0
- package/lib/src/legacy/components/loading-indicators/LoadingIndicator/LoadingIndicator.stories.d.ts +11 -0
- package/lib/src/legacy/components/loading-indicators/LoadingIndicator/LoadingIndicator.styles.d.ts +7 -0
- package/lib/src/legacy/components/loading-indicators/LoadingIndicator/index.d.ts +1 -0
- package/lib/src/legacy/components/loading-indicators/LoadingList/LoadingList.d.ts +1 -0
- package/lib/src/legacy/components/loading-indicators/LoadingList/LoadingList.stories.d.ts +10 -0
- package/lib/src/legacy/components/loading-indicators/LoadingList/LoadingList.styles.d.ts +1 -0
- package/lib/src/legacy/components/loading-indicators/LoadingList/index.d.ts +1 -0
- package/lib/src/legacy/components/loading-indicators/PercentageRing/PercentageRing.d.ts +12 -0
- package/lib/src/legacy/components/loading-indicators/PercentageRing/PercentageRing.stories.d.ts +10 -0
- package/lib/src/legacy/components/loading-indicators/PercentageRing/PercentageRing.styles.d.ts +1 -0
- package/lib/src/legacy/components/loading-indicators/PercentageRing/index.d.ts +1 -0
- package/lib/src/legacy/components/loading-indicators/RandomLoadingMessage/RandomLoadingMessage.d.ts +1 -0
- package/lib/src/legacy/components/loading-indicators/RandomLoadingMessage/RandomLoadingMessage.stories.d.ts +10 -0
- package/lib/src/legacy/components/loading-indicators/RandomLoadingMessage/index.d.ts +1 -0
- package/lib/src/legacy/components/loading-indicators/RandomLoadingMessage/random-messages.d.ts +2 -0
- package/lib/src/legacy/components/loading-indicators/index.d.ts +7 -0
- package/lib/src/legacy/components/modals/ConfirmModal/ConfirmModal.d.ts +17 -0
- package/lib/src/legacy/components/modals/ConfirmModal/ConfirmModal.stories.d.ts +44 -0
- package/lib/src/legacy/components/modals/ConfirmModal/ConfirmModal.styles.d.ts +1 -0
- package/lib/src/legacy/components/modals/ConfirmModal/index.d.ts +1 -0
- package/lib/src/legacy/components/modals/ModalBase/ModalBase.d.ts +26 -0
- package/lib/src/legacy/components/modals/ModalBase/ModalBase.stories.d.ts +9 -0
- package/lib/src/legacy/components/modals/ModalBase/ModalBase.styles.d.ts +4 -0
- package/lib/src/legacy/components/modals/ModalBase/index.d.ts +2 -0
- package/lib/src/legacy/components/modals/index.d.ts +2 -0
- package/lib/src/legacy/components/text-truncate/TextTruncate.d.ts +8 -0
- package/lib/src/legacy/components/text-truncate/TextTruncate.stories.d.ts +6 -0
- package/lib/src/legacy/components/text-truncate/TextTruncate.styles.d.ts +1 -0
- package/lib/src/legacy/components/text-truncate/TextTruncate.test.d.ts +1 -0
- package/lib/src/legacy/components/text-truncate/index.d.ts +1 -0
- package/lib/src/legacy/components/user-feedback/Shrug/Shrug.d.ts +14 -0
- package/lib/src/legacy/components/user-feedback/Shrug/Shrug.stories.d.ts +31 -0
- package/lib/src/legacy/components/user-feedback/Shrug/Shrug.styles.d.ts +1 -0
- package/lib/src/legacy/components/user-feedback/Shrug/index.d.ts +1 -0
- package/lib/src/legacy/components/user-feedback/index.d.ts +1 -0
- package/lib/src/legacy/styles/globals/buttons.d.ts +1 -0
- package/lib/src/legacy/styles/globals/forms.d.ts +1 -0
- package/lib/src/legacy/styles/globals/index.d.ts +1 -0
- package/lib/src/legacy/styles/globals/layout.d.ts +1 -0
- package/lib/src/legacy/styles/globals/lists.d.ts +1 -0
- package/lib/src/legacy/styles/globals/margin-padding.d.ts +1 -0
- package/lib/src/legacy/styles/globals/media.d.ts +1 -0
- package/lib/src/legacy/styles/globals/tables.d.ts +1 -0
- package/lib/src/legacy/styles/globals/typography.d.ts +1 -0
- package/lib/src/legacy/styles/globals/utility-classes.d.ts +1 -0
- package/lib/src/legacy/styles/index.d.ts +1 -0
- package/lib/src/legacy/tokens/animation.d.ts +4 -0
- package/lib/src/legacy/tokens/breakpoints.d.ts +10 -0
- package/lib/src/legacy/tokens/colors.d.ts +144 -0
- package/lib/src/legacy/tokens/index.d.ts +8 -0
- package/lib/src/legacy/tokens/margin.d.ts +4 -0
- package/lib/src/legacy/tokens/numbers.d.ts +10 -0
- package/lib/src/legacy/tokens/padding.d.ts +4 -0
- package/lib/src/legacy/tokens/spacings.d.ts +5 -0
- package/lib/src/legacy/tokens/typography.d.ts +61 -0
- package/lib/src/legacy/utils/color.d.ts +21 -0
- package/lib/src/legacy/utils/index.d.ts +4 -0
- package/lib/src/legacy/utils/number.d.ts +21 -0
- package/lib/src/legacy/utils/string.d.ts +12 -0
- package/lib/src/setupTests.d.ts +1 -0
- package/lib/src/storybook/labelArgTypes.d.ts +3 -0
- package/lib/src/stylesAndAnimations/borders/BorderColor.d.ts +3 -0
- package/lib/src/stylesAndAnimations/borders/BorderColor.stories.d.ts +6 -0
- package/lib/src/stylesAndAnimations/borders/BorderRadius.d.ts +3 -0
- package/lib/src/stylesAndAnimations/borders/BorderRadius.stories.d.ts +6 -0
- package/lib/src/stylesAndAnimations/borders/BorderStyles.d.ts +3 -0
- package/lib/src/stylesAndAnimations/borders/BorderStyles.stories.d.ts +6 -0
- package/lib/src/stylesAndAnimations/borders/BorderThickness.d.ts +3 -0
- package/lib/src/stylesAndAnimations/borders/BorderThickness.stories.d.ts +6 -0
- package/lib/src/stylesAndAnimations/borders/index.d.ts +4 -0
- package/lib/src/stylesAndAnimations/colors/Colors.d.ts +1 -0
- package/lib/src/stylesAndAnimations/colors/Colors.stories.d.ts +6 -0
- package/lib/src/stylesAndAnimations/colors/Swatch.d.ts +8 -0
- package/lib/src/stylesAndAnimations/colors/UtilityClasses.d.ts +1 -0
- package/lib/src/stylesAndAnimations/colors/UtilityClasses.stories.d.ts +6 -0
- package/lib/src/stylesAndAnimations/colors/constants.d.ts +5 -0
- package/lib/src/stylesAndAnimations/colors/hooks.d.ts +1 -0
- package/lib/src/stylesAndAnimations/colors/index.d.ts +1 -0
- package/lib/src/stylesAndAnimations/sizing/Sizing.d.ts +2 -0
- package/lib/src/stylesAndAnimations/sizing/Sizing.stories.d.ts +6 -0
- package/lib/src/stylesAndAnimations/sizing/index.d.ts +1 -0
- package/lib/src/stylesAndAnimations/typography/Typography.d.ts +1 -0
- package/lib/src/stylesAndAnimations/typography/Typography.stories.d.ts +6 -0
- package/lib/src/stylesAndAnimations/typography/index.d.ts +1 -0
- package/lib/src/types.d.ts +19 -0
- package/lib/stylesAndAnimations/colors/ColorSwatch.d.ts +7 -0
- package/lib/stylesAndAnimations/colors/Colors.d.ts +1 -0
- package/lib/stylesAndAnimations/colors/Colors.stories.d.ts +6 -0
- package/lib/stylesAndAnimations/colors/Swatch.d.ts +8 -0
- package/lib/stylesAndAnimations/colors/constants.d.ts +23 -0
- package/lib/stylesAndAnimations/colors/index.d.ts +1 -0
- package/lib/types.d.ts +2 -0
- package/package.json +1 -1
- package/src/components/alert/Alert.mdx +65 -0
- package/src/components/alert/Alert.stories.tsx +162 -0
- package/src/components/alert/Alert.tsx +68 -0
- package/src/components/alert/__tests__/Alert.test.tsx +52 -0
- package/src/components/alert/index.ts +2 -0
- package/src/components/alert/styles/Alert.scss +139 -0
- package/src/components/alert/styles/_tokens.scss +71 -0
- package/src/components/alert/types.ts +28 -0
- package/src/components/index.ts +1 -0
- package/src/components/pill/Pill.mdx +27 -0
- package/src/components/pill/Pill.stories.tsx +87 -0
- package/src/components/pill/Pill.tsx +36 -0
- package/src/components/pill/__tests__/Pill.test.tsx +93 -0
- package/src/components/pill/styles/Pill.scss +15 -2
- package/src/components/pill/types.ts +4 -0
- package/src/index.ts +1 -0
- package/src/setup/setupIcons.ts +8 -0
- package/src/styles/index.scss +2 -1
- package/src/types.ts +2 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const Colors: () => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const UtilityClasses: () => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const useTheme: () => string;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Colors } from './Colors';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Sizing } from './Sizing';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const Typography: () => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Typography } from './Typography';
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
export type PermafrostComponent = {
|
|
2
|
+
id?: string;
|
|
3
|
+
className?: string;
|
|
4
|
+
'data-cy'?: string;
|
|
5
|
+
'data-testid'?: string;
|
|
6
|
+
};
|
|
7
|
+
export type ButtonVariant = 'default' | 'primary' | 'destructive';
|
|
8
|
+
export type ButtonSize = 'normal' | 'large';
|
|
9
|
+
import { IconName } from '../build/generated/iconTypes';
|
|
10
|
+
export type { IconName };
|
|
11
|
+
import { IconSizes } from './components/icons/types';
|
|
12
|
+
export type { IconSizes };
|
|
13
|
+
import { SelectOption } from './components/forms/select/types';
|
|
14
|
+
export type { SelectOption };
|
|
15
|
+
import { TableProps, TableColumn, Direction, Alignment } from './components/table/types';
|
|
16
|
+
export type { TableProps, TableColumn, Direction, Alignment };
|
|
17
|
+
export type SemanticColor = 'primary' | 'secondary' | 'warning' | 'error' | 'success' | 'info';
|
|
18
|
+
import { PillColor, PillSize } from './components/pill/types';
|
|
19
|
+
export type { PillColor, PillSize };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const Colors: () => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
interface ColorPalette {
|
|
2
|
+
base: string;
|
|
3
|
+
50: string;
|
|
4
|
+
100: string;
|
|
5
|
+
150: string;
|
|
6
|
+
200: string;
|
|
7
|
+
250: string;
|
|
8
|
+
300: string;
|
|
9
|
+
400: string;
|
|
10
|
+
450: string;
|
|
11
|
+
500: string;
|
|
12
|
+
550?: string;
|
|
13
|
+
600: string;
|
|
14
|
+
700: string;
|
|
15
|
+
800: string;
|
|
16
|
+
900: string;
|
|
17
|
+
}
|
|
18
|
+
interface ThemeColors {
|
|
19
|
+
[key: string]: ColorPalette;
|
|
20
|
+
}
|
|
21
|
+
export declare const colorList: readonly ["primary", "secondary", "tertiary", "blue", "gray", "green", "orange", "pink", "purple", "red", "teal", "yellow"];
|
|
22
|
+
export declare const themeColors: ThemeColors;
|
|
23
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Colors } from './Colors';
|
package/lib/types.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { type AlertType, type AlertSize, type AlertVariant } from './components/alert/types';
|
|
1
2
|
import { type SelectOption } from './components/forms/select/types';
|
|
2
3
|
import { type IconSizes, type IconName } from './components/icons/types';
|
|
3
4
|
import { type PillColor, type PillSize, type PillVariant, type PillType } from './components/pill/types';
|
|
@@ -15,3 +16,4 @@ export type SemanticColor = 'neutral' | 'info' | 'warning' | 'error' | 'success'
|
|
|
15
16
|
export type { SelectOption };
|
|
16
17
|
export type { TableProps, TableColumn, Direction, Alignment };
|
|
17
18
|
export type { PillColor, PillSize, PillVariant, PillType };
|
|
19
|
+
export type { AlertType, AlertSize, AlertVariant };
|
package/package.json
CHANGED
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
import { Canvas, Meta, Controls, Story } from '@storybook/blocks';
|
|
2
|
+
import * as Alert from './Alert.stories';
|
|
3
|
+
|
|
4
|
+
<Meta title="Components/Alert" name="Alert" of={Alert} />
|
|
5
|
+
|
|
6
|
+
# Alert
|
|
7
|
+
|
|
8
|
+
Inline alerts notify users of a status or action result. They appear at the top
|
|
9
|
+
of a content area or near the item that needs attention.
|
|
10
|
+
|
|
11
|
+
Use `type` to set the semantic meaning (warning, info, success, error) — the
|
|
12
|
+
icon and accent color are chosen automatically. `variant` controls the visual
|
|
13
|
+
style: **soft** (subtle background) or **bordered** (colored border).
|
|
14
|
+
|
|
15
|
+
`size` controls density: **large** (default, banner-style) or **small**
|
|
16
|
+
(compact inline). When `tinted` is true on a **bordered** alert, the background
|
|
17
|
+
swaps from neutral to a type-specific tinted color.
|
|
18
|
+
|
|
19
|
+
Pass `title` to add a heading above the message. Add `actionText` + `onAction`
|
|
20
|
+
for an inline action button, and `onClose` to make it dismissable.
|
|
21
|
+
|
|
22
|
+
<Canvas of={Alert.Default} />
|
|
23
|
+
|
|
24
|
+
<Controls of={Alert.Default} />
|
|
25
|
+
|
|
26
|
+
## Types
|
|
27
|
+
|
|
28
|
+
<Canvas of={Alert.Types} />
|
|
29
|
+
|
|
30
|
+
## Variants
|
|
31
|
+
|
|
32
|
+
<Canvas of={Alert.Variants} />
|
|
33
|
+
|
|
34
|
+
## Small Bordered
|
|
35
|
+
|
|
36
|
+
Compact inline alerts without tinted backgrounds.
|
|
37
|
+
|
|
38
|
+
<Canvas of={Alert.SmallBordered} />
|
|
39
|
+
|
|
40
|
+
## Small Bordered Tinted
|
|
41
|
+
|
|
42
|
+
Compact inline alerts with type-specific tinted backgrounds — useful when
|
|
43
|
+
alerts sit alongside content and need stronger visual distinction.
|
|
44
|
+
|
|
45
|
+
<Canvas of={Alert.SmallBorderedTinted} />
|
|
46
|
+
|
|
47
|
+
## Small Tinted with Close
|
|
48
|
+
|
|
49
|
+
<Canvas of={Alert.SmallTintedWithClose} />
|
|
50
|
+
|
|
51
|
+
## With Title
|
|
52
|
+
|
|
53
|
+
<Canvas of={Alert.WithTitle} />
|
|
54
|
+
|
|
55
|
+
## With Action
|
|
56
|
+
|
|
57
|
+
<Canvas of={Alert.WithAction} />
|
|
58
|
+
|
|
59
|
+
## Closeable
|
|
60
|
+
|
|
61
|
+
<Canvas of={Alert.Closeable} />
|
|
62
|
+
|
|
63
|
+
## Combined
|
|
64
|
+
|
|
65
|
+
<Canvas of={Alert.Combined} />
|
|
@@ -0,0 +1,162 @@
|
|
|
1
|
+
import {
|
|
2
|
+
faTriangleExclamation,
|
|
3
|
+
faCircleInfo,
|
|
4
|
+
faCircleCheck,
|
|
5
|
+
faCircleExclamation,
|
|
6
|
+
faXmark,
|
|
7
|
+
} from '@fortawesome/free-solid-svg-icons';
|
|
8
|
+
import { type Meta, type StoryObj } from '@storybook/react';
|
|
9
|
+
import { fn } from '@storybook/test';
|
|
10
|
+
|
|
11
|
+
import { registerFontAwesomeIcons } from '@/setup/setupIcons';
|
|
12
|
+
|
|
13
|
+
import { Alert } from './Alert';
|
|
14
|
+
import { type AlertSize, type AlertType, type AlertVariant } from './types';
|
|
15
|
+
|
|
16
|
+
registerFontAwesomeIcons(
|
|
17
|
+
faTriangleExclamation,
|
|
18
|
+
faCircleInfo,
|
|
19
|
+
faCircleCheck,
|
|
20
|
+
faCircleExclamation,
|
|
21
|
+
faXmark,
|
|
22
|
+
);
|
|
23
|
+
|
|
24
|
+
const TYPES: AlertType[] = ['warning', 'info', 'success', 'error'];
|
|
25
|
+
const VARIANTS: AlertVariant[] = ['soft', 'bordered'];
|
|
26
|
+
const SIZES: AlertSize[] = ['large', 'small'];
|
|
27
|
+
|
|
28
|
+
const meta: Meta<typeof Alert> = {
|
|
29
|
+
title: 'Components/Alert',
|
|
30
|
+
component: Alert,
|
|
31
|
+
decorators: [
|
|
32
|
+
(Story) => (
|
|
33
|
+
<div style={{ display: 'flex', flexDirection: 'column', gap: 16, maxWidth: 700 }}>
|
|
34
|
+
<Story />
|
|
35
|
+
</div>
|
|
36
|
+
),
|
|
37
|
+
],
|
|
38
|
+
argTypes: {
|
|
39
|
+
type: { control: 'select', options: TYPES },
|
|
40
|
+
variant: { control: 'select', options: VARIANTS },
|
|
41
|
+
size: { control: 'select', options: SIZES },
|
|
42
|
+
tinted: { control: 'boolean' },
|
|
43
|
+
title: { control: 'text' },
|
|
44
|
+
actionText: { control: 'text' },
|
|
45
|
+
onAction: { control: false },
|
|
46
|
+
onClose: { control: false },
|
|
47
|
+
children: { control: 'text' },
|
|
48
|
+
},
|
|
49
|
+
};
|
|
50
|
+
|
|
51
|
+
export default meta;
|
|
52
|
+
|
|
53
|
+
type Story = StoryObj<typeof Alert>;
|
|
54
|
+
|
|
55
|
+
export const Default: Story = {
|
|
56
|
+
args: {
|
|
57
|
+
type: 'warning',
|
|
58
|
+
variant: 'soft',
|
|
59
|
+
children:
|
|
60
|
+
'This preset may incur additional charges depending on your submission size and usage.',
|
|
61
|
+
},
|
|
62
|
+
};
|
|
63
|
+
|
|
64
|
+
export const Types: Story = {
|
|
65
|
+
render: () => (
|
|
66
|
+
<>
|
|
67
|
+
{TYPES.map((type) => (
|
|
68
|
+
<Alert key={type} type={type}>
|
|
69
|
+
This is a {type} alert.
|
|
70
|
+
</Alert>
|
|
71
|
+
))}
|
|
72
|
+
</>
|
|
73
|
+
),
|
|
74
|
+
};
|
|
75
|
+
|
|
76
|
+
export const Variants: Story = {
|
|
77
|
+
render: () => (
|
|
78
|
+
<>
|
|
79
|
+
{VARIANTS.map((variant) => (
|
|
80
|
+
<Alert key={variant} type="info" variant={variant}>
|
|
81
|
+
This is the {variant} variant.
|
|
82
|
+
</Alert>
|
|
83
|
+
))}
|
|
84
|
+
</>
|
|
85
|
+
),
|
|
86
|
+
};
|
|
87
|
+
|
|
88
|
+
export const WithTitle: Story = {
|
|
89
|
+
args: {
|
|
90
|
+
type: 'info',
|
|
91
|
+
title: 'Info Title',
|
|
92
|
+
children: (
|
|
93
|
+
<>
|
|
94
|
+
An amazing message giving more context. A <a href="#">link</a> can be used in this content.
|
|
95
|
+
</>
|
|
96
|
+
),
|
|
97
|
+
},
|
|
98
|
+
};
|
|
99
|
+
|
|
100
|
+
export const WithAction: Story = {
|
|
101
|
+
args: {
|
|
102
|
+
type: 'warning',
|
|
103
|
+
actionText: 'Action',
|
|
104
|
+
onAction: fn(),
|
|
105
|
+
children: 'This preset may incur additional charges.',
|
|
106
|
+
},
|
|
107
|
+
};
|
|
108
|
+
|
|
109
|
+
export const Closeable: Story = {
|
|
110
|
+
args: {
|
|
111
|
+
type: 'success',
|
|
112
|
+
onClose: fn(),
|
|
113
|
+
children: 'Your changes have been saved.',
|
|
114
|
+
},
|
|
115
|
+
};
|
|
116
|
+
|
|
117
|
+
export const Combined: Story = {
|
|
118
|
+
args: {
|
|
119
|
+
type: 'error',
|
|
120
|
+
variant: 'bordered',
|
|
121
|
+
title: 'Upload Failed',
|
|
122
|
+
actionText: 'Retry',
|
|
123
|
+
onAction: fn(),
|
|
124
|
+
onClose: fn(),
|
|
125
|
+
children: 'The file could not be uploaded. Please check your connection and try again.',
|
|
126
|
+
},
|
|
127
|
+
};
|
|
128
|
+
|
|
129
|
+
export const SmallBordered: Story = {
|
|
130
|
+
render: () => (
|
|
131
|
+
<>
|
|
132
|
+
{TYPES.map((type) => (
|
|
133
|
+
<Alert key={type} type={type} variant="bordered" size="small">
|
|
134
|
+
This is a small bordered {type} alert.
|
|
135
|
+
</Alert>
|
|
136
|
+
))}
|
|
137
|
+
</>
|
|
138
|
+
),
|
|
139
|
+
};
|
|
140
|
+
|
|
141
|
+
export const SmallBorderedTinted: Story = {
|
|
142
|
+
render: () => (
|
|
143
|
+
<>
|
|
144
|
+
{TYPES.map((type) => (
|
|
145
|
+
<Alert key={type} type={type} variant="bordered" size="small" tinted>
|
|
146
|
+
This is a small bordered tinted {type} alert.
|
|
147
|
+
</Alert>
|
|
148
|
+
))}
|
|
149
|
+
</>
|
|
150
|
+
),
|
|
151
|
+
};
|
|
152
|
+
|
|
153
|
+
export const SmallTintedWithClose: Story = {
|
|
154
|
+
args: {
|
|
155
|
+
type: 'info',
|
|
156
|
+
variant: 'bordered',
|
|
157
|
+
size: 'small',
|
|
158
|
+
tinted: true,
|
|
159
|
+
onClose: fn(),
|
|
160
|
+
children: 'New correspondence has been added',
|
|
161
|
+
},
|
|
162
|
+
};
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import classNames from 'classnames';
|
|
2
|
+
|
|
3
|
+
import { type AlertProps, type AlertType } from './types';
|
|
4
|
+
import { Icon } from '../icons/Icon';
|
|
5
|
+
import { type IconName } from '../icons/types';
|
|
6
|
+
|
|
7
|
+
const ALERT_ICON: Record<AlertType, IconName> = {
|
|
8
|
+
warning: 'fa-triangle-exclamation',
|
|
9
|
+
info: 'fa-circle-info',
|
|
10
|
+
success: 'fa-circle-check',
|
|
11
|
+
error: 'fa-circle-exclamation',
|
|
12
|
+
};
|
|
13
|
+
|
|
14
|
+
export const Alert = ({
|
|
15
|
+
type,
|
|
16
|
+
variant = 'soft',
|
|
17
|
+
size = 'large',
|
|
18
|
+
tinted = false,
|
|
19
|
+
title,
|
|
20
|
+
children,
|
|
21
|
+
actionText,
|
|
22
|
+
onAction,
|
|
23
|
+
onClose,
|
|
24
|
+
closeAriaLabel = 'Dismiss',
|
|
25
|
+
className,
|
|
26
|
+
...rest
|
|
27
|
+
}: AlertProps) => {
|
|
28
|
+
return (
|
|
29
|
+
<div
|
|
30
|
+
role="alert"
|
|
31
|
+
className={classNames(
|
|
32
|
+
'alert',
|
|
33
|
+
`alert--${variant}`,
|
|
34
|
+
`alert--${variant}-${type}`,
|
|
35
|
+
{ 'alert--small': size === 'small', 'alert--tinted': tinted, 'alert--has-title': !!title },
|
|
36
|
+
className,
|
|
37
|
+
)}
|
|
38
|
+
{...rest}
|
|
39
|
+
>
|
|
40
|
+
<Icon name={ALERT_ICON[type]} size="sm" />
|
|
41
|
+
|
|
42
|
+
<div className="alert__body">
|
|
43
|
+
{title && <div className="alert__title">{title}</div>}
|
|
44
|
+
<div className="alert__message">{children}</div>
|
|
45
|
+
</div>
|
|
46
|
+
|
|
47
|
+
{((actionText && onAction) || onClose) && (
|
|
48
|
+
<div className="alert__actions">
|
|
49
|
+
{actionText && onAction && (
|
|
50
|
+
<button type="button" className="alert__action" onClick={onAction}>
|
|
51
|
+
{actionText}
|
|
52
|
+
</button>
|
|
53
|
+
)}
|
|
54
|
+
{onClose && (
|
|
55
|
+
<button
|
|
56
|
+
type="button"
|
|
57
|
+
className="alert__close"
|
|
58
|
+
onClick={onClose}
|
|
59
|
+
aria-label={closeAriaLabel}
|
|
60
|
+
>
|
|
61
|
+
<Icon name="fa-xmark" size="xs" />
|
|
62
|
+
</button>
|
|
63
|
+
)}
|
|
64
|
+
</div>
|
|
65
|
+
)}
|
|
66
|
+
</div>
|
|
67
|
+
);
|
|
68
|
+
};
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import { render, screen } from '@testing-library/react';
|
|
2
|
+
import userEvent from '@testing-library/user-event';
|
|
3
|
+
|
|
4
|
+
import { Alert } from '@/components/alert/Alert';
|
|
5
|
+
|
|
6
|
+
describe('Alert', () => {
|
|
7
|
+
describe('action button', () => {
|
|
8
|
+
it('renders action button and calls onAction when clicked', async () => {
|
|
9
|
+
const user = userEvent.setup();
|
|
10
|
+
const handleAction = jest.fn();
|
|
11
|
+
render(
|
|
12
|
+
<Alert type="info" actionText="Retry" onAction={handleAction}>
|
|
13
|
+
Something failed
|
|
14
|
+
</Alert>,
|
|
15
|
+
);
|
|
16
|
+
await user.click(screen.getByRole('button', { name: 'Retry' }));
|
|
17
|
+
expect(handleAction).toHaveBeenCalledTimes(1);
|
|
18
|
+
});
|
|
19
|
+
|
|
20
|
+
it('does not render action button when actionText is provided without onAction', () => {
|
|
21
|
+
render(
|
|
22
|
+
<Alert type="info" actionText="Orphan">
|
|
23
|
+
msg
|
|
24
|
+
</Alert>,
|
|
25
|
+
);
|
|
26
|
+
expect(screen.queryByRole('button', { name: 'Orphan' })).not.toBeInTheDocument();
|
|
27
|
+
});
|
|
28
|
+
});
|
|
29
|
+
|
|
30
|
+
describe('close button', () => {
|
|
31
|
+
it('calls onClose when close button is clicked', async () => {
|
|
32
|
+
const user = userEvent.setup();
|
|
33
|
+
const handleClose = jest.fn();
|
|
34
|
+
render(
|
|
35
|
+
<Alert type="warning" onClose={handleClose}>
|
|
36
|
+
dismissable
|
|
37
|
+
</Alert>,
|
|
38
|
+
);
|
|
39
|
+
await user.click(screen.getByRole('button', { name: 'Dismiss' }));
|
|
40
|
+
expect(handleClose).toHaveBeenCalledTimes(1);
|
|
41
|
+
});
|
|
42
|
+
|
|
43
|
+
it('uses custom closeAriaLabel', () => {
|
|
44
|
+
render(
|
|
45
|
+
<Alert type="info" onClose={() => {}} closeAriaLabel="Fermer">
|
|
46
|
+
msg
|
|
47
|
+
</Alert>,
|
|
48
|
+
);
|
|
49
|
+
expect(screen.getByRole('button', { name: 'Fermer' })).toBeInTheDocument();
|
|
50
|
+
});
|
|
51
|
+
});
|
|
52
|
+
});
|