@economic/taco 1.14.2 → 1.15.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/AlertDialog/components/Content.d.ts +1 -1
- package/dist/components/Button/Button.stories.d.ts +3 -0
- package/dist/components/Calendar/Calendar.d.ts +1 -1
- package/dist/components/Calendar/Calendar.stories.d.ts +1 -1
- package/dist/components/Datepicker/Datepicker.d.ts +1 -1
- package/dist/components/Datepicker/Datepicker.stories.d.ts +1 -1
- package/dist/components/Dialog/components/Content.d.ts +1 -1
- package/dist/components/Dialog/components/Drawer.d.ts +1 -1
- package/dist/components/IconButton/IconButton.d.ts +2 -2
- package/dist/components/IconButton/IconButton.stories.d.ts +4 -1
- package/dist/components/Listbox/Listbox.d.ts +2 -2
- package/dist/components/Listbox/Listbox.stories.d.ts +1 -1
- package/dist/components/Listbox/ScrollableList.d.ts +1 -1
- package/dist/components/Menu/components/Checkbox.d.ts +1 -1
- package/dist/components/Menu/components/Content.d.ts +1 -1
- package/dist/components/Menu/components/Item.d.ts +1 -1
- package/dist/components/Menu/components/Link.d.ts +1 -1
- package/dist/components/Menu/components/Trigger.d.ts +1 -1
- package/dist/components/Popover/Popover.d.ts +6 -0
- package/dist/components/Popover/Popover.stories.d.ts +17 -2
- package/dist/components/SearchInput/SearchInput.d.ts +1 -1
- package/dist/components/SearchInput/SearchInput.stories.d.ts +1 -1
- package/dist/components/Select/Select.d.ts +1 -1
- package/dist/components/Select/Select.stories.d.ts +1 -1
- package/dist/components/Select2/components/Option.d.ts +1 -1
- package/dist/components/Select2/components/Trigger.d.ts +1 -1
- package/dist/components/Tag/Tag.d.ts +1 -1
- package/dist/esm/packages/taco/src/components/Card/Card.js +1 -1
- package/dist/esm/packages/taco/src/components/Combobox/useCombobox.js +2 -2
- package/dist/esm/packages/taco/src/components/Combobox/useCombobox.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Datepicker/useDatepicker.js +2 -2
- package/dist/esm/packages/taco/src/components/Datepicker/useDatepicker.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Dialog/components/Content.js +2 -2
- package/dist/esm/packages/taco/src/components/Dialog/components/Content.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Input/Input.js +2 -2
- package/dist/esm/packages/taco/src/components/Input/Input.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Listbox/ScrollableList.js +2 -2
- package/dist/esm/packages/taco/src/components/Listbox/ScrollableList.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Listbox/useListbox.js +2 -2
- package/dist/esm/packages/taco/src/components/Listbox/useListbox.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Listbox/useMultiListbox.js +2 -2
- package/dist/esm/packages/taco/src/components/Listbox/useMultiListbox.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Menu/components/Content.js +2 -2
- package/dist/esm/packages/taco/src/components/Menu/components/Content.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Menu/components/Trigger.js +2 -2
- package/dist/esm/packages/taco/src/components/Menu/components/Trigger.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Navigation/Navigation.js +2 -2
- package/dist/esm/packages/taco/src/components/Navigation/Navigation.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Popover/Popover.js +7 -1
- package/dist/esm/packages/taco/src/components/Popover/Popover.js.map +1 -1
- package/dist/esm/packages/taco/src/components/SearchInput/SearchInput.js +1 -1
- package/dist/esm/packages/taco/src/components/Select/useSelect.js +2 -2
- package/dist/esm/packages/taco/src/components/Select/useSelect.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Select2/Select2.js +1 -1
- package/dist/esm/packages/taco/src/components/Table/components/BaseTable.js +2 -2
- package/dist/esm/packages/taco/src/components/Table/components/BaseTable.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Table/components/Table.js +2 -2
- package/dist/esm/packages/taco/src/components/Table/components/Table.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Table/components/WindowedTable.js +2 -2
- package/dist/esm/packages/taco/src/components/Table/components/WindowedTable.js.map +1 -1
- package/dist/esm/packages/taco/src/components/Table/hooks/useTable.js +1 -2
- package/dist/esm/packages/taco/src/components/Table/hooks/useTable.js.map +1 -1
- package/dist/esm/packages/taco/src/index.js +1 -1
- package/dist/esm/packages/taco/src/primitives/Collection/components/Root.js +39 -50
- package/dist/esm/packages/taco/src/primitives/Collection/components/Root.js.map +1 -1
- package/dist/esm/packages/taco/src/primitives/Listbox2/components/Root.js +1 -1
- package/dist/esm/packages/taco/src/primitives/Listbox2/components/Root.js.map +1 -1
- package/dist/primitives/Collection/components/Root.d.ts +2 -2
- package/dist/taco.cjs.development.js +65 -85
- package/dist/taco.cjs.development.js.map +1 -1
- package/dist/taco.cjs.production.min.js +1 -1
- package/dist/taco.cjs.production.min.js.map +1 -1
- package/dist/utils/storyutils.d.ts +2 -1
- package/package.json +23 -24
- package/types.json +2 -2
- package/dist/esm/packages/taco/src/utils/hooks/useProxiedRef.js +0 -18
- package/dist/esm/packages/taco/src/utils/hooks/useProxiedRef.js.map +0 -1
- package/dist/utils/hooks/useProxiedRef.d.ts +0 -2
|
@@ -4194,9 +4194,10 @@ const Checkbox = /*#__PURE__*/React.forwardRef(function Checkbox(props, ref) {
|
|
|
4194
4194
|
return element;
|
|
4195
4195
|
});
|
|
4196
4196
|
|
|
4197
|
-
|
|
4198
|
-
|
|
4199
|
-
|
|
4197
|
+
// merges an external ref (optional) with an internal ref (required)
|
|
4198
|
+
const useMergedRef = ref => {
|
|
4199
|
+
const internalRef = React__default.useRef(null);
|
|
4200
|
+
React__default.useEffect(() => {
|
|
4200
4201
|
if (ref) {
|
|
4201
4202
|
if (typeof ref === 'function') {
|
|
4202
4203
|
ref(internalRef.current);
|
|
@@ -4239,7 +4240,7 @@ const Input = /*#__PURE__*/React.forwardRef(function Input(props, ref) {
|
|
|
4239
4240
|
autoFocus,
|
|
4240
4241
|
...otherProps
|
|
4241
4242
|
} = props;
|
|
4242
|
-
const inputRef =
|
|
4243
|
+
const inputRef = useMergedRef(ref);
|
|
4243
4244
|
const hasContainer = button || icon;
|
|
4244
4245
|
const className = cn(getInputClasses(props), 'min-h-[theme(spacing.8)] pointer-events-all', {
|
|
4245
4246
|
'pr-8': !!hasContainer
|
|
@@ -4393,7 +4394,7 @@ const ScrollableList = /*#__PURE__*/React.forwardRef(function ScrollableList(pro
|
|
|
4393
4394
|
allOptionsSelected = false,
|
|
4394
4395
|
...otherProps
|
|
4395
4396
|
} = props;
|
|
4396
|
-
const listRef =
|
|
4397
|
+
const listRef = useMergedRef(ref);
|
|
4397
4398
|
const itemRefs = React.useMemo(() => data.map(() => /*#__PURE__*/React.createRef()), [data]);
|
|
4398
4399
|
const {
|
|
4399
4400
|
texts
|
|
@@ -4692,7 +4693,7 @@ const useCombobox = ({
|
|
|
4692
4693
|
value,
|
|
4693
4694
|
...props
|
|
4694
4695
|
}, ref) => {
|
|
4695
|
-
const inputRef =
|
|
4696
|
+
const inputRef = useMergedRef(ref);
|
|
4696
4697
|
const buttonRef = React.useRef(null);
|
|
4697
4698
|
const listRef = React.useRef(null);
|
|
4698
4699
|
const [open, setOpen] = React.useState(false);
|
|
@@ -5101,7 +5102,7 @@ const useDatepicker = ({
|
|
|
5101
5102
|
value,
|
|
5102
5103
|
...props
|
|
5103
5104
|
}, ref) => {
|
|
5104
|
-
const inputRef =
|
|
5105
|
+
const inputRef = useMergedRef(ref);
|
|
5105
5106
|
const {
|
|
5106
5107
|
formatting
|
|
5107
5108
|
} = useLocalization();
|
|
@@ -5257,7 +5258,10 @@ const Close$1 = /*#__PURE__*/React.forwardRef((props, ref) => /*#__PURE__*/React
|
|
|
5257
5258
|
const Popover = /*#__PURE__*/React.forwardRef(function Popover(props, ref) {
|
|
5258
5259
|
const {
|
|
5259
5260
|
children,
|
|
5261
|
+
defaultOpen,
|
|
5260
5262
|
modal = false,
|
|
5263
|
+
open,
|
|
5264
|
+
onChange,
|
|
5261
5265
|
trigger,
|
|
5262
5266
|
...otherProps
|
|
5263
5267
|
} = props;
|
|
@@ -5268,7 +5272,10 @@ const Popover = /*#__PURE__*/React.forwardRef(function Popover(props, ref) {
|
|
|
5268
5272
|
return /*#__PURE__*/React.createElement(PopoverContext.Provider, {
|
|
5269
5273
|
value: context
|
|
5270
5274
|
}, /*#__PURE__*/React.createElement(PopoverPrimitive.Root, {
|
|
5271
|
-
|
|
5275
|
+
defaultOpen: defaultOpen,
|
|
5276
|
+
modal: modal,
|
|
5277
|
+
open: open,
|
|
5278
|
+
onOpenChange: onChange
|
|
5272
5279
|
}, trigger && /*#__PURE__*/React.createElement(Trigger$2, null, trigger), children));
|
|
5273
5280
|
});
|
|
5274
5281
|
Popover.Trigger = Trigger$2;
|
|
@@ -5443,7 +5450,7 @@ const RenderPropWrapper$1 = /*#__PURE__*/React.forwardRef(function RenderPropWra
|
|
|
5443
5450
|
});
|
|
5444
5451
|
const Content$4 = /*#__PURE__*/React.forwardRef(function DialogContent(props, ref) {
|
|
5445
5452
|
const dialog = useCurrentDialog();
|
|
5446
|
-
const internalRef =
|
|
5453
|
+
const internalRef = useMergedRef(ref);
|
|
5447
5454
|
const {
|
|
5448
5455
|
position,
|
|
5449
5456
|
handleProps: dragHandleProps
|
|
@@ -5890,7 +5897,7 @@ const useListbox = ({
|
|
|
5890
5897
|
value: emptyValue
|
|
5891
5898
|
}, ...externalData] : externalData);
|
|
5892
5899
|
const id = React.useMemo(() => nativeId || uuid.v4(), [nativeId]);
|
|
5893
|
-
const inputRef =
|
|
5900
|
+
const inputRef = useMergedRef(ref);
|
|
5894
5901
|
const currentIndex = value !== undefined ? getIndexFromValue(data, value) : undefined;
|
|
5895
5902
|
const {
|
|
5896
5903
|
getNextIndex
|
|
@@ -6011,7 +6018,7 @@ const useMultiListbox = ({
|
|
|
6011
6018
|
texts
|
|
6012
6019
|
} = useLocalization();
|
|
6013
6020
|
const id = React.useMemo(() => nativeId || uuid.v4(), [nativeId]);
|
|
6014
|
-
const inputRef =
|
|
6021
|
+
const inputRef = useMergedRef(ref);
|
|
6015
6022
|
const data = React.useMemo(() => {
|
|
6016
6023
|
return [{
|
|
6017
6024
|
text: texts.listbox.allOption,
|
|
@@ -6214,7 +6221,7 @@ const useCurrentMenu = () => {
|
|
|
6214
6221
|
};
|
|
6215
6222
|
|
|
6216
6223
|
const Content$7 = /*#__PURE__*/React.forwardRef(function MenuContent(props, ref) {
|
|
6217
|
-
const internalRef =
|
|
6224
|
+
const internalRef = useMergedRef(ref);
|
|
6218
6225
|
const menu = useCurrentMenu();
|
|
6219
6226
|
const {
|
|
6220
6227
|
children,
|
|
@@ -6347,7 +6354,7 @@ const Link = /*#__PURE__*/React.forwardRef(function MenuLink(props, ref) {
|
|
|
6347
6354
|
|
|
6348
6355
|
const Trigger$5 = /*#__PURE__*/React.forwardRef(function MenuTrigger(props, ref) {
|
|
6349
6356
|
const menu = useCurrentMenu();
|
|
6350
|
-
const internalRef =
|
|
6357
|
+
const internalRef = useMergedRef(ref);
|
|
6351
6358
|
React.useEffect(() => {
|
|
6352
6359
|
if (internalRef.current) {
|
|
6353
6360
|
menu === null || menu === void 0 ? void 0 : menu.setMinWidth(internalRef.current.getBoundingClientRect().width);
|
|
@@ -6685,7 +6692,7 @@ const Item$2 = /*#__PURE__*/React__default.forwardRef(function Item(props, ref)
|
|
|
6685
6692
|
role,
|
|
6686
6693
|
...otherProps
|
|
6687
6694
|
} = props;
|
|
6688
|
-
const proxyRef =
|
|
6695
|
+
const proxyRef = useMergedRef(ref);
|
|
6689
6696
|
const [isDraggedOver, dropTargetProps] = useDropTarget(onDrop);
|
|
6690
6697
|
const isTreeitem = role === 'treeitem';
|
|
6691
6698
|
const className = cn('yt-navigation__item cursor-pointer', {
|
|
@@ -6844,7 +6851,7 @@ const useSelect = ({
|
|
|
6844
6851
|
texts
|
|
6845
6852
|
} = useLocalization();
|
|
6846
6853
|
const flattenedData = useFlattenedData(data);
|
|
6847
|
-
const listboxInputRef =
|
|
6854
|
+
const listboxInputRef = useMergedRef(ref);
|
|
6848
6855
|
const [open, setOpen] = React.useState(false);
|
|
6849
6856
|
const id = React.useMemo(() => nativeId || `select_${uuid.v4()}`, [nativeId]);
|
|
6850
6857
|
const inputRef = React.useRef(null);
|
|
@@ -7260,21 +7267,6 @@ const useId = nativeId => {
|
|
|
7260
7267
|
return React__default.useMemo(() => nativeId !== null && nativeId !== void 0 ? nativeId : uuid.v4(), []);
|
|
7261
7268
|
};
|
|
7262
7269
|
|
|
7263
|
-
// merges an external ref (optional) with an internal ref (required)
|
|
7264
|
-
const useMergedRef = ref => {
|
|
7265
|
-
const internalRef = React__default.useRef(null);
|
|
7266
|
-
React__default.useEffect(() => {
|
|
7267
|
-
if (ref) {
|
|
7268
|
-
if (typeof ref === 'function') {
|
|
7269
|
-
ref(internalRef.current);
|
|
7270
|
-
} else {
|
|
7271
|
-
ref.current = internalRef.current;
|
|
7272
|
-
}
|
|
7273
|
-
}
|
|
7274
|
-
}, [ref]);
|
|
7275
|
-
return internalRef;
|
|
7276
|
-
};
|
|
7277
|
-
|
|
7278
7270
|
const isAriaSelectionKey = event => {
|
|
7279
7271
|
if (event.key === 'Enter' || event.key === ' ' || event.key === 'Tab') {
|
|
7280
7272
|
return true;
|
|
@@ -7288,98 +7280,87 @@ const isAriaDirectionKey = event => {
|
|
|
7288
7280
|
return false;
|
|
7289
7281
|
};
|
|
7290
7282
|
|
|
7291
|
-
const
|
|
7283
|
+
const getOptionsFromCollection = (collection, selector) => collection.querySelectorAll(selector);
|
|
7292
7284
|
// we use javascript to set attributes (rather than cloning children and adding them)
|
|
7293
7285
|
// so that we can support nesting (e.g. groups) - child elements that aren't options.
|
|
7294
7286
|
// without doing this we would have to unwrap and flatten all groups
|
|
7295
7287
|
const Root = /*#__PURE__*/React__default.forwardRef(function CollectionRoot(props, ref) {
|
|
7296
7288
|
const {
|
|
7297
|
-
|
|
7289
|
+
querySelector,
|
|
7298
7290
|
tabIndex = 0,
|
|
7299
7291
|
...otherProps
|
|
7300
7292
|
} = props;
|
|
7301
7293
|
const internalRef = useMergedRef(ref);
|
|
7302
7294
|
const [activeIndex, setActiveIndex] = React__default.useState();
|
|
7303
|
-
const
|
|
7295
|
+
const lastLengthRef = React__default.useRef(0);
|
|
7296
|
+
const setActiveOption = (index, collection, option) => {
|
|
7304
7297
|
var _collection$querySele;
|
|
7305
7298
|
(_collection$querySele = collection.querySelector(`[aria-current]`)) === null || _collection$querySele === void 0 ? void 0 : _collection$querySele.removeAttribute('aria-current');
|
|
7306
|
-
|
|
7307
|
-
|
|
7308
|
-
|
|
7309
|
-
|
|
7310
|
-
|
|
7311
|
-
option.scrollIntoView({
|
|
7312
|
-
block: 'nearest'
|
|
7313
|
-
});
|
|
7314
|
-
}
|
|
7315
|
-
}
|
|
7299
|
+
option.setAttribute('aria-current', 'true');
|
|
7300
|
+
option.scrollIntoView({
|
|
7301
|
+
block: 'nearest'
|
|
7302
|
+
});
|
|
7303
|
+
setActiveIndex(index);
|
|
7316
7304
|
};
|
|
7317
7305
|
const setActiveIndexByElement = React__default.useCallback(option => {
|
|
7318
7306
|
if (internalRef.current) {
|
|
7319
|
-
if (option.matches(
|
|
7320
|
-
const options =
|
|
7307
|
+
if (option.matches(querySelector)) {
|
|
7308
|
+
const options = getOptionsFromCollection(internalRef.current, querySelector);
|
|
7321
7309
|
const nextActiveIndex = Array.from(options).indexOf(option);
|
|
7322
7310
|
if (nextActiveIndex > -1) {
|
|
7323
|
-
|
|
7311
|
+
setActiveOption(nextActiveIndex, internalRef.current, option);
|
|
7324
7312
|
}
|
|
7325
7313
|
}
|
|
7326
7314
|
}
|
|
7327
|
-
}, [internalRef.current]);
|
|
7315
|
+
}, [internalRef.current, querySelector]);
|
|
7328
7316
|
React__default.useEffect(() => {
|
|
7329
7317
|
if (internalRef.current) {
|
|
7330
7318
|
internalRef.current.setActiveIndex = setActiveIndexByElement;
|
|
7331
7319
|
}
|
|
7332
7320
|
}, [internalRef.current]);
|
|
7333
|
-
// set/remove appropriate aria-current attributes
|
|
7334
|
-
// we do this in a hook because we expose setActiveIndex on the ref
|
|
7335
|
-
React__default.useEffect(() => {
|
|
7336
|
-
if (internalRef.current) {
|
|
7337
|
-
toggleCurrent(internalRef.current);
|
|
7338
|
-
}
|
|
7339
|
-
}, [activeIndex]);
|
|
7340
|
-
// set the initial active index on mount
|
|
7341
7321
|
React__default.useEffect(() => {
|
|
7342
7322
|
if (internalRef.current) {
|
|
7343
|
-
const
|
|
7344
|
-
if (
|
|
7345
|
-
const
|
|
7346
|
-
if (
|
|
7347
|
-
|
|
7348
|
-
|
|
7349
|
-
|
|
7323
|
+
const options = getOptionsFromCollection(internalRef.current, querySelector);
|
|
7324
|
+
if (options.length && options.length !== lastLengthRef.current) {
|
|
7325
|
+
const selected = internalRef.current.querySelectorAll(`[aria-selected]`);
|
|
7326
|
+
if (selected.length === 1) {
|
|
7327
|
+
if (options) {
|
|
7328
|
+
const firstSelected = selected.item(0);
|
|
7329
|
+
const selectedIndex = Array.from(options).indexOf(firstSelected);
|
|
7330
|
+
if (selectedIndex > -1) {
|
|
7331
|
+
setActiveOption(selectedIndex, internalRef.current, firstSelected);
|
|
7332
|
+
}
|
|
7350
7333
|
}
|
|
7334
|
+
} else {
|
|
7335
|
+
// multiple selected or none selected should go to 0
|
|
7336
|
+
setActiveOption(0, internalRef.current, options.item(0));
|
|
7351
7337
|
}
|
|
7352
|
-
} else {
|
|
7353
|
-
// multiple selected or none selected should go to 0
|
|
7354
|
-
setActiveIndex(0);
|
|
7355
|
-
}
|
|
7356
|
-
}
|
|
7357
|
-
}, []);
|
|
7358
|
-
// if children length changes, make sure we still have a valid active index (e.g. searching/filtering or adding a new item)
|
|
7359
|
-
React__default.useEffect(() => {
|
|
7360
|
-
if (internalRef.current) {
|
|
7361
|
-
// make sure index and dom are synced
|
|
7362
|
-
toggleCurrent(internalRef.current);
|
|
7363
|
-
if (activeIndex !== undefined && activeIndex > React__default.Children.count(props.children)) {
|
|
7364
|
-
setActiveIndex(0);
|
|
7365
7338
|
}
|
|
7339
|
+
lastLengthRef.current = options.length;
|
|
7366
7340
|
}
|
|
7367
7341
|
}, [props.children]);
|
|
7368
7342
|
const handleClick = event => {
|
|
7369
|
-
|
|
7343
|
+
const option = event.target;
|
|
7344
|
+
if (option.matches(querySelector)) {
|
|
7345
|
+
const options = getOptionsFromCollection(event.currentTarget, querySelector);
|
|
7346
|
+
const nextActiveIndex = Array.from(options).indexOf(option);
|
|
7347
|
+
if (nextActiveIndex > -1) {
|
|
7348
|
+
setActiveOption(nextActiveIndex, event.currentTarget, option);
|
|
7349
|
+
}
|
|
7350
|
+
}
|
|
7370
7351
|
};
|
|
7371
7352
|
const handleKeyDown = event => {
|
|
7372
7353
|
// this stops the event dispatched to the option rebounding back and starting an infinite loop
|
|
7373
7354
|
if (event.target !== event.currentTarget) {
|
|
7374
7355
|
return;
|
|
7375
7356
|
}
|
|
7376
|
-
const options =
|
|
7357
|
+
const options = getOptionsFromCollection(event.currentTarget, querySelector);
|
|
7377
7358
|
if (options) {
|
|
7378
7359
|
if (isAriaDirectionKey(event)) {
|
|
7379
7360
|
const nextActiveIndex = getNextEnabledItem$1(event, options, activeIndex);
|
|
7380
7361
|
if (nextActiveIndex !== undefined && nextActiveIndex !== activeIndex) {
|
|
7381
7362
|
event.preventDefault();
|
|
7382
|
-
|
|
7363
|
+
setActiveOption(nextActiveIndex, event.currentTarget, options.item(nextActiveIndex));
|
|
7383
7364
|
}
|
|
7384
7365
|
} else if (activeIndex !== undefined) {
|
|
7385
7366
|
// forward events onto the underlying option - this lets consumers place onKeyDown handlers on their own components
|
|
@@ -7391,7 +7372,7 @@ const Root = /*#__PURE__*/React__default.forwardRef(function CollectionRoot(prop
|
|
|
7391
7372
|
onClick: handleClick,
|
|
7392
7373
|
onKeyDown: handleKeyDown,
|
|
7393
7374
|
ref: internalRef,
|
|
7394
|
-
tabIndex: tabIndex
|
|
7375
|
+
tabIndex: tabIndex
|
|
7395
7376
|
}));
|
|
7396
7377
|
});
|
|
7397
7378
|
const getNextIndexFromKeycode = (event, length, activeIndex) => {
|
|
@@ -7471,7 +7452,7 @@ const Root$1 = /*#__PURE__*/React__default.forwardRef(function Listbox2(props, r
|
|
|
7471
7452
|
id: id,
|
|
7472
7453
|
ref: ref,
|
|
7473
7454
|
role: "listbox",
|
|
7474
|
-
|
|
7455
|
+
querySelector: customSelector ? `${DEFAULT_SELECTOR}, ${customSelector}` : DEFAULT_SELECTOR
|
|
7475
7456
|
}), children)));
|
|
7476
7457
|
});
|
|
7477
7458
|
const createListboxValueSetter = (multiple, setValue) => nextValue => {
|
|
@@ -9486,8 +9467,7 @@ const useTable = (props, ref) => {
|
|
|
9486
9467
|
columns,
|
|
9487
9468
|
data,
|
|
9488
9469
|
initialState: {
|
|
9489
|
-
//
|
|
9490
|
-
// @ts-ignore: not sure how to type this correctly right now
|
|
9470
|
+
// @ts-expect-error: not sure how to type this correctly right now
|
|
9491
9471
|
sortBy: getInternalSortRules(sortRules) || defaultSortRules,
|
|
9492
9472
|
pageSize: !disablePagination ? pageSize : undefined,
|
|
9493
9473
|
pageIndex: !disablePagination ? pageIndex : undefined
|
|
@@ -9691,7 +9671,7 @@ const Column = ({
|
|
|
9691
9671
|
|
|
9692
9672
|
const DefaultEmptyState = () => null;
|
|
9693
9673
|
const BaseTable = /*#__PURE__*/React__default.forwardRef(function BaseTable(props, ref) {
|
|
9694
|
-
const tableRef =
|
|
9674
|
+
const tableRef = useMergedRef(ref);
|
|
9695
9675
|
const {
|
|
9696
9676
|
autoFocus,
|
|
9697
9677
|
children,
|
|
@@ -9735,7 +9715,7 @@ const Table = /*#__PURE__*/React__default.forwardRef(function Table(props, ref)
|
|
|
9735
9715
|
emptyStateRenderer = DefaultEmptyState,
|
|
9736
9716
|
...otherProps
|
|
9737
9717
|
} = props;
|
|
9738
|
-
const tableRef =
|
|
9718
|
+
const tableRef = useMergedRef(ref);
|
|
9739
9719
|
const {
|
|
9740
9720
|
rowProps,
|
|
9741
9721
|
tableProps,
|
|
@@ -9837,7 +9817,7 @@ const getAverageRowHeight = (rowHeights = {}) => {
|
|
|
9837
9817
|
return estimatedHeight / keys.length;
|
|
9838
9818
|
};
|
|
9839
9819
|
const WindowedTable = /*#__PURE__*/React__default.forwardRef(function WindowedTable(props, ref) {
|
|
9840
|
-
const tableRef =
|
|
9820
|
+
const tableRef = useMergedRef(ref);
|
|
9841
9821
|
const {
|
|
9842
9822
|
emptyStateRenderer = DefaultEmptyState,
|
|
9843
9823
|
length,
|