iguazio.dashboard-react-controls 0.0.39 → 1.2.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/components/Backdrop/Backdrop.js +4 -11
- package/dist/components/Button/Button.js +25 -28
- package/dist/components/ConfirmDialog/ConfirmDialog.js +10 -24
- package/dist/components/FormCheckBox/FormCheckBox.js +25 -25
- package/dist/components/FormChipCell/FormChip/FormChip.js +33 -33
- package/dist/components/FormChipCell/FormChipCell.js +66 -109
- package/dist/components/FormChipCell/FormChipCellView.js +19 -37
- package/dist/components/FormChipCell/NewChipForm/NewChipForm.js +58 -90
- package/dist/components/FormChipCell/NewChipInput/NewChipInput.js +24 -22
- package/dist/components/FormChipCell/formChipCell.util.js +0 -1
- package/dist/components/FormCombobox/FormCombobox.js +82 -140
- package/dist/components/FormInput/FormInput.js +110 -175
- package/dist/components/FormInput/InputNumberButtons/InputNumberButtons.js +6 -21
- package/dist/components/FormKeyValueTable/FormKeyValueTable.js +23 -39
- package/dist/components/FormRadio/FormRadio.js +23 -22
- package/dist/components/FormSelect/FormSelect.js +56 -92
- package/dist/components/FormSelect/FormSelect.test.js +19 -35
- package/dist/components/FormTextarea/FormTextarea.js +44 -69
- package/dist/components/Modal/Modal.js +8 -21
- package/dist/components/Modal/Modal.scss +2 -2
- package/dist/components/PopUpDialog/PopUpDialog.js +28 -43
- package/dist/components/RoundedIcon/RoundedIcon.js +7 -18
- package/dist/components/RoundedIcon/roundedIcon.scss +2 -2
- package/dist/components/Tip/Tip.js +25 -40
- package/dist/components/Tip/Tip.test.js +36 -45
- package/dist/components/Tooltip/Tooltip.js +40 -64
- package/dist/components/TooltipTemplate/ProducerTooltipTemplate.js +2 -8
- package/dist/components/TooltipTemplate/TextTooltipTemplate.js +2 -12
- package/dist/components/Wizard/Wizard.js +35 -57
- package/dist/components/Wizard/Wizard.scss +1 -3
- package/dist/components/Wizard/WizardSteps/WizardSteps.js +4 -16
- package/dist/components/Wizard/WizardSteps/WizardSteps.scss +1 -0
- package/dist/components/index.js +0 -18
- package/dist/constants.js +4 -6
- package/dist/elements/FormActionButton/FormActionButton.js +6 -12
- package/dist/elements/FormRowActions/FormRowActions.js +6 -18
- package/dist/elements/HiddenChipsBlock/HiddenChipsBlock.js +37 -55
- package/dist/elements/OptionsMenu/OptionsMenu.js +4 -14
- package/dist/elements/SelectOption/SelectOption.js +6 -18
- package/dist/elements/SelectOption/SelectOption.test.js +19 -12
- package/dist/elements/SelectOption/selectOption.scss +5 -2
- package/dist/elements/ValidationTemplate/ValidationTemplate.js +2 -11
- package/dist/elements/index.js +0 -6
- package/dist/hooks/index.js +0 -1
- package/dist/hooks/useDebounce.js +1 -5
- package/dist/hooks/useDetectOutsideClick.js +4 -8
- package/dist/hooks/useFormTable.hook.js +31 -41
- package/dist/images/archive-icon.svg +3 -0
- package/dist/images/arrow.svg +1 -1
- package/dist/images/close.svg +2 -2
- package/dist/images/collapse.svg +2 -2
- package/dist/images/copy-to-clipboard-icon.svg +3 -0
- package/dist/images/deploy-icon.svg +4 -0
- package/dist/images/edit.svg +1 -1
- package/dist/images/edit_old.svg +3 -0
- package/dist/images/expand.svg +2 -2
- package/dist/images/eye-icon.svg +3 -0
- package/dist/images/link-icon.svg +5 -0
- package/dist/images/monitor-icon.svg +3 -0
- package/dist/images/refresh.svg +1 -1
- package/dist/images/tag-icon.svg +4 -0
- package/dist/images/unarchive-icon.svg +3 -0
- package/dist/images/yaml.svg +2 -3
- package/dist/images/yaml_old.svg +4 -0
- package/dist/index.js +0 -13
- package/dist/scss/borders.scss +1 -1
- package/dist/scss/colors.scss +2 -0
- package/dist/scss/common.scss +7 -3
- package/dist/scss/mixins.scss +6 -19
- package/dist/scss/shadows.scss +3 -3
- package/dist/scss/variables.scss +2 -0
- package/dist/types.js +19 -49
- package/dist/utils/common.util.js +3 -13
- package/dist/utils/form.util.js +20 -24
- package/dist/utils/generateChipsList.util.js +0 -3
- package/dist/utils/getFirstScrollableParent.util.js +0 -5
- package/dist/utils/validation.util.js +72 -94
- package/package.json +104 -104
- package/dist/images/eye.svg +0 -4
package/dist/images/refresh.svg
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
-
<path d="
|
|
2
|
+
<path d="M17.6485 6.35C16.1976 4.9 14.2064 4 11.995 4C7.57223 4 4 7.58 4 12C4 16.42 7.57223 20 11.995 20C15.7273 20 18.8393 17.45 19.7298 14H17.6485C16.828 16.33 14.6066 18 11.995 18C8.68293 18 5.99124 15.31 5.99124 12C5.99124 8.69 8.68293 6 11.995 6C13.656 6 15.137 6.69 16.2176 7.78L12.9956 11H20V4L17.6485 6.35Z" fill="#7F7989"/>
|
|
3
3
|
</svg>
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path d="M8.83115 7.23777C8.63381 7.10591 8.4018 7.03553 8.16447 7.03553C7.84621 7.03553 7.54098 7.16196 7.31594 7.38701C7.09089 7.61205 6.96447 7.91727 6.96447 8.23553C6.96447 8.47287 7.03485 8.70488 7.1667 8.90222C7.29856 9.09956 7.48597 9.25336 7.70525 9.34419C7.92452 9.43501 8.1658 9.45878 8.39857 9.41248C8.63135 9.36617 8.84517 9.25189 9.01299 9.08406C9.18082 8.91624 9.29511 8.70242 9.34141 8.46964C9.38771 8.23687 9.36395 7.99559 9.27312 7.77631C9.1823 7.55704 9.02849 7.36963 8.83115 7.23777Z" fill="#7F7989"/>
|
|
3
|
+
<path fill-rule="evenodd" clip-rule="evenodd" d="M6 4C4.89543 4 4 4.89543 4 6V11.6569C4 12.1873 4.21071 12.696 4.58579 13.0711L11.364 19.8492C12.145 20.6303 13.4113 20.6303 14.1924 19.8492L19.8492 14.1924C20.6303 13.4113 20.6303 12.145 19.8492 11.364L13.0711 4.58579C12.696 4.21071 12.1873 4 11.6569 4H6ZM6 11.6569V6L11.6569 6L18.435 12.7782L12.7782 18.435L6 11.6569Z" fill="#7F7989"/>
|
|
4
|
+
</svg>
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path d="M9.09 4.27L7.09 2.27H21.89V8.27H13.09L11.09 6.27H19.89V4.27H9.09ZM20.89 16.07V9.27H18.89V14.07L20.89 16.07ZM20.89 18.62V18.61L18.89 16.61V16.62L10.55 8.27L8.55 6.27L7.02 4.74L3.28 1L2 2.27L3.89 4.16V8.27H8L18 18.27H6.89V9.27H4.89V20.27H20L21.73 22L23 20.73L20.89 18.62Z" fill="#7F7989"/>
|
|
3
|
+
</svg>
|
package/dist/images/yaml.svg
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
<svg xmlns="http://www.w3.org/2000/svg"
|
|
2
|
-
|
|
3
|
-
<path fill="none" fill-rule="evenodd" d="M0 0h24v24H0V0z"/>
|
|
1
|
+
<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
2
|
+
<path d="M16 17C16.56 17 17 17.44 17 18C17 18.56 16.56 19 16 19C15.44 19 15 18.56 15 18C15 17.44 15.44 17 16 17ZM16 14C13.27 14 10.94 15.66 10 18C10.94 20.34 13.27 22 16 22C18.73 22 21.06 20.34 22 18C21.06 15.66 18.73 14 16 14ZM16 20.5C15.337 20.5 14.7011 20.2366 14.2322 19.7678C13.7634 19.2989 13.5 18.663 13.5 18C13.5 17.337 13.7634 16.7011 14.2322 16.2322C14.7011 15.7634 15.337 15.5 16 15.5C16.663 15.5 17.2989 15.7634 17.7678 16.2322C18.2366 16.7011 18.5 17.337 18.5 18C18.5 18.663 18.2366 19.2989 17.7678 19.7678C17.2989 20.2366 16.663 20.5 16 20.5ZM8.27 19H5V3H12V8H17V12.07C17.7 12.15 18.36 12.32 19 12.56V7L13 1H5C4.46957 1 3.96086 1.21071 3.58579 1.58579C3.21071 1.96086 3 2.46957 3 3V19C3 19.5304 3.21071 20.0391 3.58579 20.4142C3.96086 20.7893 4.46957 21 5 21H9.5C9 20.41 8.59 19.73 8.27 19Z" fill="#7F7989"/>
|
|
4
3
|
</svg>
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24">
|
|
2
|
+
<path fill="#474056" fill-rule="evenodd" d="M16 21c-3.182 0-5.899-2.073-7-5 1.101-2.927 3.818-5 7-5s5.899 2.073 7 5c-1.101 2.927-3.818 5-7 5zm0-8.333c-1.757 0-3.182 1.493-3.182 3.333s1.425 3.333 3.182 3.333c1.756 0 3.182-1.493 3.182-3.333S17.756 12.667 16 12.667zM16 18c-1.057 0-1.909-.893-1.909-2s.852-2 1.909-2c1.056 0 1.909.893 1.909 2s-.853 2-1.909 2zM5 7h8v2H5V7zm0 6v-2h6l-2 2H5zm12-5.6L12.5 3H3.8c-.4 0-.8.5-.8 1v14.2c0 .4.4.8.8.8H9l2 2H4c-1.7 0-3-1.3-3-3V4c0-1.7 1.4-3 3-3h9.4L19 6.6V10h-2V7.4z"/>
|
|
3
|
+
<path fill="none" fill-rule="evenodd" d="M0 0h24v24H0V0z"/>
|
|
4
|
+
</svg>
|
package/dist/index.js
CHANGED
|
@@ -1,32 +1,19 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
4
|
-
|
|
5
4
|
Object.defineProperty(exports, "__esModule", {
|
|
6
5
|
value: true
|
|
7
6
|
});
|
|
8
7
|
exports.types = exports.hooks = exports.elements = exports.constants = exports.components = void 0;
|
|
9
|
-
|
|
10
8
|
var components = _interopRequireWildcard(require("./components"));
|
|
11
|
-
|
|
12
9
|
exports.components = components;
|
|
13
|
-
|
|
14
10
|
var constants = _interopRequireWildcard(require("./constants"));
|
|
15
|
-
|
|
16
11
|
exports.constants = constants;
|
|
17
|
-
|
|
18
12
|
var elements = _interopRequireWildcard(require("./elements"));
|
|
19
|
-
|
|
20
13
|
exports.elements = elements;
|
|
21
|
-
|
|
22
14
|
var hooks = _interopRequireWildcard(require("./hooks"));
|
|
23
|
-
|
|
24
15
|
exports.hooks = hooks;
|
|
25
|
-
|
|
26
16
|
var types = _interopRequireWildcard(require("./types"));
|
|
27
|
-
|
|
28
17
|
exports.types = types;
|
|
29
|
-
|
|
30
18
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
31
|
-
|
|
32
19
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
package/dist/scss/borders.scss
CHANGED
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
$activeJobTabBorder: 3px solid $cornflowerBlue;
|
|
4
4
|
$disabledBorder: 1px solid rgba($spunPearl, 0.3);
|
|
5
5
|
$errorBorder: 1px solid $amaranth;
|
|
6
|
-
$gitBorder: 1px solid $white;
|
|
7
6
|
$labelBorder: 1px solid $amethyst;
|
|
8
7
|
$parametersBorder: 1px solid $burntSiennaTwo;
|
|
9
8
|
$primaryBorder: 1px solid rgba($black, 0.2);
|
|
@@ -18,3 +17,4 @@ $uploadFileIdleBorder: 1px dashed $silver;
|
|
|
18
17
|
$labelEditBorder: 1px solid rgba($amethyst, 0.34);
|
|
19
18
|
$applyBtnBorder: 4px solid $brightTurquoise;
|
|
20
19
|
$focusBorder: 1px solid $topaz;
|
|
20
|
+
$tableRowBorder: 1px solid $titanWhite;
|
package/dist/scss/colors.scss
CHANGED
|
@@ -21,6 +21,7 @@ $doveGrayTwo: #6e6e6e;
|
|
|
21
21
|
$ebonyClay: #293445;
|
|
22
22
|
$gallery: #eee;
|
|
23
23
|
$gossamer: #0b9b7b;
|
|
24
|
+
$ghostWhite: #f5f7ff;
|
|
24
25
|
$grandis: #ffd077;
|
|
25
26
|
$grandisTwo: rgba($grandis, 0.36);
|
|
26
27
|
$gunsmoke: #7f8d89;
|
|
@@ -33,6 +34,7 @@ $java: #13bbb1;
|
|
|
33
34
|
$javaLight: #1fcc9e;
|
|
34
35
|
$javaTwo: rgba($java, 0.24);
|
|
35
36
|
$kimberly: #6d5e92;
|
|
37
|
+
$magnoliaWhite: #eef1ff;
|
|
36
38
|
$malibu: #869cff;
|
|
37
39
|
$malibuTwo: rgba($malibu, 0.12);
|
|
38
40
|
$maroonFlash: #bc2553;
|
package/dist/scss/common.scss
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
@import './colors';
|
|
2
2
|
@import './borders';
|
|
3
|
+
@import './variables';
|
|
3
4
|
|
|
4
5
|
#root {
|
|
5
6
|
z-index: 1;
|
|
@@ -122,7 +123,7 @@ textarea {
|
|
|
122
123
|
}
|
|
123
124
|
|
|
124
125
|
.form-table {
|
|
125
|
-
$tableHeaderHeight:
|
|
126
|
+
$tableHeaderHeight: 50px;
|
|
126
127
|
|
|
127
128
|
max-height: 500px;
|
|
128
129
|
overflow: hidden;
|
|
@@ -148,7 +149,9 @@ textarea {
|
|
|
148
149
|
background-color: $alabaster;
|
|
149
150
|
|
|
150
151
|
.form-table__cell {
|
|
151
|
-
|
|
152
|
+
&:not(.form-table__actions-cell) {
|
|
153
|
+
padding: 10px 15px;
|
|
154
|
+
}
|
|
152
155
|
}
|
|
153
156
|
}
|
|
154
157
|
|
|
@@ -239,9 +242,10 @@ textarea {
|
|
|
239
242
|
}
|
|
240
243
|
|
|
241
244
|
.form-table__actions-cell {
|
|
245
|
+
flex: 0 1 auto;
|
|
242
246
|
visibility: hidden;
|
|
243
247
|
justify-content: flex-end;
|
|
244
|
-
width:
|
|
248
|
+
min-width: $actionsCellWidth;
|
|
245
249
|
padding: 0;
|
|
246
250
|
|
|
247
251
|
& > * {
|
package/dist/scss/mixins.scss
CHANGED
|
@@ -14,14 +14,9 @@
|
|
|
14
14
|
flex-shrink: 1;
|
|
15
15
|
}
|
|
16
16
|
|
|
17
|
-
@mixin tableDet {
|
|
18
|
-
|
|
19
|
-
align-items: center;
|
|
17
|
+
@mixin tableDet($topPadding, $rightPadding, $bottomPadding, $leftPadding) {
|
|
18
|
+
padding: $topPadding $rightPadding $bottomPadding $leftPadding;
|
|
20
19
|
text-align: left;
|
|
21
|
-
|
|
22
|
-
&:first-child {
|
|
23
|
-
margin-left: 10px;
|
|
24
|
-
}
|
|
25
20
|
}
|
|
26
21
|
|
|
27
22
|
@mixin detailsMetadataStatisticsTable {
|
|
@@ -30,7 +25,6 @@
|
|
|
30
25
|
flex: 1;
|
|
31
26
|
flex-direction: column;
|
|
32
27
|
align-items: flex-start;
|
|
33
|
-
overflow-x: auto;
|
|
34
28
|
|
|
35
29
|
&-wrapper {
|
|
36
30
|
min-width: 100%;
|
|
@@ -42,7 +36,7 @@
|
|
|
42
36
|
z-index: 3;
|
|
43
37
|
display: flex;
|
|
44
38
|
min-width: 100%;
|
|
45
|
-
padding
|
|
39
|
+
padding: 15px 10px;
|
|
46
40
|
color: $topaz;
|
|
47
41
|
font-weight: bold;
|
|
48
42
|
background-color: $white;
|
|
@@ -380,16 +374,8 @@
|
|
|
380
374
|
line-height: $lineHeight;
|
|
381
375
|
}
|
|
382
376
|
|
|
383
|
-
@mixin tableHeader
|
|
384
|
-
|
|
385
|
-
justify-content: flex-start;
|
|
386
|
-
align-items: center;
|
|
387
|
-
height: auto;
|
|
388
|
-
min-height: 50px;
|
|
389
|
-
margin: 0 1px;
|
|
390
|
-
padding: $topPadding $rightPadding $bottomPadding $leftPadding;
|
|
391
|
-
text-align: left;
|
|
392
|
-
color: $topaz;
|
|
377
|
+
@mixin tableHeader {
|
|
378
|
+
background-color: $magnoliaWhite;
|
|
393
379
|
font-weight: bold;
|
|
394
380
|
font-size: 14px;
|
|
395
381
|
}
|
|
@@ -466,6 +452,7 @@
|
|
|
466
452
|
&-actions {
|
|
467
453
|
width: 44px;
|
|
468
454
|
max-width: 44px;
|
|
455
|
+
padding: 0;
|
|
469
456
|
}
|
|
470
457
|
}
|
|
471
458
|
|
package/dist/scss/shadows.scss
CHANGED
|
@@ -2,13 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
$jobsShadow: 0 3px 4px rgba($black, 0.18);
|
|
4
4
|
$headerShadow: inset 0 -1px 0 #edecef;
|
|
5
|
-
$mainHeaderShadow: 0 2px 4px -1px rgba($black, 0.2),
|
|
6
|
-
0
|
|
5
|
+
$mainHeaderShadow: 0 2px 4px -1px rgba($black, 0.2), 0 4px 5px 0 rgba($black, 0.14),
|
|
6
|
+
0 1px 10px 0 rgba($black, 0.12);
|
|
7
7
|
$filterShadow: 0 4px 8px rgba($black, 0.23);
|
|
8
8
|
$tooltipShadow: 0 5px 11px rgba($black, 0.18);
|
|
9
9
|
$hiddenChipsBlockShadow: 1px 3px 8px rgba($black, 0.2);
|
|
10
10
|
$previewBoxShadowInit: 0px 3px 10px rgba(0, 0, 0, 0.07);
|
|
11
|
-
$previewBoxShadow: 0
|
|
11
|
+
$previewBoxShadow: 0 3px 10px rgba($black, 0.3);
|
|
12
12
|
$projectStatisticsShadow: 0 8px 30px rgba($topaz, 0.08);
|
|
13
13
|
$dropdownShadow: 0 0 30px rgba($black, 0.15);
|
|
14
14
|
$tablePanelShadow: -3px 0 10px -5px rgba($black, 0.2);
|
package/dist/scss/variables.scss
CHANGED
package/dist/types.js
CHANGED
|
@@ -4,27 +4,36 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.WIZARD_STEPS_CONFIG = exports.SORT_PROPS = exports.SELECT_OPTIONS = exports.SELECT_OPTION = exports.POP_UP_CUSTOM_POSITION = exports.MODAL_SIZES = exports.INPUT_VALIDATION_RULES = exports.INPUT_LINK = exports.FORM_TABLE_EDITING_ITEM = exports.EXCLUDE_SORT_BY = exports.DEFAULT_SORT_BY = exports.CONFIRM_DIALOG_SUBMIT_BUTTON = exports.CONFIRM_DIALOG_CANCEL_BUTTON = exports.COMBOBOX_VALIDATION_RULES = exports.COMBOBOX_SUGGESTION_LIST = exports.COMBOBOX_SELECT_OPTIONS = exports.CHIP_OPTIONS = exports.CHIP_INPUT_LIST = exports.CHIPS = exports.CHIP = exports.BUTTON_VARIANTS = exports.ALLOW_SORT_BY = void 0;
|
|
7
|
-
|
|
8
7
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
9
|
-
|
|
10
8
|
var _constants = require("./constants");
|
|
11
|
-
|
|
12
9
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
13
|
-
|
|
14
|
-
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
15
|
-
|
|
10
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
11
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
12
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
13
|
+
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); } /*
|
|
14
|
+
Copyright 2022 Iguazio Systems Ltd.
|
|
15
|
+
Licensed under the Apache License, Version 2.0 (the "License") with
|
|
16
|
+
an addition restriction as set forth herein. You may not use this
|
|
17
|
+
file except in compliance with the License. You may obtain a copy of
|
|
18
|
+
the License at http://www.apache.org/licenses/LICENSE-2.0.
|
|
19
|
+
Unless required by applicable law or agreed to in writing, software
|
|
20
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
21
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
22
|
+
implied. See the License for the specific language governing
|
|
23
|
+
permissions and limitations under the License.
|
|
24
|
+
In addition, you may not use the software for any purposes that are
|
|
25
|
+
illegal under applicable law, and the grant of the foregoing license
|
|
26
|
+
under the Apache 2.0 license is conditioned upon your compliance with
|
|
27
|
+
such restriction.
|
|
28
|
+
*/
|
|
16
29
|
var BUTTON_VARIANTS = _propTypes.default.oneOf([_constants.DANGER_BUTTON, _constants.LABEL_BUTTON, _constants.PRIMARY_BUTTON, _constants.SECONDARY_BUTTON, _constants.TERTIARY_BUTTON]);
|
|
17
|
-
|
|
18
30
|
exports.BUTTON_VARIANTS = BUTTON_VARIANTS;
|
|
19
|
-
|
|
20
31
|
var CHIP = _propTypes.default.shape({
|
|
21
32
|
delimiter: _propTypes.default.element,
|
|
22
33
|
id: _propTypes.default.string,
|
|
23
34
|
value: _propTypes.default.string.isRequired
|
|
24
35
|
});
|
|
25
|
-
|
|
26
36
|
exports.CHIP = CHIP;
|
|
27
|
-
|
|
28
37
|
var CHIP_INPUT_LIST = _propTypes.default.arrayOf(_propTypes.default.shape({
|
|
29
38
|
disabled: _propTypes.default.bool,
|
|
30
39
|
icon: _propTypes.default.element,
|
|
@@ -33,9 +42,7 @@ var CHIP_INPUT_LIST = _propTypes.default.arrayOf(_propTypes.default.shape({
|
|
|
33
42
|
subLabel: _propTypes.default.string,
|
|
34
43
|
ui: _propTypes.default.shape({})
|
|
35
44
|
}));
|
|
36
|
-
|
|
37
45
|
exports.CHIP_INPUT_LIST = CHIP_INPUT_LIST;
|
|
38
|
-
|
|
39
46
|
var CHIP_OPTIONS = _propTypes.default.shape({
|
|
40
47
|
background: _propTypes.default.oneOf(['amethyst', 'green', 'grey', 'java', 'none', 'orange', 'purple', 'sorbus']),
|
|
41
48
|
boldValue: _propTypes.default.bool,
|
|
@@ -44,55 +51,39 @@ var CHIP_OPTIONS = _propTypes.default.shape({
|
|
|
44
51
|
font: _propTypes.default.oneOf(['primary', 'white', 'green', 'purple', 'orange']),
|
|
45
52
|
borderRadius: _propTypes.default.oneOf(['primary', 'secondary'])
|
|
46
53
|
});
|
|
47
|
-
|
|
48
54
|
exports.CHIP_OPTIONS = CHIP_OPTIONS;
|
|
49
|
-
|
|
50
55
|
var CHIPS = _propTypes.default.arrayOf(CHIP);
|
|
51
|
-
|
|
52
56
|
exports.CHIPS = CHIPS;
|
|
53
|
-
|
|
54
57
|
var POP_UP_CUSTOM_POSITION = _propTypes.default.shape({
|
|
55
58
|
element: _propTypes.default.shape({}),
|
|
56
59
|
position: _propTypes.default.oneOf(['top-left', 'top-right', 'bottom-left', 'bottom-right'])
|
|
57
60
|
});
|
|
58
|
-
|
|
59
61
|
exports.POP_UP_CUSTOM_POSITION = POP_UP_CUSTOM_POSITION;
|
|
60
|
-
|
|
61
62
|
var MODAL_SIZES = _propTypes.default.oneOf([_constants.MODAL_SM, _constants.MODAL_MD, _constants.MODAL_LG, _constants.MODAL_MIN, _constants.MODAL_MAX]);
|
|
62
|
-
|
|
63
63
|
exports.MODAL_SIZES = MODAL_SIZES;
|
|
64
|
-
|
|
65
64
|
var CONFIRM_DIALOG_CANCEL_BUTTON = _propTypes.default.shape({
|
|
66
65
|
handler: _propTypes.default.func,
|
|
67
66
|
label: _propTypes.default.string.isRequired,
|
|
68
67
|
variant: _propTypes.default.string.isRequired
|
|
69
68
|
});
|
|
70
|
-
|
|
71
69
|
exports.CONFIRM_DIALOG_CANCEL_BUTTON = CONFIRM_DIALOG_CANCEL_BUTTON;
|
|
72
|
-
|
|
73
70
|
var CONFIRM_DIALOG_SUBMIT_BUTTON = _propTypes.default.shape({
|
|
74
71
|
handler: _propTypes.default.func.isRequired,
|
|
75
72
|
label: _propTypes.default.string.isRequired,
|
|
76
73
|
variant: _propTypes.default.string.isRequired
|
|
77
74
|
});
|
|
78
|
-
|
|
79
75
|
exports.CONFIRM_DIALOG_SUBMIT_BUTTON = CONFIRM_DIALOG_SUBMIT_BUTTON;
|
|
80
|
-
|
|
81
76
|
var WIZARD_STEPS_CONFIG = _propTypes.default.arrayOf(_propTypes.default.shape({
|
|
82
77
|
id: _propTypes.default.string,
|
|
83
78
|
label: _propTypes.default.string,
|
|
84
79
|
getActions: _propTypes.default.func
|
|
85
80
|
}));
|
|
86
|
-
|
|
87
81
|
exports.WIZARD_STEPS_CONFIG = WIZARD_STEPS_CONFIG;
|
|
88
|
-
|
|
89
82
|
var INPUT_LINK = _propTypes.default.shape({
|
|
90
83
|
show: _propTypes.default.oneOfType([_propTypes.default.bool, _propTypes.default.string]),
|
|
91
84
|
url: _propTypes.default.string
|
|
92
85
|
});
|
|
93
|
-
|
|
94
86
|
exports.INPUT_LINK = INPUT_LINK;
|
|
95
|
-
|
|
96
87
|
var SELECT_OPTION = _propTypes.default.shape({
|
|
97
88
|
disabled: _propTypes.default.bool,
|
|
98
89
|
hidden: _propTypes.default.bool,
|
|
@@ -102,46 +93,34 @@ var SELECT_OPTION = _propTypes.default.shape({
|
|
|
102
93
|
status: _propTypes.default.string,
|
|
103
94
|
subLabel: _propTypes.default.string
|
|
104
95
|
});
|
|
105
|
-
|
|
106
96
|
exports.SELECT_OPTION = SELECT_OPTION;
|
|
107
|
-
|
|
108
97
|
var SELECT_OPTIONS = _propTypes.default.arrayOf(SELECT_OPTION);
|
|
109
|
-
|
|
110
98
|
exports.SELECT_OPTIONS = SELECT_OPTIONS;
|
|
111
|
-
|
|
112
99
|
var INPUT_VALIDATION_RULES = _propTypes.default.arrayOf(_propTypes.default.shape({
|
|
113
100
|
name: _propTypes.default.string.isRequired,
|
|
114
101
|
label: _propTypes.default.string.isRequired,
|
|
115
102
|
pattern: _propTypes.default.oneOfType([_propTypes.default.instanceOf(RegExp), _propTypes.default.func]).isRequired,
|
|
116
103
|
isValid: _propTypes.default.bool
|
|
117
104
|
}));
|
|
118
|
-
|
|
119
105
|
exports.INPUT_VALIDATION_RULES = INPUT_VALIDATION_RULES;
|
|
120
|
-
|
|
121
106
|
var COMBOBOX_SUGGESTION_LIST = _propTypes.default.arrayOf(_propTypes.default.shape({
|
|
122
107
|
customDelimiter: _propTypes.default.string,
|
|
123
108
|
id: _propTypes.default.string.isRequired,
|
|
124
109
|
label: _propTypes.default.string.isRequired
|
|
125
110
|
}));
|
|
126
|
-
|
|
127
111
|
exports.COMBOBOX_SUGGESTION_LIST = COMBOBOX_SUGGESTION_LIST;
|
|
128
|
-
|
|
129
112
|
var COMBOBOX_VALIDATION_RULES = _propTypes.default.arrayOf(_propTypes.default.shape({
|
|
130
113
|
name: _propTypes.default.string.isRequired,
|
|
131
114
|
label: _propTypes.default.string.isRequired,
|
|
132
115
|
isValid: _propTypes.default.bool
|
|
133
116
|
}));
|
|
134
|
-
|
|
135
117
|
exports.COMBOBOX_VALIDATION_RULES = COMBOBOX_VALIDATION_RULES;
|
|
136
|
-
|
|
137
118
|
var COMBOBOX_SELECT_OPTIONS = _propTypes.default.arrayOf(_propTypes.default.shape({
|
|
138
119
|
className: _propTypes.default.string,
|
|
139
120
|
id: _propTypes.default.string.isRequired,
|
|
140
121
|
label: _propTypes.default.string.isRequired
|
|
141
122
|
}));
|
|
142
|
-
|
|
143
123
|
exports.COMBOBOX_SELECT_OPTIONS = COMBOBOX_SELECT_OPTIONS;
|
|
144
|
-
|
|
145
124
|
var FORM_TABLE_EDITING_ITEM = _propTypes.default.shape(_defineProperty({
|
|
146
125
|
data: _propTypes.default.shape({}).isRequired,
|
|
147
126
|
ui: _propTypes.default.shape({
|
|
@@ -150,25 +129,16 @@ var FORM_TABLE_EDITING_ITEM = _propTypes.default.shape(_defineProperty({
|
|
|
150
129
|
fieldsPath: _propTypes.default.string.isRequired
|
|
151
130
|
}).isRequired
|
|
152
131
|
}, _propTypes.default.string, _propTypes.default.any));
|
|
153
|
-
|
|
154
132
|
exports.FORM_TABLE_EDITING_ITEM = FORM_TABLE_EDITING_ITEM;
|
|
155
|
-
|
|
156
133
|
var SORT_PROPS = _propTypes.default.shape({
|
|
157
134
|
selectedColumnName: _propTypes.default.string.isRequired,
|
|
158
135
|
getSortingIcon: _propTypes.default.func.isRequired,
|
|
159
136
|
sortTable: _propTypes.default.func.isRequired
|
|
160
137
|
});
|
|
161
|
-
|
|
162
138
|
exports.SORT_PROPS = SORT_PROPS;
|
|
163
|
-
|
|
164
139
|
var ALLOW_SORT_BY = _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.number, _propTypes.default.arrayOf(_propTypes.default.string, _propTypes.default.number)]);
|
|
165
|
-
|
|
166
140
|
exports.ALLOW_SORT_BY = ALLOW_SORT_BY;
|
|
167
|
-
|
|
168
141
|
var DEFAULT_SORT_BY = _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.number]);
|
|
169
|
-
|
|
170
142
|
exports.DEFAULT_SORT_BY = DEFAULT_SORT_BY;
|
|
171
|
-
|
|
172
143
|
var EXCLUDE_SORT_BY = _propTypes.default.oneOfType([_propTypes.default.string, _propTypes.default.number, _propTypes.default.arrayOf(_propTypes.default.string, _propTypes.default.number)]);
|
|
173
|
-
|
|
174
144
|
exports.EXCLUDE_SORT_BY = EXCLUDE_SORT_BY;
|
|
@@ -4,15 +4,10 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.openPopUp = exports.openConfirmPopUp = exports.isEveryObjectValueEmpty = exports.areArraysEqual = void 0;
|
|
7
|
-
|
|
8
7
|
var _reactModalPromise = require("react-modal-promise");
|
|
9
|
-
|
|
10
8
|
var _lodash = require("lodash");
|
|
11
|
-
|
|
12
9
|
var _components = require("../components");
|
|
13
|
-
|
|
14
10
|
var _constants = require("../constants");
|
|
15
|
-
|
|
16
11
|
/*
|
|
17
12
|
Copyright 2022 Iguazio Systems Ltd.
|
|
18
13
|
Licensed under the Apache License, Version 2.0 (the "License") with
|
|
@@ -29,12 +24,11 @@ illegal under applicable law, and the grant of the foregoing license
|
|
|
29
24
|
under the Apache 2.0 license is conditioned upon your compliance with
|
|
30
25
|
such restriction.
|
|
31
26
|
*/
|
|
27
|
+
|
|
32
28
|
var openPopUp = function openPopUp(element, props) {
|
|
33
29
|
return (0, _reactModalPromise.create)(element)(props);
|
|
34
30
|
};
|
|
35
|
-
|
|
36
31
|
exports.openPopUp = openPopUp;
|
|
37
|
-
|
|
38
32
|
var openConfirmPopUp = function openConfirmPopUp(confirmHandler, message) {
|
|
39
33
|
return openPopUp(_components.ConfirmDialog, {
|
|
40
34
|
cancelButton: {
|
|
@@ -50,18 +44,15 @@ var openConfirmPopUp = function openConfirmPopUp(confirmHandler, message) {
|
|
|
50
44
|
message: message
|
|
51
45
|
});
|
|
52
46
|
};
|
|
53
|
-
|
|
54
47
|
exports.openConfirmPopUp = openConfirmPopUp;
|
|
55
|
-
|
|
56
48
|
var isEveryObjectValueEmpty = function isEveryObjectValueEmpty(obj) {
|
|
57
49
|
return Object.values(obj).every(function (item) {
|
|
58
50
|
return !item || item.length === 0;
|
|
59
51
|
});
|
|
60
|
-
};
|
|
61
|
-
|
|
52
|
+
};
|
|
62
53
|
|
|
54
|
+
// Checks, whether two arrays of objects are equal, can omit some keys if their comparison is not necessary
|
|
63
55
|
exports.isEveryObjectValueEmpty = isEveryObjectValueEmpty;
|
|
64
|
-
|
|
65
56
|
var areArraysEqual = function areArraysEqual(firstArray, secondArray) {
|
|
66
57
|
var omitBy = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : [];
|
|
67
58
|
if (firstArray.length !== secondArray.length) return false;
|
|
@@ -69,5 +60,4 @@ var areArraysEqual = function areArraysEqual(firstArray, secondArray) {
|
|
|
69
60
|
return (0, _lodash.isEqual)((0, _lodash.omit)(a, omitBy), (0, _lodash.omit)(b, omitBy));
|
|
70
61
|
}));
|
|
71
62
|
};
|
|
72
|
-
|
|
73
63
|
exports.areArraysEqual = areArraysEqual;
|
package/dist/utils/form.util.js
CHANGED
|
@@ -4,49 +4,49 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.setFieldState = exports.parseObjectToKeyValue = exports.generateObjectFromKeyValue = exports.areFormValuesChanged = void 0;
|
|
7
|
-
|
|
8
7
|
var _lodash = require("lodash");
|
|
9
|
-
|
|
10
8
|
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
11
|
-
|
|
12
9
|
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
13
|
-
|
|
14
10
|
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
15
|
-
|
|
16
|
-
function
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
11
|
+
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
12
|
+
function _iterableToArrayLimit(arr, i) { var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0); } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i.return && (_r = _i.return(), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }
|
|
13
|
+
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; } /*
|
|
14
|
+
Copyright 2022 Iguazio Systems Ltd.
|
|
15
|
+
Licensed under the Apache License, Version 2.0 (the "License") with
|
|
16
|
+
an addition restriction as set forth herein. You may not use this
|
|
17
|
+
file except in compliance with the License. You may obtain a copy of
|
|
18
|
+
the License at http://www.apache.org/licenses/LICENSE-2.0.
|
|
19
|
+
Unless required by applicable law or agreed to in writing, software
|
|
20
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
21
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
22
|
+
implied. See the License for the specific language governing
|
|
23
|
+
permissions and limitations under the License.
|
|
24
|
+
In addition, you may not use the software for any purposes that are
|
|
25
|
+
illegal under applicable law, and the grant of the foregoing license
|
|
26
|
+
under the Apache 2.0 license is conditioned upon your compliance with
|
|
27
|
+
such restriction.
|
|
28
|
+
*/
|
|
22
29
|
var setFieldState = function setFieldState(args, state) {
|
|
23
30
|
var fieldName = args[0];
|
|
24
31
|
var states = args[1];
|
|
25
32
|
var field = state.fields[fieldName];
|
|
26
|
-
|
|
27
33
|
if (field) {
|
|
28
34
|
for (var stateName in states) {
|
|
29
35
|
(0, _lodash.set)(field, stateName, states[stateName]);
|
|
30
36
|
}
|
|
31
37
|
}
|
|
32
38
|
};
|
|
33
|
-
|
|
34
39
|
exports.setFieldState = setFieldState;
|
|
35
|
-
|
|
36
40
|
var areFormValuesChanged = function areFormValuesChanged(initialValues, values) {
|
|
37
41
|
var replacer = function replacer(key, value) {
|
|
38
42
|
if (value === '') {
|
|
39
43
|
return undefined;
|
|
40
44
|
}
|
|
41
|
-
|
|
42
45
|
return value;
|
|
43
46
|
};
|
|
44
|
-
|
|
45
47
|
return !(0, _lodash.isEqual)(JSON.stringify(initialValues, replacer), JSON.stringify(values, replacer));
|
|
46
48
|
};
|
|
47
|
-
|
|
48
49
|
exports.areFormValuesChanged = areFormValuesChanged;
|
|
49
|
-
|
|
50
50
|
var generateObjectFromKeyValue = function generateObjectFromKeyValue() {
|
|
51
51
|
var keyValueList = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
|
|
52
52
|
return keyValueList.reduce(function (acc, keyValue) {
|
|
@@ -54,16 +54,13 @@ var generateObjectFromKeyValue = function generateObjectFromKeyValue() {
|
|
|
54
54
|
return acc;
|
|
55
55
|
}, {});
|
|
56
56
|
};
|
|
57
|
-
|
|
58
57
|
exports.generateObjectFromKeyValue = generateObjectFromKeyValue;
|
|
59
|
-
|
|
60
58
|
var parseObjectToKeyValue = function parseObjectToKeyValue() {
|
|
61
59
|
var object = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
62
60
|
return Object.entries(object).map(function (_ref) {
|
|
63
61
|
var _ref2 = _slicedToArray(_ref, 2),
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
62
|
+
key = _ref2[0],
|
|
63
|
+
value = _ref2[1];
|
|
67
64
|
return {
|
|
68
65
|
data: {
|
|
69
66
|
key: key,
|
|
@@ -72,5 +69,4 @@ var parseObjectToKeyValue = function parseObjectToKeyValue() {
|
|
|
72
69
|
};
|
|
73
70
|
});
|
|
74
71
|
};
|
|
75
|
-
|
|
76
72
|
exports.parseObjectToKeyValue = parseObjectToKeyValue;
|
|
@@ -4,7 +4,6 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.generateChipsList = void 0;
|
|
7
|
-
|
|
8
7
|
/*
|
|
9
8
|
Copyright 2022 Iguazio Systems Ltd.
|
|
10
9
|
Licensed under the Apache License, Version 2.0 (the "License") with
|
|
@@ -32,11 +31,9 @@ var generateChipsList = function generateChipsList(chips, maxLength) {
|
|
|
32
31
|
hiddenChipsNumber: hiddenChipsNumber
|
|
33
32
|
};
|
|
34
33
|
}
|
|
35
|
-
|
|
36
34
|
return {
|
|
37
35
|
visibleChips: chips,
|
|
38
36
|
hiddenChips: []
|
|
39
37
|
};
|
|
40
38
|
};
|
|
41
|
-
|
|
42
39
|
exports.generateChipsList = generateChipsList;
|
|
@@ -4,7 +4,6 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.getFirstScrollableParentUtil = void 0;
|
|
7
|
-
|
|
8
7
|
/*
|
|
9
8
|
Copyright 2022 Iguazio Systems Ltd.
|
|
10
9
|
Licensed under the Apache License, Version 2.0 (the "License") with
|
|
@@ -22,17 +21,13 @@ under the Apache 2.0 license is conditioned upon your compliance with
|
|
|
22
21
|
such restriction.
|
|
23
22
|
*/
|
|
24
23
|
var regex = /(auto|scroll|hidden)/;
|
|
25
|
-
|
|
26
24
|
var style = function style(node, prop) {
|
|
27
25
|
return getComputedStyle(node, null).getPropertyValue(prop);
|
|
28
26
|
};
|
|
29
|
-
|
|
30
27
|
var scroll = function scroll(node) {
|
|
31
28
|
return regex.test(style(node, 'overflow') + style(node, 'overflow-y') + style(node, 'overflow-x'));
|
|
32
29
|
};
|
|
33
|
-
|
|
34
30
|
var getFirstScrollableParentUtil = function getFirstScrollableParentUtil(node) {
|
|
35
31
|
return !node || node === document.body ? document.body : scroll(node) ? node : getFirstScrollableParentUtil(node.parentNode);
|
|
36
32
|
};
|
|
37
|
-
|
|
38
33
|
exports.getFirstScrollableParentUtil = getFirstScrollableParentUtil;
|