@doist/reactist 10.0.0-beta.8 → 11.1.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/dist/reactist.cjs.development.js +546 -692
- package/dist/reactist.cjs.development.js.map +1 -1
- package/dist/reactist.cjs.production.min.js +1 -1
- package/dist/reactist.cjs.production.min.js.map +1 -1
- package/es/_virtual/_rollupPluginBabelHelpers.js +34 -20
- package/es/_virtual/_rollupPluginBabelHelpers.js.map +1 -1
- package/es/components/deprecated-button/deprecated-button.js +2 -1
- package/es/components/deprecated-button/deprecated-button.js.map +1 -1
- package/es/components/deprecated-modal/deprecated-modal.js +1 -1
- package/es/components/deprecated-modal/deprecated-modal.js.map +1 -1
- package/es/components/dropdown/dropdown.js +3 -1
- package/es/components/dropdown/dropdown.js.map +1 -1
- package/es/components/key-capturer/key-capturer.js.map +1 -1
- package/es/components/keyboard-shortcut/keyboard-shortcut.js +2 -1
- package/es/components/keyboard-shortcut/keyboard-shortcut.js.map +1 -1
- package/es/components/menu/menu.js +34 -13
- package/es/components/menu/menu.js.map +1 -1
- package/es/components/notification/notification.js +8 -3
- package/es/components/notification/notification.js.map +1 -1
- package/es/components/popover/popover.js.map +1 -1
- package/es/components/popover/positioning-utils.js.map +1 -1
- package/es/components/progress-bar/progress-bar.js +8 -2
- package/es/components/progress-bar/progress-bar.js.map +1 -1
- package/es/components/select/select.js +3 -1
- package/es/components/select/select.js.map +1 -1
- package/es/components/time/time-utils.js.map +1 -1
- package/es/components/time/time.js.map +1 -1
- package/es/components/tooltip/tooltip.js +3 -1
- package/es/components/tooltip/tooltip.js.map +1 -1
- package/es/index.js +3 -7
- package/es/index.js.map +1 -1
- package/es/new-components/alert/alert.js +16 -6
- package/es/new-components/alert/alert.js.map +1 -1
- package/es/new-components/alert/alert.module.css.js +1 -1
- package/es/{components → new-components}/avatar/avatar.js +14 -8
- package/es/new-components/avatar/avatar.js.map +1 -0
- package/es/new-components/avatar/avatar.module.css.js +4 -0
- package/es/new-components/avatar/avatar.module.css.js.map +1 -0
- package/es/{components → new-components}/avatar/utils.js +0 -0
- package/es/new-components/avatar/utils.js.map +1 -0
- package/es/new-components/base-button/base-button.js +4 -2
- package/es/new-components/base-button/base-button.js.map +1 -1
- package/es/new-components/box/box.js +5 -3
- package/es/new-components/box/box.js.map +1 -1
- package/es/new-components/box/box.module.css.js +1 -1
- package/es/new-components/box/width.module.css.js +4 -0
- package/es/new-components/box/width.module.css.js.map +1 -0
- package/es/new-components/button/button.js +2 -1
- package/es/new-components/button/button.js.map +1 -1
- package/es/new-components/button-link/button-link.js +2 -1
- package/es/new-components/button-link/button-link.js.map +1 -1
- package/es/new-components/checkbox-field/checkbox-field.js +27 -10
- package/es/new-components/checkbox-field/checkbox-field.js.map +1 -1
- package/es/new-components/checkbox-field/checkbox-field.module.css.js +1 -1
- package/es/new-components/checkbox-field/checkbox-icon.js +2 -1
- package/es/new-components/checkbox-field/checkbox-icon.js.map +1 -1
- package/es/new-components/columns/columns.js +4 -2
- package/es/new-components/columns/columns.js.map +1 -1
- package/es/new-components/divider/divider.js +4 -2
- package/es/new-components/divider/divider.js.map +1 -1
- package/es/new-components/heading/heading.js +2 -1
- package/es/new-components/heading/heading.js.map +1 -1
- package/es/new-components/heading/heading.module.css.js +1 -1
- package/es/new-components/hidden/hidden.js +2 -1
- package/es/new-components/hidden/hidden.js.map +1 -1
- package/es/new-components/icons/alert-icon.js +2 -1
- package/es/new-components/icons/alert-icon.js.map +1 -1
- package/es/new-components/inline/inline.js +4 -3
- package/es/new-components/inline/inline.js.map +1 -1
- package/es/new-components/loading/loading.js +6 -2
- package/es/new-components/loading/loading.js.map +1 -1
- package/es/new-components/modal/modal.js +35 -17
- package/es/new-components/modal/modal.js.map +1 -1
- package/es/new-components/modal/modal.module.css.js +1 -1
- package/es/new-components/notice/notice.js +3 -1
- package/es/new-components/notice/notice.js.map +1 -1
- package/es/new-components/password-field/password-field.js +2 -1
- package/es/new-components/password-field/password-field.js.map +1 -1
- package/es/new-components/select-field/select-field.js +2 -1
- package/es/new-components/select-field/select-field.js.map +1 -1
- package/es/new-components/stack/stack.js +2 -1
- package/es/new-components/stack/stack.js.map +1 -1
- package/es/new-components/switch-field/switch-field.js +28 -5
- package/es/new-components/switch-field/switch-field.js.map +1 -1
- package/es/new-components/switch-field/switch-field.module.css.js +1 -1
- package/es/new-components/tabs/tabs.js +10 -5
- package/es/new-components/tabs/tabs.js.map +1 -1
- package/es/new-components/tabs/tabs.module.css.js +1 -1
- package/es/new-components/text/text.js +2 -1
- package/es/new-components/text/text.js.map +1 -1
- package/es/new-components/text/text.module.css.js +1 -1
- package/es/new-components/text-area/text-area.js +3 -1
- package/es/new-components/text-area/text-area.js.map +1 -1
- package/es/new-components/text-field/text-field.js +2 -1
- package/es/new-components/text-field/text-field.js.map +1 -1
- package/es/new-components/text-link/text-link.js +2 -1
- package/es/new-components/text-link/text-link.js.map +1 -1
- package/es/new-components/text-link/text-link.module.css.js +1 -1
- package/lib/_virtual/_rollupPluginBabelHelpers.js +1 -1
- package/lib/components/deprecated-button/deprecated-button.js +1 -1
- package/lib/components/deprecated-button/deprecated-button.js.map +1 -1
- package/lib/components/deprecated-modal/deprecated-modal.js +1 -1
- package/lib/components/deprecated-modal/deprecated-modal.js.map +1 -1
- package/lib/components/dropdown/dropdown.js +1 -1
- package/lib/components/dropdown/dropdown.js.map +1 -1
- package/lib/components/keyboard-shortcut/keyboard-shortcut.js +1 -1
- package/lib/components/keyboard-shortcut/keyboard-shortcut.js.map +1 -1
- package/lib/components/menu/menu.js +1 -1
- package/lib/components/menu/menu.js.map +1 -1
- package/lib/components/notification/notification.d.ts +4 -2
- package/lib/components/notification/notification.js +1 -1
- package/lib/components/notification/notification.js.map +1 -1
- package/lib/components/progress-bar/progress-bar.d.ts +3 -1
- package/lib/components/progress-bar/progress-bar.js +1 -1
- package/lib/components/progress-bar/progress-bar.js.map +1 -1
- package/lib/components/select/select.js +1 -1
- package/lib/components/select/select.js.map +1 -1
- package/lib/components/tooltip/tooltip.js +1 -1
- package/lib/components/tooltip/tooltip.js.map +1 -1
- package/lib/index.d.ts +1 -5
- package/lib/index.js +1 -1
- package/lib/new-components/alert/alert.js +1 -1
- package/lib/new-components/alert/alert.js.map +1 -1
- package/lib/new-components/alert/alert.module.css.js +1 -1
- package/lib/{components/avatar/avatar.test.d.ts → new-components/alert/alert.test.d.ts} +0 -0
- package/lib/{components → new-components}/avatar/avatar.d.ts +6 -3
- package/lib/new-components/avatar/avatar.js +2 -0
- package/lib/new-components/avatar/avatar.js.map +1 -0
- package/lib/new-components/avatar/avatar.module.css.js +2 -0
- package/lib/new-components/avatar/avatar.module.css.js.map +1 -0
- package/lib/{components/avatar/utils.test.d.ts → new-components/avatar/avatar.test.d.ts} +0 -0
- package/lib/new-components/avatar/index.d.ts +1 -0
- package/lib/{components → new-components}/avatar/utils.d.ts +0 -0
- package/lib/{components → new-components}/avatar/utils.js +0 -0
- package/lib/new-components/avatar/utils.js.map +1 -0
- package/lib/{components/error-message/error-message.test.d.ts → new-components/avatar/utils.test.d.ts} +0 -0
- package/lib/new-components/base-button/base-button.js +1 -1
- package/lib/new-components/base-button/base-button.js.map +1 -1
- package/lib/new-components/box/box.d.ts +8 -7
- package/lib/new-components/box/box.js +1 -1
- package/lib/new-components/box/box.js.map +1 -1
- package/lib/new-components/box/box.module.css.js +1 -1
- package/lib/new-components/box/width.module.css.js +2 -0
- package/lib/new-components/box/width.module.css.js.map +1 -0
- package/lib/new-components/button/button.js +1 -1
- package/lib/new-components/button/button.js.map +1 -1
- package/lib/new-components/button-link/button-link.js +1 -1
- package/lib/new-components/button-link/button-link.js.map +1 -1
- package/lib/new-components/checkbox-field/checkbox-field.d.ts +15 -2
- package/lib/new-components/checkbox-field/checkbox-field.js +1 -1
- package/lib/new-components/checkbox-field/checkbox-field.js.map +1 -1
- package/lib/new-components/checkbox-field/checkbox-field.module.css.js +1 -1
- package/lib/new-components/checkbox-field/checkbox-icon.js +1 -1
- package/lib/new-components/checkbox-field/checkbox-icon.js.map +1 -1
- package/lib/new-components/columns/columns.js +1 -1
- package/lib/new-components/columns/columns.js.map +1 -1
- package/lib/new-components/divider/divider.js +1 -1
- package/lib/new-components/divider/divider.js.map +1 -1
- package/lib/new-components/heading/heading.js +1 -1
- package/lib/new-components/heading/heading.js.map +1 -1
- package/lib/new-components/heading/heading.module.css.js +1 -1
- package/lib/new-components/hidden/hidden.js +1 -1
- package/lib/new-components/hidden/hidden.js.map +1 -1
- package/lib/new-components/icons/alert-icon.js +1 -1
- package/lib/new-components/icons/alert-icon.js.map +1 -1
- package/lib/new-components/inline/inline.js +1 -1
- package/lib/new-components/inline/inline.js.map +1 -1
- package/lib/new-components/loading/loading.d.ts +8 -7
- package/lib/new-components/loading/loading.js +1 -1
- package/lib/new-components/loading/loading.js.map +1 -1
- package/lib/new-components/modal/modal.d.ts +9 -4
- package/lib/new-components/modal/modal.js +1 -1
- package/lib/new-components/modal/modal.js.map +1 -1
- package/lib/new-components/modal/modal.module.css.js +1 -1
- package/lib/new-components/notice/notice.js +1 -1
- package/lib/new-components/notice/notice.js.map +1 -1
- package/lib/{components/icon/icon.test.d.ts → new-components/notice/notice.test.d.ts} +0 -0
- package/lib/new-components/password-field/password-field.js +1 -1
- package/lib/new-components/password-field/password-field.js.map +1 -1
- package/lib/new-components/select-field/select-field.js +1 -1
- package/lib/new-components/select-field/select-field.js.map +1 -1
- package/lib/new-components/stack/stack.js +1 -1
- package/lib/new-components/stack/stack.js.map +1 -1
- package/lib/new-components/switch-field/switch-field.d.ts +9 -2
- package/lib/new-components/switch-field/switch-field.js +1 -1
- package/lib/new-components/switch-field/switch-field.js.map +1 -1
- package/lib/new-components/switch-field/switch-field.module.css.js +1 -1
- package/lib/new-components/tabs/tabs.js +1 -1
- package/lib/new-components/tabs/tabs.js.map +1 -1
- package/lib/new-components/tabs/tabs.module.css.js +1 -1
- package/lib/new-components/text/text.js +1 -1
- package/lib/new-components/text/text.js.map +1 -1
- package/lib/new-components/text/text.module.css.js +1 -1
- package/lib/new-components/text-area/text-area.js +1 -1
- package/lib/new-components/text-area/text-area.js.map +1 -1
- package/lib/new-components/text-field/text-field.js +1 -1
- package/lib/new-components/text-field/text-field.js.map +1 -1
- package/lib/new-components/text-link/text-link.js +1 -1
- package/lib/new-components/text-link/text-link.js.map +1 -1
- package/lib/new-components/text-link/text-link.module.css.js +1 -1
- package/package.json +15 -12
- package/styles/alert.css +6 -2
- package/styles/alert.module.css.css +1 -1
- package/styles/avatar.css +5 -1
- package/styles/avatar.module.css.css +1 -0
- package/styles/base-button.css +3 -2
- package/styles/base-field.css +3 -2
- package/styles/box.css +3 -2
- package/styles/box.module.css.css +1 -1
- package/styles/checkbox-field.css +4 -4
- package/styles/checkbox-field.module.css.css +1 -1
- package/styles/color-picker.css +1 -1
- package/styles/columns.css +2 -1
- package/styles/deprecated-button.css +1 -1
- package/styles/deprecated-loading.css +1 -1
- package/styles/deprecated-modal.css +1 -1
- package/styles/divider.css +2 -1
- package/styles/dropdown.css +1 -1
- package/styles/heading.css +3 -2
- package/styles/heading.module.css.css +1 -1
- package/styles/hidden-visually.css +2 -1
- package/styles/hidden.css +2 -1
- package/styles/inline.css +2 -1
- package/styles/loading.css +3 -2
- package/styles/menu.css +1 -1
- package/styles/modal.css +4 -3
- package/styles/modal.module.css.css +1 -1
- package/styles/notice.css +2 -1
- package/styles/password-field.css +3 -2
- package/styles/progress-bar.css +5 -0
- package/styles/reactist.css +17 -20
- package/styles/select-field.css +3 -2
- package/styles/spinner.module.css.css +1 -1
- package/styles/stack.css +2 -1
- package/styles/switch-field.css +4 -3
- package/styles/switch-field.module.css.css +1 -1
- package/styles/tabs.css +3 -2
- package/styles/tabs.module.css.css +1 -1
- package/styles/text-area.css +3 -2
- package/styles/text-field.css +3 -2
- package/styles/text-link.css +3 -2
- package/styles/text-link.module.css.css +1 -1
- package/styles/text.css +3 -2
- package/styles/text.module.css.css +1 -1
- package/styles/width.module.css.css +1 -0
- package/es/components/avatar/avatar.js.map +0 -1
- package/es/components/avatar/index.js +0 -6
- package/es/components/avatar/index.js.map +0 -1
- package/es/components/avatar/utils.js.map +0 -1
- package/es/components/error-message/error-message.js +0 -90
- package/es/components/error-message/error-message.js.map +0 -1
- package/es/components/error-message/index.js +0 -6
- package/es/components/error-message/index.js.map +0 -1
- package/es/components/icon/icon.js +0 -96
- package/es/components/icon/icon.js.map +0 -1
- package/es/components/icon/index.js +0 -6
- package/es/components/icon/index.js.map +0 -1
- package/es/components/icons/ThinQuestionMarkIcon.svg.js +0 -24
- package/es/components/icons/ThinQuestionMarkIcon.svg.js.map +0 -1
- package/es/components/icons/ThreeDotsIcon.svg.js +0 -40
- package/es/components/icons/ThreeDotsIcon.svg.js.map +0 -1
- package/es/components/range-input/index.js +0 -6
- package/es/components/range-input/index.js.map +0 -1
- package/es/components/range-input/range-input.js +0 -55
- package/es/components/range-input/range-input.js.map +0 -1
- package/es/components/tip/index.js +0 -6
- package/es/components/tip/index.js.map +0 -1
- package/es/components/tip/tip.js +0 -30
- package/es/components/tip/tip.js.map +0 -1
- package/lib/components/avatar/avatar.js +0 -2
- package/lib/components/avatar/avatar.js.map +0 -1
- package/lib/components/avatar/index.d.ts +0 -2
- package/lib/components/avatar/index.js +0 -2
- package/lib/components/avatar/index.js.map +0 -1
- package/lib/components/avatar/utils.js.map +0 -1
- package/lib/components/error-message/error-message.d.ts +0 -23
- package/lib/components/error-message/error-message.js +0 -2
- package/lib/components/error-message/error-message.js.map +0 -1
- package/lib/components/error-message/index.d.ts +0 -2
- package/lib/components/error-message/index.js +0 -2
- package/lib/components/error-message/index.js.map +0 -1
- package/lib/components/icon/icon.d.ts +0 -31
- package/lib/components/icon/icon.js +0 -2
- package/lib/components/icon/icon.js.map +0 -1
- package/lib/components/icon/index.d.ts +0 -2
- package/lib/components/icon/index.js +0 -2
- package/lib/components/icon/index.js.map +0 -1
- package/lib/components/icons/ThinQuestionMarkIcon.svg.js +0 -2
- package/lib/components/icons/ThinQuestionMarkIcon.svg.js.map +0 -1
- package/lib/components/icons/ThreeDotsIcon.svg.js +0 -2
- package/lib/components/icons/ThreeDotsIcon.svg.js.map +0 -1
- package/lib/components/range-input/index.d.ts +0 -2
- package/lib/components/range-input/index.js +0 -2
- package/lib/components/range-input/index.js.map +0 -1
- package/lib/components/range-input/range-input.d.ts +0 -25
- package/lib/components/range-input/range-input.js +0 -2
- package/lib/components/range-input/range-input.js.map +0 -1
- package/lib/components/range-input/range-input.test.d.ts +0 -1
- package/lib/components/tip/index.d.ts +0 -2
- package/lib/components/tip/index.js +0 -2
- package/lib/components/tip/index.js.map +0 -1
- package/lib/components/tip/tip.d.ts +0 -20
- package/lib/components/tip/tip.js +0 -2
- package/lib/components/tip/tip.js.map +0 -1
- package/lib/components/tip/tip.test.d.ts +0 -1
- package/styles/error-message.css +0 -1
- package/styles/icon.css +0 -2
- package/styles/range-input.css +0 -1
- package/styles/tip.css +0 -4
|
@@ -14,35 +14,23 @@ var Tab$1 = require('reakit/Tab');
|
|
|
14
14
|
var dialog = require('@reach/dialog');
|
|
15
15
|
var FocusLock = _interopDefault(require('react-focus-lock'));
|
|
16
16
|
var ReactDOM = _interopDefault(require('react-dom'));
|
|
17
|
-
var PropTypes = _interopDefault(require('prop-types'));
|
|
18
17
|
var dayjs = _interopDefault(require('dayjs'));
|
|
19
18
|
var LocalizedFormat = _interopDefault(require('dayjs/plugin/localizedFormat'));
|
|
20
19
|
var Reakit = require('reakit/Menu');
|
|
21
20
|
var Popover$1 = require('reakit/Popover');
|
|
22
21
|
|
|
23
|
-
function _defineProperty(obj, key, value) {
|
|
24
|
-
if (key in obj) {
|
|
25
|
-
Object.defineProperty(obj, key, {
|
|
26
|
-
value: value,
|
|
27
|
-
enumerable: true,
|
|
28
|
-
configurable: true,
|
|
29
|
-
writable: true
|
|
30
|
-
});
|
|
31
|
-
} else {
|
|
32
|
-
obj[key] = value;
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
return obj;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
22
|
function ownKeys(object, enumerableOnly) {
|
|
39
23
|
var keys = Object.keys(object);
|
|
40
24
|
|
|
41
25
|
if (Object.getOwnPropertySymbols) {
|
|
42
26
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
27
|
+
|
|
28
|
+
if (enumerableOnly) {
|
|
29
|
+
symbols = symbols.filter(function (sym) {
|
|
30
|
+
return Object.getOwnPropertyDescriptor(object, sym).enumerable;
|
|
31
|
+
});
|
|
32
|
+
}
|
|
33
|
+
|
|
46
34
|
keys.push.apply(keys, symbols);
|
|
47
35
|
}
|
|
48
36
|
|
|
@@ -69,10 +57,35 @@ function _objectSpread2(target) {
|
|
|
69
57
|
return target;
|
|
70
58
|
}
|
|
71
59
|
|
|
60
|
+
function _defineProperty(obj, key, value) {
|
|
61
|
+
if (key in obj) {
|
|
62
|
+
Object.defineProperty(obj, key, {
|
|
63
|
+
value: value,
|
|
64
|
+
enumerable: true,
|
|
65
|
+
configurable: true,
|
|
66
|
+
writable: true
|
|
67
|
+
});
|
|
68
|
+
} else {
|
|
69
|
+
obj[key] = value;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
return obj;
|
|
73
|
+
}
|
|
74
|
+
|
|
72
75
|
function _inheritsLoose(subClass, superClass) {
|
|
73
76
|
subClass.prototype = Object.create(superClass.prototype);
|
|
74
77
|
subClass.prototype.constructor = subClass;
|
|
75
|
-
|
|
78
|
+
|
|
79
|
+
_setPrototypeOf(subClass, superClass);
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
function _setPrototypeOf(o, p) {
|
|
83
|
+
_setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {
|
|
84
|
+
o.__proto__ = p;
|
|
85
|
+
return o;
|
|
86
|
+
};
|
|
87
|
+
|
|
88
|
+
return _setPrototypeOf(o, p);
|
|
76
89
|
}
|
|
77
90
|
|
|
78
91
|
function _objectWithoutPropertiesLoose(source, excluded) {
|
|
@@ -183,12 +196,15 @@ function mapResponsiveProp(fromValue, mapper) {
|
|
|
183
196
|
};
|
|
184
197
|
}
|
|
185
198
|
|
|
186
|
-
var modules_54d944f2 = {"box":"
|
|
199
|
+
var modules_54d944f2 = {"box":"_2a8ae321","position-absolute":"_29e047b9","position-fixed":"fe54fea9","position-relative":"_6a95a38d","position-sticky":"ccc689fe","tablet-position-absolute":"aad88ae1","tablet-position-fixed":"_2044ccd3","tablet-position-relative":"a0904035","tablet-position-sticky":"_770506a5","desktop-position-absolute":"_5a954855","desktop-position-fixed":"_2dc73359","desktop-position-relative":"_6ab005ed","desktop-position-sticky":"fa60c726","display-block":"_221ad6a3","display-flex":"_6764f5bc","display-inline":"_50c37dba","display-inlineBlock":"_16546fe0","display-inlineFlex":"_2782a687","display-none":"b70b4fb7","tablet-display-block":"_5b3547cc","tablet-display-flex":"_099432e6","tablet-display-inline":"d99fcd80","tablet-display-inlineBlock":"_8f160568","tablet-display-inlineFlex":"_5b7b4be4","tablet-display-none":"_553721f8","desktop-display-block":"_6b86b317","desktop-display-flex":"eb20eda4","desktop-display-inline":"be19d1e9","desktop-display-inlineBlock":"dcf7c80a","desktop-display-inlineFlex":"e4f02b1f","desktop-display-none":"_3974e6d8","flexDirection-column":"daf5e366","flexDirection-row":"_47f2ddb7","tablet-flexDirection-column":"_27490d54","tablet-flexDirection-row":"_0317f51b","desktop-flexDirection-column":"_97590faa","desktop-flexDirection-row":"bf5d416e","flexWrap-wrap":"_210c1f9e","flexWrap-nowrap":"_2c775d07","flexShrink-0":"_25cae61d","flexGrow-0":"_6068a9cf","flexGrow-1":"c63f682c","alignItems-flexStart":"_0e774dfc","alignItems-center":"_5695a5d5","alignItems-flexEnd":"_139515d8","alignItems-baseline":"cea92f0a","tablet-alignItems-flexStart":"_3dc7ec16","tablet-alignItems-center":"_7993a7fa","tablet-alignItems-flexEnd":"b90d7edc","tablet-alignItems-baseline":"_7bd633f1","desktop-alignItems-flexStart":"_260d232b","desktop-alignItems-center":"_9e2e0a07","desktop-alignItems-flexEnd":"fc97448b","desktop-alignItems-baseline":"_0f76a529","justifyContent-flexStart":"_21d759bf","justifyContent-center":"ff70e049","justifyContent-flexEnd":"ae15d5ad","justifyContent-spaceAround":"_84374266","justifyContent-spaceBetween":"e72a8ca2","justifyContent-spaceEvenly":"_86224cb5","tablet-justifyContent-flexStart":"dceedee0","tablet-justifyContent-center":"_34ab3dab","tablet-justifyContent-flexEnd":"d5da2eb9","tablet-justifyContent-spaceAround":"_1677560d","tablet-justifyContent-spaceBetween":"ef77b2e7","tablet-justifyContent-spaceEvenly":"_685ef848","desktop-justifyContent-flexStart":"_695667f2","desktop-justifyContent-center":"ebb180cc","desktop-justifyContent-flexEnd":"bd5bb675","desktop-justifyContent-spaceBetween":"ae08a70c","overflow-hidden":"_4afa6fac","overflow-auto":"d8d342e4","overflow-visible":"c104da68","overflow-scroll":"_2d6bc0d0","height-full":"_99458759","bg-default":"aadb417c","bg-aside":"_36dca662","bg-highlight":"a1054115","bg-selected":"d17b4e9a","borderRadius-standard":"e3a3ee05","borderRadius-full":"be0cb60b","border-primary":"b9999f44","border-secondary":"_91063996","border-tertiary":"_0902977e","textAlign-start":"a7c58898","textAlign-center":"_2c9a262a","textAlign-end":"_46f07e93","textAlign-justify":"e526003e","tablet-textAlign-start":"_26864fce","tablet-textAlign-center":"e8f51d21","tablet-textAlign-end":"c1dc8b90","tablet-textAlign-justify":"_36bb3fa9","desktop-textAlign-start":"_942e35b0","desktop-textAlign-center":"_92da5c98","desktop-textAlign-end":"_2b0ecaf6","desktop-textAlign-justify":"_3dd24641"};
|
|
187
200
|
|
|
188
201
|
var modules_b537a8ee = {"paddingTop-xsmall":"c4803194","paddingTop-small":"_4e9ab24b","paddingTop-medium":"_1d226e27","paddingTop-large":"eb6097f1","paddingTop-xlarge":"d3229ba4","paddingTop-xxlarge":"_47978ba4","tablet-paddingTop-xsmall":"f987719c","tablet-paddingTop-small":"_8dbc4b4d","tablet-paddingTop-medium":"ae44fe07","tablet-paddingTop-large":"ffe9548d","tablet-paddingTop-xlarge":"f2b76a44","tablet-paddingTop-xxlarge":"c6eb8f43","desktop-paddingTop-xsmall":"_8699b560","desktop-paddingTop-small":"_02c374b7","desktop-paddingTop-medium":"_0dd0332f","desktop-paddingTop-large":"da55f1f6","desktop-paddingTop-xlarge":"_8ef2a278","desktop-paddingTop-xxlarge":"_8b493b28","paddingRight-xsmall":"_211eebc7","paddingRight-small":"ad0ccf15","paddingRight-medium":"a03e39af","paddingRight-large":"f0941ead","paddingRight-xlarge":"e47c5a43","paddingRight-xxlarge":"e849a5cf","tablet-paddingRight-xsmall":"_85374228","tablet-paddingRight-small":"_89df37b9","tablet-paddingRight-medium":"_1cc50ebe","tablet-paddingRight-large":"_1060982b","tablet-paddingRight-xlarge":"be58847d","tablet-paddingRight-xxlarge":"_45093484","desktop-paddingRight-xsmall":"f8d99d6a","desktop-paddingRight-small":"efa076d9","desktop-paddingRight-medium":"e59caa64","desktop-paddingRight-large":"da42f46a","desktop-paddingRight-xlarge":"b3ee2580","desktop-paddingRight-xxlarge":"_3ef94658","paddingBottom-xsmall":"b0e6eab4","paddingBottom-small":"_9510d053","paddingBottom-medium":"d7af60c9","paddingBottom-large":"b75f86cd","paddingBottom-xlarge":"fbd4ce29","paddingBottom-xxlarge":"_33e3ad63","tablet-paddingBottom-xsmall":"f0302da7","tablet-paddingBottom-small":"_4f9b8012","tablet-paddingBottom-medium":"_4333e20e","tablet-paddingBottom-large":"_30bbc76c","tablet-paddingBottom-xlarge":"ba5a4008","tablet-paddingBottom-xxlarge":"_423a3b1a","desktop-paddingBottom-xsmall":"b40139b7","desktop-paddingBottom-small":"f96071fa","desktop-paddingBottom-medium":"fe803c9a","desktop-paddingBottom-large":"_01686eb9","desktop-paddingBottom-xlarge":"afa763d8","desktop-paddingBottom-xxlarge":"a95785f1","paddingLeft-xsmall":"cad4e2ec","paddingLeft-small":"d70b3c17","paddingLeft-medium":"_8c851bd6","paddingLeft-large":"_078feb3c","paddingLeft-xlarge":"_76ab968c","paddingLeft-xxlarge":"aaca85d7","tablet-paddingLeft-xsmall":"_5eb0e5aa","tablet-paddingLeft-small":"_0384fb4f","tablet-paddingLeft-medium":"edffff6f","tablet-paddingLeft-large":"_873b9a46","tablet-paddingLeft-xlarge":"_89105db5","tablet-paddingLeft-xxlarge":"db1966fe","desktop-paddingLeft-xsmall":"b17f826b","desktop-paddingLeft-small":"_6dc83610","desktop-paddingLeft-medium":"_3421b8b2","desktop-paddingLeft-large":"_68cec7a6","desktop-paddingLeft-xlarge":"_94bde020","desktop-paddingLeft-xxlarge":"b94ee579"};
|
|
189
202
|
|
|
190
203
|
var modules_131405ac = {"marginTop-xsmall":"c7813d79","marginTop-small":"d3449da6","marginTop-medium":"_4ea254c1","marginTop-large":"c0844f64","marginTop-xlarge":"_213145b4","marginTop-xxlarge":"df61c84c","marginTop--xsmall":"efe72b13","marginTop--small":"_870c2768","marginTop--medium":"_0b927c57","marginTop--large":"_461db014","marginTop--xlarge":"_2a3a8cb8","marginTop--xxlarge":"_9bcda921","tablet-marginTop-xsmall":"_6add01e4","tablet-marginTop-small":"_735ef86b","tablet-marginTop-medium":"_0477d068","tablet-marginTop-large":"_2c90af97","tablet-marginTop-xlarge":"_63a82db6","tablet-marginTop-xxlarge":"_03cd7726","tablet-marginTop--xsmall":"c986a62a","tablet-marginTop--small":"be2bdcdd","tablet-marginTop--medium":"_47d2686b","tablet-marginTop--large":"_25e5af9d","tablet-marginTop--xlarge":"ee82f441","tablet-marginTop--xxlarge":"a6f9d404","desktop-marginTop-xsmall":"_4d8d9a36","desktop-marginTop-small":"e813cee7","desktop-marginTop-medium":"_56975b7d","desktop-marginTop-large":"_53b367f6","desktop-marginTop-xlarge":"d69e7311","desktop-marginTop-xxlarge":"_92f57c7e","desktop-marginTop--xsmall":"_96880d3e","desktop-marginTop--small":"dc3f3555","desktop-marginTop--medium":"_86dd06bb","desktop-marginTop--large":"c93ef12e","desktop-marginTop--xlarge":"bc8fd4a2","desktop-marginTop--xxlarge":"b12a9124","marginRight-xsmall":"_6016f4fb","marginRight-small":"b85e3dfa","marginRight-medium":"_297575f4","marginRight-large":"b401ac6c","marginRight-xlarge":"dc3ec387","marginRight-xxlarge":"_24694604","marginRight--xsmall":"_8e9bf2ee","marginRight--small":"ae9d1115","marginRight--medium":"_14e46fc3","marginRight--large":"_3370631b","marginRight--xlarge":"_3f0e9b50","marginRight--xxlarge":"bc13e010","tablet-marginRight-xsmall":"_6fa1aae3","tablet-marginRight-small":"_2976c5cb","tablet-marginRight-medium":"_38d94802","tablet-marginRight-large":"db9569b5","tablet-marginRight-xlarge":"_4a52f06d","tablet-marginRight-xxlarge":"_8a0f0410","tablet-marginRight--xsmall":"e7d40e9d","tablet-marginRight--small":"_680fde91","tablet-marginRight--medium":"_021010ca","tablet-marginRight--large":"_9e52c87c","tablet-marginRight--xlarge":"_4d602613","tablet-marginRight--xxlarge":"_21b1b65a","desktop-marginRight-xsmall":"_7321bc07","desktop-marginRight-small":"fa1721f4","desktop-marginRight-medium":"_3fd7b4b8","desktop-marginRight-large":"_4fdc2f74","desktop-marginRight-xlarge":"c0254761","desktop-marginRight-xxlarge":"_710a5f09","desktop-marginRight--xsmall":"e08bee7f","desktop-marginRight--small":"e5ab73d2","desktop-marginRight--medium":"_5e731477","desktop-marginRight--large":"_0f57a22e","desktop-marginRight--xlarge":"_25f26ed3","desktop-marginRight--xxlarge":"_11a3b4e0","marginBottom-xsmall":"_6a4f69f7","marginBottom-small":"db26b033","marginBottom-medium":"c7313022","marginBottom-large":"a5885889","marginBottom-xlarge":"_33dfbd8e","marginBottom-xxlarge":"_795ad2de","marginBottom--xsmall":"a329dbd3","marginBottom--small":"_85e739fb","marginBottom--medium":"_681f65ff","marginBottom--large":"caf50d8f","marginBottom--xlarge":"_1e084cbf","marginBottom--xxlarge":"_3dfb1c7e","tablet-marginBottom-xsmall":"ef4735be","tablet-marginBottom-small":"de55afba","tablet-marginBottom-medium":"_0e33ce88","tablet-marginBottom-large":"_8ca391fc","tablet-marginBottom-xlarge":"_3a609d23","tablet-marginBottom-xxlarge":"_3e1177e4","tablet-marginBottom--xsmall":"d384884d","tablet-marginBottom--small":"_75254cec","tablet-marginBottom--medium":"_5d9f127d","tablet-marginBottom--large":"_835f1089","tablet-marginBottom--xlarge":"dad52a72","tablet-marginBottom--xxlarge":"_8703a4bf","desktop-marginBottom-xsmall":"_90fd20e9","desktop-marginBottom-small":"f3769191","desktop-marginBottom-medium":"_156410f8","desktop-marginBottom-large":"_7fed74d0","desktop-marginBottom-xlarge":"_477dc10e","desktop-marginBottom-xxlarge":"_85c82d89","desktop-marginBottom--xsmall":"_4f09c1e0","desktop-marginBottom--small":"_9523e048","desktop-marginBottom--medium":"efe10240","desktop-marginBottom--large":"c43971e6","desktop-marginBottom--xlarge":"f9b4da15","desktop-marginBottom--xxlarge":"a10fdf70","marginLeft-xsmall":"f9be90b4","marginLeft-small":"f53218d5","marginLeft-medium":"c4a9b3ab","marginLeft-large":"_5755e2c3","marginLeft-xlarge":"_33fc9354","marginLeft-xxlarge":"_4749a3bf","marginLeft--xsmall":"c76cb3c7","marginLeft--small":"_96003c07","marginLeft--medium":"_09988d07","marginLeft--large":"b4a486f6","marginLeft--xlarge":"f396e75e","marginLeft--xxlarge":"_81d1f26d","tablet-marginLeft-xsmall":"_0a46e8f1","tablet-marginLeft-small":"_57c970af","tablet-marginLeft-medium":"_4b6099d3","tablet-marginLeft-large":"_378fcff5","tablet-marginLeft-xlarge":"f8785663","tablet-marginLeft-xxlarge":"_72f957ee","tablet-marginLeft--xsmall":"_2288c7e1","tablet-marginLeft--small":"b27c1c05","tablet-marginLeft--medium":"_702cbb13","tablet-marginLeft--large":"_1a2748b4","tablet-marginLeft--xlarge":"b8c043a5","tablet-marginLeft--xxlarge":"_8dc8ff63","desktop-marginLeft-xsmall":"c2af646d","desktop-marginLeft-small":"c03d07be","desktop-marginLeft-medium":"_915fb1d3","desktop-marginLeft-large":"_64214ee1","desktop-marginLeft-xlarge":"_7be4a22c","desktop-marginLeft-xxlarge":"_5ec0a401","desktop-marginLeft--xsmall":"ea29f1ee","desktop-marginLeft--small":"c26652c7","desktop-marginLeft--medium":"c24f6af9","desktop-marginLeft--large":"c2671f27","desktop-marginLeft--xlarge":"cc51a04e","desktop-marginLeft--xxlarge":"fd581f54"};
|
|
191
204
|
|
|
205
|
+
var modules_89b7671c = {"minWidth-0":"_68ab48ca","minWidth-xsmall":"_6fa2b565","minWidth-small":"dd50fabd","minWidth-medium":"e7e2c808","minWidth-large":"_6abbe25e","minWidth-xlarge":"_54f479ac","maxWidth-xsmall":"_148492bc","maxWidth-small":"bd023b96","maxWidth-medium":"e102903f","maxWidth-large":"_0e8d76d7","maxWidth-xlarge":"_47a031d0","maxWidth-full":"cd4c8183","width-0":"_5f5959e8","width-full":"_8c75067a","width-auto":"_56a651f6","width-maxContent":"_26f87bb8","width-minContent":"_07a6ab44","width-fitContent":"a87016fa","width-xsmall":"_1a972e50","width-small":"c96d8261","width-medium":"f3829d42","width-large":"_2caef228","width-xlarge":"_069e1491"};
|
|
206
|
+
|
|
207
|
+
var _excluded = ["as", "position", "display", "flexDirection", "flexWrap", "flexGrow", "flexShrink", "alignItems", "justifyContent", "overflow", "width", "height", "background", "border", "borderRadius", "minWidth", "maxWidth", "textAlign", "padding", "paddingY", "paddingX", "paddingTop", "paddingRight", "paddingBottom", "paddingLeft", "margin", "marginY", "marginX", "marginTop", "marginRight", "marginBottom", "marginLeft", "className", "children"];
|
|
192
208
|
var Box = /*#__PURE__*/polymorphicComponent(function Box(_ref, ref) {
|
|
193
209
|
var _ref2, _ref3, _ref4, _ref5, _ref6, _ref7, _ref8, _ref9;
|
|
194
210
|
|
|
@@ -230,7 +246,7 @@ var Box = /*#__PURE__*/polymorphicComponent(function Box(_ref, ref) {
|
|
|
230
246
|
marginLeft = _ref.marginLeft,
|
|
231
247
|
className = _ref.className,
|
|
232
248
|
children = _ref.children,
|
|
233
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
249
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded);
|
|
234
250
|
|
|
235
251
|
var resolvedPaddingTop = (_ref2 = paddingTop !== null && paddingTop !== void 0 ? paddingTop : paddingY) !== null && _ref2 !== void 0 ? _ref2 : padding;
|
|
236
252
|
var resolvedPaddingRight = (_ref3 = paddingRight !== null && paddingRight !== void 0 ? paddingRight : paddingX) !== null && _ref3 !== void 0 ? _ref3 : padding;
|
|
@@ -242,23 +258,25 @@ var Box = /*#__PURE__*/polymorphicComponent(function Box(_ref, ref) {
|
|
|
242
258
|
var resolvedMarginLeft = (_ref9 = marginLeft !== null && marginLeft !== void 0 ? marginLeft : marginX) !== null && _ref9 !== void 0 ? _ref9 : margin;
|
|
243
259
|
var omitFlex = !display || typeof display === 'string' && display !== 'flex' && display !== 'inlineFlex';
|
|
244
260
|
return /*#__PURE__*/React.createElement(component, _objectSpread2(_objectSpread2({}, props), {}, {
|
|
245
|
-
className: classNames(className, modules_54d944f2.box, display ? getClassNames(modules_54d944f2, 'display', display) : null, position !== 'static' ? getClassNames(modules_54d944f2, 'position', position) : null, minWidth != null ? getClassNames(
|
|
261
|
+
className: classNames(className, modules_54d944f2.box, display ? getClassNames(modules_54d944f2, 'display', display) : null, position !== 'static' ? getClassNames(modules_54d944f2, 'position', position) : null, minWidth != null ? getClassNames(modules_89b7671c, 'minWidth', String(minWidth)) : null, getClassNames(modules_89b7671c, 'maxWidth', maxWidth), textAlign !== 'start' ? getClassNames(modules_54d944f2, 'textAlign', textAlign) : null, // padding
|
|
246
262
|
getClassNames(modules_b537a8ee, 'paddingTop', resolvedPaddingTop), getClassNames(modules_b537a8ee, 'paddingRight', resolvedPaddingRight), getClassNames(modules_b537a8ee, 'paddingBottom', resolvedPaddingBottom), getClassNames(modules_b537a8ee, 'paddingLeft', resolvedPaddingLeft), // margin
|
|
247
263
|
getClassNames(modules_131405ac, 'marginTop', resolvedMarginTop), getClassNames(modules_131405ac, 'marginRight', resolvedMarginRight), getClassNames(modules_131405ac, 'marginBottom', resolvedMarginBottom), getClassNames(modules_131405ac, 'marginLeft', resolvedMarginLeft), // flex props
|
|
248
264
|
omitFlex ? null : getClassNames(modules_54d944f2, 'flexDirection', flexDirection), omitFlex ? null : getClassNames(modules_54d944f2, 'flexWrap', flexWrap), omitFlex ? null : getClassNames(modules_54d944f2, 'alignItems', alignItems), omitFlex ? null : getClassNames(modules_54d944f2, 'justifyContent', justifyContent), flexShrink != null ? getClassNames(modules_54d944f2, 'flexShrink', String(flexShrink)) : null, flexGrow != null ? getClassNames(modules_54d944f2, 'flexGrow', String(flexGrow)) : null, // other props
|
|
249
|
-
getClassNames(modules_54d944f2, 'overflow', overflow), getClassNames(
|
|
265
|
+
getClassNames(modules_54d944f2, 'overflow', overflow), width != null ? getClassNames(modules_89b7671c, 'width', String(width)) : null, getClassNames(modules_54d944f2, 'height', height), getClassNames(modules_54d944f2, 'bg', background), borderRadius !== 'none' ? getClassNames(modules_54d944f2, 'borderRadius', borderRadius) : null, border !== 'none' ? getClassNames(modules_54d944f2, 'border', border) : null) || undefined,
|
|
250
266
|
ref: ref
|
|
251
267
|
}), children);
|
|
252
268
|
});
|
|
253
269
|
|
|
254
270
|
var modules_67f2d07a = {"space-xsmall":"_6f59c771","column":"_91e05f0f","space-small":"_5a55af26","space-medium":"fa261310","space-large":"_6ebd4e46","space-xlarge":"_55ce4aea","space-xxlarge":"_04c9c3ac","tablet-space-xsmall":"ab76d8cd","tablet-space-small":"_14629bfb","tablet-space-medium":"_5b4e39ea","tablet-space-large":"ba270182","tablet-space-xlarge":"b96e7ec7","tablet-space-xxlarge":"d276612c","desktop-space-xsmall":"d7a73106","desktop-space-small":"_8f5e0e9e","desktop-space-medium":"_3a168411","desktop-space-large":"_0abcc12e","desktop-space-xlarge":"e0bafc60","desktop-space-xxlarge":"d2df9afd","columnWidth-auto":"b18d0b47","columnWidth-1-2":"_102a6b27","columnWidth-1-3":"_829872fe","columnWidth-2-3":"cf5aef9a","columnWidth-1-4":"_931bf714","columnWidth-3-4":"b0303130","columnWidth-1-5":"f6589a6f","columnWidth-2-5":"_2823aed9","columnWidth-3-5":"d00ba3bb","columnWidth-4-5":"_338f2d7c","tablet-tablet-space-xsmall":"_06582234"};
|
|
255
271
|
|
|
272
|
+
var _excluded$1 = ["width", "children", "exceptionallySetClassName"],
|
|
273
|
+
_excluded2 = ["space", "align", "alignY", "collapseBelow", "children", "exceptionallySetClassName"];
|
|
256
274
|
var Column = /*#__PURE__*/polymorphicComponent(function Column(_ref, ref) {
|
|
257
275
|
var _ref$width = _ref.width,
|
|
258
276
|
width = _ref$width === void 0 ? 'auto' : _ref$width,
|
|
259
277
|
children = _ref.children,
|
|
260
278
|
exceptionallySetClassName = _ref.exceptionallySetClassName,
|
|
261
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
279
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$1);
|
|
262
280
|
|
|
263
281
|
return /*#__PURE__*/React.createElement(Box, Object.assign({}, props, {
|
|
264
282
|
className: [exceptionallySetClassName, modules_67f2d07a.column, width !== 'content' ? getClassNames(modules_67f2d07a, 'columnWidth', width.replace('/', '-')) : null],
|
|
@@ -278,7 +296,7 @@ var Columns = /*#__PURE__*/polymorphicComponent(function Columns(_ref2, ref) {
|
|
|
278
296
|
collapseBelow = _ref2.collapseBelow,
|
|
279
297
|
children = _ref2.children,
|
|
280
298
|
exceptionallySetClassName = _ref2.exceptionallySetClassName,
|
|
281
|
-
props = _objectWithoutPropertiesLoose(_ref2,
|
|
299
|
+
props = _objectWithoutPropertiesLoose(_ref2, _excluded2);
|
|
282
300
|
|
|
283
301
|
return /*#__PURE__*/React.createElement(Box, Object.assign({}, props, {
|
|
284
302
|
className: [exceptionallySetClassName, getClassNames(modules_67f2d07a, 'space', space)],
|
|
@@ -303,10 +321,12 @@ var Columns = /*#__PURE__*/polymorphicComponent(function Columns(_ref2, ref) {
|
|
|
303
321
|
|
|
304
322
|
var modules_c742c4d7 = {"weight-primary":"_3f3a401c","weight-secondary":"_03b05b70","weight-tertiary":"b6f67ff8"};
|
|
305
323
|
|
|
324
|
+
var _excluded$2 = ["weight"];
|
|
325
|
+
|
|
306
326
|
function Divider(_ref) {
|
|
307
327
|
var _ref$weight = _ref.weight,
|
|
308
|
-
weight = _ref$weight === void 0 ? '
|
|
309
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
328
|
+
weight = _ref$weight === void 0 ? 'tertiary' : _ref$weight,
|
|
329
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$2);
|
|
310
330
|
|
|
311
331
|
return /*#__PURE__*/React.createElement(Box, Object.assign({
|
|
312
332
|
as: "hr",
|
|
@@ -316,6 +336,7 @@ function Divider(_ref) {
|
|
|
316
336
|
|
|
317
337
|
var modules_da5d5c21 = {"space-xsmall":"_6b1279e0","space-small":"_0d82c42d","space-medium":"_556714e1","space-large":"e90b43fb","space-xlarge":"a9c34345","space-xxlarge":"aa102efe","tablet-space-xsmall":"_34d16157","tablet-space-small":"c7e0e54f","tablet-space-medium":"_7f2a4e4b","tablet-space-large":"ae256487","tablet-space-xlarge":"e88be0f7","tablet-space-xxlarge":"dc7bcb18","desktop-space-xsmall":"_853f3012","desktop-space-small":"_3bfaf758","desktop-space-medium":"_36462a93","desktop-space-large":"e73081b7","desktop-space-xlarge":"e22ec9dd","desktop-space-xxlarge":"_4a20bd12"};
|
|
318
338
|
|
|
339
|
+
var _excluded$3 = ["as", "space", "align", "alignY", "children", "exceptionallySetClassName"];
|
|
319
340
|
var Inline = /*#__PURE__*/polymorphicComponent(function Inline(_ref, ref) {
|
|
320
341
|
var as = _ref.as,
|
|
321
342
|
space = _ref.space,
|
|
@@ -325,9 +346,9 @@ var Inline = /*#__PURE__*/polymorphicComponent(function Inline(_ref, ref) {
|
|
|
325
346
|
alignY = _ref$alignY === void 0 ? 'center' : _ref$alignY,
|
|
326
347
|
children = _ref.children,
|
|
327
348
|
exceptionallySetClassName = _ref.exceptionallySetClassName,
|
|
328
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
349
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$3);
|
|
329
350
|
|
|
330
|
-
return /*#__PURE__*/React.createElement(Box,
|
|
351
|
+
return /*#__PURE__*/React.createElement(Box, Object.assign({}, props, {
|
|
331
352
|
as: as,
|
|
332
353
|
display: "flex",
|
|
333
354
|
flexWrap: "wrap",
|
|
@@ -339,11 +360,12 @@ var Inline = /*#__PURE__*/polymorphicComponent(function Inline(_ref, ref) {
|
|
|
339
360
|
justifyContent: mapResponsiveProp(align, function (align) {
|
|
340
361
|
return align === 'left' ? 'flexStart' : align === 'right' ? 'flexEnd' : 'center';
|
|
341
362
|
})
|
|
342
|
-
}), children)
|
|
363
|
+
}), children);
|
|
343
364
|
});
|
|
344
365
|
|
|
345
366
|
var modules_3af3b7ac = {"space-xsmall":"_7b475ead","space-small":"_5641699f","space-medium":"_1a1c63e4","space-large":"_560f80a0","space-xlarge":"_84ffebbc","space-xxlarge":"b60a65cb","tablet-space-xsmall":"d808f5c3","tablet-space-small":"a51c76b3","tablet-space-medium":"_7185a7aa","tablet-space-large":"af82e610","tablet-space-xlarge":"_88b4ff46","tablet-space-xxlarge":"_9de15321","desktop-space-xsmall":"_6fb32d20","desktop-space-small":"_07ee315a","desktop-space-medium":"a270d7ec","desktop-space-large":"ea6ebb29","desktop-space-xlarge":"_35b36178","desktop-space-xxlarge":"_56c7dc23"};
|
|
346
367
|
|
|
368
|
+
var _excluded$4 = ["as", "space", "align", "dividers", "children", "exceptionallySetClassName"];
|
|
347
369
|
var Stack = /*#__PURE__*/polymorphicComponent(function Stack(_ref, ref) {
|
|
348
370
|
var as = _ref.as,
|
|
349
371
|
space = _ref.space,
|
|
@@ -353,7 +375,7 @@ var Stack = /*#__PURE__*/polymorphicComponent(function Stack(_ref, ref) {
|
|
|
353
375
|
dividers = _ref$dividers === void 0 ? 'none' : _ref$dividers,
|
|
354
376
|
children = _ref.children,
|
|
355
377
|
exceptionallySetClassName = _ref.exceptionallySetClassName,
|
|
356
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
378
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$4);
|
|
357
379
|
|
|
358
380
|
var alignProps = align === 'start' ? undefined : {
|
|
359
381
|
width: 'full',
|
|
@@ -376,6 +398,7 @@ var Stack = /*#__PURE__*/polymorphicComponent(function Stack(_ref, ref) {
|
|
|
376
398
|
|
|
377
399
|
var modules_4689e97e = {"hiddenOnPrint":"_0e595dea"};
|
|
378
400
|
|
|
401
|
+
var _excluded$5 = ["display", "children", "exceptionallySetClassName"];
|
|
379
402
|
/**
|
|
380
403
|
* A component that allows to specify how to hide itself on certain responsive screen sizes, or on
|
|
381
404
|
* print media.
|
|
@@ -390,7 +413,7 @@ var Hidden = /*#__PURE__*/polymorphicComponent(function Hidden(_ref, ref) {
|
|
|
390
413
|
display = _ref$display === void 0 ? 'block' : _ref$display,
|
|
391
414
|
children = _ref.children,
|
|
392
415
|
exceptionallySetClassName = _ref.exceptionallySetClassName,
|
|
393
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
416
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$5);
|
|
394
417
|
|
|
395
418
|
var hiddenOnPrint = 'print' in props && props.print;
|
|
396
419
|
var hiddenOnDesktop = ('above' in props);
|
|
@@ -439,6 +462,242 @@ var HiddenVisually = /*#__PURE__*/polymorphicComponent(function HiddenVisually(p
|
|
|
439
462
|
}));
|
|
440
463
|
});
|
|
441
464
|
|
|
465
|
+
var _excluded$6 = ["children", "content", "position", "gapSize", "className"];
|
|
466
|
+
|
|
467
|
+
var SHOW_DELAY = 500;
|
|
468
|
+
var HIDE_DELAY = 100;
|
|
469
|
+
|
|
470
|
+
function useDelayedTooltipState(initialState) {
|
|
471
|
+
var tooltipState = Tooltip$1.useTooltipState(initialState);
|
|
472
|
+
var delay = useDelay();
|
|
473
|
+
return React__default.useMemo(function () {
|
|
474
|
+
return _objectSpread2(_objectSpread2({}, tooltipState), {}, {
|
|
475
|
+
show: delay(function () {
|
|
476
|
+
return tooltipState.show();
|
|
477
|
+
}, SHOW_DELAY),
|
|
478
|
+
hide: delay(function () {
|
|
479
|
+
return tooltipState.hide();
|
|
480
|
+
}, HIDE_DELAY)
|
|
481
|
+
});
|
|
482
|
+
}, [delay, tooltipState]);
|
|
483
|
+
}
|
|
484
|
+
|
|
485
|
+
function Tooltip(_ref) {
|
|
486
|
+
var children = _ref.children,
|
|
487
|
+
content = _ref.content,
|
|
488
|
+
_ref$position = _ref.position,
|
|
489
|
+
position = _ref$position === void 0 ? 'top' : _ref$position,
|
|
490
|
+
_ref$gapSize = _ref.gapSize,
|
|
491
|
+
gapSize = _ref$gapSize === void 0 ? 3 : _ref$gapSize,
|
|
492
|
+
className = _ref.className,
|
|
493
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$6);
|
|
494
|
+
|
|
495
|
+
var tooltip = useDelayedTooltipState({
|
|
496
|
+
placement: position,
|
|
497
|
+
gutter: gapSize
|
|
498
|
+
});
|
|
499
|
+
var child = React__default.Children.only(children);
|
|
500
|
+
|
|
501
|
+
if (!content) {
|
|
502
|
+
return child;
|
|
503
|
+
}
|
|
504
|
+
/**
|
|
505
|
+
* Prevents the tooltip from automatically firing on focus all the time. This is to prevent
|
|
506
|
+
* tooltips from showing when the trigger element is focused back after a popover or dialog that
|
|
507
|
+
* it opened was closed. See link below for more details.
|
|
508
|
+
* @see https://github.com/reakit/reakit/discussions/749
|
|
509
|
+
*/
|
|
510
|
+
|
|
511
|
+
|
|
512
|
+
function handleFocus(event) {
|
|
513
|
+
// If focus is not followed by a key up event, does it mean that it's not
|
|
514
|
+
// an intentional keyboard focus? Not sure but it seems to work.
|
|
515
|
+
// This may be resolved soon in an upcoming version of reakit:
|
|
516
|
+
// https://github.com/reakit/reakit/issues/750
|
|
517
|
+
function handleKeyUp(e) {
|
|
518
|
+
var eventKey = e.key;
|
|
519
|
+
|
|
520
|
+
if (eventKey !== 'Escape' && eventKey !== 'Enter' && eventKey !== 'Space') {
|
|
521
|
+
tooltip.show();
|
|
522
|
+
}
|
|
523
|
+
}
|
|
524
|
+
|
|
525
|
+
event.currentTarget.addEventListener('keyup', handleKeyUp, {
|
|
526
|
+
once: true
|
|
527
|
+
}); // Prevent tooltip.show from being called by TooltipReference
|
|
528
|
+
|
|
529
|
+
event.preventDefault(); // eslint-disable-next-line @typescript-eslint/no-unsafe-call, @typescript-eslint/no-unsafe-member-access
|
|
530
|
+
|
|
531
|
+
if (typeof child.props.onFocus === 'function') child.props.onFocus(event);
|
|
532
|
+
}
|
|
533
|
+
|
|
534
|
+
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(Tooltip$1.TooltipReference, Object.assign({}, tooltip, {
|
|
535
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/no-unsafe-member-access, @typescript-eslint/no-unsafe-assignment
|
|
536
|
+
ref: child.ref
|
|
537
|
+
}, child.props, {
|
|
538
|
+
onFocus: handleFocus
|
|
539
|
+
}), function (referenceProps) {
|
|
540
|
+
return /*#__PURE__*/React__default.cloneElement(child, referenceProps);
|
|
541
|
+
}), tooltip.visible ? /*#__PURE__*/React__default.createElement(Tooltip$1.Tooltip, Object.assign({}, tooltip, props, {
|
|
542
|
+
className: classNames('reactist_tooltip', className)
|
|
543
|
+
}), typeof content === 'function' ? content() : content) : null);
|
|
544
|
+
}
|
|
545
|
+
// Internal helpers
|
|
546
|
+
//
|
|
547
|
+
|
|
548
|
+
/**
|
|
549
|
+
* Returns a function offering the same interface as setTimeout, but cleans up on unmount.
|
|
550
|
+
*
|
|
551
|
+
* The timeout state is shared, and only one delayed function can be active at any given time. If
|
|
552
|
+
* a new delayed function is called while another one was waiting for its time to run, that older
|
|
553
|
+
* invocation is cleared and it never runs.
|
|
554
|
+
*
|
|
555
|
+
* This is suitable for our use case here, but probably not the most intuitive thing in general.
|
|
556
|
+
* That's why this is not made a shared util or something like it.
|
|
557
|
+
*/
|
|
558
|
+
|
|
559
|
+
function useDelay() {
|
|
560
|
+
var timeoutRef = React__default.useRef();
|
|
561
|
+
var clearTimeouts = React__default.useCallback(function clearTimeouts() {
|
|
562
|
+
if (timeoutRef.current != null) {
|
|
563
|
+
clearTimeout(timeoutRef.current);
|
|
564
|
+
}
|
|
565
|
+
}, []); // Runs clearTimeouts when the component is unmounted
|
|
566
|
+
|
|
567
|
+
React__default.useEffect(function () {
|
|
568
|
+
return clearTimeouts;
|
|
569
|
+
}, [clearTimeouts]);
|
|
570
|
+
return React__default.useCallback(function delay(fn, delay) {
|
|
571
|
+
return function () {
|
|
572
|
+
clearTimeouts();
|
|
573
|
+
timeoutRef.current = setTimeout(fn, delay);
|
|
574
|
+
};
|
|
575
|
+
}, [clearTimeouts]);
|
|
576
|
+
}
|
|
577
|
+
|
|
578
|
+
var modules_c7f5018f = {"svg":"_51539197","spinner":"_54fbe2b3","tint":"a0c466ed","fill":"_745b73d3"};
|
|
579
|
+
|
|
580
|
+
function Spinner(_ref) {
|
|
581
|
+
var _ref$size = _ref.size,
|
|
582
|
+
size = _ref$size === void 0 ? 24 : _ref$size;
|
|
583
|
+
return /*#__PURE__*/React.createElement("svg", {
|
|
584
|
+
"aria-hidden": true,
|
|
585
|
+
width: size,
|
|
586
|
+
height: size,
|
|
587
|
+
viewBox: "0 0 24 24",
|
|
588
|
+
className: modules_c7f5018f.svg
|
|
589
|
+
}, /*#__PURE__*/React.createElement("g", {
|
|
590
|
+
fill: "none",
|
|
591
|
+
fillRule: "nonzero"
|
|
592
|
+
}, /*#__PURE__*/React.createElement("path", {
|
|
593
|
+
className: modules_c7f5018f.tint,
|
|
594
|
+
d: "M17.945 3.958A9.955 9.955 0 0 0 12 2c-2.19 0-4.217.705-5.865 1.9L5.131 2.16A11.945 11.945 0 0 1 12 0c2.59 0 4.99.82 6.95 2.217l-1.005 1.741z"
|
|
595
|
+
}), /*#__PURE__*/React.createElement("path", {
|
|
596
|
+
className: modules_c7f5018f.fill,
|
|
597
|
+
d: "M5.13 2.16L6.136 3.9A9.987 9.987 0 0 0 2 12c0 5.523 4.477 10 10 10s10-4.477 10-10a9.986 9.986 0 0 0-4.055-8.042l1.006-1.741A11.985 11.985 0 0 1 24 12c0 6.627-5.373 12-12 12S0 18.627 0 12c0-4.073 2.029-7.671 5.13-9.84z"
|
|
598
|
+
})));
|
|
599
|
+
}
|
|
600
|
+
|
|
601
|
+
var modules_b9569bce = {"label":"_1f20c88a","baseButton":"_623015f3","size-small":"_062de645","size-normal":"_55e2a6a9","size-large":"cab32a7c","disabled":"e71c191a","iconButton":"_368efc16","startIcon":"d35389c1","endIcon":"_900d41d8","variant-primary":"_7c95e162","variant-secondary":"_9cb889aa","variant-tertiary":"_611b5b28","variant-quaternary":"_80c2bb84","tone-destructive":"ee13c455"};
|
|
602
|
+
|
|
603
|
+
var _excluded$7 = ["as", "variant", "tone", "size", "disabled", "loading", "tooltip", "onClick", "exceptionallySetClassName", "children", "startIcon", "endIcon", "icon"];
|
|
604
|
+
|
|
605
|
+
function preventDefault(event) {
|
|
606
|
+
event.preventDefault();
|
|
607
|
+
}
|
|
608
|
+
/**
|
|
609
|
+
* The component that powers `Button` and `ButtonLink`, where the button styling logic and some
|
|
610
|
+
* common functionality resides. This component is internal to Reactist.
|
|
611
|
+
*
|
|
612
|
+
* 🎨 [Figma](https://www.figma.com/file/LYlWNzvhMDh907l07mPPQk/Product-Web?node-id=4693%3A175143)
|
|
613
|
+
*
|
|
614
|
+
* @see Button
|
|
615
|
+
* @see ButtonLink
|
|
616
|
+
*/
|
|
617
|
+
|
|
618
|
+
|
|
619
|
+
var BaseButton = /*#__PURE__*/polymorphicComponent(function BaseButton(_ref, ref) {
|
|
620
|
+
var _ref$as = _ref.as,
|
|
621
|
+
as = _ref$as === void 0 ? 'div' : _ref$as,
|
|
622
|
+
variant = _ref.variant,
|
|
623
|
+
_ref$tone = _ref.tone,
|
|
624
|
+
tone = _ref$tone === void 0 ? 'normal' : _ref$tone,
|
|
625
|
+
_ref$size = _ref.size,
|
|
626
|
+
size = _ref$size === void 0 ? 'normal' : _ref$size,
|
|
627
|
+
_ref$disabled = _ref.disabled,
|
|
628
|
+
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
|
|
629
|
+
_ref$loading = _ref.loading,
|
|
630
|
+
loading = _ref$loading === void 0 ? false : _ref$loading,
|
|
631
|
+
tooltip = _ref.tooltip,
|
|
632
|
+
onClick = _ref.onClick,
|
|
633
|
+
exceptionallySetClassName = _ref.exceptionallySetClassName,
|
|
634
|
+
children = _ref.children,
|
|
635
|
+
startIcon = _ref.startIcon,
|
|
636
|
+
endIcon = _ref.endIcon,
|
|
637
|
+
icon = _ref.icon,
|
|
638
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$7);
|
|
639
|
+
|
|
640
|
+
var isDisabled = loading || disabled;
|
|
641
|
+
var buttonElement = /*#__PURE__*/React.createElement(Box, Object.assign({}, props, {
|
|
642
|
+
as: as,
|
|
643
|
+
ref: ref,
|
|
644
|
+
"aria-disabled": isDisabled,
|
|
645
|
+
onClick: isDisabled ? preventDefault : onClick,
|
|
646
|
+
className: [exceptionallySetClassName, modules_b9569bce.baseButton, modules_b9569bce["variant-" + variant], modules_b9569bce["tone-" + tone], modules_b9569bce["size-" + size], icon ? modules_b9569bce.iconButton : null, disabled ? modules_b9569bce.disabled : null]
|
|
647
|
+
}), icon ? loading && /*#__PURE__*/React.createElement(Spinner, null) || icon : /*#__PURE__*/React.createElement(React.Fragment, null, startIcon ? /*#__PURE__*/React.createElement(Box, {
|
|
648
|
+
display: "flex",
|
|
649
|
+
className: modules_b9569bce.startIcon,
|
|
650
|
+
"aria-hidden": true
|
|
651
|
+
}, loading && !endIcon ? /*#__PURE__*/React.createElement(Spinner, null) : startIcon) : null, children ? /*#__PURE__*/React.createElement("span", {
|
|
652
|
+
className: modules_b9569bce.label
|
|
653
|
+
}, children) : null, endIcon || loading && !startIcon ? /*#__PURE__*/React.createElement(Box, {
|
|
654
|
+
display: "flex",
|
|
655
|
+
className: modules_b9569bce.endIcon,
|
|
656
|
+
"aria-hidden": true
|
|
657
|
+
}, loading ? /*#__PURE__*/React.createElement(Spinner, null) : endIcon) : null)); // If it's an icon-only button, make sure it uses the aria-label as tooltip if no tooltip was provided
|
|
658
|
+
|
|
659
|
+
var tooltipContent = icon ? tooltip !== null && tooltip !== void 0 ? tooltip : props['aria-label'] : tooltip;
|
|
660
|
+
return tooltipContent ? /*#__PURE__*/React.createElement(Tooltip, {
|
|
661
|
+
content: tooltipContent
|
|
662
|
+
}, buttonElement) : buttonElement;
|
|
663
|
+
});
|
|
664
|
+
|
|
665
|
+
var _excluded$8 = ["variant", "tone", "size", "type", "disabled", "exceptionallySetClassName"];
|
|
666
|
+
/**
|
|
667
|
+
* A semantic button that also looks like a button, and provides all the necessary visual variants.
|
|
668
|
+
* It follows the [WAI-ARIA Button Pattern](https://www.w3.org/TR/wai-aria-practices/#button).
|
|
669
|
+
*
|
|
670
|
+
* 🎨 [Figma](https://www.figma.com/file/LYlWNzvhMDh907l07mPPQk/Product-Web?node-id=4693%3A175143)
|
|
671
|
+
*
|
|
672
|
+
* @see ButtonLink
|
|
673
|
+
*/
|
|
674
|
+
|
|
675
|
+
var Button = /*#__PURE__*/React.forwardRef(function Button(_ref, ref) {
|
|
676
|
+
var variant = _ref.variant,
|
|
677
|
+
_ref$tone = _ref.tone,
|
|
678
|
+
tone = _ref$tone === void 0 ? 'normal' : _ref$tone,
|
|
679
|
+
_ref$size = _ref.size,
|
|
680
|
+
size = _ref$size === void 0 ? 'normal' : _ref$size,
|
|
681
|
+
_ref$type = _ref.type,
|
|
682
|
+
type = _ref$type === void 0 ? 'button' : _ref$type,
|
|
683
|
+
_ref$disabled = _ref.disabled,
|
|
684
|
+
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
|
|
685
|
+
exceptionallySetClassName = _ref.exceptionallySetClassName,
|
|
686
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$8);
|
|
687
|
+
|
|
688
|
+
return /*#__PURE__*/React.createElement(BaseButton, Object.assign({}, props, {
|
|
689
|
+
as: "button",
|
|
690
|
+
ref: ref,
|
|
691
|
+
variant: variant,
|
|
692
|
+
tone: tone,
|
|
693
|
+
size: size,
|
|
694
|
+
type: type,
|
|
695
|
+
disabled: disabled,
|
|
696
|
+
exceptionallySetClassName: exceptionallySetClassName
|
|
697
|
+
}));
|
|
698
|
+
});
|
|
699
|
+
|
|
700
|
+
var _excluded$9 = ["tone"];
|
|
442
701
|
var alertIconForTone = {
|
|
443
702
|
info: AlertInfoIcon,
|
|
444
703
|
positive: AlertPositiveIcon,
|
|
@@ -448,7 +707,7 @@ var alertIconForTone = {
|
|
|
448
707
|
|
|
449
708
|
function AlertIcon(_ref) {
|
|
450
709
|
var tone = _ref.tone,
|
|
451
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
710
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$9);
|
|
452
711
|
|
|
453
712
|
var Icon = alertIconForTone[tone];
|
|
454
713
|
return Icon ? /*#__PURE__*/React.createElement(Icon, Object.assign({}, props)) : null;
|
|
@@ -521,7 +780,7 @@ function CloseIcon(props) {
|
|
|
521
780
|
}));
|
|
522
781
|
}
|
|
523
782
|
|
|
524
|
-
var modules_6205a58e = {"container":"
|
|
783
|
+
var modules_6205a58e = {"container":"eb665121","tone-info":"d0373ff9","tone-positive":"bb18dcab","tone-caution":"_0af02331","tone-critical":"f76146f9"};
|
|
525
784
|
|
|
526
785
|
function Alert(_ref) {
|
|
527
786
|
var id = _ref.id,
|
|
@@ -533,7 +792,7 @@ function Alert(_ref) {
|
|
|
533
792
|
id: id,
|
|
534
793
|
role: "alert",
|
|
535
794
|
"aria-live": "polite",
|
|
536
|
-
|
|
795
|
+
borderRadius: "standard",
|
|
537
796
|
className: [modules_6205a58e.container, getClassNames(modules_6205a58e, 'tone', tone)]
|
|
538
797
|
}, /*#__PURE__*/React.createElement(Columns, {
|
|
539
798
|
space: "small",
|
|
@@ -542,38 +801,25 @@ function Alert(_ref) {
|
|
|
542
801
|
width: "content"
|
|
543
802
|
}, /*#__PURE__*/React.createElement(AlertIcon, {
|
|
544
803
|
tone: tone
|
|
545
|
-
})), /*#__PURE__*/React.createElement(Column, null,
|
|
804
|
+
})), /*#__PURE__*/React.createElement(Column, null, /*#__PURE__*/React.createElement(Box, {
|
|
805
|
+
paddingY: "xsmall",
|
|
806
|
+
paddingRight: onClose != null && closeLabel != null ? undefined : 'small'
|
|
807
|
+
}, children)), onClose != null && closeLabel != null ? /*#__PURE__*/React.createElement(Column, {
|
|
546
808
|
width: "content"
|
|
547
|
-
}, /*#__PURE__*/React.createElement(
|
|
548
|
-
|
|
809
|
+
}, /*#__PURE__*/React.createElement(Button, {
|
|
810
|
+
variant: "quaternary",
|
|
811
|
+
size: "small",
|
|
549
812
|
onClick: onClose,
|
|
550
|
-
"aria-label": closeLabel
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
var _ref$size = _ref.size,
|
|
558
|
-
size = _ref$size === void 0 ? 24 : _ref$size;
|
|
559
|
-
return /*#__PURE__*/React.createElement("svg", {
|
|
560
|
-
"aria-hidden": true,
|
|
561
|
-
width: size,
|
|
562
|
-
height: size,
|
|
563
|
-
viewBox: "0 0 24 24",
|
|
564
|
-
className: modules_c7f5018f.svg
|
|
565
|
-
}, /*#__PURE__*/React.createElement("g", {
|
|
566
|
-
fill: "none",
|
|
567
|
-
fillRule: "nonzero"
|
|
568
|
-
}, /*#__PURE__*/React.createElement("path", {
|
|
569
|
-
className: modules_c7f5018f.tint,
|
|
570
|
-
d: "M17.945 3.958A9.955 9.955 0 0 0 12 2c-2.19 0-4.217.705-5.865 1.9L5.131 2.16A11.945 11.945 0 0 1 12 0c2.59 0 4.99.82 6.95 2.217l-1.005 1.741z"
|
|
571
|
-
}), /*#__PURE__*/React.createElement("path", {
|
|
572
|
-
className: modules_c7f5018f.fill,
|
|
573
|
-
d: "M5.13 2.16L6.136 3.9A9.987 9.987 0 0 0 2 12c0 5.523 4.477 10 10 10s10-4.477 10-10a9.986 9.986 0 0 0-4.055-8.042l1.006-1.741A11.985 11.985 0 0 1 24 12c0 6.627-5.373 12-12 12S0 18.627 0 12c0-4.073 2.029-7.671 5.13-9.84z"
|
|
574
|
-
})));
|
|
813
|
+
"aria-label": closeLabel,
|
|
814
|
+
icon: /*#__PURE__*/React.createElement(CloseIcon, null),
|
|
815
|
+
style: {
|
|
816
|
+
// @ts-expect-error not sure how to make TypeScript understand custom CSS properties
|
|
817
|
+
'--reactist-btn-hover-fill': 'transparent'
|
|
818
|
+
}
|
|
819
|
+
})) : null));
|
|
575
820
|
}
|
|
576
821
|
|
|
822
|
+
var _excluded$a = ["size", "exceptionallySetClassName"];
|
|
577
823
|
var sizeMapping = {
|
|
578
824
|
small: 24,
|
|
579
825
|
medium: 36,
|
|
@@ -586,17 +832,20 @@ function Loading(_ref) {
|
|
|
586
832
|
var _ref$size = _ref.size,
|
|
587
833
|
size = _ref$size === void 0 ? 'small' : _ref$size,
|
|
588
834
|
exceptionallySetClassName = _ref.exceptionallySetClassName,
|
|
589
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
835
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$a);
|
|
590
836
|
|
|
591
837
|
var numericSize = (_sizeMapping$size = sizeMapping[size]) !== null && _sizeMapping$size !== void 0 ? _sizeMapping$size : sizeMapping.small;
|
|
838
|
+
var ariaLabel = props['aria-label'] ? props['aria-label'] : !props['aria-labelledby'] ? 'Loading…' : undefined;
|
|
592
839
|
return /*#__PURE__*/React__default.createElement(Box, Object.assign({}, props, {
|
|
840
|
+
"aria-label": ariaLabel,
|
|
593
841
|
className: exceptionallySetClassName,
|
|
594
842
|
display: "flex",
|
|
595
843
|
alignItems: "center",
|
|
596
844
|
justifyContent: "center",
|
|
597
845
|
role: "progressbar"
|
|
598
846
|
}), /*#__PURE__*/React__default.createElement(Spinner, {
|
|
599
|
-
size: numericSize
|
|
847
|
+
size: numericSize,
|
|
848
|
+
"aria-hidden": true
|
|
600
849
|
}));
|
|
601
850
|
}
|
|
602
851
|
|
|
@@ -618,11 +867,14 @@ function Notice(_ref) {
|
|
|
618
867
|
width: "content"
|
|
619
868
|
}, /*#__PURE__*/React.createElement(AlertIcon, {
|
|
620
869
|
tone: tone
|
|
621
|
-
})), /*#__PURE__*/React.createElement(Column, null,
|
|
870
|
+
})), /*#__PURE__*/React.createElement(Column, null, /*#__PURE__*/React.createElement(Box, {
|
|
871
|
+
paddingY: "xsmall"
|
|
872
|
+
}, children))));
|
|
622
873
|
}
|
|
623
874
|
|
|
624
|
-
var modules_949d2ff4 = {"heading":"
|
|
875
|
+
var modules_949d2ff4 = {"heading":"_71a1610c","weight-light":"_63750f40","tone-secondary":"_9ce984cf","tone-danger":"_1acad35e","size-largest":"_3da27a00","size-larger":"df220733","size-smaller":"eb373739","lineClampMultipleLines":"f53cfd2b","lineClamp-1":"e4819fc9","lineClamp-2":"a0ed6177","lineClamp-3":"_180d433e","lineClamp-4":"_40826ad9","lineClamp-5":"_5999b247"};
|
|
625
876
|
|
|
877
|
+
var _excluded$b = ["level", "weight", "size", "tone", "children", "lineClamp", "align", "exceptionallySetClassName"];
|
|
626
878
|
var Heading = /*#__PURE__*/React.forwardRef(function Heading(_ref, ref) {
|
|
627
879
|
var level = _ref.level,
|
|
628
880
|
_ref$weight = _ref.weight,
|
|
@@ -631,261 +883,56 @@ var Heading = /*#__PURE__*/React.forwardRef(function Heading(_ref, ref) {
|
|
|
631
883
|
_ref$tone = _ref.tone,
|
|
632
884
|
tone = _ref$tone === void 0 ? 'normal' : _ref$tone,
|
|
633
885
|
children = _ref.children,
|
|
634
|
-
lineClamp = _ref.lineClamp,
|
|
635
|
-
align = _ref.align,
|
|
636
|
-
exceptionallySetClassName = _ref.exceptionallySetClassName,
|
|
637
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
638
|
-
|
|
639
|
-
// In TypeScript v4.1, this would be properly recognized without needing the type assertion
|
|
640
|
-
// https://devblogs.microsoft.com/typescript/announcing-typescript-4-1-beta/#template-literal-types
|
|
641
|
-
var headingElementName = "h" + level;
|
|
642
|
-
var lineClampMultipleLines = typeof lineClamp === 'string' ? parseInt(lineClamp, 10) > 1 : (lineClamp || 0) > 1;
|
|
643
|
-
return /*#__PURE__*/React.createElement(Box, Object.assign({}, props, {
|
|
644
|
-
className: [exceptionallySetClassName, modules_949d2ff4.heading, weight !== 'regular' ? getClassNames(modules_949d2ff4, 'weight', weight) : null, tone !== 'normal' ? getClassNames(modules_949d2ff4, 'tone', tone) : null, getClassNames(modules_949d2ff4, 'size', size), lineClampMultipleLines ? modules_949d2ff4.lineClampMultipleLines : null, lineClamp ? getClassNames(modules_949d2ff4, 'lineClamp', lineClamp.toString()) : null],
|
|
645
|
-
textAlign: align,
|
|
646
|
-
// Prevents emojis from being cut-off
|
|
647
|
-
// See https://github.com/Doist/reactist/pull/528
|
|
648
|
-
paddingRight: lineClamp ? 'xsmall' : undefined,
|
|
649
|
-
as: headingElementName,
|
|
650
|
-
ref: ref
|
|
651
|
-
}), children);
|
|
652
|
-
});
|
|
653
|
-
|
|
654
|
-
var modules_a9637dd3 = {"text":"c12d1277","size-caption":"c88e1204","size-copy":"_426d67ec","size-subtitle":"f978d6c7","weight-semibold":"_0c31eccd","weight-bold":"aba17bdd","tone-secondary":"_2767b43d","tone-danger":"e8ae531e","lineClampMultipleLines":"dc839422","lineClamp-1":"e2d23135","lineClamp-2":"_7c778b7e","lineClamp-3":"_5ff41166","lineClamp-4":"b7a4998e","lineClamp-5":"_6a7f8803"};
|
|
655
|
-
|
|
656
|
-
var Text = /*#__PURE__*/polymorphicComponent(function Text(_ref, ref) {
|
|
657
|
-
var as = _ref.as,
|
|
658
|
-
_ref$size = _ref.size,
|
|
659
|
-
size = _ref$size === void 0 ? 'body' : _ref$size,
|
|
660
|
-
_ref$weight = _ref.weight,
|
|
661
|
-
weight = _ref$weight === void 0 ? 'regular' : _ref$weight,
|
|
662
|
-
_ref$tone = _ref.tone,
|
|
663
|
-
tone = _ref$tone === void 0 ? 'normal' : _ref$tone,
|
|
664
|
-
align = _ref.align,
|
|
665
|
-
children = _ref.children,
|
|
666
|
-
lineClamp = _ref.lineClamp,
|
|
667
|
-
exceptionallySetClassName = _ref.exceptionallySetClassName,
|
|
668
|
-
props = _objectWithoutPropertiesLoose(_ref, ["as", "size", "weight", "tone", "align", "children", "lineClamp", "exceptionallySetClassName"]);
|
|
669
|
-
|
|
670
|
-
var lineClampMultipleLines = typeof lineClamp === 'string' ? Number(lineClamp) > 1 : (lineClamp !== null && lineClamp !== void 0 ? lineClamp : 1) > 1;
|
|
671
|
-
return /*#__PURE__*/React.createElement(Box, Object.assign({}, props, {
|
|
672
|
-
as: as,
|
|
673
|
-
className: [exceptionallySetClassName, modules_a9637dd3.text, size !== 'body' ? getClassNames(modules_a9637dd3, 'size', size) : null, weight !== 'regular' ? getClassNames(modules_a9637dd3, 'weight', weight) : null, tone !== 'normal' ? getClassNames(modules_a9637dd3, 'tone', tone) : null, lineClampMultipleLines ? modules_a9637dd3.lineClampMultipleLines : null, lineClamp ? getClassNames(modules_a9637dd3, 'lineClamp', lineClamp.toString()) : null],
|
|
674
|
-
textAlign: align,
|
|
675
|
-
// Prevents emojis from being cut-off
|
|
676
|
-
// See https://github.com/Doist/reactist/pull/528
|
|
677
|
-
paddingRight: lineClamp ? 'xsmall' : undefined,
|
|
678
|
-
ref: ref
|
|
679
|
-
}), children);
|
|
680
|
-
});
|
|
681
|
-
|
|
682
|
-
var SHOW_DELAY = 500;
|
|
683
|
-
var HIDE_DELAY = 100;
|
|
684
|
-
|
|
685
|
-
function useDelayedTooltipState(initialState) {
|
|
686
|
-
var tooltipState = Tooltip$1.useTooltipState(initialState);
|
|
687
|
-
var delay = useDelay();
|
|
688
|
-
return React__default.useMemo(function () {
|
|
689
|
-
return _objectSpread2(_objectSpread2({}, tooltipState), {}, {
|
|
690
|
-
show: delay(function () {
|
|
691
|
-
return tooltipState.show();
|
|
692
|
-
}, SHOW_DELAY),
|
|
693
|
-
hide: delay(function () {
|
|
694
|
-
return tooltipState.hide();
|
|
695
|
-
}, HIDE_DELAY)
|
|
696
|
-
});
|
|
697
|
-
}, [delay, tooltipState]);
|
|
698
|
-
}
|
|
699
|
-
|
|
700
|
-
function Tooltip(_ref) {
|
|
701
|
-
var children = _ref.children,
|
|
702
|
-
content = _ref.content,
|
|
703
|
-
_ref$position = _ref.position,
|
|
704
|
-
position = _ref$position === void 0 ? 'top' : _ref$position,
|
|
705
|
-
_ref$gapSize = _ref.gapSize,
|
|
706
|
-
gapSize = _ref$gapSize === void 0 ? 3 : _ref$gapSize,
|
|
707
|
-
className = _ref.className,
|
|
708
|
-
props = _objectWithoutPropertiesLoose(_ref, ["children", "content", "position", "gapSize", "className"]);
|
|
709
|
-
|
|
710
|
-
var tooltip = useDelayedTooltipState({
|
|
711
|
-
placement: position,
|
|
712
|
-
gutter: gapSize
|
|
713
|
-
});
|
|
714
|
-
var child = React__default.Children.only(children);
|
|
715
|
-
|
|
716
|
-
if (!content) {
|
|
717
|
-
return child;
|
|
718
|
-
}
|
|
719
|
-
/**
|
|
720
|
-
* Prevents the tooltip from automatically firing on focus all the time. This is to prevent
|
|
721
|
-
* tooltips from showing when the trigger element is focused back after a popover or dialog that
|
|
722
|
-
* it opened was closed. See link below for more details.
|
|
723
|
-
* @see https://github.com/reakit/reakit/discussions/749
|
|
724
|
-
*/
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
function handleFocus(event) {
|
|
728
|
-
// If focus is not followed by a key up event, does it mean that it's not
|
|
729
|
-
// an intentional keyboard focus? Not sure but it seems to work.
|
|
730
|
-
// This may be resolved soon in an upcoming version of reakit:
|
|
731
|
-
// https://github.com/reakit/reakit/issues/750
|
|
732
|
-
function handleKeyUp(e) {
|
|
733
|
-
var eventKey = e.key;
|
|
734
|
-
|
|
735
|
-
if (eventKey !== 'Escape' && eventKey !== 'Enter' && eventKey !== 'Space') {
|
|
736
|
-
tooltip.show();
|
|
737
|
-
}
|
|
738
|
-
}
|
|
739
|
-
|
|
740
|
-
event.currentTarget.addEventListener('keyup', handleKeyUp, {
|
|
741
|
-
once: true
|
|
742
|
-
}); // Prevent tooltip.show from being called by TooltipReference
|
|
743
|
-
|
|
744
|
-
event.preventDefault(); // eslint-disable-next-line @typescript-eslint/no-unsafe-call, @typescript-eslint/no-unsafe-member-access
|
|
745
|
-
|
|
746
|
-
if (typeof child.props.onFocus === 'function') child.props.onFocus(event);
|
|
747
|
-
}
|
|
748
|
-
|
|
749
|
-
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(Tooltip$1.TooltipReference, Object.assign({}, tooltip, {
|
|
750
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/no-unsafe-member-access, @typescript-eslint/no-unsafe-assignment
|
|
751
|
-
ref: child.ref
|
|
752
|
-
}, child.props, {
|
|
753
|
-
onFocus: handleFocus
|
|
754
|
-
}), function (referenceProps) {
|
|
755
|
-
return /*#__PURE__*/React__default.cloneElement(child, referenceProps);
|
|
756
|
-
}), tooltip.visible ? /*#__PURE__*/React__default.createElement(Tooltip$1.Tooltip, Object.assign({}, tooltip, props, {
|
|
757
|
-
className: classNames('reactist_tooltip', className)
|
|
758
|
-
}), typeof content === 'function' ? content() : content) : null);
|
|
759
|
-
}
|
|
760
|
-
// Internal helpers
|
|
761
|
-
//
|
|
762
|
-
|
|
763
|
-
/**
|
|
764
|
-
* Returns a function offering the same interface as setTimeout, but cleans up on unmount.
|
|
765
|
-
*
|
|
766
|
-
* The timeout state is shared, and only one delayed function can be active at any given time. If
|
|
767
|
-
* a new delayed function is called while another one was waiting for its time to run, that older
|
|
768
|
-
* invocation is cleared and it never runs.
|
|
769
|
-
*
|
|
770
|
-
* This is suitable for our use case here, but probably not the most intuitive thing in general.
|
|
771
|
-
* That's why this is not made a shared util or something like it.
|
|
772
|
-
*/
|
|
773
|
-
|
|
774
|
-
function useDelay() {
|
|
775
|
-
var timeoutRef = React__default.useRef();
|
|
776
|
-
var clearTimeouts = React__default.useCallback(function clearTimeouts() {
|
|
777
|
-
if (timeoutRef.current != null) {
|
|
778
|
-
clearTimeout(timeoutRef.current);
|
|
779
|
-
}
|
|
780
|
-
}, []); // Runs clearTimeouts when the component is unmounted
|
|
781
|
-
|
|
782
|
-
React__default.useEffect(function () {
|
|
783
|
-
return clearTimeouts;
|
|
784
|
-
}, [clearTimeouts]);
|
|
785
|
-
return React__default.useCallback(function delay(fn, delay) {
|
|
786
|
-
return function () {
|
|
787
|
-
clearTimeouts();
|
|
788
|
-
timeoutRef.current = setTimeout(fn, delay);
|
|
789
|
-
};
|
|
790
|
-
}, [clearTimeouts]);
|
|
791
|
-
}
|
|
792
|
-
|
|
793
|
-
var modules_b9569bce = {"label":"_1f20c88a","baseButton":"_623015f3","size-small":"_062de645","size-normal":"_55e2a6a9","size-large":"cab32a7c","disabled":"e71c191a","iconButton":"_368efc16","startIcon":"d35389c1","endIcon":"_900d41d8","variant-primary":"_7c95e162","variant-secondary":"_9cb889aa","variant-tertiary":"_611b5b28","variant-quaternary":"_80c2bb84","tone-destructive":"ee13c455"};
|
|
794
|
-
|
|
795
|
-
function preventDefault(event) {
|
|
796
|
-
event.preventDefault();
|
|
797
|
-
}
|
|
798
|
-
/**
|
|
799
|
-
* The component that powers `Button` and `ButtonLink`, where the button styling logic and some
|
|
800
|
-
* common functionality resides. This component is internal to Reactist.
|
|
801
|
-
*
|
|
802
|
-
* 🎨 [Figma](https://www.figma.com/file/LYlWNzvhMDh907l07mPPQk/Product-Web?node-id=4693%3A175143)
|
|
803
|
-
*
|
|
804
|
-
* @see Button
|
|
805
|
-
* @see ButtonLink
|
|
806
|
-
*/
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
var BaseButton = /*#__PURE__*/polymorphicComponent(function BaseButton(_ref, ref) {
|
|
810
|
-
var _ref$as = _ref.as,
|
|
811
|
-
as = _ref$as === void 0 ? 'div' : _ref$as,
|
|
812
|
-
variant = _ref.variant,
|
|
813
|
-
_ref$tone = _ref.tone,
|
|
814
|
-
tone = _ref$tone === void 0 ? 'normal' : _ref$tone,
|
|
815
|
-
_ref$size = _ref.size,
|
|
816
|
-
size = _ref$size === void 0 ? 'normal' : _ref$size,
|
|
817
|
-
_ref$disabled = _ref.disabled,
|
|
818
|
-
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
|
|
819
|
-
_ref$loading = _ref.loading,
|
|
820
|
-
loading = _ref$loading === void 0 ? false : _ref$loading,
|
|
821
|
-
tooltip = _ref.tooltip,
|
|
822
|
-
onClick = _ref.onClick,
|
|
823
|
-
exceptionallySetClassName = _ref.exceptionallySetClassName,
|
|
824
|
-
children = _ref.children,
|
|
825
|
-
startIcon = _ref.startIcon,
|
|
826
|
-
endIcon = _ref.endIcon,
|
|
827
|
-
icon = _ref.icon,
|
|
828
|
-
props = _objectWithoutPropertiesLoose(_ref, ["as", "variant", "tone", "size", "disabled", "loading", "tooltip", "onClick", "exceptionallySetClassName", "children", "startIcon", "endIcon", "icon"]);
|
|
829
|
-
|
|
830
|
-
var isDisabled = loading || disabled;
|
|
831
|
-
var buttonElement = /*#__PURE__*/React.createElement(Box, Object.assign({}, props, {
|
|
832
|
-
as: as,
|
|
833
|
-
ref: ref,
|
|
834
|
-
"aria-disabled": isDisabled,
|
|
835
|
-
onClick: isDisabled ? preventDefault : onClick,
|
|
836
|
-
className: [exceptionallySetClassName, modules_b9569bce.baseButton, modules_b9569bce["variant-" + variant], modules_b9569bce["tone-" + tone], modules_b9569bce["size-" + size], icon ? modules_b9569bce.iconButton : null, disabled ? modules_b9569bce.disabled : null]
|
|
837
|
-
}), icon ? loading && /*#__PURE__*/React.createElement(Spinner, null) || icon : /*#__PURE__*/React.createElement(React.Fragment, null, startIcon ? /*#__PURE__*/React.createElement(Box, {
|
|
838
|
-
display: "flex",
|
|
839
|
-
className: modules_b9569bce.startIcon,
|
|
840
|
-
"aria-hidden": true
|
|
841
|
-
}, loading && !endIcon ? /*#__PURE__*/React.createElement(Spinner, null) : startIcon) : null, children ? /*#__PURE__*/React.createElement("span", {
|
|
842
|
-
className: modules_b9569bce.label
|
|
843
|
-
}, children) : null, endIcon || loading && !startIcon ? /*#__PURE__*/React.createElement(Box, {
|
|
844
|
-
display: "flex",
|
|
845
|
-
className: modules_b9569bce.endIcon,
|
|
846
|
-
"aria-hidden": true
|
|
847
|
-
}, loading ? /*#__PURE__*/React.createElement(Spinner, null) : endIcon) : null)); // If it's an icon-only button, make sure it uses the aria-label as tooltip if no tooltip was provided
|
|
886
|
+
lineClamp = _ref.lineClamp,
|
|
887
|
+
align = _ref.align,
|
|
888
|
+
exceptionallySetClassName = _ref.exceptionallySetClassName,
|
|
889
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$b);
|
|
848
890
|
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
891
|
+
// In TypeScript v4.1, this would be properly recognized without needing the type assertion
|
|
892
|
+
// https://devblogs.microsoft.com/typescript/announcing-typescript-4-1-beta/#template-literal-types
|
|
893
|
+
var headingElementName = "h" + level;
|
|
894
|
+
var lineClampMultipleLines = typeof lineClamp === 'string' ? parseInt(lineClamp, 10) > 1 : (lineClamp || 0) > 1;
|
|
895
|
+
return /*#__PURE__*/React.createElement(Box, Object.assign({}, props, {
|
|
896
|
+
className: [exceptionallySetClassName, modules_949d2ff4.heading, weight !== 'regular' ? getClassNames(modules_949d2ff4, 'weight', weight) : null, tone !== 'normal' ? getClassNames(modules_949d2ff4, 'tone', tone) : null, getClassNames(modules_949d2ff4, 'size', size), lineClampMultipleLines ? modules_949d2ff4.lineClampMultipleLines : null, lineClamp ? getClassNames(modules_949d2ff4, 'lineClamp', lineClamp.toString()) : null],
|
|
897
|
+
textAlign: align,
|
|
898
|
+
// Prevents emojis from being cut-off
|
|
899
|
+
// See https://github.com/Doist/reactist/pull/528
|
|
900
|
+
paddingRight: lineClamp ? 'xsmall' : undefined,
|
|
901
|
+
as: headingElementName,
|
|
902
|
+
ref: ref
|
|
903
|
+
}), children);
|
|
853
904
|
});
|
|
854
905
|
|
|
855
|
-
|
|
856
|
-
* A semantic button that also looks like a button, and provides all the necessary visual variants.
|
|
857
|
-
* It follows the [WAI-ARIA Button Pattern](https://www.w3.org/TR/wai-aria-practices/#button).
|
|
858
|
-
*
|
|
859
|
-
* 🎨 [Figma](https://www.figma.com/file/LYlWNzvhMDh907l07mPPQk/Product-Web?node-id=4693%3A175143)
|
|
860
|
-
*
|
|
861
|
-
* @see ButtonLink
|
|
862
|
-
*/
|
|
906
|
+
var modules_a9637dd3 = {"text":"c5028ea8","size-caption":"_05d3a546","size-copy":"_100565e3","size-subtitle":"b8f72625","weight-semibold":"_398ecda1","weight-bold":"_8054cd6b","tone-secondary":"_6abd56b1","tone-danger":"_274b4a47","lineClampMultipleLines":"_724b0054","lineClamp-1":"_51ac6ee4","lineClamp-2":"b0742803","lineClamp-3":"dd664c95","lineClamp-4":"b02775b5","lineClamp-5":"da91b300"};
|
|
863
907
|
|
|
864
|
-
var
|
|
865
|
-
|
|
908
|
+
var _excluded$c = ["as", "size", "weight", "tone", "align", "children", "lineClamp", "exceptionallySetClassName"];
|
|
909
|
+
var Text = /*#__PURE__*/polymorphicComponent(function Text(_ref, ref) {
|
|
910
|
+
var as = _ref.as,
|
|
911
|
+
_ref$size = _ref.size,
|
|
912
|
+
size = _ref$size === void 0 ? 'body' : _ref$size,
|
|
913
|
+
_ref$weight = _ref.weight,
|
|
914
|
+
weight = _ref$weight === void 0 ? 'regular' : _ref$weight,
|
|
866
915
|
_ref$tone = _ref.tone,
|
|
867
916
|
tone = _ref$tone === void 0 ? 'normal' : _ref$tone,
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
type = _ref$type === void 0 ? 'button' : _ref$type,
|
|
872
|
-
_ref$disabled = _ref.disabled,
|
|
873
|
-
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
|
|
917
|
+
align = _ref.align,
|
|
918
|
+
children = _ref.children,
|
|
919
|
+
lineClamp = _ref.lineClamp,
|
|
874
920
|
exceptionallySetClassName = _ref.exceptionallySetClassName,
|
|
875
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
921
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$c);
|
|
876
922
|
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
}));
|
|
923
|
+
var lineClampMultipleLines = typeof lineClamp === 'string' ? Number(lineClamp) > 1 : (lineClamp !== null && lineClamp !== void 0 ? lineClamp : 1) > 1;
|
|
924
|
+
return /*#__PURE__*/React.createElement(Box, Object.assign({}, props, {
|
|
925
|
+
as: as,
|
|
926
|
+
className: [exceptionallySetClassName, modules_a9637dd3.text, size !== 'body' ? getClassNames(modules_a9637dd3, 'size', size) : null, weight !== 'regular' ? getClassNames(modules_a9637dd3, 'weight', weight) : null, tone !== 'normal' ? getClassNames(modules_a9637dd3, 'tone', tone) : null, lineClampMultipleLines ? modules_a9637dd3.lineClampMultipleLines : null, lineClamp ? getClassNames(modules_a9637dd3, 'lineClamp', lineClamp.toString()) : null],
|
|
927
|
+
textAlign: align,
|
|
928
|
+
// Prevents emojis from being cut-off
|
|
929
|
+
// See https://github.com/Doist/reactist/pull/528
|
|
930
|
+
paddingRight: lineClamp ? 'xsmall' : undefined,
|
|
931
|
+
ref: ref
|
|
932
|
+
}), children);
|
|
887
933
|
});
|
|
888
934
|
|
|
935
|
+
var _excluded$d = ["as", "variant", "tone", "size", "exceptionallySetClassName", "openInNewTab"];
|
|
889
936
|
/**
|
|
890
937
|
* A semantic link that looks like a button, exactly matching the `Button` component in all visual
|
|
891
938
|
* aspects.
|
|
@@ -906,7 +953,7 @@ var ButtonLink = /*#__PURE__*/polymorphicComponent(function ButtonLink(_ref, ref
|
|
|
906
953
|
exceptionallySetClassName = _ref.exceptionallySetClassName,
|
|
907
954
|
_ref$openInNewTab = _ref.openInNewTab,
|
|
908
955
|
openInNewTab = _ref$openInNewTab === void 0 ? false : _ref$openInNewTab,
|
|
909
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
956
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$d);
|
|
910
957
|
|
|
911
958
|
return /*#__PURE__*/React.createElement(BaseButton, Object.assign({}, props, {
|
|
912
959
|
as: as,
|
|
@@ -920,15 +967,16 @@ var ButtonLink = /*#__PURE__*/polymorphicComponent(function ButtonLink(_ref, ref
|
|
|
920
967
|
}));
|
|
921
968
|
});
|
|
922
969
|
|
|
923
|
-
var modules_3d05deee = {"container":"
|
|
970
|
+
var modules_3d05deee = {"container":"b55607a1"};
|
|
924
971
|
|
|
972
|
+
var _excluded$e = ["as", "openInNewTab", "exceptionallySetClassName"];
|
|
925
973
|
var TextLink = /*#__PURE__*/polymorphicComponent(function TextLink(_ref, ref) {
|
|
926
974
|
var _ref$as = _ref.as,
|
|
927
975
|
as = _ref$as === void 0 ? 'a' : _ref$as,
|
|
928
976
|
_ref$openInNewTab = _ref.openInNewTab,
|
|
929
977
|
openInNewTab = _ref$openInNewTab === void 0 ? false : _ref$openInNewTab,
|
|
930
978
|
exceptionallySetClassName = _ref.exceptionallySetClassName,
|
|
931
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
979
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$e);
|
|
932
980
|
|
|
933
981
|
return /*#__PURE__*/React.createElement(Box, Object.assign({}, props, {
|
|
934
982
|
as: as,
|
|
@@ -940,6 +988,7 @@ var TextLink = /*#__PURE__*/polymorphicComponent(function TextLink(_ref, ref) {
|
|
|
940
988
|
}));
|
|
941
989
|
});
|
|
942
990
|
|
|
991
|
+
var _excluded$f = ["checked", "indeterminate", "disabled"];
|
|
943
992
|
var svgPath = {
|
|
944
993
|
checked: 'M18 4a2 2 0 0 1 2 2v12a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h12zm-2.457 4.293l-5.293 5.293-1.793-1.793a1 1 0 1 0-1.414 1.414l2.5 2.5a1 1 0 0 0 1.414 0l6-6a1 1 0 1 0-1.414-1.414z',
|
|
945
994
|
unchecked: 'M18 4a2 2 0 0 1 2 2v12a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h12zm0 1H6a1 1 0 0 0-1 1v12a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1V6a1 1 0 0 0-1-1z',
|
|
@@ -976,7 +1025,7 @@ function CheckboxIcon(_ref2) {
|
|
|
976
1025
|
var checked = _ref2.checked,
|
|
977
1026
|
indeterminate = _ref2.indeterminate,
|
|
978
1027
|
disabled = _ref2.disabled,
|
|
979
|
-
props = _objectWithoutPropertiesLoose(_ref2,
|
|
1028
|
+
props = _objectWithoutPropertiesLoose(_ref2, _excluded$f);
|
|
980
1029
|
|
|
981
1030
|
var pathKey = getPathKey({
|
|
982
1031
|
checked: checked,
|
|
@@ -995,8 +1044,9 @@ function CheckboxIcon(_ref2) {
|
|
|
995
1044
|
}));
|
|
996
1045
|
}
|
|
997
1046
|
|
|
998
|
-
var modules_664a6a80 = {"container":"
|
|
1047
|
+
var modules_664a6a80 = {"container":"_96c4d12f","disabled":"_5048e2a5","checked":"_42187b48","keyFocused":"_3510166f"};
|
|
999
1048
|
|
|
1049
|
+
var _excluded$g = ["label", "disabled", "indeterminate", "defaultChecked", "onChange"];
|
|
1000
1050
|
var CheckboxField = /*#__PURE__*/React.forwardRef(function CheckboxField(_ref, ref) {
|
|
1001
1051
|
var _ref2, _props$checked, _props$checked2;
|
|
1002
1052
|
|
|
@@ -1005,7 +1055,7 @@ var CheckboxField = /*#__PURE__*/React.forwardRef(function CheckboxField(_ref, r
|
|
|
1005
1055
|
indeterminate = _ref.indeterminate,
|
|
1006
1056
|
defaultChecked = _ref.defaultChecked,
|
|
1007
1057
|
_onChange = _ref.onChange,
|
|
1008
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
1058
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$g);
|
|
1009
1059
|
|
|
1010
1060
|
var isControlledComponent = typeof props.checked === 'boolean';
|
|
1011
1061
|
|
|
@@ -1020,9 +1070,13 @@ var CheckboxField = /*#__PURE__*/React.forwardRef(function CheckboxField(_ref, r
|
|
|
1020
1070
|
console.warn('A Checkbox needs a label');
|
|
1021
1071
|
}
|
|
1022
1072
|
|
|
1023
|
-
var _React$useState = React.useState(
|
|
1024
|
-
|
|
1025
|
-
|
|
1073
|
+
var _React$useState = React.useState(false),
|
|
1074
|
+
keyFocused = _React$useState[0],
|
|
1075
|
+
setKeyFocused = _React$useState[1];
|
|
1076
|
+
|
|
1077
|
+
var _React$useState2 = React.useState((_ref2 = (_props$checked = props.checked) !== null && _props$checked !== void 0 ? _props$checked : defaultChecked) !== null && _ref2 !== void 0 ? _ref2 : false),
|
|
1078
|
+
checkedState = _React$useState2[0],
|
|
1079
|
+
setChecked = _React$useState2[1];
|
|
1026
1080
|
|
|
1027
1081
|
var isChecked = (_props$checked2 = props.checked) !== null && _props$checked2 !== void 0 ? _props$checked2 : checkedState;
|
|
1028
1082
|
var internalRef = React.useRef(null);
|
|
@@ -1036,10 +1090,11 @@ var CheckboxField = /*#__PURE__*/React.forwardRef(function CheckboxField(_ref, r
|
|
|
1036
1090
|
as: "label",
|
|
1037
1091
|
display: "flex",
|
|
1038
1092
|
alignItems: "center",
|
|
1039
|
-
className: [modules_664a6a80.container, disabled ? modules_664a6a80.disabled : null, isChecked ? modules_664a6a80.checked : null,
|
|
1040
|
-
}, /*#__PURE__*/React.createElement(
|
|
1093
|
+
className: [modules_664a6a80.container, disabled ? modules_664a6a80.disabled : null, isChecked ? modules_664a6a80.checked : null, keyFocused ? modules_664a6a80.keyFocused : null]
|
|
1094
|
+
}, /*#__PURE__*/React.createElement("input", Object.assign({}, props, {
|
|
1041
1095
|
ref: combinedRef,
|
|
1042
1096
|
type: "checkbox",
|
|
1097
|
+
"aria-checked": indeterminate ? 'mixed' : isChecked,
|
|
1043
1098
|
checked: isChecked,
|
|
1044
1099
|
disabled: disabled,
|
|
1045
1100
|
onChange: function onChange(event) {
|
|
@@ -1048,12 +1103,24 @@ var CheckboxField = /*#__PURE__*/React.forwardRef(function CheckboxField(_ref, r
|
|
|
1048
1103
|
if (!event.defaultPrevented) {
|
|
1049
1104
|
setChecked(event.currentTarget.checked);
|
|
1050
1105
|
}
|
|
1106
|
+
},
|
|
1107
|
+
onBlur: function onBlur(event) {
|
|
1108
|
+
var _props$onBlur;
|
|
1109
|
+
|
|
1110
|
+
setKeyFocused(false);
|
|
1111
|
+
props === null || props === void 0 ? void 0 : (_props$onBlur = props.onBlur) === null || _props$onBlur === void 0 ? void 0 : _props$onBlur.call(props, event);
|
|
1112
|
+
},
|
|
1113
|
+
onKeyUp: function onKeyUp(event) {
|
|
1114
|
+
var _props$onKeyUp;
|
|
1115
|
+
|
|
1116
|
+
setKeyFocused(true);
|
|
1117
|
+
props === null || props === void 0 ? void 0 : (_props$onKeyUp = props.onKeyUp) === null || _props$onKeyUp === void 0 ? void 0 : _props$onKeyUp.call(props, event);
|
|
1051
1118
|
}
|
|
1052
|
-
}))
|
|
1053
|
-
"aria-hidden": true,
|
|
1119
|
+
})), /*#__PURE__*/React.createElement(CheckboxIcon, {
|
|
1054
1120
|
checked: isChecked,
|
|
1121
|
+
disabled: disabled,
|
|
1055
1122
|
indeterminate: indeterminate,
|
|
1056
|
-
|
|
1123
|
+
"aria-hidden": true
|
|
1057
1124
|
}), label ? /*#__PURE__*/React.createElement(Text, null, label) : null);
|
|
1058
1125
|
});
|
|
1059
1126
|
|
|
@@ -1182,6 +1249,7 @@ var modules_3f03ead6 = {"inputWrapper":"_460d581b"};
|
|
|
1182
1249
|
|
|
1183
1250
|
var modules_aaf25250 = {"inputWrapper":"dd9ffeab"};
|
|
1184
1251
|
|
|
1252
|
+
var _excluded$h = ["label", "secondaryLabel", "auxiliaryLabel", "hint", "maxWidth", "togglePasswordLabel", "hidden", "aria-describedby"];
|
|
1185
1253
|
var PasswordField = /*#__PURE__*/React.forwardRef(function PasswordField(_ref, ref) {
|
|
1186
1254
|
var label = _ref.label,
|
|
1187
1255
|
secondaryLabel = _ref.secondaryLabel,
|
|
@@ -1192,7 +1260,7 @@ var PasswordField = /*#__PURE__*/React.forwardRef(function PasswordField(_ref, r
|
|
|
1192
1260
|
togglePasswordLabel = _ref$togglePasswordLa === void 0 ? 'Toggle password visibility' : _ref$togglePasswordLa,
|
|
1193
1261
|
hidden = _ref.hidden,
|
|
1194
1262
|
ariaDescribedBy = _ref['aria-describedby'],
|
|
1195
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
1263
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$h);
|
|
1196
1264
|
|
|
1197
1265
|
var id = useId(props.id);
|
|
1198
1266
|
var internalRef = React.useRef(null);
|
|
@@ -1245,6 +1313,7 @@ var PasswordField = /*#__PURE__*/React.forwardRef(function PasswordField(_ref, r
|
|
|
1245
1313
|
|
|
1246
1314
|
var modules_1fa9b208 = {"selectWrapper":"_828e09c5"};
|
|
1247
1315
|
|
|
1316
|
+
var _excluded$i = ["id", "label", "secondaryLabel", "auxiliaryLabel", "hint", "maxWidth", "children", "hidden", "aria-describedby"];
|
|
1248
1317
|
var SelectField = /*#__PURE__*/React.forwardRef(function SelectField(_ref, ref) {
|
|
1249
1318
|
var id = _ref.id,
|
|
1250
1319
|
label = _ref.label,
|
|
@@ -1255,7 +1324,7 @@ var SelectField = /*#__PURE__*/React.forwardRef(function SelectField(_ref, ref)
|
|
|
1255
1324
|
children = _ref.children,
|
|
1256
1325
|
hidden = _ref.hidden,
|
|
1257
1326
|
ariaDescribedBy = _ref['aria-describedby'],
|
|
1258
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
1327
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$i);
|
|
1259
1328
|
|
|
1260
1329
|
return /*#__PURE__*/React.createElement(BaseField, {
|
|
1261
1330
|
id: id,
|
|
@@ -1289,8 +1358,9 @@ function SelectChevron(props) {
|
|
|
1289
1358
|
}));
|
|
1290
1359
|
}
|
|
1291
1360
|
|
|
1292
|
-
var modules_8e05f7c9 = {"container":"
|
|
1361
|
+
var modules_8e05f7c9 = {"container":"ec63c3f1","disabled":"_7de9c06d","checked":"a37981fc","toggle":"_2a17ac45","label":"_68cc9707","handle":"_91409c7f","keyFocused":"a6490371"};
|
|
1293
1362
|
|
|
1363
|
+
var _excluded$j = ["label", "hint", "disabled", "hidden", "defaultChecked", "id", "aria-describedby", "aria-label", "aria-labelledby", "onChange"];
|
|
1294
1364
|
var SwitchField = /*#__PURE__*/React.forwardRef(function SwitchField(_ref, ref) {
|
|
1295
1365
|
var _ref2, _props$checked, _props$checked2;
|
|
1296
1366
|
|
|
@@ -1302,23 +1372,31 @@ var SwitchField = /*#__PURE__*/React.forwardRef(function SwitchField(_ref, ref)
|
|
|
1302
1372
|
defaultChecked = _ref.defaultChecked,
|
|
1303
1373
|
originalId = _ref.id,
|
|
1304
1374
|
originalAriaDescribedBy = _ref['aria-describedby'],
|
|
1375
|
+
originalAriaLabel = _ref['aria-label'],
|
|
1376
|
+
originalAriaLabelledby = _ref['aria-labelledby'],
|
|
1305
1377
|
_onChange = _ref.onChange,
|
|
1306
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
1378
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$j);
|
|
1307
1379
|
|
|
1308
1380
|
var id = useId(originalId);
|
|
1309
1381
|
var hintId = useId();
|
|
1310
1382
|
var ariaDescribedBy = originalAriaDescribedBy !== null && originalAriaDescribedBy !== void 0 ? originalAriaDescribedBy : hint ? hintId : undefined;
|
|
1383
|
+
var ariaLabel = originalAriaLabel !== null && originalAriaLabel !== void 0 ? originalAriaLabel : undefined;
|
|
1384
|
+
var ariaLabelledBy = originalAriaLabelledby !== null && originalAriaLabelledby !== void 0 ? originalAriaLabelledby : undefined;
|
|
1385
|
+
|
|
1386
|
+
var _React$useState = React.useState(false),
|
|
1387
|
+
keyFocused = _React$useState[0],
|
|
1388
|
+
setKeyFocused = _React$useState[1];
|
|
1311
1389
|
|
|
1312
|
-
var _React$
|
|
1313
|
-
checkedState = _React$
|
|
1314
|
-
setChecked = _React$
|
|
1390
|
+
var _React$useState2 = React.useState((_ref2 = (_props$checked = props.checked) !== null && _props$checked !== void 0 ? _props$checked : defaultChecked) !== null && _ref2 !== void 0 ? _ref2 : false),
|
|
1391
|
+
checkedState = _React$useState2[0],
|
|
1392
|
+
setChecked = _React$useState2[1];
|
|
1315
1393
|
|
|
1316
1394
|
var isChecked = (_props$checked2 = props.checked) !== null && _props$checked2 !== void 0 ? _props$checked2 : checkedState;
|
|
1317
1395
|
return /*#__PURE__*/React.createElement(Stack, {
|
|
1318
1396
|
space: "small",
|
|
1319
1397
|
hidden: hidden
|
|
1320
1398
|
}, /*#__PURE__*/React.createElement(Box, {
|
|
1321
|
-
className: [modules_8e05f7c9.container, disabled ? modules_8e05f7c9.disabled : null, isChecked ? modules_8e05f7c9.checked : null],
|
|
1399
|
+
className: [modules_8e05f7c9.container, disabled ? modules_8e05f7c9.disabled : null, isChecked ? modules_8e05f7c9.checked : null, keyFocused ? modules_8e05f7c9.keyFocused : null],
|
|
1322
1400
|
as: "label",
|
|
1323
1401
|
display: "flex",
|
|
1324
1402
|
alignItems: "center"
|
|
@@ -1334,6 +1412,8 @@ var SwitchField = /*#__PURE__*/React.forwardRef(function SwitchField(_ref, ref)
|
|
|
1334
1412
|
type: "checkbox",
|
|
1335
1413
|
disabled: disabled,
|
|
1336
1414
|
"aria-describedby": ariaDescribedBy,
|
|
1415
|
+
"aria-label": ariaLabel,
|
|
1416
|
+
"aria-labelledby": ariaLabelledBy,
|
|
1337
1417
|
ref: ref,
|
|
1338
1418
|
checked: isChecked,
|
|
1339
1419
|
onChange: function onChange(event) {
|
|
@@ -1342,6 +1422,18 @@ var SwitchField = /*#__PURE__*/React.forwardRef(function SwitchField(_ref, ref)
|
|
|
1342
1422
|
if (!event.defaultPrevented) {
|
|
1343
1423
|
setChecked(event.currentTarget.checked);
|
|
1344
1424
|
}
|
|
1425
|
+
},
|
|
1426
|
+
onBlur: function onBlur(event) {
|
|
1427
|
+
var _props$onBlur;
|
|
1428
|
+
|
|
1429
|
+
setKeyFocused(false);
|
|
1430
|
+
props === null || props === void 0 ? void 0 : (_props$onBlur = props.onBlur) === null || _props$onBlur === void 0 ? void 0 : _props$onBlur.call(props, event);
|
|
1431
|
+
},
|
|
1432
|
+
onKeyUp: function onKeyUp(event) {
|
|
1433
|
+
var _props$onKeyUp;
|
|
1434
|
+
|
|
1435
|
+
setKeyFocused(true);
|
|
1436
|
+
props === null || props === void 0 ? void 0 : (_props$onKeyUp = props.onKeyUp) === null || _props$onKeyUp === void 0 ? void 0 : _props$onKeyUp.call(props, event);
|
|
1345
1437
|
}
|
|
1346
1438
|
}))), /*#__PURE__*/React.createElement("span", {
|
|
1347
1439
|
className: modules_8e05f7c9.handle
|
|
@@ -1354,6 +1446,8 @@ var SwitchField = /*#__PURE__*/React.forwardRef(function SwitchField(_ref, ref)
|
|
|
1354
1446
|
|
|
1355
1447
|
var modules_2728c236 = {"container":"_5a579f96"};
|
|
1356
1448
|
|
|
1449
|
+
var _excluded$k = ["id", "label", "secondaryLabel", "auxiliaryLabel", "hint", "maxWidth"];
|
|
1450
|
+
|
|
1357
1451
|
function TextArea(_ref) {
|
|
1358
1452
|
var id = _ref.id,
|
|
1359
1453
|
label = _ref.label,
|
|
@@ -1361,7 +1455,7 @@ function TextArea(_ref) {
|
|
|
1361
1455
|
auxiliaryLabel = _ref.auxiliaryLabel,
|
|
1362
1456
|
hint = _ref.hint,
|
|
1363
1457
|
maxWidth = _ref.maxWidth,
|
|
1364
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
1458
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$k);
|
|
1365
1459
|
|
|
1366
1460
|
return /*#__PURE__*/React.createElement(BaseField, {
|
|
1367
1461
|
id: id,
|
|
@@ -1378,6 +1472,7 @@ function TextArea(_ref) {
|
|
|
1378
1472
|
});
|
|
1379
1473
|
}
|
|
1380
1474
|
|
|
1475
|
+
var _excluded$l = ["id", "label", "secondaryLabel", "auxiliaryLabel", "hint", "type", "maxWidth", "hidden", "aria-describedby"];
|
|
1381
1476
|
var TextField = /*#__PURE__*/React.forwardRef(function TextField(_ref, ref) {
|
|
1382
1477
|
var id = _ref.id,
|
|
1383
1478
|
label = _ref.label,
|
|
@@ -1389,7 +1484,7 @@ var TextField = /*#__PURE__*/React.forwardRef(function TextField(_ref, ref) {
|
|
|
1389
1484
|
maxWidth = _ref.maxWidth,
|
|
1390
1485
|
hidden = _ref.hidden,
|
|
1391
1486
|
ariaDescribedBy = _ref['aria-describedby'],
|
|
1392
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
1487
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$l);
|
|
1393
1488
|
|
|
1394
1489
|
return /*#__PURE__*/React.createElement(BaseField, {
|
|
1395
1490
|
id: id,
|
|
@@ -1432,8 +1527,13 @@ function usePrevious(value) {
|
|
|
1432
1527
|
return ref.current;
|
|
1433
1528
|
}
|
|
1434
1529
|
|
|
1435
|
-
var modules_40c67f5b = {"tab":"
|
|
1530
|
+
var modules_40c67f5b = {"tab":"d7928f1c","tab-normal":"_5d8e72b3","tab-primary":"_8a23756d","tab-secondary":"_88fd4c95","tab-tertiary":"_40c4cce9","tab-plain":"_13722523"};
|
|
1436
1531
|
|
|
1532
|
+
var _excluded$m = ["color", "variant"],
|
|
1533
|
+
_excluded2$1 = ["children", "space"],
|
|
1534
|
+
_excluded3 = ["color", "variant"],
|
|
1535
|
+
_excluded4 = ["children", "id", "as", "render"],
|
|
1536
|
+
_excluded5 = ["color", "variant"];
|
|
1437
1537
|
var TabsContext = /*#__PURE__*/React.createContext(null);
|
|
1438
1538
|
/**
|
|
1439
1539
|
* Used to group components that compose a set of tabs. There can only be one active tab within the same `<Tabs>` group.
|
|
@@ -1485,7 +1585,7 @@ function Tab(_ref2) {
|
|
|
1485
1585
|
|
|
1486
1586
|
var color = tabContextValue.color,
|
|
1487
1587
|
variant = tabContextValue.variant,
|
|
1488
|
-
tabState = _objectWithoutPropertiesLoose(tabContextValue,
|
|
1588
|
+
tabState = _objectWithoutPropertiesLoose(tabContextValue, _excluded$m);
|
|
1489
1589
|
|
|
1490
1590
|
return /*#__PURE__*/React.createElement(Tab$1.Tab, Object.assign({
|
|
1491
1591
|
className: classNames(modules_40c67f5b.tab, modules_40c67f5b["tab-" + (variant !== null && variant !== void 0 ? variant : '')], modules_40c67f5b["tab-" + (color !== null && color !== void 0 ? color : '')]),
|
|
@@ -1500,7 +1600,7 @@ function TabList(_ref3) {
|
|
|
1500
1600
|
var children = _ref3.children,
|
|
1501
1601
|
_ref3$space = _ref3.space,
|
|
1502
1602
|
space = _ref3$space === void 0 ? 'medium' : _ref3$space,
|
|
1503
|
-
props = _objectWithoutPropertiesLoose(_ref3,
|
|
1603
|
+
props = _objectWithoutPropertiesLoose(_ref3, _excluded2$1);
|
|
1504
1604
|
|
|
1505
1605
|
var tabContextValue = React.useContext(TabsContext);
|
|
1506
1606
|
|
|
@@ -1508,7 +1608,7 @@ function TabList(_ref3) {
|
|
|
1508
1608
|
return null;
|
|
1509
1609
|
}
|
|
1510
1610
|
|
|
1511
|
-
var tabState = _objectWithoutPropertiesLoose(tabContextValue,
|
|
1611
|
+
var tabState = _objectWithoutPropertiesLoose(tabContextValue, _excluded3);
|
|
1512
1612
|
|
|
1513
1613
|
return /*#__PURE__*/React.createElement(Tab$1.TabList, Object.assign({}, props, tabState), /*#__PURE__*/React.createElement(Inline, {
|
|
1514
1614
|
space: space
|
|
@@ -1524,7 +1624,7 @@ var TabPanel = /*#__PURE__*/polymorphicComponent(function TabPanel(_ref4, ref) {
|
|
|
1524
1624
|
as = _ref4.as,
|
|
1525
1625
|
_ref4$render = _ref4.render,
|
|
1526
1626
|
render = _ref4$render === void 0 ? 'always' : _ref4$render,
|
|
1527
|
-
props = _objectWithoutPropertiesLoose(_ref4,
|
|
1627
|
+
props = _objectWithoutPropertiesLoose(_ref4, _excluded4);
|
|
1528
1628
|
|
|
1529
1629
|
var tabContextValue = React.useContext(TabsContext);
|
|
1530
1630
|
|
|
@@ -1543,7 +1643,7 @@ var TabPanel = /*#__PURE__*/polymorphicComponent(function TabPanel(_ref4, ref) {
|
|
|
1543
1643
|
return null;
|
|
1544
1644
|
}
|
|
1545
1645
|
|
|
1546
|
-
var tabState = _objectWithoutPropertiesLoose(tabContextValue,
|
|
1646
|
+
var tabState = _objectWithoutPropertiesLoose(tabContextValue, _excluded5);
|
|
1547
1647
|
|
|
1548
1648
|
return /*#__PURE__*/React.createElement(Tab$1.TabPanel, Object.assign({
|
|
1549
1649
|
tabId: id
|
|
@@ -1565,8 +1665,13 @@ function TabAwareSlot(_ref5) {
|
|
|
1565
1665
|
}) : null;
|
|
1566
1666
|
}
|
|
1567
1667
|
|
|
1568
|
-
var modules_8f59d13b = {"reach-portal":"
|
|
1668
|
+
var modules_8f59d13b = {"reach-portal":"dddb40c3","fadein":"_955f2d73","fitContent":"_95c7550e","container":"_88079712","full":"_4779d078","large":"_5fd86231","medium":"bdfb5931","small":"_4e848a11","xlarge":"d673fba2","overlay":"ea9ae0cc","expand":"a8bf8a4f","buttonContainer":"_44d6850e"};
|
|
1569
1669
|
|
|
1670
|
+
var _excluded$n = ["isOpen", "onDismiss", "height", "width", "exceptionallySetClassName", "autoFocus", "children"],
|
|
1671
|
+
_excluded2$2 = ["children", "button", "withDivider", "exceptionallySetClassName"],
|
|
1672
|
+
_excluded3$1 = ["exceptionallySetClassName", "children"],
|
|
1673
|
+
_excluded4$1 = ["exceptionallySetClassName", "withDivider"],
|
|
1674
|
+
_excluded5$1 = ["children"];
|
|
1570
1675
|
var ModalContext = /*#__PURE__*/React.createContext({
|
|
1571
1676
|
onDismiss: undefined,
|
|
1572
1677
|
height: 'fitContent'
|
|
@@ -1597,7 +1702,7 @@ function Modal(_ref) {
|
|
|
1597
1702
|
_ref$autoFocus = _ref.autoFocus,
|
|
1598
1703
|
autoFocus = _ref$autoFocus === void 0 ? true : _ref$autoFocus,
|
|
1599
1704
|
children = _ref.children,
|
|
1600
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
1705
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$n);
|
|
1601
1706
|
|
|
1602
1707
|
var contextValue = React.useMemo(function () {
|
|
1603
1708
|
return {
|
|
@@ -1614,7 +1719,8 @@ function Modal(_ref) {
|
|
|
1614
1719
|
"data-testid": "modal-overlay"
|
|
1615
1720
|
}, /*#__PURE__*/React.createElement(FocusLock, {
|
|
1616
1721
|
autoFocus: autoFocus,
|
|
1617
|
-
whiteList: isNotInternalFrame
|
|
1722
|
+
whiteList: isNotInternalFrame,
|
|
1723
|
+
returnFocus: true
|
|
1618
1724
|
}, /*#__PURE__*/React.createElement(dialog.DialogContent, Object.assign({}, props, {
|
|
1619
1725
|
as: Box,
|
|
1620
1726
|
borderRadius: "full",
|
|
@@ -1640,10 +1746,26 @@ function ModalCloseButton(props) {
|
|
|
1640
1746
|
var _React$useContext = React.useContext(ModalContext),
|
|
1641
1747
|
onDismiss = _React$useContext.onDismiss;
|
|
1642
1748
|
|
|
1749
|
+
var _React$useState = React.useState(false),
|
|
1750
|
+
includeInTabOrder = _React$useState[0],
|
|
1751
|
+
setIncludeInTabOrder = _React$useState[1];
|
|
1752
|
+
|
|
1753
|
+
var _React$useState2 = React.useState(false),
|
|
1754
|
+
isMounted = _React$useState2[0],
|
|
1755
|
+
setIsMounted = _React$useState2[1];
|
|
1756
|
+
|
|
1757
|
+
React.useEffect(function skipAutoFocus() {
|
|
1758
|
+
if (isMounted) {
|
|
1759
|
+
setIncludeInTabOrder(true);
|
|
1760
|
+
} else {
|
|
1761
|
+
setIsMounted(true);
|
|
1762
|
+
}
|
|
1763
|
+
}, [isMounted]);
|
|
1643
1764
|
return /*#__PURE__*/React.createElement(Button, Object.assign({}, props, {
|
|
1644
1765
|
variant: "quaternary",
|
|
1645
1766
|
onClick: onDismiss,
|
|
1646
|
-
icon: /*#__PURE__*/React.createElement(CloseIcon, null)
|
|
1767
|
+
icon: /*#__PURE__*/React.createElement(CloseIcon, null),
|
|
1768
|
+
tabIndex: includeInTabOrder ? 0 : -1
|
|
1647
1769
|
}));
|
|
1648
1770
|
}
|
|
1649
1771
|
/**
|
|
@@ -1661,7 +1783,7 @@ function ModalHeader(_ref2) {
|
|
|
1661
1783
|
_ref2$withDivider = _ref2.withDivider,
|
|
1662
1784
|
withDivider = _ref2$withDivider === void 0 ? false : _ref2$withDivider,
|
|
1663
1785
|
exceptionallySetClassName = _ref2.exceptionallySetClassName,
|
|
1664
|
-
props = _objectWithoutPropertiesLoose(_ref2,
|
|
1786
|
+
props = _objectWithoutPropertiesLoose(_ref2, _excluded2$2);
|
|
1665
1787
|
|
|
1666
1788
|
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Box, Object.assign({}, props, {
|
|
1667
1789
|
as: "header",
|
|
@@ -1678,7 +1800,8 @@ function ModalHeader(_ref2) {
|
|
|
1678
1800
|
width: "content",
|
|
1679
1801
|
exceptionallySetClassName: modules_8f59d13b.buttonContainer
|
|
1680
1802
|
}, typeof button !== 'boolean' ? button : button === true ? /*#__PURE__*/React.createElement(ModalCloseButton, {
|
|
1681
|
-
"aria-label": "Close modal"
|
|
1803
|
+
"aria-label": "Close modal",
|
|
1804
|
+
autoFocus: false
|
|
1682
1805
|
}) : null))), withDivider ? /*#__PURE__*/React.createElement(Divider, null) : null);
|
|
1683
1806
|
}
|
|
1684
1807
|
/**
|
|
@@ -1697,7 +1820,7 @@ function ModalHeader(_ref2) {
|
|
|
1697
1820
|
function ModalBody(_ref3) {
|
|
1698
1821
|
var exceptionallySetClassName = _ref3.exceptionallySetClassName,
|
|
1699
1822
|
children = _ref3.children,
|
|
1700
|
-
props = _objectWithoutPropertiesLoose(_ref3,
|
|
1823
|
+
props = _objectWithoutPropertiesLoose(_ref3, _excluded3$1);
|
|
1701
1824
|
|
|
1702
1825
|
var _React$useContext2 = React.useContext(ModalContext),
|
|
1703
1826
|
height = _React$useContext2.height;
|
|
@@ -1724,7 +1847,7 @@ function ModalFooter(_ref4) {
|
|
|
1724
1847
|
var exceptionallySetClassName = _ref4.exceptionallySetClassName,
|
|
1725
1848
|
_ref4$withDivider = _ref4.withDivider,
|
|
1726
1849
|
withDivider = _ref4$withDivider === void 0 ? false : _ref4$withDivider,
|
|
1727
|
-
props = _objectWithoutPropertiesLoose(_ref4,
|
|
1850
|
+
props = _objectWithoutPropertiesLoose(_ref4, _excluded4$1);
|
|
1728
1851
|
|
|
1729
1852
|
return /*#__PURE__*/React.createElement(React.Fragment, null, withDivider ? /*#__PURE__*/React.createElement(Divider, null) : null, /*#__PURE__*/React.createElement(Box, Object.assign({
|
|
1730
1853
|
as: "footer"
|
|
@@ -1732,10 +1855,7 @@ function ModalFooter(_ref4) {
|
|
|
1732
1855
|
className: exceptionallySetClassName,
|
|
1733
1856
|
padding: "large"
|
|
1734
1857
|
})));
|
|
1735
|
-
}
|
|
1736
|
-
// ModalActions
|
|
1737
|
-
//
|
|
1738
|
-
|
|
1858
|
+
}
|
|
1739
1859
|
/**
|
|
1740
1860
|
* A specific version of the ModalFooter, tailored to showing an inline list of actions (buttons).
|
|
1741
1861
|
* @see ModalFooter
|
|
@@ -1743,14 +1863,12 @@ function ModalFooter(_ref4) {
|
|
|
1743
1863
|
|
|
1744
1864
|
function ModalActions(_ref5) {
|
|
1745
1865
|
var children = _ref5.children,
|
|
1746
|
-
props = _objectWithoutPropertiesLoose(_ref5,
|
|
1866
|
+
props = _objectWithoutPropertiesLoose(_ref5, _excluded5$1);
|
|
1747
1867
|
|
|
1748
1868
|
return /*#__PURE__*/React.createElement(ModalFooter, Object.assign({}, props), /*#__PURE__*/React.createElement(Inline, {
|
|
1749
1869
|
align: "right",
|
|
1750
1870
|
space: "large"
|
|
1751
|
-
},
|
|
1752
|
-
return /*#__PURE__*/React.createElement("div", null, child);
|
|
1753
|
-
})));
|
|
1871
|
+
}, children));
|
|
1754
1872
|
}
|
|
1755
1873
|
|
|
1756
1874
|
function getInitials(name) {
|
|
@@ -1777,8 +1895,10 @@ function emailToIndex(email, maxIndex) {
|
|
|
1777
1895
|
return hash % maxIndex;
|
|
1778
1896
|
}
|
|
1779
1897
|
|
|
1898
|
+
var modules_08f3eeac = {"avatar":"_38a1be89","size-xxs":"d32e92ae","size-xs":"_0667d719","size-s":"cf529fcf","size-m":"_6e268eab","size-l":"d64c62cf","size-xl":"_44fb77de","size-xxl":"_01f85e0e","size-xxxl":"_41a5fe19","tablet-size-xxs":"_6ab1577d","tablet-size-xs":"b52a4963","tablet-size-s":"_714a8419","tablet-size-m":"_81cd4d51","tablet-size-l":"bf0a4edb","tablet-size-xl":"e4f0dabd","tablet-size-xxl":"_67ea065d","tablet-size-xxxl":"_2af7f76f","desktop-size-xxs":"_759081dc","desktop-size-xs":"_8290d1c1","desktop-size-s":"_48ea172d","desktop-size-m":"_758f6641","desktop-size-l":"f9ada088","desktop-size-xl":"d3bb7470","desktop-size-xxl":"_9a312ee3","desktop-size-xxxl":"a1d30c23"};
|
|
1899
|
+
|
|
1900
|
+
var _excluded$o = ["user", "avatarUrl", "size", "className", "colorList", "exceptionallySetClassName"];
|
|
1780
1901
|
var AVATAR_COLORS = ['#fcc652', '#e9952c', '#e16b2d', '#d84b40', '#e8435a', '#e5198a', '#ad3889', '#86389c', '#a8a8a8', '#98be2f', '#5d9d50', '#5f9f85', '#5bbcb6', '#32a3bf', '#2bafeb', '#2d88c3', '#3863cc', '#5e5e5e'];
|
|
1781
|
-
var AVATAR_SIZES = ['xxs', 'xs', 's', 'm', 'l', 'xl', 'xxl', 'xxxl'];
|
|
1782
1902
|
|
|
1783
1903
|
function Avatar(_ref) {
|
|
1784
1904
|
var user = _ref.user,
|
|
@@ -1787,20 +1907,23 @@ function Avatar(_ref) {
|
|
|
1787
1907
|
size = _ref$size === void 0 ? 'l' : _ref$size,
|
|
1788
1908
|
className = _ref.className,
|
|
1789
1909
|
_ref$colorList = _ref.colorList,
|
|
1790
|
-
colorList = _ref$colorList === void 0 ? AVATAR_COLORS : _ref$colorList
|
|
1910
|
+
colorList = _ref$colorList === void 0 ? AVATAR_COLORS : _ref$colorList,
|
|
1911
|
+
exceptionallySetClassName = _ref.exceptionallySetClassName,
|
|
1912
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$o);
|
|
1913
|
+
|
|
1791
1914
|
var userInitials = getInitials(user.name) || getInitials(user.email);
|
|
1792
|
-
var avatarSize = size
|
|
1793
|
-
var avatarClass = classNames("reactist_avatar reactist_avatar_size--" + avatarSize, className);
|
|
1915
|
+
var avatarSize = size ? size : 'l';
|
|
1794
1916
|
var style = avatarUrl ? {
|
|
1795
1917
|
backgroundImage: "url(" + avatarUrl + ")",
|
|
1796
1918
|
textIndent: '-9999px'
|
|
1797
1919
|
} : {
|
|
1798
1920
|
backgroundColor: colorList[emailToIndex(user.email, colorList.length)]
|
|
1799
1921
|
};
|
|
1800
|
-
|
|
1801
|
-
|
|
1922
|
+
var sizeClassName = getClassNames(modules_08f3eeac, 'size', avatarSize);
|
|
1923
|
+
return /*#__PURE__*/React__default.createElement(Box, Object.assign({
|
|
1924
|
+
className: [className, modules_08f3eeac.avatar, sizeClassName, exceptionallySetClassName],
|
|
1802
1925
|
style: style
|
|
1803
|
-
}, userInitials);
|
|
1926
|
+
}, props), userInitials);
|
|
1804
1927
|
}
|
|
1805
1928
|
|
|
1806
1929
|
Avatar.displayName = 'Avatar';
|
|
@@ -1827,6 +1950,7 @@ function Checkbox(_ref) {
|
|
|
1827
1950
|
|
|
1828
1951
|
Checkbox.displayName = 'Checkbox';
|
|
1829
1952
|
|
|
1953
|
+
var _excluded$p = ["type", "variant", "size", "loading", "disabled", "tooltip", "onClick", "children"];
|
|
1830
1954
|
/**
|
|
1831
1955
|
* @deprecated
|
|
1832
1956
|
*/
|
|
@@ -1844,7 +1968,7 @@ var Button$1 = /*#__PURE__*/React__default.forwardRef(function Button(_ref, ref)
|
|
|
1844
1968
|
tooltip = _ref.tooltip,
|
|
1845
1969
|
onClick = _ref.onClick,
|
|
1846
1970
|
children = _ref.children,
|
|
1847
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
1971
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$p);
|
|
1848
1972
|
|
|
1849
1973
|
var className = classNames('reactist_button', variant ? "reactist_button--" + variant : null, size !== 'default' ? "reactist_button--" + size : null, {
|
|
1850
1974
|
'reactist_button--loading': loading
|
|
@@ -1867,6 +1991,8 @@ Button$1.defaultProps = {
|
|
|
1867
1991
|
disabled: false
|
|
1868
1992
|
};
|
|
1869
1993
|
|
|
1994
|
+
var _excluded$q = ["children", "onClick", "tooltip", "className"];
|
|
1995
|
+
|
|
1870
1996
|
var Box$1 = /*#__PURE__*/function (_React$Component) {
|
|
1871
1997
|
_inheritsLoose(Box, _React$Component);
|
|
1872
1998
|
|
|
@@ -2017,7 +2143,7 @@ var Trigger = /*#__PURE__*/React__default.forwardRef(function Trigger(_ref, ref)
|
|
|
2017
2143
|
onClick = _ref.onClick,
|
|
2018
2144
|
tooltip = _ref.tooltip,
|
|
2019
2145
|
className = _ref.className,
|
|
2020
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
2146
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$q);
|
|
2021
2147
|
|
|
2022
2148
|
function handleClick(event) {
|
|
2023
2149
|
event.preventDefault();
|
|
@@ -2145,214 +2271,6 @@ function ColorItem(_ref2) {
|
|
|
2145
2271
|
|
|
2146
2272
|
ColorItem.displayName = 'ColorItem';
|
|
2147
2273
|
|
|
2148
|
-
var ErrorMessage = /*#__PURE__*/function (_React$Component) {
|
|
2149
|
-
_inheritsLoose(ErrorMessage, _React$Component);
|
|
2150
|
-
|
|
2151
|
-
function ErrorMessage(props, context) {
|
|
2152
|
-
var _this;
|
|
2153
|
-
|
|
2154
|
-
_this = _React$Component.call(this, props, context) || this;
|
|
2155
|
-
|
|
2156
|
-
_this._clearTimeout = function () {
|
|
2157
|
-
_this.timeout && clearTimeout(_this.timeout);
|
|
2158
|
-
};
|
|
2159
|
-
|
|
2160
|
-
_this._triggerDelayedHide = function () {
|
|
2161
|
-
_this._clearTimeout();
|
|
2162
|
-
|
|
2163
|
-
_this.timeout = setTimeout(_this._hide, _this.props.timeout);
|
|
2164
|
-
};
|
|
2165
|
-
|
|
2166
|
-
_this._hide = function () {
|
|
2167
|
-
var _this$props$onHide, _this$props;
|
|
2168
|
-
|
|
2169
|
-
_this._clearTimeout();
|
|
2170
|
-
|
|
2171
|
-
_this.setState(function () {
|
|
2172
|
-
return {
|
|
2173
|
-
visible: false
|
|
2174
|
-
};
|
|
2175
|
-
});
|
|
2176
|
-
|
|
2177
|
-
(_this$props$onHide = (_this$props = _this.props).onHide) === null || _this$props$onHide === void 0 ? void 0 : _this$props$onHide.call(_this$props);
|
|
2178
|
-
};
|
|
2179
|
-
|
|
2180
|
-
var isValidMessage = _this._isValidMessage(props.message);
|
|
2181
|
-
|
|
2182
|
-
if (isValidMessage) {
|
|
2183
|
-
_this._triggerDelayedHide();
|
|
2184
|
-
}
|
|
2185
|
-
|
|
2186
|
-
_this.state = {
|
|
2187
|
-
visible: isValidMessage
|
|
2188
|
-
};
|
|
2189
|
-
return _this;
|
|
2190
|
-
}
|
|
2191
|
-
|
|
2192
|
-
var _proto = ErrorMessage.prototype;
|
|
2193
|
-
|
|
2194
|
-
_proto.UNSAFE_componentWillReceiveProps = function UNSAFE_componentWillReceiveProps(nextProps) {
|
|
2195
|
-
if (this._isValidMessage(nextProps.message)) {
|
|
2196
|
-
this.setState(function () {
|
|
2197
|
-
return {
|
|
2198
|
-
visible: true
|
|
2199
|
-
};
|
|
2200
|
-
});
|
|
2201
|
-
|
|
2202
|
-
this._triggerDelayedHide();
|
|
2203
|
-
}
|
|
2204
|
-
};
|
|
2205
|
-
|
|
2206
|
-
_proto._isValidMessage = function _isValidMessage(message) {
|
|
2207
|
-
return typeof message === 'string' && message.length > 0;
|
|
2208
|
-
};
|
|
2209
|
-
|
|
2210
|
-
_proto.render = function render() {
|
|
2211
|
-
var message = this.props.message;
|
|
2212
|
-
|
|
2213
|
-
if (!this.state.visible || !this._isValidMessage(message)) {
|
|
2214
|
-
return false;
|
|
2215
|
-
}
|
|
2216
|
-
|
|
2217
|
-
return /*#__PURE__*/React__default.createElement("div", {
|
|
2218
|
-
className: "reactist_error_message"
|
|
2219
|
-
}, /*#__PURE__*/React__default.createElement("p", null, message), /*#__PURE__*/React__default.createElement("div", {
|
|
2220
|
-
onClick: this._hide,
|
|
2221
|
-
className: "dismiss_icon"
|
|
2222
|
-
}));
|
|
2223
|
-
};
|
|
2224
|
-
|
|
2225
|
-
return ErrorMessage;
|
|
2226
|
-
}(React__default.Component);
|
|
2227
|
-
|
|
2228
|
-
ErrorMessage.displayName = 'ErrorMessage';
|
|
2229
|
-
ErrorMessage.defaultProps = {
|
|
2230
|
-
timeout: 2500
|
|
2231
|
-
};
|
|
2232
|
-
|
|
2233
|
-
var ThreeDotsIcon = function ThreeDotsIcon(_ref) {
|
|
2234
|
-
var _ref$color = _ref.color,
|
|
2235
|
-
color = _ref$color === void 0 ? '#A5A5A5' : _ref$color;
|
|
2236
|
-
return /*#__PURE__*/React__default.createElement("svg", {
|
|
2237
|
-
width: "26px",
|
|
2238
|
-
height: "26px",
|
|
2239
|
-
viewBox: "0 0 26 26"
|
|
2240
|
-
}, /*#__PURE__*/React__default.createElement("g", {
|
|
2241
|
-
stroke: "none",
|
|
2242
|
-
strokeWidth: "1",
|
|
2243
|
-
fill: "none",
|
|
2244
|
-
fillRule: "evenodd"
|
|
2245
|
-
}, /*#__PURE__*/React__default.createElement("circle", {
|
|
2246
|
-
fill: color,
|
|
2247
|
-
cx: "19",
|
|
2248
|
-
cy: "13",
|
|
2249
|
-
r: "2"
|
|
2250
|
-
}), /*#__PURE__*/React__default.createElement("circle", {
|
|
2251
|
-
fill: color,
|
|
2252
|
-
cx: "13",
|
|
2253
|
-
cy: "13",
|
|
2254
|
-
r: "2"
|
|
2255
|
-
}), /*#__PURE__*/React__default.createElement("circle", {
|
|
2256
|
-
fill: color,
|
|
2257
|
-
cx: "7",
|
|
2258
|
-
cy: "13",
|
|
2259
|
-
r: "2"
|
|
2260
|
-
})));
|
|
2261
|
-
};
|
|
2262
|
-
|
|
2263
|
-
ThreeDotsIcon.propTypes = {
|
|
2264
|
-
/** Color of the icon. */
|
|
2265
|
-
color: PropTypes.string
|
|
2266
|
-
};
|
|
2267
|
-
|
|
2268
|
-
var Icon = /*#__PURE__*/function (_React$Component) {
|
|
2269
|
-
_inheritsLoose(Icon, _React$Component);
|
|
2270
|
-
|
|
2271
|
-
function Icon(props, context) {
|
|
2272
|
-
var _this;
|
|
2273
|
-
|
|
2274
|
-
_this = _React$Component.call(this, props, context) || this;
|
|
2275
|
-
|
|
2276
|
-
_this._onClick = function (event) {
|
|
2277
|
-
event.preventDefault();
|
|
2278
|
-
|
|
2279
|
-
if (_this.props.onClick && !_this.props.disabled) {
|
|
2280
|
-
_this.props.onClick();
|
|
2281
|
-
}
|
|
2282
|
-
};
|
|
2283
|
-
|
|
2284
|
-
_this._hover = function () {
|
|
2285
|
-
_this.setState(function () {
|
|
2286
|
-
return {
|
|
2287
|
-
hovered: true
|
|
2288
|
-
};
|
|
2289
|
-
});
|
|
2290
|
-
};
|
|
2291
|
-
|
|
2292
|
-
_this._unhover = function () {
|
|
2293
|
-
_this.setState(function () {
|
|
2294
|
-
return {
|
|
2295
|
-
hovered: false
|
|
2296
|
-
};
|
|
2297
|
-
});
|
|
2298
|
-
};
|
|
2299
|
-
|
|
2300
|
-
_this.state = {
|
|
2301
|
-
hovered: false
|
|
2302
|
-
};
|
|
2303
|
-
return _this;
|
|
2304
|
-
}
|
|
2305
|
-
|
|
2306
|
-
var _proto = Icon.prototype;
|
|
2307
|
-
|
|
2308
|
-
_proto.render = function render() {
|
|
2309
|
-
var _this$props = this.props,
|
|
2310
|
-
image = _this$props.image,
|
|
2311
|
-
hoveredImage = _this$props.hoveredImage,
|
|
2312
|
-
icon = _this$props.icon,
|
|
2313
|
-
tooltip = _this$props.tooltip,
|
|
2314
|
-
disabled = _this$props.disabled;
|
|
2315
|
-
var className = classNames('reactist_icon', {
|
|
2316
|
-
'reactist_icon--component': !image,
|
|
2317
|
-
disabled: disabled
|
|
2318
|
-
}, this.props.className);
|
|
2319
|
-
var style = typeof image === 'string' ? this.state.hovered && hoveredImage ? {
|
|
2320
|
-
backgroundImage: "url(" + hoveredImage + ")"
|
|
2321
|
-
} : {
|
|
2322
|
-
backgroundImage: "url(" + image + ")"
|
|
2323
|
-
} : undefined; // only apply style for image components
|
|
2324
|
-
|
|
2325
|
-
var iconComponent = !image && (icon ? icon : /*#__PURE__*/React__default.createElement(ThreeDotsIcon, {
|
|
2326
|
-
color: this.state.hovered ? '#474747' : undefined
|
|
2327
|
-
})); // only set icon component for non-image components
|
|
2328
|
-
|
|
2329
|
-
var component =
|
|
2330
|
-
/*#__PURE__*/
|
|
2331
|
-
|
|
2332
|
-
/* eslint-disable jsx-a11y/anchor-is-valid */
|
|
2333
|
-
React__default.createElement("a", {
|
|
2334
|
-
href: "#",
|
|
2335
|
-
style: style,
|
|
2336
|
-
onClick: this._onClick,
|
|
2337
|
-
className: className,
|
|
2338
|
-
onMouseEnter: this._hover,
|
|
2339
|
-
onMouseLeave: this._unhover
|
|
2340
|
-
}, iconComponent && iconComponent)
|
|
2341
|
-
/* eslint-enable jsx-a11y/anchor-is-valid */
|
|
2342
|
-
;
|
|
2343
|
-
return tooltip ? /*#__PURE__*/React__default.createElement(Tooltip, {
|
|
2344
|
-
content: tooltip
|
|
2345
|
-
}, component) : component;
|
|
2346
|
-
};
|
|
2347
|
-
|
|
2348
|
-
return Icon;
|
|
2349
|
-
}(React__default.Component);
|
|
2350
|
-
|
|
2351
|
-
Icon.displayName = 'Icon';
|
|
2352
|
-
Icon.defaultProps = {
|
|
2353
|
-
disabled: false
|
|
2354
|
-
};
|
|
2355
|
-
|
|
2356
2274
|
var Input = /*#__PURE__*/React__default.forwardRef(function (props, ref) {
|
|
2357
2275
|
var className = classNames('reactist_input', props.className);
|
|
2358
2276
|
return /*#__PURE__*/React__default.createElement("input", Object.assign({}, props, {
|
|
@@ -2362,6 +2280,7 @@ var Input = /*#__PURE__*/React__default.forwardRef(function (props, ref) {
|
|
|
2362
2280
|
});
|
|
2363
2281
|
Input.displayName = 'Input';
|
|
2364
2282
|
|
|
2283
|
+
var _excluded$r = ["children", "className", "translateKey", "isMac"];
|
|
2365
2284
|
// Support for setting up how to translate modifiers globally.
|
|
2366
2285
|
//
|
|
2367
2286
|
|
|
@@ -2445,7 +2364,7 @@ function KeyboardShortcut(_ref) {
|
|
|
2445
2364
|
translateKey = _ref$translateKey === void 0 ? globalTranslateKey : _ref$translateKey,
|
|
2446
2365
|
_ref$isMac = _ref.isMac,
|
|
2447
2366
|
isMac = _ref$isMac === void 0 ? (_navigator$platform$t = (_navigator$platform = navigator.platform) === null || _navigator$platform === void 0 ? void 0 : _navigator$platform.toUpperCase().includes('MAC')) !== null && _navigator$platform$t !== void 0 ? _navigator$platform$t : false : _ref$isMac,
|
|
2448
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
2367
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$r);
|
|
2449
2368
|
|
|
2450
2369
|
var shortcuts = typeof children === 'string' ? [children] : children;
|
|
2451
2370
|
return /*#__PURE__*/React.createElement("span", Object.assign({
|
|
@@ -2968,7 +2887,8 @@ Popover.defaultProps = {
|
|
|
2968
2887
|
function ProgressBar(_ref) {
|
|
2969
2888
|
var _ref$fillPercentage = _ref.fillPercentage,
|
|
2970
2889
|
fillPercentage = _ref$fillPercentage === void 0 ? 0 : _ref$fillPercentage,
|
|
2971
|
-
className = _ref.className
|
|
2890
|
+
className = _ref.className,
|
|
2891
|
+
ariaValuetext = _ref['aria-valuetext'];
|
|
2972
2892
|
var finalClassName = classNames('reactist_progress_bar', className);
|
|
2973
2893
|
var width = fillPercentage < 0 ? 0 : fillPercentage > 100 ? 100 : fillPercentage;
|
|
2974
2894
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
@@ -2978,60 +2898,16 @@ function ProgressBar(_ref) {
|
|
|
2978
2898
|
style: {
|
|
2979
2899
|
width: width + "%"
|
|
2980
2900
|
}
|
|
2981
|
-
})
|
|
2901
|
+
}), /*#__PURE__*/React__default.createElement(HiddenVisually, null, /*#__PURE__*/React__default.createElement("progress", {
|
|
2902
|
+
value: width,
|
|
2903
|
+
max: 100,
|
|
2904
|
+
"aria-valuetext": ariaValuetext !== null && ariaValuetext !== void 0 ? ariaValuetext : undefined
|
|
2905
|
+
})));
|
|
2982
2906
|
}
|
|
2983
2907
|
|
|
2984
2908
|
ProgressBar.displayName = 'ProgressBar';
|
|
2985
2909
|
|
|
2986
|
-
|
|
2987
|
-
var _ref$value = _ref.value,
|
|
2988
|
-
value = _ref$value === void 0 ? 0 : _ref$value,
|
|
2989
|
-
_ref$min = _ref.min,
|
|
2990
|
-
min = _ref$min === void 0 ? 0 : _ref$min,
|
|
2991
|
-
_ref$max = _ref.max,
|
|
2992
|
-
max = _ref$max === void 0 ? 100 : _ref$max,
|
|
2993
|
-
_ref$stepSize = _ref.stepSize,
|
|
2994
|
-
stepSize = _ref$stepSize === void 0 ? 1 : _ref$stepSize,
|
|
2995
|
-
onPlus = _ref.onPlus,
|
|
2996
|
-
onMinus = _ref.onMinus,
|
|
2997
|
-
_onChange = _ref.onChange,
|
|
2998
|
-
className = _ref.className;
|
|
2999
|
-
|
|
3000
|
-
if (typeof onPlus !== 'function') {
|
|
3001
|
-
onPlus = _onChange;
|
|
3002
|
-
}
|
|
3003
|
-
|
|
3004
|
-
if (typeof onMinus !== 'function') {
|
|
3005
|
-
onMinus = _onChange;
|
|
3006
|
-
}
|
|
3007
|
-
|
|
3008
|
-
var rangeInputClassName = classNames('reactist_range_input', className);
|
|
3009
|
-
return /*#__PURE__*/React__default.createElement("div", {
|
|
3010
|
-
className: rangeInputClassName
|
|
3011
|
-
}, /*#__PURE__*/React__default.createElement("span", {
|
|
3012
|
-
className: "range_btn minus",
|
|
3013
|
-
onClick: function onClick() {
|
|
3014
|
-
return value > min && onMinus && onMinus(value - stepSize);
|
|
3015
|
-
}
|
|
3016
|
-
}), /*#__PURE__*/React__default.createElement("input", {
|
|
3017
|
-
value: value,
|
|
3018
|
-
className: "range_slider",
|
|
3019
|
-
type: "range",
|
|
3020
|
-
min: min,
|
|
3021
|
-
max: max,
|
|
3022
|
-
step: stepSize,
|
|
3023
|
-
onChange: function onChange(event) {
|
|
3024
|
-
return _onChange === null || _onChange === void 0 ? void 0 : _onChange(parseInt(event.target.value));
|
|
3025
|
-
}
|
|
3026
|
-
}), /*#__PURE__*/React__default.createElement("span", {
|
|
3027
|
-
className: "range_btn plus",
|
|
3028
|
-
onClick: function onClick() {
|
|
3029
|
-
return value < max && onPlus && onPlus(value + stepSize);
|
|
3030
|
-
}
|
|
3031
|
-
}));
|
|
3032
|
-
}
|
|
3033
|
-
|
|
3034
|
-
RangeInput.displayName = 'RangeInput';
|
|
2910
|
+
var _excluded$s = ["value", "options", "onChange", "disabled", "className", "defaultValue"];
|
|
3035
2911
|
|
|
3036
2912
|
function Select(_ref) {
|
|
3037
2913
|
var value = _ref.value,
|
|
@@ -3043,7 +2919,7 @@ function Select(_ref) {
|
|
|
3043
2919
|
_ref$className = _ref.className,
|
|
3044
2920
|
className = _ref$className === void 0 ? '' : _ref$className,
|
|
3045
2921
|
defaultValue = _ref.defaultValue,
|
|
3046
|
-
otherProps = _objectWithoutPropertiesLoose(_ref,
|
|
2922
|
+
otherProps = _objectWithoutPropertiesLoose(_ref, _excluded$s);
|
|
3047
2923
|
|
|
3048
2924
|
var selectClassName = classNames('reactist_select', {
|
|
3049
2925
|
disabled: disabled
|
|
@@ -3287,49 +3163,6 @@ Time.defaultProps = {
|
|
|
3287
3163
|
}
|
|
3288
3164
|
};
|
|
3289
3165
|
|
|
3290
|
-
var ThinQuestionMark = function ThinQuestionMark() {
|
|
3291
|
-
return /*#__PURE__*/React__default.createElement("svg", {
|
|
3292
|
-
width: "18px",
|
|
3293
|
-
height: "18px",
|
|
3294
|
-
viewBox: "0 0 18 18"
|
|
3295
|
-
}, /*#__PURE__*/React__default.createElement("g", {
|
|
3296
|
-
stroke: "none",
|
|
3297
|
-
strokeWidth: "1",
|
|
3298
|
-
fill: "none",
|
|
3299
|
-
fillRule: "evenodd"
|
|
3300
|
-
}, /*#__PURE__*/React__default.createElement("g", {
|
|
3301
|
-
fill: "#979797"
|
|
3302
|
-
}, /*#__PURE__*/React__default.createElement("path", {
|
|
3303
|
-
d: "M9,17 C13.418278,17 17,13.418278 17,9 C17,4.581722 13.418278,1 9,1 C4.581722,1 1,4.581722 1,9 C1,13.418278 4.581722,17 9,17 Z M9,18 C4.02943725,18 0,13.9705627 0,9 C0,4.02943725 4.02943725,0 9,0 C13.9705627,0 18,4.02943725 18,9 C18,13.9705627 13.9705627,18 9,18 Z",
|
|
3304
|
-
fillRule: "nonzero"
|
|
3305
|
-
}), /*#__PURE__*/React__default.createElement("path", {
|
|
3306
|
-
d: "M5.625,6.671875 L6.9609375,6.671875 C7.046875,5.5546875 7.796875,4.859375 8.9765625,4.859375 C10.140625,4.859375 10.890625,5.5703125 10.890625,6.5390625 C10.890625,7.375 10.5390625,7.8671875 9.6328125,8.421875 C8.5625,9.0625 8.0625,9.765625 8.0703125,10.796875 L8.0703125,11.515625 L9.4375,11.515625 L9.4375,11.0078125 C9.4375,10.1875 9.71875,9.75 10.7109375,9.1640625 C11.7109375,8.5625 12.34375,7.6953125 12.34375,6.46875 C12.34375,4.859375 11,3.640625 9.03125,3.640625 C6.8359375,3.640625 5.7109375,4.984375 5.625,6.671875 Z M8.859375,15.140625 C9.4921875,15.140625 9.9375,14.6875 9.9375,14.0546875 C9.9375,13.4140625 9.4921875,12.9609375 8.859375,12.9609375 C8.2265625,12.9609375 7.7734375,13.4140625 7.7734375,14.0546875 C7.7734375,14.6875 8.2265625,15.140625 8.859375,15.140625 Z"
|
|
3307
|
-
}))));
|
|
3308
|
-
};
|
|
3309
|
-
|
|
3310
|
-
function Tip(_ref) {
|
|
3311
|
-
var title = _ref.title,
|
|
3312
|
-
message = _ref.message,
|
|
3313
|
-
top = _ref.top,
|
|
3314
|
-
className = _ref.className;
|
|
3315
|
-
var tipClass = classNames('reactist_tip__container', className);
|
|
3316
|
-
return /*#__PURE__*/React__default.createElement(Dropdown.Box, {
|
|
3317
|
-
top: top,
|
|
3318
|
-
className: tipClass
|
|
3319
|
-
}, /*#__PURE__*/React__default.createElement(Dropdown.Trigger, null, /*#__PURE__*/React__default.createElement(ThinQuestionMark, null)), /*#__PURE__*/React__default.createElement(Dropdown.Body, null, /*#__PURE__*/React__default.createElement("div", {
|
|
3320
|
-
className: "reactist_tip"
|
|
3321
|
-
}, /*#__PURE__*/React__default.createElement("p", {
|
|
3322
|
-
className: "reactist_tip--title"
|
|
3323
|
-
}, title), /*#__PURE__*/React__default.createElement("p", {
|
|
3324
|
-
className: "reactist_tip--message"
|
|
3325
|
-
}, message))));
|
|
3326
|
-
}
|
|
3327
|
-
|
|
3328
|
-
Tip.displayName = 'Tip';
|
|
3329
|
-
Tip.defaultProps = {
|
|
3330
|
-
top: false
|
|
3331
|
-
};
|
|
3332
|
-
|
|
3333
3166
|
var CloseIcon$1 = function CloseIcon() {
|
|
3334
3167
|
return /*#__PURE__*/React__default.createElement("svg", {
|
|
3335
3168
|
width: "24",
|
|
@@ -3342,6 +3175,8 @@ var CloseIcon$1 = function CloseIcon() {
|
|
|
3342
3175
|
}));
|
|
3343
3176
|
};
|
|
3344
3177
|
|
|
3178
|
+
var _excluded$t = ["id", "icon", "title", "subtitle", "children", "customCloseButton", "onClick", "onClose", "closeAltText", "className", "aria-live"];
|
|
3179
|
+
|
|
3345
3180
|
function Notification(_ref) {
|
|
3346
3181
|
var id = _ref.id,
|
|
3347
3182
|
icon = _ref.icon,
|
|
@@ -3354,7 +3189,9 @@ function Notification(_ref) {
|
|
|
3354
3189
|
_ref$closeAltText = _ref.closeAltText,
|
|
3355
3190
|
closeAltText = _ref$closeAltText === void 0 ? 'Close' : _ref$closeAltText,
|
|
3356
3191
|
className = _ref.className,
|
|
3357
|
-
|
|
3192
|
+
_ref$ariaLive = _ref['aria-live'],
|
|
3193
|
+
ariaLive = _ref$ariaLive === void 0 ? 'polite' : _ref$ariaLive,
|
|
3194
|
+
rest = _objectWithoutPropertiesLoose(_ref, _excluded$t);
|
|
3358
3195
|
|
|
3359
3196
|
var titleId = title ? id + "-title" : null;
|
|
3360
3197
|
var titleIdAttribute = titleId ? {
|
|
@@ -3388,11 +3225,12 @@ function Notification(_ref) {
|
|
|
3388
3225
|
}, icon !== null && icon !== void 0 ? icon : null, notificationContent);
|
|
3389
3226
|
return /*#__PURE__*/React__default.createElement("div", Object.assign({
|
|
3390
3227
|
id: id,
|
|
3391
|
-
role: "
|
|
3228
|
+
role: "alert",
|
|
3392
3229
|
className: classNames('reactist-notification', className, {
|
|
3393
3230
|
'reactist-notification--with-button': Boolean(onClick),
|
|
3394
3231
|
'reactist-notification--with-close-button': Boolean(onClose)
|
|
3395
|
-
})
|
|
3232
|
+
}),
|
|
3233
|
+
"aria-live": ariaLive
|
|
3396
3234
|
}, ariaLabelledBy, ariaDescribedBy, rest), onClick ? /*#__PURE__*/React__default.createElement("button", {
|
|
3397
3235
|
className: "reactist-notification__button",
|
|
3398
3236
|
onClick: onClick
|
|
@@ -3403,6 +3241,17 @@ function Notification(_ref) {
|
|
|
3403
3241
|
}, customCloseButton !== null && customCloseButton !== void 0 ? customCloseButton : /*#__PURE__*/React__default.createElement(CloseIcon$1, null)) : null);
|
|
3404
3242
|
}
|
|
3405
3243
|
|
|
3244
|
+
var _excluded$u = ["children", "onItemSelect"],
|
|
3245
|
+
_excluded2$3 = ["exceptionallySetClassName"],
|
|
3246
|
+
_excluded3$2 = ["handleItemSelect"],
|
|
3247
|
+
_excluded4$2 = ["exceptionallySetClassName"],
|
|
3248
|
+
_excluded5$2 = ["handleItemSelect"],
|
|
3249
|
+
_excluded6 = ["value", "children", "onSelect", "hideOnSelect", "onClick", "exceptionallySetClassName"],
|
|
3250
|
+
_excluded7 = ["handleItemSelect"],
|
|
3251
|
+
_excluded8 = ["children", "onItemSelect"],
|
|
3252
|
+
_excluded9 = ["handleItemSelect"],
|
|
3253
|
+
_excluded10 = ["label", "children", "exceptionallySetClassName"],
|
|
3254
|
+
_excluded11 = ["handleItemSelect"];
|
|
3406
3255
|
var MenuContext = /*#__PURE__*/React.createContext( // Reakit gives us no means to obtain a valid initial/default value of type MenuStateReturn
|
|
3407
3256
|
// (it is normally obtained by calling useMenuState but we can't call hooks outside components).
|
|
3408
3257
|
// This is however of little consequence since this value is only used if some of the components
|
|
@@ -3417,10 +3266,11 @@ var MenuContext = /*#__PURE__*/React.createContext( // Reakit gives us no means
|
|
|
3417
3266
|
function Menu(_ref) {
|
|
3418
3267
|
var children = _ref.children,
|
|
3419
3268
|
onItemSelect = _ref.onItemSelect,
|
|
3420
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
3269
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded$u);
|
|
3421
3270
|
|
|
3422
3271
|
var state = Reakit.useMenuState(_objectSpread2({
|
|
3423
|
-
loop: true
|
|
3272
|
+
loop: true,
|
|
3273
|
+
unstable_offset: [8, 8]
|
|
3424
3274
|
}, props));
|
|
3425
3275
|
var handleItemSelect = React.useCallback(function handleItemSelect(value) {
|
|
3426
3276
|
if (onItemSelect) onItemSelect(value);
|
|
@@ -3441,10 +3291,10 @@ function Menu(_ref) {
|
|
|
3441
3291
|
|
|
3442
3292
|
var MenuButton = /*#__PURE__*/polymorphicComponent(function MenuButton(_ref2, ref) {
|
|
3443
3293
|
var exceptionallySetClassName = _ref2.exceptionallySetClassName,
|
|
3444
|
-
props = _objectWithoutPropertiesLoose(_ref2,
|
|
3294
|
+
props = _objectWithoutPropertiesLoose(_ref2, _excluded2$3);
|
|
3445
3295
|
|
|
3446
3296
|
var _React$useContext = React.useContext(MenuContext),
|
|
3447
|
-
state = _objectWithoutPropertiesLoose(_React$useContext,
|
|
3297
|
+
state = _objectWithoutPropertiesLoose(_React$useContext, _excluded3$2);
|
|
3448
3298
|
|
|
3449
3299
|
return /*#__PURE__*/React.createElement(Reakit.MenuButton, Object.assign({}, props, state, {
|
|
3450
3300
|
ref: ref,
|
|
@@ -3488,11 +3338,19 @@ function MenuBackdrop(_ref3) {
|
|
|
3488
3338
|
|
|
3489
3339
|
var MenuList = /*#__PURE__*/polymorphicComponent(function MenuList(_ref4, ref) {
|
|
3490
3340
|
var exceptionallySetClassName = _ref4.exceptionallySetClassName,
|
|
3491
|
-
props = _objectWithoutPropertiesLoose(_ref4,
|
|
3341
|
+
props = _objectWithoutPropertiesLoose(_ref4, _excluded4$2);
|
|
3492
3342
|
|
|
3493
3343
|
var _React$useContext2 = React.useContext(MenuContext),
|
|
3494
|
-
state = _objectWithoutPropertiesLoose(_React$useContext2,
|
|
3344
|
+
state = _objectWithoutPropertiesLoose(_React$useContext2, _excluded5$2);
|
|
3495
3345
|
|
|
3346
|
+
var previousVisible = usePrevious(state.visible);
|
|
3347
|
+
React.useEffect(function focusTriggerOnClose() {
|
|
3348
|
+
if (state.visible === false && previousVisible === true) {
|
|
3349
|
+
var _state$unstable_refer, _state$unstable_refer2;
|
|
3350
|
+
|
|
3351
|
+
(_state$unstable_refer = state.unstable_referenceRef) === null || _state$unstable_refer === void 0 ? void 0 : (_state$unstable_refer2 = _state$unstable_refer.current) === null || _state$unstable_refer2 === void 0 ? void 0 : _state$unstable_refer2.focus();
|
|
3352
|
+
}
|
|
3353
|
+
}, [state.visible, previousVisible, state.unstable_referenceRef]);
|
|
3496
3354
|
return state.visible ? /*#__PURE__*/React.createElement(MenuBackdrop, Object.assign({}, state), /*#__PURE__*/React.createElement(Reakit.Menu, Object.assign({}, props, state, {
|
|
3497
3355
|
ref: ref,
|
|
3498
3356
|
className: classNames('reactist_menulist', exceptionallySetClassName)
|
|
@@ -3511,11 +3369,11 @@ var MenuItem = /*#__PURE__*/polymorphicComponent(function MenuItem(_ref5, ref) {
|
|
|
3511
3369
|
hideOnSelect = _ref5$hideOnSelect === void 0 ? true : _ref5$hideOnSelect,
|
|
3512
3370
|
onClick = _ref5.onClick,
|
|
3513
3371
|
exceptionallySetClassName = _ref5.exceptionallySetClassName,
|
|
3514
|
-
props = _objectWithoutPropertiesLoose(_ref5,
|
|
3372
|
+
props = _objectWithoutPropertiesLoose(_ref5, _excluded6);
|
|
3515
3373
|
|
|
3516
3374
|
var _React$useContext3 = React.useContext(MenuContext),
|
|
3517
3375
|
handleItemSelect = _React$useContext3.handleItemSelect,
|
|
3518
|
-
state = _objectWithoutPropertiesLoose(_React$useContext3,
|
|
3376
|
+
state = _objectWithoutPropertiesLoose(_React$useContext3, _excluded7);
|
|
3519
3377
|
|
|
3520
3378
|
var hide = state.hide;
|
|
3521
3379
|
var handleClick = React.useCallback(function handleClick(event) {
|
|
@@ -3556,11 +3414,11 @@ var MenuItem = /*#__PURE__*/polymorphicComponent(function MenuItem(_ref5, ref) {
|
|
|
3556
3414
|
var SubMenu = /*#__PURE__*/React.forwardRef(function SubMenu(_ref6, ref) {
|
|
3557
3415
|
var children = _ref6.children,
|
|
3558
3416
|
onItemSelect = _ref6.onItemSelect,
|
|
3559
|
-
props = _objectWithoutPropertiesLoose(_ref6,
|
|
3417
|
+
props = _objectWithoutPropertiesLoose(_ref6, _excluded8);
|
|
3560
3418
|
|
|
3561
3419
|
var _React$useContext4 = React.useContext(MenuContext),
|
|
3562
3420
|
parentMenuItemSelect = _React$useContext4.handleItemSelect,
|
|
3563
|
-
state = _objectWithoutPropertiesLoose(_React$useContext4,
|
|
3421
|
+
state = _objectWithoutPropertiesLoose(_React$useContext4, _excluded9);
|
|
3564
3422
|
|
|
3565
3423
|
var parentMenuHide = state.hide;
|
|
3566
3424
|
var handleSubItemSelect = React.useCallback(function handleSubItemSelect(value) {
|
|
@@ -3594,10 +3452,10 @@ var MenuGroup = /*#__PURE__*/polymorphicComponent(function MenuGroud(_ref7, ref)
|
|
|
3594
3452
|
var label = _ref7.label,
|
|
3595
3453
|
children = _ref7.children,
|
|
3596
3454
|
exceptionallySetClassName = _ref7.exceptionallySetClassName,
|
|
3597
|
-
props = _objectWithoutPropertiesLoose(_ref7,
|
|
3455
|
+
props = _objectWithoutPropertiesLoose(_ref7, _excluded10);
|
|
3598
3456
|
|
|
3599
3457
|
var _React$useContext5 = React.useContext(MenuContext),
|
|
3600
|
-
state = _objectWithoutPropertiesLoose(_React$useContext5,
|
|
3458
|
+
state = _objectWithoutPropertiesLoose(_React$useContext5, _excluded11);
|
|
3601
3459
|
|
|
3602
3460
|
return /*#__PURE__*/React.createElement(Reakit.MenuGroup, Object.assign({
|
|
3603
3461
|
ref: ref
|
|
@@ -3820,7 +3678,7 @@ var Actions = /*#__PURE__*/function (_React$Component4) {
|
|
|
3820
3678
|
this.props.children, function (child) {
|
|
3821
3679
|
var _child$props;
|
|
3822
3680
|
|
|
3823
|
-
if (child
|
|
3681
|
+
if (child !== null && child !== void 0 && (_child$props = child.props) !== null && _child$props !== void 0 && _child$props.close) {
|
|
3824
3682
|
return /*#__PURE__*/React__default.cloneElement(child, {
|
|
3825
3683
|
onClick: function onClick() {
|
|
3826
3684
|
return _this2._onClick(child.props.onClick);
|
|
@@ -3900,11 +3758,9 @@ exports.DeprecatedLoading = Loading$1;
|
|
|
3900
3758
|
exports.DeprecatedModal = index;
|
|
3901
3759
|
exports.Divider = Divider;
|
|
3902
3760
|
exports.Dropdown = Dropdown;
|
|
3903
|
-
exports.ErrorMessage = ErrorMessage;
|
|
3904
3761
|
exports.Heading = Heading;
|
|
3905
3762
|
exports.Hidden = Hidden;
|
|
3906
3763
|
exports.HiddenVisually = HiddenVisually;
|
|
3907
|
-
exports.Icon = Icon;
|
|
3908
3764
|
exports.Inline = Inline;
|
|
3909
3765
|
exports.Input = Input;
|
|
3910
3766
|
exports.KeyCapturer = KeyCapturer;
|
|
@@ -3926,7 +3782,6 @@ exports.Notification = Notification;
|
|
|
3926
3782
|
exports.PasswordField = PasswordField;
|
|
3927
3783
|
exports.Popover = Popover;
|
|
3928
3784
|
exports.ProgressBar = ProgressBar;
|
|
3929
|
-
exports.RangeInput = RangeInput;
|
|
3930
3785
|
exports.SUPPORTED_KEYS = SUPPORTED_KEYS;
|
|
3931
3786
|
exports.Select = Select;
|
|
3932
3787
|
exports.SelectField = SelectField;
|
|
@@ -3943,7 +3798,6 @@ exports.TextArea = TextArea;
|
|
|
3943
3798
|
exports.TextField = TextField;
|
|
3944
3799
|
exports.TextLink = TextLink;
|
|
3945
3800
|
exports.Time = Time;
|
|
3946
|
-
exports.Tip = Tip;
|
|
3947
3801
|
exports.Tooltip = Tooltip;
|
|
3948
3802
|
exports.usePrevious = usePrevious;
|
|
3949
3803
|
//# sourceMappingURL=reactist.cjs.development.js.map
|