@zendeskgarden/react-dropdowns 9.0.0-next.9 → 9.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.
Files changed (93) hide show
  1. package/dist/esm/elements/combobox/Combobox.js +47 -48
  2. package/dist/esm/elements/combobox/Field.js +0 -1
  3. package/dist/esm/elements/combobox/Hint.js +1 -2
  4. package/dist/esm/elements/combobox/Label.js +1 -2
  5. package/dist/esm/elements/combobox/Listbox.js +7 -8
  6. package/dist/esm/elements/combobox/Message.js +1 -2
  7. package/dist/esm/elements/combobox/OptGroup.js +5 -6
  8. package/dist/esm/elements/combobox/Option.js +9 -6
  9. package/dist/esm/elements/combobox/OptionMeta.js +1 -2
  10. package/dist/esm/elements/combobox/Tag.js +0 -1
  11. package/dist/esm/elements/combobox/utils.js +1 -1
  12. package/dist/esm/elements/menu/Item.js +11 -10
  13. package/dist/esm/elements/menu/ItemGroup.js +6 -6
  14. package/dist/esm/elements/menu/ItemMeta.js +1 -2
  15. package/dist/esm/elements/menu/Menu.js +9 -36
  16. package/dist/esm/elements/menu/MenuList.js +8 -9
  17. package/dist/esm/elements/menu/Separator.js +0 -1
  18. package/dist/esm/elements/menu/utils.js +1 -1
  19. package/dist/esm/node_modules/@zendeskgarden/svg-icons/src/16/check-lg-stroke.svg.js +1 -1
  20. package/dist/esm/node_modules/@zendeskgarden/svg-icons/src/16/chevron-down-stroke.svg.js +1 -1
  21. package/dist/esm/node_modules/@zendeskgarden/svg-icons/src/16/chevron-left-stroke.svg.js +1 -1
  22. package/dist/esm/node_modules/@zendeskgarden/svg-icons/src/16/chevron-right-stroke.svg.js +1 -1
  23. package/dist/esm/node_modules/@zendeskgarden/svg-icons/src/16/plus-stroke.svg.js +1 -1
  24. package/dist/esm/views/combobox/StyledCombobox.js +4 -7
  25. package/dist/esm/views/combobox/StyledContainer.js +2 -5
  26. package/dist/esm/views/combobox/StyledField.js +2 -5
  27. package/dist/esm/views/combobox/StyledFloatingListbox.js +5 -8
  28. package/dist/esm/views/combobox/StyledHint.js +2 -5
  29. package/dist/esm/views/combobox/StyledInput.js +13 -10
  30. package/dist/esm/views/combobox/StyledInputGroup.js +2 -5
  31. package/dist/esm/views/combobox/StyledInputIcon.js +26 -10
  32. package/dist/esm/views/combobox/StyledLabel.js +2 -5
  33. package/dist/esm/views/combobox/StyledListbox.js +3 -7
  34. package/dist/esm/views/combobox/StyledListboxSeparator.js +10 -7
  35. package/dist/esm/views/combobox/StyledMessage.js +2 -5
  36. package/dist/esm/views/combobox/StyledOptGroup.js +2 -5
  37. package/dist/esm/views/combobox/StyledOption.js +35 -17
  38. package/dist/esm/views/combobox/StyledOptionContent.js +2 -5
  39. package/dist/esm/views/combobox/StyledOptionIcon.js +25 -6
  40. package/dist/esm/views/combobox/StyledOptionMeta.js +12 -7
  41. package/dist/esm/views/combobox/StyledOptionTypeIcon.js +18 -11
  42. package/dist/esm/views/combobox/StyledTag.js +6 -6
  43. package/dist/esm/views/combobox/StyledTagsButton.js +10 -7
  44. package/dist/esm/views/combobox/StyledTrigger.js +71 -43
  45. package/dist/esm/views/combobox/StyledValue.js +13 -9
  46. package/dist/esm/views/menu/StyledFloatingMenu.js +2 -5
  47. package/dist/esm/views/menu/StyledItem.js +2 -5
  48. package/dist/esm/views/menu/StyledItemContent.js +2 -5
  49. package/dist/esm/views/menu/StyledItemGroup.js +2 -5
  50. package/dist/esm/views/menu/StyledItemIcon.js +2 -5
  51. package/dist/esm/views/menu/StyledItemMeta.js +2 -5
  52. package/dist/esm/views/menu/StyledItemTypeIcon.js +2 -5
  53. package/dist/esm/views/menu/StyledMenu.js +5 -8
  54. package/dist/esm/views/menu/StyledSeparator.js +2 -5
  55. package/dist/index.cjs.js +457 -412
  56. package/dist/typings/context/useComboboxContext.d.ts +12 -13
  57. package/dist/typings/context/useFieldContext.d.ts +6 -6
  58. package/dist/typings/context/useItemContext.d.ts +2 -3
  59. package/dist/typings/context/useItemGroupContext.d.ts +2 -3
  60. package/dist/typings/context/useMenuContext.d.ts +10 -11
  61. package/dist/typings/context/useOptionContext.d.ts +2 -3
  62. package/dist/typings/elements/combobox/Field.d.ts +3 -1
  63. package/dist/typings/elements/combobox/Option.d.ts +3 -1
  64. package/dist/typings/elements/combobox/Tag.d.ts +3 -1
  65. package/dist/typings/elements/combobox/TagAvatar.d.ts +1 -2
  66. package/dist/typings/elements/combobox/utils.d.ts +2 -2
  67. package/dist/typings/elements/menu/Item.d.ts +3 -1
  68. package/dist/typings/elements/menu/utils.d.ts +2 -2
  69. package/dist/typings/types/index.d.ts +2 -0
  70. package/dist/typings/views/combobox/StyledCombobox.d.ts +1 -1
  71. package/dist/typings/views/combobox/StyledFloatingListbox.d.ts +3 -3
  72. package/dist/typings/views/combobox/StyledHint.d.ts +0 -1
  73. package/dist/typings/views/combobox/StyledInput.d.ts +4 -4
  74. package/dist/typings/views/combobox/StyledInputIcon.d.ts +1 -2
  75. package/dist/typings/views/combobox/StyledLabel.d.ts +0 -1
  76. package/dist/typings/views/combobox/StyledListbox.d.ts +3 -3
  77. package/dist/typings/views/combobox/StyledMessage.d.ts +0 -1
  78. package/dist/typings/views/combobox/StyledOptGroup.d.ts +1 -1
  79. package/dist/typings/views/combobox/StyledOption.d.ts +2 -2
  80. package/dist/typings/views/combobox/StyledOptionIcon.d.ts +8 -4
  81. package/dist/typings/views/combobox/StyledOptionMeta.d.ts +1 -1
  82. package/dist/typings/views/combobox/StyledOptionTypeIcon.d.ts +1 -2
  83. package/dist/typings/views/combobox/StyledTag.d.ts +2 -6
  84. package/dist/typings/views/combobox/StyledTagsButton.d.ts +1 -1
  85. package/dist/typings/views/combobox/StyledTrigger.d.ts +9 -9
  86. package/dist/typings/views/combobox/StyledValue.d.ts +7 -7
  87. package/dist/typings/views/index.d.ts +0 -1
  88. package/dist/typings/views/menu/StyledItemIcon.d.ts +2 -3
  89. package/dist/typings/views/menu/StyledItemTypeIcon.d.ts +1 -2
  90. package/dist/typings/views/menu/StyledMenu.d.ts +1 -1
  91. package/package.json +12 -12
  92. package/dist/esm/views/menu/StyledButton.js +0 -23
  93. package/dist/typings/views/menu/StyledButton.d.ts +0 -20
package/dist/index.cjs.js CHANGED
@@ -14,13 +14,13 @@ var reactTheming = require('@zendeskgarden/react-theming');
14
14
  var reactForms = require('@zendeskgarden/react-forms');
15
15
  var polished = require('polished');
16
16
  var reactTags = require('@zendeskgarden/react-tags');
17
- var reactButtons = require('@zendeskgarden/react-buttons');
18
17
  var reactDom$1 = require('react-dom');
19
18
  var reactDom = require('@floating-ui/react-dom');
20
19
  var containerUtilities = require('@zendeskgarden/container-utilities');
21
20
  var reactTooltips = require('@zendeskgarden/react-tooltips');
22
21
  var reactMergeRefs = require('react-merge-refs');
23
22
  var containerMenu = require('@zendeskgarden/container-menu');
23
+ var reactButtons = require('@zendeskgarden/react-buttons');
24
24
 
25
25
  function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
26
26
 
@@ -47,7 +47,7 @@ var PropTypes__default = /*#__PURE__*/_interopDefault(PropTypes);
47
47
  var styled__default = /*#__PURE__*/_interopDefault(styled);
48
48
 
49
49
  var _path$4;
50
- function _extends$4() { _extends$4 = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$4.apply(this, arguments); }
50
+ function _extends$4() { return _extends$4 = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends$4.apply(null, arguments); }
51
51
  var SvgChevronDownStroke = function SvgChevronDownStroke(props) {
52
52
  return /*#__PURE__*/React__namespace.createElement("svg", _extends$4({
53
53
  xmlns: "http://www.w3.org/2000/svg",
@@ -80,110 +80,95 @@ const useFieldContext = () => {
80
80
  return context;
81
81
  };
82
82
 
83
- const COMPONENT_ID$v = 'dropdowns.combobox.label';
83
+ const COMPONENT_ID$u = 'dropdowns.combobox.label';
84
84
  const StyledLabel = styled__default.default(reactForms.Field.Label).attrs({
85
- 'data-garden-id': COMPONENT_ID$v,
86
- 'data-garden-version': '9.0.0-next.9'
85
+ 'data-garden-id': COMPONENT_ID$u,
86
+ 'data-garden-version': '9.1.0'
87
87
  }).withConfig({
88
88
  displayName: "StyledLabel",
89
89
  componentId: "sc-az6now-0"
90
- })(["vertical-align:revert;", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$v, props));
91
- StyledLabel.defaultProps = {
92
- theme: reactTheming.DEFAULT_THEME
93
- };
90
+ })(["vertical-align:revert;", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$u, props));
94
91
 
95
- const COMPONENT_ID$u = 'dropdowns.combobox.hint';
92
+ const COMPONENT_ID$t = 'dropdowns.combobox.hint';
96
93
  const StyledHint = styled__default.default(reactForms.Field.Hint).attrs({
97
- 'data-garden-id': COMPONENT_ID$u,
98
- 'data-garden-version': '9.0.0-next.9'
94
+ 'data-garden-id': COMPONENT_ID$t,
95
+ 'data-garden-version': '9.1.0'
99
96
  }).withConfig({
100
97
  displayName: "StyledHint",
101
98
  componentId: "sc-106qvqx-0"
102
- })(["", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$u, props));
103
- StyledHint.defaultProps = {
104
- theme: reactTheming.DEFAULT_THEME
105
- };
99
+ })(["", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$t, props));
106
100
 
107
- const COMPONENT_ID$t = 'dropdowns.combobox.message';
101
+ const COMPONENT_ID$s = 'dropdowns.combobox.message';
108
102
  const StyledMessage = styled__default.default(reactForms.Field.Message).attrs({
109
- 'data-garden-id': COMPONENT_ID$t,
110
- 'data-garden-version': '9.0.0-next.9'
103
+ 'data-garden-id': COMPONENT_ID$s,
104
+ 'data-garden-version': '9.1.0'
111
105
  }).withConfig({
112
106
  displayName: "StyledMessage",
113
107
  componentId: "sc-jux8m5-0"
114
- })(["", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$t, props));
115
- StyledMessage.defaultProps = {
116
- theme: reactTheming.DEFAULT_THEME
117
- };
108
+ })(["", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$s, props));
118
109
 
