fansunited-frontend-components 0.0.39 → 0.0.40

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 (48) hide show
  1. package/ChanceGame.js +104 -102
  2. package/ClassicQuizPlay.js +45 -42
  3. package/CollectLead.js +25 -24
  4. package/Discussion.js +376 -378
  5. package/EitherOrPlay.d.ts +4 -0
  6. package/EitherOrPlay.d.ts.map +1 -0
  7. package/EitherOrPlay.js +2533 -0
  8. package/EventGamePlay.js +59 -54
  9. package/MatchQuizPlay.js +63 -57
  10. package/PersonalityQuizPlay.js +7935 -7201
  11. package/PickThePair.js +153 -151
  12. package/PollVote.js +108 -104
  13. package/chunks/{AlertMessage-C2aBXCrl.js → AlertMessage-cjTHrMUK.js} +51 -51
  14. package/chunks/ArrowRightAlt-88jKjh6A.js +8 -0
  15. package/chunks/Avatar-CQCrd1m-.js +352 -0
  16. package/chunks/ChanceGameEmbedVariant-DWqOTf4o.js +1051 -0
  17. package/chunks/{CheckCircle-D-GH16Lb.js → CheckCircle-ClY-iOQ5.js} +105 -105
  18. package/chunks/{CollectLeadForm-o9NdYQgu.js → CollectLeadForm-0vVnu4DL.js} +5 -5
  19. package/chunks/FavoriteBorder-BHnvGBrn.js +11 -0
  20. package/chunks/{useInfoPage-v91yL5SS.js → NotFoundSkeleton-B3RNa8KJ.js} +451 -646
  21. package/chunks/Notification-BTtUhfZQ.js +615 -0
  22. package/chunks/OverlayLeadAfterCollection-CaBbwZVo.js +480 -0
  23. package/chunks/{OverlayScoreStateSkeleton-xvq9lQEi.js → OverlayScoreStateSkeleton-DJn0Rim3.js} +3 -3
  24. package/chunks/Person-D0Im9_zE.js +522 -0
  25. package/chunks/{PickOneOfX-C2YpLk40.js → PickOneOfX-DYQ4c1o2.js} +7 -7
  26. package/chunks/{Portal-DWAr8MhA.js → Portal-B9wkUnY2.js} +7 -7
  27. package/chunks/{ConstantsProvider-BPJJz9fq.js → PrizeCard-gMp7I66d.js} +3593 -2860
  28. package/chunks/{Spinner-m59ZJZ35.js → Spinner-BBA89t5s.js} +50 -50
  29. package/chunks/StandardLeadAfterCollection-L1cOGfS6.js +432 -0
  30. package/chunks/{Tabs-BGihvj9C.js → Tabs-D_n8rNw3.js} +28 -28
  31. package/chunks/{Textarea-Bzlb89Zp.js → Textarea-BdN2xj4j.js} +44 -44
  32. package/chunks/{TimerOutlined-DiX8hCoC.js → TimerOutlined-DmKZDDI-.js} +1 -1
  33. package/chunks/chevron-right-DGEksBI7.js +330 -0
  34. package/chunks/default-quiz-bg-vertical-CT7rrg9o.js +5 -0
  35. package/chunks/index-2s5UkG1y.js +1607 -0
  36. package/chunks/useImageVariant-pnFelF9A.js +535 -0
  37. package/chunks/useInfoPage-DPkzE5Gn.js +204 -0
  38. package/components.d.ts +2 -1
  39. package/components.d.ts.map +1 -1
  40. package/index.d.ts +1 -0
  41. package/index.d.ts.map +1 -1
  42. package/index.js +4 -2
  43. package/package.json +1 -1
  44. package/chunks/ChanceGameEmbedVariant-BvIKBhq_.js +0 -2609
  45. package/chunks/Notification-Bwcoljir.js +0 -961
  46. package/chunks/OverlayLeadAfterCollection-B3D5ct0J.js +0 -901
  47. package/chunks/chevron-right-Dlc9ZKhv.js +0 -846
  48. package/chunks/useImageVariant-Do8kOVs2.js +0 -537
