@clearstory/drywall-react 3.6.0 → 3.7.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/KeyboardArrowRight-ywXLVR_a.js +12 -0
- package/dist/TablePagination-BWugB9nc.js +665 -0
- package/dist/{Tabs-DzfngSGu.js → Tabs-C9SJL9Or.js} +186 -191
- package/dist/components/TablePagination/index.d.ts +2 -0
- package/dist/components/TablePagination/index.js +6 -0
- package/dist/components/Tabs/index.js +1 -1
- package/dist/main.d.ts +1 -0
- package/dist/main.js +94 -90
- package/package.json +1 -1
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import "react";
|
|
2
|
+
import { c as r } from "./createSvgIcon-CGGjtU_g.js";
|
|
3
|
+
import { jsx as o } from "react/jsx-runtime";
|
|
4
|
+
const d = r(/* @__PURE__ */ o("path", {
|
|
5
|
+
d: "M15.41 16.09l-4.58-4.59 4.58-4.59L14 5.5l-6 6 6 6z"
|
|
6
|
+
}), "KeyboardArrowLeft"), p = r(/* @__PURE__ */ o("path", {
|
|
7
|
+
d: "M8.59 16.34l4.58-4.59-4.58-4.59L10 5.75l6 6-6 6z"
|
|
8
|
+
}), "KeyboardArrowRight");
|
|
9
|
+
export {
|
|
10
|
+
d as K,
|
|
11
|
+
p as a
|
|
12
|
+
};
|
|
@@ -0,0 +1,665 @@
|
|
|
1
|
+
import * as et from "react";
|
|
2
|
+
import { createElement as ft } from "react";
|
|
3
|
+
import { P as t } from "./index-CyAhC1RZ.js";
|
|
4
|
+
import { c as q } from "./clsx-OuTLNxxd.js";
|
|
5
|
+
import { m as $ } from "./memoTheme-CCudmmpb.js";
|
|
6
|
+
import { g as ot } from "./generateUtilityClasses-CIjBDg4V.js";
|
|
7
|
+
import { c as nt } from "./createTheme-B1FDFl52.js";
|
|
8
|
+
import { u as I } from "./useSlot-BVGwJA4b.js";
|
|
9
|
+
import { jsx as s, jsxs as st } from "react/jsx-runtime";
|
|
10
|
+
import { u as at } from "./DefaultPropsProvider-Hks9kyHW.js";
|
|
11
|
+
import { u as gt } from "./index-D2IRntbh.js";
|
|
12
|
+
import { a as Bt, K as Pt } from "./KeyboardArrowRight-ywXLVR_a.js";
|
|
13
|
+
import { c as lt } from "./createSvgIcon-CGGjtU_g.js";
|
|
14
|
+
import { I as N } from "./IconButton-TpdTqzbL.js";
|
|
15
|
+
import { s as P } from "./styled-D8CtiDxW.js";
|
|
16
|
+
import { c as it } from "./composeClasses-2Ou-RZJr.js";
|
|
17
|
+
import { T as X } from "./TableCell-DoYXdVk-.js";
|
|
18
|
+
import { u as Z } from "./useId-CK6Kn3Tn.js";
|
|
19
|
+
import { I as Tt } from "./InputBase-C0p5hzfj.js";
|
|
20
|
+
import { M as It } from "./MenuItem-trBk-sK2.js";
|
|
21
|
+
import { T as ht } from "./Toolbar-BrvXkKNF.js";
|
|
22
|
+
import { S as yt } from "./Select-BaTU7yXy.js";
|
|
23
|
+
import { i as W } from "./integerPropType-BihGt2aU.js";
|
|
24
|
+
import { c as Rt } from "./chainPropTypes-D9lkm76m.js";
|
|
25
|
+
const St = lt(/* @__PURE__ */ s("path", {
|
|
26
|
+
d: "M18.41 16.59L13.82 12l4.59-4.59L17 6l-6 6 6 6zM6 6h2v12H6z"
|
|
27
|
+
}), "FirstPage"), xt = lt(/* @__PURE__ */ s("path", {
|
|
28
|
+
d: "M5.59 7.41L10.18 12l-4.59 4.59L7 18l6-6-6-6zM16 6h2v12h-2z"
|
|
29
|
+
}), "LastPage");
|
|
30
|
+
function vt(e) {
|
|
31
|
+
return nt("MuiTablePaginationActions", e);
|
|
32
|
+
}
|
|
33
|
+
ot("MuiTablePaginationActions", ["root"]);
|
|
34
|
+
const wt = (e) => {
|
|
35
|
+
const {
|
|
36
|
+
classes: n
|
|
37
|
+
} = e;
|
|
38
|
+
return it({
|
|
39
|
+
root: ["root"]
|
|
40
|
+
}, vt, n);
|
|
41
|
+
}, Lt = P("div", {
|
|
42
|
+
name: "MuiTablePaginationActions",
|
|
43
|
+
slot: "Root"
|
|
44
|
+
})({}), rt = /* @__PURE__ */ et.forwardRef(function(n, c) {
|
|
45
|
+
const T = at({
|
|
46
|
+
props: n,
|
|
47
|
+
name: "MuiTablePaginationActions"
|
|
48
|
+
}), {
|
|
49
|
+
backIconButtonProps: h,
|
|
50
|
+
className: F,
|
|
51
|
+
count: y,
|
|
52
|
+
disabled: g = !1,
|
|
53
|
+
getItemAriaLabel: a,
|
|
54
|
+
nextIconButtonProps: j,
|
|
55
|
+
onPageChange: R,
|
|
56
|
+
page: l,
|
|
57
|
+
rowsPerPage: S,
|
|
58
|
+
showFirstButton: D,
|
|
59
|
+
showLastButton: O,
|
|
60
|
+
slots: m = {},
|
|
61
|
+
slotProps: o = {},
|
|
62
|
+
...B
|
|
63
|
+
} = T, i = gt(), U = wt(T), z = (d) => {
|
|
64
|
+
R(d, 0);
|
|
65
|
+
}, x = (d) => {
|
|
66
|
+
R(d, l - 1);
|
|
67
|
+
}, M = (d) => {
|
|
68
|
+
R(d, l + 1);
|
|
69
|
+
}, E = (d) => {
|
|
70
|
+
R(d, Math.max(0, Math.ceil(y / S) - 1));
|
|
71
|
+
}, p = m.firstButton ?? N, r = m.lastButton ?? N, u = m.nextButton ?? N, C = m.previousButton ?? N, v = m.firstButtonIcon ?? St, k = m.lastButtonIcon ?? xt, w = m.nextButtonIcon ?? Bt, A = m.previousButtonIcon ?? Pt, b = i ? r : p, H = i ? u : C, K = i ? C : u, _ = i ? p : r, G = i ? o.lastButton : o.firstButton, V = i ? o.nextButton : o.previousButton, J = i ? o.previousButton : o.nextButton, Q = i ? o.firstButton : o.lastButton;
|
|
72
|
+
return /* @__PURE__ */ st(Lt, {
|
|
73
|
+
ref: c,
|
|
74
|
+
className: q(U.root, F),
|
|
75
|
+
...B,
|
|
76
|
+
children: [D && /* @__PURE__ */ s(b, {
|
|
77
|
+
onClick: z,
|
|
78
|
+
disabled: g || l === 0,
|
|
79
|
+
"aria-label": a("first", l),
|
|
80
|
+
title: a("first", l),
|
|
81
|
+
...G,
|
|
82
|
+
children: i ? /* @__PURE__ */ s(k, {
|
|
83
|
+
...o.lastButtonIcon
|
|
84
|
+
}) : /* @__PURE__ */ s(v, {
|
|
85
|
+
...o.firstButtonIcon
|
|
86
|
+
})
|
|
87
|
+
}), /* @__PURE__ */ s(H, {
|
|
88
|
+
onClick: x,
|
|
89
|
+
disabled: g || l === 0,
|
|
90
|
+
color: "inherit",
|
|
91
|
+
"aria-label": a("previous", l),
|
|
92
|
+
title: a("previous", l),
|
|
93
|
+
...V ?? h,
|
|
94
|
+
children: i ? /* @__PURE__ */ s(w, {
|
|
95
|
+
...o.nextButtonIcon
|
|
96
|
+
}) : /* @__PURE__ */ s(A, {
|
|
97
|
+
...o.previousButtonIcon
|
|
98
|
+
})
|
|
99
|
+
}), /* @__PURE__ */ s(K, {
|
|
100
|
+
onClick: M,
|
|
101
|
+
disabled: g || (y !== -1 ? l >= Math.ceil(y / S) - 1 : !1),
|
|
102
|
+
color: "inherit",
|
|
103
|
+
"aria-label": a("next", l),
|
|
104
|
+
title: a("next", l),
|
|
105
|
+
...J ?? j,
|
|
106
|
+
children: i ? /* @__PURE__ */ s(A, {
|
|
107
|
+
...o.previousButtonIcon
|
|
108
|
+
}) : /* @__PURE__ */ s(w, {
|
|
109
|
+
...o.nextButtonIcon
|
|
110
|
+
})
|
|
111
|
+
}), O && /* @__PURE__ */ s(_, {
|
|
112
|
+
onClick: E,
|
|
113
|
+
disabled: g || l >= Math.ceil(y / S) - 1,
|
|
114
|
+
"aria-label": a("last", l),
|
|
115
|
+
title: a("last", l),
|
|
116
|
+
...Q,
|
|
117
|
+
children: i ? /* @__PURE__ */ s(v, {
|
|
118
|
+
...o.firstButtonIcon
|
|
119
|
+
}) : /* @__PURE__ */ s(k, {
|
|
120
|
+
...o.lastButtonIcon
|
|
121
|
+
})
|
|
122
|
+
})]
|
|
123
|
+
});
|
|
124
|
+
});
|
|
125
|
+
process.env.NODE_ENV !== "production" && (rt.propTypes = {
|
|
126
|
+
// ┌────────────────────────────── Warning ──────────────────────────────┐
|
|
127
|
+
// │ These PropTypes are generated from the TypeScript type definitions. │
|
|
128
|
+
// │ To update them, edit the d.ts file and run `pnpm proptypes`. │
|
|
129
|
+
// └─────────────────────────────────────────────────────────────────────┘
|
|
130
|
+
/**
|
|
131
|
+
* This prop is an alias for `slotProps.previousButton` and will be overriden by it if both are used.
|
|
132
|
+
* @deprecated Use `slotProps.previousButton` instead.
|
|
133
|
+
*/
|
|
134
|
+
backIconButtonProps: t.object,
|
|
135
|
+
/**
|
|
136
|
+
* @ignore
|
|
137
|
+
*/
|
|
138
|
+
children: t.node,
|
|
139
|
+
/**
|
|
140
|
+
* Override or extend the styles applied to the component.
|
|
141
|
+
*/
|
|
142
|
+
classes: t.object,
|
|
143
|
+
/**
|
|
144
|
+
* @ignore
|
|
145
|
+
*/
|
|
146
|
+
className: t.string,
|
|
147
|
+
/**
|
|
148
|
+
* @ignore
|
|
149
|
+
*/
|
|
150
|
+
count: t.number.isRequired,
|
|
151
|
+
/**
|
|
152
|
+
* If `true`, the component is disabled.
|
|
153
|
+
* @default false
|
|
154
|
+
*/
|
|
155
|
+
disabled: t.bool,
|
|
156
|
+
/**
|
|
157
|
+
* Accepts a function which returns a string value that provides a user-friendly name for the current page.
|
|
158
|
+
* This is important for screen reader users.
|
|
159
|
+
*
|
|
160
|
+
* For localization purposes, you can use the provided [translations](https://mui.com/material-ui/guides/localization/).
|
|
161
|
+
* @param {string} type The link or button type to format ('first' | 'last' | 'next' | 'previous').
|
|
162
|
+
* @returns {string}
|
|
163
|
+
*/
|
|
164
|
+
getItemAriaLabel: t.func.isRequired,
|
|
165
|
+
/**
|
|
166
|
+
* This prop is an alias for `slotProps.nextButton` and will be overriden by it if both are used.
|
|
167
|
+
* @deprecated Use `slotProps.nextButton` instead.
|
|
168
|
+
*/
|
|
169
|
+
nextIconButtonProps: t.object,
|
|
170
|
+
/**
|
|
171
|
+
* @ignore
|
|
172
|
+
*/
|
|
173
|
+
onPageChange: t.func.isRequired,
|
|
174
|
+
/**
|
|
175
|
+
* @ignore
|
|
176
|
+
*/
|
|
177
|
+
page: t.number.isRequired,
|
|
178
|
+
/**
|
|
179
|
+
* @ignore
|
|
180
|
+
*/
|
|
181
|
+
rowsPerPage: t.number.isRequired,
|
|
182
|
+
/**
|
|
183
|
+
* @ignore
|
|
184
|
+
*/
|
|
185
|
+
showFirstButton: t.bool.isRequired,
|
|
186
|
+
/**
|
|
187
|
+
* @ignore
|
|
188
|
+
*/
|
|
189
|
+
showLastButton: t.bool.isRequired,
|
|
190
|
+
/**
|
|
191
|
+
* @ignore
|
|
192
|
+
*/
|
|
193
|
+
slotProps: t.shape({
|
|
194
|
+
firstButton: t.object,
|
|
195
|
+
firstButtonIcon: t.object,
|
|
196
|
+
lastButton: t.object,
|
|
197
|
+
lastButtonIcon: t.object,
|
|
198
|
+
nextButton: t.object,
|
|
199
|
+
nextButtonIcon: t.object,
|
|
200
|
+
previousButton: t.object,
|
|
201
|
+
previousButtonIcon: t.object
|
|
202
|
+
}),
|
|
203
|
+
/**
|
|
204
|
+
* @ignore
|
|
205
|
+
*/
|
|
206
|
+
slots: t.shape({
|
|
207
|
+
firstButton: t.elementType,
|
|
208
|
+
firstButtonIcon: t.elementType,
|
|
209
|
+
lastButton: t.elementType,
|
|
210
|
+
lastButtonIcon: t.elementType,
|
|
211
|
+
nextButton: t.elementType,
|
|
212
|
+
nextButtonIcon: t.elementType,
|
|
213
|
+
previousButton: t.elementType,
|
|
214
|
+
previousButtonIcon: t.elementType
|
|
215
|
+
})
|
|
216
|
+
});
|
|
217
|
+
function jt(e) {
|
|
218
|
+
return nt("MuiTablePagination", e);
|
|
219
|
+
}
|
|
220
|
+
const L = ot("MuiTablePagination", ["root", "toolbar", "spacer", "selectLabel", "selectRoot", "select", "selectIcon", "input", "menuItem", "displayedRows", "actions"]);
|
|
221
|
+
var tt;
|
|
222
|
+
const Mt = P(X, {
|
|
223
|
+
name: "MuiTablePagination",
|
|
224
|
+
slot: "Root"
|
|
225
|
+
})($(({
|
|
226
|
+
theme: e
|
|
227
|
+
}) => ({
|
|
228
|
+
overflow: "auto",
|
|
229
|
+
color: (e.vars || e).palette.text.primary,
|
|
230
|
+
fontSize: e.typography.pxToRem(14),
|
|
231
|
+
// Increase the specificity to override TableCell.
|
|
232
|
+
"&:last-child": {
|
|
233
|
+
padding: 0
|
|
234
|
+
}
|
|
235
|
+
}))), Ct = P(ht, {
|
|
236
|
+
name: "MuiTablePagination",
|
|
237
|
+
slot: "Toolbar",
|
|
238
|
+
overridesResolver: (e, n) => ({
|
|
239
|
+
[`& .${L.actions}`]: n.actions,
|
|
240
|
+
...n.toolbar
|
|
241
|
+
})
|
|
242
|
+
})($(({
|
|
243
|
+
theme: e
|
|
244
|
+
}) => ({
|
|
245
|
+
minHeight: 52,
|
|
246
|
+
paddingRight: 2,
|
|
247
|
+
[`${e.breakpoints.up("xs")} and (orientation: landscape)`]: {
|
|
248
|
+
minHeight: 52
|
|
249
|
+
},
|
|
250
|
+
[e.breakpoints.up("sm")]: {
|
|
251
|
+
minHeight: 52,
|
|
252
|
+
paddingRight: 2
|
|
253
|
+
},
|
|
254
|
+
[`& .${L.actions}`]: {
|
|
255
|
+
flexShrink: 0,
|
|
256
|
+
marginLeft: 20
|
|
257
|
+
}
|
|
258
|
+
}))), kt = P("div", {
|
|
259
|
+
name: "MuiTablePagination",
|
|
260
|
+
slot: "Spacer"
|
|
261
|
+
})({
|
|
262
|
+
flex: "1 1 100%"
|
|
263
|
+
}), At = P("p", {
|
|
264
|
+
name: "MuiTablePagination",
|
|
265
|
+
slot: "SelectLabel"
|
|
266
|
+
})($(({
|
|
267
|
+
theme: e
|
|
268
|
+
}) => ({
|
|
269
|
+
...e.typography.body2,
|
|
270
|
+
flexShrink: 0
|
|
271
|
+
}))), Nt = P(yt, {
|
|
272
|
+
name: "MuiTablePagination",
|
|
273
|
+
slot: "Select",
|
|
274
|
+
overridesResolver: (e, n) => ({
|
|
275
|
+
[`& .${L.selectIcon}`]: n.selectIcon,
|
|
276
|
+
[`& .${L.select}`]: n.select,
|
|
277
|
+
...n.input,
|
|
278
|
+
...n.selectRoot
|
|
279
|
+
})
|
|
280
|
+
})({
|
|
281
|
+
color: "inherit",
|
|
282
|
+
fontSize: "inherit",
|
|
283
|
+
flexShrink: 0,
|
|
284
|
+
marginRight: 32,
|
|
285
|
+
marginLeft: 8,
|
|
286
|
+
[`& .${L.select}`]: {
|
|
287
|
+
paddingLeft: 8,
|
|
288
|
+
paddingRight: 24,
|
|
289
|
+
textAlign: "right",
|
|
290
|
+
textAlignLast: "right"
|
|
291
|
+
// Align <select> on Chrome.
|
|
292
|
+
}
|
|
293
|
+
}), qt = P(It, {
|
|
294
|
+
name: "MuiTablePagination",
|
|
295
|
+
slot: "MenuItem"
|
|
296
|
+
})({}), $t = P("p", {
|
|
297
|
+
name: "MuiTablePagination",
|
|
298
|
+
slot: "DisplayedRows"
|
|
299
|
+
})($(({
|
|
300
|
+
theme: e
|
|
301
|
+
}) => ({
|
|
302
|
+
...e.typography.body2,
|
|
303
|
+
flexShrink: 0
|
|
304
|
+
})));
|
|
305
|
+
function Ft({
|
|
306
|
+
from: e,
|
|
307
|
+
to: n,
|
|
308
|
+
count: c
|
|
309
|
+
}) {
|
|
310
|
+
return `${e}–${n} of ${c !== -1 ? c : `more than ${n}`}`;
|
|
311
|
+
}
|
|
312
|
+
function Dt(e) {
|
|
313
|
+
return `Go to ${e} page`;
|
|
314
|
+
}
|
|
315
|
+
const Ot = (e) => {
|
|
316
|
+
const {
|
|
317
|
+
classes: n
|
|
318
|
+
} = e;
|
|
319
|
+
return it({
|
|
320
|
+
root: ["root"],
|
|
321
|
+
toolbar: ["toolbar"],
|
|
322
|
+
spacer: ["spacer"],
|
|
323
|
+
selectLabel: ["selectLabel"],
|
|
324
|
+
select: ["select"],
|
|
325
|
+
input: ["input"],
|
|
326
|
+
selectIcon: ["selectIcon"],
|
|
327
|
+
menuItem: ["menuItem"],
|
|
328
|
+
displayedRows: ["displayedRows"],
|
|
329
|
+
actions: ["actions"]
|
|
330
|
+
}, jt, n);
|
|
331
|
+
}, Ut = /* @__PURE__ */ et.forwardRef(function(n, c) {
|
|
332
|
+
const T = at({
|
|
333
|
+
props: n,
|
|
334
|
+
name: "MuiTablePagination"
|
|
335
|
+
}), {
|
|
336
|
+
ActionsComponent: h = rt,
|
|
337
|
+
backIconButtonProps: F,
|
|
338
|
+
colSpan: y,
|
|
339
|
+
component: g = X,
|
|
340
|
+
count: a,
|
|
341
|
+
disabled: j = !1,
|
|
342
|
+
getItemAriaLabel: R = Dt,
|
|
343
|
+
labelDisplayedRows: l = Ft,
|
|
344
|
+
labelRowsPerPage: S = "Rows per page:",
|
|
345
|
+
nextIconButtonProps: D,
|
|
346
|
+
onPageChange: O,
|
|
347
|
+
onRowsPerPageChange: m,
|
|
348
|
+
page: o,
|
|
349
|
+
rowsPerPage: B,
|
|
350
|
+
rowsPerPageOptions: i = [10, 25, 50, 100],
|
|
351
|
+
SelectProps: Y = {},
|
|
352
|
+
showFirstButton: U = !1,
|
|
353
|
+
showLastButton: z = !1,
|
|
354
|
+
slotProps: x = {},
|
|
355
|
+
slots: M = {},
|
|
356
|
+
...E
|
|
357
|
+
} = T, p = T, r = Ot(p), u = x?.select ?? Y, C = u.native ? "option" : qt;
|
|
358
|
+
let v;
|
|
359
|
+
(g === X || g === "td") && (v = y || 1e3);
|
|
360
|
+
const k = Z(u.id), w = Z(u.labelId), A = () => a === -1 ? (o + 1) * B : B === -1 ? a : Math.min(a, (o + 1) * B), b = {
|
|
361
|
+
slots: M,
|
|
362
|
+
slotProps: x
|
|
363
|
+
}, [H, K] = I("root", {
|
|
364
|
+
ref: c,
|
|
365
|
+
className: r.root,
|
|
366
|
+
elementType: Mt,
|
|
367
|
+
externalForwardedProps: {
|
|
368
|
+
...b,
|
|
369
|
+
component: g,
|
|
370
|
+
...E
|
|
371
|
+
},
|
|
372
|
+
ownerState: p,
|
|
373
|
+
additionalProps: {
|
|
374
|
+
colSpan: v
|
|
375
|
+
}
|
|
376
|
+
}), [_, G] = I("toolbar", {
|
|
377
|
+
className: r.toolbar,
|
|
378
|
+
elementType: Ct,
|
|
379
|
+
externalForwardedProps: b,
|
|
380
|
+
ownerState: p
|
|
381
|
+
}), [V, J] = I("spacer", {
|
|
382
|
+
className: r.spacer,
|
|
383
|
+
elementType: kt,
|
|
384
|
+
externalForwardedProps: b,
|
|
385
|
+
ownerState: p
|
|
386
|
+
}), [Q, d] = I("selectLabel", {
|
|
387
|
+
className: r.selectLabel,
|
|
388
|
+
elementType: At,
|
|
389
|
+
externalForwardedProps: b,
|
|
390
|
+
ownerState: p,
|
|
391
|
+
additionalProps: {
|
|
392
|
+
id: w
|
|
393
|
+
}
|
|
394
|
+
}), [ct, ut] = I("select", {
|
|
395
|
+
className: r.select,
|
|
396
|
+
elementType: Nt,
|
|
397
|
+
externalForwardedProps: b,
|
|
398
|
+
ownerState: p
|
|
399
|
+
}), [pt, mt] = I("menuItem", {
|
|
400
|
+
className: r.menuItem,
|
|
401
|
+
elementType: C,
|
|
402
|
+
externalForwardedProps: b,
|
|
403
|
+
ownerState: p
|
|
404
|
+
}), [bt, dt] = I("displayedRows", {
|
|
405
|
+
className: r.displayedRows,
|
|
406
|
+
elementType: $t,
|
|
407
|
+
externalForwardedProps: b,
|
|
408
|
+
ownerState: p
|
|
409
|
+
});
|
|
410
|
+
return /* @__PURE__ */ s(H, {
|
|
411
|
+
...K,
|
|
412
|
+
children: /* @__PURE__ */ st(_, {
|
|
413
|
+
...G,
|
|
414
|
+
children: [/* @__PURE__ */ s(V, {
|
|
415
|
+
...J
|
|
416
|
+
}), i.length > 1 && /* @__PURE__ */ s(Q, {
|
|
417
|
+
...d,
|
|
418
|
+
children: S
|
|
419
|
+
}), i.length > 1 && /* @__PURE__ */ s(ct, {
|
|
420
|
+
variant: "standard",
|
|
421
|
+
...!u.variant && {
|
|
422
|
+
input: tt || (tt = /* @__PURE__ */ s(Tt, {}))
|
|
423
|
+
},
|
|
424
|
+
value: B,
|
|
425
|
+
onChange: m,
|
|
426
|
+
id: k,
|
|
427
|
+
labelId: w,
|
|
428
|
+
...u,
|
|
429
|
+
classes: {
|
|
430
|
+
...u.classes,
|
|
431
|
+
// TODO v5 remove `classes.input`
|
|
432
|
+
root: q(r.input, r.selectRoot, (u.classes || {}).root),
|
|
433
|
+
select: q(r.select, (u.classes || {}).select),
|
|
434
|
+
// TODO v5 remove `selectIcon`
|
|
435
|
+
icon: q(r.selectIcon, (u.classes || {}).icon)
|
|
436
|
+
},
|
|
437
|
+
disabled: j,
|
|
438
|
+
...ut,
|
|
439
|
+
children: i.map((f) => /* @__PURE__ */ ft(pt, {
|
|
440
|
+
...mt,
|
|
441
|
+
key: f.label ? f.label : f,
|
|
442
|
+
value: f.value ? f.value : f
|
|
443
|
+
}, f.label ? f.label : f))
|
|
444
|
+
}), /* @__PURE__ */ s(bt, {
|
|
445
|
+
...dt,
|
|
446
|
+
children: l({
|
|
447
|
+
from: a === 0 ? 0 : o * B + 1,
|
|
448
|
+
to: A(),
|
|
449
|
+
count: a === -1 ? -1 : a,
|
|
450
|
+
page: o
|
|
451
|
+
})
|
|
452
|
+
}), /* @__PURE__ */ s(h, {
|
|
453
|
+
className: r.actions,
|
|
454
|
+
backIconButtonProps: F,
|
|
455
|
+
count: a,
|
|
456
|
+
nextIconButtonProps: D,
|
|
457
|
+
onPageChange: O,
|
|
458
|
+
page: o,
|
|
459
|
+
rowsPerPage: B,
|
|
460
|
+
showFirstButton: U,
|
|
461
|
+
showLastButton: z,
|
|
462
|
+
slotProps: x.actions,
|
|
463
|
+
slots: M.actions,
|
|
464
|
+
getItemAriaLabel: R,
|
|
465
|
+
disabled: j
|
|
466
|
+
})]
|
|
467
|
+
})
|
|
468
|
+
});
|
|
469
|
+
});
|
|
470
|
+
process.env.NODE_ENV !== "production" && (Ut.propTypes = {
|
|
471
|
+
// ┌────────────────────────────── Warning ──────────────────────────────┐
|
|
472
|
+
// │ These PropTypes are generated from the TypeScript type definitions. │
|
|
473
|
+
// │ To update them, edit the d.ts file and run `pnpm proptypes`. │
|
|
474
|
+
// └─────────────────────────────────────────────────────────────────────┘
|
|
475
|
+
/**
|
|
476
|
+
* The component used for displaying the actions.
|
|
477
|
+
* Either a string to use a HTML element or a component.
|
|
478
|
+
* @default TablePaginationActions
|
|
479
|
+
*/
|
|
480
|
+
ActionsComponent: t.elementType,
|
|
481
|
+
/**
|
|
482
|
+
* Props applied to the back arrow [`IconButton`](https://mui.com/material-ui/api/icon-button/) component.
|
|
483
|
+
*
|
|
484
|
+
* This prop is an alias for `slotProps.actions.previousButton` and will be overriden by it if both are used.
|
|
485
|
+
* @deprecated Use `slotProps.actions.previousButton` instead.
|
|
486
|
+
*/
|
|
487
|
+
backIconButtonProps: t.object,
|
|
488
|
+
/**
|
|
489
|
+
* Override or extend the styles applied to the component.
|
|
490
|
+
*/
|
|
491
|
+
classes: t.object,
|
|
492
|
+
/**
|
|
493
|
+
* @ignore
|
|
494
|
+
*/
|
|
495
|
+
colSpan: t.number,
|
|
496
|
+
/**
|
|
497
|
+
* The component used for the root node.
|
|
498
|
+
* Either a string to use a HTML element or a component.
|
|
499
|
+
*/
|
|
500
|
+
component: t.elementType,
|
|
501
|
+
/**
|
|
502
|
+
* The total number of rows.
|
|
503
|
+
*
|
|
504
|
+
* To enable server side pagination for an unknown number of items, provide -1.
|
|
505
|
+
*/
|
|
506
|
+
count: W.isRequired,
|
|
507
|
+
/**
|
|
508
|
+
* If `true`, the component is disabled.
|
|
509
|
+
* @default false
|
|
510
|
+
*/
|
|
511
|
+
disabled: t.bool,
|
|
512
|
+
/**
|
|
513
|
+
* Accepts a function which returns a string value that provides a user-friendly name for the current page.
|
|
514
|
+
* This is important for screen reader users.
|
|
515
|
+
*
|
|
516
|
+
* For localization purposes, you can use the provided [translations](https://mui.com/material-ui/guides/localization/).
|
|
517
|
+
* @param {string} type The link or button type to format ('first' | 'last' | 'next' | 'previous').
|
|
518
|
+
* @returns {string}
|
|
519
|
+
* @default function defaultGetAriaLabel(type) {
|
|
520
|
+
* return `Go to ${type} page`;
|
|
521
|
+
* }
|
|
522
|
+
*/
|
|
523
|
+
getItemAriaLabel: t.func,
|
|
524
|
+
/**
|
|
525
|
+
* Customize the displayed rows label. Invoked with a `{ from, to, count, page }`
|
|
526
|
+
* object.
|
|
527
|
+
*
|
|
528
|
+
* For localization purposes, you can use the provided [translations](https://mui.com/material-ui/guides/localization/).
|
|
529
|
+
* @default function defaultLabelDisplayedRows({ from, to, count }) {
|
|
530
|
+
* return `${from}–${to} of ${count !== -1 ? count : `more than ${to}`}`;
|
|
531
|
+
* }
|
|
532
|
+
*/
|
|
533
|
+
labelDisplayedRows: t.func,
|
|
534
|
+
/**
|
|
535
|
+
* Customize the rows per page label.
|
|
536
|
+
*
|
|
537
|
+
* For localization purposes, you can use the provided [translations](https://mui.com/material-ui/guides/localization/).
|
|
538
|
+
* @default 'Rows per page:'
|
|
539
|
+
*/
|
|
540
|
+
labelRowsPerPage: t.node,
|
|
541
|
+
/**
|
|
542
|
+
* Props applied to the next arrow [`IconButton`](https://mui.com/material-ui/api/icon-button/) element.
|
|
543
|
+
*
|
|
544
|
+
* This prop is an alias for `slotProps.actions.nextButton` and will be overriden by it if both are used.
|
|
545
|
+
* @deprecated Use `slotProps.actions.nextButton` instead.
|
|
546
|
+
*/
|
|
547
|
+
nextIconButtonProps: t.object,
|
|
548
|
+
/**
|
|
549
|
+
* Callback fired when the page is changed.
|
|
550
|
+
*
|
|
551
|
+
* @param {React.MouseEvent<HTMLButtonElement> | null} event The event source of the callback.
|
|
552
|
+
* @param {number} page The page selected.
|
|
553
|
+
*/
|
|
554
|
+
onPageChange: t.func.isRequired,
|
|
555
|
+
/**
|
|
556
|
+
* Callback fired when the number of rows per page is changed.
|
|
557
|
+
*
|
|
558
|
+
* @param {React.ChangeEvent<HTMLTextAreaElement | HTMLInputElement>} event The event source of the callback.
|
|
559
|
+
*/
|
|
560
|
+
onRowsPerPageChange: t.func,
|
|
561
|
+
/**
|
|
562
|
+
* The zero-based index of the current page.
|
|
563
|
+
*/
|
|
564
|
+
page: Rt(W.isRequired, (e) => {
|
|
565
|
+
const {
|
|
566
|
+
count: n,
|
|
567
|
+
page: c,
|
|
568
|
+
rowsPerPage: T
|
|
569
|
+
} = e;
|
|
570
|
+
if (n === -1)
|
|
571
|
+
return null;
|
|
572
|
+
const h = Math.max(0, Math.ceil(n / T) - 1);
|
|
573
|
+
return c < 0 || c > h ? new Error(`MUI: The page prop of a TablePagination is out of range (0 to ${h}, but page is ${c}).`) : null;
|
|
574
|
+
}),
|
|
575
|
+
/**
|
|
576
|
+
* The number of rows per page.
|
|
577
|
+
*
|
|
578
|
+
* Set -1 to display all the rows.
|
|
579
|
+
*/
|
|
580
|
+
rowsPerPage: W.isRequired,
|
|
581
|
+
/**
|
|
582
|
+
* Customizes the options of the rows per page select field. If less than two options are
|
|
583
|
+
* available, no select field will be displayed.
|
|
584
|
+
* Use -1 for the value with a custom label to show all the rows.
|
|
585
|
+
* @default [10, 25, 50, 100]
|
|
586
|
+
*/
|
|
587
|
+
rowsPerPageOptions: t.arrayOf(t.oneOfType([t.number, t.shape({
|
|
588
|
+
label: t.string.isRequired,
|
|
589
|
+
value: t.number.isRequired
|
|
590
|
+
})]).isRequired),
|
|
591
|
+
/**
|
|
592
|
+
* Props applied to the rows per page [`Select`](https://mui.com/material-ui/api/select/) element.
|
|
593
|
+
*
|
|
594
|
+
* This prop is an alias for `slotProps.select` and will be overriden by it if both are used.
|
|
595
|
+
* @deprecated Use `slotProps.select` instead.
|
|
596
|
+
*
|
|
597
|
+
* @default {}
|
|
598
|
+
*/
|
|
599
|
+
SelectProps: t.object,
|
|
600
|
+
/**
|
|
601
|
+
* If `true`, show the first-page button.
|
|
602
|
+
* @default false
|
|
603
|
+
*/
|
|
604
|
+
showFirstButton: t.bool,
|
|
605
|
+
/**
|
|
606
|
+
* If `true`, show the last-page button.
|
|
607
|
+
* @default false
|
|
608
|
+
*/
|
|
609
|
+
showLastButton: t.bool,
|
|
610
|
+
/**
|
|
611
|
+
* The props used for each slot inside.
|
|
612
|
+
* @default {}
|
|
613
|
+
*/
|
|
614
|
+
slotProps: t.shape({
|
|
615
|
+
actions: t.shape({
|
|
616
|
+
firstButton: t.object,
|
|
617
|
+
firstButtonIcon: t.object,
|
|
618
|
+
lastButton: t.object,
|
|
619
|
+
lastButtonIcon: t.object,
|
|
620
|
+
nextButton: t.object,
|
|
621
|
+
nextButtonIcon: t.object,
|
|
622
|
+
previousButton: t.object,
|
|
623
|
+
previousButtonIcon: t.object
|
|
624
|
+
}),
|
|
625
|
+
displayedRows: t.oneOfType([t.func, t.object]),
|
|
626
|
+
menuItem: t.oneOfType([t.func, t.object]),
|
|
627
|
+
root: t.oneOfType([t.func, t.object]),
|
|
628
|
+
select: t.object,
|
|
629
|
+
selectLabel: t.oneOfType([t.func, t.object]),
|
|
630
|
+
spacer: t.oneOfType([t.func, t.object]),
|
|
631
|
+
toolbar: t.oneOfType([t.func, t.object])
|
|
632
|
+
}),
|
|
633
|
+
/**
|
|
634
|
+
* The components used for each slot inside.
|
|
635
|
+
* @default {}
|
|
636
|
+
*/
|
|
637
|
+
slots: t.shape({
|
|
638
|
+
actions: t.shape({
|
|
639
|
+
firstButton: t.elementType,
|
|
640
|
+
firstButtonIcon: t.elementType,
|
|
641
|
+
lastButton: t.elementType,
|
|
642
|
+
lastButtonIcon: t.elementType,
|
|
643
|
+
nextButton: t.elementType,
|
|
644
|
+
nextButtonIcon: t.elementType,
|
|
645
|
+
previousButton: t.elementType,
|
|
646
|
+
previousButtonIcon: t.elementType
|
|
647
|
+
}),
|
|
648
|
+
displayedRows: t.elementType,
|
|
649
|
+
menuItem: t.elementType,
|
|
650
|
+
root: t.elementType,
|
|
651
|
+
select: t.elementType,
|
|
652
|
+
selectLabel: t.elementType,
|
|
653
|
+
spacer: t.elementType,
|
|
654
|
+
toolbar: t.elementType
|
|
655
|
+
}),
|
|
656
|
+
/**
|
|
657
|
+
* The system prop that allows defining system overrides as well as additional CSS styles.
|
|
658
|
+
*/
|
|
659
|
+
sx: t.oneOfType([t.arrayOf(t.oneOfType([t.func, t.object, t.bool])), t.func, t.object])
|
|
660
|
+
});
|
|
661
|
+
export {
|
|
662
|
+
Ut as T,
|
|
663
|
+
jt as g,
|
|
664
|
+
L as t
|
|
665
|
+
};
|