@veritone-ce/design-system 2.8.13-next.0 → 2.8.13

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 (66) hide show
  1. package/dist/cjs/Dialog/components.js +90 -29
  2. package/dist/cjs/Dialog/state.js +8 -2
  3. package/dist/cjs/Dialog/styles.module.scss.js +2 -2
  4. package/dist/cjs/FileUploader/controlled.js +0 -7
  5. package/dist/cjs/Menu/controlled.js +77 -2
  6. package/dist/cjs/Select/controlled.js +3 -0
  7. package/dist/cjs/Table/AutoTable/controlled.js +1 -2
  8. package/dist/cjs/Table/AutoTable/styles.module.scss.js +1 -1
  9. package/dist/cjs/TablePagination/index.js +8 -21
  10. package/dist/cjs/index.js +0 -11
  11. package/dist/cjs/styles/createPalette.js +0 -11
  12. package/dist/cjs/styles.css +1 -1
  13. package/dist/cjs/unstable/Card/index.js +33 -0
  14. package/dist/cjs/unstable/Card/styles.module.scss.js +1 -1
  15. package/dist/cjs/unstable/index.js +13 -39
  16. package/dist/esm/Dialog/components.js +89 -28
  17. package/dist/esm/Dialog/state.js +8 -2
  18. package/dist/esm/Dialog/styles.module.scss.js +2 -2
  19. package/dist/esm/FileUploader/controlled.js +0 -7
  20. package/dist/esm/Menu/controlled.js +77 -2
  21. package/dist/esm/Select/controlled.js +3 -0
  22. package/dist/esm/Table/AutoTable/controlled.js +1 -2
  23. package/dist/esm/Table/AutoTable/styles.module.scss.js +1 -1
  24. package/dist/esm/TablePagination/index.js +8 -21
  25. package/dist/esm/index.js +1 -1
  26. package/dist/esm/styles/createPalette.js +1 -1
  27. package/dist/esm/styles.css +1 -1
  28. package/dist/esm/unstable/Card/index.js +29 -0
  29. package/dist/esm/unstable/Card/styles.module.scss.js +1 -1
  30. package/dist/esm/unstable/index.js +1 -5
  31. package/dist/types/Dialog/components.d.ts +20 -27
  32. package/dist/types/Dialog/factory.d.ts +5 -4
  33. package/dist/types/Dialog/state.d.ts +15 -1
  34. package/dist/types/Menu/controlled.d.ts +9 -1
  35. package/dist/types/Select/types.d.ts +8 -0
  36. package/dist/types/TablePagination/index.d.ts +1 -1
  37. package/dist/types/styles/createPalette.d.ts +2 -13
  38. package/dist/types/unstable/Card/index.d.ts +11 -2
  39. package/dist/types/unstable/index.d.ts +0 -3
  40. package/package.json +7 -1
  41. package/dist/cjs/styles/entrypoint.scss.js +0 -7
  42. package/dist/cjs/unstable/Card/components.js +0 -213
  43. package/dist/cjs/unstable/Card/state.js +0 -53
  44. package/dist/cjs/unstable/StatCard/index.js +0 -124
  45. package/dist/cjs/unstable/StatCard/index.module.scss.js +0 -7
  46. package/dist/cjs/unstable/skeleton/index.js +0 -74
  47. package/dist/cjs/unstable/skeleton/index.module.scss.js +0 -7
  48. package/dist/cjs/unstable/suspense/index.js +0 -18
  49. package/dist/cjs/unstable/suspense/index.module.scss.js +0 -7
  50. package/dist/cjs/unstable/suspense/loader.js +0 -23
  51. package/dist/esm/styles/entrypoint.scss.js +0 -3
  52. package/dist/esm/unstable/Card/components.js +0 -182
  53. package/dist/esm/unstable/Card/state.js +0 -30
  54. package/dist/esm/unstable/StatCard/index.js +0 -116
  55. package/dist/esm/unstable/StatCard/index.module.scss.js +0 -3
  56. package/dist/esm/unstable/skeleton/index.js +0 -69
  57. package/dist/esm/unstable/skeleton/index.module.scss.js +0 -3
  58. package/dist/esm/unstable/suspense/index.js +0 -15
  59. package/dist/esm/unstable/suspense/index.module.scss.js +0 -3
  60. package/dist/esm/unstable/suspense/loader.js +0 -20
  61. package/dist/types/unstable/Card/components.d.ts +0 -90
  62. package/dist/types/unstable/Card/state.d.ts +0 -20
  63. package/dist/types/unstable/StatCard/index.d.ts +0 -33
  64. package/dist/types/unstable/skeleton/index.d.ts +0 -15
  65. package/dist/types/unstable/suspense/index.d.ts +0 -9
  66. package/dist/types/unstable/suspense/loader.d.ts +0 -7
