@sanity/ui 3.1.1-canary.1 → 3.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +175 -185
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +176 -186
- package/dist/index.mjs.map +1 -1
- package/package.json +53 -39
- package/src/core/components/autocomplete/autocomplete.tsx +1 -11
- package/src/core/components/tree/treeItem.tsx +2 -12
package/dist/index.mjs
CHANGED
|
@@ -3,7 +3,7 @@ import { Arrow, Avatar, AvatarCounter, AvatarStack, Badge, BoundaryElementProvid
|
|
|
3
3
|
import { jsx, jsxs, Fragment as Fragment$1 } from "react/jsx-runtime";
|
|
4
4
|
import { c } from "react-compiler-runtime";
|
|
5
5
|
import { SpinnerIcon, ChevronDownIcon, CloseIcon, ToggleArrowRightIcon } from "@sanity/icons";
|
|
6
|
-
import { useState, useRef, useEffect, useImperativeHandle, Component, forwardRef, useReducer,
|
|
6
|
+
import { useState, useRef, useEffect, useImperativeHandle, Component, forwardRef, useReducer, cloneElement, Children, isValidElement, Fragment, useContext, useSyncExternalStore, startTransition, useId } from "react";
|
|
7
7
|
import { styled, keyframes, css } from "styled-components";
|
|
8
8
|
import { getTheme_v2 } from "@sanity/ui/theme";
|
|
9
9
|
import { motion, AnimatePresence } from "framer-motion";
|
|
@@ -220,7 +220,7 @@ function autocompleteReducer(state, msg) {
|
|
|
220
220
|
} : state;
|
|
221
221
|
}
|
|
222
222
|
const AUTOCOMPLETE_LISTBOX_IGNORE_KEYS = ["Control", "Shift", "Alt", "Enter", "Home", "End", "PageUp", "PageDown", "Meta", "Tab", "CapsLock"], AUTOCOMPLETE_POPOVER_PLACEMENT = "bottom-start", AUTOCOMPLETE_POPOVER_FALLBACK_PLACEMENTS = ["bottom-start", "top-start"], DEFAULT_RENDER_VALUE = (value, option) => option ? option.value : value, DEFAULT_FILTER_OPTION = (query, option) => option.value.toLowerCase().indexOf(query.toLowerCase()) > -1, InnerAutocomplete = forwardRef(function(props, forwardedRef) {
|
|
223
|
-
const $ = c(
|
|
223
|
+
const $ = c(180);
|
|
224
224
|
let customValidity, disabled, filterOptionProp, icon, id, loading, onBlur, onChange, onFocus, onQueryChange, onSelect, openButton, openOnFocus, optionsProp, prefix, readOnly, relatedElements, renderOptionProp, renderPopover, restProps, suffix, t0, t1, t2, t3, t4, t5, t6, valueProp;
|
|
225
225
|
$[0] !== props ? ({
|
|
226
226
|
border: t0,
|
|
@@ -276,29 +276,24 @@ const AUTOCOMPLETE_LISTBOX_IGNORE_KEYS = ["Control", "Shift", "Alt", "Enter", "H
|
|
|
276
276
|
} = t112;
|
|
277
277
|
return /* @__PURE__ */ jsx(Card, { "data-as": "button", padding: paddingProp, radius: 2, tone: "inherit", children: /* @__PURE__ */ jsx(Text, { size: fontSize, textOverflow: "ellipsis", children: value_0 }) });
|
|
278
278
|
}, $[33] = fontSize, $[34] = paddingProp, $[35] = t10) : t10 = $[35];
|
|
279
|
-
const renderOption = typeof renderOptionProp == "function" ? renderOptionProp : t10, filterOption = typeof filterOptionProp == "function" ? filterOptionProp : DEFAULT_FILTER_OPTION, rootElementRef = useRef(null), resultsPopoverElementRef = useRef(null), inputElementRef = useRef(null), listBoxElementRef = useRef(null), [inputElement,
|
|
280
|
-
let t11;
|
|
281
|
-
$[36]
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
const setInputElement = t11, listFocusedRef = useRef(!1), valueRef = useRef(value), valuePropRef = useRef(valueProp), popoverMouseWithinRef = useRef(!1);
|
|
285
|
-
let t12, t13;
|
|
286
|
-
$[37] !== inputElement ? (t12 = () => inputElement, t13 = [inputElement], $[37] = inputElement, $[38] = t12, $[39] = t13) : (t12 = $[38], t13 = $[39]), useImperativeHandle(inputElementRef, t12, t13);
|
|
287
|
-
let t14, t15;
|
|
288
|
-
$[40] !== inputElement ? (t14 = () => inputElement, t15 = [inputElement], $[40] = inputElement, $[41] = t14, $[42] = t15) : (t14 = $[41], t15 = $[42]), useImperativeHandle(forwardedRef, t14, t15);
|
|
279
|
+
const renderOption = typeof renderOptionProp == "function" ? renderOptionProp : t10, filterOption = typeof filterOptionProp == "function" ? filterOptionProp : DEFAULT_FILTER_OPTION, rootElementRef = useRef(null), resultsPopoverElementRef = useRef(null), inputElementRef = useRef(null), listBoxElementRef = useRef(null), [inputElement, setInputElement] = useState(null), listFocusedRef = useRef(!1), valueRef = useRef(value), valuePropRef = useRef(valueProp), popoverMouseWithinRef = useRef(!1);
|
|
280
|
+
let t11, t12;
|
|
281
|
+
$[36] !== inputElement ? (t11 = () => inputElement, t12 = [inputElement], $[36] = inputElement, $[37] = t11, $[38] = t12) : (t11 = $[37], t12 = $[38]), useImperativeHandle(inputElementRef, t11, t12);
|
|
282
|
+
let t13, t14;
|
|
283
|
+
$[39] !== inputElement ? (t13 = () => inputElement, t14 = [inputElement], $[39] = inputElement, $[40] = t13, $[41] = t14) : (t13 = $[40], t14 = $[41]), useImperativeHandle(forwardedRef, t13, t14);
|
|
289
284
|
const listBoxId = `${id}-listbox`, options = Array.isArray(optionsProp) ? optionsProp : EMPTY_ARRAY, padding = _getArrayProp(paddingProp);
|
|
285
|
+
let t15;
|
|
286
|
+
$[42] !== options || $[43] !== value ? (t15 = value !== null ? options.find((o) => o.value === value) : void 0, $[42] = options, $[43] = value, $[44] = t15) : t15 = $[44];
|
|
287
|
+
const currentOption = t15;
|
|
290
288
|
let t16;
|
|
291
|
-
$[
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
if ($[46] !== filterOption || $[47] !== options || $[48] !== query) {
|
|
295
|
-
let t182;
|
|
296
|
-
$[50] !== filterOption || $[51] !== query ? (t182 = (option) => query ? filterOption(query, option) : !0, $[50] = filterOption, $[51] = query, $[52] = t182) : t182 = $[52], t17 = options.filter(t182), $[46] = filterOption, $[47] = options, $[48] = query, $[49] = t17;
|
|
289
|
+
if ($[45] !== filterOption || $[46] !== options || $[47] !== query) {
|
|
290
|
+
let t172;
|
|
291
|
+
$[49] !== filterOption || $[50] !== query ? (t172 = (option) => query ? filterOption(query, option) : !0, $[49] = filterOption, $[50] = query, $[51] = t172) : t172 = $[51], t16 = options.filter(t172), $[45] = filterOption, $[46] = options, $[47] = query, $[48] = t16;
|
|
297
292
|
} else
|
|
298
|
-
|
|
299
|
-
const filteredOptions =
|
|
300
|
-
let
|
|
301
|
-
$[
|
|
293
|
+
t16 = $[48];
|
|
294
|
+
const filteredOptions = t16, filteredOptionsLen = filteredOptions.length, activeItemId = activeValue ? `${id}-option-${activeValue}` : void 0, expanded = query !== null && loading || focused && query !== null;
|
|
295
|
+
let t17;
|
|
296
|
+
$[52] !== onBlur || $[53] !== onQueryChange || $[54] !== relatedElements ? (t17 = (event) => {
|
|
302
297
|
setTimeout(() => {
|
|
303
298
|
if (popoverMouseWithinRef.current)
|
|
304
299
|
return;
|
|
@@ -315,27 +310,27 @@ const AUTOCOMPLETE_LISTBOX_IGNORE_KEYS = ["Control", "Shift", "Alt", "Enter", "H
|
|
|
315
310
|
type: "root/blur"
|
|
316
311
|
}), popoverMouseWithinRef.current = !1, onQueryChange && onQueryChange(null), onBlur && onBlur(event));
|
|
317
312
|
}, 0);
|
|
318
|
-
}, $[
|
|
319
|
-
const handleRootBlur =
|
|
320
|
-
let
|
|
321
|
-
$[
|
|
313
|
+
}, $[52] = onBlur, $[53] = onQueryChange, $[54] = relatedElements, $[55] = t17) : t17 = $[55];
|
|
314
|
+
const handleRootBlur = t17;
|
|
315
|
+
let t18;
|
|
316
|
+
$[56] === Symbol.for("react.memo_cache_sentinel") ? (t18 = (event_0) => {
|
|
322
317
|
const listBoxElement = listBoxElementRef.current, focusedElement = event_0.target instanceof HTMLElement ? event_0.target : null, listFocused_0 = listBoxElement?.contains(focusedElement) || !1;
|
|
323
318
|
listFocused_0 !== listFocusedRef.current && (listFocusedRef.current = listFocused_0, dispatch({
|
|
324
319
|
type: "root/setListFocused",
|
|
325
320
|
listFocused: listFocused_0
|
|
326
321
|
}));
|
|
327
|
-
}, $[
|
|
328
|
-
const handleRootFocus =
|
|
329
|
-
let
|
|
330
|
-
$[
|
|
322
|
+
}, $[56] = t18) : t18 = $[56];
|
|
323
|
+
const handleRootFocus = t18;
|
|
324
|
+
let t19;
|
|
325
|
+
$[57] !== onChange || $[58] !== onQueryChange || $[59] !== onSelect ? (t19 = (v) => {
|
|
331
326
|
dispatch({
|
|
332
327
|
type: "value/change",
|
|
333
328
|
value: v
|
|
334
329
|
}), popoverMouseWithinRef.current = !1, onSelect && onSelect(v), valueRef.current = v, onChange && onChange(v), onQueryChange && onQueryChange(null), inputElementRef.current?.focus();
|
|
335
|
-
}, $[
|
|
336
|
-
const handleOptionSelect =
|
|
337
|
-
let
|
|
338
|
-
$[
|
|
330
|
+
}, $[57] = onChange, $[58] = onQueryChange, $[59] = onSelect, $[60] = t19) : t19 = $[60];
|
|
331
|
+
const handleOptionSelect = t19;
|
|
332
|
+
let t20;
|
|
333
|
+
$[61] !== activeValue || $[62] !== filteredOptions || $[63] !== filteredOptionsLen || $[64] !== onQueryChange ? (t20 = (event_1) => {
|
|
339
334
|
if (event_1.key === "ArrowDown") {
|
|
340
335
|
if (event_1.preventDefault(), !filteredOptionsLen)
|
|
341
336
|
return;
|
|
@@ -369,58 +364,58 @@ const AUTOCOMPLETE_LISTBOX_IGNORE_KEYS = ["Control", "Shift", "Alt", "Enter", "H
|
|
|
369
364
|
inputElementRef.current?.focus();
|
|
370
365
|
return;
|
|
371
366
|
}
|
|
372
|
-
}, $[
|
|
373
|
-
const handleRootKeyDown =
|
|
374
|
-
let
|
|
375
|
-
$[
|
|
367
|
+
}, $[61] = activeValue, $[62] = filteredOptions, $[63] = filteredOptionsLen, $[64] = onQueryChange, $[65] = t20) : t20 = $[65];
|
|
368
|
+
const handleRootKeyDown = t20;
|
|
369
|
+
let t21;
|
|
370
|
+
$[66] !== onQueryChange ? (t21 = (event_2) => {
|
|
376
371
|
const nextQuery = event_2.currentTarget.value;
|
|
377
372
|
dispatch({
|
|
378
373
|
type: "input/change",
|
|
379
374
|
query: nextQuery
|
|
380
375
|
}), onQueryChange && onQueryChange(nextQuery);
|
|
381
|
-
}, $[
|
|
382
|
-
const handleInputChange =
|
|
383
|
-
let
|
|
384
|
-
$[
|
|
376
|
+
}, $[66] = onQueryChange, $[67] = t21) : t21 = $[67];
|
|
377
|
+
const handleInputChange = t21;
|
|
378
|
+
let t22;
|
|
379
|
+
$[68] !== currentOption || $[69] !== renderValue || $[70] !== value ? (t22 = () => {
|
|
385
380
|
dispatch({
|
|
386
381
|
type: "root/open",
|
|
387
382
|
query: value ? renderValue(value, currentOption) : ""
|
|
388
383
|
});
|
|
389
|
-
}, $[
|
|
390
|
-
const dispatchOpen =
|
|
391
|
-
let
|
|
392
|
-
$[
|
|
384
|
+
}, $[68] = currentOption, $[69] = renderValue, $[70] = value, $[71] = t22) : t22 = $[71];
|
|
385
|
+
const dispatchOpen = t22;
|
|
386
|
+
let t23;
|
|
387
|
+
$[72] !== dispatchOpen || $[73] !== focused || $[74] !== onFocus || $[75] !== openOnFocus ? (t23 = (event_3) => {
|
|
393
388
|
focused || (dispatch({
|
|
394
389
|
type: "input/focus"
|
|
395
390
|
}), onFocus && onFocus(event_3), openOnFocus && dispatchOpen());
|
|
396
|
-
}, $[
|
|
397
|
-
const handleInputFocus =
|
|
391
|
+
}, $[72] = dispatchOpen, $[73] = focused, $[74] = onFocus, $[75] = openOnFocus, $[76] = t23) : t23 = $[76];
|
|
392
|
+
const handleInputFocus = t23;
|
|
393
|
+
let t24;
|
|
394
|
+
$[77] === Symbol.for("react.memo_cache_sentinel") ? (t24 = () => {
|
|
395
|
+
popoverMouseWithinRef.current = !0;
|
|
396
|
+
}, $[77] = t24) : t24 = $[77];
|
|
397
|
+
const handlePopoverMouseEnter = t24;
|
|
398
398
|
let t25;
|
|
399
399
|
$[78] === Symbol.for("react.memo_cache_sentinel") ? (t25 = () => {
|
|
400
|
-
popoverMouseWithinRef.current = !
|
|
400
|
+
popoverMouseWithinRef.current = !1;
|
|
401
401
|
}, $[78] = t25) : t25 = $[78];
|
|
402
|
-
const
|
|
402
|
+
const handlePopoverMouseLeave = t25;
|
|
403
403
|
let t26;
|
|
404
|
-
$[79]
|
|
405
|
-
popoverMouseWithinRef.current = !1;
|
|
406
|
-
}, $[79] = t26) : t26 = $[79];
|
|
407
|
-
const handlePopoverMouseLeave = t26;
|
|
408
|
-
let t27;
|
|
409
|
-
$[80] !== onChange || $[81] !== onQueryChange ? (t27 = () => {
|
|
404
|
+
$[79] !== onChange || $[80] !== onQueryChange ? (t26 = () => {
|
|
410
405
|
dispatch({
|
|
411
406
|
type: "root/clear"
|
|
412
407
|
}), valueRef.current = "", onChange && onChange(""), onQueryChange && onQueryChange(null), inputElementRef.current?.focus();
|
|
413
|
-
}, $[
|
|
414
|
-
const handleClearButtonClick =
|
|
415
|
-
let
|
|
416
|
-
$[
|
|
408
|
+
}, $[79] = onChange, $[80] = onQueryChange, $[81] = t26) : t26 = $[81];
|
|
409
|
+
const handleClearButtonClick = t26;
|
|
410
|
+
let t27;
|
|
411
|
+
$[82] === Symbol.for("react.memo_cache_sentinel") ? (t27 = () => {
|
|
417
412
|
dispatch({
|
|
418
413
|
type: "input/focus"
|
|
419
414
|
});
|
|
420
|
-
}, $[
|
|
421
|
-
const handleClearButtonFocus =
|
|
422
|
-
let
|
|
423
|
-
$[
|
|
415
|
+
}, $[82] = t27) : t27 = $[82];
|
|
416
|
+
const handleClearButtonFocus = t27;
|
|
417
|
+
let t28, t29;
|
|
418
|
+
$[83] !== valueProp ? (t28 = () => {
|
|
424
419
|
if (valueProp !== valuePropRef.current) {
|
|
425
420
|
valuePropRef.current = valueProp, valueProp !== void 0 && (dispatch({
|
|
426
421
|
type: "value/change",
|
|
@@ -432,16 +427,16 @@ const AUTOCOMPLETE_LISTBOX_IGNORE_KEYS = ["Control", "Shift", "Alt", "Enter", "H
|
|
|
432
427
|
type: "value/change",
|
|
433
428
|
value: valueProp || null
|
|
434
429
|
}));
|
|
435
|
-
},
|
|
436
|
-
let
|
|
437
|
-
$[
|
|
430
|
+
}, t29 = [valueProp], $[83] = valueProp, $[84] = t28, $[85] = t29) : (t28 = $[84], t29 = $[85]), useEffect(t28, t29);
|
|
431
|
+
let t30, t31;
|
|
432
|
+
$[86] !== focused ? (t30 = () => {
|
|
438
433
|
!focused && valueRef.current && dispatch({
|
|
439
434
|
type: "root/setActiveValue",
|
|
440
435
|
value: valueRef.current
|
|
441
436
|
});
|
|
442
|
-
},
|
|
443
|
-
let
|
|
444
|
-
$[
|
|
437
|
+
}, t31 = [focused], $[86] = focused, $[87] = t30, $[88] = t31) : (t30 = $[87], t31 = $[88]), useEffect(t30, t31);
|
|
438
|
+
let t32, t33;
|
|
439
|
+
$[89] !== activeValue || $[90] !== filteredOptions ? (t32 = () => {
|
|
445
440
|
const listElement = listBoxElementRef.current;
|
|
446
441
|
if (!listElement)
|
|
447
442
|
return;
|
|
@@ -454,95 +449,95 @@ const AUTOCOMPLETE_LISTBOX_IGNORE_KEYS = ["Control", "Shift", "Alt", "Enter", "H
|
|
|
454
449
|
focusFirstDescendant(activeItemElement);
|
|
455
450
|
}
|
|
456
451
|
}
|
|
457
|
-
},
|
|
458
|
-
let
|
|
452
|
+
}, t33 = [activeValue, filteredOptions], $[89] = activeValue, $[90] = filteredOptions, $[91] = t32, $[92] = t33) : (t32 = $[91], t33 = $[92]), useEffect(t32, t33);
|
|
453
|
+
let t34;
|
|
459
454
|
bb0: {
|
|
460
455
|
if (!loading && !disabled && value) {
|
|
461
|
-
let
|
|
462
|
-
$[
|
|
456
|
+
let t352;
|
|
457
|
+
$[93] === Symbol.for("react.memo_cache_sentinel") ? (t352 = {
|
|
463
458
|
"aria-label": "Clear",
|
|
464
459
|
onFocus: handleClearButtonFocus
|
|
465
|
-
}, $[
|
|
460
|
+
}, $[93] = t352) : t352 = $[93], t34 = t352;
|
|
466
461
|
break bb0;
|
|
467
462
|
}
|
|
468
|
-
|
|
463
|
+
t34 = void 0;
|
|
469
464
|
}
|
|
470
|
-
const clearButton =
|
|
471
|
-
let
|
|
472
|
-
$[
|
|
465
|
+
const clearButton = t34, openButtonBoxPadding = padding.map(_temp$3), openButtonPadding = padding.map(_temp2$1), openButtonProps = typeof openButton == "object" ? openButton : EMPTY_RECORD;
|
|
466
|
+
let t35;
|
|
467
|
+
$[94] !== dispatchOpen || $[95] !== openButtonProps ? (t35 = (event_4) => {
|
|
473
468
|
dispatchOpen(), openButtonProps.onClick && openButtonProps.onClick(event_4), _raf(() => inputElementRef.current?.focus());
|
|
474
|
-
}, $[
|
|
475
|
-
const handleOpenClick =
|
|
469
|
+
}, $[94] = dispatchOpen, $[95] = openButtonProps, $[96] = t35) : t35 = $[96];
|
|
470
|
+
const handleOpenClick = t35;
|
|
471
|
+
let t36;
|
|
472
|
+
$[97] !== disabled || $[98] !== expanded || $[99] !== fontSize || $[100] !== handleOpenClick || $[101] !== openButton || $[102] !== openButtonBoxPadding || $[103] !== openButtonPadding || $[104] !== openButtonProps || $[105] !== readOnly ? (t36 = !disabled && !readOnly && openButton ? /* @__PURE__ */ jsx(Box, { "aria-hidden": expanded, padding: openButtonBoxPadding, children: /* @__PURE__ */ jsx(Button, { "aria-label": "Open", disabled: expanded, fontSize, icon: ChevronDownIcon, mode: "bleed", padding: openButtonPadding, ...openButtonProps, onClick: handleOpenClick }) }) : void 0, $[97] = disabled, $[98] = expanded, $[99] = fontSize, $[100] = handleOpenClick, $[101] = openButton, $[102] = openButtonBoxPadding, $[103] = openButtonPadding, $[104] = openButtonProps, $[105] = readOnly, $[106] = t36) : t36 = $[106];
|
|
473
|
+
const openButtonNode = t36;
|
|
476
474
|
let t37;
|
|
477
|
-
$[98] !== disabled || $[99] !== expanded || $[100] !== fontSize || $[101] !== handleOpenClick || $[102] !== openButton || $[103] !== openButtonBoxPadding || $[104] !== openButtonPadding || $[105] !== openButtonProps || $[106] !== readOnly ? (t37 = !disabled && !readOnly && openButton ? /* @__PURE__ */ jsx(Box, { "aria-hidden": expanded, padding: openButtonBoxPadding, children: /* @__PURE__ */ jsx(Button, { "aria-label": "Open", disabled: expanded, fontSize, icon: ChevronDownIcon, mode: "bleed", padding: openButtonPadding, ...openButtonProps, onClick: handleOpenClick }) }) : void 0, $[98] = disabled, $[99] = expanded, $[100] = fontSize, $[101] = handleOpenClick, $[102] = openButton, $[103] = openButtonBoxPadding, $[104] = openButtonPadding, $[105] = openButtonProps, $[106] = readOnly, $[107] = t37) : t37 = $[107];
|
|
478
|
-
const openButtonNode = t37;
|
|
479
|
-
let t38;
|
|
480
475
|
bb1: {
|
|
481
476
|
if (query === null) {
|
|
482
477
|
if (value !== null) {
|
|
483
|
-
let
|
|
484
|
-
$[
|
|
478
|
+
let t382;
|
|
479
|
+
$[107] !== currentOption || $[108] !== renderValue || $[109] !== value ? (t382 = renderValue(value, currentOption), $[107] = currentOption, $[108] = renderValue, $[109] = value, $[110] = t382) : t382 = $[110], t37 = t382;
|
|
485
480
|
break bb1;
|
|
486
481
|
}
|
|
487
|
-
|
|
482
|
+
t37 = "";
|
|
488
483
|
break bb1;
|
|
489
484
|
}
|
|
490
|
-
|
|
485
|
+
t37 = query;
|
|
491
486
|
}
|
|
492
|
-
const inputValue =
|
|
493
|
-
let
|
|
494
|
-
$[
|
|
487
|
+
const inputValue = t37;
|
|
488
|
+
let t38;
|
|
489
|
+
$[111] !== listFocused ? (t38 = (event_5) => {
|
|
495
490
|
event_5.key === "Tab" && listFocused && inputElementRef.current?.focus();
|
|
496
|
-
}, $[
|
|
497
|
-
const handleListBoxKeyDown =
|
|
498
|
-
let
|
|
491
|
+
}, $[111] = listFocused, $[112] = t38) : t38 = $[112];
|
|
492
|
+
const handleListBoxKeyDown = t38;
|
|
493
|
+
let t39;
|
|
499
494
|
bb2: {
|
|
500
495
|
if (filteredOptions.length === 0) {
|
|
501
|
-
|
|
496
|
+
t39 = null;
|
|
502
497
|
break bb2;
|
|
503
498
|
}
|
|
504
|
-
let
|
|
505
|
-
if ($[
|
|
506
|
-
let
|
|
507
|
-
$[
|
|
499
|
+
let t402;
|
|
500
|
+
if ($[113] !== activeValue || $[114] !== currentOption || $[115] !== filteredOptions || $[116] !== handleOptionSelect || $[117] !== id || $[118] !== listFocused || $[119] !== loading || $[120] !== renderOption) {
|
|
501
|
+
let t413;
|
|
502
|
+
$[122] !== activeValue || $[123] !== currentOption || $[124] !== handleOptionSelect || $[125] !== id || $[126] !== listFocused || $[127] !== loading || $[128] !== renderOption ? (t413 = (option_0) => {
|
|
508
503
|
const active = activeValue !== null ? option_0.value === activeValue : currentOption === option_0;
|
|
509
504
|
return /* @__PURE__ */ jsx(AutocompleteOption, { id: `${id}-option-${option_0.value}`, onSelect: handleOptionSelect, selected: active, value: option_0.value, children: cloneElement(renderOption(option_0), {
|
|
510
505
|
disabled: loading,
|
|
511
506
|
selected: active,
|
|
512
507
|
tabIndex: listFocused && active ? 0 : -1
|
|
513
508
|
}) }, option_0.value);
|
|
514
|
-
}, $[
|
|
509
|
+
}, $[122] = activeValue, $[123] = currentOption, $[124] = handleOptionSelect, $[125] = id, $[126] = listFocused, $[127] = loading, $[128] = renderOption, $[129] = t413) : t413 = $[129], t402 = filteredOptions.map(t413), $[113] = activeValue, $[114] = currentOption, $[115] = filteredOptions, $[116] = handleOptionSelect, $[117] = id, $[118] = listFocused, $[119] = loading, $[120] = renderOption, $[121] = t402;
|
|
515
510
|
} else
|
|
516
|
-
|
|
511
|
+
t402 = $[121];
|
|
512
|
+
let t412;
|
|
513
|
+
$[130] !== listBoxId || $[131] !== t402 ? (t412 = /* @__PURE__ */ jsx(Stack, { as: "ul", "aria-multiselectable": !1, "data-ui": "AutoComplete__resultsList", id: listBoxId, ref: listBoxElementRef, role: "listbox", space: 1, children: t402 }), $[130] = listBoxId, $[131] = t402, $[132] = t412) : t412 = $[132];
|
|
517
514
|
let t422;
|
|
518
|
-
$[
|
|
519
|
-
let t432;
|
|
520
|
-
$[134] !== handleListBoxKeyDown || $[135] !== listBox || $[136] !== t422 ? (t432 = /* @__PURE__ */ jsx(ListBox, { "data-ui": "AutoComplete__results", onKeyDown: handleListBoxKeyDown, padding: 1, ...listBox, tabIndex: -1, children: t422 }), $[134] = handleListBoxKeyDown, $[135] = listBox, $[136] = t422, $[137] = t432) : t432 = $[137], t40 = t432;
|
|
515
|
+
$[133] !== handleListBoxKeyDown || $[134] !== listBox || $[135] !== t412 ? (t422 = /* @__PURE__ */ jsx(ListBox, { "data-ui": "AutoComplete__results", onKeyDown: handleListBoxKeyDown, padding: 1, ...listBox, tabIndex: -1, children: t412 }), $[133] = handleListBoxKeyDown, $[134] = listBox, $[135] = t412, $[136] = t422) : t422 = $[136], t39 = t422;
|
|
521
516
|
}
|
|
522
|
-
const content2 =
|
|
523
|
-
let
|
|
517
|
+
const content2 = t39;
|
|
518
|
+
let t40;
|
|
524
519
|
bb3: {
|
|
525
520
|
if (renderPopover) {
|
|
526
|
-
const
|
|
527
|
-
let
|
|
528
|
-
$[
|
|
521
|
+
const t413 = !expanded;
|
|
522
|
+
let t422;
|
|
523
|
+
$[137] !== content2 || $[138] !== handlePopoverMouseEnter || $[139] !== handlePopoverMouseLeave || $[140] !== inputElement || $[141] !== renderPopover || $[142] !== t413 ? (t422 = /* @__PURE__ */ jsx(RenderPopover, { content: content2, hidden: t413, inputElement, onMouseEnter: handlePopoverMouseEnter, onMouseLeave: handlePopoverMouseLeave, resultsPopoverElementRef, renderPopover }), $[137] = content2, $[138] = handlePopoverMouseEnter, $[139] = handlePopoverMouseLeave, $[140] = inputElement, $[141] = renderPopover, $[142] = t413, $[143] = t422) : t422 = $[143], t40 = t422;
|
|
529
524
|
break bb3;
|
|
530
525
|
}
|
|
531
526
|
if (filteredOptionsLen === 0) {
|
|
532
|
-
|
|
527
|
+
t40 = null;
|
|
533
528
|
break bb3;
|
|
534
529
|
}
|
|
535
|
-
let
|
|
536
|
-
$[
|
|
530
|
+
let t412;
|
|
531
|
+
$[144] !== content2 || $[145] !== expanded || $[146] !== handlePopoverMouseEnter || $[147] !== handlePopoverMouseLeave || $[148] !== inputElement || $[149] !== popover || $[150] !== radius ? (t412 = /* @__PURE__ */ jsx(Popover, { arrow: !1, constrainSize: !0, content: content2, fallbackPlacements: AUTOCOMPLETE_POPOVER_FALLBACK_PLACEMENTS, matchReferenceWidth: !0, onMouseEnter: handlePopoverMouseEnter, onMouseLeave: handlePopoverMouseLeave, open: expanded, overflow: "auto", placement: AUTOCOMPLETE_POPOVER_PLACEMENT, portal: !0, radius, ref: resultsPopoverElementRef, referenceElement: inputElement, ...popover }), $[144] = content2, $[145] = expanded, $[146] = handlePopoverMouseEnter, $[147] = handlePopoverMouseLeave, $[148] = inputElement, $[149] = popover, $[150] = radius, $[151] = t412) : t412 = $[151], t40 = t412;
|
|
537
532
|
}
|
|
538
|
-
const results =
|
|
533
|
+
const results = t40, t41 = loading && AnimatedSpinnerIcon, t42 = suffix || openButtonNode;
|
|
534
|
+
let t43;
|
|
535
|
+
$[152] !== activeItemId || $[153] !== border || $[154] !== clearButton || $[155] !== customValidity || $[156] !== disabled || $[157] !== expanded || $[158] !== fontSize || $[159] !== handleClearButtonClick || $[160] !== handleInputChange || $[161] !== handleInputFocus || $[162] !== icon || $[163] !== id || $[164] !== inputValue || $[165] !== listBoxId || $[166] !== padding || $[167] !== prefix || $[168] !== radius || $[169] !== readOnly || $[170] !== restProps || $[171] !== t41 || $[172] !== t42 ? (t43 = /* @__PURE__ */ jsx(TextInput, { ...restProps, "aria-activedescendant": activeItemId, "aria-autocomplete": "list", "aria-expanded": expanded, "aria-owns": listBoxId, autoCapitalize: "off", autoComplete: "off", autoCorrect: "off", border, clearButton, customValidity, disabled, fontSize, icon, iconRight: t41, id, inputMode: "search", onChange: handleInputChange, onClear: handleClearButtonClick, onFocus: handleInputFocus, padding, prefix, radius, readOnly, ref: setInputElement, role: "combobox", spellCheck: !1, suffix: t42, value: inputValue }), $[152] = activeItemId, $[153] = border, $[154] = clearButton, $[155] = customValidity, $[156] = disabled, $[157] = expanded, $[158] = fontSize, $[159] = handleClearButtonClick, $[160] = handleInputChange, $[161] = handleInputFocus, $[162] = icon, $[163] = id, $[164] = inputValue, $[165] = listBoxId, $[166] = padding, $[167] = prefix, $[168] = radius, $[169] = readOnly, $[170] = restProps, $[171] = t41, $[172] = t42, $[173] = t43) : t43 = $[173];
|
|
539
536
|
let t44;
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
return $[175] !== handleRootBlur || $[176] !== handleRootFocus || $[177] !== handleRootKeyDown || $[178] !== results || $[179] !== t44 ? (t45 = /* @__PURE__ */ jsxs(StyledAutocomplete, { "data-ui": "Autocomplete", onBlur: handleRootBlur, onFocus: handleRootFocus, onKeyDown: handleRootKeyDown, ref: rootElementRef, children: [
|
|
543
|
-
t44,
|
|
537
|
+
return $[174] !== handleRootBlur || $[175] !== handleRootFocus || $[176] !== handleRootKeyDown || $[177] !== results || $[178] !== t43 ? (t44 = /* @__PURE__ */ jsxs(StyledAutocomplete, { "data-ui": "Autocomplete", onBlur: handleRootBlur, onFocus: handleRootFocus, onKeyDown: handleRootKeyDown, ref: rootElementRef, children: [
|
|
538
|
+
t43,
|
|
544
539
|
results
|
|
545
|
-
] }), $[
|
|
540
|
+
] }), $[174] = handleRootBlur, $[175] = handleRootFocus, $[176] = handleRootKeyDown, $[177] = results, $[178] = t43, $[179] = t44) : t44 = $[179], t44;
|
|
546
541
|
});
|
|
547
542
|
function RenderPopover({
|
|
548
543
|
renderPopover,
|
|
@@ -1796,7 +1791,7 @@ const StyledTreeItem = /* @__PURE__ */ styled.li.withConfig({
|
|
|
1796
1791
|
componentId: "sc-iiskig-2"
|
|
1797
1792
|
})`& > svg{transition:transform 100ms;}`;
|
|
1798
1793
|
function TreeItem(props) {
|
|
1799
|
-
const $ = c(
|
|
1794
|
+
const $ = c(112);
|
|
1800
1795
|
let IconComponent, children, href, idProp, linkAs, muted, onClick, restProps, t0, t1, t2, t3, t4, text, weight;
|
|
1801
1796
|
$[0] !== props ? ({
|
|
1802
1797
|
children,
|
|
@@ -1815,101 +1810,96 @@ function TreeItem(props) {
|
|
|
1815
1810
|
weight,
|
|
1816
1811
|
...restProps
|
|
1817
1812
|
} = props, $[0] = props, $[1] = IconComponent, $[2] = children, $[3] = href, $[4] = idProp, $[5] = linkAs, $[6] = muted, $[7] = onClick, $[8] = restProps, $[9] = t0, $[10] = t1, $[11] = t2, $[12] = t3, $[13] = t4, $[14] = text, $[15] = weight) : (IconComponent = $[1], children = $[2], href = $[3], idProp = $[4], linkAs = $[5], muted = $[6], onClick = $[7], restProps = $[8], t0 = $[9], t1 = $[10], t2 = $[11], t3 = $[12], t4 = $[13], text = $[14], weight = $[15]);
|
|
1818
|
-
const expandedProp = t0 === void 0 ? !1 : t0, fontSize = t1 === void 0 ? 1 : t1, padding = t2 === void 0 ? 2 : t2, selected = t3 === void 0 ? !1 : t3, space = t4 === void 0 ? 2 : t4, [rootElement,
|
|
1819
|
-
let t5;
|
|
1820
|
-
$[16] === Symbol.for("react.memo_cache_sentinel") ? (t5 = (node) => {
|
|
1821
|
-
startTransition(() => _setRootElement(node));
|
|
1822
|
-
}, $[16] = t5) : t5 = $[16];
|
|
1823
|
-
const setRootElement = t5, treeitemRef = useRef(null), tree = useTree(), {
|
|
1813
|
+
const expandedProp = t0 === void 0 ? !1 : t0, fontSize = t1 === void 0 ? 1 : t1, padding = t2 === void 0 ? 2 : t2, selected = t3 === void 0 ? !1 : t3, space = t4 === void 0 ? 2 : t4, [rootElement, setRootElement] = useState(null), treeitemRef = useRef(null), tree = useTree(), {
|
|
1824
1814
|
path,
|
|
1825
1815
|
registerItem,
|
|
1826
1816
|
setExpanded,
|
|
1827
1817
|
setFocusedElement
|
|
1828
1818
|
} = tree, _id = useId(), id = idProp || _id;
|
|
1829
|
-
let
|
|
1830
|
-
if ($[
|
|
1819
|
+
let t5, t6;
|
|
1820
|
+
if ($[16] !== id || $[17] !== path) {
|
|
1831
1821
|
const itemPath = path.concat([id || ""]);
|
|
1832
|
-
|
|
1822
|
+
t5 = itemPath, t6 = itemPath.join("/"), $[16] = id, $[17] = path, $[18] = t5, $[19] = t6;
|
|
1833
1823
|
} else
|
|
1834
|
-
|
|
1835
|
-
let
|
|
1836
|
-
$[
|
|
1837
|
-
const [itemPath_0, itemKey] =
|
|
1838
|
-
let
|
|
1839
|
-
$[
|
|
1824
|
+
t5 = $[18], t6 = $[19];
|
|
1825
|
+
let t7;
|
|
1826
|
+
$[20] !== t5 || $[21] !== t6 ? (t7 = [t5, t6], $[20] = t5, $[21] = t6, $[22] = t7) : t7 = $[22];
|
|
1827
|
+
const [itemPath_0, itemKey] = t7, itemState = tree.state[itemKey], focused = tree.focusedElement === rootElement, expanded = itemState?.expanded === void 0 ? expandedProp : itemState?.expanded || !1, tabIndex = tree.focusedElement && tree.focusedElement === rootElement ? 0 : -1, t8 = tree.level + 1;
|
|
1828
|
+
let t9;
|
|
1829
|
+
$[23] !== itemPath_0 || $[24] !== t8 || $[25] !== tree ? (t9 = {
|
|
1840
1830
|
...tree,
|
|
1841
|
-
level:
|
|
1831
|
+
level: t8,
|
|
1842
1832
|
path: itemPath_0
|
|
1843
|
-
}, $[
|
|
1844
|
-
const contextValue =
|
|
1845
|
-
let
|
|
1846
|
-
$[
|
|
1833
|
+
}, $[23] = itemPath_0, $[24] = t8, $[25] = tree, $[26] = t9) : t9 = $[26];
|
|
1834
|
+
const contextValue = t9;
|
|
1835
|
+
let t10;
|
|
1836
|
+
$[27] !== expanded || $[28] !== itemKey || $[29] !== onClick || $[30] !== rootElement || $[31] !== setExpanded || $[32] !== setFocusedElement ? (t10 = (event) => {
|
|
1847
1837
|
onClick && onClick(event);
|
|
1848
1838
|
const target = event.target;
|
|
1849
1839
|
target instanceof HTMLElement && (target.getAttribute("data-ui") === "TreeItem" || target.closest('[data-ui="TreeItem__box"]')) && (event.stopPropagation(), setExpanded(itemKey, !expanded), setFocusedElement(rootElement));
|
|
1850
|
-
}, $[
|
|
1851
|
-
const handleClick =
|
|
1852
|
-
let
|
|
1853
|
-
$[
|
|
1840
|
+
}, $[27] = expanded, $[28] = itemKey, $[29] = onClick, $[30] = rootElement, $[31] = setExpanded, $[32] = setFocusedElement, $[33] = t10) : t10 = $[33];
|
|
1841
|
+
const handleClick = t10;
|
|
1842
|
+
let t11;
|
|
1843
|
+
$[34] !== focused || $[35] !== rootElement ? (t11 = (event_0) => {
|
|
1854
1844
|
focused && event_0.key === "Enter" && (treeitemRef.current || rootElement)?.click();
|
|
1855
|
-
}, $[
|
|
1856
|
-
const handleKeyDown =
|
|
1857
|
-
let
|
|
1858
|
-
$[
|
|
1845
|
+
}, $[34] = focused, $[35] = rootElement, $[36] = t11) : t11 = $[36];
|
|
1846
|
+
const handleKeyDown = t11;
|
|
1847
|
+
let t12, t13;
|
|
1848
|
+
$[37] !== expanded || $[38] !== itemKey || $[39] !== registerItem || $[40] !== rootElement || $[41] !== selected ? (t12 = () => {
|
|
1859
1849
|
if (rootElement)
|
|
1860
1850
|
return registerItem(rootElement, itemKey, expanded, selected);
|
|
1861
|
-
},
|
|
1862
|
-
const
|
|
1863
|
-
let
|
|
1864
|
-
$[
|
|
1865
|
-
visibility:
|
|
1851
|
+
}, t13 = [expanded, itemKey, registerItem, rootElement, selected], $[37] = expanded, $[38] = itemKey, $[39] = registerItem, $[40] = rootElement, $[41] = selected, $[42] = t12, $[43] = t13) : (t12 = $[42], t13 = $[43]), useEffect(t12, t13);
|
|
1852
|
+
const t14 = IconComponent || children ? "visible" : "hidden";
|
|
1853
|
+
let t15;
|
|
1854
|
+
$[44] !== t14 ? (t15 = {
|
|
1855
|
+
visibility: t14,
|
|
1866
1856
|
pointerEvents: "none"
|
|
1867
|
-
}, $[
|
|
1857
|
+
}, $[44] = t14, $[45] = t15) : t15 = $[45];
|
|
1858
|
+
let t16;
|
|
1859
|
+
$[46] !== IconComponent || $[47] !== fontSize || $[48] !== muted || $[49] !== weight ? (t16 = IconComponent && /* @__PURE__ */ jsx(Text, { muted, size: fontSize, weight, children: /* @__PURE__ */ jsx(IconComponent, {}) }), $[46] = IconComponent, $[47] = fontSize, $[48] = muted, $[49] = weight, $[50] = t16) : t16 = $[50];
|
|
1868
1860
|
let t17;
|
|
1869
|
-
$[
|
|
1870
|
-
let t18;
|
|
1871
|
-
$[52] !== IconComponent || $[53] !== expanded || $[54] !== fontSize || $[55] !== muted || $[56] !== weight ? (t18 = !IconComponent && /* @__PURE__ */ jsx(ToggleArrowText, { muted, size: fontSize, weight, children: /* @__PURE__ */ jsx(ToggleArrowRightIcon, { style: {
|
|
1861
|
+
$[51] !== IconComponent || $[52] !== expanded || $[53] !== fontSize || $[54] !== muted || $[55] !== weight ? (t17 = !IconComponent && /* @__PURE__ */ jsx(ToggleArrowText, { muted, size: fontSize, weight, children: /* @__PURE__ */ jsx(ToggleArrowRightIcon, { style: {
|
|
1872
1862
|
transform: expanded ? "rotate(90deg)" : void 0
|
|
1873
|
-
} }) }), $[
|
|
1863
|
+
} }) }), $[51] = IconComponent, $[52] = expanded, $[53] = fontSize, $[54] = muted, $[55] = weight, $[56] = t17) : t17 = $[56];
|
|
1864
|
+
let t18;
|
|
1865
|
+
$[57] !== space || $[58] !== t15 || $[59] !== t16 || $[60] !== t17 ? (t18 = /* @__PURE__ */ jsxs(Box, { marginRight: space, style: t15, children: [
|
|
1866
|
+
t16,
|
|
1867
|
+
t17
|
|
1868
|
+
] }), $[57] = space, $[58] = t15, $[59] = t16, $[60] = t17, $[61] = t18) : t18 = $[61];
|
|
1874
1869
|
let t19;
|
|
1875
|
-
$[
|
|
1876
|
-
t17,
|
|
1877
|
-
t18
|
|
1878
|
-
] }), $[58] = space, $[59] = t16, $[60] = t17, $[61] = t18, $[62] = t19) : t19 = $[62];
|
|
1870
|
+
$[62] !== fontSize || $[63] !== muted || $[64] !== text || $[65] !== weight ? (t19 = /* @__PURE__ */ jsx(Box, { flex: 1, children: /* @__PURE__ */ jsx(Text, { muted, size: fontSize, textOverflow: "ellipsis", weight, children: text }) }), $[62] = fontSize, $[63] = muted, $[64] = text, $[65] = weight, $[66] = t19) : t19 = $[66];
|
|
1879
1871
|
let t20;
|
|
1880
|
-
$[
|
|
1881
|
-
|
|
1882
|
-
|
|
1883
|
-
|
|
1884
|
-
|
|
1885
|
-
] }), $[68] = padding, $[69] = t19, $[70] = t20, $[71] = t21) : t21 = $[71];
|
|
1886
|
-
const content2 = t21;
|
|
1872
|
+
$[67] !== padding || $[68] !== t18 || $[69] !== t19 ? (t20 = /* @__PURE__ */ jsxs(Flex, { padding, children: [
|
|
1873
|
+
t18,
|
|
1874
|
+
t19
|
|
1875
|
+
] }), $[67] = padding, $[68] = t18, $[69] = t19, $[70] = t20) : t20 = $[70];
|
|
1876
|
+
const content2 = t20;
|
|
1887
1877
|
if (href) {
|
|
1888
|
-
const
|
|
1878
|
+
const t212 = selected ? "" : void 0;
|
|
1879
|
+
let t222;
|
|
1880
|
+
$[71] !== content2 || $[72] !== expanded || $[73] !== href || $[74] !== linkAs || $[75] !== tabIndex || $[76] !== tree.level ? (t222 = /* @__PURE__ */ jsx(TreeItemBox, { $level: tree.level, "aria-expanded": expanded, as: linkAs, "data-ui": "TreeItem__box", href, ref: treeitemRef, role: "treeitem", tabIndex, children: content2 }), $[71] = content2, $[72] = expanded, $[73] = href, $[74] = linkAs, $[75] = tabIndex, $[76] = tree.level, $[77] = t222) : t222 = $[77];
|
|
1889
1881
|
let t232;
|
|
1890
|
-
$[
|
|
1882
|
+
$[78] !== children || $[79] !== expanded ? (t232 = children && /* @__PURE__ */ jsx(TreeGroup, { hidden: !expanded, children }), $[78] = children, $[79] = expanded, $[80] = t232) : t232 = $[80];
|
|
1891
1883
|
let t242;
|
|
1892
|
-
$[
|
|
1884
|
+
$[81] !== contextValue || $[82] !== t232 ? (t242 = /* @__PURE__ */ jsx(TreeContext.Provider, { value: contextValue, children: t232 }), $[81] = contextValue, $[82] = t232, $[83] = t242) : t242 = $[83];
|
|
1893
1885
|
let t252;
|
|
1894
|
-
$[
|
|
1895
|
-
|
|
1896
|
-
|
|
1897
|
-
|
|
1898
|
-
t252
|
|
1899
|
-
] }), $[85] = handleClick, $[86] = id, $[87] = itemKey, $[88] = restProps, $[89] = t222, $[90] = t232, $[91] = t252, $[92] = t262) : t262 = $[92], t262;
|
|
1886
|
+
return $[84] !== handleClick || $[85] !== id || $[86] !== itemKey || $[87] !== restProps || $[88] !== t212 || $[89] !== t222 || $[90] !== t242 ? (t252 = /* @__PURE__ */ jsxs(StyledTreeItem, { "data-selected": t212, "data-tree-id": id, "data-tree-key": itemKey, "data-ui": "TreeItem", ...restProps, onClick: handleClick, ref: setRootElement, role: "none", children: [
|
|
1887
|
+
t222,
|
|
1888
|
+
t242
|
|
1889
|
+
] }), $[84] = handleClick, $[85] = id, $[86] = itemKey, $[87] = restProps, $[88] = t212, $[89] = t222, $[90] = t242, $[91] = t252) : t252 = $[91], t252;
|
|
1900
1890
|
}
|
|
1901
|
-
const
|
|
1891
|
+
const t21 = selected ? "" : void 0;
|
|
1892
|
+
let t22;
|
|
1893
|
+
$[92] !== content2 || $[93] !== tree.level ? (t22 = /* @__PURE__ */ jsx(TreeItemBox, { $level: tree.level, as: "div", "data-ui": "TreeItem__box", children: content2 }), $[92] = content2, $[93] = tree.level, $[94] = t22) : t22 = $[94];
|
|
1902
1894
|
let t23;
|
|
1903
|
-
$[
|
|
1895
|
+
$[95] !== children || $[96] !== expanded ? (t23 = children && /* @__PURE__ */ jsx(TreeGroup, { expanded, children }), $[95] = children, $[96] = expanded, $[97] = t23) : t23 = $[97];
|
|
1904
1896
|
let t24;
|
|
1905
|
-
$[
|
|
1897
|
+
$[98] !== contextValue || $[99] !== t23 ? (t24 = /* @__PURE__ */ jsx(TreeContext.Provider, { value: contextValue, children: t23 }), $[98] = contextValue, $[99] = t23, $[100] = t24) : t24 = $[100];
|
|
1906
1898
|
let t25;
|
|
1907
|
-
$[
|
|
1908
|
-
|
|
1909
|
-
|
|
1910
|
-
|
|
1911
|
-
t25
|
|
1912
|
-
] }), $[102] = expanded, $[103] = handleClick, $[104] = handleKeyDown, $[105] = id, $[106] = itemKey, $[107] = restProps, $[108] = t22, $[109] = t23, $[110] = t25, $[111] = tabIndex, $[112] = t26) : t26 = $[112], t26;
|
|
1899
|
+
return $[101] !== expanded || $[102] !== handleClick || $[103] !== handleKeyDown || $[104] !== id || $[105] !== itemKey || $[106] !== restProps || $[107] !== t21 || $[108] !== t22 || $[109] !== t24 || $[110] !== tabIndex ? (t25 = /* @__PURE__ */ jsxs(StyledTreeItem, { "data-selected": t21, "data-ui": "TreeItem", "data-tree-id": id, "data-tree-key": itemKey, ...restProps, "aria-expanded": expanded, onClick: handleClick, onKeyDown: handleKeyDown, ref: setRootElement, role: "treeitem", tabIndex, children: [
|
|
1900
|
+
t22,
|
|
1901
|
+
t24
|
|
1902
|
+
] }), $[101] = expanded, $[102] = handleClick, $[103] = handleKeyDown, $[104] = id, $[105] = itemKey, $[106] = restProps, $[107] = t21, $[108] = t22, $[109] = t24, $[110] = tabIndex, $[111] = t25) : t25 = $[111], t25;
|
|
1913
1903
|
}
|
|
1914
1904
|
TreeItem.displayName = "TreeItem";
|
|
1915
1905
|
export {
|