@timmbr/ui 1.13.1 → 1.14.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/AttributeValueField/AttributeValueField.d.ts +20 -0
- package/dist/components/AttributeValueField/AttributeValueField.d.ts.map +1 -0
- package/dist/components/AttributeValueField/AttributeValueField.js +130 -0
- package/dist/components/AttributeValueField/index.d.ts +2 -0
- package/dist/components/AttributeValueField/index.d.ts.map +1 -0
- package/dist/components/Checkbox/Checkbox.js +1 -1
- package/dist/components/DataTable/DataTable.d.ts +10 -0
- package/dist/components/DataTable/DataTable.d.ts.map +1 -0
- package/dist/components/DataTable/DataTable.js +177 -0
- package/dist/components/DataTable/DataTable.types.d.ts +42 -0
- package/dist/components/DataTable/DataTable.types.d.ts.map +1 -0
- package/dist/components/DataTable/index.d.ts +3 -0
- package/dist/components/DataTable/index.d.ts.map +1 -0
- package/dist/components/Dialog/Dialog.js +1 -1
- package/dist/components/Drawer/Drawer.js +1 -1
- package/dist/components/FormField/FormField.js +1 -1
- package/dist/components/ImageUpload/ImageUpload.js +4 -4
- package/dist/components/ImageUpload/subcomponents/ImageUploadDropzone.js +3 -3
- package/dist/components/ImageUpload/subcomponents/ImageUploadModal.js +1 -1
- package/dist/components/Input/Input.js +3 -3
- package/dist/components/Radio/Radio.js +1 -1
- package/dist/components/Select/Select.js +2 -2
- package/dist/components/Switch/Switch.js +1 -1
- package/dist/components/Table/Table.d.ts.map +1 -1
- package/dist/components/Table/Table.js +14 -7
- package/dist/components/Table/Table.styles.js +2 -2
- package/dist/components/Table/Table.types.d.ts +1 -0
- package/dist/components/Table/Table.types.d.ts.map +1 -1
- package/dist/components/Table/TablePagination.js +3 -3
- package/dist/components/Textarea/Textarea.js +2 -2
- package/dist/components/Toast/Toast.js +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -0
- package/dist/node_modules/.pnpm/@tanstack_react-table@8.21._59ea1c5c486c125464e3b5e1938c78d1/node_modules/@tanstack/react-table/build/lib/index.js +74 -0
- package/dist/node_modules/.pnpm/@tanstack_table-core@8.21.3/node_modules/@tanstack/table-core/build/lib/index.js +3027 -0
- package/package.json +5 -3
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { cva } from 'class-variance-authority';
|
|
2
2
|
|
|
3
3
|
const tableContainerVariants = cva(
|
|
4
|
-
"relative w-full overflow-auto rounded-lg font-sans text-foreground",
|
|
4
|
+
"relative w-full overflow-auto rounded-lg font-sans text-foreground scroll-smooth [scrollbar-width:thin]",
|
|
5
5
|
{
|
|
6
6
|
variants: {
|
|
7
7
|
bordered: {
|
|
@@ -38,7 +38,7 @@ const tableRowVariants = cva(
|
|
|
38
38
|
"border-b border-grey-200 dark:border-grey-800 transition-colors data-[state=selected]:bg-primary/5 hover:bg-grey-50/80 dark:hover:bg-grey-900/60"
|
|
39
39
|
);
|
|
40
40
|
const tableHeadVariants = cva(
|
|
41
|
-
"h-10 text-left align-middle font-semibold text-muted-foreground text-body-3 uppercase tracking-wider select-none bg-
|
|
41
|
+
"sticky top-0 z-20 h-10 text-left align-middle font-semibold text-muted-foreground text-body-3 uppercase tracking-wider select-none bg-card border-b border-border [&:has([role=checkbox])]:pr-0"
|
|
42
42
|
);
|
|
43
43
|
const tableCellVariants = cva(
|
|
44
44
|
"align-middle [&:has([role=checkbox])]:pr-0"
|
|
@@ -2,6 +2,7 @@ import type * as React from 'react';
|
|
|
2
2
|
import type { TableVariants } from './Table.styles';
|
|
3
3
|
export interface TableProps extends React.TableHTMLAttributes<HTMLTableElement>, TableVariants {
|
|
4
4
|
containerClassName?: string;
|
|
5
|
+
containerRef?: React.Ref<HTMLDivElement>;
|
|
5
6
|
}
|
|
6
7
|
export type TableHeaderProps = React.HTMLAttributes<HTMLTableSectionElement>;
|
|
7
8
|
export type TableBodyProps = React.HTMLAttributes<HTMLTableSectionElement>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Table.types.d.ts","sourceRoot":"","sources":["../../../src/components/Table/Table.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAC;AACpC,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAEpD,MAAM,WAAW,UACf,SAAQ,KAAK,CAAC,mBAAmB,CAAC,gBAAgB,CAAC,EACjD,aAAa;IACf,kBAAkB,CAAC,EAAE,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"Table.types.d.ts","sourceRoot":"","sources":["../../../src/components/Table/Table.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAC;AACpC,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAEpD,MAAM,WAAW,UACf,SAAQ,KAAK,CAAC,mBAAmB,CAAC,gBAAgB,CAAC,EACjD,aAAa;IACf,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,YAAY,CAAC,EAAE,KAAK,CAAC,GAAG,CAAC,cAAc,CAAC,CAAC;CAC1C;AAED,MAAM,MAAM,gBAAgB,GAAG,KAAK,CAAC,cAAc,CAAC,uBAAuB,CAAC,CAAC;AAE7E,MAAM,MAAM,cAAc,GAAG,KAAK,CAAC,cAAc,CAAC,uBAAuB,CAAC,CAAC;AAE3E,MAAM,MAAM,gBAAgB,GAAG,KAAK,CAAC,cAAc,CAAC,uBAAuB,CAAC,CAAC;AAE7E,MAAM,MAAM,aAAa,GAAG,KAAK,CAAC,cAAc,CAAC,mBAAmB,CAAC,CAAC;AAEtE,MAAM,MAAM,cAAc,GAAG,KAAK,CAAC,gBAAgB,CAAC,oBAAoB,CAAC,CAAC;AAE1E,MAAM,MAAM,cAAc,GAAG,KAAK,CAAC,gBAAgB,CAAC,oBAAoB,CAAC,CAAC;AAE1E,MAAM,MAAM,iBAAiB,GAAG,KAAK,CAAC,cAAc,CAAC,uBAAuB,CAAC,CAAC;AAE9E,MAAM,WAAW,oBAAqB,SAAQ,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;IAChF;;;OAGG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IACd;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB;;OAEG;IACH,eAAe,CAAC,EAAE,MAAM,EAAE,CAAC;IAC3B;;OAEG;IACH,YAAY,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IACtC;;OAEG;IACH,gBAAgB,CAAC,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,IAAI,CAAC;IAC9C;;OAEG;IACH,iBAAiB,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,KAAK,KAAK,CAAC,SAAS,CAAC;CACpF"}
|
|
@@ -56,7 +56,7 @@ const TablePagination = React.forwardRef(
|
|
|
56
56
|
"aria-label": "Rows per page",
|
|
57
57
|
value: pageSize,
|
|
58
58
|
onChange: (e) => onPageSizeChange(Number(e.target.value)),
|
|
59
|
-
className: "h-7 rounded-[2px] border border-
|
|
59
|
+
className: "h-7 rounded-[2px] border border-border bg-card px-2 py-0 text-body-3 font-medium text-foreground focus:outline-none focus:ring-1 focus:ring-primary",
|
|
60
60
|
children: pageSizeOptions.map((opt) => /* @__PURE__ */ jsx("option", { value: opt, children: opt }, opt))
|
|
61
61
|
}
|
|
62
62
|
)
|
|
@@ -70,7 +70,7 @@ const TablePagination = React.forwardRef(
|
|
|
70
70
|
"aria-label": "Previous page",
|
|
71
71
|
disabled: page <= 1,
|
|
72
72
|
onClick: () => onPageChange?.(page - 1),
|
|
73
|
-
className: "inline-flex items-center gap-1 h-8 px-2.5 rounded-[2px] border border-
|
|
73
|
+
className: "inline-flex items-center gap-1 h-8 px-2.5 rounded-[2px] border border-border bg-card text-body-3 font-medium text-foreground hover:bg-accent disabled:opacity-40 disabled:pointer-events-none transition-colors cursor-pointer",
|
|
74
74
|
children: [
|
|
75
75
|
/* @__PURE__ */ jsx(ChevronLeft, { className: "size-3.5" }),
|
|
76
76
|
/* @__PURE__ */ jsx("span", { children: "Previous" })
|
|
@@ -89,7 +89,7 @@ const TablePagination = React.forwardRef(
|
|
|
89
89
|
"aria-label": "Next page",
|
|
90
90
|
disabled: page >= computedTotalPages,
|
|
91
91
|
onClick: () => onPageChange?.(page + 1),
|
|
92
|
-
className: "inline-flex items-center gap-1 h-8 px-2.5 rounded-[2px] border border-
|
|
92
|
+
className: "inline-flex items-center gap-1 h-8 px-2.5 rounded-[2px] border border-border bg-card text-body-3 font-medium text-foreground hover:bg-accent disabled:opacity-40 disabled:pointer-events-none transition-colors cursor-pointer",
|
|
93
93
|
children: [
|
|
94
94
|
/* @__PURE__ */ jsx("span", { children: "Next" }),
|
|
95
95
|
/* @__PURE__ */ jsx(ChevronRight, { className: "size-3.5" })
|
|
@@ -146,7 +146,7 @@ const Textarea = React.forwardRef(
|
|
|
146
146
|
id: `${id}-desc`,
|
|
147
147
|
className: cn(
|
|
148
148
|
"text-body-3 mt-1 flex items-center gap-1.5 flex-1",
|
|
149
|
-
isError ? "text-destructive font-medium" : "text-muted"
|
|
149
|
+
isError ? "text-destructive font-medium" : "text-muted-foreground"
|
|
150
150
|
),
|
|
151
151
|
children: [
|
|
152
152
|
isError ? /* @__PURE__ */ jsx(AlertCircle, { className: "w-3.5 h-3.5 shrink-0", "aria-hidden": "true" }) : /* @__PURE__ */ jsx(Info, { className: "w-3.5 h-3.5 shrink-0", "aria-hidden": "true" }),
|
|
@@ -154,7 +154,7 @@ const Textarea = React.forwardRef(
|
|
|
154
154
|
]
|
|
155
155
|
}
|
|
156
156
|
) : /* @__PURE__ */ jsx("span", {}),
|
|
157
|
-
showCount && maxLength && /* @__PURE__ */ jsxs("span", { className: "text-caption-lg tabular-nums text-muted shrink-0 select-none", children: [
|
|
157
|
+
showCount && maxLength && /* @__PURE__ */ jsxs("span", { className: "text-caption-lg tabular-nums text-muted-foreground shrink-0 select-none", children: [
|
|
158
158
|
currentValue.length,
|
|
159
159
|
"/",
|
|
160
160
|
maxLength
|
|
@@ -90,7 +90,7 @@ const ToastClose = React.forwardRef(({ className, ...props }, ref) => /* @__PURE
|
|
|
90
90
|
ref,
|
|
91
91
|
"data-slot": "toast-close",
|
|
92
92
|
className: cn(
|
|
93
|
-
"absolute right-1 top-1 flex items-center justify-center min-w-[44px] min-h-[44px] rounded-sm text-muted hover:text-foreground opacity-70 hover:opacity-100 transition-opacity focus:outline-none focus-visible:ring-2 focus-visible:ring-ring cursor-pointer",
|
|
93
|
+
"absolute right-1 top-1 flex items-center justify-center min-w-[44px] min-h-[44px] rounded-sm text-muted-foreground hover:text-foreground opacity-70 hover:opacity-100 transition-opacity focus:outline-none focus-visible:ring-2 focus-visible:ring-ring cursor-pointer",
|
|
94
94
|
className
|
|
95
95
|
),
|
|
96
96
|
"toast-close": "",
|
package/dist/index.d.ts
CHANGED
|
@@ -19,6 +19,7 @@ export * from './components/FilterPanel';
|
|
|
19
19
|
export * from './components/FilterDrawer';
|
|
20
20
|
export * from './components/Label';
|
|
21
21
|
export * from './components/FormField';
|
|
22
|
+
export * from './components/AttributeValueField';
|
|
22
23
|
export * from './components/ImageUpload';
|
|
23
24
|
export * from './components/OtpInput';
|
|
24
25
|
export * from './components/AlertDialog';
|
|
@@ -55,6 +56,7 @@ export * from './components/Spinner';
|
|
|
55
56
|
export * from './components/Skeleton';
|
|
56
57
|
export * from './components/EmptyState';
|
|
57
58
|
export * from './components/Table';
|
|
59
|
+
export * from './components/DataTable';
|
|
58
60
|
export * from './components/Pagination';
|
|
59
61
|
export * from './components/DataList';
|
|
60
62
|
export * from './components/List';
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"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AAC1C,cAAc,2BAA2B,CAAC;AAC1C,cAAc,sBAAsB,CAAC;AACrC,cAAc,uBAAuB,CAAC;AACtC,cAAc,yBAAyB,CAAC;AAGxC,cAAc,oBAAoB,CAAC;AACnC,cAAc,wBAAwB,CAAC;AACvC,cAAc,yBAAyB,CAAC;AACxC,cAAc,uBAAuB,CAAC;AACtC,cAAc,mBAAmB,CAAC;AAClC,cAAc,mBAAmB,CAAC;AAClC,cAAc,0BAA0B,CAAC;AACzC,cAAc,qBAAqB,CAAC;AACpC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,yBAAyB,CAAC;AACxC,cAAc,6BAA6B,CAAC;AAC5C,cAAc,mBAAmB,CAAC;AAClC,cAAc,qBAAqB,CAAC;AACpC,cAAc,yBAAyB,CAAC;AACxC,cAAc,sBAAsB,CAAC;AACrC,cAAc,wBAAwB,CAAC;AACvC,cAAc,oBAAoB,CAAC;AACnC,cAAc,qBAAqB,CAAC;AACpC,cAAc,uBAAuB,CAAC;AACtC,cAAc,6BAA6B,CAAC;AAC5C,cAAc,uBAAuB,CAAC;AACtC,cAAc,0BAA0B,CAAC;AACzC,cAAc,4BAA4B,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -3,6 +3,7 @@ export { Accordion, AccordionContent, AccordionItem, AccordionTrigger } from './
|
|
|
3
3
|
export { Alert, AlertDescription, AlertTitle } from './components/Alert/Alert.js';
|
|
4
4
|
export { AlertDialog, AlertDialogAction, AlertDialogBody, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogMedia, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger } from './components/AlertDialog/AlertDialog.js';
|
|
5
5
|
export { AnimationProvider, useGlobalAnimation } from './providers/AnimationProvider.js';
|
|
6
|
+
export { AttributeValueField } from './components/AttributeValueField/AttributeValueField.js';
|
|
6
7
|
export { AuthModal } from './components/AuthModal/AuthModal.js';
|
|
7
8
|
export { AuthModalBanner } from './components/AuthModal/subcomponents/AuthModalBanner.js';
|
|
8
9
|
export { AuthModalIdentifierForm } from './components/AuthModal/subcomponents/AuthModalIdentifierForm.js';
|
|
@@ -28,6 +29,7 @@ export { DEFAULT_FILTER_LABELS, FilterOptionList, FilterPanel, FilterPriceSlider
|
|
|
28
29
|
export { DEFAULT_FOOTER_LEGAL_LINKS, DEFAULT_FOOTER_SECTIONS, DEFAULT_FOOTER_SOCIAL_LINKS, isCrossZoneNavigation, resolveNavDestination } from './components/NavFooter/NavFooter.helpers.js';
|
|
29
30
|
export { DEFAULT_STORAGE_KEY, isNavItemActive, isRouteActive, readStoredCollapsed, writeStoredCollapsed } from './components/SideBarNavigation/SideBarNavigation.helpers.js';
|
|
30
31
|
export { DataList, DataListAction, DataListItem, DataListLabel, DataListValue } from './components/DataList/DataList.js';
|
|
32
|
+
export { DataTable } from './components/DataTable/DataTable.js';
|
|
31
33
|
export { Dialog, DialogBody, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger } from './components/Dialog/Dialog.js';
|
|
32
34
|
export { Divider } from './components/Divider/Divider.js';
|
|
33
35
|
export { Drawer, DrawerBody, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger } from './components/Drawer/Drawer.js';
|
|
@@ -137,6 +139,7 @@ export { dropdownContentVariants, dropdownItemIconVariants, dropdownItemVariants
|
|
|
137
139
|
export { emptyStateIconWrapperVariants, emptyStateVariants } from './components/EmptyState/EmptyState.styles.js';
|
|
138
140
|
export { filterDrawerBadgeVariants, filterDrawerContentVariants, filterDrawerFooterVariants, filterDrawerHeaderVariants, filterDrawerNavItemVariants, filterDrawerNavVariants, filterDrawerPanesVariants } from './components/FilterDrawer/FilterDrawer.styles.js';
|
|
139
141
|
export { filterLinkButtonVariants, filterOptionCountVariants, filterOptionLabelVariants, filterOptionRowVariants, filterPanelBodyVariants, filterPanelHeaderVariants, filterPanelTitleVariants, filterPanelVariants, filterSectionContentVariants, filterSectionTriggerVariants, filterToggleListVariants } from './components/FilterPanel/FilterPanel.styles.js';
|
|
142
|
+
export { flexRender } from '@tanstack/react-table';
|
|
140
143
|
export { footerLegalBarVariants, footerLegalLinkVariants, footerNavLinkVariants, footerOfficeBlockVariants, footerSectionTitleVariants, footerSocialButtonVariants, navFooterContainerVariants, navFooterRootVariants } from './components/NavFooter/NavFooter.styles.js';
|
|
141
144
|
export { formFieldVariants } from './components/FormField/FormField.styles.js';
|
|
142
145
|
export { headingVariants } from './components/Heading/Heading.styles.js';
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { createTable } from '../../../../../../@tanstack_table-core@8.21.3/node_modules/@tanstack/table-core/build/lib/index.js';
|
|
3
|
+
export { ColumnFaceting, ColumnFiltering, ColumnGrouping, ColumnOrdering, ColumnPinning, ColumnSizing, ColumnVisibility, GlobalFaceting, GlobalFiltering, Headers, RowExpanding, RowPagination, RowPinning, RowSelection, RowSorting, _getVisibleLeafColumns, aggregationFns, buildHeaderGroups, createCell, createColumn, createRow, defaultColumnSizing, filterFns, flattenBy, functionalUpdate, getCoreRowModel, getMemoOptions, getSortedRowModel, isFunction, isNumberArray, isRowSelected, isSubRowSelected, makeStateUpdater, memo, orderColumns, passiveEventSupported, reSplitAlphaNumeric, selectRowsFn, shouldAutoRemoveFilter, sortingFns } from '../../../../../../@tanstack_table-core@8.21.3/node_modules/@tanstack/table-core/build/lib/index.js';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* react-table
|
|
7
|
+
*
|
|
8
|
+
* Copyright (c) TanStack
|
|
9
|
+
*
|
|
10
|
+
* This source code is licensed under the MIT license found in the
|
|
11
|
+
* LICENSE.md file in the root directory of this source tree.
|
|
12
|
+
*
|
|
13
|
+
* @license MIT
|
|
14
|
+
*/
|
|
15
|
+
|
|
16
|
+
//
|
|
17
|
+
|
|
18
|
+
/**
|
|
19
|
+
* If rendering headers, cells, or footers with custom markup, use flexRender instead of `cell.getValue()` or `cell.renderValue()`.
|
|
20
|
+
*/
|
|
21
|
+
function flexRender(Comp, props) {
|
|
22
|
+
return !Comp ? null : isReactComponent(Comp) ? /*#__PURE__*/React.createElement(Comp, props) : Comp;
|
|
23
|
+
}
|
|
24
|
+
function isReactComponent(component) {
|
|
25
|
+
return isClassComponent(component) || typeof component === 'function' || isExoticComponent(component);
|
|
26
|
+
}
|
|
27
|
+
function isClassComponent(component) {
|
|
28
|
+
return typeof component === 'function' && (() => {
|
|
29
|
+
const proto = Object.getPrototypeOf(component);
|
|
30
|
+
return proto.prototype && proto.prototype.isReactComponent;
|
|
31
|
+
})();
|
|
32
|
+
}
|
|
33
|
+
function isExoticComponent(component) {
|
|
34
|
+
return typeof component === 'object' && typeof component.$$typeof === 'symbol' && ['react.memo', 'react.forward_ref'].includes(component.$$typeof.description);
|
|
35
|
+
}
|
|
36
|
+
function useReactTable(options) {
|
|
37
|
+
// Compose in the generic options to the user options
|
|
38
|
+
const resolvedOptions = {
|
|
39
|
+
state: {},
|
|
40
|
+
// Dummy state
|
|
41
|
+
onStateChange: () => {},
|
|
42
|
+
// noop
|
|
43
|
+
renderFallbackValue: null,
|
|
44
|
+
...options
|
|
45
|
+
};
|
|
46
|
+
|
|
47
|
+
// Create a new table and store it in state
|
|
48
|
+
const [tableRef] = React.useState(() => ({
|
|
49
|
+
current: createTable(resolvedOptions)
|
|
50
|
+
}));
|
|
51
|
+
|
|
52
|
+
// By default, manage table state here using the table's initial state
|
|
53
|
+
const [state, setState] = React.useState(() => tableRef.current.initialState);
|
|
54
|
+
|
|
55
|
+
// Compose the default state above with any user state. This will allow the user
|
|
56
|
+
// to only control a subset of the state if desired.
|
|
57
|
+
tableRef.current.setOptions(prev => ({
|
|
58
|
+
...prev,
|
|
59
|
+
...options,
|
|
60
|
+
state: {
|
|
61
|
+
...state,
|
|
62
|
+
...options.state
|
|
63
|
+
},
|
|
64
|
+
// Similarly, we'll maintain both our internal state and any user-provided
|
|
65
|
+
// state.
|
|
66
|
+
onStateChange: updater => {
|
|
67
|
+
setState(updater);
|
|
68
|
+
options.onStateChange == null || options.onStateChange(updater);
|
|
69
|
+
}
|
|
70
|
+
}));
|
|
71
|
+
return tableRef.current;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
export { createTable, flexRender, useReactTable };
|