carbon-react 118.5.1 → 118.5.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.d.ts +2 -2
- package/esm/__internal__/character-count/character-count.component.js +7 -16
- package/esm/__internal__/character-count/character-count.style.js +13 -7
- package/esm/__internal__/checkable-input/checkable-input.component.js +38 -37
- package/esm/__internal__/checkable-input/checkable-input.style.js +12 -9
- package/esm/__internal__/checkable-input/hidden-checkable-input.component.js +21 -27
- package/esm/__internal__/field-help/field-help.component.d.ts +1 -1
- package/esm/__internal__/field-help/field-help.component.js +13 -19
- package/esm/__internal__/field-help/field-help.style.js +8 -5
- package/esm/__internal__/fieldset/fieldset.component.d.ts +1 -1
- package/esm/__internal__/fieldset/fieldset.component.js +37 -204
- package/esm/__internal__/fieldset/fieldset.style.js +17 -11
- package/esm/__internal__/focus-trap/focus-trap-utils.d.ts +1 -1
- package/esm/__internal__/focus-trap/focus-trap-utils.js +12 -48
- package/esm/__internal__/focus-trap/focus-trap.component.d.ts +1 -1
- package/esm/__internal__/focus-trap/focus-trap.component.js +43 -96
- package/esm/__internal__/form-field/form-field.component.d.ts +1 -1
- package/esm/__internal__/form-field/form-field.component.js +31 -219
- package/esm/__internal__/form-field/form-field.style.js +7 -4
- package/esm/__internal__/form-spacing-provider/form-spacing-provider.component.d.ts +1 -1
- package/esm/__internal__/form-spacing-provider/form-spacing-provider.component.js +10 -13
- package/esm/__internal__/full-screen-heading/full-screen-heading.component.js +1 -2
- package/esm/__internal__/full-screen-heading/full-screen-heading.style.js +7 -4
- package/esm/__internal__/input/input-presentation.component.js +15 -19
- package/esm/__internal__/input/input-presentation.style.js +56 -39
- package/esm/__internal__/input/input.component.js +34 -57
- package/esm/__internal__/input/input.style.js +21 -12
- package/esm/__internal__/input-behaviour/input-behaviour.component.d.ts +1 -1
- package/esm/__internal__/input-behaviour/input-behaviour.component.js +6 -9
- package/esm/__internal__/input-behaviour/input-group-behaviour.component.d.ts +1 -1
- package/esm/__internal__/input-behaviour/input-group-behaviour.component.js +5 -10
- package/esm/__internal__/input-behaviour/useInputBehaviour.d.ts +1 -1
- package/esm/__internal__/input-behaviour/useInputBehaviour.js +3 -6
- package/esm/__internal__/input-icon-toggle/input-icon-toggle.component.d.ts +1 -1
- package/esm/__internal__/input-icon-toggle/input-icon-toggle.component.js +24 -45
- package/esm/__internal__/input-icon-toggle/input-icon-toggle.style.js +20 -15
- package/esm/__internal__/label/label.component.d.ts +2 -2
- package/esm/__internal__/label/label.component.js +36 -65
- package/esm/__internal__/label/label.style.js +32 -20
- package/esm/__internal__/popover/popover.component.d.ts +1 -1
- package/esm/__internal__/popover/popover.component.js +12 -45
- package/esm/__internal__/popover/popover.style.js +12 -6
- package/esm/__internal__/radio-button-mapper/radio-button-mapper.component.d.ts +1 -1
- package/esm/__internal__/radio-button-mapper/radio-button-mapper.component.js +11 -25
- package/esm/__internal__/sticky-footer/sticky-footer.component.d.ts +1 -1
- package/esm/__internal__/sticky-footer/sticky-footer.component.js +12 -30
- package/esm/__internal__/sticky-footer/sticky-footer.style.js +7 -4
- package/esm/__internal__/tooltip-provider/index.d.ts +1 -1
- package/esm/__internal__/tooltip-provider/index.js +10 -9
- package/esm/__internal__/utils/helpers/browser-type-check/index.js +0 -1
- package/esm/__internal__/utils/helpers/events/composedPath.js +1 -4
- package/esm/__internal__/utils/helpers/events/events.js +2 -19
- package/esm/__internal__/utils/helpers/guid/index.d.ts +1 -1
- package/esm/__internal__/utils/helpers/guid/index.js +0 -1
- package/esm/__internal__/utils/helpers/tags/tags-specs/tags-specs.d.ts +1 -1
- package/esm/__internal__/utils/helpers/tags/tags-specs/tags-specs.js +2 -3
- package/esm/__internal__/utils/helpers/tags/tags.js +0 -4
- package/esm/__internal__/utils/logger/index.js +1 -1
- package/esm/__internal__/validation-message/validation-message.component.d.ts +2 -2
- package/esm/__internal__/validation-message/validation-message.component.js +6 -12
- package/esm/__internal__/validation-message/validation-message.style.js +7 -4
- package/esm/__internal__/validations/validation-icon.component.d.ts +1 -1
- package/esm/__internal__/validations/validation-icon.component.js +24 -68
- package/esm/__internal__/validations/validation-icon.style.js +13 -7
- package/esm/__spec_helper__/enzyme-snapshot-helper.js +0 -5
- package/esm/__spec_helper__/expect.js +2 -5
- package/esm/__spec_helper__/mock-match-media.js +0 -3
- package/esm/__spec_helper__/mock-resize-observer.js +0 -2
- package/esm/__spec_helper__/test-utils.d.ts +10 -10
- package/esm/__spec_helper__/test-utils.js +53 -79
- package/esm/components/accordion/accordion-group/accordion-group.component.d.ts +1 -1
- package/esm/components/accordion/accordion-group/accordion-group.component.js +10 -212
- package/esm/components/accordion/accordion.component.js +30 -38
- package/esm/components/accordion/accordion.style.js +89 -52
- package/esm/components/action-popover/action-popover-item/action-popover-item.component.d.ts +1 -1
- package/esm/components/action-popover/action-popover-item/action-popover-item.component.js +27 -63
- package/esm/components/action-popover/action-popover-menu/action-popover-menu.component.js +16 -20
- package/esm/components/action-popover/action-popover-menu-button/action-popover-menu-button.component.d.ts +2 -2
- package/esm/components/action-popover/action-popover-menu-button/action-popover-menu-button.component.js +16 -32
- package/esm/components/action-popover/action-popover.component.d.ts +1 -1
- package/esm/components/action-popover/action-popover.component.js +23 -202
- package/esm/components/action-popover/action-popover.style.js +38 -24
- package/esm/components/advanced-color-picker/advanced-color-picker-cell.style.js +14 -8
- package/esm/components/advanced-color-picker/advanced-color-picker.component.d.ts +1 -1
- package/esm/components/advanced-color-picker/advanced-color-picker.component.js +43 -225
- package/esm/components/advanced-color-picker/advanced-color-picker.style.d.ts +2 -2
- package/esm/components/advanced-color-picker/advanced-color-picker.style.js +15 -9
- package/esm/components/alert/alert.component.d.ts +2 -2
- package/esm/components/alert/alert.component.js +12 -70
- package/esm/components/anchor-navigation/anchor-navigation-item/anchor-navigation-item.component.js +20 -17
- package/esm/components/anchor-navigation/anchor-navigation-item/anchor-navigation-item.style.js +14 -8
- package/esm/components/anchor-navigation/anchor-navigation.component.js +19 -24
- package/esm/components/badge/badge.component.d.ts +1 -1
- package/esm/components/badge/badge.component.js +8 -21
- package/esm/components/badge/badge.style.js +15 -9
- package/esm/components/batch-selection/batch-selection.component.d.ts +1 -1
- package/esm/components/batch-selection/batch-selection.component.js +8 -17
- package/esm/components/batch-selection/batch-selection.style.js +9 -6
- package/esm/components/box/box.component.js +60 -42
- package/esm/components/box/box.config.js +0 -1
- package/esm/components/breadcrumbs/breadcrumbs.component.js +6 -6
- package/esm/components/breadcrumbs/crumb/crumb.component.js +16 -14
- package/esm/components/breadcrumbs/crumb/crumb.style.js +7 -4
- package/esm/components/button/button-types.style.d.ts +1 -1
- package/esm/components/button/button-types.style.js +0 -2
- package/esm/components/button/button.component.js +39 -68
- package/esm/components/button/button.style.js +32 -30
- package/esm/components/button-bar/button-bar.component.d.ts +1 -1
- package/esm/components/button-bar/button-bar.component.js +20 -336
- package/esm/components/button-bar/button-bar.style.js +8 -5
- package/esm/components/button-minor/button-minor.component.d.ts +2 -2
- package/esm/components/button-minor/button-minor.component.js +13 -352
- package/esm/components/button-minor/button-minor.style.js +31 -21
- package/esm/components/button-toggle/button-toggle-icon.component.d.ts +2 -2
- package/esm/components/button-toggle/button-toggle-icon.component.js +17 -22
- package/esm/components/button-toggle/button-toggle-input.component.js +1 -7
- package/esm/components/button-toggle/button-toggle.component.d.ts +1 -1
- package/esm/components/button-toggle/button-toggle.component.js +21 -51
- package/esm/components/button-toggle/button-toggle.style.js +50 -29
- package/esm/components/button-toggle-group/button-toggle-group.component.d.ts +1 -1
- package/esm/components/button-toggle-group/button-toggle-group.component.js +29 -211
- package/esm/components/button-toggle-group/button-toggle-group.style.js +35 -20
- package/esm/components/carbon-provider/carbon-provider.component.d.ts +1 -1
- package/esm/components/carbon-provider/carbon-provider.component.js +9 -56
- package/esm/components/carbon-provider/top-modal-context.d.ts +1 -1
- package/esm/components/carbon-provider/top-modal-context.js +8 -12
- package/esm/components/card/card-column/card-column.component.d.ts +1 -1
- package/esm/components/card/card-column/card-column.component.js +9 -12
- package/esm/components/card/card-column/card-column.style.js +6 -3
- package/esm/components/card/card-footer/card-footer.component.d.ts +1 -1
- package/esm/components/card/card-footer/card-footer.component.js +8 -324
- package/esm/components/card/card-footer/card-footer.style.js +9 -6
- package/esm/components/card/card-row/card-row.component.d.ts +1 -1
- package/esm/components/card/card-row/card-row.component.js +7 -167
- package/esm/components/card/card-row/card-row.style.js +7 -4
- package/esm/components/card/card.component.d.ts +1 -1
- package/esm/components/card/card.component.js +18 -194
- package/esm/components/card/card.style.js +14 -11
- package/esm/components/carousel/carousel.component.d.ts +1 -1
- package/esm/components/carousel/carousel.component.js +13 -41
- package/esm/components/carousel/carousel.style.js +14 -8
- package/esm/components/carousel/slide/slide.component.d.ts +1 -1
- package/esm/components/carousel/slide/slide.component.js +2 -10
- package/esm/components/carousel/slide/slide.style.js +9 -5
- package/esm/components/checkbox/checkbox-group.component.d.ts +1 -1
- package/esm/components/checkbox/checkbox-group.component.js +2 -174
- package/esm/components/checkbox/checkbox-group.style.js +7 -4
- package/esm/components/checkbox/checkbox-svg.component.d.ts +2 -2
- package/esm/components/checkbox/checkbox-svg.component.js +0 -2
- package/esm/components/checkbox/checkbox.component.js +43 -46
- package/esm/components/checkbox/checkbox.style.js +16 -13
- package/esm/components/confirm/confirm.component.d.ts +1 -1
- package/esm/components/confirm/confirm.component.js +30 -88
- package/esm/components/confirm/confirm.style.js +14 -8
- package/esm/components/content/content.component.d.ts +1 -1
- package/esm/components/content/content.component.js +12 -178
- package/esm/components/content/content.style.js +22 -17
- package/esm/components/date/__internal__/date-formats/index.js +15 -26
- package/esm/components/date/__internal__/date-picker/date-picker.component.js +20 -33
- package/esm/components/date/__internal__/date-picker/day-picker.style.js +8 -5
- package/esm/components/date/__internal__/navbar/navbar.component.js +16 -15
- package/esm/components/date/__internal__/utils.js +1 -31
- package/esm/components/date/__internal__/weekday/weekday.component.js +15 -15
- package/esm/components/date/date.component.js +45 -89
- package/esm/components/date/date.style.js +18 -12
- package/esm/components/date-range/date-range.component.js +32 -67
- package/esm/components/date-range/date-range.style.js +6 -3
- package/esm/components/decimal/decimal.component.js +34 -58
- package/esm/components/definition-list/dd.component.d.ts +1 -1
- package/esm/components/definition-list/dd.component.js +6 -319
- package/esm/components/definition-list/definition-list.style.js +22 -13
- package/esm/components/definition-list/dl.component.d.ts +1 -1
- package/esm/components/definition-list/dl.component.js +10 -333
- package/esm/components/definition-list/dt.component.d.ts +1 -1
- package/esm/components/definition-list/dt.component.js +6 -319
- package/esm/components/detail/detail.component.d.ts +1 -1
- package/esm/components/detail/detail.component.js +21 -185
- package/esm/components/detail/detail.style.js +14 -8
- package/esm/components/dialog/dialog.component.d.ts +1 -1
- package/esm/components/dialog/dialog.component.js +25 -96
- package/esm/components/dialog/dialog.style.js +52 -30
- package/esm/components/dialog-full-screen/content.style.js +21 -12
- package/esm/components/dialog-full-screen/dialog-full-screen.component.d.ts +1 -1
- package/esm/components/dialog-full-screen/dialog-full-screen.component.js +27 -88
- package/esm/components/dialog-full-screen/dialog-full-screen.style.js +13 -7
- package/esm/components/dismissible-box/dismissible-box.component.d.ts +1 -1
- package/esm/components/dismissible-box/dismissible-box.component.js +22 -2464
- package/esm/components/dismissible-box/dismissible-box.style.js +8 -5
- package/esm/components/draggable/draggable-container.component.js +9 -15
- package/esm/components/draggable/draggable-item.component.js +17 -25
- package/esm/components/draggable/draggable-item.style.js +6 -3
- package/esm/components/draggable/internal/drop-target.component.d.ts +1 -1
- package/esm/components/draggable/internal/drop-target.component.js +8 -170
- package/esm/components/drawer/drawer.component.d.ts +1 -1
- package/esm/components/drawer/drawer.component.js +19 -52
- package/esm/components/drawer/drawer.style.js +70 -47
- package/esm/components/duelling-picklist/duelling-picklist.component.d.ts +1 -1
- package/esm/components/duelling-picklist/duelling-picklist.component.js +11 -180
- package/esm/components/duelling-picklist/duelling-picklist.context.js +1 -3
- package/esm/components/duelling-picklist/duelling-picklist.style.js +7 -4
- package/esm/components/duelling-picklist/picklist/picklist.component.d.ts +1 -1
- package/esm/components/duelling-picklist/picklist/picklist.component.js +9 -23
- package/esm/components/duelling-picklist/picklist-divider/picklist-divider.component.d.ts +2 -2
- package/esm/components/duelling-picklist/picklist-divider/picklist-divider.component.js +1 -7
- package/esm/components/duelling-picklist/picklist-group/picklist-group.component.js +13 -16
- package/esm/components/duelling-picklist/picklist-group/picklist-group.style.js +15 -9
- package/esm/components/duelling-picklist/picklist-item/picklist-item.component.js +16 -17
- package/esm/components/duelling-picklist/picklist-item/picklist-item.style.js +14 -8
- package/esm/components/duelling-picklist/picklist-placeholder/picklist-placeholder.component.d.ts +2 -2
- package/esm/components/duelling-picklist/picklist-placeholder/picklist-placeholder.component.js +7 -10
- package/esm/components/fieldset/fieldset.component.d.ts +1 -1
- package/esm/components/fieldset/fieldset.component.js +8 -171
- package/esm/components/fieldset/fieldset.style.js +13 -7
- package/esm/components/flat-table/flat-table-body/flat-table-body.component.js +6 -6
- package/esm/components/flat-table/flat-table-body-draggable/flat-table-body-draggable.component.js +13 -24
- package/esm/components/flat-table/flat-table-body-draggable/flat-table-body-draggable.style.js +7 -4
- package/esm/components/flat-table/flat-table-cell/flat-table-cell.component.js +20 -38
- package/esm/components/flat-table/flat-table-cell/flat-table-cell.style.js +24 -18
- package/esm/components/flat-table/flat-table-checkbox/flat-table-checkbox.component.js +15 -29
- package/esm/components/flat-table/flat-table-checkbox/flat-table-checkbox.style.js +10 -7
- package/esm/components/flat-table/flat-table-head/flat-table-head.component.js +9 -12
- package/esm/components/flat-table/flat-table-header/flat-table-header-utils.js +1 -4
- package/esm/components/flat-table/flat-table-header/flat-table-header.component.js +16 -29
- package/esm/components/flat-table/flat-table-header/flat-table-header.style.js +16 -13
- package/esm/components/flat-table/flat-table-row/__internal__/flat-table-row-draggable.component.js +11 -18
- package/esm/components/flat-table/flat-table-row/flat-table-row.component.js +34 -65
- package/esm/components/flat-table/flat-table-row/flat-table-row.style.js +28 -36
- package/esm/components/flat-table/flat-table-row-header/flat-table-row-header.component.js +18 -33
- package/esm/components/flat-table/flat-table-row-header/flat-table-row-header.style.js +23 -17
- package/esm/components/flat-table/flat-table.component.js +66 -85
- package/esm/components/flat-table/flat-table.style.js +139 -86
- package/esm/components/flat-table/sort/sort.component.js +6 -12
- package/esm/components/form/__internal__/form-summary.component.d.ts +2 -2
- package/esm/components/form/__internal__/form-summary.component.js +14 -31
- package/esm/components/form/__internal__/form-summary.style.js +42 -24
- package/esm/components/form/form.component.d.ts +1 -1
- package/esm/components/form/form.component.js +19 -501
- package/esm/components/form/form.style.js +73 -42
- package/esm/components/global-header/global-header.component.d.ts +1 -1
- package/esm/components/global-header/global-header.component.js +22 -1033
- package/esm/components/grid/grid-container/grid-container.component.d.ts +1 -1
- package/esm/components/grid/grid-container/grid-container.component.js +2 -1837
- package/esm/components/grid/grid-item/grid-item.component.d.ts +1 -1
- package/esm/components/grid/grid-item/grid-item.component.js +2 -1238
- package/esm/components/grid/grid-item/grid-item.style.js +19 -30
- package/esm/components/grouped-character/grouped-character.component.js +26 -39
- package/esm/components/heading/heading.component.d.ts +1 -1
- package/esm/components/heading/heading.component.js +20 -199
- package/esm/components/heading/heading.style.js +30 -18
- package/esm/components/help/help.component.js +21 -30
- package/esm/components/help/help.style.js +7 -4
- package/esm/components/hr/hr.component.js +8 -12
- package/esm/components/i18n-provider/i18n-provider.component.d.ts +1 -1
- package/esm/components/i18n-provider/i18n-provider.component.js +8 -139
- package/esm/components/icon/icon-unicodes.js +2 -3
- package/esm/components/icon/icon.component.js +28 -38
- package/esm/components/icon/icon.style.js +13 -18
- package/esm/components/icon-button/icon-button.component.js +15 -21
- package/esm/components/icon-button/icon-button.style.js +7 -4
- package/esm/components/image/image.component.d.ts +2 -2
- package/esm/components/image/image.component.js +9 -1690
- package/esm/components/image/image.style.js +22 -15
- package/esm/components/inline-inputs/inline-inputs.component.d.ts +1 -1
- package/esm/components/inline-inputs/inline-inputs.component.js +16 -189
- package/esm/components/inline-inputs/inline-inputs.style.js +38 -20
- package/esm/components/link/link.component.js +32 -37
- package/esm/components/link/link.style.js +11 -14
- package/esm/components/link-preview/__internal__/placeholder.component.d.ts +2 -2
- package/esm/components/link-preview/__internal__/placeholder.component.js +18 -11
- package/esm/components/link-preview/link-preview.component.d.ts +2 -2
- package/esm/components/link-preview/link-preview.component.js +15 -34
- package/esm/components/link-preview/link-preview.style.js +14 -8
- package/esm/components/loader/loader-square.style.js +10 -13
- package/esm/components/loader/loader.component.d.ts +2 -2
- package/esm/components/loader/loader.component.js +9 -175
- package/esm/components/loader-bar/loader-bar.component.d.ts +2 -2
- package/esm/components/loader-bar/loader-bar.component.js +6 -169
- package/esm/components/loader-bar/loader-bar.style.js +14 -12
- package/esm/components/menu/__internal__/keyboard-navigation/index.js +4 -22
- package/esm/components/menu/__internal__/spec-helper/index.js +2 -3
- package/esm/components/menu/__internal__/submenu/submenu.component.js +32 -70
- package/esm/components/menu/__internal__/submenu/submenu.style.js +28 -19
- package/esm/components/menu/menu-divider/menu-divider.component.js +6 -6
- package/esm/components/menu/menu-divider/menu-divider.style.js +8 -5
- package/esm/components/menu/menu-full-screen/menu-full-screen.component.d.ts +1 -1
- package/esm/components/menu/menu-full-screen/menu-full-screen.component.js +16 -36
- package/esm/components/menu/menu-full-screen/menu-full-screen.style.js +17 -11
- package/esm/components/menu/menu-item/menu-item.component.d.ts +1 -1
- package/esm/components/menu/menu-item/menu-item.component.js +30 -2096
- package/esm/components/menu/menu-item/menu-item.style.js +20 -17
- package/esm/components/menu/menu-segment-title/menu-segment-title.component.js +7 -7
- package/esm/components/menu/menu-segment-title/menu-segment-title.style.js +8 -5
- package/esm/components/menu/menu.component.d.ts +1 -1
- package/esm/components/menu/menu.component.js +9 -1888
- package/esm/components/menu/menu.context.js +1 -3
- package/esm/components/menu/menu.style.js +21 -12
- package/esm/components/menu/scrollable-block/scrollable-block.component.d.ts +1 -1
- package/esm/components/menu/scrollable-block/scrollable-block.component.js +10 -23
- package/esm/components/menu/scrollable-block/scrollable-block.style.js +8 -5
- package/esm/components/message/message-content/message-content.component.d.ts +1 -1
- package/esm/components/message/message-content/message-content.component.js +6 -12
- package/esm/components/message/message-content/message-content.style.js +6 -3
- package/esm/components/message/message.component.d.ts +1 -1
- package/esm/components/message/message.component.js +15 -186
- package/esm/components/message/message.style.js +13 -7
- package/esm/components/message/type-icon/type-icon.component.d.ts +2 -2
- package/esm/components/message/type-icon/type-icon.component.js +5 -10
- package/esm/components/message/type-icon/type-icon.style.js +14 -8
- package/esm/components/modal/__internal__/modal-manager.d.ts +1 -1
- package/esm/components/modal/__internal__/modal-manager.js +14 -33
- package/esm/components/modal/modal.component.d.ts +1 -1
- package/esm/components/modal/modal.component.js +12 -31
- package/esm/components/modal/modal.style.js +22 -13
- package/esm/components/multi-action-button/multi-action-button.component.d.ts +2 -2
- package/esm/components/multi-action-button/multi-action-button.component.js +21 -624
- package/esm/components/multi-action-button/multi-action-button.style.js +25 -16
- package/esm/components/navigation-bar/navigation-bar.component.js +12 -14
- package/esm/components/navigation-bar/navigation-bar.style.js +17 -11
- package/esm/components/note/__internal__/status-icon/status-icon.component.js +5 -4
- package/esm/components/note/note.component.d.ts +1 -1
- package/esm/components/note/note.component.js +15 -192
- package/esm/components/note/note.style.js +34 -19
- package/esm/components/number/number.component.js +15 -22
- package/esm/components/numeral-date/numeral-date.component.d.ts +1 -1
- package/esm/components/numeral-date/numeral-date.component.js +47 -299
- package/esm/components/numeral-date/numeral-date.style.js +8 -7
- package/esm/components/pager/__internal__/pager-navigation-link.component.d.ts +1 -1
- package/esm/components/pager/__internal__/pager-navigation-link.component.js +14 -27
- package/esm/components/pager/__internal__/pager-navigation.component.d.ts +1 -1
- package/esm/components/pager/__internal__/pager-navigation.component.js +18 -45
- package/esm/components/pager/pager.component.d.ts +1 -1
- package/esm/components/pager/pager.component.js +36 -73
- package/esm/components/pager/pager.style.js +14 -8
- package/esm/components/pages/page/page.component.d.ts +1 -1
- package/esm/components/pages/page/page.component.js +8 -170
- package/esm/components/pages/pages.component.d.ts +1 -1
- package/esm/components/pages/pages.component.js +12 -68
- package/esm/components/password/password.component.d.ts +2 -2
- package/esm/components/password/password.component.js +8 -546
- package/esm/components/pill/pill.component.d.ts +1 -1
- package/esm/components/pill/pill.component.js +34 -246
- package/esm/components/pill/pill.style.js +12 -15
- package/esm/components/pod/pod.component.js +27 -30
- package/esm/components/pod/pod.style.js +95 -65
- package/esm/components/popover-container/popover-container.component.d.ts +3 -3
- package/esm/components/popover-container/popover-container.component.js +69 -262
- package/esm/components/popover-container/popover-container.style.js +10 -9
- package/esm/components/portal/portal.d.ts +1 -1
- package/esm/components/portal/portal.js +12 -23
- package/esm/components/portrait/portrait-gravatar.component.d.ts +2 -2
- package/esm/components/portrait/portrait-gravatar.component.js +8 -18
- package/esm/components/portrait/portrait-initials.component.d.ts +2 -2
- package/esm/components/portrait/portrait-initials.component.js +18 -26
- package/esm/components/portrait/portrait.component.d.ts +1 -1
- package/esm/components/portrait/portrait.component.js +22 -205
- package/esm/components/portrait/portrait.style.js +32 -30
- package/esm/components/preview/__internal__/preview-placeholder.component.d.ts +2 -2
- package/esm/components/preview/__internal__/preview-placeholder.component.js +9 -18
- package/esm/components/preview/__internal__/preview-placeholder.style.js +12 -6
- package/esm/components/preview/preview.component.d.ts +1 -1
- package/esm/components/preview/preview.component.js +8 -176
- package/esm/components/preview/preview.style.js +2 -1
- package/esm/components/profile/profile.component.d.ts +2 -2
- package/esm/components/profile/profile.component.js +11 -27
- package/esm/components/profile/profile.style.d.ts +1 -1
- package/esm/components/profile/profile.style.js +37 -19
- package/esm/components/progress-tracker/progress-tracker.component.d.ts +2 -2
- package/esm/components/progress-tracker/progress-tracker.component.js +22 -203
- package/esm/components/progress-tracker/progress-tracker.style.js +62 -48
- package/esm/components/radio-button/radio-button-group.component.d.ts +1 -1
- package/esm/components/radio-button/radio-button-group.component.js +2 -188
- package/esm/components/radio-button/radio-button-group.style.js +8 -5
- package/esm/components/radio-button/radio-button-svg.component.d.ts +1 -1
- package/esm/components/radio-button/radio-button-svg.component.js +0 -2
- package/esm/components/radio-button/radio-button.component.js +45 -46
- package/esm/components/radio-button/radio-button.style.js +11 -8
- package/esm/components/search/search-button.style.js +6 -3
- package/esm/components/search/search.component.js +31 -49
- package/esm/components/search/search.style.js +11 -10
- package/esm/components/select/__internal__/select-text/select-text.component.d.ts +1 -1
- package/esm/components/select/__internal__/select-text/select-text.component.js +13 -30
- package/esm/components/select/__internal__/select-text/select-text.style.js +11 -8
- package/esm/components/select/filterable-select/filterable-select.component.js +61 -108
- package/esm/components/select/list-action-button/list-action-button.component.js +7 -9
- package/esm/components/select/multi-select/multi-select.component.js +71 -122
- package/esm/components/select/multi-select/multi-select.style.js +12 -6
- package/esm/components/select/option/option.component.js +22 -24
- package/esm/components/select/option/option.style.js +13 -7
- package/esm/components/select/option-group-header/option-group-header.component.js +8 -8
- package/esm/components/select/option-row/option-row.component.js +14 -17
- package/esm/components/select/option-row/option-row.style.js +13 -7
- package/esm/components/select/select-list/select-list-container.style.js +18 -9
- package/esm/components/select/select-list/select-list.component.js +53 -93
- package/esm/components/select/select-list/select-list.style.js +19 -10
- package/esm/components/select/select-textbox/select-textbox.component.js +58 -65
- package/esm/components/select/select.style.js +12 -9
- package/esm/components/select/simple-select/simple-select.component.js +48 -90
- package/esm/components/select/utils/get-next-child-by-text.js +4 -13
- package/esm/components/select/utils/get-next-index-by-key.js +0 -13
- package/esm/components/select/utils/highlight-part-of-text.js +0 -9
- package/esm/components/select/utils/is-expected-option.js +0 -4
- package/esm/components/select/utils/is-expected-value.js +0 -1
- package/esm/components/select/utils/with-filter.hoc.js +15 -49
- package/esm/components/settings-row/settings-row.component.d.ts +1 -1
- package/esm/components/settings-row/settings-row.component.js +11 -177
- package/esm/components/settings-row/settings-row.style.js +7 -4
- package/esm/components/show-edit-pod/show-edit-pod.component.js +31 -68
- package/esm/components/sidebar/__internal__/sidebar-header/sidebar-header.component.d.ts +1 -1
- package/esm/components/sidebar/__internal__/sidebar-header/sidebar-header.component.js +14 -173
- package/esm/components/sidebar/__internal__/sidebar-header/sidebar-header.style.js +7 -4
- package/esm/components/sidebar/sidebar.component.js +28 -28
- package/esm/components/sidebar/sidebar.style.js +13 -10
- package/esm/components/simple-color-picker/simple-color/simple-color.component.js +1 -2
- package/esm/components/simple-color-picker/simple-color/simple-color.style.js +24 -17
- package/esm/components/simple-color-picker/simple-color-picker.component.js +34 -47
- package/esm/components/simple-color-picker/simple-color-picker.style.js +13 -11
- package/esm/components/split-button/split-button-children.style.js +9 -6
- package/esm/components/split-button/split-button-toggle.style.js +10 -7
- package/esm/components/split-button/split-button.component.d.ts +1 -1
- package/esm/components/split-button/split-button.component.js +20 -523
- package/esm/components/step-sequence/step-sequence-item/step-sequence-item.component.d.ts +1 -1
- package/esm/components/step-sequence/step-sequence-item/step-sequence-item.component.js +12 -30
- package/esm/components/step-sequence/step-sequence-item/step-sequence-item.style.js +5 -4
- package/esm/components/step-sequence/step-sequence.component.d.ts +1 -1
- package/esm/components/step-sequence/step-sequence.component.js +7 -322
- package/esm/components/step-sequence/step-sequence.style.js +7 -4
- package/esm/components/switch/__internal__/switch-slider-panel.style.js +8 -5
- package/esm/components/switch/__internal__/switch-slider.component.d.ts +2 -2
- package/esm/components/switch/__internal__/switch-slider.component.js +11 -22
- package/esm/components/switch/__internal__/switch-slider.style.js +15 -12
- package/esm/components/switch/switch.component.js +40 -43
- package/esm/components/switch/switch.style.js +10 -7
- package/esm/components/tabs/__internal__/tab-title/tab-title.component.js +41 -53
- package/esm/components/tabs/__internal__/tab-title/tab-title.style.js +68 -50
- package/esm/components/tabs/__internal__/tabs-header/tabs-header.component.d.ts +1 -1
- package/esm/components/tabs/__internal__/tabs-header/tabs-header.component.js +19 -31
- package/esm/components/tabs/__internal__/tabs-header/tabs-header.style.js +52 -31
- package/esm/components/tabs/tab/tab.component.d.ts +1 -1
- package/esm/components/tabs/tab/tab.component.js +28 -205
- package/esm/components/tabs/tab/tab.style.js +8 -5
- package/esm/components/tabs/tabs.component.d.ts +1 -1
- package/esm/components/tabs/tabs.component.js +44 -239
- package/esm/components/tabs/tabs.style.js +9 -6
- package/esm/components/text-editor/__internal__/decorators/link-decorator.d.ts +1 -1
- package/esm/components/text-editor/__internal__/decorators/link-decorator.js +16 -11
- package/esm/components/text-editor/__internal__/editor-counter/editor-counter.component.d.ts +2 -2
- package/esm/components/text-editor/__internal__/editor-counter/editor-counter.component.js +19 -25
- package/esm/components/text-editor/__internal__/editor-counter/editor-counter.style.js +6 -3
- package/esm/components/text-editor/__internal__/editor-link/editor-link.component.d.ts +1 -1
- package/esm/components/text-editor/__internal__/editor-link/editor-link.component.js +10 -19
- package/esm/components/text-editor/__internal__/label-wrapper/label-wrapper.component.d.ts +1 -1
- package/esm/components/text-editor/__internal__/label-wrapper/label-wrapper.component.js +5 -12
- package/esm/components/text-editor/__internal__/toolbar/toolbar-button/toolbar-button.component.js +14 -14
- package/esm/components/text-editor/__internal__/toolbar/toolbar-button/toolbar-button.style.js +7 -4
- package/esm/components/text-editor/__internal__/toolbar/toolbar.component.d.ts +1 -1
- package/esm/components/text-editor/__internal__/toolbar/toolbar.component.js +12 -39
- package/esm/components/text-editor/__internal__/utils/utils.js +13 -23
- package/esm/components/text-editor/text-editor.component.js +43 -66
- package/esm/components/text-editor/text-editor.style.js +17 -11
- package/esm/components/textarea/textarea.component.js +54 -68
- package/esm/components/textarea/textarea.style.js +13 -7
- package/esm/components/textbox/__internal__/prefix.style.js +6 -3
- package/esm/components/textbox/textbox.component.js +63 -67
- package/esm/components/textbox/textbox.style.js +7 -4
- package/esm/components/tile/tile-footer/tile-footer.component.d.ts +1 -1
- package/esm/components/tile/tile-footer/tile-footer.component.js +7 -168
- package/esm/components/tile/tile-footer/tile-footer.style.js +7 -8
- package/esm/components/tile/tile.component.d.ts +1 -1
- package/esm/components/tile/tile.component.js +13 -332
- package/esm/components/tile/tile.style.js +25 -26
- package/esm/components/tile-select/__internal__/accordion/accordion.component.d.ts +1 -1
- package/esm/components/tile-select/__internal__/accordion/accordion.component.js +7 -322
- package/esm/components/tile-select/tile-select-group.component.d.ts +1 -1
- package/esm/components/tile-select/tile-select-group.component.js +13 -183
- package/esm/components/tile-select/tile-select.component.js +32 -36
- package/esm/components/tile-select/tile-select.style.d.ts +1 -1
- package/esm/components/tile-select/tile-select.style.js +63 -36
- package/esm/components/toast/toast.component.js +17 -28
- package/esm/components/toast/toast.style.d.ts +1 -1
- package/esm/components/toast/toast.style.js +61 -37
- package/esm/components/tooltip/tooltip-pointer.style.js +9 -8
- package/esm/components/tooltip/tooltip.component.js +40 -42
- package/esm/components/tooltip/tooltip.style.js +11 -10
- package/esm/components/typography/list.component.d.ts +2 -2
- package/esm/components/typography/list.component.js +22 -939
- package/esm/components/typography/typography.component.js +43 -65
- package/esm/components/vertical-divider/vertical-divider.component.js +9 -11
- package/esm/components/vertical-divider/vertical-divider.style.js +20 -11
- package/esm/components/vertical-menu/vertical-menu-full-screen.component.d.ts +1 -1
- package/esm/components/vertical-menu/vertical-menu-full-screen.component.js +12 -24
- package/esm/components/vertical-menu/vertical-menu-item.component.d.ts +1 -1
- package/esm/components/vertical-menu/vertical-menu-item.component.js +14 -208
- package/esm/components/vertical-menu/vertical-menu-trigger.component.d.ts +1 -1
- package/esm/components/vertical-menu/vertical-menu-trigger.component.js +9 -174
- package/esm/components/vertical-menu/vertical-menu.component.d.ts +1 -1
- package/esm/components/vertical-menu/vertical-menu.component.js +10 -23
- package/esm/components/vertical-menu/vertical-menu.style.js +19 -10
- package/esm/hooks/__internal__/useCharacterCount/useCharacterCount.d.ts +1 -1
- package/esm/hooks/__internal__/useCharacterCount/useCharacterCount.js +4 -4
- package/esm/hooks/__internal__/useClickAwayListener/useClickAwayListener.js +5 -3
- package/esm/hooks/__internal__/useFloating/useFloating.js +16 -20
- package/esm/hooks/__internal__/useFormSpacing/add-form-spacing/index.d.ts +1 -1
- package/esm/hooks/__internal__/useFormSpacing/add-form-spacing/index.js +2 -5
- package/esm/hooks/__internal__/useInputAccessibility/useInputAccessibility.js +10 -11
- package/esm/hooks/__internal__/useIsStickyFooterForm/useIsStickyFooterForm.js +1 -5
- package/esm/hooks/__internal__/useMenuKeyboardNavigation/useMenuKeyboardNavigation.js +8 -21
- package/esm/hooks/__internal__/useModalManager/useModalManager.js +8 -11
- package/esm/hooks/__internal__/useResizeObserver/useResizeObserver.js +4 -9
- package/esm/hooks/__internal__/useScrollBlock/scroll-block-manager.js +12 -21
- package/esm/hooks/__internal__/useScrollBlock/useScrollBlock.js +34 -32
- package/esm/hooks/__internal__/useStableCallback/useStableCallback.js +8 -5
- package/esm/hooks/__internal__/useThrottle/useThrottle.js +2 -1
- package/esm/hooks/__internal__/useUniqueId/index.d.ts +1 -1
- package/esm/hooks/useMediaQuery/useMediaQuery.js +0 -2
- package/esm/locales/en-gb.js +3 -9
- package/esm/locales/pl-pl.js +3 -24
- package/esm/style/design-tokens/carbon-scoped-tokens-provider/carbon-scoped-tokens-provider.component.js +7 -4
- package/esm/style/design-tokens/debug-theme.util.js +7 -10
- package/esm/style/design-tokens/generate-css-variables.util.d.ts +1 -1
- package/esm/style/design-tokens/generate-css-variables.util.js +3 -2
- package/esm/style/palette/index.js +12 -13
- package/esm/style/themes/aegean/aegean-theme.config.js +14 -18
- package/esm/style/themes/base/base-theme.config.js +3 -6
- package/esm/style/themes/base/index.js +4 -2
- package/esm/style/themes/mint/mint-theme.config.js +14 -18
- package/esm/style/themes/sage/index.d.ts +1 -1
- package/esm/style/themes/sage/index.js +4 -2
- package/esm/style/themes/test-utils.js +4 -4
- package/esm/style/utils/add-hex-symbols.js +0 -1
- package/esm/style/utils/at-opacity.d.ts +1 -1
- package/esm/style/utils/at-opacity.js +2 -4
- package/esm/style/utils/color.js +11 -16
- package/esm/style/utils/filter-out-styled-system-spacing-props.js +4 -3
- package/esm/style/utils/form-style-utils.js +2 -13
- package/esm/style/utils/get-color-value.js +0 -1
- package/esm/style/utils/get-rgb-values.js +1 -1
- package/esm/style/utils/merge-deep.js +9 -8
- package/esm/style/utils/mix.d.ts +1 -1
- package/esm/style/utils/mix.js +8 -10
- package/esm/style/utils/width.js +9 -5
- package/lib/__internal__/character-count/character-count.component.d.ts +2 -2
- package/lib/__internal__/character-count/character-count.component.js +7 -21
- package/lib/__internal__/character-count/character-count.style.js +16 -16
- package/lib/__internal__/character-count/index.js +0 -2
- package/lib/__internal__/checkable-input/checkable-input-svg-wrapper.style.js +0 -3
- package/lib/__internal__/checkable-input/checkable-input.component.js +40 -52
- package/lib/__internal__/checkable-input/checkable-input.style.js +14 -22
- package/lib/__internal__/checkable-input/hidden-checkable-input.component.js +23 -40
- package/lib/__internal__/checkable-input/hidden-checkable-input.style.js +0 -3
- package/lib/__internal__/checkable-input/index.js +0 -2
- package/lib/__internal__/field-help/field-help.component.d.ts +1 -1
- package/lib/__internal__/field-help/field-help.component.js +14 -23
- package/lib/__internal__/field-help/field-help.style.js +10 -11
- package/lib/__internal__/field-help/index.js +0 -2
- package/lib/__internal__/fieldset/fieldset.component.d.ts +1 -1
- package/lib/__internal__/fieldset/fieldset.component.js +37 -211
- package/lib/__internal__/fieldset/fieldset.style.js +19 -20
- package/lib/__internal__/fieldset/index.js +0 -2
- package/lib/__internal__/filter-object-properties/filter-object-properties.js +0 -1
- package/lib/__internal__/filter-object-properties/index.js +0 -2
- package/lib/__internal__/focus-trap/focus-trap-utils.d.ts +1 -1
- package/lib/__internal__/focus-trap/focus-trap-utils.js +13 -52
- package/lib/__internal__/focus-trap/focus-trap.component.d.ts +1 -1
- package/lib/__internal__/focus-trap/focus-trap.component.js +44 -110
- package/lib/__internal__/focus-trap/index.js +0 -2
- package/lib/__internal__/form-field/form-field.component.d.ts +1 -1
- package/lib/__internal__/form-field/form-field.component.js +33 -234
- package/lib/__internal__/form-field/form-field.style.js +9 -12
- package/lib/__internal__/form-field/index.js +0 -2
- package/lib/__internal__/form-spacing-provider/form-spacing-context.js +0 -4
- package/lib/__internal__/form-spacing-provider/form-spacing-provider.component.d.ts +1 -1
- package/lib/__internal__/form-spacing-provider/form-spacing-provider.component.js +10 -17
- package/lib/__internal__/form-spacing-provider/index.js +0 -3
- package/lib/__internal__/full-screen-heading/full-screen-heading.component.js +3 -13
- package/lib/__internal__/full-screen-heading/full-screen-heading.style.js +9 -11
- package/lib/__internal__/full-screen-heading/index.js +0 -2
- package/lib/__internal__/i18n-context/index.js +0 -5
- package/lib/__internal__/input/index.js +0 -4
- package/lib/__internal__/input/input-presentation.component.js +17 -29
- package/lib/__internal__/input/input-presentation.style.js +61 -51
- package/lib/__internal__/input/input.component.js +38 -69
- package/lib/__internal__/input/input.style.js +24 -19
- package/lib/__internal__/input-behaviour/index.js +0 -2
- package/lib/__internal__/input-behaviour/input-behaviour.component.d.ts +1 -1
- package/lib/__internal__/input-behaviour/input-behaviour.component.js +8 -17
- package/lib/__internal__/input-behaviour/input-group-behaviour.component.d.ts +1 -1
- package/lib/__internal__/input-behaviour/input-group-behaviour.component.js +7 -18
- package/lib/__internal__/input-behaviour/useInputBehaviour.d.ts +1 -1
- package/lib/__internal__/input-behaviour/useInputBehaviour.js +3 -7
- package/lib/__internal__/input-icon-toggle/index.js +0 -2
- package/lib/__internal__/input-icon-toggle/input-icon-toggle.component.d.ts +1 -1
- package/lib/__internal__/input-icon-toggle/input-icon-toggle.component.js +24 -51
- package/lib/__internal__/input-icon-toggle/input-icon-toggle.style.js +22 -23
- package/lib/__internal__/label/icon-wrapper.style.js +0 -5
- package/lib/__internal__/label/index.js +0 -2
- package/lib/__internal__/label/label.component.d.ts +2 -2
- package/lib/__internal__/label/label.component.js +38 -78
- package/lib/__internal__/label/label.style.js +34 -26
- package/lib/__internal__/popover/index.js +0 -2
- package/lib/__internal__/popover/popover.component.d.ts +1 -1
- package/lib/__internal__/popover/popover.component.js +14 -60
- package/lib/__internal__/popover/popover.style.js +12 -10
- package/lib/__internal__/radio-button-mapper/index.js +0 -2
- package/lib/__internal__/radio-button-mapper/radio-button-mapper.component.d.ts +1 -1
- package/lib/__internal__/radio-button-mapper/radio-button-mapper.component.js +13 -32
- package/lib/__internal__/sticky-footer/index.js +0 -2
- package/lib/__internal__/sticky-footer/sticky-footer.component.d.ts +1 -1
- package/lib/__internal__/sticky-footer/sticky-footer.component.js +14 -40
- package/lib/__internal__/sticky-footer/sticky-footer.style.js +9 -10
- package/lib/__internal__/tooltip-provider/index.d.ts +1 -1
- package/lib/__internal__/tooltip-provider/index.js +12 -20
- package/lib/__internal__/utils/helpers/browser-type-check/index.js +1 -4
- package/lib/__internal__/utils/helpers/events/composedPath.js +0 -6
- package/lib/__internal__/utils/helpers/events/events.js +1 -21
- package/lib/__internal__/utils/helpers/events/index.js +0 -2
- package/lib/__internal__/utils/helpers/guid/index.d.ts +1 -1
- package/lib/__internal__/utils/helpers/guid/index.js +0 -3
- package/lib/__internal__/utils/helpers/tags/index.js +0 -2
- package/lib/__internal__/utils/helpers/tags/tags-specs/index.js +0 -1
- package/lib/__internal__/utils/helpers/tags/tags-specs/tags-specs.d.ts +1 -1
- package/lib/__internal__/utils/helpers/tags/tags-specs/tags-specs.js +2 -5
- package/lib/__internal__/utils/helpers/tags/tags.js +0 -5
- package/lib/__internal__/utils/logger/index.js +1 -2
- package/lib/__internal__/validation-message/index.js +0 -2
- package/lib/__internal__/validation-message/validation-message.component.d.ts +2 -2
- package/lib/__internal__/validation-message/validation-message.component.js +6 -16
- package/lib/__internal__/validation-message/validation-message.style.js +9 -10
- package/lib/__internal__/validations/index.js +0 -2
- package/lib/__internal__/validations/validation-icon.component.d.ts +1 -1
- package/lib/__internal__/validations/validation-icon.component.js +26 -80
- package/lib/__internal__/validations/validation-icon.style.js +15 -17
- package/lib/__spec_helper__/enzyme-snapshot-helper.js +1 -7
- package/lib/__spec_helper__/expect.js +2 -8
- package/lib/__spec_helper__/index.js +0 -4
- package/lib/__spec_helper__/mock-match-media.js +1 -8
- package/lib/__spec_helper__/mock-resize-observer.js +0 -3
- package/lib/__spec_helper__/test-utils.d.ts +10 -10
- package/lib/__spec_helper__/test-utils.js +56 -105
- package/lib/components/accordion/accordion-group/accordion-group.component.d.ts +1 -1
- package/lib/components/accordion/accordion-group/accordion-group.component.js +13 -225
- package/lib/components/accordion/accordion.component.js +32 -52
- package/lib/components/accordion/accordion.style.js +92 -64
- package/lib/components/accordion/index.js +0 -3
- package/lib/components/action-popover/action-popover-context.js +0 -4
- package/lib/components/action-popover/action-popover-divider/action-popover-divider.component.js +0 -2
- package/lib/components/action-popover/action-popover-item/action-popover-item.component.d.ts +1 -1
- package/lib/components/action-popover/action-popover-item/action-popover-item.component.js +29 -77
- package/lib/components/action-popover/action-popover-menu/action-popover-menu.component.js +18 -37
- package/lib/components/action-popover/action-popover-menu-button/action-popover-menu-button.component.d.ts +2 -2
- package/lib/components/action-popover/action-popover-menu-button/action-popover-menu-button.component.js +17 -37
- package/lib/components/action-popover/action-popover.component.d.ts +1 -1
- package/lib/components/action-popover/action-popover.component.js +25 -220
- package/lib/components/action-popover/action-popover.style.js +42 -38
- package/lib/components/action-popover/index.js +6 -12
- package/lib/components/advanced-color-picker/advanced-color-picker-cell.style.js +17 -15
- package/lib/components/advanced-color-picker/advanced-color-picker.component.d.ts +1 -1
- package/lib/components/advanced-color-picker/advanced-color-picker.component.js +45 -241
- package/lib/components/advanced-color-picker/advanced-color-picker.style.d.ts +2 -2
- package/lib/components/advanced-color-picker/advanced-color-picker.style.js +20 -29
- package/lib/components/advanced-color-picker/index.js +0 -2
- package/lib/components/alert/alert.component.d.ts +2 -2
- package/lib/components/alert/alert.component.js +13 -74
- package/lib/components/alert/index.js +0 -2
- package/lib/components/anchor-navigation/anchor-navigation-item/anchor-navigation-item.component.js +20 -23
- package/lib/components/anchor-navigation/anchor-navigation-item/anchor-navigation-item.style.js +16 -14
- package/lib/components/anchor-navigation/anchor-navigation.component.js +21 -40
- package/lib/components/anchor-navigation/anchor-navigation.style.js +1 -4
- package/lib/components/anchor-navigation/anchor-section-divider.component.js +0 -3
- package/lib/components/anchor-navigation/index.js +0 -4
- package/lib/components/badge/badge.component.d.ts +1 -1
- package/lib/components/badge/badge.component.js +8 -24
- package/lib/components/badge/badge.style.js +18 -20
- package/lib/components/badge/index.js +0 -2
- package/lib/components/batch-selection/batch-selection.component.d.ts +1 -1
- package/lib/components/batch-selection/batch-selection.component.js +8 -21
- package/lib/components/batch-selection/batch-selection.style.js +11 -15
- package/lib/components/batch-selection/index.js +0 -2
- package/lib/components/box/box.component.js +63 -56
- package/lib/components/box/box.config.js +0 -3
- package/lib/components/box/index.js +0 -2
- package/lib/components/breadcrumbs/breadcrumbs.component.js +6 -14
- package/lib/components/breadcrumbs/breadcrumbs.style.js +0 -3
- package/lib/components/breadcrumbs/crumb/crumb.component.js +16 -21
- package/lib/components/breadcrumbs/crumb/crumb.style.js +10 -13
- package/lib/components/breadcrumbs/crumb/index.js +0 -2
- package/lib/components/breadcrumbs/index.js +0 -3
- package/lib/components/button/button-types.style.d.ts +1 -1
- package/lib/components/button/button-types.style.js +0 -6
- package/lib/components/button/button.component.js +41 -89
- package/lib/components/button/button.config.js +1 -1
- package/lib/components/button/button.style.js +34 -40
- package/lib/components/button/index.js +6 -9
- package/lib/components/button-bar/button-bar.component.d.ts +1 -1
- package/lib/components/button-bar/button-bar.component.js +22 -343
- package/lib/components/button-bar/button-bar.config.js +1 -1
- package/lib/components/button-bar/button-bar.style.js +10 -15
- package/lib/components/button-bar/index.js +0 -2
- package/lib/components/button-minor/button-minor.component.d.ts +2 -2
- package/lib/components/button-minor/button-minor.component.js +14 -356
- package/lib/components/button-minor/button-minor.style.js +35 -32
- package/lib/components/button-minor/index.js +0 -2
- package/lib/components/button-toggle/button-toggle-icon.component.d.ts +2 -2
- package/lib/components/button-toggle/button-toggle-icon.component.js +17 -27
- package/lib/components/button-toggle/button-toggle-input.component.js +3 -18
- package/lib/components/button-toggle/button-toggle.component.d.ts +1 -1
- package/lib/components/button-toggle/button-toggle.component.js +23 -66
- package/lib/components/button-toggle/button-toggle.style.js +53 -38
- package/lib/components/button-toggle/index.js +0 -2
- package/lib/components/button-toggle-group/button-toggle-group.component.d.ts +1 -1
- package/lib/components/button-toggle-group/button-toggle-group.component.js +31 -228
- package/lib/components/button-toggle-group/button-toggle-group.style.js +37 -29
- package/lib/components/button-toggle-group/index.js +0 -2
- package/lib/components/carbon-provider/carbon-provider.component.d.ts +1 -1
- package/lib/components/carbon-provider/carbon-provider.component.js +12 -68
- package/lib/components/carbon-provider/index.js +0 -2
- package/lib/components/carbon-provider/top-modal-context.d.ts +1 -1
- package/lib/components/carbon-provider/top-modal-context.js +9 -19
- package/lib/components/card/__internal__/card-context/index.js +0 -4
- package/lib/components/card/card-column/card-column.component.d.ts +1 -1
- package/lib/components/card/card-column/card-column.component.js +9 -16
- package/lib/components/card/card-column/card-column.style.js +6 -6
- package/lib/components/card/card-column/index.js +0 -2
- package/lib/components/card/card-footer/card-footer.component.d.ts +1 -1
- package/lib/components/card/card-footer/card-footer.component.js +10 -334
- package/lib/components/card/card-footer/card-footer.style.js +11 -15
- package/lib/components/card/card-footer/index.js +0 -2
- package/lib/components/card/card-row/card-row.component.d.ts +1 -1
- package/lib/components/card/card-row/card-row.component.js +7 -172
- package/lib/components/card/card-row/card-row.style.js +9 -13
- package/lib/components/card/card-row/index.js +0 -2
- package/lib/components/card/card.component.d.ts +1 -1
- package/lib/components/card/card.component.js +20 -208
- package/lib/components/card/card.config.js +1 -1
- package/lib/components/card/card.style.js +16 -20
- package/lib/components/card/index.js +6 -11
- package/lib/components/carousel/carousel.component.d.ts +1 -1
- package/lib/components/carousel/carousel.component.js +15 -51
- package/lib/components/carousel/carousel.style.js +17 -19
- package/lib/components/carousel/index.js +0 -3
- package/lib/components/carousel/slide/index.js +0 -2
- package/lib/components/carousel/slide/slide.component.d.ts +1 -1
- package/lib/components/carousel/slide/slide.component.js +1 -13
- package/lib/components/carousel/slide/slide.style.js +11 -11
- package/lib/components/carousel/slide.config.js +1 -3
- package/lib/components/checkbox/checkbox-group.component.d.ts +1 -1
- package/lib/components/checkbox/checkbox-group.component.js +2 -184
- package/lib/components/checkbox/checkbox-group.style.js +9 -16
- package/lib/components/checkbox/checkbox-svg.component.d.ts +2 -2
- package/lib/components/checkbox/checkbox-svg.component.js +0 -6
- package/lib/components/checkbox/checkbox.component.js +45 -66
- package/lib/components/checkbox/checkbox.style.js +18 -28
- package/lib/components/checkbox/index.js +4 -7
- package/lib/components/confirm/confirm.component.d.ts +1 -1
- package/lib/components/confirm/confirm.component.js +32 -102
- package/lib/components/confirm/confirm.style.js +16 -17
- package/lib/components/confirm/index.js +0 -2
- package/lib/components/content/content.component.d.ts +1 -1
- package/lib/components/content/content.component.js +12 -181
- package/lib/components/content/content.style.js +25 -26
- package/lib/components/content/index.js +0 -2
- package/lib/components/date/__internal__/date-formats/index.js +15 -26
- package/lib/components/date/__internal__/date-picker/date-picker.component.js +22 -51
- package/lib/components/date/__internal__/date-picker/day-picker.style.js +6 -8
- package/lib/components/date/__internal__/date-picker/index.js +0 -2
- package/lib/components/date/__internal__/navbar/button.style.js +0 -3
- package/lib/components/date/__internal__/navbar/index.js +0 -2
- package/lib/components/date/__internal__/navbar/navbar.component.js +16 -21
- package/lib/components/date/__internal__/navbar/navbar.style.js +0 -3
- package/lib/components/date/__internal__/utils.js +7 -48
- package/lib/components/date/__internal__/weekday/abbr.style.js +0 -3
- package/lib/components/date/__internal__/weekday/index.js +0 -2
- package/lib/components/date/__internal__/weekday/weekday.component.js +15 -20
- package/lib/components/date/__internal__/weekday/weekday.style.js +0 -3
- package/lib/components/date/date.component.js +47 -113
- package/lib/components/date/date.style.js +20 -27
- package/lib/components/date/index.js +0 -2
- package/lib/components/date-range/date-range.component.js +34 -86
- package/lib/components/date-range/date-range.context.js +0 -4
- package/lib/components/date-range/date-range.style.js +6 -11
- package/lib/components/date-range/index.js +0 -2
- package/lib/components/decimal/decimal.component.js +36 -75
- package/lib/components/decimal/index.js +0 -2
- package/lib/components/definition-list/__internal__/dl.context.js +0 -4
- package/lib/components/definition-list/dd.component.d.ts +1 -1
- package/lib/components/definition-list/dd.component.js +6 -323
- package/lib/components/definition-list/definition-list.style.js +25 -24
- package/lib/components/definition-list/dl.component.d.ts +1 -1
- package/lib/components/definition-list/dl.component.js +10 -345
- package/lib/components/definition-list/dt.component.d.ts +1 -1
- package/lib/components/definition-list/dt.component.js +8 -328
- package/lib/components/definition-list/index.js +6 -10
- package/lib/components/detail/detail.component.d.ts +1 -1
- package/lib/components/detail/detail.component.js +22 -191
- package/lib/components/detail/detail.style.js +17 -19
- package/lib/components/detail/index.js +0 -2
- package/lib/components/dialog/dialog.component.d.ts +1 -1
- package/lib/components/dialog/dialog.component.js +27 -115
- package/lib/components/dialog/dialog.config.js +1 -1
- package/lib/components/dialog/dialog.style.js +56 -46
- package/lib/components/dialog/index.js +0 -2
- package/lib/components/dialog-full-screen/content.style.js +23 -19
- package/lib/components/dialog-full-screen/dialog-full-screen.component.d.ts +1 -1
- package/lib/components/dialog-full-screen/dialog-full-screen.component.js +29 -106
- package/lib/components/dialog-full-screen/dialog-full-screen.style.js +15 -20
- package/lib/components/dialog-full-screen/index.js +0 -2
- package/lib/components/dismissible-box/dismissible-box.component.d.ts +1 -1
- package/lib/components/dismissible-box/dismissible-box.component.js +23 -2470
- package/lib/components/dismissible-box/dismissible-box.style.js +10 -14
- package/lib/components/dismissible-box/index.js +0 -2
- package/lib/components/draggable/draggable-container.component.js +11 -28
- package/lib/components/draggable/draggable-item.component.js +17 -31
- package/lib/components/draggable/draggable-item.style.js +6 -9
- package/lib/components/draggable/index.js +0 -3
- package/lib/components/draggable/internal/drop-target.component.d.ts +1 -1
- package/lib/components/draggable/internal/drop-target.component.js +8 -175
- package/lib/components/drawer/drawer.component.d.ts +1 -1
- package/lib/components/drawer/drawer.component.js +21 -66
- package/lib/components/drawer/drawer.style.js +73 -58
- package/lib/components/drawer/index.js +6 -9
- package/lib/components/duelling-picklist/duelling-picklist.component.d.ts +1 -1
- package/lib/components/duelling-picklist/duelling-picklist.component.js +13 -191
- package/lib/components/duelling-picklist/duelling-picklist.context.js +1 -7
- package/lib/components/duelling-picklist/duelling-picklist.style.js +10 -13
- package/lib/components/duelling-picklist/index.js +10 -17
- package/lib/components/duelling-picklist/picklist/picklist.component.d.ts +1 -1
- package/lib/components/duelling-picklist/picklist/picklist.component.js +11 -36
- package/lib/components/duelling-picklist/picklist/picklist.style.js +1 -5
- package/lib/components/duelling-picklist/picklist-divider/picklist-divider.component.d.ts +2 -2
- package/lib/components/duelling-picklist/picklist-divider/picklist-divider.component.js +1 -11
- package/lib/components/duelling-picklist/picklist-divider/picklist-divider.style.js +0 -3
- package/lib/components/duelling-picklist/picklist-group/picklist-group.component.js +15 -33
- package/lib/components/duelling-picklist/picklist-group/picklist-group.style.js +18 -19
- package/lib/components/duelling-picklist/picklist-item/picklist-item.component.js +18 -30
- package/lib/components/duelling-picklist/picklist-item/picklist-item.style.js +17 -19
- package/lib/components/duelling-picklist/picklist-placeholder/picklist-placeholder.component.d.ts +2 -2
- package/lib/components/duelling-picklist/picklist-placeholder/picklist-placeholder.component.js +8 -14
- package/lib/components/fieldset/fieldset.component.d.ts +1 -1
- package/lib/components/fieldset/fieldset.component.js +8 -178
- package/lib/components/fieldset/fieldset.style.js +14 -17
- package/lib/components/fieldset/index.js +0 -2
- package/lib/components/flat-table/flat-table-body/flat-table-body.component.js +6 -11
- package/lib/components/flat-table/flat-table-body/index.js +0 -2
- package/lib/components/flat-table/flat-table-body-draggable/flat-table-body-draggable.component.js +15 -36
- package/lib/components/flat-table/flat-table-body-draggable/flat-table-body-draggable.style.js +9 -10
- package/lib/components/flat-table/flat-table-body-draggable/index.js +0 -2
- package/lib/components/flat-table/flat-table-cell/flat-table-cell.component.js +22 -50
- package/lib/components/flat-table/flat-table-cell/flat-table-cell.style.js +27 -29
- package/lib/components/flat-table/flat-table-cell/index.js +0 -2
- package/lib/components/flat-table/flat-table-checkbox/flat-table-checkbox.component.js +17 -38
- package/lib/components/flat-table/flat-table-checkbox/flat-table-checkbox.style.js +12 -15
- package/lib/components/flat-table/flat-table-checkbox/index.js +0 -2
- package/lib/components/flat-table/flat-table-head/flat-table-head.component.js +11 -21
- package/lib/components/flat-table/flat-table-head/flat-table-head.style.js +0 -6
- package/lib/components/flat-table/flat-table-head/index.js +0 -2
- package/lib/components/flat-table/flat-table-header/flat-table-header-utils.js +1 -5
- package/lib/components/flat-table/flat-table-header/flat-table-header.component.js +18 -41
- package/lib/components/flat-table/flat-table-header/flat-table-header.style.js +18 -24
- package/lib/components/flat-table/flat-table-header/index.js +0 -2
- package/lib/components/flat-table/flat-table-row/__internal__/flat-table-row-draggable.component.js +11 -22
- package/lib/components/flat-table/flat-table-row/flat-table-row.component.js +36 -82
- package/lib/components/flat-table/flat-table-row/flat-table-row.style.js +30 -50
- package/lib/components/flat-table/flat-table-row/index.js +0 -2
- package/lib/components/flat-table/flat-table-row-header/flat-table-row-header.component.js +20 -45
- package/lib/components/flat-table/flat-table-row-header/flat-table-row-header.style.js +25 -27
- package/lib/components/flat-table/flat-table-row-header/index.js +0 -2
- package/lib/components/flat-table/flat-table.component.js +68 -98
- package/lib/components/flat-table/flat-table.config.js +1 -1
- package/lib/components/flat-table/flat-table.style.js +143 -105
- package/lib/components/flat-table/index.js +16 -27
- package/lib/components/flat-table/sort/index.js +0 -2
- package/lib/components/flat-table/sort/sort.component.js +8 -23
- package/lib/components/flat-table/sort/sort.style.js +0 -4
- package/lib/components/form/__internal__/form-summary.component.d.ts +2 -2
- package/lib/components/form/__internal__/form-summary.component.js +16 -40
- package/lib/components/form/__internal__/form-summary.style.js +45 -34
- package/lib/components/form/form.component.d.ts +1 -1
- package/lib/components/form/form.component.js +21 -513
- package/lib/components/form/form.style.js +78 -58
- package/lib/components/form/index.js +0 -2
- package/lib/components/global-header/global-header.component.d.ts +1 -1
- package/lib/components/global-header/global-header.component.js +24 -1045
- package/lib/components/global-header/index.js +0 -2
- package/lib/components/grid/grid-container/grid-container.component.d.ts +1 -1
- package/lib/components/grid/grid-container/grid-container.component.js +1 -1839
- package/lib/components/grid/grid-container/grid-container.style.js +0 -4
- package/lib/components/grid/grid-container/index.js +0 -2
- package/lib/components/grid/grid-item/grid-item.component.d.ts +1 -1
- package/lib/components/grid/grid-item/grid-item.component.js +1 -1240
- package/lib/components/grid/grid-item/grid-item.style.js +22 -38
- package/lib/components/grid/grid-item/index.js +0 -2
- package/lib/components/grid/index.js +0 -3
- package/lib/components/grouped-character/grouped-character.component.js +28 -53
- package/lib/components/grouped-character/grouped-character.utils.js +1 -5
- package/lib/components/grouped-character/index.js +0 -2
- package/lib/components/heading/heading.component.d.ts +1 -1
- package/lib/components/heading/heading.component.js +20 -205
- package/lib/components/heading/heading.style.js +34 -35
- package/lib/components/heading/index.js +0 -2
- package/lib/components/help/help.component.js +23 -44
- package/lib/components/help/help.style.js +9 -14
- package/lib/components/help/index.js +0 -2
- package/lib/components/hr/hr.component.js +8 -17
- package/lib/components/hr/hr.style.js +0 -5
- package/lib/components/hr/index.js +0 -2
- package/lib/components/i18n-provider/i18n-provider.component.d.ts +1 -1
- package/lib/components/i18n-provider/i18n-provider.component.js +9 -145
- package/lib/components/i18n-provider/index.js +0 -2
- package/lib/components/icon/icon-config.js +1 -1
- package/lib/components/icon/icon-unicodes.js +2 -3
- package/lib/components/icon/icon.component.js +30 -55
- package/lib/components/icon/icon.style.js +15 -32
- package/lib/components/icon/index.js +0 -2
- package/lib/components/icon-button/icon-button.component.js +17 -38
- package/lib/components/icon-button/icon-button.style.js +9 -14
- package/lib/components/icon-button/index.js +0 -2
- package/lib/components/image/image.component.d.ts +2 -2
- package/lib/components/image/image.component.js +9 -1694
- package/lib/components/image/image.style.js +24 -23
- package/lib/components/image/index.js +0 -2
- package/lib/components/inline-inputs/index.js +0 -2
- package/lib/components/inline-inputs/inline-inputs.component.d.ts +1 -1
- package/lib/components/inline-inputs/inline-inputs.component.js +18 -201
- package/lib/components/inline-inputs/inline-inputs.style.js +41 -32
- package/lib/components/link/index.js +0 -2
- package/lib/components/link/link.component.js +34 -52
- package/lib/components/link/link.config.js +1 -1
- package/lib/components/link/link.style.js +14 -24
- package/lib/components/link-preview/__internal__/placeholder.component.d.ts +2 -2
- package/lib/components/link-preview/__internal__/placeholder.component.js +18 -16
- package/lib/components/link-preview/index.js +0 -2
- package/lib/components/link-preview/link-preview.component.d.ts +2 -2
- package/lib/components/link-preview/link-preview.component.js +15 -43
- package/lib/components/link-preview/link-preview.style.js +17 -17
- package/lib/components/loader/index.js +0 -2
- package/lib/components/loader/loader-square.style.js +12 -21
- package/lib/components/loader/loader.component.d.ts +2 -2
- package/lib/components/loader/loader.component.js +9 -183
- package/lib/components/loader/loader.style.js +0 -5
- package/lib/components/loader-bar/index.js +0 -2
- package/lib/components/loader-bar/loader-bar.component.d.ts +2 -2
- package/lib/components/loader-bar/loader-bar.component.js +8 -180
- package/lib/components/loader-bar/loader-bar.style.js +16 -20
- package/lib/components/menu/__internal__/keyboard-navigation/index.js +4 -24
- package/lib/components/menu/__internal__/locators.js +1 -1
- package/lib/components/menu/__internal__/spec-helper/index.js +2 -8
- package/lib/components/menu/__internal__/submenu/index.js +0 -2
- package/lib/components/menu/__internal__/submenu/submenu.component.js +34 -88
- package/lib/components/menu/__internal__/submenu/submenu.context.js +0 -4
- package/lib/components/menu/__internal__/submenu/submenu.style.js +30 -33
- package/lib/components/menu/index.js +8 -15
- package/lib/components/menu/menu-divider/index.js +0 -2
- package/lib/components/menu/menu-divider/menu-divider.component.js +8 -19
- package/lib/components/menu/menu-divider/menu-divider.style.js +10 -13
- package/lib/components/menu/menu-full-screen/index.js +0 -2
- package/lib/components/menu/menu-full-screen/menu-full-screen.component.d.ts +1 -1
- package/lib/components/menu/menu-full-screen/menu-full-screen.component.js +18 -53
- package/lib/components/menu/menu-full-screen/menu-full-screen.style.js +19 -25
- package/lib/components/menu/menu-item/index.js +0 -2
- package/lib/components/menu/menu-item/menu-item.component.d.ts +1 -1
- package/lib/components/menu/menu-item/menu-item.component.js +32 -2112
- package/lib/components/menu/menu-item/menu-item.style.js +22 -31
- package/lib/components/menu/menu-segment-title/index.js +0 -2
- package/lib/components/menu/menu-segment-title/menu-segment-title.component.js +9 -20
- package/lib/components/menu/menu-segment-title/menu-segment-title.style.js +10 -13
- package/lib/components/menu/menu.component.d.ts +1 -1
- package/lib/components/menu/menu.component.js +13 -1900
- package/lib/components/menu/menu.context.js +1 -7
- package/lib/components/menu/menu.style.js +24 -24
- package/lib/components/menu/scrollable-block/index.js +0 -2
- package/lib/components/menu/scrollable-block/scrollable-block.component.d.ts +1 -1
- package/lib/components/menu/scrollable-block/scrollable-block.component.js +12 -34
- package/lib/components/menu/scrollable-block/scrollable-block.style.js +10 -17
- package/lib/components/message/index.js +0 -2
- package/lib/components/message/message-content/message-content.component.d.ts +1 -1
- package/lib/components/message/message-content/message-content.component.js +6 -17
- package/lib/components/message/message-content/message-content.style.js +6 -6
- package/lib/components/message/message.component.d.ts +1 -1
- package/lib/components/message/message.component.js +15 -196
- package/lib/components/message/message.style.js +15 -17
- package/lib/components/message/type-icon/type-icon.component.d.ts +2 -2
- package/lib/components/message/type-icon/type-icon.component.js +5 -15
- package/lib/components/message/type-icon/type-icon.style.js +16 -14
- package/lib/components/modal/__internal__/modal-manager.d.ts +1 -1
- package/lib/components/modal/__internal__/modal-manager.js +14 -34
- package/lib/components/modal/index.js +6 -9
- package/lib/components/modal/modal.component.d.ts +1 -1
- package/lib/components/modal/modal.component.js +14 -46
- package/lib/components/modal/modal.style.js +24 -21
- package/lib/components/multi-action-button/index.js +0 -2
- package/lib/components/multi-action-button/multi-action-button.component.d.ts +2 -2
- package/lib/components/multi-action-button/multi-action-button.component.js +23 -637
- package/lib/components/multi-action-button/multi-action-button.style.js +27 -29
- package/lib/components/navigation-bar/index.js +0 -2
- package/lib/components/navigation-bar/navigation-bar.component.js +12 -18
- package/lib/components/navigation-bar/navigation-bar.style.js +20 -20
- package/lib/components/note/__internal__/status-icon/index.js +0 -2
- package/lib/components/note/__internal__/status-icon/status-icon.component.js +5 -11
- package/lib/components/note/__internal__/status-icon/status-icon.style.js +0 -3
- package/lib/components/note/index.js +0 -2
- package/lib/components/note/note.component.d.ts +1 -1
- package/lib/components/note/note.component.js +15 -202
- package/lib/components/note/note.style.js +37 -30
- package/lib/components/number/index.js +0 -2
- package/lib/components/number/number.component.js +17 -35
- package/lib/components/numeral-date/index.js +0 -2
- package/lib/components/numeral-date/numeral-date-context.js +0 -4
- package/lib/components/numeral-date/numeral-date.component.d.ts +1 -1
- package/lib/components/numeral-date/numeral-date.component.js +49 -323
- package/lib/components/numeral-date/numeral-date.style.js +11 -19
- package/lib/components/pager/__internal__/pager-navigation-link.component.d.ts +1 -1
- package/lib/components/pager/__internal__/pager-navigation-link.component.js +16 -36
- package/lib/components/pager/__internal__/pager-navigation.component.d.ts +1 -1
- package/lib/components/pager/__internal__/pager-navigation.component.js +20 -58
- package/lib/components/pager/index.js +0 -2
- package/lib/components/pager/pager.component.d.ts +1 -1
- package/lib/components/pager/pager.component.js +38 -85
- package/lib/components/pager/pager.style.js +17 -22
- package/lib/components/pages/index.js +4 -7
- package/lib/components/pages/page/index.js +0 -2
- package/lib/components/pages/page/page.component.d.ts +1 -1
- package/lib/components/pages/page/page.component.js +10 -183
- package/lib/components/pages/page/page.style.js +0 -5
- package/lib/components/pages/pages.component.d.ts +1 -1
- package/lib/components/pages/pages.component.js +14 -82
- package/lib/components/pages/pages.config.js +1 -3
- package/lib/components/pages/pages.style.js +1 -7
- package/lib/components/password/index.js +0 -2
- package/lib/components/password/password.component.d.ts +2 -2
- package/lib/components/password/password.component.js +10 -557
- package/lib/components/password/password.style.js +1 -6
- package/lib/components/pill/index.js +0 -2
- package/lib/components/pill/pill.component.d.ts +1 -1
- package/lib/components/pill/pill.component.js +35 -253
- package/lib/components/pill/pill.style.config.js +0 -2
- package/lib/components/pill/pill.style.js +14 -28
- package/lib/components/pod/index.js +0 -2
- package/lib/components/pod/pod.component.js +29 -47
- package/lib/components/pod/pod.config.js +1 -1
- package/lib/components/pod/pod.style.js +98 -78
- package/lib/components/popover-container/index.js +0 -2
- package/lib/components/popover-container/popover-container.component.d.ts +3 -3
- package/lib/components/popover-container/popover-container.component.js +73 -276
- package/lib/components/popover-container/popover-container.style.js +11 -17
- package/lib/components/portal/index.js +0 -2
- package/lib/components/portal/portal.d.ts +1 -1
- package/lib/components/portal/portal.js +14 -34
- package/lib/components/portrait/index.js +0 -2
- package/lib/components/portrait/portrait-gravatar.component.d.ts +2 -2
- package/lib/components/portrait/portrait-gravatar.component.js +8 -24
- package/lib/components/portrait/portrait-initials.component.d.ts +2 -2
- package/lib/components/portrait/portrait-initials.component.js +20 -36
- package/lib/components/portrait/portrait.component.d.ts +1 -1
- package/lib/components/portrait/portrait.component.js +24 -218
- package/lib/components/portrait/portrait.style.js +35 -42
- package/lib/components/preview/__internal__/preview-placeholder.component.d.ts +2 -2
- package/lib/components/preview/__internal__/preview-placeholder.component.js +9 -23
- package/lib/components/preview/__internal__/preview-placeholder.style.js +14 -12
- package/lib/components/preview/index.js +0 -2
- package/lib/components/preview/preview.component.d.ts +1 -1
- package/lib/components/preview/preview.component.js +8 -181
- package/lib/components/preview/preview.style.js +3 -6
- package/lib/components/profile/index.js +0 -2
- package/lib/components/profile/profile.component.d.ts +2 -2
- package/lib/components/profile/profile.component.js +11 -32
- package/lib/components/profile/profile.style.d.ts +1 -1
- package/lib/components/profile/profile.style.js +38 -27
- package/lib/components/progress-tracker/index.js +0 -2
- package/lib/components/progress-tracker/progress-tracker.component.d.ts +2 -2
- package/lib/components/progress-tracker/progress-tracker.component.js +24 -214
- package/lib/components/progress-tracker/progress-tracker.config.js +0 -1
- package/lib/components/progress-tracker/progress-tracker.style.js +65 -57
- package/lib/components/radio-button/index.js +0 -4
- package/lib/components/radio-button/radio-button-group.component.d.ts +1 -1
- package/lib/components/radio-button/radio-button-group.component.js +1 -199
- package/lib/components/radio-button/radio-button-group.style.js +10 -11
- package/lib/components/radio-button/radio-button-svg.component.d.ts +1 -1
- package/lib/components/radio-button/radio-button-svg.component.js +0 -7
- package/lib/components/radio-button/radio-button.component.js +47 -66
- package/lib/components/radio-button/radio-button.style.js +13 -24
- package/lib/components/search/index.js +0 -2
- package/lib/components/search/search-button.style.js +6 -9
- package/lib/components/search/search.component.js +33 -70
- package/lib/components/search/search.style.js +13 -24
- package/lib/components/select/__internal__/select-list-context.js +0 -4
- package/lib/components/select/__internal__/select-text/index.js +0 -2
- package/lib/components/select/__internal__/select-text/select-text.component.d.ts +1 -1
- package/lib/components/select/__internal__/select-text/select-text.component.js +13 -34
- package/lib/components/select/__internal__/select-text/select-text.style.js +13 -16
- package/lib/components/select/filterable-select/filterable-select.component.js +63 -134
- package/lib/components/select/filterable-select/index.js +0 -2
- package/lib/components/select/index.js +12 -19
- package/lib/components/select/list-action-button/index.js +0 -2
- package/lib/components/select/list-action-button/list-action-button.component.js +7 -17
- package/lib/components/select/list-action-button/list-action-button.style.js +0 -4
- package/lib/components/select/multi-select/index.js +0 -2
- package/lib/components/select/multi-select/multi-select.component.js +73 -151
- package/lib/components/select/multi-select/multi-select.style.js +13 -17
- package/lib/components/select/option/index.js +0 -2
- package/lib/components/select/option/option.component.js +24 -35
- package/lib/components/select/option/option.style.js +16 -14
- package/lib/components/select/option-group-header/index.js +0 -2
- package/lib/components/select/option-group-header/option-group-header.component.js +8 -15
- package/lib/components/select/option-group-header/option-group-header.style.js +0 -4
- package/lib/components/select/option-row/index.js +0 -2
- package/lib/components/select/option-row/option-row.component.js +16 -28
- package/lib/components/select/option-row/option-row.style.js +16 -14
- package/lib/components/select/select-list/index.js +0 -2
- package/lib/components/select/select-list/select-list-container.style.js +18 -13
- package/lib/components/select/select-list/select-list.component.js +55 -120
- package/lib/components/select/select-list/select-list.style.js +22 -17
- package/lib/components/select/select-textbox/index.js +0 -2
- package/lib/components/select/select-textbox/select-textbox.component.js +60 -81
- package/lib/components/select/select.style.js +14 -21
- package/lib/components/select/simple-select/index.js +0 -2
- package/lib/components/select/simple-select/simple-select.component.js +50 -115
- package/lib/components/select/utils/get-next-child-by-text.js +4 -14
- package/lib/components/select/utils/get-next-index-by-key.js +1 -15
- package/lib/components/select/utils/highlight-part-of-text.js +0 -13
- package/lib/components/select/utils/is-expected-option.js +0 -9
- package/lib/components/select/utils/is-expected-value.js +0 -2
- package/lib/components/select/utils/is-navigation-key.js +0 -1
- package/lib/components/select/utils/matching-text.style.js +0 -3
- package/lib/components/select/utils/with-filter.hoc.js +17 -64
- package/lib/components/settings-row/index.js +0 -2
- package/lib/components/settings-row/settings-row.component.d.ts +1 -1
- package/lib/components/settings-row/settings-row.component.js +11 -183
- package/lib/components/settings-row/settings-row.style.js +9 -14
- package/lib/components/show-edit-pod/index.js +0 -2
- package/lib/components/show-edit-pod/show-edit-pod.component.js +34 -88
- package/lib/components/show-edit-pod/show-edit-pod.style.js +0 -6
- package/lib/components/sidebar/__internal__/sidebar-header/index.js +0 -2
- package/lib/components/sidebar/__internal__/sidebar-header/sidebar-header.component.d.ts +1 -1
- package/lib/components/sidebar/__internal__/sidebar-header/sidebar-header.component.js +14 -177
- package/lib/components/sidebar/__internal__/sidebar-header/sidebar-header.style.js +9 -14
- package/lib/components/sidebar/index.js +6 -9
- package/lib/components/sidebar/sidebar.component.js +29 -52
- package/lib/components/sidebar/sidebar.config.js +1 -1
- package/lib/components/sidebar/sidebar.style.js +15 -23
- package/lib/components/simple-color-picker/index.js +4 -7
- package/lib/components/simple-color-picker/simple-color/index.js +0 -2
- package/lib/components/simple-color-picker/simple-color/simple-color.component.js +3 -14
- package/lib/components/simple-color-picker/simple-color/simple-color.style.js +28 -30
- package/lib/components/simple-color-picker/simple-color-picker.component.js +36 -71
- package/lib/components/simple-color-picker/simple-color-picker.style.js +16 -20
- package/lib/components/split-button/index.js +0 -2
- package/lib/components/split-button/split-button-children.style.js +11 -15
- package/lib/components/split-button/split-button-toggle.style.js +12 -16
- package/lib/components/split-button/split-button.component.d.ts +1 -1
- package/lib/components/split-button/split-button.component.js +22 -544
- package/lib/components/split-button/split-button.config.js +1 -1
- package/lib/components/split-button/split-button.style.js +0 -6
- package/lib/components/step-sequence/index.js +0 -3
- package/lib/components/step-sequence/step-sequence-item/index.js +0 -2
- package/lib/components/step-sequence/step-sequence-item/step-sequence-item.component.d.ts +1 -1
- package/lib/components/step-sequence/step-sequence-item/step-sequence-item.component.js +14 -39
- package/lib/components/step-sequence/step-sequence-item/step-sequence-item.style.js +7 -12
- package/lib/components/step-sequence/step-sequence.component.d.ts +1 -1
- package/lib/components/step-sequence/step-sequence.component.js +8 -328
- package/lib/components/step-sequence/step-sequence.config.js +1 -1
- package/lib/components/step-sequence/step-sequence.style.js +9 -12
- package/lib/components/switch/__internal__/switch-slider-panel.style.js +10 -14
- package/lib/components/switch/__internal__/switch-slider.component.d.ts +2 -2
- package/lib/components/switch/__internal__/switch-slider.component.js +11 -32
- package/lib/components/switch/__internal__/switch-slider.style.js +17 -22
- package/lib/components/switch/index.js +0 -2
- package/lib/components/switch/switch.component.js +42 -62
- package/lib/components/switch/switch.style.js +12 -23
- package/lib/components/tabs/__internal__/tab-title/index.js +6 -9
- package/lib/components/tabs/__internal__/tab-title/tab-title.component.js +43 -73
- package/lib/components/tabs/__internal__/tab-title/tab-title.style.js +71 -60
- package/lib/components/tabs/__internal__/tabs-header/index.js +0 -2
- package/lib/components/tabs/__internal__/tabs-header/tabs-header.component.d.ts +1 -1
- package/lib/components/tabs/__internal__/tabs-header/tabs-header.component.js +20 -40
- package/lib/components/tabs/__internal__/tabs-header/tabs-header.style.js +57 -42
- package/lib/components/tabs/index.js +4 -5
- package/lib/components/tabs/tab/index.js +6 -9
- package/lib/components/tabs/tab/tab.component.d.ts +1 -1
- package/lib/components/tabs/tab/tab.component.js +30 -215
- package/lib/components/tabs/tab/tab.style.js +10 -14
- package/lib/components/tabs/tabs.component.d.ts +1 -1
- package/lib/components/tabs/tabs.component.js +47 -258
- package/lib/components/tabs/tabs.style.js +11 -17
- package/lib/components/text-editor/__internal__/decorators/index.js +0 -5
- package/lib/components/text-editor/__internal__/decorators/link-decorator.d.ts +1 -1
- package/lib/components/text-editor/__internal__/decorators/link-decorator.js +16 -13
- package/lib/components/text-editor/__internal__/editor-counter/editor-counter.component.d.ts +2 -2
- package/lib/components/text-editor/__internal__/editor-counter/editor-counter.component.js +19 -30
- package/lib/components/text-editor/__internal__/editor-counter/editor-counter.style.js +6 -6
- package/lib/components/text-editor/__internal__/editor-counter/index.js +0 -2
- package/lib/components/text-editor/__internal__/editor-link/editor-link.component.d.ts +1 -1
- package/lib/components/text-editor/__internal__/editor-link/editor-link.component.js +12 -28
- package/lib/components/text-editor/__internal__/editor-link/editor-link.style.js +0 -4
- package/lib/components/text-editor/__internal__/editor-link/index.js +0 -2
- package/lib/components/text-editor/__internal__/label-wrapper/index.js +0 -2
- package/lib/components/text-editor/__internal__/label-wrapper/label-wrapper.component.d.ts +1 -1
- package/lib/components/text-editor/__internal__/label-wrapper/label-wrapper.component.js +10 -14
- package/lib/components/text-editor/__internal__/toolbar/index.js +0 -2
- package/lib/components/text-editor/__internal__/toolbar/toolbar-button/index.js +0 -2
- package/lib/components/text-editor/__internal__/toolbar/toolbar-button/toolbar-button.component.js +14 -20
- package/lib/components/text-editor/__internal__/toolbar/toolbar-button/toolbar-button.style.js +9 -12
- package/lib/components/text-editor/__internal__/toolbar/toolbar.component.d.ts +1 -1
- package/lib/components/text-editor/__internal__/toolbar/toolbar.component.js +14 -53
- package/lib/components/text-editor/__internal__/toolbar/toolbar.style.js +1 -5
- package/lib/components/text-editor/__internal__/utils/index.js +22 -23
- package/lib/components/text-editor/__internal__/utils/utils.js +16 -52
- package/lib/components/text-editor/index.js +6 -9
- package/lib/components/text-editor/text-editor.component.js +46 -92
- package/lib/components/text-editor/text-editor.style.js +20 -22
- package/lib/components/text-editor/types.js +1 -1
- package/lib/components/textarea/index.js +0 -2
- package/lib/components/textarea/textarea.component.js +57 -99
- package/lib/components/textarea/textarea.style.js +15 -19
- package/lib/components/textbox/__internal__/prefix.style.js +6 -7
- package/lib/components/textbox/index.js +0 -2
- package/lib/components/textbox/textbox.component.js +65 -98
- package/lib/components/textbox/textbox.style.js +10 -11
- package/lib/components/tile/index.js +0 -2
- package/lib/components/tile/tile-footer/index.js +0 -2
- package/lib/components/tile/tile-footer/tile-footer.component.d.ts +1 -1
- package/lib/components/tile/tile-footer/tile-footer.component.js +7 -171
- package/lib/components/tile/tile-footer/tile-footer.style.js +9 -15
- package/lib/components/tile/tile.component.d.ts +1 -1
- package/lib/components/tile/tile.component.js +13 -337
- package/lib/components/tile/tile.style.js +27 -35
- package/lib/components/tile-select/__internal__/accordion/accordion.component.d.ts +1 -1
- package/lib/components/tile-select/__internal__/accordion/accordion.component.js +9 -331
- package/lib/components/tile-select/__internal__/accordion/accordion.style.js +1 -5
- package/lib/components/tile-select/__internal__/accordion/index.js +0 -2
- package/lib/components/tile-select/index.js +0 -3
- package/lib/components/tile-select/tile-select-group.component.d.ts +1 -1
- package/lib/components/tile-select/tile-select-group.component.js +13 -189
- package/lib/components/tile-select/tile-select.component.js +34 -52
- package/lib/components/tile-select/tile-select.style.d.ts +1 -1
- package/lib/components/tile-select/tile-select.style.js +67 -51
- package/lib/components/toast/index.js +0 -2
- package/lib/components/toast/toast.component.js +19 -45
- package/lib/components/toast/toast.style.d.ts +1 -1
- package/lib/components/toast/toast.style.js +64 -52
- package/lib/components/tooltip/index.js +0 -2
- package/lib/components/tooltip/tooltip-pointer.style.js +11 -16
- package/lib/components/tooltip/tooltip.component.js +42 -58
- package/lib/components/tooltip/tooltip.style.js +13 -19
- package/lib/components/typography/index.js +6 -9
- package/lib/components/typography/list.component.d.ts +2 -2
- package/lib/components/typography/list.component.js +24 -945
- package/lib/components/typography/typography.component.js +45 -77
- package/lib/components/vertical-divider/index.js +0 -2
- package/lib/components/vertical-divider/vertical-divider.component.js +11 -20
- package/lib/components/vertical-divider/vertical-divider.style.js +23 -20
- package/lib/components/vertical-menu/index.js +4 -9
- package/lib/components/vertical-menu/vertical-menu-full-screen.component.d.ts +1 -1
- package/lib/components/vertical-menu/vertical-menu-full-screen.component.js +14 -40
- package/lib/components/vertical-menu/vertical-menu-full-screen.context.js +0 -4
- package/lib/components/vertical-menu/vertical-menu-item.component.d.ts +1 -1
- package/lib/components/vertical-menu/vertical-menu-item.component.js +16 -219
- package/lib/components/vertical-menu/vertical-menu-trigger.component.d.ts +1 -1
- package/lib/components/vertical-menu/vertical-menu-trigger.component.js +9 -179
- package/lib/components/vertical-menu/vertical-menu.component.d.ts +1 -1
- package/lib/components/vertical-menu/vertical-menu.component.js +10 -27
- package/lib/components/vertical-menu/vertical-menu.style.js +22 -22
- package/lib/hooks/__internal__/useCharacterCount/index.js +0 -2
- package/lib/hooks/__internal__/useCharacterCount/useCharacterCount.d.ts +1 -1
- package/lib/hooks/__internal__/useCharacterCount/useCharacterCount.js +6 -13
- package/lib/hooks/__internal__/useClickAwayListener/index.js +0 -2
- package/lib/hooks/__internal__/useClickAwayListener/useClickAwayListener.js +2 -5
- package/lib/hooks/__internal__/useFloating/index.js +0 -2
- package/lib/hooks/__internal__/useFloating/useFloating.js +16 -22
- package/lib/hooks/__internal__/useFormSpacing/add-form-spacing/index.d.ts +1 -1
- package/lib/hooks/__internal__/useFormSpacing/add-form-spacing/index.js +2 -7
- package/lib/hooks/__internal__/useFormSpacing/index.js +0 -7
- package/lib/hooks/__internal__/useInputAccessibility/index.js +0 -2
- package/lib/hooks/__internal__/useInputAccessibility/useInputAccessibility.js +10 -12
- package/lib/hooks/__internal__/useIsAboveBreakpoint/index.js +0 -2
- package/lib/hooks/__internal__/useIsAboveBreakpoint/useIsAboveBreakpoint.js +0 -3
- package/lib/hooks/__internal__/useIsStickyFooterForm/index.js +0 -2
- package/lib/hooks/__internal__/useIsStickyFooterForm/useIsStickyFooterForm.js +3 -14
- package/lib/hooks/__internal__/useLocale/index.js +0 -2
- package/lib/hooks/__internal__/useLocale/useLocale.js +0 -4
- package/lib/hooks/__internal__/useMenuKeyboardNavigation/index.js +0 -2
- package/lib/hooks/__internal__/useMenuKeyboardNavigation/useMenuKeyboardNavigation.js +8 -29
- package/lib/hooks/__internal__/useModalManager/index.js +0 -2
- package/lib/hooks/__internal__/useModalManager/useModalManager.js +8 -16
- package/lib/hooks/__internal__/usePrevious/index.js +0 -2
- package/lib/hooks/__internal__/useResizeObserver/index.js +0 -2
- package/lib/hooks/__internal__/useResizeObserver/useResizeObserver.js +4 -11
- package/lib/hooks/__internal__/useScrollBlock/index.js +0 -2
- package/lib/hooks/__internal__/useScrollBlock/scroll-block-manager.js +12 -22
- package/lib/hooks/__internal__/useScrollBlock/useScrollBlock.js +31 -35
- package/lib/hooks/__internal__/useStableCallback/index.js +0 -2
- package/lib/hooks/__internal__/useStableCallback/useStableCallback.js +7 -8
- package/lib/hooks/__internal__/useThrottle/index.js +0 -2
- package/lib/hooks/__internal__/useThrottle/useThrottle.js +1 -4
- package/lib/hooks/__internal__/useUniqueId/index.d.ts +1 -1
- package/lib/hooks/__internal__/useUniqueId/index.js +0 -5
- package/lib/hooks/useMediaQuery/index.js +0 -2
- package/lib/hooks/useMediaQuery/useMediaQuery.js +0 -8
- package/lib/locales/date-fns-locales/index.js +0 -2
- package/lib/locales/en-gb.js +3 -10
- package/lib/locales/index.js +0 -3
- package/lib/locales/pl-pl.js +3 -26
- package/lib/style/design-tokens/carbon-scoped-tokens-provider/carbon-scoped-tokens-provider.component.js +7 -8
- package/lib/style/design-tokens/carbon-scoped-tokens-provider/index.js +0 -2
- package/lib/style/design-tokens/debug-theme.util.js +7 -13
- package/lib/style/design-tokens/generate-css-variables.util.d.ts +1 -1
- package/lib/style/design-tokens/generate-css-variables.util.js +2 -4
- package/lib/style/global-style.js +0 -3
- package/lib/style/palette/index.js +12 -16
- package/lib/style/themes/aegean/aegean-theme.config.js +14 -20
- package/lib/style/themes/aegean/index.js +0 -5
- package/lib/style/themes/base/base-theme.config.js +4 -12
- package/lib/style/themes/base/index.js +4 -12
- package/lib/style/themes/index.js +9 -16
- package/lib/style/themes/medium/index.js +0 -3
- package/lib/style/themes/mint/index.js +0 -5
- package/lib/style/themes/mint/mint-theme.config.js +14 -20
- package/lib/style/themes/none/index.js +0 -5
- package/lib/style/themes/none/none-theme.config.js +0 -2
- package/lib/style/themes/sage/index.d.ts +1 -1
- package/lib/style/themes/sage/index.js +4 -6
- package/lib/style/themes/small/index.js +0 -3
- package/lib/style/themes/test-utils.js +4 -6
- package/lib/style/utils/add-hex-symbols.js +0 -3
- package/lib/style/utils/at-opacity.d.ts +1 -1
- package/lib/style/utils/at-opacity.js +2 -6
- package/lib/style/utils/color.js +12 -23
- package/lib/style/utils/filter-out-position-props.js +0 -4
- package/lib/style/utils/filter-out-styled-system-spacing-props.js +4 -5
- package/lib/style/utils/filter-styled-system-margin-props.js +0 -4
- package/lib/style/utils/filter-styled-system-padding-props.js +0 -4
- package/lib/style/utils/form-style-utils.js +3 -20
- package/lib/style/utils/get-color-value.js +0 -5
- package/lib/style/utils/get-rgb-values.js +1 -2
- package/lib/style/utils/index.js +4 -8
- package/lib/style/utils/merge-deep.js +9 -9
- package/lib/style/utils/mix.d.ts +1 -1
- package/lib/style/utils/mix.js +8 -12
- package/lib/style/utils/shade.js +0 -4
- package/lib/style/utils/tint.js +0 -4
- package/lib/style/utils/visually-hidden.js +0 -3
- package/lib/style/utils/width.js +8 -9
- package/package.json +93 -101
|
@@ -2,12 +2,10 @@ const setupResizeObserverMock = () => {
|
|
|
2
2
|
if (!window) {
|
|
3
3
|
return;
|
|
4
4
|
}
|
|
5
|
-
|
|
6
5
|
window.ResizeObserver = window.ResizeObserver || jest.fn().mockImplementation(() => ({
|
|
7
6
|
disconnect: jest.fn(),
|
|
8
7
|
observe: jest.fn(),
|
|
9
8
|
unobserve: jest.fn()
|
|
10
9
|
}));
|
|
11
10
|
};
|
|
12
|
-
|
|
13
11
|
export default setupResizeObserverMock;
|
|
@@ -6,7 +6,7 @@ import { mockMatchMedia } from "./mock-match-media";
|
|
|
6
6
|
declare const toCSSCase: (str: string) => string;
|
|
7
7
|
declare const assertStyleMatch: <Props>(styleSpec: {
|
|
8
8
|
[key: string]: string | number | undefined;
|
|
9
|
-
}, component: ReactWrapper<Props, {}, import("react").Component<{}, {}, any>> | ShallowWrapper<Props, {}, import("react").Component<{}, {}, any>> | ReactTestRendererJSON | ReactTestRendererJSON[] | null, opts?: jest.Options
|
|
9
|
+
}, component: ReactWrapper<Props, {}, import("react").Component<{}, {}, any>> | ShallowWrapper<Props, {}, import("react").Component<{}, {}, any>> | ReactTestRendererJSON | ReactTestRendererJSON[] | null, opts?: jest.Options) => void;
|
|
10
10
|
declare const makeArrayKeys: (n: number) => number[];
|
|
11
11
|
declare const keyboard: Record<string, () => void>;
|
|
12
12
|
declare const simulate: {
|
|
@@ -36,17 +36,17 @@ declare const paddingProps: readonly [readonly ["p", "padding"], readonly ["pl",
|
|
|
36
36
|
declare type PaddingProps = {
|
|
37
37
|
[K in typeof paddingProps[number][0]]?: string | number;
|
|
38
38
|
};
|
|
39
|
-
export declare const getDefaultValue: (value?: string | number
|
|
40
|
-
declare const testStyledSystemMargin: (component: (spacingProps?: MarginProps
|
|
41
|
-
declare const testStyledSystemPadding: (component: (spacingProps?: PaddingProps
|
|
42
|
-
declare const testStyledSystemSpacing: (component: (spacingProps?: MarginProps | PaddingProps
|
|
39
|
+
export declare const getDefaultValue: (value?: string | number) => string | number | undefined;
|
|
40
|
+
declare const testStyledSystemMargin: (component: (spacingProps?: MarginProps) => JSX.Element, defaults?: MarginProps, styleContainer?: ((wrapper: ReactWrapper) => ReactWrapper) | undefined, assertOpts?: jest.Options) => void;
|
|
41
|
+
declare const testStyledSystemPadding: (component: (spacingProps?: PaddingProps) => JSX.Element, defaults?: PaddingProps, styleContainer?: ((wrapper: ReactWrapper) => ReactWrapper) | undefined, assertOpts?: jest.Options) => void;
|
|
42
|
+
declare const testStyledSystemSpacing: (component: (spacingProps?: MarginProps | PaddingProps) => JSX.Element, defaults?: MarginProps | PaddingProps, styleContainer?: ((wrapper: ReactWrapper) => ReactWrapper) | undefined, assertOpts?: jest.Options) => void;
|
|
43
43
|
declare const testStyledSystemColor: (component: (colorProperties?: any) => JSX.Element, styleContainer?: ((wrapper: ReactWrapper) => void) | undefined) => void;
|
|
44
44
|
declare const testStyledSystemWidth: (component: (widthProperties?: {
|
|
45
45
|
width: string;
|
|
46
|
-
}
|
|
47
|
-
declare const testStyledSystemLayout: (component: (layoutProperties?: LayoutProps
|
|
48
|
-
declare const testStyledSystemFlexBox: (component: (flexboxProperties?: FlexboxProps
|
|
49
|
-
declare const testStyledSystemBackground: (component: (backgroundProperties?: BackgroundProps
|
|
50
|
-
declare const testStyledSystemPosition: (component: (positionProperties?: PositionProps
|
|
46
|
+
}) => JSX.Element, styleContainer?: ((wrapper: ReactWrapper) => ReactWrapper) | undefined) => void;
|
|
47
|
+
declare const testStyledSystemLayout: (component: (layoutProperties?: LayoutProps) => JSX.Element, styleContainer?: ((wrapper: ReactWrapper) => ReactWrapper) | undefined) => void;
|
|
48
|
+
declare const testStyledSystemFlexBox: (component: (flexboxProperties?: FlexboxProps) => JSX.Element, styleContainer?: ((wrapper: ReactWrapper) => ReactWrapper) | undefined) => void;
|
|
49
|
+
declare const testStyledSystemBackground: (component: (backgroundProperties?: BackgroundProps) => JSX.Element, styleContainer?: ((wrapper: ReactWrapper) => ReactWrapper) | undefined) => void;
|
|
50
|
+
declare const testStyledSystemPosition: (component: (positionProperties?: PositionProps) => JSX.Element, styleContainer?: ((wrapper: ReactWrapper) => ReactWrapper) | undefined) => void;
|
|
51
51
|
declare const expectConsoleOutput: (message: string, type?: "warn" | "error") => () => void;
|
|
52
52
|
export { assertStyleMatch, toCSSCase, hoverList, selectedItemOf, childrenFrom, makeArrayKeys, keyboard, assertKeyboardTraversal, assertHoverTraversal, listFrom, click, simulate, carbonThemesJestTable, mockMatchMedia, testStyledSystemSpacing, testStyledSystemMargin, testStyledSystemPadding, testStyledSystemColor, testStyledSystemWidth, testStyledSystemLayout, testStyledSystemFlexBox, testStyledSystemBackground, testStyledSystemPosition, expectConsoleOutput, };
|
|
@@ -1,104 +1,85 @@
|
|
|
1
1
|
/* eslint-disable jest/no-conditional-expect */
|
|
2
|
-
|
|
3
2
|
/* eslint-disable jest/no-identical-title */
|
|
4
|
-
|
|
5
3
|
/* eslint-disable jest/no-export */
|
|
6
4
|
import { mount } from "enzyme";
|
|
7
5
|
import { sprintf } from "sprintf-js";
|
|
8
6
|
import { space } from "../style/themes/base/base-theme.config";
|
|
9
7
|
import { carbonThemeList } from "../style/themes";
|
|
10
8
|
import { mockMatchMedia } from "./mock-match-media";
|
|
11
|
-
|
|
12
9
|
const isUpper = char => char.toUpperCase() === char;
|
|
13
|
-
|
|
14
10
|
const humpToDash = (acc, char) => `${acc}${isUpper(char) ? `-${char.toLowerCase()}` : char}`;
|
|
15
|
-
|
|
16
11
|
const toCSSCase = str => {
|
|
17
12
|
return str.split("").reduce(humpToDash, "");
|
|
18
13
|
};
|
|
19
|
-
|
|
20
14
|
const assertStyleMatch = (styleSpec, component, opts) => {
|
|
21
|
-
Object.entries(styleSpec).forEach(
|
|
15
|
+
Object.entries(styleSpec).forEach(_ref => {
|
|
16
|
+
let [attr, value] = _ref;
|
|
22
17
|
expect(component).toHaveStyleRule(toCSSCase(attr), value, opts);
|
|
23
18
|
});
|
|
24
19
|
};
|
|
25
|
-
|
|
26
20
|
const makeArrayKeys = n => [...Array(n).keys()];
|
|
27
|
-
|
|
28
21
|
const dispatchKeyPress = code => {
|
|
29
22
|
const ev = new KeyboardEvent("keydown", {
|
|
30
23
|
key: code
|
|
31
24
|
});
|
|
32
25
|
document.dispatchEvent(ev);
|
|
33
26
|
};
|
|
34
|
-
|
|
35
27
|
const keys = ["ArrowUp", "ArrowDown", "ArrowRight", "ArrowLeft", "Enter", "Tab", " ", "Escape", "End", "Home", "D", "E", "P", "Z", "1"];
|
|
36
28
|
const keyboard = keys.reduce((acc, key) => {
|
|
37
29
|
const methodName = `press${key === " " ? "Space" : key}`;
|
|
38
|
-
|
|
39
30
|
acc[methodName] = () => dispatchKeyPress(key);
|
|
40
|
-
|
|
41
31
|
return acc;
|
|
42
|
-
}, {});
|
|
32
|
+
}, {});
|
|
33
|
+
|
|
34
|
+
// Build an object of Enzyme simulate helpers
|
|
43
35
|
// e.g. simulate.keydown.pressTab(target, { shiftKey: true })
|
|
44
36
|
// e.g. simulate.keydown.pressEscape(target)
|
|
45
|
-
|
|
46
37
|
const keydown = keys.reduce((acc, key) => {
|
|
47
38
|
const methodName = `press${key === " " ? "Space" : key}`;
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
39
|
+
acc[methodName] = function (target) {
|
|
40
|
+
let {
|
|
41
|
+
shiftKey
|
|
42
|
+
} = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {
|
|
43
|
+
shiftKey: false
|
|
44
|
+
};
|
|
54
45
|
target.simulate("keydown", {
|
|
55
46
|
shiftKey,
|
|
56
47
|
key
|
|
57
48
|
});
|
|
58
49
|
};
|
|
59
|
-
|
|
60
50
|
return acc;
|
|
61
51
|
}, {});
|
|
62
52
|
const simulate = {
|
|
63
53
|
keydown
|
|
64
54
|
};
|
|
65
|
-
|
|
66
55
|
const listFrom = wrapper => wrapper.find("ul");
|
|
67
|
-
|
|
68
56
|
const childrenFrom = node => node.children();
|
|
69
|
-
|
|
70
57
|
const hoverList = wrapper => item => {
|
|
71
58
|
childrenFrom(listFrom(wrapper)).at(item).simulate("mouseover");
|
|
72
59
|
};
|
|
73
|
-
|
|
74
60
|
const simulateEvent = eventName => wrapper => wrapper.simulate(eventName);
|
|
75
|
-
|
|
76
61
|
const click = simulateEvent("click");
|
|
77
|
-
|
|
78
62
|
const selectedItemOf = wrapper => wrapper.state().selectedItem;
|
|
79
|
-
|
|
80
63
|
const isUnique = (val, index, self) => self.indexOf(val) === index;
|
|
81
|
-
|
|
82
64
|
const isSelectableGiven = nonSelectables => i => !nonSelectables.includes(i);
|
|
83
|
-
|
|
84
65
|
const selectedItemReducer = method => wrapper => (acc, i) => {
|
|
85
66
|
method(wrapper)(i);
|
|
86
67
|
return [...acc, selectedItemOf(wrapper)];
|
|
87
68
|
};
|
|
88
|
-
|
|
89
69
|
const arraysEqual = (arr1, arr2) => arr1.sort().join(",") === arr2.sort().join(",");
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
70
|
+
const assertCorrectTraversal = method => expect => _ref2 => {
|
|
71
|
+
let {
|
|
72
|
+
num,
|
|
73
|
+
nonSelectables = []
|
|
74
|
+
} = _ref2;
|
|
75
|
+
return wrapper => {
|
|
76
|
+
const array = makeArrayKeys(num);
|
|
77
|
+
const validIndexes = array.filter(isSelectableGiven(nonSelectables));
|
|
78
|
+
const selectedItem = selectedItemOf(wrapper);
|
|
79
|
+
const indexesThatWereSelected = array.reduce(selectedItemReducer(method)(wrapper), [selectedItem]).filter(isUnique);
|
|
80
|
+
expect(arraysEqual(validIndexes, indexesThatWereSelected)).toBeTruthy();
|
|
81
|
+
};
|
|
100
82
|
};
|
|
101
|
-
|
|
102
83
|
const assertKeyboardTraversal = assertCorrectTraversal(() => keyboard.pressArrowDown)(expect);
|
|
103
84
|
const assertHoverTraversal = assertCorrectTraversal(wrapper => hoverList(wrapper))(expect);
|
|
104
85
|
const carbonThemesJestTable = carbonThemeList.map(theme => [theme.name, theme]);
|
|
@@ -114,25 +95,21 @@ export const getDefaultValue = value => {
|
|
|
114
95
|
const spaceArrayLength = space.length - 1;
|
|
115
96
|
if (value === undefined) return value;
|
|
116
97
|
const parsedValue = +value;
|
|
117
|
-
|
|
118
98
|
if (typeof value === "string" && parsedValue > spaceArrayLength) {
|
|
119
99
|
return `${value}px`;
|
|
120
100
|
}
|
|
121
|
-
|
|
122
101
|
if (parsedValue <= spaceArrayLength) {
|
|
123
102
|
return space[parsedValue];
|
|
124
103
|
}
|
|
125
|
-
|
|
126
104
|
if (parsedValue > spaceArrayLength) {
|
|
127
105
|
return `${parsedValue * 8}px`;
|
|
128
106
|
}
|
|
129
|
-
|
|
130
107
|
return value;
|
|
131
108
|
};
|
|
132
|
-
|
|
133
109
|
const testStyledSystemMargin = (component, defaults, styleContainer, assertOpts) => {
|
|
134
110
|
describe("default props", () => {
|
|
135
|
-
const wrapper = mount(component({
|
|
111
|
+
const wrapper = mount(component({
|
|
112
|
+
...defaults
|
|
136
113
|
}));
|
|
137
114
|
const StyleElement = styleContainer ? styleContainer(wrapper) : wrapper;
|
|
138
115
|
it("should set the correct margins", () => {
|
|
@@ -141,7 +118,6 @@ const testStyledSystemMargin = (component, defaults, styleContainer, assertOpts)
|
|
|
141
118
|
let marginRight;
|
|
142
119
|
let marginTop;
|
|
143
120
|
let marginBottom;
|
|
144
|
-
|
|
145
121
|
if (defaults) {
|
|
146
122
|
margin = getDefaultValue(defaults.m);
|
|
147
123
|
marginLeft = getDefaultValue(defaults.ml || defaults.mx);
|
|
@@ -169,7 +145,8 @@ const testStyledSystemMargin = (component, defaults, styleContainer, assertOpts)
|
|
|
169
145
|
const props = {
|
|
170
146
|
[styledSystemProp]: 2
|
|
171
147
|
};
|
|
172
|
-
const wrapper = mount(component({
|
|
148
|
+
const wrapper = mount(component({
|
|
149
|
+
...props
|
|
173
150
|
}));
|
|
174
151
|
assertStyleMatch({
|
|
175
152
|
[propName]: "var(--spacing200)"
|
|
@@ -177,10 +154,10 @@ const testStyledSystemMargin = (component, defaults, styleContainer, assertOpts)
|
|
|
177
154
|
});
|
|
178
155
|
});
|
|
179
156
|
};
|
|
180
|
-
|
|
181
157
|
const testStyledSystemPadding = (component, defaults, styleContainer, assertOpts) => {
|
|
182
158
|
describe("default props", () => {
|
|
183
|
-
const wrapper = mount(component({
|
|
159
|
+
const wrapper = mount(component({
|
|
160
|
+
...defaults
|
|
184
161
|
}));
|
|
185
162
|
const StyleElement = styleContainer ? styleContainer(wrapper) : wrapper;
|
|
186
163
|
it("should set the correct paddings", () => {
|
|
@@ -189,7 +166,6 @@ const testStyledSystemPadding = (component, defaults, styleContainer, assertOpts
|
|
|
189
166
|
let paddingRight;
|
|
190
167
|
let paddingTop;
|
|
191
168
|
let paddingBottom;
|
|
192
|
-
|
|
193
169
|
if (defaults) {
|
|
194
170
|
padding = getDefaultValue(defaults.p);
|
|
195
171
|
paddingLeft = getDefaultValue(defaults.pl || defaults.px);
|
|
@@ -217,7 +193,8 @@ const testStyledSystemPadding = (component, defaults, styleContainer, assertOpts
|
|
|
217
193
|
const props = {
|
|
218
194
|
[styledSystemProp]: 2
|
|
219
195
|
};
|
|
220
|
-
const wrapper = mount(component({
|
|
196
|
+
const wrapper = mount(component({
|
|
197
|
+
...props
|
|
221
198
|
}));
|
|
222
199
|
assertStyleMatch({
|
|
223
200
|
[propName]: "var(--spacing200)"
|
|
@@ -225,27 +202,25 @@ const testStyledSystemPadding = (component, defaults, styleContainer, assertOpts
|
|
|
225
202
|
});
|
|
226
203
|
});
|
|
227
204
|
};
|
|
228
|
-
|
|
229
205
|
const testStyledSystemSpacing = (component, defaults, styleContainer, assertOpts) => {
|
|
230
206
|
testStyledSystemMargin(component, defaults, styleContainer, assertOpts);
|
|
231
207
|
testStyledSystemPadding(component, defaults, styleContainer, assertOpts);
|
|
232
208
|
};
|
|
233
|
-
|
|
234
209
|
const testStyledSystemColor = (component, styleContainer) => {
|
|
235
210
|
describe.each(colorProps)('when a prop is specified using the "%s" styled system props', (styledSystemProp, propName, value) => {
|
|
236
211
|
it(`then ${propName} should have been set correctly`, () => {
|
|
237
212
|
const props = {
|
|
238
213
|
[styledSystemProp]: value
|
|
239
214
|
};
|
|
240
|
-
const wrapper = mount(component({
|
|
215
|
+
const wrapper = mount(component({
|
|
216
|
+
...props
|
|
241
217
|
}));
|
|
242
|
-
const StyleElement = styleContainer ? styleContainer(wrapper) : wrapper;
|
|
243
|
-
|
|
218
|
+
const StyleElement = styleContainer ? styleContainer(wrapper) : wrapper;
|
|
219
|
+
// Some props need to have camelcase so used toHaveStyleRule rather than assertStyleMatch
|
|
244
220
|
expect(StyleElement).toHaveStyleRule(propName, value);
|
|
245
221
|
});
|
|
246
222
|
});
|
|
247
223
|
};
|
|
248
|
-
|
|
249
224
|
const testStyledSystemWidth = (component, styleContainer) => {
|
|
250
225
|
describe("when a width prop is specified using styled system props", () => {
|
|
251
226
|
it("then width should have been set correctly", () => {
|
|
@@ -253,29 +228,29 @@ const testStyledSystemWidth = (component, styleContainer) => {
|
|
|
253
228
|
const props = {
|
|
254
229
|
[styledSystemProp]: value
|
|
255
230
|
};
|
|
256
|
-
const wrapper = mount(component({
|
|
231
|
+
const wrapper = mount(component({
|
|
232
|
+
...props
|
|
257
233
|
}));
|
|
258
234
|
const StyleElement = styleContainer ? styleContainer(wrapper) : wrapper;
|
|
259
235
|
expect(StyleElement).toHaveStyleRule(propName, value);
|
|
260
236
|
});
|
|
261
237
|
});
|
|
262
238
|
};
|
|
263
|
-
|
|
264
239
|
const testStyledSystemLayout = (component, styleContainer) => {
|
|
265
240
|
describe.each(layoutProps)('when a prop is specified using the "%s" styled system props', (styledSystemProp, propName, value) => {
|
|
266
241
|
it(`then ${propName} should have been set correctly`, () => {
|
|
267
242
|
const props = {
|
|
268
243
|
[styledSystemProp]: value
|
|
269
244
|
};
|
|
270
|
-
const wrapper = mount(component({
|
|
245
|
+
const wrapper = mount(component({
|
|
246
|
+
...props
|
|
271
247
|
}));
|
|
272
|
-
const StyleElement = styleContainer ? styleContainer(wrapper) : wrapper;
|
|
273
|
-
|
|
248
|
+
const StyleElement = styleContainer ? styleContainer(wrapper) : wrapper;
|
|
249
|
+
// Some props need to have camelcase so used toHaveStyleRule rather than assertStyleMatch
|
|
274
250
|
expect(StyleElement).toHaveStyleRule(propName, value);
|
|
275
251
|
});
|
|
276
252
|
});
|
|
277
253
|
};
|
|
278
|
-
|
|
279
254
|
const testStyledSystemFlexBox = (component, styleContainer) => {
|
|
280
255
|
describe.each(flexBoxProps)('when a prop is specified using the "%s" styled system props', (styledSystemProp, propName, value) => {
|
|
281
256
|
it(`then ${propName} should have been set correctly`, () => {
|
|
@@ -289,14 +264,14 @@ const testStyledSystemFlexBox = (component, styleContainer) => {
|
|
|
289
264
|
});
|
|
290
265
|
});
|
|
291
266
|
};
|
|
292
|
-
|
|
293
267
|
const testStyledSystemBackground = (component, styleContainer) => {
|
|
294
268
|
describe.each(backgroundProps)('when a prop is specified using the "%s" styled system props', (styledSystemProp, propName, value) => {
|
|
295
269
|
it(`then ${propName} should have been set correctly`, () => {
|
|
296
270
|
const props = {
|
|
297
271
|
[styledSystemProp]: value
|
|
298
272
|
};
|
|
299
|
-
const wrapper = mount(component({
|
|
273
|
+
const wrapper = mount(component({
|
|
274
|
+
...props
|
|
300
275
|
}));
|
|
301
276
|
assertStyleMatch({
|
|
302
277
|
[styledSystemProp]: value
|
|
@@ -304,41 +279,42 @@ const testStyledSystemBackground = (component, styleContainer) => {
|
|
|
304
279
|
});
|
|
305
280
|
});
|
|
306
281
|
};
|
|
307
|
-
|
|
308
282
|
const testStyledSystemPosition = (component, styleContainer) => {
|
|
309
283
|
describe.each(positionProps)('when a prop is specified using the "%s" styled system props', (styledSystemProp, value) => {
|
|
310
284
|
it(`then ${styledSystemProp} should have been set correctly`, () => {
|
|
311
285
|
const props = {
|
|
312
286
|
[styledSystemProp]: value
|
|
313
287
|
};
|
|
314
|
-
const wrapper = mount(component({
|
|
288
|
+
const wrapper = mount(component({
|
|
289
|
+
...props
|
|
315
290
|
}));
|
|
316
291
|
assertStyleMatch({
|
|
317
292
|
[styledSystemProp]: value
|
|
318
293
|
}, styleContainer ? styleContainer(wrapper) : wrapper);
|
|
319
294
|
});
|
|
320
295
|
});
|
|
321
|
-
};
|
|
322
|
-
|
|
296
|
+
};
|
|
323
297
|
|
|
324
|
-
|
|
298
|
+
// this util will catch that a console output occurred without polluting the output when running the unit tests
|
|
299
|
+
const expectConsoleOutput = function (message) {
|
|
300
|
+
let type = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : "error";
|
|
325
301
|
if (!message) {
|
|
326
302
|
throw new Error(`no ${type} message provided`);
|
|
327
303
|
}
|
|
328
|
-
|
|
329
304
|
expect.assertions(1);
|
|
330
305
|
const consoleType = global.console[type];
|
|
331
306
|
let consoleArgs;
|
|
332
|
-
jest.spyOn(global.console, type).mockImplementation((
|
|
307
|
+
jest.spyOn(global.console, type).mockImplementation(function () {
|
|
308
|
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
309
|
+
args[_key] = arguments[_key];
|
|
310
|
+
}
|
|
333
311
|
if (!args.length) return;
|
|
334
312
|
const msg = args.join(" ");
|
|
335
313
|
const params = args.slice(1, args.length);
|
|
336
|
-
|
|
337
314
|
if (sprintf(msg, ...params).includes(message)) {
|
|
338
315
|
consoleArgs = args;
|
|
339
316
|
return;
|
|
340
317
|
}
|
|
341
|
-
|
|
342
318
|
consoleType(...args);
|
|
343
319
|
});
|
|
344
320
|
return () => {
|
|
@@ -346,9 +322,7 @@ const expectConsoleOutput = (message, type = "error") => {
|
|
|
346
322
|
// eslint-disable-next-line no-console
|
|
347
323
|
expect(console[type]).toHaveBeenCalledWith(...consoleArgs);
|
|
348
324
|
}
|
|
349
|
-
|
|
350
325
|
global.console[type] = consoleType;
|
|
351
326
|
};
|
|
352
327
|
};
|
|
353
|
-
|
|
354
328
|
export { assertStyleMatch, toCSSCase, hoverList, selectedItemOf, childrenFrom, makeArrayKeys, keyboard, assertKeyboardTraversal, assertHoverTraversal, listFrom, click, simulate, carbonThemesJestTable, mockMatchMedia, testStyledSystemSpacing, testStyledSystemMargin, testStyledSystemPadding, testStyledSystemColor, testStyledSystemWidth, testStyledSystemLayout, testStyledSystemFlexBox, testStyledSystemBackground, testStyledSystemPosition, expectConsoleOutput };
|
|
@@ -8,7 +8,7 @@ export interface AccordionGroupProps extends MarginProps {
|
|
|
8
8
|
children?: AccordionGroupChild;
|
|
9
9
|
}
|
|
10
10
|
export declare const AccordionGroup: {
|
|
11
|
-
({ children, ...rest }: AccordionGroupProps): JSX.Element;
|
|
11
|
+
({ children, ...rest }: AccordionGroupProps): React.JSX.Element;
|
|
12
12
|
displayName: string;
|
|
13
13
|
};
|
|
14
14
|
export default AccordionGroup;
|
|
@@ -5,10 +5,13 @@ import Events from "../../../__internal__/utils/helpers/events";
|
|
|
5
5
|
import Accordion from "../accordion.component";
|
|
6
6
|
import { StyledAccordionGroup } from "../accordion.style";
|
|
7
7
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
8
|
+
// typescript-to-proptypes breaks on recursive type references so it has to be an interface
|
|
9
|
+
// eslint-disable-next-line @typescript-eslint/no-empty-interface
|
|
10
|
+
export const AccordionGroup = _ref => {
|
|
11
|
+
let {
|
|
12
|
+
children,
|
|
13
|
+
...rest
|
|
14
|
+
} = _ref;
|
|
12
15
|
const hasProperChildren = useMemo(() => {
|
|
13
16
|
let hasAccordionChildren = true;
|
|
14
17
|
React.Children.toArray(children).forEach(child => {
|
|
@@ -25,34 +28,24 @@ const AccordionGroup = ({
|
|
|
25
28
|
const refs = useMemo(() => filteredChildren.map(child => child.ref || /*#__PURE__*/React.createRef()), [filteredChildren]);
|
|
26
29
|
const focusAccordion = useCallback((ev, index) => {
|
|
27
30
|
ev.preventDefault();
|
|
28
|
-
|
|
29
31
|
if (index === -1) {
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
(_refs$current = refs[refs.length - 1].current) === null || _refs$current === void 0 ? void 0 : _refs$current.focus();
|
|
32
|
+
refs[refs.length - 1].current?.focus();
|
|
33
33
|
} else if (index === refs.length) {
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
(_refs$0$current = refs[0].current) === null || _refs$0$current === void 0 ? void 0 : _refs$0$current.focus();
|
|
34
|
+
refs[0].current?.focus();
|
|
37
35
|
} else {
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
(_refs$index$current = refs[index].current) === null || _refs$index$current === void 0 ? void 0 : _refs$index$current.focus();
|
|
36
|
+
refs[index].current?.focus();
|
|
41
37
|
}
|
|
42
38
|
}, [refs]);
|
|
43
39
|
const handleKeyboardAccessibility = useCallback((ev, index) => {
|
|
44
40
|
if (Events.isUpKey(ev)) {
|
|
45
41
|
focusAccordion(ev, index - 1);
|
|
46
42
|
}
|
|
47
|
-
|
|
48
43
|
if (Events.isDownKey(ev)) {
|
|
49
44
|
focusAccordion(ev, index + 1);
|
|
50
45
|
}
|
|
51
|
-
|
|
52
46
|
if (Events.isHomeKey(ev)) {
|
|
53
47
|
focusAccordion(ev, 0);
|
|
54
48
|
}
|
|
55
|
-
|
|
56
49
|
if (Events.isEndKey(ev)) {
|
|
57
50
|
focusAccordion(ev, refs.length - 1);
|
|
58
51
|
}
|
|
@@ -66,200 +59,5 @@ const AccordionGroup = ({
|
|
|
66
59
|
handleKeyboardAccessibility
|
|
67
60
|
})));
|
|
68
61
|
};
|
|
69
|
-
|
|
70
|
-
AccordionGroup.propTypes = {
|
|
71
|
-
"children": PropTypes.oneOfType([PropTypes.element, PropTypes.shape({
|
|
72
|
-
"__@iterator": PropTypes.func.isRequired,
|
|
73
|
-
"__@unscopables": PropTypes.func.isRequired,
|
|
74
|
-
"at": PropTypes.func.isRequired,
|
|
75
|
-
"concat": PropTypes.func.isRequired,
|
|
76
|
-
"copyWithin": PropTypes.func.isRequired,
|
|
77
|
-
"entries": PropTypes.func.isRequired,
|
|
78
|
-
"every": PropTypes.func.isRequired,
|
|
79
|
-
"fill": PropTypes.func.isRequired,
|
|
80
|
-
"filter": PropTypes.func.isRequired,
|
|
81
|
-
"find": PropTypes.func.isRequired,
|
|
82
|
-
"findIndex": PropTypes.func.isRequired,
|
|
83
|
-
"flat": PropTypes.func.isRequired,
|
|
84
|
-
"flatMap": PropTypes.func.isRequired,
|
|
85
|
-
"forEach": PropTypes.func.isRequired,
|
|
86
|
-
"includes": PropTypes.func.isRequired,
|
|
87
|
-
"indexOf": PropTypes.func.isRequired,
|
|
88
|
-
"join": PropTypes.func.isRequired,
|
|
89
|
-
"keys": PropTypes.func.isRequired,
|
|
90
|
-
"lastIndexOf": PropTypes.func.isRequired,
|
|
91
|
-
"length": PropTypes.number.isRequired,
|
|
92
|
-
"map": PropTypes.func.isRequired,
|
|
93
|
-
"pop": PropTypes.func.isRequired,
|
|
94
|
-
"push": PropTypes.func.isRequired,
|
|
95
|
-
"reduce": PropTypes.func.isRequired,
|
|
96
|
-
"reduceRight": PropTypes.func.isRequired,
|
|
97
|
-
"reverse": PropTypes.func.isRequired,
|
|
98
|
-
"shift": PropTypes.func.isRequired,
|
|
99
|
-
"slice": PropTypes.func.isRequired,
|
|
100
|
-
"some": PropTypes.func.isRequired,
|
|
101
|
-
"sort": PropTypes.func.isRequired,
|
|
102
|
-
"splice": PropTypes.func.isRequired,
|
|
103
|
-
"toLocaleString": PropTypes.func.isRequired,
|
|
104
|
-
"toString": PropTypes.func.isRequired,
|
|
105
|
-
"unshift": PropTypes.func.isRequired,
|
|
106
|
-
"values": PropTypes.func.isRequired
|
|
107
|
-
}), PropTypes.bool]),
|
|
108
|
-
"m": PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.oneOf([null]), PropTypes.number, PropTypes.shape({
|
|
109
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
110
|
-
"description": PropTypes.string,
|
|
111
|
-
"toString": PropTypes.func.isRequired,
|
|
112
|
-
"valueOf": PropTypes.func.isRequired
|
|
113
|
-
}), PropTypes.string])), PropTypes.number, PropTypes.object, PropTypes.shape({
|
|
114
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
115
|
-
"description": PropTypes.string,
|
|
116
|
-
"toString": PropTypes.func.isRequired,
|
|
117
|
-
"valueOf": PropTypes.func.isRequired
|
|
118
|
-
}), PropTypes.string]),
|
|
119
|
-
"margin": PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.oneOf([null]), PropTypes.number, PropTypes.shape({
|
|
120
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
121
|
-
"description": PropTypes.string,
|
|
122
|
-
"toString": PropTypes.func.isRequired,
|
|
123
|
-
"valueOf": PropTypes.func.isRequired
|
|
124
|
-
}), PropTypes.string])), PropTypes.number, PropTypes.object, PropTypes.shape({
|
|
125
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
126
|
-
"description": PropTypes.string,
|
|
127
|
-
"toString": PropTypes.func.isRequired,
|
|
128
|
-
"valueOf": PropTypes.func.isRequired
|
|
129
|
-
}), PropTypes.string]),
|
|
130
|
-
"marginBottom": PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.oneOf([null]), PropTypes.number, PropTypes.shape({
|
|
131
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
132
|
-
"description": PropTypes.string,
|
|
133
|
-
"toString": PropTypes.func.isRequired,
|
|
134
|
-
"valueOf": PropTypes.func.isRequired
|
|
135
|
-
}), PropTypes.string])), PropTypes.number, PropTypes.object, PropTypes.shape({
|
|
136
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
137
|
-
"description": PropTypes.string,
|
|
138
|
-
"toString": PropTypes.func.isRequired,
|
|
139
|
-
"valueOf": PropTypes.func.isRequired
|
|
140
|
-
}), PropTypes.string]),
|
|
141
|
-
"marginLeft": PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.oneOf([null]), PropTypes.number, PropTypes.shape({
|
|
142
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
143
|
-
"description": PropTypes.string,
|
|
144
|
-
"toString": PropTypes.func.isRequired,
|
|
145
|
-
"valueOf": PropTypes.func.isRequired
|
|
146
|
-
}), PropTypes.string])), PropTypes.number, PropTypes.object, PropTypes.shape({
|
|
147
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
148
|
-
"description": PropTypes.string,
|
|
149
|
-
"toString": PropTypes.func.isRequired,
|
|
150
|
-
"valueOf": PropTypes.func.isRequired
|
|
151
|
-
}), PropTypes.string]),
|
|
152
|
-
"marginRight": PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.oneOf([null]), PropTypes.number, PropTypes.shape({
|
|
153
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
154
|
-
"description": PropTypes.string,
|
|
155
|
-
"toString": PropTypes.func.isRequired,
|
|
156
|
-
"valueOf": PropTypes.func.isRequired
|
|
157
|
-
}), PropTypes.string])), PropTypes.number, PropTypes.object, PropTypes.shape({
|
|
158
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
159
|
-
"description": PropTypes.string,
|
|
160
|
-
"toString": PropTypes.func.isRequired,
|
|
161
|
-
"valueOf": PropTypes.func.isRequired
|
|
162
|
-
}), PropTypes.string]),
|
|
163
|
-
"marginTop": PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.oneOf([null]), PropTypes.number, PropTypes.shape({
|
|
164
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
165
|
-
"description": PropTypes.string,
|
|
166
|
-
"toString": PropTypes.func.isRequired,
|
|
167
|
-
"valueOf": PropTypes.func.isRequired
|
|
168
|
-
}), PropTypes.string])), PropTypes.number, PropTypes.object, PropTypes.shape({
|
|
169
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
170
|
-
"description": PropTypes.string,
|
|
171
|
-
"toString": PropTypes.func.isRequired,
|
|
172
|
-
"valueOf": PropTypes.func.isRequired
|
|
173
|
-
}), PropTypes.string]),
|
|
174
|
-
"marginX": PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.oneOf([null]), PropTypes.number, PropTypes.shape({
|
|
175
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
176
|
-
"description": PropTypes.string,
|
|
177
|
-
"toString": PropTypes.func.isRequired,
|
|
178
|
-
"valueOf": PropTypes.func.isRequired
|
|
179
|
-
}), PropTypes.string])), PropTypes.number, PropTypes.object, PropTypes.shape({
|
|
180
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
181
|
-
"description": PropTypes.string,
|
|
182
|
-
"toString": PropTypes.func.isRequired,
|
|
183
|
-
"valueOf": PropTypes.func.isRequired
|
|
184
|
-
}), PropTypes.string]),
|
|
185
|
-
"marginY": PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.oneOf([null]), PropTypes.number, PropTypes.shape({
|
|
186
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
187
|
-
"description": PropTypes.string,
|
|
188
|
-
"toString": PropTypes.func.isRequired,
|
|
189
|
-
"valueOf": PropTypes.func.isRequired
|
|
190
|
-
}), PropTypes.string])), PropTypes.number, PropTypes.object, PropTypes.shape({
|
|
191
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
192
|
-
"description": PropTypes.string,
|
|
193
|
-
"toString": PropTypes.func.isRequired,
|
|
194
|
-
"valueOf": PropTypes.func.isRequired
|
|
195
|
-
}), PropTypes.string]),
|
|
196
|
-
"mb": PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.oneOf([null]), PropTypes.number, PropTypes.shape({
|
|
197
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
198
|
-
"description": PropTypes.string,
|
|
199
|
-
"toString": PropTypes.func.isRequired,
|
|
200
|
-
"valueOf": PropTypes.func.isRequired
|
|
201
|
-
}), PropTypes.string])), PropTypes.number, PropTypes.object, PropTypes.shape({
|
|
202
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
203
|
-
"description": PropTypes.string,
|
|
204
|
-
"toString": PropTypes.func.isRequired,
|
|
205
|
-
"valueOf": PropTypes.func.isRequired
|
|
206
|
-
}), PropTypes.string]),
|
|
207
|
-
"ml": PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.oneOf([null]), PropTypes.number, PropTypes.shape({
|
|
208
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
209
|
-
"description": PropTypes.string,
|
|
210
|
-
"toString": PropTypes.func.isRequired,
|
|
211
|
-
"valueOf": PropTypes.func.isRequired
|
|
212
|
-
}), PropTypes.string])), PropTypes.number, PropTypes.object, PropTypes.shape({
|
|
213
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
214
|
-
"description": PropTypes.string,
|
|
215
|
-
"toString": PropTypes.func.isRequired,
|
|
216
|
-
"valueOf": PropTypes.func.isRequired
|
|
217
|
-
}), PropTypes.string]),
|
|
218
|
-
"mr": PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.oneOf([null]), PropTypes.number, PropTypes.shape({
|
|
219
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
220
|
-
"description": PropTypes.string,
|
|
221
|
-
"toString": PropTypes.func.isRequired,
|
|
222
|
-
"valueOf": PropTypes.func.isRequired
|
|
223
|
-
}), PropTypes.string])), PropTypes.number, PropTypes.object, PropTypes.shape({
|
|
224
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
225
|
-
"description": PropTypes.string,
|
|
226
|
-
"toString": PropTypes.func.isRequired,
|
|
227
|
-
"valueOf": PropTypes.func.isRequired
|
|
228
|
-
}), PropTypes.string]),
|
|
229
|
-
"mt": PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.oneOf([null]), PropTypes.number, PropTypes.shape({
|
|
230
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
231
|
-
"description": PropTypes.string,
|
|
232
|
-
"toString": PropTypes.func.isRequired,
|
|
233
|
-
"valueOf": PropTypes.func.isRequired
|
|
234
|
-
}), PropTypes.string])), PropTypes.number, PropTypes.object, PropTypes.shape({
|
|
235
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
236
|
-
"description": PropTypes.string,
|
|
237
|
-
"toString": PropTypes.func.isRequired,
|
|
238
|
-
"valueOf": PropTypes.func.isRequired
|
|
239
|
-
}), PropTypes.string]),
|
|
240
|
-
"mx": PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.oneOf([null]), PropTypes.number, PropTypes.shape({
|
|
241
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
242
|
-
"description": PropTypes.string,
|
|
243
|
-
"toString": PropTypes.func.isRequired,
|
|
244
|
-
"valueOf": PropTypes.func.isRequired
|
|
245
|
-
}), PropTypes.string])), PropTypes.number, PropTypes.object, PropTypes.shape({
|
|
246
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
247
|
-
"description": PropTypes.string,
|
|
248
|
-
"toString": PropTypes.func.isRequired,
|
|
249
|
-
"valueOf": PropTypes.func.isRequired
|
|
250
|
-
}), PropTypes.string]),
|
|
251
|
-
"my": PropTypes.oneOfType([PropTypes.arrayOf(PropTypes.oneOfType([PropTypes.oneOf([null]), PropTypes.number, PropTypes.shape({
|
|
252
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
253
|
-
"description": PropTypes.string,
|
|
254
|
-
"toString": PropTypes.func.isRequired,
|
|
255
|
-
"valueOf": PropTypes.func.isRequired
|
|
256
|
-
}), PropTypes.string])), PropTypes.number, PropTypes.object, PropTypes.shape({
|
|
257
|
-
"__@toStringTag": PropTypes.string.isRequired,
|
|
258
|
-
"description": PropTypes.string,
|
|
259
|
-
"toString": PropTypes.func.isRequired,
|
|
260
|
-
"valueOf": PropTypes.func.isRequired
|
|
261
|
-
}), PropTypes.string])
|
|
262
|
-
};
|
|
263
|
-
export { AccordionGroup };
|
|
264
62
|
AccordionGroup.displayName = "AccordionGroup";
|
|
265
63
|
export default AccordionGroup;
|