119
- const COMPONENT_ID$s = 'dropdowns.combobox';
110
+ const COMPONENT_ID$r = 'dropdowns.combobox';
120
111
  const sizeStyles$a = props => {
121
- const minWidth = `${props.isCompact ? 100 : 144}px`;
122
- const marginTop = `${props.theme.space.base * (props.isCompact ? 1 : 2)}px`;
112
+ const minWidth = `${props.$isCompact ? 100 : 144}px`;
113
+ const marginTop = `${props.theme.space.base * (props.$isCompact ? 1 : 2)}px`;
123
114
  return styled.css(["min-width:", ";", ":not([hidden]) + &&,", " + &&,", " + &&,&& + ", ",&& + ", "{margin-top:", ";}"], minWidth, StyledLabel, StyledHint, StyledMessage, StyledHint, StyledMessage, marginTop);
124
115
  };
125
116
  const StyledCombobox = styled__default.default.div.attrs({
126
- 'data-garden-id': COMPONENT_ID$s,
127
- 'data-garden-version': '9.0.0-next.9'
117
+ 'data-garden-id': COMPONENT_ID$r,
118
+ 'data-garden-version': '9.1.0'
128
119
  }).withConfig({
129
120
  displayName: "StyledCombobox",
130
121
  componentId: "sc-13eybg8-0"
131
- })(["", ";", ";"], sizeStyles$a, props => reactTheming.retrieveComponentStyles(COMPONENT_ID$s, props));
132
- StyledCombobox.defaultProps = {
133
- theme: reactTheming.DEFAULT_THEME
134
- };
122
+ })(["", ";", ";"], sizeStyles$a, props => reactTheming.retrieveComponentStyles(COMPONENT_ID$r, props));
135
123
 
136
- const COMPONENT_ID$r = 'dropdowns.combobox.container';
124
+ const COMPONENT_ID$q = 'dropdowns.combobox.container';
137
125
  const StyledContainer = styled__default.default.div.attrs({
138
- 'data-garden-id': COMPONENT_ID$r,
139
- 'data-garden-version': '9.0.0-next.9'
126
+ 'data-garden-id': COMPONENT_ID$q,
127
+ 'data-garden-version': '9.1.0'
140
128
  }).withConfig({
141
129
  displayName: "StyledContainer",
142
130
  componentId: "sc-14i9jid-0"
143
- })(["display:flex;", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$r, props));
144
- StyledContainer.defaultProps = {
145
- theme: reactTheming.DEFAULT_THEME
146
- };
131
+ })(["display:flex;", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$q, props));
147
132
 
148
- const COMPONENT_ID$q = 'dropdowns.combobox.field';
133
+ const COMPONENT_ID$p = 'dropdowns.combobox.field';
149
134
  const StyledField = styled__default.default.div.attrs({
150
- 'data-garden-id': COMPONENT_ID$q,
151
- 'data-garden-version': '9.0.0-next.9'
135
+ 'data-garden-id': COMPONENT_ID$p,
136
+ 'data-garden-version': '9.1.0'
152
137
  }).withConfig({
153
138
  displayName: "StyledField",
154
139
  componentId: "sc-zc57xl-0"
155
- })(["direction:", ";", ";"], props => props.theme.rtl ? 'rtl' : 'ltr', props => reactTheming.retrieveComponentStyles(COMPONENT_ID$q, props));
156
- StyledField.defaultProps = {
157
- theme: reactTheming.DEFAULT_THEME
158
- };
140
+ })(["direction:", ";", ";"], props => props.theme.rtl ? 'rtl' : 'ltr', props => reactTheming.retrieveComponentStyles(COMPONENT_ID$p, props));
159
141
 
160
- const COMPONENT_ID$p = 'dropdowns.combobox.floating';
142
+ const COMPONENT_ID$o = 'dropdowns.combobox.floating';
161
143
  const StyledFloatingListbox = styled__default.default.div.attrs({
162
- 'data-garden-id': COMPONENT_ID$p,
163
- 'data-garden-version': '9.0.0-next.9'
144
+ 'data-garden-id': COMPONENT_ID$o,
145
+ 'data-garden-version': '9.1.0'
164
146
  }).withConfig({
165
147
  displayName: "StyledFloatingListbox",
166
148
  componentId: "sc-1cp6spf-0"
167
- })(["top:0;left:0;", ";", ";"], props => reactTheming.menuStyles(props.position, {
149
+ })(["top:0;left:0;", ";", ";"], props => reactTheming.menuStyles(props.$position, {
168
150
  theme: props.theme,
169
- hidden: props.isHidden,
151
+ hidden: props.$isHidden,
170
152
  animationModifier: '[data-garden-animate="true"]',
171
- zIndex: props.zIndex
172
- }), props => reactTheming.retrieveComponentStyles(COMPONENT_ID$p, props));
173
- StyledFloatingListbox.defaultProps = {
174
- theme: reactTheming.DEFAULT_THEME
175
- };
153
+ zIndex: props.$zIndex
154
+ }), props => reactTheming.retrieveComponentStyles(COMPONENT_ID$o, props));
176
155
 
177
- const COMPONENT_ID$o = 'dropdowns.combobox.input';
178
- const colorStyles$8 = props => {
179
- const placeholderColor = reactTheming.getColorV8('neutralHue', 400, props.theme);
156
+ const COMPONENT_ID$n = 'dropdowns.combobox.input';
157
+ const colorStyles$9 = _ref => {
158
+ let {
159
+ theme
160
+ } = _ref;
161
+ const placeholderColor = reactTheming.getColor({
162
+ theme,
163
+ variable: 'foreground.disabled'
164
+ });
180
165
  return styled.css(["background-color:inherit;color:inherit;&::placeholder{opacity:1;color:", ";}"], placeholderColor);
181
166
  };
182
167
  const getHeight = props => {
183
- if (props.isBare && !props.isMultiselectable) {
168
+ if (props.$isBare && !props.$isMultiselectable) {
184
169
  return props.theme.space.base * 5;
185
170
  }
186
- return props.theme.space.base * (props.isCompact ? 5 : 8);
171
+ return props.theme.space.base * (props.$isCompact ? 5 : 8);
187
172
  };
188
173
  const sizeStyles$9 = props => {
189
174
  const height = props.theme.space.base * 5;
@@ -194,89 +179,114 @@ const sizeStyles$9 = props => {
194
179
  return styled.css(["min-width:", ";height:", "px;line-height:", ";font-size:", ";&&{margin-top:", ";margin-bottom:", ";}"], minWidth, height, lineHeight, fontSize, margin, margin);
195
180
  };
196
181
  const StyledInput = styled__default.default.input.attrs({
197
- 'data-garden-id': COMPONENT_ID$o,
198
- 'data-garden-version': '9.0.0-next.9'
182
+ 'data-garden-id': COMPONENT_ID$n,
183
+ 'data-garden-version': '9.1.0'
199
184
  }).withConfig({
200
185
  displayName: "StyledInput",
201
186
  componentId: "sc-1lkqdg-0"
202
- })(["flex-basis:0;flex-grow:1;border:none;padding:0;font-family:inherit;&:focus{outline:none;}", ";", ";&[hidden]{display:revert;", "}&[aria-hidden='true']{display:none;}", ";"], sizeStyles$9, colorStyles$8, props => props.isEditable && polished.hideVisually(), props => reactTheming.retrieveComponentStyles(COMPONENT_ID$o, props));
203
- StyledInput.defaultProps = {
204
- theme: reactTheming.DEFAULT_THEME
205
- };
187
+ })(["flex-basis:0;flex-grow:1;border:none;padding:0;font-family:inherit;&:focus{outline:none;}", ";", ";&[hidden]{display:revert;", "}&[aria-hidden='true']{display:none;}", ";"], sizeStyles$9, colorStyles$9, props => props.$isEditable && polished.hideVisually(), props => reactTheming.retrieveComponentStyles(COMPONENT_ID$n, props));
206
188
 
207
- const COMPONENT_ID$n = 'dropdowns.combobox.input_group';
189
+ const COMPONENT_ID$m = 'dropdowns.combobox.input_group';
208
190
  const sizeStyles$8 = props => {
209
191
  const margin = props.theme.shadowWidths.sm;
210
192
  return styled.css(["margin:-", ";min-width:0;& > *{margin:", ";}"], margin, margin);
211
193
  };
212
194
  const StyledInputGroup = styled__default.default.div.attrs({
213
- 'data-garden-id': COMPONENT_ID$n,
214
- 'data-garden-version': '9.0.0-next.9'
195
+ 'data-garden-id': COMPONENT_ID$m,
196
+ 'data-garden-version': '9.1.0'
215
197
  }).withConfig({
216
198
  displayName: "StyledInputGroup",
217
199
  componentId: "sc-yx3q7u-0"
218
- })(["display:flex;flex-grow:1;flex-wrap:wrap;", ";", ";"], sizeStyles$8, props => reactTheming.retrieveComponentStyles(COMPONENT_ID$n, props));
219
- StyledInputGroup.defaultProps = {
220
- theme: reactTheming.DEFAULT_THEME
221
- };
200
+ })(["display:flex;flex-grow:1;flex-wrap:wrap;", ";", ";"], sizeStyles$8, props => reactTheming.retrieveComponentStyles(COMPONENT_ID$m, props));
222
201
 