@@ -1,846 +0,0 @@
1
- import { m as k, n as A, s as x, _ as p, ah as X, ai as F, P as o, p as O, k as $, q as B, K as W, t as _, O as Y, ag as N, Q as K, R as V, r as m, aj as q, d as R } from "./ConstantsProvider-BPJJz9fq.js";
2
- import * as w from "react";
3
- import { forwardRef as L, createElement as P } from "react";
4
- import { c as Q } from "./Spinner-m59ZJZ35.js";
5
- import { a as Z } from "./useInfoPage-v91yL5SS.js";
6
- import { d as G } from "./Notification-Bwcoljir.js";
7
- import { jsx as b } from "react/jsx-runtime";
8
- function oo(e) {
9
- return A("MuiCardActions", e);
10
- }
11
- k("MuiCardActions", ["root"]);
12
- const eo = ["className", "component", "children", "buttonFlex", "orientation", "slots", "slotProps"], to = () => _({
13
- root: ["root"]
14
- }, oo, {}), H = x("div")(({
15
- ownerState: e
16
- }) => {
17
- var t;
18
- return p({
19
- "--Button-radius": "var(--Card-childRadius)",
20
- "--IconButton-radius": "var(--Card-childRadius)",
21
- display: "flex"
22
- }, ((t = e.orientation) == null ? void 0 : t.startsWith("horizontal")) && {
23
- alignItems: "center"
24
- // it is common to have children aligned center in horizontal orientation, but not vertically.
25
- }, {
26
- flexDirection: e.orientation === "horizontal" ? "row" : "column"
27
- }, e.orientation === "horizontal-reverse" && {
28
- flexDirection: "row-reverse"
29
- }, {
30
- zIndex: 1,
31
- // render above Link's overlay
32
- gap: "calc(0.625 * var(--Card-padding))",
33
- padding: "var(--unstable_padding)",
34
- "--unstable_padding": "calc(0.75 * var(--Card-padding)) 0 0 0",
35
- [`.${Z.root} > &`]: {
36
- "--unstable_padding": "calc(0.75 * var(--Card-padding)) 0 var(--Card-padding)"
37
- },
38
- [`.${Q.root} > .${G.root} + &`]: {
39
- "--unstable_padding": "0"
40
- }
41
- }, e.buttonFlex ? {
42
- [`& > :not(.${X.root})`]: {
43
- flex: e.buttonFlex
44
- },
45
- [`& > :not(button) > .${F.root}`]: {
46
- width: "100%"
47
- // for button to fill its wrapper.
48
- }
49
- } : {
50
- [`& > .${F.root}:only-child`]: {
51
- flex: "auto"
52
- }
53
- });
54
- }), ro = x(H, {
55
- name: "JoyCardActions",
56
- slot: "Root",
57
- overridesResolver: (e, t) => t.root
58
- })({}), ao = /* @__PURE__ */ w.forwardRef(function(t, a) {
59
- const r = O({
60
- props: t,
61
- name: "JoyCardActions"
62
- }), {
63
- className: s,
64
- component: l = "div",
65
- children: i,
66
- buttonFlex: c,
67
- orientation: u = "horizontal",
68
- slots: n = {},
69
- slotProps: v = {}
70
- } = r, h = $(r, eo), g = p({}, h, {
71
- component: l,
72
- slots: n,
73
- slotProps: v
74
- }), y = p({}, r, {
75
- component: l,
76
- buttonFlex: c,
77
- orientation: u
78
- }), f = to(), [C, T] = B("root", {
79
- ref: a,
80
- className: W(f.root, s),
81
- elementType: ro,
82
- externalForwardedProps: g,
83
- ownerState: y
84
- });
85
- return /* @__PURE__ */ b(C, p({}, T, {
86
- children: i
87
- }));
88
- });
89
- process.env.NODE_ENV !== "production" && (ao.propTypes = {
90
- // ┌────────────────────────────── Warning ──────────────────────────────┐
91
- // │ These PropTypes are generated from the TypeScript type definitions. │
92
- // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │
93
- // └─────────────────────────────────────────────────────────────────────┘
94
- /**
95
- * The CSS `flex` for the Button and its wrapper.
96
- */
97
- buttonFlex: o.oneOfType([o.number, o.string]),
98
- /**
99
- * Used to render icon or text elements inside the CardActions if `src` is not set.
100
- * This can be an element, or just a string.
101
- */
102
- children: o.node,
103
- /**
104
- * @ignore
105
- */
106
- className: o.string,
107
- /**
108
- * The component used for the root node.
109
- * Either a string to use a HTML element or a component.
110
- */
111
- component: o.elementType,
112
- /**
113
- * The component orientation.
114
- * @default 'horizontal'
115
- */
116
- orientation: o.oneOf(["horizontal-reverse", "horizontal", "vertical"]),
117
- /**
118
- * The props used for each slot inside.
119
- * @default {}
120
- */
121
- slotProps: o.shape({
122
- root: o.oneOfType([o.func, o.object])
123
- }),
124
- /**
125
- * The components used for each slot inside.
126
- * @default {}
127
- */
128
- slots: o.shape({
129
- root: o.elementType
130
- }),
131
- /**
132
- * The system prop that allows defining system overrides as well as additional CSS styles.
133
- */
134
- sx: o.oneOfType([o.arrayOf(o.oneOfType([o.func, o.object, o.bool])), o.func, o.object])
135
- });
136
- function so(e) {
137
- return A("MuiDialogActions", e);
138
- }
139
- k("MuiDialogActions", ["root"]);
140
- const lo = ["component", "children", "buttonFlex", "orientation", "slots", "slotProps"], no = () => _({
141
- root: ["root"]
142
- }, so, {}), io = x(H, {
143
- name: "JoyDialogActions",
144
- slot: "Root",
145
- overridesResolver: (e, t) => t.root
146
- })({}), co = /* @__PURE__ */ w.forwardRef(function(t, a) {
147
- const r = O({
148
- props: t,
149
- name: "JoyDialogActions"
150
- }), {
151
- component: s = "div",
152
- children: l,
153
- buttonFlex: i,
154
- orientation: c = "horizontal-reverse",
155
- slots: u = {},
156
- slotProps: n = {}
157
- } = r, v = $(r, lo), h = p({}, v, {
158
- component: s,
159
- slots: u,
160
- slotProps: n
161
- }), g = p({}, r, {
162
- component: s,
163
- buttonFlex: i,
164
- orientation: c
165
- }), y = no(), [f, C] = B("root", {
166
- ref: a,
167
- className: y.root,
168
- elementType: io,
169
- externalForwardedProps: h,
170
- ownerState: g
171
- });
172
- return /* @__PURE__ */ b(f, p({}, C, {
173
- children: l
174
- }));
175
- });
176
- process.env.NODE_ENV !== "production" && (co.propTypes = {
177
- // ┌────────────────────────────── Warning ──────────────────────────────┐
178
- // │ These PropTypes are generated from the TypeScript type definitions. │
179
- // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │
180
- // └─────────────────────────────────────────────────────────────────────┘
181
- /**
182
- * The CSS `flex` for the Button and its wrapper.
183
- */
184
- buttonFlex: o.oneOfType([o.number, o.string]),
185
- /**
186
- * Used to render icon or text elements inside the DialogActions if `src` is not set.
187
- * This can be an element, or just a string.
188
- */
189
- children: o.node,
190
- /**
191
- * The component used for the root node.
192
- * Either a string to use a HTML element or a component.
193
- */
194
- component: o.elementType,
195
- /**
196
- * The component orientation.
197
- * @default 'horizontal-reverse'
198
- */
199
- orientation: o.oneOf(["horizontal-reverse", "horizontal", "vertical"]),
200
- /**
201
- * The props used for each slot inside.
202
- * @default {}
203
- */
204
- slotProps: o.shape({
205
- root: o.oneOfType([o.func, o.object])
206
- }),
207
- /**
208
- * The components used for each slot inside.
209
- * @default {}
210
- */
211
- slots: o.shape({
212
- root: o.elementType
213
- }),
214
- /**
215
- * The system prop that allows defining system overrides as well as additional CSS styles.
216
- */
217
- sx: o.oneOfType([o.arrayOf(o.oneOfType([o.func, o.object, o.bool])), o.func, o.object])
218
- });
219
- function po(e) {
220
- return A("MuiSheet", e);
221
- }
222
- k("MuiSheet", ["root", "colorPrimary", "colorNeutral", "colorDanger", "colorSuccess", "colorWarning", "colorContext", "variantPlain", "variantOutlined", "variantSoft", "variantSolid"]);
223
- const uo = ["className", "color", "component", "variant", "invertedColors", "slots", "slotProps"], bo = (e) => {
224
- const {
225
- variant: t,
226
- color: a
227
- } = e, r = {
228
- root: ["root", t && `variant${m(t)}`, a && `color${m(a)}`]
229
- };
230
- return _(r, po, {});
231
- }, vo = x("div", {
232
- name: "JoySheet",
233
- slot: "Root",
234
- overridesResolver: (e, t) => t.root
235
- })(({
236
- theme: e,
237
- ownerState: t
238
- }) => {
239
- var a, r;
240
- const s = (a = e.variants[t.variant]) == null ? void 0 : a[t.color], {
241
- borderRadius: l,
242
- bgcolor: i,
243
- backgroundColor: c,
244
- background: u
245
- } = Y({
246
- theme: e,
247
- ownerState: t
248
- }, ["borderRadius", "bgcolor", "backgroundColor", "background"]), n = N(e, `palette.${i}`) || i || N(e, `palette.${c}`) || c || u || (s == null ? void 0 : s.backgroundColor) || (s == null ? void 0 : s.background) || e.vars.palette.background.surface;
249
- return [p({
250
- "--Icon-color": t.color !== "neutral" || t.variant === "solid" ? "currentColor" : e.vars.palette.text.icon,
251
- "--ListItem-stickyBackground": n === "transparent" ? "initial" : n,
252
- // for sticky List
253
- "--Sheet-background": n === "transparent" ? "initial" : n
254
- }, l !== void 0 && {
255
- "--List-radius": `calc(${l} - var(--variant-borderWidth, 0px))`,
256
- "--unstable_actionRadius": `calc(${l} - var(--variant-borderWidth, 0px))`
257
- }, {
258
- backgroundColor: e.vars.palette.background.surface,
259
- position: "relative"
260
- }), p({}, e.typography["body-md"], t.variant === "solid" && t.color && t.invertedColors && K(t.color)(e), t.variant === "soft" && t.color && t.invertedColors && V(t.color)(e), (r = e.variants[t.variant]) == null ? void 0 : r[t.color], s)];
261
- }), go = /* @__PURE__ */ w.forwardRef(function(t, a) {
262
- const r = O({
263
- props: t,
264
- name: "JoySheet"
265
- }), {
266
- className: s,
267
- color: l = "neutral",
268
- component: i = "div",
269
- variant: c = "plain",
270
- invertedColors: u = !1,
271
- slots: n = {},
272
- slotProps: v = {}
273
- } = r, h = $(r, uo), g = p({}, r, {
274
- color: l,
275
- component: i,
276
- invertedColors: u,
277
- variant: c
278
- }), y = bo(g), f = p({}, h, {
279
- component: i,
280
- slots: n,
281
- slotProps: v
282
- }), [C, T] = B("root", {
283
- ref: a,
284
- className: W(y.root, s),
285
- elementType: vo,
286
- externalForwardedProps: f,
287
- ownerState: g
288
- });
289
- return /* @__PURE__ */ b(C, p({}, T));
290
- });
291
- process.env.NODE_ENV !== "production" && (go.propTypes = {
292
- // ┌────────────────────────────── Warning ──────────────────────────────┐
293
- // │ These PropTypes are generated from the TypeScript type definitions. │
294
- // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │
295
- // └─────────────────────────────────────────────────────────────────────┘
296
- /**
297
- * The content of the component.
298
- */
299
- children: o.node,
300
- /**
301
- * @ignore
302
- */
303
- className: o.string,
304
- /**
305
- * The color of the component. It supports those theme colors that make sense for this component.
306
- * @default 'neutral'
307
- */
308
- color: o.oneOfType([o.oneOf(["danger", "neutral", "primary", "success", "warning"]), o.string]),
309
- /**
310
- * The component used for the root node.
311
- * Either a string to use a HTML element or a component.
312
- */
313
- component: o.elementType,
314
- /**
315
- * If `true`, the children with an implicit color prop invert their colors to match the component's variant and color.
316
- * @default false
317
- */
318
- invertedColors: o.bool,
319
- /**
320
- * The props used for each slot inside.
321
- * @default {}
322
- */
323
- slotProps: o.shape({
324
- root: o.oneOfType([o.func, o.object])
325
- }),
326
- /**
327
- * The components used for each slot inside.
328
- * @default {}
329
- */
330
- slots: o.shape({
331
- root: o.elementType
332
- }),
333
- /**
334
- * The system prop that allows defining system overrides as well as additional CSS styles.
335
- */
336
- sx: o.oneOfType([o.arrayOf(o.oneOfType([o.func, o.object, o.bool])), o.func, o.object]),
337
- /**
338
- * The [global variant](https://mui.com/joy-ui/main-features/global-variants/) to use.
339
- * @default 'plain'
340
- */
341
- variant: o.oneOfType([o.oneOf(["outlined", "plain", "soft", "solid"]), o.string])
342
- });
343
- function ho(e) {
344
- return A("MuiTable", e);
345
- }
346
- k("MuiTable", ["root", "colorPrimary", "colorNeutral", "colorDanger", "colorSuccess", "colorWarning", "colorContext", "variantPlain", "variantOutlined", "variantSoft", "variantSolid", "sizeSm", "sizeMd", "sizeLg", "stickyHeader", "stickyFooter", "noWrap", "hoverRow", "borderAxisNone", "borderAxisX", "borderAxisXBetween", "borderAxisY", "borderAxisYBetween", "borderAxisBoth", "borderAxisBothBetween"]);
347
- const yo = ["className", "component", "children", "borderAxis", "hoverRow", "noWrap", "size", "variant", "color", "stripe", "stickyHeader", "stickyFooter", "slots", "slotProps"], fo = (e) => {
348
- const {
349
- size: t,
350
- variant: a,
351
- color: r,
352
- borderAxis: s,
353
- stickyHeader: l,
354
- stickyFooter: i,
355
- noWrap: c,
356
- hoverRow: u
357
- } = e, n = {
358
- root: ["root", l && "stickyHeader", i && "stickyFooter", c && "noWrap", u && "hoverRow", s && `borderAxis${m(s)}`, a && `variant${m(a)}`, r && `color${m(r)}`, t && `size${m(t)}`]
359
- };
360
- return _(n, ho, {});
361
- }, d = {
362
- /**
363
- * According to https://www.w3.org/TR/2014/REC-html5-20141028/tabular-data.html#the-tr-element,
364
- * `tr` can only have `td | th` as children, so using :first-of-type is better than :first-child to prevent emotion SSR warning
365
- */
366
- getColumnExceptFirst() {
367
- return "& tr > *:not(:first-of-type), & tr > th + td, & tr > td + th";
368
- },
369
- /**
370
- * Every cell in the table
371
- */
372
- getCell() {
373
- return "& th, & td";
374
- },
375
- /**
376
- * `th` cell of the table (could exist in the body)
377
- */
378
- getHeadCell() {
379
- return "& th";
380
- },
381
- /**
382
- * Only the cell of `thead`
383
- */
384
- getHeaderCell() {
385
- return "& thead th";
386
- },
387
- getHeaderCellOfRow(e) {
388
- return `& thead tr:nth-of-type(${e}) th`;
389
- },
390
- getBottomHeaderCell() {
391
- return "& thead th:not([colspan])";
392
- },
393
- getHeaderNestedFirstColumn() {
394
- return "& thead tr:not(:first-of-type) th:not([colspan]):first-of-type";
395
- },
396
- /**
397
- * The body cell that contains data
398
- */
399
- getDataCell() {
400
- return "& td";
401
- },
402
- getDataCellExceptLastRow() {
403
- return "& tr:not(:last-of-type) > td";
404
- },
405
- /**
406
- * The body cell either `td` or `th`
407
- */
408
- getBodyCellExceptLastRow() {
409
- return `${this.getDataCellExceptLastRow()}, & tr:not(:last-of-type) > th[scope="row"]`;
410
- },
411
- getBodyCellOfRow(e) {
412
- return typeof e == "number" && e < 0 ? `& tbody tr:nth-last-of-type(${Math.abs(e)}) td, & tbody tr:nth-last-of-type(${Math.abs(e)}) th[scope="row"]` : `& tbody tr:nth-of-type(${e}) td, & tbody tr:nth-of-type(${e}) th[scope="row"]`;
413
- },
414
- getBodyRow(e) {
415
- return e === void 0 ? "& tbody tr" : `& tbody tr:nth-of-type(${e})`;
416
- },
417
- getFooterCell() {
418
- return "& tfoot th, & tfoot td";
419
- },
420
- getFooterFirstRowCell() {
421
- return "& tfoot tr:not(:last-of-type) th, & tfoot tr:not(:last-of-type) td";
422
- }
423
- }, Co = x("table", {
424
- name: "JoyTable",
425
- slot: "Root",
426
- overridesResolver: (e, t) => t.root
427
- })(({
428
- theme: e,
429
- ownerState: t
430
- }) => {
431
- var a, r, s, l, i, c, u;
432
- const n = (a = e.variants[t.variant]) == null ? void 0 : a[t.color];
433
- return [p({
434
- "--Table-headerUnderlineThickness": "2px",
435
- "--TableCell-borderColor": (r = n == null ? void 0 : n.borderColor) != null ? r : e.vars.palette.divider,
436
- "--TableCell-headBackground": `var(--Sheet-background, ${e.vars.palette.background.surface})`
437
- }, t.size === "sm" && {
438
- "--unstable_TableCell-height": "var(--TableCell-height, 32px)",
439
- "--TableCell-paddingX": "0.25rem",
440
- "--TableCell-paddingY": "0.25rem"
441
- }, t.size === "md" && {
442
- "--unstable_TableCell-height": "var(--TableCell-height, 40px)",
443
- "--TableCell-paddingX": "0.5rem",
444
- "--TableCell-paddingY": "0.375rem"
445
- }, t.size === "lg" && {
446
- "--unstable_TableCell-height": "var(--TableCell-height, 48px)",
447
- "--TableCell-paddingX": "0.75rem",
448
- "--TableCell-paddingY": "0.5rem"
449
- }, {
450
- tableLayout: "fixed",
451
- width: "100%",
452
- borderSpacing: "0px",
453
- borderCollapse: "separate",
454
- borderRadius: "var(--TableCell-cornerRadius, var(--unstable_actionRadius))"
455
- }, e.typography[`body-${{
456
- sm: "xs",
457
- md: "sm",
458
- lg: "md"
459
- }[t.size]}`], (s = e.variants[t.variant]) == null ? void 0 : s[t.color], {
460
- "& caption": {
461
- color: e.vars.palette.text.tertiary,
462
- padding: "calc(2 * var(--TableCell-paddingY)) var(--TableCell-paddingX)"
463
- },
464
- [d.getDataCell()]: p({
465
- padding: "var(--TableCell-paddingY) var(--TableCell-paddingX)",
466
- height: "var(--unstable_TableCell-height)",
467
- borderColor: "var(--TableCell-borderColor)",
468
- // must come after border bottom
469
- backgroundColor: "var(--TableCell-dataBackground)"
470
- }, t.noWrap && {
471
- textOverflow: "ellipsis",
472
- whiteSpace: "nowrap",
473
- overflow: "hidden"
474
- }),
475
- [d.getHeadCell()]: {
476
- textAlign: "left",
477
- padding: "var(--TableCell-paddingY) var(--TableCell-paddingX)",
478
- backgroundColor: "var(--TableCell-headBackground)",
479
- // use `background-color` in case the Sheet has gradient background
480
- height: "var(--unstable_TableCell-height)",
481
- fontWeight: e.vars.fontWeight.lg,
482
- borderColor: "var(--TableCell-borderColor)",
483
- color: e.vars.palette.text.secondary,
484
- textOverflow: "ellipsis",
485
- whiteSpace: "nowrap",
486
- overflow: "hidden"
487
- },
488
- [d.getHeaderCell()]: {
489
- verticalAlign: "bottom",
490
- // Automatic radius adjustment with Sheet
491
- "&:first-of-type": {
492
- borderTopLeftRadius: "var(--TableCell-cornerRadius, var(--unstable_actionRadius))"
493
- },
494
- "&:last-of-type": {
495
- borderTopRightRadius: "var(--TableCell-cornerRadius, var(--unstable_actionRadius))"
496
- }
497
- },
498
- "& tfoot tr > *": {
499
- backgroundColor: `var(--TableCell-footBackground, ${e.vars.palette.background.level1})`,
500
- // Automatic radius adjustment with Sheet
501
- "&:first-of-type": {
502
- borderBottomLeftRadius: "var(--TableCell-cornerRadius, var(--unstable_actionRadius))"
503
- },
504
- "&:last-of-type": {
505
- borderBottomRightRadius: "var(--TableCell-cornerRadius, var(--unstable_actionRadius))"
506
- }
507
- }
508
- }), (((l = t.borderAxis) == null ? void 0 : l.startsWith("x")) || ((i = t.borderAxis) == null ? void 0 : i.startsWith("both"))) && {
509
- // insert border between rows
510
- [d.getHeaderCell()]: {
511
- borderBottomWidth: 1,
512
- borderBottomStyle: "solid"
513
- },
514
- [d.getBottomHeaderCell()]: {
515
- borderBottomWidth: "var(--Table-headerUnderlineThickness)",
516
- borderBottomStyle: "solid"
517
- },
518
- [d.getBodyCellExceptLastRow()]: {
519
- borderBottomWidth: 1,
520
- borderBottomStyle: "solid"
521
- },
522
- [d.getFooterCell()]: {
523
- borderTopWidth: 1,
524
- borderTopStyle: "solid"
525
- }
526
- }, (((c = t.borderAxis) == null ? void 0 : c.startsWith("y")) || ((u = t.borderAxis) == null ? void 0 : u.startsWith("both"))) && {
527
- // insert border between columns
528
- [`${d.getColumnExceptFirst()}, ${d.getHeaderNestedFirstColumn()}`]: {
529
- borderLeftWidth: 1,
530
- borderLeftStyle: "solid"
531
- }
532
- }, (t.borderAxis === "x" || t.borderAxis === "both") && {
533
- // insert border at the top of header and bottom of body
534
- [d.getHeaderCellOfRow(1)]: {
535
- borderTopWidth: 1,
536
- borderTopStyle: "solid"
537
- },
538
- [d.getBodyCellOfRow(-1)]: {
539
- borderBottomWidth: 1,
540
- borderBottomStyle: "solid"
541
- },
542
- [d.getFooterCell()]: {
543
- borderBottomWidth: 1,
544
- borderBottomStyle: "solid"
545
- }
546
- }, (t.borderAxis === "y" || t.borderAxis === "both") && {
547
- // insert border on the left of first column and right of the last column
548
- "& tr > *:first-of-type": {
549
- borderLeftWidth: 1,
550
- borderLeftStyle: "solid"
551
- },
552
- "& tr > *:last-of-type:not(:first-of-type)": {
553
- borderRightWidth: 1,
554
- borderRightStyle: "solid"
555
- }
556
- }, t.stripe && {
557
- [d.getBodyRow(t.stripe)]: {
558
- // For customization, a table cell can look for this variable with a fallback value.
559
- background: `var(--TableRow-stripeBackground, ${e.vars.palette.background.level2})`,
560
- color: e.vars.palette.text.primary
561
- }
562
- }, t.hoverRow && {
563
- [d.getBodyRow()]: {
564
- "&:hover": {
565
- background: `var(--TableRow-hoverBackground, ${e.vars.palette.background.level3})`
566
- }
567
- }
568
- }, t.stickyHeader && {
569
- // The column header
570
- [d.getHeaderCell()]: {
571
- position: "sticky",
572
- top: 0,
573
- zIndex: e.vars.zIndex.table
574
- },
575
- [d.getHeaderCellOfRow(2)]: {
576
- // support upto 2 rows for the sticky header
577
- top: "var(--unstable_TableCell-height)"
578
- }
579
- }, t.stickyFooter && {
580
- // The column header
581
- [d.getFooterCell()]: {
582
- position: "sticky",
583
- bottom: 0,
584
- zIndex: e.vars.zIndex.table,
585
- color: e.vars.palette.text.secondary,
586
- fontWeight: e.vars.fontWeight.lg
587
- },
588
- [d.getFooterFirstRowCell()]: {
589
- // support upto 2 rows for the sticky footer
590
- bottom: "var(--unstable_TableCell-height)"
591
- }
592
- }];
593
- }), mo = /* @__PURE__ */ w.forwardRef(function(t, a) {
594
- const r = O({
595
- props: t,
596
- name: "JoyTable"
597
- }), {
598
- className: s,
599
- component: l,
600
- children: i,
601
- borderAxis: c = "xBetween",
602
- hoverRow: u = !1,
603
- noWrap: n = !1,
604
- size: v = "md",
605
- variant: h = "plain",
606
- color: g = "neutral",
607
- stripe: y,
608
- stickyHeader: f = !1,
609
- stickyFooter: C = !1,
610
- slots: T = {},
611
- slotProps: E = {}
612
- } = r, j = $(r, yo), z = p({}, r, {
613
- borderAxis: c,
614
- hoverRow: u,
615
- noWrap: n,
616
- component: l,
617
- size: v,
618
- color: g,
619
- variant: h,
620
- stripe: y,
621
- stickyHeader: f,
622
- stickyFooter: C
623
- }), M = fo(z), S = p({}, j, {
624
- component: l,
625
- slots: T,
626
- slotProps: E
627
- }), [U, J] = B("root", {
628
- ref: a,
629
- className: W(M.root, s),
630
- elementType: Co,
631
- externalForwardedProps: S,
632
- ownerState: z
633
- });
634
- return /* @__PURE__ */ b(q.Provider, {
635
- value: !0,
636
- children: /* @__PURE__ */ b(U, p({}, J, {
637
- children: i
638
- }))
639
- });
640
- });
641
- process.env.NODE_ENV !== "production" && (mo.propTypes = {
642
- // ┌────────────────────────────── Warning ──────────────────────────────┐
643
- // │ These PropTypes are generated from the TypeScript type definitions. │
644
- // │ To update them, edit the TypeScript types and run `pnpm proptypes`. │
645
- // └─────────────────────────────────────────────────────────────────────┘
646
- /**
647
- * The axis to display a border on the table cell.
648
- * @default 'xBetween'
649
- */
650
- borderAxis: o.oneOfType([o.oneOf(["both", "bothBetween", "none", "x", "xBetween", "y", "yBetween"]), o.string]),
651
- /**
652
- * Children of the table
653
- */
654
- children: o.node,
655
- /**
656
- * @ignore
657
- */
658
- className: o.string,
659
- /**
660
- * The color of the component. It supports those theme colors that make sense for this component.
661
- * @default 'neutral'
662
- */
663
- color: o.oneOfType([o.oneOf(["danger", "neutral", "primary", "success", "warning"]), o.string]),
664
- /**
665
- * The component used for the root node.
666
- * Either a string to use a HTML element or a component.
667
- */
668
- component: o.elementType,
669
- /**
670
- * If `true`, the table row will shade on hover.
671
- * @default false
672
- */
673
- hoverRow: o.bool,
674
- /**
675
- * If `true`, the body cells will not wrap, but instead will truncate with a text overflow ellipsis.
676
- *
677
- * Note: Header cells are always truncated with overflow ellipsis.
678
- *
679
- * @default false
680
- */
681
- noWrap: o.bool,
682
- /**
683
- * The size of the component.
684
- * It accepts theme values between 'sm' and 'lg'.
685
- * @default 'md'
686
- */
687
- size: o.oneOfType([o.oneOf(["sm", "md", "lg"]), o.string]),
688
- /**
689
- * The props used for each slot inside.
690
- * @default {}
691
- */
692
- slotProps: o.shape({
693
- root: o.oneOfType([o.func, o.object])
694
- }),
695
- /**
696
- * The components used for each slot inside.
697
- * @default {}
698
- */
699
- slots: o.shape({
700
- root: o.elementType
701
- }),
702
- /**
703
- * If `true`, the footer always appear at the bottom of the overflow table.
704
- *
705
- * ⚠️ It doesn't work with IE11.
706
- * @default false
707
- */
708
- stickyFooter: o.bool,
709
- /**
710
- * If `true`, the header always appear at the top of the overflow table.
711
- *
712
- * ⚠️ It doesn't work with IE11.
713
- * @default false
714
- */
715
- stickyHeader: o.bool,
716
- /**
717
- * The odd or even row of the table body will have subtle background color.
718
- */
719
- stripe: o.oneOfType([o.oneOf(["odd", "even"]), o.string]),
720
- /**
721
- * The system prop that allows defining system overrides as well as additional CSS styles.
722
- */
723
- sx: o.oneOfType([o.arrayOf(o.oneOfType([o.func, o.object, o.bool])), o.func, o.object]),
724
- /**
725
- * The [global variant](https://mui.com/joy-ui/main-features/global-variants/) to use.
726
- * @default 'plain'
727
- */
728
- variant: o.oneOfType([o.oneOf(["outlined", "plain", "soft", "solid"]), o.string])
729
- });
730
- const wo = R(/* @__PURE__ */ b("path", {
731
- d: "M15.41 16.59 10.83 12l4.58-4.59L14 6l-6 6 6 6z"
732
- }), "KeyboardArrowLeft"), Po = R(/* @__PURE__ */ b("path", {
733
- d: "M8.59 16.59 13.17 12 8.59 7.41 10 6l6 6-6 6z"
734
- }), "KeyboardArrowRight"), Wo = R(/* @__PURE__ */ b("path", {
735
- d: "M11 18h2v-2h-2zm1-16C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8m0-14c-2.21 0-4 1.79-4 4h2c0-1.1.9-2 2-2s2 .9 2 2c0 2-3 1.75-3 5h2c0-2.25 3-2.5 3-5 0-2.21-1.79-4-4-4"
736
- }), "HelpOutline"), zo = R(/* @__PURE__ */ b("path", {
737
- d: "M3 17.25V21h3.75L17.81 9.94l-3.75-3.75zM20.71 7.04c.39-.39.39-1.02 0-1.41l-2.34-2.34a.996.996 0 0 0-1.41 0l-1.83 1.83 3.75 3.75z"
738
- }), "Edit"), Fo = R(/* @__PURE__ */ b("path", {
739
- d: "M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4m0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4"
740
- }), "Person");
741
- /**
742
- * @license lucide-react v0.454.0 - ISC
743
- *
744
- * This source code is licensed under the ISC license.
745
- * See the LICENSE file in the root directory of this source tree.
746
- */
747
- const To = (e) => e.replace(/([a-z0-9])([A-Z])/g, "$1-$2").toLowerCase(), D = (...e) => e.filter((t, a, r) => !!t && t.trim() !== "" && r.indexOf(t) === a).join(" ").trim();
748
- /**
749
- * @license lucide-react v0.454.0 - ISC
750
- *
751
- * This source code is licensed under the ISC license.
752
- * See the LICENSE file in the root directory of this source tree.
753
- */
754
- var xo = {
755
- xmlns: "http://www.w3.org/2000/svg",
756
- width: 24,
757
- height: 24,
758
- viewBox: "0 0 24 24",
759
- fill: "none",
760
- stroke: "currentColor",
761
- strokeWidth: 2,
762
- strokeLinecap: "round",
763
- strokeLinejoin: "round"
764
- };
765
- /**
766
- * @license lucide-react v0.454.0 - ISC
767
- *
768
- * This source code is licensed under the ISC license.
769
- * See the LICENSE file in the root directory of this source tree.
770
- */
771
- const Ro = L(
772
- ({
773
- color: e = "currentColor",
774
- size: t = 24,
775
- strokeWidth: a = 2,
776
- absoluteStrokeWidth: r,
777
- className: s = "",
778
- children: l,
779
- iconNode: i,
780
- ...c
781
- }, u) => P(
782
- "svg",
783
- {
784
- ref: u,
785
- ...xo,
786
- width: t,
787
- height: t,
788
- stroke: e,
789
- strokeWidth: r ? Number(a) * 24 / Number(t) : a,
790
- className: D("lucide", s),
791
- ...c
792
- },
793
- [
794
- ...i.map(([n, v]) => P(n, v)),
795
- ...Array.isArray(l) ? l : [l]
796
- ]
797
- )
798
- );
799
- /**
800
- * @license lucide-react v0.454.0 - ISC
801
- *
802
- * This source code is licensed under the ISC license.
803
- * See the LICENSE file in the root directory of this source tree.
804
- */
805
- const I = (e, t) => {
806
- const a = L(
807
- ({ className: r, ...s }, l) => P(Ro, {
808
- ref: l,
809
- iconNode: t,
810
- className: D(`lucide-${To(e)}`, r),
811
- ...s
812
- })
813
- );
814
- return a.displayName = `${e}`, a;
815
- };
816
- /**
817
- * @license lucide-react v0.454.0 - ISC
818
- *
819
- * This source code is licensed under the ISC license.
820
- * See the LICENSE file in the root directory of this source tree.
821
- */
822
- const No = I("ChevronLeft", [
823
- ["path", { d: "m15 18-6-6 6-6", key: "1wnfg3" }]
824
- ]);
825
- /**
826
- * @license lucide-react v0.454.0 - ISC
827
- *
828
- * This source code is licensed under the ISC license.
829
- * See the LICENSE file in the root directory of this source tree.
830
- */
831
- const Lo = I("ChevronRight", [
832
- ["path", { d: "m9 18 6-6-6-6", key: "mthhwq" }]
833
- ]);
834
- export {
835
- No as C,
836
- co as D,
837
- zo as E,
838
- Wo as H,
839
- wo as K,
840
- Fo as P,
841
- go as S,
842
- mo as T,
843
- Po as a,
844
- Lo as b,
845
- I as c
846
- };