@zendeskgarden/react-dropdowns 9.12.3 → 9.12.5
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/esm/elements/combobox/Combobox.js +32 -33
- package/dist/esm/elements/combobox/Label.js +6 -7
- package/dist/esm/elements/combobox/Listbox.js +16 -18
- package/dist/esm/elements/combobox/OptGroup.js +9 -10
- package/dist/esm/elements/combobox/Option.js +13 -14
- package/dist/esm/elements/combobox/Tag.js +7 -8
- package/dist/esm/elements/combobox/TagGroup.js +20 -23
- package/dist/esm/elements/menu/Item.js +16 -17
- package/dist/esm/elements/menu/ItemGroup.js +9 -10
- package/dist/esm/elements/menu/Menu.js +18 -19
- package/dist/esm/elements/menu/MenuList.js +19 -21
- package/dist/esm/elements/menu/Separator.js +4 -5
- package/dist/esm/node_modules/@zendeskgarden/svg-icons/src/16/check-lg-stroke.svg.js +2 -2
- package/dist/esm/node_modules/@zendeskgarden/svg-icons/src/16/chevron-down-stroke.svg.js +4 -4
- package/dist/esm/node_modules/@zendeskgarden/svg-icons/src/16/chevron-left-stroke.svg.js +4 -4
- package/dist/esm/node_modules/@zendeskgarden/svg-icons/src/16/chevron-right-stroke.svg.js +4 -4
- package/dist/esm/node_modules/@zendeskgarden/svg-icons/src/16/plus-stroke.svg.js +4 -4
- package/dist/esm/views/combobox/StyledCombobox.js +5 -5
- package/dist/esm/views/combobox/StyledContainer.js +3 -3
- package/dist/esm/views/combobox/StyledField.js +3 -3
- package/dist/esm/views/combobox/StyledFloatingListbox.js +3 -3
- package/dist/esm/views/combobox/StyledHint.js +3 -3
- package/dist/esm/views/combobox/StyledInput.js +10 -11
- package/dist/esm/views/combobox/StyledInputGroup.js +5 -5
- package/dist/esm/views/combobox/StyledInputIcon.js +9 -10
- package/dist/esm/views/combobox/StyledLabel.js +3 -3
- package/dist/esm/views/combobox/StyledListbox.js +5 -5
- package/dist/esm/views/combobox/StyledListboxSeparator.js +8 -9
- package/dist/esm/views/combobox/StyledMessage.js +3 -3
- package/dist/esm/views/combobox/StyledOptGroup.js +3 -3
- package/dist/esm/views/combobox/StyledOption.js +10 -11
- package/dist/esm/views/combobox/StyledOptionContent.js +3 -3
- package/dist/esm/views/combobox/StyledOptionIcon.js +10 -11
- package/dist/esm/views/combobox/StyledOptionMeta.js +9 -10
- package/dist/esm/views/combobox/StyledOptionSelectionIcon.js +11 -13
- package/dist/esm/views/combobox/StyledOptionTypeIcon.js +9 -10
- package/dist/esm/views/combobox/StyledTag.js +3 -3
- package/dist/esm/views/combobox/StyledTagsButton.js +6 -7
- package/dist/esm/views/combobox/StyledTrigger.js +12 -13
- package/dist/esm/views/combobox/StyledValue.js +8 -9
- package/dist/esm/views/menu/StyledFloatingMenu.js +3 -3
- package/dist/esm/views/menu/StyledItem.js +3 -3
- package/dist/esm/views/menu/StyledItemAnchor.js +3 -3
- package/dist/esm/views/menu/StyledItemContent.js +3 -3
- package/dist/esm/views/menu/StyledItemGroup.js +3 -3
- package/dist/esm/views/menu/StyledItemIcon.js +3 -3
- package/dist/esm/views/menu/StyledItemMeta.js +3 -3
- package/dist/esm/views/menu/StyledItemTypeIcon.js +3 -3
- package/dist/esm/views/menu/StyledMenu.js +3 -3
- package/dist/esm/views/menu/StyledSeparator.js +1 -1
- package/dist/index.cjs.js +250 -278
- package/package.json +8 -8
package/dist/index.cjs.js
CHANGED
|
@@ -83,7 +83,7 @@ const useFieldContext = () => {
|
|
|
83
83
|
const COMPONENT_ID$w = 'dropdowns.combobox.label';
|
|
84
84
|
const StyledLabel = styled__default.default(reactForms.Field.Label).attrs({
|
|
85
85
|
'data-garden-id': COMPONENT_ID$w,
|
|
86
|
-
'data-garden-version': '9.12.
|
|
86
|
+
'data-garden-version': '9.12.5'
|
|
87
87
|
}).withConfig({
|
|
88
88
|
displayName: "StyledLabel",
|
|
89
89
|
componentId: "sc-az6now-0"
|
|
@@ -92,7 +92,7 @@ const StyledLabel = styled__default.default(reactForms.Field.Label).attrs({
|
|
|
92
92
|
const COMPONENT_ID$v = 'dropdowns.combobox.hint';
|
|
93
93
|
const StyledHint = styled__default.default(reactForms.Field.Hint).attrs({
|
|
94
94
|
'data-garden-id': COMPONENT_ID$v,
|
|
95
|
-
'data-garden-version': '9.12.
|
|
95
|
+
'data-garden-version': '9.12.5'
|
|
96
96
|
}).withConfig({
|
|
97
97
|
displayName: "StyledHint",
|
|
98
98
|
componentId: "sc-106qvqx-0"
|
|
@@ -101,7 +101,7 @@ const StyledHint = styled__default.default(reactForms.Field.Hint).attrs({
|
|
|
101
101
|
const COMPONENT_ID$u = 'dropdowns.combobox.message';
|
|
102
102
|
const StyledMessage = styled__default.default(reactForms.Field.Message).attrs({
|
|
103
103
|
'data-garden-id': COMPONENT_ID$u,
|
|
104
|
-
'data-garden-version': '9.12.
|
|
104
|
+
'data-garden-version': '9.12.5'
|
|
105
105
|
}).withConfig({
|
|
106
106
|
displayName: "StyledMessage",
|
|
107
107
|
componentId: "sc-jux8m5-0"
|
|
@@ -115,7 +115,7 @@ const sizeStyles$b = props => {
|
|
|
115
115
|
};
|
|
116
116
|
const StyledCombobox = styled__default.default.div.attrs({
|
|
117
117
|
'data-garden-id': COMPONENT_ID$t,
|
|
118
|
-
'data-garden-version': '9.12.
|
|
118
|
+
'data-garden-version': '9.12.5'
|
|
119
119
|
}).withConfig({
|
|
120
120
|
displayName: "StyledCombobox",
|
|
121
121
|
componentId: "sc-13eybg8-0"
|
|
@@ -124,7 +124,7 @@ const StyledCombobox = styled__default.default.div.attrs({
|
|
|
124
124
|
const COMPONENT_ID$s = 'dropdowns.combobox.container';
|
|
125
125
|
const StyledContainer = styled__default.default.div.attrs({
|
|
126
126
|
'data-garden-id': COMPONENT_ID$s,
|
|
127
|
-
'data-garden-version': '9.12.
|
|
127
|
+
'data-garden-version': '9.12.5'
|
|
128
128
|
}).withConfig({
|
|
129
129
|
displayName: "StyledContainer",
|
|
130
130
|
componentId: "sc-14i9jid-0"
|
|
@@ -133,7 +133,7 @@ const StyledContainer = styled__default.default.div.attrs({
|
|
|
133
133
|
const COMPONENT_ID$r = 'dropdowns.combobox.field';
|
|
134
134
|
const StyledField = styled__default.default.div.attrs({
|
|
135
135
|
'data-garden-id': COMPONENT_ID$r,
|
|
136
|
-
'data-garden-version': '9.12.
|
|
136
|
+
'data-garden-version': '9.12.5'
|
|
137
137
|
}).withConfig({
|
|
138
138
|
displayName: "StyledField",
|
|
139
139
|
componentId: "sc-zc57xl-0"
|
|
@@ -142,7 +142,7 @@ const StyledField = styled__default.default.div.attrs({
|
|
|
142
142
|
const COMPONENT_ID$q = 'dropdowns.combobox.floating';
|
|
143
143
|
const StyledFloatingListbox = styled__default.default.div.attrs({
|
|
144
144
|
'data-garden-id': COMPONENT_ID$q,
|
|
145
|
-
'data-garden-version': '9.12.
|
|
145
|
+
'data-garden-version': '9.12.5'
|
|
146
146
|
}).withConfig({
|
|
147
147
|
displayName: "StyledFloatingListbox",
|
|
148
148
|
componentId: "sc-1cp6spf-0"
|
|
@@ -154,10 +154,9 @@ const StyledFloatingListbox = styled__default.default.div.attrs({
|
|
|
154
154
|
}), reactTheming.componentStyles);
|
|
155
155
|
|
|
156
156
|
const COMPONENT_ID$p = 'dropdowns.combobox.input';
|
|
157
|
-
const colorStyles$a =
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
} = _ref;
|
|
157
|
+
const colorStyles$a = ({
|
|
158
|
+
theme
|
|
159
|
+
}) => {
|
|
161
160
|
const placeholderColor = reactTheming.getColor({
|
|
162
161
|
theme,
|
|
163
162
|
variable: 'foreground.disabled'
|
|
@@ -180,7 +179,7 @@ const sizeStyles$a = props => {
|
|
|
180
179
|
};
|
|
181
180
|
const StyledInput = styled__default.default.input.attrs({
|
|
182
181
|
'data-garden-id': COMPONENT_ID$p,
|
|
183
|
-
'data-garden-version': '9.12.
|
|
182
|
+
'data-garden-version': '9.12.5'
|
|
184
183
|
}).withConfig({
|
|
185
184
|
displayName: "StyledInput",
|
|
186
185
|
componentId: "sc-1lkqdg-0"
|
|
@@ -193,21 +192,20 @@ const sizeStyles$9 = props => {
|
|
|
193
192
|
};
|
|
194
193
|
const StyledInputGroup = styled__default.default.div.attrs({
|
|
195
194
|
'data-garden-id': COMPONENT_ID$o,
|
|
196
|
-
'data-garden-version': '9.12.
|
|
195
|
+
'data-garden-version': '9.12.5'
|
|
197
196
|
}).withConfig({
|
|
198
197
|
displayName: "StyledInputGroup",
|
|
199
198
|
componentId: "sc-yx3q7u-0"
|
|
200
199
|
})(["display:flex;flex-grow:1;flex-wrap:wrap;", ";", ";"], sizeStyles$9, reactTheming.componentStyles);
|
|
201
200
|
|
|
202
201
|
const COMPONENT_ID$n = 'dropdowns.combobox.trigger';
|
|
203
|
-
const colorStyles$9 =
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
} = _ref;
|
|
202
|
+
const colorStyles$9 = ({
|
|
203
|
+
theme,
|
|
204
|
+
$validation,
|
|
205
|
+
$isBare,
|
|
206
|
+
$isLabelHovered,
|
|
207
|
+
$focusInset
|
|
208
|
+
}) => {
|
|
211
209
|
const foregroundColor = reactTheming.getColor({
|
|
212
210
|
theme,
|
|
213
211
|
variable: 'foreground.default'
|
|
@@ -303,18 +301,17 @@ const sizeStyles$8 = props => {
|
|
|
303
301
|
};
|
|
304
302
|
const StyledTrigger = styled__default.default.div.attrs({
|
|
305
303
|
'data-garden-id': COMPONENT_ID$n,
|
|
306
|
-
'data-garden-version': '9.12.
|
|
304
|
+
'data-garden-version': '9.12.5'
|
|
307
305
|
}).withConfig({
|
|
308
306
|
displayName: "StyledTrigger",
|
|
309
307
|
componentId: "sc-116nftk-0"
|
|
310
308
|
})(["overflow-y:", ";transition:border-color 0.25s ease-in-out,box-shadow 0.1s ease-in-out,background-color 0.25s ease-in-out,color 0.25s ease-in-out;border:", ";border-radius:", ";cursor:", ";box-sizing:border-box;", ";&:focus{outline:none;}", ";&[aria-disabled='true']{cursor:default;}", ";"], props => props.$isBare && !props.$isMultiselectable ? 'visible' : 'auto', props => props.$isBare ? 'none' : props.theme.borders.sm, props => props.$isBare ? '0' : props.theme.borderRadii.md, props => !props.$isAutocomplete && props.$isEditable ? 'text' : 'pointer', sizeStyles$8, colorStyles$9, reactTheming.componentStyles);
|
|
311
309
|
|
|
312
310
|
const COMPONENT_ID$m = 'dropdowns.combobox.input_icon';
|
|
313
|
-
const colorStyles$8 =
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
} = _ref;
|
|
311
|
+
const colorStyles$8 = ({
|
|
312
|
+
theme,
|
|
313
|
+
$isLabelHovered
|
|
314
|
+
}) => {
|
|
318
315
|
const options = {
|
|
319
316
|
theme,
|
|
320
317
|
variable: 'foreground.subtle'
|
|
@@ -349,19 +346,18 @@ const sizeStyles$7 = props => {
|
|
|
349
346
|
};
|
|
350
347
|
const StyledInputIcon = styled__default.default(reactTheming.StyledBaseIcon).attrs({
|
|
351
348
|
'data-garden-id': COMPONENT_ID$m,
|
|
352
|
-
'data-garden-version': '9.12.
|
|
349
|
+
'data-garden-version': '9.12.5'
|
|
353
350
|
}).withConfig({
|
|
354
351
|
displayName: "StyledInputIcon",
|
|
355
352
|
componentId: "sc-gqbs1s-0"
|
|
356
353
|
})(["position:sticky;flex-shrink:0;transform:", ";transition:transform 0.25s ease-in-out,color 0.25s ease-in-out;", ";", ";", ";"], props => props.$isRotated && `rotate(${props.theme.rtl ? '-' : '+'}180deg)`, sizeStyles$7, colorStyles$8, reactTheming.componentStyles);
|
|
357
354
|
|
|
358
355
|
const COMPONENT_ID$l = 'dropdowns.combobox.option';
|
|
359
|
-
const colorStyles$7 =
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
} = _ref;
|
|
356
|
+
const colorStyles$7 = ({
|
|
357
|
+
theme,
|
|
358
|
+
$isActive,
|
|
359
|
+
$type
|
|
360
|
+
}) => {
|
|
365
361
|
let backgroundColor;
|
|
366
362
|
let boxShadow;
|
|
367
363
|
if ($isActive && $type !== 'group' && $type !== 'header') {
|
|
@@ -404,7 +400,7 @@ const sizeStyles$6 = props => {
|
|
|
404
400
|
};
|
|
405
401
|
const StyledOption = styled__default.default.li.attrs({
|
|
406
402
|
'data-garden-id': COMPONENT_ID$l,
|
|
407
|
-
'data-garden-version': '9.12.
|
|
403
|
+
'data-garden-version': '9.12.5'
|
|
408
404
|
}).withConfig({
|
|
409
405
|
displayName: "StyledOption",
|
|
410
406
|
componentId: "sc-jl4wn6-0"
|
|
@@ -413,7 +409,7 @@ const StyledOption = styled__default.default.li.attrs({
|
|
|
413
409
|
const COMPONENT_ID$k = 'dropdowns.combobox.option.content';
|
|
414
410
|
const StyledOptionContent = styled__default.default.div.attrs({
|
|
415
411
|
'data-garden-id': COMPONENT_ID$k,
|
|
416
|
-
'data-garden-version': '9.12.
|
|
412
|
+
'data-garden-version': '9.12.5'
|
|
417
413
|
}).withConfig({
|
|
418
414
|
displayName: "StyledOptionContent",
|
|
419
415
|
componentId: "sc-121ujpu-0"
|
|
@@ -422,17 +418,16 @@ const StyledOptionContent = styled__default.default.div.attrs({
|
|
|
422
418
|
const COMPONENT_ID$j = 'dropdowns.combobox.optgroup';
|
|
423
419
|
const StyledOptGroup = styled__default.default.ul.attrs({
|
|
424
420
|
'data-garden-id': COMPONENT_ID$j,
|
|
425
|
-
'data-garden-version': '9.12.
|
|
421
|
+
'data-garden-version': '9.12.5'
|
|
426
422
|
}).withConfig({
|
|
427
423
|
displayName: "StyledOptGroup",
|
|
428
424
|
componentId: "sc-1kavqsx-0"
|
|
429
425
|
})(["margin:0;padding:0;list-style-type:none;", ";"], reactTheming.componentStyles);
|
|
430
426
|
|
|
431
427
|
const COMPONENT_ID$i = 'dropdowns.combobox.separator';
|
|
432
|
-
const colorStyles$6 =
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
} = _ref;
|
|
428
|
+
const colorStyles$6 = ({
|
|
429
|
+
theme
|
|
430
|
+
}) => {
|
|
436
431
|
const backgroundColor = reactTheming.getColor({
|
|
437
432
|
theme,
|
|
438
433
|
variable: 'border.subtle'
|
|
@@ -446,7 +441,7 @@ const sizeStyles$5 = props => {
|
|
|
446
441
|
};
|
|
447
442
|
const StyledListboxSeparator = styled__default.default.li.attrs({
|
|
448
443
|
'data-garden-id': COMPONENT_ID$i,
|
|
449
|
-
'data-garden-version': '9.12.
|
|
444
|
+
'data-garden-version': '9.12.5'
|
|
450
445
|
}).withConfig({
|
|
451
446
|
displayName: "StyledListboxSeparator",
|
|
452
447
|
componentId: "sc-1p6toh2-0"
|
|
@@ -460,19 +455,18 @@ const sizeStyles$4 = props => {
|
|
|
460
455
|
};
|
|
461
456
|
const StyledListbox = styled__default.default.ul.attrs({
|
|
462
457
|
'data-garden-id': COMPONENT_ID$h,
|
|
463
|
-
'data-garden-version': '9.12.
|
|
458
|
+
'data-garden-version': '9.12.5'
|
|
464
459
|
}).withConfig({
|
|
465
460
|
displayName: "StyledListbox",
|
|
466
461
|
componentId: "sc-1k13ba7-0"
|
|
467
462
|
})(["overflow-y:auto;list-style-type:none;", ";&&&{display:block;}", ":first-child ", " ", ":first-child ", "[role='none']:first-child{display:none;}"], sizeStyles$4, StyledOption, StyledOptionContent, StyledOptGroup, StyledListboxSeparator);
|
|
468
463
|
|
|
469
464
|
const COMPONENT_ID$g = 'dropdowns.combobox.option.icon';
|
|
470
|
-
const colorStyles$5 =
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
} = _ref;
|
|
465
|
+
const colorStyles$5 = ({
|
|
466
|
+
theme,
|
|
467
|
+
$isDisabled,
|
|
468
|
+
$type
|
|
469
|
+
}) => {
|
|
476
470
|
let variable;
|
|
477
471
|
if ($isDisabled) {
|
|
478
472
|
variable = 'foreground.disabled';
|
|
@@ -497,18 +491,17 @@ const sizeStyles$3 = props => {
|
|
|
497
491
|
};
|
|
498
492
|
const StyledOptionIcon = styled__default.default(reactTheming.StyledBaseIcon).attrs({
|
|
499
493
|
'data-garden-id': COMPONENT_ID$g,
|
|
500
|
-
'data-garden-version': '9.12.
|
|
494
|
+
'data-garden-version': '9.12.5'
|
|
501
495
|
}).withConfig({
|
|
502
496
|
displayName: "StyledOptionIcon",
|
|
503
497
|
componentId: "sc-qsab3y-0"
|
|
504
498
|
})(["flex-shrink:0;", ";", ";", ";"], sizeStyles$3, colorStyles$5, reactTheming.componentStyles);
|
|
505
499
|
|
|
506
500
|
const COMPONENT_ID$f = 'dropdowns.combobox.option.meta';
|
|
507
|
-
const colorStyles$4 =
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
} = _ref;
|
|
501
|
+
const colorStyles$4 = ({
|
|
502
|
+
theme,
|
|
503
|
+
$isDisabled
|
|
504
|
+
}) => {
|
|
512
505
|
const variable = $isDisabled ? 'foreground.disabled' : 'foreground.subtle';
|
|
513
506
|
const color = reactTheming.getColor({
|
|
514
507
|
theme,
|
|
@@ -523,28 +516,26 @@ const sizeStyles$2 = props => {
|
|
|
523
516
|
};
|
|
524
517
|
const StyledOptionMeta = styled__default.default.div.attrs({
|
|
525
518
|
'data-garden-id': COMPONENT_ID$f,
|
|
526
|
-
'data-garden-version': '9.12.
|
|
519
|
+
'data-garden-version': '9.12.5'
|
|
527
520
|
}).withConfig({
|
|
528
521
|
displayName: "StyledOptionMeta",
|
|
529
522
|
componentId: "sc-j6pu10-0"
|
|
530
523
|
})(["transition:color 0.25s ease-in-out;font-weight:", ";", ";", ";", ";"], props => props.theme.fontWeights.regular, sizeStyles$2, colorStyles$4, reactTheming.componentStyles);
|
|
531
524
|
|
|
532
525
|
const COMPONENT_ID$e = 'dropdowns.combobox.option.selection_icon';
|
|
533
|
-
const colorStyles$3 =
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
} = _ref;
|
|
526
|
+
const colorStyles$3 = ({
|
|
527
|
+
theme
|
|
528
|
+
}) => {
|
|
537
529
|
const color = reactTheming.getColor({
|
|
538
530
|
theme,
|
|
539
531
|
variable: 'foreground.primary'
|
|
540
532
|
});
|
|
541
533
|
return styled.css(["color:", ";"], color);
|
|
542
534
|
};
|
|
543
|
-
const sizeStyles$1 =
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
} = _ref2;
|
|
535
|
+
const sizeStyles$1 = ({
|
|
536
|
+
theme,
|
|
537
|
+
$isCompact
|
|
538
|
+
}) => {
|
|
548
539
|
const size = theme.iconSizes.sm;
|
|
549
540
|
const position = `${theme.space.base * 3.5}px`;
|
|
550
541
|
const top = polished.math(`(${getMinHeight({
|
|
@@ -556,18 +547,17 @@ const sizeStyles$1 = _ref2 => {
|
|
|
556
547
|
};
|
|
557
548
|
const StyledOptionSelectionIcon = styled__default.default(reactTheming.StyledBaseIcon).attrs({
|
|
558
549
|
'data-garden-id': COMPONENT_ID$e,
|
|
559
|
-
'data-garden-version': '9.12.
|
|
550
|
+
'data-garden-version': '9.12.5'
|
|
560
551
|
}).withConfig({
|
|
561
552
|
displayName: "StyledOptionSelectionIcon",
|
|
562
553
|
componentId: "sc-12wj24m-0"
|
|
563
554
|
})(["position:absolute;", ";", ";", ";"], sizeStyles$1, colorStyles$3, reactTheming.componentStyles);
|
|
564
555
|
|
|
565
556
|
const COMPONENT_ID$d = 'dropdowns.combobox.option.type_icon';
|
|
566
|
-
const colorStyles$2 =
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
} = _ref;
|
|
557
|
+
const colorStyles$2 = ({
|
|
558
|
+
theme,
|
|
559
|
+
$type
|
|
560
|
+
}) => {
|
|
571
561
|
const opacity = $type && $type !== 'danger' ? 1 : 0;
|
|
572
562
|
let color;
|
|
573
563
|
if ($type === 'add') {
|
|
@@ -599,7 +589,7 @@ const sizeStyles = props => {
|
|
|
599
589
|
};
|
|
600
590
|
const StyledOptionTypeIcon = styled__default.default(reactTheming.StyledBaseIcon).attrs({
|
|
601
591
|
'data-garden-id': COMPONENT_ID$d,
|
|
602
|
-
'data-garden-version': '9.12.
|
|
592
|
+
'data-garden-version': '9.12.5'
|
|
603
593
|
}).withConfig({
|
|
604
594
|
displayName: "StyledOptionTypeIcon",
|
|
605
595
|
componentId: "sc-xpink2-0"
|
|
@@ -608,7 +598,7 @@ const StyledOptionTypeIcon = styled__default.default(reactTheming.StyledBaseIcon
|
|
|
608
598
|
const COMPONENT_ID$c = 'dropdowns.combobox.tag';
|
|
609
599
|
const StyledTag = styled__default.default(reactTags.Tag).attrs({
|
|
610
600
|
'data-garden-id': COMPONENT_ID$c,
|
|
611
|
-
'data-garden-version': '9.12.
|
|
601
|
+
'data-garden-version': '9.12.5'
|
|
612
602
|
}).withConfig({
|
|
613
603
|
displayName: "StyledTag",
|
|
614
604
|
componentId: "sc-1alam0r-0"
|
|
@@ -618,11 +608,10 @@ const StyledTag = styled__default.default(reactTags.Tag).attrs({
|
|
|
618
608
|
}), polished.hideVisually(), reactTheming.componentStyles);
|
|
619
609
|
|
|
620
610
|
const COMPONENT_ID$b = 'dropdowns.combobox.value';
|
|
621
|
-
const colorStyles$1 =
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
} = _ref;
|
|
611
|
+
const colorStyles$1 = ({
|
|
612
|
+
theme,
|
|
613
|
+
$isPlaceholder
|
|
614
|
+
}) => {
|
|
626
615
|
const foregroundColor = $isPlaceholder && reactTheming.getColor({
|
|
627
616
|
theme,
|
|
628
617
|
variable: 'foreground.disabled'
|
|
@@ -631,7 +620,7 @@ const colorStyles$1 = _ref => {
|
|
|
631
620
|
};
|
|
632
621
|
const StyledValue = styled__default.default.div.attrs({
|
|
633
622
|
'data-garden-id': COMPONENT_ID$b,
|
|
634
|
-
'data-garden-version': '9.12.
|
|
623
|
+
'data-garden-version': '9.12.5'
|
|
635
624
|
}).withConfig({
|
|
636
625
|
displayName: "StyledValue",
|
|
637
626
|
componentId: "sc-t719sx-0"
|
|
@@ -643,10 +632,9 @@ const StyledValue = styled__default.default.div.attrs({
|
|
|
643
632
|
}, sizeStyles$a, colorStyles$1, reactTheming.componentStyles);
|
|
644
633
|
|
|
645
634
|
const COMPONENT_ID$a = 'dropdowns.combobox.tags_button';
|
|
646
|
-
const colorStyles =
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
} = _ref;
|
|
635
|
+
const colorStyles = ({
|
|
636
|
+
theme
|
|
637
|
+
}) => {
|
|
650
638
|
const color = reactTheming.getColor({
|
|
651
639
|
theme,
|
|
652
640
|
variable: 'foreground.primary'
|
|
@@ -656,7 +644,7 @@ const colorStyles = _ref => {
|
|
|
656
644
|
const StyledTagsButton = styled__default.default(StyledValue).attrs({
|
|
657
645
|
as: 'button',
|
|
658
646
|
'data-garden-id': COMPONENT_ID$a,
|
|
659
|
-
'data-garden-version': '9.12.
|
|
647
|
+
'data-garden-version': '9.12.5'
|
|
660
648
|
}).withConfig({
|
|
661
649
|
displayName: "StyledTagsButton",
|
|
662
650
|
componentId: "sc-6q5w33-0"
|
|
@@ -665,7 +653,7 @@ const StyledTagsButton = styled__default.default(StyledValue).attrs({
|
|
|
665
653
|
const COMPONENT_ID$9 = 'dropdowns.menu';
|
|
666
654
|
const StyledMenu = styled__default.default(StyledListbox).attrs({
|
|
667
655
|
'data-garden-id': COMPONENT_ID$9,
|
|
668
|
-
'data-garden-version': '9.12.
|
|
656
|
+
'data-garden-version': '9.12.5'
|
|
669
657
|
}).withConfig({
|
|
670
658
|
displayName: "StyledMenu",
|
|
671
659
|
componentId: "sc-f77ntu-0"
|
|
@@ -678,7 +666,7 @@ const StyledMenu = styled__default.default(StyledListbox).attrs({
|
|
|
678
666
|
const COMPONENT_ID$8 = 'dropdowns.menu.floating';
|
|
679
667
|
const StyledFloatingMenu = styled__default.default(StyledFloatingListbox).attrs({
|
|
680
668
|
'data-garden-id': COMPONENT_ID$8,
|
|
681
|
-
'data-garden-version': '9.12.
|
|
669
|
+
'data-garden-version': '9.12.5'
|
|
682
670
|
}).withConfig({
|
|
683
671
|
displayName: "StyledFloatingMenu",
|
|
684
672
|
componentId: "sc-1rc7ahb-0"
|
|
@@ -687,7 +675,7 @@ const StyledFloatingMenu = styled__default.default(StyledFloatingListbox).attrs(
|
|
|
687
675
|
const COMPONENT_ID$7 = 'dropdowns.menu.item';
|
|
688
676
|
const StyledItem = styled__default.default(StyledOption).attrs({
|
|
689
677
|
'data-garden-id': COMPONENT_ID$7,
|
|
690
|
-
'data-garden-version': '9.12.
|
|
678
|
+
'data-garden-version': '9.12.5'
|
|
691
679
|
}).withConfig({
|
|
692
680
|
displayName: "StyledItem",
|
|
693
681
|
componentId: "sc-1jp99dq-0"
|
|
@@ -696,7 +684,7 @@ const StyledItem = styled__default.default(StyledOption).attrs({
|
|
|
696
684
|
const COMPONENT_ID$6 = 'dropdowns.menu.item.type_icon';
|
|
697
685
|
const StyledItemTypeIcon = styled__default.default(StyledOptionTypeIcon).attrs({
|
|
698
686
|
'data-garden-id': COMPONENT_ID$6,
|
|
699
|
-
'data-garden-version': '9.12.
|
|
687
|
+
'data-garden-version': '9.12.5'
|
|
700
688
|
}).withConfig({
|
|
701
689
|
displayName: "StyledItemTypeIcon",
|
|
702
690
|
componentId: "sc-1pll3nu-0"
|
|
@@ -705,7 +693,7 @@ const StyledItemTypeIcon = styled__default.default(StyledOptionTypeIcon).attrs({
|
|
|
705
693
|
const COMPONENT_ID$5 = 'dropdowns.menu.item_anchor';
|
|
706
694
|
const StyledItemAnchor = styled__default.default(StyledOption).attrs({
|
|
707
695
|
'data-garden-id': COMPONENT_ID$5,
|
|
708
|
-
'data-garden-version': '9.12.
|
|
696
|
+
'data-garden-version': '9.12.5',
|
|
709
697
|
as: 'a'
|
|
710
698
|
}).withConfig({
|
|
711
699
|
displayName: "StyledItemAnchor",
|
|
@@ -715,7 +703,7 @@ const StyledItemAnchor = styled__default.default(StyledOption).attrs({
|
|
|
715
703
|
const COMPONENT_ID$4 = 'dropdowns.menu.item.content';
|
|
716
704
|
const StyledItemContent = styled__default.default(StyledOptionContent).attrs({
|
|
717
705
|
'data-garden-id': COMPONENT_ID$4,
|
|
718
|
-
'data-garden-version': '9.12.
|
|
706
|
+
'data-garden-version': '9.12.5'
|
|
719
707
|
}).withConfig({
|
|
720
708
|
displayName: "StyledItemContent",
|
|
721
709
|
componentId: "sc-1opglsb-0"
|
|
@@ -724,7 +712,7 @@ const StyledItemContent = styled__default.default(StyledOptionContent).attrs({
|
|
|
724
712
|
const COMPONENT_ID$3 = 'dropdowns.menu.item_group';
|
|
725
713
|
const StyledItemGroup = styled__default.default(StyledOptGroup).attrs({
|
|
726
714
|
'data-garden-id': COMPONENT_ID$3,
|
|
727
|
-
'data-garden-version': '9.12.
|
|
715
|
+
'data-garden-version': '9.12.5'
|
|
728
716
|
}).withConfig({
|
|
729
717
|
displayName: "StyledItemGroup",
|
|
730
718
|
componentId: "sc-1umk3cg-0"
|
|
@@ -733,7 +721,7 @@ const StyledItemGroup = styled__default.default(StyledOptGroup).attrs({
|
|
|
733
721
|
const COMPONENT_ID$2 = 'dropdowns.menu.item.icon';
|
|
734
722
|
const StyledItemIcon = styled__default.default(StyledOptionIcon).attrs({
|
|
735
723
|
'data-garden-id': COMPONENT_ID$2,
|
|
736
|
-
'data-garden-version': '9.12.
|
|
724
|
+
'data-garden-version': '9.12.5'
|
|
737
725
|
}).withConfig({
|
|
738
726
|
displayName: "StyledItemIcon",
|
|
739
727
|
componentId: "sc-w9orqb-0"
|
|
@@ -742,7 +730,7 @@ const StyledItemIcon = styled__default.default(StyledOptionIcon).attrs({
|
|
|
742
730
|
const COMPONENT_ID$1 = 'dropdowns.menu.item.meta';
|
|
743
731
|
const StyledItemMeta = styled__default.default(StyledOptionMeta).attrs({
|
|
744
732
|
'data-garden-id': COMPONENT_ID$1,
|
|
745
|
-
'data-garden-version': '9.12.
|
|
733
|
+
'data-garden-version': '9.12.5'
|
|
746
734
|
}).withConfig({
|
|
747
735
|
displayName: "StyledItemMeta",
|
|
748
736
|
componentId: "sc-1unw3x1-0"
|
|
@@ -751,25 +739,24 @@ const StyledItemMeta = styled__default.default(StyledOptionMeta).attrs({
|
|
|
751
739
|
const COMPONENT_ID = 'dropdowns.menu.separator';
|
|
752
740
|
const StyledSeparator = styled__default.default(StyledListboxSeparator).attrs({
|
|
753
741
|
'data-garden-id': COMPONENT_ID,
|
|
754
|
-
'data-garden-version': '9.12.
|
|
742
|
+
'data-garden-version': '9.12.5'
|
|
755
743
|
}).withConfig({
|
|
756
744
|
displayName: "StyledSeparator",
|
|
757
745
|
componentId: "sc-8kqwen-0"
|
|
758
746
|
})(["", ";"], reactTheming.componentStyles);
|
|
759
747
|
|
|
760
|
-
const Listbox = React.forwardRef((
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
} = _ref;
|
|
748
|
+
const Listbox = React.forwardRef(({
|
|
749
|
+
appendToNode,
|
|
750
|
+
children,
|
|
751
|
+
isCompact,
|
|
752
|
+
isExpanded,
|
|
753
|
+
maxHeight,
|
|
754
|
+
minHeight,
|
|
755
|
+
onMouseDown,
|
|
756
|
+
triggerRef,
|
|
757
|
+
zIndex,
|
|
758
|
+
...props
|
|
759
|
+
}, ref) => {
|
|
773
760
|
const floatingRef = React.useRef(null);
|
|
774
761
|
const [isVisible, setIsVisible] = React.useState(false);
|
|
775
762
|
const [height, setHeight] = React.useState();
|
|
@@ -789,11 +776,10 @@ const Listbox = React.forwardRef((_ref, ref) => {
|
|
|
789
776
|
},
|
|
790
777
|
placement: 'bottom-start',
|
|
791
778
|
middleware: [reactDom.offset(theme.space.base), reactDom.flip(), reactDom.size({
|
|
792
|
-
apply:
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
} = _ref2;
|
|
779
|
+
apply: ({
|
|
780
|
+
rects,
|
|
781
|
+
availableHeight
|
|
782
|
+
}) => {
|
|
797
783
|
if (rects.reference.width > 0) {
|
|
798
784
|
setWidth(rects.reference.width);
|
|
799
785
|
if (!(minHeight === null || minHeight === 'fit-content') && rects.floating.height > availableHeight) {
|
|
@@ -871,14 +857,13 @@ const TagAvatarComponent = reactTags.Tag.Avatar;
|
|
|
871
857
|
TagAvatarComponent.displayName = 'Tag.Avatar';
|
|
872
858
|
const TagAvatar = TagAvatarComponent;
|
|
873
859
|
|
|
874
|
-
const TagComponent = React.forwardRef((
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
} = _ref;
|
|
860
|
+
const TagComponent = React.forwardRef(({
|
|
861
|
+
children,
|
|
862
|
+
option,
|
|
863
|
+
removeLabel,
|
|
864
|
+
tooltipZIndex,
|
|
865
|
+
...props
|
|
866
|
+
}, ref) => {
|
|
882
867
|
const {
|
|
883
868
|
getTagProps,
|
|
884
869
|
isCompact,
|
|
@@ -922,29 +907,26 @@ TagComponent.propTypes = {
|
|
|
922
907
|
const Tag = TagComponent;
|
|
923
908
|
Tag.Avatar = TagAvatar;
|
|
924
909
|
|
|
925
|
-
const TagGroup =
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
|
|
935
|
-
return React__namespace.default.createElement(
|
|
936
|
-
|
|
937
|
-
|
|
938
|
-
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
}, optionTagProps[option.value]));
|
|
946
|
-
}), children);
|
|
947
|
-
};
|
|
910
|
+
const TagGroup = ({
|
|
911
|
+
children,
|
|
912
|
+
isDisabled,
|
|
913
|
+
isExpanded,
|
|
914
|
+
listboxZIndex,
|
|
915
|
+
maxTags,
|
|
916
|
+
optionTagProps,
|
|
917
|
+
selection
|
|
918
|
+
}) => React__namespace.default.createElement(React__namespace.default.Fragment, null, selection.map((option, index) => {
|
|
919
|
+
const disabled = isDisabled || option.disabled;
|
|
920
|
+
return React__namespace.default.createElement(Tag, Object.assign({
|
|
921
|
+
key: option.value,
|
|
922
|
+
hidden: !isExpanded && index >= maxTags,
|
|
923
|
+
option: {
|
|
924
|
+
...option,
|
|
925
|
+
disabled
|
|
926
|
+
},
|
|
927
|
+
tooltipZIndex: listboxZIndex ? listboxZIndex + 1 : undefined
|
|
928
|
+
}, optionTagProps[option.value]));
|
|
929
|
+
}), children);
|
|
948
930
|
TagGroup.displayName = 'TagGroup';
|
|
949
931
|
|
|
950
932
|
const toOption = props => {
|
|
@@ -975,39 +957,38 @@ const toOptions = (children, optionTagProps) => React.Children.toArray(children)
|
|
|
975
957
|
}, []);
|
|
976
958
|
|
|
977
959
|
const MAX_TAGS = 4;
|
|
978
|
-
const Combobox = React.forwardRef((
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
|
|
987
|
-
|
|
988
|
-
|
|
989
|
-
|
|
990
|
-
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
} = _ref;
|
|
960
|
+
const Combobox = React.forwardRef(({
|
|
961
|
+
children,
|
|
962
|
+
activeIndex,
|
|
963
|
+
defaultActiveIndex,
|
|
964
|
+
defaultExpanded,
|
|
965
|
+
endIcon,
|
|
966
|
+
focusInset,
|
|
967
|
+
inputProps: _inputProps,
|
|
968
|
+
inputValue: _inputValue,
|
|
969
|
+
isAutocomplete,
|
|
970
|
+
isBare,
|
|
971
|
+
isCompact,
|
|
972
|
+
isDisabled,
|
|
973
|
+
isEditable = true,
|
|
974
|
+
isExpanded: _isExpanded,
|
|
975
|
+
isMultiselectable,
|
|
976
|
+
listboxAppendToNode,
|
|
977
|
+
listboxAriaLabel,
|
|
978
|
+
listboxMaxHeight = '400px',
|
|
979
|
+
listboxMinHeight,
|
|
980
|
+
listboxZIndex = 1000,
|
|
981
|
+
maxHeight,
|
|
982
|
+
maxTags = MAX_TAGS,
|
|
983
|
+
onChange,
|
|
984
|
+
placeholder,
|
|
985
|
+
renderExpandTags,
|
|
986
|
+
renderValue,
|
|
987
|
+
selectionValue,
|
|
988
|
+
startIcon,
|
|
989
|
+
validation,
|
|
990
|
+
...props
|
|
991
|
+
}, ref) => {
|
|
1011
992
|
const {
|
|
1012
993
|
hasHint,
|
|
1013
994
|
hasMessage,
|
|
@@ -1261,13 +1242,12 @@ const Hint = React.forwardRef((props, ref) => {
|
|
|
1261
1242
|
});
|
|
1262
1243
|
Hint.displayName = 'Field.Hint';
|
|
1263
1244
|
|
|
1264
|
-
const Label = React.forwardRef((
|
|
1265
|
-
|
|
1266
|
-
|
|
1267
|
-
|
|
1268
|
-
|
|
1269
|
-
|
|
1270
|
-
} = _ref;
|
|
1245
|
+
const Label = React.forwardRef(({
|
|
1246
|
+
onClick,
|
|
1247
|
+
onMouseEnter,
|
|
1248
|
+
onMouseLeave,
|
|
1249
|
+
...props
|
|
1250
|
+
}, ref) => {
|
|
1271
1251
|
const {
|
|
1272
1252
|
labelProps
|
|
1273
1253
|
} = useFieldContext();
|
|
@@ -1445,20 +1425,19 @@ const OptionMetaComponent = React.forwardRef((props, ref) => {
|
|
|
1445
1425
|
OptionMetaComponent.displayName = 'Option.Meta';
|
|
1446
1426
|
const OptionMeta = OptionMetaComponent;
|
|
1447
1427
|
|
|
1448
|
-
const OptionComponent = React.forwardRef((
|
|
1449
|
-
|
|
1450
|
-
|
|
1451
|
-
|
|
1452
|
-
|
|
1453
|
-
|
|
1454
|
-
|
|
1455
|
-
|
|
1456
|
-
|
|
1457
|
-
|
|
1458
|
-
|
|
1459
|
-
|
|
1460
|
-
|
|
1461
|
-
} = _ref;
|
|
1428
|
+
const OptionComponent = React.forwardRef(({
|
|
1429
|
+
children,
|
|
1430
|
+
hasSelection,
|
|
1431
|
+
icon,
|
|
1432
|
+
isDisabled,
|
|
1433
|
+
isHidden,
|
|
1434
|
+
isSelected,
|
|
1435
|
+
label,
|
|
1436
|
+
type,
|
|
1437
|
+
value,
|
|
1438
|
+
tagProps,
|
|
1439
|
+
...props
|
|
1440
|
+
}, ref) => {
|
|
1462
1441
|
const contextValue = React.useMemo(() => ({
|
|
1463
1442
|
isDisabled,
|
|
1464
1443
|
type
|
|
@@ -1535,16 +1514,15 @@ OptionComponent.propTypes = {
|
|
|
1535
1514
|
const Option = OptionComponent;
|
|
1536
1515
|
Option.Meta = OptionMeta;
|
|
1537
1516
|
|
|
1538
|
-
const OptGroup = React.forwardRef((
|
|
1539
|
-
|
|
1540
|
-
|
|
1541
|
-
|
|
1542
|
-
|
|
1543
|
-
|
|
1544
|
-
|
|
1545
|
-
|
|
1546
|
-
|
|
1547
|
-
} = _ref;
|
|
1517
|
+
const OptGroup = React.forwardRef(({
|
|
1518
|
+
children,
|
|
1519
|
+
content,
|
|
1520
|
+
icon,
|
|
1521
|
+
legend,
|
|
1522
|
+
'aria-label': ariaLabel,
|
|
1523
|
+
onMouseDown,
|
|
1524
|
+
...props
|
|
1525
|
+
}, ref) => {
|
|
1548
1526
|
const {
|
|
1549
1527
|
getOptGroupProps,
|
|
1550
1528
|
isCompact
|
|
@@ -1645,21 +1623,20 @@ const toItems = (children, type) => React.Children.toArray(children).reduce((ite
|
|
|
1645
1623
|
}, []);
|
|
1646
1624
|
|
|
1647
1625
|
const PLACEMENT_DEFAULT = 'bottom-start';
|
|
1648
|
-
const MenuList = React.forwardRef((
|
|
1649
|
-
|
|
1650
|
-
|
|
1651
|
-
|
|
1652
|
-
|
|
1653
|
-
|
|
1654
|
-
|
|
1655
|
-
|
|
1656
|
-
|
|
1657
|
-
|
|
1658
|
-
|
|
1659
|
-
|
|
1660
|
-
|
|
1661
|
-
|
|
1662
|
-
} = _ref;
|
|
1626
|
+
const MenuList = React.forwardRef(({
|
|
1627
|
+
appendToNode,
|
|
1628
|
+
hasArrow,
|
|
1629
|
+
isCompact,
|
|
1630
|
+
isExpanded,
|
|
1631
|
+
fallbackPlacements: _fallbackPlacements,
|
|
1632
|
+
maxHeight = '400px',
|
|
1633
|
+
minHeight,
|
|
1634
|
+
placement: _placement = PLACEMENT_DEFAULT,
|
|
1635
|
+
triggerRef,
|
|
1636
|
+
zIndex = 1000,
|
|
1637
|
+
children,
|
|
1638
|
+
...props
|
|
1639
|
+
}, ref) => {
|
|
1663
1640
|
const floatingRef = React.useRef(null);
|
|
1664
1641
|
const [isVisible, setIsVisible] = React.useState(isExpanded);
|
|
1665
1642
|
const [height, setHeight] = React.useState();
|
|
@@ -1685,11 +1662,10 @@ const MenuList = React.forwardRef((_ref, ref) => {
|
|
|
1685
1662
|
middleware: [reactDom.offset(theme.space.base * (hasArrow ? 2 : 1)), _placement === 'auto' ? reactDom.autoPlacement() : reactDom.flip({
|
|
1686
1663
|
fallbackPlacements
|
|
1687
1664
|
}), reactDom.size({
|
|
1688
|
-
apply:
|
|
1689
|
-
|
|
1690
|
-
|
|
1691
|
-
|
|
1692
|
-
} = _ref2;
|
|
1665
|
+
apply: ({
|
|
1666
|
+
rects,
|
|
1667
|
+
availableHeight
|
|
1668
|
+
}) => {
|
|
1693
1669
|
if (!(minHeight === null || minHeight === 'fit-content')) {
|
|
1694
1670
|
if (rects.floating.height > availableHeight) {
|
|
1695
1671
|
setHeight(availableHeight);
|
|
@@ -1762,25 +1738,24 @@ MenuList.propTypes = {
|
|
|
1762
1738
|
zIndex: PropTypes__default.default.number
|
|
1763
1739
|
};
|
|
1764
1740
|
|
|
1765
|
-
const Menu = React.forwardRef((
|
|
1766
|
-
|
|
1767
|
-
|
|
1768
|
-
|
|
1769
|
-
|
|
1770
|
-
|
|
1771
|
-
|
|
1772
|
-
|
|
1773
|
-
|
|
1774
|
-
|
|
1775
|
-
|
|
1776
|
-
|
|
1777
|
-
|
|
1778
|
-
|
|
1779
|
-
|
|
1780
|
-
|
|
1781
|
-
|
|
1782
|
-
|
|
1783
|
-
} = _ref2;
|
|
1741
|
+
const Menu = React.forwardRef(({
|
|
1742
|
+
button,
|
|
1743
|
+
buttonProps: _buttonProps = {},
|
|
1744
|
+
children,
|
|
1745
|
+
isCompact,
|
|
1746
|
+
focusedValue: _focusedValue,
|
|
1747
|
+
defaultFocusedValue,
|
|
1748
|
+
defaultExpanded,
|
|
1749
|
+
isExpanded: _isExpanded,
|
|
1750
|
+
restoreFocus,
|
|
1751
|
+
selectedItems,
|
|
1752
|
+
onChange,
|
|
1753
|
+
onMouseLeave,
|
|
1754
|
+
maxHeight = '400px',
|
|
1755
|
+
placement = 'bottom-start',
|
|
1756
|
+
zIndex = 1000,
|
|
1757
|
+
...props
|
|
1758
|
+
}, ref) => {
|
|
1784
1759
|
const triggerRef = React.useRef(null);
|
|
1785
1760
|
const menuRef = React.useRef(null);
|
|
1786
1761
|
const items = toItems(children);
|
|
@@ -1880,16 +1855,15 @@ const useItemGroupContext = () => {
|
|
|
1880
1855
|
return React.useContext(ItemGroupContext);
|
|
1881
1856
|
};
|
|
1882
1857
|
|
|
1883
|
-
const ItemGroup = React.forwardRef((
|
|
1884
|
-
|
|
1885
|
-
|
|
1886
|
-
|
|
1887
|
-
|
|
1888
|
-
|
|
1889
|
-
|
|
1890
|
-
|
|
1891
|
-
|
|
1892
|
-
} = _ref;
|
|
1858
|
+
const ItemGroup = React.forwardRef(({
|
|
1859
|
+
children,
|
|
1860
|
+
content,
|
|
1861
|
+
legend,
|
|
1862
|
+
icon,
|
|
1863
|
+
'aria-label': ariaLabel,
|
|
1864
|
+
type,
|
|
1865
|
+
...props
|
|
1866
|
+
}, ref) => {
|
|
1893
1867
|
const {
|
|
1894
1868
|
isCompact,
|
|
1895
1869
|
getItemGroupProps
|
|
@@ -1966,23 +1940,22 @@ const renderActionIcon = itemType => {
|
|
|
1966
1940
|
return React__namespace.default.createElement(SvgCheckLgStroke, null);
|
|
1967
1941
|
}
|
|
1968
1942
|
};
|
|
1969
|
-
const ItemComponent = React.forwardRef((
|
|
1970
|
-
|
|
1971
|
-
|
|
1972
|
-
|
|
1973
|
-
|
|
1974
|
-
|
|
1975
|
-
|
|
1976
|
-
|
|
1977
|
-
|
|
1978
|
-
|
|
1979
|
-
|
|
1980
|
-
|
|
1981
|
-
|
|
1982
|
-
|
|
1983
|
-
|
|
1984
|
-
|
|
1985
|
-
} = _ref;
|
|
1943
|
+
const ItemComponent = React.forwardRef(({
|
|
1944
|
+
children,
|
|
1945
|
+
value,
|
|
1946
|
+
label = value,
|
|
1947
|
+
href,
|
|
1948
|
+
isSelected,
|
|
1949
|
+
icon,
|
|
1950
|
+
isDisabled,
|
|
1951
|
+
isExternal,
|
|
1952
|
+
type,
|
|
1953
|
+
name,
|
|
1954
|
+
onClick,
|
|
1955
|
+
onKeyDown,
|
|
1956
|
+
onMouseEnter,
|
|
1957
|
+
...other
|
|
1958
|
+
}, ref) => {
|
|
1986
1959
|
const {
|
|
1987
1960
|
type: selectionType
|
|
1988
1961
|
} = useItemGroupContext();
|
|
@@ -2063,11 +2036,10 @@ const Item = ItemComponent;
|
|
|
2063
2036
|
Item.Meta = ItemMeta;
|
|
2064
2037
|
|
|
2065
2038
|
const Separator = React.forwardRef(
|
|
2066
|
-
(
|
|
2067
|
-
|
|
2068
|
-
|
|
2069
|
-
|
|
2070
|
-
} = _ref;
|
|
2039
|
+
({
|
|
2040
|
+
children,
|
|
2041
|
+
...props
|
|
2042
|
+
}, ref) => {
|
|
2071
2043
|
const {
|
|
2072
2044
|
getSeparatorProps
|
|
2073
2045
|
} = useMenuContext();
|