223
- const COMPONENT_ID$m = 'dropdowns.combobox.trigger';
224
- const colorStyles$7 = props => {
225
- const SHADE = 600;
226
- let hue = 'neutralHue';
227
- if (props.validation === 'success') {
228
- hue = 'successHue';
229
- } else if (props.validation === 'warning') {
230
- hue = 'warningHue';
231
- } else if (props.validation === 'error') {
232
- hue = 'dangerHue';
233
- }
234
- const backgroundColor = props.isBare ? 'transparent' : reactTheming.getColorV8('background', 600 , props.theme);
202
+ const COMPONENT_ID$l = 'dropdowns.combobox.trigger';
203
+ const colorStyles$8 = _ref => {
204
+ let {
205
+ theme,
206
+ $validation,
207
+ $isBare,
208
+ $isLabelHovered,
209
+ $focusInset
210
+ } = _ref;
211
+ const foregroundColor = reactTheming.getColor({
212
+ theme,
213
+ variable: 'foreground.default'
214
+ });
215
+ const backgroundColor = $isBare ? 'transparent' : reactTheming.getColor({
216
+ theme,
217
+ variable: 'background.default'
218
+ });
235
219
  let borderColor;
220
+ let borderVariable;
236
221
  let hoverBorderColor;
237
222
  let focusBorderColor;
238
- let focusShade;
239
- if (props.validation) {
240
- borderColor = reactTheming.getColorV8(hue, SHADE, props.theme);
241
- hoverBorderColor = borderColor;
242
- if (props.validation === 'warning') {
243
- focusBorderColor = reactTheming.getColorV8(hue, SHADE + 100, props.theme);
244
- focusShade = SHADE + 100;
245
- } else {
246
- focusBorderColor = borderColor;
223
+ if ($validation) {
224
+ if ($validation === 'success') {
225
+ borderVariable = 'border.successEmphasis';
226
+ } else if ($validation === 'warning') {
227
+ borderVariable = 'border.warningEmphasis';
228
+ } else if ($validation === 'error') {
229
+ borderVariable = 'border.dangerEmphasis';
247
230
  }
231
+ borderColor = reactTheming.getColor({
232
+ theme,
233
+ variable: borderVariable
234
+ });
235
+ hoverBorderColor = borderColor;
236
+ focusBorderColor = borderColor;
248
237
  } else {
249
- borderColor = reactTheming.getColorV8('neutralHue', SHADE - 300, props.theme);
250
- hoverBorderColor = reactTheming.getColorV8('primaryHue', SHADE, props.theme);
238
+ borderColor = reactTheming.getColor({
239
+ theme,
240
+ variable: 'border.default',
241
+ dark: {
242
+ offset: -100
243
+ },
244
+ light: {
245
+ offset: 100
246
+ }
247
+ });
248
+ borderVariable = 'border.primaryEmphasis';
249
+ hoverBorderColor = reactTheming.getColor({
250
+ theme,
251
+ variable: borderVariable
252
+ });
251
253
  focusBorderColor = hoverBorderColor;
252
254
  }
253
- const disabledBackgroundColor = props.isBare ? undefined : reactTheming.getColorV8('neutralHue', SHADE - 500, props.theme);
254
- const disabledBorderColor = reactTheming.getColorV8('neutralHue', SHADE - 400, props.theme);
255
- const disabledForegroundColor = reactTheming.getColorV8('neutralHue', SHADE - 200, props.theme);
255
+ const disabledBackgroundColor = $isBare ? undefined : reactTheming.getColor({
256
+ theme,
257
+ variable: 'background.disabled'
258
+ });
259
+ const disabledBorderColor = reactTheming.getColor({
260
+ theme,
261
+ variable: 'border.disabled'
262
+ });
263
+ const disabledForegroundColor = reactTheming.getColor({
264
+ theme,
265
+ variable: 'foreground.disabled'
266
+ });
256
267
  const focusSelector = `
257
268
  &:focus-within:not([aria-disabled='true']),
258
269
  &:focus-visible
259
270
  `;
260
- return styled.css(["border-color:", ";background-color:", ";color:", ";&:hover{border-color:", ";}", " &[aria-disabled='true']{border-color:", ";background-color:", ";color:", ";}"], props.isLabelHovered ? hoverBorderColor : borderColor, backgroundColor, reactTheming.getColorV8('foreground', 600 , props.theme), hoverBorderColor, reactTheming.focusStyles({
261
- theme: props.theme,
262
- inset: props.focusInset,
271
+ return styled.css(["color-scheme:only ", ";border-color:", ";background-color:", ";color:", ";&:hover{border-color:", ";}", " &[aria-disabled='true']{border-color:", ";background-color:", ";color:", ";}"], theme.colors.base, $isLabelHovered ? hoverBorderColor : borderColor, backgroundColor, foregroundColor, hoverBorderColor, reactTheming.focusStyles({
272
+ theme,
273
+ inset: $focusInset,
263
274
  color: {
264
- hue: focusBorderColor,
265
- shade: focusShade
275
+ variable: borderVariable
266
276
  },
267
277
  selector: focusSelector,
268
278
  styles: {
269
279
  borderColor: focusBorderColor
270
280
  },
271
- condition: !props.isBare
281
+ condition: !$isBare
272
282
  }), disabledBorderColor, disabledBackgroundColor, disabledForegroundColor);
273
283
  };
274
284
  const sizeStyles$7 = props => {
275
285
  const inputHeight = getHeight(props);
276
286
  let minHeight;
277
287
  let horizontalPadding;
278
- if (props.isBare) {
279
- if (props.isMultiselectable) {
288
+ if (props.$isBare) {
289
+ if (props.$isMultiselectable) {
280
290
  minHeight = polished.math(`${props.theme.shadowWidths.sm} * 2 + ${inputHeight}`);
281
291
  horizontalPadding = props.theme.shadowWidths.sm;
282
292
  } else {
@@ -284,30 +294,46 @@ const sizeStyles$7 = props => {
284
294
  horizontalPadding = '0';
285
295
  }
286
296
  } else {
287
- minHeight = `${props.theme.space.base * (props.isCompact ? 3 : 2) + inputHeight}px`;
297
+ minHeight = `${props.theme.space.base * (props.$isCompact ? 3 : 2) + inputHeight}px`;
288
298
  horizontalPadding = `${props.theme.space.base * 3}px`;
289
299
  }
290
- const maxHeight = props.maxHeight || minHeight;
291
- const verticalPadding = polished.math(`(${minHeight} - ${inputHeight} - (${props.isBare ? 0 : props.theme.borderWidths.sm} * 2)) / 2`);
292
- return styled.css(["padding:", " ", ";min-height:", ";max-height:", ";font-size:", ";"], verticalPadding, horizontalPadding, minHeight, maxHeight, props.theme.fontSizes.md);
300
+ const $maxHeight = props.$maxHeight || minHeight;
301
+ const verticalPadding = polished.math(`(${minHeight} - ${inputHeight} - (${props.$isBare ? 0 : props.theme.borderWidths.sm} * 2)) / 2`);
302
+ return styled.css(["padding:", " ", ";min-height:", ";max-height:", ";font-size:", ";"], verticalPadding, horizontalPadding, minHeight, $maxHeight, props.theme.fontSizes.md);
293
303
  };
294
304
  const StyledTrigger = styled__default.default.div.attrs({
295
- 'data-garden-id': COMPONENT_ID$m,
296
- 'data-garden-version': '9.0.0-next.9'
305
+ 'data-garden-id': COMPONENT_ID$l,
306
+ 'data-garden-version': '9.1.0'
297
307
  }).withConfig({
298
308
  displayName: "StyledTrigger",
299
309
  componentId: "sc-116nftk-0"
300
- })(["overflow-y:auto;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 ? 'none' : props.theme.borders.sm, props => props.isBare ? '0' : props.theme.borderRadii.md, props => !props.isAutocomplete && props.isEditable ? 'text' : 'pointer', sizeStyles$7, colorStyles$7, props => reactTheming.retrieveComponentStyles(COMPONENT_ID$m, props));
301
- StyledTrigger.defaultProps = {
302
- theme: reactTheming.DEFAULT_THEME
303
- };
310
+ })(["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$7, colorStyles$8, props => reactTheming.retrieveComponentStyles(COMPONENT_ID$l, props));
304
311
 
305
- const COMPONENT_ID$l = 'dropdowns.combobox.input_icon';
306
- const colorStyles$6 = props => {
307
- const color = reactTheming.getColorV8('neutralHue', 600, props.theme);
308
- const focusColor = reactTheming.getColorV8('neutralHue', 700, props.theme);
309
- const disabledColor = reactTheming.getColorV8('neutralHue', 400, props.theme);
310
- return styled.css(["color:", ";", ":hover &,", ":focus-within &,", ":focus &{color:", ";}", "[aria-disabled='true'] &{color:", ";}"], props.$isLabelHovered ? focusColor : color, StyledTrigger, StyledTrigger, StyledTrigger, focusColor, StyledTrigger, disabledColor);
312
+ const COMPONENT_ID$k = 'dropdowns.combobox.input_icon';
313
+ const colorStyles$7 = _ref => {
314
+ let {
315
+ theme,
316
+ $isLabelHovered
317
+ } = _ref;
318
+ const options = {
319
+ theme,
320
+ variable: 'foreground.subtle'
321
+ };
322
+ const color = reactTheming.getColor(options);
323
+ const focusColor = reactTheming.getColor({
324
+ ...options,
325
+ dark: {
326
+ offset: -100
327
+ },
328
+ light: {
329
+ offset: 100
330
+ }
331
+ });
332
+ const disabledColor = reactTheming.getColor({
333
+ theme,
334
+ variable: 'foreground.disabled'
335
+ });
336
+ return styled.css(["color:", ";", ":hover &&,", ":focus-within &&,", ":focus &&{color:", ";}", "[aria-disabled='true'] &&{color:", ";}"], $isLabelHovered ? focusColor : color, StyledTrigger, StyledTrigger, StyledTrigger, focusColor, StyledTrigger, disabledColor);
311
337
  };
312
338
  const sizeStyles$6 = props => {
313
339
  const size = props.theme.iconSizes.md;
@@ -322,35 +348,53 @@ const sizeStyles$6 = props => {
322
348
  return styled.css(["top:", ";margin-", ":", ";width:", ";height:", ";"], position, side, margin, size, size);
323
349
  };
324
350
  const StyledInputIcon = styled__default.default(reactTheming.StyledBaseIcon).attrs({
325
- 'data-garden-id': COMPONENT_ID$l,
326
- 'data-garden-version': '9.0.0-next.9'
351
+ 'data-garden-id': COMPONENT_ID$k,
352
+ 'data-garden-version': '9.1.0'
327
353
  }).withConfig({
328
354
  displayName: "StyledInputIcon",
329
355
  componentId: "sc-gqbs1s-0"
330
- })(["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$6, colorStyles$6, props => reactTheming.retrieveComponentStyles(COMPONENT_ID$l, props));
331
- StyledInputIcon.defaultProps = {
332
- theme: reactTheming.DEFAULT_THEME
333
- };
356
+ })(["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$6, colorStyles$7, props => reactTheming.retrieveComponentStyles(COMPONENT_ID$k, props));
334
357
 
335
- const COMPONENT_ID$k = 'dropdowns.combobox.option';
336
- const colorStyles$5 = props => {
358
+ const COMPONENT_ID$j = 'dropdowns.combobox.option';
359
+ const colorStyles$6 = _ref => {
360
+ let {
361
+ theme,
362
+ $isActive,
363
+ $type
364
+ } = _ref;
337
365
  let backgroundColor;
338
366
  let boxShadow;
339
- if (props.isActive && props.$type !== 'group' && props.$type !== 'header') {
340
- const hue = props.$type === 'danger' ? 'dangerHue' : 'primaryHue';
341
- backgroundColor = reactTheming.getColorV8(hue, 600, props.theme, 0.08);
342
- boxShadow = `inset ${props.theme.rtl ? `-${props.theme.shadowWidths.md}` : props.theme.shadowWidths.md} 0 ${reactTheming.getColorV8(hue, 600, props.theme)}`;
367
+ if ($isActive && $type !== 'group' && $type !== 'header') {
368
+ const variable = 'background.primaryEmphasis';
369
+ backgroundColor = reactTheming.getColor({
370
+ theme,
371
+ variable,
372
+ transparency: theme.opacity[100]
373
+ });
374
+ boxShadow = `inset ${theme.rtl ? `-${theme.shadowWidths.md}` : theme.shadowWidths.md} 0 ${reactTheming.getColor({
375
+ theme,
376
+ variable
377
+ })}`;
343
378
  }
344
- const disabledForegroundColor = reactTheming.getColorV8('neutralHue', 400, props.theme);
345
- let foregroundColor = reactTheming.getColorV8('foreground', 600 , props.theme);
346
- if (props.$type === 'add') {
347
- foregroundColor = reactTheming.getColorV8('primaryHue', 600, props.theme);
348
- } else if (props.$type === 'danger') {
349
- foregroundColor = reactTheming.getColorV8('dangerHue', 600, props.theme);
379
+ let foregroundVariable;
380
+ if ($type === 'add') {
381
+ foregroundVariable = 'foreground.primary';
382
+ } else if ($type === 'danger') {
383
+ foregroundVariable = 'foreground.danger';
384
+ } else {
385
+ foregroundVariable = 'foreground.default';
350
386
  }
387
+ const foregroundColor = reactTheming.getColor({
388
+ theme,
389
+ variable: foregroundVariable
390
+ });
391
+ const disabledForegroundColor = reactTheming.getColor({
392
+ theme,
393
+ variable: 'foreground.disabled'
394
+ });
351
395
  return styled.css(["box-shadow:", ";background-color:", ";color:", ";&[aria-disabled='true']{background-color:transparent;color:", ";}"], boxShadow, backgroundColor, foregroundColor, disabledForegroundColor);
352
396
  };
353
- const getMinHeight = props => props.theme.space.base * (props.isCompact ? 7 : 9);
397
+ const getMinHeight = props => props.theme.space.base * (props.$isCompact ? 7 : 9);
354
398
  const sizeStyles$5 = props => {
355
399
  const lineHeight = props.theme.lineHeights.md;
356
400
  const minHeight = getMinHeight(props);
@@ -359,43 +403,40 @@ const sizeStyles$5 = props => {
359
403
  return styled.css(["box-sizing:border-box;padding:", " ", ";min-height:", "px;line-height:", ";"], paddingVertical, paddingHorizontal, minHeight, lineHeight);
360
404
  };
361
405
  const StyledOption = styled__default.default.li.attrs({
362
- 'data-garden-id': COMPONENT_ID$k,
363
- 'data-garden-version': '9.0.0-next.9'
406
+ 'data-garden-id': COMPONENT_ID$j,
407
+ 'data-garden-version': '9.1.0'
364
408
  }).withConfig({
365
409
  displayName: "StyledOption",
366
410
  componentId: "sc-jl4wn6-0"
367
- })(["display:flex;position:relative;transition:color 0.25s ease-in-out;cursor:", ";overflow-wrap:anywhere;font-weight:", ";user-select:none;&:focus{outline:none;}", ";", ";&[aria-disabled='true']{cursor:default;}&[aria-hidden='true']{", ";}", ";"], props => props.$type === 'group' || props.$type === 'header' ? 'default' : 'pointer', props => props.$type === 'header' || props.$type === 'previous' ? props.theme.fontWeights.semibold : props.theme.fontWeights.regular, sizeStyles$5, colorStyles$5, polished.hideVisually(), props => reactTheming.retrieveComponentStyles(COMPONENT_ID$k, props));
368
- StyledOption.defaultProps = {
369
- theme: reactTheming.DEFAULT_THEME
370
- };
411
+ })(["display:flex;position:relative;transition:color 0.25s ease-in-out;cursor:", ";overflow-wrap:anywhere;font-weight:", ";user-select:none;&:focus{outline:none;}", ";", ";&[aria-disabled='true']{cursor:default;}&[aria-hidden='true']{", ";}", ";"], props => props.$type === 'group' || props.$type === 'header' ? 'default' : 'pointer', props => props.$type === 'header' || props.$type === 'previous' ? props.theme.fontWeights.semibold : props.theme.fontWeights.regular, sizeStyles$5, colorStyles$6, polished.hideVisually(), props => reactTheming.retrieveComponentStyles(COMPONENT_ID$j, props));
371
412
 
372
- const COMPONENT_ID$j = 'dropdowns.combobox.option.content';
413
+ const COMPONENT_ID$i = 'dropdowns.combobox.option.content';
373
414
  const StyledOptionContent = styled__default.default.div.attrs({
374
- 'data-garden-id': COMPONENT_ID$j,
375
- 'data-garden-version': '9.0.0-next.9'
415
+ 'data-garden-id': COMPONENT_ID$i,
416
+ 'data-garden-version': '9.1.0'
376
417
  }).withConfig({
377
418
  displayName: "StyledOptionContent",
378
419
  componentId: "sc-121ujpu-0"
379
- })(["display:flex;flex-direction:column;flex-grow:1;", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$j, props));
380
- StyledOptionContent.defaultProps = {
381
- theme: reactTheming.DEFAULT_THEME
382
- };
420
+ })(["display:flex;flex-direction:column;flex-grow:1;", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$i, props));
383
421
 
384
- const COMPONENT_ID$i = 'dropdowns.combobox.optgroup';
422
+ const COMPONENT_ID$h = 'dropdowns.combobox.optgroup';
385
423
  const StyledOptGroup = styled__default.default.ul.attrs({
386
- 'data-garden-id': COMPONENT_ID$i,
387
- 'data-garden-version': '9.0.0-next.9'
424
+ 'data-garden-id': COMPONENT_ID$h,
425
+ 'data-garden-version': '9.1.0'
388
426
  }).withConfig({
389
427
  displayName: "StyledOptGroup",
390
428
  componentId: "sc-1kavqsx-0"
391
- })(["margin:0;padding:0;list-style-type:none;", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$i, props));
392
- StyledOptGroup.defaultProps = {
393
- theme: reactTheming.DEFAULT_THEME
394
- };
429
+ })(["margin:0;padding:0;list-style-type:none;", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$h, props));
395
430
 
396
- const COMPONENT_ID$h = 'dropdowns.combobox.separator';
397
- const colorStyles$4 = props => {
398
- const backgroundColor = reactTheming.getColorV8('neutralHue', 200, props.theme);
431
+ const COMPONENT_ID$g = 'dropdowns.combobox.separator';
432
+ const colorStyles$5 = _ref => {
433
+ let {
434
+ theme
435
+ } = _ref;
436
+ const backgroundColor = reactTheming.getColor({
437
+ theme,
438
+ variable: 'border.subtle'
439
+ });
399
440
  return styled.css(["background-color:", ";"], backgroundColor);
400
441
  };
401
442
  const sizeStyles$4 = props => {
@@ -404,34 +445,50 @@ const sizeStyles$4 = props => {
404
445
  return styled.css(["margin:", " 0;height:", ";"], margin, height);
405
446
  };
406
447
  const StyledListboxSeparator = styled__default.default.li.attrs({
407
- 'data-garden-id': COMPONENT_ID$h,
408
- 'data-garden-version': '9.0.0-next.9'
448
+ 'data-garden-id': COMPONENT_ID$g,
449
+ 'data-garden-version': '9.1.0'
409
450
  }).withConfig({
410
451
  displayName: "StyledListboxSeparator",
411
452
  componentId: "sc-1p6toh2-0"
412
- })(["cursor:default;", ";", ";", ";"], sizeStyles$4, colorStyles$4, props => reactTheming.retrieveComponentStyles(COMPONENT_ID$h, props));
413
- StyledListboxSeparator.defaultProps = {
414
- theme: reactTheming.DEFAULT_THEME
415
- };
453
+ })(["cursor:default;", ";", ";", ";"], sizeStyles$4, colorStyles$5, props => reactTheming.retrieveComponentStyles(COMPONENT_ID$g, props));
416
454
 
417
- const COMPONENT_ID$g = 'dropdowns.combobox.listbox';
455
+ const COMPONENT_ID$f = 'dropdowns.combobox.listbox';
418
456
  const sizeStyles$3 = props => {
419
457
  const padding = props.theme.space.base;
420
- const minHeight = props.minHeight === undefined ? `${getMinHeight(props) + padding * 2}px` : props.minHeight;
421
- return styled.css(["min-height:", ";max-height:", ";&&&{padding-top:", "px;padding-bottom:", "px;}"], minHeight, props.maxHeight, padding, padding);
458
+ const $minHeight = props.$minHeight === undefined ? `${getMinHeight(props) + padding * 2}px` : props.$minHeight;
459
+ return styled.css(["min-height:", ";max-height:", ";&&&{padding-top:", "px;padding-bottom:", "px;}"], $minHeight, props.$maxHeight, padding, padding);
422
460
  };
423
461
  const StyledListbox = styled__default.default.ul.attrs({
424
- 'data-garden-id': COMPONENT_ID$g,
425
- 'data-garden-version': '9.0.0-next.9'
462
+ 'data-garden-id': COMPONENT_ID$f,
463
+ 'data-garden-version': '9.1.0'
426
464
  }).withConfig({
427
465
  displayName: "StyledListbox",
428
466
  componentId: "sc-1k13ba7-0"
429
467
  })(["overflow-y:auto;list-style-type:none;", ";&&&{display:block;}", ":first-child ", " ", ":first-child ", "[role='none']:first-child{display:none;}"], sizeStyles$3, StyledOption, StyledOptionContent, StyledOptGroup, StyledListboxSeparator);
430
- StyledListbox.defaultProps = {
431
- theme: reactTheming.DEFAULT_THEME
432
- };
433
468
 
434
- const COMPONENT_ID$f = 'dropdowns.combobox.option.icon';
469
+ const COMPONENT_ID$e = 'dropdowns.combobox.option.icon';
470
+ const colorStyles$4 = _ref => {
471
+ let {
472
+ theme,
473
+ $isDisabled,
474
+ $type
475
+ } = _ref;
476
+ let variable;
477
+ if ($isDisabled) {
478
+ variable = 'foreground.disabled';
479
+ } else if ($type === 'danger') {
480
+ variable = 'foreground.danger';
481
+ } else if ($type === 'add') {
482
+ variable = 'foreground.primary';
483
+ } else {
484
+ variable = 'foreground.subtle';
485
+ }
486
+ const color = reactTheming.getColor({
487
+ theme,
488
+ variable
489
+ });
490
+ return styled.css(["color:", ";"], color);
491
+ };
435
492
  const sizeStyles$2 = props => {
436
493
  const size = props.theme.iconSizes.md;
437
494
  const marginTop = polished.math(`(${props.theme.lineHeights.md} - ${size}) / 2`);
@@ -439,19 +496,24 @@ const sizeStyles$2 = props => {
439
496
  return styled.css(["margin-top:", ";margin-", ":", ";width:", ";height:", ";"], marginTop, props.theme.rtl ? 'left' : 'right', marginHorizontal, size, size);
440
497
  };
441
498
  const StyledOptionIcon = styled__default.default(reactTheming.StyledBaseIcon).attrs({
442
- 'data-garden-id': COMPONENT_ID$f,
443
- 'data-garden-version': '9.0.0-next.9'
499
+ 'data-garden-id': COMPONENT_ID$e,
500
+ 'data-garden-version': '9.1.0'
444
501
  }).withConfig({
445
502
  displayName: "StyledOptionIcon",
446
503
  componentId: "sc-qsab3y-0"
447
- })(["flex-shrink:0;", ";", ";"], sizeStyles$2, props => reactTheming.retrieveComponentStyles(COMPONENT_ID$f, props));
448
- StyledOptionIcon.defaultProps = {
449
- theme: reactTheming.DEFAULT_THEME
450
- };
504
+ })(["flex-shrink:0;", ";", ";", ";"], sizeStyles$2, colorStyles$4, props => reactTheming.retrieveComponentStyles(COMPONENT_ID$e, props));
451
505
 
452
- const COMPONENT_ID$e = 'dropdowns.combobox.option.meta';
453
- const colorStyles$3 = props => {
454
- const color = reactTheming.getColorV8('neutralHue', props.isDisabled ? 400 : 600, props.theme);
506
+ const COMPONENT_ID$d = 'dropdowns.combobox.option.meta';
507
+ const colorStyles$3 = _ref => {
508
+ let {
509
+ theme,
510
+ $isDisabled
511
+ } = _ref;
512
+ const variable = $isDisabled ? 'foreground.disabled' : 'foreground.subtle';
513
+ const color = reactTheming.getColor({
514
+ theme,
515
+ variable
516
+ });
455
517
  return styled.css(["color:", ";"], color);
456
518
  };
457
519
  const sizeStyles$1 = props => {
@@ -460,26 +522,33 @@ const sizeStyles$1 = props => {
460
522
  return styled.css(["line-height:", ";font-size:", ";"], lineHeight, fontSize);
461
523
  };
462
524
  const StyledOptionMeta = styled__default.default.div.attrs({
463
- 'data-garden-id': COMPONENT_ID$e,
464
- 'data-garden-version': '9.0.0-next.9'
525
+ 'data-garden-id': COMPONENT_ID$d,
526
+ 'data-garden-version': '9.1.0'
465
527
  }).withConfig({
466
528
  displayName: "StyledOptionMeta",
467
529
  componentId: "sc-j6pu10-0"
468
- })(["transition:color 0.25s ease-in-out;font-weight:", ";", ";", ";", ";"], props => props.theme.fontWeights.regular, sizeStyles$1, colorStyles$3, props => reactTheming.retrieveComponentStyles(COMPONENT_ID$e, props));
469
- StyledOptionMeta.defaultProps = {
470
- theme: reactTheming.DEFAULT_THEME
471
- };
530
+ })(["transition:color 0.25s ease-in-out;font-weight:", ";", ";", ";", ";"], props => props.theme.fontWeights.regular, sizeStyles$1, colorStyles$3, props => reactTheming.retrieveComponentStyles(COMPONENT_ID$d, props));
472
531
 
473
- const COMPONENT_ID$d = 'dropdowns.combobox.option.type_icon';
474
- const colorStyles$2 = props => {
475
- const opacity = props.$type && props.$type !== 'danger' ? 1 : 0;
532
+ const COMPONENT_ID$c = 'dropdowns.combobox.option.type_icon';
533
+ const colorStyles$2 = _ref => {
534
+ let {
535
+ theme,
536
+ $type
537
+ } = _ref;
538
+ const opacity = $type && $type !== 'danger' ? 1 : 0;
476
539
  let color;
477
- if (props.$type === 'add' || props.$type === 'danger') {
540
+ if ($type === 'add') {
478
541
  color = 'inherit';
479
- } else if (props.$type === 'header' || props.$type === 'next' || props.$type === 'previous') {
480
- color = reactTheming.getColorV8('neutralHue', 600, props.theme);
542
+ } else if ($type === 'header' || $type === 'next' || $type === 'previous') {
543
+ color = reactTheming.getColor({
544
+ theme,
545
+ variable: 'foreground.subtle'
546
+ });
481
547
  } else {
482
- color = reactTheming.getColorV8('primaryHue', 600, props.theme);
548
+ color = reactTheming.getColor({
549
+ theme,
550
+ variable: 'foreground.primary'
551
+ });
483
552
  }
484
553
  return styled.css(["opacity:", ";color:", ";", "[aria-selected='true'] > &{opacity:1;}", "[aria-disabled='true'] > &{color:inherit;}"], opacity, color, StyledOption, StyledOption);
485
554
  };
@@ -496,189 +565,154 @@ const sizeStyles = props => {
496
565
  return styled.css(["top:", ";", ":", ";width:", ";height:", ";"], top, side, position, size, size);
497
566
  };
498
567
  const StyledOptionTypeIcon = styled__default.default(reactTheming.StyledBaseIcon).attrs({
499
- 'data-garden-id': COMPONENT_ID$d,
500
- 'data-garden-version': '9.0.0-next.9'
568
+ 'data-garden-id': COMPONENT_ID$c,
569
+ 'data-garden-version': '9.1.0'
501
570
  }).withConfig({
502
571
  displayName: "StyledOptionTypeIcon",
503
572
  componentId: "sc-xpink2-0"
504
- })(["position:absolute;transform:", ";transition:opacity 0.1s ease-in-out;", ";", ";", ";"], props => props.theme.rtl && (props.$type === 'next' || props.$type === 'previous') && 'rotate(180deg)', sizeStyles, colorStyles$2, props => reactTheming.retrieveComponentStyles(COMPONENT_ID$d, props));
505
- StyledOptionTypeIcon.defaultProps = {
506
- theme: reactTheming.DEFAULT_THEME
507
- };
573
+ })(["position:absolute;transform:", ";transition:opacity 0.1s ease-in-out;", ";", ";", ";"], props => props.theme.rtl && (props.$type === 'next' || props.$type === 'previous') && 'rotate(180deg)', sizeStyles, colorStyles$2, props => reactTheming.retrieveComponentStyles(COMPONENT_ID$c, props));
508
574
 
509
- const COMPONENT_ID$c = 'dropdowns.combobox.tag';
575
+ const COMPONENT_ID$b = 'dropdowns.combobox.tag';
510
576
  const StyledTag = styled__default.default(reactTags.Tag).attrs({
511
- 'data-garden-id': COMPONENT_ID$c,
512
- 'data-garden-version': '9.0.0-next.9'
577
+ 'data-garden-id': COMPONENT_ID$b,
578
+ 'data-garden-version': '9.1.0'
513
579
  }).withConfig({
514
580
  displayName: "StyledTag",
515
581
  componentId: "sc-1alam0r-0"
516
- })(["&[aria-disabled='true']{color:", ";}&[hidden]{display:revert;", "}", ";"], props => props.hue ? undefined : reactTheming.getColorV8('neutralHue', 400, props.theme), polished.hideVisually(), props => reactTheming.retrieveComponentStyles(COMPONENT_ID$c, props));
517
- StyledTag.defaultProps = {
518
- theme: reactTheming.DEFAULT_THEME
519
- };
582
+ })(["&[aria-disabled='true']{color:", ";}&[hidden]{display:revert;", "}", ";"], props => props.hue ? undefined : reactTheming.getColor({
583
+ theme: props.theme,
584
+ variable: 'foreground.disabled'
585
+ }), polished.hideVisually(), props => reactTheming.retrieveComponentStyles(COMPONENT_ID$b, props));
520
586
 
521
- const COMPONENT_ID$b = 'dropdowns.combobox.value';
522
- const colorStyles$1 = props => {
523
- const foregroundColor = props.isPlaceholder && reactTheming.getColorV8('neutralHue', 400, props.theme);
587
+ const COMPONENT_ID$a = 'dropdowns.combobox.value';
588
+ const colorStyles$1 = _ref => {
589
+ let {
590
+ theme,
591
+ $isPlaceholder
592
+ } = _ref;
593
+ const foregroundColor = $isPlaceholder && reactTheming.getColor({
594
+ theme,
595
+ variable: 'foreground.disabled'
596
+ });
524
597
  return styled.css(["color:", ";"], foregroundColor);
525
598
  };
526
599
  const StyledValue = styled__default.default.div.attrs({
527
- 'data-garden-id': COMPONENT_ID$b,
528
- 'data-garden-version': '9.0.0-next.9'
600
+ 'data-garden-id': COMPONENT_ID$a,
601
+ 'data-garden-version': '9.1.0'
529
602
  }).withConfig({
530
603
  displayName: "StyledValue",
531
604
  componentId: "sc-t719sx-0"
532
605
  })(["flex-basis:0;flex-grow:1;cursor:", ";overflow:hidden;text-overflow:ellipsis;white-space:pre;user-select:none;", ";", ";&[hidden]{display:none;}", ";"], props => {
533
- if (props.isDisabled) {
606
+ if (props.$isDisabled) {
534
607
  return 'default';
535
608
  }
536
- return props.isEditable && !props.isAutocomplete ? 'text' : 'pointer';
537
- }, sizeStyles$9, colorStyles$1, props => reactTheming.retrieveComponentStyles(COMPONENT_ID$b, props));
538
- StyledValue.defaultProps = {
539
- theme: reactTheming.DEFAULT_THEME
540
- };
609
+ return props.$isEditable && !props.$isAutocomplete ? 'text' : 'pointer';
610
+ }, sizeStyles$9, colorStyles$1, props => reactTheming.retrieveComponentStyles(COMPONENT_ID$a, props));
541
611
 
542
- const COMPONENT_ID$a = 'dropdowns.combobox.tags_button';
543
- const colorStyles = props => {
544
- const color = reactTheming.getColorV8('primaryHue', 600, props.theme);
612
+ const COMPONENT_ID$9 = 'dropdowns.combobox.tags_button';
613
+ const colorStyles = _ref => {
614
+ let {
615
+ theme
616
+ } = _ref;
617
+ const color = reactTheming.getColor({
618
+ theme,
619
+ variable: 'foreground.primary'
620
+ });
545
621
  return styled.css(["color:", ";&:disabled{color:inherit;}"], color);
546
622
  };
547
623
  const StyledTagsButton = styled__default.default(StyledValue).attrs({
548
624
  as: 'button',
549
- 'data-garden-id': COMPONENT_ID$a,
550
- 'data-garden-version': '9.0.0-next.9'
625
+ 'data-garden-id': COMPONENT_ID$9,
626
+ 'data-garden-version': '9.1.0'
551
627
  }).withConfig({
552
628
  displayName: "StyledTagsButton",
553
629
  componentId: "sc-6q5w33-0"
554
- })(["display:inline-flex;flex:0 1 auto;align-items:center;border:none;background-color:transparent;cursor:pointer;min-width:auto;font-family:inherit;&:hover{text-decoration:underline;}", ";&:disabled{cursor:default;text-decoration:none;}", ";"], colorStyles, props => reactTheming.retrieveComponentStyles(COMPONENT_ID$a, props));
555
- StyledTagsButton.defaultProps = {
556
- theme: reactTheming.DEFAULT_THEME
557
- };
630
+ })(["display:inline-flex;flex:0 1 auto;align-items:center;border:none;background-color:transparent;cursor:pointer;min-width:auto;font-family:inherit;&:hover{text-decoration:underline;}", ";&:disabled{cursor:default;text-decoration:none;}", ";"], colorStyles, props => reactTheming.retrieveComponentStyles(COMPONENT_ID$9, props));
558
631
 
559
- const COMPONENT_ID$9 = 'dropdowns.menu';
632
+ const COMPONENT_ID$8 = 'dropdowns.menu';
560
633
  const StyledMenu = styled__default.default(StyledListbox).attrs({
561
- 'data-garden-id': COMPONENT_ID$9,
562
- 'data-garden-version': '9.0.0-next.9'
634
+ 'data-garden-id': COMPONENT_ID$8,
635
+ 'data-garden-version': '9.1.0'
563
636
  }).withConfig({
564
637
  displayName: "StyledMenu",
565
638
  componentId: "sc-f77ntu-0"
566
- })(["position:static !important;", ";", ";"], props => props.arrowPosition && reactTheming.arrowStyles(props.arrowPosition, {
567
- size: `${props.theme.space.base * 2}px`,
568
- inset: '2px',
639
+ })(["position:static !important;", ";", ";"], props => props.$arrowPosition && reactTheming.arrowStyles(props.$arrowPosition, {
640
+ size: `${props.theme.space.base * 1.5}px`,
641
+ inset: '1px',
569
642
  animationModifier: '[data-garden-animate-arrow="true"]'
570
- }), props => reactTheming.retrieveComponentStyles(COMPONENT_ID$9, props));
571
- StyledMenu.defaultProps = {
572
- theme: reactTheming.DEFAULT_THEME
573
- };
643
+ }), props => reactTheming.retrieveComponentStyles(COMPONENT_ID$8, props));
574
644
 
575
- const COMPONENT_ID$8 = 'dropdowns.menu.floating';
645
+ const COMPONENT_ID$7 = 'dropdowns.menu.floating';
576
646
  const StyledFloatingMenu = styled__default.default(StyledFloatingListbox).attrs({
577
- 'data-garden-id': COMPONENT_ID$8,
578
- 'data-garden-version': '9.0.0-next.9'
647
+ 'data-garden-id': COMPONENT_ID$7,
648
+ 'data-garden-version': '9.1.0'
579
649
  }).withConfig({
580
650
  displayName: "StyledFloatingMenu",
581
651
  componentId: "sc-1rc7ahb-0"
582
- })(["", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$8, props));
583
- StyledFloatingMenu.defaultProps = {
584
- theme: reactTheming.DEFAULT_THEME
585
- };
652
+ })(["", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$7, props));
586
653
 
587
- const COMPONENT_ID$7 = 'dropdowns.menu.item';
654
+ const COMPONENT_ID$6 = 'dropdowns.menu.item';
588
655
  const StyledItem = styled__default.default(StyledOption).attrs({
589
- 'data-garden-id': COMPONENT_ID$7,
590
- 'data-garden-version': '9.0.0-next.9'
656
+ 'data-garden-id': COMPONENT_ID$6,
657
+ 'data-garden-version': '9.1.0'
591
658
  }).withConfig({
592
659
  displayName: "StyledItem",
593
660
  componentId: "sc-1jp99dq-0"
594
- })(["", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$7, props));
595
- StyledItem.defaultProps = {
596
- theme: reactTheming.DEFAULT_THEME
597
- };
661
+ })(["", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$6, props));
598
662
 
599
- const COMPONENT_ID$6 = 'dropdowns.menu.item.content';
663
+ const COMPONENT_ID$5 = 'dropdowns.menu.item.content';
600
664
  const StyledItemContent = styled__default.default(StyledOptionContent).attrs({
601
- 'data-garden-id': COMPONENT_ID$6,
602
- 'data-garden-version': '9.0.0-next.9'
665
+ 'data-garden-id': COMPONENT_ID$5,
666
+ 'data-garden-version': '9.1.0'
603
667
  }).withConfig({
604
668
  displayName: "StyledItemContent",
605
669
  componentId: "sc-1opglsb-0"
606
- })(["", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$6, props));
607
- StyledItemContent.defaultProps = {
608
- theme: reactTheming.DEFAULT_THEME
609
- };
670
+ })(["", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$5, props));
610
671
 
611
- const COMPONENT_ID$5 = 'dropdowns.menu.item_group';
672
+ const COMPONENT_ID$4 = 'dropdowns.menu.item_group';
612
673
  const StyledItemGroup = styled__default.default(StyledOptGroup).attrs({
613
- 'data-garden-id': COMPONENT_ID$5,
614
- 'data-garden-version': '9.0.0-next.9'
674
+ 'data-garden-id': COMPONENT_ID$4,
675
+ 'data-garden-version': '9.1.0'
615
676
  }).withConfig({
616
677
  displayName: "StyledItemGroup",
617
678
  componentId: "sc-1umk3cg-0"
618
- })(["", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$5, props));
619
- StyledItemGroup.defaultProps = {
620
- theme: reactTheming.DEFAULT_THEME
621
- };
679
+ })(["", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$4, props));
622
680
 
