@qualtrics/ui-react 2.21.0 → 2.22.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +18 -0
- package/dist/__shared/cjs/{index-0ae99de2.js → index-75d9309a.js} +4 -4
- package/dist/__shared/cjs/{index-201e8786.js → index-a8c1a789.js} +678 -568
- package/dist/components/Accordion/Accordion.js +2 -3
- package/dist/components/Accordion/Accordion2.js +3 -3
- package/dist/components/Accordion/AccordionHeader.js +5 -4
- package/dist/components/Accordion/AccordionPanel.js +3 -3
- package/dist/components/Accordion/AccordionSection.js +1 -2
- package/dist/components/Button/Button.js +3 -3
- package/dist/components/Button/Button2.js +2 -2
- package/dist/components/ButtonGroup/ButtonGroup.js +1 -1
- package/dist/components/ButtonGroup/ButtonGroup2.js +3 -3
- package/dist/components/Checkbox/Checkbox.js +11 -11
- package/dist/components/Checkbox/Checkbox2.js +3 -3
- package/dist/components/Checkbox/VisualCheckbox2.js +3 -3
- package/dist/components/ColorPicker/Alpha.js +12 -9
- package/dist/components/ColorPicker/ColorPicker.js +10 -8
- package/dist/components/ColorPicker/ColorPicker2.js +3 -3
- package/dist/components/ColorPicker/ColorPickerFlyoutInputs.js +8 -6
- package/dist/components/ColorPicker/Hue.js +3 -2
- package/dist/components/ColorPicker/Palette.js +7 -5
- package/dist/components/ColorPicker/Saturation.js +9 -8
- package/dist/components/ColorPicker/utils/hexToRgbaString.js +3 -2
- package/dist/components/ColorPicker/utils/rgbToHex.js +1 -1
- package/dist/components/ColorPicker/utils/validateHex.js +10 -9
- package/dist/components/Combobox/Combobox.js +48 -29
- package/dist/components/Combobox/Combobox2.js +3 -3
- package/dist/components/Combobox/ComboboxHeader.js +1 -1
- package/dist/components/Combobox/ComboboxIcon.js +3 -2
- package/dist/components/Combobox/ComboboxInput.js +4 -4
- package/dist/components/Combobox/ComboboxList.js +2 -2
- package/dist/components/ConfigPane/ConfigPane2.js +3 -3
- package/dist/components/Divider/Divider2.js +3 -3
- package/dist/components/Dropdown/ChildIndexContext/reach-descendants.js +5 -2
- package/dist/components/Dropdown/Dropdown.js +14 -9
- package/dist/components/Dropdown/Dropdown2.js +3 -3
- package/dist/components/Dropdown/DropdownButton.js +23 -19
- package/dist/components/Dropdown/DropdownList.js +4 -4
- package/dist/components/Dropdown/DropdownOption.js +6 -9
- package/dist/components/Dropdown/DropdownSearch.js +12 -6
- package/dist/components/FilePicker/FilePicker.js +13 -6
- package/dist/components/FilePicker/FilePicker2.js +3 -3
- package/dist/components/FormField/Caption.js +3 -3
- package/dist/components/FormField/FormField.js +2 -2
- package/dist/components/FormField/FormField2.js +3 -3
- package/dist/components/FormField/FormFieldContext.js +3 -3
- package/dist/components/FullScreenTakeover/FullScreenTakeover.js +5 -3
- package/dist/components/FullScreenTakeover/FullScreenTakeover2.js +3 -3
- package/dist/components/Icon/Icon.js +2 -2
- package/dist/components/IconButton/IconButton2.js +3 -3
- package/dist/components/InlineInput/InlineInput.js +12 -9
- package/dist/components/InlineInput/InlineInput2.js +3 -3
- package/dist/components/Input/Input.js +1 -1
- package/dist/components/Input/Input2.js +3 -3
- package/dist/components/Input/InputField.js +2 -2
- package/dist/components/InputGroup/InputGroup2.js +3 -3
- package/dist/components/Label/Label2.js +3 -3
- package/dist/components/Link/Link2.js +3 -3
- package/dist/components/LoadingSpinner/LoadingSpinner.js +1 -1
- package/dist/components/LoadingSpinner/LoadingSpinner2.js +3 -3
- package/dist/components/LogicEditor/ConditionSet.js +5 -5
- package/dist/components/LogicEditor/LogicEditor.js +1 -1
- package/dist/components/LogicEditor/LogicEditor2.js +3 -3
- package/dist/components/LogicEditor/utils.js +2 -1
- package/dist/components/Modal/Modal.js +14 -13
- package/dist/components/Modal/Modal2.js +3 -3
- package/dist/components/NewMenu/BaseMenu.js +44 -36
- package/dist/components/NewMenu/NewMenu.js +3 -3
- package/dist/components/NewMenu/SelectMenu/SelectMenu.js +2 -2
- package/dist/components/NewMenu/parts/ArrowNav/ArrowNav.js +10 -7
- package/dist/components/NewMenu/parts/MenuItem.js +1 -1
- package/dist/components/NumberStepper/NumberStepper.js +7 -6
- package/dist/components/NumberStepper/NumberStepper2.js +3 -3
- package/dist/components/NumberStepper/NumberStepperDecrement.js +1 -1
- package/dist/components/NumberStepper/NumberStepperIncrement.js +1 -1
- package/dist/components/NumberStepper/NumberStepperInput.js +3 -3
- package/dist/components/PageLayout/PageLayout.js +3 -3
- package/dist/components/Pagination/Pagination.js +1 -1
- package/dist/components/Pagination/Pagination2.js +3 -3
- package/dist/components/Pagination/PaginationNextButton.js +5 -5
- package/dist/components/Pagination/PaginationPageInput.js +11 -9
- package/dist/components/Pagination/PaginationPreviousButton.js +5 -5
- package/dist/components/Popover/Popover.js +9 -7
- package/dist/components/Popover/Popover2.js +3 -3
- package/dist/components/QuickSearch/QuickSearch.js +4 -3
- package/dist/components/QuickSearch/QuickSearch2.js +3 -3
- package/dist/components/QuickSearch/QuickSearchInput.js +4 -4
- package/dist/components/Radio/Radio.js +12 -11
- package/dist/components/Radio/Radio2.js +3 -3
- package/dist/components/SearchInput/SearchInput.js +4 -3
- package/dist/components/SearchInput/SearchInput2.js +3 -3
- package/dist/components/SidebarNav/SidebarNav.js +2 -1
- package/dist/components/SidebarNav/SidebarNav2.js +3 -3
- package/dist/components/SidebarNav/SidebarNavLink.js +1 -1
- package/dist/components/Slider/RangeSlider.js +2 -2
- package/dist/components/Slider/Slider.js +1 -1
- package/dist/components/Slider/Slider2.js +3 -3
- package/dist/components/Slider/SliderButton.js +1 -1
- package/dist/components/Switch/Switch.js +11 -11
- package/dist/components/Switch/Switch2.js +3 -3
- package/dist/components/Table/Table2.js +3 -3
- package/dist/components/Tabs/Tab.js +3 -3
- package/dist/components/Tabs/TabList.js +6 -5
- package/dist/components/Tabs/TabPanel.js +3 -3
- package/dist/components/Tabs/Tabs2.js +3 -3
- package/dist/components/Tooltip/Tooltip.js +10 -4
- package/dist/components/Tooltip/Tooltip2.js +3 -3
- package/dist/components/UIProvider/UIProvider.js +2 -2
- package/dist/components/deprecated_ColorPicker/Alpha.js +4 -4
- package/dist/components/deprecated_ColorPicker/Color.js +6 -6
- package/dist/components/deprecated_ColorPicker/ColorPicker.js +2 -2
- package/dist/components/deprecated_ColorPicker/ColorPicker2.js +3 -3
- package/dist/components/deprecated_ColorPicker/HexInput.js +1 -1
- package/dist/components/deprecated_ColorPicker/Hue.js +3 -3
- package/dist/components/deprecated_ColorPicker/Saturation.js +5 -5
- package/dist/components/deprecated_ColorPicker/Swatch.js +2 -2
- package/dist/components/deprecated_NumberStepper/NumberStepper2.js +3 -3
- package/dist/components/deprecated_NumberStepper/NumberStepperDecrement.js +2 -2
- package/dist/components/deprecated_NumberStepper/NumberStepperIncrement.js +2 -2
- package/dist/components/deprecated_NumberStepper/NumberStepperInput.js +8 -8
- package/dist/components/deprecated_Tabs/Tabs.js +11 -7
- package/dist/components/deprecated_Tabs/Tabs2.js +3 -3
- package/dist/components/deprecated_Toolbar/Toolbar2.js +3 -3
- package/dist/components/deprecated_Toolbar/ToolbarPanel.js +3 -3
- package/dist/components/deprecated_Toolbar/ToolbarPanels.js +4 -2
- package/dist/components/deprecated_Toolbar/ToolbarTab.js +8 -8
- package/dist/components/deprecated_Toolbar/ToolbarTabs.js +6 -3
- package/dist/hooks/useBreakpoints/useBreakpoints.js +1 -1
- package/dist/hooks/useClickOutside/useClickOutside.js +2 -1
- package/dist/hooks/useControllableState/useControllableState.js +2 -1
- package/dist/hooks/useEventListener/useEventListener.js +1 -1
- package/dist/hooks/useId/useId.js +1 -1
- package/dist/hooks/useOverlay/useOverlay.js +7 -6
- package/dist/hooks/useOverlay/useOverlay2.js +3 -3
- package/dist/hooks/useResponsiveValue/useResponsiveValue.js +2 -1
- package/dist/hooks/useScreenReaderAnnouncement/useScreenReaderAnnouncement.js +4 -2
- package/dist/hooks/useScreenReaderAnnouncement/useScreenReaderAnnouncement2.js +3 -3
- package/dist/icons/Icon.js +3 -3
- package/dist/icons/createIconComponent.js +1 -1
- package/dist/icons/index.js +1 -1
- package/dist/index.d.ts +14 -7
- package/dist/index.es.js +1 -1
- package/dist/index.js +3 -4
- package/dist/next/AdvancedTable/AdvancedTable.js +62 -52
- package/dist/next/AdvancedTable/AdvancedTable2.js +3 -3
- package/dist/next/AdvancedTable/AdvancedTableCell.js +6 -4
- package/dist/next/AdvancedTable/AdvancedTableColumnHeader.js +18 -10
- package/dist/next/AdvancedTable/AdvancedTableColumnHeaderMenu.js +7 -6
- package/dist/next/AdvancedTable/AdvancedTableDragPreview.js +5 -4
- package/dist/next/AdvancedTable/AdvancedTablePagination.js +1 -1
- package/dist/next/AdvancedTable/AdvancedTableTypes.js +6 -6
- package/dist/next/AdvancedTable/useAdvancedTableDragAndDrop.js +3 -2
- package/dist/next/AdvancedTable/useComputedWidth.js +1 -1
- package/dist/next/CollapsibleSearchInput/CollapsibleSearchInput.js +5 -3
- package/dist/next/CollapsibleSearchInput/CollapsibleSearchInput2.js +3 -3
- package/dist/next/CollapsibleSearchInput/CollapsibleSearchInputIconButton.js +1 -1
- package/dist/next/Combobox/Combobox2.js +3 -3
- package/dist/next/Combobox/ComboboxFlyout.js +2 -2
- package/dist/next/Combobox/ComboboxGroup.js +1 -1
- package/dist/next/Combobox/ComboboxInput.js +2 -2
- package/dist/next/Combobox/ComboboxOption.js +1 -1
- package/dist/next/Combobox/hooks/useComboboxFilteredGroup/useComboboxFilteredGroup.js +1 -1
- package/dist/next/Combobox/hooks/useComboboxFocusSequence/useComboboxFocusSequence.js +12 -8
- package/dist/next/Combobox/hooks/useComboboxValue/useComboboxValue.js +1 -1
- package/dist/next/Combobox/hooks/useListboxFlyoutDimensions/useListboxFlyoutDimensions.js +3 -2
- package/dist/next/Combobox/hooks/useSelectedOptionScroll/useSelectedOptionScroll.js +2 -1
- package/dist/next/Combobox/hooks/useShouldRenderGroupHeader/useShouldRenderGroupHeader.js +2 -1
- package/dist/next/Combobox/utils/nodeRegistration/nodeRegistration.js +1 -1
- package/dist/next/Drawer/Drawer.js +7 -4
- package/dist/next/Drawer/Drawer2.js +3 -3
- package/dist/next/FilterAnchor/FilterAnchor.js +3 -3
- package/dist/next/FilterAnchor/FilterAnchor2.js +3 -3
- package/dist/next/Input/Input.js +2 -2
- package/dist/next/Input/Input2.js +3 -3
- package/dist/next/Menu/Menu.js +5 -3
- package/dist/next/Menu/Menu2.js +3 -3
- package/dist/next/Menu/MenuItem.js +8 -9
- package/dist/next/Menu/MenuPane.js +20 -8
- package/dist/next/Menu/SubMenu.js +16 -18
- package/dist/next/Menu/useMutationObserver.js +1 -1
- package/dist/next/Menu/usePaneSearch.js +31 -21
- package/dist/next/PhoneNumberInput/PhoneNumberInput.js +7 -6
- package/dist/next/PhoneNumberInput/PhoneNumberInput2.js +3 -3
- package/dist/next/SplitButton/SplitButton.js +8 -2
- package/dist/next/SplitButton/SplitButton2.js +3 -3
- package/dist/next/TimePicker/TimeDropdown.js +4 -4
- package/dist/next/TimePicker/TimeInput.js +2 -2
- package/dist/next/TimePicker/TimePicker.js +4 -4
- package/dist/next/TimePicker/TimePicker2.js +3 -3
- package/dist/next/TimePicker/TimePickerIcon.js +2 -1
- package/dist/next/TimePicker/utils.js +14 -27
- package/dist/next/ToggleButton/styles.js +3 -3
- package/dist/next/index.d.ts +1 -1
- package/dist/next/index.js +317 -260
- package/dist/utils/Flyout/Flyout.js +1 -1
- package/dist/utils/Flyout/Flyout2.js +3 -3
- package/dist/utils/Popper/Popper.js +9 -5
- package/dist/utils/TextOverflowTooltip/TextOverflowTooltip.js +2 -1
- package/dist/utils/Translation/containsComponentOrElement.js +1 -3
- package/dist/utils/Translation/useTranslation.js +4 -5
- package/dist/utils/filterChildren/filterChildren.js +2 -1
- package/dist/utils/getSubDataTestId/getSubDataTestId.js +1 -1
- package/dist/utils/mediaQueryManager/mediaQueryManager.js +1 -1
- package/dist/utils/mergeRefs/mergeRefs.js +1 -1
- package/dist/utils/wrapEvent/wrapEvent.js +2 -2
- package/next/package.json +1 -1
- package/package.json +2 -2
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var _includesInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/includes');
|
|
4
3
|
var React = require('react');
|
|
5
4
|
var classNames = require('classnames');
|
|
6
|
-
var icons_index = require('./index-
|
|
5
|
+
var icons_index = require('./index-75d9309a.js');
|
|
7
6
|
var _extends = require('@babel/runtime-corejs3/helpers/extends');
|
|
8
7
|
var reactPopper = require('react-popper');
|
|
9
8
|
var core = require('@popperjs/core');
|
|
@@ -35,7 +34,6 @@ function _interopNamespace(e) {
|
|
|
35
34
|
return Object.freeze(n);
|
|
36
35
|
}
|
|
37
36
|
|
|
38
|
-
var _includesInstanceProperty__default = /*#__PURE__*/_interopDefaultLegacy(_includesInstanceProperty);
|
|
39
37
|
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
40
38
|
var React__namespace = /*#__PURE__*/_interopNamespace(React);
|
|
41
39
|
var classNames__default = /*#__PURE__*/_interopDefaultLegacy(classNames);
|
|
@@ -44,9 +42,9 @@ var ReactFocusLock__default = /*#__PURE__*/_interopDefaultLegacy(ReactFocusLock)
|
|
|
44
42
|
var ReactDOM__default = /*#__PURE__*/_interopDefaultLegacy(ReactDOM);
|
|
45
43
|
var useResizeObserver__default = /*#__PURE__*/_interopDefaultLegacy(useResizeObserver$1);
|
|
46
44
|
|
|
47
|
-
var css_248z$I = ".
|
|
48
|
-
var AccordionStyles = {"accordion":"
|
|
49
|
-
var stylesheet$I=".
|
|
45
|
+
var css_248z$I = "._qmn0o{width:100%;display:flex;flex-direction:column}._qmn0o._A47qQ{grid-gap:20px;gap:20px}._fplM9{display:flex;width:100%;border:none;outline:none;background-color:transparent;color:#32363a;font-size:14px;font-weight:700;line-height:18px;text-align:left;padding:10px 16px 10px 0;cursor:pointer}._fplM9 ._Zul9j{margin-top:-3px}._n8t-a{flex:1}._xEkQp{padding:8px 16px 16px 24px;font-size:14px;line-height:20px}._ealXn ._fplM9{border-radius:4px}._ealXn ._fplM9:hover:not(._JBZ8U){background-color:rgba(50,54,58,.08)}._ealXn ._fplM9:active:not(._JBZ8U){background-color:rgba(50,54,58,.11)}._qn-Kx ._fplM9{font-weight:400;padding-left:12px;border-top:1px solid #eee}._qn-Kx ._fplM9:hover:not(._JBZ8U){background-color:rgba(50,54,58,.08)}._qn-Kx ._fplM9:active:not(._JBZ8U){background-color:rgba(50,54,58,.11)}._A47qQ ._krT9e{border-radius:6px;box-shadow:0 3px 4px rgba(0,0,0,.05),0 6px 10px rgba(0,0,0,.05)}._A47qQ ._krT9e._km3be{box-shadow:none}._A47qQ ._krT9e._km3be ._fplM9{border-radius:6px}._A47qQ ._fplM9{border:1px solid #e5e5e5;border-radius:6px 6px 0 0;font-weight:400;padding:22px 20px}._A47qQ ._fplM9 ._n8t-a{padding-left:20px}._A47qQ ._fplM9:hover:not(disabled){border:1px solid #c2c2c2}._A47qQ ._fplM9:active:not(._JBZ8U){border:1px solid #898989}._A47qQ ._xEkQp{padding:24px 20px;color:#6a6d70;border:1px solid #e5e5e5;border-top:none;border-radius:0 0 6px 6px}._km3be ._xEkQp{display:none}._JBZ8U{fill:rgba(81,85,89,.6);background-color:hsla(0,0%,100%,.6);color:rgba(50,54,58,.6);cursor:default}._fplM9.focus-visible,._fplM9:focus-visible{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88;position:relative}._fplM9.focus-visible:before,._fplM9:focus-visible:before{z-index:1}._qn-Kx ._fplM9.focus-visible,._qn-Kx ._fplM9:focus-visible{border-color:transparent}";
|
|
46
|
+
var AccordionStyles = {"accordion":"_qmn0o","block-variant":"_A47qQ","header":"_fplM9","headerIcon":"_Zul9j","title":"_n8t-a","panel":"_xEkQp","default-variant":"_ealXn","disabled":"_JBZ8U","outlined-variant":"_qn-Kx","section":"_krT9e","closed":"_km3be"};
|
|
47
|
+
var stylesheet$I="._qmn0o{width:100%;display:flex;flex-direction:column}._qmn0o._A47qQ{grid-gap:20px;gap:20px}._fplM9{display:flex;width:100%;border:none;outline:none;background-color:transparent;color:#32363a;font-size:14px;font-weight:700;line-height:18px;text-align:left;padding:10px 16px 10px 0;cursor:pointer}._fplM9 ._Zul9j{margin-top:-3px}._n8t-a{flex:1}._xEkQp{padding:8px 16px 16px 24px;font-size:14px;line-height:20px}._ealXn ._fplM9{border-radius:4px}._ealXn ._fplM9:hover:not(._JBZ8U){background-color:rgba(50,54,58,.08)}._ealXn ._fplM9:active:not(._JBZ8U){background-color:rgba(50,54,58,.11)}._qn-Kx ._fplM9{font-weight:400;padding-left:12px;border-top:1px solid #eee}._qn-Kx ._fplM9:hover:not(._JBZ8U){background-color:rgba(50,54,58,.08)}._qn-Kx ._fplM9:active:not(._JBZ8U){background-color:rgba(50,54,58,.11)}._A47qQ ._krT9e{border-radius:6px;box-shadow:0 3px 4px rgba(0,0,0,.05),0 6px 10px rgba(0,0,0,.05)}._A47qQ ._krT9e._km3be{box-shadow:none}._A47qQ ._krT9e._km3be ._fplM9{border-radius:6px}._A47qQ ._fplM9{border:1px solid #e5e5e5;border-radius:6px 6px 0 0;font-weight:400;padding:22px 20px}._A47qQ ._fplM9 ._n8t-a{padding-left:20px}._A47qQ ._fplM9:hover:not(disabled){border:1px solid #c2c2c2}._A47qQ ._fplM9:active:not(._JBZ8U){border:1px solid #898989}._A47qQ ._xEkQp{padding:24px 20px;color:#6a6d70;border:1px solid #e5e5e5;border-top:none;border-radius:0 0 6px 6px}._km3be ._xEkQp{display:none}._JBZ8U{fill:rgba(81,85,89,.6);background-color:hsla(0,0%,100%,.6);color:rgba(50,54,58,.6);cursor:default}._fplM9.focus-visible,._fplM9:focus-visible{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88;position:relative}._fplM9.focus-visible:before,._fplM9:focus-visible:before{z-index:1}._qn-Kx ._fplM9.focus-visible,._qn-Kx ._fplM9:focus-visible{border-color:transparent}";
|
|
50
48
|
icons_index.styleInject(css_248z$I);
|
|
51
49
|
|
|
52
50
|
/**
|
|
@@ -85,6 +83,7 @@ function _filterChildren(children) {
|
|
|
85
83
|
|
|
86
84
|
// Returns ReactChild
|
|
87
85
|
function _findMatch(child, queries, matchesList) {
|
|
86
|
+
var _newChild;
|
|
88
87
|
let newChild = child;
|
|
89
88
|
let foundMatch = false;
|
|
90
89
|
let i;
|
|
@@ -99,7 +98,7 @@ function _findMatch(child, queries, matchesList) {
|
|
|
99
98
|
break;
|
|
100
99
|
}
|
|
101
100
|
}
|
|
102
|
-
if (newChild
|
|
101
|
+
if ((_newChild = newChild) !== null && _newChild !== void 0 && (_newChild = _newChild.props) !== null && _newChild !== void 0 && _newChild.children) {
|
|
103
102
|
const modifiedChildren = _filterChildren(newChild.props.children, queries, matchesList);
|
|
104
103
|
newChild = /*#__PURE__*/React__default["default"].cloneElement(newChild, {
|
|
105
104
|
children: modifiedChildren
|
|
@@ -118,14 +117,14 @@ function filterChildren(children, queries) {
|
|
|
118
117
|
return [_filterChildren(children, queries, matchesList), matchesList];
|
|
119
118
|
}
|
|
120
119
|
|
|
121
|
-
var css_248z$H = ".
|
|
122
|
-
var styles$C = {"flyout":"
|
|
123
|
-
var stylesheet$H=".
|
|
120
|
+
var css_248z$H = "._jbWYB{background-color:#fff;border-radius:4px;border:4px solid transparent;border-right:none;border-left:none;box-shadow:0 0 0 1px #eee,0 8px 20px rgba(0,0,0,.1),0 4px 6px rgba(0,0,0,.05);z-index:1000;max-width:500px;overflow-x:hidden;overflow-y:auto;overflow:hidden auto}._rlojO{min-height:40px;padding:10px 12px;display:flex;flex-direction:row;align-items:center;cursor:pointer;font-size:14px;color:#32363a;word-break:break-word;outline:none}._rlojO._f29sy,._rlojO._XDOJs._rlojO:hover{background-color:#efefef;box-shadow:inset 0 0 0 2px #0a3f88,inset 0 0 0 4px #fff;border-radius:6px}._rlojO._OVNIb{background-color:#ebf3fb;font-weight:500;font-family:\"72Duplex\",\"72\",\"Helvetica Neue\",Helvetica,Arial,sans-serif}._rlojO._OVNIb._f29sy,._rlojO._OVNIb._XDOJs._rlojO._OVNIb:hover{background-color:#e4effa}._rlojO:active:not(._OVNIb):not([aria-disabled=true]){background-color:#e8e9e9}._K01-S ._AyuDq{min-height:40px;padding:10px 12px;display:flex;flex-direction:row;align-items:center;font-size:12px;color:#32363a;font-weight:700;word-break:break-word}._K01-S ._zFLlk{display:none}._K01-S:not(:first-child) ._zFLlk{display:block;margin:3.5px 0}._lUBAu{width:100%;height:40px}";
|
|
121
|
+
var styles$C = {"flyout":"_jbWYB","flyoutOption":"_rlojO","highlighted":"_f29sy","hoverHighlight":"_XDOJs","selected":"_OVNIb","flyoutHeader":"_K01-S","headerContent":"_AyuDq","headerDivider":"_zFLlk","flyoutSpinner":"_lUBAu"};
|
|
122
|
+
var stylesheet$H="._jbWYB{background-color:#fff;border-radius:4px;border:4px solid transparent;border-right:none;border-left:none;box-shadow:0 0 0 1px #eee,0 8px 20px rgba(0,0,0,.1),0 4px 6px rgba(0,0,0,.05);z-index:1000;max-width:500px;overflow-x:hidden;overflow-y:auto;overflow:hidden auto}._rlojO{min-height:40px;padding:10px 12px;display:flex;flex-direction:row;align-items:center;cursor:pointer;font-size:14px;color:#32363a;word-break:break-word;outline:none}._rlojO._f29sy,._rlojO._XDOJs._rlojO:hover{background-color:#efefef;box-shadow:inset 0 0 0 2px #0a3f88,inset 0 0 0 4px #fff;border-radius:6px}._rlojO._OVNIb{background-color:#ebf3fb;font-weight:500;font-family:\"72Duplex\",\"72\",\"Helvetica Neue\",Helvetica,Arial,sans-serif}._rlojO._OVNIb._f29sy,._rlojO._OVNIb._XDOJs._rlojO._OVNIb:hover{background-color:#e4effa}._rlojO:active:not(._OVNIb):not([aria-disabled=true]){background-color:#e8e9e9}._K01-S ._AyuDq{min-height:40px;padding:10px 12px;display:flex;flex-direction:row;align-items:center;font-size:12px;color:#32363a;font-weight:700;word-break:break-word}._K01-S ._zFLlk{display:none}._K01-S:not(:first-child) ._zFLlk{display:block;margin:3.5px 0}._lUBAu{width:100%;height:40px}";
|
|
124
123
|
icons_index.styleInject(css_248z$H);
|
|
125
124
|
|
|
126
|
-
var css_248z$G = ".
|
|
127
|
-
var styles$B = {"spinnerContainer":"
|
|
128
|
-
var stylesheet$G=".
|
|
125
|
+
var css_248z$G = "._ceLzc{position:relative;display:inline-block}._ceLzc._ET3A1{min-height:20px;min-width:20px}._ceLzc._blrUV{min-height:25px;min-width:25px}._ceLzc._6JLvV{min-height:40px;min-width:40px}._ceLzc._6YPlz{min-height:64px;min-width:64px}._ceLzc ._nlfOD{display:inline-block;background-color:transparent;position:absolute;z-index:10;width:0;height:0;left:50%;bottom:50%;pointer-events:none}._ceLzc ._nlfOD._W9yKe{visibility:hidden}._ceLzc ._nlfOD div{position:absolute;transform:rotate(20deg)}._ceLzc ._nlfOD div div:nth-child(-n+9){background-color:#fff;transform-origin:0 0;animation:_nlfOD .8s linear infinite}._ceLzc ._nlfOD div div:nth-child(-n+9):after{content:\" \";display:block;position:absolute;top:5px;left:-1px;width:2px;height:10px;border-radius:20%;background:#000}._ceLzc ._nlfOD div div:first-child{transform:rotate(20deg);animation-delay:-.8s}._ceLzc ._nlfOD div div:nth-child(2){transform:rotate(60deg);animation-delay:-.7s}._ceLzc ._nlfOD div div:nth-child(3){transform:rotate(100deg);animation-delay:-.6s}._ceLzc ._nlfOD div div:nth-child(4){transform:rotate(140deg);animation-delay:-.5s}._ceLzc ._nlfOD div div:nth-child(5){transform:rotate(180deg);animation-delay:-.4s}._ceLzc ._nlfOD div div:nth-child(6){transform:rotate(220deg);animation-delay:-.3s}._ceLzc ._nlfOD div div:nth-child(7){transform:rotate(260deg);animation-delay:-.2s}._ceLzc ._nlfOD div div:nth-child(8){transform:rotate(300deg);animation-delay:-.1s}._ceLzc ._nlfOD div div:nth-child(9){transform:rotate(340deg);animation-delay:0s}._ceLzc ._6YPlz div div:nth-child(-n+9):after{top:10px;left:-2px;width:4px;height:18px}._ceLzc ._ET3A1 div div:nth-child(-n+9):after{top:2px;left:-1px;width:1.5px;height:6px}._ceLzc ._blrUV div div:nth-child(-n+9):after{top:4px;left:-1px;width:2px;height:7px}._ceLzc ._412cV div div:nth-child(-n+9):after{background:#fff}._ceLzc ._-zYHC{width:100%;height:100%}._ceLzc ._-zYHC._zK519{pointer-events:none}._ceLzc ._-zYHC._W9yKe{opacity:0}._ceLzc ._-zYHC._lFu1R{opacity:.5}@keyframes _nlfOD{0%{opacity:1}to{opacity:0}}";
|
|
126
|
+
var styles$B = {"spinnerContainer":"_ceLzc","xs":"_ET3A1","small":"_blrUV","medium":"_6JLvV","large":"_6YPlz","spinnerComponent":"_nlfOD","hide":"_W9yKe","inverted":"_412cV","spinnerContent":"_-zYHC","disablePointerEvents":"_zK519","fade":"_lFu1R"};
|
|
127
|
+
var stylesheet$G="._ceLzc{position:relative;display:inline-block}._ceLzc._ET3A1{min-height:20px;min-width:20px}._ceLzc._blrUV{min-height:25px;min-width:25px}._ceLzc._6JLvV{min-height:40px;min-width:40px}._ceLzc._6YPlz{min-height:64px;min-width:64px}._ceLzc ._nlfOD{display:inline-block;background-color:transparent;position:absolute;z-index:10;width:0;height:0;left:50%;bottom:50%;pointer-events:none}._ceLzc ._nlfOD._W9yKe{visibility:hidden}._ceLzc ._nlfOD div{position:absolute;transform:rotate(20deg)}._ceLzc ._nlfOD div div:nth-child(-n+9){background-color:#fff;transform-origin:0 0;animation:_nlfOD .8s linear infinite}._ceLzc ._nlfOD div div:nth-child(-n+9):after{content:\" \";display:block;position:absolute;top:5px;left:-1px;width:2px;height:10px;border-radius:20%;background:#000}._ceLzc ._nlfOD div div:first-child{transform:rotate(20deg);animation-delay:-.8s}._ceLzc ._nlfOD div div:nth-child(2){transform:rotate(60deg);animation-delay:-.7s}._ceLzc ._nlfOD div div:nth-child(3){transform:rotate(100deg);animation-delay:-.6s}._ceLzc ._nlfOD div div:nth-child(4){transform:rotate(140deg);animation-delay:-.5s}._ceLzc ._nlfOD div div:nth-child(5){transform:rotate(180deg);animation-delay:-.4s}._ceLzc ._nlfOD div div:nth-child(6){transform:rotate(220deg);animation-delay:-.3s}._ceLzc ._nlfOD div div:nth-child(7){transform:rotate(260deg);animation-delay:-.2s}._ceLzc ._nlfOD div div:nth-child(8){transform:rotate(300deg);animation-delay:-.1s}._ceLzc ._nlfOD div div:nth-child(9){transform:rotate(340deg);animation-delay:0s}._ceLzc ._6YPlz div div:nth-child(-n+9):after{top:10px;left:-2px;width:4px;height:18px}._ceLzc ._ET3A1 div div:nth-child(-n+9):after{top:2px;left:-1px;width:1.5px;height:6px}._ceLzc ._blrUV div div:nth-child(-n+9):after{top:4px;left:-1px;width:2px;height:7px}._ceLzc ._412cV div div:nth-child(-n+9):after{background:#fff}._ceLzc ._-zYHC{width:100%;height:100%}._ceLzc ._-zYHC._zK519{pointer-events:none}._ceLzc ._-zYHC._W9yKe{opacity:0}._ceLzc ._-zYHC._lFu1R{opacity:.5}@keyframes _nlfOD{0%{opacity:1}to{opacity:0}}";
|
|
129
128
|
icons_index.styleInject(css_248z$G);
|
|
130
129
|
|
|
131
130
|
/* DO NOT MODIFY - THIS IS AN AUTO-GENERATED FILE */
|
|
@@ -245,8 +244,7 @@ function isClassComponent(component) {
|
|
|
245
244
|
return !!(typeof component === 'function' && !!component.prototype.isReactComponent);
|
|
246
245
|
}
|
|
247
246
|
function isFunctionComponent(component) {
|
|
248
|
-
|
|
249
|
-
return !!(typeof component === 'function' && _includesInstanceProperty__default["default"](_context = String(component)).call(_context, 'return React.createElement'));
|
|
247
|
+
return !!(typeof component === 'function' && String(component).includes('return React.createElement'));
|
|
250
248
|
}
|
|
251
249
|
function isReactComponent(component) {
|
|
252
250
|
return !!(isClassComponent(component) || isFunctionComponent(component));
|
|
@@ -262,9 +260,8 @@ function containsComponentOrElement(placeholders) {
|
|
|
262
260
|
}
|
|
263
261
|
|
|
264
262
|
/* eslint-disable babel/no-unused-expressions */
|
|
265
|
-
const NO_LOCALIZED_TEXT_FOR_KEY = key =>
|
|
266
|
-
const NO_LOCALIZED_OR_FALLBACK_TEXT_FOR_KEY = key =>
|
|
267
|
-
Please refer to https://designsystem.qualtrics.com/localization for more information about localizing Qualtrics ui-react components`;
|
|
263
|
+
const NO_LOCALIZED_TEXT_FOR_KEY = key => "There is no localized text for KEY: ".concat(key, ". Defaulting to fallback text");
|
|
264
|
+
const NO_LOCALIZED_OR_FALLBACK_TEXT_FOR_KEY = key => "There is no localized or fallback text for KEY: ".concat(key, ". \n Please refer to https://designsystem.qualtrics.com/localization for more information about localizing Qualtrics ui-react components");
|
|
268
265
|
const USETRANSLATION_PLACEHOLDER_CONTAINS_ELEMENT = 'The useTranslation function cannot include React elements as placeholders.';
|
|
269
266
|
const HAS_ERROR_BEEN_LOGGED_FOR_KEY = new Set();
|
|
270
267
|
|
|
@@ -284,7 +281,7 @@ const useTranslation = () => {
|
|
|
284
281
|
* @returns The translated string if found; otherwise `##${translation-key}##`.
|
|
285
282
|
*/
|
|
286
283
|
const translate = React.useCallback((key, placeholders) => {
|
|
287
|
-
const translatedText = localizedText
|
|
284
|
+
const translatedText = localizedText === null || localizedText === void 0 ? void 0 : localizedText[key];
|
|
288
285
|
const fallbackText = fallbackLocalizedText[key];
|
|
289
286
|
if (!translatedText && !HAS_ERROR_BEEN_LOGGED_FOR_KEY.has(key)) {
|
|
290
287
|
HAS_ERROR_BEEN_LOGGED_FOR_KEY.add(key);
|
|
@@ -299,7 +296,7 @@ const useTranslation = () => {
|
|
|
299
296
|
const compiledMessage = insertPlaceholders(text, placeholders);
|
|
300
297
|
return compiledMessage.join('');
|
|
301
298
|
}
|
|
302
|
-
return text ||
|
|
299
|
+
return text || "##".concat(key, "##");
|
|
303
300
|
}, [localizedText]);
|
|
304
301
|
return {
|
|
305
302
|
translate
|
|
@@ -396,7 +393,7 @@ const LoadingSpinner = /*#__PURE__*/React__default["default"].forwardRef((_ref,
|
|
|
396
393
|
}),
|
|
397
394
|
"data-loadingspinner": show || undefined,
|
|
398
395
|
role: role,
|
|
399
|
-
"aria-label": ariaLabel
|
|
396
|
+
"aria-label": ariaLabel !== null && ariaLabel !== void 0 ? ariaLabel : ariaLabelledby ? undefined : defaultAriaLabel,
|
|
400
397
|
"aria-labelledby": ariaLabelledby,
|
|
401
398
|
"aria-live": ariaLive,
|
|
402
399
|
"aria-hidden": ariaHidden
|
|
@@ -449,7 +446,7 @@ const Flyout = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
449
446
|
let content;
|
|
450
447
|
if (isLoading) {
|
|
451
448
|
content = /*#__PURE__*/React__default["default"].createElement("div", {
|
|
452
|
-
id:
|
|
449
|
+
id: "".concat(id, "-loading-spinner")
|
|
453
450
|
// eslint-disable-next-line jsx-a11y/role-has-required-aria-props
|
|
454
451
|
,
|
|
455
452
|
role: "option" // `aria-selected` is omitted because this option is not selectable
|
|
@@ -530,7 +527,7 @@ const FlyoutOption = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
530
527
|
*/
|
|
531
528
|
function getSubDataTestId(dataTestId, suffix) {
|
|
532
529
|
if (dataTestId) {
|
|
533
|
-
return
|
|
530
|
+
return "".concat(dataTestId, "-").concat(suffix);
|
|
534
531
|
}
|
|
535
532
|
return undefined;
|
|
536
533
|
}
|
|
@@ -554,7 +551,7 @@ function mergeRefs() {
|
|
|
554
551
|
try {
|
|
555
552
|
ref.current = value;
|
|
556
553
|
} catch (error) {
|
|
557
|
-
throw new Error(
|
|
554
|
+
throw new Error("Cannot assign value \"".concat(value, "\" to ref \"").concat(ref, "\": ").concat(error));
|
|
558
555
|
}
|
|
559
556
|
}
|
|
560
557
|
});
|
|
@@ -608,12 +605,13 @@ const {
|
|
|
608
605
|
isParentAnchorHidden: false
|
|
609
606
|
});
|
|
610
607
|
|
|
608
|
+
var _process$env;
|
|
611
609
|
function useMockedPopper(_, popperElement, _ref) {
|
|
612
610
|
let {
|
|
613
611
|
onFirstUpdate
|
|
614
612
|
} = _ref;
|
|
615
613
|
React.useEffect(() => {
|
|
616
|
-
onFirstUpdate
|
|
614
|
+
onFirstUpdate === null || onFirstUpdate === void 0 ? void 0 : onFirstUpdate();
|
|
617
615
|
}, [onFirstUpdate, popperElement]);
|
|
618
616
|
return {
|
|
619
617
|
styles: {
|
|
@@ -625,7 +623,7 @@ function useMockedPopper(_, popperElement, _ref) {
|
|
|
625
623
|
}
|
|
626
624
|
};
|
|
627
625
|
}
|
|
628
|
-
const usePopper = typeof process !== 'undefined' && process.env
|
|
626
|
+
const usePopper = typeof process !== 'undefined' && ((_process$env = process.env) === null || _process$env === void 0 ? void 0 : _process$env.NODE_ENV) === 'test' ? useMockedPopper : reactPopper.usePopper;
|
|
629
627
|
function useResizeObserver(_ref2) {
|
|
630
628
|
let {
|
|
631
629
|
element,
|
|
@@ -722,7 +720,7 @@ const Popper = _ref4 => {
|
|
|
722
720
|
onFirstUpdate
|
|
723
721
|
});
|
|
724
722
|
const handleUpdate = React.useCallback(() => {
|
|
725
|
-
update
|
|
723
|
+
update === null || update === void 0 ? void 0 : update();
|
|
726
724
|
}, [update]);
|
|
727
725
|
|
|
728
726
|
// Tell popper.js to update the positioning when the popper element changes size since it only listens for window resizing out of the box.
|
|
@@ -748,7 +746,10 @@ const Popper = _ref4 => {
|
|
|
748
746
|
* If the parent anchor is hidden via CSS opacity, Popper will not consider it to be hidden.
|
|
749
747
|
* To get around this issue, we set `data-popper-reference-hidden` to `true` for all child Popper elements if any ancestor Popper has `data-popper-reference-hidden` set to `true`.
|
|
750
748
|
*/
|
|
751
|
-
const isAnchorHidden = React.useMemo(() =>
|
|
749
|
+
const isAnchorHidden = React.useMemo(() => {
|
|
750
|
+
var _attributes$popper;
|
|
751
|
+
return isParentAnchorHidden || !!(attributes !== null && attributes !== void 0 && (_attributes$popper = attributes.popper) !== null && _attributes$popper !== void 0 && _attributes$popper['data-popper-reference-hidden']);
|
|
752
|
+
}, [isParentAnchorHidden, attributes]);
|
|
752
753
|
const context = React.useMemo(() => ({
|
|
753
754
|
isParentAnchorHidden: isAnchorHidden
|
|
754
755
|
}), [isAnchorHidden]);
|
|
@@ -778,7 +779,7 @@ const Popper = _ref4 => {
|
|
|
778
779
|
}, /*#__PURE__*/React__default["default"].createElement(Portal, {
|
|
779
780
|
portalTarget: portalTarget
|
|
780
781
|
}, open ? isFocusLocked ? /*#__PURE__*/React__default["default"].createElement(ReactFocusLock__default["default"], _extends__default["default"]({}, focusLockProps, {
|
|
781
|
-
disabled: isReady ? focusLockProps
|
|
782
|
+
disabled: isReady ? focusLockProps === null || focusLockProps === void 0 ? void 0 : focusLockProps.disabled : true // Prevents unintended page scroll when popper element is not yet positioned
|
|
782
783
|
}), popperElementWithArrow) : popperElementWithArrow : null)));
|
|
783
784
|
};
|
|
784
785
|
|
|
@@ -814,16 +815,16 @@ function wrapAround(value, min, max) {
|
|
|
814
815
|
*/
|
|
815
816
|
function wrapEvent(theirHandler, ourHandler) {
|
|
816
817
|
return event => {
|
|
817
|
-
theirHandler
|
|
818
|
+
theirHandler === null || theirHandler === void 0 ? void 0 : theirHandler(event);
|
|
818
819
|
if (!event.defaultPrevented) {
|
|
819
|
-
return ourHandler
|
|
820
|
+
return ourHandler === null || ourHandler === void 0 ? void 0 : ourHandler(event);
|
|
820
821
|
}
|
|
821
822
|
};
|
|
822
823
|
}
|
|
823
824
|
|
|
824
|
-
var css_248z$E = ".
|
|
825
|
-
var styles$A = {"tooltip":"
|
|
826
|
-
var stylesheet$E=".
|
|
825
|
+
var css_248z$E = "._a-i94{position:absolute;z-index:2000;max-width:240px;padding:8px 16px;color:#fff;text-align:center;text-decoration:none;background-color:#222;border-radius:4px;box-shadow:0 3px 4px 0 rgba(0,0,0,.05),0 6px 10px 0 rgba(0,0,0,.05);font-size:14px;opacity:0;pointer-events:none;overflow-wrap:break-word;border:1px solid #898989}._a-i94._GIrch{color:#32363a;background-color:#fff}._xkgll{opacity:1;pointer-events:all}._MhnYC,._MhnYC>div{position:absolute;width:8px;height:8px;background:inherit}._MhnYC{visibility:hidden;z-index:2000}._MhnYC>div{visibility:visible;border:1px solid #898989;transform:rotate(45deg)}[data-popper-placement^=top]>._MhnYC{bottom:-4px}[data-popper-placement^=top]>._MhnYC>div{border-top-color:transparent;border-left-color:transparent}[data-popper-placement^=right]>._MhnYC{left:-5px}[data-popper-placement^=right]>._MhnYC>div{border-top-color:transparent;border-right-color:transparent}[data-popper-placement^=bottom]>._MhnYC{top:-5px}[data-popper-placement^=bottom]>._MhnYC>div{border-bottom-color:transparent;border-right-color:transparent}[data-popper-placement^=left]>._MhnYC{right:-4px}[data-popper-placement^=left]>._MhnYC>div{border-bottom-color:transparent;border-left-color:transparent}._u6Iwd{position:absolute}[data-popper-placement^=top]>._u6Iwd{bottom:-13px;left:0;width:100%;height:17px}[data-popper-placement^=right]>._u6Iwd{top:0;left:-13px;width:17px;height:100%}[data-popper-placement^=bottom]>._u6Iwd{top:-13px;left:0;width:100%;height:17px}[data-popper-placement^=left]>._u6Iwd{top:0;right:-13px;width:17px;height:100%}";
|
|
826
|
+
var styles$A = {"tooltip":"_a-i94","lightTheme":"_GIrch","visible":"_xkgll","arrow":"_MhnYC","offsetBackplate":"_u6Iwd"};
|
|
827
|
+
var stylesheet$E="._a-i94{position:absolute;z-index:2000;max-width:240px;padding:8px 16px;color:#fff;text-align:center;text-decoration:none;background-color:#222;border-radius:4px;box-shadow:0 3px 4px 0 rgba(0,0,0,.05),0 6px 10px 0 rgba(0,0,0,.05);font-size:14px;opacity:0;pointer-events:none;overflow-wrap:break-word;border:1px solid #898989}._a-i94._GIrch{color:#32363a;background-color:#fff}._xkgll{opacity:1;pointer-events:all}._MhnYC,._MhnYC>div{position:absolute;width:8px;height:8px;background:inherit}._MhnYC{visibility:hidden;z-index:2000}._MhnYC>div{visibility:visible;border:1px solid #898989;transform:rotate(45deg)}[data-popper-placement^=top]>._MhnYC{bottom:-4px}[data-popper-placement^=top]>._MhnYC>div{border-top-color:transparent;border-left-color:transparent}[data-popper-placement^=right]>._MhnYC{left:-5px}[data-popper-placement^=right]>._MhnYC>div{border-top-color:transparent;border-right-color:transparent}[data-popper-placement^=bottom]>._MhnYC{top:-5px}[data-popper-placement^=bottom]>._MhnYC>div{border-bottom-color:transparent;border-right-color:transparent}[data-popper-placement^=left]>._MhnYC{right:-4px}[data-popper-placement^=left]>._MhnYC>div{border-bottom-color:transparent;border-left-color:transparent}._u6Iwd{position:absolute}[data-popper-placement^=top]>._u6Iwd{bottom:-13px;left:0;width:100%;height:17px}[data-popper-placement^=right]>._u6Iwd{top:0;left:-13px;width:17px;height:100%}[data-popper-placement^=bottom]>._u6Iwd{top:-13px;left:0;width:100%;height:17px}[data-popper-placement^=left]>._u6Iwd{top:0;right:-13px;width:17px;height:100%}";
|
|
827
828
|
icons_index.styleInject(css_248z$E);
|
|
828
829
|
|
|
829
830
|
const useSSRLayoutEffect = function () {
|
|
@@ -875,7 +876,7 @@ function useEventListener(targetOrRef, event, handler) {
|
|
|
875
876
|
return undefined;
|
|
876
877
|
}
|
|
877
878
|
const target = isEventTarget(targetOrRef) ? targetOrRef : targetOrRef.current;
|
|
878
|
-
if (target
|
|
879
|
+
if (target !== null && target !== void 0 && target.addEventListener && !isDisabled) {
|
|
879
880
|
target.addEventListener(event, listener, isCaptureEvent);
|
|
880
881
|
return () => target.removeEventListener(event, listener, isCaptureEvent);
|
|
881
882
|
}
|
|
@@ -894,10 +895,11 @@ function useClickOutside(refs, onClickOutside) {
|
|
|
894
895
|
const allRefs = React.useMemo(() => Array.isArray(refs) ? refs : [refs], [refs]);
|
|
895
896
|
const handler = event => {
|
|
896
897
|
const isInside = allRefs.some(ref => {
|
|
898
|
+
var _el$contains;
|
|
897
899
|
const {
|
|
898
900
|
current: el
|
|
899
901
|
} = ref;
|
|
900
|
-
return el
|
|
902
|
+
return el === null || el === void 0 || (_el$contains = el.contains) === null || _el$contains === void 0 ? void 0 : _el$contains.call(el, event.target);
|
|
901
903
|
});
|
|
902
904
|
if (!isInside) {
|
|
903
905
|
onClickOutside(event);
|
|
@@ -1001,10 +1003,11 @@ function useControllableState(initialState, onChange, externalState) {
|
|
|
1001
1003
|
replaceState(nextState);
|
|
1002
1004
|
}
|
|
1003
1005
|
if (nextState !== currentState) {
|
|
1006
|
+
var _onChangeRef$current;
|
|
1004
1007
|
for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
|
1005
1008
|
args[_key - 1] = arguments[_key];
|
|
1006
1009
|
}
|
|
1007
|
-
onChangeRef.current
|
|
1010
|
+
(_onChangeRef$current = onChangeRef.current) === null || _onChangeRef$current === void 0 ? void 0 : _onChangeRef$current.call(onChangeRef, nextState, ...args);
|
|
1008
1011
|
}
|
|
1009
1012
|
}, [onChangeRef, externalStateRef, internalStateRef]);
|
|
1010
1013
|
const actualState = externalState === undefined ? state : externalState;
|
|
@@ -1157,7 +1160,7 @@ function getPreviousIndex(index, numItems) {
|
|
|
1157
1160
|
* @returns If an external ID is passed in, the external ID. Otherwise, a randomly generated ID.
|
|
1158
1161
|
*/
|
|
1159
1162
|
function useId(defaultExternalId) {
|
|
1160
|
-
const [currentId] = React.useState(() => defaultExternalId
|
|
1163
|
+
const [currentId] = React.useState(() => defaultExternalId !== null && defaultExternalId !== void 0 ? defaultExternalId : uuid.v4());
|
|
1161
1164
|
return currentId;
|
|
1162
1165
|
}
|
|
1163
1166
|
|
|
@@ -1213,9 +1216,9 @@ function usePrevious(value) {
|
|
|
1213
1216
|
return ref.current;
|
|
1214
1217
|
}
|
|
1215
1218
|
|
|
1216
|
-
var css_248z$D = ".
|
|
1217
|
-
var classes = {"ariaLiveElement":"
|
|
1218
|
-
var stylesheet$D=".
|
|
1219
|
+
var css_248z$D = "._1iMHi{position:absolute;top:-10000px;left:-10000px}";
|
|
1220
|
+
var classes = {"ariaLiveElement":"_1iMHi"};
|
|
1221
|
+
var stylesheet$D="._1iMHi{position:absolute;top:-10000px;left:-10000px}";
|
|
1219
1222
|
icons_index.styleInject(css_248z$D);
|
|
1220
1223
|
|
|
1221
1224
|
/**
|
|
@@ -1241,16 +1244,18 @@ function useScreenReaderAnnouncement(politeness) {
|
|
|
1241
1244
|
|
|
1242
1245
|
// Sets the politeness of `aria-live`
|
|
1243
1246
|
React.useEffect(() => {
|
|
1244
|
-
|
|
1247
|
+
var _ariaLiveElementRef$c;
|
|
1248
|
+
if (politeness !== undefined) (_ariaLiveElementRef$c = ariaLiveElementRef.current) === null || _ariaLiveElementRef$c === void 0 ? void 0 : _ariaLiveElementRef$c.setAttribute('aria-live', politeness);
|
|
1245
1249
|
}, [politeness]);
|
|
1246
1250
|
|
|
1247
1251
|
// Announces oldest message in the queue
|
|
1248
1252
|
React.useEffect(() => {
|
|
1249
1253
|
if (!isAnnouncingMessage && messageQueue.length > 0) {
|
|
1254
|
+
var _ariaLiveElementRef$c2;
|
|
1250
1255
|
setIsAnnouncingMessage(true);
|
|
1251
1256
|
const oldestMessage = messageQueue[0];
|
|
1252
1257
|
let delay;
|
|
1253
|
-
if (ariaLiveElementRef.current
|
|
1258
|
+
if (((_ariaLiveElementRef$c2 = ariaLiveElementRef.current) === null || _ariaLiveElementRef$c2 === void 0 ? void 0 : _ariaLiveElementRef$c2.textContent) === oldestMessage) {
|
|
1254
1259
|
/*
|
|
1255
1260
|
* If the message to be announced is the same as the previous message, the message needs to be reset.
|
|
1256
1261
|
* The screen reader won't read the change unless the text has changed.
|
|
@@ -1388,7 +1393,7 @@ function subscribe(query, callback) {
|
|
|
1388
1393
|
});
|
|
1389
1394
|
}
|
|
1390
1395
|
const entry = map.get(query);
|
|
1391
|
-
entry
|
|
1396
|
+
entry === null || entry === void 0 ? void 0 : entry.subscribers.add(callback);
|
|
1392
1397
|
return entry ? function unsubscribe() {
|
|
1393
1398
|
entry.subscribers.delete(callback);
|
|
1394
1399
|
if (entry.subscribers.size === 0) {
|
|
@@ -1411,7 +1416,7 @@ function getMediaQueryValue(query) {
|
|
|
1411
1416
|
}
|
|
1412
1417
|
|
|
1413
1418
|
function getMinWidthQuery(length, unit) {
|
|
1414
|
-
return
|
|
1419
|
+
return "(min-width: ".concat(length).concat(unit, ")");
|
|
1415
1420
|
}
|
|
1416
1421
|
function getInitialValues(breakpointsConfig, unit) {
|
|
1417
1422
|
const initialValues = {};
|
|
@@ -1449,6 +1454,7 @@ function useBreakpoints() {
|
|
|
1449
1454
|
}
|
|
1450
1455
|
|
|
1451
1456
|
function useResponsiveValue(values) {
|
|
1457
|
+
var _values$returnKey;
|
|
1452
1458
|
let breakpoints = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : DEFAULT_BREAKPOINTS;
|
|
1453
1459
|
let unit = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 'em';
|
|
1454
1460
|
const matches = useBreakpoints(breakpoints, unit);
|
|
@@ -1458,10 +1464,11 @@ function useResponsiveValue(values) {
|
|
|
1458
1464
|
}
|
|
1459
1465
|
return acc;
|
|
1460
1466
|
}, undefined);
|
|
1461
|
-
return values[returnKey]
|
|
1467
|
+
return (_values$returnKey = values[returnKey]) !== null && _values$returnKey !== void 0 ? _values$returnKey : null;
|
|
1462
1468
|
}
|
|
1463
1469
|
|
|
1464
1470
|
const Tooltip = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
1471
|
+
var _children$ref;
|
|
1465
1472
|
let {
|
|
1466
1473
|
content,
|
|
1467
1474
|
unstable_contentKey: contentKey,
|
|
@@ -1496,10 +1503,14 @@ const Tooltip = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =>
|
|
|
1496
1503
|
const {
|
|
1497
1504
|
isFocusVisible
|
|
1498
1505
|
} = interactions.useFocusVisible();
|
|
1499
|
-
const getIsAnchorKeyboardFocused = () =>
|
|
1506
|
+
const getIsAnchorKeyboardFocused = () => {
|
|
1507
|
+
var _anchorRef$current;
|
|
1508
|
+
return (showOnDescendantFocus ? (_anchorRef$current = anchorRef.current) === null || _anchorRef$current === void 0 ? void 0 : _anchorRef$current.contains(document.activeElement) : document.activeElement === anchorRef.current) && isFocusVisible;
|
|
1509
|
+
};
|
|
1500
1510
|
const addAriaDescribedByToTrigger = triggeringTarget => {
|
|
1501
1511
|
if (!ariaHidden && triggeringTarget instanceof Element) {
|
|
1502
|
-
|
|
1512
|
+
var _triggeringTarget$get;
|
|
1513
|
+
const describedBy = new Set((_triggeringTarget$get = triggeringTarget.getAttribute('aria-describedby')) === null || _triggeringTarget$get === void 0 ? void 0 : _triggeringTarget$get.split(' '));
|
|
1503
1514
|
describedBy.add(flyoutContainerId);
|
|
1504
1515
|
triggeringTarget.setAttribute('aria-describedby', Array.from(describedBy).join(' '));
|
|
1505
1516
|
setTriggerElements(prev => new Set(prev).add(triggeringTarget));
|
|
@@ -1507,7 +1518,8 @@ const Tooltip = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =>
|
|
|
1507
1518
|
};
|
|
1508
1519
|
const removeAriaDescribedByFromAllTriggers = () => {
|
|
1509
1520
|
triggerElements.forEach(triggeringTarget => {
|
|
1510
|
-
|
|
1521
|
+
var _triggeringTarget$get2;
|
|
1522
|
+
const describedBy = new Set((_triggeringTarget$get2 = triggeringTarget.getAttribute('aria-describedby')) === null || _triggeringTarget$get2 === void 0 ? void 0 : _triggeringTarget$get2.split(' '));
|
|
1511
1523
|
describedBy.delete(flyoutContainerId);
|
|
1512
1524
|
if (describedBy.size > 0) {
|
|
1513
1525
|
triggeringTarget.setAttribute('aria-describedby', Array.from(describedBy).join(' '));
|
|
@@ -1636,7 +1648,7 @@ const Tooltip = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =>
|
|
|
1636
1648
|
open: isInDOM,
|
|
1637
1649
|
placement: placement,
|
|
1638
1650
|
anchor: /*#__PURE__*/React__default["default"].cloneElement(children, {
|
|
1639
|
-
ref: mergeRefs(anchorRef, children.ref
|
|
1651
|
+
ref: mergeRefs(anchorRef, (_children$ref = children.ref) !== null && _children$ref !== void 0 ? _children$ref : null)
|
|
1640
1652
|
}),
|
|
1641
1653
|
popper: /*#__PURE__*/React__default["default"].createElement("div", _extends__default["default"]({}, rest, {
|
|
1642
1654
|
id: flyoutContainerId,
|
|
@@ -1689,6 +1701,7 @@ const Tooltip = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =>
|
|
|
1689
1701
|
* Displays a tooltip containing the overflowing text if the text does not fit inside the bounds of its container.
|
|
1690
1702
|
*/
|
|
1691
1703
|
const TextOverflowTooltip = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
1704
|
+
var _textParentHTMLElemen;
|
|
1692
1705
|
let {
|
|
1693
1706
|
lightTheme = false,
|
|
1694
1707
|
delayMs = 500,
|
|
@@ -1708,7 +1721,7 @@ const TextOverflowTooltip = /*#__PURE__*/React__default["default"].forwardRef((_
|
|
|
1708
1721
|
]);
|
|
1709
1722
|
|
|
1710
1723
|
return /*#__PURE__*/React__default["default"].createElement(Tooltip, {
|
|
1711
|
-
content: textParentHTMLElementRef.current
|
|
1724
|
+
content: (_textParentHTMLElemen = textParentHTMLElementRef.current) === null || _textParentHTMLElemen === void 0 ? void 0 : _textParentHTMLElemen.textContent,
|
|
1712
1725
|
disabled: !isTextOverflowing,
|
|
1713
1726
|
lightTheme: lightTheme,
|
|
1714
1727
|
delayMs: delayMs,
|
|
@@ -1800,7 +1813,7 @@ const Accordion = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
1800
1813
|
}
|
|
1801
1814
|
});
|
|
1802
1815
|
const toggleSection = React.useCallback(sectionId => {
|
|
1803
|
-
if (
|
|
1816
|
+
if (openSectionIds.includes(sectionId)) {
|
|
1804
1817
|
setOpenSectionIds(prevOpenSectionIds => prevOpenSectionIds.filter(id => id !== sectionId));
|
|
1805
1818
|
} else if (isMultiOpen) {
|
|
1806
1819
|
setOpenSectionIds(prevOpenSectionIds => [...prevOpenSectionIds, sectionId]);
|
|
@@ -1823,7 +1836,7 @@ const Accordion = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
1823
1836
|
return /*#__PURE__*/React__default["default"].createElement("div", {
|
|
1824
1837
|
ref: ref,
|
|
1825
1838
|
className: classNames__default["default"](AccordionStyles.accordion, {
|
|
1826
|
-
[AccordionStyles[
|
|
1839
|
+
[AccordionStyles["".concat(variant, "-variant")]]: variant
|
|
1827
1840
|
}),
|
|
1828
1841
|
"data-testid": dataTestId
|
|
1829
1842
|
}, /*#__PURE__*/React__default["default"].createElement(AccordionContextProvider, {
|
|
@@ -1846,7 +1859,7 @@ const AccordionSection = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
1846
1859
|
} = useAccordionContext();
|
|
1847
1860
|
const [isOpen, setIsOpen] = React.useState(false);
|
|
1848
1861
|
React.useEffect(() => {
|
|
1849
|
-
if (openSectionIds !== undefined) setIsOpen(
|
|
1862
|
+
if (openSectionIds !== undefined) setIsOpen(openSectionIds.includes(sectionId));
|
|
1850
1863
|
}, [sectionId, openSectionIds]);
|
|
1851
1864
|
const classes = classNames__default["default"](AccordionStyles.section, {
|
|
1852
1865
|
[AccordionStyles.closed]: !isOpen
|
|
@@ -1902,17 +1915,18 @@ const AccordionHeader = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
1902
1915
|
}, [registerNode, deregisterNode]);
|
|
1903
1916
|
return /*#__PURE__*/React__default["default"].createElement("div", {
|
|
1904
1917
|
role: headingLevel ? 'heading' : undefined,
|
|
1905
|
-
"aria-level": headingLevel
|
|
1918
|
+
"aria-level": headingLevel !== null && headingLevel !== void 0 ? headingLevel : undefined,
|
|
1906
1919
|
ref: ref
|
|
1907
1920
|
}, /*#__PURE__*/React__default["default"].createElement("button", {
|
|
1908
1921
|
className: classes,
|
|
1909
1922
|
ref: headerRef,
|
|
1910
|
-
id:
|
|
1923
|
+
id: "accordion-header-".concat(sectionId),
|
|
1911
1924
|
onClick: handleClick,
|
|
1912
1925
|
onKeyDown: handleKeyDown,
|
|
1913
1926
|
"aria-expanded": isOpen,
|
|
1914
|
-
"aria-controls":
|
|
1915
|
-
"
|
|
1927
|
+
"aria-controls": "accordion-panel-".concat(sectionId),
|
|
1928
|
+
"aria-disabled": isDisabled,
|
|
1929
|
+
"data-testid": getSubDataTestId(dataTestId, "section-".concat(position, "-header")),
|
|
1916
1930
|
type: "button"
|
|
1917
1931
|
}, isOpen ? /*#__PURE__*/React__default["default"].createElement(icons_index.CaretDownIcon, {
|
|
1918
1932
|
"aria-hidden": true,
|
|
@@ -1940,10 +1954,10 @@ const AccordionPanel = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
1940
1954
|
return /*#__PURE__*/React__default["default"].createElement("div", {
|
|
1941
1955
|
className: classNames__default["default"](className, AccordionStyles.panel),
|
|
1942
1956
|
ref: ref,
|
|
1943
|
-
id:
|
|
1957
|
+
id: "accordion-panel-".concat(sectionId),
|
|
1944
1958
|
role: "region",
|
|
1945
|
-
"aria-labelledby":
|
|
1946
|
-
"data-testid": getSubDataTestId(dataTestId,
|
|
1959
|
+
"aria-labelledby": "accordion-header-".concat(sectionId),
|
|
1960
|
+
"data-testid": getSubDataTestId(dataTestId, "section-".concat(position, "-panel"))
|
|
1947
1961
|
}, children);
|
|
1948
1962
|
});
|
|
1949
1963
|
|
|
@@ -1992,9 +2006,9 @@ function BreakpointSwitch(_ref) {
|
|
|
1992
2006
|
}, useResponsiveValue(childList));
|
|
1993
2007
|
}
|
|
1994
2008
|
|
|
1995
|
-
var css_248z$C = ".
|
|
1996
|
-
var buttonStyles = {"btn":"
|
|
1997
|
-
var stylesheet$C=".
|
|
2009
|
+
var css_248z$C = "._U--V5{padding:0 16px;font-size:14px;line-height:14px;color:#fff;fill:#fff;background-color:#fff;border:1px solid #fff;border-radius:4px;height:36px;min-height:36px;cursor:pointer;position:relative;display:inline-flex;justify-content:center;align-items:center;text-decoration:none;overflow:hidden;transition:border .2s,background .2s,color .2s}._U--V5._8D1KI{padding:0 8px;height:26px;min-height:26px}._U--V5._PdjYa{display:block;width:100%}._U--V5._jEbm7{cursor:not-allowed}._U--V5:active:focus,._U--V5:focus{outline:none}._U--V5._2lOEc{background-color:#fff;border-color:#515559;color:#515559;fill:#515559}._U--V5._2lOEc:hover:not(._jEbm7){background-color:#eee}._U--V5._2lOEc:active:not(._jEbm7){background-color:#e5e5e5}._U--V5._2lOEc._jEbm7{color:rgba(81,85,89,.4);fill:rgba(81,85,89,.4);background-color:hsla(0,0%,100%,.4);border:1px solid rgba(81,85,89,.4)}._U--V5._p2Y5M{background-color:#0b6ed0;border-color:#0b6ed0;color:#fff;fill:#fff}._U--V5._p2Y5M:hover:not(._jEbm7){background-color:#085caf;border-color:#085caf}._U--V5._p2Y5M:active:not(._jEbm7){background-color:#0854a1;border-color:#0854a1}._U--V5._p2Y5M._jEbm7{background-color:rgba(11,110,208,.4);border-color:transparent;fill:hsla(0,0%,100%,.4)}._U--V5._CoqTM{background-color:#fff;border-color:#0b6ed0;color:#0b6ed0;fill:#0b6ed0}._U--V5._CoqTM:hover:not(._jEbm7){background-color:#eef5fc}._U--V5._CoqTM:active:not(._jEbm7){background-color:#e1edf9}._U--V5._CoqTM._jEbm7{background-color:hsla(0,0%,100%,.4);border-color:rgba(11,110,208,.4);color:rgba(11,110,208,.4);fill:rgba(11,110,208,.4)}._U--V5._afQeg{background-color:#fff;border-color:#fff;color:#0b6ed0;fill:#0b6ed0}._U--V5._afQeg:hover:not(._jEbm7){background-color:#eef5fc;border-color:#eef5fc}._U--V5._afQeg:active:not(._jEbm7){background-color:#e1edf9;border-color:#e1edf9}._U--V5._afQeg._jEbm7{background-color:hsla(0,0%,100%,.4);border-color:hsla(0,0%,100%,.4);color:rgba(11,110,208,.4);fill:rgba(11,110,208,.4)}._U--V5._MkOjH{color:#0b6ed0;fill:#0b6ed0;padding:0}._U--V5._MkOjH:hover:not(._jEbm7){color:#085caf}._U--V5._MkOjH:active:not(._jEbm7){color:#0854a1}._U--V5._MkOjH._jEbm7{color:rgba(11,110,208,.4);fill:rgba(11,110,208,.4)}._U--V5._OApZb{background-color:#fff;border-color:#b00;color:#b00;fill:#b00}._U--V5._OApZb:hover:not(._jEbm7){background-color:#ffecec}._U--V5._OApZb:active:not(._jEbm7){background-color:#ffdbdb}._U--V5._OApZb._jEbm7{background-color:hsla(0,0%,100%,.4);border-color:rgba(187,0,0,.4);color:rgba(187,0,0,.4);fill:rgba(187,0,0,.4)}._U--V5.focus-visible,._U--V5:focus-visible{outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
2010
|
+
var buttonStyles = {"btn":"_U--V5","small":"_8D1KI","full":"_PdjYa","disabled":"_jEbm7","default":"_2lOEc","primary":"_p2Y5M","secondary":"_CoqTM","tertiary":"_afQeg","link":"_MkOjH","danger":"_OApZb"};
|
|
2011
|
+
var stylesheet$C="._U--V5{padding:0 16px;font-size:14px;line-height:14px;color:#fff;fill:#fff;background-color:#fff;border:1px solid #fff;border-radius:4px;height:36px;min-height:36px;cursor:pointer;position:relative;display:inline-flex;justify-content:center;align-items:center;text-decoration:none;overflow:hidden;transition:border .2s,background .2s,color .2s}._U--V5._8D1KI{padding:0 8px;height:26px;min-height:26px}._U--V5._PdjYa{display:block;width:100%}._U--V5._jEbm7{cursor:not-allowed}._U--V5:active:focus,._U--V5:focus{outline:none}._U--V5._2lOEc{background-color:#fff;border-color:#515559;color:#515559;fill:#515559}._U--V5._2lOEc:hover:not(._jEbm7){background-color:#eee}._U--V5._2lOEc:active:not(._jEbm7){background-color:#e5e5e5}._U--V5._2lOEc._jEbm7{color:rgba(81,85,89,.4);fill:rgba(81,85,89,.4);background-color:hsla(0,0%,100%,.4);border:1px solid rgba(81,85,89,.4)}._U--V5._p2Y5M{background-color:#0b6ed0;border-color:#0b6ed0;color:#fff;fill:#fff}._U--V5._p2Y5M:hover:not(._jEbm7){background-color:#085caf;border-color:#085caf}._U--V5._p2Y5M:active:not(._jEbm7){background-color:#0854a1;border-color:#0854a1}._U--V5._p2Y5M._jEbm7{background-color:rgba(11,110,208,.4);border-color:transparent;fill:hsla(0,0%,100%,.4)}._U--V5._CoqTM{background-color:#fff;border-color:#0b6ed0;color:#0b6ed0;fill:#0b6ed0}._U--V5._CoqTM:hover:not(._jEbm7){background-color:#eef5fc}._U--V5._CoqTM:active:not(._jEbm7){background-color:#e1edf9}._U--V5._CoqTM._jEbm7{background-color:hsla(0,0%,100%,.4);border-color:rgba(11,110,208,.4);color:rgba(11,110,208,.4);fill:rgba(11,110,208,.4)}._U--V5._afQeg{background-color:#fff;border-color:#fff;color:#0b6ed0;fill:#0b6ed0}._U--V5._afQeg:hover:not(._jEbm7){background-color:#eef5fc;border-color:#eef5fc}._U--V5._afQeg:active:not(._jEbm7){background-color:#e1edf9;border-color:#e1edf9}._U--V5._afQeg._jEbm7{background-color:hsla(0,0%,100%,.4);border-color:hsla(0,0%,100%,.4);color:rgba(11,110,208,.4);fill:rgba(11,110,208,.4)}._U--V5._MkOjH{color:#0b6ed0;fill:#0b6ed0;padding:0}._U--V5._MkOjH:hover:not(._jEbm7){color:#085caf}._U--V5._MkOjH:active:not(._jEbm7){color:#0854a1}._U--V5._MkOjH._jEbm7{color:rgba(11,110,208,.4);fill:rgba(11,110,208,.4)}._U--V5._OApZb{background-color:#fff;border-color:#b00;color:#b00;fill:#b00}._U--V5._OApZb:hover:not(._jEbm7){background-color:#ffecec}._U--V5._OApZb:active:not(._jEbm7){background-color:#ffdbdb}._U--V5._OApZb._jEbm7{background-color:hsla(0,0%,100%,.4);border-color:rgba(187,0,0,.4);color:rgba(187,0,0,.4);fill:rgba(187,0,0,.4)}._U--V5.focus-visible,._U--V5:focus-visible{outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
1998
2012
|
icons_index.styleInject(css_248z$C);
|
|
1999
2013
|
|
|
2000
2014
|
function createContextValue(value) {
|
|
@@ -2051,14 +2065,14 @@ const Button = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =>
|
|
|
2051
2065
|
// stops form submission for type="submit"
|
|
2052
2066
|
return e.preventDefault();
|
|
2053
2067
|
}
|
|
2054
|
-
onClick
|
|
2068
|
+
onClick === null || onClick === void 0 ? void 0 : onClick(e);
|
|
2055
2069
|
};
|
|
2056
2070
|
const keyDownHandler = disabled ? undefined : onKeyDown;
|
|
2057
2071
|
return (
|
|
2058
2072
|
/*#__PURE__*/
|
|
2059
2073
|
/* eslint-disable react/button-has-type */
|
|
2060
2074
|
React__default["default"].createElement("button", _extends__default["default"]({}, rest, {
|
|
2061
|
-
"aria-disabled": ariaDisabled
|
|
2075
|
+
"aria-disabled": ariaDisabled !== null && ariaDisabled !== void 0 ? ariaDisabled : disabled,
|
|
2062
2076
|
type: type,
|
|
2063
2077
|
className: classes,
|
|
2064
2078
|
ref: ref,
|
|
@@ -2069,9 +2083,9 @@ const Button = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =>
|
|
|
2069
2083
|
);
|
|
2070
2084
|
});
|
|
2071
2085
|
|
|
2072
|
-
var css_248z$B = ".
|
|
2073
|
-
var styles$z = {"buttonGroup":"
|
|
2074
|
-
var stylesheet$B=".
|
|
2086
|
+
var css_248z$B = "._mltkU{display:inline-flex;align-items:stretch}._mltkU._dYUPH{width:100%}._mltkU ._zsE2Q{margin:0;min-width:0}._mltkU ._zsE2Q:focus{z-index:20}._mltkU ._zsE2Q:hover{z-index:10}._mltkU ._zsE2Q._suI0p{border:none}._mltkU ._zsE2Q._dYUPH{display:inline-flex;width:auto;flex-grow:1}._mltkU ._zsE2Q:first-child{margin:0 -1px 0 0;border-top-left-radius:4px;border-bottom-left-radius:4px;border-top-right-radius:0;border-bottom-right-radius:0}._mltkU ._zsE2Q:first-child._suI0p{border-right:1px solid #fff}._mltkU ._zsE2Q:not(:last-child):not(:first-child){margin:0 -1px 0 0;border-radius:0}._mltkU ._zsE2Q:not(:last-child):not(:first-child)._suI0p{border-left:1px solid #fff;border-right:1px solid #fff}._mltkU ._zsE2Q:last-child{margin:0;border-top-left-radius:0;border-bottom-left-radius:0;border-top-right-radius:4px;border-bottom-right-radius:4px}._mltkU ._zsE2Q:last-child._suI0p{border-left:1px solid #fff}._mltkU ._zsE2Q:only-child{margin:0;border-top-left-radius:4px;border-bottom-left-radius:4px;border-top-right-radius:4px;border-bottom-right-radius:4px}";
|
|
2087
|
+
var styles$z = {"buttonGroup":"_mltkU","full":"_dYUPH","buttonGroupElement":"_zsE2Q","primary":"_suI0p"};
|
|
2088
|
+
var stylesheet$B="._mltkU{display:inline-flex;align-items:stretch}._mltkU._dYUPH{width:100%}._mltkU ._zsE2Q{margin:0;min-width:0}._mltkU ._zsE2Q:focus{z-index:20}._mltkU ._zsE2Q:hover{z-index:10}._mltkU ._zsE2Q._suI0p{border:none}._mltkU ._zsE2Q._dYUPH{display:inline-flex;width:auto;flex-grow:1}._mltkU ._zsE2Q:first-child{margin:0 -1px 0 0;border-top-left-radius:4px;border-bottom-left-radius:4px;border-top-right-radius:0;border-bottom-right-radius:0}._mltkU ._zsE2Q:first-child._suI0p{border-right:1px solid #fff}._mltkU ._zsE2Q:not(:last-child):not(:first-child){margin:0 -1px 0 0;border-radius:0}._mltkU ._zsE2Q:not(:last-child):not(:first-child)._suI0p{border-left:1px solid #fff;border-right:1px solid #fff}._mltkU ._zsE2Q:last-child{margin:0;border-top-left-radius:0;border-bottom-left-radius:0;border-top-right-radius:4px;border-bottom-right-radius:4px}._mltkU ._zsE2Q:last-child._suI0p{border-left:1px solid #fff}._mltkU ._zsE2Q:only-child{margin:0;border-top-left-radius:4px;border-bottom-left-radius:4px;border-top-right-radius:4px;border-bottom-right-radius:4px}";
|
|
2075
2089
|
icons_index.styleInject(css_248z$B);
|
|
2076
2090
|
|
|
2077
2091
|
const ButtonGroup = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
@@ -2092,7 +2106,7 @@ const ButtonGroup = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref
|
|
|
2092
2106
|
}), React__default["default"].Children.map(children, child => {
|
|
2093
2107
|
if (! /*#__PURE__*/React__default["default"].isValidElement(child)) {
|
|
2094
2108
|
// eslint-disable-next-line no-console
|
|
2095
|
-
console.warn(
|
|
2109
|
+
console.warn("Warning: \"".concat(child, "\" is invalid child of ButtonGroup!"));
|
|
2096
2110
|
return null;
|
|
2097
2111
|
}
|
|
2098
2112
|
const buttonElementClasses = classNames__default["default"](child.props.className, styles$z.buttonGroupElement, {
|
|
@@ -2108,9 +2122,9 @@ const ButtonGroup = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref
|
|
|
2108
2122
|
}));
|
|
2109
2123
|
});
|
|
2110
2124
|
|
|
2111
|
-
var css_248z$A = ".
|
|
2112
|
-
var styles$y = {"checkbox":"
|
|
2113
|
-
var stylesheet$A=".
|
|
2125
|
+
var css_248z$A = "._UDUdI{display:inline-flex;position:relative;margin-top:6px;margin-bottom:6px}._pLfXg,._UDUdI{cursor:pointer;height:16px;width:16px}._pLfXg{position:absolute;opacity:0;z-index:10}._pLfXg:checked~._BIrnZ>._SgN-D{fill-opacity:1}._pLfXg:checked:enabled~._BIrnZ{border-color:transparent;background-color:#0b6ed0}._pLfXg:checked:enabled~._BIrnZ>._SgN-D{fill:#fff}._pLfXg:checked:enabled:hover~._BIrnZ{background-color:#085caf}._pLfXg:not(:checked):enabled:hover~._BIrnZ{border-color:#0b6ed0}._pLfXg:disabled{cursor:not-allowed}._pLfXg:disabled~._BIrnZ{opacity:.4}._8sWUL{color:#32363a;display:flex;align-items:center;cursor:pointer}._wwDHB{cursor:auto;color:hsla(0,0%,53.7%,.4)}._B40I4{margin-right:12px;flex-shrink:0}._BIrnZ{display:flex;align-items:center;justify-content:center;position:absolute;top:0;left:0;height:16px;width:16px;background-color:#fff;border-radius:4px;border:1px solid #898989;z-index:0}._SgN-D{fill:#0b6ed0;fill-opacity:0}._pLfXg.focus-visible~._BIrnZ,._pLfXg:focus-visible~._BIrnZ{border-color:#0b6ed0;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
2126
|
+
var styles$y = {"checkbox":"_UDUdI","input":"_pLfXg","check":"_BIrnZ","checkIcon":"_SgN-D","label":"_8sWUL","labelDisabled":"_wwDHB","wrappedInput":"_B40I4"};
|
|
2127
|
+
var stylesheet$A="._UDUdI{display:inline-flex;position:relative;margin-top:6px;margin-bottom:6px}._pLfXg,._UDUdI{cursor:pointer;height:16px;width:16px}._pLfXg{position:absolute;opacity:0;z-index:10}._pLfXg:checked~._BIrnZ>._SgN-D{fill-opacity:1}._pLfXg:checked:enabled~._BIrnZ{border-color:transparent;background-color:#0b6ed0}._pLfXg:checked:enabled~._BIrnZ>._SgN-D{fill:#fff}._pLfXg:checked:enabled:hover~._BIrnZ{background-color:#085caf}._pLfXg:not(:checked):enabled:hover~._BIrnZ{border-color:#0b6ed0}._pLfXg:disabled{cursor:not-allowed}._pLfXg:disabled~._BIrnZ{opacity:.4}._8sWUL{color:#32363a;display:flex;align-items:center;cursor:pointer}._wwDHB{cursor:auto;color:hsla(0,0%,53.7%,.4)}._B40I4{margin-right:12px;flex-shrink:0}._BIrnZ{display:flex;align-items:center;justify-content:center;position:absolute;top:0;left:0;height:16px;width:16px;background-color:#fff;border-radius:4px;border:1px solid #898989;z-index:0}._SgN-D{fill:#0b6ed0;fill-opacity:0}._pLfXg.focus-visible~._BIrnZ,._pLfXg:focus-visible~._BIrnZ{border-color:#0b6ed0;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
2114
2128
|
icons_index.styleInject(css_248z$A);
|
|
2115
2129
|
|
|
2116
2130
|
const Check = props => /*#__PURE__*/React__default["default"].createElement("svg", _extends__default["default"]({}, props, {
|
|
@@ -2137,7 +2151,7 @@ const useFormFieldControl = () => {
|
|
|
2137
2151
|
setHasControl
|
|
2138
2152
|
} = context;
|
|
2139
2153
|
React.useEffect(() => {
|
|
2140
|
-
setHasControl
|
|
2154
|
+
setHasControl === null || setHasControl === void 0 ? void 0 : setHasControl(true);
|
|
2141
2155
|
}, [setHasControl]);
|
|
2142
2156
|
return context;
|
|
2143
2157
|
};
|
|
@@ -2147,7 +2161,7 @@ const useFormFieldLabel = () => {
|
|
|
2147
2161
|
setHasLabel
|
|
2148
2162
|
} = context;
|
|
2149
2163
|
React.useEffect(() => {
|
|
2150
|
-
setHasLabel
|
|
2164
|
+
setHasLabel === null || setHasLabel === void 0 ? void 0 : setHasLabel(true);
|
|
2151
2165
|
}, [setHasLabel]);
|
|
2152
2166
|
return context;
|
|
2153
2167
|
};
|
|
@@ -2157,7 +2171,7 @@ const useFormFieldType = type => {
|
|
|
2157
2171
|
setFormFieldType
|
|
2158
2172
|
} = context;
|
|
2159
2173
|
React.useEffect(() => {
|
|
2160
|
-
setFormFieldType
|
|
2174
|
+
setFormFieldType === null || setFormFieldType === void 0 ? void 0 : setFormFieldType(type);
|
|
2161
2175
|
}, [setFormFieldType, type]);
|
|
2162
2176
|
return context;
|
|
2163
2177
|
};
|
|
@@ -2182,22 +2196,22 @@ const Checkbox = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
2182
2196
|
helperTextId: formFieldHelperTextId,
|
|
2183
2197
|
errorTextId: formFieldErrorTextId
|
|
2184
2198
|
} = useFormFieldContext();
|
|
2185
|
-
const internalAriaDescribedby = concatIds(externalAriaDescribedBy, formFieldHelperTextId, formFieldErrorTextId, inputProps
|
|
2199
|
+
const internalAriaDescribedby = concatIds(externalAriaDescribedBy, formFieldHelperTextId, formFieldErrorTextId, inputProps === null || inputProps === void 0 ? void 0 : inputProps['aria-describedby']);
|
|
2186
2200
|
return /*#__PURE__*/React__default["default"].createElement("span", _extends__default["default"]({}, rest, {
|
|
2187
2201
|
ref: ref,
|
|
2188
2202
|
className: classNames__default["default"](className, styles$y.checkbox)
|
|
2189
2203
|
}), /*#__PURE__*/React__default["default"].createElement("input", _extends__default["default"]({}, inputProps, {
|
|
2190
|
-
name: name
|
|
2191
|
-
className: classNames__default["default"](styles$y.input, inputProps
|
|
2204
|
+
name: name !== null && name !== void 0 ? name : inputProps === null || inputProps === void 0 ? void 0 : inputProps.name,
|
|
2205
|
+
className: classNames__default["default"](styles$y.input, inputProps === null || inputProps === void 0 ? void 0 : inputProps.className),
|
|
2192
2206
|
type: "checkbox",
|
|
2193
|
-
id: id
|
|
2194
|
-
checked: checked
|
|
2195
|
-
defaultChecked: defaultChecked
|
|
2196
|
-
disabled: disabled
|
|
2197
|
-
onChange: disabled ? undefined : onChange
|
|
2198
|
-
value: value
|
|
2199
|
-
"aria-label": externalAriaLabel
|
|
2200
|
-
"aria-labelledby": externalAriaLabelledBy
|
|
2207
|
+
id: id !== null && id !== void 0 ? id : inputProps === null || inputProps === void 0 ? void 0 : inputProps.id,
|
|
2208
|
+
checked: checked !== null && checked !== void 0 ? checked : inputProps === null || inputProps === void 0 ? void 0 : inputProps.checked,
|
|
2209
|
+
defaultChecked: defaultChecked !== null && defaultChecked !== void 0 ? defaultChecked : inputProps === null || inputProps === void 0 ? void 0 : inputProps.defaultChecked,
|
|
2210
|
+
disabled: disabled !== null && disabled !== void 0 ? disabled : inputProps === null || inputProps === void 0 ? void 0 : inputProps.disabled,
|
|
2211
|
+
onChange: disabled ? undefined : onChange !== null && onChange !== void 0 ? onChange : inputProps === null || inputProps === void 0 ? void 0 : inputProps.onChange,
|
|
2212
|
+
value: value !== null && value !== void 0 ? value : inputProps === null || inputProps === void 0 ? void 0 : inputProps.value,
|
|
2213
|
+
"aria-label": externalAriaLabel !== null && externalAriaLabel !== void 0 ? externalAriaLabel : inputProps === null || inputProps === void 0 ? void 0 : inputProps['aria-label'],
|
|
2214
|
+
"aria-labelledby": externalAriaLabelledBy !== null && externalAriaLabelledBy !== void 0 ? externalAriaLabelledBy : inputProps === null || inputProps === void 0 ? void 0 : inputProps['aria-labelledby'],
|
|
2201
2215
|
"aria-describedby": internalAriaDescribedby
|
|
2202
2216
|
})), /*#__PURE__*/React__default["default"].createElement("span", {
|
|
2203
2217
|
className: styles$y.check
|
|
@@ -2206,9 +2220,9 @@ const Checkbox = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
2206
2220
|
})));
|
|
2207
2221
|
});
|
|
2208
2222
|
|
|
2209
|
-
var css_248z$z = ".
|
|
2210
|
-
var styles$x = {"label":"
|
|
2211
|
-
var stylesheet$z=".
|
|
2223
|
+
var css_248z$z = "._BN4wB{font-size:14px}._Sa4fS{color:#6a6d70;line-height:20px;display:inline-flex;flex-direction:column;align-items:flex-start}._mQOHy{color:#0b6ed0}";
|
|
2224
|
+
var styles$x = {"label":"_BN4wB","control":"_Sa4fS","focused":"_mQOHy"};
|
|
2225
|
+
var stylesheet$z="._BN4wB{font-size:14px}._Sa4fS{color:#6a6d70;line-height:20px;display:inline-flex;flex-direction:column;align-items:flex-start}._mQOHy{color:#0b6ed0}";
|
|
2212
2226
|
icons_index.styleInject(css_248z$z);
|
|
2213
2227
|
|
|
2214
2228
|
const Label = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
@@ -2264,9 +2278,9 @@ const CheckboxField = /*#__PURE__*/React__default["default"].forwardRef((_ref, r
|
|
|
2264
2278
|
}), label);
|
|
2265
2279
|
});
|
|
2266
2280
|
|
|
2267
|
-
var css_248z$y = ".
|
|
2268
|
-
var styles$w = {"input":"
|
|
2269
|
-
var stylesheet$y=".
|
|
2281
|
+
var css_248z$y = "._UI-Q6{display:inline-block;height:36px;min-height:36px;padding:8px 12px;line-height:20px;font-size:14px;color:#32363a;caret-color:#32363a;background-color:#fafafa;border:1px solid #898989;border-radius:4px;outline:none}._UI-Q6::-moz-placeholder{color:#515559;opacity:1}._UI-Q6::placeholder{color:#515559;opacity:1}._UI-Q6:hover{cursor:pointer;background-color:#f5f5f5}._UI-Q6:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88;background-color:#fafafa;cursor:text;outline:none;border-color:transparent}._UI-Q6._jTMbC{border-color:#b00}._UI-Q6._jTMbC:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #900000;border-color:transparent}._UI-Q6:disabled{background-color:#fafafa;border-color:#e5e5e5;color:#9d9fa1;-webkit-text-fill-color:#9d9fa1;cursor:not-allowed}._UI-Q6:disabled::-moz-placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._UI-Q6:disabled::placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._UI-Q6._quq1x{height:auto}._UI-Q6._quq1x::-webkit-resizer{background-image:url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iOCIgaGVpZ2h0PSI4IiBmaWxsPSJub25lIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjxwYXRoIGQ9Ik03IDF2M2EzIDMgMCAwMS0zIDNIMSIgc3Ryb2tlPSIjOTI5MjkyIiBzdHJva2Utd2lkdGg9IjIiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIvPjwvc3ZnPg==);background-size:8px 8px;background-repeat:no-repeat;background-position:50%}._UI-Q6._8ew-r{display:block;width:100%}._UI-Q6._rkpMg{padding:4px 8px}input._UI-Q6._rkpMg{height:26px;min-height:26px}[type=number]._UI-Q6{-moz-appearance:textfield}[type=number]._UI-Q6::-webkit-inner-spin-button,[type=number]._UI-Q6::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}._9qSWw{line-height:20px;color:#6a6d70;display:flex;flex-direction:column;align-items:flex-start}._9qSWw:hover{cursor:pointer}._9qSWw._TbI3j{color:#0b6ed0}._INB7-{margin-top:4px}";
|
|
2282
|
+
var styles$w = {"input":"_UI-Q6","invalid":"_jTMbC","multiline":"_quq1x","full":"_8ew-r","small":"_rkpMg","label":"_9qSWw","focused":"_TbI3j","wrappedInput":"_INB7-"};
|
|
2283
|
+
var stylesheet$y="._UI-Q6{display:inline-block;height:36px;min-height:36px;padding:8px 12px;line-height:20px;font-size:14px;color:#32363a;caret-color:#32363a;background-color:#fafafa;border:1px solid #898989;border-radius:4px;outline:none}._UI-Q6::-moz-placeholder{color:#515559;opacity:1}._UI-Q6::placeholder{color:#515559;opacity:1}._UI-Q6:hover{cursor:pointer;background-color:#f5f5f5}._UI-Q6:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88;background-color:#fafafa;cursor:text;outline:none;border-color:transparent}._UI-Q6._jTMbC{border-color:#b00}._UI-Q6._jTMbC:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #900000;border-color:transparent}._UI-Q6:disabled{background-color:#fafafa;border-color:#e5e5e5;color:#9d9fa1;-webkit-text-fill-color:#9d9fa1;cursor:not-allowed}._UI-Q6:disabled::-moz-placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._UI-Q6:disabled::placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._UI-Q6._quq1x{height:auto}._UI-Q6._quq1x::-webkit-resizer{background-image:url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iOCIgaGVpZ2h0PSI4IiBmaWxsPSJub25lIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPjxwYXRoIGQ9Ik03IDF2M2EzIDMgMCAwMS0zIDNIMSIgc3Ryb2tlPSIjOTI5MjkyIiBzdHJva2Utd2lkdGg9IjIiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIvPjwvc3ZnPg==);background-size:8px 8px;background-repeat:no-repeat;background-position:50%}._UI-Q6._8ew-r{display:block;width:100%}._UI-Q6._rkpMg{padding:4px 8px}input._UI-Q6._rkpMg{height:26px;min-height:26px}[type=number]._UI-Q6{-moz-appearance:textfield}[type=number]._UI-Q6::-webkit-inner-spin-button,[type=number]._UI-Q6::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}._9qSWw{line-height:20px;color:#6a6d70;display:flex;flex-direction:column;align-items:flex-start}._9qSWw:hover{cursor:pointer}._9qSWw._TbI3j{color:#0b6ed0}._INB7-{margin-top:4px}";
|
|
2270
2284
|
icons_index.styleInject(css_248z$y);
|
|
2271
2285
|
|
|
2272
2286
|
const Input$1 = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
@@ -2309,7 +2323,7 @@ const Input$1 = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =>
|
|
|
2309
2323
|
onChange: disabled ? null : onChange,
|
|
2310
2324
|
value,
|
|
2311
2325
|
'aria-describedby': internalAriaDescribedby,
|
|
2312
|
-
readOnly: readOnly
|
|
2326
|
+
readOnly: readOnly !== null && readOnly !== void 0 ? readOnly : formFieldIsReadOnly
|
|
2313
2327
|
};
|
|
2314
2328
|
return multiline ? /*#__PURE__*/React__default["default"].createElement("textarea", _extends__default["default"]({}, commonProps, {
|
|
2315
2329
|
rows: rows
|
|
@@ -2343,11 +2357,11 @@ const InputField = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref)
|
|
|
2343
2357
|
useFormFieldType('input');
|
|
2344
2358
|
function handleFocus(e) {
|
|
2345
2359
|
setFocused(true);
|
|
2346
|
-
onFocus
|
|
2360
|
+
onFocus === null || onFocus === void 0 ? void 0 : onFocus(e);
|
|
2347
2361
|
}
|
|
2348
2362
|
function handleBlur(e) {
|
|
2349
2363
|
setFocused(false);
|
|
2350
|
-
onBlur
|
|
2364
|
+
onBlur === null || onBlur === void 0 ? void 0 : onBlur(e);
|
|
2351
2365
|
}
|
|
2352
2366
|
return /*#__PURE__*/React__default["default"].createElement(Label, _extends__default["default"]({
|
|
2353
2367
|
htmlFor: id,
|
|
@@ -2365,9 +2379,9 @@ const InputField = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref)
|
|
|
2365
2379
|
}, rest, inputPropsWithoutClass)));
|
|
2366
2380
|
});
|
|
2367
2381
|
|
|
2368
|
-
var css_248z$x = ".
|
|
2369
|
-
var styles$v = {"colorPicker":"
|
|
2370
|
-
var stylesheet$x=".
|
|
2382
|
+
var css_248z$x = "._9ygY1{display:flex;line-height:1.15}._9ygY1 ._YN59M{display:flex;align-items:center;background-color:#fafafa;border:0;border-radius:4px 0 0 4px;padding:0;cursor:pointer;outline:none}._9ygY1 ._YN59M:hover:not(._vg8u0){background-color:#f5f5f5}._9ygY1 ._YN59M._vg8u0{cursor:not-allowed;fill:rgba(81,85,89,.4)}._9ygY1 ._YN59M:active:not(._vg8u0){background-color:#eee}._9ygY1 ._H8POd{width:18px;height:36px;border-radius:4px 0 0 4px;border:1px solid #898989;border-right-width:0}._9ygY1 ._H8POd._vg8u0{border-color:#d9d9d9}._9ygY1 ._nKRpb{position:relative;background-image:linear-gradient(45deg,rgba(0,0,0,.1) 25%,transparent 0),linear-gradient(135deg,rgba(0,0,0,.1) 25%,transparent 0),linear-gradient(45deg,transparent 75%,rgba(0,0,0,.1) 0),linear-gradient(135deg,transparent 75%,rgba(0,0,0,.1) 0);background-color:#fff;background-size:18px 18px;background-position:0 0,9px 0,9px -9px,0 9px}._9ygY1 ._4nunF{width:18px;height:36px;border:1px solid #898989;border-width:1px 0}._9ygY1 ._4nunF._vg8u0{border-color:#d9d9d9}._9ygY1 ._HFO-2{height:36px;border:1px solid #898989;border-width:1px 0}._9ygY1 ._HFO-2._vg8u0{border-color:#d9d9d9}._9ygY1 ._4zrmm{border-radius:0 4px 4px 0;width:115px;padding-left:21px}._9ygY1 ._Nr-xg{position:absolute;top:10px;left:13px;font-size:14px;color:#32363a;-webkit-user-select:none;-moz-user-select:none;user-select:none;pointer-events:none}._9ygY1 ._Nr-xg._KF0bm{color:#9d9fa1}._YN59M.focus-visible,._YN59M:focus-visible{background:#fafafa;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88;z-index:10}._0Kp5K{width:264px;padding:8px;background-color:#fff;border:1px solid #eee;border-radius:4px;box-shadow:0 8px 20px rgba(0,0,0,.1);line-height:1.15}._0Kp5K ._1tWB9{position:relative;width:246px;height:150px;border-radius:4px;border:1px solid rgba(0,0,0,.43);background:linear-gradient(0deg,#000,transparent),linear-gradient(90deg,#fff,transparent);background-origin:border-box}._0Kp5K ._D3K4T{position:absolute;width:12px;height:12px;border-radius:50%;border:1px solid #fff;box-shadow:inset 0 0 0 1px rgba(0,0,0,.5);outline:none;cursor:pointer}._0Kp5K ._H4SeI{display:flex;justify-content:space-between;margin:12px 0}._0Kp5K ._H4SeI._4ohRe{margin-bottom:0}._0Kp5K ._HkrU3{display:flex}._0Kp5K ._bKKte{width:19px;height:38px;border-radius:2px 0 0 2px;border:1px solid rgba(0,0,0,.43);border-right-width:0}._0Kp5K ._8Juqu{width:19px;height:38px;border-radius:0 2px 2px 0;border:1px solid rgba(0,0,0,.43);border-left-width:0}._0Kp5K ._1LAGn{background-image:linear-gradient(45deg,rgba(0,0,0,.1) 25%,transparent 0),linear-gradient(135deg,rgba(0,0,0,.1) 25%,transparent 0),linear-gradient(45deg,transparent 75%,rgba(0,0,0,.1) 0),linear-gradient(135deg,transparent 75%,rgba(0,0,0,.1) 0);background-color:#fff;background-size:19px 19px;background-position:0 0,9.5px 0,9.5px -9.5px,0 9.5px;border-radius:0 2px 2px 0}._0Kp5K ._SgOEX{width:202px;height:38px;padding:0 3px;border-radius:1px;border:1px solid rgba(0,0,0,.43);background:linear-gradient(90deg,red,red 2%,#ff0 18%,#0f0 34%,#0ff 50%,#00f 66%,#f0f 82%,red 98%,red)}._0Kp5K ._SgOEX._kDmhf{height:16px;margin-bottom:6px}._0Kp5K ._207Bc{position:relative;background-color:#fff;border:1px solid rgba(0,0,0,.25);border-radius:1px;background-clip:padding-box;width:8px;height:38px;outline:none;cursor:pointer;top:-1px}._0Kp5K ._207Bc._kDmhf{height:16px}._0Kp5K ._k7ebf{position:relative;background-image:linear-gradient(45deg,rgba(0,0,0,.1) 25%,transparent 0),linear-gradient(135deg,rgba(0,0,0,.1) 25%,transparent 0),linear-gradient(45deg,transparent 75%,rgba(0,0,0,.1) 0),linear-gradient(135deg,transparent 75%,rgba(0,0,0,.1) 0);background-color:#fff;background-size:16px 16px;background-position:0 0,8px 0,8px -8px,0 8px;border-radius:1px}._0Kp5K ._lnY-e{width:202px;height:16px;padding:0 3px;border-radius:1px;border:1px solid rgba(0,0,0,.43);background-origin:border-box!important}._0Kp5K ._4pSsE{position:relative;background-color:#fff;border:1px solid rgba(0,0,0,.25);border-radius:1px;background-clip:padding-box;width:8px;height:16px;outline:none;cursor:pointer;top:-1px}._0Kp5K ._CBoeU{display:flex;justify-content:space-between}._0Kp5K ._-MnkZ{display:flex;flex-direction:column;align-items:center}._0Kp5K ._-MnkZ._HM5Li{margin-left:4px}._0Kp5K ._FnarT{position:absolute;top:3px;left:5px;font-size:14px;line-height:20px;color:#32363a;-webkit-user-select:none;-moz-user-select:none;user-select:none;pointer-events:none}._0Kp5K ._autMu{padding:3px 4px 3px 13px!important;width:78px}._0Kp5K ._213NX{text-align:right;padding:3px 4px 3px 0!important;width:34px}._0Kp5K ._-E-Nz{text-align:right;padding:3px 16px 3px 0!important;width:46px}._0Kp5K ._B10EY{position:absolute;top:3px;right:4px;font-size:14px;line-height:20px;color:#32363a;-webkit-user-select:none;-moz-user-select:none;user-select:none;pointer-events:none}._0Kp5K ._WXW3A{line-height:22px}._0Kp5K ._7btIN{display:flex}._0Kp5K ._808NC{display:flex;flex-wrap:wrap;margin:9px -3px -3px}._0Kp5K ._808NC._HgeP-{margin-top:0}._0Kp5K ._I5mBU{width:22px;height:22px;margin:3px;border-radius:4px;border:1px solid rgba(0,0,0,.43);outline:none;cursor:pointer}._Jre69{position:relative}._oWoaI{display:none}._wzVJ1{border:0;clip:rect(0 0 0);height:1px;margin:-1px;overflow:hidden;padding:0;width:1px;position:absolute}._D3K4T.focus-visible,._D3K4T:focus-visible{box-shadow:inset 0 0 0 1px rgba(0,0,0,.5),0 0 0 2px #fff,0 0 0 4px #0a3f88;background-color:#fff}._4pSsE.focus-visible,._4pSsE:focus-visible,._207Bc.focus-visible,._207Bc:focus-visible,._I5mBU.focus-visible,._I5mBU:focus-visible{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
2383
|
+
var styles$v = {"colorPicker":"_9ygY1","colorPickerButton":"_YN59M","disabledButton":"_vg8u0","colorPickerButtonPreview":"_H8POd","alphaBackground":"_nKRpb","colorPickerButtonAlphaPreview":"_4nunF","caretIcon":"_HFO-2","colorPickerInput":"_4zrmm","colorPickerInputDecoration":"_Nr-xg","disabledDecoration":"_KF0bm","colorPickerFlyout":"_0Kp5K","saturationGrid":"_1tWB9","saturationLoop":"_D3K4T","sliderGroup":"_H4SeI","removeBottomMargin":"_4ohRe","sliderPreviewContainer":"_HkrU3","sliderPreview":"_bKKte","sliderPreviewAlpha":"_8Juqu","sliderPreviewAlphaBackground":"_1LAGn","hueSliderRail":"_SgOEX","alphaEnabled":"_kDmhf","hueSliderThumb":"_207Bc","alphaSliderRailBackground":"_k7ebf","alphaSliderRail":"_lnY-e","alphaSliderThumb":"_4pSsE","hexInputGroup":"_CBoeU","hexInputContainer":"_-MnkZ","rgbInputContainer":"_HM5Li","hexInputDecoration":"_FnarT","hexInput":"_autMu","rgbInput":"_213NX","alphaInput":"_-E-Nz","alphaInputDecoration":"_B10EY","inputLabel":"_WXW3A","rgbContainer":"_7btIN","palette":"_808NC","removeUpperMargin":"_HgeP-","swatch":"_I5mBU","relativePositionContainer":"_Jre69","hidden":"_oWoaI","hiddenLiveRegion":"_wzVJ1"};
|
|
2384
|
+
var stylesheet$x="._9ygY1{display:flex;line-height:1.15}._9ygY1 ._YN59M{display:flex;align-items:center;background-color:#fafafa;border:0;border-radius:4px 0 0 4px;padding:0;cursor:pointer;outline:none}._9ygY1 ._YN59M:hover:not(._vg8u0){background-color:#f5f5f5}._9ygY1 ._YN59M._vg8u0{cursor:not-allowed;fill:rgba(81,85,89,.4)}._9ygY1 ._YN59M:active:not(._vg8u0){background-color:#eee}._9ygY1 ._H8POd{width:18px;height:36px;border-radius:4px 0 0 4px;border:1px solid #898989;border-right-width:0}._9ygY1 ._H8POd._vg8u0{border-color:#d9d9d9}._9ygY1 ._nKRpb{position:relative;background-image:linear-gradient(45deg,rgba(0,0,0,.1) 25%,transparent 0),linear-gradient(135deg,rgba(0,0,0,.1) 25%,transparent 0),linear-gradient(45deg,transparent 75%,rgba(0,0,0,.1) 0),linear-gradient(135deg,transparent 75%,rgba(0,0,0,.1) 0);background-color:#fff;background-size:18px 18px;background-position:0 0,9px 0,9px -9px,0 9px}._9ygY1 ._4nunF{width:18px;height:36px;border:1px solid #898989;border-width:1px 0}._9ygY1 ._4nunF._vg8u0{border-color:#d9d9d9}._9ygY1 ._HFO-2{height:36px;border:1px solid #898989;border-width:1px 0}._9ygY1 ._HFO-2._vg8u0{border-color:#d9d9d9}._9ygY1 ._4zrmm{border-radius:0 4px 4px 0;width:115px;padding-left:21px}._9ygY1 ._Nr-xg{position:absolute;top:10px;left:13px;font-size:14px;color:#32363a;-webkit-user-select:none;-moz-user-select:none;user-select:none;pointer-events:none}._9ygY1 ._Nr-xg._KF0bm{color:#9d9fa1}._YN59M.focus-visible,._YN59M:focus-visible{background:#fafafa;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88;z-index:10}._0Kp5K{width:264px;padding:8px;background-color:#fff;border:1px solid #eee;border-radius:4px;box-shadow:0 8px 20px rgba(0,0,0,.1);line-height:1.15}._0Kp5K ._1tWB9{position:relative;width:246px;height:150px;border-radius:4px;border:1px solid rgba(0,0,0,.43);background:linear-gradient(0deg,#000,transparent),linear-gradient(90deg,#fff,transparent);background-origin:border-box}._0Kp5K ._D3K4T{position:absolute;width:12px;height:12px;border-radius:50%;border:1px solid #fff;box-shadow:inset 0 0 0 1px rgba(0,0,0,.5);outline:none;cursor:pointer}._0Kp5K ._H4SeI{display:flex;justify-content:space-between;margin:12px 0}._0Kp5K ._H4SeI._4ohRe{margin-bottom:0}._0Kp5K ._HkrU3{display:flex}._0Kp5K ._bKKte{width:19px;height:38px;border-radius:2px 0 0 2px;border:1px solid rgba(0,0,0,.43);border-right-width:0}._0Kp5K ._8Juqu{width:19px;height:38px;border-radius:0 2px 2px 0;border:1px solid rgba(0,0,0,.43);border-left-width:0}._0Kp5K ._1LAGn{background-image:linear-gradient(45deg,rgba(0,0,0,.1) 25%,transparent 0),linear-gradient(135deg,rgba(0,0,0,.1) 25%,transparent 0),linear-gradient(45deg,transparent 75%,rgba(0,0,0,.1) 0),linear-gradient(135deg,transparent 75%,rgba(0,0,0,.1) 0);background-color:#fff;background-size:19px 19px;background-position:0 0,9.5px 0,9.5px -9.5px,0 9.5px;border-radius:0 2px 2px 0}._0Kp5K ._SgOEX{width:202px;height:38px;padding:0 3px;border-radius:1px;border:1px solid rgba(0,0,0,.43);background:linear-gradient(90deg,red,red 2%,#ff0 18%,#0f0 34%,#0ff 50%,#00f 66%,#f0f 82%,red 98%,red)}._0Kp5K ._SgOEX._kDmhf{height:16px;margin-bottom:6px}._0Kp5K ._207Bc{position:relative;background-color:#fff;border:1px solid rgba(0,0,0,.25);border-radius:1px;background-clip:padding-box;width:8px;height:38px;outline:none;cursor:pointer;top:-1px}._0Kp5K ._207Bc._kDmhf{height:16px}._0Kp5K ._k7ebf{position:relative;background-image:linear-gradient(45deg,rgba(0,0,0,.1) 25%,transparent 0),linear-gradient(135deg,rgba(0,0,0,.1) 25%,transparent 0),linear-gradient(45deg,transparent 75%,rgba(0,0,0,.1) 0),linear-gradient(135deg,transparent 75%,rgba(0,0,0,.1) 0);background-color:#fff;background-size:16px 16px;background-position:0 0,8px 0,8px -8px,0 8px;border-radius:1px}._0Kp5K ._lnY-e{width:202px;height:16px;padding:0 3px;border-radius:1px;border:1px solid rgba(0,0,0,.43);background-origin:border-box!important}._0Kp5K ._4pSsE{position:relative;background-color:#fff;border:1px solid rgba(0,0,0,.25);border-radius:1px;background-clip:padding-box;width:8px;height:16px;outline:none;cursor:pointer;top:-1px}._0Kp5K ._CBoeU{display:flex;justify-content:space-between}._0Kp5K ._-MnkZ{display:flex;flex-direction:column;align-items:center}._0Kp5K ._-MnkZ._HM5Li{margin-left:4px}._0Kp5K ._FnarT{position:absolute;top:3px;left:5px;font-size:14px;line-height:20px;color:#32363a;-webkit-user-select:none;-moz-user-select:none;user-select:none;pointer-events:none}._0Kp5K ._autMu{padding:3px 4px 3px 13px!important;width:78px}._0Kp5K ._213NX{text-align:right;padding:3px 4px 3px 0!important;width:34px}._0Kp5K ._-E-Nz{text-align:right;padding:3px 16px 3px 0!important;width:46px}._0Kp5K ._B10EY{position:absolute;top:3px;right:4px;font-size:14px;line-height:20px;color:#32363a;-webkit-user-select:none;-moz-user-select:none;user-select:none;pointer-events:none}._0Kp5K ._WXW3A{line-height:22px}._0Kp5K ._7btIN{display:flex}._0Kp5K ._808NC{display:flex;flex-wrap:wrap;margin:9px -3px -3px}._0Kp5K ._808NC._HgeP-{margin-top:0}._0Kp5K ._I5mBU{width:22px;height:22px;margin:3px;border-radius:4px;border:1px solid rgba(0,0,0,.43);outline:none;cursor:pointer}._Jre69{position:relative}._oWoaI{display:none}._wzVJ1{border:0;clip:rect(0 0 0);height:1px;margin:-1px;overflow:hidden;padding:0;width:1px;position:absolute}._D3K4T.focus-visible,._D3K4T:focus-visible{box-shadow:inset 0 0 0 1px rgba(0,0,0,.5),0 0 0 2px #fff,0 0 0 4px #0a3f88;background-color:#fff}._4pSsE.focus-visible,._4pSsE:focus-visible,._207Bc.focus-visible,._207Bc:focus-visible,._I5mBU.focus-visible,._I5mBU:focus-visible{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
2371
2385
|
icons_index.styleInject(css_248z$x);
|
|
2372
2386
|
|
|
2373
2387
|
function getMousePosition(e, containerRef) {
|
|
@@ -2401,9 +2415,10 @@ function hexToRgb(hex) {
|
|
|
2401
2415
|
}
|
|
2402
2416
|
|
|
2403
2417
|
function hexToRgbaString(color) {
|
|
2418
|
+
var _color$alpha;
|
|
2404
2419
|
const rgb = hexToRgb(color.hex);
|
|
2405
|
-
const alpha = color.alpha
|
|
2406
|
-
return
|
|
2420
|
+
const alpha = (_color$alpha = color.alpha) !== null && _color$alpha !== void 0 ? _color$alpha : 100;
|
|
2421
|
+
return "rgba(".concat(rgb.r, ", ").concat(rgb.g, ", ").concat(rgb.b, ", ").concat(alpha / 100, ")");
|
|
2407
2422
|
}
|
|
2408
2423
|
|
|
2409
2424
|
function rgbToHex(_ref) {
|
|
@@ -2415,7 +2430,7 @@ function rgbToHex(_ref) {
|
|
|
2415
2430
|
const rStr = r.toString(16).padStart(2, '0');
|
|
2416
2431
|
const gStr = g.toString(16).padStart(2, '0');
|
|
2417
2432
|
const bStr = b.toString(16).padStart(2, '0');
|
|
2418
|
-
return
|
|
2433
|
+
return "#".concat(rStr).concat(gStr).concat(bStr);
|
|
2419
2434
|
}
|
|
2420
2435
|
|
|
2421
2436
|
// formula from https://www.rapidtables.com/convert/color/hsv-to-rgb.html
|
|
@@ -2557,41 +2572,42 @@ function calculateTargetId(focusedId, paletteLength, direction) {
|
|
|
2557
2572
|
}
|
|
2558
2573
|
|
|
2559
2574
|
function validateHex(currentColor, newHex, isAlphaEnabled) {
|
|
2575
|
+
var _currentColor$alpha;
|
|
2560
2576
|
// set current alpha to hex format
|
|
2561
|
-
const alpha = Math.round((currentColor.alpha
|
|
2577
|
+
const alpha = Math.round(((_currentColor$alpha = currentColor.alpha) !== null && _currentColor$alpha !== void 0 ? _currentColor$alpha : 100) / 100 * 255).toString(16).toUpperCase().padStart(2, '0');
|
|
2562
2578
|
let newAlpha = isAlphaEnabled ? alpha : '';
|
|
2563
2579
|
let validatedHex;
|
|
2564
2580
|
const hexLength = isAlphaEnabled ? 8 : 6;
|
|
2565
2581
|
const hexRegex = /^[a-fA-F0-9]+$/;
|
|
2566
2582
|
|
|
2567
2583
|
// if newHex contains invalid characters or is empty string, revert to previous color
|
|
2568
|
-
if (!hexRegex.test(newHex.slice(0, hexLength))) return
|
|
2584
|
+
if (!hexRegex.test(newHex.slice(0, hexLength))) return "".concat(currentColor.hex.substring(1)).concat(newAlpha);
|
|
2569
2585
|
|
|
2570
2586
|
// match validation pattern based on string length
|
|
2571
2587
|
switch (newHex.length) {
|
|
2572
2588
|
case 1:
|
|
2573
|
-
validatedHex =
|
|
2589
|
+
validatedHex = "".concat(newHex.repeat(6)).concat(newAlpha);
|
|
2574
2590
|
break;
|
|
2575
2591
|
case 2:
|
|
2576
|
-
validatedHex =
|
|
2592
|
+
validatedHex = "".concat(newHex.repeat(3)).concat(newAlpha);
|
|
2577
2593
|
break;
|
|
2578
2594
|
case 3:
|
|
2579
|
-
validatedHex =
|
|
2595
|
+
validatedHex = "".concat(newHex[0].repeat(2)).concat(newHex[1].repeat(2)).concat(newHex[2].repeat(2)).concat(newAlpha);
|
|
2580
2596
|
break;
|
|
2581
2597
|
case 4:
|
|
2582
2598
|
case 5:
|
|
2583
2599
|
newAlpha = isAlphaEnabled ? newHex[3].repeat(2) : '';
|
|
2584
|
-
validatedHex =
|
|
2600
|
+
validatedHex = "".concat(newHex[0].repeat(2)).concat(newHex[1].repeat(2)).concat(newHex[2].repeat(2)).concat(newAlpha);
|
|
2585
2601
|
break;
|
|
2586
2602
|
case 6:
|
|
2587
|
-
validatedHex =
|
|
2603
|
+
validatedHex = "".concat(newHex).concat(newAlpha);
|
|
2588
2604
|
break;
|
|
2589
2605
|
case 7:
|
|
2590
|
-
validatedHex =
|
|
2606
|
+
validatedHex = "".concat(newHex.substring(0, 6)).concat(newAlpha);
|
|
2591
2607
|
break;
|
|
2592
2608
|
default:
|
|
2593
2609
|
newAlpha = isAlphaEnabled ? newHex.substring(6, 8) : '';
|
|
2594
|
-
validatedHex =
|
|
2610
|
+
validatedHex = "".concat(newHex.substring(0, 6)).concat(newAlpha);
|
|
2595
2611
|
break;
|
|
2596
2612
|
}
|
|
2597
2613
|
return validatedHex.toUpperCase();
|
|
@@ -2663,7 +2679,7 @@ function Saturation$1(_ref) {
|
|
|
2663
2679
|
} = _ref;
|
|
2664
2680
|
const gridRef = React.useRef(null);
|
|
2665
2681
|
const loopRef = React.useRef(null);
|
|
2666
|
-
const saturationId =
|
|
2682
|
+
const saturationId = "".concat(containerId, "-saturation");
|
|
2667
2683
|
const {
|
|
2668
2684
|
translate
|
|
2669
2685
|
} = useTranslation();
|
|
@@ -2728,22 +2744,23 @@ function Saturation$1(_ref) {
|
|
|
2728
2744
|
return /*#__PURE__*/React__default["default"].createElement("div", {
|
|
2729
2745
|
className: styles$v.saturationGrid,
|
|
2730
2746
|
style: {
|
|
2731
|
-
backgroundColor:
|
|
2747
|
+
backgroundColor: "".concat(hsvToHex({
|
|
2732
2748
|
h: hsv.h,
|
|
2733
2749
|
s: 1,
|
|
2734
2750
|
v: 1
|
|
2735
|
-
})
|
|
2751
|
+
}))
|
|
2736
2752
|
},
|
|
2737
2753
|
onMouseDown: e => {
|
|
2754
|
+
var _loopRef$current;
|
|
2738
2755
|
// prevent text highlighting while dragging
|
|
2739
2756
|
e.preventDefault();
|
|
2740
|
-
loopRef.current
|
|
2757
|
+
(_loopRef$current = loopRef.current) === null || _loopRef$current === void 0 ? void 0 : _loopRef$current.focus();
|
|
2741
2758
|
handleMouseDown(e);
|
|
2742
2759
|
},
|
|
2743
2760
|
"data-testid": getSubDataTestId(dataTestId, 'saturation-grid'),
|
|
2744
2761
|
ref: gridRef
|
|
2745
2762
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
2746
|
-
id:
|
|
2763
|
+
id: "".concat(saturationId, "-saturation-desc"),
|
|
2747
2764
|
className: styles$v.hidden
|
|
2748
2765
|
}, saturationAriaDesc), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
2749
2766
|
"aria-live": loopRef.current === document.activeElement ? 'assertive' : 'off',
|
|
@@ -2754,13 +2771,13 @@ function Saturation$1(_ref) {
|
|
|
2754
2771
|
}, valueAriaLive), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
2755
2772
|
className: styles$v.saturationLoop,
|
|
2756
2773
|
style: {
|
|
2757
|
-
left:
|
|
2758
|
-
bottom:
|
|
2774
|
+
left: "calc(".concat(hsv.s * 100, "% - ").concat(hsv.s * 12, "px)"),
|
|
2775
|
+
bottom: "calc(".concat(hsv.v * 100, "% - ").concat(hsv.v * 12, "px)")
|
|
2759
2776
|
},
|
|
2760
2777
|
onKeyDown: handleKeyDown,
|
|
2761
2778
|
tabIndex: 0,
|
|
2762
2779
|
"aria-label": saturationAriaLabel,
|
|
2763
|
-
"aria-describedby":
|
|
2780
|
+
"aria-describedby": "".concat(saturationId, "-saturation-desc"),
|
|
2764
2781
|
ref: loopRef,
|
|
2765
2782
|
"data-testid": getSubDataTestId(dataTestId, 'saturation-thumb')
|
|
2766
2783
|
}));
|
|
@@ -2830,9 +2847,10 @@ function Hue$1(_ref) {
|
|
|
2830
2847
|
[styles$v.alphaEnabled]: isAlphaEnabled
|
|
2831
2848
|
}),
|
|
2832
2849
|
onMouseDown: e => {
|
|
2850
|
+
var _thumbRef$current;
|
|
2833
2851
|
// prevent text highlighting while dragging
|
|
2834
2852
|
e.preventDefault();
|
|
2835
|
-
thumbRef.current
|
|
2853
|
+
(_thumbRef$current = thumbRef.current) === null || _thumbRef$current === void 0 ? void 0 : _thumbRef$current.focus();
|
|
2836
2854
|
handleMouseDown(e);
|
|
2837
2855
|
},
|
|
2838
2856
|
"data-testid": getSubDataTestId(dataTestId, 'hue-rail'),
|
|
@@ -2843,7 +2861,7 @@ function Hue$1(_ref) {
|
|
|
2843
2861
|
[styles$v.alphaEnabled]: isAlphaEnabled
|
|
2844
2862
|
}),
|
|
2845
2863
|
style: {
|
|
2846
|
-
left:
|
|
2864
|
+
left: "calc(".concat(hue / 359 * 100, "% - 4px)")
|
|
2847
2865
|
},
|
|
2848
2866
|
onKeyDown: handleKeyDown,
|
|
2849
2867
|
"aria-label": hueAriaLabel,
|
|
@@ -2859,6 +2877,7 @@ function Hue$1(_ref) {
|
|
|
2859
2877
|
|
|
2860
2878
|
/* eslint-disable jsx-a11y/no-static-element-interactions */
|
|
2861
2879
|
function Alpha$1(_ref) {
|
|
2880
|
+
var _color$alpha5, _color$alpha6, _color$alpha7;
|
|
2862
2881
|
let {
|
|
2863
2882
|
color,
|
|
2864
2883
|
onAlphaChange,
|
|
@@ -2883,16 +2902,17 @@ function Alpha$1(_ref) {
|
|
|
2883
2902
|
});
|
|
2884
2903
|
const handleMouseDown = useMouseDrag$1(handleChange);
|
|
2885
2904
|
function handleKeyDown(e) {
|
|
2905
|
+
var _color$alpha, _color$alpha2, _color$alpha3, _color$alpha4;
|
|
2886
2906
|
switch (e.key) {
|
|
2887
2907
|
case 'ArrowDown':
|
|
2888
2908
|
case 'ArrowLeft':
|
|
2889
2909
|
e.preventDefault(); // prevent page scroll
|
|
2890
|
-
onAlphaChange(Math.min((color.alpha
|
|
2910
|
+
onAlphaChange(Math.min(((_color$alpha = color.alpha) !== null && _color$alpha !== void 0 ? _color$alpha : MAX_ALPHA) + 1, MAX_ALPHA));
|
|
2891
2911
|
break;
|
|
2892
2912
|
case 'ArrowUp':
|
|
2893
2913
|
case 'ArrowRight':
|
|
2894
2914
|
e.preventDefault(); // prevent page scroll
|
|
2895
|
-
onAlphaChange(Math.max((color.alpha
|
|
2915
|
+
onAlphaChange(Math.max(((_color$alpha2 = color.alpha) !== null && _color$alpha2 !== void 0 ? _color$alpha2 : MAX_ALPHA) - 1, MIN_ALPHA));
|
|
2896
2916
|
break;
|
|
2897
2917
|
case 'End':
|
|
2898
2918
|
e.preventDefault(); // prevent page scroll
|
|
@@ -2904,11 +2924,11 @@ function Alpha$1(_ref) {
|
|
|
2904
2924
|
break;
|
|
2905
2925
|
case 'PageDown':
|
|
2906
2926
|
e.preventDefault(); // prevent page scroll
|
|
2907
|
-
onAlphaChange(Math.min((color.alpha
|
|
2927
|
+
onAlphaChange(Math.min(((_color$alpha3 = color.alpha) !== null && _color$alpha3 !== void 0 ? _color$alpha3 : MAX_ALPHA) + 10, MAX_ALPHA));
|
|
2908
2928
|
break;
|
|
2909
2929
|
case 'PageUp':
|
|
2910
2930
|
e.preventDefault(); // prevent page scroll
|
|
2911
|
-
onAlphaChange(Math.max((color.alpha
|
|
2931
|
+
onAlphaChange(Math.max(((_color$alpha4 = color.alpha) !== null && _color$alpha4 !== void 0 ? _color$alpha4 : MAX_ALPHA) - 10, MIN_ALPHA));
|
|
2912
2932
|
break;
|
|
2913
2933
|
default:
|
|
2914
2934
|
break;
|
|
@@ -2919,12 +2939,13 @@ function Alpha$1(_ref) {
|
|
|
2919
2939
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
2920
2940
|
className: styles$v.alphaSliderRail,
|
|
2921
2941
|
style: {
|
|
2922
|
-
background:
|
|
2942
|
+
background: "linear-gradient(90deg, ".concat(color.hex, ", transparent)")
|
|
2923
2943
|
},
|
|
2924
2944
|
onMouseDown: e => {
|
|
2945
|
+
var _thumbRef$current;
|
|
2925
2946
|
// prevent text highlighting while dragging
|
|
2926
2947
|
e.preventDefault();
|
|
2927
|
-
thumbRef.current
|
|
2948
|
+
(_thumbRef$current = thumbRef.current) === null || _thumbRef$current === void 0 ? void 0 : _thumbRef$current.focus();
|
|
2928
2949
|
handleMouseDown(e);
|
|
2929
2950
|
},
|
|
2930
2951
|
"data-testid": getSubDataTestId(dataTestId, 'alpha-rail'),
|
|
@@ -2933,14 +2954,14 @@ function Alpha$1(_ref) {
|
|
|
2933
2954
|
role: "slider",
|
|
2934
2955
|
className: styles$v.alphaSliderThumb,
|
|
2935
2956
|
style: {
|
|
2936
|
-
left:
|
|
2957
|
+
left: "calc(".concat(MAX_ALPHA - ((_color$alpha5 = color.alpha) !== null && _color$alpha5 !== void 0 ? _color$alpha5 : MAX_ALPHA), "% - 4px)")
|
|
2937
2958
|
},
|
|
2938
2959
|
onKeyDown: handleKeyDown,
|
|
2939
2960
|
"aria-label": alphaAriaLabel,
|
|
2940
2961
|
"aria-valuemin": MIN_ALPHA,
|
|
2941
2962
|
"aria-valuemax": MAX_ALPHA,
|
|
2942
|
-
"aria-valuenow": color.alpha
|
|
2943
|
-
"aria-valuetext":
|
|
2963
|
+
"aria-valuenow": (_color$alpha6 = color.alpha) !== null && _color$alpha6 !== void 0 ? _color$alpha6 : MAX_ALPHA,
|
|
2964
|
+
"aria-valuetext": "".concat((_color$alpha7 = color.alpha) !== null && _color$alpha7 !== void 0 ? _color$alpha7 : MAX_ALPHA, "%"),
|
|
2944
2965
|
tabIndex: 0,
|
|
2945
2966
|
ref: thumbRef,
|
|
2946
2967
|
"data-testid": getSubDataTestId(dataTestId, 'alpha-thumb')
|
|
@@ -2948,6 +2969,7 @@ function Alpha$1(_ref) {
|
|
|
2948
2969
|
}
|
|
2949
2970
|
|
|
2950
2971
|
const Swatch$1 = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
2972
|
+
var _color$name;
|
|
2951
2973
|
let {
|
|
2952
2974
|
color,
|
|
2953
2975
|
onColorSwatchClick,
|
|
@@ -2967,14 +2989,14 @@ const Swatch$1 = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
2967
2989
|
type: "button",
|
|
2968
2990
|
className: styles$v.swatch,
|
|
2969
2991
|
style: {
|
|
2970
|
-
backgroundColor:
|
|
2992
|
+
backgroundColor: "".concat(color.hex)
|
|
2971
2993
|
},
|
|
2972
2994
|
onClick: handleClick,
|
|
2973
2995
|
tabIndex: cellIndex === focusedSwatchIndex ? 0 : -1,
|
|
2974
|
-
"aria-label":
|
|
2996
|
+
"aria-label": "".concat((_color$name = color.name) !== null && _color$name !== void 0 ? _color$name : '', " ").concat(color.hex),
|
|
2975
2997
|
"aria-describedby": ariaDescribedBy,
|
|
2976
2998
|
ref: ref,
|
|
2977
|
-
"data-testid": getSubDataTestId(dataTestId,
|
|
2999
|
+
"data-testid": getSubDataTestId(dataTestId, "".concat(color.hex.substring(1), "-swatch"))
|
|
2978
3000
|
}));
|
|
2979
3001
|
});
|
|
2980
3002
|
function Palette(_ref2) {
|
|
@@ -2991,7 +3013,7 @@ function Palette(_ref2) {
|
|
|
2991
3013
|
} = useTranslation();
|
|
2992
3014
|
const paletteAriaLabel = translate('palette');
|
|
2993
3015
|
const swatchAriaDesc = translate('selectColor');
|
|
2994
|
-
const swatchDescriptionId =
|
|
3016
|
+
const swatchDescriptionId = "".concat(containerId, "-swatch-desc");
|
|
2995
3017
|
const swatchRefs = React.useRef({});
|
|
2996
3018
|
|
|
2997
3019
|
// split palette into rows for grid aria role semantics
|
|
@@ -3007,8 +3029,9 @@ function Palette(_ref2) {
|
|
|
3007
3029
|
function updateFocusedSwatchIndex(e, direction) {
|
|
3008
3030
|
e.preventDefault(); // prevents scroll
|
|
3009
3031
|
setFocusedSwatchIndex(prevFocusedSwatchIndex => {
|
|
3032
|
+
var _swatchRefs$current;
|
|
3010
3033
|
const targetId = calculateTargetId(prevFocusedSwatchIndex, palette.length, direction);
|
|
3011
|
-
swatchRefs.current
|
|
3034
|
+
(_swatchRefs$current = swatchRefs.current) === null || _swatchRefs$current === void 0 || (_swatchRefs$current = _swatchRefs$current[targetId]) === null || _swatchRefs$current === void 0 ? void 0 : _swatchRefs$current.focus();
|
|
3012
3035
|
return targetId;
|
|
3013
3036
|
});
|
|
3014
3037
|
}
|
|
@@ -3080,7 +3103,7 @@ function RGBInput(_ref) {
|
|
|
3080
3103
|
containerId,
|
|
3081
3104
|
dataTestId
|
|
3082
3105
|
} = _ref;
|
|
3083
|
-
const inputId =
|
|
3106
|
+
const inputId = "".concat(containerId, "-").concat(label, "-input");
|
|
3084
3107
|
const [internalValue, setInternalValue] = React.useState(externalValue);
|
|
3085
3108
|
React.useEffect(() => {
|
|
3086
3109
|
setInternalValue(externalValue);
|
|
@@ -3098,13 +3121,14 @@ function RGBInput(_ref) {
|
|
|
3098
3121
|
onChange: e => setInternalValue(parseInt(e.target.value, 10) || 0),
|
|
3099
3122
|
onBlur: onBlur,
|
|
3100
3123
|
"aria-label": ariaLabel,
|
|
3101
|
-
"data-testid": getSubDataTestId(dataTestId,
|
|
3124
|
+
"data-testid": getSubDataTestId(dataTestId, "".concat(label, "-channel"))
|
|
3102
3125
|
}), /*#__PURE__*/React__default["default"].createElement(Label, {
|
|
3103
3126
|
htmlFor: inputId,
|
|
3104
3127
|
className: styles$v.inputLabel
|
|
3105
3128
|
}, label));
|
|
3106
3129
|
}
|
|
3107
3130
|
const ColorPickerFlyoutInputs = function HexInputGroup(_ref2) {
|
|
3131
|
+
var _color$alpha;
|
|
3108
3132
|
let {
|
|
3109
3133
|
color,
|
|
3110
3134
|
onHexBlur,
|
|
@@ -3113,8 +3137,8 @@ const ColorPickerFlyoutInputs = function HexInputGroup(_ref2) {
|
|
|
3113
3137
|
containerId,
|
|
3114
3138
|
dataTestId
|
|
3115
3139
|
} = _ref2;
|
|
3116
|
-
const hexInputId =
|
|
3117
|
-
const alphaInputId =
|
|
3140
|
+
const hexInputId = "".concat(containerId, "-hex-input");
|
|
3141
|
+
const alphaInputId = "".concat(containerId, "-alpha-input");
|
|
3118
3142
|
const {
|
|
3119
3143
|
translate
|
|
3120
3144
|
} = useTranslation();
|
|
@@ -3138,9 +3162,10 @@ const ColorPickerFlyoutInputs = function HexInputGroup(_ref2) {
|
|
|
3138
3162
|
onHexBlur(validatedHex);
|
|
3139
3163
|
setInternalHex(validatedHex);
|
|
3140
3164
|
}
|
|
3141
|
-
const [internalAlpha, setInternalAlpha] = React.useState(color.alpha
|
|
3165
|
+
const [internalAlpha, setInternalAlpha] = React.useState((_color$alpha = color.alpha) !== null && _color$alpha !== void 0 ? _color$alpha : 100);
|
|
3142
3166
|
React.useEffect(() => {
|
|
3143
|
-
|
|
3167
|
+
var _color$alpha2;
|
|
3168
|
+
setInternalAlpha((_color$alpha2 = color.alpha) !== null && _color$alpha2 !== void 0 ? _color$alpha2 : 100);
|
|
3144
3169
|
}, [color.alpha, isAlphaEnabled]);
|
|
3145
3170
|
function handleAlphaBlur(e) {
|
|
3146
3171
|
const newAlpha = Math.min(Math.max(parseInt(e.target.value, 10) || 0, 0), 100);
|
|
@@ -3340,6 +3365,7 @@ const ColorPickerFlyout = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
3340
3365
|
});
|
|
3341
3366
|
|
|
3342
3367
|
function ColorPicker$1(_ref) {
|
|
3368
|
+
var _color$name;
|
|
3343
3369
|
let {
|
|
3344
3370
|
color: externalColor,
|
|
3345
3371
|
onChange,
|
|
@@ -3358,16 +3384,17 @@ function ColorPicker$1(_ref) {
|
|
|
3358
3384
|
'data-testid': dataTestId
|
|
3359
3385
|
} = _ref;
|
|
3360
3386
|
const containerId = useId(id);
|
|
3361
|
-
const flyoutId =
|
|
3387
|
+
const flyoutId = "".concat(containerId, "-flyout");
|
|
3362
3388
|
const [color, setColor] = useControllableState(externalColor, onChange, externalColor);
|
|
3363
3389
|
const [isOpen, setIsOpen] = React.useState(false);
|
|
3364
3390
|
const [hsv, setHsv] = React.useState(hexToHsv(color.hex));
|
|
3365
3391
|
const [inputHex, setInputHex] = React.useState(color.hex);
|
|
3366
3392
|
const [triggerHexUpdate, setTriggerHexUpdate] = React.useState(0);
|
|
3367
3393
|
React.useEffect(() => {
|
|
3368
|
-
|
|
3394
|
+
var _color$alpha;
|
|
3395
|
+
const alpha = isAlphaEnabled ? Math.round(((_color$alpha = color.alpha) !== null && _color$alpha !== void 0 ? _color$alpha : 100) / 100 * 255).toString(16).padStart(2, '0') : '';
|
|
3369
3396
|
const hex = color.hex.substring(1);
|
|
3370
|
-
setInputHex(
|
|
3397
|
+
setInputHex("".concat(hex).concat(alpha));
|
|
3371
3398
|
}, [color, isAlphaEnabled]);
|
|
3372
3399
|
const anchorRef = React.useRef(null);
|
|
3373
3400
|
const popperRef = React.useRef(null);
|
|
@@ -3376,7 +3403,7 @@ function ColorPicker$1(_ref) {
|
|
|
3376
3403
|
translate
|
|
3377
3404
|
} = useTranslation();
|
|
3378
3405
|
const anchorAriaDescription = translate('colorPickerAnchorDesc', {
|
|
3379
|
-
colorName: color.name
|
|
3406
|
+
colorName: (_color$name = color.name) !== null && _color$name !== void 0 ? _color$name : '',
|
|
3380
3407
|
colorHex: color.hex
|
|
3381
3408
|
});
|
|
3382
3409
|
const inputAriaLabel = translate('hex');
|
|
@@ -3434,7 +3461,7 @@ function ColorPicker$1(_ref) {
|
|
|
3434
3461
|
name,
|
|
3435
3462
|
...rest
|
|
3436
3463
|
} = _ref3;
|
|
3437
|
-
const hex =
|
|
3464
|
+
const hex = "#".concat(validatedHex.substring(0, 6));
|
|
3438
3465
|
if (isAlphaEnabled) {
|
|
3439
3466
|
const alpha = Math.round(parseInt(validatedHex.substring(6, 8), 16) / 255 * 100);
|
|
3440
3467
|
return {
|
|
@@ -3457,7 +3484,7 @@ function ColorPicker$1(_ref) {
|
|
|
3457
3484
|
} = _ref4;
|
|
3458
3485
|
const newColor = {
|
|
3459
3486
|
...rest,
|
|
3460
|
-
hex:
|
|
3487
|
+
hex: "#".concat(hex)
|
|
3461
3488
|
};
|
|
3462
3489
|
return newColor;
|
|
3463
3490
|
});
|
|
@@ -3560,11 +3587,11 @@ function ColorPicker$1(_ref) {
|
|
|
3560
3587
|
onClick: handleAnchorClick,
|
|
3561
3588
|
"aria-label": ariaLabel,
|
|
3562
3589
|
"aria-labelledby": ariaLabelledBy,
|
|
3563
|
-
"aria-describedby":
|
|
3590
|
+
"aria-describedby": "".concat(anchorAriaDescription, " ").concat(ariaDescribedBy),
|
|
3564
3591
|
"aria-expanded": isOpen,
|
|
3565
3592
|
"aria-controls": isOpen ? flyoutId : undefined,
|
|
3566
3593
|
"aria-haspopup": "dialog",
|
|
3567
|
-
ref: mergeRefs(anchorRef, externalButtonRef
|
|
3594
|
+
ref: mergeRefs(anchorRef, externalButtonRef !== null && externalButtonRef !== void 0 ? externalButtonRef : null),
|
|
3568
3595
|
"data-testid": getSubDataTestId(dataTestId, 'anchor-button')
|
|
3569
3596
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
3570
3597
|
className: classNames__default["default"](styles$v.colorPickerButtonPreview, {
|
|
@@ -3613,9 +3640,9 @@ function ColorPicker$1(_ref) {
|
|
|
3613
3640
|
})));
|
|
3614
3641
|
}
|
|
3615
3642
|
|
|
3616
|
-
var css_248z$w = ".
|
|
3617
|
-
var styles$u = {"combobox":"
|
|
3618
|
-
var stylesheet$w=".
|
|
3643
|
+
var css_248z$w = "._bZwvn{position:relative;display:inline-block}._k929v{padding-right:36px}._k929v._gsTix{box-shadow:none!important;border:1px solid #898989!important}._mUgkG{margin-top:4px}._gK0pz{position:absolute;right:4px;bottom:4px;height:28px;width:28px;border-radius:4px;fill:#515559;cursor:pointer}._gK0pz:hover{background-color:rgba(50,54,58,.08)}._gK0pz:active{background-color:rgba(50,54,58,.11)}._gK0pz._RbR6m{transform:rotate(-180deg)}._gK0pz._2vyAm{opacity:.4}._asLvc{min-height:40px;padding:10px 12px;display:flex;flex-direction:row;align-items:center;background-color:#fff;font-size:14px;color:#32363a;word-break:break-word}._2vyAm{cursor:not-allowed}._2vyAm:hover{background-color:transparent}";
|
|
3644
|
+
var styles$u = {"combobox":"_bZwvn","comboboxInput":"_k929v","ignoreFocusStyle":"_gsTix","labelledInput":"_mUgkG","comboboxIcon":"_gK0pz","open":"_RbR6m","disabled":"_2vyAm","comboboxEmpty":"_asLvc"};
|
|
3645
|
+
var stylesheet$w="._bZwvn{position:relative;display:inline-block}._k929v{padding-right:36px}._k929v._gsTix{box-shadow:none!important;border:1px solid #898989!important}._mUgkG{margin-top:4px}._gK0pz{position:absolute;right:4px;bottom:4px;height:28px;width:28px;border-radius:4px;fill:#515559;cursor:pointer}._gK0pz:hover{background-color:rgba(50,54,58,.08)}._gK0pz:active{background-color:rgba(50,54,58,.11)}._gK0pz._RbR6m{transform:rotate(-180deg)}._gK0pz._2vyAm{opacity:.4}._asLvc{min-height:40px;padding:10px 12px;display:flex;flex-direction:row;align-items:center;background-color:#fff;font-size:14px;color:#32363a;word-break:break-word}._2vyAm{cursor:not-allowed}._2vyAm:hover{background-color:transparent}";
|
|
3619
3646
|
icons_index.styleInject(css_248z$w);
|
|
3620
3647
|
|
|
3621
3648
|
const {
|
|
@@ -3682,21 +3709,21 @@ const ComboboxInput = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
3682
3709
|
onChange: handleInputChange,
|
|
3683
3710
|
onFocus: wrapEvent(onFocus, handleFocus),
|
|
3684
3711
|
onKeyDown: wrapEvent(onKeyDown, handleKeyDown),
|
|
3685
|
-
onMouseDown: e => onMouseDown
|
|
3712
|
+
onMouseDown: e => onMouseDown === null || onMouseDown === void 0 ? void 0 : onMouseDown(e),
|
|
3686
3713
|
onClick: e => {
|
|
3687
3714
|
if (!isOptionSelectedOnKeyboardHighlight && numberOfOptions > 0) {
|
|
3688
3715
|
setHighlightedIndex(0);
|
|
3689
3716
|
}
|
|
3690
3717
|
setIsOpen(true);
|
|
3691
|
-
onClick
|
|
3718
|
+
onClick === null || onClick === void 0 ? void 0 : onClick(e);
|
|
3692
3719
|
},
|
|
3693
3720
|
role: "combobox",
|
|
3694
3721
|
"aria-autocomplete": isFilteringDisabled ? 'none' : 'list',
|
|
3695
3722
|
"aria-expanded": isAriaExpanded,
|
|
3696
3723
|
"aria-controls": isAriaExpanded ? listContainerId : undefined,
|
|
3697
3724
|
"aria-activedescendant": activeDescendantId,
|
|
3698
|
-
"aria-label": ariaLabelFromProps
|
|
3699
|
-
"aria-labelledby": ariaLabelledbyFromProps
|
|
3725
|
+
"aria-label": ariaLabelFromProps !== null && ariaLabelFromProps !== void 0 ? ariaLabelFromProps : ariaLabel,
|
|
3726
|
+
"aria-labelledby": ariaLabelledbyFromProps !== null && ariaLabelledbyFromProps !== void 0 ? ariaLabelledbyFromProps : ariaLabelledby
|
|
3700
3727
|
}));
|
|
3701
3728
|
});
|
|
3702
3729
|
|
|
@@ -3741,8 +3768,8 @@ const ComboboxList = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
3741
3768
|
...style
|
|
3742
3769
|
} : style,
|
|
3743
3770
|
id: listContainerId,
|
|
3744
|
-
"aria-label": ariaLabelFromProps
|
|
3745
|
-
"aria-labelledby": ariaLabelledbyFromProps
|
|
3771
|
+
"aria-label": ariaLabelFromProps !== null && ariaLabelFromProps !== void 0 ? ariaLabelFromProps : ariaLabel,
|
|
3772
|
+
"aria-labelledby": ariaLabelledbyFromProps !== null && ariaLabelledbyFromProps !== void 0 ? ariaLabelledbyFromProps : ariaLabelledby
|
|
3746
3773
|
}), children)
|
|
3747
3774
|
});
|
|
3748
3775
|
});
|
|
@@ -3774,7 +3801,7 @@ const ComboboxHeader = /*#__PURE__*/React__default["default"].forwardRef((_ref,
|
|
|
3774
3801
|
} = _ref;
|
|
3775
3802
|
return /*#__PURE__*/React__default["default"].createElement(FlyoutHeader, _extends__default["default"]({}, rest, {
|
|
3776
3803
|
title: title,
|
|
3777
|
-
onMouseDown: wrapEvent(onMouseDown, e => e
|
|
3804
|
+
onMouseDown: wrapEvent(onMouseDown, e => e === null || e === void 0 ? void 0 : e.preventDefault()),
|
|
3778
3805
|
ref: ref
|
|
3779
3806
|
}), children);
|
|
3780
3807
|
});
|
|
@@ -3804,19 +3831,25 @@ const ComboboxIcon = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
3804
3831
|
if (inputRef.current === document.activeElement) {
|
|
3805
3832
|
setIsOpen(!isOpen);
|
|
3806
3833
|
} else {
|
|
3807
|
-
|
|
3834
|
+
var _inputRef$current;
|
|
3835
|
+
(_inputRef$current = inputRef.current) === null || _inputRef$current === void 0 ? void 0 : _inputRef$current.focus();
|
|
3808
3836
|
}
|
|
3809
3837
|
}) : undefined,
|
|
3810
|
-
onMouseDown: wrapEvent(onMouseDown, e => e
|
|
3838
|
+
onMouseDown: wrapEvent(onMouseDown, e => e === null || e === void 0 ? void 0 : e.preventDefault()),
|
|
3811
3839
|
ref: mergeRefs(ref, iconRef),
|
|
3812
3840
|
"aria-hidden": "true"
|
|
3813
3841
|
}));
|
|
3814
3842
|
});
|
|
3815
3843
|
|
|
3816
|
-
const getOptionLabel = option =>
|
|
3817
|
-
|
|
3844
|
+
const getOptionLabel = option => {
|
|
3845
|
+
var _option$props;
|
|
3846
|
+
return option === null || option === void 0 || (_option$props = option.props) === null || _option$props === void 0 ? void 0 : _option$props.label;
|
|
3847
|
+
};
|
|
3848
|
+
const getOptionValue = option => {
|
|
3849
|
+
var _option$props2;
|
|
3850
|
+
return option === null || option === void 0 || (_option$props2 = option.props) === null || _option$props2 === void 0 ? void 0 : _option$props2.value;
|
|
3851
|
+
};
|
|
3818
3852
|
const doesOptionMatchFilter = (option, header, inputValue) => {
|
|
3819
|
-
var _context, _context2;
|
|
3820
3853
|
const label = getOptionLabel(option);
|
|
3821
3854
|
|
|
3822
3855
|
// Filtering is turned off if the input value is empty or not a string, so the given option will be included in the filtered list, thus returns true
|
|
@@ -3825,7 +3858,7 @@ const doesOptionMatchFilter = (option, header, inputValue) => {
|
|
|
3825
3858
|
}
|
|
3826
3859
|
|
|
3827
3860
|
// Returns true if the given option's label or the given header includes the input value (the label and header must be strings in order to do the comparison)
|
|
3828
|
-
return typeof label === 'string' &&
|
|
3861
|
+
return typeof label === 'string' && label.toLowerCase().includes(inputValue.toLowerCase()) || typeof header === 'string' && header.toLowerCase().includes(inputValue.toLowerCase());
|
|
3829
3862
|
};
|
|
3830
3863
|
const Combobox = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
3831
3864
|
let {
|
|
@@ -3863,20 +3896,23 @@ const Combobox = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
3863
3896
|
// Gets the <ComboboxInput> and <ComboboxList> components from the children
|
|
3864
3897
|
React__default["default"].Children.forEach(children, child => {
|
|
3865
3898
|
if ( /*#__PURE__*/React__default["default"].isValidElement(child)) {
|
|
3866
|
-
if (child
|
|
3899
|
+
if ((child === null || child === void 0 ? void 0 : child.type) === ComboboxInput) {
|
|
3867
3900
|
comboboxInput = child;
|
|
3868
|
-
} else if (child
|
|
3901
|
+
} else if ((child === null || child === void 0 ? void 0 : child.type) === ComboboxList) {
|
|
3869
3902
|
comboboxList = child;
|
|
3870
3903
|
}
|
|
3871
3904
|
}
|
|
3872
3905
|
});
|
|
3873
3906
|
const listContainerId = useId(comboboxList.props.id);
|
|
3874
|
-
const noMatchesFoundContainerId =
|
|
3907
|
+
const noMatchesFoundContainerId = "".concat(listContainerId, "-no-matches-found");
|
|
3875
3908
|
|
|
3876
3909
|
// Extracts all ComboboxOptions
|
|
3877
|
-
const [, [allOptions]] = React.useMemo(() =>
|
|
3878
|
-
|
|
3879
|
-
|
|
3910
|
+
const [, [allOptions]] = React.useMemo(() => {
|
|
3911
|
+
var _comboboxList;
|
|
3912
|
+
return filterChildren((_comboboxList = comboboxList) === null || _comboboxList === void 0 || (_comboboxList = _comboboxList.props) === null || _comboboxList === void 0 ? void 0 : _comboboxList.children, [{
|
|
3913
|
+
matcher: child => (child === null || child === void 0 ? void 0 : child.type) === ComboboxOption
|
|
3914
|
+
}]);
|
|
3915
|
+
}, [comboboxList]);
|
|
3880
3916
|
const {
|
|
3881
3917
|
defaultValue: defaultInputValue,
|
|
3882
3918
|
onChange: onInputChange,
|
|
@@ -3899,7 +3935,7 @@ const Combobox = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
3899
3935
|
const [selectedOptionLabel, setSelectedOptionLabel] = React.useState(() => getLabelForValue(selectedOptionValue) || externalInputValue || defaultInputValue || '');
|
|
3900
3936
|
const [inputValue, setInputValue] = useControllableState(selectedOptionLabel,
|
|
3901
3937
|
// `e &&` prevents `ComboboxInput` from calling consumer-passed `onChange` for consumer-controlled `Combobox` value updates.
|
|
3902
|
-
(_, e) => e && onInputChange
|
|
3938
|
+
(_, e) => e && (onInputChange === null || onInputChange === void 0 ? void 0 : onInputChange(e)), externalInputValue);
|
|
3903
3939
|
|
|
3904
3940
|
// listen for updates from controlled value
|
|
3905
3941
|
React.useEffect(() => {
|
|
@@ -3927,6 +3963,7 @@ const Combobox = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
3927
3963
|
|
|
3928
3964
|
// Gets the filtered options based on the current input value (only if isFilteringDisabled is false)
|
|
3929
3965
|
const [listChildrenFilteredOptions, [, filteredOptions]] = React.useMemo(() => {
|
|
3966
|
+
var _comboboxList2;
|
|
3930
3967
|
let currentHeaderTitle;
|
|
3931
3968
|
const handleSelect = option => {
|
|
3932
3969
|
const newOptionValue = getOptionValue(option);
|
|
@@ -3938,15 +3975,16 @@ const Combobox = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
3938
3975
|
}
|
|
3939
3976
|
});
|
|
3940
3977
|
};
|
|
3941
|
-
return filterChildren(comboboxList
|
|
3978
|
+
return filterChildren((_comboboxList2 = comboboxList) === null || _comboboxList2 === void 0 || (_comboboxList2 = _comboboxList2.props) === null || _comboboxList2 === void 0 ? void 0 : _comboboxList2.children, [
|
|
3942
3979
|
/*
|
|
3943
3980
|
* For each header, adds a key value pair to the headerCounts object where the key is the header title and the value is 0.
|
|
3944
3981
|
* The value will be updated in the matcher/modifier below this matcher/modifier.
|
|
3945
3982
|
*/
|
|
3946
3983
|
{
|
|
3947
|
-
matcher: child => child
|
|
3984
|
+
matcher: child => (child === null || child === void 0 ? void 0 : child.type) === ComboboxHeader,
|
|
3948
3985
|
modifier: child => {
|
|
3949
|
-
|
|
3986
|
+
var _props;
|
|
3987
|
+
currentHeaderTitle = (_props = child.props) === null || _props === void 0 ? void 0 : _props.title;
|
|
3950
3988
|
headerCounts[currentHeaderTitle] = 0;
|
|
3951
3989
|
return child;
|
|
3952
3990
|
}
|
|
@@ -3956,16 +3994,18 @@ const Combobox = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
3956
3994
|
* Otherwise, returns null.
|
|
3957
3995
|
*/
|
|
3958
3996
|
{
|
|
3959
|
-
matcher: child => child
|
|
3997
|
+
matcher: child => (child === null || child === void 0 ? void 0 : child.type) === ComboboxOption,
|
|
3960
3998
|
modifier: (child, index) => {
|
|
3961
3999
|
if (inputValue === selectedOptionLabel || isFilteringDisabled || doesOptionMatchFilter(child, currentHeaderTitle, inputValue)) {
|
|
4000
|
+
var _props$id;
|
|
3962
4001
|
headerCounts[currentHeaderTitle] += 1;
|
|
3963
4002
|
return /*#__PURE__*/React.cloneElement(child, {
|
|
3964
4003
|
onSelect: e => {
|
|
3965
|
-
|
|
4004
|
+
var _props2, _props2$onSelect;
|
|
4005
|
+
child === null || child === void 0 || (_props2 = child.props) === null || _props2 === void 0 || (_props2$onSelect = _props2.onSelect) === null || _props2$onSelect === void 0 ? void 0 : _props2$onSelect.call(_props2, e);
|
|
3966
4006
|
|
|
3967
4007
|
// Prevents form submission
|
|
3968
|
-
if (e
|
|
4008
|
+
if ((e === null || e === void 0 ? void 0 : e.key) === 'Enter') {
|
|
3969
4009
|
e.preventDefault();
|
|
3970
4010
|
}
|
|
3971
4011
|
if (!e.key) {
|
|
@@ -3986,7 +4026,7 @@ const Combobox = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
3986
4026
|
isHighlightedOnHover: isOptionSelectedOnKeyboardHighlight,
|
|
3987
4027
|
isHighlighted: isOptionSelectedOnKeyboardHighlight ? false : index === highlightedIndex,
|
|
3988
4028
|
isSelected: isOptionSelectedOnKeyboardHighlight ? index === selectedIndex : selectedOptionValue === getOptionValue(child),
|
|
3989
|
-
id: child.props.id
|
|
4029
|
+
id: (_props$id = child.props.id) !== null && _props$id !== void 0 ? _props$id : "".concat(listContainerId, "-option-").concat(index),
|
|
3990
4030
|
ref: node => {
|
|
3991
4031
|
optionRefs.current[Number(index)] = node;
|
|
3992
4032
|
}
|
|
@@ -4000,15 +4040,19 @@ const Combobox = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
4000
4040
|
|
|
4001
4041
|
// Gets all filtered options, as well as headers that have at least one filtered option
|
|
4002
4042
|
const [listChildrenFilteredOptionsAndHeaders] = React.useMemo(() => filterChildren(listChildrenFilteredOptions, [{
|
|
4003
|
-
matcher: child => child
|
|
4043
|
+
matcher: child => (child === null || child === void 0 ? void 0 : child.type) === ComboboxOption
|
|
4004
4044
|
}, {
|
|
4005
|
-
matcher: child => child
|
|
4006
|
-
modifier: child =>
|
|
4045
|
+
matcher: child => (child === null || child === void 0 ? void 0 : child.type) === ComboboxHeader,
|
|
4046
|
+
modifier: child => {
|
|
4047
|
+
var _props3;
|
|
4048
|
+
return headerCounts[(_props3 = child.props) === null || _props3 === void 0 ? void 0 : _props3.title] ? child : null;
|
|
4049
|
+
}
|
|
4007
4050
|
}]), [headerCounts, listChildrenFilteredOptions]);
|
|
4008
4051
|
const keyboardHighlightOrSelectOption = (index, e) => {
|
|
4009
4052
|
if (isOptionSelectedOnKeyboardHighlight) {
|
|
4053
|
+
var _filteredOptions$inde, _filteredOptions$inde2;
|
|
4010
4054
|
setSelectedIndex(index);
|
|
4011
|
-
filteredOptions[index]
|
|
4055
|
+
(_filteredOptions$inde = filteredOptions[index]) === null || _filteredOptions$inde === void 0 || (_filteredOptions$inde = _filteredOptions$inde.props) === null || _filteredOptions$inde === void 0 || (_filteredOptions$inde2 = _filteredOptions$inde.onSelect) === null || _filteredOptions$inde2 === void 0 ? void 0 : _filteredOptions$inde2.call(_filteredOptions$inde, e);
|
|
4012
4056
|
} else {
|
|
4013
4057
|
setHighlightedIndex(index);
|
|
4014
4058
|
}
|
|
@@ -4066,7 +4110,8 @@ const Combobox = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
4066
4110
|
case 'Enter':
|
|
4067
4111
|
if (isFlyoutOpen) {
|
|
4068
4112
|
if (!isOptionSelectedOnKeyboardHighlight && filteredOptions.length > 0 && filteredOptions[highlightedIndex] !== undefined) {
|
|
4069
|
-
|
|
4113
|
+
var _filteredOptions$high, _filteredOptions$high2;
|
|
4114
|
+
(_filteredOptions$high = filteredOptions[highlightedIndex]) === null || _filteredOptions$high === void 0 || (_filteredOptions$high = _filteredOptions$high.props) === null || _filteredOptions$high === void 0 || (_filteredOptions$high2 = _filteredOptions$high.onSelect) === null || _filteredOptions$high2 === void 0 ? void 0 : _filteredOptions$high2.call(_filteredOptions$high, e);
|
|
4070
4115
|
}
|
|
4071
4116
|
}
|
|
4072
4117
|
setIsFlyoutOpen(false);
|
|
@@ -4127,11 +4172,12 @@ const Combobox = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
4127
4172
|
React.useEffect(() => {
|
|
4128
4173
|
const currentIndex = isOptionSelectedOnKeyboardHighlight ? selectedIndex : highlightedIndex;
|
|
4129
4174
|
const optionRef = optionRefs.current[currentIndex];
|
|
4130
|
-
if (isFocusVisible && isFlyoutOpen && optionRef && listRef
|
|
4175
|
+
if (isFocusVisible && isFlyoutOpen && optionRef && listRef !== null && listRef !== void 0 && listRef.current) {
|
|
4176
|
+
var _listRef$current, _listRef$current2;
|
|
4131
4177
|
if (currentIndex === 0) {
|
|
4132
4178
|
// Scrolls the first header into view if one exists
|
|
4133
4179
|
listRef.current.scrollTop = 0;
|
|
4134
|
-
} else if (listRef.current
|
|
4180
|
+
} else if (((_listRef$current = listRef.current) === null || _listRef$current === void 0 ? void 0 : _listRef$current.scrollHeight) > ((_listRef$current2 = listRef.current) === null || _listRef$current2 === void 0 ? void 0 : _listRef$current2.clientHeight)) {
|
|
4135
4181
|
const scrollBottom = listRef.current.clientHeight + listRef.current.scrollTop;
|
|
4136
4182
|
const elementBottom = optionRef.offsetTop + optionRef.offsetHeight;
|
|
4137
4183
|
if (elementBottom > scrollBottom) {
|
|
@@ -4171,16 +4217,18 @@ const Combobox = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
4171
4217
|
const activeDescendantId = React.useMemo(() => {
|
|
4172
4218
|
if (isAriaExpanded) {
|
|
4173
4219
|
if (unstable_isLoading) {
|
|
4174
|
-
return
|
|
4220
|
+
return "".concat(listContainerId, "-loading-spinner");
|
|
4175
4221
|
}
|
|
4176
4222
|
if (filteredOptions.length === 0) {
|
|
4177
4223
|
return undefined;
|
|
4178
4224
|
}
|
|
4179
4225
|
if (selectedIndex !== -1) {
|
|
4180
|
-
|
|
4226
|
+
var _filteredOptions$sele;
|
|
4227
|
+
return (_filteredOptions$sele = filteredOptions[selectedIndex]) === null || _filteredOptions$sele === void 0 ? void 0 : _filteredOptions$sele.props.id;
|
|
4181
4228
|
}
|
|
4182
4229
|
if (highlightedIndex !== -1) {
|
|
4183
|
-
|
|
4230
|
+
var _filteredOptions$high3;
|
|
4231
|
+
return (_filteredOptions$high3 = filteredOptions[highlightedIndex]) === null || _filteredOptions$high3 === void 0 ? void 0 : _filteredOptions$high3.props.id;
|
|
4184
4232
|
}
|
|
4185
4233
|
}
|
|
4186
4234
|
return undefined;
|
|
@@ -4227,14 +4275,14 @@ const Combobox = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
4227
4275
|
}, translate('noMatchesFound')) : listChildrenFilteredOptionsAndHeaders)));
|
|
4228
4276
|
});
|
|
4229
4277
|
|
|
4230
|
-
var css_248z$v = ".
|
|
4231
|
-
var styles$t = {"paneContainer":"
|
|
4232
|
-
var stylesheet$v=".
|
|
4278
|
+
var css_248z$v = "._MGeCe{grid-area:configPane;position:relative;height:100%}._0Vjhf{overflow:hidden;height:100%;position:absolute;background-color:#fff;top:0;transition:width .5s;width:292px;border-right:1px solid #898989;box-sizing:border-box}._zTeq7._lNdSi ._0Vjhf,._zTeq7:not(._Ff6Pj) ._0Vjhf{-webkit-clip-path:inset(0 -20px 0 0);clip-path:inset(0 -20px 0 0);box-shadow:0 8px 20px 0 rgba(0,0,0,.1),0 4px 6px 0 rgba(0,0,0,.05)}._Ff6Pj ._0Vjhf{width:0}._lNdSi._Ff6Pj ._0Vjhf{width:30px;cursor:pointer}._5DHlo ._0Vjhf{border-right-color:#eee}._332zD{height:100%;position:relative;width:292px}._Ff6Pj ._332zD,._zTeq7 ._332zD{width:0}._lNdSi._Ff6Pj ._332zD,._lNdSi._zTeq7 ._332zD{width:30px}._yd1-W ._332zD{transition:width .5s}._y5FDR{position:absolute;width:292px;height:100%;right:0;overflow:auto;padding:12px 0}._Ff6Pj ._y5FDR{visibility:hidden}._yd1-W ._y5FDR{visibility:visible}._y5FDR ._oKgCZ{width:252px;margin-left:20px}._Xs90L{display:flex;flex-direction:row;justify-content:space-between;align-items:center;padding-bottom:12px}._RqQ33{flex-grow:1;padding-right:8px;line-height:20px;margin:8px 0}._RqQ33 *{font-weight:400;font-size:16px;margin:0}._Zi0i9{position:absolute;transition:left .5s;top:0;left:290px;width:12px;cursor:pointer;height:100%}._Ff6Pj ._Zi0i9{left:0}._lNdSi._Ff6Pj ._Zi0i9{left:30px}._Zi0i9 ._WCnLT{width:4px;height:100%}._lNdSi._Ff6Pj ._0Vjhf:hover+._Zi0i9 ._WCnLT,._Zi0i9:hover ._WCnLT{background-color:#9dc5ed}._lNdSi._Ff6Pj ._0Vjhf:hover+._Zi0i9 ._szc-P>span,._Zi0i9:hover ._szc-P>span{background-color:#0b6ed0;border-color:#0b6ed0}._lNdSi._Ff6Pj ._0Vjhf:hover+._Zi0i9 ._szc-P>span>svg,._Zi0i9:hover ._szc-P>span>svg{fill:#fff}._lNdSi._Ff6Pj ._0Vjhf:hover+._Zi0i9 ._szc-P:active>span,._Zi0i9:hover ._szc-P:active>span{background-color:#0854a1;border-color:#0854a1}._lNdSi._Ff6Pj ._0Vjhf:hover+._Zi0i9 ._szc-P:active>span>svg,._Zi0i9:hover ._szc-P:active>span>svg{fill:#fff}._Zi0i9 ._szc-P{left:-16px;width:36px;height:36px;position:absolute;top:48px;display:flex;justify-content:center;align-items:center;padding:0;background-color:transparent;border:2px solid transparent;border-radius:6px;outline:none;cursor:pointer;z-index:10;opacity:0}._Zi0i9 ._szc-P._dQnqp._dQnqp._dQnqp{opacity:1}._Zi0i9 ._szc-P._E-H1p._E-H1p._E-H1p{opacity:0}._Zi0i9 ._szc-P:active>span{background-color:#0854a1;border-color:#0854a1}._Zi0i9 ._szc-P:active>span>svg{fill:#fff}._Zi0i9 ._szc-P>span{width:24px;height:24px;display:flex;justify-content:center;align-items:center;background-color:#fff;border:1px solid #898989;border-radius:50%}._Zi0i9 ._szc-P>span>svg{fill:#515559;border-radius:50%}._0Vjhf:hover+._Zi0i9 ._szc-P,._Ff6Pj ._Zi0i9 ._szc-P,._Zi0i9:hover ._szc-P{opacity:1}._szc-P.focus-visible,._szc-P:focus-visible{opacity:1;border-color:#0a3f88}";
|
|
4279
|
+
var styles$t = {"paneContainer":"_MGeCe","paneContentContainer":"_0Vjhf","unpinned":"_zTeq7","hidden":"_Ff6Pj","preview":"_lNdSi","openHidden":"_5DHlo","spacer":"_332zD","transitioning":"_yd1-W","paneContent":"_y5FDR","paneContentInner":"_oKgCZ","header":"_Xs90L","title":"_RqQ33","clickableArea":"_Zi0i9","hoverBorder":"_WCnLT","toolbarPanelExpandCollapseButton":"_szc-P","overrideShow":"_dQnqp","overrideHide":"_E-H1p"};
|
|
4280
|
+
var stylesheet$v="._MGeCe{grid-area:configPane;position:relative;height:100%}._0Vjhf{overflow:hidden;height:100%;position:absolute;background-color:#fff;top:0;transition:width .5s;width:292px;border-right:1px solid #898989;box-sizing:border-box}._zTeq7._lNdSi ._0Vjhf,._zTeq7:not(._Ff6Pj) ._0Vjhf{-webkit-clip-path:inset(0 -20px 0 0);clip-path:inset(0 -20px 0 0);box-shadow:0 8px 20px 0 rgba(0,0,0,.1),0 4px 6px 0 rgba(0,0,0,.05)}._Ff6Pj ._0Vjhf{width:0}._lNdSi._Ff6Pj ._0Vjhf{width:30px;cursor:pointer}._5DHlo ._0Vjhf{border-right-color:#eee}._332zD{height:100%;position:relative;width:292px}._Ff6Pj ._332zD,._zTeq7 ._332zD{width:0}._lNdSi._Ff6Pj ._332zD,._lNdSi._zTeq7 ._332zD{width:30px}._yd1-W ._332zD{transition:width .5s}._y5FDR{position:absolute;width:292px;height:100%;right:0;overflow:auto;padding:12px 0}._Ff6Pj ._y5FDR{visibility:hidden}._yd1-W ._y5FDR{visibility:visible}._y5FDR ._oKgCZ{width:252px;margin-left:20px}._Xs90L{display:flex;flex-direction:row;justify-content:space-between;align-items:center;padding-bottom:12px}._RqQ33{flex-grow:1;padding-right:8px;line-height:20px;margin:8px 0}._RqQ33 *{font-weight:400;font-size:16px;margin:0}._Zi0i9{position:absolute;transition:left .5s;top:0;left:290px;width:12px;cursor:pointer;height:100%}._Ff6Pj ._Zi0i9{left:0}._lNdSi._Ff6Pj ._Zi0i9{left:30px}._Zi0i9 ._WCnLT{width:4px;height:100%}._lNdSi._Ff6Pj ._0Vjhf:hover+._Zi0i9 ._WCnLT,._Zi0i9:hover ._WCnLT{background-color:#9dc5ed}._lNdSi._Ff6Pj ._0Vjhf:hover+._Zi0i9 ._szc-P>span,._Zi0i9:hover ._szc-P>span{background-color:#0b6ed0;border-color:#0b6ed0}._lNdSi._Ff6Pj ._0Vjhf:hover+._Zi0i9 ._szc-P>span>svg,._Zi0i9:hover ._szc-P>span>svg{fill:#fff}._lNdSi._Ff6Pj ._0Vjhf:hover+._Zi0i9 ._szc-P:active>span,._Zi0i9:hover ._szc-P:active>span{background-color:#0854a1;border-color:#0854a1}._lNdSi._Ff6Pj ._0Vjhf:hover+._Zi0i9 ._szc-P:active>span>svg,._Zi0i9:hover ._szc-P:active>span>svg{fill:#fff}._Zi0i9 ._szc-P{left:-16px;width:36px;height:36px;position:absolute;top:48px;display:flex;justify-content:center;align-items:center;padding:0;background-color:transparent;border:2px solid transparent;border-radius:6px;outline:none;cursor:pointer;z-index:10;opacity:0}._Zi0i9 ._szc-P._dQnqp._dQnqp._dQnqp{opacity:1}._Zi0i9 ._szc-P._E-H1p._E-H1p._E-H1p{opacity:0}._Zi0i9 ._szc-P:active>span{background-color:#0854a1;border-color:#0854a1}._Zi0i9 ._szc-P:active>span>svg{fill:#fff}._Zi0i9 ._szc-P>span{width:24px;height:24px;display:flex;justify-content:center;align-items:center;background-color:#fff;border:1px solid #898989;border-radius:50%}._Zi0i9 ._szc-P>span>svg{fill:#515559;border-radius:50%}._0Vjhf:hover+._Zi0i9 ._szc-P,._Ff6Pj ._Zi0i9 ._szc-P,._Zi0i9:hover ._szc-P{opacity:1}._szc-P.focus-visible,._szc-P:focus-visible{opacity:1;border-color:#0a3f88}";
|
|
4233
4281
|
icons_index.styleInject(css_248z$v);
|
|
4234
4282
|
|
|
4235
|
-
var css_248z$u = ".
|
|
4236
|
-
var styles$s = {"button":"
|
|
4237
|
-
var stylesheet$u=".
|
|
4283
|
+
var css_248z$u = "._oL-6j{border-radius:4px;border:none;height:36px;width:36px;display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;padding:0;cursor:pointer;fill:#515559;background-color:transparent;transition:background .2s,color .2s}._oL-6j:focus{outline:none}._oL-6j:hover:not(._jhdYU){background-color:rgba(50,54,58,.08)}._oL-6j:active:not(._jhdYU){background-color:rgba(50,54,58,.11);stroke-width:2}._oL-6j._jhdYU{cursor:not-allowed;fill:rgba(81,85,89,.6)}._oL-6j.focus-visible,._oL-6j:focus-visible{outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
4284
|
+
var styles$s = {"button":"_oL-6j","disabled":"_jhdYU"};
|
|
4285
|
+
var stylesheet$u="._oL-6j{border-radius:4px;border:none;height:36px;width:36px;display:inline-flex;flex-shrink:0;align-items:center;justify-content:center;padding:0;cursor:pointer;fill:#515559;background-color:transparent;transition:background .2s,color .2s}._oL-6j:focus{outline:none}._oL-6j:hover:not(._jhdYU){background-color:rgba(50,54,58,.08)}._oL-6j:active:not(._jhdYU){background-color:rgba(50,54,58,.11);stroke-width:2}._oL-6j._jhdYU{cursor:not-allowed;fill:rgba(81,85,89,.6)}._oL-6j.focus-visible,._oL-6j:focus-visible{outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
4238
4286
|
icons_index.styleInject(css_248z$u);
|
|
4239
4287
|
|
|
4240
4288
|
const sizePropInIconErrorMessage = 'Warning: The `Icon` prop `size` is invalid when used as a child of `IconButton`.';
|
|
@@ -4446,9 +4494,9 @@ const ConfigPane = _ref2 => {
|
|
|
4446
4494
|
})));
|
|
4447
4495
|
};
|
|
4448
4496
|
|
|
4449
|
-
var css_248z$t = ".
|
|
4450
|
-
var styles$r = {"divider":"
|
|
4451
|
-
var stylesheet$t=".
|
|
4497
|
+
var css_248z$t = "._BS07a{border:none;height:1px;margin:0;flex-shrink:0;background-color:#e5e5e5}";
|
|
4498
|
+
var styles$r = {"divider":"_BS07a"};
|
|
4499
|
+
var stylesheet$t="._BS07a{border:none;height:1px;margin:0;flex-shrink:0;background-color:#e5e5e5}";
|
|
4452
4500
|
icons_index.styleInject(css_248z$t);
|
|
4453
4501
|
|
|
4454
4502
|
const Divider = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
@@ -4462,9 +4510,9 @@ const Divider = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =>
|
|
|
4462
4510
|
}, rest));
|
|
4463
4511
|
});
|
|
4464
4512
|
|
|
4465
|
-
var css_248z$s = ".
|
|
4466
|
-
var styles$q = {"container":"
|
|
4467
|
-
var stylesheet$s=".
|
|
4513
|
+
var css_248z$s = "._enUAC{max-width:100%;position:relative;display:inline-block}._i0NGQ{display:inline-flex;justify-content:space-between;align-items:center;background-color:#fafafa;border:1px solid #898989;border-radius:4px;height:36px;color:#515559;outline:none;cursor:pointer}._i0NGQ:hover:not([aria-disabled=true]){cursor:pointer;background-color:#f5f5f5}._i0NGQ:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88;background-color:#fafafa}._i0NGQ:disabled,._i0NGQ[aria-disabled=true]{color:#74777a;border-color:#e5e5e5;cursor:not-allowed}._i0NGQ._6-osc{border-color:#b00}._i0NGQ._6-osc:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #900000}._i0NGQ._Nkl50{min-width:120px;padding:0 4px 0 12px}._i0NGQ._tj3dL{margin-top:4px}._i0NGQ._MREOr:not([aria-disabled=true]):not(:disabled){color:#32363a}._i0NGQ ._YwHex{display:inline-flex;align-items:center;min-height:10px}._i0NGQ ._YwHex._66Era{line-height:20px;font-size:14px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}._i0NGQ ._VM9BK{height:24px;width:24px;border-radius:4px;fill:#515559;flex-shrink:0;cursor:pointer}._i0NGQ ._VM9BK._fbJku{border-color:#e5e5e5;fill:#9d9fa1;opacity:.4;cursor:not-allowed}._i0NGQ ._VM9BK._HbvjK{transform:rotate(-180deg)}._Xn-u8[aria-disabled=true]{cursor:not-allowed;color:rgba(81,85,89,.65);fill:#9d9fa1}._H1kr8{position:-webkit-sticky;position:sticky;top:0;z-index:20;padding:4px 8px 8px!important;border-bottom:1px solid #e8e8e8;border-radius:4px 4px 0 0;background-color:#fff!important}._rJiup{min-height:40px;padding:10px 12px;display:flex;flex-direction:row;align-items:center;background-color:#fff;font-size:14px;color:#32363a;word-break:break-word}._Bhf0k{fill:#515559}._Xr-Gq{margin:2px 12px 2px 0}._Xr-Gq._Ua0gy>svg{border-color:#0b6ed0}._-5nVZ{width:100%}";
|
|
4514
|
+
var styles$q = {"container":"_enUAC","button":"_i0NGQ","invalid":"_6-osc","hasText":"_Nkl50","labelled":"_tj3dL","selected":"_MREOr","buttonLabel":"_YwHex","isString":"_66Era","icon":"_VM9BK","disabled":"_fbJku","open":"_HbvjK","option":"_Xn-u8","search":"_H1kr8","emptyOption":"_rJiup","searchIcon":"_Bhf0k","checkbox":"_Xr-Gq","highlighted":"_Ua0gy","searchInput":"_-5nVZ"};
|
|
4515
|
+
var stylesheet$s="._enUAC{max-width:100%;position:relative;display:inline-block}._i0NGQ{display:inline-flex;justify-content:space-between;align-items:center;background-color:#fafafa;border:1px solid #898989;border-radius:4px;height:36px;color:#515559;outline:none;cursor:pointer}._i0NGQ:hover:not([aria-disabled=true]){cursor:pointer;background-color:#f5f5f5}._i0NGQ:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88;background-color:#fafafa}._i0NGQ:disabled,._i0NGQ[aria-disabled=true]{color:#74777a;border-color:#e5e5e5;cursor:not-allowed}._i0NGQ._6-osc{border-color:#b00}._i0NGQ._6-osc:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #900000}._i0NGQ._Nkl50{min-width:120px;padding:0 4px 0 12px}._i0NGQ._tj3dL{margin-top:4px}._i0NGQ._MREOr:not([aria-disabled=true]):not(:disabled){color:#32363a}._i0NGQ ._YwHex{display:inline-flex;align-items:center;min-height:10px}._i0NGQ ._YwHex._66Era{line-height:20px;font-size:14px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}._i0NGQ ._VM9BK{height:24px;width:24px;border-radius:4px;fill:#515559;flex-shrink:0;cursor:pointer}._i0NGQ ._VM9BK._fbJku{border-color:#e5e5e5;fill:#9d9fa1;opacity:.4;cursor:not-allowed}._i0NGQ ._VM9BK._HbvjK{transform:rotate(-180deg)}._Xn-u8[aria-disabled=true]{cursor:not-allowed;color:rgba(81,85,89,.65);fill:#9d9fa1}._H1kr8{position:-webkit-sticky;position:sticky;top:0;z-index:20;padding:4px 8px 8px!important;border-bottom:1px solid #e8e8e8;border-radius:4px 4px 0 0;background-color:#fff!important}._rJiup{min-height:40px;padding:10px 12px;display:flex;flex-direction:row;align-items:center;background-color:#fff;font-size:14px;color:#32363a;word-break:break-word}._Bhf0k{fill:#515559}._Xr-Gq{margin:2px 12px 2px 0}._Xr-Gq._Ua0gy>svg{border-color:#0b6ed0}._-5nVZ{width:100%}";
|
|
4468
4516
|
icons_index.styleInject(css_248z$s);
|
|
4469
4517
|
|
|
4470
4518
|
const {
|
|
@@ -4473,6 +4521,7 @@ const {
|
|
|
4473
4521
|
} = createContextUtilities({});
|
|
4474
4522
|
|
|
4475
4523
|
const DropdownButton = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
4524
|
+
var _ref2, _children$props$aria, _children$props, _ref3, _children$props$aria2, _children$props2, _ref4, _children$props$aria3, _children$props3, _children$props$tabIn, _children$props4, _children$props7, _children$props8;
|
|
4476
4525
|
let {
|
|
4477
4526
|
children,
|
|
4478
4527
|
className,
|
|
@@ -4519,9 +4568,9 @@ const DropdownButton = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
4519
4568
|
helperTextId: formFieldHelperTextId,
|
|
4520
4569
|
errorTextId: formFieldErrorTextId
|
|
4521
4570
|
} = useFormFieldControl();
|
|
4522
|
-
const ariaLabelledBy = children
|
|
4523
|
-
const ariaLabel = children
|
|
4524
|
-
const ariaDescribedby = concatIds(children
|
|
4571
|
+
const ariaLabelledBy = (_ref2 = (_children$props$aria = children === null || children === void 0 || (_children$props = children.props) === null || _children$props === void 0 ? void 0 : _children$props['aria-labelledby']) !== null && _children$props$aria !== void 0 ? _children$props$aria : externalAriaLabelledBy) !== null && _ref2 !== void 0 ? _ref2 : dropdownAriaLabelledBy ? "".concat(dropdownAriaLabelledBy, " ").concat(buttonId) : undefined;
|
|
4572
|
+
const ariaLabel = (_ref3 = (_children$props$aria2 = children === null || children === void 0 || (_children$props2 = children.props) === null || _children$props2 === void 0 ? void 0 : _children$props2['aria-label']) !== null && _children$props$aria2 !== void 0 ? _children$props$aria2 : externalAriaLabel) !== null && _ref3 !== void 0 ? _ref3 : dropdownAriaLabel && typeof label === 'string' ? "".concat(dropdownAriaLabel, " ").concat(label) : dropdownAriaLabel;
|
|
4573
|
+
const ariaDescribedby = concatIds((_ref4 = (_children$props$aria3 = children === null || children === void 0 || (_children$props3 = children.props) === null || _children$props3 === void 0 ? void 0 : _children$props3['aria-describedby']) !== null && _children$props$aria3 !== void 0 ? _children$props$aria3 : externalAriaDescribedBy) !== null && _ref4 !== void 0 ? _ref4 : dropdownAriaDescribedby, formFieldHelperTextId, formFieldErrorTextId);
|
|
4525
4574
|
React.useEffect(() => {
|
|
4526
4575
|
const selectedLabels = [];
|
|
4527
4576
|
options.forEach(option => {
|
|
@@ -4533,12 +4582,13 @@ const DropdownButton = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
4533
4582
|
setLabel(selectedLabels.length > 0 ? selectedLabels.join(', ') : defaultLabel);
|
|
4534
4583
|
}, [setLabel, options, defaultLabel]);
|
|
4535
4584
|
React.useEffect(() => {
|
|
4536
|
-
|
|
4585
|
+
var _buttonRef$current;
|
|
4586
|
+
setMinWidth(buttonRef === null || buttonRef === void 0 || (_buttonRef$current = buttonRef.current) === null || _buttonRef$current === void 0 ? void 0 : _buttonRef$current.offsetWidth);
|
|
4537
4587
|
});
|
|
4538
4588
|
const isInvalid = isInvalidProp !== undefined ? isInvalidProp : dropdownIsInvalid;
|
|
4539
4589
|
const handleClick = e => {
|
|
4540
|
-
if (disabled
|
|
4541
|
-
onClick
|
|
4590
|
+
if (disabled !== null && disabled !== void 0 ? disabled : dropdownAriaDisabled) return;
|
|
4591
|
+
onClick === null || onClick === void 0 ? void 0 : onClick(e);
|
|
4542
4592
|
// Needed because some browsers don't focus on click
|
|
4543
4593
|
e.currentTarget.focus();
|
|
4544
4594
|
setIsOpen(currentIsOpen => {
|
|
@@ -4547,15 +4597,15 @@ const DropdownButton = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
4547
4597
|
});
|
|
4548
4598
|
};
|
|
4549
4599
|
const handleKeyDown = e => {
|
|
4550
|
-
if (disabled
|
|
4551
|
-
onKeyDown
|
|
4600
|
+
if (disabled !== null && disabled !== void 0 ? disabled : dropdownAriaDisabled) return;
|
|
4601
|
+
onKeyDown === null || onKeyDown === void 0 ? void 0 : onKeyDown(e);
|
|
4552
4602
|
onKeyDownButton(e);
|
|
4553
4603
|
};
|
|
4554
4604
|
return /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, children ? /*#__PURE__*/React__default["default"].cloneElement(children, {
|
|
4555
|
-
ref: mergeRefs(ref, children
|
|
4605
|
+
ref: mergeRefs(ref, children === null || children === void 0 ? void 0 : children.ref, buttonRef, dropdownButtonRef),
|
|
4556
4606
|
disabled: disabled || dropdownAriaDisabled,
|
|
4557
4607
|
'aria-disabled': dropdownAriaDisabled,
|
|
4558
|
-
tabIndex: children.props
|
|
4608
|
+
tabIndex: (_children$props$tabIn = (_children$props4 = children.props) === null || _children$props4 === void 0 ? void 0 : _children$props4.tabIndex) !== null && _children$props$tabIn !== void 0 ? _children$props$tabIn : 0,
|
|
4559
4609
|
role: 'button',
|
|
4560
4610
|
'aria-expanded': isOpen,
|
|
4561
4611
|
'aria-haspopup': 'listbox',
|
|
@@ -4565,15 +4615,17 @@ const DropdownButton = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
4565
4615
|
'aria-describedby': ariaDescribedby,
|
|
4566
4616
|
id: buttonId,
|
|
4567
4617
|
onFocus: e => {
|
|
4568
|
-
|
|
4569
|
-
onFocus
|
|
4618
|
+
var _children$props5, _children$props5$onFo;
|
|
4619
|
+
(_children$props5 = children.props) === null || _children$props5 === void 0 || (_children$props5$onFo = _children$props5.onFocus) === null || _children$props5$onFo === void 0 ? void 0 : _children$props5$onFo.call(_children$props5, e);
|
|
4620
|
+
onFocus === null || onFocus === void 0 ? void 0 : onFocus(e);
|
|
4570
4621
|
},
|
|
4571
4622
|
onBlur: e => {
|
|
4572
|
-
|
|
4573
|
-
onBlur
|
|
4623
|
+
var _children$props6, _children$props6$onBl;
|
|
4624
|
+
(_children$props6 = children.props) === null || _children$props6 === void 0 || (_children$props6$onBl = _children$props6.onBlur) === null || _children$props6$onBl === void 0 ? void 0 : _children$props6$onBl.call(_children$props6, e);
|
|
4625
|
+
onBlur === null || onBlur === void 0 ? void 0 : onBlur(e);
|
|
4574
4626
|
},
|
|
4575
|
-
onKeyDown: wrapEvent(children.props
|
|
4576
|
-
onClick: wrapEvent(children.props
|
|
4627
|
+
onKeyDown: wrapEvent((_children$props7 = children.props) === null || _children$props7 === void 0 ? void 0 : _children$props7.onKeyDown, handleKeyDown),
|
|
4628
|
+
onClick: wrapEvent((_children$props8 = children.props) === null || _children$props8 === void 0 ? void 0 : _children$props8.onClick, handleClick)
|
|
4577
4629
|
}) : /*#__PURE__*/React__default["default"].createElement("button", _extends__default["default"]({}, rest, {
|
|
4578
4630
|
ref: mergeRefs(ref, buttonRef, dropdownButtonRef),
|
|
4579
4631
|
type: "button",
|
|
@@ -4590,14 +4642,14 @@ const DropdownButton = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
4590
4642
|
[styles$q.hasText]: !!label,
|
|
4591
4643
|
[styles$q.invalid]: isInvalid,
|
|
4592
4644
|
[styles$q.labelled]: hasFormLabel,
|
|
4593
|
-
[styles$q.selected]: externalLabel
|
|
4645
|
+
[styles$q.selected]: externalLabel !== null && externalLabel !== void 0 ? externalLabel : isOptionSelected // defaultLabel has lighter text color
|
|
4594
4646
|
}),
|
|
4595
4647
|
|
|
4596
4648
|
onFocus: onFocus,
|
|
4597
4649
|
onBlur: onBlur,
|
|
4598
4650
|
onKeyDown: handleKeyDown,
|
|
4599
4651
|
onClick: handleClick,
|
|
4600
|
-
"data-testid": dataTestId
|
|
4652
|
+
"data-testid": dataTestId !== null && dataTestId !== void 0 ? dataTestId : getSubDataTestId(contextDataTestId, 'button')
|
|
4601
4653
|
}), /*#__PURE__*/React__default["default"].createElement("span", {
|
|
4602
4654
|
className: classNames__default["default"](styles$q.buttonLabel, {
|
|
4603
4655
|
[styles$q.isString]: typeof label === 'string'
|
|
@@ -4606,7 +4658,7 @@ const DropdownButton = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
4606
4658
|
size: "medium",
|
|
4607
4659
|
className: classNames__default["default"](styles$q.icon, {
|
|
4608
4660
|
[styles$q.open]: isOpen,
|
|
4609
|
-
[styles$q.disabled]: disabled
|
|
4661
|
+
[styles$q.disabled]: disabled !== null && disabled !== void 0 ? disabled : dropdownAriaDisabled
|
|
4610
4662
|
}),
|
|
4611
4663
|
"aria-hidden": "true"
|
|
4612
4664
|
})));
|
|
@@ -4649,14 +4701,17 @@ function useDescendant(descendant, context, indexProp) {
|
|
|
4649
4701
|
// index on the following render and we will re-register descendants
|
|
4650
4702
|
// so that everything is up-to-date before the user interacts with a
|
|
4651
4703
|
// collection.
|
|
4652
|
-
const index = indexProp
|
|
4704
|
+
const index = indexProp !== null && indexProp !== void 0 ? indexProp : descendants.findIndex(item => item.element === descendant.element);
|
|
4653
4705
|
const previousDescendants = usePrevious(descendants);
|
|
4654
4706
|
|
|
4655
4707
|
// We also need to re-register descendants any time ANY of the other
|
|
4656
4708
|
// descendants have changed. My brain was melting when I wrote this and it
|
|
4657
4709
|
// feels a little off, but checking in render and using the result in the
|
|
4658
4710
|
// effect's dependency array works well enough.
|
|
4659
|
-
const someDescendantsHaveChanged = descendants.some((descendant, index) =>
|
|
4711
|
+
const someDescendantsHaveChanged = descendants.some((descendant, index) => {
|
|
4712
|
+
var _previousDescendants$;
|
|
4713
|
+
return descendant.element !== (previousDescendants === null || previousDescendants === void 0 || (_previousDescendants$ = previousDescendants[index]) === null || _previousDescendants$ === void 0 ? void 0 : _previousDescendants$.element);
|
|
4714
|
+
});
|
|
4660
4715
|
|
|
4661
4716
|
// Prevent any flashing
|
|
4662
4717
|
useSSRLayoutEffect(() => {
|
|
@@ -4811,9 +4866,9 @@ function useChildIndex(_ref2) {
|
|
|
4811
4866
|
}, ChildIndexContext);
|
|
4812
4867
|
}
|
|
4813
4868
|
|
|
4814
|
-
var css_248z$r = ".
|
|
4815
|
-
var inputClasses = {"container":"
|
|
4816
|
-
var stylesheet$r=".
|
|
4869
|
+
var css_248z$r = "._Vylos{position:relative;display:inline-block;height:36px}._OVs7G{width:100%;height:100%;padding:8px 12px;color:#32363a;caret-color:#32363a;font-size:14px;background-color:#fafafa;border:1px solid #898989;border-radius:4px;outline:none}._OVs7G:hover{cursor:pointer;background-color:#f5f5f5}._OVs7G:focus{background-color:#fafafa;cursor:text;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88;outline:none;border-color:transparent}._OVs7G:disabled,._OVs7G[aria-disabled=true]{background-color:#fafafa;border-color:#e5e5e5;color:#9d9fa1;-webkit-text-fill-color:#9d9fa1;cursor:not-allowed}._OVs7G:disabled::-moz-placeholder,._OVs7G[aria-disabled=true]::-moz-placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._OVs7G:disabled::placeholder,._OVs7G[aria-disabled=true]::placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._OVs7G:invalid,._OVs7G[aria-invalid=true]{border-color:#b00}._OVs7G:invalid:focus,._OVs7G[aria-invalid=true]:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #900000;border-color:transparent}._OVs7G[type=number]{-moz-appearance:textfield}._OVs7G[type=number]::-webkit-inner-spin-button,._OVs7G[type=number]::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}._OVs7G::-moz-placeholder{color:#515559;opacity:1}._OVs7G::placeholder{color:#515559;opacity:1}._Zbpdl{pointer-events:none;color:#515559;fill:#515559}._WiNM-{display:flex;flex-direction:column;align-items:center;position:absolute;top:50%;transform:translateY(-50%)}._MPlNA{color:#515559;font-size:16px}._3Rbtn{left:0;margin-left:6px}._2cIlT,._3Rbtn{pointer-events:none;color:#515559;fill:#515559;display:flex;flex-direction:column;align-items:center;position:absolute;top:50%;transform:translateY(-50%)}._2cIlT{right:0;margin-right:6px}";
|
|
4870
|
+
var inputClasses = {"container":"_Vylos","input":"_OVs7G","addOn":"_Zbpdl","addOnVerticalCenter":"_WiNM-","addOnTextNode":"_MPlNA","leftAddOn":"_3Rbtn","rightAddOn":"_2cIlT"};
|
|
4871
|
+
var stylesheet$r="._Vylos{position:relative;display:inline-block;height:36px}._OVs7G{width:100%;height:100%;padding:8px 12px;color:#32363a;caret-color:#32363a;font-size:14px;background-color:#fafafa;border:1px solid #898989;border-radius:4px;outline:none}._OVs7G:hover{cursor:pointer;background-color:#f5f5f5}._OVs7G:focus{background-color:#fafafa;cursor:text;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88;outline:none;border-color:transparent}._OVs7G:disabled,._OVs7G[aria-disabled=true]{background-color:#fafafa;border-color:#e5e5e5;color:#9d9fa1;-webkit-text-fill-color:#9d9fa1;cursor:not-allowed}._OVs7G:disabled::-moz-placeholder,._OVs7G[aria-disabled=true]::-moz-placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._OVs7G:disabled::placeholder,._OVs7G[aria-disabled=true]::placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._OVs7G:invalid,._OVs7G[aria-invalid=true]{border-color:#b00}._OVs7G:invalid:focus,._OVs7G[aria-invalid=true]:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #900000;border-color:transparent}._OVs7G[type=number]{-moz-appearance:textfield}._OVs7G[type=number]::-webkit-inner-spin-button,._OVs7G[type=number]::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}._OVs7G::-moz-placeholder{color:#515559;opacity:1}._OVs7G::placeholder{color:#515559;opacity:1}._Zbpdl{pointer-events:none;color:#515559;fill:#515559}._WiNM-{display:flex;flex-direction:column;align-items:center;position:absolute;top:50%;transform:translateY(-50%)}._MPlNA{color:#515559;font-size:16px}._3Rbtn{left:0;margin-left:6px}._2cIlT,._3Rbtn{pointer-events:none;color:#515559;fill:#515559;display:flex;flex-direction:column;align-items:center;position:absolute;top:50%;transform:translateY(-50%)}._2cIlT{right:0;margin-right:6px}";
|
|
4817
4872
|
icons_index.styleInject(css_248z$r);
|
|
4818
4873
|
|
|
4819
4874
|
const getAddOnComponent = (addOn, containerClassName, containerRef) => {
|
|
@@ -4876,13 +4931,14 @@ const Input = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
4876
4931
|
onChange: onChange,
|
|
4877
4932
|
className: inputClasses.input,
|
|
4878
4933
|
style: {
|
|
4879
|
-
paddingLeft:
|
|
4880
|
-
paddingRight:
|
|
4934
|
+
paddingLeft: "".concat(addOnWidths.leftAddOnWidth + ADD_ON_HORIZONTAL_PADDING, "px"),
|
|
4935
|
+
paddingRight: "".concat(addOnWidths.rightAddOnWidth + ADD_ON_HORIZONTAL_PADDING, "px")
|
|
4881
4936
|
},
|
|
4882
4937
|
ref: ref
|
|
4883
4938
|
})), getAddOnComponent(rightAddOn, inputClasses.rightAddOn, rightAddOnRef));
|
|
4884
4939
|
});
|
|
4885
4940
|
|
|
4941
|
+
/* eslint-disable no-nested-ternary */
|
|
4886
4942
|
const DropdownSearch = /*#__PURE__*/React__default["default"].forwardRef((_, ref) => {
|
|
4887
4943
|
const {
|
|
4888
4944
|
translate
|
|
@@ -4900,7 +4956,10 @@ const DropdownSearch = /*#__PURE__*/React__default["default"].forwardRef((_, ref
|
|
|
4900
4956
|
dataTestId,
|
|
4901
4957
|
listboxId
|
|
4902
4958
|
} = useDropdownContext();
|
|
4903
|
-
const handleSelect = () =>
|
|
4959
|
+
const handleSelect = () => {
|
|
4960
|
+
var _inputRef$current;
|
|
4961
|
+
return (_inputRef$current = inputRef.current) === null || _inputRef$current === void 0 ? void 0 : _inputRef$current.focus();
|
|
4962
|
+
};
|
|
4904
4963
|
const myIndex = useChildIndex({
|
|
4905
4964
|
element: internalRef.current,
|
|
4906
4965
|
isVisible: true
|
|
@@ -4909,25 +4968,28 @@ const DropdownSearch = /*#__PURE__*/React__default["default"].forwardRef((_, ref
|
|
|
4909
4968
|
React.useEffect(() => {
|
|
4910
4969
|
// for keyboard navigation
|
|
4911
4970
|
if (isHighlighted) {
|
|
4912
|
-
|
|
4971
|
+
var _inputRef$current2;
|
|
4972
|
+
(_inputRef$current2 = inputRef.current) === null || _inputRef$current2 === void 0 ? void 0 : _inputRef$current2.focus();
|
|
4913
4973
|
}
|
|
4914
4974
|
}, [isHighlighted]);
|
|
4915
4975
|
React.useEffect(() => {
|
|
4916
4976
|
// for initial open with mouse
|
|
4917
4977
|
if (isHighlighted && isOpen) {
|
|
4918
|
-
|
|
4978
|
+
var _inputRef$current3;
|
|
4979
|
+
(_inputRef$current3 = inputRef.current) === null || _inputRef$current3 === void 0 ? void 0 : _inputRef$current3.focus();
|
|
4919
4980
|
}
|
|
4920
4981
|
// Omitted `isHighlighted` because we don't want to focus the input on mouse enter.
|
|
4921
4982
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
4922
4983
|
}, [isOpen]);
|
|
4923
4984
|
React.useEffect(() => {
|
|
4924
4985
|
if (isOpen) {
|
|
4925
|
-
|
|
4986
|
+
var _internalRef$current;
|
|
4987
|
+
setSearchHeight((_internalRef$current = internalRef.current) === null || _internalRef$current === void 0 ? void 0 : _internalRef$current.offsetHeight);
|
|
4926
4988
|
}
|
|
4927
4989
|
}, [isOpen, setSearchHeight]);
|
|
4928
4990
|
const handleKeyDown = e => {
|
|
4929
4991
|
const keysToAllow = ['ArrowDown', 'Escape', 'Tab', 'PageUp', 'Home', 'PageDown', 'End'];
|
|
4930
|
-
if (!
|
|
4992
|
+
if (!keysToAllow.includes(e.key)) {
|
|
4931
4993
|
// `Dropdown` component listens for keystrokes to highlight options with matching labels. We want the focus to remain in the search bar.
|
|
4932
4994
|
e.stopPropagation();
|
|
4933
4995
|
}
|
|
@@ -5003,8 +5065,8 @@ const DropdownList = /*#__PURE__*/React__default["default"].forwardRef((_ref, re
|
|
|
5003
5065
|
translate
|
|
5004
5066
|
} = useTranslation();
|
|
5005
5067
|
const noMatchesText = React.useMemo(() => isSearchable && translate('noMatchesFound'), [isSearchable, translate]);
|
|
5006
|
-
const ariaLabelledby = externalAriaLabelledBy
|
|
5007
|
-
const ariaLabel = externalAriaLabel
|
|
5068
|
+
const ariaLabelledby = externalAriaLabelledBy !== null && externalAriaLabelledBy !== void 0 ? externalAriaLabelledBy : ariaLabelledByFromContext;
|
|
5069
|
+
const ariaLabel = externalAriaLabel !== null && externalAriaLabel !== void 0 ? externalAriaLabel : ariaLabelFromContext;
|
|
5008
5070
|
const announceToScreenReader = useScreenReaderAnnouncement('assertive');
|
|
5009
5071
|
const showNoResults = React.useMemo(() => options.filter(option => option.isVisible).length === 1,
|
|
5010
5072
|
// 1 to include the search box entry
|
|
@@ -5035,14 +5097,14 @@ const DropdownList = /*#__PURE__*/React__default["default"].forwardRef((_ref, re
|
|
|
5035
5097
|
"aria-labelledby": ariaLabelledby,
|
|
5036
5098
|
hidden: !isOpen,
|
|
5037
5099
|
onKeyDown: e => {
|
|
5038
|
-
onKeyDown
|
|
5100
|
+
onKeyDown === null || onKeyDown === void 0 ? void 0 : onKeyDown(e);
|
|
5039
5101
|
onKeyDownList(e);
|
|
5040
5102
|
},
|
|
5041
5103
|
style: {
|
|
5042
5104
|
minWidth,
|
|
5043
5105
|
...style
|
|
5044
5106
|
},
|
|
5045
|
-
"data-testid": dataTestId
|
|
5107
|
+
"data-testid": dataTestId !== null && dataTestId !== void 0 ? dataTestId : getSubDataTestId(contextDataTestId, 'flyout')
|
|
5046
5108
|
}), isSearchable && /*#__PURE__*/React__default["default"].createElement(DropdownSearch, null), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
5047
5109
|
id: listboxId,
|
|
5048
5110
|
role: "listbox",
|
|
@@ -5059,6 +5121,7 @@ const DropdownList = /*#__PURE__*/React__default["default"].forwardRef((_ref, re
|
|
|
5059
5121
|
});
|
|
5060
5122
|
|
|
5061
5123
|
const Dropdown = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
5124
|
+
var _ref2, _dropdownButton$props, _dropdownButton$props2, _dropdownList$props$i, _dropdownList$props;
|
|
5062
5125
|
let {
|
|
5063
5126
|
className,
|
|
5064
5127
|
children,
|
|
@@ -5093,7 +5156,7 @@ const Dropdown = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
5093
5156
|
const [searchHeight, setSearchHeight] = React.useState();
|
|
5094
5157
|
React__default["default"].Children.forEach(children, child => {
|
|
5095
5158
|
if ( /*#__PURE__*/React__default["default"].isValidElement(child)) {
|
|
5096
|
-
switch (child
|
|
5159
|
+
switch (child === null || child === void 0 ? void 0 : child.type) {
|
|
5097
5160
|
case DropdownButton:
|
|
5098
5161
|
dropdownButton = child;
|
|
5099
5162
|
break;
|
|
@@ -5106,9 +5169,9 @@ const Dropdown = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
5106
5169
|
}
|
|
5107
5170
|
});
|
|
5108
5171
|
const containerId = useId(id);
|
|
5109
|
-
const buttonId = dropdownButton.props.children
|
|
5110
|
-
const dialogId = dropdownList.props
|
|
5111
|
-
const listboxId =
|
|
5172
|
+
const buttonId = (_ref2 = (_dropdownButton$props = (_dropdownButton$props2 = dropdownButton.props.children) === null || _dropdownButton$props2 === void 0 || (_dropdownButton$props2 = _dropdownButton$props2.props) === null || _dropdownButton$props2 === void 0 ? void 0 : _dropdownButton$props2.id) !== null && _dropdownButton$props !== void 0 ? _dropdownButton$props : dropdownButton.props.id) !== null && _ref2 !== void 0 ? _ref2 : "".concat(containerId, "-button");
|
|
5173
|
+
const dialogId = (_dropdownList$props$i = (_dropdownList$props = dropdownList.props) === null || _dropdownList$props === void 0 ? void 0 : _dropdownList$props.id) !== null && _dropdownList$props$i !== void 0 ? _dropdownList$props$i : "".concat(containerId, "-list");
|
|
5174
|
+
const listboxId = "".concat(containerId, "-listbox");
|
|
5112
5175
|
const [isOpen, setIsOpen] = useControllableState(false, onIsOpenChange, externalIsOpen);
|
|
5113
5176
|
const [value, setValue] = useControllableState(defaultValue, onChange, externalValue);
|
|
5114
5177
|
const [selectedIndex, setSelectedIndex] = React.useState(0);
|
|
@@ -5130,8 +5193,9 @@ const Dropdown = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
5130
5193
|
let currentIndex = (highlightedIndex + 1) % options.length; // start at next index
|
|
5131
5194
|
let count = 0;
|
|
5132
5195
|
while (count < options.length) {
|
|
5196
|
+
var _option$label;
|
|
5133
5197
|
const option = options[currentIndex];
|
|
5134
|
-
if (option.label
|
|
5198
|
+
if ((_option$label = option.label) !== null && _option$label !== void 0 && _option$label.toLowerCase().startsWith(lowerCaseChar)) {
|
|
5135
5199
|
index = currentIndex;
|
|
5136
5200
|
break;
|
|
5137
5201
|
}
|
|
@@ -5144,8 +5208,9 @@ const Dropdown = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
5144
5208
|
}
|
|
5145
5209
|
};
|
|
5146
5210
|
const selectHighlightedItem = e => {
|
|
5211
|
+
var _option$handleSelect;
|
|
5147
5212
|
const option = options[highlightedIndex];
|
|
5148
|
-
option
|
|
5213
|
+
option === null || option === void 0 || (_option$handleSelect = option.handleSelect) === null || _option$handleSelect === void 0 ? void 0 : _option$handleSelect.call(option, e);
|
|
5149
5214
|
};
|
|
5150
5215
|
useClickOutside([buttonRef, listRef], handleClose);
|
|
5151
5216
|
React.useEffect(() => {
|
|
@@ -5165,9 +5230,10 @@ const Dropdown = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
5165
5230
|
return valueArray;
|
|
5166
5231
|
});
|
|
5167
5232
|
} else {
|
|
5233
|
+
var _buttonRef$current;
|
|
5168
5234
|
setValue(newValue);
|
|
5169
5235
|
handleClose();
|
|
5170
|
-
buttonRef.current
|
|
5236
|
+
(_buttonRef$current = buttonRef.current) === null || _buttonRef$current === void 0 ? void 0 : _buttonRef$current.focus();
|
|
5171
5237
|
}
|
|
5172
5238
|
}, [isMultiSelect, handleClose, setValue]);
|
|
5173
5239
|
const onKeyDownButton = e => {
|
|
@@ -5206,6 +5272,7 @@ const Dropdown = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
5206
5272
|
}
|
|
5207
5273
|
};
|
|
5208
5274
|
const onKeyDownList = e => {
|
|
5275
|
+
var _buttonRef$current2, _buttonRef$current3;
|
|
5209
5276
|
let newHighlightedIndex;
|
|
5210
5277
|
if (disabled) return;
|
|
5211
5278
|
switch (e.key) {
|
|
@@ -5246,12 +5313,12 @@ const Dropdown = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
5246
5313
|
// close, focus button, and don't let event bubble up
|
|
5247
5314
|
e.stopPropagation();
|
|
5248
5315
|
handleClose();
|
|
5249
|
-
buttonRef.current
|
|
5316
|
+
(_buttonRef$current2 = buttonRef.current) === null || _buttonRef$current2 === void 0 ? void 0 : _buttonRef$current2.focus();
|
|
5250
5317
|
break;
|
|
5251
5318
|
case 'Tab':
|
|
5252
5319
|
// close and focus next focusable element
|
|
5253
5320
|
handleClose();
|
|
5254
|
-
buttonRef.current
|
|
5321
|
+
(_buttonRef$current3 = buttonRef.current) === null || _buttonRef$current3 === void 0 ? void 0 : _buttonRef$current3.focus();
|
|
5255
5322
|
break;
|
|
5256
5323
|
case 'PageUp':
|
|
5257
5324
|
case 'Home':
|
|
@@ -5351,9 +5418,9 @@ const DropdownHeader = /*#__PURE__*/React__default["default"].forwardRef((_ref,
|
|
|
5351
5418
|
}, commonProps), children) : /*#__PURE__*/React__default["default"].createElement("div", commonProps, children));
|
|
5352
5419
|
});
|
|
5353
5420
|
|
|
5354
|
-
var css_248z$q = ".
|
|
5355
|
-
var styles$p = {"checkbox":"
|
|
5356
|
-
var stylesheet$q=".
|
|
5421
|
+
var css_248z$q = "._PR3X0{display:inline-flex;position:relative}._FG-uU,._PR3X0{cursor:pointer;height:16px;width:16px}._FG-uU{position:absolute;opacity:0;z-index:10}._FG-uU._zGRpQ~._m-oFI>._233GL{fill-opacity:1}._FG-uU._zGRpQ~._m-oFI{border-color:transparent;background-color:#0b6ed0}._FG-uU._zGRpQ~._m-oFI>._233GL{fill:#fff}._FG-uU._zGRpQ:hover~._m-oFI{background-color:#085caf}._FG-uU:not(._zGRpQ):hover~._m-oFI{border-color:#0b6ed0}._FG-uU._3YmLr{cursor:not-allowed}._FG-uU._3YmLr~._m-oFI{opacity:.4}._m-oFI{display:flex;align-items:center;justify-content:center;position:absolute;top:0;left:0;height:16px;width:16px;background-color:#fff;border-radius:4px;border:1px solid #898989;z-index:0}._233GL{fill:#0b6ed0;fill-opacity:0}";
|
|
5422
|
+
var styles$p = {"checkbox":"_PR3X0","input":"_FG-uU","checked":"_zGRpQ","check":"_m-oFI","checkIcon":"_233GL","disabled":"_3YmLr"};
|
|
5423
|
+
var stylesheet$q="._PR3X0{display:inline-flex;position:relative}._FG-uU,._PR3X0{cursor:pointer;height:16px;width:16px}._FG-uU{position:absolute;opacity:0;z-index:10}._FG-uU._zGRpQ~._m-oFI>._233GL{fill-opacity:1}._FG-uU._zGRpQ~._m-oFI{border-color:transparent;background-color:#0b6ed0}._FG-uU._zGRpQ~._m-oFI>._233GL{fill:#fff}._FG-uU._zGRpQ:hover~._m-oFI{background-color:#085caf}._FG-uU:not(._zGRpQ):hover~._m-oFI{border-color:#0b6ed0}._FG-uU._3YmLr{cursor:not-allowed}._FG-uU._3YmLr~._m-oFI{opacity:.4}._m-oFI{display:flex;align-items:center;justify-content:center;position:absolute;top:0;left:0;height:16px;width:16px;background-color:#fff;border-radius:4px;border:1px solid #898989;z-index:0}._233GL{fill:#0b6ed0;fill-opacity:0}";
|
|
5357
5424
|
icons_index.styleInject(css_248z$q);
|
|
5358
5425
|
|
|
5359
5426
|
// Internal only component, used with Dropdown and SelectMenu multiselects.
|
|
@@ -5411,12 +5478,9 @@ const DropdownOption = /*#__PURE__*/React__default["default"].forwardRef((_ref,
|
|
|
5411
5478
|
const {
|
|
5412
5479
|
setVisibleChildIds
|
|
5413
5480
|
} = useDropdownHeaderContext();
|
|
5414
|
-
const isVisible = React.useMemo(() =>
|
|
5415
|
-
var _context;
|
|
5416
|
-
return isSearchFilteringDisabled || !label || !searchValue || typeof label === 'string' && _includesInstanceProperty__default["default"](_context = label.toLowerCase()).call(_context, searchValue.toLowerCase());
|
|
5417
|
-
}, [isSearchFilteringDisabled, label, searchValue]);
|
|
5481
|
+
const isVisible = React.useMemo(() => isSearchFilteringDisabled || !label || !searchValue || typeof label === 'string' && label.toLowerCase().includes(searchValue.toLowerCase()), [isSearchFilteringDisabled, label, searchValue]);
|
|
5418
5482
|
React.useEffect(() => {
|
|
5419
|
-
setVisibleChildIds
|
|
5483
|
+
setVisibleChildIds === null || setVisibleChildIds === void 0 ? void 0 : setVisibleChildIds(visibleChildIds => {
|
|
5420
5484
|
const duplicateSet = new Set(visibleChildIds);
|
|
5421
5485
|
if (isVisible) {
|
|
5422
5486
|
return duplicateSet.add(value);
|
|
@@ -5425,7 +5489,7 @@ const DropdownOption = /*#__PURE__*/React__default["default"].forwardRef((_ref,
|
|
|
5425
5489
|
return duplicateSet;
|
|
5426
5490
|
});
|
|
5427
5491
|
}, [setVisibleChildIds, isVisible, value]);
|
|
5428
|
-
const isSelected = Array.isArray(selectedValue) ?
|
|
5492
|
+
const isSelected = Array.isArray(selectedValue) ? selectedValue.includes(value) : value === selectedValue;
|
|
5429
5493
|
const handleSelect = React.useCallback(e => {
|
|
5430
5494
|
if (!disabled) {
|
|
5431
5495
|
const handler = wrapEvent(onSelect, () => onOptionSelected(value));
|
|
@@ -5443,7 +5507,8 @@ const DropdownOption = /*#__PURE__*/React__default["default"].forwardRef((_ref,
|
|
|
5443
5507
|
const isHighlighted = highlightedIndex === myIndex && myIndex !== -1;
|
|
5444
5508
|
React.useEffect(() => {
|
|
5445
5509
|
if (isHighlighted) {
|
|
5446
|
-
|
|
5510
|
+
var _listRef$current, _listRef$current2, _internalRef$current;
|
|
5511
|
+
if (isOpen && internalRef !== null && internalRef !== void 0 && internalRef.current && listRef !== null && listRef !== void 0 && listRef.current && ((_listRef$current = listRef.current) === null || _listRef$current === void 0 ? void 0 : _listRef$current.scrollHeight) > ((_listRef$current2 = listRef.current) === null || _listRef$current2 === void 0 ? void 0 : _listRef$current2.clientHeight)) {
|
|
5447
5512
|
const scrollBottom = listRef.current.clientHeight + listRef.current.scrollTop;
|
|
5448
5513
|
const elementBottom = internalRef.current.offsetTop + internalRef.current.offsetHeight;
|
|
5449
5514
|
if (elementBottom > scrollBottom) {
|
|
@@ -5452,7 +5517,7 @@ const DropdownOption = /*#__PURE__*/React__default["default"].forwardRef((_ref,
|
|
|
5452
5517
|
listRef.current.scrollTop = internalRef.current.offsetTop - (isSearchable ? searchHeight : 0);
|
|
5453
5518
|
}
|
|
5454
5519
|
}
|
|
5455
|
-
internalRef.current
|
|
5520
|
+
(_internalRef$current = internalRef.current) === null || _internalRef$current === void 0 ? void 0 : _internalRef$current.focus({
|
|
5456
5521
|
preventScroll: true
|
|
5457
5522
|
});
|
|
5458
5523
|
}
|
|
@@ -5481,9 +5546,9 @@ const DropdownOption = /*#__PURE__*/React__default["default"].forwardRef((_ref,
|
|
|
5481
5546
|
});
|
|
5482
5547
|
});
|
|
5483
5548
|
|
|
5484
|
-
var css_248z$p = ".
|
|
5485
|
-
var filePickerStyles = {"container":"
|
|
5486
|
-
var stylesheet$p=".
|
|
5549
|
+
var css_248z$p = "._xfGJ4{position:relative}._xfGJ4[focus-within] button{outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._xfGJ4:focus-within button{outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._W0iEY{opacity:0;position:absolute;height:36px;width:100%;left:0;z-index:-1}._Gx29b{margin-left:16px;font-size:14px;color:#32363a}._Gx29b ._rB3uq{margin-right:16px}";
|
|
5550
|
+
var filePickerStyles = {"container":"_xfGJ4","fileInput":"_W0iEY","fileDetails":"_Gx29b","fileName":"_rB3uq"};
|
|
5551
|
+
var stylesheet$p="._xfGJ4{position:relative}._xfGJ4[focus-within] button{outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._xfGJ4:focus-within button{outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._W0iEY{opacity:0;position:absolute;height:36px;width:100%;left:0;z-index:-1}._Gx29b{margin-left:16px;font-size:14px;color:#32363a}._Gx29b ._rB3uq{margin-right:16px}";
|
|
5487
5552
|
icons_index.styleInject(css_248z$p);
|
|
5488
5553
|
|
|
5489
5554
|
const FileDetails = _ref => {
|
|
@@ -5521,8 +5586,8 @@ const FilePicker = /*#__PURE__*/React__default["default"].forwardRef((_ref2, ref
|
|
|
5521
5586
|
const [filesChanged, setFilesChanged] = React.useState(false);
|
|
5522
5587
|
const [files, setFiles] = useControllableState(undefined, undefined, externalFiles);
|
|
5523
5588
|
const fileInputId = useId(externalId);
|
|
5524
|
-
const fileDetailsId =
|
|
5525
|
-
const buttonId =
|
|
5589
|
+
const fileDetailsId = "".concat(fileInputId, "-fileDetails");
|
|
5590
|
+
const buttonId = "".concat(fileInputId, "-button");
|
|
5526
5591
|
const fileInputRef = React.useRef(null);
|
|
5527
5592
|
const buttonRef = React.useRef(null);
|
|
5528
5593
|
|
|
@@ -5534,12 +5599,13 @@ const FilePicker = /*#__PURE__*/React__default["default"].forwardRef((_ref2, ref
|
|
|
5534
5599
|
|
|
5535
5600
|
// returns focus to input after closing system dialog
|
|
5536
5601
|
useDidUpdate(() => {
|
|
5537
|
-
|
|
5602
|
+
var _fileInputRef$current;
|
|
5603
|
+
(_fileInputRef$current = fileInputRef.current) === null || _fileInputRef$current === void 0 ? void 0 : _fileInputRef$current.focus();
|
|
5538
5604
|
}, [filesChanged]);
|
|
5539
5605
|
const internalAriaDescribedby = concatIds(externalAriaDescribedBy, formFieldHelperTextId, formFieldErrorTextId);
|
|
5540
5606
|
const handleChange = e => {
|
|
5541
5607
|
setFiles(e.target.files, e);
|
|
5542
|
-
onChange
|
|
5608
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(e);
|
|
5543
5609
|
// This is needed due to CFE-508
|
|
5544
5610
|
setFilesChanged(val => !val);
|
|
5545
5611
|
};
|
|
@@ -5557,10 +5623,16 @@ const FilePicker = /*#__PURE__*/React__default["default"].forwardRef((_ref2, ref
|
|
|
5557
5623
|
}, /*#__PURE__*/React__default["default"].createElement(Button, {
|
|
5558
5624
|
disabled: disabled,
|
|
5559
5625
|
kind: "secondary",
|
|
5560
|
-
onClick: () =>
|
|
5626
|
+
onClick: () => {
|
|
5627
|
+
var _fileInputRef$current2;
|
|
5628
|
+
return (_fileInputRef$current2 = fileInputRef.current) === null || _fileInputRef$current2 === void 0 ? void 0 : _fileInputRef$current2.click();
|
|
5629
|
+
},
|
|
5561
5630
|
tabIndex: -1,
|
|
5562
5631
|
ref: buttonRef,
|
|
5563
|
-
onFocus: () =>
|
|
5632
|
+
onFocus: () => {
|
|
5633
|
+
var _fileInputRef$current3;
|
|
5634
|
+
return (_fileInputRef$current3 = fileInputRef.current) === null || _fileInputRef$current3 === void 0 ? void 0 : _fileInputRef$current3.focus();
|
|
5635
|
+
},
|
|
5564
5636
|
id: buttonId,
|
|
5565
5637
|
"aria-hidden": true
|
|
5566
5638
|
}, buttonLabel), /*#__PURE__*/React__default["default"].createElement("input", _extends__default["default"]({}, rest, {
|
|
@@ -5581,14 +5653,14 @@ const FilePicker = /*#__PURE__*/React__default["default"].forwardRef((_ref2, ref
|
|
|
5581
5653
|
}));
|
|
5582
5654
|
});
|
|
5583
5655
|
|
|
5584
|
-
var css_248z$o = ".
|
|
5585
|
-
var styles$o = {"formField":"
|
|
5586
|
-
var stylesheet$o=".
|
|
5656
|
+
var css_248z$o = "._PyakO{display:flex;flex-direction:column;align-items:flex-start}._cIThr{margin-top:6px;max-width:100%}._cIThr *+*{margin-top:4px}";
|
|
5657
|
+
var styles$o = {"formField":"_PyakO","captionContainer":"_cIThr"};
|
|
5658
|
+
var stylesheet$o="._PyakO{display:flex;flex-direction:column;align-items:flex-start}._cIThr{margin-top:6px;max-width:100%}._cIThr *+*{margin-top:4px}";
|
|
5587
5659
|
icons_index.styleInject(css_248z$o);
|
|
5588
5660
|
|
|
5589
|
-
var css_248z$n = ".
|
|
5590
|
-
var styles$n = {"caption":"
|
|
5591
|
-
var stylesheet$n=".
|
|
5661
|
+
var css_248z$n = "._DWn8p{display:flex;align-items:center;font-size:12px;line-height:16px;min-height:16px}._-L-ZS{color:#74777a;fill:#74777a}._EHEpy{color:#b00;fill:#b00}._2nEI3,._M7aMP{margin-left:-2px;margin-right:3px}";
|
|
5662
|
+
var styles$n = {"caption":"_DWn8p","helperText":"_-L-ZS","errorText":"_EHEpy","errorIcon":"_M7aMP","readOnlyIcon":"_2nEI3"};
|
|
5663
|
+
var stylesheet$n="._DWn8p{display:flex;align-items:center;font-size:12px;line-height:16px;min-height:16px}._-L-ZS{color:#74777a;fill:#74777a}._EHEpy{color:#b00;fill:#b00}._2nEI3,._M7aMP{margin-left:-2px;margin-right:3px}";
|
|
5592
5664
|
icons_index.styleInject(css_248z$n);
|
|
5593
5665
|
|
|
5594
5666
|
const HelperText = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
@@ -5655,8 +5727,8 @@ const FormField = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref)
|
|
|
5655
5727
|
const [hasLabel, setHasLabel] = React.useState(false);
|
|
5656
5728
|
const [formFieldType, setFormFieldType] = React.useState('');
|
|
5657
5729
|
const containerId = useId(externalId);
|
|
5658
|
-
const helperTextId = helperText ?
|
|
5659
|
-
const errorTextId = errorText ?
|
|
5730
|
+
const helperTextId = helperText ? "".concat(containerId, "-helper-text") : undefined;
|
|
5731
|
+
const errorTextId = errorText ? "".concat(containerId, "-error-text") : undefined;
|
|
5660
5732
|
return /*#__PURE__*/React__default["default"].createElement("div", _extends__default["default"]({}, rest, {
|
|
5661
5733
|
ref: mergeRefs(ref, focusRef),
|
|
5662
5734
|
className: classNames__default["default"](className, {
|
|
@@ -5687,9 +5759,9 @@ const FormField = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref)
|
|
|
5687
5759
|
}, errorText)) : null);
|
|
5688
5760
|
});
|
|
5689
5761
|
|
|
5690
|
-
var css_248z$m = ".
|
|
5691
|
-
var styles$m = {"dialog":"
|
|
5692
|
-
var stylesheet$m=".
|
|
5762
|
+
var css_248z$m = "._ox5vY{position:fixed;left:0;top:0;width:100vw;height:100vh;background-color:#fff;overflow:auto}@keyframes _QBFda{0%{transform:scale3d(.7,.7,.7);opacity:0}}._irDJp{animation:_QBFda both;animation-duration:.2s}@keyframes _LAwbO{to{transform:scale3d(.7,.7,.7);opacity:0}}._bkCOe{animation:_LAwbO both;animation-duration:.2s}";
|
|
5763
|
+
var styles$m = {"dialog":"_ox5vY","transitionIn":"_irDJp","showAnimation":"_QBFda","transitionOut":"_bkCOe","hideAnimation":"_LAwbO"};
|
|
5764
|
+
var stylesheet$m="._ox5vY{position:fixed;left:0;top:0;width:100vw;height:100vh;background-color:#fff;overflow:auto}@keyframes _QBFda{0%{transform:scale3d(.7,.7,.7);opacity:0}}._irDJp{animation:_QBFda both;animation-duration:.2s}@keyframes _LAwbO{to{transform:scale3d(.7,.7,.7);opacity:0}}._bkCOe{animation:_LAwbO both;animation-duration:.2s}";
|
|
5693
5765
|
icons_index.styleInject(css_248z$m);
|
|
5694
5766
|
|
|
5695
5767
|
const FullScreenTakeover = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
@@ -5722,14 +5794,16 @@ const FullScreenTakeover = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
5722
5794
|
React.useEffect(() => {
|
|
5723
5795
|
// If `focusedElementWhenDialogOpened` has been set, then we know that the element has been opened at least once. Without this check, the component will focus `elementRefToFocusOnClose` on page load.
|
|
5724
5796
|
if (!isInDOM && focusedElementWhenDialogOpened) {
|
|
5725
|
-
|
|
5726
|
-
elementToFocus
|
|
5797
|
+
var _elementRefToFocusOnC;
|
|
5798
|
+
const elementToFocus = (_elementRefToFocusOnC = elementRefToFocusOnClose === null || elementRefToFocusOnClose === void 0 ? void 0 : elementRefToFocusOnClose.current) !== null && _elementRefToFocusOnC !== void 0 ? _elementRefToFocusOnC : focusedElementWhenDialogOpened;
|
|
5799
|
+
elementToFocus === null || elementToFocus === void 0 ? void 0 : elementToFocus.focus();
|
|
5727
5800
|
}
|
|
5728
5801
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
5729
5802
|
}, [isInDOM, focusedElementWhenDialogOpened]);
|
|
5730
5803
|
const handleAnimationEnd = () => {
|
|
5731
5804
|
if (isOpen) {
|
|
5732
|
-
|
|
5805
|
+
var _ref2, _elementRefToFocusOnO;
|
|
5806
|
+
(_ref2 = (_elementRefToFocusOnO = elementRefToFocusOnOpen === null || elementRefToFocusOnOpen === void 0 ? void 0 : elementRefToFocusOnOpen.current) !== null && _elementRefToFocusOnO !== void 0 ? _elementRefToFocusOnO : dialogRef === null || dialogRef === void 0 ? void 0 : dialogRef.current) === null || _ref2 === void 0 ? void 0 : _ref2.focus();
|
|
5733
5807
|
} else {
|
|
5734
5808
|
setIsInDOM(false);
|
|
5735
5809
|
}
|
|
@@ -5772,7 +5846,7 @@ const deprecated = {
|
|
|
5772
5846
|
function deprecationWarning(type) {
|
|
5773
5847
|
if (deprecated[type]) {
|
|
5774
5848
|
// eslint-disable-next-line no-console
|
|
5775
|
-
console.warn(
|
|
5849
|
+
console.warn("\"IconTypes.".concat(type, "\" has been deprecated! Use \"IconTypes.").concat(deprecated[type], "\" instead."));
|
|
5776
5850
|
}
|
|
5777
5851
|
}
|
|
5778
5852
|
const Icon = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
@@ -5782,7 +5856,7 @@ const Icon = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
|
5782
5856
|
...rest
|
|
5783
5857
|
} = _ref;
|
|
5784
5858
|
// eslint-disable-next-line no-console
|
|
5785
|
-
console.warn(
|
|
5859
|
+
console.warn("<Icon> component is deprecated! Use individual icon components from the @qualtrics/ui-react/icons import path instead", type);
|
|
5786
5860
|
deprecationWarning(type);
|
|
5787
5861
|
const svgContent = componentStyles.IconData[deprecated[type] || type];
|
|
5788
5862
|
const pixels = IconSizes[size];
|
|
@@ -6270,9 +6344,9 @@ var IconTypes = {
|
|
|
6270
6344
|
WorkingFromHome: 'WorkingFromHome'
|
|
6271
6345
|
};
|
|
6272
6346
|
|
|
6273
|
-
var css_248z$l = ".
|
|
6274
|
-
var styles$l = {"container":"
|
|
6275
|
-
var stylesheet$l=".
|
|
6347
|
+
var css_248z$l = "._vJ1Cu{display:inline-block}._pfxbp{color:#085caf;cursor:pointer;font-size:14px;box-sizing:border-box;padding:4px;margin:-5px;outline:0;border:1px solid transparent;border-radius:4px;background-clip:padding-box;display:block}._pfxbp::-moz-selection{background-color:rgba(11,110,208,.11)}._pfxbp::selection{background-color:rgba(11,110,208,.11)}._pfxbp:focus,._pfxbp:hover{background-color:#f5f5f5}._pfxbp:focus{border:2px solid #0a3f88;padding:3px}._pfxbp:focus._uVKuJ{background-color:#fafafa;cursor:text;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 1px 8px hsla(0,0%,66.7%,.5)}";
|
|
6348
|
+
var styles$l = {"container":"_vJ1Cu","inlineInput":"_pfxbp","isEditing":"_uVKuJ"};
|
|
6349
|
+
var stylesheet$l="._vJ1Cu{display:inline-block}._pfxbp{color:#085caf;cursor:pointer;font-size:14px;box-sizing:border-box;padding:4px;margin:-5px;outline:0;border:1px solid transparent;border-radius:4px;background-clip:padding-box;display:block}._pfxbp::-moz-selection{background-color:rgba(11,110,208,.11)}._pfxbp::selection{background-color:rgba(11,110,208,.11)}._pfxbp:focus,._pfxbp:hover{background-color:#f5f5f5}._pfxbp:focus{border:2px solid #0a3f88;padding:3px}._pfxbp:focus._uVKuJ{background-color:#fafafa;cursor:text;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 1px 8px hsla(0,0%,66.7%,.5)}";
|
|
6276
6350
|
icons_index.styleInject(css_248z$l);
|
|
6277
6351
|
|
|
6278
6352
|
const InlineInput = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
@@ -6297,19 +6371,19 @@ const InlineInput = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
6297
6371
|
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
6298
6372
|
// @ts-ignore: Property 'value' does not exist on type 'HTMLSpanElement'
|
|
6299
6373
|
e.target.value = newVal;
|
|
6300
|
-
onChange
|
|
6374
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(e);
|
|
6301
6375
|
setLastVal(newVal);
|
|
6302
6376
|
}
|
|
6303
6377
|
});
|
|
6304
6378
|
const handleBlur = e => {
|
|
6305
6379
|
setIsEditing(false);
|
|
6306
6380
|
e.target.value = e.target.innerText;
|
|
6307
|
-
onBlur
|
|
6381
|
+
onBlur === null || onBlur === void 0 ? void 0 : onBlur(e);
|
|
6308
6382
|
};
|
|
6309
6383
|
const handleFocus = e => {
|
|
6310
6384
|
setIsEditing(true);
|
|
6311
6385
|
e.target.value = e.target.innerText;
|
|
6312
|
-
onFocus
|
|
6386
|
+
onFocus === null || onFocus === void 0 ? void 0 : onFocus(e);
|
|
6313
6387
|
};
|
|
6314
6388
|
const handleKeyDown = e => {
|
|
6315
6389
|
if (e.key === 'Enter') {
|
|
@@ -6320,13 +6394,13 @@ const InlineInput = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
6320
6394
|
e.stopPropagation(); // prevent event from closing modals or popovers
|
|
6321
6395
|
setIsEditing(false);
|
|
6322
6396
|
}
|
|
6323
|
-
onKeyDown
|
|
6397
|
+
onKeyDown === null || onKeyDown === void 0 ? void 0 : onKeyDown(e);
|
|
6324
6398
|
};
|
|
6325
6399
|
const handleMouseDown = e => {
|
|
6326
6400
|
if (isFocused) {
|
|
6327
6401
|
setIsEditing(true);
|
|
6328
6402
|
}
|
|
6329
|
-
onMouseDown
|
|
6403
|
+
onMouseDown === null || onMouseDown === void 0 ? void 0 : onMouseDown(e);
|
|
6330
6404
|
};
|
|
6331
6405
|
const handlePaste = e => {
|
|
6332
6406
|
// Strip formatting and newlines from pasted data
|
|
@@ -6334,7 +6408,7 @@ const InlineInput = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
6334
6408
|
e.preventDefault(); // prevent paste and manually insert text after stripping formatting
|
|
6335
6409
|
const text = e.clipboardData.getData('text').replace(/[\n\r]/g, ' ');
|
|
6336
6410
|
const selection = window.getSelection();
|
|
6337
|
-
const range = selection
|
|
6411
|
+
const range = selection === null || selection === void 0 ? void 0 : selection.getRangeAt(0);
|
|
6338
6412
|
if (range && selection) {
|
|
6339
6413
|
range.deleteContents();
|
|
6340
6414
|
const textNode = document.createTextNode(text);
|
|
@@ -6349,13 +6423,16 @@ const InlineInput = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
6349
6423
|
};
|
|
6350
6424
|
useDidUpdate(() => {
|
|
6351
6425
|
if (typeof window !== 'undefined') {
|
|
6426
|
+
var _window$getSelection2;
|
|
6352
6427
|
if (isEditing && isFocused && internalRef.current) {
|
|
6353
|
-
|
|
6428
|
+
var _window$getSelection;
|
|
6429
|
+
(_window$getSelection = window.getSelection()) === null || _window$getSelection === void 0 ? void 0 : _window$getSelection.selectAllChildren(internalRef.current);
|
|
6354
6430
|
}
|
|
6355
6431
|
// Clear window selection only if it is on the InlineInput. Without this check, we would mistakenly clear the
|
|
6356
6432
|
// selection after focus moves from this component to an Input or another component that sets the window selection.
|
|
6357
|
-
else if (internalRef.current && window.getSelection()
|
|
6358
|
-
|
|
6433
|
+
else if (internalRef.current && (_window$getSelection2 = window.getSelection()) !== null && _window$getSelection2 !== void 0 && _window$getSelection2.containsNode(internalRef.current, true)) {
|
|
6434
|
+
var _window$getSelection3;
|
|
6435
|
+
(_window$getSelection3 = window.getSelection()) === null || _window$getSelection3 === void 0 ? void 0 : _window$getSelection3.removeAllRanges();
|
|
6359
6436
|
}
|
|
6360
6437
|
}
|
|
6361
6438
|
}, [isEditing, isFocused]);
|
|
@@ -6390,9 +6467,9 @@ const InlineInput = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
6390
6467
|
}), defaultValue));
|
|
6391
6468
|
});
|
|
6392
6469
|
|
|
6393
|
-
var css_248z$k = ".
|
|
6394
|
-
var styles$k = {"addon":"
|
|
6395
|
-
var stylesheet$k=".
|
|
6470
|
+
var css_248z$k = "._1mtQX{border:1px solid #898989;border-radius:4px;height:36px;min-height:36px;color:#6a6d70;fill:#6a6d70;background-color:#fafafa;font-size:14px;display:inline-flex;justify-content:center;align-items:center;line-height:1;padding:0 13px}._1mtQX._dTgZc{height:26px;min-height:26px;padding:5px 8px}._qj0VK{display:flex;align-items:stretch}._qj0VK._NRjNC{width:100%}._qj0VK ._mhaVA{margin:0;position:relative;flex-shrink:0;z-index:10}._qj0VK ._mhaVA:first-child{margin:0 -1px 0 0;border-top-left-radius:4px;border-bottom-left-radius:4px;border-top-right-radius:0;border-bottom-right-radius:0}._qj0VK ._mhaVA:not(:last-child):not(:first-child){margin:0 -1px 0 0;border-radius:0}._qj0VK ._mhaVA:last-child{border-top-left-radius:0;border-bottom-left-radius:0}._qj0VK ._mhaVA:last-child,._qj0VK ._mhaVA:only-child{margin:0;border-top-right-radius:4px;border-bottom-right-radius:4px}._qj0VK ._mhaVA:only-child{border-top-left-radius:4px;border-bottom-left-radius:4px}._qj0VK ._mhaVA._6L0m5{flex-shrink:1;min-width:40px;z-index:0}._qj0VK ._mhaVA._6L0m5._NRjNC{flex-grow:1}._qj0VK ._mhaVA:focus{z-index:20}";
|
|
6471
|
+
var styles$k = {"addon":"_1mtQX","small":"_dTgZc","inputGroup":"_qj0VK","full":"_NRjNC","inputGroupElement":"_mhaVA","input":"_6L0m5"};
|
|
6472
|
+
var stylesheet$k="._1mtQX{border:1px solid #898989;border-radius:4px;height:36px;min-height:36px;color:#6a6d70;fill:#6a6d70;background-color:#fafafa;font-size:14px;display:inline-flex;justify-content:center;align-items:center;line-height:1;padding:0 13px}._1mtQX._dTgZc{height:26px;min-height:26px;padding:5px 8px}._qj0VK{display:flex;align-items:stretch}._qj0VK._NRjNC{width:100%}._qj0VK ._mhaVA{margin:0;position:relative;flex-shrink:0;z-index:10}._qj0VK ._mhaVA:first-child{margin:0 -1px 0 0;border-top-left-radius:4px;border-bottom-left-radius:4px;border-top-right-radius:0;border-bottom-right-radius:0}._qj0VK ._mhaVA:not(:last-child):not(:first-child){margin:0 -1px 0 0;border-radius:0}._qj0VK ._mhaVA:last-child{border-top-left-radius:0;border-bottom-left-radius:0}._qj0VK ._mhaVA:last-child,._qj0VK ._mhaVA:only-child{margin:0;border-top-right-radius:4px;border-bottom-right-radius:4px}._qj0VK ._mhaVA:only-child{border-top-left-radius:4px;border-bottom-left-radius:4px}._qj0VK ._mhaVA._6L0m5{flex-shrink:1;min-width:40px;z-index:0}._qj0VK ._mhaVA._6L0m5._NRjNC{flex-grow:1}._qj0VK ._mhaVA:focus{z-index:20}";
|
|
6396
6473
|
icons_index.styleInject(css_248z$k);
|
|
6397
6474
|
|
|
6398
6475
|
const InputGroup = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
@@ -6437,9 +6514,9 @@ const InputGroupAddon = /*#__PURE__*/React__default["default"].forwardRef((_ref,
|
|
|
6437
6514
|
}), children);
|
|
6438
6515
|
});
|
|
6439
6516
|
|
|
6440
|
-
var css_248z$j = ".
|
|
6441
|
-
var styles$j = {"link":"
|
|
6442
|
-
var stylesheet$j=".
|
|
6517
|
+
var css_248z$j = "._7y-QP{color:#0b6ed0;cursor:pointer;text-decoration:underline;text-decoration-thickness:1px;-webkit-text-decoration-skip:ink;text-decoration-skip-ink:auto;text-underline-offset:3px;border-radius:1px}._7y-QP:active:focus,._7y-QP:focus{outline:none}._7y-QP:visited{color:#0854a1}._7y-QP:hover{color:#085caf}._7y-QP:active{color:#0854a1}._7y-QP.focus-visible,._7y-QP:focus-visible{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
6518
|
+
var styles$j = {"link":"_7y-QP"};
|
|
6519
|
+
var stylesheet$j="._7y-QP{color:#0b6ed0;cursor:pointer;text-decoration:underline;text-decoration-thickness:1px;-webkit-text-decoration-skip:ink;text-decoration-skip-ink:auto;text-underline-offset:3px;border-radius:1px}._7y-QP:active:focus,._7y-QP:focus{outline:none}._7y-QP:visited{color:#0854a1}._7y-QP:hover{color:#085caf}._7y-QP:active{color:#0854a1}._7y-QP.focus-visible,._7y-QP:focus-visible{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
6443
6520
|
icons_index.styleInject(css_248z$j);
|
|
6444
6521
|
|
|
6445
6522
|
const Link = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
@@ -6461,9 +6538,9 @@ const Link = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
|
6461
6538
|
}), children);
|
|
6462
6539
|
});
|
|
6463
6540
|
|
|
6464
|
-
var css_248z$i = ".
|
|
6465
|
-
var styles$i = {"set":"
|
|
6466
|
-
var stylesheet$i=".
|
|
6541
|
+
var css_248z$i = "._iGozK{width:100%}._TZ4ly{display:flex;align-items:center}._lFiuN{display:flex;flex-wrap:wrap;grid-gap:4px}._lFiuN :nth-last-child(2){margin-right:42px}._8MBRW{position:relative;padding-left:32px;padding-top:16px;display:flex}._b3X1x ._8MBRW{padding-top:0;padding-left:16px}._b3X1x ._8MBRW+._8MBRW{margin-top:16px}._2-fxu{position:absolute;left:16px;top:0;height:34px;width:16px;border-left:1px solid #c2c2c2;border-bottom:1px solid #c2c2c2;border-bottom-left-radius:4px}._b3X1x ._8MBRW:first-of-type ._2-fxu{top:16px;border-bottom:none;border-bottom-left-radius:0;border-top:1px solid #c2c2c2;border-top-left-radius:4px}._b3X1x ._2-fxu{top:-16px;left:0}._b3X1x ._8MBRW:not(:first-of-type):not(:last-of-type) ._2-fxu{border-bottom-left-radius:0}._NPKGZ{margin-left:-46px}._XDdiV{margin:0 2px 0 4px}._XDdiV.focus-visible,._XDdiV:focus-visible{outline-width:2px}._2kFey{margin-left:4px}";
|
|
6542
|
+
var styles$i = {"set":"_iGozK","setWrapper":"_TZ4ly","condition":"_lFiuN","branch":"_8MBRW","fixedSet":"_b3X1x","connection":"_2-fxu","conditionControlsContainer":"_NPKGZ","controls":"_XDdiV","controlMenuItem":"_2kFey"};
|
|
6543
|
+
var stylesheet$i="._iGozK{width:100%}._TZ4ly{display:flex;align-items:center}._lFiuN{display:flex;flex-wrap:wrap;grid-gap:4px}._lFiuN :nth-last-child(2){margin-right:42px}._8MBRW{position:relative;padding-left:32px;padding-top:16px;display:flex}._b3X1x ._8MBRW{padding-top:0;padding-left:16px}._b3X1x ._8MBRW+._8MBRW{margin-top:16px}._2-fxu{position:absolute;left:16px;top:0;height:34px;width:16px;border-left:1px solid #c2c2c2;border-bottom:1px solid #c2c2c2;border-bottom-left-radius:4px}._b3X1x ._8MBRW:first-of-type ._2-fxu{top:16px;border-bottom:none;border-bottom-left-radius:0;border-top:1px solid #c2c2c2;border-top-left-radius:4px}._b3X1x ._2-fxu{top:-16px;left:0}._b3X1x ._8MBRW:not(:first-of-type):not(:last-of-type) ._2-fxu{border-bottom-left-radius:0}._NPKGZ{margin-left:-46px}._XDdiV{margin:0 2px 0 4px}._XDdiV.focus-visible,._XDdiV:focus-visible{outline-width:2px}._2kFey{margin-left:4px}";
|
|
6467
6544
|
icons_index.styleInject(css_248z$i);
|
|
6468
6545
|
|
|
6469
6546
|
/* eslint-disable @typescript-eslint/no-use-before-define */
|
|
@@ -6494,7 +6571,8 @@ function constructValidDefaultState(_ref) {
|
|
|
6494
6571
|
return clone;
|
|
6495
6572
|
}
|
|
6496
6573
|
function fixedSetHasNoConditions(defaultValue, fixedSet) {
|
|
6497
|
-
|
|
6574
|
+
var _defaultValue$conditi;
|
|
6575
|
+
return fixedSet && defaultValue && (!(defaultValue !== null && defaultValue !== void 0 && defaultValue.conditions) || !((defaultValue === null || defaultValue === void 0 || (_defaultValue$conditi = defaultValue.conditions) === null || _defaultValue$conditi === void 0 ? void 0 : _defaultValue$conditi.length) >= 1));
|
|
6498
6576
|
}
|
|
6499
6577
|
function ensureFixedSetHasOneCondition(defaultValue, fixedSet) {
|
|
6500
6578
|
if (fixedSetHasNoConditions(defaultValue, fixedSet)) {
|
|
@@ -6636,9 +6714,9 @@ const ConditionContainer = function ConditionContainer(_ref) {
|
|
|
6636
6714
|
}), conditionControls);
|
|
6637
6715
|
};
|
|
6638
6716
|
|
|
6639
|
-
var css_248z$h = ".
|
|
6640
|
-
var styles$h = {"menuBtn":"
|
|
6641
|
-
var stylesheet$h=".
|
|
6717
|
+
var css_248z$h = "._-X5dV._-X5dV{min-width:0;max-width:100%;padding:0 4px 0 12px;white-space:nowrap;line-height:20px;font-size:14px;cursor:pointer;justify-content:space-between;text-align:left;outline:none;background-color:#fafafa;border:none;box-shadow:inset 0 0 0 1px #898989;border-radius:4px;height:36px;color:#515559;fill:#515559}._-X5dV._-X5dV,._-X5dV._-X5dV ._Hd8nM{display:inline-flex;align-items:center}._-X5dV._-X5dV ._Hd8nM{overflow:hidden;text-overflow:ellipsis}._-X5dV._-X5dV._k8ppd{min-height:26px;height:26px}._-X5dV._-X5dV._z1dcp{color:#32363a}._-X5dV._-X5dV:hover:not([aria-disabled=true]){background-color:#f5f5f5}._-X5dV._-X5dV:focus{background-color:#fafafa;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._-X5dV._-X5dV[aria-disabled=true]{box-shadow:inset 0 0 0 1px #e5e5e5;color:#74777a;cursor:not-allowed}._-X5dV._-X5dV[aria-disabled=true]>svg{fill:#515559;opacity:.4}._-X5dV._-X5dV[aria-disabled=true]:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._-X5dV._-X5dV._Ohktj{padding-left:0}._-X5dV._-X5dV._Tu3ND{margin-top:4px}._-X5dV._-X5dV ._rZzMy{fill:#515559}._-X5dV._-X5dV ._rZzMy._k8ppd{top:0}._-X5dV._-X5dV ._rZzMy._ZZNDf{transform:rotate(-180deg)}._z0ubf{margin:0;font-size:14px;color:#32363a;fill:#32363a;list-style:none;min-width:160px;max-width:350px;min-height:10px;max-height:99%;background:#fff;border:1px solid #eee;border-radius:4px;box-shadow:0 8px 20px rgba(0,0,0,.1),0 4px 6px rgba(0,0,0,.05);z-index:1000;overflow-x:hidden;overflow-y:auto;overflow:hidden auto}._z0ubf::-webkit-scrollbar,._z0ubf::-webkit-scrollbar-thumb{visibility:hidden;width:8px;border-radius:4px}._z0ubf::-webkit-scrollbar{background-color:rgba(0,0,0,.06)}._z0ubf::-webkit-scrollbar-thumb{background-color:rgba(0,0,0,.4)}._z0ubf:hover::-webkit-scrollbar,._z0ubf:hover::-webkit-scrollbar-thumb,._z0ubf[focus-within]::-webkit-scrollbar,._z0ubf[focus-within]::-webkit-scrollbar-thumb{visibility:visible}._z0ubf:focus-within::-webkit-scrollbar,._z0ubf:focus-within::-webkit-scrollbar-thumb,._z0ubf:hover::-webkit-scrollbar,._z0ubf:hover::-webkit-scrollbar-thumb{visibility:visible}._7XyRp{position:relative;padding:10px 12px;min-height:40px;display:flex;flex-direction:row;align-items:center;cursor:pointer;outline:none;word-break:break-word}._7XyRp[aria-disabled=true]{cursor:not-allowed;color:rgba(50,54,58,.65);fill:rgba(50,54,58,.65)}._7XyRp._lLmBE{background-color:#efefef}._7XyRp._VqvvX{box-shadow:inset 0 0 0 2px #0a3f88,inset 0 0 0 4px #fff;border-radius:6px}._7XyRp._z1dcp{background-color:#ebf3fb;font-weight:500;font-family:\"72Duplex\",\"72\",\"Helvetica Neue\",Helvetica,Arial,sans-serif}._7XyRp._z1dcp._lLmBE{background-color:#e4effa}._7XyRp._JIsXa{cursor:default}._7XyRp:active:not(._6D1JJ):not(._z1dcp):not([aria-disabled=true]):not(._JIsXa){background-color:#e8e9e9}._6D1JJ{padding-right:32px}._6D1JJ ._rZzMy{position:absolute;top:8px;right:3px;fill:#515559}._c5AR8{padding:8px;border-bottom:1px solid #e8e8e8;border-radius:4px 4px 0 0;position:-webkit-sticky;position:sticky;top:0;z-index:20;background-color:#fff}._btmT7{position:absolute;top:13px;left:13px}._5WOiA._5WOiA{padding-left:32px}._VZ9Zr{margin:2px 12px 2px 0;flex-shrink:0}._VZ9Zr._nLs1l>svg{border-color:#0b6ed0}._yo2jr{display:flex;justify-self:center;margin:8px}";
|
|
6718
|
+
var styles$h = {"menuBtn":"_-X5dV","menuBtnLabel":"_Hd8nM","small":"_k8ppd","selected":"_z1dcp","unlabelledButton":"_Ohktj","formLabelled":"_Tu3ND","rightIcon":"_rZzMy","open":"_ZZNDf","contentPane":"_z0ubf","menuItem":"_7XyRp","active":"_lLmBE","focus":"_VqvvX","noMenuItems":"_JIsXa","subMenu":"_6D1JJ","searchBox":"_c5AR8","searchBoxIcon":"_btmT7","searchBoxInput":"_5WOiA","checkbox":"_VZ9Zr","highlighted":"_nLs1l","menuSpinner":"_yo2jr"};
|
|
6719
|
+
var stylesheet$h="._-X5dV._-X5dV{min-width:0;max-width:100%;padding:0 4px 0 12px;white-space:nowrap;line-height:20px;font-size:14px;cursor:pointer;justify-content:space-between;text-align:left;outline:none;background-color:#fafafa;border:none;box-shadow:inset 0 0 0 1px #898989;border-radius:4px;height:36px;color:#515559;fill:#515559}._-X5dV._-X5dV,._-X5dV._-X5dV ._Hd8nM{display:inline-flex;align-items:center}._-X5dV._-X5dV ._Hd8nM{overflow:hidden;text-overflow:ellipsis}._-X5dV._-X5dV._k8ppd{min-height:26px;height:26px}._-X5dV._-X5dV._z1dcp{color:#32363a}._-X5dV._-X5dV:hover:not([aria-disabled=true]){background-color:#f5f5f5}._-X5dV._-X5dV:focus{background-color:#fafafa;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._-X5dV._-X5dV[aria-disabled=true]{box-shadow:inset 0 0 0 1px #e5e5e5;color:#74777a;cursor:not-allowed}._-X5dV._-X5dV[aria-disabled=true]>svg{fill:#515559;opacity:.4}._-X5dV._-X5dV[aria-disabled=true]:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._-X5dV._-X5dV._Ohktj{padding-left:0}._-X5dV._-X5dV._Tu3ND{margin-top:4px}._-X5dV._-X5dV ._rZzMy{fill:#515559}._-X5dV._-X5dV ._rZzMy._k8ppd{top:0}._-X5dV._-X5dV ._rZzMy._ZZNDf{transform:rotate(-180deg)}._z0ubf{margin:0;font-size:14px;color:#32363a;fill:#32363a;list-style:none;min-width:160px;max-width:350px;min-height:10px;max-height:99%;background:#fff;border:1px solid #eee;border-radius:4px;box-shadow:0 8px 20px rgba(0,0,0,.1),0 4px 6px rgba(0,0,0,.05);z-index:1000;overflow-x:hidden;overflow-y:auto;overflow:hidden auto}._z0ubf::-webkit-scrollbar,._z0ubf::-webkit-scrollbar-thumb{visibility:hidden;width:8px;border-radius:4px}._z0ubf::-webkit-scrollbar{background-color:rgba(0,0,0,.06)}._z0ubf::-webkit-scrollbar-thumb{background-color:rgba(0,0,0,.4)}._z0ubf:hover::-webkit-scrollbar,._z0ubf:hover::-webkit-scrollbar-thumb,._z0ubf[focus-within]::-webkit-scrollbar,._z0ubf[focus-within]::-webkit-scrollbar-thumb{visibility:visible}._z0ubf:focus-within::-webkit-scrollbar,._z0ubf:focus-within::-webkit-scrollbar-thumb,._z0ubf:hover::-webkit-scrollbar,._z0ubf:hover::-webkit-scrollbar-thumb{visibility:visible}._7XyRp{position:relative;padding:10px 12px;min-height:40px;display:flex;flex-direction:row;align-items:center;cursor:pointer;outline:none;word-break:break-word}._7XyRp[aria-disabled=true]{cursor:not-allowed;color:rgba(50,54,58,.65);fill:rgba(50,54,58,.65)}._7XyRp._lLmBE{background-color:#efefef}._7XyRp._VqvvX{box-shadow:inset 0 0 0 2px #0a3f88,inset 0 0 0 4px #fff;border-radius:6px}._7XyRp._z1dcp{background-color:#ebf3fb;font-weight:500;font-family:\"72Duplex\",\"72\",\"Helvetica Neue\",Helvetica,Arial,sans-serif}._7XyRp._z1dcp._lLmBE{background-color:#e4effa}._7XyRp._JIsXa{cursor:default}._7XyRp:active:not(._6D1JJ):not(._z1dcp):not([aria-disabled=true]):not(._JIsXa){background-color:#e8e9e9}._6D1JJ{padding-right:32px}._6D1JJ ._rZzMy{position:absolute;top:8px;right:3px;fill:#515559}._c5AR8{padding:8px;border-bottom:1px solid #e8e8e8;border-radius:4px 4px 0 0;position:-webkit-sticky;position:sticky;top:0;z-index:20;background-color:#fff}._btmT7{position:absolute;top:13px;left:13px}._5WOiA._5WOiA{padding-left:32px}._VZ9Zr{margin:2px 12px 2px 0;flex-shrink:0}._VZ9Zr._nLs1l>svg{border-color:#0b6ed0}._yo2jr{display:flex;justify-self:center;margin:8px}";
|
|
6642
6720
|
icons_index.styleInject(css_248z$h);
|
|
6643
6721
|
|
|
6644
6722
|
const MenuItem = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
@@ -6669,7 +6747,7 @@ const MenuItem = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
6669
6747
|
// eslint-disable-next-line jsx-a11y/no-static-element-interactions
|
|
6670
6748
|
React__default["default"].createElement("div", _extends__default["default"]({}, rest, {
|
|
6671
6749
|
ref: ref,
|
|
6672
|
-
role: role
|
|
6750
|
+
role: role !== null && role !== void 0 ? role : defaultRole,
|
|
6673
6751
|
tabIndex: tabIndex,
|
|
6674
6752
|
"aria-disabled": disabled,
|
|
6675
6753
|
"aria-checked": isSelectable ? isSelected : undefined,
|
|
@@ -6871,9 +6949,10 @@ const ArrowNav = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
6871
6949
|
preventScroll: true
|
|
6872
6950
|
});
|
|
6873
6951
|
} else if (highlightedIndex === 0 && searchable) {
|
|
6874
|
-
searchBoxRef
|
|
6952
|
+
searchBoxRef === null || searchBoxRef === void 0 ? void 0 : searchBoxRef.current.focus();
|
|
6875
6953
|
} else {
|
|
6876
|
-
|
|
6954
|
+
var _anchorRef$current;
|
|
6955
|
+
anchorRef === null || anchorRef === void 0 || (_anchorRef$current = anchorRef.current) === null || _anchorRef$current === void 0 ? void 0 : _anchorRef$current.focus();
|
|
6877
6956
|
}
|
|
6878
6957
|
}
|
|
6879
6958
|
}, [highlightedIndex, refs, searchable, allChildren.length,
|
|
@@ -6892,14 +6971,16 @@ const ArrowNav = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
6892
6971
|
onHighlightedIndexChange((highlightedIndex - 1 + numChildren) % numChildren);
|
|
6893
6972
|
}
|
|
6894
6973
|
} else if (e.key === 'PageUp' || e.key === 'Home') {
|
|
6974
|
+
var _containerRef$current;
|
|
6895
6975
|
// Only call the highlighted index change handler for the current nav list (i.e. if the event bubbles up to a parent nav list, don't call the highlighted index change handler on the parent nav list)
|
|
6896
|
-
if (containerRef.current
|
|
6976
|
+
if ((_containerRef$current = containerRef.current) !== null && _containerRef$current !== void 0 && _containerRef$current.contains(e.target)) {
|
|
6897
6977
|
e.preventDefault();
|
|
6898
6978
|
onHighlightedIndexChange(0);
|
|
6899
6979
|
}
|
|
6900
6980
|
} else if (e.key === 'PageDown' || e.key === 'End') {
|
|
6981
|
+
var _containerRef$current2;
|
|
6901
6982
|
// Only call the highlighted index change handler for the current nav list (i.e. if the event bubbles up to a parent nav list, don't call the highlighted index change handler on the parent nav list)
|
|
6902
|
-
if (containerRef.current
|
|
6983
|
+
if ((_containerRef$current2 = containerRef.current) !== null && _containerRef$current2 !== void 0 && _containerRef$current2.contains(e.target)) {
|
|
6903
6984
|
e.preventDefault();
|
|
6904
6985
|
const lastIndex = numChildren - 1;
|
|
6905
6986
|
onHighlightedIndexChange(lastIndex);
|
|
@@ -6917,20 +6998,20 @@ const ArrowNav = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
6917
6998
|
style: {
|
|
6918
6999
|
...style,
|
|
6919
7000
|
minWidth,
|
|
6920
|
-
maxHeight: maxHeight
|
|
7001
|
+
maxHeight: maxHeight !== null && maxHeight !== void 0 ? maxHeight :
|
|
6921
7002
|
// This logic is located here instead of BaseMenu.js so the maxHeight will update with screen resizing (Popper has a resize listener that causes this to rerender)
|
|
6922
7003
|
Math.min(350, (isSubmenu ?
|
|
6923
7004
|
// Submenus: window height - submenu popper offset - 8px of container padding - half of anchor height (fallback to default 18px))
|
|
6924
7005
|
document.documentElement.clientHeight - SUBMENU_POPPER_OFFSET[0] :
|
|
6925
7006
|
// Menus: half of window height - menu popper offset - 8px of container padding - half of anchor height (fallback to default 18px)
|
|
6926
|
-
document.documentElement.clientHeight / 2 - FLYOUT_POPPER_OFFSET[1]) - 8 - (anchorRef
|
|
7007
|
+
document.documentElement.clientHeight / 2 - FLYOUT_POPPER_OFFSET[1]) - 8 - (anchorRef !== null && anchorRef !== void 0 && anchorRef.current ? anchorRef.current.offsetHeight / 2 : 18))
|
|
6927
7008
|
}
|
|
6928
7009
|
}, rest), searchable && /*#__PURE__*/React__default["default"].createElement(MenuSearchBox, {
|
|
6929
7010
|
"aria-controls": menuId,
|
|
6930
7011
|
value: searchTerm,
|
|
6931
7012
|
ref: searchBoxRef,
|
|
6932
7013
|
onChange: e => {
|
|
6933
|
-
setSearchTerm
|
|
7014
|
+
setSearchTerm === null || setSearchTerm === void 0 ? void 0 : setSearchTerm(e.target.value);
|
|
6934
7015
|
},
|
|
6935
7016
|
onFocus: () => onHighlightedIndexChange(0)
|
|
6936
7017
|
}), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
@@ -6945,6 +7026,7 @@ const ArrowNav = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
6945
7026
|
});
|
|
6946
7027
|
|
|
6947
7028
|
const BaseMenu = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
7029
|
+
var _externalAnchor$props, _externalAnchor$props2, _useMenuContext, _externalAnchor$props3, _externalAnchor$props4, _externalAnchor$props5, _externalAnchor$props6, _externalAnchor$props7, _externalAnchor$props8, _externalAnchor$props9, _anchorRef$current;
|
|
6948
7030
|
let {
|
|
6949
7031
|
anchor: externalAnchor,
|
|
6950
7032
|
'aria-label': externalAriaLabel,
|
|
@@ -6985,9 +7067,9 @@ const BaseMenu = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
6985
7067
|
private_isFirstElementHighlightedOnUserActivatedOpen = true,
|
|
6986
7068
|
...rest
|
|
6987
7069
|
} = _ref;
|
|
6988
|
-
const anchorId = useId(externalAnchor
|
|
6989
|
-
const arrowNavId =
|
|
6990
|
-
const parentCloseAndFocusAnchor = useMenuContext()
|
|
7070
|
+
const anchorId = useId((_externalAnchor$props = externalAnchor === null || externalAnchor === void 0 || (_externalAnchor$props2 = externalAnchor.props) === null || _externalAnchor$props2 === void 0 ? void 0 : _externalAnchor$props2.id) !== null && _externalAnchor$props !== void 0 ? _externalAnchor$props : externalId);
|
|
7071
|
+
const arrowNavId = "".concat(anchorId, "-menu");
|
|
7072
|
+
const parentCloseAndFocusAnchor = (_useMenuContext = useMenuContext()) === null || _useMenuContext === void 0 ? void 0 : _useMenuContext.closeAndFocusAnchor;
|
|
6991
7073
|
const isSubmenu = Boolean(parentCloseAndFocusAnchor);
|
|
6992
7074
|
const {
|
|
6993
7075
|
translate
|
|
@@ -7006,20 +7088,23 @@ const BaseMenu = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
7006
7088
|
// Call onIsOpenChange whenever externalIsOpen changes
|
|
7007
7089
|
useDidUpdate(() => {
|
|
7008
7090
|
if (isSubmenu) {
|
|
7009
|
-
|
|
7091
|
+
var _onIsOpenChangeRef$cu;
|
|
7092
|
+
(_onIsOpenChangeRef$cu = onIsOpenChangeRef.current) === null || _onIsOpenChangeRef$cu === void 0 ? void 0 : _onIsOpenChangeRef$cu.call(onIsOpenChangeRef, externalIsOpen);
|
|
7010
7093
|
}
|
|
7011
7094
|
}, [externalIsOpen, onIsOpenChangeRef, isSubmenu]);
|
|
7012
7095
|
// Call onIsOpenChange if open on mount or on unmount
|
|
7013
7096
|
React.useEffect(() => {
|
|
7014
7097
|
if (isSubmenu) {
|
|
7015
7098
|
if (externalIsOpenRef.current) {
|
|
7016
|
-
|
|
7099
|
+
var _onIsOpenChangeRef$cu2;
|
|
7100
|
+
(_onIsOpenChangeRef$cu2 = onIsOpenChangeRef.current) === null || _onIsOpenChangeRef$cu2 === void 0 ? void 0 : _onIsOpenChangeRef$cu2.call(onIsOpenChangeRef, true);
|
|
7017
7101
|
}
|
|
7018
7102
|
return () => {
|
|
7019
7103
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
7020
7104
|
if (externalIsOpenRef.current) {
|
|
7105
|
+
var _onIsOpenChangeRef$cu3;
|
|
7021
7106
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
7022
|
-
onIsOpenChangeRef.current
|
|
7107
|
+
(_onIsOpenChangeRef$cu3 = onIsOpenChangeRef.current) === null || _onIsOpenChangeRef$cu3 === void 0 ? void 0 : _onIsOpenChangeRef$cu3.call(onIsOpenChangeRef, false);
|
|
7023
7108
|
}
|
|
7024
7109
|
};
|
|
7025
7110
|
}
|
|
@@ -7033,11 +7118,15 @@ const BaseMenu = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
7033
7118
|
}, [setHighlightedIndex, setIsOpen, setSearchTerm]);
|
|
7034
7119
|
const handleMultiSelectChange = item => {
|
|
7035
7120
|
let arr = selectedValue || selectedValue === 0 ? [].concat(selectedValue) : [];
|
|
7036
|
-
const i = arr.findIndex(v =>
|
|
7121
|
+
const i = arr.findIndex(v => {
|
|
7122
|
+
var _item$props;
|
|
7123
|
+
return v === (item === null || item === void 0 || (_item$props = item.props) === null || _item$props === void 0 ? void 0 : _item$props.value);
|
|
7124
|
+
});
|
|
7037
7125
|
if (i !== -1) {
|
|
7038
7126
|
arr.splice(i, 1);
|
|
7039
7127
|
} else {
|
|
7040
|
-
|
|
7128
|
+
var _item$props2;
|
|
7129
|
+
arr = union(arr, item === null || item === void 0 || (_item$props2 = item.props) === null || _item$props2 === void 0 ? void 0 : _item$props2.value);
|
|
7041
7130
|
}
|
|
7042
7131
|
setSelectedValue(arr, getLabelFromValue(children, arr), item);
|
|
7043
7132
|
};
|
|
@@ -7050,11 +7139,12 @@ const BaseMenu = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
7050
7139
|
setSelectedValue(value, getLabelFromValue(children, value), item);
|
|
7051
7140
|
};
|
|
7052
7141
|
const handleItemSelected = item => {
|
|
7142
|
+
var _item$props3;
|
|
7053
7143
|
if (!selectable) {
|
|
7054
7144
|
closeAndFocusAnchor();
|
|
7055
7145
|
return;
|
|
7056
7146
|
}
|
|
7057
|
-
const value = item
|
|
7147
|
+
const value = item === null || item === void 0 || (_item$props3 = item.props) === null || _item$props3 === void 0 ? void 0 : _item$props3.value;
|
|
7058
7148
|
if (!value && value !== 0) {
|
|
7059
7149
|
// eslint-disable-next-line no-console
|
|
7060
7150
|
console.warn('<MenuItem> should have a "value" prop when used in a <SelectMenu>', item);
|
|
@@ -7120,12 +7210,12 @@ const BaseMenu = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
7120
7210
|
onSelectedValueChange: handleSubmenuOnSelectedValueChange
|
|
7121
7211
|
});
|
|
7122
7212
|
}
|
|
7123
|
-
if (child
|
|
7124
|
-
var
|
|
7213
|
+
if ((child === null || child === void 0 ? void 0 : child.type) === MenuItem) {
|
|
7214
|
+
var _child$props, _child$props2;
|
|
7125
7215
|
menuItemIndex += 1;
|
|
7126
7216
|
return /*#__PURE__*/React__default["default"].cloneElement(child, {
|
|
7127
7217
|
isHighlighted: actualIndex === highlightedIndex,
|
|
7128
|
-
isSelected: selectable && typeof selectedValue !== 'undefined' && Array.isArray(selectedValue) ?
|
|
7218
|
+
isSelected: selectable && typeof selectedValue !== 'undefined' && Array.isArray(selectedValue) ? selectedValue.includes(child === null || child === void 0 || (_child$props = child.props) === null || _child$props === void 0 ? void 0 : _child$props.value) : (child === null || child === void 0 || (_child$props2 = child.props) === null || _child$props2 === void 0 ? void 0 : _child$props2.value) === selectedValue,
|
|
7129
7219
|
onSelect: wrapEvent(child.props.onSelect, () => {
|
|
7130
7220
|
handleItemSelected(child);
|
|
7131
7221
|
}),
|
|
@@ -7135,21 +7225,21 @@ const BaseMenu = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
7135
7225
|
}
|
|
7136
7226
|
return child;
|
|
7137
7227
|
});
|
|
7138
|
-
const anchorLabel = label
|
|
7139
|
-
const menuAnchorLabel = anchorLabel
|
|
7228
|
+
const anchorLabel = label !== null && label !== void 0 ? label : getLabelFromValue(children, selectedValue);
|
|
7229
|
+
const menuAnchorLabel = anchorLabel !== null && anchorLabel !== void 0 ? anchorLabel : defaultLabel;
|
|
7140
7230
|
const announceToScreenReader = useScreenReaderAnnouncement('assertive');
|
|
7141
|
-
const ariaLabelledBy = externalAnchor
|
|
7142
|
-
const ariaLabel = externalAnchor
|
|
7143
|
-
const ariaExpanded = externalAnchor
|
|
7231
|
+
const ariaLabelledBy = (_externalAnchor$props3 = externalAnchor === null || externalAnchor === void 0 || (_externalAnchor$props4 = externalAnchor.props) === null || _externalAnchor$props4 === void 0 ? void 0 : _externalAnchor$props4['aria-labelledby']) !== null && _externalAnchor$props3 !== void 0 ? _externalAnchor$props3 : externalAriaLabelledBy ? "".concat(externalAriaLabelledBy, " ").concat(anchorId) : undefined;
|
|
7232
|
+
const ariaLabel = (_externalAnchor$props5 = externalAnchor === null || externalAnchor === void 0 || (_externalAnchor$props6 = externalAnchor.props) === null || _externalAnchor$props6 === void 0 ? void 0 : _externalAnchor$props6['aria-label']) !== null && _externalAnchor$props5 !== void 0 ? _externalAnchor$props5 : externalAriaLabel && typeof menuAnchorLabel === 'string' ? "".concat(externalAriaLabel, " ").concat(menuAnchorLabel) : externalAriaLabel;
|
|
7233
|
+
const ariaExpanded = (externalAnchor === null || externalAnchor === void 0 ? void 0 : externalAnchor.props['aria-expanded']) !== undefined ? externalAnchor.props['aria-expanded'] : isOpen ? true : undefined;
|
|
7144
7234
|
const actualAnchor = externalAnchor !== undefined ? /*#__PURE__*/React__default["default"].cloneElement(externalAnchor, {
|
|
7145
7235
|
ref: mergeRefs(ref, anchorRef, externalAnchor.ref),
|
|
7146
|
-
tabIndex: externalAnchor.props.tabIndex
|
|
7147
|
-
role: externalAnchor.props.role
|
|
7236
|
+
tabIndex: (_externalAnchor$props7 = externalAnchor.props.tabIndex) !== null && _externalAnchor$props7 !== void 0 ? _externalAnchor$props7 : 0,
|
|
7237
|
+
role: (_externalAnchor$props8 = externalAnchor.props.role) !== null && _externalAnchor$props8 !== void 0 ? _externalAnchor$props8 : 'button',
|
|
7148
7238
|
id: anchorId,
|
|
7149
7239
|
'aria-controls': isOpen ? arrowNavId : undefined,
|
|
7150
7240
|
'aria-expanded': ariaExpanded,
|
|
7151
7241
|
'aria-haspopup': 'menu',
|
|
7152
|
-
'aria-disabled': externalAnchor.props['aria-disabled']
|
|
7242
|
+
'aria-disabled': (_externalAnchor$props9 = externalAnchor.props['aria-disabled']) !== null && _externalAnchor$props9 !== void 0 ? _externalAnchor$props9 : disabled,
|
|
7153
7243
|
'aria-labelledby': ariaLabelledBy,
|
|
7154
7244
|
'aria-label': ariaLabel,
|
|
7155
7245
|
onMouseDown: preventClickOutside,
|
|
@@ -7230,17 +7320,17 @@ const BaseMenu = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
7230
7320
|
id: arrowNavId,
|
|
7231
7321
|
role: "menu",
|
|
7232
7322
|
"aria-labelledby": anchorId,
|
|
7233
|
-
isNavItem: child => child
|
|
7323
|
+
isNavItem: child => (child === null || child === void 0 ? void 0 : child.type) === MenuItem || (child === null || child === void 0 ? void 0 : child.type) === MenuSearchBox || isType(child, menuType),
|
|
7234
7324
|
style: {
|
|
7235
7325
|
zIndex,
|
|
7236
|
-
maxWidth: maxFlyoutWidth
|
|
7237
|
-
width: maxFlyoutWidth
|
|
7326
|
+
maxWidth: maxFlyoutWidth !== null && maxFlyoutWidth !== void 0 ? maxFlyoutWidth : undefined,
|
|
7327
|
+
width: maxFlyoutWidth !== null && maxFlyoutWidth !== void 0 ? maxFlyoutWidth : undefined
|
|
7238
7328
|
},
|
|
7239
7329
|
onMouseDown: preventClickOutside,
|
|
7240
7330
|
className: classNames__default["default"](styles$h.contentPane, flyoutClassName),
|
|
7241
7331
|
highlightedIndex: highlightedIndex,
|
|
7242
7332
|
maxHeight: maxHeight,
|
|
7243
|
-
minWidth: isSubmenu ? undefined : Math.min(350, Math.max(160, anchorRef
|
|
7333
|
+
minWidth: isSubmenu ? undefined : Math.min(350, Math.max(160, anchorRef === null || anchorRef === void 0 || (_anchorRef$current = anchorRef.current) === null || _anchorRef$current === void 0 ? void 0 : _anchorRef$current.offsetWidth)),
|
|
7244
7334
|
searchable: searchable,
|
|
7245
7335
|
onHighlightedIndexChange: i => setHighlightedIndex(i),
|
|
7246
7336
|
searchTerm: searchTerm,
|
|
@@ -7259,8 +7349,9 @@ const BaseMenu = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
7259
7349
|
// (not menu container) so we focus anchor before browser moves focus
|
|
7260
7350
|
closeAndFocusAnchor();
|
|
7261
7351
|
} else if (e.key === 'ArrowLeft' && isSubmenu) {
|
|
7352
|
+
var _arrowNavRef$current;
|
|
7262
7353
|
// Only update the highlighted index for the current menu (i.e. if the event bubbles up to a parent menu, don't update the highlighted index for the parent menu)
|
|
7263
|
-
if (arrowNavRef.current
|
|
7354
|
+
if ((_arrowNavRef$current = arrowNavRef.current) !== null && _arrowNavRef$current !== void 0 && _arrowNavRef$current.contains(e.target) && e.target !== searchBoxRef.current) {
|
|
7264
7355
|
setHighlightedIndex(-1);
|
|
7265
7356
|
}
|
|
7266
7357
|
}
|
|
@@ -7279,16 +7370,13 @@ function filterItems(valueToFilterBy, items) {
|
|
|
7279
7370
|
const result = items.filter(item => {
|
|
7280
7371
|
const searchTermLowerCase = valueToFilterBy.toLowerCase();
|
|
7281
7372
|
if (typeof item.props.label === 'string') {
|
|
7282
|
-
|
|
7283
|
-
return _includesInstanceProperty__default["default"](_context2 = item.props.label.toLowerCase()).call(_context2, searchTermLowerCase);
|
|
7373
|
+
return item.props.label.toLowerCase().includes(searchTermLowerCase);
|
|
7284
7374
|
}
|
|
7285
7375
|
if (typeof item.props.children === 'string') {
|
|
7286
|
-
|
|
7287
|
-
return _includesInstanceProperty__default["default"](_context3 = item.props.children.toLowerCase()).call(_context3, searchTermLowerCase);
|
|
7376
|
+
return item.props.children.toLowerCase().includes(searchTermLowerCase);
|
|
7288
7377
|
}
|
|
7289
7378
|
// eslint-disable-next-line no-console
|
|
7290
|
-
console.warn(
|
|
7291
|
-
Ensure prop "children" is of type "string" or provide a "label" prop!`, item);
|
|
7379
|
+
console.warn("<MenuItem> not included in search results!\n Ensure prop \"children\" is of type \"string\" or provide a \"label\" prop!", item);
|
|
7292
7380
|
return false;
|
|
7293
7381
|
});
|
|
7294
7382
|
return result;
|
|
@@ -7307,11 +7395,12 @@ function getDescendent(children, value) {
|
|
|
7307
7395
|
if (value === undefined) return null;
|
|
7308
7396
|
const childArray = React__default["default"].Children.toArray(children);
|
|
7309
7397
|
for (let i = 0; i < childArray.length; i += 1) {
|
|
7398
|
+
var _child$props3, _child$props4;
|
|
7310
7399
|
const child = childArray[i];
|
|
7311
|
-
if (child
|
|
7400
|
+
if ((child === null || child === void 0 ? void 0 : child.type) === MenuItem && (child === null || child === void 0 || (_child$props3 = child.props) === null || _child$props3 === void 0 ? void 0 : _child$props3.value) === value) {
|
|
7312
7401
|
return child;
|
|
7313
7402
|
}
|
|
7314
|
-
if (child
|
|
7403
|
+
if ((child === null || child === void 0 ? void 0 : child.type) !== MenuItem && child !== null && child !== void 0 && (_child$props4 = child.props) !== null && _child$props4 !== void 0 && _child$props4.children) {
|
|
7315
7404
|
const descendent = getDescendent(child.props.children, value);
|
|
7316
7405
|
if (descendent) {
|
|
7317
7406
|
return descendent;
|
|
@@ -7321,12 +7410,13 @@ function getDescendent(children, value) {
|
|
|
7321
7410
|
return null;
|
|
7322
7411
|
}
|
|
7323
7412
|
function getLabel(menuOptionNode) {
|
|
7324
|
-
|
|
7413
|
+
var _menuOptionNode$props;
|
|
7414
|
+
if ( /*#__PURE__*/React.isValidElement(menuOptionNode)) return getLabel(menuOptionNode === null || menuOptionNode === void 0 || (_menuOptionNode$props = menuOptionNode.props) === null || _menuOptionNode$props === void 0 ? void 0 : _menuOptionNode$props.children);
|
|
7325
7415
|
return menuOptionNode;
|
|
7326
7416
|
}
|
|
7327
7417
|
function union(arr1, arr2) {
|
|
7328
7418
|
return [].concat(arr1).concat(arr2).reduce((result, current) => {
|
|
7329
|
-
if (!
|
|
7419
|
+
if (!result.includes(current)) {
|
|
7330
7420
|
result.push(current);
|
|
7331
7421
|
}
|
|
7332
7422
|
return result;
|
|
@@ -7371,8 +7461,8 @@ const SelectMenu = /*#__PURE__*/React__default["default"].forwardRef(function Se
|
|
|
7371
7461
|
for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
|
7372
7462
|
args[_key - 1] = arguments[_key];
|
|
7373
7463
|
}
|
|
7374
|
-
onSelectedValueChange
|
|
7375
|
-
onChange
|
|
7464
|
+
onSelectedValueChange === null || onSelectedValueChange === void 0 ? void 0 : onSelectedValueChange(value, ...args);
|
|
7465
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(value);
|
|
7376
7466
|
}
|
|
7377
7467
|
}, rest));
|
|
7378
7468
|
});
|
|
@@ -7483,11 +7573,11 @@ const ConditionSet = function ConditionSet(_ref) {
|
|
|
7483
7573
|
}
|
|
7484
7574
|
}
|
|
7485
7575
|
if (fixedSet) {
|
|
7486
|
-
lastConnectionRef.current.style.height =
|
|
7487
|
-
lastConnectionRef.current.style.top =
|
|
7576
|
+
lastConnectionRef.current.style.height = "".concat(height - 38, "px");
|
|
7577
|
+
lastConnectionRef.current.style.top = "-".concat(height - 56, "px");
|
|
7488
7578
|
} else {
|
|
7489
|
-
lastConnectionRef.current.style.height =
|
|
7490
|
-
lastConnectionRef.current.style.top =
|
|
7579
|
+
lastConnectionRef.current.style.height = "".concat(height - 18, "px");
|
|
7580
|
+
lastConnectionRef.current.style.top = "-".concat(height - 52, "px");
|
|
7491
7581
|
}
|
|
7492
7582
|
}
|
|
7493
7583
|
}
|
|
@@ -7517,7 +7607,7 @@ const ConditionSet = function ConditionSet(_ref) {
|
|
|
7517
7607
|
if (fixedSet) {
|
|
7518
7608
|
indices.shift();
|
|
7519
7609
|
}
|
|
7520
|
-
return getSubDataTestId(rootDataTestId,
|
|
7610
|
+
return getSubDataTestId(rootDataTestId, "".concat(prefix, "-").concat(indices.join('-')));
|
|
7521
7611
|
}, [fixedSet, rootDataTestId]);
|
|
7522
7612
|
function renderControls(itemType, itemPosition, itemIndex, itemLevel, numberOfSetItems, itemId) {
|
|
7523
7613
|
return /*#__PURE__*/React__default["default"].createElement(Controls, {
|
|
@@ -7644,7 +7734,7 @@ const LogicEditor = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref
|
|
|
7644
7734
|
const classes = classNames__default["default"](className, styles$i.editor);
|
|
7645
7735
|
function update(newState) {
|
|
7646
7736
|
setState(newState);
|
|
7647
|
-
onChange
|
|
7737
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(newState);
|
|
7648
7738
|
}
|
|
7649
7739
|
const handleNewLogicItem = (item, position) => {
|
|
7650
7740
|
const newState = shallowCopy(state);
|
|
@@ -7713,9 +7803,9 @@ const LogicEditor = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref
|
|
|
7713
7803
|
})));
|
|
7714
7804
|
});
|
|
7715
7805
|
|
|
7716
|
-
var css_248z$g = ".
|
|
7717
|
-
var styles$g = {"backdrop":"
|
|
7718
|
-
var stylesheet$g=".
|
|
7806
|
+
var css_248z$g = "._zrinO{position:fixed;left:0;top:0;width:100%;height:100%;background-color:rgba(0,0,0,.3);align-items:flex-start}._SV7-Z,._zrinO{display:flex;overflow:auto}._SV7-Z{flex-direction:column;box-shadow:0 12px 35px -8px rgba(0,0,0,.12);border-radius:8px;background-color:#fff;min-width:450px;min-height:198px;max-width:85%;max-height:85%;margin:auto;outline:none}:not(._sY3Zh)._YfYJ0{width:100vw;min-width:200px;max-width:none;max-height:100vh;border-radius:0}@media screen and (min-width:480px){:not(._sY3Zh)._YfYJ0{max-width:480px;max-height:calc(100vh - 80px);border-radius:8px}}:not(._sY3Zh)._rCm6w{width:100vw;min-width:200px;max-width:none;max-height:100vh;border-radius:0}@media screen and (min-width:480px){:not(._sY3Zh)._rCm6w{max-width:480px;max-height:calc(100vh - 80px);border-radius:8px}}@media screen and (min-width:768px){:not(._sY3Zh)._rCm6w{max-width:700px}}:not(._sY3Zh)._jTTSA{width:100vw;min-width:200px;max-width:none;max-height:100vh;border-radius:0}@media screen and (min-width:480px){:not(._sY3Zh)._jTTSA{max-width:480px;max-height:calc(100vh - 80px);border-radius:8px}}@media screen and (min-width:768px){:not(._sY3Zh)._jTTSA{max-width:700px}}@media screen and (min-width:1024px){:not(._sY3Zh)._jTTSA{max-width:1000px}}:not(._sY3Zh)._HZYTJ{width:100vw;min-width:200px;max-width:none;max-height:100vh;border-radius:0}@media screen and (min-width:480px){:not(._sY3Zh)._HZYTJ{max-width:480px;max-height:calc(100vh - 80px);border-radius:8px}}@media screen and (min-width:768px){:not(._sY3Zh)._HZYTJ{max-width:700px}}@media screen and (min-width:1024px){:not(._sY3Zh)._HZYTJ{max-width:1000px}}@media screen and (min-width:1632px){:not(._sY3Zh)._HZYTJ{max-width:1600px;max-height:calc(100vh - 32px)}}._sY3Zh{min-width:200px;width:calc(100% - 48px)}._sY3Zh,._sY3Zh._YfYJ0{max-height:calc(100vh - 80px)}._sY3Zh._YfYJ0{max-width:480px;border-radius:8px}._sY3Zh._rCm6w{max-width:700px}._sY3Zh._jTTSA{max-width:1000px}._sY3Zh._HZYTJ{max-width:1600px;max-height:calc(100vh - 32px)}._6IHZs{height:calc(100vh - 80px)}@media screen and (max-width:479px){._6IHZs{height:100vh}}@media screen and (min-width:1632px){._6IHZs{height:calc(100vh - 32px)}}._c2lE8{position:relative;display:flex;flex-direction:row;flex-shrink:0;min-height:65px;padding:20px 24px;align-items:center;font-size:18px;font-weight:400;line-height:24px;color:#32363a;border-bottom:1px solid #eee}._RCVmW{padding-right:64px}._pyftg{position:absolute;top:14px;right:14px}._wZOk0{flex-grow:1;font-size:14px;overflow:auto;color:#32363a}._o5Ekf,._wZOk0{padding:20px 24px}._o5Ekf{display:flex;flex-direction:row;flex-shrink:0;align-items:center;justify-content:flex-end;border-top:1px solid #eee}._o5Ekf>*{margin:0 4px}._o5Ekf>:first-child{margin-left:0}._o5Ekf>:last-child{margin-right:0}@keyframes _KFibi{0%{opacity:0}}._KFibi{animation:_KFibi ease-in both;animation-duration:.2s}@keyframes _IzlKW{to{opacity:0}}._IzlKW{animation:_IzlKW ease-out both;animation-duration:.2s}@keyframes _PXsr1{0%{transform:scale3d(.7,.7,.7);opacity:0}}._PXsr1{animation:_PXsr1 both;animation-duration:.2s}@keyframes _UvKnB{to{transform:scale3d(.7,.7,.7);opacity:0}}._UvKnB{animation:_UvKnB both;animation-duration:.2s}";
|
|
7807
|
+
var styles$g = {"backdrop":"_zrinO","modal":"_SV7-Z","responsive":"_sY3Zh","dialogSmall":"_YfYJ0","dialogMedium":"_rCm6w","dialogLarge":"_jTTSA","dialogExtraLarge":"_HZYTJ","growToMaxHeight":"_6IHZs","modalHeader":"_c2lE8","modalHeaderWithCloseButton":"_RCVmW","modalHeaderCloseButton":"_pyftg","modalBody":"_wZOk0","modalFooter":"_o5Ekf","fadeEnter":"_KFibi","fadeLeave":"_IzlKW","zoomEnter":"_PXsr1","zoomLeave":"_UvKnB"};
|
|
7808
|
+
var stylesheet$g="._zrinO{position:fixed;left:0;top:0;width:100%;height:100%;background-color:rgba(0,0,0,.3);align-items:flex-start}._SV7-Z,._zrinO{display:flex;overflow:auto}._SV7-Z{flex-direction:column;box-shadow:0 12px 35px -8px rgba(0,0,0,.12);border-radius:8px;background-color:#fff;min-width:450px;min-height:198px;max-width:85%;max-height:85%;margin:auto;outline:none}:not(._sY3Zh)._YfYJ0{width:100vw;min-width:200px;max-width:none;max-height:100vh;border-radius:0}@media screen and (min-width:480px){:not(._sY3Zh)._YfYJ0{max-width:480px;max-height:calc(100vh - 80px);border-radius:8px}}:not(._sY3Zh)._rCm6w{width:100vw;min-width:200px;max-width:none;max-height:100vh;border-radius:0}@media screen and (min-width:480px){:not(._sY3Zh)._rCm6w{max-width:480px;max-height:calc(100vh - 80px);border-radius:8px}}@media screen and (min-width:768px){:not(._sY3Zh)._rCm6w{max-width:700px}}:not(._sY3Zh)._jTTSA{width:100vw;min-width:200px;max-width:none;max-height:100vh;border-radius:0}@media screen and (min-width:480px){:not(._sY3Zh)._jTTSA{max-width:480px;max-height:calc(100vh - 80px);border-radius:8px}}@media screen and (min-width:768px){:not(._sY3Zh)._jTTSA{max-width:700px}}@media screen and (min-width:1024px){:not(._sY3Zh)._jTTSA{max-width:1000px}}:not(._sY3Zh)._HZYTJ{width:100vw;min-width:200px;max-width:none;max-height:100vh;border-radius:0}@media screen and (min-width:480px){:not(._sY3Zh)._HZYTJ{max-width:480px;max-height:calc(100vh - 80px);border-radius:8px}}@media screen and (min-width:768px){:not(._sY3Zh)._HZYTJ{max-width:700px}}@media screen and (min-width:1024px){:not(._sY3Zh)._HZYTJ{max-width:1000px}}@media screen and (min-width:1632px){:not(._sY3Zh)._HZYTJ{max-width:1600px;max-height:calc(100vh - 32px)}}._sY3Zh{min-width:200px;width:calc(100% - 48px)}._sY3Zh,._sY3Zh._YfYJ0{max-height:calc(100vh - 80px)}._sY3Zh._YfYJ0{max-width:480px;border-radius:8px}._sY3Zh._rCm6w{max-width:700px}._sY3Zh._jTTSA{max-width:1000px}._sY3Zh._HZYTJ{max-width:1600px;max-height:calc(100vh - 32px)}._6IHZs{height:calc(100vh - 80px)}@media screen and (max-width:479px){._6IHZs{height:100vh}}@media screen and (min-width:1632px){._6IHZs{height:calc(100vh - 32px)}}._c2lE8{position:relative;display:flex;flex-direction:row;flex-shrink:0;min-height:65px;padding:20px 24px;align-items:center;font-size:18px;font-weight:400;line-height:24px;color:#32363a;border-bottom:1px solid #eee}._RCVmW{padding-right:64px}._pyftg{position:absolute;top:14px;right:14px}._wZOk0{flex-grow:1;font-size:14px;overflow:auto;color:#32363a}._o5Ekf,._wZOk0{padding:20px 24px}._o5Ekf{display:flex;flex-direction:row;flex-shrink:0;align-items:center;justify-content:flex-end;border-top:1px solid #eee}._o5Ekf>*{margin:0 4px}._o5Ekf>:first-child{margin-left:0}._o5Ekf>:last-child{margin-right:0}@keyframes _KFibi{0%{opacity:0}}._KFibi{animation:_KFibi ease-in both;animation-duration:.2s}@keyframes _IzlKW{to{opacity:0}}._IzlKW{animation:_IzlKW ease-out both;animation-duration:.2s}@keyframes _PXsr1{0%{transform:scale3d(.7,.7,.7);opacity:0}}._PXsr1{animation:_PXsr1 both;animation-duration:.2s}@keyframes _UvKnB{to{transform:scale3d(.7,.7,.7);opacity:0}}._UvKnB{animation:_UvKnB both;animation-duration:.2s}";
|
|
7719
7809
|
icons_index.styleInject(css_248z$g);
|
|
7720
7810
|
|
|
7721
7811
|
const {
|
|
@@ -7730,7 +7820,7 @@ const OverlayContainer = /*#__PURE__*/React__default["default"].forwardRef((_ref
|
|
|
7730
7820
|
} = _ref;
|
|
7731
7821
|
return /*#__PURE__*/React__default["default"].createElement("div", _extends__default["default"]({}, rest, {
|
|
7732
7822
|
ref: ref
|
|
7733
|
-
}), children, /*#__PURE__*/React__default["default"].createElement("style", null,
|
|
7823
|
+
}), children, /*#__PURE__*/React__default["default"].createElement("style", null, "body { overflow: hidden; }"));
|
|
7734
7824
|
});
|
|
7735
7825
|
const Overlay = /*#__PURE__*/React__default["default"].forwardRef((_ref2, ref) => {
|
|
7736
7826
|
let {
|
|
@@ -7758,14 +7848,14 @@ const Overlay = /*#__PURE__*/React__default["default"].forwardRef((_ref2, ref) =
|
|
|
7758
7848
|
// Ensure that when a user clicks on the dialog and drags and lifts out on the overlay,
|
|
7759
7849
|
// the modal does not fire onDismiss.
|
|
7760
7850
|
if (e.target === mouseDownTarget.current && e.target === overlay.current) {
|
|
7761
|
-
onDismiss
|
|
7851
|
+
onDismiss === null || onDismiss === void 0 ? void 0 : onDismiss(e);
|
|
7762
7852
|
}
|
|
7763
7853
|
};
|
|
7764
7854
|
const handleKeyDown = e => {
|
|
7765
7855
|
if (e.key === 'Escape') {
|
|
7766
7856
|
e.stopPropagation(); // prevent event from closing modals or popovers
|
|
7767
|
-
onDismiss
|
|
7768
|
-
onClose
|
|
7857
|
+
onDismiss === null || onDismiss === void 0 ? void 0 : onDismiss(e);
|
|
7858
|
+
onClose === null || onClose === void 0 ? void 0 : onClose(e);
|
|
7769
7859
|
}
|
|
7770
7860
|
};
|
|
7771
7861
|
const handleBodyKeyDown = e => {
|
|
@@ -7808,13 +7898,13 @@ const Dialog = /*#__PURE__*/React__default["default"].forwardRef((_ref3, ref) =>
|
|
|
7808
7898
|
const prefix = 'dialog';
|
|
7809
7899
|
switch (maxSize) {
|
|
7810
7900
|
case 'small':
|
|
7811
|
-
return
|
|
7901
|
+
return "".concat(prefix, "Small");
|
|
7812
7902
|
case 'medium':
|
|
7813
|
-
return
|
|
7903
|
+
return "".concat(prefix, "Medium");
|
|
7814
7904
|
case 'large':
|
|
7815
|
-
return
|
|
7905
|
+
return "".concat(prefix, "Large");
|
|
7816
7906
|
case 'xl':
|
|
7817
|
-
return
|
|
7907
|
+
return "".concat(prefix, "ExtraLarge");
|
|
7818
7908
|
default:
|
|
7819
7909
|
return '';
|
|
7820
7910
|
}
|
|
@@ -7878,21 +7968,22 @@ const Modal = /*#__PURE__*/React__default["default"].forwardRef((_ref4, ref) =>
|
|
|
7878
7968
|
// This effect should only run when the Modal is added or removed from the DOM
|
|
7879
7969
|
useDidUpdate(() => {
|
|
7880
7970
|
if (isInDOM) {
|
|
7881
|
-
if (elementRefToFocusOnOpen
|
|
7971
|
+
if (elementRefToFocusOnOpen !== null && elementRefToFocusOnOpen !== void 0 && elementRefToFocusOnOpen.current) {
|
|
7882
7972
|
elementRefToFocusOnOpen.current.focus();
|
|
7883
7973
|
} else if (typeof onClose === 'function' && closeIconButtonRef.current) {
|
|
7884
7974
|
closeIconButtonRef.current.focus();
|
|
7885
7975
|
} else {
|
|
7886
|
-
|
|
7976
|
+
var _dialogRef$current;
|
|
7977
|
+
(_dialogRef$current = dialogRef.current) === null || _dialogRef$current === void 0 ? void 0 : _dialogRef$current.focus();
|
|
7887
7978
|
}
|
|
7888
|
-
} else if (elementRefToFocusOnClose
|
|
7979
|
+
} else if (elementRefToFocusOnClose !== null && elementRefToFocusOnClose !== void 0 && elementRefToFocusOnClose.current) {
|
|
7889
7980
|
elementRefToFocusOnClose.current.focus();
|
|
7890
7981
|
} else {
|
|
7891
7982
|
/*
|
|
7892
7983
|
* This replaces the `returnFocus` prop of `react-focus-lock`.
|
|
7893
7984
|
* The logic is done in this effect instead because `elementRefToFocusOnClose.current` is not available until after the `Overlay` is unmounted.
|
|
7894
7985
|
*/
|
|
7895
|
-
elementUsedToOpenModal
|
|
7986
|
+
elementUsedToOpenModal === null || elementUsedToOpenModal === void 0 ? void 0 : elementUsedToOpenModal.focus();
|
|
7896
7987
|
}
|
|
7897
7988
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
7898
7989
|
}, [isInDOM]);
|
|
@@ -7912,7 +8003,7 @@ const Modal = /*#__PURE__*/React__default["default"].forwardRef((_ref4, ref) =>
|
|
|
7912
8003
|
onDismiss: onDismiss
|
|
7913
8004
|
}, /*#__PURE__*/React__default["default"].createElement(Dialog, _extends__default["default"]({}, rest, {
|
|
7914
8005
|
onAnimationEnd: e => {
|
|
7915
|
-
externalOnAnimationEnd
|
|
8006
|
+
externalOnAnimationEnd === null || externalOnAnimationEnd === void 0 ? void 0 : externalOnAnimationEnd(e);
|
|
7916
8007
|
if (!open) setIsInDOM(false);
|
|
7917
8008
|
},
|
|
7918
8009
|
maxSize: maxSize,
|
|
@@ -7972,9 +8063,9 @@ const ModalFooter = /*#__PURE__*/React__default["default"].forwardRef((_ref7, re
|
|
|
7972
8063
|
}), children);
|
|
7973
8064
|
});
|
|
7974
8065
|
|
|
7975
|
-
var css_248z$f = ".
|
|
7976
|
-
var styles$f = {"numberStepperContainer":"
|
|
7977
|
-
var stylesheet$f=".
|
|
8066
|
+
var css_248z$f = "._1Kscx{display:inline-flex;width:127px}._xdR6R{color:#32363a;background:#fafafa;outline:none;text-align:center;padding:0 12px;min-width:55px;width:100%;font-size:14px;border:1px solid #898989;border-radius:0;-moz-appearance:textfield}._xdR6R:hover:not(._DRb6j){cursor:pointer;background:#f5f5f5}._xdR6R._XmAhN{box-shadow:0 0 0 2px #fff,0 0 0 4px #900000}._xdR6R._DRb6j{cursor:not-allowed;fill:#74777a;color:#74777a;border-color:#e5e5e5}._xdR6R._DRb6j>svg{opacity:.4}._xdR6R::-webkit-inner-spin-button,._xdR6R::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}._xdR6R:focus{z-index:0;border:none;border-radius:4px}._xdR6R:focus:not(._XmAhN){box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._xDIyd,._xdR6R:focus:not(._DRb6j){background:#fafafa}._xDIyd{padding:0;display:flex;justify-content:center;align-items:center;flex-shrink:0;width:36px;height:36px;fill:#515559;outline:none;border-radius:4px 0 0 4px;border:1px solid #898989;border-right-width:0}._xDIyd:hover:not(._DRb6j){cursor:pointer;background:#f5f5f5}._xDIyd:active:not(._DRb6j){background:#e5e5e5}._xDIyd._DRb6j{cursor:not-allowed;fill:#74777a;color:#74777a;border-color:#e5e5e5}._xDIyd._DRb6j>svg{opacity:.4}._ox4nz{padding:0;display:flex;justify-content:center;align-items:center;flex-shrink:0;width:36px;height:36px;background:#fafafa;fill:#515559;outline:none;border-radius:0 4px 4px 0;border:1px solid #898989;border-left-width:0}._ox4nz:hover:not(._DRb6j){cursor:pointer;background:#f5f5f5}._ox4nz:active:not(._DRb6j){background:#e5e5e5}._ox4nz._DRb6j{cursor:not-allowed;fill:#74777a;color:#74777a;border-color:#e5e5e5}._ox4nz._DRb6j>svg{opacity:.4}";
|
|
8067
|
+
var styles$f = {"numberStepperContainer":"_1Kscx","numberStepperInput":"_xdR6R","disabled":"_DRb6j","invalid":"_XmAhN","decrementBtn":"_xDIyd","incrementBtn":"_ox4nz"};
|
|
8068
|
+
var stylesheet$f="._1Kscx{display:inline-flex;width:127px}._xdR6R{color:#32363a;background:#fafafa;outline:none;text-align:center;padding:0 12px;min-width:55px;width:100%;font-size:14px;border:1px solid #898989;border-radius:0;-moz-appearance:textfield}._xdR6R:hover:not(._DRb6j){cursor:pointer;background:#f5f5f5}._xdR6R._XmAhN{box-shadow:0 0 0 2px #fff,0 0 0 4px #900000}._xdR6R._DRb6j{cursor:not-allowed;fill:#74777a;color:#74777a;border-color:#e5e5e5}._xdR6R._DRb6j>svg{opacity:.4}._xdR6R::-webkit-inner-spin-button,._xdR6R::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}._xdR6R:focus{z-index:0;border:none;border-radius:4px}._xdR6R:focus:not(._XmAhN){box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._xDIyd,._xdR6R:focus:not(._DRb6j){background:#fafafa}._xDIyd{padding:0;display:flex;justify-content:center;align-items:center;flex-shrink:0;width:36px;height:36px;fill:#515559;outline:none;border-radius:4px 0 0 4px;border:1px solid #898989;border-right-width:0}._xDIyd:hover:not(._DRb6j){cursor:pointer;background:#f5f5f5}._xDIyd:active:not(._DRb6j){background:#e5e5e5}._xDIyd._DRb6j{cursor:not-allowed;fill:#74777a;color:#74777a;border-color:#e5e5e5}._xDIyd._DRb6j>svg{opacity:.4}._ox4nz{padding:0;display:flex;justify-content:center;align-items:center;flex-shrink:0;width:36px;height:36px;background:#fafafa;fill:#515559;outline:none;border-radius:0 4px 4px 0;border:1px solid #898989;border-left-width:0}._ox4nz:hover:not(._DRb6j){cursor:pointer;background:#f5f5f5}._ox4nz:active:not(._DRb6j){background:#e5e5e5}._ox4nz._DRb6j{cursor:not-allowed;fill:#74777a;color:#74777a;border-color:#e5e5e5}._ox4nz._DRb6j>svg{opacity:.4}";
|
|
7978
8069
|
icons_index.styleInject(css_248z$f);
|
|
7979
8070
|
|
|
7980
8071
|
const {
|
|
@@ -8029,7 +8120,7 @@ const NumberStepperInput$1 = /*#__PURE__*/React__default["default"].forwardRef((
|
|
|
8029
8120
|
* depending on the key that was pressed.
|
|
8030
8121
|
*/
|
|
8031
8122
|
const handleKeyDown = e => {
|
|
8032
|
-
onKeyDown
|
|
8123
|
+
onKeyDown === null || onKeyDown === void 0 ? void 0 : onKeyDown(e);
|
|
8033
8124
|
if (isExternallyDisabled) return;
|
|
8034
8125
|
if (e.key === 'ArrowUp') {
|
|
8035
8126
|
// Prevents browser's default increment
|
|
@@ -8064,7 +8155,7 @@ const NumberStepperInput$1 = /*#__PURE__*/React__default["default"].forwardRef((
|
|
|
8064
8155
|
* Selects the DOM element
|
|
8065
8156
|
*/
|
|
8066
8157
|
const handleFocus = e => {
|
|
8067
|
-
onFocus
|
|
8158
|
+
onFocus === null || onFocus === void 0 ? void 0 : onFocus(e);
|
|
8068
8159
|
if (isExternallyDisabled) return;
|
|
8069
8160
|
e.target.select();
|
|
8070
8161
|
};
|
|
@@ -8074,7 +8165,7 @@ const NumberStepperInput$1 = /*#__PURE__*/React__default["default"].forwardRef((
|
|
|
8074
8165
|
* Calls `handleInputBlur`
|
|
8075
8166
|
*/
|
|
8076
8167
|
const handleBlur = e => {
|
|
8077
|
-
onBlur
|
|
8168
|
+
onBlur === null || onBlur === void 0 ? void 0 : onBlur(e);
|
|
8078
8169
|
if (isExternallyDisabled) return;
|
|
8079
8170
|
handleInputBlur(e);
|
|
8080
8171
|
};
|
|
@@ -8139,7 +8230,7 @@ const NumberStepperIncrement$1 = /*#__PURE__*/React__default["default"].forwardR
|
|
|
8139
8230
|
*/
|
|
8140
8231
|
const handleClick = e => {
|
|
8141
8232
|
if (!isDisabled) {
|
|
8142
|
-
onClick
|
|
8233
|
+
onClick === null || onClick === void 0 ? void 0 : onClick(e);
|
|
8143
8234
|
increment(true);
|
|
8144
8235
|
}
|
|
8145
8236
|
};
|
|
@@ -8192,7 +8283,7 @@ const NumberStepperDecrement$1 = /*#__PURE__*/React__default["default"].forwardR
|
|
|
8192
8283
|
*/
|
|
8193
8284
|
const handleClick = e => {
|
|
8194
8285
|
if (!isDisabled) {
|
|
8195
|
-
onClick
|
|
8286
|
+
onClick === null || onClick === void 0 ? void 0 : onClick(e);
|
|
8196
8287
|
decrement(true);
|
|
8197
8288
|
}
|
|
8198
8289
|
};
|
|
@@ -8363,15 +8454,16 @@ const NumberStepper$1 = /*#__PURE__*/React__default["default"].forwardRef((_ref,
|
|
|
8363
8454
|
}
|
|
8364
8455
|
}
|
|
8365
8456
|
if (regex.test(val)) {
|
|
8457
|
+
var _val$split;
|
|
8366
8458
|
const currentIsSeparatedByComma = isSeparatedByComma(val);
|
|
8367
8459
|
const currentDecimalSeparator = currentIsSeparatedByComma ? ',' : '.';
|
|
8368
|
-
const decimalPortion = val.split(currentDecimalSeparator)
|
|
8369
|
-
if (decimalPortion
|
|
8460
|
+
const decimalPortion = (_val$split = val.split(currentDecimalSeparator)) === null || _val$split === void 0 ? void 0 : _val$split[1];
|
|
8461
|
+
if ((decimalPortion === null || decimalPortion === void 0 ? void 0 : decimalPortion.length) > 2) {
|
|
8370
8462
|
let rounded = String(roundToTwoDecimalPlaces(convertToNumber$1(val)));
|
|
8371
8463
|
|
|
8372
8464
|
// If a user types a number that rounds out to a whole number, such as '23.000' or `1.999`, the '.' is rounded away, causing the user to lose their place in the input.
|
|
8373
8465
|
if (rounded.indexOf('.') === -1) {
|
|
8374
|
-
rounded +=
|
|
8466
|
+
rounded += "".concat(currentDecimalSeparator, "00");
|
|
8375
8467
|
}
|
|
8376
8468
|
setInputValue(localizeNumber(rounded, currentIsSeparatedByComma));
|
|
8377
8469
|
} else {
|
|
@@ -8422,7 +8514,7 @@ const NumberStepper$1 = /*#__PURE__*/React__default["default"].forwardRef((_ref,
|
|
|
8422
8514
|
} = e;
|
|
8423
8515
|
if (!componentHasFocus.current && currentTarget.contains(document.activeElement)) {
|
|
8424
8516
|
componentHasFocus.current = true;
|
|
8425
|
-
onFocus
|
|
8517
|
+
onFocus === null || onFocus === void 0 ? void 0 : onFocus(e);
|
|
8426
8518
|
}
|
|
8427
8519
|
},
|
|
8428
8520
|
onBlur: e => {
|
|
@@ -8435,7 +8527,7 @@ const NumberStepper$1 = /*#__PURE__*/React__default["default"].forwardRef((_ref,
|
|
|
8435
8527
|
// Check if the new focused element is a child of the original container
|
|
8436
8528
|
if (!currentTarget.contains(document.activeElement)) {
|
|
8437
8529
|
componentHasFocus.current = false;
|
|
8438
|
-
onBlur
|
|
8530
|
+
onBlur === null || onBlur === void 0 ? void 0 : onBlur(e);
|
|
8439
8531
|
}
|
|
8440
8532
|
});
|
|
8441
8533
|
}
|
|
@@ -8451,7 +8543,7 @@ function convertToNumber$1(value) {
|
|
|
8451
8543
|
if (typeof value === 'number') {
|
|
8452
8544
|
return value;
|
|
8453
8545
|
}
|
|
8454
|
-
const num = Number(value
|
|
8546
|
+
const num = Number(value === null || value === void 0 ? void 0 : value.replace(',', '.'));
|
|
8455
8547
|
if (Number.isNaN(num)) {
|
|
8456
8548
|
return 0;
|
|
8457
8549
|
}
|
|
@@ -8484,9 +8576,9 @@ function clampMinMax$1(value, _ref2) {
|
|
|
8484
8576
|
return value;
|
|
8485
8577
|
}
|
|
8486
8578
|
|
|
8487
|
-
var css_248z$e = ".
|
|
8488
|
-
var styles$e = {"pageContainer":"
|
|
8489
|
-
var stylesheet$e=".
|
|
8579
|
+
var css_248z$e = "._IluYS{height:100vh;width:100vw;display:grid;grid-template-rows:auto 1fr;grid-template-columns:auto auto 1fr;grid-template-areas:\"pageHeader pageHeader pageHeader\" \"sidebarNav configPane mainContent\"}._rEEgu{grid-area:pageHeader}._vGxAT{grid-area:mainContent;height:100%;overflow:auto}";
|
|
8580
|
+
var styles$e = {"pageContainer":"_IluYS","pageHeader":"_rEEgu","mainContent":"_vGxAT"};
|
|
8581
|
+
var stylesheet$e="._IluYS{height:100vh;width:100vw;display:grid;grid-template-rows:auto 1fr;grid-template-columns:auto auto 1fr;grid-template-areas:\"pageHeader pageHeader pageHeader\" \"sidebarNav configPane mainContent\"}._rEEgu{grid-area:pageHeader}._vGxAT{grid-area:mainContent;height:100%;overflow:auto}";
|
|
8490
8582
|
icons_index.styleInject(css_248z$e);
|
|
8491
8583
|
|
|
8492
8584
|
const PageContainer = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
@@ -8522,9 +8614,9 @@ const MainContent = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
8522
8614
|
}));
|
|
8523
8615
|
});
|
|
8524
8616
|
|
|
8525
|
-
var css_248z$d = ".
|
|
8526
|
-
var styles$d = {"pagination":"
|
|
8527
|
-
var stylesheet$d=".
|
|
8617
|
+
var css_248z$d = "._ZFLqw{display:flex;align-items:center;justify-content:center;font-size:14px;white-space:pre}._H-pNk{margin-right:8px}._ZOOVD{margin-left:8px}._Xtphj{margin:-10px -15px}._xbWQ3{width:100%;text-align:center}";
|
|
8618
|
+
var styles$d = {"pagination":"_ZFLqw","previousButton":"_H-pNk","nextButton":"_ZOOVD","btnIcon":"_Xtphj","input":"_xbWQ3"};
|
|
8619
|
+
var stylesheet$d="._ZFLqw{display:flex;align-items:center;justify-content:center;font-size:14px;white-space:pre}._H-pNk{margin-right:8px}._ZOOVD{margin-left:8px}._Xtphj{margin:-10px -15px}._xbWQ3{width:100%;text-align:center}";
|
|
8528
8620
|
icons_index.styleInject(css_248z$d);
|
|
8529
8621
|
|
|
8530
8622
|
const {
|
|
@@ -8563,19 +8655,19 @@ const PaginationPreviousButton = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
8563
8655
|
*/
|
|
8564
8656
|
const decrement = () => {
|
|
8565
8657
|
const newPage = pageInputValue - 1;
|
|
8566
|
-
setPageInputValue
|
|
8567
|
-
handlePageChange
|
|
8658
|
+
setPageInputValue === null || setPageInputValue === void 0 ? void 0 : setPageInputValue(newPage);
|
|
8659
|
+
handlePageChange === null || handlePageChange === void 0 ? void 0 : handlePageChange(newPage);
|
|
8568
8660
|
};
|
|
8569
8661
|
return /*#__PURE__*/React__default["default"].createElement(Button, _extends__default["default"]({}, rest, {
|
|
8570
|
-
disabled: disabled
|
|
8662
|
+
disabled: disabled !== null && disabled !== void 0 ? disabled : pageInputValue === 1,
|
|
8571
8663
|
ref: ref,
|
|
8572
8664
|
kind: "tertiary",
|
|
8573
8665
|
onClick: e => {
|
|
8574
|
-
onClick
|
|
8666
|
+
onClick === null || onClick === void 0 ? void 0 : onClick(e);
|
|
8575
8667
|
decrement();
|
|
8576
8668
|
},
|
|
8577
8669
|
className: classNames__default["default"](className, styles$d.previousButton),
|
|
8578
|
-
"data-testid": dataTestIdFromProps
|
|
8670
|
+
"data-testid": dataTestIdFromProps !== null && dataTestIdFromProps !== void 0 ? dataTestIdFromProps : getSubDataTestId(dataTestId, 'PreviousButton'),
|
|
8579
8671
|
"aria-label": buttonLabel
|
|
8580
8672
|
}), /*#__PURE__*/React__default["default"].createElement(icons_index.ChevronLeftIcon, {
|
|
8581
8673
|
className: styles$d.btnIcon,
|
|
@@ -8616,19 +8708,19 @@ const PaginationNextButton = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
8616
8708
|
*/
|
|
8617
8709
|
const increment = () => {
|
|
8618
8710
|
const newPage = pageInputValue + 1;
|
|
8619
|
-
setPageInputValue
|
|
8620
|
-
handlePageChange
|
|
8711
|
+
setPageInputValue === null || setPageInputValue === void 0 ? void 0 : setPageInputValue(newPage);
|
|
8712
|
+
handlePageChange === null || handlePageChange === void 0 ? void 0 : handlePageChange(newPage);
|
|
8621
8713
|
};
|
|
8622
8714
|
return /*#__PURE__*/React__default["default"].createElement(Button, _extends__default["default"]({}, rest, {
|
|
8623
|
-
disabled: disabled
|
|
8715
|
+
disabled: disabled !== null && disabled !== void 0 ? disabled : pageInputValue === numPages,
|
|
8624
8716
|
ref: ref,
|
|
8625
8717
|
kind: "tertiary",
|
|
8626
8718
|
onClick: e => {
|
|
8627
|
-
onClick
|
|
8719
|
+
onClick === null || onClick === void 0 ? void 0 : onClick(e);
|
|
8628
8720
|
increment();
|
|
8629
8721
|
},
|
|
8630
8722
|
className: classNames__default["default"](className, styles$d.nextButton),
|
|
8631
|
-
"data-testid": dataTestIdFromProps
|
|
8723
|
+
"data-testid": dataTestIdFromProps !== null && dataTestIdFromProps !== void 0 ? dataTestIdFromProps : getSubDataTestId(dataTestId, 'NextButton'),
|
|
8632
8724
|
"aria-label": buttonLabel
|
|
8633
8725
|
}), /*#__PURE__*/React__default["default"].createElement(icons_index.ChevronRightIcon, {
|
|
8634
8726
|
className: styles$d.btnIcon,
|
|
@@ -8674,7 +8766,8 @@ const PaginationPageInput = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
8674
8766
|
* Computes the width of the input based on the number of characters entered
|
|
8675
8767
|
*/
|
|
8676
8768
|
const inputWidth = React.useMemo(() => {
|
|
8677
|
-
|
|
8769
|
+
var _currentPage$toString;
|
|
8770
|
+
const numDigits = (_currentPage$toString = currentPage === null || currentPage === void 0 ? void 0 : currentPage.toString().length) !== null && _currentPage$toString !== void 0 ? _currentPage$toString : 0;
|
|
8678
8771
|
const minWidth = 36;
|
|
8679
8772
|
return numDigits > 2 ? 9 * (numDigits - 2) + minWidth : minWidth;
|
|
8680
8773
|
}, [currentPage]);
|
|
@@ -8684,7 +8777,7 @@ const PaginationPageInput = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
8684
8777
|
*/
|
|
8685
8778
|
const handleBlur = () => {
|
|
8686
8779
|
if (pageInputValue !== currentPage && currentPage !== undefined) {
|
|
8687
|
-
setPageInputValue
|
|
8780
|
+
setPageInputValue === null || setPageInputValue === void 0 ? void 0 : setPageInputValue(currentPage);
|
|
8688
8781
|
}
|
|
8689
8782
|
};
|
|
8690
8783
|
|
|
@@ -8695,11 +8788,11 @@ const PaginationPageInput = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
8695
8788
|
*/
|
|
8696
8789
|
const handleInputChange = newValue => {
|
|
8697
8790
|
if (newValue === '' || !Number.isInteger(Number(newValue))) {
|
|
8698
|
-
setPageInputValue
|
|
8791
|
+
setPageInputValue === null || setPageInputValue === void 0 ? void 0 : setPageInputValue(newValue);
|
|
8699
8792
|
} else {
|
|
8700
8793
|
const newPage = Math.min(Math.max(1, newValue), numPages || Number.MAX_SAFE_INTEGER);
|
|
8701
|
-
setPageInputValue
|
|
8702
|
-
handlePageChange
|
|
8794
|
+
setPageInputValue === null || setPageInputValue === void 0 ? void 0 : setPageInputValue(newPage);
|
|
8795
|
+
handlePageChange === null || handlePageChange === void 0 ? void 0 : handlePageChange(newPage);
|
|
8703
8796
|
}
|
|
8704
8797
|
};
|
|
8705
8798
|
|
|
@@ -8707,7 +8800,8 @@ const PaginationPageInput = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
8707
8800
|
* If there is a ref to the input, selects all text within the input
|
|
8708
8801
|
*/
|
|
8709
8802
|
const handleFocus = () => {
|
|
8710
|
-
|
|
8803
|
+
var _inputRef$current;
|
|
8804
|
+
(_inputRef$current = inputRef.current) === null || _inputRef$current === void 0 ? void 0 : _inputRef$current.select();
|
|
8711
8805
|
};
|
|
8712
8806
|
return /*#__PURE__*/React__default["default"].createElement(Translate, {
|
|
8713
8807
|
messageKey: "pagination",
|
|
@@ -8725,15 +8819,15 @@ const PaginationPageInput = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
8725
8819
|
max: numPages,
|
|
8726
8820
|
value: pageInputValue,
|
|
8727
8821
|
onChange: e => {
|
|
8728
|
-
onChange
|
|
8822
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(e);
|
|
8729
8823
|
handleInputChange(e.target.value);
|
|
8730
8824
|
},
|
|
8731
8825
|
onBlur: e => {
|
|
8732
|
-
onBlur
|
|
8826
|
+
onBlur === null || onBlur === void 0 ? void 0 : onBlur(e);
|
|
8733
8827
|
handleBlur();
|
|
8734
8828
|
},
|
|
8735
8829
|
onFocus: e => {
|
|
8736
|
-
onFocus
|
|
8830
|
+
onFocus === null || onFocus === void 0 ? void 0 : onFocus(e);
|
|
8737
8831
|
handleFocus();
|
|
8738
8832
|
},
|
|
8739
8833
|
style: {
|
|
@@ -8792,7 +8886,7 @@ const Pagination = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref)
|
|
|
8792
8886
|
* @param {Number} newPage - The value entered into the input
|
|
8793
8887
|
*/
|
|
8794
8888
|
const handlePageChange = React.useCallback(newPage => {
|
|
8795
|
-
onPageChange
|
|
8889
|
+
onPageChange === null || onPageChange === void 0 ? void 0 : onPageChange({
|
|
8796
8890
|
page: newPage
|
|
8797
8891
|
});
|
|
8798
8892
|
}, [onPageChange]);
|
|
@@ -8818,9 +8912,9 @@ const Pagination = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref)
|
|
|
8818
8912
|
}, children || /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, /*#__PURE__*/React__default["default"].createElement(PaginationPreviousButton, null), Number(numPages) > 0 ? /*#__PURE__*/React__default["default"].createElement(PaginationPageInput, null) : null, /*#__PURE__*/React__default["default"].createElement(PaginationNextButton, null))));
|
|
8819
8913
|
});
|
|
8820
8914
|
|
|
8821
|
-
var css_248z$c = ".
|
|
8822
|
-
var styles$c = {"popover":"
|
|
8823
|
-
var stylesheet$c=".
|
|
8915
|
+
var css_248z$c = "._ti2on{position:absolute;z-index:1000;background-color:#fff;border-radius:4px;display:inline-block;box-shadow:0 3px 4px 0 rgba(0,0,0,.05),0 6px 10px 0 rgba(0,0,0,.05);border:1px solid #898989}._ti2on:focus{outline:none}._hIfkA,._hIfkA>div{position:absolute;width:8px;height:8px;background:inherit}._hIfkA{visibility:hidden;z-index:1000}._hIfkA>div{visibility:visible;border:1px solid #898989;transform:rotate(45deg)}[data-popper-placement^=top]>._hIfkA{bottom:-4px}[data-popper-placement^=top]>._hIfkA>div{border-top-color:transparent;border-left-color:transparent}[data-popper-placement^=right]>._hIfkA{left:-5px}[data-popper-placement^=right]>._hIfkA>div{border-top-color:transparent;border-right-color:transparent}[data-popper-placement^=bottom]>._hIfkA{top:-5px}[data-popper-placement^=bottom]>._hIfkA>div{border-bottom-color:transparent;border-right-color:transparent}[data-popper-placement^=left]>._hIfkA{right:-4px}[data-popper-placement^=left]>._hIfkA>div{border-bottom-color:transparent;border-left-color:transparent}";
|
|
8916
|
+
var styles$c = {"popover":"_ti2on","arrow":"_hIfkA"};
|
|
8917
|
+
var stylesheet$c="._ti2on{position:absolute;z-index:1000;background-color:#fff;border-radius:4px;display:inline-block;box-shadow:0 3px 4px 0 rgba(0,0,0,.05),0 6px 10px 0 rgba(0,0,0,.05);border:1px solid #898989}._ti2on:focus{outline:none}._hIfkA,._hIfkA>div{position:absolute;width:8px;height:8px;background:inherit}._hIfkA{visibility:hidden;z-index:1000}._hIfkA>div{visibility:visible;border:1px solid #898989;transform:rotate(45deg)}[data-popper-placement^=top]>._hIfkA{bottom:-4px}[data-popper-placement^=top]>._hIfkA>div{border-top-color:transparent;border-left-color:transparent}[data-popper-placement^=right]>._hIfkA{left:-5px}[data-popper-placement^=right]>._hIfkA>div{border-top-color:transparent;border-right-color:transparent}[data-popper-placement^=bottom]>._hIfkA{top:-5px}[data-popper-placement^=bottom]>._hIfkA>div{border-bottom-color:transparent;border-right-color:transparent}[data-popper-placement^=left]>._hIfkA{right:-4px}[data-popper-placement^=left]>._hIfkA>div{border-bottom-color:transparent;border-left-color:transparent}";
|
|
8824
8918
|
icons_index.styleInject(css_248z$c);
|
|
8825
8919
|
|
|
8826
8920
|
const Popover = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
@@ -8844,7 +8938,7 @@ const Popover = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =>
|
|
|
8844
8938
|
const classes = classNames__default["default"](styles$c.popover, className);
|
|
8845
8939
|
const anchorRef = React.useRef();
|
|
8846
8940
|
const popperRef = React.useRef(null);
|
|
8847
|
-
const preventClickOutside = useClickOutsidePortals(e => show && onClickOutside
|
|
8941
|
+
const preventClickOutside = useClickOutsidePortals(e => show && (onClickOutside === null || onClickOutside === void 0 ? void 0 : onClickOutside(e)));
|
|
8848
8942
|
const [isInDOM, setIsInDOM] = React.useState(false);
|
|
8849
8943
|
const popoverId = useId(externalId);
|
|
8850
8944
|
|
|
@@ -8861,22 +8955,23 @@ const Popover = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =>
|
|
|
8861
8955
|
* 2. A user in Safari clicks on 1 or more `Popover` anchor elements and then presses the `Escape` key. This is because buttons aren't focused on `click` or `mousedown` in Safari by default.
|
|
8862
8956
|
*/
|
|
8863
8957
|
if (!show && isInDOM) {
|
|
8958
|
+
var _anchorRef$current;
|
|
8864
8959
|
// Prevents scroll so that the page does not scroll to the anchor element if the anchor element is out of view
|
|
8865
|
-
anchorRef.current
|
|
8960
|
+
(_anchorRef$current = anchorRef.current) === null || _anchorRef$current === void 0 ? void 0 : _anchorRef$current.focus({
|
|
8866
8961
|
preventScroll: true
|
|
8867
8962
|
});
|
|
8868
8963
|
}
|
|
8869
8964
|
setIsInDOM(show);
|
|
8870
8965
|
}, [show, isInDOM]);
|
|
8871
8966
|
const handlePopoverContainerClick = e => {
|
|
8872
|
-
onClick
|
|
8967
|
+
onClick === null || onClick === void 0 ? void 0 : onClick(e);
|
|
8873
8968
|
};
|
|
8874
8969
|
const handlePopoverContainerKeyDown = e => {
|
|
8875
8970
|
if (e.key === 'Escape') {
|
|
8876
8971
|
e.stopPropagation(); // prevent event from closing modals or popovers
|
|
8877
|
-
onClose
|
|
8972
|
+
onClose === null || onClose === void 0 ? void 0 : onClose(e);
|
|
8878
8973
|
}
|
|
8879
|
-
onKeyDown
|
|
8974
|
+
onKeyDown === null || onKeyDown === void 0 ? void 0 : onKeyDown(e);
|
|
8880
8975
|
};
|
|
8881
8976
|
return /*#__PURE__*/React__default["default"].createElement(Popper, {
|
|
8882
8977
|
open: show,
|
|
@@ -8889,6 +8984,7 @@ const Popover = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =>
|
|
|
8889
8984
|
'aria-expanded': show,
|
|
8890
8985
|
'aria-controls': show ? popoverId : undefined,
|
|
8891
8986
|
onMouseDown: e => {
|
|
8987
|
+
var _children$props$onMou, _children$props;
|
|
8892
8988
|
/*
|
|
8893
8989
|
* Prevents the anchor element from getting focus (only in some browsers).
|
|
8894
8990
|
* If a Popover is open and out of view, and another button is clicked, this prevents the browser from scrolling to the open Popover.
|
|
@@ -8896,9 +8992,9 @@ const Popover = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =>
|
|
|
8896
8992
|
*/
|
|
8897
8993
|
e.preventDefault();
|
|
8898
8994
|
preventClickOutside();
|
|
8899
|
-
children.props.onMouseDown
|
|
8995
|
+
(_children$props$onMou = (_children$props = children.props).onMouseDown) === null || _children$props$onMou === void 0 ? void 0 : _children$props$onMou.call(_children$props, e);
|
|
8900
8996
|
},
|
|
8901
|
-
ref: mergeRefs(anchorRef, children
|
|
8997
|
+
ref: mergeRefs(anchorRef, children === null || children === void 0 ? void 0 : children.ref)
|
|
8902
8998
|
}),
|
|
8903
8999
|
popper: /*#__PURE__*/React__default["default"].createElement("div", _extends__default["default"]({}, rest, {
|
|
8904
9000
|
ref: mergeRefs(ref, popperRef),
|
|
@@ -8934,9 +9030,9 @@ const Popover = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =>
|
|
|
8934
9030
|
});
|
|
8935
9031
|
});
|
|
8936
9032
|
|
|
8937
|
-
var css_248z$b = ".
|
|
8938
|
-
var styles$b = {"loadingSpinner":"
|
|
8939
|
-
var stylesheet$b=".
|
|
9033
|
+
var css_248z$b = "._zL-re{display:flex;height:32px}";
|
|
9034
|
+
var styles$b = {"loadingSpinner":"_zL-re"};
|
|
9035
|
+
var stylesheet$b="._zL-re{display:flex;height:32px}";
|
|
8940
9036
|
icons_index.styleInject(css_248z$b);
|
|
8941
9037
|
|
|
8942
9038
|
const QuickSearchInput = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
@@ -8972,11 +9068,11 @@ const QuickSearchInput = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
8972
9068
|
if (!open) {
|
|
8973
9069
|
setIsLoading(true);
|
|
8974
9070
|
}
|
|
8975
|
-
setIsOpen
|
|
9071
|
+
setIsOpen === null || setIsOpen === void 0 ? void 0 : setIsOpen(true);
|
|
8976
9072
|
};
|
|
8977
9073
|
const closeMenu = React.useCallback(() => {
|
|
8978
9074
|
setItems([]);
|
|
8979
|
-
internalCloseMenu
|
|
9075
|
+
internalCloseMenu === null || internalCloseMenu === void 0 ? void 0 : internalCloseMenu();
|
|
8980
9076
|
setIsLoading(true);
|
|
8981
9077
|
}, [setItems, internalCloseMenu, setIsLoading]);
|
|
8982
9078
|
const onSearchRef = useLatest(onSearch);
|
|
@@ -9006,14 +9102,14 @@ const QuickSearchInput = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
9006
9102
|
if (e.key === 'Enter' || e.key === 'ArrowDown') {
|
|
9007
9103
|
e.preventDefault(); // prevent scroll
|
|
9008
9104
|
openMenu();
|
|
9009
|
-
setHighlightedIndex
|
|
9105
|
+
setHighlightedIndex === null || setHighlightedIndex === void 0 ? void 0 : setHighlightedIndex(0);
|
|
9010
9106
|
if (!open) {
|
|
9011
9107
|
handleSearch(value);
|
|
9012
9108
|
}
|
|
9013
9109
|
} else if (e.key === 'ArrowUp') {
|
|
9014
9110
|
e.preventDefault(); // prevent scroll
|
|
9015
9111
|
openMenu();
|
|
9016
|
-
setHighlightedIndex
|
|
9112
|
+
setHighlightedIndex === null || setHighlightedIndex === void 0 ? void 0 : setHighlightedIndex(items.length - 1);
|
|
9017
9113
|
if (!open) {
|
|
9018
9114
|
handleSearch(value);
|
|
9019
9115
|
}
|
|
@@ -9061,6 +9157,7 @@ const QuickSearchInput = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
9061
9157
|
});
|
|
9062
9158
|
|
|
9063
9159
|
const QuickSearch = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
9160
|
+
var _anchorRef$current;
|
|
9064
9161
|
let {
|
|
9065
9162
|
maxHeight: externalMaxHeight,
|
|
9066
9163
|
menuProps,
|
|
@@ -9076,7 +9173,7 @@ const QuickSearch = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
9076
9173
|
const [items, setItems] = React.useState([]);
|
|
9077
9174
|
const maxHeight = items.length > 10 ? 500 : undefined;
|
|
9078
9175
|
const anchorRef = React.useRef(null);
|
|
9079
|
-
const anchorWidth = anchorRef
|
|
9176
|
+
const anchorWidth = anchorRef === null || anchorRef === void 0 || (_anchorRef$current = anchorRef.current) === null || _anchorRef$current === void 0 ? void 0 : _anchorRef$current.clientWidth;
|
|
9080
9177
|
const {
|
|
9081
9178
|
translate
|
|
9082
9179
|
} = useTranslation();
|
|
@@ -9089,7 +9186,7 @@ const QuickSearch = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
9089
9186
|
portalTarget: portalTarget,
|
|
9090
9187
|
zIndex: zIndex,
|
|
9091
9188
|
anchor: /*#__PURE__*/React__default["default"].createElement(QuickSearchInput, _extends__default["default"]({}, rest, {
|
|
9092
|
-
role: role
|
|
9189
|
+
role: role !== null && role !== void 0 ? role : 'searchbox',
|
|
9093
9190
|
ref: mergeRefs(ref, anchorRef),
|
|
9094
9191
|
setIsLoading: setIsLoading,
|
|
9095
9192
|
items: items,
|
|
@@ -9106,14 +9203,14 @@ const QuickSearch = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
9106
9203
|
return /*#__PURE__*/React__default["default"].createElement(MenuItem, {
|
|
9107
9204
|
key: index,
|
|
9108
9205
|
value: value,
|
|
9109
|
-
onSelect: () => onSelect
|
|
9206
|
+
onSelect: () => onSelect === null || onSelect === void 0 ? void 0 : onSelect(item)
|
|
9110
9207
|
}, label);
|
|
9111
9208
|
}));
|
|
9112
9209
|
});
|
|
9113
9210
|
|
|
9114
|
-
var css_248z$a = ".
|
|
9115
|
-
var styles$a = {"radio":"
|
|
9116
|
-
var stylesheet$a=".
|
|
9211
|
+
var css_248z$a = "._nAppc{display:inline-flex;position:relative;margin-top:6px;margin-bottom:6px}._nAppc,._ZJD1h{cursor:pointer;height:16px;width:16px}._ZJD1h{position:absolute;opacity:0;z-index:10}._ZJD1h:checked~._f90ej>._p16VW{fill-opacity:1}._ZJD1h:checked:enabled~._f90ej{border-color:transparent;background-color:#0b6ed0}._ZJD1h:checked:enabled~._f90ej>._p16VW{fill:#fff}._ZJD1h:checked:enabled:hover~._f90ej{background-color:#085caf}._ZJD1h:not(:checked):enabled:hover~._f90ej{border-color:#0b6ed0}._ZJD1h:disabled{cursor:not-allowed}._ZJD1h:disabled~._f90ej{opacity:.4}._ZJD1h:checked~._f90ej:after{content:\"\"}._E6tZo{color:#32363a;display:flex;align-items:center;cursor:pointer}._PWMen{cursor:auto;color:hsla(0,0%,53.7%,.4)}._l1MPV{margin-right:12px;flex-shrink:0}._f90ej{display:flex;align-items:center;justify-content:center;position:absolute;top:0;left:0;height:16px;width:16px;background-color:#fff;border-radius:4px;border:1px solid #898989;z-index:0;border-radius:50%;background-color:transparent!important;border-color:#898989!important}._p16VW{fill:#0b6ed0;fill-opacity:0}._f90ej:after{position:absolute;z-index:0;background-color:#0b6ed0;border-radius:50%;height:10px;width:10px;top:2px;left:2px}._WHodw{border:none;padding:0;margin:0}._bgbJ7{padding:0;margin:0 0 14px;color:#01213f}._ZJD1h.focus-visible~._f90ej,._ZJD1h:focus-visible~._f90ej{border-color:#0b6ed0;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
9212
|
+
var styles$a = {"radio":"_nAppc","input":"_ZJD1h","check":"_f90ej","checkIcon":"_p16VW","label":"_E6tZo","labelDisabled":"_PWMen","wrappedInput":"_l1MPV","radioGroup":"_WHodw","legend":"_bgbJ7"};
|
|
9213
|
+
var stylesheet$a="._nAppc{display:inline-flex;position:relative;margin-top:6px;margin-bottom:6px}._nAppc,._ZJD1h{cursor:pointer;height:16px;width:16px}._ZJD1h{position:absolute;opacity:0;z-index:10}._ZJD1h:checked~._f90ej>._p16VW{fill-opacity:1}._ZJD1h:checked:enabled~._f90ej{border-color:transparent;background-color:#0b6ed0}._ZJD1h:checked:enabled~._f90ej>._p16VW{fill:#fff}._ZJD1h:checked:enabled:hover~._f90ej{background-color:#085caf}._ZJD1h:not(:checked):enabled:hover~._f90ej{border-color:#0b6ed0}._ZJD1h:disabled{cursor:not-allowed}._ZJD1h:disabled~._f90ej{opacity:.4}._ZJD1h:checked~._f90ej:after{content:\"\"}._E6tZo{color:#32363a;display:flex;align-items:center;cursor:pointer}._PWMen{cursor:auto;color:hsla(0,0%,53.7%,.4)}._l1MPV{margin-right:12px;flex-shrink:0}._f90ej{display:flex;align-items:center;justify-content:center;position:absolute;top:0;left:0;height:16px;width:16px;background-color:#fff;border-radius:4px;border:1px solid #898989;z-index:0;border-radius:50%;background-color:transparent!important;border-color:#898989!important}._p16VW{fill:#0b6ed0;fill-opacity:0}._f90ej:after{position:absolute;z-index:0;background-color:#0b6ed0;border-radius:50%;height:10px;width:10px;top:2px;left:2px}._WHodw{border:none;padding:0;margin:0}._bgbJ7{padding:0;margin:0 0 14px;color:#01213f}._ZJD1h.focus-visible~._f90ej,._ZJD1h:focus-visible~._f90ej{border-color:#0b6ed0;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
9117
9214
|
icons_index.styleInject(css_248z$a);
|
|
9118
9215
|
|
|
9119
9216
|
const {
|
|
@@ -9122,6 +9219,7 @@ const {
|
|
|
9122
9219
|
} = createContextUtilities({});
|
|
9123
9220
|
|
|
9124
9221
|
const Radio = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
9222
|
+
var _ref2;
|
|
9125
9223
|
let {
|
|
9126
9224
|
id,
|
|
9127
9225
|
className,
|
|
@@ -9146,25 +9244,25 @@ const Radio = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
|
9146
9244
|
helperTextId: formFieldHelperTextId,
|
|
9147
9245
|
errorTextId: formFieldErrorTextId
|
|
9148
9246
|
} = useFormFieldContext();
|
|
9149
|
-
const internalAriaDescribedby = concatIds(externalAriaDescribedBy, formFieldHelperTextId, formFieldErrorTextId, inputProps
|
|
9150
|
-
const checked = groupValue !== undefined ? value === groupValue : radioChecked
|
|
9151
|
-
const defaultChecked = groupDefaultValue !== undefined ? value === groupDefaultValue : radioDefaultChecked
|
|
9152
|
-
const onChange = radioGroupOnChange
|
|
9247
|
+
const internalAriaDescribedby = concatIds(externalAriaDescribedBy, formFieldHelperTextId, formFieldErrorTextId, inputProps === null || inputProps === void 0 ? void 0 : inputProps['aria-describedby']);
|
|
9248
|
+
const checked = groupValue !== undefined ? value === groupValue : radioChecked !== null && radioChecked !== void 0 ? radioChecked : inputProps === null || inputProps === void 0 ? void 0 : inputProps.checked;
|
|
9249
|
+
const defaultChecked = groupDefaultValue !== undefined ? value === groupDefaultValue : radioDefaultChecked !== null && radioDefaultChecked !== void 0 ? radioDefaultChecked : inputProps === null || inputProps === void 0 ? void 0 : inputProps.defaultChecked;
|
|
9250
|
+
const onChange = (_ref2 = radioGroupOnChange !== null && radioGroupOnChange !== void 0 ? radioGroupOnChange : radioOnChange) !== null && _ref2 !== void 0 ? _ref2 : inputProps === null || inputProps === void 0 ? void 0 : inputProps.onChange;
|
|
9153
9251
|
return /*#__PURE__*/React__default["default"].createElement("span", _extends__default["default"]({}, rest, {
|
|
9154
9252
|
ref: ref,
|
|
9155
9253
|
className: classNames__default["default"](className, styles$a.radio)
|
|
9156
9254
|
}), /*#__PURE__*/React__default["default"].createElement("input", _extends__default["default"]({}, inputProps, {
|
|
9157
|
-
className: classNames__default["default"](styles$a.input, inputProps
|
|
9255
|
+
className: classNames__default["default"](styles$a.input, inputProps === null || inputProps === void 0 ? void 0 : inputProps.className),
|
|
9158
9256
|
type: "radio",
|
|
9159
|
-
id: id
|
|
9257
|
+
id: id !== null && id !== void 0 ? id : inputProps === null || inputProps === void 0 ? void 0 : inputProps.id,
|
|
9160
9258
|
checked: checked,
|
|
9161
9259
|
defaultChecked: defaultChecked,
|
|
9162
|
-
disabled: disabled
|
|
9163
|
-
name: name
|
|
9164
|
-
value: value
|
|
9260
|
+
disabled: disabled !== null && disabled !== void 0 ? disabled : inputProps === null || inputProps === void 0 ? void 0 : inputProps.disabled,
|
|
9261
|
+
name: name !== null && name !== void 0 ? name : inputProps === null || inputProps === void 0 ? void 0 : inputProps.name,
|
|
9262
|
+
value: value !== null && value !== void 0 ? value : inputProps === null || inputProps === void 0 ? void 0 : inputProps.value,
|
|
9165
9263
|
onChange: disabled ? undefined : onChange,
|
|
9166
|
-
"aria-label": ariaLabel
|
|
9167
|
-
"aria-labelledby": ariaLabelledBy
|
|
9264
|
+
"aria-label": ariaLabel !== null && ariaLabel !== void 0 ? ariaLabel : inputProps === null || inputProps === void 0 ? void 0 : inputProps['aria-label'],
|
|
9265
|
+
"aria-labelledby": ariaLabelledBy !== null && ariaLabelledBy !== void 0 ? ariaLabelledBy : inputProps === null || inputProps === void 0 ? void 0 : inputProps['aria-labelledby'],
|
|
9168
9266
|
"aria-describedby": internalAriaDescribedby
|
|
9169
9267
|
})), /*#__PURE__*/React__default["default"].createElement("span", {
|
|
9170
9268
|
className: styles$a.check
|
|
@@ -9225,9 +9323,9 @@ const RadioGroup = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref)
|
|
|
9225
9323
|
}, label), children));
|
|
9226
9324
|
});
|
|
9227
9325
|
|
|
9228
|
-
var css_248z$9 = ".
|
|
9229
|
-
var styles$9 = {"searchInput":"
|
|
9230
|
-
var stylesheet$9=".
|
|
9326
|
+
var css_248z$9 = "._T-2qa{display:inline-block;position:relative}._gbn53._gbn53{padding-left:36px;padding-right:36px;width:100%}._gbn53._gbn53:disabled+._zFkOa{fill-opacity:.6}._zFkOa{position:absolute;top:50%;left:0;transform:translateY(-50%);margin-left:6px;fill:#515559;pointer-events:none}._zFkOa._dMORJ{z-index:20}._7zbkP{position:absolute;top:0;right:0;width:36px;height:100%;background-color:transparent;line-height:0;border:none;border-radius:4px}._7zbkP:hover{cursor:pointer}._7zbkP:hover>._v158J{fill:#32363a}._7zbkP:focus{outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._v158J{fill:#515559}";
|
|
9327
|
+
var styles$9 = {"searchInput":"_T-2qa","searchInputInput":"_gbn53","searchInputSearchIcon":"_zFkOa","usedWithinInputGroup":"_dMORJ","searchInputClearButton":"_7zbkP","searchInputClearButtonIcon":"_v158J"};
|
|
9328
|
+
var stylesheet$9="._T-2qa{display:inline-block;position:relative}._gbn53._gbn53{padding-left:36px;padding-right:36px;width:100%}._gbn53._gbn53:disabled+._zFkOa{fill-opacity:.6}._zFkOa{position:absolute;top:50%;left:0;transform:translateY(-50%);margin-left:6px;fill:#515559;pointer-events:none}._zFkOa._dMORJ{z-index:20}._7zbkP{position:absolute;top:0;right:0;width:36px;height:100%;background-color:transparent;line-height:0;border:none;border-radius:4px}._7zbkP:hover{cursor:pointer}._7zbkP:hover>._v158J{fill:#32363a}._7zbkP:focus{outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._v158J{fill:#515559}";
|
|
9231
9329
|
icons_index.styleInject(css_248z$9);
|
|
9232
9330
|
|
|
9233
9331
|
const SearchInput = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
@@ -9261,7 +9359,8 @@ const SearchInput = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
9261
9359
|
// Focuses the input after the input value is cleared so that screen readers see that the input doesn't have a value
|
|
9262
9360
|
React.useEffect(() => {
|
|
9263
9361
|
if (wasInputValueCleared) {
|
|
9264
|
-
|
|
9362
|
+
var _inputRef$current;
|
|
9363
|
+
(_inputRef$current = inputRef.current) === null || _inputRef$current === void 0 ? void 0 : _inputRef$current.focus();
|
|
9265
9364
|
setWasInputValueCleared(false);
|
|
9266
9365
|
}
|
|
9267
9366
|
}, [wasInputValueCleared]);
|
|
@@ -9280,7 +9379,7 @@ const SearchInput = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
9280
9379
|
|
|
9281
9380
|
clearInputText();
|
|
9282
9381
|
}
|
|
9283
|
-
onKeyDown
|
|
9382
|
+
onKeyDown === null || onKeyDown === void 0 ? void 0 : onKeyDown(e);
|
|
9284
9383
|
};
|
|
9285
9384
|
return /*#__PURE__*/React__default["default"].createElement("span", {
|
|
9286
9385
|
className: classNames__default["default"](styles$9.searchInput, className),
|
|
@@ -9289,7 +9388,7 @@ const SearchInput = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
9289
9388
|
role: "searchbox",
|
|
9290
9389
|
id: id,
|
|
9291
9390
|
className: styles$9.searchInputInput,
|
|
9292
|
-
placeholder: placeholder
|
|
9391
|
+
placeholder: placeholder !== null && placeholder !== void 0 ? placeholder : translate('searchText'),
|
|
9293
9392
|
value: inputValue,
|
|
9294
9393
|
onChange: handleInputChange,
|
|
9295
9394
|
onKeyDown: handleInputKeyDown,
|
|
@@ -9327,9 +9426,9 @@ const SearchInput = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
9327
9426
|
|
|
9328
9427
|
/* eslint-disable import/prefer-default-export */
|
|
9329
9428
|
|
|
9330
|
-
var css_248z$8 = ".
|
|
9331
|
-
var styles$8 = {"sideBarNav":"
|
|
9332
|
-
var stylesheet$8=".
|
|
9429
|
+
var css_248z$8 = "._0yLIR{grid-area:sidebarNav;height:100%;display:flex;flex-direction:column;align-items:center;min-width:165px;max-width:240px;background-color:#fff;border-right:1px solid #eee;overflow:hidden}._0yLIR._3MOZB{width:69px;min-width:auto;max-width:none}._FXJiW{margin:12px 0 28px;width:100%;overflow:auto;padding:4px 16px 0}._ao5at{margin-bottom:12px;background-color:transparent!important}._ao5at:hover{background-color:rgba(11,110,208,.08)!important}._ao5at:hover ._2okHE{fill:#085caf}._ao5at:hover ._Ct9-y{color:#085caf}._ao5at:active{background-color:rgba(11,110,208,.12)!important}._ao5at:active ._2okHE{fill:#0854a1}._ao5at:active ._Ct9-y{color:#0854a1}._ao5at._05Ze3{background-color:rgba(11,110,208,.08)!important}._ao5at._05Ze3 ._2okHE{fill:#0b6ed0}._ao5at._05Ze3 ._Ct9-y{color:#0b6ed0;font-family:\"72Duplex\",\"72\",\"Helvetica Neue\",Helvetica,Arial,sans-serif;font-weight:500}._ao5at._05Ze3:hover{background-color:rgba(11,110,208,.08)!important}._ao5at._05Ze3:hover ._2okHE{fill:#085caf}._ao5at._05Ze3:hover ._Ct9-y{color:#085caf}._ao5at._05Ze3:active{background-color:rgba(11,110,208,.12)!important}._ao5at._05Ze3:active ._2okHE{fill:#0854a1}._ao5at._05Ze3:active ._Ct9-y{color:#0854a1}._2Ynby{border-radius:6px}._2Ynby ._2okHE{display:block;fill:#515559}._dOt2a{width:100%;padding:0 16px;margin-top:auto;margin-bottom:0}._Cp-0t,._k6-lt{width:100%;display:flex;align-items:start;border:1px solid transparent;border-radius:6px;outline:none;cursor:pointer;padding:5px 11px 5px 5px;text-decoration:none}._Cp-0t ._2okHE,._k6-lt ._2okHE{fill:#515559}._Cp-0t ._Ct9-y,._k6-lt ._Ct9-y{font-size:14px;line-height:19px;color:#515559;overflow:hidden;overflow-wrap:break-word;margin:2.5px 0 2.5px 6px}._ao5at.focus-visible,._ao5at:focus-visible{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
9430
|
+
var styles$8 = {"sideBarNav":"_0yLIR","collapsed":"_3MOZB","navItems":"_FXJiW","sidebarNavItem":"_ao5at","icon":"_2okHE","label":"_Ct9-y","selected":"_05Ze3","sidebarNavItemIconButton":"_2Ynby","expandCollapseButtonContainer":"_dOt2a","navLink":"_Cp-0t","iconButtonWithLabel":"_k6-lt"};
|
|
9431
|
+
var stylesheet$8="._0yLIR{grid-area:sidebarNav;height:100%;display:flex;flex-direction:column;align-items:center;min-width:165px;max-width:240px;background-color:#fff;border-right:1px solid #eee;overflow:hidden}._0yLIR._3MOZB{width:69px;min-width:auto;max-width:none}._FXJiW{margin:12px 0 28px;width:100%;overflow:auto;padding:4px 16px 0}._ao5at{margin-bottom:12px;background-color:transparent!important}._ao5at:hover{background-color:rgba(11,110,208,.08)!important}._ao5at:hover ._2okHE{fill:#085caf}._ao5at:hover ._Ct9-y{color:#085caf}._ao5at:active{background-color:rgba(11,110,208,.12)!important}._ao5at:active ._2okHE{fill:#0854a1}._ao5at:active ._Ct9-y{color:#0854a1}._ao5at._05Ze3{background-color:rgba(11,110,208,.08)!important}._ao5at._05Ze3 ._2okHE{fill:#0b6ed0}._ao5at._05Ze3 ._Ct9-y{color:#0b6ed0;font-family:\"72Duplex\",\"72\",\"Helvetica Neue\",Helvetica,Arial,sans-serif;font-weight:500}._ao5at._05Ze3:hover{background-color:rgba(11,110,208,.08)!important}._ao5at._05Ze3:hover ._2okHE{fill:#085caf}._ao5at._05Ze3:hover ._Ct9-y{color:#085caf}._ao5at._05Ze3:active{background-color:rgba(11,110,208,.12)!important}._ao5at._05Ze3:active ._2okHE{fill:#0854a1}._ao5at._05Ze3:active ._Ct9-y{color:#0854a1}._2Ynby{border-radius:6px}._2Ynby ._2okHE{display:block;fill:#515559}._dOt2a{width:100%;padding:0 16px;margin-top:auto;margin-bottom:0}._Cp-0t,._k6-lt{width:100%;display:flex;align-items:start;border:1px solid transparent;border-radius:6px;outline:none;cursor:pointer;padding:5px 11px 5px 5px;text-decoration:none}._Cp-0t ._2okHE,._k6-lt ._2okHE{fill:#515559}._Cp-0t ._Ct9-y,._k6-lt ._Ct9-y{font-size:14px;line-height:19px;color:#515559;overflow:hidden;overflow-wrap:break-word;margin:2.5px 0 2.5px 6px}._ao5at.focus-visible,._ao5at:focus-visible{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
9333
9432
|
icons_index.styleInject(css_248z$8);
|
|
9334
9433
|
|
|
9335
9434
|
const {
|
|
@@ -9406,7 +9505,8 @@ const SidebarNav = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
9406
9505
|
*/
|
|
9407
9506
|
React.useEffect(() => {
|
|
9408
9507
|
if (isExpandCollapseButtonFocused) {
|
|
9409
|
-
|
|
9508
|
+
var _expandCollapseButton;
|
|
9509
|
+
(_expandCollapseButton = expandCollapseButtonRef.current) === null || _expandCollapseButton === void 0 ? void 0 : _expandCollapseButton.focus();
|
|
9410
9510
|
}
|
|
9411
9511
|
}, [isCollapsed, isExpandCollapseButtonFocused]);
|
|
9412
9512
|
return /*#__PURE__*/React__default["default"].createElement("div", {
|
|
@@ -9452,7 +9552,7 @@ const SidebarNavLink = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
9452
9552
|
isCollapsed,
|
|
9453
9553
|
NavLink
|
|
9454
9554
|
} = useSidebarNavContext();
|
|
9455
|
-
const Icon = isCollapsed ? icon
|
|
9555
|
+
const Icon = isCollapsed ? icon !== null && icon !== void 0 ? icon : icons_index.ExcludeIcon : icon;
|
|
9456
9556
|
const link = /*#__PURE__*/React__default["default"].createElement(NavLink, {
|
|
9457
9557
|
className: isActive => classNames__default["default"](styles$8.sidebarNavItem, styles$8.navLink, {
|
|
9458
9558
|
[styles$8.noIcon]: !Icon,
|
|
@@ -9483,9 +9583,9 @@ const SidebarNavLink = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
9483
9583
|
return link;
|
|
9484
9584
|
});
|
|
9485
9585
|
|
|
9486
|
-
var css_248z$7 = ".
|
|
9487
|
-
var styles$7 = {"slider":"
|
|
9488
|
-
var stylesheet$7=".
|
|
9586
|
+
var css_248z$7 = "._Khqzg{height:auto;width:200px;padding:5px 10px}._oT52q{position:relative;height:10px;border:1px solid #898989;border-radius:5px;background:#fafafa}._URu9p{top:-1px;bottom:-1px;background-color:#007ac0;border:1px solid #007ac0;border-radius:5px}._ug4QF,._URu9p{position:absolute}._ug4QF{top:-5px;left:-10px;border:1px solid #007ac0;overflow:visible;width:18px;height:18px;padding:0;margin:0;border-radius:9px;cursor:pointer;display:inline-block;text-align:center;background:#fff;text-decoration:none;outline:none}._ug4QF:before{content:\"\";position:absolute;top:4px;left:4px;background:#007ac0;width:8px;height:8px;border-radius:10px}._ug4QF.focus-visible,._ug4QF:focus-visible{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
9587
|
+
var styles$7 = {"slider":"_Khqzg","track":"_oT52q","fill":"_URu9p","button":"_ug4QF"};
|
|
9588
|
+
var stylesheet$7="._Khqzg{height:auto;width:200px;padding:5px 10px}._oT52q{position:relative;height:10px;border:1px solid #898989;border-radius:5px;background:#fafafa}._URu9p{top:-1px;bottom:-1px;background-color:#007ac0;border:1px solid #007ac0;border-radius:5px}._ug4QF,._URu9p{position:absolute}._ug4QF{top:-5px;left:-10px;border:1px solid #007ac0;overflow:visible;width:18px;height:18px;padding:0;margin:0;border-radius:9px;cursor:pointer;display:inline-block;text-align:center;background:#fff;text-decoration:none;outline:none}._ug4QF:before{content:\"\";position:absolute;top:4px;left:4px;background:#007ac0;width:8px;height:8px;border-radius:10px}._ug4QF.focus-visible,._ug4QF:focus-visible{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
9489
9589
|
icons_index.styleInject(css_248z$7);
|
|
9490
9590
|
|
|
9491
9591
|
const buttonOffset = -10;
|
|
@@ -9532,7 +9632,7 @@ const SliderButton = _ref => {
|
|
|
9532
9632
|
const anchorButton = /*#__PURE__*/React__default["default"].createElement("div", _extends__default["default"]({}, rest, {
|
|
9533
9633
|
className: styles$7.button,
|
|
9534
9634
|
style: {
|
|
9535
|
-
left:
|
|
9635
|
+
left: "calc(".concat(buttonPosition, "% + ").concat(buttonOffset, "px")
|
|
9536
9636
|
},
|
|
9537
9637
|
onMouseDown: handleMouseDown,
|
|
9538
9638
|
onKeyDown: onKeyDown,
|
|
@@ -9669,7 +9769,7 @@ const Slider = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =>
|
|
|
9669
9769
|
className: styles$7.fill,
|
|
9670
9770
|
style: {
|
|
9671
9771
|
left: -1,
|
|
9672
|
-
right:
|
|
9772
|
+
right: "".concat(100 - buttonPosition, "%")
|
|
9673
9773
|
}
|
|
9674
9774
|
}), /*#__PURE__*/React__default["default"].createElement(SliderButton, {
|
|
9675
9775
|
"aria-valuemin": min,
|
|
@@ -9790,8 +9890,8 @@ const RangeSlider = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref
|
|
|
9790
9890
|
}, /*#__PURE__*/React__default["default"].createElement("span", {
|
|
9791
9891
|
className: styles$7.fill,
|
|
9792
9892
|
style: {
|
|
9793
|
-
left:
|
|
9794
|
-
right:
|
|
9893
|
+
left: "".concat(buttonPositions[0], "%"),
|
|
9894
|
+
right: "".concat(100 - buttonPositions[1], "%")
|
|
9795
9895
|
}
|
|
9796
9896
|
}), values.map((value, index) => /*#__PURE__*/React__default["default"].createElement(SliderButton, {
|
|
9797
9897
|
key: index,
|
|
@@ -9813,9 +9913,9 @@ const RangeSlider = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref
|
|
|
9813
9913
|
}))));
|
|
9814
9914
|
});
|
|
9815
9915
|
|
|
9816
|
-
var css_248z$6 = ".
|
|
9817
|
-
var styles$6 = {"switch":"
|
|
9818
|
-
var stylesheet$6=".
|
|
9916
|
+
var css_248z$6 = "._dYedK{cursor:pointer;display:inline-flex;position:relative;align-items:center;margin-top:6px;margin-bottom:6px}._dYedK._Fv-5n{cursor:not-allowed}._v2AU-{cursor:pointer;position:absolute;top:0;opacity:0;height:16px;width:32px;border-radius:34px;z-index:10}._v2AU-:disabled{cursor:not-allowed}._v2AU-:disabled~._bzEeN{opacity:.4}._v2AU-:checked~._bzEeN{background-color:#0b6ed0}._v2AU-:checked~._bzEeN:before{transform:translateX(16px);background-color:#fff;border-color:#0b6ed0}._v2AU-:hover:not(:disabled):not(:checked)~._bzEeN{background-color:#6a6a6a}._v2AU-:hover:not(:disabled):checked~._bzEeN{background-color:#085caf}._v2AU-:hover:not(:disabled):checked~._bzEeN:before{border-color:#085caf}._bzEeN{width:32px;background-color:#898989;border-radius:34px}._bzEeN,._bzEeN:before{height:16px;transition:.2s}._bzEeN:before{box-sizing:border-box;position:absolute;left:0;content:\"\";width:16px;background-color:#fff;border-radius:50%;border:1px solid #898989;z-index:0}._QU3iD{color:#32363a;display:flex;align-items:center;cursor:pointer}._t8FrM{cursor:auto;color:hsla(0,0%,53.7%,.4)}._lN4TM{margin-right:12px;flex-shrink:0}._v2AU-.focus-visible~._bzEeN,._v2AU-:focus-visible~._bzEeN{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
9917
|
+
var styles$6 = {"switch":"_dYedK","disabled":"_Fv-5n","input":"_v2AU-","slider":"_bzEeN","label":"_QU3iD","labelDisabled":"_t8FrM","wrappedInput":"_lN4TM"};
|
|
9918
|
+
var stylesheet$6="._dYedK{cursor:pointer;display:inline-flex;position:relative;align-items:center;margin-top:6px;margin-bottom:6px}._dYedK._Fv-5n{cursor:not-allowed}._v2AU-{cursor:pointer;position:absolute;top:0;opacity:0;height:16px;width:32px;border-radius:34px;z-index:10}._v2AU-:disabled{cursor:not-allowed}._v2AU-:disabled~._bzEeN{opacity:.4}._v2AU-:checked~._bzEeN{background-color:#0b6ed0}._v2AU-:checked~._bzEeN:before{transform:translateX(16px);background-color:#fff;border-color:#0b6ed0}._v2AU-:hover:not(:disabled):not(:checked)~._bzEeN{background-color:#6a6a6a}._v2AU-:hover:not(:disabled):checked~._bzEeN{background-color:#085caf}._v2AU-:hover:not(:disabled):checked~._bzEeN:before{border-color:#085caf}._bzEeN{width:32px;background-color:#898989;border-radius:34px}._bzEeN,._bzEeN:before{height:16px;transition:.2s}._bzEeN:before{box-sizing:border-box;position:absolute;left:0;content:\"\";width:16px;background-color:#fff;border-radius:50%;border:1px solid #898989;z-index:0}._QU3iD{color:#32363a;display:flex;align-items:center;cursor:pointer}._t8FrM{cursor:auto;color:hsla(0,0%,53.7%,.4)}._lN4TM{margin-right:12px;flex-shrink:0}._v2AU-.focus-visible~._bzEeN,._v2AU-:focus-visible~._bzEeN{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
9819
9919
|
icons_index.styleInject(css_248z$6);
|
|
9820
9920
|
|
|
9821
9921
|
const Switch = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
@@ -9838,26 +9938,26 @@ const Switch = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =>
|
|
|
9838
9938
|
helperTextId: formFieldHelperTextId,
|
|
9839
9939
|
errorTextId: formFieldErrorTextId
|
|
9840
9940
|
} = useFormFieldContext();
|
|
9841
|
-
const internalAriaDescribedby = concatIds(externalAriaDescribedBy, formFieldHelperTextId, formFieldErrorTextId, inputProps
|
|
9941
|
+
const internalAriaDescribedby = concatIds(externalAriaDescribedBy, formFieldHelperTextId, formFieldErrorTextId, inputProps === null || inputProps === void 0 ? void 0 : inputProps['aria-describedby']);
|
|
9842
9942
|
return /*#__PURE__*/React__default["default"].createElement("span", _extends__default["default"]({}, rest, {
|
|
9843
9943
|
ref: ref,
|
|
9844
9944
|
className: classNames__default["default"](className, styles$6.switch, {
|
|
9845
9945
|
[styles$6.disabled]: disabled
|
|
9846
9946
|
})
|
|
9847
9947
|
}), /*#__PURE__*/React__default["default"].createElement("input", _extends__default["default"]({}, inputProps, {
|
|
9848
|
-
className: classNames__default["default"](styles$6.input, inputProps
|
|
9948
|
+
className: classNames__default["default"](styles$6.input, inputProps === null || inputProps === void 0 ? void 0 : inputProps.className),
|
|
9849
9949
|
type: "checkbox",
|
|
9850
9950
|
role: "switch",
|
|
9851
|
-
id: id
|
|
9852
|
-
checked: checked
|
|
9853
|
-
defaultChecked: defaultChecked
|
|
9854
|
-
disabled: disabled
|
|
9855
|
-
onChange: disabled ? undefined : onChange
|
|
9856
|
-
value: value
|
|
9857
|
-
"aria-label": ariaLabel
|
|
9858
|
-
"aria-labelledby": ariaLabelledBy
|
|
9951
|
+
id: id !== null && id !== void 0 ? id : inputProps === null || inputProps === void 0 ? void 0 : inputProps.id,
|
|
9952
|
+
checked: checked !== null && checked !== void 0 ? checked : inputProps === null || inputProps === void 0 ? void 0 : inputProps.checked,
|
|
9953
|
+
defaultChecked: defaultChecked !== null && defaultChecked !== void 0 ? defaultChecked : inputProps === null || inputProps === void 0 ? void 0 : inputProps.defaultChecked,
|
|
9954
|
+
disabled: disabled !== null && disabled !== void 0 ? disabled : inputProps === null || inputProps === void 0 ? void 0 : inputProps.disabled,
|
|
9955
|
+
onChange: disabled ? undefined : onChange !== null && onChange !== void 0 ? onChange : inputProps === null || inputProps === void 0 ? void 0 : inputProps.onChange,
|
|
9956
|
+
value: value !== null && value !== void 0 ? value : inputProps === null || inputProps === void 0 ? void 0 : inputProps.value,
|
|
9957
|
+
"aria-label": ariaLabel !== null && ariaLabel !== void 0 ? ariaLabel : inputProps === null || inputProps === void 0 ? void 0 : inputProps['aria-label'],
|
|
9958
|
+
"aria-labelledby": ariaLabelledBy !== null && ariaLabelledBy !== void 0 ? ariaLabelledBy : inputProps === null || inputProps === void 0 ? void 0 : inputProps['aria-labelledby'],
|
|
9859
9959
|
"aria-describedby": internalAriaDescribedby,
|
|
9860
|
-
tabIndex: tabIndex
|
|
9960
|
+
tabIndex: tabIndex !== null && tabIndex !== void 0 ? tabIndex : inputProps === null || inputProps === void 0 ? void 0 : inputProps.tabIndex
|
|
9861
9961
|
})), /*#__PURE__*/React__default["default"].createElement("span", {
|
|
9862
9962
|
className: styles$6.slider
|
|
9863
9963
|
}));
|
|
@@ -9896,9 +9996,9 @@ const SwitchField = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref
|
|
|
9896
9996
|
}), label);
|
|
9897
9997
|
});
|
|
9898
9998
|
|
|
9899
|
-
var css_248z$5 = ".
|
|
9900
|
-
var styles$5 = {"table":"
|
|
9901
|
-
var stylesheet$5=".
|
|
9999
|
+
var css_248z$5 = "._3HsX6{font-size:14px;color:#32363a;width:100%;max-width:100%;border-collapse:collapse;background-color:#fff;border:none}._3HsX6 ._7KNzo:first-child,._3HsX6 ._S3ru4:first-child{padding-left:16px}._uCTpq{font-size:12px}._7KNzo{padding:12px 8px;text-align:left;font-weight:700}._YbkQp ._XVqN-{border-top:1px solid #ededed}._YbkQp ._XVqN-:hover{background-color:#fafafa}._XVqN-{transition:background-color 125ms ease-in;border-bottom:1px solid #ededed}._S3ru4{padding:16px 8px;word-break:break-word;text-align:left}";
|
|
10000
|
+
var styles$5 = {"table":"_3HsX6","tableCell":"_S3ru4","tableHeaderCell":"_7KNzo","tableHead":"_uCTpq","tableBody":"_YbkQp","tableRow":"_XVqN-"};
|
|
10001
|
+
var stylesheet$5="._3HsX6{font-size:14px;color:#32363a;width:100%;max-width:100%;border-collapse:collapse;background-color:#fff;border:none}._3HsX6 ._7KNzo:first-child,._3HsX6 ._S3ru4:first-child{padding-left:16px}._uCTpq{font-size:12px}._7KNzo{padding:12px 8px;text-align:left;font-weight:700}._YbkQp ._XVqN-{border-top:1px solid #ededed}._YbkQp ._XVqN-:hover{background-color:#fafafa}._XVqN-{transition:background-color 125ms ease-in;border-bottom:1px solid #ededed}._S3ru4{padding:16px 8px;word-break:break-word;text-align:left}";
|
|
9902
10002
|
icons_index.styleInject(css_248z$5);
|
|
9903
10003
|
|
|
9904
10004
|
const Table = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
@@ -10030,9 +10130,9 @@ const Tabs$1 = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =>
|
|
|
10030
10130
|
}, children));
|
|
10031
10131
|
});
|
|
10032
10132
|
|
|
10033
|
-
var css_248z$4 = ".
|
|
10034
|
-
var styles$4 = {"tablist":"
|
|
10035
|
-
var stylesheet$4=".
|
|
10133
|
+
var css_248z$4 = "._Uj-Q8{display:flex;justify-content:left;border-bottom:1px solid #e5e5e5;height:52px}._Uj-Q8._MzjyU ._2-JBy{flex:1 1 0px;max-width:none}._2-JBy{background:inherit;font-family:inherit;font-size:100%;line-height:1.15;margin:0;-webkit-appearance:button;-moz-appearance:button;appearance:button;text-transform:none;text-align:center;color:#6a6d70;height:52px;padding:16px 12px;max-width:200px;text-overflow:ellipsis;white-space:nowrap;overflow:hidden;border:none;border-bottom:2px solid transparent;border-radius:1px;display:block;outline:none;cursor:pointer}._2-JBy:hover{color:#32363a}._2-JBy._sVrwB{border-bottom-color:#0b6ed0;color:#32363a;font-family:\"72Duplex\",\"72\",\"Helvetica Neue\",Helvetica,Arial,sans-serif;font-weight:500}._UX8ht{padding-top:32px}._UX8ht._Wn0Qf{display:none}._2-JBy.focus-visible,._2-JBy:focus-visible{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
10134
|
+
var styles$4 = {"tablist":"_Uj-Q8","grow":"_MzjyU","tab":"_2-JBy","selected":"_sVrwB","tabpanel":"_UX8ht","inactive":"_Wn0Qf"};
|
|
10135
|
+
var stylesheet$4="._Uj-Q8{display:flex;justify-content:left;border-bottom:1px solid #e5e5e5;height:52px}._Uj-Q8._MzjyU ._2-JBy{flex:1 1 0px;max-width:none}._2-JBy{background:inherit;font-family:inherit;font-size:100%;line-height:1.15;margin:0;-webkit-appearance:button;-moz-appearance:button;appearance:button;text-transform:none;text-align:center;color:#6a6d70;height:52px;padding:16px 12px;max-width:200px;text-overflow:ellipsis;white-space:nowrap;overflow:hidden;border:none;border-bottom:2px solid transparent;border-radius:1px;display:block;outline:none;cursor:pointer}._2-JBy:hover{color:#32363a}._2-JBy._sVrwB{border-bottom-color:#0b6ed0;color:#32363a;font-family:\"72Duplex\",\"72\",\"Helvetica Neue\",Helvetica,Arial,sans-serif;font-weight:500}._UX8ht{padding-top:32px}._UX8ht._Wn0Qf{display:none}._2-JBy.focus-visible,._2-JBy:focus-visible{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
10036
10136
|
icons_index.styleInject(css_248z$4);
|
|
10037
10137
|
|
|
10038
10138
|
const Tab$1 = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
@@ -10050,8 +10150,8 @@ const Tab$1 = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
|
10050
10150
|
rootTestId,
|
|
10051
10151
|
isTabListFocused
|
|
10052
10152
|
} = useTabContext$1();
|
|
10053
|
-
const tabId = getSubDataTestId(rootId,
|
|
10054
|
-
const tabTestId = getSubDataTestId(rootTestId,
|
|
10153
|
+
const tabId = getSubDataTestId(rootId, "tab-".concat(value));
|
|
10154
|
+
const tabTestId = getSubDataTestId(rootTestId, "tab-".concat(value));
|
|
10055
10155
|
const isSelected = activeTab === value;
|
|
10056
10156
|
const onClick = React__default["default"].useCallback(() => {
|
|
10057
10157
|
setActiveTab(value);
|
|
@@ -10067,7 +10167,7 @@ const Tab$1 = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
|
10067
10167
|
[styles$4.selected]: isSelected
|
|
10068
10168
|
}),
|
|
10069
10169
|
"aria-selected": isSelected,
|
|
10070
|
-
"aria-controls":
|
|
10170
|
+
"aria-controls": "".concat(rootId, "-tabpanel-").concat(value),
|
|
10071
10171
|
"aria-label": ariaLabel,
|
|
10072
10172
|
onClick: onClick,
|
|
10073
10173
|
ref: ref,
|
|
@@ -10091,8 +10191,8 @@ const TabsList = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
10091
10191
|
isTabListFocused,
|
|
10092
10192
|
setIsTabListFocused
|
|
10093
10193
|
} = useTabContext$1();
|
|
10094
|
-
const tabListId = getSubDataTestId(rootId,
|
|
10095
|
-
const tabListTestId = getSubDataTestId(rootTestId,
|
|
10194
|
+
const tabListId = getSubDataTestId(rootId, "tablist");
|
|
10195
|
+
const tabListTestId = getSubDataTestId(rootTestId, "tablist");
|
|
10096
10196
|
const tabListRef = React.useRef(null);
|
|
10097
10197
|
// We use this map of tab element to index to allow constant time index
|
|
10098
10198
|
// lookup when we handle an event from a child tab
|
|
@@ -10154,10 +10254,11 @@ const TabsList = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
10154
10254
|
ref: mergeRefs(ref, tabListRef),
|
|
10155
10255
|
tabIndex: -1 // Needed to satisfy the jsx-a11y/interactive-supports-focus rule
|
|
10156
10256
|
}), React__default["default"].Children.map(children, (child, index) => {
|
|
10157
|
-
if (child
|
|
10257
|
+
if ((child === null || child === void 0 ? void 0 : child.type) === Tab$1) {
|
|
10258
|
+
var _child$props$value;
|
|
10158
10259
|
return /*#__PURE__*/React__default["default"].cloneElement(child, {
|
|
10159
|
-
value: child.props.value
|
|
10160
|
-
ref: mergeRefs(child
|
|
10260
|
+
value: (_child$props$value = child.props.value) !== null && _child$props$value !== void 0 ? _child$props$value : index,
|
|
10261
|
+
ref: mergeRefs(child === null || child === void 0 ? void 0 : child.ref, node => {
|
|
10161
10262
|
// Store a reverse node/index map for
|
|
10162
10263
|
// constant time index lookups from event handlers
|
|
10163
10264
|
if (node) {
|
|
@@ -10183,14 +10284,14 @@ const TabPanel = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) =
|
|
|
10183
10284
|
rootId,
|
|
10184
10285
|
rootTestId
|
|
10185
10286
|
} = useTabContext$1();
|
|
10186
|
-
const tabPanelId = getSubDataTestId(rootId,
|
|
10187
|
-
const tabPanelTestId = getSubDataTestId(rootTestId,
|
|
10287
|
+
const tabPanelId = getSubDataTestId(rootId, "tabpanel-".concat(value));
|
|
10288
|
+
const tabPanelTestId = getSubDataTestId(rootTestId, "tabpanel-".concat(value));
|
|
10188
10289
|
return /*#__PURE__*/React__default["default"].createElement("div", _extends__default["default"]({}, rest, {
|
|
10189
10290
|
ref: ref,
|
|
10190
10291
|
"data-testid": tabPanelTestId,
|
|
10191
10292
|
id: tabPanelId,
|
|
10192
10293
|
role: "tabpanel",
|
|
10193
|
-
"aria-labelledby":
|
|
10294
|
+
"aria-labelledby": "".concat(rootId, "-tab-").concat(value),
|
|
10194
10295
|
className: classNames__default["default"](styles$4.tabpanel, className, {
|
|
10195
10296
|
[styles$4.inactive]: value !== activeTab
|
|
10196
10297
|
})
|
|
@@ -10219,15 +10320,15 @@ const UIProvider = _ref => {
|
|
|
10219
10320
|
config = {}
|
|
10220
10321
|
} = _ref;
|
|
10221
10322
|
return /*#__PURE__*/React__default["default"].createElement(TranslationProvider, {
|
|
10222
|
-
localizedText: config
|
|
10323
|
+
localizedText: config === null || config === void 0 ? void 0 : config.localizedText
|
|
10223
10324
|
}, /*#__PURE__*/React__default["default"].createElement(PortalTargetProvider, {
|
|
10224
|
-
target: portalTarget
|
|
10325
|
+
target: portalTarget !== null && portalTarget !== void 0 ? portalTarget : null
|
|
10225
10326
|
}, children));
|
|
10226
10327
|
};
|
|
10227
10328
|
|
|
10228
|
-
var css_248z$3 = ".
|
|
10229
|
-
var styles$3 = {"colorPickerBtnColor":"
|
|
10230
|
-
var stylesheet$3=".
|
|
10329
|
+
var css_248z$3 = "._QZsWN{margin-left:-6px;height:16px;width:16px;border-radius:2px;box-shadow:inset 0 0 0 1px rgba(0,0,0,.15)}._dpFGP{margin-right:-12px;margin-left:4px}._5dpir{background-color:#fff;border-radius:4px;box-shadow:0 4px 24px -4px rgba(0,0,0,.5);width:156px}._rw1Xp{margin:8px 8px 0;display:flex}._8iId6,._n0DAr{margin-left:4px}._rChN9{margin:8px 4px 0 8px;display:flex;flex-wrap:wrap}._TcA5O{margin:0 4px 4px 0}._TcA5O:hover{width:18px;height:18px;margin:-1px 3px 3px -1px}._QLdhQ{margin:4px 8px 8px}._bdlXv{position:relative;width:96px;height:96px;outline:0}._bdlXv.focus-visible ._YIc06,._bdlXv:focus-visible ._YIc06{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._wdJ-b{background:linear-gradient(90deg,#fff,transparent)}._lu0Wn,._wdJ-b{position:absolute;top:0;right:0;bottom:0;left:0}._lu0Wn{background:linear-gradient(0deg,#000,transparent)}._YIc06{position:absolute;border:2px solid #fff;border-radius:5px;height:8px;width:8px;margin:0 0 -4px -4px;box-shadow:0 0 1px 1px rgba(0,0,0,.4),inset 0 0 1px #000}._phSFD{position:relative;background:linear-gradient(0deg,red,#ff0 17%,#0f0 33%,#0ff 50%,#00f 67%,#f0f 83%,red);width:16px;height:96px;outline:0}._phSFD.focus-visible ._0vdqQ,._phSFD:focus-visible ._0vdqQ{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._0vdqQ{width:16px;height:4px;background:#fff;border-radius:50%;position:absolute;box-shadow:0 0 4px 1px rgba(0,0,0,.4);transform:translateY(2px)}._5iJOi{position:relative;width:16px;height:96px}._e-vCj{width:16px;height:4px;background:#fff;border-radius:50%;box-shadow:0 0 4px 1px rgba(0,0,0,.4);transform:translateY(2px)}._e-vCj,._lDJIB{position:absolute}._lDJIB{top:0;right:0;bottom:0;left:0;outline:0}._lDJIB.focus-visible ._e-vCj,._lDJIB:focus-visible ._e-vCj{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._vMQc-{position:absolute;top:0;right:0;bottom:0;left:0;background-image:linear-gradient(45deg,#d9dadb 25%,transparent 0),linear-gradient(-45deg,#d9dadb 25%,transparent 0),linear-gradient(45deg,transparent 75%,#d9dadb 0),linear-gradient(-45deg,transparent 75%,#d9dadb 0);background-size:16px 16px;background-position:0 0,0 8px,8px -8px,-8px 0}._nbQdB{border-radius:2px;height:16px;width:16px;cursor:pointer;box-shadow:inset 0 0 0 1px rgba(0,0,0,.15)}._nbQdB.focus-visible,._nbQdB:focus-visible{outline:none}._nbQdB.focus-visible,._nbQdB:focus-visible{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._-FH-k{display:flex}._-FH-k ._Vi-aR{position:relative;flex-shrink:0;width:26px;height:26px}._-FH-k ._vHkBE{position:absolute;top:0;right:0;bottom:0;left:0;border-top-left-radius:4px;border-bottom-left-radius:4px;border:1px solid #c6c6c6}._-FH-k ._KbnaR{flex-basis:100%;min-width:0;border-top-left-radius:0;border-bottom-left-radius:0}";
|
|
10330
|
+
var styles$3 = {"colorPickerBtnColor":"_QZsWN","colorPickerBtnIcon":"_dpFGP","colorPicker":"_5dpir","colorPickerSliderContainer":"_rw1Xp","colorPickerHue":"_n0DAr","colorPickerAlpha":"_8iId6","colorPickerSwatches":"_rChN9","colorPickerSwatch":"_TcA5O","colorPickerHex":"_QLdhQ","saturation":"_bdlXv","saturationCircle":"_YIc06","saturationWhite":"_wdJ-b","saturationBlack":"_lu0Wn","hue":"_phSFD","hueSlider":"_0vdqQ","alpha":"_5iJOi","alphaSlider":"_e-vCj","alphaGradient":"_lDJIB","alphaCheckerboard":"_vMQc-","swatch":"_nbQdB","hex":"_-FH-k","hexSwatch":"_Vi-aR","hexSwatchColor":"_vHkBE","hexInput":"_KbnaR"};
|
|
10331
|
+
var stylesheet$3="._QZsWN{margin-left:-6px;height:16px;width:16px;border-radius:2px;box-shadow:inset 0 0 0 1px rgba(0,0,0,.15)}._dpFGP{margin-right:-12px;margin-left:4px}._5dpir{background-color:#fff;border-radius:4px;box-shadow:0 4px 24px -4px rgba(0,0,0,.5);width:156px}._rw1Xp{margin:8px 8px 0;display:flex}._8iId6,._n0DAr{margin-left:4px}._rChN9{margin:8px 4px 0 8px;display:flex;flex-wrap:wrap}._TcA5O{margin:0 4px 4px 0}._TcA5O:hover{width:18px;height:18px;margin:-1px 3px 3px -1px}._QLdhQ{margin:4px 8px 8px}._bdlXv{position:relative;width:96px;height:96px;outline:0}._bdlXv.focus-visible ._YIc06,._bdlXv:focus-visible ._YIc06{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._wdJ-b{background:linear-gradient(90deg,#fff,transparent)}._lu0Wn,._wdJ-b{position:absolute;top:0;right:0;bottom:0;left:0}._lu0Wn{background:linear-gradient(0deg,#000,transparent)}._YIc06{position:absolute;border:2px solid #fff;border-radius:5px;height:8px;width:8px;margin:0 0 -4px -4px;box-shadow:0 0 1px 1px rgba(0,0,0,.4),inset 0 0 1px #000}._phSFD{position:relative;background:linear-gradient(0deg,red,#ff0 17%,#0f0 33%,#0ff 50%,#00f 67%,#f0f 83%,red);width:16px;height:96px;outline:0}._phSFD.focus-visible ._0vdqQ,._phSFD:focus-visible ._0vdqQ{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._0vdqQ{width:16px;height:4px;background:#fff;border-radius:50%;position:absolute;box-shadow:0 0 4px 1px rgba(0,0,0,.4);transform:translateY(2px)}._5iJOi{position:relative;width:16px;height:96px}._e-vCj{width:16px;height:4px;background:#fff;border-radius:50%;box-shadow:0 0 4px 1px rgba(0,0,0,.4);transform:translateY(2px)}._e-vCj,._lDJIB{position:absolute}._lDJIB{top:0;right:0;bottom:0;left:0;outline:0}._lDJIB.focus-visible ._e-vCj,._lDJIB:focus-visible ._e-vCj{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._vMQc-{position:absolute;top:0;right:0;bottom:0;left:0;background-image:linear-gradient(45deg,#d9dadb 25%,transparent 0),linear-gradient(-45deg,#d9dadb 25%,transparent 0),linear-gradient(45deg,transparent 75%,#d9dadb 0),linear-gradient(-45deg,transparent 75%,#d9dadb 0);background-size:16px 16px;background-position:0 0,0 8px,8px -8px,-8px 0}._nbQdB{border-radius:2px;height:16px;width:16px;cursor:pointer;box-shadow:inset 0 0 0 1px rgba(0,0,0,.15)}._nbQdB.focus-visible,._nbQdB:focus-visible{outline:none}._nbQdB.focus-visible,._nbQdB:focus-visible{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._-FH-k{display:flex}._-FH-k ._Vi-aR{position:relative;flex-shrink:0;width:26px;height:26px}._-FH-k ._vHkBE{position:absolute;top:0;right:0;bottom:0;left:0;border-top-left-radius:4px;border-bottom-left-radius:4px;border:1px solid #c6c6c6}._-FH-k ._KbnaR{flex-basis:100%;min-width:0;border-top-left-radius:0;border-bottom-left-radius:0}";
|
|
10231
10332
|
icons_index.styleInject(css_248z$3);
|
|
10232
10333
|
|
|
10233
10334
|
function useMouseDrag(handleChange) {
|
|
@@ -10324,13 +10425,13 @@ const Saturation = function Saturation(_ref) {
|
|
|
10324
10425
|
} = _ref;
|
|
10325
10426
|
const containerRef = React__default["default"].useRef(null);
|
|
10326
10427
|
const handleChange = useEventCallback(e => {
|
|
10327
|
-
onChange
|
|
10428
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(getMouseChange$2(e, hsb, containerRef.current), e);
|
|
10328
10429
|
});
|
|
10329
10430
|
const handleMouseDown = useMouseDrag(handleChange);
|
|
10330
10431
|
function handleKeyDown(e) {
|
|
10331
10432
|
if (Object.keys(KEY_CHANGES$2).indexOf(e.key) > -1) {
|
|
10332
10433
|
const change = getKeyChange$2(e, hsb);
|
|
10333
|
-
onChange
|
|
10434
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(change, e);
|
|
10334
10435
|
}
|
|
10335
10436
|
}
|
|
10336
10437
|
return (
|
|
@@ -10339,7 +10440,7 @@ const Saturation = function Saturation(_ref) {
|
|
|
10339
10440
|
React__default["default"].createElement("div", _extends__default["default"]({}, rest, {
|
|
10340
10441
|
ref: containerRef,
|
|
10341
10442
|
style: {
|
|
10342
|
-
backgroundColor:
|
|
10443
|
+
backgroundColor: "hsl(".concat(hsb.h, ", 100%, 50%)")
|
|
10343
10444
|
},
|
|
10344
10445
|
className: classNames__default["default"](styles$3.saturation, className),
|
|
10345
10446
|
onMouseDown: handleMouseDown,
|
|
@@ -10356,8 +10457,8 @@ const Saturation = function Saturation(_ref) {
|
|
|
10356
10457
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
10357
10458
|
className: styles$3.saturationCircle,
|
|
10358
10459
|
style: {
|
|
10359
|
-
bottom:
|
|
10360
|
-
left:
|
|
10460
|
+
bottom: "".concat(hsb.b * 100, "%"),
|
|
10461
|
+
left: "".concat(hsb.s * 100, "%")
|
|
10361
10462
|
}
|
|
10362
10463
|
}))))
|
|
10363
10464
|
);
|
|
@@ -10391,7 +10492,7 @@ const HexInput = function HexInput(_ref) {
|
|
|
10391
10492
|
function handleChange(e) {
|
|
10392
10493
|
setValue(e.target.value);
|
|
10393
10494
|
if (isValid(e.target.value)) {
|
|
10394
|
-
onChange
|
|
10495
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(e.target.value, e);
|
|
10395
10496
|
}
|
|
10396
10497
|
}
|
|
10397
10498
|
function handleBlur() {
|
|
@@ -10430,9 +10531,9 @@ const Swatch = function Swatch(_ref) {
|
|
|
10430
10531
|
...rest
|
|
10431
10532
|
} = _ref;
|
|
10432
10533
|
function handleClick(e) {
|
|
10433
|
-
onClick
|
|
10534
|
+
onClick === null || onClick === void 0 ? void 0 : onClick(color, e);
|
|
10434
10535
|
}
|
|
10435
|
-
const handleKeyDown = e => e.keyCode === ENTER && onClick
|
|
10536
|
+
const handleKeyDown = e => e.keyCode === ENTER && (onClick === null || onClick === void 0 ? void 0 : onClick(color, e));
|
|
10436
10537
|
return /*#__PURE__*/React__default["default"].createElement("span", _extends__default["default"]({}, rest, {
|
|
10437
10538
|
role: "button",
|
|
10438
10539
|
tabIndex: 0,
|
|
@@ -10489,13 +10590,13 @@ const Hue = function Hue(_ref) {
|
|
|
10489
10590
|
const containerRef = React__default["default"].useRef(null);
|
|
10490
10591
|
const handleChange = useEventCallback(e => {
|
|
10491
10592
|
const change = getMouseChange$1(e, hsb, containerRef.current);
|
|
10492
|
-
onChange
|
|
10593
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(change, e);
|
|
10493
10594
|
});
|
|
10494
10595
|
const handleMouseDown = useMouseDrag(handleChange);
|
|
10495
10596
|
function handleKeyDown(e) {
|
|
10496
10597
|
if (Object.keys(KEY_CHANGES$1).indexOf(e.key) > -1) {
|
|
10497
10598
|
const change = getKeyChange$1(e, hsb);
|
|
10498
|
-
onChange
|
|
10599
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(change, e);
|
|
10499
10600
|
}
|
|
10500
10601
|
}
|
|
10501
10602
|
return (
|
|
@@ -10516,7 +10617,7 @@ const Hue = function Hue(_ref) {
|
|
|
10516
10617
|
}), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
10517
10618
|
className: styles$3.hueSlider,
|
|
10518
10619
|
style: {
|
|
10519
|
-
bottom:
|
|
10620
|
+
bottom: "".concat(hsb.h / 360 * 100, "%")
|
|
10520
10621
|
}
|
|
10521
10622
|
}))
|
|
10522
10623
|
);
|
|
@@ -10566,13 +10667,13 @@ const Alpha = function Alpha(_ref) {
|
|
|
10566
10667
|
const containerRef = React__default["default"].useRef(null);
|
|
10567
10668
|
const handleChange = useEventCallback(e => {
|
|
10568
10669
|
const change = getMouseChange(e, hsl, alpha, containerRef.current);
|
|
10569
|
-
onChange
|
|
10670
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(change, e);
|
|
10570
10671
|
});
|
|
10571
10672
|
const handleMouseDown = useMouseDrag(handleChange);
|
|
10572
10673
|
function handleKeyDown(e) {
|
|
10573
10674
|
if (Object.keys(KEY_CHANGES).indexOf(e.key) > -1) {
|
|
10574
10675
|
const change = getKeyChange(e, hsl);
|
|
10575
|
-
onChange
|
|
10676
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(change, e);
|
|
10576
10677
|
}
|
|
10577
10678
|
}
|
|
10578
10679
|
return /*#__PURE__*/React__default["default"].createElement("div", {
|
|
@@ -10587,7 +10688,7 @@ const Alpha = function Alpha(_ref) {
|
|
|
10587
10688
|
onTouchMove: handleChange,
|
|
10588
10689
|
onTouchStart: handleChange,
|
|
10589
10690
|
style: {
|
|
10590
|
-
background:
|
|
10691
|
+
background: "linear-gradient(to top, hsla(".concat(hsl.h, ", ").concat(hsl.s * 100, "%, ").concat(hsl.l * 100, "%, 0) 0%, hsla(").concat(hsl.h, ", ").concat(hsl.s * 100, "%, ").concat(hsl.l * 100, "%, 1) 100%)")
|
|
10591
10692
|
},
|
|
10592
10693
|
role: "slider",
|
|
10593
10694
|
"aria-valuemin": 0,
|
|
@@ -10597,7 +10698,7 @@ const Alpha = function Alpha(_ref) {
|
|
|
10597
10698
|
}), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
10598
10699
|
className: styles$3.alphaSlider,
|
|
10599
10700
|
style: {
|
|
10600
|
-
bottom:
|
|
10701
|
+
bottom: "".concat(alpha * 100, "%")
|
|
10601
10702
|
}
|
|
10602
10703
|
})));
|
|
10603
10704
|
};
|
|
@@ -10695,7 +10796,7 @@ class Color {
|
|
|
10695
10796
|
setColor(strVal) {
|
|
10696
10797
|
strVal = strVal.toLowerCase();
|
|
10697
10798
|
if (strVal.charAt(0) !== '#') {
|
|
10698
|
-
strVal =
|
|
10799
|
+
strVal = "#".concat(strVal);
|
|
10699
10800
|
}
|
|
10700
10801
|
this.value = this.stringToHSB(strVal) || {
|
|
10701
10802
|
h: 0,
|
|
@@ -10752,7 +10853,7 @@ class Color {
|
|
|
10752
10853
|
}
|
|
10753
10854
|
toHex(h, s, b, a) {
|
|
10754
10855
|
const rgb = this.toRGB(Number(h), Number(s), Number(b), Number(a));
|
|
10755
|
-
return
|
|
10856
|
+
return "#".concat((1 << 24 | parseInt(String(rgb.r), 10) << 16 | parseInt(String(rgb.g), 10) << 8 | parseInt(String(rgb.b), 10)).toString(16).substr(1));
|
|
10756
10857
|
}
|
|
10757
10858
|
toHSL(h, s, b, a) {
|
|
10758
10859
|
h = h || this.value.h;
|
|
@@ -10858,16 +10959,16 @@ class Color {
|
|
|
10858
10959
|
switch (format) {
|
|
10859
10960
|
case 'rgb':
|
|
10860
10961
|
rgb = this.toRGB();
|
|
10861
|
-
return
|
|
10962
|
+
return "rgb(".concat(rgb.r, ",").concat(rgb.g, ",").concat(rgb.b, ")");
|
|
10862
10963
|
case 'rgba':
|
|
10863
10964
|
rgb = this.toRGB();
|
|
10864
|
-
return
|
|
10965
|
+
return "rgba(".concat(rgb.r, ",").concat(rgb.g, ",").concat(rgb.b, ",").concat(rgb.a, ")");
|
|
10865
10966
|
case 'hsl':
|
|
10866
10967
|
hsl = this.toHSL();
|
|
10867
|
-
return
|
|
10968
|
+
return "hsl(".concat(Math.round(hsl.h), ",").concat(Math.round(hsl.s * 100), "%,").concat(Math.round(hsl.l * 100), "%)");
|
|
10868
10969
|
case 'hsla':
|
|
10869
10970
|
hsl = this.toHSL();
|
|
10870
|
-
return
|
|
10971
|
+
return "hsla(".concat(Math.round(hsl.h), ",").concat(Math.round(hsl.s * 100), "%,").concat(Math.round(hsl.l * 100), "%,").concat(hsl.a, ")");
|
|
10871
10972
|
case 'hex':
|
|
10872
10973
|
return this.toHex();
|
|
10873
10974
|
default:
|
|
@@ -10898,14 +10999,14 @@ const ColorPicker = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref
|
|
|
10898
10999
|
...rest
|
|
10899
11000
|
} = _ref;
|
|
10900
11001
|
const [show, setShow] = React__default["default"].useState(false);
|
|
10901
|
-
const [color, setColor] = React__default["default"].useState(new Color(externalColor
|
|
11002
|
+
const [color, setColor] = React__default["default"].useState(new Color(externalColor !== null && externalColor !== void 0 ? externalColor : defaultColor));
|
|
10902
11003
|
React.useEffect(() => {
|
|
10903
11004
|
if (externalColor) setColor(new Color(externalColor));
|
|
10904
11005
|
}, [externalColor]);
|
|
10905
11006
|
function handleChange(rawColor, e) {
|
|
10906
11007
|
const nextColor = new Color(rawColor);
|
|
10907
11008
|
setColor(nextColor);
|
|
10908
|
-
onChange
|
|
11009
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(nextColor.getValue(), e);
|
|
10909
11010
|
}
|
|
10910
11011
|
let alpha;
|
|
10911
11012
|
let width = 136;
|
|
@@ -10986,9 +11087,9 @@ const ColorPicker = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref
|
|
|
10986
11087
|
|
|
10987
11088
|
/* eslint-disable camelcase */
|
|
10988
11089
|
|
|
10989
|
-
var css_248z$2 = ".
|
|
10990
|
-
var styles$2 = {"numberStepperContainer":"
|
|
10991
|
-
var stylesheet$2=".
|
|
11090
|
+
var css_248z$2 = "._9ZV2j{display:inline-flex}._zmRfj{color:#32363a;background:#fafafa;outline:none;text-align:center;padding:0 12px;min-width:55px;width:100%;font-size:14px;border:1px solid #898989;border-radius:0;-moz-appearance:textfield}._zmRfj:hover:not(._wOW1Z){cursor:pointer;background:#f5f5f5}._zmRfj._0vELT{box-shadow:0 0 0 2px #fff,0 0 0 4px #900000}._zmRfj._wOW1Z{cursor:not-allowed;fill:#74777a;color:#74777a;border-color:#e5e5e5}._zmRfj._wOW1Z>svg{opacity:.4}._zmRfj::-webkit-inner-spin-button,._zmRfj::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}._zmRfj:focus{z-index:0;border:none;border-radius:4px}._zmRfj:focus:not(._0vELT){box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._-U-8i,._zmRfj:focus:not(._wOW1Z){background:#fafafa}._-U-8i{padding:0;display:flex;justify-content:center;align-items:center;flex-shrink:0;width:36px;height:36px;fill:#515559;outline:none;border-radius:4px 0 0 4px;border:1px solid #898989;border-right-width:0}._-U-8i:hover:not(._wOW1Z){cursor:pointer;background:#f5f5f5}._-U-8i:active:not(._wOW1Z){background:#e5e5e5}._-U-8i._wOW1Z{cursor:not-allowed;fill:#74777a;color:#74777a;border-color:#e5e5e5}._-U-8i._wOW1Z>svg{opacity:.4}._WAoyx{padding:0;display:flex;justify-content:center;align-items:center;flex-shrink:0;width:36px;height:36px;background:#fafafa;fill:#515559;outline:none;border-radius:0 4px 4px 0;border:1px solid #898989;border-left-width:0}._WAoyx:hover:not(._wOW1Z){cursor:pointer;background:#f5f5f5}._WAoyx:active:not(._wOW1Z){background:#e5e5e5}._WAoyx._wOW1Z{cursor:not-allowed;fill:#74777a;color:#74777a;border-color:#e5e5e5}._WAoyx._wOW1Z>svg{opacity:.4}._TzW-C{position:absolute;top:0;left:0;width:0;height:0;margin:0;overflow:hidden}";
|
|
11091
|
+
var styles$2 = {"numberStepperContainer":"_9ZV2j","numberStepperInput":"_zmRfj","disabled":"_wOW1Z","invalid":"_0vELT","decrementBtn":"_-U-8i","incrementBtn":"_WAoyx","inputValueAlert":"_TzW-C"};
|
|
11092
|
+
var stylesheet$2="._9ZV2j{display:inline-flex}._zmRfj{color:#32363a;background:#fafafa;outline:none;text-align:center;padding:0 12px;min-width:55px;width:100%;font-size:14px;border:1px solid #898989;border-radius:0;-moz-appearance:textfield}._zmRfj:hover:not(._wOW1Z){cursor:pointer;background:#f5f5f5}._zmRfj._0vELT{box-shadow:0 0 0 2px #fff,0 0 0 4px #900000}._zmRfj._wOW1Z{cursor:not-allowed;fill:#74777a;color:#74777a;border-color:#e5e5e5}._zmRfj._wOW1Z>svg{opacity:.4}._zmRfj::-webkit-inner-spin-button,._zmRfj::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}._zmRfj:focus{z-index:0;border:none;border-radius:4px}._zmRfj:focus:not(._0vELT){box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._-U-8i,._zmRfj:focus:not(._wOW1Z){background:#fafafa}._-U-8i{padding:0;display:flex;justify-content:center;align-items:center;flex-shrink:0;width:36px;height:36px;fill:#515559;outline:none;border-radius:4px 0 0 4px;border:1px solid #898989;border-right-width:0}._-U-8i:hover:not(._wOW1Z){cursor:pointer;background:#f5f5f5}._-U-8i:active:not(._wOW1Z){background:#e5e5e5}._-U-8i._wOW1Z{cursor:not-allowed;fill:#74777a;color:#74777a;border-color:#e5e5e5}._-U-8i._wOW1Z>svg{opacity:.4}._WAoyx{padding:0;display:flex;justify-content:center;align-items:center;flex-shrink:0;width:36px;height:36px;background:#fafafa;fill:#515559;outline:none;border-radius:0 4px 4px 0;border:1px solid #898989;border-left-width:0}._WAoyx:hover:not(._wOW1Z){cursor:pointer;background:#f5f5f5}._WAoyx:active:not(._wOW1Z){background:#e5e5e5}._WAoyx._wOW1Z{cursor:not-allowed;fill:#74777a;color:#74777a;border-color:#e5e5e5}._WAoyx._wOW1Z>svg{opacity:.4}._TzW-C{position:absolute;top:0;left:0;width:0;height:0;margin:0;overflow:hidden}";
|
|
10992
11093
|
icons_index.styleInject(css_248z$2);
|
|
10993
11094
|
|
|
10994
11095
|
const {
|
|
@@ -11043,7 +11144,7 @@ const NumberStepperInput = /*#__PURE__*/React__default["default"].forwardRef((_r
|
|
|
11043
11144
|
helperTextId: formFieldHelperTextId,
|
|
11044
11145
|
errorTextId: formFieldErrorTextId
|
|
11045
11146
|
} = useFormFieldControl();
|
|
11046
|
-
const internalAriaDescribedby = concatIds(ariaDescribedByFromProps
|
|
11147
|
+
const internalAriaDescribedby = concatIds(ariaDescribedByFromProps !== null && ariaDescribedByFromProps !== void 0 ? ariaDescribedByFromProps : ariaDescribedBy, formFieldHelperTextId, formFieldErrorTextId);
|
|
11047
11148
|
|
|
11048
11149
|
// Indicates if the `inputValue` is invalid
|
|
11049
11150
|
const isInputValueInvalid = typeof inputValue === 'number' && (inputValue > inputMax || inputValue < inputMin);
|
|
@@ -11054,7 +11155,7 @@ const NumberStepperInput = /*#__PURE__*/React__default["default"].forwardRef((_r
|
|
|
11054
11155
|
* depending on the key that was pressed.
|
|
11055
11156
|
*/
|
|
11056
11157
|
const handleKeyDown = e => {
|
|
11057
|
-
onKeyDown
|
|
11158
|
+
onKeyDown === null || onKeyDown === void 0 ? void 0 : onKeyDown(e);
|
|
11058
11159
|
if (isExternallyDisabled) return;
|
|
11059
11160
|
if (e.key === 'ArrowUp') {
|
|
11060
11161
|
// Prevents browser's default increment
|
|
@@ -11089,7 +11190,7 @@ const NumberStepperInput = /*#__PURE__*/React__default["default"].forwardRef((_r
|
|
|
11089
11190
|
* Selects the DOM element
|
|
11090
11191
|
*/
|
|
11091
11192
|
const handleFocus = e => {
|
|
11092
|
-
onFocus
|
|
11193
|
+
onFocus === null || onFocus === void 0 ? void 0 : onFocus(e);
|
|
11093
11194
|
if (isExternallyDisabled) return;
|
|
11094
11195
|
e.target.select();
|
|
11095
11196
|
};
|
|
@@ -11099,15 +11200,15 @@ const NumberStepperInput = /*#__PURE__*/React__default["default"].forwardRef((_r
|
|
|
11099
11200
|
* Calls `handleInputBlur`
|
|
11100
11201
|
*/
|
|
11101
11202
|
const handleBlur = e => {
|
|
11102
|
-
onBlur
|
|
11203
|
+
onBlur === null || onBlur === void 0 ? void 0 : onBlur(e);
|
|
11103
11204
|
if (isExternallyDisabled) return;
|
|
11104
11205
|
handleInputBlur(e);
|
|
11105
11206
|
};
|
|
11106
11207
|
return /*#__PURE__*/React__default["default"].createElement("input", _extends__default["default"]({}, rest, {
|
|
11107
11208
|
// `type`, `step`, `min`, `max`, `onChange`, and `value` are purposely overwritten
|
|
11108
11209
|
ref: ref,
|
|
11109
|
-
"data-testid": dataTestIdFromProps
|
|
11110
|
-
id: idFromProps
|
|
11210
|
+
"data-testid": dataTestIdFromProps !== null && dataTestIdFromProps !== void 0 ? dataTestIdFromProps : getSubDataTestId(dataTestId, 'Input'),
|
|
11211
|
+
id: idFromProps !== null && idFromProps !== void 0 ? idFromProps : inputId,
|
|
11111
11212
|
className: classNames__default["default"](className, styles$2.numberStepperInput, {
|
|
11112
11213
|
[styles$2.invalid]: isInputValueInvalid,
|
|
11113
11214
|
[styles$2.disabled]: isExternallyDisabled
|
|
@@ -11120,8 +11221,8 @@ const NumberStepperInput = /*#__PURE__*/React__default["default"].forwardRef((_r
|
|
|
11120
11221
|
"aria-valuemin": inputMin,
|
|
11121
11222
|
"aria-valuemax": inputMax,
|
|
11122
11223
|
"aria-valuenow": Number(inputValue),
|
|
11123
|
-
"aria-label": ariaLabelFromProps
|
|
11124
|
-
"aria-labelledby": ariaLabelledByFromProps
|
|
11224
|
+
"aria-label": ariaLabelFromProps !== null && ariaLabelFromProps !== void 0 ? ariaLabelFromProps : ariaLabel,
|
|
11225
|
+
"aria-labelledby": ariaLabelledByFromProps !== null && ariaLabelledByFromProps !== void 0 ? ariaLabelledByFromProps : ariaLabelledBy,
|
|
11125
11226
|
"aria-describedby": internalAriaDescribedby,
|
|
11126
11227
|
"aria-invalid": isInputValueInvalid,
|
|
11127
11228
|
"aria-disabled": isExternallyDisabled,
|
|
@@ -11170,12 +11271,12 @@ const NumberStepperIncrement = /*#__PURE__*/React__default["default"].forwardRef
|
|
|
11170
11271
|
*/
|
|
11171
11272
|
const handleClick = e => {
|
|
11172
11273
|
if (!isDisabled) {
|
|
11173
|
-
onClick
|
|
11274
|
+
onClick === null || onClick === void 0 ? void 0 : onClick(e);
|
|
11174
11275
|
increment(true);
|
|
11175
11276
|
}
|
|
11176
11277
|
};
|
|
11177
11278
|
return /*#__PURE__*/React__default["default"].createElement("button", _extends__default["default"]({}, rest, {
|
|
11178
|
-
"data-testid": dataTestIdFromProps
|
|
11279
|
+
"data-testid": dataTestIdFromProps !== null && dataTestIdFromProps !== void 0 ? dataTestIdFromProps : getSubDataTestId(dataTestId, 'Increment'),
|
|
11179
11280
|
ref: ref,
|
|
11180
11281
|
type: "button",
|
|
11181
11282
|
className: classNames__default["default"](className, styles$2.incrementBtn, {
|
|
@@ -11229,12 +11330,12 @@ const NumberStepperDecrement = /*#__PURE__*/React__default["default"].forwardRef
|
|
|
11229
11330
|
*/
|
|
11230
11331
|
const handleClick = e => {
|
|
11231
11332
|
if (!isDisabled) {
|
|
11232
|
-
onClick
|
|
11333
|
+
onClick === null || onClick === void 0 ? void 0 : onClick(e);
|
|
11233
11334
|
decrement(true);
|
|
11234
11335
|
}
|
|
11235
11336
|
};
|
|
11236
11337
|
return /*#__PURE__*/React__default["default"].createElement("button", _extends__default["default"]({}, rest, {
|
|
11237
|
-
"data-testid": dataTestIdFromProps
|
|
11338
|
+
"data-testid": dataTestIdFromProps !== null && dataTestIdFromProps !== void 0 ? dataTestIdFromProps : getSubDataTestId(dataTestId, 'Decrement'),
|
|
11238
11339
|
ref: ref,
|
|
11239
11340
|
type: "button",
|
|
11240
11341
|
className: classNames__default["default"](className, styles$2.decrementBtn, {
|
|
@@ -11435,9 +11536,9 @@ function clampMinMax(value, _ref2) {
|
|
|
11435
11536
|
|
|
11436
11537
|
/* eslint-disable camelcase */
|
|
11437
11538
|
|
|
11438
|
-
var css_248z$1 = ".
|
|
11439
|
-
var styles$1 = {"tabs":"
|
|
11440
|
-
var stylesheet$1=".
|
|
11539
|
+
var css_248z$1 = "._5NQH4{display:block}._7s7DQ{display:flex;justify-content:left;border-bottom:1px solid #e5e5e5;height:52px}._zWBmM{color:#6a6d70;cursor:pointer;height:52px;padding:16px 12px;max-width:200px;text-overflow:ellipsis;white-space:nowrap;overflow:hidden;border-bottom:1px solid transparent;border-radius:1px}._zWBmM:hover{color:#32363a}._zWBmM:focus{outline:none}._zWBmM._8HiqX{margin-bottom:-1px;border-bottom:2px solid #0b6ed0;color:#32363a;font-family:\"72Duplex\",\"72\",\"Helvetica Neue\",Helvetica,Arial,sans-serif;font-weight:500}._qCmXi{padding-top:32px}._qCmXi._zD5HH{display:none}._zWBmM.focus-visible,._zWBmM:focus-visible{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
11540
|
+
var styles$1 = {"tabs":"_5NQH4","bar":"_7s7DQ","tab":"_zWBmM","active":"_8HiqX","panel":"_qCmXi","inactive":"_zD5HH"};
|
|
11541
|
+
var stylesheet$1="._5NQH4{display:block}._7s7DQ{display:flex;justify-content:left;border-bottom:1px solid #e5e5e5;height:52px}._zWBmM{color:#6a6d70;cursor:pointer;height:52px;padding:16px 12px;max-width:200px;text-overflow:ellipsis;white-space:nowrap;overflow:hidden;border-bottom:1px solid transparent;border-radius:1px}._zWBmM:hover{color:#32363a}._zWBmM:focus{outline:none}._zWBmM._8HiqX{margin-bottom:-1px;border-bottom:2px solid #0b6ed0;color:#32363a;font-family:\"72Duplex\",\"72\",\"Helvetica Neue\",Helvetica,Arial,sans-serif;font-weight:500}._qCmXi{padding-top:32px}._qCmXi._zD5HH{display:none}._zWBmM.focus-visible,._zWBmM:focus-visible{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
11441
11542
|
icons_index.styleInject(css_248z$1);
|
|
11442
11543
|
|
|
11443
11544
|
const {
|
|
@@ -11461,8 +11562,8 @@ const Tabs = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
|
11461
11562
|
...rest
|
|
11462
11563
|
} = _ref;
|
|
11463
11564
|
const tabsId = useId(externalId);
|
|
11464
|
-
const tabIdPrefix =
|
|
11465
|
-
const tabPanelIdPrefix =
|
|
11565
|
+
const tabIdPrefix = "".concat(tabsId, "-tab-");
|
|
11566
|
+
const tabPanelIdPrefix = "".concat(tabsId, "-tab-panel-");
|
|
11466
11567
|
const tabRefs = React.useRef({});
|
|
11467
11568
|
const [tabIndexOfActiveTab, setTabIndexOfActiveTab] = React.useState(0);
|
|
11468
11569
|
const focusOnIndex = index => {
|
|
@@ -11477,7 +11578,7 @@ const Tabs = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
|
11477
11578
|
setTabIndexOfActiveTab(0);
|
|
11478
11579
|
};
|
|
11479
11580
|
const handleSelect = key => {
|
|
11480
|
-
onChange
|
|
11581
|
+
onChange === null || onChange === void 0 ? void 0 : onChange(key);
|
|
11481
11582
|
};
|
|
11482
11583
|
const handleKeyDown = (event, tabElementKey, index) => {
|
|
11483
11584
|
if (event.key === 'Enter' || event.key === ' ') {
|
|
@@ -11499,6 +11600,7 @@ const Tabs = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
|
11499
11600
|
const tabs = [];
|
|
11500
11601
|
React__default["default"].Children.forEach(children, (child, index) => {
|
|
11501
11602
|
if (child) {
|
|
11603
|
+
var _child$props$id;
|
|
11502
11604
|
const key = child.key || String(index);
|
|
11503
11605
|
const active = key === activeKey;
|
|
11504
11606
|
const context = {
|
|
@@ -11510,17 +11612,19 @@ const Tabs = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
|
11510
11612
|
value: context
|
|
11511
11613
|
}, /*#__PURE__*/React__default["default"].cloneElement(child, {
|
|
11512
11614
|
key,
|
|
11513
|
-
id: child.props.id
|
|
11615
|
+
id: (_child$props$id = child.props.id) !== null && _child$props$id !== void 0 ? _child$props$id : tabIdPrefix + key,
|
|
11514
11616
|
children: child.props.children,
|
|
11515
11617
|
ref: mergeRefs(child.ref, node => {
|
|
11516
11618
|
tabRefs.current[index] = node;
|
|
11517
11619
|
}),
|
|
11518
11620
|
onKeyDown: event => {
|
|
11519
|
-
|
|
11621
|
+
var _child$props$onKeyDow, _child$props;
|
|
11622
|
+
(_child$props$onKeyDow = (_child$props = child.props).onKeyDown) === null || _child$props$onKeyDow === void 0 ? void 0 : _child$props$onKeyDow.call(_child$props);
|
|
11520
11623
|
handleKeyDown(event, key, index);
|
|
11521
11624
|
},
|
|
11522
11625
|
onClick: () => {
|
|
11523
|
-
|
|
11626
|
+
var _child$props$onClick, _child$props2;
|
|
11627
|
+
(_child$props$onClick = (_child$props2 = child.props).onClick) === null || _child$props$onClick === void 0 ? void 0 : _child$props$onClick.call(_child$props2);
|
|
11524
11628
|
handleSelect(key);
|
|
11525
11629
|
},
|
|
11526
11630
|
'aria-controls': tabPanelIdPrefix + key
|
|
@@ -11533,6 +11637,7 @@ const Tabs = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
|
11533
11637
|
const panels = [];
|
|
11534
11638
|
React__default["default"].Children.forEach(children, (child, index) => {
|
|
11535
11639
|
if (child) {
|
|
11640
|
+
var _child$props$id2;
|
|
11536
11641
|
const key = child.key || String(index);
|
|
11537
11642
|
const isActive = key === activeKey;
|
|
11538
11643
|
const panelClasses = classNames__default["default"](styles$1.panel, {
|
|
@@ -11541,7 +11646,7 @@ const Tabs = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
|
11541
11646
|
panels.push( /*#__PURE__*/React__default["default"].createElement("div", {
|
|
11542
11647
|
key: key,
|
|
11543
11648
|
role: "tabpanel",
|
|
11544
|
-
"aria-labelledby": child.props.id
|
|
11649
|
+
"aria-labelledby": (_child$props$id2 = child.props.id) !== null && _child$props$id2 !== void 0 ? _child$props$id2 : tabIdPrefix + key,
|
|
11545
11650
|
className: panelClasses,
|
|
11546
11651
|
id: tabPanelIdPrefix + key
|
|
11547
11652
|
}, isActive ? child.props.children : null));
|
|
@@ -11590,9 +11695,9 @@ const Tab = /*#__PURE__*/React__default["default"].forwardRef((_ref, ref) => {
|
|
|
11590
11695
|
|
|
11591
11696
|
/* eslint-disable camelcase */
|
|
11592
11697
|
|
|
11593
|
-
var css_248z = ".
|
|
11594
|
-
var styles = {"toolbar":"
|
|
11595
|
-
var stylesheet=".
|
|
11698
|
+
var css_248z = "._2M2-Z,._fhBa6{display:flex}._fhBa6{flex-direction:column;align-items:center;min-width:165px;max-width:240px;padding:12px 16px 16px;border-right:1px solid #898989;background-color:#fff}._M5Blq{width:69px;min-width:auto;max-width:none}._GZcnC{width:100%}._xzxnS{margin-bottom:12px;background-color:transparent!important}._xzxnS:hover{background-color:rgba(11,110,208,.08)!important}._xzxnS:hover>svg{fill:#085caf}._xzxnS:hover>span{color:#085caf}._xzxnS:active{background-color:rgba(11,110,208,.12)!important}._xzxnS:active>svg{fill:#0854a1}._xzxnS:active>span{color:#0854a1}._xzxnS._XRkZ5{background-color:rgba(11,110,208,.08)!important}._xzxnS._XRkZ5>svg{fill:#0b6ed0}._xzxnS._XRkZ5>span{color:#0b6ed0;font-family:\"72Duplex\",\"72\",\"Helvetica Neue\",Helvetica,Arial,sans-serif;font-weight:500}._xzxnS._XRkZ5:hover{background-color:rgba(11,110,208,.08)!important}._xzxnS._XRkZ5:hover>svg{fill:#085caf}._xzxnS._XRkZ5:hover>span{color:#085caf}._xzxnS._XRkZ5:active{background-color:rgba(11,110,208,.12)!important}._xzxnS._XRkZ5:active>svg{fill:#0854a1}._xzxnS._XRkZ5:active>span{color:#0854a1}._ycTUl{border-radius:6px}._ycTUl>._S2C-L{display:block;fill:#515559}._Po3be{margin-top:auto;margin-bottom:0}._V7S7U{position:relative;width:295px;background-color:#fff;padding:2px 1px 2px 2px;border-right:1px solid #898989}._V7S7U:hover>._yNDcG{opacity:1}._h-eoD{width:0;border-width:0;padding:0}._hjkFc{border-radius:4px;min-width:100%;min-height:100%;outline:none}._jhr52{width:36px;height:36px;position:absolute;top:48px;right:-18px;display:flex;justify-content:center;align-items:center;padding:0;background-color:transparent;border:2px solid transparent;border-radius:6px;outline:none;cursor:pointer;z-index:10}._yNDcG{opacity:0}._jhr52._e4SoM._e4SoM,._O-XVZ,._yNDcG:hover{opacity:1}._jhr52._FSQLb._FSQLb{opacity:0}._jhr52>span{width:24px;height:24px;display:flex;justify-content:center;align-items:center;background-color:#fff;border:1px solid #898989;border-radius:50%}._jhr52>span:hover{background-color:#0b6ed0;border-color:#0b6ed0}._jhr52>span:hover>svg{fill:#fff}._jhr52>span:active{background-color:#0854a1;border-color:#0854a1}._jhr52>span:active>svg{fill:#fff}._jhr52>span>svg{fill:#515559;border-radius:50%}._hjkFc._Hylg1{display:none!important}._npS-x{width:100%;height:36px;display:flex;align-items:center;border:1px solid transparent;border-radius:4px;outline:none;cursor:pointer;padding:0 7px}._M-F9c{font-size:14px;color:#515559;justify-self:left;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}._h8Fxu{width:100%;height:36px;display:flex;align-items:center;border:1px solid transparent;border-radius:4px;outline:none;cursor:pointer;padding:0 5px}._cq2dr{fill:#515559}._XXIse{font-size:14px;color:#515559;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;margin-left:5px}._h8Fxu.focus-visible,._h8Fxu:focus-visible,._hjkFc.focus-visible,._hjkFc:focus-visible,._npS-x.focus-visible,._npS-x:focus-visible{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._jhr52.focus-visible,._jhr52:focus-visible{border-color:#0a3f88}._jhr52:active>span{background-color:#0854a1;border-color:#0854a1}._jhr52:active>span>svg{fill:#fff}._yNDcG.focus-visible,._yNDcG:focus-visible{opacity:1}";
|
|
11699
|
+
var styles = {"toolbar":"_2M2-Z","toolbarNav":"_fhBa6","toolbarNavCollapsed":"_M5Blq","toolbarTabs":"_GZcnC","toolbarTab":"_xzxnS","selected":"_XRkZ5","toolbarTabIconButton":"_ycTUl","icon":"_S2C-L","tabsExpandCollapseButton":"_Po3be","toolbarPanels":"_V7S7U","toolbarPanelExpandCollapseButtonDefaultHidden":"_yNDcG","toolbarPanelsCollapsed":"_h-eoD","toolbarPanel":"_hjkFc","toolbarPanelExpandCollapseButton":"_jhr52","toolbarPanelExpandCollapseButtonDefaultShown":"_O-XVZ","overrideShow":"_e4SoM","overrideHide":"_FSQLb","notSelected":"_Hylg1","buttonWithLabel":"_npS-x","buttonWithLabelLabel":"_M-F9c","iconButtonWithLabel":"_h8Fxu","iconButtonWithLabelIcon":"_cq2dr","iconButtonWithLabelLabel":"_XXIse"};
|
|
11700
|
+
var stylesheet="._2M2-Z,._fhBa6{display:flex}._fhBa6{flex-direction:column;align-items:center;min-width:165px;max-width:240px;padding:12px 16px 16px;border-right:1px solid #898989;background-color:#fff}._M5Blq{width:69px;min-width:auto;max-width:none}._GZcnC{width:100%}._xzxnS{margin-bottom:12px;background-color:transparent!important}._xzxnS:hover{background-color:rgba(11,110,208,.08)!important}._xzxnS:hover>svg{fill:#085caf}._xzxnS:hover>span{color:#085caf}._xzxnS:active{background-color:rgba(11,110,208,.12)!important}._xzxnS:active>svg{fill:#0854a1}._xzxnS:active>span{color:#0854a1}._xzxnS._XRkZ5{background-color:rgba(11,110,208,.08)!important}._xzxnS._XRkZ5>svg{fill:#0b6ed0}._xzxnS._XRkZ5>span{color:#0b6ed0;font-family:\"72Duplex\",\"72\",\"Helvetica Neue\",Helvetica,Arial,sans-serif;font-weight:500}._xzxnS._XRkZ5:hover{background-color:rgba(11,110,208,.08)!important}._xzxnS._XRkZ5:hover>svg{fill:#085caf}._xzxnS._XRkZ5:hover>span{color:#085caf}._xzxnS._XRkZ5:active{background-color:rgba(11,110,208,.12)!important}._xzxnS._XRkZ5:active>svg{fill:#0854a1}._xzxnS._XRkZ5:active>span{color:#0854a1}._ycTUl{border-radius:6px}._ycTUl>._S2C-L{display:block;fill:#515559}._Po3be{margin-top:auto;margin-bottom:0}._V7S7U{position:relative;width:295px;background-color:#fff;padding:2px 1px 2px 2px;border-right:1px solid #898989}._V7S7U:hover>._yNDcG{opacity:1}._h-eoD{width:0;border-width:0;padding:0}._hjkFc{border-radius:4px;min-width:100%;min-height:100%;outline:none}._jhr52{width:36px;height:36px;position:absolute;top:48px;right:-18px;display:flex;justify-content:center;align-items:center;padding:0;background-color:transparent;border:2px solid transparent;border-radius:6px;outline:none;cursor:pointer;z-index:10}._yNDcG{opacity:0}._jhr52._e4SoM._e4SoM,._O-XVZ,._yNDcG:hover{opacity:1}._jhr52._FSQLb._FSQLb{opacity:0}._jhr52>span{width:24px;height:24px;display:flex;justify-content:center;align-items:center;background-color:#fff;border:1px solid #898989;border-radius:50%}._jhr52>span:hover{background-color:#0b6ed0;border-color:#0b6ed0}._jhr52>span:hover>svg{fill:#fff}._jhr52>span:active{background-color:#0854a1;border-color:#0854a1}._jhr52>span:active>svg{fill:#fff}._jhr52>span>svg{fill:#515559;border-radius:50%}._hjkFc._Hylg1{display:none!important}._npS-x{width:100%;height:36px;display:flex;align-items:center;border:1px solid transparent;border-radius:4px;outline:none;cursor:pointer;padding:0 7px}._M-F9c{font-size:14px;color:#515559;justify-self:left;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}._h8Fxu{width:100%;height:36px;display:flex;align-items:center;border:1px solid transparent;border-radius:4px;outline:none;cursor:pointer;padding:0 5px}._cq2dr{fill:#515559}._XXIse{font-size:14px;color:#515559;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;margin-left:5px}._h8Fxu.focus-visible,._h8Fxu:focus-visible,._hjkFc.focus-visible,._hjkFc:focus-visible,._npS-x.focus-visible,._npS-x:focus-visible{box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._jhr52.focus-visible,._jhr52:focus-visible{border-color:#0a3f88}._jhr52:active>span{background-color:#0854a1;border-color:#0854a1}._jhr52:active>span>svg{fill:#fff}._yNDcG.focus-visible,._yNDcG:focus-visible{opacity:1}";
|
|
11596
11701
|
icons_index.styleInject(css_248z);
|
|
11597
11702
|
|
|
11598
11703
|
const {
|
|
@@ -11689,9 +11794,11 @@ const ToolbarTabs = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
11689
11794
|
React.useEffect(() => {
|
|
11690
11795
|
if (isExpandCollapseButtonFocused) {
|
|
11691
11796
|
if (isCollapsed) {
|
|
11692
|
-
|
|
11797
|
+
var _expandToolbarTabsIco;
|
|
11798
|
+
(_expandToolbarTabsIco = expandToolbarTabsIconButtonRef.current) === null || _expandToolbarTabsIco === void 0 ? void 0 : _expandToolbarTabsIco.focus();
|
|
11693
11799
|
} else {
|
|
11694
|
-
|
|
11800
|
+
var _collapseToolbarTabsI;
|
|
11801
|
+
(_collapseToolbarTabsI = collapseToolbarTabsIconButtonWithLabelRef.current) === null || _collapseToolbarTabsI === void 0 ? void 0 : _collapseToolbarTabsI.focus();
|
|
11695
11802
|
}
|
|
11696
11803
|
}
|
|
11697
11804
|
}, [isCollapsed, isExpandCollapseButtonFocused]);
|
|
@@ -11704,7 +11811,8 @@ const ToolbarTabs = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
11704
11811
|
const [focusedIndex, setFocusedIndex] = React.useState(selectedIndex);
|
|
11705
11812
|
const numTabs = React__default["default"].Children.count(children);
|
|
11706
11813
|
const focusTab = index => {
|
|
11707
|
-
|
|
11814
|
+
var _tabRefs$current;
|
|
11815
|
+
(_tabRefs$current = tabRefs.current) === null || _tabRefs$current === void 0 || (_tabRefs$current = _tabRefs$current[index]) === null || _tabRefs$current === void 0 ? void 0 : _tabRefs$current.focus();
|
|
11708
11816
|
setFocusedIndex(index);
|
|
11709
11817
|
};
|
|
11710
11818
|
|
|
@@ -11814,7 +11922,7 @@ const ToolbarTab = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
11814
11922
|
const isFocused = focusedIndex === index;
|
|
11815
11923
|
const isSelected = selectedIndex === index;
|
|
11816
11924
|
const handleSelect = () => {
|
|
11817
|
-
setSelectedIndex
|
|
11925
|
+
setSelectedIndex === null || setSelectedIndex === void 0 ? void 0 : setSelectedIndex(Number(index));
|
|
11818
11926
|
};
|
|
11819
11927
|
const handleClick = e => {
|
|
11820
11928
|
/*
|
|
@@ -11833,22 +11941,22 @@ const ToolbarTab = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
11833
11941
|
case 'ArrowDown':
|
|
11834
11942
|
case 'ArrowRight':
|
|
11835
11943
|
e.preventDefault(); // Prevent page scroll
|
|
11836
|
-
focusTab
|
|
11944
|
+
focusTab === null || focusTab === void 0 ? void 0 : focusTab(getNextIndex(focusedIndex, numTabs));
|
|
11837
11945
|
break;
|
|
11838
11946
|
case 'ArrowUp':
|
|
11839
11947
|
case 'ArrowLeft':
|
|
11840
11948
|
e.preventDefault(); // Prevent page scroll
|
|
11841
|
-
focusTab
|
|
11949
|
+
focusTab === null || focusTab === void 0 ? void 0 : focusTab(getPrevIndex(focusedIndex, numTabs));
|
|
11842
11950
|
break;
|
|
11843
11951
|
case 'PageUp':
|
|
11844
11952
|
case 'Home':
|
|
11845
11953
|
e.preventDefault(); // Prevent page scroll
|
|
11846
|
-
focusTab
|
|
11954
|
+
focusTab === null || focusTab === void 0 ? void 0 : focusTab(0);
|
|
11847
11955
|
break;
|
|
11848
11956
|
case 'PageDown':
|
|
11849
11957
|
case 'End':
|
|
11850
11958
|
e.preventDefault(); // Prevent page scroll
|
|
11851
|
-
focusTab
|
|
11959
|
+
focusTab === null || focusTab === void 0 ? void 0 : focusTab(Number(numTabs) - 1);
|
|
11852
11960
|
break;
|
|
11853
11961
|
default:
|
|
11854
11962
|
}
|
|
@@ -11858,13 +11966,13 @@ const ToolbarTab = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
11858
11966
|
ref,
|
|
11859
11967
|
role: 'tab',
|
|
11860
11968
|
'aria-selected': isSelected,
|
|
11861
|
-
'aria-controls': ariaControls ||
|
|
11862
|
-
id: id ||
|
|
11969
|
+
'aria-controls': ariaControls || "toolbar-".concat(toolbarId, "-panel-").concat(index),
|
|
11970
|
+
id: id || "toolbar-".concat(toolbarId, "-tab-").concat(index),
|
|
11863
11971
|
// Exsures the correct tab is focused when tabbing into the Toolbar
|
|
11864
11972
|
tabIndex: isFocused ? 0 : -1,
|
|
11865
11973
|
onClick: handleClick,
|
|
11866
11974
|
onKeyDown: handleKeyDown,
|
|
11867
|
-
'data-testid': dataTestId || getSubDataTestId(rootDataTestId,
|
|
11975
|
+
'data-testid': dataTestId || getSubDataTestId(rootDataTestId, "tab-".concat(index))
|
|
11868
11976
|
};
|
|
11869
11977
|
const iconButtonClassName = classNames__default["default"](className, styles.toolbarTab, styles.toolbarTabIconButton, {
|
|
11870
11978
|
[styles.selected]: isSelected
|
|
@@ -11967,6 +12075,7 @@ const ExpandCollapseButton = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
|
11967
12075
|
* ```
|
|
11968
12076
|
*/
|
|
11969
12077
|
const ToolbarPanels = /*#__PURE__*/React.forwardRef((_ref2, ref) => {
|
|
12078
|
+
var _props$id, _React$Children$toArr;
|
|
11970
12079
|
let {
|
|
11971
12080
|
isCollapsible = true,
|
|
11972
12081
|
defaultIsCollapsed = false,
|
|
@@ -11992,7 +12101,8 @@ const ToolbarPanels = /*#__PURE__*/React.forwardRef((_ref2, ref) => {
|
|
|
11992
12101
|
* This allows a screen reader user to click the expand/collapse button using their keyboard and have focus stay on the same button.
|
|
11993
12102
|
*/
|
|
11994
12103
|
if (wasExpandCollapseButtonClicked) {
|
|
11995
|
-
|
|
12104
|
+
var _expandCollapseButton;
|
|
12105
|
+
(_expandCollapseButton = expandCollapseButtonRef.current) === null || _expandCollapseButton === void 0 ? void 0 : _expandCollapseButton.focus();
|
|
11996
12106
|
setWasExpandCollapseButtonClicked(false);
|
|
11997
12107
|
}
|
|
11998
12108
|
}, [wasExpandCollapseButtonClicked]);
|
|
@@ -12000,7 +12110,7 @@ const ToolbarPanels = /*#__PURE__*/React.forwardRef((_ref2, ref) => {
|
|
|
12000
12110
|
setIsCollapsed(currentIsCollapsed => !currentIsCollapsed);
|
|
12001
12111
|
setWasExpandCollapseButtonClicked(true);
|
|
12002
12112
|
};
|
|
12003
|
-
const selectedTabPanelId = React__default["default"].Children.toArray(children)
|
|
12113
|
+
const selectedTabPanelId = (_props$id = (_React$Children$toArr = React__default["default"].Children.toArray(children)) === null || _React$Children$toArr === void 0 || (_React$Children$toArr = _React$Children$toArr[Number(selectedIndex)]) === null || _React$Children$toArr === void 0 || (_React$Children$toArr = _React$Children$toArr.props) === null || _React$Children$toArr === void 0 ? void 0 : _React$Children$toArr.id) !== null && _props$id !== void 0 ? _props$id : "toolbar-".concat(toolbarId, "-panel-").concat(selectedIndex);
|
|
12004
12114
|
return /*#__PURE__*/React__default["default"].createElement("div", _extends__default["default"]({}, rest, {
|
|
12005
12115
|
ref: mergeRefs(ref, isToolbarPanelsContainerHoveredRef),
|
|
12006
12116
|
className: classNames__default["default"](className, styles.toolbarPanels, {
|
|
@@ -12056,9 +12166,9 @@ const ToolbarPanel = _ref => {
|
|
|
12056
12166
|
[styles.notSelected]: !isSelected
|
|
12057
12167
|
}),
|
|
12058
12168
|
tabIndex: isFocusable && isContainerInTabOrder ? 0 : -1,
|
|
12059
|
-
"aria-labelledby": ariaLabelledby ||
|
|
12060
|
-
id: id ||
|
|
12061
|
-
"data-testid": dataTestId || getSubDataTestId(rootDataTestId,
|
|
12169
|
+
"aria-labelledby": ariaLabelledby || "toolbar-".concat(toolbarId, "-tab-").concat(index),
|
|
12170
|
+
id: id || "toolbar-".concat(toolbarId, "-panel-").concat(index),
|
|
12171
|
+
"data-testid": dataTestId || getSubDataTestId(rootDataTestId, "panel-".concat(index))
|
|
12062
12172
|
}), isFocusable ? children : null);
|
|
12063
12173
|
};
|
|
12064
12174
|
|