@@ -17,10 +17,10 @@ require('../styles/defaultTheme.js');
17
17
  require('../styles/provider.client.js');
18
18
  var portal = require('../styles/portal.js');
19
19
  require('../styles/css-vars.js');
20
- var index = require('../Button/index.js');
21
- var index$1 = require('../IconButton/index.js');
20
+ var index$1 = require('../Button/index.js');
21
+ var index = require('../Typography/index.js');
22
+ var index$2 = require('../IconButton/index.js');
22
23
  var internal = require('../Icon/internal.js');
23
- var components = require('../unstable/Card/components.js');
24
24
 
25
25
  function _interopNamespaceDefault(e) {
26
26
  var n = Object.create(null);
@@ -50,18 +50,9 @@ const Dialog = React__namespace.forwardRef(function Dialog2({
50
50
  overlayClassName,
51
51
  lockScroll = true,
52
52
  disableAutoFocus = false,
53
- open,
54
- onDismiss,
55
- preventOutsideDismiss,
56
- preventEscapeDismiss,
57
- ...props
53
+ "data-testid": dataTestId,
54
+ ...options
58
55
  }, propRef) {
59
- const options = {
60
- open,
61
- onDismiss,
62
- preventOutsideDismiss,
63
- preventEscapeDismiss
64
- };
65
56
  const dialog = state.useDialog(options);
66
57
  const { isMounted: overlayIsMounted, styles: overlayTransitionStyles } = react.useTransitionStyles(dialog.context, {
67
58
  duration: 225,
@@ -93,11 +84,13 @@ const Dialog = React__namespace.forwardRef(function Dialog2({
93
84
  context: dialog.context,
94
85
  disabled: disableAutoFocus,
95
86
  children: /* @__PURE__ */ jsxRuntime.jsx(portal.PortalThemeRelay, { children: /* @__PURE__ */ jsxRuntime.jsx(
96
- components.default,
87
+ "div",
97
88
  {
98
89
  ref,
90
+ "aria-labelledby": dialog.labelId,
91
+ "aria-describedby": dialog.descriptionId,
99
92
  ...dialog.getFloatingProps(),
100
- ...props,
93
+ "data-testid": dataTestId,
101
94
  style: {
102
95
  ...innerTransitionStyles,
103
96
  ...style
@@ -115,41 +108,109 @@ const Dialog = React__namespace.forwardRef(function Dialog2({
115
108
  });
116
109
  const DialogStart = React__namespace.forwardRef(
117
110
  function DialogStart2({ children, ...props }, ref) {
118
- return /* @__PURE__ */ jsxRuntime.jsx(components.CardStart, { ref, ...props, children });
111
+ return /* @__PURE__ */ jsxRuntime.jsx(
112
+ "div",
113
+ {
114
+ ref,
115
+ ...props,
116
+ className: cx.cx(styles_module.default["dialog-start"], props.className),
117
+ children
118
+ }
119
+ );
119
120
  }
120
121
  );
121
122
  const DialogContent = React__namespace.forwardRef(function DialogContent2({ children, ...props }, ref) {
122
- return /* @__PURE__ */ jsxRuntime.jsx(components.CardContent, { ref, ...props, children });
123
+ return /* @__PURE__ */ jsxRuntime.jsx(
124
+ "div",
125
+ {
126
+ ...props,
127
+ ref,
128
+ className: cx.cx(styles_module.default["dialog-content"], props.className),
129
+ children
130
+ }
131
+ );
123
132
  });
124
133
  const DialogEnd = React__namespace.forwardRef(
125
134
  function DialogEnd2({ children, ...props }, ref) {
126
- return /* @__PURE__ */ jsxRuntime.jsx(components.CardEnd, { ref, ...props, children });
135
+ return /* @__PURE__ */ jsxRuntime.jsx(
136
+ "div",
137
+ {
138
+ ref,
139
+ ...props,
140
+ className: cx.cx(styles_module.default["dialog-end"], props.className),
141
+ children
142
+ }
143
+ );
127
144
  }
128
145
  );
129
- const DialogTitle = React__namespace.forwardRef(function DialogTitle2({ children, className, ...props }, ref) {
130
- return /* @__PURE__ */ jsxRuntime.jsx(
131
- components.CardTitle,
146
+ const DialogTitle = React__namespace.forwardRef(function DialogTitle2({ children, ...props }, ref) {
147
+ const { setLabelId } = state.useDialogContext();
148
+ const id = React__namespace.useId();
149
+ React__namespace.useLayoutEffect(() => {
150
+ setLabelId(id);
151
+ return () => setLabelId(void 0);
152
+ }, [id, setLabelId]);
153
+ return /* @__PURE__ */ jsxRuntime.jsx(DialogStart, { children: /* @__PURE__ */ jsxRuntime.jsx(
154
+ index.default,
132
155
  {
156
+ variant: "h4",
157
+ color: "primary",
133
158
  ref,
134
- className: cx.cx(className, styles_module.default["dialog-title"]),
159
+ id,
160
+ leadingTrim: true,
135
161
  ...props,
162
+ className: cx.cx(styles_module.default["dialog-title"], props.className),
136
163
  children
137
164
  }
138
- );
165
+ ) });
139
166
  });
140
167
  const DialogTypography = React__namespace.forwardRef(function DialogTypography2({ children, ...props }, ref) {
141
- return /* @__PURE__ */ jsxRuntime.jsx(components.CardTypography, { ref, ...props, children });
168
+ return /* @__PURE__ */ jsxRuntime.jsx(
169
+ index.default,
170
+ {
171
+ variant: "paragraph2",
172
+ color: "primary",
173
+ ...props,
174
+ ref,
175
+ className: cx.cx(styles_module.default["dialog-typography"], props.className),
176
+ children
177
+ }
178
+ );
142
179
  });
143
180
  const DialogDescription = React__namespace.forwardRef(function DialogDescription2({ children, ...props }, ref) {
144
- return /* @__PURE__ */ jsxRuntime.jsx(components.CardDescription, { ref, ...props, children });
181
+ const { setDescriptionId } = state.useDialogContext();
182
+ const id = React__namespace.useId();
183
+ React__namespace.useLayoutEffect(() => {
184
+ setDescriptionId(id);
185
+ return () => setDescriptionId(void 0);
186
+ }, [id, setDescriptionId]);
187
+ return /* @__PURE__ */ jsxRuntime.jsx(
188
+ DialogTypography,
189
+ {
190
+ variant: "paragraph2",
191
+ color: "primary",
192
+ ...props,
193
+ ref,
194
+ id,
195
+ children
196
+ }
197
+ );
145
198
  });
146
199
  const DialogActions = React__namespace.forwardRef(function DialogActions2({ children, ...props }, ref) {
147
- return /* @__PURE__ */ jsxRuntime.jsx(components.CardActions, { ref, ...props, children });
200
+ return /* @__PURE__ */ jsxRuntime.jsx(DialogEnd, { children: /* @__PURE__ */ jsxRuntime.jsx(
201
+ "div",
202
+ {
203
+ ...props,
204
+ ref,
205
+ className: cx.cx(styles_module.default["dialog-actions"], props.className),
206
+ children
207
+ }
208
+ ) });
148
209
  });
149
210
  const DialogCloseButton = React__namespace.forwardRef(function DialogCloseButton2(props, ref) {
150
211
  const { dismiss } = state.useDialogContext();
151
212
  return /* @__PURE__ */ jsxRuntime.jsx(
152
- index.default,
213
+ index$1.default,
153
214
  {
154
215
  variant: "tertiary",
155
216
  ...props,
@@ -164,7 +225,7 @@ const DialogCloseButton = React__namespace.forwardRef(function DialogCloseButton
164
225
  const DialogCloseIconButton = React__namespace.forwardRef(function DialogCloseIconButton2({ children = /* @__PURE__ */ jsxRuntime.jsx(internal.CloseIcon, {}), ...props }, ref) {
165
226
  const { dismiss } = state.useDialogContext();
166
227
  return /* @__PURE__ */ jsxRuntime.jsx(
167
- index$1.default,
228
+ index$2.default,
168
229
  {
169
230
  ...props,
170
231
  ref,
@@ -30,6 +30,8 @@ function useDialog({
30
30
  preventOutsideDismiss,
31
31
  preventEscapeDismiss
32
32
  }) {
33
+ const [labelId, setLabelId] = React__namespace.useState();
34
+ const [descriptionId, setDescriptionId] = React__namespace.useState();
33
35
  const data = react.useFloating({
34
36
  open,
35
37
  onOpenChange: (newOpen) => !newOpen && typeof dismissDialog === "function" && dismissDialog()
@@ -47,9 +49,13 @@ function useDialog({
47
49
  open,
48
50
  dismiss: dismissDialog,
49
51
  ...interactions,
50
- ...data
52
+ ...data,
53
+ labelId,
54
+ descriptionId,
55
+ setLabelId,
56
+ setDescriptionId
51
57
  }),
52
- [open, dismissDialog, interactions, data]
58
+ [open, dismissDialog, interactions, data, labelId, descriptionId]
53
59
  );
54
60
  }
55
61
  const DialogContext = React__namespace.createContext(null);
@@ -2,6 +2,6 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var styles = {"dialog-overlay":"vt_ce_Dialog_dialog-overlay__9285b892","dialog":"vt_ce_Dialog_dialog__6471c2e3","dialog-title":"vt_ce_Dialog_dialog-title__d88ef551"};
5
+ var css = {"dialog-overlay":"vt_ce_Dialog_dialog-overlay__9285b892","dialog":"vt_ce_Dialog_dialog__6471c2e3","dialog-start":"vt_ce_Dialog_dialog-start__3d0c37c9","dialog-end":"vt_ce_Dialog_dialog-end__d33601cf","dialog-content":"vt_ce_Dialog_dialog-content__237fe65e","dialog-title":"vt_ce_Dialog_dialog-title__d88ef551","dialog-typography":"vt_ce_Dialog_dialog-typography__94d06942","dialog-actions":"vt_ce_Dialog_dialog-actions__e259c208"};
6
6
 
7
- exports.default = styles;
7
+ exports.default = css;
@@ -18,14 +18,7 @@ var index$2 = require('../IconButton/index.js');
18
18
  var wrappers = require('../Icon/wrappers.js');
19
19
  require('../Icon/factory.js');
20
20
  var styles_module = require('./styles.module.scss.js');
21
- require('../unstable/Breadcrumbs/index.js');
22
- require('../unstable/Card/components.js');
23
21
  var index$1 = require('../unstable/LinearProgress/index.js');
24
- require('@mui/material');
25
- require('../FormControl/index.js');
26
- require('../ErrorBoundary/index.js');
27
- require('../Button/index.js');
28
- require('../unstable/Tabs/index.js');
29
22
 
30
23
  const CloudUploadOutlinedIcon = wrappers.adaptMuiSvgIcon(iconsMaterial.CloudUploadOutlined);
31
24
  const DeleteOutlineIcon = wrappers.adaptMuiSvgIcon(iconsMaterial.DeleteOutline);
@@ -15,6 +15,7 @@ require('../styles/provider.client.js');
15
15
  var portal = require('../styles/portal.js');
16
16
  require('../styles/css-vars.js');
17
17
  var react = require('@floating-ui/react');
18
+ var reactVirtual = require('@tanstack/react-virtual');
18
19
  var utils = require('../popover/utils.js');
19
20
  var index = require('../Typography/index.js');
20
21
  var wrappers = require('../Icon/wrappers.js');
@@ -29,6 +30,9 @@ function Menu({
29
30
  strategy = "absolute",
30
31
  enableTypeahead = true,
31
32
  matchAnchorWidth = false,
33
+ virtualize = false,
34
+ onReachEnd,
35
+ reachEndOffset = 120,
32
36
  options,
33
37
  dismissEnabled = true,
34
38
  disableAutoFocus = false,
@@ -39,6 +43,13 @@ function Menu({
39
43
  const [activeIndex, setActiveIndex] = React.useState(null);
40
44
  const elementsRef = React.useRef([]);
41
45
  const labelsRef = React.useRef([]);
46
+ const menuScrollRef = React.useRef(null);
47
+ const hasNestedOptions = options.some((option) => Boolean(option.options));
48
+ const virtualizeConfig = virtualize && !hasNestedOptions ? {
49
+ itemSize: typeof virtualize === "object" ? virtualize.itemSize ?? 40 : 40,
50
+ overscan: typeof virtualize === "object" ? virtualize.overscan ?? 8 : 8,
51
+ maxHeight: typeof virtualize === "object" ? virtualize.maxHeight ?? 320 : 320
52
+ } : null;
42
53
  const { floatingStyles, refs, context, middlewareData } = react.useFloating({
43
54
  open: isOpen,
44
55
  onOpenChange(newOpen) {
@@ -68,19 +79,26 @@ function Menu({
68
79
  ],
69
80
  whileElementsMounted: react.autoUpdate
70
81
  });
82
+ const virtualizer = reactVirtual.useVirtualizer({
83
+ count: options.length,
84
+ getScrollElement: () => menuScrollRef.current,
85
+ estimateSize: () => virtualizeConfig?.itemSize ?? 40,
86
+ overscan: virtualizeConfig?.overscan ?? 8
87
+ });
71
88
  const role = react.useRole(context, { role: assumeRole });
72
89
  const dismiss = react.useDismiss(context, {
73
90
  enabled: dismissEnabled,
74
91
  bubbles: false
75
92
  });
76
93
  const listNavigation = react.useListNavigation(context, {
94
+ enabled: !virtualizeConfig,
77
95
  listRef: elementsRef,
78
96
  activeIndex,
79
97
  nested: false,
80
98
  onNavigate: setActiveIndex
81
99
  });
82
100
  const typeahead = react.useTypeahead(context, {
83
- enabled: enableTypeahead,
101
+ enabled: enableTypeahead && !virtualizeConfig,
84
102
  listRef: labelsRef,
85
103
  onMatch: isOpen ? setActiveIndex : void 0,
86
104
  activeIndex
@@ -98,6 +116,21 @@ function Menu({
98
116
  transform: `scale(95%)`
99
117
  }
100
118
  });
119
+ React.useEffect(() => {
120
+ labelsRef.current = options.map((option) => option.label);
121
+ }, [options]);
122
+ const handleMenuScroll = React.useCallback(
123
+ (event) => {
124
+ if (!onReachEnd)
125
+ return;
126
+ const target = event.currentTarget;
127
+ const distanceToBottom = target.scrollHeight - target.scrollTop - target.clientHeight;
128
+ if (distanceToBottom <= reachEndOffset) {
129
+ onReachEnd();
130
+ }
131
+ },
132
+ [onReachEnd, reachEndOffset]
133
+ );
101
134
  return /* @__PURE__ */ jsxRuntime.jsx(react.FloatingList, { elementsRef, labelsRef, children: isMounted && /* @__PURE__ */ jsxRuntime.jsx(react.FloatingPortal, { root: props.portalEl, children: /* @__PURE__ */ jsxRuntime.jsx(
102
135
  react.FloatingFocusManager,
103
136
  {
@@ -120,12 +153,54 @@ function Menu({
120
153
  children: /* @__PURE__ */ jsxRuntime.jsx(
121
154
  "div",
122
155
  {
156
+ ref: virtualizeConfig ? menuScrollRef : void 0,
157
+ onScroll: onReachEnd ? handleMenuScroll : void 0,
123
158
  style: {
124
159
  ...transitionStyles,
160
+ ...virtualizeConfig ? { maxHeight: virtualizeConfig.maxHeight } : {},
125
161
  ...props.style
126
162
  },
127
163
  className: cx.cx(styles_module.default["menu"], className),
128
- children: options?.map((option, i) => {
164
+ children: virtualizeConfig ? /* @__PURE__ */ jsxRuntime.jsx(
165
+ "div",
166
+ {
167
+ style: {
168
+ height: `${virtualizer.getTotalSize()}px`,
169
+ position: "relative"
170
+ },
171
+ children: virtualizer.getVirtualItems().map((virtualItem) => {
172
+ const option = options[virtualItem.index];
173
+ if (!option) {
174
+ return null;
175
+ }
176
+ return /* @__PURE__ */ jsxRuntime.jsx(
177
+ MenuItem,
178
+ {
179
+ role: "menuitem",
180
+ isActive: virtualItem.index === activeIndex,
181
+ disabled: option.disabled,
182
+ style: {
183
+ position: "absolute",
184
+ top: 0,
185
+ left: 0,
186
+ width: "100%",
187
+ transform: `translateY(${virtualItem.start}px)`
188
+ },
189
+ ...getItemProps({
190
+ onClick(event) {
191
+ option.onSelect(
192
+ event
193
+ );
194
+ }
195
+ }),
196
+ icon: option.icon,
197
+ label: option.label
198
+ },
199
+ virtualItem.key
200
+ );
201
+ })
202
+ }
203
+ ) : options?.map((option, i) => {
129
204
  if (option.options) {
130
205
  return /* @__PURE__ */ jsxRuntime.jsx(
131
206
  NestedMenu,
@@ -172,6 +172,9 @@ function ControlledSelect({
172
172
  anchorId,
173
173
  anchor: open ? anchorRef.current : null,
174
174
  open: open && !freeSolo,
175
+ virtualize: props.virtualize,
176
+ onReachEnd: props.onMenuReachEnd,
177
+ reachEndOffset: props.menuReachEndOffset,
175
178
  portalEl: props.portalEl,
176
179
  strategy: props.dropdownStrategy,
177
180
  enableTypeahead: false,
@@ -84,8 +84,7 @@ function ControlledAutoTable({
84
84
  const size = rowsPerPage ?? 10;
85
85
  table.setPageSize(size);
86
86
  options.onRowsPerPageChange(size);
87
- },
88
- className: styles_module.default.pagination
87
+ }
89
88
  }
90
89
  ) }) }) })
91
90
  ]
@@ -2,6 +2,6 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var styles = {"visuallyHidden":"vt_ce_AutoTable_visuallyHidden__d42457bf","errorContainer":"vt_ce_AutoTable_errorContainer__22629d1a","loadingContainer":"vt_ce_AutoTable_loadingContainer__800e1c5c","table":"vt_ce_AutoTable_table__abdcf037","stickyHeader":"vt_ce_AutoTable_stickyHeader__1fdfff7b","virtualTableBody":"vt_ce_AutoTable_virtualTableBody__1264b0bb","pagination":"vt_ce_AutoTable_pagination__1b911403"};
5
+ var styles = {"visuallyHidden":"vt_ce_AutoTable_visuallyHidden__d42457bf","errorContainer":"vt_ce_AutoTable_errorContainer__22629d1a","loadingContainer":"vt_ce_AutoTable_loadingContainer__800e1c5c","table":"vt_ce_AutoTable_table__abdcf037","stickyHeader":"vt_ce_AutoTable_stickyHeader__1fdfff7b","virtualTableBody":"vt_ce_AutoTable_virtualTableBody__1264b0bb"};
6
6
 
7
7
  exports.default = styles;
@@ -13,13 +13,6 @@ var uncontrolled = require('../Select/uncontrolled.js');
13
13
  var React = require('react');
14
14
  var index$1 = require('../Input/index.js');
15
15
  var index = require('../FormControl/index.js');
16
- var cx = require('../styles/cx.js');
17
- require('../styles/defaultThemeOptions.js');
18
- require('@capsizecss/core');
19
- require('color2k');
20
- require('../styles/defaultTheme.js');
21
- require('../styles/provider.client.js');
22
- require('../styles/css-vars.js');
23
16
 
24
17
  function TablePagination({
25
18
  page,
@@ -29,12 +22,6 @@ function TablePagination({
29
22
  rowsPerPageLabel = "Rows per page:",
30
23
  rowsPerPageVariant = "normal",
31
24
  showPageNumberInput = false,
32
- onChangePage,
33
- onRowsPerPageChange,
34
- "data-pendo-prev": dataPendoPrev,
35
- "data-pendo-next": dataPendoNext,
36
- "data-pendo-select": dataPendoSelect,
37
- className,
38
25
  ...props
39
26
  }) {
40
27
  const showPrev = page !== 1;
@@ -52,7 +39,7 @@ function TablePagination({
52
39
  Math.min(Math.ceil(count / rowsPerPage), Number(inputPage))
53
40
  );
54
41
  if (newPage !== page) {
55
- onChangePage(newPage);
42
+ props.onChangePage(newPage);
56
43
  }
57
44
  setInputPage(newPage.toString());
58
45
  };
@@ -64,7 +51,7 @@ function TablePagination({
64
51
  React.useEffect(() => {
65
52
  setInputPage(page.toString());
66
53
  }, [page]);
67
- return /* @__PURE__ */ jsxRuntime.jsxs("nav", { ...props, className: cx.cx(styles_module.default["container"], className), children: [
54
+ return /* @__PURE__ */ jsxRuntime.jsxs("nav", { className: styles_module.default["container"], children: [
68
55
  /* @__PURE__ */ jsxRuntime.jsx(index.default, { label: rowsPerPageLabel, placement: "inline-start", children: /* @__PURE__ */ jsxRuntime.jsx(
69
56
  uncontrolled.default,
70
57
  {
@@ -75,9 +62,9 @@ function TablePagination({
75
62
  label: option.toLocaleString(),
76
63
  value: option
77
64
  })),
78
- onChange: (_, newRowsPerPage) => onRowsPerPageChange?.(newRowsPerPage),
65
+ onChange: (_, newRowsPerPage) => props.onRowsPerPageChange?.(newRowsPerPage),
79
66
  className: styles_module.default["rows-per-page-select"],
80
- "data-pendo": dataPendoSelect,
67
+ "data-pendo": props["data-pendo-select"],
81
68
  tight: rowsPerPageVariant === "tight"
82
69
  }
83
70
  ) }),
@@ -106,8 +93,8 @@ function TablePagination({
106
93
  {
107
94
  type: "button",
108
95
  disabled: !showPrev,
109
- onClick: () => onChangePage(page - 1),
110
- "data-pendo": dataPendoPrev,
96
+ onClick: () => props.onChangePage(page - 1),
97
+ "data-pendo": props["data-pendo-prev"],
111
98
  children: /* @__PURE__ */ jsxRuntime.jsx(internal.NavigateBeforeIcon, {})
112
99
  }
113
100
  ) }),
@@ -116,8 +103,8 @@ function TablePagination({
116
103
  {
117
104
  type: "button",
118
105
  disabled: !showNext,
119
- onClick: () => onChangePage(page + 1),
120
- "data-pendo": dataPendoNext,
106
+ onClick: () => props.onChangePage(page + 1),
107
+ "data-pendo": props["data-pendo-next"],
121
108
  children: /* @__PURE__ */ jsxRuntime.jsx(internal.NavigateNextIcon, {})
122
109
  }
123
110
  ) })
package/dist/cjs/index.js CHANGED
@@ -71,17 +71,6 @@ exports.useTheme = useTheme.default;
71
71
  exports.TypographyVariantKeys = typography.TypographyVariantKeys;
72
72
  exports.PortalThemeRelay = portal.PortalThemeRelay;
73
73
  exports.createPalette = createPalette.createPalette;
74
- exports.createPaletteAction = createPalette.createPaletteAction;
75
- exports.createPaletteActionVariantsColors = createPalette.createPaletteActionVariantsColors;
76
- exports.createPaletteBackground = createPalette.createPaletteBackground;
77
- exports.createPaletteBrand = createPalette.createPaletteBrand;
78
- exports.createPaletteColor = createPalette.createPaletteColor;
79
- exports.createPaletteIndicator = createPalette.createPaletteIndicator;
80
- exports.createPaletteStroke = createPalette.createPaletteStroke;
81
- exports.createPaletteSurfaceColors = createPalette.createPaletteSurfaceColors;
82
- exports.createPaletteTable = createPalette.createPaletteTable;
83
- exports.createPaletteText = createPalette.createPaletteText;
84
- exports.createPaletteTooltip = createPalette.createPaletteTooltip;
85
74
  exports.createTypography = createTypography.createTypography;
86
75
  exports.ThemeContext = provider_client.ThemeContext;
87
76
  exports.ThemeContextProvider = provider_client.ThemeContextProvider;
@@ -225,14 +225,3 @@ function createPalette(options = {}) {
225
225
  }
226
226
 
227
227
  exports.createPalette = createPalette;
228
- exports.createPaletteAction = createPaletteAction;
229
- exports.createPaletteActionVariantsColors = createPaletteActionVariantsColors;
230
- exports.createPaletteBackground = createPaletteBackground;
231
- exports.createPaletteBrand = createPaletteBrand;
232
- exports.createPaletteColor = createPaletteColor;
233
- exports.createPaletteIndicator = createPaletteIndicator;
234
- exports.createPaletteStroke = createPaletteStroke;
235
- exports.createPaletteSurfaceColors = createPaletteSurfaceColors;
236
- exports.createPaletteTable = createPaletteTable;
237
- exports.createPaletteText = createPaletteText;
238
- exports.createPaletteTooltip = createPaletteTooltip;