623
- const COMPONENT_ID$4 = 'dropdowns.menu.item.icon';
681
+ const COMPONENT_ID$3 = 'dropdowns.menu.item.icon';
624
682
  const StyledItemIcon = styled__default.default(StyledOptionIcon).attrs({
625
- 'data-garden-id': COMPONENT_ID$4,
626
- 'data-garden-version': '9.0.0-next.9'
683
+ 'data-garden-id': COMPONENT_ID$3,
684
+ 'data-garden-version': '9.1.0'
627
685
  }).withConfig({
628
686
  displayName: "StyledItemIcon",
629
687
  componentId: "sc-w9orqb-0"
630
- })(["", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$4, props));
631
- StyledItemIcon.defaultProps = {
632
- theme: reactTheming.DEFAULT_THEME
633
- };
688
+ })(["", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$3, props));
634
689
 
635
- const COMPONENT_ID$3 = 'dropdowns.menu.item.meta';
690
+ const COMPONENT_ID$2 = 'dropdowns.menu.item.meta';
636
691
  const StyledItemMeta = styled__default.default(StyledOptionMeta).attrs({
637
- 'data-garden-id': COMPONENT_ID$3,
638
- 'data-garden-version': '9.0.0-next.9'
692
+ 'data-garden-id': COMPONENT_ID$2,
693
+ 'data-garden-version': '9.1.0'
639
694
  }).withConfig({
640
695
  displayName: "StyledItemMeta",
641
696
  componentId: "sc-1unw3x1-0"
642
- })(["", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$3, props));
643
- StyledItemMeta.defaultProps = {
644
- theme: reactTheming.DEFAULT_THEME
645
- };
697
+ })(["", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$2, props));
646
698
 
