@primer/react 38.0.0-rc.9 → 38.0.0-rc.ac46326da

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 (67) hide show
  1. package/CHANGELOG.md +314 -0
  2. package/dist/ActionBar/{ActionBar-3069d5f1.css → ActionBar-8ed12fe7.css} +2 -2
  3. package/dist/ActionBar/ActionBar-8ed12fe7.css.map +1 -0
  4. package/dist/ActionBar/ActionBar.d.ts +3 -0
  5. package/dist/ActionBar/ActionBar.d.ts.map +1 -1
  6. package/dist/ActionBar/ActionBar.js +292 -305
  7. package/dist/ActionBar/ActionBar.module.css.js +2 -2
  8. package/dist/ActionBar/index.d.ts +3 -0
  9. package/dist/ActionBar/index.d.ts.map +1 -1
  10. package/dist/ActionBar/index.js +3 -2
  11. package/dist/ActionList/index.d.ts +1 -1
  12. package/dist/Autocomplete/Autocomplete.d.ts +1 -1
  13. package/dist/BaseStyles.d.ts +2 -3
  14. package/dist/BaseStyles.d.ts.map +1 -1
  15. package/dist/BaseStyles.js +35 -61
  16. package/dist/LabelGroup/LabelGroup.d.ts.map +1 -1
  17. package/dist/LabelGroup/LabelGroup.js +1 -2
  18. package/dist/NavList/NavList.d.ts +1 -1
  19. package/dist/Overlay/Overlay.d.ts.map +1 -1
  20. package/dist/Overlay/Overlay.js +3 -6
  21. package/dist/SegmentedControl/SegmentedControl.d.ts.map +1 -1
  22. package/dist/SegmentedControl/SegmentedControl.js +15 -9
  23. package/dist/SegmentedControl/SegmentedControlButton.d.ts +3 -1
  24. package/dist/SegmentedControl/SegmentedControlButton.d.ts.map +1 -1
  25. package/dist/SegmentedControl/SegmentedControlButton.js +76 -69
  26. package/dist/TextInput/TextInput.d.ts +1 -1
  27. package/dist/TextInputWithTokens/TextInputWithTokens.d.ts +5 -5
  28. package/dist/TextInputWithTokens/TextInputWithTokens.d.ts.map +1 -1
  29. package/dist/TextInputWithTokens/TextInputWithTokens.js +229 -249
  30. package/dist/ThemeProvider.d.ts +0 -1
  31. package/dist/ThemeProvider.d.ts.map +1 -1
  32. package/dist/ThemeProvider.js +9 -8
  33. package/dist/deprecated/ActionList/Item.d.ts.map +1 -1
  34. package/dist/deprecated/ActionList/Item.js +66 -71
  35. package/dist/{DialogV1 → deprecated/DialogV1}/Dialog-dce13989.css +1 -1
  36. package/dist/deprecated/DialogV1/Dialog-dce13989.css.map +1 -0
  37. package/dist/{DialogV1 → deprecated/DialogV1}/Dialog.d.ts +1 -1
  38. package/dist/deprecated/DialogV1/Dialog.d.ts.map +1 -0
  39. package/dist/{DialogV1 → deprecated/DialogV1}/Dialog.js +3 -3
  40. package/dist/deprecated/DialogV1/Dialog.module.css.js +5 -0
  41. package/dist/deprecated/DialogV1/index.d.ts.map +1 -0
  42. package/dist/deprecated/index.d.ts +2 -2
  43. package/dist/deprecated/index.d.ts.map +1 -1
  44. package/dist/deprecated/index.js +1 -1
  45. package/dist/index.d.ts +1 -1
  46. package/dist/index.d.ts.map +1 -1
  47. package/dist/index.js +1 -1
  48. package/dist/internal/components/TextInputInnerAction.d.ts +1 -1
  49. package/generated/components.json +85 -110
  50. package/package.json +3 -18
  51. package/dist/ActionBar/ActionBar-3069d5f1.css.map +0 -1
  52. package/dist/Box/Box.d.ts +0 -18
  53. package/dist/Box/Box.d.ts.map +0 -1
  54. package/dist/Box/index.d.ts +0 -3
  55. package/dist/Box/index.d.ts.map +0 -1
  56. package/dist/DialogV1/Dialog-dce13989.css.map +0 -1
  57. package/dist/DialogV1/Dialog.d.ts.map +0 -1
  58. package/dist/DialogV1/Dialog.module.css.js +0 -5
  59. package/dist/DialogV1/index.d.ts.map +0 -1
  60. package/dist/constants.d.ts +0 -15
  61. package/dist/constants.d.ts.map +0 -1
  62. package/dist/constants.js +0 -28
  63. package/dist/sx.d.ts +0 -24
  64. package/dist/sx.d.ts.map +0 -1
  65. package/dist/utils/layout.d.ts +0 -21
  66. package/dist/utils/layout.d.ts.map +0 -1
  67. /package/dist/{DialogV1 → deprecated/DialogV1}/index.d.ts +0 -0
