carbon-react 119.10.0 → 119.10.2
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/esm/__internal__/character-count/character-count.component.js +6 -7
- package/esm/__internal__/character-count/character-count.style.js +7 -13
- package/esm/__internal__/checkable-input/checkable-input.component.js +31 -32
- package/esm/__internal__/checkable-input/checkable-input.style.js +9 -12
- package/esm/__internal__/checkable-input/hidden-checkable-input.component.js +13 -14
- package/esm/__internal__/field-help/field-help.component.js +11 -14
- package/esm/__internal__/field-help/field-help.style.js +5 -8
- package/esm/__internal__/fieldset/fieldset.component.js +32 -36
- package/esm/__internal__/fieldset/fieldset.style.js +11 -17
- package/esm/__internal__/focus-trap/focus-trap.component.js +10 -11
- package/esm/__internal__/form-field/form-field.component.js +31 -32
- package/esm/__internal__/form-field/form-field.style.js +4 -7
- package/esm/__internal__/form-spacing-provider/form-spacing-provider.component.js +8 -11
- package/esm/__internal__/full-screen-heading/full-screen-heading.style.js +4 -7
- package/esm/__internal__/input/input-presentation.component.js +15 -16
- package/esm/__internal__/input/input-presentation.style.js +36 -58
- package/esm/__internal__/input/input.component.js +22 -23
- package/esm/__internal__/input/input.style.js +12 -21
- package/esm/__internal__/input-behaviour/input-behaviour.component.js +3 -4
- package/esm/__internal__/input-behaviour/input-group-behaviour.component.js +4 -5
- package/esm/__internal__/input-icon-toggle/input-icon-toggle.component.js +22 -24
- package/esm/__internal__/input-icon-toggle/input-icon-toggle.style.js +14 -20
- package/esm/__internal__/label/label.component.js +34 -37
- package/esm/__internal__/label/label.style.js +20 -32
- package/esm/__internal__/popover/popover.component.js +10 -11
- package/esm/__internal__/popover/popover.style.js +6 -12
- package/esm/__internal__/radio-button-mapper/radio-button-mapper.component.js +9 -10
- package/esm/__internal__/sticky-footer/sticky-footer.component.js +6 -7
- package/esm/__internal__/sticky-footer/sticky-footer.style.js +4 -7
- package/esm/__internal__/tooltip-provider/index.js +9 -10
- package/esm/__internal__/validation-message/validation-message.component.js +5 -6
- package/esm/__internal__/validation-message/validation-message.style.js +4 -7
- package/esm/__internal__/validations/validation-icon.component.js +21 -23
- package/esm/__internal__/validations/validation-icon.style.js +7 -13
- package/esm/__spec_helper__/test-utils.js +17 -26
- package/esm/components/accordion/accordion-group/accordion-group.component.js +4 -5
- package/esm/components/accordion/accordion.component.js +26 -27
- package/esm/components/accordion/accordion.style.js +52 -89
- package/esm/components/action-popover/action-popover-item/action-popover-item.component.js +20 -21
- package/esm/components/action-popover/action-popover-menu/action-popover-menu.component.js +13 -14
- package/esm/components/action-popover/action-popover-menu-button/action-popover-menu-button.component.js +13 -16
- package/esm/components/action-popover/action-popover.component.js +15 -17
- package/esm/components/action-popover/action-popover.style.js +45 -69
- package/esm/components/advanced-color-picker/advanced-color-picker-cell.style.js +8 -14
- package/esm/components/advanced-color-picker/advanced-color-picker.component.js +30 -35
- package/esm/components/advanced-color-picker/advanced-color-picker.style.js +8 -14
- package/esm/components/alert/alert.component.js +9 -12
- package/esm/components/anchor-navigation/anchor-navigation-item/anchor-navigation-item.component.js +17 -20
- package/esm/components/anchor-navigation/anchor-navigation-item/anchor-navigation-item.style.js +8 -14
- package/esm/components/anchor-navigation/anchor-navigation.component.js +7 -11
- package/esm/components/badge/badge.component.js +6 -7
- package/esm/components/badge/badge.style.js +9 -15
- package/esm/components/batch-selection/batch-selection.component.js +7 -8
- package/esm/components/batch-selection/batch-selection.style.js +6 -9
- package/esm/components/box/box.component.js +39 -60
- package/esm/components/breadcrumbs/breadcrumbs.component.js +4 -5
- package/esm/components/breadcrumbs/crumb/crumb.component.js +14 -17
- package/esm/components/breadcrumbs/crumb/crumb.style.js +4 -7
- package/esm/components/button/button.component.js +36 -38
- package/esm/components/button/button.style.js +22 -32
- package/esm/components/button-bar/button-bar.component.js +17 -20
- package/esm/components/button-bar/button-bar.style.js +5 -8
- package/esm/components/button-minor/button-minor.component.js +7 -8
- package/esm/components/button-minor/button-minor.style.js +19 -31
- package/esm/components/button-toggle/button-toggle-group/button-toggle-group.component.js +24 -25
- package/esm/components/button-toggle/button-toggle-group/button-toggle-group.style.js +12 -21
- package/esm/components/button-toggle/button-toggle-icon.component.js +15 -18
- package/esm/components/button-toggle/button-toggle.component.js +20 -21
- package/esm/components/button-toggle/button-toggle.style.js +33 -57
- package/esm/components/carbon-provider/carbon-provider.component.js +6 -7
- package/esm/components/carbon-provider/top-modal-context.js +3 -4
- package/esm/components/card/card-column/card-column.component.js +7 -10
- package/esm/components/card/card-column/card-column.style.js +3 -6
- package/esm/components/card/card-footer/card-footer.component.js +6 -7
- package/esm/components/card/card-footer/card-footer.style.js +6 -9
- package/esm/components/card/card-row/card-row.component.js +5 -6
- package/esm/components/card/card-row/card-row.style.js +4 -7
- package/esm/components/card/card.component.js +16 -17
- package/esm/components/card/card.style.js +11 -14
- package/esm/components/carousel/carousel.component.js +11 -12
- package/esm/components/carousel/carousel.style.js +8 -14
- package/esm/components/carousel/slide/slide.style.js +4 -7
- package/esm/components/checkbox/checkbox-group.style.js +8 -14
- package/esm/components/checkbox/checkbox.component.js +35 -36
- package/esm/components/checkbox/checkbox.style.js +14 -17
- package/esm/components/confirm/confirm.component.js +28 -29
- package/esm/components/confirm/confirm.style.js +8 -14
- package/esm/components/content/content.component.js +10 -11
- package/esm/components/content/content.style.js +17 -22
- package/esm/components/date/__internal__/date-formats/index.js +7 -9
- package/esm/components/date/__internal__/date-picker/date-picker.component.js +11 -12
- package/esm/components/date/__internal__/date-picker/day-picker.style.js +3 -6
- package/esm/components/date/__internal__/navbar/navbar.component.js +15 -18
- package/esm/components/date/__internal__/utils.js +1 -3
- package/esm/components/date/__internal__/weekday/weekday.component.js +11 -14
- package/esm/components/date/date.component.js +30 -31
- package/esm/components/date/date.style.js +12 -18
- package/esm/components/date-range/date-range.component.js +15 -16
- package/esm/components/date-range/date-range.style.js +3 -6
- package/esm/components/decimal/decimal.component.js +18 -19
- package/esm/components/definition-list/dd.component.js +4 -5
- package/esm/components/definition-list/definition-list.style.js +13 -22
- package/esm/components/definition-list/dl.component.js +8 -9
- package/esm/components/definition-list/dt.component.js +4 -5
- package/esm/components/detail/detail.component.js +18 -21
- package/esm/components/detail/detail.style.js +8 -14
- package/esm/components/dialog/dialog.component.js +22 -23
- package/esm/components/dialog/dialog.style.js +28 -52
- package/esm/components/dialog-full-screen/content.style.js +12 -21
- package/esm/components/dialog-full-screen/dialog-full-screen.component.js +24 -25
- package/esm/components/dialog-full-screen/dialog-full-screen.style.js +7 -13
- package/esm/components/dismissible-box/dismissible-box.component.js +19 -22
- package/esm/components/dismissible-box/dismissible-box.style.js +5 -8
- package/esm/components/draggable/draggable-container.component.js +5 -6
- package/esm/components/draggable/draggable-item.component.js +8 -9
- package/esm/components/draggable/draggable-item.style.js +3 -6
- package/esm/components/draggable/internal/drop-target.component.js +5 -6
- package/esm/components/drawer/drawer.component.js +17 -18
- package/esm/components/drawer/drawer.style.js +40 -70
- package/esm/components/duelling-picklist/duelling-picklist.component.js +9 -10
- package/esm/components/duelling-picklist/duelling-picklist.style.js +4 -7
- package/esm/components/duelling-picklist/picklist/picklist.component.js +6 -7
- package/esm/components/duelling-picklist/picklist-group/picklist-group.component.js +10 -11
- package/esm/components/duelling-picklist/picklist-group/picklist-group.style.js +9 -15
- package/esm/components/duelling-picklist/picklist-item/picklist-item.component.js +14 -15
- package/esm/components/duelling-picklist/picklist-item/picklist-item.style.js +8 -14
- package/esm/components/duelling-picklist/picklist-placeholder/picklist-placeholder.component.js +5 -8
- package/esm/components/fieldset/fieldset.component.js +6 -7
- package/esm/components/fieldset/fieldset.style.js +7 -13
- package/esm/components/flat-table/flat-table-body/flat-table-body.component.js +4 -5
- package/esm/components/flat-table/flat-table-body-draggable/flat-table-body-draggable.component.js +10 -12
- package/esm/components/flat-table/flat-table-body-draggable/flat-table-body-draggable.style.js +4 -7
- package/esm/components/flat-table/flat-table-cell/flat-table-cell.component.js +18 -19
- package/esm/components/flat-table/flat-table-cell/flat-table-cell.style.js +18 -24
- package/esm/components/flat-table/flat-table-checkbox/flat-table-checkbox.component.js +13 -14
- package/esm/components/flat-table/flat-table-checkbox/flat-table-checkbox.style.js +7 -10
- package/esm/components/flat-table/flat-table-head/flat-table-head.component.js +4 -5
- package/esm/components/flat-table/flat-table-header/flat-table-header.component.js +14 -15
- package/esm/components/flat-table/flat-table-header/flat-table-header.style.js +13 -16
- package/esm/components/flat-table/flat-table-row/__internal__/flat-table-row-draggable.component.js +6 -7
- package/esm/components/flat-table/flat-table-row/flat-table-row.component.js +22 -23
- package/esm/components/flat-table/flat-table-row/flat-table-row.style.js +25 -26
- package/esm/components/flat-table/flat-table-row-header/flat-table-row-header.component.js +18 -19
- package/esm/components/flat-table/flat-table-row-header/flat-table-row-header.style.js +17 -23
- package/esm/components/flat-table/flat-table.component.js +17 -18
- package/esm/components/flat-table/flat-table.style.js +67 -111
- package/esm/components/flat-table/sort/sort.component.js +5 -6
- package/esm/components/form/__internal__/form-summary.component.js +9 -11
- package/esm/components/form/__internal__/form-summary.style.js +24 -42
- package/esm/components/form/form.component.js +17 -18
- package/esm/components/form/form.style.js +37 -64
- package/esm/components/global-header/global-header.component.js +5 -6
- package/esm/components/grid/grid-item/grid-item.style.js +16 -19
- package/esm/components/grouped-character/grouped-character.component.js +13 -15
- package/esm/components/heading/heading.component.js +16 -17
- package/esm/components/heading/heading.style.js +18 -30
- package/esm/components/help/help.component.js +17 -18
- package/esm/components/help/help.style.js +4 -7
- package/esm/components/hr/hr.component.js +6 -7
- package/esm/components/i18n-provider/i18n-provider.component.js +6 -9
- package/esm/components/icon/icon.component.js +26 -27
- package/esm/components/icon/icon.style.js +12 -13
- package/esm/components/icon-button/icon-button.component.js +8 -9
- package/esm/components/icon-button/icon-button.style.js +4 -7
- package/esm/components/image/image.component.js +7 -8
- package/esm/components/image/image.style.js +16 -22
- package/esm/components/inline-inputs/inline-inputs.component.js +14 -15
- package/esm/components/inline-inputs/inline-inputs.style.js +20 -38
- package/esm/components/link/link.component.js +22 -24
- package/esm/components/link/link.style.js +10 -11
- package/esm/components/link-preview/__internal__/placeholder.component.js +9 -18
- package/esm/components/link-preview/link-preview.component.js +10 -11
- package/esm/components/link-preview/link-preview.style.js +8 -14
- package/esm/components/loader/loader-square.style.js +7 -10
- package/esm/components/loader/loader.component.js +7 -8
- package/esm/components/loader/loader.config.d.ts +1 -1
- package/esm/components/loader-bar/loader-bar.component.js +4 -5
- package/esm/components/loader-bar/loader-bar.style.js +8 -14
- package/esm/components/menu/__internal__/spec-helper/index.js +1 -2
- package/esm/components/menu/__internal__/submenu/submenu.component.js +18 -19
- package/esm/components/menu/__internal__/submenu/submenu.style.js +20 -29
- package/esm/components/menu/menu-divider/menu-divider.component.js +4 -5
- package/esm/components/menu/menu-divider/menu-divider.style.js +5 -8
- package/esm/components/menu/menu-full-screen/menu-full-screen.component.js +7 -8
- package/esm/components/menu/menu-full-screen/menu-full-screen.style.js +11 -17
- package/esm/components/menu/menu-item/menu-item.component.js +22 -23
- package/esm/components/menu/menu-item/menu-item.style.js +17 -20
- package/esm/components/menu/menu-segment-title/menu-segment-title.component.js +5 -6
- package/esm/components/menu/menu-segment-title/menu-segment-title.style.js +5 -8
- package/esm/components/menu/menu.component.js +5 -6
- package/esm/components/menu/menu.style.js +12 -21
- package/esm/components/menu/scrollable-block/scrollable-block.component.js +8 -9
- package/esm/components/menu/scrollable-block/scrollable-block.style.js +5 -8
- package/esm/components/message/message-content/message-content.component.js +5 -6
- package/esm/components/message/message-content/message-content.style.js +3 -6
- package/esm/components/message/message.component.js +13 -14
- package/esm/components/message/message.style.js +7 -13
- package/esm/components/message/type-icon/type-icon.component.js +4 -5
- package/esm/components/message/type-icon/type-icon.style.js +8 -14
- package/esm/components/modal/__internal__/modal-manager.js +4 -8
- package/esm/components/modal/modal.component.js +10 -11
- package/esm/components/modal/modal.style.js +13 -22
- package/esm/components/multi-action-button/multi-action-button.component.js +14 -15
- package/esm/components/multi-action-button/multi-action-button.style.js +16 -25
- package/esm/components/navigation-bar/fixed-navigation-bar.context.js +7 -8
- package/esm/components/navigation-bar/navigation-bar.component.js +11 -12
- package/esm/components/navigation-bar/navigation-bar.style.js +12 -18
- package/esm/components/note/__internal__/status-icon/status-icon.component.js +4 -5
- package/esm/components/note/note.component.js +12 -13
- package/esm/components/note/note.style.js +19 -34
- package/esm/components/number/number.component.js +7 -8
- package/esm/components/numeral-date/numeral-date.component.js +36 -37
- package/esm/components/numeral-date/numeral-date.style.js +7 -8
- package/esm/components/pager/__internal__/pager-navigation-link.component.js +9 -10
- package/esm/components/pager/__internal__/pager-navigation.component.js +16 -17
- package/esm/components/pager/pager.component.js +41 -39
- package/esm/components/pager/pager.style.js +8 -14
- package/esm/components/pages/page/page.component.js +6 -7
- package/esm/components/pages/pages.component.js +7 -8
- package/esm/components/password/password.component.js +6 -7
- package/esm/components/pill/pill.component.js +31 -34
- package/esm/components/pill/pill.style.js +11 -12
- package/esm/components/pod/pod.component.js +23 -24
- package/esm/components/pod/pod.style.js +65 -95
- package/esm/components/popover-container/popover-container.component.js +57 -67
- package/esm/components/popover-container/popover-container.style.js +6 -10
- package/esm/components/portal/portal.js +6 -7
- package/esm/components/portrait/portrait-gravatar.component.js +7 -8
- package/esm/components/portrait/portrait-initials.component.js +7 -8
- package/esm/components/portrait/portrait.component.js +20 -21
- package/esm/components/portrait/portrait.style.js +17 -26
- package/esm/components/preview/__internal__/preview-placeholder.component.js +7 -8
- package/esm/components/preview/__internal__/preview-placeholder.style.js +6 -12
- package/esm/components/preview/preview.component.js +6 -7
- package/esm/components/profile/profile.component.js +9 -10
- package/esm/components/profile/profile.style.js +19 -37
- package/esm/components/progress-tracker/progress-tracker.component.js +19 -20
- package/esm/components/progress-tracker/progress-tracker.style.js +42 -62
- package/esm/components/radio-button/radio-button-group.style.js +5 -8
- package/esm/components/radio-button/radio-button.component.js +33 -34
- package/esm/components/radio-button/radio-button.style.js +8 -11
- package/esm/components/search/search-button.style.js +3 -6
- package/esm/components/search/search.component.js +26 -27
- package/esm/components/search/search.style.js +10 -11
- package/esm/components/select/__internal__/select-text/select-text.component.d.ts +1 -4
- package/esm/components/select/__internal__/select-text/select-text.component.js +10 -17
- package/esm/components/select/__internal__/select-text/select-text.style.js +8 -11
- package/esm/components/select/filterable-select/filterable-select.component.js +40 -42
- package/esm/components/select/list-action-button/list-action-button.component.js +4 -5
- package/esm/components/select/multi-select/multi-select.component.js +39 -40
- package/esm/components/select/multi-select/multi-select.style.js +6 -12
- package/esm/components/select/option/option.component.d.ts +2 -2
- package/esm/components/select/option/option.component.js +12 -13
- package/esm/components/select/option/option.style.js +7 -13
- package/esm/components/select/option-group-header/option-group-header.component.js +6 -7
- package/esm/components/select/option-row/option-row.component.js +11 -12
- package/esm/components/select/option-row/option-row.style.js +7 -13
- package/esm/components/select/select-list/select-list-container.style.js +9 -18
- package/esm/components/select/select-list/select-list.component.js +30 -32
- package/esm/components/select/select-list/select-list.style.js +10 -19
- package/esm/components/select/select-textbox/select-textbox.component.js +66 -98
- package/esm/components/select/select.style.js +9 -12
- package/esm/components/select/simple-select/simple-select.component.js +36 -37
- package/esm/components/select/utils/get-next-child-by-text.js +1 -2
- package/esm/components/select/utils/with-filter.hoc.js +9 -10
- package/esm/components/settings-row/settings-row.component.js +9 -10
- package/esm/components/settings-row/settings-row.style.js +4 -7
- package/esm/components/show-edit-pod/show-edit-pod.component.js +24 -25
- package/esm/components/sidebar/__internal__/sidebar-header/sidebar-header.component.js +11 -14
- package/esm/components/sidebar/__internal__/sidebar-header/sidebar-header.style.js +4 -7
- package/esm/components/sidebar/sidebar.component.js +22 -23
- package/esm/components/sidebar/sidebar.style.js +10 -13
- package/esm/components/simple-color-picker/simple-color/simple-color.style.js +11 -20
- package/esm/components/simple-color-picker/simple-color-picker.component.js +17 -20
- package/esm/components/simple-color-picker/simple-color-picker.style.js +9 -13
- package/esm/components/split-button/split-button-children.style.js +6 -9
- package/esm/components/split-button/split-button-toggle.style.js +7 -10
- package/esm/components/split-button/split-button.component.js +15 -16
- package/esm/components/step-sequence/step-sequence-item/step-sequence-item.component.js +10 -11
- package/esm/components/step-sequence/step-sequence-item/step-sequence-item.style.js +4 -5
- package/esm/components/step-sequence/step-sequence.component.js +5 -6
- package/esm/components/step-sequence/step-sequence.style.js +4 -7
- package/esm/components/switch/__internal__/switch-slider-panel.style.js +5 -8
- package/esm/components/switch/__internal__/switch-slider.component.js +10 -11
- package/esm/components/switch/__internal__/switch-slider.style.js +10 -13
- package/esm/components/switch/switch.component.js +32 -33
- package/esm/components/switch/switch.style.js +11 -17
- package/esm/components/tabs/__internal__/tab-title/tab-title.component.js +28 -29
- package/esm/components/tabs/__internal__/tab-title/tab-title.style.js +50 -68
- package/esm/components/tabs/__internal__/tabs-header/tabs-header.component.js +14 -18
- package/esm/components/tabs/__internal__/tabs-header/tabs-header.style.js +31 -52
- package/esm/components/tabs/tab/tab.component.js +20 -21
- package/esm/components/tabs/tab/tab.style.js +5 -8
- package/esm/components/tabs/tabs.component.js +18 -20
- package/esm/components/tabs/tabs.style.js +6 -9
- package/esm/components/text-editor/__internal__/decorators/link-decorator.js +1 -6
- package/esm/components/text-editor/__internal__/editor-counter/editor-counter.component.js +17 -20
- package/esm/components/text-editor/__internal__/editor-counter/editor-counter.style.js +3 -6
- package/esm/components/text-editor/__internal__/editor-link/editor-link.component.js +6 -7
- package/esm/components/text-editor/__internal__/label-wrapper/label-wrapper.component.js +4 -5
- package/esm/components/text-editor/__internal__/toolbar/toolbar-button/toolbar-button.component.js +12 -13
- package/esm/components/text-editor/__internal__/toolbar/toolbar-button/toolbar-button.style.js +4 -7
- package/esm/components/text-editor/__internal__/toolbar/toolbar.component.js +7 -8
- package/esm/components/text-editor/__internal__/utils/utils.js +2 -4
- package/esm/components/text-editor/text-editor.component.js +15 -16
- package/esm/components/text-editor/text-editor.style.js +11 -17
- package/esm/components/textarea/textarea.component.js +41 -42
- package/esm/components/textarea/textarea.style.js +7 -13
- package/esm/components/textbox/__internal__/prefix.style.js +3 -6
- package/esm/components/textbox/textbox.component.js +55 -56
- package/esm/components/textbox/textbox.style.js +5 -8
- package/esm/components/tile/tile-footer/tile-footer.component.js +5 -6
- package/esm/components/tile/tile-footer/tile-footer.style.js +4 -7
- package/esm/components/tile/tile.component.js +9 -10
- package/esm/components/tile/tile.style.js +19 -25
- package/esm/components/tile-select/__internal__/accordion/accordion.component.js +6 -7
- package/esm/components/tile-select/tile-select-group.component.js +11 -12
- package/esm/components/tile-select/tile-select.component.js +25 -26
- package/esm/components/tile-select/tile-select.style.js +36 -63
- package/esm/components/toast/toast.component.js +14 -15
- package/esm/components/toast/toast.style.js +37 -61
- package/esm/components/tooltip/tooltip-pointer.style.js +6 -9
- package/esm/components/tooltip/tooltip.component.js +28 -37
- package/esm/components/tooltip/tooltip.style.js +8 -11
- package/esm/components/typography/list.component.js +17 -23
- package/esm/components/typography/typography.component.js +36 -43
- package/esm/components/vertical-divider/vertical-divider.component.js +7 -8
- package/esm/components/vertical-divider/vertical-divider.style.js +11 -20
- package/esm/components/vertical-menu/vertical-menu-full-screen.component.js +8 -9
- package/esm/components/vertical-menu/vertical-menu-item.component.js +12 -13
- package/esm/components/vertical-menu/vertical-menu-trigger.component.js +7 -8
- package/esm/components/vertical-menu/vertical-menu.component.js +8 -9
- package/esm/components/vertical-menu/vertical-menu.style.js +10 -19
- package/esm/hooks/__internal__/useCharacterCount/useCharacterCount.js +1 -4
- package/esm/hooks/__internal__/useChildButtons/useChildButtons.js +1 -2
- package/esm/hooks/__internal__/useClickAwayListener/useClickAwayListener.js +1 -2
- package/esm/hooks/__internal__/useFloating/useFloating.js +14 -16
- package/esm/hooks/__internal__/useInputAccessibility/useInputAccessibility.js +9 -10
- package/esm/hooks/__internal__/useModalAria/useModalAria.js +5 -6
- package/esm/hooks/__internal__/useModalManager/useModalManager.js +7 -8
- package/esm/hooks/__internal__/useScrollBlock/useScrollBlock.js +17 -23
- package/esm/hooks/__internal__/useStableCallback/useStableCallback.js +1 -6
- package/esm/locales/en-gb.js +1 -2
- package/esm/locales/pl-pl.js +1 -2
- package/esm/style/design-tokens/carbon-scoped-tokens-provider/carbon-scoped-tokens-provider.component.js +3 -6
- package/esm/style/design-tokens/debug-theme.util.js +1 -2
- package/esm/style/design-tokens/generate-css-variables.util.js +1 -2
- package/esm/style/palette/index.js +7 -10
- package/esm/style/utils/color.js +6 -7
- package/esm/style/utils/filter-out-styled-system-spacing-props.js +1 -4
- package/esm/style/utils/form-style-utils.js +1 -2
- package/esm/style/utils/merge-deep.js +2 -8
- package/esm/style/utils/mix.js +2 -6
- package/esm/style/utils/width.js +5 -8
- package/lib/__internal__/character-count/character-count.component.js +6 -7
- package/lib/__internal__/character-count/character-count.style.js +7 -13
- package/lib/__internal__/checkable-input/checkable-input.component.js +31 -32
- package/lib/__internal__/checkable-input/checkable-input.style.js +9 -12
- package/lib/__internal__/checkable-input/hidden-checkable-input.component.js +13 -14
- package/lib/__internal__/field-help/field-help.component.js +11 -14
- package/lib/__internal__/field-help/field-help.style.js +5 -8
- package/lib/__internal__/fieldset/fieldset.component.js +32 -36
- package/lib/__internal__/fieldset/fieldset.style.js +11 -17
- package/lib/__internal__/focus-trap/focus-trap.component.js +10 -11
- package/lib/__internal__/form-field/form-field.component.js +31 -32
- package/lib/__internal__/form-field/form-field.style.js +4 -7
- package/lib/__internal__/form-spacing-provider/form-spacing-provider.component.js +8 -11
- package/lib/__internal__/full-screen-heading/full-screen-heading.style.js +4 -7
- package/lib/__internal__/input/input-presentation.component.js +15 -16
- package/lib/__internal__/input/input-presentation.style.js +36 -58
- package/lib/__internal__/input/input.component.js +22 -23
- package/lib/__internal__/input/input.style.js +12 -21
- package/lib/__internal__/input-behaviour/input-behaviour.component.js +3 -4
- package/lib/__internal__/input-behaviour/input-group-behaviour.component.js +4 -5
- package/lib/__internal__/input-icon-toggle/input-icon-toggle.component.js +22 -24
- package/lib/__internal__/input-icon-toggle/input-icon-toggle.style.js +14 -20
- package/lib/__internal__/label/label.component.js +34 -37
- package/lib/__internal__/label/label.style.js +20 -32
- package/lib/__internal__/popover/popover.component.js +10 -11
- package/lib/__internal__/popover/popover.style.js +6 -12
- package/lib/__internal__/radio-button-mapper/radio-button-mapper.component.js +9 -10
- package/lib/__internal__/sticky-footer/sticky-footer.component.js +6 -7
- package/lib/__internal__/sticky-footer/sticky-footer.style.js +4 -7
- package/lib/__internal__/tooltip-provider/index.js +9 -10
- package/lib/__internal__/validation-message/validation-message.component.js +5 -6
- package/lib/__internal__/validation-message/validation-message.style.js +4 -7
- package/lib/__internal__/validations/validation-icon.component.js +21 -23
- package/lib/__internal__/validations/validation-icon.style.js +7 -13
- package/lib/__spec_helper__/test-utils.js +17 -26
- package/lib/components/accordion/accordion-group/accordion-group.component.js +4 -5
- package/lib/components/accordion/accordion.component.js +26 -27
- package/lib/components/accordion/accordion.style.js +52 -89
- package/lib/components/action-popover/action-popover-item/action-popover-item.component.js +20 -21
- package/lib/components/action-popover/action-popover-menu/action-popover-menu.component.js +13 -14
- package/lib/components/action-popover/action-popover-menu-button/action-popover-menu-button.component.js +13 -16
- package/lib/components/action-popover/action-popover.component.js +15 -17
- package/lib/components/action-popover/action-popover.style.js +45 -69
- package/lib/components/advanced-color-picker/advanced-color-picker-cell.style.js +8 -14
- package/lib/components/advanced-color-picker/advanced-color-picker.component.js +30 -35
- package/lib/components/advanced-color-picker/advanced-color-picker.style.js +8 -14
- package/lib/components/alert/alert.component.js +9 -12
- package/lib/components/anchor-navigation/anchor-navigation-item/anchor-navigation-item.component.js +17 -20
- package/lib/components/anchor-navigation/anchor-navigation-item/anchor-navigation-item.style.js +8 -14
- package/lib/components/anchor-navigation/anchor-navigation.component.js +7 -11
- package/lib/components/badge/badge.component.js +6 -7
- package/lib/components/badge/badge.style.js +9 -15
- package/lib/components/batch-selection/batch-selection.component.js +7 -8
- package/lib/components/batch-selection/batch-selection.style.js +6 -9
- package/lib/components/box/box.component.js +39 -60
- package/lib/components/breadcrumbs/breadcrumbs.component.js +4 -5
- package/lib/components/breadcrumbs/crumb/crumb.component.js +14 -17
- package/lib/components/breadcrumbs/crumb/crumb.style.js +4 -7
- package/lib/components/button/button.component.js +36 -38
- package/lib/components/button/button.style.js +22 -32
- package/lib/components/button-bar/button-bar.component.js +17 -20
- package/lib/components/button-bar/button-bar.style.js +5 -8
- package/lib/components/button-minor/button-minor.component.js +7 -8
- package/lib/components/button-minor/button-minor.style.js +19 -31
- package/lib/components/button-toggle/button-toggle-group/button-toggle-group.component.js +24 -25
- package/lib/components/button-toggle/button-toggle-group/button-toggle-group.style.js +12 -21
- package/lib/components/button-toggle/button-toggle-icon.component.js +15 -18
- package/lib/components/button-toggle/button-toggle.component.js +20 -21
- package/lib/components/button-toggle/button-toggle.style.js +33 -57
- package/lib/components/carbon-provider/carbon-provider.component.js +6 -7
- package/lib/components/carbon-provider/top-modal-context.js +3 -4
- package/lib/components/card/card-column/card-column.component.js +7 -10
- package/lib/components/card/card-column/card-column.style.js +3 -6
- package/lib/components/card/card-footer/card-footer.component.js +6 -7
- package/lib/components/card/card-footer/card-footer.style.js +6 -9
- package/lib/components/card/card-row/card-row.component.js +5 -6
- package/lib/components/card/card-row/card-row.style.js +4 -7
- package/lib/components/card/card.component.js +16 -17
- package/lib/components/card/card.style.js +11 -14
- package/lib/components/carousel/carousel.component.js +11 -12
- package/lib/components/carousel/carousel.style.js +8 -14
- package/lib/components/carousel/slide/slide.style.js +4 -7
- package/lib/components/checkbox/checkbox-group.style.js +8 -14
- package/lib/components/checkbox/checkbox.component.js +35 -36
- package/lib/components/checkbox/checkbox.style.js +14 -17
- package/lib/components/confirm/confirm.component.js +28 -29
- package/lib/components/confirm/confirm.style.js +8 -14
- package/lib/components/content/content.component.js +10 -11
- package/lib/components/content/content.style.js +17 -22
- package/lib/components/date/__internal__/date-formats/index.js +7 -9
- package/lib/components/date/__internal__/date-picker/date-picker.component.js +11 -12
- package/lib/components/date/__internal__/date-picker/day-picker.style.js +3 -6
- package/lib/components/date/__internal__/navbar/navbar.component.js +15 -18
- package/lib/components/date/__internal__/utils.js +1 -3
- package/lib/components/date/__internal__/weekday/weekday.component.js +11 -14
- package/lib/components/date/date.component.js +30 -31
- package/lib/components/date/date.style.js +12 -18
- package/lib/components/date-range/date-range.component.js +15 -16
- package/lib/components/date-range/date-range.style.js +3 -6
- package/lib/components/decimal/decimal.component.js +18 -19
- package/lib/components/definition-list/dd.component.js +4 -5
- package/lib/components/definition-list/definition-list.style.js +13 -22
- package/lib/components/definition-list/dl.component.js +8 -9
- package/lib/components/definition-list/dt.component.js +4 -5
- package/lib/components/detail/detail.component.js +18 -21
- package/lib/components/detail/detail.style.js +8 -14
- package/lib/components/dialog/dialog.component.js +22 -23
- package/lib/components/dialog/dialog.style.js +28 -52
- package/lib/components/dialog-full-screen/content.style.js +12 -21
- package/lib/components/dialog-full-screen/dialog-full-screen.component.js +24 -25
- package/lib/components/dialog-full-screen/dialog-full-screen.style.js +7 -13
- package/lib/components/dismissible-box/dismissible-box.component.js +19 -22
- package/lib/components/dismissible-box/dismissible-box.style.js +5 -8
- package/lib/components/draggable/draggable-container.component.js +5 -6
- package/lib/components/draggable/draggable-item.component.js +8 -9
- package/lib/components/draggable/draggable-item.style.js +3 -6
- package/lib/components/draggable/internal/drop-target.component.js +5 -6
- package/lib/components/drawer/drawer.component.js +17 -18
- package/lib/components/drawer/drawer.style.js +40 -70
- package/lib/components/duelling-picklist/duelling-picklist.component.js +9 -10
- package/lib/components/duelling-picklist/duelling-picklist.style.js +4 -7
- package/lib/components/duelling-picklist/picklist/picklist.component.js +6 -7
- package/lib/components/duelling-picklist/picklist-group/picklist-group.component.js +10 -11
- package/lib/components/duelling-picklist/picklist-group/picklist-group.style.js +9 -15
- package/lib/components/duelling-picklist/picklist-item/picklist-item.component.js +14 -15
- package/lib/components/duelling-picklist/picklist-item/picklist-item.style.js +8 -14
- package/lib/components/duelling-picklist/picklist-placeholder/picklist-placeholder.component.js +5 -8
- package/lib/components/fieldset/fieldset.component.js +6 -7
- package/lib/components/fieldset/fieldset.style.js +7 -13
- package/lib/components/flat-table/flat-table-body/flat-table-body.component.js +4 -5
- package/lib/components/flat-table/flat-table-body-draggable/flat-table-body-draggable.component.js +10 -12
- package/lib/components/flat-table/flat-table-body-draggable/flat-table-body-draggable.style.js +4 -7
- package/lib/components/flat-table/flat-table-cell/flat-table-cell.component.js +18 -19
- package/lib/components/flat-table/flat-table-cell/flat-table-cell.style.js +18 -24
- package/lib/components/flat-table/flat-table-checkbox/flat-table-checkbox.component.js +13 -14
- package/lib/components/flat-table/flat-table-checkbox/flat-table-checkbox.style.js +7 -10
- package/lib/components/flat-table/flat-table-head/flat-table-head.component.js +4 -5
- package/lib/components/flat-table/flat-table-header/flat-table-header.component.js +14 -15
- package/lib/components/flat-table/flat-table-header/flat-table-header.style.js +13 -16
- package/lib/components/flat-table/flat-table-row/__internal__/flat-table-row-draggable.component.js +6 -7
- package/lib/components/flat-table/flat-table-row/flat-table-row.component.js +22 -23
- package/lib/components/flat-table/flat-table-row/flat-table-row.style.js +25 -26
- package/lib/components/flat-table/flat-table-row-header/flat-table-row-header.component.js +18 -19
- package/lib/components/flat-table/flat-table-row-header/flat-table-row-header.style.js +17 -23
- package/lib/components/flat-table/flat-table.component.js +17 -18
- package/lib/components/flat-table/flat-table.style.js +67 -111
- package/lib/components/flat-table/sort/sort.component.js +5 -6
- package/lib/components/form/__internal__/form-summary.component.js +9 -11
- package/lib/components/form/__internal__/form-summary.style.js +24 -42
- package/lib/components/form/form.component.js +17 -18
- package/lib/components/form/form.style.js +37 -64
- package/lib/components/global-header/global-header.component.js +5 -6
- package/lib/components/grid/grid-item/grid-item.style.js +16 -19
- package/lib/components/grouped-character/grouped-character.component.js +13 -15
- package/lib/components/heading/heading.component.js +16 -17
- package/lib/components/heading/heading.style.js +18 -30
- package/lib/components/help/help.component.js +17 -18
- package/lib/components/help/help.style.js +4 -7
- package/lib/components/hr/hr.component.js +6 -7
- package/lib/components/i18n-provider/i18n-provider.component.js +6 -9
- package/lib/components/icon/icon.component.js +26 -27
- package/lib/components/icon/icon.style.js +12 -13
- package/lib/components/icon-button/icon-button.component.js +8 -9
- package/lib/components/icon-button/icon-button.style.js +4 -7
- package/lib/components/image/image.component.js +7 -8
- package/lib/components/image/image.style.js +16 -22
- package/lib/components/inline-inputs/inline-inputs.component.js +14 -15
- package/lib/components/inline-inputs/inline-inputs.style.js +20 -38
- package/lib/components/link/link.component.js +22 -24
- package/lib/components/link/link.style.js +10 -11
- package/lib/components/link-preview/__internal__/placeholder.component.js +9 -18
- package/lib/components/link-preview/link-preview.component.js +10 -11
- package/lib/components/link-preview/link-preview.style.js +8 -14
- package/lib/components/loader/loader-square.style.js +7 -10
- package/lib/components/loader/loader.component.js +7 -8
- package/lib/components/loader/loader.config.d.ts +1 -1
- package/lib/components/loader-bar/loader-bar.component.js +4 -5
- package/lib/components/loader-bar/loader-bar.style.js +8 -14
- package/lib/components/menu/__internal__/spec-helper/index.js +1 -2
- package/lib/components/menu/__internal__/submenu/submenu.component.js +18 -19
- package/lib/components/menu/__internal__/submenu/submenu.style.js +20 -29
- package/lib/components/menu/menu-divider/menu-divider.component.js +4 -5
- package/lib/components/menu/menu-divider/menu-divider.style.js +5 -8
- package/lib/components/menu/menu-full-screen/menu-full-screen.component.js +7 -8
- package/lib/components/menu/menu-full-screen/menu-full-screen.style.js +11 -17
- package/lib/components/menu/menu-item/menu-item.component.js +22 -23
- package/lib/components/menu/menu-item/menu-item.style.js +17 -20
- package/lib/components/menu/menu-segment-title/menu-segment-title.component.js +5 -6
- package/lib/components/menu/menu-segment-title/menu-segment-title.style.js +5 -8
- package/lib/components/menu/menu.component.js +5 -6
- package/lib/components/menu/menu.style.js +12 -21
- package/lib/components/menu/scrollable-block/scrollable-block.component.js +8 -9
- package/lib/components/menu/scrollable-block/scrollable-block.style.js +5 -8
- package/lib/components/message/message-content/message-content.component.js +5 -6
- package/lib/components/message/message-content/message-content.style.js +3 -6
- package/lib/components/message/message.component.js +13 -14
- package/lib/components/message/message.style.js +7 -13
- package/lib/components/message/type-icon/type-icon.component.js +4 -5
- package/lib/components/message/type-icon/type-icon.style.js +8 -14
- package/lib/components/modal/__internal__/modal-manager.js +4 -8
- package/lib/components/modal/modal.component.js +10 -11
- package/lib/components/modal/modal.style.js +13 -22
- package/lib/components/multi-action-button/multi-action-button.component.js +14 -15
- package/lib/components/multi-action-button/multi-action-button.style.js +16 -25
- package/lib/components/navigation-bar/fixed-navigation-bar.context.js +7 -8
- package/lib/components/navigation-bar/navigation-bar.component.js +11 -12
- package/lib/components/navigation-bar/navigation-bar.style.js +12 -18
- package/lib/components/note/__internal__/status-icon/status-icon.component.js +4 -5
- package/lib/components/note/note.component.js +12 -13
- package/lib/components/note/note.style.js +19 -34
- package/lib/components/number/number.component.js +7 -8
- package/lib/components/numeral-date/numeral-date.component.js +36 -37
- package/lib/components/numeral-date/numeral-date.style.js +7 -8
- package/lib/components/pager/__internal__/pager-navigation-link.component.js +9 -10
- package/lib/components/pager/__internal__/pager-navigation.component.js +16 -17
- package/lib/components/pager/pager.component.js +41 -39
- package/lib/components/pager/pager.style.js +8 -14
- package/lib/components/pages/page/page.component.js +6 -7
- package/lib/components/pages/pages.component.js +7 -8
- package/lib/components/password/password.component.js +6 -7
- package/lib/components/pill/pill.component.js +31 -34
- package/lib/components/pill/pill.style.js +11 -12
- package/lib/components/pod/pod.component.js +23 -24
- package/lib/components/pod/pod.style.js +65 -95
- package/lib/components/popover-container/popover-container.component.js +57 -67
- package/lib/components/popover-container/popover-container.style.js +6 -10
- package/lib/components/portal/portal.js +6 -7
- package/lib/components/portrait/portrait-gravatar.component.js +7 -8
- package/lib/components/portrait/portrait-initials.component.js +7 -8
- package/lib/components/portrait/portrait.component.js +20 -21
- package/lib/components/portrait/portrait.style.js +17 -26
- package/lib/components/preview/__internal__/preview-placeholder.component.js +7 -8
- package/lib/components/preview/__internal__/preview-placeholder.style.js +6 -12
- package/lib/components/preview/preview.component.js +6 -7
- package/lib/components/profile/profile.component.js +9 -10
- package/lib/components/profile/profile.style.js +19 -37
- package/lib/components/progress-tracker/progress-tracker.component.js +19 -20
- package/lib/components/progress-tracker/progress-tracker.style.js +42 -62
- package/lib/components/radio-button/radio-button-group.style.js +5 -8
- package/lib/components/radio-button/radio-button.component.js +33 -34
- package/lib/components/radio-button/radio-button.style.js +8 -11
- package/lib/components/search/search-button.style.js +3 -6
- package/lib/components/search/search.component.js +26 -27
- package/lib/components/search/search.style.js +10 -11
- package/lib/components/select/__internal__/select-text/select-text.component.d.ts +1 -4
- package/lib/components/select/__internal__/select-text/select-text.component.js +10 -17
- package/lib/components/select/__internal__/select-text/select-text.style.js +8 -11
- package/lib/components/select/filterable-select/filterable-select.component.js +40 -42
- package/lib/components/select/list-action-button/list-action-button.component.js +4 -5
- package/lib/components/select/multi-select/multi-select.component.js +39 -40
- package/lib/components/select/multi-select/multi-select.style.js +6 -12
- package/lib/components/select/option/option.component.d.ts +2 -2
- package/lib/components/select/option/option.component.js +12 -13
- package/lib/components/select/option/option.style.js +7 -13
- package/lib/components/select/option-group-header/option-group-header.component.js +6 -7
- package/lib/components/select/option-row/option-row.component.js +11 -12
- package/lib/components/select/option-row/option-row.style.js +7 -13
- package/lib/components/select/select-list/select-list-container.style.js +9 -18
- package/lib/components/select/select-list/select-list.component.js +30 -32
- package/lib/components/select/select-list/select-list.style.js +10 -19
- package/lib/components/select/select-textbox/select-textbox.component.js +65 -97
- package/lib/components/select/select.style.js +9 -12
- package/lib/components/select/simple-select/simple-select.component.js +36 -37
- package/lib/components/select/utils/get-next-child-by-text.js +1 -2
- package/lib/components/select/utils/with-filter.hoc.js +9 -10
- package/lib/components/settings-row/settings-row.component.js +9 -10
- package/lib/components/settings-row/settings-row.style.js +4 -7
- package/lib/components/show-edit-pod/show-edit-pod.component.js +24 -25
- package/lib/components/sidebar/__internal__/sidebar-header/sidebar-header.component.js +11 -14
- package/lib/components/sidebar/__internal__/sidebar-header/sidebar-header.style.js +4 -7
- package/lib/components/sidebar/sidebar.component.js +22 -23
- package/lib/components/sidebar/sidebar.style.js +10 -13
- package/lib/components/simple-color-picker/simple-color/simple-color.style.js +11 -20
- package/lib/components/simple-color-picker/simple-color-picker.component.js +17 -20
- package/lib/components/simple-color-picker/simple-color-picker.style.js +9 -13
- package/lib/components/split-button/split-button-children.style.js +6 -9
- package/lib/components/split-button/split-button-toggle.style.js +7 -10
- package/lib/components/split-button/split-button.component.js +15 -16
- package/lib/components/step-sequence/step-sequence-item/step-sequence-item.component.js +10 -11
- package/lib/components/step-sequence/step-sequence-item/step-sequence-item.style.js +4 -5
- package/lib/components/step-sequence/step-sequence.component.js +5 -6
- package/lib/components/step-sequence/step-sequence.style.js +4 -7
- package/lib/components/switch/__internal__/switch-slider-panel.style.js +5 -8
- package/lib/components/switch/__internal__/switch-slider.component.js +10 -11
- package/lib/components/switch/__internal__/switch-slider.style.js +10 -13
- package/lib/components/switch/switch.component.js +32 -33
- package/lib/components/switch/switch.style.js +11 -17
- package/lib/components/tabs/__internal__/tab-title/tab-title.component.js +28 -29
- package/lib/components/tabs/__internal__/tab-title/tab-title.style.js +50 -68
- package/lib/components/tabs/__internal__/tabs-header/tabs-header.component.js +14 -18
- package/lib/components/tabs/__internal__/tabs-header/tabs-header.style.js +31 -52
- package/lib/components/tabs/tab/tab.component.js +20 -21
- package/lib/components/tabs/tab/tab.style.js +5 -8
- package/lib/components/tabs/tabs.component.js +18 -20
- package/lib/components/tabs/tabs.style.js +6 -9
- package/lib/components/text-editor/__internal__/decorators/link-decorator.js +1 -6
- package/lib/components/text-editor/__internal__/editor-counter/editor-counter.component.js +17 -20
- package/lib/components/text-editor/__internal__/editor-counter/editor-counter.style.js +3 -6
- package/lib/components/text-editor/__internal__/editor-link/editor-link.component.js +6 -7
- package/lib/components/text-editor/__internal__/label-wrapper/label-wrapper.component.js +4 -5
- package/lib/components/text-editor/__internal__/toolbar/toolbar-button/toolbar-button.component.js +12 -13
- package/lib/components/text-editor/__internal__/toolbar/toolbar-button/toolbar-button.style.js +4 -7
- package/lib/components/text-editor/__internal__/toolbar/toolbar.component.js +7 -8
- package/lib/components/text-editor/__internal__/utils/utils.js +2 -4
- package/lib/components/text-editor/text-editor.component.js +15 -16
- package/lib/components/text-editor/text-editor.style.js +11 -17
- package/lib/components/textarea/textarea.component.js +41 -42
- package/lib/components/textarea/textarea.style.js +7 -13
- package/lib/components/textbox/__internal__/prefix.style.js +3 -6
- package/lib/components/textbox/textbox.component.js +55 -56
- package/lib/components/textbox/textbox.style.js +5 -8
- package/lib/components/tile/tile-footer/tile-footer.component.js +5 -6
- package/lib/components/tile/tile-footer/tile-footer.style.js +4 -7
- package/lib/components/tile/tile.component.js +9 -10
- package/lib/components/tile/tile.style.js +19 -25
- package/lib/components/tile-select/__internal__/accordion/accordion.component.js +6 -7
- package/lib/components/tile-select/tile-select-group.component.js +11 -12
- package/lib/components/tile-select/tile-select.component.js +25 -26
- package/lib/components/tile-select/tile-select.style.js +36 -63
- package/lib/components/toast/toast.component.js +14 -15
- package/lib/components/toast/toast.style.js +37 -61
- package/lib/components/tooltip/tooltip-pointer.style.js +6 -9
- package/lib/components/tooltip/tooltip.component.js +28 -37
- package/lib/components/tooltip/tooltip.style.js +8 -11
- package/lib/components/typography/list.component.js +17 -23
- package/lib/components/typography/typography.component.js +36 -43
- package/lib/components/vertical-divider/vertical-divider.component.js +7 -8
- package/lib/components/vertical-divider/vertical-divider.style.js +11 -20
- package/lib/components/vertical-menu/vertical-menu-full-screen.component.js +8 -9
- package/lib/components/vertical-menu/vertical-menu-item.component.js +12 -13
- package/lib/components/vertical-menu/vertical-menu-trigger.component.js +7 -8
- package/lib/components/vertical-menu/vertical-menu.component.js +8 -9
- package/lib/components/vertical-menu/vertical-menu.style.js +10 -19
- package/lib/hooks/__internal__/useCharacterCount/useCharacterCount.js +1 -4
- package/lib/hooks/__internal__/useChildButtons/useChildButtons.js +1 -2
- package/lib/hooks/__internal__/useClickAwayListener/useClickAwayListener.js +1 -2
- package/lib/hooks/__internal__/useFloating/useFloating.js +14 -16
- package/lib/hooks/__internal__/useInputAccessibility/useInputAccessibility.js +9 -10
- package/lib/hooks/__internal__/useModalAria/useModalAria.js +5 -6
- package/lib/hooks/__internal__/useModalManager/useModalManager.js +7 -8
- package/lib/hooks/__internal__/useScrollBlock/useScrollBlock.js +17 -23
- package/lib/hooks/__internal__/useStableCallback/useStableCallback.js +1 -6
- package/lib/locales/en-gb.js +1 -2
- package/lib/locales/pl-pl.js +1 -2
- package/lib/style/design-tokens/carbon-scoped-tokens-provider/carbon-scoped-tokens-provider.component.js +3 -6
- package/lib/style/design-tokens/debug-theme.util.js +1 -2
- package/lib/style/design-tokens/generate-css-variables.util.js +1 -2
- package/lib/style/palette/index.js +7 -10
- package/lib/style/utils/color.js +6 -7
- package/lib/style/utils/filter-out-styled-system-spacing-props.js +1 -4
- package/lib/style/utils/form-style-utils.js +1 -2
- package/lib/style/utils/merge-deep.js +2 -8
- package/lib/style/utils/mix.js +2 -6
- package/lib/style/utils/width.js +5 -8
- package/package.json +18 -9
|
@@ -16,24 +16,22 @@ const StyledTitleContent = _styledComponents.default.span`
|
|
|
16
16
|
line-height: 20px;
|
|
17
17
|
margin: 0;
|
|
18
18
|
|
|
19
|
-
${
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
} = _ref;
|
|
36
|
-
return (0, _styledComponents.css)`
|
|
19
|
+
${({
|
|
20
|
+
hasCustomLayout,
|
|
21
|
+
error,
|
|
22
|
+
warning,
|
|
23
|
+
info,
|
|
24
|
+
size,
|
|
25
|
+
isTabSelected,
|
|
26
|
+
hasSiblings,
|
|
27
|
+
borders = false,
|
|
28
|
+
position = "top",
|
|
29
|
+
noLeftBorder,
|
|
30
|
+
noRightBorder,
|
|
31
|
+
hasHref,
|
|
32
|
+
alternateStyling,
|
|
33
|
+
align
|
|
34
|
+
}) => (0, _styledComponents.css)`
|
|
37
35
|
text-align: ${align};
|
|
38
36
|
|
|
39
37
|
${position === "left" && (0, _styledComponents.css)`
|
|
@@ -224,8 +222,7 @@ const StyledTitleContent = _styledComponents.default.span`
|
|
|
224
222
|
`}
|
|
225
223
|
`}
|
|
226
224
|
`}
|
|
227
|
-
|
|
228
|
-
}}
|
|
225
|
+
`}
|
|
229
226
|
`;
|
|
230
227
|
exports.StyledTitleContent = StyledTitleContent;
|
|
231
228
|
const tabTitleStyles = (0, _styledComponents.css)`
|
|
@@ -242,43 +239,35 @@ const tabTitleStyles = (0, _styledComponents.css)`
|
|
|
242
239
|
text-decoration: none;
|
|
243
240
|
outline-offset: 0px;
|
|
244
241
|
margin: 0;
|
|
245
|
-
${
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
${_ref3 => {
|
|
253
|
-
let {
|
|
254
|
-
position
|
|
255
|
-
} = _ref3;
|
|
256
|
-
return (0, _styledComponents.css)`
|
|
242
|
+
${({
|
|
243
|
+
position
|
|
244
|
+
}) => position === "top" && "white-space: nowrap"};
|
|
245
|
+
|
|
246
|
+
${({
|
|
247
|
+
position
|
|
248
|
+
}) => (0, _styledComponents.css)`
|
|
257
249
|
${position === "left" && (0, _styledComponents.css)`
|
|
258
250
|
border-top-right-radius: var(--borderRadius000);
|
|
259
251
|
`}
|
|
260
|
-
|
|
261
|
-
}}
|
|
252
|
+
`}
|
|
262
253
|
|
|
263
254
|
a:visited {
|
|
264
255
|
color: inherit;
|
|
265
256
|
}
|
|
266
257
|
|
|
267
|
-
${
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
} = _ref4;
|
|
281
|
-
return (0, _styledComponents.css)`
|
|
258
|
+
${({
|
|
259
|
+
size,
|
|
260
|
+
position = "top",
|
|
261
|
+
borders = false,
|
|
262
|
+
noRightBorder,
|
|
263
|
+
noLeftBorder,
|
|
264
|
+
isTabSelected,
|
|
265
|
+
alternateStyling,
|
|
266
|
+
error,
|
|
267
|
+
warning,
|
|
268
|
+
info,
|
|
269
|
+
isInSidebar
|
|
270
|
+
}) => (0, _styledComponents.css)`
|
|
282
271
|
height: ${size === "large" ? "var(--sizing600)" : "var(--sizing500)"};
|
|
283
272
|
|
|
284
273
|
${position === "top" && (0, _styledComponents.css)`
|
|
@@ -414,8 +403,7 @@ const tabTitleStyles = (0, _styledComponents.css)`
|
|
|
414
403
|
background-color: var(--colorsActionMinor200);
|
|
415
404
|
`}
|
|
416
405
|
`}
|
|
417
|
-
|
|
418
|
-
}}
|
|
406
|
+
`}
|
|
419
407
|
`;
|
|
420
408
|
const StyledTabTitleButton = _styledComponents.default.button`
|
|
421
409
|
${tabTitleStyles}
|
|
@@ -426,14 +414,12 @@ const StyledTabTitleLink = _styledComponents.default.a`
|
|
|
426
414
|
`;
|
|
427
415
|
exports.StyledTabTitleLink = StyledTabTitleLink;
|
|
428
416
|
const StyledLayoutWrapper = _styledComponents.default.div`
|
|
429
|
-
${
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
} = _ref5;
|
|
436
|
-
return (0, _styledComponents.css)`
|
|
417
|
+
${({
|
|
418
|
+
hasCustomLayout,
|
|
419
|
+
titlePosition = "before",
|
|
420
|
+
hasCustomSibling,
|
|
421
|
+
position
|
|
422
|
+
}) => (0, _styledComponents.css)`
|
|
437
423
|
${hasCustomLayout && (0, _styledComponents.css)`
|
|
438
424
|
flex-grow: 2;
|
|
439
425
|
`}
|
|
@@ -464,19 +450,16 @@ const StyledLayoutWrapper = _styledComponents.default.div`
|
|
|
464
450
|
}
|
|
465
451
|
}
|
|
466
452
|
`}
|
|
467
|
-
|
|
468
|
-
}}
|
|
453
|
+
`}
|
|
469
454
|
`;
|
|
470
455
|
exports.StyledLayoutWrapper = StyledLayoutWrapper;
|
|
471
456
|
const StyledSelectedIndicator = _styledComponents.default.div`
|
|
472
457
|
position: absolute;
|
|
473
458
|
z-index: 1;
|
|
474
459
|
|
|
475
|
-
${
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
} = _ref6;
|
|
479
|
-
return (0, _styledComponents.css)`
|
|
460
|
+
${({
|
|
461
|
+
position = "top"
|
|
462
|
+
}) => (0, _styledComponents.css)`
|
|
480
463
|
${position === "top" && (0, _styledComponents.css)`
|
|
481
464
|
bottom: 0px;
|
|
482
465
|
left: 0px;
|
|
@@ -494,7 +477,6 @@ const StyledSelectedIndicator = _styledComponents.default.div`
|
|
|
494
477
|
height: 100%;
|
|
495
478
|
width: var(--sizing025);
|
|
496
479
|
`}
|
|
497
|
-
|
|
498
|
-
}}
|
|
480
|
+
`}
|
|
499
481
|
`;
|
|
500
482
|
exports.StyledSelectedIndicator = StyledSelectedIndicator;
|
|
@@ -16,24 +16,20 @@ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj &&
|
|
|
16
16
|
* It is ultimately tied to the position of the scroll that will then fade the shadow in and out. */
|
|
17
17
|
const fullOpacityThreshold = 128;
|
|
18
18
|
const getOpacityRatio = value => value / fullOpacityThreshold;
|
|
19
|
-
const getScrollRight =
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
extendedLine,
|
|
34
|
-
noRightBorder = false,
|
|
35
|
-
isInSidebar = false
|
|
36
|
-
} = _ref2;
|
|
19
|
+
const getScrollRight = ({
|
|
20
|
+
scrollWidth,
|
|
21
|
+
clientWidth,
|
|
22
|
+
scrollLeft
|
|
23
|
+
}) => scrollWidth - clientWidth - scrollLeft;
|
|
24
|
+
const TabsHeader = ({
|
|
25
|
+
align = "left",
|
|
26
|
+
children,
|
|
27
|
+
position = "top",
|
|
28
|
+
role,
|
|
29
|
+
extendedLine,
|
|
30
|
+
noRightBorder = false,
|
|
31
|
+
isInSidebar = false
|
|
32
|
+
}) => {
|
|
37
33
|
const [leftScrollOpacity, setLeftScrollOpacity] = (0, _react.useState)(0);
|
|
38
34
|
const [rightScrollOpacity, setRightScrollOpacity] = (0, _react.useState)(1);
|
|
39
35
|
const ref = (0, _react.useRef)(null);
|
|
@@ -11,12 +11,10 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
|
|
|
11
11
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
12
12
|
const outlineWidth = "3px";
|
|
13
13
|
const StyledTabsHeaderWrapper = _styledComponents.default.div`
|
|
14
|
-
${
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
} = _ref;
|
|
19
|
-
return position === "left" && (0, _styledComponents.css)`
|
|
14
|
+
${({
|
|
15
|
+
position,
|
|
16
|
+
isInSidebar
|
|
17
|
+
}) => position === "left" && (0, _styledComponents.css)`
|
|
20
18
|
overflow-y: auto;
|
|
21
19
|
box-sizing: border-box;
|
|
22
20
|
padding: 3px;
|
|
@@ -35,8 +33,7 @@ const StyledTabsHeaderWrapper = _styledComponents.default.div`
|
|
|
35
33
|
margin: auto;
|
|
36
34
|
padding: 0px;
|
|
37
35
|
`}
|
|
38
|
-
|
|
39
|
-
}}
|
|
36
|
+
`}
|
|
40
37
|
`;
|
|
41
38
|
exports.StyledTabsHeaderWrapper = StyledTabsHeaderWrapper;
|
|
42
39
|
const commonShadowStyles = (0, _styledComponents.css)`
|
|
@@ -45,46 +42,35 @@ const commonShadowStyles = (0, _styledComponents.css)`
|
|
|
45
42
|
background-repeat: no-repeat;
|
|
46
43
|
background-size: 16px 48px;
|
|
47
44
|
background-attachment: scroll;
|
|
48
|
-
z-index: ${
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
} = _ref2;
|
|
52
|
-
return theme.zIndex.overlay;
|
|
53
|
-
}};
|
|
45
|
+
z-index: ${({
|
|
46
|
+
theme
|
|
47
|
+
}) => theme.zIndex.overlay};
|
|
54
48
|
position: sticky;
|
|
55
49
|
min-width: 16px;
|
|
56
50
|
transition: opacity 0.1s ease-in-out;
|
|
57
51
|
`;
|
|
58
52
|
const StyledTabsHeaderList = _styledComponents.default.div`
|
|
59
53
|
display: flex;
|
|
60
|
-
${
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
} = _ref3;
|
|
64
|
-
return !extendedLine && (0, _styledComponents.css)`
|
|
54
|
+
${({
|
|
55
|
+
extendedLine = true
|
|
56
|
+
}) => !extendedLine && (0, _styledComponents.css)`
|
|
65
57
|
width: fit-content;
|
|
66
|
-
|
|
67
|
-
}}
|
|
58
|
+
`}
|
|
68
59
|
cursor: default;
|
|
69
60
|
list-style: none;
|
|
70
61
|
margin: -${outlineWidth};
|
|
71
62
|
padding: ${outlineWidth};
|
|
72
63
|
overflow-x: auto;
|
|
73
64
|
position: relative;
|
|
74
|
-
${
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
} = _ref4;
|
|
78
|
-
return position === "top" && "white-space: nowrap";
|
|
79
|
-
}};
|
|
65
|
+
${({
|
|
66
|
+
position
|
|
67
|
+
}) => position === "top" && "white-space: nowrap"};
|
|
80
68
|
|
|
81
|
-
${
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
} = _ref5;
|
|
87
|
-
return isScrollable && (0, _styledComponents.css)`
|
|
69
|
+
${({
|
|
70
|
+
isScrollable,
|
|
71
|
+
leftScrollOpacity,
|
|
72
|
+
rightScrollOpacity
|
|
73
|
+
}) => isScrollable && (0, _styledComponents.css)`
|
|
88
74
|
&:before {
|
|
89
75
|
${commonShadowStyles}
|
|
90
76
|
background: radial-gradient(
|
|
@@ -110,8 +96,7 @@ const StyledTabsHeaderList = _styledComponents.default.div`
|
|
|
110
96
|
margin-left: -16px;
|
|
111
97
|
opacity: ${rightScrollOpacity};
|
|
112
98
|
}
|
|
113
|
-
|
|
114
|
-
}}
|
|
99
|
+
`}
|
|
115
100
|
|
|
116
101
|
&::-webkit-scrollbar {
|
|
117
102
|
-webkit-appearance: none;
|
|
@@ -125,23 +110,18 @@ const StyledTabsHeaderList = _styledComponents.default.div`
|
|
|
125
110
|
cursor: pointer;
|
|
126
111
|
}
|
|
127
112
|
|
|
128
|
-
${
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
} = _ref6;
|
|
132
|
-
return align === "right" && (0, _styledComponents.css)`
|
|
113
|
+
${({
|
|
114
|
+
align = "left"
|
|
115
|
+
}) => align === "right" && (0, _styledComponents.css)`
|
|
133
116
|
justify-content: flex-end;
|
|
134
117
|
text-align: right;
|
|
135
|
-
|
|
136
|
-
}}
|
|
118
|
+
`}
|
|
137
119
|
|
|
138
|
-
${
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
} = _ref7;
|
|
144
|
-
return position === "left" && (0, _styledComponents.css)`
|
|
120
|
+
${({
|
|
121
|
+
position = "top",
|
|
122
|
+
noRightBorder,
|
|
123
|
+
align = "left"
|
|
124
|
+
}) => position === "left" && (0, _styledComponents.css)`
|
|
145
125
|
flex-direction: column;
|
|
146
126
|
box-shadow: none;
|
|
147
127
|
|
|
@@ -152,8 +132,7 @@ const StyledTabsHeaderList = _styledComponents.default.div`
|
|
|
152
132
|
${align === "right" && (0, _styledComponents.css)`
|
|
153
133
|
justify-content: flex-start;
|
|
154
134
|
`}
|
|
155
|
-
|
|
156
|
-
}}
|
|
135
|
+
`}
|
|
157
136
|
`;
|
|
158
137
|
exports.StyledTabsHeaderList = StyledTabsHeaderList;
|
|
159
138
|
StyledTabsHeaderList.defaultProps = {
|
|
@@ -14,27 +14,26 @@ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj &&
|
|
|
14
14
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
15
15
|
const TabContext = /*#__PURE__*/_react.default.createContext({});
|
|
16
16
|
exports.TabContext = TabContext;
|
|
17
|
-
const Tab =
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
} = _ref;
|
|
17
|
+
const Tab = ({
|
|
18
|
+
ariaLabelledby,
|
|
19
|
+
className,
|
|
20
|
+
children,
|
|
21
|
+
isTabSelected,
|
|
22
|
+
position = "top",
|
|
23
|
+
role = "tabpanel",
|
|
24
|
+
tabId,
|
|
25
|
+
updateErrors,
|
|
26
|
+
updateWarnings,
|
|
27
|
+
updateInfos,
|
|
28
|
+
href,
|
|
29
|
+
// title is destructured purely to NOT spread it as part of rest to the underlying HTML element.
|
|
30
|
+
// Both this and titleProps are used as part of child.props inside Tabs component
|
|
31
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
32
|
+
title,
|
|
33
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
34
|
+
titleProps,
|
|
35
|
+
...rest
|
|
36
|
+
}) => {
|
|
38
37
|
const [tabErrors, setTabErrors] = (0, _react.useState)({});
|
|
39
38
|
const [tabWarnings, setTabWarnings] = (0, _react.useState)({});
|
|
40
39
|
const [tabInfos, setTabInfos] = (0, _react.useState)({});
|
|
@@ -13,12 +13,10 @@ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj &&
|
|
|
13
13
|
const StyledTab = _styledComponents.default.div`
|
|
14
14
|
display: none;
|
|
15
15
|
|
|
16
|
-
${
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
} = _ref;
|
|
21
|
-
return isTabSelected && (0, _styledComponents.css)`
|
|
16
|
+
${({
|
|
17
|
+
isTabSelected,
|
|
18
|
+
position = "top"
|
|
19
|
+
}) => isTabSelected && (0, _styledComponents.css)`
|
|
22
20
|
display: block;
|
|
23
21
|
|
|
24
22
|
${position === "left" && (0, _styledComponents.css)`
|
|
@@ -26,8 +24,7 @@ const StyledTab = _styledComponents.default.div`
|
|
|
26
24
|
`}
|
|
27
25
|
|
|
28
26
|
${_styledSystem.padding}
|
|
29
|
-
|
|
30
|
-
}}
|
|
27
|
+
`}
|
|
31
28
|
`;
|
|
32
29
|
StyledTab.defaultProps = {
|
|
33
30
|
theme: _base.default
|
|
@@ -23,24 +23,23 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
23
23
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
24
24
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
25
25
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
26
|
-
const Tabs =
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
} = _ref;
|
|
26
|
+
const Tabs = ({
|
|
27
|
+
align = "left",
|
|
28
|
+
className,
|
|
29
|
+
children,
|
|
30
|
+
onTabChange,
|
|
31
|
+
selectedTabId,
|
|
32
|
+
renderHiddenTabs = true,
|
|
33
|
+
position = "top",
|
|
34
|
+
extendedLine = true,
|
|
35
|
+
size,
|
|
36
|
+
borders = "off",
|
|
37
|
+
variant = "default",
|
|
38
|
+
validationStatusOverride,
|
|
39
|
+
headerWidth,
|
|
40
|
+
showValidationsSummary,
|
|
41
|
+
...rest
|
|
42
|
+
}) => {
|
|
44
43
|
if (position !== "left" && headerWidth !== undefined) {
|
|
45
44
|
// eslint-disable-next-line no-console
|
|
46
45
|
console.error("Invalid usage of prop headerWidth in Tabs. The headerWidth can be used only if position is set to left");
|
|
@@ -188,8 +187,7 @@ const Tabs = _ref => {
|
|
|
188
187
|
const tabHasError = errorOverride !== undefined ? errorOverride : !!errorsCount;
|
|
189
188
|
const tabHasWarning = warningOverride !== undefined ? warningOverride : !!warningsCount && !tabHasError;
|
|
190
189
|
const tabHasInfo = infoOverride !== undefined ? infoOverride : !!infosCount && !tabHasError && !tabHasWarning;
|
|
191
|
-
const getValidationMessage =
|
|
192
|
-
let validations = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
190
|
+
const getValidationMessage = (message, validations = {}) => {
|
|
193
191
|
const summaryOfMessages = Object.values(validations).filter(value => value && typeof value === "string");
|
|
194
192
|
if (!showValidationsSummary || !summaryOfMessages.length) {
|
|
195
193
|
return message;
|
|
@@ -13,13 +13,11 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
13
13
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
14
14
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
15
15
|
const StyledTabs = _styledComponents.default.div`
|
|
16
|
-
${
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
} = _ref;
|
|
22
|
-
return (0, _styledComponents.css)`
|
|
16
|
+
${({
|
|
17
|
+
position,
|
|
18
|
+
isInSidebar,
|
|
19
|
+
headerWidth
|
|
20
|
+
}) => (0, _styledComponents.css)`
|
|
23
21
|
color: var(--colorsActionMinorYin090);
|
|
24
22
|
|
|
25
23
|
${position === "left" && (0, _styledComponents.css)`
|
|
@@ -39,8 +37,7 @@ const StyledTabs = _styledComponents.default.div`
|
|
|
39
37
|
|
|
40
38
|
width: 100%;
|
|
41
39
|
`}
|
|
42
|
-
|
|
43
|
-
}}
|
|
40
|
+
`}
|
|
44
41
|
|
|
45
42
|
${_styledSystem.margin}
|
|
46
43
|
`;
|
|
@@ -24,12 +24,7 @@ function findWithRegex(regex, contentBlock, callback) {
|
|
|
24
24
|
});
|
|
25
25
|
}
|
|
26
26
|
const linkStrategy = (contentBlock, callback) => {
|
|
27
|
-
const combineRegex =
|
|
28
|
-
for (var _len = arguments.length, regex = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
29
|
-
regex[_key] = arguments[_key];
|
|
30
|
-
}
|
|
31
|
-
return new RegExp(regex.map(r => r.source).join(""), "g");
|
|
32
|
-
};
|
|
27
|
+
const combineRegex = (...regex) => new RegExp(regex.map(r => r.source).join(""), "g");
|
|
33
28
|
const urlRegex = combineRegex(/\b/, /(http:\/\/|https:\/\/|www\.)/,
|
|
34
29
|
// prefix
|
|
35
30
|
/([\w-]+:([\w-]+@))?/,
|
|
@@ -9,25 +9,22 @@ var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
|
9
9
|
var _editorCounter = require("./editor-counter.style");
|
|
10
10
|
var _validations = _interopRequireDefault(require("../../../../__internal__/validations"));
|
|
11
11
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
12
|
-
const Counter =
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
hasError: !!error
|
|
30
|
-
}, `${limit - count}`));
|
|
31
|
-
};
|
|
12
|
+
const Counter = ({
|
|
13
|
+
count = 0,
|
|
14
|
+
limit = 3000,
|
|
15
|
+
error,
|
|
16
|
+
warning,
|
|
17
|
+
info
|
|
18
|
+
}) => /*#__PURE__*/_react.default.createElement(_editorCounter.StyledCounterWrapper, {
|
|
19
|
+
"data-component": "text-editor-counter"
|
|
20
|
+
}, !!(error || warning || info) && /*#__PURE__*/_react.default.createElement(_validations.default, {
|
|
21
|
+
error: error,
|
|
22
|
+
warning: warning,
|
|
23
|
+
info: info,
|
|
24
|
+
tooltipPosition: "top",
|
|
25
|
+
tabIndex: 0
|
|
26
|
+
}), /*#__PURE__*/_react.default.createElement(_editorCounter.StyledCounter, {
|
|
27
|
+
hasError: !!error
|
|
28
|
+
}, `${limit - count}`));
|
|
32
29
|
var _default = Counter;
|
|
33
30
|
exports.default = _default;
|
|
@@ -7,12 +7,9 @@ exports.StyledCounterWrapper = exports.StyledCounter = void 0;
|
|
|
7
7
|
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
8
8
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
9
9
|
const StyledCounter = _styledComponents.default.span`
|
|
10
|
-
color: ${
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
} = _ref;
|
|
14
|
-
return hasError ? "var(--colorsSemanticNegative500)" : "var(--colorsUtilityYin055)";
|
|
15
|
-
}};
|
|
10
|
+
color: ${({
|
|
11
|
+
hasError
|
|
12
|
+
}) => hasError ? "var(--colorsSemanticNegative500)" : "var(--colorsUtilityYin055)"};
|
|
16
13
|
width: 100%;
|
|
17
14
|
`;
|
|
18
15
|
exports.StyledCounter = StyledCounter;
|
|
@@ -12,13 +12,12 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
12
12
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
13
13
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
14
14
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
15
|
-
const EditorLink =
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
} = _ref;
|
|
15
|
+
const EditorLink = ({
|
|
16
|
+
children,
|
|
17
|
+
contentState,
|
|
18
|
+
entityKey,
|
|
19
|
+
...rest
|
|
20
|
+
}) => {
|
|
22
21
|
const url = !!contentState && !!entityKey ? contentState.getEntity(entityKey).getData() : children[0].props.text;
|
|
23
22
|
const buildValidUrl = () => {
|
|
24
23
|
const candidateUrl = url.url || url;
|
|
@@ -14,11 +14,10 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
14
14
|
* TextEditor component is composed with divs and spans.
|
|
15
15
|
* We have to manually trigger focus on TextEditor by clicking on label component.
|
|
16
16
|
* This wrapper allows us to trigger focus on TextEditor
|
|
17
|
-
*/const LabelWrapper =
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
} = _ref;
|
|
17
|
+
*/const LabelWrapper = ({
|
|
18
|
+
onClick,
|
|
19
|
+
children
|
|
20
|
+
}) => {
|
|
22
21
|
return /*#__PURE__*/_react.default.createElement("span", {
|
|
23
22
|
onClick: onClick
|
|
24
23
|
}, " ", children, " ");
|