647
- const COMPONENT_ID$2 = 'dropdowns.menu.item.type_icon';
699
+ const COMPONENT_ID$1 = 'dropdowns.menu.item.type_icon';
648
700
  const StyledItemTypeIcon = styled__default.default(StyledOptionTypeIcon).attrs({
649
- 'data-garden-id': COMPONENT_ID$2,
650
- 'data-garden-version': '9.0.0-next.9'
701
+ 'data-garden-id': COMPONENT_ID$1,
702
+ 'data-garden-version': '9.1.0'
651
703
  }).withConfig({
652
704
  displayName: "StyledItemTypeIcon",
653
705
  componentId: "sc-1pll3nu-0"
654
- })(["", "[aria-checked='true'] > &{opacity:1;}", ";"], StyledItem, props => reactTheming.retrieveComponentStyles(COMPONENT_ID$2, props));
655
- StyledItemTypeIcon.defaultProps = {
656
- theme: reactTheming.DEFAULT_THEME
657
- };
658
-
659
- const COMPONENT_ID$1 = 'dropdowns.menu.button';
660
- const StyledButton = styled__default.default(reactButtons.Button).attrs({
661
- 'data-garden-id': COMPONENT_ID$1,
662
- 'data-garden-version': '9.0.0-next.9'
663
- }).withConfig({
664
- displayName: "StyledButton",
665
- componentId: "sc-5hs2jg-0"
666
- })(["", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID$1, props));
667
- StyledButton.defaultProps = {
668
- theme: reactTheming.DEFAULT_THEME
669
- };
706
+ })(["", "[aria-checked='true'] > &{opacity:1;}", ";"], StyledItem, props => reactTheming.retrieveComponentStyles(COMPONENT_ID$1, props));
670
707
 