@@ -1,7 +1,6 @@
1
1
  import { c } from 'react-compiler-runtime';
2
2
  import { FocusKeys } from '@primer/behaviors';
3
3
  import { isFocusable } from '@primer/behaviors/utils';
4
- import { omit } from '@styled-system/props';
5
4
  import React, { useRef, useState } from 'react';
6
5
  import { isValidElementType } from 'react-is';
7
6
  import { useRefObjectAsForwardedRef } from '../hooks/useRefObjectAsForwardedRef.js';
@@ -27,99 +26,75 @@ function TextInputWithTokensInnerComponent(t0, forwardedRef) {
27
26
  const $ = c(135);
28
27
  let IconComponent;
29
28
  let LeadingVisual;
30
- let TokenComponent;
31
29
  let TrailingVisual;
32
30
  let block;
33
31
  let className;
34
32
  let contrast;
35
33
  let disabled;
36
- let hideTokenRemoveButtons;
37
- let loaderPosition;
38
34
  let loading;
39
35
  let maxHeight;
40
36
  let maxWidthProp;
41
37
  let minWidthProp;
42
38
  let onTokenRemove;
43
- let preventTokenWrapping;
44
- let size;
39
+ let rest;
45
40
  let style;
46
41
  let t1;
42
+ let t2;
43
+ let t3;
44
+ let t4;
45
+ let t5;
47
46
  let tokens;
48
47
  let validationStatus;
49
48
  let variantProp;
50
49
  let visibleTokenCount;
51
50
  let widthProp;
52
51
  if ($[0] !== t0) {
53
- const {
54
- icon: t2,
55
- leadingVisual: t3,
56
- trailingVisual: t4,
57
- loading: t5,
58
- loaderPosition: t6,
59
- contrast: t7,
60
- className: t8,
61
- block: t9,
62
- disabled: t10,
63
- tokens: t11,
64
- onTokenRemove: t12,
65
- tokenComponent: t13,
66
- preventTokenWrapping: t14,
67
- size: t15,
68
- hideTokenRemoveButtons: t16,
69
- maxHeight: t17,
70
- width: t18,
71
- minWidth: t19,
72
- maxWidth: t20,
73
- validationStatus: t21,
74
- variant: t22,
75
- visibleTokenCount: t23,
76
- style: t24,
52
+ ({
53
+ icon: IconComponent,
54
+ leadingVisual: LeadingVisual,
55
+ trailingVisual: TrailingVisual,
56
+ loading,
57
+ loaderPosition: t1,
58
+ contrast,
59
+ className,
60
+ block,
61
+ disabled,
62
+ tokens,
63
+ onTokenRemove,
64
+ tokenComponent: t2,
65
+ preventTokenWrapping: t3,
66
+ size: t4,
67
+ hideTokenRemoveButtons: t5,
68
+ maxHeight,
69
+ width: widthProp,
70
+ minWidth: minWidthProp,
71
+ maxWidth: maxWidthProp,
72
+ validationStatus,
73
+ variant: variantProp,
74
+ visibleTokenCount,
75
+ style,
77
76
  ...rest
78
- } = t0;
79
- IconComponent = t2;
80
- LeadingVisual = t3;
81
- TrailingVisual = t4;
82
- loading = t5;
83
- contrast = t7;
84
- className = t8;
85
- block = t9;
86
- disabled = t10;
87
- tokens = t11;
88
- onTokenRemove = t12;
89
- maxHeight = t17;
90
- widthProp = t18;
91
- minWidthProp = t19;
92
- maxWidthProp = t20;
93
- validationStatus = t21;
94
- variantProp = t22;
95
- visibleTokenCount = t23;
96
- style = t24;
97
- loaderPosition = t6 === undefined ? "auto" : t6;
98
- TokenComponent = t13 === undefined ? Token : t13;
99
- preventTokenWrapping = t14 === undefined ? false : t14;
100
- size = t15 === undefined ? "xlarge" : t15;
101
- hideTokenRemoveButtons = t16 === undefined ? false : t16;
102
- t1 = omit(rest);
77
+ } = t0);
103
78
  $[0] = t0;
104
79
  $[1] = IconComponent;
105
80
  $[2] = LeadingVisual;
106
- $[3] = TokenComponent;
107
- $[4] = TrailingVisual;
108
- $[5] = block;
109
- $[6] = className;
110
- $[7] = contrast;
111
- $[8] = disabled;
112
- $[9] = hideTokenRemoveButtons;
113
- $[10] = loaderPosition;
114
- $[11] = loading;
115
- $[12] = maxHeight;
116
- $[13] = maxWidthProp;
117
- $[14] = minWidthProp;
118
- $[15] = onTokenRemove;
119
- $[16] = preventTokenWrapping;
120
- $[17] = size;
121
- $[18] = style;
122
- $[19] = t1;
81
+ $[3] = TrailingVisual;
82
+ $[4] = block;
83
+ $[5] = className;
84
+ $[6] = contrast;
85
+ $[7] = disabled;
86
+ $[8] = loading;
87
+ $[9] = maxHeight;
88
+ $[10] = maxWidthProp;
89
+ $[11] = minWidthProp;
90
+ $[12] = onTokenRemove;
91
+ $[13] = rest;
92
+ $[14] = style;
93
+ $[15] = t1;
94
+ $[16] = t2;
95
+ $[17] = t3;
96
+ $[18] = t4;
97
+ $[19] = t5;
123
98
  $[20] = tokens;
124
99
  $[21] = validationStatus;
125
100
  $[22] = variantProp;
@@ -128,41 +103,46 @@ function TextInputWithTokensInnerComponent(t0, forwardedRef) {
128
103
  } else {
129
104
  IconComponent = $[1];
130
105
  LeadingVisual = $[2];
131
- TokenComponent = $[3];
132
- TrailingVisual = $[4];
133
- block = $[5];
134
- className = $[6];
135
- contrast = $[7];
136
- disabled = $[8];
137
- hideTokenRemoveButtons = $[9];
138
- loaderPosition = $[10];
139
- loading = $[11];
140
- maxHeight = $[12];
141
- maxWidthProp = $[13];
142
- minWidthProp = $[14];
143
- onTokenRemove = $[15];
144
- preventTokenWrapping = $[16];
145
- size = $[17];
146
- style = $[18];
147
- t1 = $[19];
106
+ TrailingVisual = $[3];
107
+ block = $[4];
108
+ className = $[5];
109
+ contrast = $[6];
110
+ disabled = $[7];
111
+ loading = $[8];
112
+ maxHeight = $[9];
113
+ maxWidthProp = $[10];
114
+ minWidthProp = $[11];
115
+ onTokenRemove = $[12];
116
+ rest = $[13];
117
+ style = $[14];
118
+ t1 = $[15];
119
+ t2 = $[16];
120
+ t3 = $[17];
121
+ t4 = $[18];
122
+ t5 = $[19];
148
123
  tokens = $[20];
149
124
  validationStatus = $[21];
150
125
  variantProp = $[22];
151
126
  visibleTokenCount = $[23];
152
127
  widthProp = $[24];
153
128
  }
129
+ const loaderPosition = t1 === undefined ? "auto" : t1;
130
+ const TokenComponent = t2 === undefined ? Token : t2;
131
+ const preventTokenWrapping = t3 === undefined ? false : t3;
132
+ const size = t4 === undefined ? "xlarge" : t4;
133
+ const hideTokenRemoveButtons = t5 === undefined ? false : t5;
154
134
  let inputPropsRest;
155
135
  let onBlur;
156
136
  let onFocus;
157
137
  let onKeyDown;
158
- if ($[25] !== t1) {
138
+ if ($[25] !== rest) {
159
139
  ({
160
140
  onBlur,
161
141
  onFocus,
162
142
  onKeyDown,
163
143
  ...inputPropsRest
164
- } = t1);
165
- $[25] = t1;
144
+ } = rest);
145
+ $[25] = rest;
166
146
  $[26] = inputPropsRest;
167
147
  $[27] = onBlur;
168
148
  $[28] = onFocus;
@@ -177,16 +157,16 @@ function TextInputWithTokensInnerComponent(t0, forwardedRef) {
177
157
  useRefObjectAsForwardedRef(forwardedRef, ref);
178
158
  const [selectedTokenIndex, setSelectedTokenIndex] = useState();
179
159
  const [tokensAreTruncated, setTokensAreTruncated] = useState(Boolean(visibleTokenCount));
180
- let t2;
160
+ let t6;
181
161
  if ($[30] !== selectedTokenIndex) {
182
- t2 = [selectedTokenIndex];
162
+ t6 = [selectedTokenIndex];
183
163
  $[30] = selectedTokenIndex;
184
- $[31] = t2;
164
+ $[31] = t6;
185
165
  } else {
186
- t2 = $[31];
166
+ t6 = $[31];
187
167
  }
188
168
  const {
189
- containerRef: t3
169
+ containerRef: t7
190
170
  } = useFocusZone({
191
171
  focusOutBehavior: "wrap",
192
172
  bindKeys: FocusKeys.ArrowHorizontal | FocusKeys.HomeAndEnd,
@@ -208,11 +188,11 @@ function TextInputWithTokensInnerComponent(t0, forwardedRef) {
208
188
  }
209
189
  return (_containerRef$current = containerRef.current) === null || _containerRef$current === void 0 ? void 0 : _containerRef$current.children[nextIndex];
210
190
  }
211
- }, t2);
212
- const containerRef = t3;
213
- let t4;
191
+ }, t6);
192
+ const containerRef = t7;
193
+ let t8;
214
194
  if ($[32] !== containerRef || $[33] !== onTokenRemove || $[34] !== selectedTokenIndex) {
215
- t4 = tokenId => {
195
+ t8 = tokenId => {
216
196
  onTokenRemove(tokenId);
217
197
  setTimeout(() => {
218
198
  var _containerRef$current2, _containerRef$current3;
@@ -229,27 +209,27 @@ function TextInputWithTokensInnerComponent(t0, forwardedRef) {
229
209
  $[32] = containerRef;
230
210
  $[33] = onTokenRemove;
231
211
  $[34] = selectedTokenIndex;
232
- $[35] = t4;
212
+ $[35] = t8;
233
213
  } else {
234
- t4 = $[35];
214
+ t8 = $[35];
235
215
  }
236
- const handleTokenRemove = t4;
237
- let t5;
216
+ const handleTokenRemove = t8;
217
+ let t9;
238
218
  if ($[36] !== disabled) {
239
- t5 = tokenIndex => () => {
219
+ t9 = tokenIndex => () => {
240
220
  if (!disabled) {
241
221
  setSelectedTokenIndex(tokenIndex);
242
222
  }
243
223
  };
244
224
  $[36] = disabled;
245
- $[37] = t5;
225
+ $[37] = t9;
246
226
  } else {
247
- t5 = $[37];
227
+ t9 = $[37];
248
228
  }
249
- const handleTokenFocus = t5;
250
- let t6;
229
+ const handleTokenFocus = t9;
230
+ let t10;
251
231
  if ($[38] !== containerRef || $[39] !== visibleTokenCount) {
252
- t6 = () => {
232
+ t10 = () => {
253
233
  setSelectedTokenIndex(undefined);
254
234
  setTimeout(() => {
255
235
  var _containerRef$current4;
@@ -260,41 +240,41 @@ function TextInputWithTokensInnerComponent(t0, forwardedRef) {
260
240
  };
261
241
  $[38] = containerRef;
262
242
  $[39] = visibleTokenCount;
263
- $[40] = t6;
243
+ $[40] = t10;
264
244
  } else {
265
- t6 = $[40];
245
+ t10 = $[40];
266
246
  }
267
- const handleTokenBlur = t6;
268
- let t7;
247
+ const handleTokenBlur = t10;
248
+ let t11;
269
249
  if ($[41] === Symbol.for("react.memo_cache_sentinel")) {
270
- t7 = event => {
250
+ t11 = event => {
271
251
  if (event.key === "Escape") {
272
252
  var _ref$current2;
273
253
  (_ref$current2 = ref.current) === null || _ref$current2 === void 0 ? void 0 : _ref$current2.focus();
274
254
  }
275
255
  };
276
- $[41] = t7;
256
+ $[41] = t11;
277
257
  } else {
278
- t7 = $[41];
258
+ t11 = $[41];
279
259
  }
280
- const handleTokenKeyUp = t7;
281
- let t8;
260
+ const handleTokenKeyUp = t11;
261
+ let t12;
282
262
  if ($[42] !== onFocus || $[43] !== visibleTokenCount) {
283
- t8 = event_0 => {
263
+ t12 = event_0 => {
284
264
  onFocus && onFocus(event_0);
285
265
  setSelectedTokenIndex(undefined);
286
266
  visibleTokenCount && setTokensAreTruncated(false);
287
267
  };
288
268
  $[42] = onFocus;
289
269
  $[43] = visibleTokenCount;
290
- $[44] = t8;
270
+ $[44] = t12;
291
271
  } else {
292
- t8 = $[44];
272
+ t12 = $[44];
293
273
  }
294
- const handleInputFocus = t8;
295
- let t9;
274
+ const handleInputFocus = t12;
275
+ let t13;
296
276
  if ($[45] !== containerRef || $[46] !== onBlur || $[47] !== visibleTokenCount) {
297
- t9 = event_1 => {
277
+ t13 = event_1 => {
298
278
  onBlur && onBlur(event_1);
299
279
  setTimeout(() => {
300
280
  var _containerRef$current5;
@@ -306,14 +286,14 @@ function TextInputWithTokensInnerComponent(t0, forwardedRef) {
306
286
  $[45] = containerRef;
307
287
  $[46] = onBlur;
308
288
  $[47] = visibleTokenCount;
309
- $[48] = t9;
289
+ $[48] = t13;
310
290
  } else {
311
- t9 = $[48];
291
+ t13 = $[48];
312
292
  }
313
- const handleInputBlur = t9;
314
- let t10;
293
+ const handleInputBlur = t13;
294
+ let t14;
315
295
  if ($[49] !== handleTokenRemove || $[50] !== onKeyDown || $[51] !== tokens) {
316
- t10 = e => {
296
+ t14 = e => {
317
297
  var _ref$current3;
318
298
  if (onKeyDown) {
319
299
  onKeyDown(e);
@@ -336,113 +316,113 @@ function TextInputWithTokensInnerComponent(t0, forwardedRef) {
336
316
  $[49] = handleTokenRemove;
337
317
  $[50] = onKeyDown;
338
318
  $[51] = tokens;
339
- $[52] = t10;
319
+ $[52] = t14;
340
320
  } else {
341
- t10 = $[52];
321
+ t14 = $[52];
342
322
  }
343
- const handleInputKeyDown = t10;
344
- let t11;
323
+ const handleInputKeyDown = t14;
324
+ let t15;
345
325
  if ($[53] === Symbol.for("react.memo_cache_sentinel")) {
346
- t11 = () => {
326
+ t15 = () => {
347
327
  var _ref$current5;
348
328
  (_ref$current5 = ref.current) === null || _ref$current5 === void 0 ? void 0 : _ref$current5.focus();
349
329
  };
350
- $[53] = t11;
330
+ $[53] = t15;
351
331
  } else {
352
- t11 = $[53];
332
+ t15 = $[53];
353
333
  }
354
- const focusInput = t11;
334
+ const focusInput = t15;
355
335
  const preventTokenClickPropagation = _temp3;
356
- let t12;
336
+ let t16;
357
337
  if ($[54] !== tokens || $[55] !== tokensAreTruncated || $[56] !== visibleTokenCount) {
358
- t12 = tokensAreTruncated ? tokens.slice(0, visibleTokenCount) : tokens;
338
+ t16 = tokensAreTruncated ? tokens.slice(0, visibleTokenCount) : tokens;
359
339
  $[54] = tokens;
360
340
  $[55] = tokensAreTruncated;
361
341
  $[56] = visibleTokenCount;
362
- $[57] = t12;
342
+ $[57] = t16;
363
343
  } else {
364
- t12 = $[57];
344
+ t16 = $[57];
365
345
  }
366
- const visibleTokens = t12;
367
- let t13;
346
+ const visibleTokens = t16;
347
+ let t17;
368
348
  if ($[58] === Symbol.for("react.memo_cache_sentinel")) {
369
- t13 = {
349
+ t17 = {
370
350
  small: "small",
371
351
  medium: "small",
372
352
  large: "medium",
373
353
  xlarge: "medium"
374
354
  };
375
- $[58] = t13;
355
+ $[58] = t17;
376
356
  } else {
377
- t13 = $[58];
357
+ t17 = $[58];
378
358
  }
379
- const inputSizeMap = t13;
359
+ const inputSizeMap = t17;
380
360
  const showLeadingLoadingIndicator = loading && (loaderPosition === "leading" || Boolean(LeadingVisual && loaderPosition !== "trailing"));
381
361
  const showTrailingLoadingIndicator = loading && (loaderPosition === "trailing" || loaderPosition === "auto" && !LeadingVisual);
382
- const t14 = Boolean(LeadingVisual || showLeadingLoadingIndicator);
383
- const t15 = Boolean(TrailingVisual || showTrailingLoadingIndicator);
384
- const t16 = inputSizeMap[size];
385
- const t17 = Boolean(preventTokenWrapping || maxHeight) || undefined;
386
- let t18;
362
+ const t18 = Boolean(LeadingVisual || showLeadingLoadingIndicator);
363
+ const t19 = Boolean(TrailingVisual || showTrailingLoadingIndicator);
364
+ const t20 = inputSizeMap[size];
365
+ const t21 = Boolean(preventTokenWrapping || maxHeight) || undefined;
366
+ let t22;
387
367
  if ($[59] !== className) {
388
- t18 = clsx(className, styles.TextInputWrapper);
368
+ t22 = clsx(className, styles.TextInputWrapper);
389
369
  $[59] = className;
390
- $[60] = t18;
370
+ $[60] = t22;
391
371
  } else {
392
- t18 = $[60];
372
+ t22 = $[60];
393
373
  }
394
- let t19;
374
+ let t23;
395
375
  if ($[61] !== maxHeight || $[62] !== style) {
396
- t19 = maxHeight ? {
376
+ t23 = maxHeight ? {
397
377
  maxHeight,
398
378
  ...style
399
379
  } : style;
400
380
  $[61] = maxHeight;
401
381
  $[62] = style;
402
- $[63] = t19;
382
+ $[63] = t23;
403
383
  } else {
404
- t19 = $[63];
384
+ t23 = $[63];
405
385
  }
406
- let t20;
386
+ let t24;
407
387
  if ($[64] !== IconComponent || $[65] !== LeadingVisual) {
408
- t20 = IconComponent && !LeadingVisual && /*#__PURE__*/jsx(IconComponent, {
388
+ t24 = IconComponent && !LeadingVisual && /*#__PURE__*/jsx(IconComponent, {
409
389
  className: "TextInput-icon"
410
390
  });
411
391
  $[64] = IconComponent;
412
392
  $[65] = LeadingVisual;
413
- $[66] = t20;
393
+ $[66] = t24;
414
394
  } else {
415
- t20 = $[66];
395
+ t24 = $[66];
416
396
  }
417
- const t21 = typeof loading === "boolean";
418
- let t22;
397
+ const t25 = typeof loading === "boolean";
398
+ let t26;
419
399
  if ($[67] !== LeadingVisual) {
420
- t22 = typeof LeadingVisual !== "string" && isValidElementType(LeadingVisual) ? /*#__PURE__*/jsx(LeadingVisual, {}) : LeadingVisual;
400
+ t26 = typeof LeadingVisual !== "string" && isValidElementType(LeadingVisual) ? /*#__PURE__*/jsx(LeadingVisual, {}) : LeadingVisual;
421
401
  $[67] = LeadingVisual;
422
- $[68] = t22;
402
+ $[68] = t26;
423
403
  } else {
424
- t22 = $[68];
404
+ t26 = $[68];
425
405
  }
426
- let t23;
427
- if ($[69] !== showLeadingLoadingIndicator || $[70] !== t21 || $[71] !== t22) {
428
- t23 = /*#__PURE__*/jsx(TextInputInnerVisualSlot, {
429
- hasLoadingIndicator: t21,
406
+ let t27;
407
+ if ($[69] !== showLeadingLoadingIndicator || $[70] !== t25 || $[71] !== t26) {
408
+ t27 = /*#__PURE__*/jsx(TextInputInnerVisualSlot, {
409
+ hasLoadingIndicator: t25,
430
410
  visualPosition: "leading",
431
411
  showLoadingIndicator: showLeadingLoadingIndicator,
432
- children: t22
412
+ children: t26
433
413
  });
434
414
  $[69] = showLeadingLoadingIndicator;
435
- $[70] = t21;
436
- $[71] = t22;
437
- $[72] = t23;
415
+ $[70] = t25;
416
+ $[71] = t26;
417
+ $[72] = t27;
438
418
  } else {
439
- t23 = $[72];
419
+ t27 = $[72];
440
420
  }
441
- const t24 = containerRef;
442
- const t25 = validationStatus === "error" ? "true" : "false";
443
- let t26;
444
- if ($[73] !== disabled || $[74] !== handleInputBlur || $[75] !== handleInputFocus || $[76] !== handleInputKeyDown || $[77] !== inputPropsRest || $[78] !== t25) {
445
- t26 = /*#__PURE__*/jsx("div", {
421
+ const t28 = containerRef;
422
+ const t29 = validationStatus === "error" ? "true" : "false";
423
+ let t30;
424
+ if ($[73] !== disabled || $[74] !== handleInputBlur || $[75] !== handleInputFocus || $[76] !== handleInputKeyDown || $[77] !== inputPropsRest || $[78] !== t29) {
425
+ t30 = /*#__PURE__*/jsx("div", {
446
426
  className: styles.InputWrapper,
447
427
  children: /*#__PURE__*/jsx(UnstyledTextInput, {
448
428
  ref: ref,
@@ -452,7 +432,7 @@ function TextInputWithTokensInnerComponent(t0, forwardedRef) {
452
432
  onKeyDown: handleInputKeyDown,
453
433
  type: "text",
454
434
  className: styles.UnstyledTextInput,
455
- "aria-invalid": t25,
435
+ "aria-invalid": t29,
456
436
  ...inputPropsRest
457
437
  })
458
438
  });
@@ -461,20 +441,20 @@ function TextInputWithTokensInnerComponent(t0, forwardedRef) {
461
441
  $[75] = handleInputFocus;
462
442
  $[76] = handleInputKeyDown;
463
443
  $[77] = inputPropsRest;
464
- $[78] = t25;
465
- $[79] = t26;
444
+ $[78] = t29;
445
+ $[79] = t30;
466
446
  } else {
467
- t26 = $[79];
447
+ t30 = $[79];
468
448
  }
469
- let t27;
449
+ let t31;
470
450
  if ($[80] !== TokenComponent || $[81] !== disabled || $[82] !== handleTokenBlur || $[83] !== handleTokenFocus || $[84] !== handleTokenRemove || $[85] !== hideTokenRemoveButtons || $[86] !== selectedTokenIndex || $[87] !== size || $[88] !== visibleTokens) {
471
- let t28;
451
+ let t32;
472
452
  if ($[90] !== TokenComponent || $[91] !== disabled || $[92] !== handleTokenBlur || $[93] !== handleTokenFocus || $[94] !== handleTokenRemove || $[95] !== hideTokenRemoveButtons || $[96] !== selectedTokenIndex || $[97] !== size) {
473
- t28 = (t29, i) => {
453
+ t32 = (t33, i) => {
474
454
  const {
475
455
  id,
476
456
  ...tokenRest
477
- } = t29;
457
+ } = t33;
478
458
  return /*#__PURE__*/jsx(TokenComponent, {
479
459
  disabled: disabled,
480
460
  onFocus: handleTokenFocus(i),
@@ -499,11 +479,11 @@ function TextInputWithTokensInnerComponent(t0, forwardedRef) {
499
479
  $[95] = hideTokenRemoveButtons;
500
480
  $[96] = selectedTokenIndex;
501
481
  $[97] = size;
502
- $[98] = t28;
482
+ $[98] = t32;
503
483
  } else {
504
- t28 = $[98];
484
+ t32 = $[98];
505
485
  }
506
- t27 = visibleTokens.map(t28);
486
+ t31 = visibleTokens.map(t32);
507
487
  $[80] = TokenComponent;
508
488
  $[81] = disabled;
509
489
  $[82] = handleTokenBlur;
@@ -513,13 +493,13 @@ function TextInputWithTokensInnerComponent(t0, forwardedRef) {
513
493
  $[86] = selectedTokenIndex;
514
494
  $[87] = size;
515
495
  $[88] = visibleTokens;
516
- $[89] = t27;
496
+ $[89] = t31;
517
497
  } else {
518
- t27 = $[89];
498
+ t31 = $[89];
519
499
  }
520
- let t28;
500
+ let t32;
521
501
  if ($[99] !== size || $[100] !== tokens || $[101] !== tokensAreTruncated || $[102] !== visibleTokens.length) {
522
- t28 = tokensAreTruncated && tokens.length - visibleTokens.length ? /*#__PURE__*/jsxs(Text, {
502
+ t32 = tokensAreTruncated && tokens.length - visibleTokens.length ? /*#__PURE__*/jsxs(Text, {
523
503
  className: overflowCountClassMap[size],
524
504
  children: ["+", tokens.length - visibleTokens.length]
525
505
  }) : null;
@@ -527,94 +507,94 @@ function TextInputWithTokensInnerComponent(t0, forwardedRef) {
527
507
  $[100] = tokens;
528
508
  $[101] = tokensAreTruncated;
529
509
  $[102] = visibleTokens.length;
530
- $[103] = t28;
510
+ $[103] = t32;
531
511
  } else {
532
- t28 = $[103];
512
+ t32 = $[103];
533
513
  }
534
- let t29;
535
- if ($[104] !== preventTokenWrapping || $[105] !== t24 || $[106] !== t26 || $[107] !== t27 || $[108] !== t28) {
536
- t29 = /*#__PURE__*/jsxs("div", {
537
- ref: t24,
514
+ let t33;
515
+ if ($[104] !== preventTokenWrapping || $[105] !== t28 || $[106] !== t30 || $[107] !== t31 || $[108] !== t32) {
516
+ t33 = /*#__PURE__*/jsxs("div", {
517
+ ref: t28,
538
518
  className: styles.Container,
539
519
  "data-prevent-token-wrapping": preventTokenWrapping,
540
- children: [t26, t27, t28]
520
+ children: [t30, t31, t32]
541
521
  });
542
522
  $[104] = preventTokenWrapping;
543
- $[105] = t24;
544
- $[106] = t26;
545
- $[107] = t27;
546
- $[108] = t28;
547
- $[109] = t29;
523
+ $[105] = t28;
524
+ $[106] = t30;
525
+ $[107] = t31;
526
+ $[108] = t32;
527
+ $[109] = t33;
548
528
  } else {
549
- t29 = $[109];
529
+ t33 = $[109];
550
530
  }
551
- const t30 = typeof loading === "boolean";
552
- let t31;
531
+ const t34 = typeof loading === "boolean";
532
+ let t35;
553
533
  if ($[110] !== TrailingVisual) {
554
- t31 = typeof TrailingVisual !== "string" && isValidElementType(TrailingVisual) ? /*#__PURE__*/jsx(TrailingVisual, {}) : TrailingVisual;
534
+ t35 = typeof TrailingVisual !== "string" && isValidElementType(TrailingVisual) ? /*#__PURE__*/jsx(TrailingVisual, {}) : TrailingVisual;
555
535
  $[110] = TrailingVisual;
556
- $[111] = t31;
536
+ $[111] = t35;
557
537
  } else {
558
- t31 = $[111];
538
+ t35 = $[111];
559
539
  }
560
- let t32;
561
- if ($[112] !== showTrailingLoadingIndicator || $[113] !== t30 || $[114] !== t31) {
562
- t32 = /*#__PURE__*/jsx(TextInputInnerVisualSlot, {
563
- hasLoadingIndicator: t30,
540
+ let t36;
541
+ if ($[112] !== showTrailingLoadingIndicator || $[113] !== t34 || $[114] !== t35) {
542
+ t36 = /*#__PURE__*/jsx(TextInputInnerVisualSlot, {
543
+ hasLoadingIndicator: t34,
564
544
  visualPosition: "trailing",
565
545
  showLoadingIndicator: showTrailingLoadingIndicator,
566
- children: t31
546
+ children: t35
567
547
  });
568
548
  $[112] = showTrailingLoadingIndicator;
569
- $[113] = t30;
570
- $[114] = t31;
571
- $[115] = t32;
549
+ $[113] = t34;
550
+ $[114] = t35;
551
+ $[115] = t36;
572
552
  } else {
573
- t32 = $[115];
553
+ t36 = $[115];
574
554
  }
575
- let t33;
576
- if ($[116] !== block || $[117] !== contrast || $[118] !== disabled || $[119] !== maxWidthProp || $[120] !== minWidthProp || $[121] !== t14 || $[122] !== t15 || $[123] !== t16 || $[124] !== t17 || $[125] !== t18 || $[126] !== t19 || $[127] !== t20 || $[128] !== t23 || $[129] !== t29 || $[130] !== t32 || $[131] !== validationStatus || $[132] !== variantProp || $[133] !== widthProp) {
577
- t33 = /*#__PURE__*/jsxs(TextInputWrapper, {
555
+ let t37;
556
+ if ($[116] !== block || $[117] !== contrast || $[118] !== disabled || $[119] !== maxWidthProp || $[120] !== minWidthProp || $[121] !== t18 || $[122] !== t19 || $[123] !== t20 || $[124] !== t21 || $[125] !== t22 || $[126] !== t23 || $[127] !== t24 || $[128] !== t27 || $[129] !== t33 || $[130] !== t36 || $[131] !== validationStatus || $[132] !== variantProp || $[133] !== widthProp) {
557
+ t37 = /*#__PURE__*/jsxs(TextInputWrapper, {
578
558
  block: block,
579
559
  contrast: contrast,
580
560
  disabled: disabled,
581
- hasLeadingVisual: t14,
582
- hasTrailingVisual: t15,
561
+ hasLeadingVisual: t18,
562
+ hasTrailingVisual: t19,
583
563
  width: widthProp,
584
564
  minWidth: minWidthProp,
585
565
  maxWidth: maxWidthProp,
586
- size: t16,
566
+ size: t20,
587
567
  validationStatus: validationStatus,
588
568
  variant: variantProp,
589
569
  onClick: focusInput,
590
- "data-token-wrapping": t17,
591
- className: t18,
592
- style: t19,
593
- children: [t20, t23, t29, t32]
570
+ "data-token-wrapping": t21,
571
+ className: t22,
572
+ style: t23,
573
+ children: [t24, t27, t33, t36]
594
574
  });
595
575
  $[116] = block;
596
576
  $[117] = contrast;
597
577
  $[118] = disabled;
598
578
  $[119] = maxWidthProp;
599
579
  $[120] = minWidthProp;
600
- $[121] = t14;
601
- $[122] = t15;
602
- $[123] = t16;
603
- $[124] = t17;
604
- $[125] = t18;
605
- $[126] = t19;
606
- $[127] = t20;
607
- $[128] = t23;
608
- $[129] = t29;
609
- $[130] = t32;
580
+ $[121] = t18;
581
+ $[122] = t19;
582
+ $[123] = t20;
583
+ $[124] = t21;
584
+ $[125] = t22;
585
+ $[126] = t23;
586
+ $[127] = t24;
587
+ $[128] = t27;
588
+ $[129] = t33;
589
+ $[130] = t36;
610
590
  $[131] = validationStatus;
611
591
  $[132] = variantProp;
612
592
  $[133] = widthProp;
613
- $[134] = t33;
593
+ $[134] = t37;
614
594
  } else {
615
- t33 = $[134];
595
+ t37 = $[134];
616
596
  }
617
- return t33;
597
+ return t37;
618
598
  }
619
599
  function _temp3(event_2) {
620
600
  event_2.stopPropagation();