@apia/table 4.0.14 → 4.0.16

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 CHANGED
@@ -3,8 +3,8 @@ import React, { useMemo, useRef, useState, memo, useEffect, useCallback, createR
3
3
  import { Box, getVariant, Input, Select, useBreakpointIndex, Label, Link, Spinner } from '@apia/theme';
4
4
  import { useMount, useUpdateEffect, useUnmount, useThrottleFn } from 'ahooks';
5
5
  import uniqueId from 'lodash-es/uniqueId';
6
- import { injectReducers, createSlice, shallowEqual as shallowEqual$1 } from '@apia/store';
7
- import { addBoundary, useLatest, useUpdateEffect as useUpdateEffect$1, getSpecificParent, isChild, autoDisconnectMutationObserver, getFocusSelector, cantFocusSelector, globalFocus, scrollParentIntoElement, customEvents, persistentStorage, EventEmitter, debugDispatcher, usePrevious, useIntermediateValue, getLabel, formatMessage, getDateFormat, noNaN, getIndex, downloadUrl, arrayOrArray, useMount as useMount$1 } from '@apia/util';
6
+ import { createSlice, injectReducers, shallowEqual as shallowEqual$1 } from '@apia/store';
7
+ import { addBoundary, useLatest, useUpdateEffect as useUpdateEffect$1, getSpecificParent, isChild, autoDisconnectMutationObserver, getFocusSelector, cantFocusSelector, globalFocus, scrollParentIntoElement, customEvents, debugDispatcher, persistentStorage, EventEmitter, usePrevious, useIntermediateValue, getLabel, getDateFormat, formatMessage, noNaN, getIndex, downloadUrl, arrayOrArray, useMount as useMount$1 } from '@apia/util';
8
8
  import { shallowEqual } from 'react-redux';
9
9
  import { useOtherTagButton, AutoEllipsis, ApiaFilter, IconButton, AccordionItem, Accordion, RequiredMark, ApiaUtil, SimpleButton } from '@apia/components';
10
10
  import { Icon } from '@apia/icons';
@@ -161,6 +161,7 @@ function willHandleKey(ev, state) {
161
161
  }
162
162
  function handleKey(state, { ev }) {
163
163
  const {
164
+ altKey: isAltPressed,
164
165
  ctrlKey: isCtrlPressed,
165
166
  key,
166
167
  shiftKey: isShiftPressed
@@ -173,6 +174,7 @@ function handleKey(state, { ev }) {
173
174
  newFocusedRow,
174
175
  ...rest
175
176
  }) => setNewFocused(state, {
177
+ altKey: isAltPressed,
176
178
  ctrlKey: isCtrlPressed,
177
179
  shiftKey: isShiftPressed,
178
180
  newFocusedColumn,
@@ -343,6 +345,7 @@ const responsiveTableSlice = createSlice({
343
345
  state[tableName] = { ...state[tableName], ...rest };
344
346
  if (handleFocus !== false) {
345
347
  setNewFocused(state[tableName], {
348
+ altKey: false,
346
349
  ctrlKey: false,
347
350
  shiftKey: false,
348
351
  shouldSelectNewFocused: rest.isFocused ?? state[tableName].isFocused
@@ -376,6 +379,7 @@ const responsiveTableSlice = createSlice({
376
379
  ...payload.newRows
377
380
  );
378
381
  setNewFocused(state[payload.tableName], {
382
+ altKey: false,
379
383
  ctrlKey: false,
380
384
  shiftKey: false,
381
385
  shouldSelectNewFocused: true,
@@ -391,6 +395,7 @@ const responsiveTableSlice = createSlice({
391
395
  (_, index) => !payload.rowIndices.includes(index)
392
396
  );
393
397
  setNewFocused(state[payload.tableName], {
398
+ altKey: false,
394
399
  ctrlKey: false,
395
400
  shiftKey: false,
396
401
  shouldSelectNewFocused: true,
@@ -2589,7 +2594,7 @@ const Responsive = React.memo(NoMemoResponsive);
2589
2594
  var __defProp$1 = Object.defineProperty;
2590
2595
  var __defNormalProp$1 = (obj, key, value) => key in obj ? __defProp$1(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2591
2596
  var __publicField$1 = (obj, key, value) => {
2592
- __defNormalProp$1(obj, key + "" , value);
2597
+ __defNormalProp$1(obj, typeof key !== "symbol" ? key + "" : key, value);
2593
2598
  return value;
2594
2599
  };
2595
2600
  const maximizationPersist = {
@@ -3340,7 +3345,7 @@ var __privateAdd = (obj, member, value) => {
3340
3345
  };
3341
3346
  var __privateSet = (obj, member, value, setter) => {
3342
3347
  __accessCheck(obj, member, "write to private field");
3343
- member.set(obj, value);
3348
+ setter ? setter.call(obj, value) : member.set(obj, value);
3344
3349
  return value;
3345
3350
  };
3346
3351
  var _unsubscribe;