@qualtrics/ui-react 2.27.0 → 2.29.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +23 -0
- package/dist/__shared/cjs/{index-88aa3bce.js → index-c2d2f188.js} +707 -451
- package/dist/__shared/cjs/{index-e6893573.js → index-c9e48360.js} +3 -3
- package/dist/components/Accordion/Accordion2.js +3 -3
- package/dist/components/Button/Button.js +3 -3
- package/dist/components/ButtonGroup/ButtonGroup2.js +3 -3
- package/dist/components/Checkbox/Checkbox.js +54 -10
- package/dist/components/Checkbox/Checkbox2.js +3 -3
- package/dist/components/Checkbox/VisualCheckbox2.js +3 -3
- package/dist/components/ColorPicker/ColorPicker2.js +3 -3
- package/dist/components/Combobox/Combobox2.js +3 -3
- package/dist/components/ConfigPane/ConfigPane2.js +3 -3
- package/dist/components/Divider/Divider2.js +3 -3
- package/dist/components/Dropdown/Dropdown.js +59 -7
- package/dist/components/Dropdown/Dropdown2.js +3 -3
- package/dist/components/FilePicker/FilePicker2.js +3 -3
- package/dist/components/FormField/Caption.js +3 -3
- package/dist/components/FormField/FormField2.js +3 -3
- package/dist/components/FullScreenTakeover/FullScreenTakeover2.js +3 -3
- package/dist/components/IconButton/IconButton2.js +3 -3
- package/dist/components/InlineInput/InlineInput2.js +3 -3
- package/dist/components/Input/Input2.js +3 -3
- 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/LoadingSpinner2.js +3 -3
- package/dist/components/LogicEditor/ConditionSet.js +3 -4
- package/dist/components/LogicEditor/Controls.js +66 -48
- package/dist/components/LogicEditor/LogicEditor.js +34 -8
- package/dist/components/LogicEditor/LogicEditor2.js +3 -3
- package/dist/components/LogicEditor/utils.js +4 -1
- package/dist/components/Modal/Modal2.js +3 -3
- package/dist/components/NewMenu/NewMenu.js +3 -3
- package/dist/components/NumberStepper/NumberStepper2.js +3 -3
- package/dist/components/PageLayout/PageLayout.js +3 -3
- package/dist/components/Pagination/Pagination2.js +3 -3
- package/dist/components/Popover/Popover2.js +3 -3
- package/dist/components/QuickSearch/QuickSearch2.js +3 -3
- package/dist/components/Radio/Radio.js +25 -5
- package/dist/components/Radio/Radio2.js +3 -3
- package/dist/components/Radio/RadioGroup.js +16 -3
- package/dist/components/SearchInput/SearchInput2.js +3 -3
- package/dist/components/SidebarNav/SidebarNav2.js +3 -3
- package/dist/components/Slider/Slider2.js +3 -3
- package/dist/components/Switch/Switch2.js +3 -3
- package/dist/components/Table/Table2.js +3 -3
- package/dist/components/Tabs/Tabs2.js +3 -3
- package/dist/components/Tooltip/Tooltip2.js +3 -3
- package/dist/components/deprecated_ColorPicker/ColorPicker2.js +3 -3
- package/dist/components/deprecated_NumberStepper/NumberStepper2.js +3 -3
- package/dist/components/deprecated_Tabs/Tabs2.js +3 -3
- package/dist/components/deprecated_Toolbar/Toolbar2.js +3 -3
- package/dist/hooks/useOverlay/useOverlay2.js +3 -3
- package/dist/hooks/useScreenReaderAnnouncement/useScreenReaderAnnouncement2.js +3 -3
- package/dist/icons/Icon.js +3 -3
- package/dist/icons/index.js +1 -1
- package/dist/index.d.ts +12 -2
- package/dist/index.es.js +1 -1
- package/dist/index.js +3 -3
- package/dist/next/AdvancedTable/AdvancedTable.js +54 -78
- package/dist/next/AdvancedTable/AdvancedTable2.js +3 -3
- package/dist/next/CollapsibleSearchInput/CollapsibleSearchInput2.js +3 -3
- package/dist/next/Combobox/Combobox2.js +3 -3
- package/dist/next/Drawer/Drawer2.js +3 -3
- package/dist/next/FilterAnchor/FilterAnchor2.js +3 -3
- package/dist/next/Form/FormFields/FormFieldWrapper.js +36 -0
- package/dist/next/Form/FormFields/InputField.js +8 -0
- package/dist/next/Form/index.js +2 -0
- package/dist/next/Form/useForm.js +298 -0
- package/dist/next/Form/useFormField.js +25 -0
- package/dist/next/Form/utils/createFormInstance.js +32 -0
- package/dist/next/Form/utils/useFormContext.js +9 -0
- package/dist/next/Input/Input.js +47 -7
- package/dist/next/Input/Input2.js +3 -3
- package/dist/next/Menu/Menu2.js +3 -3
- package/dist/next/Menu/MenuPane.js +2 -2
- package/dist/next/Pagination/Pagination.css.js +9 -0
- package/dist/next/Pagination/Pagination.css.ts.vanilla.js +8 -0
- package/dist/next/Pagination/Pagination.js +166 -0
- package/dist/next/Pagination/RowDisplayCount.js +46 -0
- package/dist/next/Pagination/index.js +2 -0
- package/dist/next/PhoneNumberInput/PhoneNumberInput2.js +3 -3
- package/dist/next/Select/Select2.js +3 -3
- package/dist/next/SplitButton/SplitButton2.js +3 -3
- package/dist/next/TimePicker/TimeDropdown.js +9 -3
- package/dist/next/TimePicker/TimePicker.js +1 -1
- package/dist/next/TimePicker/TimePicker2.js +3 -3
- package/dist/next/ToggleButton/ToggleButton.js +2 -2
- package/dist/next/ToggleButton/styles.js +3 -3
- package/dist/next/index.d.ts +170 -4
- package/dist/next/index.es.js +29 -23
- package/dist/next/index.js +1968 -1474
- package/dist/utils/Flyout/Flyout2.js +3 -3
- package/icons/package.json +1 -1
- package/next/package.json +2 -2
- package/package.json +3 -3
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import '../../../utils/index.js';
|
|
2
|
+
import createContextUtilities from '../../../utils/createContextUtilities/createContextUtilities.js';
|
|
3
|
+
|
|
4
|
+
const {
|
|
5
|
+
Provider: FormProvider,
|
|
6
|
+
useContext: useFormContext
|
|
7
|
+
} = createContextUtilities({});
|
|
8
|
+
|
|
9
|
+
export { FormProvider, useFormContext };
|
package/dist/next/Input/Input.js
CHANGED
|
@@ -2,8 +2,14 @@ import _extends from '@babel/runtime-corejs3/helpers/extends';
|
|
|
2
2
|
import React__default, { forwardRef, useRef, useState } from 'react';
|
|
3
3
|
import classNames from 'classnames';
|
|
4
4
|
import inputClasses from './Input2.js';
|
|
5
|
+
import FormFieldWrapper from '../Form/FormFields/FormFieldWrapper.js';
|
|
6
|
+
import useFormField from '../Form/useFormField.js';
|
|
5
7
|
import '../../hooks/index.js';
|
|
8
|
+
import '../../hooks/useId/index.js';
|
|
9
|
+
import '../../utils/mergeRefs/index.js';
|
|
10
|
+
import useId from '../../hooks/useId/useId.js';
|
|
6
11
|
import useSSRLayoutEffect from '../../hooks/useSSRLayoutEffect/useSSRLayoutEffect.js';
|
|
12
|
+
import mergeRefs from '../../utils/mergeRefs/mergeRefs.js';
|
|
7
13
|
|
|
8
14
|
const getAddOnComponent = (addOn, containerClassName, containerRef) => {
|
|
9
15
|
if (!addOn) {
|
|
@@ -20,16 +26,39 @@ const getAddOnComponent = (addOn, containerClassName, containerRef) => {
|
|
|
20
26
|
};
|
|
21
27
|
const Input = /*#__PURE__*/forwardRef((_ref, ref) => {
|
|
22
28
|
let {
|
|
29
|
+
name,
|
|
30
|
+
id,
|
|
23
31
|
type = 'text',
|
|
24
32
|
initialValue,
|
|
25
|
-
value,
|
|
26
|
-
onChange,
|
|
33
|
+
value: externalValue,
|
|
34
|
+
onChange: externalOnChange,
|
|
35
|
+
onBlur: externalOnBlur,
|
|
36
|
+
label,
|
|
27
37
|
leftAddOn,
|
|
28
38
|
rightAddOn,
|
|
39
|
+
errorText,
|
|
40
|
+
helperText,
|
|
29
41
|
className: externalClassName,
|
|
42
|
+
'data-testid': dataTestId,
|
|
30
43
|
style,
|
|
31
44
|
...rest
|
|
32
45
|
} = _ref;
|
|
46
|
+
const {
|
|
47
|
+
register,
|
|
48
|
+
fieldErrors
|
|
49
|
+
} = useFormField();
|
|
50
|
+
const inputId = useId(id);
|
|
51
|
+
const registerProps = name && register ? register(name, {
|
|
52
|
+
type: 'text'
|
|
53
|
+
}) : undefined;
|
|
54
|
+
const onChange = e => {
|
|
55
|
+
externalOnChange === null || externalOnChange === void 0 || externalOnChange(e);
|
|
56
|
+
registerProps === null || registerProps === void 0 || registerProps.onChange(e);
|
|
57
|
+
};
|
|
58
|
+
const onBlur = e => {
|
|
59
|
+
externalOnBlur === null || externalOnBlur === void 0 || externalOnBlur(e);
|
|
60
|
+
registerProps === null || registerProps === void 0 || registerProps.onBlur(e);
|
|
61
|
+
};
|
|
33
62
|
const leftAddOnRef = useRef(null);
|
|
34
63
|
const rightAddOnRef = useRef(null);
|
|
35
64
|
const [addOnWidths, setAddOnWidths] = useState({
|
|
@@ -55,21 +84,32 @@ const Input = /*#__PURE__*/forwardRef((_ref, ref) => {
|
|
|
55
84
|
rightAddOn // Re-runs effect when the right add-on changes
|
|
56
85
|
]);
|
|
57
86
|
|
|
58
|
-
return /*#__PURE__*/React__default.createElement(
|
|
59
|
-
|
|
87
|
+
return /*#__PURE__*/React__default.createElement(FormFieldWrapper, {
|
|
88
|
+
inputId: inputId,
|
|
89
|
+
"data-testid": dataTestId,
|
|
90
|
+
label: label,
|
|
91
|
+
errorText: errorText !== null && errorText !== void 0 ? errorText : name && (fieldErrors === null || fieldErrors === void 0 ? void 0 : fieldErrors[name]),
|
|
92
|
+
helperText: helperText,
|
|
93
|
+
className: externalClassName,
|
|
60
94
|
style: style
|
|
95
|
+
}, /*#__PURE__*/React__default.createElement("span", {
|
|
96
|
+
className: inputClasses.container
|
|
61
97
|
}, getAddOnComponent(leftAddOn, inputClasses.leftAddOn, leftAddOnRef), /*#__PURE__*/React__default.createElement("input", _extends({}, rest, {
|
|
98
|
+
id: inputId,
|
|
99
|
+
name: registerProps === null || registerProps === void 0 ? void 0 : registerProps.name,
|
|
62
100
|
type: type,
|
|
63
101
|
defaultValue: initialValue,
|
|
64
|
-
value: value,
|
|
102
|
+
value: externalValue !== null && externalValue !== void 0 ? externalValue : registerProps === null || registerProps === void 0 ? void 0 : registerProps.value,
|
|
65
103
|
onChange: onChange,
|
|
104
|
+
onBlur: onBlur,
|
|
66
105
|
className: inputClasses.input,
|
|
67
106
|
style: {
|
|
68
107
|
paddingLeft: "".concat(addOnWidths.leftAddOnWidth + ADD_ON_HORIZONTAL_PADDING, "px"),
|
|
69
108
|
paddingRight: "".concat(addOnWidths.rightAddOnWidth + ADD_ON_HORIZONTAL_PADDING, "px")
|
|
70
109
|
},
|
|
71
|
-
|
|
72
|
-
|
|
110
|
+
"data-testid": dataTestId,
|
|
111
|
+
ref: mergeRefs(ref, registerProps === null || registerProps === void 0 ? void 0 : registerProps.ref)
|
|
112
|
+
})), getAddOnComponent(rightAddOn, inputClasses.rightAddOn, rightAddOnRef)));
|
|
73
113
|
});
|
|
74
114
|
|
|
75
115
|
export { Input as default };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import styleInject from './../../__node_modules/style-inject/dist/style-inject.es.js';
|
|
2
2
|
|
|
3
|
-
var css_248z = ".
|
|
4
|
-
var inputClasses = {"container":"
|
|
5
|
-
var stylesheet=".
|
|
3
|
+
var css_248z = "._qUQkQ{position:relative;display:inline-block;height:36px}._8u-HP{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}._8u-HP:hover{cursor:pointer;background-color:#f5f5f5}._8u-HP:focus{background-color:#fafafa;cursor:text;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88;outline:none;border-color:transparent}._8u-HP:disabled,._8u-HP[aria-disabled=true]{background-color:#fafafa;border-color:#e5e5e5;color:#9d9fa1;-webkit-text-fill-color:#9d9fa1;cursor:not-allowed}._8u-HP:disabled::-moz-placeholder,._8u-HP[aria-disabled=true]::-moz-placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._8u-HP:disabled::placeholder,._8u-HP[aria-disabled=true]::placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._8u-HP:invalid,._8u-HP[aria-invalid=true]{border-color:#b00}._8u-HP:invalid:focus,._8u-HP[aria-invalid=true]:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #900000;border-color:transparent}._8u-HP[type=number]{-moz-appearance:textfield}._8u-HP[type=number]::-webkit-inner-spin-button,._8u-HP[type=number]::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}._8u-HP::-moz-placeholder{color:#515559;opacity:1}._8u-HP::placeholder{color:#515559;opacity:1}._3dyBI{pointer-events:none;color:#515559;fill:#515559}._lkORl{display:flex;flex-direction:column;align-items:center;position:absolute;top:50%;transform:translateY(-50%)}._qmQyj{color:#515559;font-size:16px}._v3K-R{left:0;margin-left:6px}._SU6o5,._v3K-R{pointer-events:none;color:#515559;fill:#515559;display:flex;flex-direction:column;align-items:center;position:absolute;top:50%;transform:translateY(-50%)}._SU6o5{right:0;margin-right:6px}";
|
|
4
|
+
var inputClasses = {"container":"_qUQkQ","input":"_8u-HP","addOn":"_3dyBI","addOnVerticalCenter":"_lkORl","addOnTextNode":"_qmQyj","leftAddOn":"_v3K-R","rightAddOn":"_SU6o5"};
|
|
5
|
+
var stylesheet="._qUQkQ{position:relative;display:inline-block;height:36px}._8u-HP{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}._8u-HP:hover{cursor:pointer;background-color:#f5f5f5}._8u-HP:focus{background-color:#fafafa;cursor:text;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88;outline:none;border-color:transparent}._8u-HP:disabled,._8u-HP[aria-disabled=true]{background-color:#fafafa;border-color:#e5e5e5;color:#9d9fa1;-webkit-text-fill-color:#9d9fa1;cursor:not-allowed}._8u-HP:disabled::-moz-placeholder,._8u-HP[aria-disabled=true]::-moz-placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._8u-HP:disabled::placeholder,._8u-HP[aria-disabled=true]::placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._8u-HP:invalid,._8u-HP[aria-invalid=true]{border-color:#b00}._8u-HP:invalid:focus,._8u-HP[aria-invalid=true]:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px #900000;border-color:transparent}._8u-HP[type=number]{-moz-appearance:textfield}._8u-HP[type=number]::-webkit-inner-spin-button,._8u-HP[type=number]::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}._8u-HP::-moz-placeholder{color:#515559;opacity:1}._8u-HP::placeholder{color:#515559;opacity:1}._3dyBI{pointer-events:none;color:#515559;fill:#515559}._lkORl{display:flex;flex-direction:column;align-items:center;position:absolute;top:50%;transform:translateY(-50%)}._qmQyj{color:#515559;font-size:16px}._v3K-R{left:0;margin-left:6px}._SU6o5,._v3K-R{pointer-events:none;color:#515559;fill:#515559;display:flex;flex-direction:column;align-items:center;position:absolute;top:50%;transform:translateY(-50%)}._SU6o5{right:0;margin-right:6px}";
|
|
6
6
|
if(typeof process !== 'object' || !process.hasOwnProperty('env') || process.env.NODE_ENV !== 'test'){styleInject(css_248z);}
|
|
7
7
|
|
|
8
8
|
export { inputClasses as default, stylesheet };
|
package/dist/next/Menu/Menu2.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import styleInject from './../../__node_modules/style-inject/dist/style-inject.es.js';
|
|
2
2
|
|
|
3
|
-
var css_248z = ".
|
|
4
|
-
var styles = {"buttonContainer":"
|
|
5
|
-
var stylesheet=".
|
|
3
|
+
var css_248z = "._JzPKZ{position:relative;display:inline-flex;height:36px;min-width:60px;cursor:pointer}._JzPKZ>._q6pza{cursor:unset;width:100%;height:100%;padding:0 28px 0 12px;border-radius:4px;white-space:nowrap;line-height:20px;font-size:14px;text-align:left;outline:none;border:none;box-shadow:inset 0 0 0 1px #898989;color:#515559;background-color:#fafafa;overflow:hidden;text-overflow:ellipsis}._JzPKZ>._q6pza:hover:not([aria-disabled=true]){background-color:#f5f5f5}._JzPKZ>._q6pza.focus-visible,._JzPKZ>._q6pza:focus-visible{background-color:#fafafa;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._JzPKZ>._q6pza+._4U8FO{fill:#515559;position:absolute;pointer-events:none;right:4px;top:50%;transform:translateY(-50%)}._JzPKZ>._q6pza[data-state=open]+._4U8FO{transform:rotate(-180deg) translateY(50%)}._JzPKZ>._q6pza[aria-disabled=true]{box-shadow:inset 0 0 0 1px #e5e5e5;color:#74777a;cursor:not-allowed}._JzPKZ>._q6pza[aria-disabled=true]+._4U8FO{fill:#515559;opacity:.4}._R24FG>[data-radix-popper-content-wrapper]{overflow:hidden;background-color:#fff;max-width:350px;box-shadow:0 8px 20px rgba(0,0,0,.1),0 4px 6px rgba(0,0,0,.05);border-radius:4px;z-index:var(--mask-z-index)!important;width:var(--mask-width);height:var(--mask-height);transition:height .35s,width .35s}._R24FG>[data-radix-popper-content-wrapper] [data-radix-popper-content-wrapper]{transform:translateZ(0)!important}._jjLLy{margin:0;padding-bottom:var(--flyout-bottom-padding);background:#fff;transition:margin-left .35s,opacity .35s,height .35s,width .35s;opacity:1;max-width:350px;width:-webkit-max-content;width:-moz-max-content;width:max-content;min-width:200px;max-height:var(--flyout-max-height)}._jjLLy ._V4D9n{height:100%;overflow-y:scroll}._jjLLy._SZQCR{margin-left:30px;opacity:0}._jjLLy._wMgQL{margin-left:-30px}._Qq6ps{position:relative;padding:10px 12px;display:flex;flex-direction:row;min-height:40px;align-items:center;cursor:pointer;outline:none;word-break:break-word;font-size:14px;color:#32363a;width:100%}._Qq6ps._Uy4Cq{cursor:unset}._Qq6ps ._oEnlH{fill:#32363a;margin-right:4px}._Qq6ps:focus,._Qq6ps:hover:not(._Qq6ps._Uy4Cq){background-color:#efefef;box-shadow:inset 0 0 0 2px #0a3f88,inset 0 0 0 4px #fff;border-radius:6px}._Qq6ps[aria-disabled=true]{cursor:not-allowed;opacity:.65}._Qq6ps._2pXrP{padding-right:32px}._Qq6ps._2pXrP ._4U8FO{position:absolute;height:100%;right:3px;fill:#515559}._Qq6ps._T7j0r{pointer-events:none}._F-fgA{position:-webkit-sticky;position:sticky;top:0;background-color:#fff;border-bottom:1px solid #e8e8e8}._F-fgA._tR4v6{padding-top:52px}._Ys3hV{pointer-events:none;position:fixed;left:0;top:0;transition:width .35s;min-width:200px;width:var(--mask-width);max-width:350px}._-uV5H{position:absolute;padding:8px;border-radius:4px 4px 0 0;pointer-events:auto;opacity:1;width:100%;transition:opacity .35s,margin-left .35s}._-uV5H._wMgQL{opacity:0}._-uV5H._wMgQL>._7IFWj{margin-left:-30px}._-uV5H._SZQCR{opacity:0}._-uV5H._SZQCR>._7IFWj{margin-left:30px}._-uV5H>._7IFWj{transition:margin-left .35s;width:100%}._-uV5H._T7j0r{pointer-events:none}body.keyboard-user ._Qq6ps:hover:not(:focus){background-color:#fff;box-shadow:none}";
|
|
4
|
+
var styles = {"buttonContainer":"_JzPKZ","button":"_q6pza","rightIcon":"_4U8FO","maskContainer":"_R24FG","flyout":"_jjLLy","scrollContainer":"_V4D9n","animatedRight":"_SZQCR","animatedLeft":"_wMgQL","menuItem":"_Qq6ps","noItems":"_Uy4Cq","backIcon":"_oEnlH","subMenu":"_2pXrP","unresponsive":"_T7j0r","stickyBox":"_F-fgA","isSearchable":"_tR4v6","searchBoxesContainer":"_Ys3hV","searchBox":"_-uV5H","searchInput":"_7IFWj"};
|
|
5
|
+
var stylesheet="._JzPKZ{position:relative;display:inline-flex;height:36px;min-width:60px;cursor:pointer}._JzPKZ>._q6pza{cursor:unset;width:100%;height:100%;padding:0 28px 0 12px;border-radius:4px;white-space:nowrap;line-height:20px;font-size:14px;text-align:left;outline:none;border:none;box-shadow:inset 0 0 0 1px #898989;color:#515559;background-color:#fafafa;overflow:hidden;text-overflow:ellipsis}._JzPKZ>._q6pza:hover:not([aria-disabled=true]){background-color:#f5f5f5}._JzPKZ>._q6pza.focus-visible,._JzPKZ>._q6pza:focus-visible{background-color:#fafafa;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}._JzPKZ>._q6pza+._4U8FO{fill:#515559;position:absolute;pointer-events:none;right:4px;top:50%;transform:translateY(-50%)}._JzPKZ>._q6pza[data-state=open]+._4U8FO{transform:rotate(-180deg) translateY(50%)}._JzPKZ>._q6pza[aria-disabled=true]{box-shadow:inset 0 0 0 1px #e5e5e5;color:#74777a;cursor:not-allowed}._JzPKZ>._q6pza[aria-disabled=true]+._4U8FO{fill:#515559;opacity:.4}._R24FG>[data-radix-popper-content-wrapper]{overflow:hidden;background-color:#fff;max-width:350px;box-shadow:0 8px 20px rgba(0,0,0,.1),0 4px 6px rgba(0,0,0,.05);border-radius:4px;z-index:var(--mask-z-index)!important;width:var(--mask-width);height:var(--mask-height);transition:height .35s,width .35s}._R24FG>[data-radix-popper-content-wrapper] [data-radix-popper-content-wrapper]{transform:translateZ(0)!important}._jjLLy{margin:0;padding-bottom:var(--flyout-bottom-padding);background:#fff;transition:margin-left .35s,opacity .35s,height .35s,width .35s;opacity:1;max-width:350px;width:-webkit-max-content;width:-moz-max-content;width:max-content;min-width:200px;max-height:var(--flyout-max-height)}._jjLLy ._V4D9n{height:100%;overflow-y:scroll}._jjLLy._SZQCR{margin-left:30px;opacity:0}._jjLLy._wMgQL{margin-left:-30px}._Qq6ps{position:relative;padding:10px 12px;display:flex;flex-direction:row;min-height:40px;align-items:center;cursor:pointer;outline:none;word-break:break-word;font-size:14px;color:#32363a;width:100%}._Qq6ps._Uy4Cq{cursor:unset}._Qq6ps ._oEnlH{fill:#32363a;margin-right:4px}._Qq6ps:focus,._Qq6ps:hover:not(._Qq6ps._Uy4Cq){background-color:#efefef;box-shadow:inset 0 0 0 2px #0a3f88,inset 0 0 0 4px #fff;border-radius:6px}._Qq6ps[aria-disabled=true]{cursor:not-allowed;opacity:.65}._Qq6ps._2pXrP{padding-right:32px}._Qq6ps._2pXrP ._4U8FO{position:absolute;height:100%;right:3px;fill:#515559}._Qq6ps._T7j0r{pointer-events:none}._F-fgA{position:-webkit-sticky;position:sticky;top:0;background-color:#fff;border-bottom:1px solid #e8e8e8}._F-fgA._tR4v6{padding-top:52px}._Ys3hV{pointer-events:none;position:fixed;left:0;top:0;transition:width .35s;min-width:200px;width:var(--mask-width);max-width:350px}._-uV5H{position:absolute;padding:8px;border-radius:4px 4px 0 0;pointer-events:auto;opacity:1;width:100%;transition:opacity .35s,margin-left .35s}._-uV5H._wMgQL{opacity:0}._-uV5H._wMgQL>._7IFWj{margin-left:-30px}._-uV5H._SZQCR{opacity:0}._-uV5H._SZQCR>._7IFWj{margin-left:30px}._-uV5H>._7IFWj{transition:margin-left .35s;width:100%}._-uV5H._T7j0r{pointer-events:none}body.keyboard-user ._Qq6ps:hover:not(:focus){background-color:#fff;box-shadow:none}";
|
|
6
6
|
if(typeof process !== 'object' || !process.hasOwnProperty('env') || process.env.NODE_ENV !== 'test'){styleInject(css_248z);}
|
|
7
7
|
|
|
8
8
|
export { styles as default, stylesheet };
|
|
@@ -130,8 +130,8 @@ const MenuPane = /*#__PURE__*/React__default.forwardRef((_ref, ref) => {
|
|
|
130
130
|
// We use the top-level Radix container as a mask. Radix does not expose this container to consumers, except through CSS.
|
|
131
131
|
// These hooks dynamically update the style of that container using CSS variables.
|
|
132
132
|
useCSSVariable('--mask-z-index', String(zIndex), [open]);
|
|
133
|
-
useCSSVariable('--mask-width', "".concat(maskWidth, "px"));
|
|
134
|
-
useCSSVariable('--mask-height', "".concat(maskHeight, "px"));
|
|
133
|
+
useCSSVariable('--mask-width', Number.isNaN(Number(maskWidth)) ? "".concat(maskWidth) : "".concat(maskWidth, "px"));
|
|
134
|
+
useCSSVariable('--mask-height', Number.isNaN(Number(maskHeight)) ? "".concat(maskHeight) : "".concat(maskHeight, "px"));
|
|
135
135
|
useCSSVariable('--flyout-max-height', "".concat(paneMaxHeight, "px"));
|
|
136
136
|
useCSSVariable('--flyout-bottom-padding', "".concat(paneBottomPadding, "px"));
|
|
137
137
|
useOverlay({
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import './Pagination.css.ts.vanilla.js';
|
|
2
|
+
|
|
3
|
+
var growingInput = 'Pagination_growingInput__1iropsc2';
|
|
4
|
+
var hidden = 'Pagination_hidden__1iropsc3';
|
|
5
|
+
var pageNumber = 'Pagination_pageNumber__1iropsc1';
|
|
6
|
+
var pagination = 'Pagination_pagination__1iropsc0';
|
|
7
|
+
var rowCount = 'Pagination_rowCount__1iropsc4';
|
|
8
|
+
|
|
9
|
+
export { growingInput, hidden, pageNumber, pagination, rowCount };
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import styleInject from './../../__node_modules/style-inject/dist/style-inject.es.js';
|
|
2
|
+
|
|
3
|
+
var css_248z = ".Pagination_pagination__1iropsc0{display:flex;align-items:center}.Pagination_pageNumber__1iropsc1{display:inline-flex;align-items:center;font-size:14px;grid-gap:6px;gap:6px;padding:0 6px;color:#32363a;text-align:center}.Pagination_growingInput__1iropsc2{position:relative;display:inline-flex}.Pagination_hidden__1iropsc3{position:absolute;visibility:hidden;padding:8px 12px;border:1px solid transparent}.Pagination_rowCount__1iropsc4{display:inline-flex;align-items:center;grid-gap:6px;gap:6px;font-size:14px;padding:0 6px;color:#32363a}";
|
|
4
|
+
var Pagination_css_ts_vanilla = {"Pagination_pagination__1iropsc0":"Pagination_pagination__1iropsc0","Pagination_pageNumber__1iropsc1":"Pagination_pageNumber__1iropsc1","Pagination_growingInput__1iropsc2":"Pagination_growingInput__1iropsc2","Pagination_hidden__1iropsc3":"Pagination_hidden__1iropsc3","Pagination_rowCount__1iropsc4":"Pagination_rowCount__1iropsc4"};
|
|
5
|
+
var stylesheet=".Pagination_pagination__1iropsc0{display:flex;align-items:center}.Pagination_pageNumber__1iropsc1{display:inline-flex;align-items:center;font-size:14px;grid-gap:6px;gap:6px;padding:0 6px;color:#32363a;text-align:center}.Pagination_growingInput__1iropsc2{position:relative;display:inline-flex}.Pagination_hidden__1iropsc3{position:absolute;visibility:hidden;padding:8px 12px;border:1px solid transparent}.Pagination_rowCount__1iropsc4{display:inline-flex;align-items:center;grid-gap:6px;gap:6px;font-size:14px;padding:0 6px;color:#32363a}";
|
|
6
|
+
if(typeof process !== 'object' || !process.hasOwnProperty('env') || process.env.NODE_ENV !== 'test'){styleInject(css_248z);}
|
|
7
|
+
|
|
8
|
+
export { Pagination_css_ts_vanilla as default, stylesheet };
|
|
@@ -0,0 +1,166 @@
|
|
|
1
|
+
import _extends from '@babel/runtime-corejs3/helpers/extends';
|
|
2
|
+
import React__default, { useState, useRef } from 'react';
|
|
3
|
+
import { growingInput, hidden, pageNumber, pagination } from './Pagination.css.js';
|
|
4
|
+
import '../../components/index.js';
|
|
5
|
+
import '../index.es.js';
|
|
6
|
+
import '../../icons/index.es.js';
|
|
7
|
+
import '../../utils/index.js';
|
|
8
|
+
import '../../hooks/index.js';
|
|
9
|
+
import useSSRLayoutEffect from '../../hooks/useSSRLayoutEffect/useSSRLayoutEffect.js';
|
|
10
|
+
import Input from '../Input/Input.js';
|
|
11
|
+
import getSubDataTestId from '../../utils/getSubDataTestId/getSubDataTestId.js';
|
|
12
|
+
import Translate from '../../utils/Translation/Translate.js';
|
|
13
|
+
import useTranslation from '../../utils/Translation/useTranslation.js';
|
|
14
|
+
import useScreenReaderAnnouncement from '../../hooks/useScreenReaderAnnouncement/useScreenReaderAnnouncement.js';
|
|
15
|
+
import { useDidUpdate } from '../../hooks/useDidUpdate/useDidUpdate.js';
|
|
16
|
+
import IconButton from '../../components/IconButton/IconButton.js';
|
|
17
|
+
import ChevronSkipBackIcon from '../../icons/components/ChevronSkipBackIcon.js';
|
|
18
|
+
import ChevronLeftIcon from '../../icons/components/ChevronLeftIcon.js';
|
|
19
|
+
import ChevronRightIcon from '../../icons/components/ChevronRightIcon.js';
|
|
20
|
+
import ChevronSkipForwardIcon from '../../icons/components/ChevronSkipForwardIcon.js';
|
|
21
|
+
|
|
22
|
+
const INVALID_INTEGER_INPUT_CHARS = ['-', '+', 'e', '.'];
|
|
23
|
+
const coalesceIntegerToRange = (value, min, max) => Math.min(Math.max(Math.round(value), min), max);
|
|
24
|
+
const GrowingIntegerInput = _ref => {
|
|
25
|
+
let {
|
|
26
|
+
value,
|
|
27
|
+
onChangeInput,
|
|
28
|
+
max,
|
|
29
|
+
min,
|
|
30
|
+
...rest
|
|
31
|
+
} = _ref;
|
|
32
|
+
const [width, setWidth] = useState(0);
|
|
33
|
+
const [internalValue, setInternalValue] = useState(value);
|
|
34
|
+
const [previousExternalValue, setPreviousExternalValue] = useState(value);
|
|
35
|
+
const span = useRef(null);
|
|
36
|
+
if (value !== previousExternalValue) {
|
|
37
|
+
setPreviousExternalValue(value);
|
|
38
|
+
setInternalValue(value);
|
|
39
|
+
}
|
|
40
|
+
useSSRLayoutEffect(() => {
|
|
41
|
+
var _span$current$offsetW, _span$current;
|
|
42
|
+
setWidth((_span$current$offsetW = (_span$current = span.current) === null || _span$current === void 0 ? void 0 : _span$current.offsetWidth) !== null && _span$current$offsetW !== void 0 ? _span$current$offsetW : 0);
|
|
43
|
+
}, [internalValue]);
|
|
44
|
+
const triggerInternalChange = e => {
|
|
45
|
+
setInternalValue(coalesceIntegerToRange(Number(e.target.value), Number.MIN_SAFE_INTEGER, Number.MAX_SAFE_INTEGER));
|
|
46
|
+
};
|
|
47
|
+
const triggerExternalChange = e => {
|
|
48
|
+
const maxNumber = Number(max) || Number.MAX_SAFE_INTEGER;
|
|
49
|
+
const minNumber = Number(min) || Number.MIN_SAFE_INTEGER;
|
|
50
|
+
const newValue = coalesceIntegerToRange(Number(e.target.value), minNumber, maxNumber);
|
|
51
|
+
setInternalValue(newValue);
|
|
52
|
+
onChangeInput(newValue);
|
|
53
|
+
};
|
|
54
|
+
const onKeyDownHandler = e => {
|
|
55
|
+
if (e.key === 'Enter') {
|
|
56
|
+
triggerExternalChange(e);
|
|
57
|
+
} else if (INVALID_INTEGER_INPUT_CHARS.includes(e.key)) {
|
|
58
|
+
e.preventDefault();
|
|
59
|
+
}
|
|
60
|
+
};
|
|
61
|
+
const displayValue = internalValue.toString();
|
|
62
|
+
return /*#__PURE__*/React__default.createElement("span", {
|
|
63
|
+
className: growingInput
|
|
64
|
+
}, /*#__PURE__*/React__default.createElement("span", {
|
|
65
|
+
className: hidden,
|
|
66
|
+
ref: span
|
|
67
|
+
}, displayValue), /*#__PURE__*/React__default.createElement(Input, _extends({
|
|
68
|
+
type: "number",
|
|
69
|
+
value: displayValue,
|
|
70
|
+
style: {
|
|
71
|
+
width,
|
|
72
|
+
minWidth: 1
|
|
73
|
+
},
|
|
74
|
+
onChange: triggerInternalChange,
|
|
75
|
+
onKeyDown: onKeyDownHandler,
|
|
76
|
+
onBlur: triggerExternalChange
|
|
77
|
+
}, rest)));
|
|
78
|
+
};
|
|
79
|
+
const PageInput = _ref2 => {
|
|
80
|
+
let {
|
|
81
|
+
numPages,
|
|
82
|
+
currentPage,
|
|
83
|
+
onChange,
|
|
84
|
+
'aria-label': ariaLabel,
|
|
85
|
+
disabled,
|
|
86
|
+
'data-testid': dataTestId
|
|
87
|
+
} = _ref2;
|
|
88
|
+
const delegatedInput = /*#__PURE__*/React__default.createElement(GrowingIntegerInput, {
|
|
89
|
+
max: numPages !== null && numPages !== void 0 ? numPages : undefined,
|
|
90
|
+
min: 1,
|
|
91
|
+
disabled: disabled,
|
|
92
|
+
key: "currentPage",
|
|
93
|
+
value: currentPage,
|
|
94
|
+
"aria-label": ariaLabel,
|
|
95
|
+
onChangeInput: onChange,
|
|
96
|
+
"data-testid": getSubDataTestId(dataTestId, 'input')
|
|
97
|
+
});
|
|
98
|
+
return /*#__PURE__*/React__default.createElement("div", {
|
|
99
|
+
className: pageNumber
|
|
100
|
+
}, numPages ? /*#__PURE__*/React__default.createElement(Translate, {
|
|
101
|
+
messageKey: "pagination",
|
|
102
|
+
placeholders: {
|
|
103
|
+
currentPage: delegatedInput,
|
|
104
|
+
numPages
|
|
105
|
+
}
|
|
106
|
+
}) : delegatedInput);
|
|
107
|
+
};
|
|
108
|
+
const Pagination = _ref3 => {
|
|
109
|
+
let {
|
|
110
|
+
hidePageNumber = false,
|
|
111
|
+
hideFirstAndLastButtons = false,
|
|
112
|
+
numPages,
|
|
113
|
+
currentPage,
|
|
114
|
+
onPageChange,
|
|
115
|
+
isDisabled = false,
|
|
116
|
+
'data-testid': dataTestId
|
|
117
|
+
} = _ref3;
|
|
118
|
+
const {
|
|
119
|
+
translate
|
|
120
|
+
} = useTranslation();
|
|
121
|
+
const announceToScreenReader = useScreenReaderAnnouncement('polite');
|
|
122
|
+
useDidUpdate(() => {
|
|
123
|
+
let messageKey = 'currentPageNumber';
|
|
124
|
+
const placeholders = {
|
|
125
|
+
currentPage
|
|
126
|
+
};
|
|
127
|
+
if (numPages) {
|
|
128
|
+
messageKey = 'currentPageNumberOf';
|
|
129
|
+
placeholders.numPages = numPages;
|
|
130
|
+
}
|
|
131
|
+
announceToScreenReader(translate(messageKey, placeholders));
|
|
132
|
+
}, [announceToScreenReader, translate, currentPage, numPages]);
|
|
133
|
+
return /*#__PURE__*/React__default.createElement("div", {
|
|
134
|
+
className: pagination,
|
|
135
|
+
"data-testid": dataTestId
|
|
136
|
+
}, !hideFirstAndLastButtons && numPages && /*#__PURE__*/React__default.createElement(IconButton, {
|
|
137
|
+
"aria-label": translate('firstPage'),
|
|
138
|
+
onClick: () => onPageChange(1),
|
|
139
|
+
disabled: isDisabled || currentPage <= 1,
|
|
140
|
+
"data-testid": getSubDataTestId(dataTestId, 'first-page')
|
|
141
|
+
}, /*#__PURE__*/React__default.createElement(ChevronSkipBackIcon, null)), /*#__PURE__*/React__default.createElement(IconButton, {
|
|
142
|
+
"aria-label": translate('previousPage'),
|
|
143
|
+
disabled: isDisabled || currentPage <= 1,
|
|
144
|
+
onClick: () => onPageChange(currentPage - 1),
|
|
145
|
+
"data-testid": getSubDataTestId(dataTestId, 'previous-page')
|
|
146
|
+
}, /*#__PURE__*/React__default.createElement(ChevronLeftIcon, null)), !hidePageNumber && /*#__PURE__*/React__default.createElement(PageInput, {
|
|
147
|
+
"aria-label": translate('currentPage'),
|
|
148
|
+
currentPage: currentPage,
|
|
149
|
+
numPages: numPages,
|
|
150
|
+
onChange: onPageChange,
|
|
151
|
+
disabled: isDisabled || numPages === 1,
|
|
152
|
+
"data-testid": getSubDataTestId(dataTestId, 'current-page')
|
|
153
|
+
}), /*#__PURE__*/React__default.createElement(IconButton, {
|
|
154
|
+
"aria-label": translate('nextPage'),
|
|
155
|
+
disabled: isDisabled || numPages !== undefined && currentPage >= numPages,
|
|
156
|
+
onClick: () => onPageChange(currentPage + 1),
|
|
157
|
+
"data-testid": getSubDataTestId(dataTestId, 'next-page')
|
|
158
|
+
}, /*#__PURE__*/React__default.createElement(ChevronRightIcon, null)), !hideFirstAndLastButtons && numPages && /*#__PURE__*/React__default.createElement(IconButton, {
|
|
159
|
+
"aria-label": translate('lastPage'),
|
|
160
|
+
disabled: isDisabled || currentPage >= numPages,
|
|
161
|
+
onClick: () => onPageChange(numPages),
|
|
162
|
+
"data-testid": getSubDataTestId(dataTestId, 'last-page')
|
|
163
|
+
}, /*#__PURE__*/React__default.createElement(ChevronSkipForwardIcon, null)));
|
|
164
|
+
};
|
|
165
|
+
|
|
166
|
+
export { Pagination as default };
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import React__default from 'react';
|
|
2
|
+
import '../Select/index.js';
|
|
3
|
+
import '../../utils/index.js';
|
|
4
|
+
import { rowCount } from './Pagination.css.js';
|
|
5
|
+
import Select from '../Select/Select.js';
|
|
6
|
+
import getSubDataTestId from '../../utils/getSubDataTestId/getSubDataTestId.js';
|
|
7
|
+
import SelectButton from '../Select/SelectButton.js';
|
|
8
|
+
import SelectPane from '../Select/SelectPane.js';
|
|
9
|
+
import SelectItem from '../Select/SelectItem.js';
|
|
10
|
+
import Translate from '../../utils/Translation/Translate.js';
|
|
11
|
+
|
|
12
|
+
const RowDisplayCount = _ref => {
|
|
13
|
+
let {
|
|
14
|
+
'data-testid': dataTestId,
|
|
15
|
+
displayCount,
|
|
16
|
+
displayCountOptions,
|
|
17
|
+
onDisplayCountChange,
|
|
18
|
+
isDisabled = false
|
|
19
|
+
} = _ref;
|
|
20
|
+
const displayCountSelect = /*#__PURE__*/React__default.createElement(Select, {
|
|
21
|
+
"data-testid": getSubDataTestId(dataTestId, 'select'),
|
|
22
|
+
isDisabled: isDisabled,
|
|
23
|
+
value: displayCount,
|
|
24
|
+
onChange: onDisplayCountChange,
|
|
25
|
+
key: "displayCountSelect"
|
|
26
|
+
}, /*#__PURE__*/React__default.createElement(SelectButton, null), /*#__PURE__*/React__default.createElement(SelectPane, {
|
|
27
|
+
style: {
|
|
28
|
+
minWidth: 'var(--radix-dropdown-menu-trigger-width)'
|
|
29
|
+
}
|
|
30
|
+
}, displayCountOptions === null || displayCountOptions === void 0 ? void 0 : displayCountOptions.map(option => /*#__PURE__*/React__default.createElement(SelectItem, {
|
|
31
|
+
value: option,
|
|
32
|
+
label: "".concat(option),
|
|
33
|
+
key: option
|
|
34
|
+
}))));
|
|
35
|
+
return /*#__PURE__*/React__default.createElement("div", {
|
|
36
|
+
className: rowCount,
|
|
37
|
+
"data-testid": dataTestId
|
|
38
|
+
}, /*#__PURE__*/React__default.createElement(Translate, {
|
|
39
|
+
messageKey: "rowDisplayCount",
|
|
40
|
+
placeholders: {
|
|
41
|
+
select: displayCountSelect
|
|
42
|
+
}
|
|
43
|
+
}));
|
|
44
|
+
};
|
|
45
|
+
|
|
46
|
+
export { RowDisplayCount as default };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import styleInject from './../../__node_modules/style-inject/dist/style-inject.es.js';
|
|
2
2
|
|
|
3
|
-
var css_248z = ".
|
|
4
|
-
var styles = {"input":"
|
|
5
|
-
var stylesheet=".
|
|
3
|
+
var css_248z = "._ex4kH input{padding-left:76px!important}._XLcmY input{background-color:#e5e5e5!important;color:#9d9fa1!important;cursor:not-allowed!important;-webkit-text-fill-color:#9d9fa1}._XLcmY input::-moz-placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._XLcmY input::placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._CEWCL{position:absolute!important;left:4px;right:4px;bottom:4px;z-index:100;width:67px;height:28px!important;border-radius:4px}._CEWCL,._CEWCL._XLcmY:hover{background-color:transparent!important}._CEWCL:hover{background-color:rgba(50,54,58,.08)!important}._CEWCL:active{background-color:rgba(50,54,58,.11)!important}._CEWCL svg{top:2px!important}._e48CZ{position:relative}._Hpw0X{position:absolute;top:18px;left:12px;line-height:0;font-size:14px;color:#32363a;z-index:101;pointer-events:none}";
|
|
4
|
+
var styles = {"input":"_ex4kH","disabled":"_XLcmY","dropdown":"_CEWCL","container":"_e48CZ","countryCode":"_Hpw0X"};
|
|
5
|
+
var stylesheet="._ex4kH input{padding-left:76px!important}._XLcmY input{background-color:#e5e5e5!important;color:#9d9fa1!important;cursor:not-allowed!important;-webkit-text-fill-color:#9d9fa1}._XLcmY input::-moz-placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._XLcmY input::placeholder{color:#aaabad;-webkit-text-fill-color:#aaabad}._CEWCL{position:absolute!important;left:4px;right:4px;bottom:4px;z-index:100;width:67px;height:28px!important;border-radius:4px}._CEWCL,._CEWCL._XLcmY:hover{background-color:transparent!important}._CEWCL:hover{background-color:rgba(50,54,58,.08)!important}._CEWCL:active{background-color:rgba(50,54,58,.11)!important}._CEWCL svg{top:2px!important}._e48CZ{position:relative}._Hpw0X{position:absolute;top:18px;left:12px;line-height:0;font-size:14px;color:#32363a;z-index:101;pointer-events:none}";
|
|
6
6
|
if(typeof process !== 'object' || !process.hasOwnProperty('env') || process.env.NODE_ENV !== 'test'){styleInject(css_248z);}
|
|
7
7
|
|
|
8
8
|
export { styles as default, stylesheet };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import styleInject from './../../__node_modules/style-inject/dist/style-inject.es.js';
|
|
2
2
|
|
|
3
|
-
var css_248z = ".
|
|
4
|
-
var styles = {"isInvalid":"
|
|
5
|
-
var stylesheet=".
|
|
3
|
+
var css_248z = "._CJ6cu{box-shadow:inset 0 0 0 1px #b00!important}._ao75N{width:unset!important;min-height:unset!important;padding:0!important;margin-right:7px}._LF5DX{background-color:rgba(11,110,208,.08);font-weight:500}";
|
|
4
|
+
var styles = {"isInvalid":"_CJ6cu","checkbox":"_ao75N","selectedItem":"_LF5DX"};
|
|
5
|
+
var stylesheet="._CJ6cu{box-shadow:inset 0 0 0 1px #b00!important}._ao75N{width:unset!important;min-height:unset!important;padding:0!important;margin-right:7px}._LF5DX{background-color:rgba(11,110,208,.08);font-weight:500}";
|
|
6
6
|
if(typeof process !== 'object' || !process.hasOwnProperty('env') || process.env.NODE_ENV !== 'test'){styleInject(css_248z);}
|
|
7
7
|
|
|
8
8
|
export { styles as default, stylesheet };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import styleInject from './../../__node_modules/style-inject/dist/style-inject.es.js';
|
|
2
2
|
|
|
3
|
-
var css_248z = ".
|
|
4
|
-
var styles = {"container":"
|
|
5
|
-
var stylesheet=".
|
|
3
|
+
var css_248z = "._MyQMX{display:flex}._9-3-D{z-index:2;width:1px;margin-left:-1px;margin-right:-1px}._9-3-D._Y5ey6{background-color:#fff}._9-3-D._W6uBO,._9-3-D._Y5ey6._9EbiJ.focus-visible:not(._xu2tf),._9-3-D._Y5ey6._9EbiJ:focus-visible:not(._xu2tf),._9-3-D._Y5ey6._WZahD:not(._9-3-D._Y5ey6._iexVS){background-color:#0b6ed0}._9-3-D._W6uBO._iexVS._WZahD,._9-3-D._W6uBO._xu2tf._9EbiJ,._9-3-D._W6uBO._xu2tf._iexVS{opacity:.4}._HRQJK{border-radius:4px 0 0 4px;border-right:none;padding-right:17px}._HRQJK:focus{z-index:1}._jn-hg{border-radius:0 4px 4px 0;transition:border .2s,background .2s,color .2s;border-left:none;min-width:35px!important;padding:0!important;justify-content:center!important}._jn-hg svg{margin-left:1px}._jn-hg._Y5ey6{background-color:#0b6ed0;border-color:transparent}._jn-hg._Y5ey6 svg{fill:#fff!important}._jn-hg._Y5ey6:not(._mhzDX):hover{background-color:#085caf!important}._jn-hg._Y5ey6:not(._mhzDX):active{background-color:#0854a1!important}._jn-hg._Y5ey6._mhzDX{opacity:.4}._jn-hg._Y5ey6._mhzDX svg{background-color:transparent}._jn-hg._W6uBO{border-color:#0b6ed0;background-color:#fff}._jn-hg._W6uBO svg{fill:#0b6ed0!important}._jn-hg._W6uBO:not(._mhzDX):hover{background-color:#eef5fc!important}._jn-hg._W6uBO:not(._mhzDX):active{background-color:#e1edf9!important}._jn-hg._W6uBO._mhzDX{opacity:.4}._jn-hg._W6uBO._mhzDX svg{background-color:transparent}._YG-2t{width:260px}";
|
|
4
|
+
var styles = {"container":"_MyQMX","divider":"_9-3-D","primary":"_Y5ey6","mainButtonFocus":"_9EbiJ","mainButtonDisabled":"_xu2tf","dropdownButtonFocus":"_WZahD","dropdownButtonDisabled":"_iexVS","secondary":"_W6uBO","mainButton":"_HRQJK","dropdownButton":"_jn-hg","disabled":"_mhzDX","dropdownOption":"_YG-2t"};
|
|
5
|
+
var stylesheet="._MyQMX{display:flex}._9-3-D{z-index:2;width:1px;margin-left:-1px;margin-right:-1px}._9-3-D._Y5ey6{background-color:#fff}._9-3-D._W6uBO,._9-3-D._Y5ey6._9EbiJ.focus-visible:not(._xu2tf),._9-3-D._Y5ey6._9EbiJ:focus-visible:not(._xu2tf),._9-3-D._Y5ey6._WZahD:not(._9-3-D._Y5ey6._iexVS){background-color:#0b6ed0}._9-3-D._W6uBO._iexVS._WZahD,._9-3-D._W6uBO._xu2tf._9EbiJ,._9-3-D._W6uBO._xu2tf._iexVS{opacity:.4}._HRQJK{border-radius:4px 0 0 4px;border-right:none;padding-right:17px}._HRQJK:focus{z-index:1}._jn-hg{border-radius:0 4px 4px 0;transition:border .2s,background .2s,color .2s;border-left:none;min-width:35px!important;padding:0!important;justify-content:center!important}._jn-hg svg{margin-left:1px}._jn-hg._Y5ey6{background-color:#0b6ed0;border-color:transparent}._jn-hg._Y5ey6 svg{fill:#fff!important}._jn-hg._Y5ey6:not(._mhzDX):hover{background-color:#085caf!important}._jn-hg._Y5ey6:not(._mhzDX):active{background-color:#0854a1!important}._jn-hg._Y5ey6._mhzDX{opacity:.4}._jn-hg._Y5ey6._mhzDX svg{background-color:transparent}._jn-hg._W6uBO{border-color:#0b6ed0;background-color:#fff}._jn-hg._W6uBO svg{fill:#0b6ed0!important}._jn-hg._W6uBO:not(._mhzDX):hover{background-color:#eef5fc!important}._jn-hg._W6uBO:not(._mhzDX):active{background-color:#e1edf9!important}._jn-hg._W6uBO._mhzDX{opacity:.4}._jn-hg._W6uBO._mhzDX svg{background-color:transparent}._YG-2t{width:260px}";
|
|
6
6
|
if(typeof process !== 'object' || !process.hasOwnProperty('env') || process.env.NODE_ENV !== 'test'){styleInject(css_248z);}
|
|
7
7
|
|
|
8
8
|
export { styles as default, stylesheet };
|
|
@@ -25,8 +25,14 @@ const TimeDropdown = _ref => {
|
|
|
25
25
|
const [refsInitialized, setRefsInitialized] = useState(false);
|
|
26
26
|
useEffect(() => {
|
|
27
27
|
const nodes = scrollRef.current;
|
|
28
|
-
if (scrolledToItem
|
|
29
|
-
nodes[scrolledToItem.index]
|
|
28
|
+
if (scrolledToItem) {
|
|
29
|
+
const nodeToScrollTo = nodes[scrolledToItem.index];
|
|
30
|
+
if (nodeToScrollTo) {
|
|
31
|
+
const {
|
|
32
|
+
parentNode
|
|
33
|
+
} = nodeToScrollTo;
|
|
34
|
+
parentNode.scrollTop = nodeToScrollTo.offsetTop;
|
|
35
|
+
}
|
|
30
36
|
}
|
|
31
37
|
}, [scrolledToItem, refsInitialized]);
|
|
32
38
|
return /*#__PURE__*/React__default.createElement(Popper, {
|
|
@@ -44,7 +50,7 @@ const TimeDropdown = _ref => {
|
|
|
44
50
|
"aria-labelledby": ariaLabelledBy,
|
|
45
51
|
"aria-describedby": ariaDescribedBy,
|
|
46
52
|
"data-testid": dataTestId && "".concat(dataTestId, "-dropdown"),
|
|
47
|
-
className: styles.
|
|
53
|
+
className: styles.timePickerFlyout,
|
|
48
54
|
onMouseOver: () => setIsOptionHovered(true),
|
|
49
55
|
onMouseLeave: () => setIsOptionHovered(false)
|
|
50
56
|
}, items.map((item, index) => /*#__PURE__*/React__default.createElement(FlyoutOption, {
|
|
@@ -188,7 +188,7 @@ const TimePicker = /*#__PURE__*/React__default.forwardRef((_ref, ref) => {
|
|
|
188
188
|
};
|
|
189
189
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
190
190
|
id: timePickerId,
|
|
191
|
-
className: styles.
|
|
191
|
+
className: styles.timePickerContainer
|
|
192
192
|
}, /*#__PURE__*/React__default.createElement(TimeInput, {
|
|
193
193
|
id: inputId,
|
|
194
194
|
dataTestId: dataTestId,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import styleInject from './../../__node_modules/style-inject/dist/style-inject.es.js';
|
|
2
2
|
|
|
3
|
-
var css_248z = ".
|
|
4
|
-
var styles = {"
|
|
5
|
-
var stylesheet=".
|
|
3
|
+
var css_248z = "._M911N{display:inline-block;position:relative}._M911N ._n6-Um{width:120px}._M911N ._n6-Um ._CaEZh._Hwm-A{transform:rotate(-180deg)}._M911N ._n6-Um ._CaEZh._aop6-{fill:#9d9fa1;opacity:.4}._M911N ._bw1Xx>input:focus{box-shadow:none!important;border:1px solid #898989!important}._M911N ._CaEZh{position:absolute;right:4px;bottom:4px;height:28px;width:28px}._M911N ._CaEZh._Hwm-A{transform:rotate(-180deg)}._zpdVv{width:120px}._zpdVv ._p5dVy._oQwaO{background-color:#efefef;border-radius:6px}";
|
|
4
|
+
var styles = {"timePickerContainer":"_M911N","input":"_n6-Um","icon":"_CaEZh","open":"_Hwm-A","disabled":"_aop6-","ignoreFocusStyle":"_bw1Xx","timePickerFlyout":"_zpdVv","option":"_p5dVy","exactMatch":"_oQwaO"};
|
|
5
|
+
var stylesheet="._M911N{display:inline-block;position:relative}._M911N ._n6-Um{width:120px}._M911N ._n6-Um ._CaEZh._Hwm-A{transform:rotate(-180deg)}._M911N ._n6-Um ._CaEZh._aop6-{fill:#9d9fa1;opacity:.4}._M911N ._bw1Xx>input:focus{box-shadow:none!important;border:1px solid #898989!important}._M911N ._CaEZh{position:absolute;right:4px;bottom:4px;height:28px;width:28px}._M911N ._CaEZh._Hwm-A{transform:rotate(-180deg)}._zpdVv{width:120px}._zpdVv ._p5dVy._oQwaO{background-color:#efefef;border-radius:6px}";
|
|
6
6
|
if(typeof process !== 'object' || !process.hasOwnProperty('env') || process.env.NODE_ENV !== 'test'){styleInject(css_248z);}
|
|
7
7
|
|
|
8
8
|
export { styles as default, stylesheet };
|
|
@@ -11,10 +11,10 @@ import getSubDataTestId from '../../utils/getSubDataTestId/getSubDataTestId.js';
|
|
|
11
11
|
const ToggleButton = /*#__PURE__*/React__default.forwardRef((_ref, ref) => {
|
|
12
12
|
let {
|
|
13
13
|
children,
|
|
14
|
-
isActivated,
|
|
14
|
+
isActivated = false,
|
|
15
15
|
onChange,
|
|
16
16
|
value,
|
|
17
|
-
isDisabled,
|
|
17
|
+
isDisabled = false,
|
|
18
18
|
kind = 'icon-text',
|
|
19
19
|
'aria-label': ariaLabel,
|
|
20
20
|
'aria-labelledby': ariaLabelledby,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import styleInject from './../../__node_modules/style-inject/dist/style-inject.es.js';
|
|
2
2
|
|
|
3
|
-
var css_248z = ".
|
|
4
|
-
var styles = {"default":"
|
|
5
|
-
var stylesheet=".
|
|
3
|
+
var css_248z = "._I3Wby{border-color:transparent;background-color:transparent;color:#515559;cursor:pointer}._f5cIL{background-color:rgba(50,54,58,.08)}._QcHKu{color:#0b6ed0;background-color:rgba(11,110,208,.08)}._1Y5xs{color:rgba(81,85,89,.4);cursor:not-allowed}._5YR9F{background:rgba(11,110,208,.08);color:#0b6ed0;border-color:#0b6ed0}._bZvc2{color:#085caf;border-color:#085caf}._808KD,._bZvc2{background:rgba(11,110,208,.11)}._808KD{color:#0854a1;border-color:#0854a1}._zh73S{background:rgba(11,110,208,.032);color:rgba(11,110,208,.4);border-color:rgba(11,110,208,.4)}._wGU4f{position:relative;display:inline-grid}._wGU4f svg{fill:currentColor}._wGU4f ._9rTIm{-webkit-appearance:none;-moz-appearance:none;appearance:none;grid-column:1;grid-row:1}._wGU4f ._9rTIm+._B6PXc{background-color:transparent;color:#515559;cursor:pointer;border:1px solid transparent;border-radius:4px;grid-column:1;grid-row:1;padding:0;min-width:76px;-webkit-user-select:none;-moz-user-select:none;user-select:none}._wGU4f ._9rTIm+._B6PXc._6nXow{padding:5px;max-width:36px;min-width:36px}._wGU4f ._9rTIm+._B6PXc._znJ-v{padding:0 16px}._wGU4f ._9rTIm+._B6PXc._AZPJR{padding:0 16px 0 12px}._wGU4f ._9rTIm:hover+._B6PXc{background-color:rgba(50,54,58,.08)}._wGU4f ._9rTIm:disabled+._B6PXc{color:rgba(81,85,89,.4);cursor:not-allowed}._wGU4f ._9rTIm:active+._B6PXc,._wGU4f ._9rTIm:focus:active+._B6PXc{color:#0b6ed0;background-color:rgba(11,110,208,.08)}._wGU4f ._9rTIm:checked+._B6PXc{background:rgba(11,110,208,.08);color:#0b6ed0;border-color:#0b6ed0}._wGU4f ._9rTIm:checked:hover+._B6PXc{background:rgba(11,110,208,.11);color:#085caf;border-color:#085caf}._wGU4f ._9rTIm:checked:disabled+._B6PXc{background:rgba(11,110,208,.032);color:rgba(11,110,208,.4);border-color:rgba(11,110,208,.4)}._wGU4f ._9rTIm:checked:active+._B6PXc,._wGU4f ._9rTIm:checked:focus:active+._B6PXc{background:rgba(11,110,208,.11);color:#0854a1;border-color:#0854a1}._N4WjV{display:inline-flex;position:relative}._N4WjV:before{content:\"\";border:1px solid #d9d9d9;border-radius:4px;position:absolute;top:0;bottom:0;right:0;left:0}._N4WjV>*{flex-shrink:0;flex-grow:0}._e0yg8{border:none;margin:0;padding:0}._e0yg8 legend{padding:0;display:block;font-size:14px;margin-bottom:6px;color:#515559}._wGU4f ._9rTIm.focus-visible+._B6PXc,._wGU4f ._9rTIm:focus-visible+._B6PXc{z-index:20;outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
4
|
+
var styles = {"default":"_I3Wby","hovered":"_f5cIL","pressed":"_QcHKu","disabled":"_1Y5xs","selectedDefault":"_5YR9F","selectedHovered":"_bZvc2","selectedPressed":"_808KD","selectedDisabled":"_zh73S","toggleContainer":"_wGU4f","toggleInput":"_9rTIm","toggleButton":"_B6PXc","iconOnly":"_6nXow","text":"_znJ-v","iconText":"_AZPJR","toggleButtonGroup":"_N4WjV","toggleButtonGroupFieldset":"_e0yg8"};
|
|
5
|
+
var stylesheet="._I3Wby{border-color:transparent;background-color:transparent;color:#515559;cursor:pointer}._f5cIL{background-color:rgba(50,54,58,.08)}._QcHKu{color:#0b6ed0;background-color:rgba(11,110,208,.08)}._1Y5xs{color:rgba(81,85,89,.4);cursor:not-allowed}._5YR9F{background:rgba(11,110,208,.08);color:#0b6ed0;border-color:#0b6ed0}._bZvc2{color:#085caf;border-color:#085caf}._808KD,._bZvc2{background:rgba(11,110,208,.11)}._808KD{color:#0854a1;border-color:#0854a1}._zh73S{background:rgba(11,110,208,.032);color:rgba(11,110,208,.4);border-color:rgba(11,110,208,.4)}._wGU4f{position:relative;display:inline-grid}._wGU4f svg{fill:currentColor}._wGU4f ._9rTIm{-webkit-appearance:none;-moz-appearance:none;appearance:none;grid-column:1;grid-row:1}._wGU4f ._9rTIm+._B6PXc{background-color:transparent;color:#515559;cursor:pointer;border:1px solid transparent;border-radius:4px;grid-column:1;grid-row:1;padding:0;min-width:76px;-webkit-user-select:none;-moz-user-select:none;user-select:none}._wGU4f ._9rTIm+._B6PXc._6nXow{padding:5px;max-width:36px;min-width:36px}._wGU4f ._9rTIm+._B6PXc._znJ-v{padding:0 16px}._wGU4f ._9rTIm+._B6PXc._AZPJR{padding:0 16px 0 12px}._wGU4f ._9rTIm:hover+._B6PXc{background-color:rgba(50,54,58,.08)}._wGU4f ._9rTIm:disabled+._B6PXc{color:rgba(81,85,89,.4);cursor:not-allowed}._wGU4f ._9rTIm:active+._B6PXc,._wGU4f ._9rTIm:focus:active+._B6PXc{color:#0b6ed0;background-color:rgba(11,110,208,.08)}._wGU4f ._9rTIm:checked+._B6PXc{background:rgba(11,110,208,.08);color:#0b6ed0;border-color:#0b6ed0}._wGU4f ._9rTIm:checked:hover+._B6PXc{background:rgba(11,110,208,.11);color:#085caf;border-color:#085caf}._wGU4f ._9rTIm:checked:disabled+._B6PXc{background:rgba(11,110,208,.032);color:rgba(11,110,208,.4);border-color:rgba(11,110,208,.4)}._wGU4f ._9rTIm:checked:active+._B6PXc,._wGU4f ._9rTIm:checked:focus:active+._B6PXc{background:rgba(11,110,208,.11);color:#0854a1;border-color:#0854a1}._N4WjV{display:inline-flex;position:relative}._N4WjV:before{content:\"\";border:1px solid #d9d9d9;border-radius:4px;position:absolute;top:0;bottom:0;right:0;left:0}._N4WjV>*{flex-shrink:0;flex-grow:0}._e0yg8{border:none;margin:0;padding:0}._e0yg8 legend{padding:0;display:block;font-size:14px;margin-bottom:6px;color:#515559}._wGU4f ._9rTIm.focus-visible+._B6PXc,._wGU4f ._9rTIm:focus-visible+._B6PXc{z-index:20;outline:none;box-shadow:0 0 0 2px #fff,0 0 0 4px #0a3f88}";
|
|
6
6
|
if(typeof process !== 'object' || !process.hasOwnProperty('env') || process.env.NODE_ENV !== 'test'){styleInject(css_248z);}
|
|
7
7
|
|
|
8
8
|
export { styles as default, stylesheet };
|