671
708
  const COMPONENT_ID = 'dropdowns.menu.separator';
672
709
  const StyledSeparator = styled__default.default(StyledListboxSeparator).attrs({
673
710
  'data-garden-id': COMPONENT_ID,
674
- 'data-garden-version': '9.0.0-next.9'
711
+ 'data-garden-version': '9.1.0'
675
712
  }).withConfig({
676
713
  displayName: "StyledSeparator",
677
714
  componentId: "sc-8kqwen-0"
678
715
  })(["", ";"], props => reactTheming.retrieveComponentStyles(COMPONENT_ID, props));
679
- StyledSeparator.defaultProps = {
680
- theme: reactTheming.DEFAULT_THEME
681
- };
682
716
 
683
717
  const Listbox = React.forwardRef((_ref, ref) => {
684
718
  let {
@@ -757,25 +791,25 @@ const Listbox = React.forwardRef((_ref, ref) => {
757
791
  children, update]);
758
792
  const Node = React__namespace.default.createElement(StyledFloatingListbox, {
759
793
  "data-garden-animate": isVisible ? 'true' : 'false',
760
- isHidden: !isExpanded,
761
- position: placement === 'bottom-start' ? 'bottom' : 'top',
794
+ $isHidden: !isExpanded,
795
+ $position: placement === 'bottom-start' ? 'bottom' : 'top',
762
796
  style: {
763
797
  transform,
764
798
  width
765
799
  },
766
- zIndex: zIndex,
800
+ $zIndex: zIndex,
767
801
  ref: floatingRef
768
802
  }, React__namespace.default.createElement(StyledListbox, Object.assign({
769
- isCompact: isCompact,
770
- maxHeight: maxHeight,
771
- minHeight: minHeight,
803
+ $isCompact: isCompact,
804
+ $maxHeight: maxHeight,
805
+ $minHeight: minHeight,
772
806
  onMouseDown: containerUtilities.composeEventHandlers(onMouseDown, handleMouseDown),
773
807
  style: {
774
808
  height
775
809
  }
776
810
  }, props, {
777
811
  ref: ref
778
- }), isVisible && children));
812
+ }), !!isVisible && children));
779
813
  return appendToNode ? reactDom$1.createPortal(Node, appendToNode) : Node;
780
814
  });
781
815
  Listbox.displayName = 'Listbox';
@@ -879,7 +913,7 @@ const toOption = props => {
879
913
  };
