@kaizen/components 1.66.0 → 1.67.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/codemods/README.md +5 -0
- package/codemods/upgradeIconV1/getNewIconPropsFromOldIconName.ts +255 -0
- package/codemods/upgradeIconV1/index.ts +33 -0
- package/codemods/upgradeIconV1/transformCaMonogramIconToBrand.spec.ts +83 -0
- package/codemods/upgradeIconV1/transformCaMonogramIconToBrand.ts +53 -0
- package/codemods/upgradeIconV1/transformIcon.spec.ts +181 -0
- package/codemods/upgradeIconV1/transformIcon.ts +115 -0
- package/codemods/upgradeIconV1/transformSpinnerIconToLoadingSpinner.spec.ts +81 -0
- package/codemods/upgradeIconV1/transformSpinnerIconToLoadingSpinner.ts +41 -0
- package/codemods/upgradeIconV1/upgradeIconV1.spec.ts +306 -0
- package/codemods/upgradeIconV1/upgradeIconV1.ts +94 -0
- package/codemods/utils/createProp.spec.ts +83 -0
- package/codemods/utils/createProp.ts +51 -0
- package/codemods/utils/getKaioTagName.spec.ts +85 -0
- package/codemods/utils/getKaioTagName.ts +129 -0
- package/codemods/utils/index.ts +3 -1
- package/codemods/utils/transformComponentsInDir.ts +32 -16
- package/codemods/utils/transformSource.ts +10 -5
- package/codemods/utils/updateJsxElementWithNewProps.ts +4 -3
- package/codemods/utils/updateKaioImports.spec.ts +223 -0
- package/codemods/utils/updateKaioImports.ts +233 -0
- package/dist/cjs/Avatar/Avatar.cjs +16 -13
- package/dist/cjs/Calendar/CalendarRange/CalendarRange.cjs +9 -7
- package/dist/cjs/Calendar/CalendarSingle/CalendarSingle.cjs +9 -7
- package/dist/cjs/Calendar/LegacyCalendarRange/LegacyCalendarRange.cjs +9 -7
- package/dist/cjs/Checkbox/Checkbox/Checkbox.cjs +5 -11
- package/dist/cjs/ClearButton/ClearButton.cjs +5 -4
- package/dist/cjs/Collapsible/Collapsible/Collapsible.cjs +4 -7
- package/dist/cjs/DateInput/DateInputWithIconButton/DateInputWithIconButton.cjs +5 -4
- package/dist/cjs/DateRangePicker/DateRangePicker.cjs +5 -4
- package/dist/cjs/ErrorPage/ErrorPage.cjs +9 -7
- package/dist/cjs/FieldMessage/FieldMessage.cjs +5 -11
- package/dist/cjs/Filter/FilterBar/subcomponents/AddFiltersMenu/AddFiltersMenu.cjs +4 -5
- package/dist/cjs/Filter/FilterButton/FilterButton/FilterButton.cjs +4 -7
- package/dist/cjs/Filter/FilterButton/FilterButtonRemovable/FilterButtonRemovable.cjs +5 -5
- package/dist/cjs/Filter/FilterMultiSelect/subcomponents/MultiSelectOption/MultiSelectOption.cjs +4 -4
- package/dist/cjs/GuidanceBlock/GuidanceBlock.cjs +5 -4
- package/dist/cjs/Illustration/utils/usePausePlay.cjs +5 -8
- package/dist/cjs/Input/InputSearch/InputSearch.cjs +4 -3
- package/dist/cjs/LikertScaleLegacy/LikertScaleLegacy.cjs +5 -6
- package/dist/cjs/Modal/ConfirmationModal/ConfirmationModal.cjs +31 -26
- package/dist/cjs/Modal/GenericModal/subcomponents/ModalHeader/ModalHeader.cjs +4 -5
- package/dist/cjs/MultiSelect/subcomponents/Checkbox/Checkbox.cjs +7 -17
- package/dist/cjs/MultiSelect/subcomponents/MultiSelectToggle/MultiSelectToggle.cjs +4 -7
- package/dist/cjs/Notification/subcomponents/CancelButton/CancelButton.cjs +4 -3
- package/dist/cjs/Notification/subcomponents/NotificationIcon/NotificationIcon.cjs +33 -38
- package/dist/cjs/Notification/subcomponents/NotificationIcon/NotificationIcon.module.css.cjs +6 -0
- package/dist/cjs/Pagination/subcomponents/DirectionalLink/DirectionalLink.cjs +11 -19
- package/dist/cjs/Pagination/subcomponents/TruncateIndicator/TruncateIndicator.cjs +4 -5
- package/dist/cjs/Popover/Popover.cjs +5 -4
- package/dist/cjs/Popover/utils/classMappers.cjs +21 -16
- package/dist/cjs/RichTextEditor/RichTextEditor/utils/controlmap.cjs +29 -25
- package/dist/cjs/RichTextEditor/utils/plugins/LinkManager/components/LinkPopover/LinkPopover.cjs +10 -12
- package/dist/cjs/Select/Select.cjs +8 -10
- package/dist/cjs/SplitButton/subcomponents/DropdownButton/DropdownButton.cjs +4 -4
- package/dist/cjs/Table/Table.cjs +11 -10
- package/dist/cjs/Tag/Tag.cjs +21 -17
- package/dist/cjs/TextField/TextField.cjs +5 -4
- package/dist/cjs/Tile/subcomponents/GenericTile/GenericTile.cjs +8 -7
- package/dist/cjs/TitleBlockZen/TitleBlockZen.cjs +9 -12
- package/dist/cjs/TitleBlockZen/subcomponents/MainActions.cjs +7 -7
- package/dist/cjs/TitleBlockZen/subcomponents/MobileActions.cjs +10 -15
- package/dist/cjs/TitleBlockZen/subcomponents/SecondaryActions.cjs +7 -7
- package/dist/cjs/ToggleSwitch/ToggleSwitch/ToggleSwitch.cjs +5 -5
- package/dist/cjs/Workflow/subcomponents/Footer/components/ProgressStepper/ProgressStepper.cjs +13 -18
- package/dist/cjs/__future__/Icon/Icon.cjs +47 -0
- package/dist/cjs/__future__/Icon/Icon.module.css.cjs +10 -0
- package/dist/cjs/__future__/Icon/constants.cjs +8 -0
- package/dist/cjs/__future__/Select/subcomponents/Option/Option.cjs +4 -5
- package/dist/cjs/__future__/Select/subcomponents/SelectToggle/SelectToggle.cjs +5 -9
- package/dist/cjs/__future__/Tag/RemovableTag/subcomponents/RemoveButton.cjs +4 -3
- package/dist/cjs/future.cjs +2 -0
- package/dist/esm/Avatar/Avatar.mjs +16 -13
- package/dist/esm/Calendar/CalendarRange/CalendarRange.mjs +9 -7
- package/dist/esm/Calendar/CalendarSingle/CalendarSingle.mjs +9 -7
- package/dist/esm/Calendar/LegacyCalendarRange/LegacyCalendarRange.mjs +9 -7
- package/dist/esm/Checkbox/Checkbox/Checkbox.mjs +5 -11
- package/dist/esm/ClearButton/ClearButton.mjs +5 -4
- package/dist/esm/Collapsible/Collapsible/Collapsible.mjs +5 -8
- package/dist/esm/DateInput/DateInputWithIconButton/DateInputWithIconButton.mjs +5 -4
- package/dist/esm/DateRangePicker/DateRangePicker.mjs +5 -4
- package/dist/esm/ErrorPage/ErrorPage.mjs +10 -8
- package/dist/esm/FieldMessage/FieldMessage.mjs +6 -12
- package/dist/esm/Filter/FilterBar/subcomponents/AddFiltersMenu/AddFiltersMenu.mjs +4 -5
- package/dist/esm/Filter/FilterButton/FilterButton/FilterButton.mjs +5 -8
- package/dist/esm/Filter/FilterButton/FilterButtonRemovable/FilterButtonRemovable.mjs +5 -5
- package/dist/esm/Filter/FilterMultiSelect/subcomponents/MultiSelectOption/MultiSelectOption.mjs +4 -4
- package/dist/esm/GuidanceBlock/GuidanceBlock.mjs +5 -4
- package/dist/esm/Illustration/utils/usePausePlay.mjs +5 -8
- package/dist/esm/Input/InputSearch/InputSearch.mjs +4 -3
- package/dist/esm/LikertScaleLegacy/LikertScaleLegacy.mjs +5 -6
- package/dist/esm/Modal/ConfirmationModal/ConfirmationModal.mjs +31 -26
- package/dist/esm/Modal/GenericModal/subcomponents/ModalHeader/ModalHeader.mjs +4 -5
- package/dist/esm/MultiSelect/subcomponents/Checkbox/Checkbox.mjs +7 -17
- package/dist/esm/MultiSelect/subcomponents/MultiSelectToggle/MultiSelectToggle.mjs +5 -8
- package/dist/esm/Notification/subcomponents/CancelButton/CancelButton.mjs +4 -3
- package/dist/esm/Notification/subcomponents/NotificationIcon/NotificationIcon.mjs +33 -38
- package/dist/esm/Notification/subcomponents/NotificationIcon/NotificationIcon.module.css.mjs +4 -0
- package/dist/esm/Pagination/subcomponents/DirectionalLink/DirectionalLink.mjs +11 -19
- package/dist/esm/Pagination/subcomponents/TruncateIndicator/TruncateIndicator.mjs +4 -5
- package/dist/esm/Popover/Popover.mjs +5 -4
- package/dist/esm/Popover/utils/classMappers.mjs +21 -16
- package/dist/esm/RichTextEditor/RichTextEditor/utils/controlmap.mjs +33 -29
- package/dist/esm/RichTextEditor/utils/plugins/LinkManager/components/LinkPopover/LinkPopover.mjs +10 -12
- package/dist/esm/Select/Select.mjs +9 -11
- package/dist/esm/SplitButton/subcomponents/DropdownButton/DropdownButton.mjs +4 -4
- package/dist/esm/Table/Table.mjs +11 -10
- package/dist/esm/Tag/Tag.mjs +21 -17
- package/dist/esm/TextField/TextField.mjs +5 -4
- package/dist/esm/Tile/subcomponents/GenericTile/GenericTile.mjs +8 -7
- package/dist/esm/TitleBlockZen/TitleBlockZen.mjs +9 -12
- package/dist/esm/TitleBlockZen/subcomponents/MainActions.mjs +7 -7
- package/dist/esm/TitleBlockZen/subcomponents/MobileActions.mjs +13 -18
- package/dist/esm/TitleBlockZen/subcomponents/SecondaryActions.mjs +7 -7
- package/dist/esm/ToggleSwitch/ToggleSwitch/ToggleSwitch.mjs +5 -5
- package/dist/esm/Workflow/subcomponents/Footer/components/ProgressStepper/ProgressStepper.mjs +16 -21
- package/dist/esm/__future__/Icon/Icon.mjs +38 -0
- package/dist/esm/__future__/Icon/Icon.module.css.mjs +8 -0
- package/dist/esm/__future__/Icon/constants.mjs +6 -0
- package/dist/esm/__future__/Select/subcomponents/Option/Option.mjs +4 -5
- package/dist/esm/__future__/Select/subcomponents/SelectToggle/SelectToggle.mjs +6 -10
- package/dist/esm/__future__/Tag/RemovableTag/subcomponents/RemoveButton.mjs +4 -3
- package/dist/esm/future.mjs +1 -0
- package/dist/styles.css +585 -561
- package/dist/types/__future__/Icon/Icon.d.ts +21 -0
- package/dist/types/__future__/Icon/constants.d.ts +5 -0
- package/dist/types/__future__/Icon/index.d.ts +1 -0
- package/dist/types/__future__/Icon/types.d.ts +4 -0
- package/dist/types/__future__/index.d.ts +1 -0
- package/package.json +10 -10
- package/src/Avatar/Avatar.module.scss +6 -8
- package/src/Avatar/Avatar.tsx +14 -5
- package/src/BrandMoment/_docs/BrandMoment.stories.tsx +6 -10
- package/src/BrandMoment/_docs/ExampleHeaders.tsx +2 -2
- package/src/Calendar/CalendarRange/CalendarRange.tsx +7 -3
- package/src/Calendar/CalendarSingle/CalendarSingle.tsx +7 -3
- package/src/Calendar/LegacyCalendarRange/LegacyCalendarRange.tsx +7 -3
- package/src/Calendar/baseCalendarClassNames.module.scss +0 -4
- package/src/Checkbox/Checkbox/Checkbox.module.scss +0 -8
- package/src/Checkbox/Checkbox/Checkbox.tsx +6 -8
- package/src/ClearButton/ClearButton.tsx +2 -2
- package/src/Collapsible/Collapsible/Collapsible.tsx +5 -6
- package/src/Collapsible/Collapsible/_docs/Collapsible.stories.tsx +2 -2
- package/src/DateInput/DateInputWithIconButton/DateInputWithIconButton.module.scss +2 -7
- package/src/DateInput/DateInputWithIconButton/DateInputWithIconButton.tsx +2 -2
- package/src/DateRangePicker/DateRangePicker.tsx +2 -2
- package/src/EmptyState/_docs/EmptyState.stickersheet.stories.tsx +8 -2
- package/src/EmptyState/_docs/EmptyState.stories.tsx +4 -2
- package/src/ErrorPage/ErrorPage.tsx +5 -3
- package/src/FieldMessage/FieldMessage.tsx +6 -14
- package/src/Filter/FilterBar/FilterBar.spec.tsx +12 -12
- package/src/Filter/FilterBar/subcomponents/AddFiltersMenu/AddFiltersMenu.tsx +2 -2
- package/src/Filter/FilterButton/FilterButton/FilterButton.module.scss +1 -1
- package/src/Filter/FilterButton/FilterButton/FilterButton.tsx +5 -6
- package/src/Filter/FilterButton/FilterButtonRemovable/FilterButtonRemovable.tsx +2 -2
- package/src/Filter/FilterDateRangePicker/FilterDateRangePicker.spec.tsx +0 -1
- package/src/Filter/FilterDateRangePicker/subcomponents/DateRangeInputField/DateRangeInputField.spec.tsx +2 -1
- package/src/Filter/FilterMultiSelect/subcomponents/MultiSelectOption/MultiSelectOption.tsx +2 -2
- package/src/Filter/FilterSelect/FilterSelect.spec.tsx +4 -5
- package/src/GuidanceBlock/GuidanceBlock.tsx +6 -2
- package/src/Icon/_docs/{Icon.stories.tsx → Icon.docs.stories.tsx} +1 -1
- package/src/Icon/_docs/Icon.mdx +1 -2
- package/src/Icon/_docs/Icon.stickersheet.stories.tsx +1 -1
- package/src/Illustration/utils/usePausePlay.tsx +7 -5
- package/src/Input/Input/_docs/Input.stickersheet.stories.tsx +7 -5
- package/src/Input/Input/_docs/Input.stories.tsx +5 -3
- package/src/Input/InputSearch/InputSearch.tsx +2 -2
- package/src/Label/Label.module.scss +4 -0
- package/src/LikertScaleLegacy/LikertScaleLegacy.tsx +2 -2
- package/src/Loading/LoadingGraphic/_docs/LoadingGraphic.stories.tsx +2 -2
- package/src/Modal/ConfirmationModal/ConfirmationModal.module.scss +2 -0
- package/src/Modal/ConfirmationModal/ConfirmationModal.tsx +32 -35
- package/src/Modal/GenericModal/subcomponents/ModalHeader/ModalHeader.tsx +2 -2
- package/src/MultiSelect/MultiSelect.spec.tsx +7 -3
- package/src/MultiSelect/subcomponents/Checkbox/Checkbox.module.scss +0 -6
- package/src/MultiSelect/subcomponents/Checkbox/Checkbox.tsx +10 -9
- package/src/MultiSelect/subcomponents/MultiSelectOptions/MultiSelectOptions.spec.tsx +11 -7
- package/src/MultiSelect/subcomponents/MultiSelectToggle/MultiSelectToggle.tsx +5 -7
- package/src/Notification/subcomponents/CancelButton/CancelButton.tsx +2 -2
- package/src/Notification/subcomponents/GenericNotification/_mixins.scss +2 -0
- package/src/Notification/subcomponents/NotificationIcon/NotificationIcon.module.css +3 -0
- package/src/Notification/subcomponents/NotificationIcon/NotificationIcon.tsx +22 -16
- package/src/Pagination/subcomponents/DirectionalLink/DirectionalLink.module.scss +0 -4
- package/src/Pagination/subcomponents/DirectionalLink/DirectionalLink.tsx +13 -12
- package/src/Pagination/subcomponents/TruncateIndicator/TruncateIndicator.module.scss +0 -1
- package/src/Pagination/subcomponents/TruncateIndicator/TruncateIndicator.tsx +2 -2
- package/src/Popover/Popover.module.scss +3 -3
- package/src/Popover/Popover.tsx +2 -2
- package/src/Popover/utils/classMappers.tsx +6 -11
- package/src/RichTextEditor/RichTextEditor/subcomponents/ToggleIconButton/_docs/ToggleIconButton.stickersheet.stories.tsx +7 -7
- package/src/RichTextEditor/RichTextEditor/subcomponents/ToggleIconButton/_docs/ToggleIconButton.stories.tsx +2 -2
- package/src/RichTextEditor/RichTextEditor/subcomponents/Toolbar/Toolbar.spec.tsx +7 -4
- package/src/RichTextEditor/RichTextEditor/subcomponents/Toolbar/_docs/Toolbar.stories.tsx +18 -12
- package/src/RichTextEditor/RichTextEditor/utils/controlmap.tsx +25 -18
- package/src/RichTextEditor/utils/plugins/LinkManager/components/LinkPopover/LinkPopover.tsx +4 -8
- package/src/Select/Select.module.scss +2 -0
- package/src/Select/Select.tsx +10 -7
- package/src/SplitButton/subcomponents/DropdownButton/DropdownButton.spec.tsx +4 -5
- package/src/SplitButton/subcomponents/DropdownButton/DropdownButton.tsx +2 -2
- package/src/Table/Table.tsx +4 -8
- package/src/Table/_docs/Table.stickersheet.stories.tsx +4 -4
- package/src/Table/_docs/Table.stories.tsx +3 -3
- package/src/Tag/Tag.module.scss +2 -0
- package/src/Tag/Tag.tsx +7 -13
- package/src/Text/Text.module.scss +2 -0
- package/src/TextField/TextField.spec.tsx +9 -4
- package/src/TextField/TextField.tsx +2 -2
- package/src/TextField/_docs/TextField.stories.tsx +4 -3
- package/src/Tile/subcomponents/GenericTile/GenericTile.tsx +3 -3
- package/src/TitleBlockZen/TitleBlockZen.module.scss +1 -0
- package/src/TitleBlockZen/TitleBlockZen.spec.tsx +1 -1
- package/src/TitleBlockZen/TitleBlockZen.tsx +6 -9
- package/src/TitleBlockZen/_docs/TitleBlockZen.stories.tsx +5 -5
- package/src/TitleBlockZen/subcomponents/MainActions.tsx +5 -3
- package/src/TitleBlockZen/subcomponents/MobileActions.tsx +13 -16
- package/src/TitleBlockZen/subcomponents/SecondaryActions.tsx +3 -3
- package/src/ToggleSwitch/ToggleSwitch/ToggleSwitch.module.scss +0 -3
- package/src/ToggleSwitch/ToggleSwitch/ToggleSwitch.tsx +2 -2
- package/src/Workflow/_docs/Workflow.stories.tsx +4 -5
- package/src/Workflow/_docs/WorkflowHeader.stories.tsx +4 -5
- package/src/Workflow/_docs/controls/controls.tsx +4 -4
- package/src/Workflow/subcomponents/Footer/components/ProgressStepper/ProgressStepper.tsx +6 -31
- package/src/__actions__/Button/v1/Button/_docs/Button.stickersheet.stories.tsx +5 -5
- package/src/__actions__/Button/v1/Button/_docs/Button.stories.tsx +6 -5
- package/src/__actions__/Button/v1/IconButton/_docs/IconButton.stickersheet.stories.tsx +6 -6
- package/src/__actions__/Button/v1/IconButton/_docs/IconButton.stories.tsx +4 -4
- package/src/__actions__/Button/v2/Button/_docs/Button.stories.tsx +6 -5
- package/src/__actions__/Button/v2/IconButton/_docs/IconButton.stories.tsx +4 -4
- package/src/__actions__/Menu/v1/_docs/Menu.stickersheet.stories.tsx +3 -3
- package/src/__actions__/Menu/v1/_docs/Menu.stories.tsx +3 -3
- package/src/__actions__/Menu/v1/_docs/MenuContentExample.tsx +6 -6
- package/src/__actions__/Menu/v1/_docs/examples.tsx +5 -5
- package/src/__actions__/Menu/v2/_docs/Menu.stories.tsx +3 -3
- package/src/__actions__/Menu/v3/_docs/ApiSpecification.mdx +1 -3
- package/src/__actions__/Menu/v3/_docs/Menu.docs.stories.tsx +46 -45
- package/src/__actions__/Menu/v3/_docs/Menu.mdx +1 -1
- package/src/__actions__/Menu/v3/_docs/Menu.spec.stories.tsx +21 -23
- package/src/__actions__/Menu/v3/_docs/Menu.stories.tsx +12 -15
- package/src/__future__/Icon/Icon.module.css +35 -0
- package/src/__future__/Icon/Icon.spec.tsx +36 -0
- package/src/__future__/Icon/Icon.tsx +85 -0
- package/src/__future__/Icon/_docs/Icon--api-specification.mdx +98 -0
- package/src/__future__/Icon/_docs/Icon--usage-guidelines.mdx +145 -0
- package/src/__future__/Icon/_docs/Icon.docs.module.css +17 -0
- package/src/__future__/Icon/_docs/Icon.docs.stories.tsx +524 -0
- package/src/__future__/Icon/_docs/Icon.stickersheet.stories.tsx +126 -0
- package/src/__future__/Icon/_docs/assets/interface-dont.png +0 -0
- package/src/__future__/Icon/_docs/assets/tooltip-dont.png +0 -0
- package/src/__future__/Icon/constants.ts +149 -0
- package/src/__future__/Icon/index.ts +1 -0
- package/src/__future__/Icon/material-symbols-metadata.json +3370 -0
- package/src/__future__/Icon/types.ts +11 -0
- package/src/__future__/Select/subcomponents/Option/Option.tsx +2 -2
- package/src/__future__/Select/subcomponents/SelectToggle/SelectToggle.module.scss +1 -1
- package/src/__future__/Select/subcomponents/SelectToggle/SelectToggle.tsx +6 -9
- package/src/__future__/Tag/RemovableTag/_docs/RemovableTag.stories.tsx +0 -77
- package/src/__future__/Tag/RemovableTag/subcomponents/RemoveButton.module.scss +0 -56
- package/src/__future__/Tag/RemovableTag/subcomponents/RemoveButton.tsx +2 -12
- package/src/__future__/Tag/Tag/Tag.module.scss +1 -1
- package/src/__future__/Tag/Tag/_docs/Tag-migration-guide.stories.tsx +6 -17
- package/src/__future__/Tag/Tag/_docs/Tag.stickersheet.stories.tsx +5 -2
- package/src/__future__/Tag/Tag/_docs/Tag.stories.tsx +13 -6
- package/src/__future__/index.ts +1 -0
- package/src/__overlays__/Tooltip/v1/_docs/Tooltip.stickersheet.stories.tsx +10 -10
- package/src/__overlays__/Tooltip/v1/_docs/Tooltip.stories.tsx +7 -4
- package/src/__overlays__/Tooltip/v1/utils/isSemanticElement.spec.tsx +4 -11
- package/src/__overlays__/Tooltip/v3/_docs/Tooltip.docs.stories.tsx +10 -10
- package/src/__overlays__/Tooltip/v3/_docs/Tooltip.spec.stories.tsx +3 -3
- package/codemods/utils/getTagName.spec.ts +0 -24
- package/codemods/utils/getTagName.ts +0 -32
- package/dist/cjs/__future__/Tag/RemovableTag/subcomponents/RemoveTagIcon.cjs +0 -23
- package/dist/esm/__future__/Tag/RemovableTag/subcomponents/RemoveTagIcon.mjs +0 -15
- package/dist/types/__future__/Tag/RemovableTag/subcomponents/RemoveTagIcon.d.ts +0 -2
- package/src/__future__/Tag/RemovableTag/subcomponents/RemoveTagIcon.tsx +0 -21
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { HTMLAttributes } from "react";
|
|
2
|
+
import { StringSuggestions } from "../../types/StringSuggestions";
|
|
3
|
+
import { IconNames } from "./types";
|
|
4
|
+
type PresentationalIcon = {
|
|
5
|
+
isPresentational: true;
|
|
6
|
+
alt?: never;
|
|
7
|
+
};
|
|
8
|
+
type MeaningfulIcon = {
|
|
9
|
+
isPresentational?: false;
|
|
10
|
+
alt: string;
|
|
11
|
+
};
|
|
12
|
+
type BaseIconProps = {
|
|
13
|
+
isFilled?: boolean;
|
|
14
|
+
} & HTMLAttributes<HTMLSpanElement> & (PresentationalIcon | MeaningfulIcon);
|
|
15
|
+
export type IconProps = BaseIconProps & {
|
|
16
|
+
/** Options available at https://fonts.google.com/icons */
|
|
17
|
+
name: StringSuggestions<IconNames>;
|
|
18
|
+
shouldMirrorInRTL?: boolean;
|
|
19
|
+
};
|
|
20
|
+
export declare const Icon: ({ name, shouldMirrorInRTL, ...restProps }: IconProps) => JSX.Element;
|
|
21
|
+
export {};
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export declare const handledRtlIcons: {
|
|
2
|
+
checklist: "checklist_rtl";
|
|
3
|
+
format_list_numbered: "format_list_numbered_rtl";
|
|
4
|
+
};
|
|
5
|
+
export declare const iconDefaultSet: ("add" | "add_a_photo" | "add_comment" | "add_link" | "arrow_back" | "arrow_downward" | "arrow_drop_down" | "arrow_drop_up" | "arrow_forward" | "arrow_upward" | "assignment" | "assignment_add" | "assignment_ind" | "assignment_returned" | "assignment_turned_in" | "backup" | "bar_chart" | "bookmark" | "brush" | "build" | "cached" | "cancel" | "chat_apps_script" | "chat_error" | "chat_paste_go" | "check" | "check_circle" | "chevron_left" | "chevron_right" | "close" | "close_fullscreen" | "cloud_download" | "comment_bank" | "content_copy" | "dashboard" | "date_range" | "delete" | "domain" | "draft" | "drag_indicator" | "edit" | "error" | "event" | "favorite" | "find_in_page" | "flag" | "flash_on" | "format_bold" | "format_indent_decrease" | "format_indent_increase" | "format_italic" | "format_list_bulleted" | "format_list_numbered" | "format_underlined" | "forum" | "forward" | "front_hand" | "grade" | "group" | "groups" | "help" | "history" | "home" | "horizontal_rule" | "info" | "key" | "keyboard_arrow_down" | "keyboard_arrow_up" | "keyboard_tab" | "keyboard_tab_rtl" | "label" | "lan" | "lightbulb" | "link_off" | "list" | "local_fire_department" | "lock" | "logout" | "mail" | "manage_accounts" | "menu" | "mms" | "more_horiz" | "more_vert" | "north_east" | "note_alt" | "notifications_active" | "open_in_full" | "open_in_new" | "pause" | "percent" | "person" | "person_add" | "person_cancel" | "person_check" | "play_circle" | "playlist_add_check" | "potted_plant" | "power" | "power_settings_new" | "print" | "privacy_tip" | "psychology_alt" | "radio_button_checked" | "radio_button_unchecked" | "rate_review" | "redo" | "reduce_capacity" | "refresh" | "remove" | "reviews" | "schedule" | "school" | "search" | "send" | "sensors" | "sentiment_dissatisfied" | "sentiment_neutral" | "sentiment_satisfied" | "sentiment_very_satisfied" | "settings" | "sms" | "south_east" | "star" | "support" | "thumb_down" | "thumb_up" | "today" | "translate" | "tune" | "undo" | "user_attributes" | "visibility" | "visibility_off" | "warning" | "zoom_in" | "zoom_out" | "auto_awesome")[];
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./Icon";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kaizen/components",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.67.0",
|
|
4
4
|
"description": "Kaizen component library",
|
|
5
5
|
"author": "Geoffrey Chong <geoff.chong@cultureamp.com>",
|
|
6
6
|
"homepage": "https://cultureamp.design",
|
|
@@ -58,15 +58,15 @@
|
|
|
58
58
|
"date-fns": "^4.1.0",
|
|
59
59
|
"lodash.debounce": "^4.0.8",
|
|
60
60
|
"nanobus": "^4.5.0",
|
|
61
|
-
"prosemirror-commands": "^1.6.
|
|
61
|
+
"prosemirror-commands": "^1.6.1",
|
|
62
62
|
"prosemirror-history": "^1.4.1",
|
|
63
63
|
"prosemirror-inputrules": "^1.4.0",
|
|
64
64
|
"prosemirror-keymap": "^1.2.2",
|
|
65
|
-
"prosemirror-model": "^1.
|
|
65
|
+
"prosemirror-model": "^1.23.0",
|
|
66
66
|
"prosemirror-schema-basic": "^1.2.3",
|
|
67
67
|
"prosemirror-schema-list": "^1.4.1",
|
|
68
68
|
"prosemirror-state": "^1.4.3",
|
|
69
|
-
"prosemirror-transform": "^1.10.
|
|
69
|
+
"prosemirror-transform": "^1.10.2",
|
|
70
70
|
"prosemirror-utils": "^1.2.2",
|
|
71
71
|
"prosemirror-view": "^1.34.3",
|
|
72
72
|
"react-animate-height": "^3.2.3",
|
|
@@ -81,7 +81,7 @@
|
|
|
81
81
|
"react-textfit": "^1.1.1",
|
|
82
82
|
"resize-observer-polyfill": "^1.5.1",
|
|
83
83
|
"tsx": "^4.19.1",
|
|
84
|
-
"use-debounce": "^10.0.
|
|
84
|
+
"use-debounce": "^10.0.4",
|
|
85
85
|
"uuid": "^10.0.0"
|
|
86
86
|
},
|
|
87
87
|
"dependenciesComments": {
|
|
@@ -90,7 +90,7 @@
|
|
|
90
90
|
"devDependencies": {
|
|
91
91
|
"@cultureamp/frontend-apis": "^10.0.0",
|
|
92
92
|
"@cultureamp/i18n-react-intl": "^2.6.3",
|
|
93
|
-
"@tanstack/react-query": "^5.59.
|
|
93
|
+
"@tanstack/react-query": "^5.59.13",
|
|
94
94
|
"@testing-library/dom": "^10.4.0",
|
|
95
95
|
"@types/jest-axe": "^3.5.9",
|
|
96
96
|
"@types/lodash.debounce": "^4.0.9",
|
|
@@ -106,20 +106,20 @@
|
|
|
106
106
|
"postcss": "^8.4.47",
|
|
107
107
|
"postcss-cli": "^11.0.0",
|
|
108
108
|
"postcss-import": "^16.1.0",
|
|
109
|
-
"postcss-preset-env": "^10.0.
|
|
109
|
+
"postcss-preset-env": "^10.0.7",
|
|
110
110
|
"postcss-scss": "^4.0.9",
|
|
111
|
-
"query-string": "^9.1.
|
|
111
|
+
"query-string": "^9.1.1",
|
|
112
112
|
"react": "^18.3.1",
|
|
113
113
|
"react-dom": "^18.3.1",
|
|
114
114
|
"react-highlight": "^0.15.0",
|
|
115
|
-
"react-intl": "^6.
|
|
115
|
+
"react-intl": "^6.8.0",
|
|
116
116
|
"rollup": "^4.24.0",
|
|
117
117
|
"sass": "^1.77.8",
|
|
118
118
|
"serialize-query-params": "^2.0.2",
|
|
119
119
|
"svgo": "^3.3.2",
|
|
120
120
|
"tslib": "^2.7.0",
|
|
121
121
|
"tsx": "^4.19.1",
|
|
122
|
-
"@kaizen/design-tokens": "10.
|
|
122
|
+
"@kaizen/design-tokens": "10.8.0",
|
|
123
123
|
"@kaizen/package-bundler": "1.1.7"
|
|
124
124
|
},
|
|
125
125
|
"peerDependencies": {
|
|
@@ -106,28 +106,26 @@ $avatar-xxl: 7.75rem;
|
|
|
106
106
|
|
|
107
107
|
.fallbackIcon {
|
|
108
108
|
color: rgba($color-purple-800-rgb, 0.7);
|
|
109
|
-
|
|
109
|
+
font-size: var(--avatar-fallback-icon-size);
|
|
110
110
|
|
|
111
111
|
.xxlarge & {
|
|
112
|
-
|
|
112
|
+
--avatar-fallback-icon-size: calc(#{$avatar-xxl} * 0.8);
|
|
113
113
|
}
|
|
114
114
|
|
|
115
115
|
.xlarge & {
|
|
116
|
-
|
|
116
|
+
--avatar-fallback-icon-size: calc(#{$avatar-xl} * 0.8);
|
|
117
117
|
}
|
|
118
118
|
|
|
119
119
|
.large & {
|
|
120
|
-
|
|
120
|
+
--avatar-fallback-icon-size: calc(#{$avatar-lg} * 0.7);
|
|
121
121
|
}
|
|
122
122
|
|
|
123
123
|
.medium & {
|
|
124
|
-
|
|
125
|
-
margin-bottom: -1px;
|
|
124
|
+
--avatar-fallback-icon-size: calc(#{$avatar-md} * 0.7);
|
|
126
125
|
}
|
|
127
126
|
|
|
128
127
|
.small & {
|
|
129
|
-
|
|
130
|
-
margin-bottom: -1px;
|
|
128
|
+
--avatar-fallback-icon-size: calc(#{$avatar-sm} * 0.7);
|
|
131
129
|
}
|
|
132
130
|
}
|
|
133
131
|
|
package/src/Avatar/Avatar.tsx
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React, { useState, useEffect, useRef, HTMLAttributes } from "react"
|
|
2
2
|
import classnames from "classnames"
|
|
3
3
|
import { Textfit } from "react-textfit"
|
|
4
|
-
import {
|
|
4
|
+
import { Icon } from "~components/__future__/Icon"
|
|
5
5
|
import { OverrideClassName } from "~components/types/OverrideClassName"
|
|
6
6
|
import styles from "./Avatar.module.scss"
|
|
7
7
|
|
|
@@ -76,12 +76,21 @@ const getMaxFontSizePixels: (size: AvatarSizes) => number = size => {
|
|
|
76
76
|
return 22
|
|
77
77
|
}
|
|
78
78
|
|
|
79
|
-
const
|
|
79
|
+
const FallbackIcon = ({ alt }: { alt: string }): JSX.Element => {
|
|
80
80
|
if (alt) {
|
|
81
|
-
return
|
|
81
|
+
return (
|
|
82
|
+
<Icon name="person" alt={alt} isFilled className={styles.fallbackIcon} />
|
|
83
|
+
)
|
|
82
84
|
}
|
|
83
85
|
|
|
84
|
-
return
|
|
86
|
+
return (
|
|
87
|
+
<Icon
|
|
88
|
+
name="person"
|
|
89
|
+
isPresentational
|
|
90
|
+
isFilled
|
|
91
|
+
className={styles.fallbackIcon}
|
|
92
|
+
/>
|
|
93
|
+
)
|
|
85
94
|
}
|
|
86
95
|
|
|
87
96
|
const renderInitials = (
|
|
@@ -95,7 +104,7 @@ const renderInitials = (
|
|
|
95
104
|
const renderFallback = disableInitials || initials === ""
|
|
96
105
|
|
|
97
106
|
return renderFallback ? (
|
|
98
|
-
<
|
|
107
|
+
<FallbackIcon alt={alt} />
|
|
99
108
|
) : (
|
|
100
109
|
<abbr
|
|
101
110
|
className={classnames(styles.initials, isLongName && styles.longName)}
|
|
@@ -2,11 +2,6 @@
|
|
|
2
2
|
import React from "react"
|
|
3
3
|
import { Meta, StoryObj } from "@storybook/react"
|
|
4
4
|
import isChromatic from "chromatic"
|
|
5
|
-
import {
|
|
6
|
-
ArrowRightIcon,
|
|
7
|
-
EmailIcon,
|
|
8
|
-
FeedbackClassifyIcon,
|
|
9
|
-
} from "~components/Icon"
|
|
10
5
|
import {
|
|
11
6
|
BrandMomentCaptureIntro,
|
|
12
7
|
BrandMomentPositiveOutro,
|
|
@@ -14,6 +9,7 @@ import {
|
|
|
14
9
|
AnimatedSceneProps,
|
|
15
10
|
} from "~components/Illustration"
|
|
16
11
|
import { Text } from "~components/Text"
|
|
12
|
+
import { Icon } from "~components/__future__/Icon"
|
|
17
13
|
import { BrandMoment } from "../index"
|
|
18
14
|
import {
|
|
19
15
|
MinimalBasic,
|
|
@@ -65,7 +61,7 @@ export const Informative: Story = {
|
|
|
65
61
|
primaryAction: {
|
|
66
62
|
label: "Get started",
|
|
67
63
|
href: "#",
|
|
68
|
-
icon: <
|
|
64
|
+
icon: <Icon name="arrow_forward" isPresentational shouldMirrorInRTL />,
|
|
69
65
|
iconPosition: "end",
|
|
70
66
|
},
|
|
71
67
|
},
|
|
@@ -98,12 +94,12 @@ export const Success: Story = {
|
|
|
98
94
|
primaryAction: {
|
|
99
95
|
label: "Go to Home",
|
|
100
96
|
href: "#",
|
|
101
|
-
icon: <
|
|
97
|
+
icon: <Icon name="arrow_forward" isPresentational shouldMirrorInRTL />,
|
|
102
98
|
iconPosition: "end",
|
|
103
99
|
},
|
|
104
100
|
secondaryAction: {
|
|
105
101
|
label: "Rate this survey",
|
|
106
|
-
icon: <
|
|
102
|
+
icon: <Icon name="reviews" isPresentational isFilled />,
|
|
107
103
|
},
|
|
108
104
|
},
|
|
109
105
|
}
|
|
@@ -132,12 +128,12 @@ export const Warning: Story = {
|
|
|
132
128
|
primaryAction: {
|
|
133
129
|
label: "Go to Home",
|
|
134
130
|
href: "#",
|
|
135
|
-
icon: <
|
|
131
|
+
icon: <Icon name="arrow_forward" isPresentational shouldMirrorInRTL />,
|
|
136
132
|
iconPosition: "end",
|
|
137
133
|
},
|
|
138
134
|
secondaryAction: {
|
|
139
135
|
label: "Contact support",
|
|
140
|
-
icon: <
|
|
136
|
+
icon: <Icon name="mail" isPresentational isFilled />,
|
|
141
137
|
},
|
|
142
138
|
},
|
|
143
139
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from "react"
|
|
2
|
-
import { CloseIcon } from "~components/Icon"
|
|
3
2
|
import { Button } from "~components/__actions__/v2"
|
|
3
|
+
import { Icon } from "~components/__future__/Icon"
|
|
4
4
|
import { assetUrl } from "~components/utils/hostedAssets"
|
|
5
5
|
import styles from "./ExampleHeaders.module.scss"
|
|
6
6
|
|
|
@@ -18,7 +18,7 @@ export const MinimalBasic = (): JSX.Element => (
|
|
|
18
18
|
<Button
|
|
19
19
|
href="#"
|
|
20
20
|
label="Exit"
|
|
21
|
-
icon={<
|
|
21
|
+
icon={<Icon name="close" isPresentational />}
|
|
22
22
|
secondary
|
|
23
23
|
/>
|
|
24
24
|
<div className={styles.logoContainer}>
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React, { useEffect, useRef } from "react"
|
|
2
2
|
import { enAU } from "date-fns/locale"
|
|
3
3
|
import { DayPicker, DayPickerRangeProps } from "react-day-picker"
|
|
4
|
-
import {
|
|
4
|
+
import { Icon } from "~components/__future__/Icon"
|
|
5
5
|
import { OverrideClassName } from "~components/types/OverrideClassName"
|
|
6
6
|
import { baseCalendarClassNames } from "../baseCalendarClassNames"
|
|
7
7
|
import { isInvalidDate } from "../utils"
|
|
@@ -55,8 +55,12 @@ export const CalendarRange = ({
|
|
|
55
55
|
defaultMonth={selectedMonth}
|
|
56
56
|
classNames={classNames}
|
|
57
57
|
components={{
|
|
58
|
-
IconRight: () =>
|
|
59
|
-
|
|
58
|
+
IconRight: () => (
|
|
59
|
+
<Icon name="arrow_forward" isPresentational shouldMirrorInRTL />
|
|
60
|
+
),
|
|
61
|
+
IconLeft: () => (
|
|
62
|
+
<Icon name="arrow_back" isPresentational shouldMirrorInRTL />
|
|
63
|
+
),
|
|
60
64
|
}}
|
|
61
65
|
numberOfMonths={2}
|
|
62
66
|
locale={locale}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React, { useEffect, useRef } from "react"
|
|
2
2
|
import { enAU } from "date-fns/locale"
|
|
3
3
|
import { DayPicker, DayPickerSingleProps } from "react-day-picker"
|
|
4
|
-
import {
|
|
4
|
+
import { Icon } from "~components/__future__/Icon"
|
|
5
5
|
import { OverrideClassName } from "~components/types/OverrideClassName"
|
|
6
6
|
import { baseCalendarClassNames } from "../baseCalendarClassNames"
|
|
7
7
|
import { isInvalidDate, isValidWeekStartsOn } from "../utils"
|
|
@@ -53,8 +53,12 @@ export const CalendarSingle = ({
|
|
|
53
53
|
}
|
|
54
54
|
classNames={classNames}
|
|
55
55
|
components={{
|
|
56
|
-
IconRight: () =>
|
|
57
|
-
|
|
56
|
+
IconRight: () => (
|
|
57
|
+
<Icon name="arrow_forward" isPresentational shouldMirrorInRTL />
|
|
58
|
+
),
|
|
59
|
+
IconLeft: () => (
|
|
60
|
+
<Icon name="arrow_back" isPresentational shouldMirrorInRTL />
|
|
61
|
+
),
|
|
58
62
|
}}
|
|
59
63
|
locale={locale}
|
|
60
64
|
{...restProps}
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
Matcher,
|
|
8
8
|
DayPickerRangeProps,
|
|
9
9
|
} from "react-day-picker"
|
|
10
|
-
import {
|
|
10
|
+
import { Icon } from "~components/__future__/Icon"
|
|
11
11
|
import { baseCalendarClassNames } from "../baseCalendarClassNames"
|
|
12
12
|
import { DayOfWeek } from "../enums"
|
|
13
13
|
import { isInvalidDate, isValidWeekStartsOn } from "../utils"
|
|
@@ -62,8 +62,12 @@ export const LegacyCalendarRange = ({
|
|
|
62
62
|
onDayClick={onDayChange}
|
|
63
63
|
classNames={classNames}
|
|
64
64
|
components={{
|
|
65
|
-
IconRight: () =>
|
|
66
|
-
|
|
65
|
+
IconRight: () => (
|
|
66
|
+
<Icon name="arrow_forward" isPresentational shouldMirrorInRTL />
|
|
67
|
+
),
|
|
68
|
+
IconLeft: () => (
|
|
69
|
+
<Icon name="arrow_back" isPresentational shouldMirrorInRTL />
|
|
70
|
+
),
|
|
67
71
|
}}
|
|
68
72
|
locale={locale}
|
|
69
73
|
/>
|
|
@@ -4,7 +4,6 @@
|
|
|
4
4
|
@import "../../../styles/utils/form-variables";
|
|
5
5
|
|
|
6
6
|
$checkbox-size: 24px;
|
|
7
|
-
$icon-size: 24px;
|
|
8
7
|
$focus-ring-offset: 2px;
|
|
9
8
|
|
|
10
9
|
$dt-color-checkbox-background-color-checked: $color-gray-500;
|
|
@@ -23,14 +22,7 @@ $dt-color-checkbox-background-color-checked: $color-gray-500;
|
|
|
23
22
|
}
|
|
24
23
|
|
|
25
24
|
.icon {
|
|
26
|
-
height: $checkbox-size;
|
|
27
|
-
width: $checkbox-size;
|
|
28
25
|
position: absolute;
|
|
29
|
-
top: 50%;
|
|
30
|
-
transform: translateY(-50%);
|
|
31
|
-
// .icon is inside .box so .box's border-box rule means
|
|
32
|
-
// .icon sits to the right of .box's left-side border
|
|
33
|
-
left: calc(-1 * #{$border-solid-border-width});
|
|
34
26
|
color: $color-white;
|
|
35
27
|
}
|
|
36
28
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React, { InputHTMLAttributes } from "react"
|
|
2
2
|
import classnames from "classnames"
|
|
3
|
-
import {
|
|
3
|
+
import { Icon } from "~components/__future__/Icon"
|
|
4
4
|
import { OverrideClassName } from "~components/types/OverrideClassName"
|
|
5
5
|
import styles from "./Checkbox.module.scss"
|
|
6
6
|
|
|
@@ -22,13 +22,11 @@ const renderCheckOrMixedIcon = (
|
|
|
22
22
|
if (status === "off") return
|
|
23
23
|
|
|
24
24
|
return (
|
|
25
|
-
<
|
|
26
|
-
{status === "on" ?
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
)}
|
|
31
|
-
</span>
|
|
25
|
+
<Icon
|
|
26
|
+
name={status === "on" ? "check" : "remove"}
|
|
27
|
+
isPresentational
|
|
28
|
+
className={classnames(styles.icon, reversed && styles.reversed)}
|
|
29
|
+
/>
|
|
32
30
|
)
|
|
33
31
|
}
|
|
34
32
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React, { ButtonHTMLAttributes } from "react"
|
|
2
2
|
import classnames from "classnames"
|
|
3
|
-
import {
|
|
3
|
+
import { Icon } from "~components/__future__/Icon"
|
|
4
4
|
import { OverrideClassName } from "~components/types/OverrideClassName"
|
|
5
5
|
import styles from "./ClearButton.module.scss"
|
|
6
6
|
|
|
@@ -23,7 +23,7 @@ export const ClearButton = ({
|
|
|
23
23
|
)}
|
|
24
24
|
{...restProps}
|
|
25
25
|
>
|
|
26
|
-
<
|
|
26
|
+
<Icon name="cancel" isPresentational isFilled />
|
|
27
27
|
</button>
|
|
28
28
|
)
|
|
29
29
|
|
|
@@ -2,8 +2,8 @@ import React, { HTMLAttributes, useId, useState } from "react"
|
|
|
2
2
|
import classnames from "classnames"
|
|
3
3
|
import AnimateHeight from "react-animate-height"
|
|
4
4
|
import { Heading } from "~components/Heading"
|
|
5
|
-
import { ChevronUpIcon, ChevronDownIcon } from "~components/Icon"
|
|
6
5
|
import { IconButton } from "~components/__actions__/v2"
|
|
6
|
+
import { Icon } from "~components/__future__/Icon"
|
|
7
7
|
import { OverrideClassName } from "~components/types/OverrideClassName"
|
|
8
8
|
import { Sticky } from "../types"
|
|
9
9
|
import styles from "./Collapsible.module.scss"
|
|
@@ -117,11 +117,10 @@ export const Collapsible = ({
|
|
|
117
117
|
<IconButton
|
|
118
118
|
label={title}
|
|
119
119
|
icon={
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
)
|
|
120
|
+
<Icon
|
|
121
|
+
name={isOpen ? "keyboard_arrow_up" : "keyboard_arrow_down"}
|
|
122
|
+
isPresentational
|
|
123
|
+
/>
|
|
125
124
|
}
|
|
126
125
|
type="button"
|
|
127
126
|
aria-expanded={isOpen}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React, { useState } from "react"
|
|
2
2
|
import { Meta, StoryObj } from "@storybook/react"
|
|
3
3
|
import { Heading } from "~components/Heading"
|
|
4
|
-
import { AddIcon } from "~components/Icon"
|
|
5
4
|
import { Text } from "~components/Text"
|
|
5
|
+
import { Icon } from "~components/__future__/Icon"
|
|
6
6
|
import { Collapsible } from "../index"
|
|
7
7
|
|
|
8
8
|
const meta = {
|
|
@@ -76,7 +76,7 @@ export const CustomHeader: Story = {
|
|
|
76
76
|
renderHeader={title => (
|
|
77
77
|
<Heading variant="heading-4" tag="span">
|
|
78
78
|
<span className="flex gap-8 items-center">
|
|
79
|
-
<
|
|
79
|
+
<Icon name="potted_plant" isPresentational /> {title}
|
|
80
80
|
</span>
|
|
81
81
|
</Heading>
|
|
82
82
|
)}
|
|
@@ -9,8 +9,8 @@ $input-disabled-opacity: 0.3;
|
|
|
9
9
|
.iconButton {
|
|
10
10
|
@include button-reset;
|
|
11
11
|
|
|
12
|
-
display:
|
|
13
|
-
padding:
|
|
12
|
+
display: flex;
|
|
13
|
+
padding: var(--spacing-6);
|
|
14
14
|
border: $border-solid-border-width $border-solid-border-style transparent;
|
|
15
15
|
border-radius: $border-solid-border-radius;
|
|
16
16
|
position: relative;
|
|
@@ -35,11 +35,6 @@ $input-disabled-opacity: 0.3;
|
|
|
35
35
|
background-color: $color-blue-100;
|
|
36
36
|
color: $color-blue-500;
|
|
37
37
|
}
|
|
38
|
-
|
|
39
|
-
svg {
|
|
40
|
-
position: relative;
|
|
41
|
-
top: 2px;
|
|
42
|
-
}
|
|
43
38
|
}
|
|
44
39
|
|
|
45
40
|
.calendarActive {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from "react"
|
|
2
2
|
import classnames from "classnames"
|
|
3
|
-
import {
|
|
3
|
+
import { Icon } from "~components/__future__/Icon"
|
|
4
4
|
import { isRefObject } from "~components/utils/isRefObject"
|
|
5
5
|
import { DateInput, DateInputProps } from "../DateInput"
|
|
6
6
|
import styles from "./DateInputWithIconButton.module.scss"
|
|
@@ -39,7 +39,7 @@ export const DateInputWithIconButton = React.forwardRef<
|
|
|
39
39
|
disabled && styles.disabled
|
|
40
40
|
)}
|
|
41
41
|
>
|
|
42
|
-
<
|
|
42
|
+
<Icon name="today" isPresentational isFilled />
|
|
43
43
|
</button>
|
|
44
44
|
)
|
|
45
45
|
|
|
@@ -13,9 +13,9 @@ import {
|
|
|
13
13
|
LegacyCalendarRange,
|
|
14
14
|
LegacyCalendarRangeProps,
|
|
15
15
|
} from "~components/Calendar/LegacyCalendarRange"
|
|
16
|
-
import { DateStartIcon } from "~components/Icon"
|
|
17
16
|
import { Label } from "~components/Label"
|
|
18
17
|
import { VisuallyHidden } from "~components/VisuallyHidden"
|
|
18
|
+
import { Icon } from "~components/__future__/Icon"
|
|
19
19
|
import styles from "./DateRangePicker.module.scss"
|
|
20
20
|
|
|
21
21
|
export type DateRangePickerProps = {
|
|
@@ -168,7 +168,7 @@ export const DateRangePicker = ({
|
|
|
168
168
|
{...inputProps}
|
|
169
169
|
>
|
|
170
170
|
<div className={styles.startIconAdornment}>
|
|
171
|
-
<
|
|
171
|
+
<Icon name="today" isPresentational isFilled />
|
|
172
172
|
</div>
|
|
173
173
|
<span className={styles.value}>
|
|
174
174
|
{selectedDateRange?.from ? value : undefined}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React from "react"
|
|
2
2
|
import { Meta } from "@storybook/react"
|
|
3
3
|
import isChromatic from "chromatic"
|
|
4
|
-
import { ChevronRightIcon } from "~components/Icon"
|
|
5
4
|
import { Button } from "~components/__actions__/v2"
|
|
5
|
+
import { Icon } from "~components/__future__/Icon"
|
|
6
6
|
import {
|
|
7
7
|
StickerSheet,
|
|
8
8
|
StickerSheetStory,
|
|
@@ -85,7 +85,13 @@ const StickerSheetTemplate: StickerSheetStory = {
|
|
|
85
85
|
>
|
|
86
86
|
<Button
|
|
87
87
|
label="Label"
|
|
88
|
-
icon={
|
|
88
|
+
icon={
|
|
89
|
+
<Icon
|
|
90
|
+
name="chevron_right"
|
|
91
|
+
isPresentational
|
|
92
|
+
shouldMirrorInRTL
|
|
93
|
+
/>
|
|
94
|
+
}
|
|
89
95
|
iconPosition="end"
|
|
90
96
|
/>
|
|
91
97
|
</EmptyStateWrapper>
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from "react"
|
|
2
2
|
import { Meta, StoryObj } from "@storybook/react"
|
|
3
|
-
import { ChevronRightIcon } from "~components/Icon"
|
|
4
3
|
import { Button } from "~components/__actions__/v2"
|
|
4
|
+
import { Icon } from "~components/__future__/Icon"
|
|
5
5
|
import { EmptyState } from "../index"
|
|
6
6
|
|
|
7
7
|
const meta = {
|
|
@@ -17,7 +17,9 @@ const meta = {
|
|
|
17
17
|
"Button (chevron right)": (
|
|
18
18
|
<Button
|
|
19
19
|
label="Label"
|
|
20
|
-
icon={
|
|
20
|
+
icon={
|
|
21
|
+
<Icon name="chevron_right" isPresentational shouldMirrorInRTL />
|
|
22
|
+
}
|
|
21
23
|
iconPosition="end"
|
|
22
24
|
/>
|
|
23
25
|
),
|
|
@@ -2,9 +2,9 @@ import React, { HTMLAttributes } from "react"
|
|
|
2
2
|
import { FormattedMessage, useIntl } from "@cultureamp/i18n-react-intl"
|
|
3
3
|
import classNames from "classnames"
|
|
4
4
|
import { BrandMoment } from "~components/BrandMoment"
|
|
5
|
-
import { ArrowRightIcon, EmailIcon } from "~components/Icon"
|
|
6
5
|
import { BrandMomentError } from "~components/Illustration"
|
|
7
6
|
import { Text } from "~components/Text"
|
|
7
|
+
import { Icon } from "~components/__future__/Icon"
|
|
8
8
|
import { OverrideClassName } from "~components/types/OverrideClassName"
|
|
9
9
|
import { ErrorStatuses, useErrorMessages } from "./hooks"
|
|
10
10
|
import styles from "./ErrorPage.module.scss"
|
|
@@ -67,7 +67,9 @@ export const ErrorPage = ({
|
|
|
67
67
|
variant="warning"
|
|
68
68
|
primaryAction={{
|
|
69
69
|
...actions.primary,
|
|
70
|
-
icon:
|
|
70
|
+
icon: (
|
|
71
|
+
<Icon name="arrow_forward" isPresentational shouldMirrorInRTL />
|
|
72
|
+
),
|
|
71
73
|
iconPosition: "end",
|
|
72
74
|
label: formatMessage({
|
|
73
75
|
id: "kzErrorPage.goToHome",
|
|
@@ -77,7 +79,7 @@ export const ErrorPage = ({
|
|
|
77
79
|
}}
|
|
78
80
|
secondaryAction={{
|
|
79
81
|
...actions.secondary,
|
|
80
|
-
icon: <
|
|
82
|
+
icon: <Icon name="mail" isPresentational isFilled />,
|
|
81
83
|
label: formatMessage({
|
|
82
84
|
id: "kzErrorPage",
|
|
83
85
|
defaultMessage: "Contact support",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React, { HTMLAttributes } from "react"
|
|
2
2
|
import classnames from "classnames"
|
|
3
|
-
import { CautionWhiteIcon, ExclamationWhiteIcon } from "~components/Icon"
|
|
4
3
|
import { Text } from "~components/Text"
|
|
4
|
+
import { Icon } from "~components/__future__/Icon"
|
|
5
5
|
import { OverrideClassName } from "~components/types/OverrideClassName"
|
|
6
6
|
import styles from "./FieldMessage.module.scss"
|
|
7
7
|
|
|
@@ -45,19 +45,11 @@ export const FieldMessage = ({
|
|
|
45
45
|
>
|
|
46
46
|
{(status === "error" || status === "caution") && (
|
|
47
47
|
<span className={styles.warningIcon}>
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
/>
|
|
54
|
-
) : (
|
|
55
|
-
<CautionWhiteIcon
|
|
56
|
-
role="img"
|
|
57
|
-
inheritSize={false}
|
|
58
|
-
aria-label={`${status} message`}
|
|
59
|
-
/>
|
|
60
|
-
)}
|
|
48
|
+
<Icon
|
|
49
|
+
name={status === "error" ? "error" : "warning"}
|
|
50
|
+
isFilled
|
|
51
|
+
alt={`${status} message`}
|
|
52
|
+
/>
|
|
61
53
|
</span>
|
|
62
54
|
)}
|
|
63
55
|
<div className={styles.message}>
|