880
914
  const toOptions = (children, optionTagProps) => React.Children.toArray(children).reduce((options, option) => {
881
915
  const retVal = options;
882
- if ( React.isValidElement(option)) {
916
+ if (React.isValidElement(option)) {
883
917
  if ('value' in option.props) {
884
918
  retVal.push(toOption(option.props));
885
919
  optionTagProps[option.props.value] = option.props.tagProps;
@@ -1010,46 +1044,31 @@ const Combobox = React.forwardRef((_ref, ref) => {
1010
1044
  const _listboxAriaLabel = reactTheming.useText(Combobox, {
1011
1045
  listboxAriaLabel
1012
1046
  }, 'listboxAriaLabel', 'Options');
1013
- const triggerProps = {
1014
- isAutocomplete,
1015
- isBare,
1016
- isCompact,
1017
- isEditable,
1018
- isLabelHovered,
1019
- isMultiselectable,
1020
- maxHeight,
1021
- focusInset,
1022
- validation,
1023
- ...getTriggerProps({
1024
- onFocus: () => {
1025
- if (!isDisabled) {
1026
- if (isEditable) {
1027
- setIsInputHidden(false);
1028
- }
1029
- if (isMultiselectable) {
1030
- setIsTagGroupExpanded(true);
1031
- }
1047
+ const triggerProps = getTriggerProps({
1048
+ onFocus: () => {
1049
+ if (!isDisabled) {
1050
+ if (isEditable) {
1051
+ setIsInputHidden(false);
1032
1052
  }
1033
- },
1034
- onBlur: event => {
1035
- if (event.relatedTarget === null || !triggerRef.current?.contains(event.relatedTarget)) {
1036
- if (isEditable) {
1037
- setIsInputHidden(true);
1038
- }
1039
- if (isMultiselectable) {
1040
- setIsTagGroupExpanded(false);
1041
- }
1053
+ if (isMultiselectable) {
1054
+ setIsTagGroupExpanded(true);
1042
1055
  }
1043
1056
  }
1044
- })
1045
- };
1057
+ },
1058
+ onBlur: event => {
1059
+ if (event.relatedTarget === null || !triggerRef.current?.contains(event.relatedTarget)) {
1060
+ if (isEditable) {
1061
+ setIsInputHidden(true);
1062
+ }
1063
+ if (isMultiselectable) {
1064
+ setIsTagGroupExpanded(false);
1065
+ }
1066
+ }
1067
+ }
1068
+ });
1046
1069
  const inputProps = {
1047
1070
  'aria-invalid': validation === 'error' || validation === 'warning',
1048
1071
  hidden: isInputHidden,
1049
- isBare,
1050
- isCompact,
1051
- isEditable,
1052
- isMultiselectable,
1053
1072
  placeholder,
1054
1073
  ...getInputProps({
1055
1074
  ..._inputProps
@@ -1085,14 +1104,24 @@ const Combobox = React.forwardRef((_ref, ref) => {
1085
1104
  return React__namespace.default.createElement(ComboboxContext.Provider, {
1086
1105
  value: contextValue
1087
1106
  }, React__namespace.default.createElement(StyledCombobox, Object.assign({
1088
- isCompact: isCompact,
1107
+ $isCompact: isCompact,
1089
1108
  tabIndex: -1
1090
1109
  }, props, {
1091
1110
  ref: ref
1092
- }), React__namespace.default.createElement(StyledTrigger, triggerProps, React__namespace.default.createElement(StyledContainer, null, startIcon && React__namespace.default.createElement(StyledInputIcon, {
1111
+ }), React__namespace.default.createElement(StyledTrigger, Object.assign({
1112
+ $isAutocomplete: isAutocomplete,
1113
+ $isBare: isBare,
1114
+ $isCompact: isCompact,
1115
+ $isEditable: isEditable,
1116
+ $isLabelHovered: isLabelHovered,
1117
+ $isMultiselectable: isMultiselectable,
1118
+ $maxHeight: maxHeight,
1119
+ $focusInset: focusInset,
1120
+ $validation: validation
1121
+ }, triggerProps), React__namespace.default.createElement(StyledContainer, null, !!startIcon && React__namespace.default.createElement(StyledInputIcon, {
1093
1122
  $isLabelHovered: isLabelHovered,
1094
1123
  $isCompact: isCompact
1095
- }, startIcon), React__namespace.default.createElement(StyledInputGroup, null, isMultiselectable && Array.isArray(selection) && React__namespace.default.createElement(TagGroup, {
1124
+ }, startIcon), React__namespace.default.createElement(StyledInputGroup, null, !!isMultiselectable && Array.isArray(selection) && React__namespace.default.createElement(TagGroup, {
1096
1125
  isDisabled: isDisabled,
1097
1126
  isExpanded: isTagGroupExpanded,
1098
1127
  maxTags: maxTags,
@@ -1101,7 +1130,7 @@ const Combobox = React.forwardRef((_ref, ref) => {
1101
1130
  }, selection.length > maxTags && React__namespace.default.createElement(StyledTagsButton, {
1102
1131
  disabled: isDisabled,
1103
1132
  hidden: isTagGroupExpanded,
1104
- isCompact: isCompact,
1133
+ $isCompact: isCompact,
1105
1134
  tabIndex: -1,
1106
1135
  type: "button"
1107
1136
  }, (() => {
@@ -1109,21 +1138,26 @@ const Combobox = React.forwardRef((_ref, ref) => {
1109
1138
  return renderExpandTags ? renderExpandTags(value) : expandTags?.replace('{{value}}', value.toString());
1110
1139
  })())), React__namespace.default.createElement(StyledValue, {
1111
1140
  hidden: !isInputHidden,
1112
- isAutocomplete: isAutocomplete,
1113
- isBare: isBare,
1114
- isCompact: isCompact,
1115
- isDisabled: isDisabled,
1116
- isEditable: isEditable,
1117
- isMultiselectable: isMultiselectable,
1118
- isPlaceholder: !(inputValue || renderValue)
1141
+ $isAutocomplete: isAutocomplete,
1142
+ $isBare: isBare,
1143
+ $isCompact: isCompact,
1144
+ $isDisabled: isDisabled,
1145
+ $isEditable: isEditable,
1146
+ $isMultiselectable: isMultiselectable,
1147
+ $isPlaceholder: !(inputValue || renderValue)
1119
1148
  }, renderValue ? renderValue({
1120
1149
  selection,
1121
1150
  inputValue
1122
- }) : inputValue || placeholder), React__namespace.default.createElement(StyledInput, inputProps)), (hasChevron || endIcon) && React__namespace.default.createElement(StyledInputIcon, {
1151
+ }) : inputValue || placeholder), React__namespace.default.createElement(StyledInput, Object.assign({
1152
+ $isBare: isBare,
1153
+ $isCompact: isCompact,
1154
+ $isEditable: isEditable,
1155
+ $isMultiselectable: isMultiselectable
1156
+ }, inputProps))), !!(hasChevron || endIcon) && React__namespace.default.createElement(StyledInputIcon, {
1123
1157
  $isCompact: isCompact,
1124
1158
  $isEnd: true,
1125
1159
  $isLabelHovered: isLabelHovered,
1126
- $isRotated: hasChevron && isExpanded
1160
+ $isRotated: !!(hasChevron && isExpanded)
1127
1161
  }, hasChevron ? React__namespace.default.createElement(SvgChevronDownStroke, null) : endIcon))), React__namespace.default.createElement(Listbox, Object.assign({
1128
1162
  appendToNode: listboxAppendToNode,
1129
1163
  isCompact: isCompact,
@@ -1186,7 +1220,7 @@ const Hint = React.forwardRef((props, ref) => {
1186
1220
  ref: ref
1187
1221
  }));
1188
1222
  });
1189
- Hint.displayName = 'Hint';
1223
+ Hint.displayName = 'Field.Hint';
1190
1224
 
1191
1225
  const Label = React.forwardRef((_ref, ref) => {
1192
1226
  let {
@@ -1206,7 +1240,7 @@ const Label = React.forwardRef((_ref, ref) => {
1206
1240
  ref: ref
1207
1241
  }));
1208
1242
  });
1209
- Label.displayName = 'Label';
1243
+ Label.displayName = 'Field.Label';
1210
1244
  Label.propTypes = {
1211
1245
  hidden: PropTypes__default.default.bool,
1212
1246
  isRegular: PropTypes__default.default.bool
@@ -1225,7 +1259,7 @@ const Message = React.forwardRef((props, ref) => {
1225
1259
  ref: ref
1226
1260
  }));
1227
1261
  });
1228
- Message.displayName = 'Message';
1262
+ Message.displayName = 'Field.Message';
1229
1263
  Message.propTypes = {
1230
1264
  validation: PropTypes__default.default.oneOf(reactForms.VALIDATION),
1231
1265
  validationLabel: PropTypes__default.default.string
@@ -1262,7 +1296,7 @@ Field.Label = Label;
1262
1296
  Field.Message = Message;
1263
1297
 
1264
1298
  var _path$3;
1265
- function _extends$3() { _extends$3 = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$3.apply(this, arguments); }
1299
+ function _extends$3() { return _extends$3 = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends$3.apply(null, arguments); }
1266
1300
  var SvgPlusStroke = function SvgPlusStroke(props) {
1267
1301
  return /*#__PURE__*/React__namespace.createElement("svg", _extends$3({
1268
1302
  xmlns: "http://www.w3.org/2000/svg",
@@ -1279,7 +1313,7 @@ var SvgPlusStroke = function SvgPlusStroke(props) {
1279
1313
  };
1280
1314
 
1281
1315
  var _path$2;
1282
- function _extends$2() { _extends$2 = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$2.apply(this, arguments); }
1316
+ function _extends$2() { return _extends$2 = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends$2.apply(null, arguments); }
1283
1317
  var SvgChevronRightStroke = function SvgChevronRightStroke(props) {
1284
1318
  return /*#__PURE__*/React__namespace.createElement("svg", _extends$2({
1285
1319
  xmlns: "http://www.w3.org/2000/svg",
@@ -1295,7 +1329,7 @@ var SvgChevronRightStroke = function SvgChevronRightStroke(props) {
1295
1329
  };
1296
1330
 
1297
1331
  var _path$1;
1298
- function _extends$1() { _extends$1 = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$1.apply(this, arguments); }
1332
+ function _extends$1() { return _extends$1 = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends$1.apply(null, arguments); }
1299
1333
  var SvgChevronLeftStroke = function SvgChevronLeftStroke(props) {
1300
1334
  return /*#__PURE__*/React__namespace.createElement("svg", _extends$1({
1301
1335
  xmlns: "http://www.w3.org/2000/svg",
@@ -1311,7 +1345,7 @@ var SvgChevronLeftStroke = function SvgChevronLeftStroke(props) {
1311
1345
  };
1312
1346
 
1313
1347
  var _path;
1314
- function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
1348
+ function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
1315
1349
  var SvgCheckLgStroke = function SvgCheckLgStroke(props) {
1316
1350
  return /*#__PURE__*/React__namespace.createElement("svg", _extends({
1317
1351
  xmlns: "http://www.w3.org/2000/svg",
@@ -1346,7 +1380,7 @@ const OptionMetaComponent = React.forwardRef((props, ref) => {
1346
1380
  isDisabled
1347
1381
  } = useOptionContext();
1348
1382
  return React__namespace.default.createElement(StyledOptionMeta, Object.assign({
1349
- isDisabled: isDisabled
1383
+ $isDisabled: isDisabled
1350
1384
  }, props, {
1351
1385
  ref: ref
1352
1386
  }));
@@ -1367,8 +1401,9 @@ const OptionComponent = React.forwardRef((_ref, ref) => {
1367
1401
  ...props
1368
1402
  } = _ref;
1369
1403
  const contextValue = React.useMemo(() => ({
1370
- isDisabled
1371
- }), [isDisabled]);
1404
+ isDisabled,
1405
+ type
1406
+ }), [isDisabled, type]);
1372
1407
  const {
1373
1408
  activeValue,
1374
1409
  getOptionProps,
@@ -1413,13 +1448,16 @@ const OptionComponent = React.forwardRef((_ref, ref) => {
1413
1448
  return React__namespace.default.createElement(OptionContext.Provider, {
1414
1449
  value: contextValue
1415
1450
  }, React__namespace.default.createElement(StyledOption, Object.assign({
1416
- isActive: isActive,
1417
- isCompact: isCompact,
1451
+ $isActive: isActive,
1452
+ $isCompact: isCompact,
1418
1453
  $type: type
1419
1454
  }, props, optionProps), React__namespace.default.createElement(StyledOptionTypeIcon, {
1420
1455
  $isCompact: isCompact,
1421
1456
  $type: type
1422
- }, renderActionIcon(type)), icon && React__namespace.default.createElement(StyledOptionIcon, null, icon), React__namespace.default.createElement(StyledOptionContent, null, children || label || value)));
1457
+ }, renderActionIcon(type)), !!icon && React__namespace.default.createElement(StyledOptionIcon, {
1458
+ $isDisabled: isDisabled,
1459
+ $type: type
1460
+ }, icon), React__namespace.default.createElement(StyledOptionContent, null, children || label || value)));
1423
1461
  });
1424
1462
  OptionComponent.displayName = 'Option';
1425
1463
  OptionComponent.propTypes = {
@@ -1457,21 +1495,21 @@ const OptGroup = React.forwardRef((_ref, ref) => {
1457
1495
  'aria-label': groupAriaLabel || legend
1458
1496
  });
1459
1497
  return React__namespace.default.createElement(StyledOption, Object.assign({
1460
- isCompact: isCompact,
1498
+ $isCompact: isCompact,
1461
1499
  $type: "group",
1462
1500
  onMouseDown: containerUtilities.composeEventHandlers(onMouseDown, handleMouseDown),
1463
1501
  role: "none"
1464
1502
  }, props, {
1465
1503
  ref: ref
1466
- }), React__namespace.default.createElement(StyledOptionContent, null, (content || legend) && React__namespace.default.createElement(StyledOption, {
1504
+ }), React__namespace.default.createElement(StyledOptionContent, null, !!(content || legend) && React__namespace.default.createElement(StyledOption, {
1467
1505
  as: "div",
1468
- isCompact: isCompact,
1506
+ $isCompact: isCompact,
1469
1507
  $type: "header"
1470
- }, icon && React__namespace.default.createElement(StyledOptionTypeIcon, {
1508
+ }, !!icon && React__namespace.default.createElement(StyledOptionTypeIcon, {
1471
1509
  $isCompact: isCompact,
1472
1510
  $type: "header"
1473
1511
  }, icon), content || legend), React__namespace.default.createElement(StyledOptGroup, Object.assign({
1474
- isCompact: isCompact
1512
+ $isCompact: isCompact
1475
1513
  }, optGroupProps), React__namespace.default.createElement(StyledListboxSeparator, {
1476
1514
  role: "none"
1477
1515
  }), children)));
@@ -1516,7 +1554,7 @@ const toItem = props => ({
1516
1554
  });
1517
1555
  const toItems = (children, type) => React.Children.toArray(children).reduce((items, item) => {
1518
1556
  const retVal = items;
1519
- if ( React.isValidElement(item)) {
1557
+ if (React.isValidElement(item)) {
1520
1558
  if ('value' in item.props) {
1521
1559
  retVal.push(toItem({
1522
1560
  ...item.props,
@@ -1622,25 +1660,25 @@ const MenuList = React.forwardRef((_ref, ref) => {
1622
1660
  children, update]);
1623
1661
  const Node = React__namespace.default.createElement(StyledFloatingMenu, {
1624
1662
  "data-garden-animate": isVisible,
1625
- isHidden: !isExpanded,
1626
- position: reactTheming.getMenuPosition(placement),
1627
- zIndex: zIndex,
1663
+ $isHidden: !isExpanded || !isVisible ,
1664
+ $position: reactTheming.getMenuPosition(placement),
1665
+ $zIndex: zIndex,
1628
1666
  style: {
1629
1667
  transform
1630
1668
  },
1631
1669
  ref: floatingRef
1632
1670
  }, React__namespace.default.createElement(StyledMenu, Object.assign({
1633
1671
  "data-garden-animate-arrow": isVisible,
1634
- arrowPosition: hasArrow ? reactTheming.getArrowPosition(theme, placement) : undefined,
1635
- isCompact: isCompact,
1636
- minHeight: minHeight,
1637
- maxHeight: maxHeight,
1672
+ $arrowPosition: hasArrow ? reactTheming.getArrowPosition(theme, placement) : undefined,
1673
+ $isCompact: isCompact,
1674
+ $minHeight: minHeight,
1675
+ $maxHeight: maxHeight,
1638
1676
  style: {
1639
1677
  height
1640
1678
  }
1641
1679
  }, props, {
1642
1680
  ref: ref
1643
- }), isVisible && children));
1681
+ }), !!isVisible && children));
1644
1682
  return appendToNode ? reactDom$1.createPortal(Node, appendToNode) : Node;
1645
1683
  });
1646
1684
  MenuList.displayName = 'MenuList';
@@ -1661,7 +1699,7 @@ MenuList.defaultProps = {
1661
1699
  zIndex: 1000
1662
1700
  };
1663
1701
 
1664
- const Menu = React.forwardRef((_ref, ref) => {
1702
+ const Menu = React.forwardRef((_ref2, ref) => {
1665
1703
  let {
1666
1704
  button,
1667
1705
  buttonProps: _buttonProps = {},
@@ -1671,11 +1709,12 @@ const Menu = React.forwardRef((_ref, ref) => {
1671
1709
  defaultFocusedValue,
1672
1710
  defaultExpanded,
1673
1711
  isExpanded: _isExpanded,
1712
+ restoreFocus,
1674
1713
  selectedItems,
1675
1714
  onChange,
1676
1715
  onMouseLeave,
1677
1716
  ...props
1678
- } = _ref;
1717
+ } = _ref2;
1679
1718
  const triggerRef = React.useRef(null);
1680
1719
  const menuRef = React.useRef(null);
1681
1720
  const items = toItems(children);
@@ -1696,6 +1735,7 @@ const Menu = React.forwardRef((_ref, ref) => {
1696
1735
  focusedValue: _focusedValue,
1697
1736
  defaultExpanded,
1698
1737
  isExpanded: _isExpanded,
1738
+ restoreFocus,
1699
1739
  selectedItems,
1700
1740
  items,
1701
1741
  menuRef,
@@ -1706,6 +1746,7 @@ const Menu = React.forwardRef((_ref, ref) => {
1706
1746
  onClick,
1707
1747
  onKeyDown,
1708
1748
  disabled,
1749
+ ref: _ref,
1709
1750
  ...buttonProps
1710
1751
  } = _buttonProps;
1711
1752
  const triggerProps = {
@@ -1719,9 +1760,9 @@ const Menu = React.forwardRef((_ref, ref) => {
1719
1760
  onKeyDown,
1720
1761
  disabled
1721
1762
  }),
1722
- ref: reactMergeRefs.mergeRefs([triggerRef, ref])
1763
+ ref: reactMergeRefs.mergeRefs([triggerRef, _ref])
1723
1764
  };
1724
- const trigger = typeof button === 'function' ? button(triggerProps) : React__namespace.default.createElement(StyledButton, triggerProps, button, React__namespace.default.createElement(StyledButton.EndIcon, {
1765
+ const trigger = typeof button === 'function' ? button(triggerProps) : React__namespace.default.createElement(reactButtons.Button, triggerProps, button, React__namespace.default.createElement(reactButtons.Button.EndIcon, {
1725
1766
  isRotated: isExpanded
1726
1767
  }, React__namespace.default.createElement(SvgChevronDownStroke, null)));
1727
1768
  const contextValue = React.useMemo(() => ({
@@ -1758,6 +1799,7 @@ Menu.propTypes = {
1758
1799
  minHeight: PropTypes__default.default.string,
1759
1800
  onChange: PropTypes__default.default.func,
1760
1801
  placement: PropTypes__default.default.oneOf(PLACEMENT),
1802
+ restoreFocus: PropTypes__default.default.bool,
1761
1803
  selectedItems: PropTypes__default.default.arrayOf(PropTypes__default.default.any),
1762
1804
  zIndex: PropTypes__default.default.number
1763
1805
  };
@@ -1798,19 +1840,20 @@ const ItemGroup = React.forwardRef((_ref, ref) => {
1798
1840
  return React__namespace.default.createElement(ItemGroupContext.Provider, {
1799
1841
  value: contextValue
1800
1842
  }, React__namespace.default.createElement(StyledItem, Object.assign({
1801
- isCompact: isCompact,
1843
+ $isCompact: isCompact,
1802
1844
  $type: "group"
1803
1845
  }, props, {
1846
+ role: "none",
1804
1847
  ref: ref
1805
- }), React__namespace.default.createElement(StyledItemContent, null, (content || legend) && React__namespace.default.createElement(StyledItem, {
1848
+ }), React__namespace.default.createElement(StyledItemContent, null, !!(content || legend) && React__namespace.default.createElement(StyledItem, {
1806
1849
  as: "div",
1807
- isCompact: isCompact,
1850
+ $isCompact: isCompact,
1808
1851
  $type: "header"
1809
- }, icon && React__namespace.default.createElement(StyledItemTypeIcon, {
1852
+ }, !!icon && React__namespace.default.createElement(StyledItemTypeIcon, {
1810
1853
  $isCompact: isCompact,
1811
1854
  $type: "header"
1812
1855
  }, icon), content || legend), React__namespace.default.createElement(StyledItemGroup, Object.assign({
1813
- isCompact: isCompact
1856
+ $isCompact: isCompact
1814
1857
  }, groupProps), React__namespace.default.createElement(StyledSeparator, {
1815
1858
  role: "none"
1816
1859
  }), children))));
@@ -1837,7 +1880,7 @@ const ItemMetaComponent = React.forwardRef((props, ref) => {
1837
1880
  isDisabled
1838
1881
  } = useItemContext();
1839
1882
  return React__namespace.default.createElement(StyledItemMeta, Object.assign({
1840
- isDisabled: isDisabled
1883
+ $isDisabled: isDisabled
1841
1884
  }, props, {
1842
1885
  ref: ref
1843
1886
  }));
@@ -1865,7 +1908,8 @@ const ItemComponent = React.forwardRef((_ref, ref) => {
1865
1908
  } = useItemGroupContext();
1866
1909
  const {
1867
1910
  focusedValue,
1868
- getItemProps
1911
+ getItemProps,
1912
+ isCompact
1869
1913
  } = useMenuContext();
1870
1914
  const item = {
1871
1915
  ...toItem({
@@ -1888,9 +1932,6 @@ const ItemComponent = React.forwardRef((_ref, ref) => {
1888
1932
  onMouseEnter
1889
1933
  });
1890
1934
  const isActive = value === focusedValue;
1891
- const {
1892
- isCompact
1893
- } = useMenuContext();
1894
1935
  const renderActionIcon = iconType => {
1895
1936
  switch (iconType) {
1896
1937
  case 'add':
@@ -1904,20 +1945,24 @@ const ItemComponent = React.forwardRef((_ref, ref) => {
1904
1945
  }
1905
1946
  };
1906
1947
  const contextValue = React.useMemo(() => ({
1907
- isDisabled
1908
- }), [isDisabled]);
1948
+ isDisabled,
1949
+ type
1950
+ }), [isDisabled, type]);
1909
1951
  return React__namespace.default.createElement(ItemContext.Provider, {
1910
1952
  value: contextValue
1911
1953
  }, React__namespace.default.createElement(StyledItem, Object.assign({
1912
1954
  $type: type,
1913
- isCompact: isCompact,
1914
- isActive: isActive
1955
+ $isCompact: isCompact,
1956
+ $isActive: isActive
1915
1957
  }, props, itemProps, {
1916
1958
  ref: reactMergeRefs.mergeRefs([_itemRef, ref])
1917
1959
  }), React__namespace.default.createElement(StyledItemTypeIcon, {
1918
1960
  $isCompact: isCompact,
1919
1961
  $type: type
1920
- }, renderActionIcon(type)), icon && React__namespace.default.createElement(StyledItemIcon, null, icon), React__namespace.default.createElement(StyledItemContent, null, children || label)));
1962
+ }, renderActionIcon(type)), !!icon && React__namespace.default.createElement(StyledItemIcon, {
1963
+ $isDisabled: isDisabled,
1964
+ $type: type
1965
+ }, icon), React__namespace.default.createElement(StyledItemContent, null, children || label)));
1921
1966
  });
1922
1967
  ItemComponent.displayName = 'Item';
1923
1968
  ItemComponent.propTypes = {