@hai-dev/ui-kit 1.0.0 → 1.0.2

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 (41) hide show
  1. package/dist/Button-0AB7oP6Y.js +655 -0
  2. package/dist/ButtonBase-Bw_3RZmN.js +5453 -0
  3. package/dist/CircularProgress-BD6BPlN2.js +290 -0
  4. package/dist/{DialogTitle-1A3dJ174.js → DialogTitle-iOQ7wKEt.js} +78 -78
  5. package/dist/assets/button.css +1 -0
  6. package/dist/assets/upload-button.css +1 -1
  7. package/dist/assets/upload-dialog.css +1 -1
  8. package/dist/button.module-BZPPmSAS.js +21 -0
  9. package/dist/components/button/button-content.d.ts +3 -0
  10. package/dist/components/button/button-content.js +17 -0
  11. package/dist/components/button/button.d.ts +3 -0
  12. package/dist/components/button/button.js +65 -0
  13. package/dist/components/button/button.stories.d.ts +7 -0
  14. package/dist/components/button/constants.d.ts +12 -0
  15. package/dist/components/button/constants.js +15 -0
  16. package/dist/components/button/index.d.ts +1 -0
  17. package/dist/components/button/index.js +4 -0
  18. package/dist/components/button/types.d.ts +38 -0
  19. package/dist/components/button/types.js +1 -0
  20. package/dist/components/button/utils/get-button-classnames.d.ts +2 -0
  21. package/dist/components/button/utils/get-button-classnames.js +17 -0
  22. package/dist/components/button/utils/index.d.ts +1 -0
  23. package/dist/components/button/utils/index.js +4 -0
  24. package/dist/components/index.d.ts +1 -0
  25. package/dist/components/index.js +4 -2
  26. package/dist/components/photo-crop-uploader/components/error-upload-dialog/error-upload-dialog.js +10 -9
  27. package/dist/components/photo-crop-uploader/components/upload-button/constants.d.ts +1 -1
  28. package/dist/components/photo-crop-uploader/components/upload-button/constants.js +1 -1
  29. package/dist/components/photo-crop-uploader/components/upload-button/types.d.ts +5 -1
  30. package/dist/components/photo-crop-uploader/components/upload-button/upload-button.js +81 -58
  31. package/dist/components/photo-crop-uploader/components/upload-dialog/upload-dialog.js +356 -86
  32. package/dist/components/photo-crop-uploader/constants.d.ts +1 -1
  33. package/dist/components/photo-crop-uploader/constants.js +1 -1
  34. package/dist/components/photo-crop-uploader/locale.js +4 -4
  35. package/dist/components/photo-crop-uploader/photo-crop-uploader.js +81 -70
  36. package/dist/components/photo-crop-uploader/types.d.ts +8 -1
  37. package/dist/index-B2JRaoNz.js +48 -0
  38. package/dist/index.d.ts +1 -1
  39. package/dist/index.js +15 -13
  40. package/package.json +73 -73
  41. package/dist/Button-BjNjCLw8.js +0 -6428
@@ -0,0 +1,655 @@
1
+ import * as y from "react";
2
+ import { g as H, a as A, r as q, u as J, s as b, c as R, b as r, d as K, B as Q, e as X, P as t } from "./ButtonBase-Bw_3RZmN.js";
3
+ import { u as Y, m as Z, c as oo, C as to } from "./CircularProgress-BD6BPlN2.js";
4
+ import { jsxs as no, jsx as d } from "react/jsx-runtime";
5
+ function ao(o) {
6
+ return A("MuiButton", o);
7
+ }
8
+ const p = H("MuiButton", ["root", "text", "textInherit", "textPrimary", "textSecondary", "textSuccess", "textError", "textInfo", "textWarning", "outlined", "outlinedInherit", "outlinedPrimary", "outlinedSecondary", "outlinedSuccess", "outlinedError", "outlinedInfo", "outlinedWarning", "contained", "containedInherit", "containedPrimary", "containedSecondary", "containedSuccess", "containedError", "containedInfo", "containedWarning", "disableElevation", "focusVisible", "disabled", "colorInherit", "colorPrimary", "colorSecondary", "colorSuccess", "colorError", "colorInfo", "colorWarning", "textSizeSmall", "textSizeMedium", "textSizeLarge", "outlinedSizeSmall", "outlinedSizeMedium", "outlinedSizeLarge", "containedSizeSmall", "containedSizeMedium", "containedSizeLarge", "sizeMedium", "sizeSmall", "sizeLarge", "fullWidth", "startIcon", "endIcon", "icon", "iconSizeSmall", "iconSizeMedium", "iconSizeLarge", "loading", "loadingWrapper", "loadingIconPlaceholder", "loadingIndicator", "loadingPositionCenter", "loadingPositionStart", "loadingPositionEnd"]), W = /* @__PURE__ */ y.createContext({});
9
+ process.env.NODE_ENV !== "production" && (W.displayName = "ButtonGroupContext");
10
+ const O = /* @__PURE__ */ y.createContext(void 0);
11
+ process.env.NODE_ENV !== "production" && (O.displayName = "ButtonGroupButtonContext");
12
+ const io = (o) => {
13
+ const {
14
+ color: n,
15
+ disableElevation: a,
16
+ fullWidth: i,
17
+ size: c,
18
+ variant: u,
19
+ loading: g,
20
+ loadingPosition: S,
21
+ classes: f
22
+ } = o, x = {
23
+ root: ["root", g && "loading", u, `${u}${r(n)}`, `size${r(c)}`, `${u}Size${r(c)}`, `color${r(n)}`, a && "disableElevation", i && "fullWidth", g && `loadingPosition${r(S)}`],
24
+ startIcon: ["icon", "startIcon", `iconSize${r(c)}`],
25
+ endIcon: ["icon", "endIcon", `iconSize${r(c)}`],
26
+ loadingIndicator: ["loadingIndicator"],
27
+ loadingWrapper: ["loadingWrapper"]
28
+ }, z = K(x, ao, f);
29
+ return {
30
+ ...f,
31
+ // forward the focused, disabled, etc. classes to the ButtonBase
32
+ ...z
33
+ };
34
+ }, T = [{
35
+ props: {
36
+ size: "small"
37
+ },
38
+ style: {
39
+ "& > *:nth-of-type(1)": {
40
+ fontSize: 18
41
+ }
42
+ }
43
+ }, {
44
+ props: {
45
+ size: "medium"
46
+ },
47
+ style: {
48
+ "& > *:nth-of-type(1)": {
49
+ fontSize: 20
50
+ }
51
+ }
52
+ }, {
53
+ props: {
54
+ size: "large"
55
+ },
56
+ style: {
57
+ "& > *:nth-of-type(1)": {
58
+ fontSize: 22
59
+ }
60
+ }
61
+ }], ro = b(Q, {
62
+ shouldForwardProp: (o) => X(o) || o === "classes",
63
+ name: "MuiButton",
64
+ slot: "Root",
65
+ overridesResolver: (o, n) => {
66
+ const {
67
+ ownerState: a
68
+ } = o;
69
+ return [n.root, n[a.variant], n[`${a.variant}${r(a.color)}`], n[`size${r(a.size)}`], n[`${a.variant}Size${r(a.size)}`], a.color === "inherit" && n.colorInherit, a.disableElevation && n.disableElevation, a.fullWidth && n.fullWidth, a.loading && n.loading];
70
+ }
71
+ })(Z(({
72
+ theme: o
73
+ }) => {
74
+ const n = o.palette.mode === "light" ? o.palette.grey[300] : o.palette.grey[800], a = o.palette.mode === "light" ? o.palette.grey.A100 : o.palette.grey[700];
75
+ return {
76
+ ...o.typography.button,
77
+ minWidth: 64,
78
+ padding: "6px 16px",
79
+ border: 0,
80
+ borderRadius: (o.vars || o).shape.borderRadius,
81
+ transition: o.transitions.create(["background-color", "box-shadow", "border-color", "color"], {
82
+ duration: o.transitions.duration.short
83
+ }),
84
+ "&:hover": {
85
+ textDecoration: "none"
86
+ },
87
+ [`&.${p.disabled}`]: {
88
+ color: (o.vars || o).palette.action.disabled
89
+ },
90
+ variants: [{
91
+ props: {
92
+ variant: "contained"
93
+ },
94
+ style: {
95
+ color: "var(--variant-containedColor)",
96
+ backgroundColor: "var(--variant-containedBg)",
97
+ boxShadow: (o.vars || o).shadows[2],
98
+ "&:hover": {
99
+ boxShadow: (o.vars || o).shadows[4],
100
+ // Reset on touch devices, it doesn't add specificity
101
+ "@media (hover: none)": {
102
+ boxShadow: (o.vars || o).shadows[2]
103
+ }
104
+ },
105
+ "&:active": {
106
+ boxShadow: (o.vars || o).shadows[8]
107
+ },
108
+ [`&.${p.focusVisible}`]: {
109
+ boxShadow: (o.vars || o).shadows[6]
110
+ },
111
+ [`&.${p.disabled}`]: {
112
+ color: (o.vars || o).palette.action.disabled,
113
+ boxShadow: (o.vars || o).shadows[0],
114
+ backgroundColor: (o.vars || o).palette.action.disabledBackground
115
+ }
116
+ }
117
+ }, {
118
+ props: {
119
+ variant: "outlined"
120
+ },
121
+ style: {
122
+ padding: "5px 15px",
123
+ border: "1px solid currentColor",
124
+ borderColor: "var(--variant-outlinedBorder, currentColor)",
125
+ backgroundColor: "var(--variant-outlinedBg)",
126
+ color: "var(--variant-outlinedColor)",
127
+ [`&.${p.disabled}`]: {
128
+ border: `1px solid ${(o.vars || o).palette.action.disabledBackground}`
129
+ }
130
+ }
131
+ }, {
132
+ props: {
133
+ variant: "text"
134
+ },
135
+ style: {
136
+ padding: "6px 8px",
137
+ color: "var(--variant-textColor)",
138
+ backgroundColor: "var(--variant-textBg)"
139
+ }
140
+ }, ...Object.entries(o.palette).filter(oo()).map(([i]) => ({
141
+ props: {
142
+ color: i
143
+ },
144
+ style: {
145
+ "--variant-textColor": (o.vars || o).palette[i].main,
146
+ "--variant-outlinedColor": (o.vars || o).palette[i].main,
147
+ "--variant-outlinedBorder": o.alpha((o.vars || o).palette[i].main, 0.5),
148
+ "--variant-containedColor": (o.vars || o).palette[i].contrastText,
149
+ "--variant-containedBg": (o.vars || o).palette[i].main,
150
+ "@media (hover: hover)": {
151
+ "&:hover": {
152
+ "--variant-containedBg": (o.vars || o).palette[i].dark,
153
+ "--variant-textBg": o.alpha((o.vars || o).palette[i].main, (o.vars || o).palette.action.hoverOpacity),
154
+ "--variant-outlinedBorder": (o.vars || o).palette[i].main,
155
+ "--variant-outlinedBg": o.alpha((o.vars || o).palette[i].main, (o.vars || o).palette.action.hoverOpacity)
156
+ }
157
+ }
158
+ }
159
+ })), {
160
+ props: {
161
+ color: "inherit"
162
+ },
163
+ style: {
164
+ color: "inherit",
165
+ borderColor: "currentColor",
166
+ "--variant-containedBg": o.vars ? o.vars.palette.Button.inheritContainedBg : n,
167
+ "@media (hover: hover)": {
168
+ "&:hover": {
169
+ "--variant-containedBg": o.vars ? o.vars.palette.Button.inheritContainedHoverBg : a,
170
+ "--variant-textBg": o.alpha((o.vars || o).palette.text.primary, (o.vars || o).palette.action.hoverOpacity),
171
+ "--variant-outlinedBg": o.alpha((o.vars || o).palette.text.primary, (o.vars || o).palette.action.hoverOpacity)
172
+ }
173
+ }
174
+ }
175
+ }, {
176
+ props: {
177
+ size: "small",
178
+ variant: "text"
179
+ },
180
+ style: {
181
+ padding: "4px 5px",
182
+ fontSize: o.typography.pxToRem(13)
183
+ }
184
+ }, {
185
+ props: {
186
+ size: "large",
187
+ variant: "text"
188
+ },
189
+ style: {
190
+ padding: "8px 11px",
191
+ fontSize: o.typography.pxToRem(15)
192
+ }
193
+ }, {
194
+ props: {
195
+ size: "small",
196
+ variant: "outlined"
197
+ },
198
+ style: {
199
+ padding: "3px 9px",
200
+ fontSize: o.typography.pxToRem(13)
201
+ }
202
+ }, {
203
+ props: {
204
+ size: "large",
205
+ variant: "outlined"
206
+ },
207
+ style: {
208
+ padding: "7px 21px",
209
+ fontSize: o.typography.pxToRem(15)
210
+ }
211
+ }, {
212
+ props: {
213
+ size: "small",
214
+ variant: "contained"
215
+ },
216
+ style: {
217
+ padding: "4px 10px",
218
+ fontSize: o.typography.pxToRem(13)
219
+ }
220
+ }, {
221
+ props: {
222
+ size: "large",
223
+ variant: "contained"
224
+ },
225
+ style: {
226
+ padding: "8px 22px",
227
+ fontSize: o.typography.pxToRem(15)
228
+ }
229
+ }, {
230
+ props: {
231
+ disableElevation: !0
232
+ },
233
+ style: {
234
+ boxShadow: "none",
235
+ "&:hover": {
236
+ boxShadow: "none"
237
+ },
238
+ [`&.${p.focusVisible}`]: {
239
+ boxShadow: "none"
240
+ },
241
+ "&:active": {
242
+ boxShadow: "none"
243
+ },
244
+ [`&.${p.disabled}`]: {
245
+ boxShadow: "none"
246
+ }
247
+ }
248
+ }, {
249
+ props: {
250
+ fullWidth: !0
251
+ },
252
+ style: {
253
+ width: "100%"
254
+ }
255
+ }, {
256
+ props: {
257
+ loadingPosition: "center"
258
+ },
259
+ style: {
260
+ transition: o.transitions.create(["background-color", "box-shadow", "border-color"], {
261
+ duration: o.transitions.duration.short
262
+ }),
263
+ [`&.${p.loading}`]: {
264
+ color: "transparent"
265
+ }
266
+ }
267
+ }]
268
+ };
269
+ })), eo = b("span", {
270
+ name: "MuiButton",
271
+ slot: "StartIcon",
272
+ overridesResolver: (o, n) => {
273
+ const {
274
+ ownerState: a
275
+ } = o;
276
+ return [n.startIcon, a.loading && n.startIconLoadingStart, n[`iconSize${r(a.size)}`]];
277
+ }
278
+ })(({
279
+ theme: o
280
+ }) => ({
281
+ display: "inherit",
282
+ marginRight: 8,
283
+ marginLeft: -4,
284
+ variants: [{
285
+ props: {
286
+ size: "small"
287
+ },
288
+ style: {
289
+ marginLeft: -2
290
+ }
291
+ }, {
292
+ props: {
293
+ loadingPosition: "start",
294
+ loading: !0
295
+ },
296
+ style: {
297
+ transition: o.transitions.create(["opacity"], {
298
+ duration: o.transitions.duration.short
299
+ }),
300
+ opacity: 0
301
+ }
302
+ }, {
303
+ props: {
304
+ loadingPosition: "start",
305
+ loading: !0,
306
+ fullWidth: !0
307
+ },
308
+ style: {
309
+ marginRight: -8
310
+ }
311
+ }, ...T]
312
+ })), so = b("span", {
313
+ name: "MuiButton",
314
+ slot: "EndIcon",
315
+ overridesResolver: (o, n) => {
316
+ const {
317
+ ownerState: a
318
+ } = o;
319
+ return [n.endIcon, a.loading && n.endIconLoadingEnd, n[`iconSize${r(a.size)}`]];
320
+ }
321
+ })(({
322
+ theme: o
323
+ }) => ({
324
+ display: "inherit",
325
+ marginRight: -4,
326
+ marginLeft: 8,
327
+ variants: [{
328
+ props: {
329
+ size: "small"
330
+ },
331
+ style: {
332
+ marginRight: -2
333
+ }
334
+ }, {
335
+ props: {
336
+ loadingPosition: "end",
337
+ loading: !0
338
+ },
339
+ style: {
340
+ transition: o.transitions.create(["opacity"], {
341
+ duration: o.transitions.duration.short
342
+ }),
343
+ opacity: 0
344
+ }
345
+ }, {
346
+ props: {
347
+ loadingPosition: "end",
348
+ loading: !0,
349
+ fullWidth: !0
350
+ },
351
+ style: {
352
+ marginLeft: -8
353
+ }
354
+ }, ...T]
355
+ })), lo = b("span", {
356
+ name: "MuiButton",
357
+ slot: "LoadingIndicator"
358
+ })(({
359
+ theme: o
360
+ }) => ({
361
+ display: "none",
362
+ position: "absolute",
363
+ visibility: "visible",
364
+ variants: [{
365
+ props: {
366
+ loading: !0
367
+ },
368
+ style: {
369
+ display: "flex"
370
+ }
371
+ }, {
372
+ props: {
373
+ loadingPosition: "start"
374
+ },
375
+ style: {
376
+ left: 14
377
+ }
378
+ }, {
379
+ props: {
380
+ loadingPosition: "start",
381
+ size: "small"
382
+ },
383
+ style: {
384
+ left: 10
385
+ }
386
+ }, {
387
+ props: {
388
+ variant: "text",
389
+ loadingPosition: "start"
390
+ },
391
+ style: {
392
+ left: 6
393
+ }
394
+ }, {
395
+ props: {
396
+ loadingPosition: "center"
397
+ },
398
+ style: {
399
+ left: "50%",
400
+ transform: "translate(-50%)",
401
+ color: (o.vars || o).palette.action.disabled
402
+ }
403
+ }, {
404
+ props: {
405
+ loadingPosition: "end"
406
+ },
407
+ style: {
408
+ right: 14
409
+ }
410
+ }, {
411
+ props: {
412
+ loadingPosition: "end",
413
+ size: "small"
414
+ },
415
+ style: {
416
+ right: 10
417
+ }
418
+ }, {
419
+ props: {
420
+ variant: "text",
421
+ loadingPosition: "end"
422
+ },
423
+ style: {
424
+ right: 6
425
+ }
426
+ }, {
427
+ props: {
428
+ loadingPosition: "start",
429
+ fullWidth: !0
430
+ },
431
+ style: {
432
+ position: "relative",
433
+ left: -10
434
+ }
435
+ }, {
436
+ props: {
437
+ loadingPosition: "end",
438
+ fullWidth: !0
439
+ },
440
+ style: {
441
+ position: "relative",
442
+ right: -10
443
+ }
444
+ }]
445
+ })), E = b("span", {
446
+ name: "MuiButton",
447
+ slot: "LoadingIconPlaceholder"
448
+ })({
449
+ display: "inline-block",
450
+ width: "1em",
451
+ height: "1em"
452
+ }), po = /* @__PURE__ */ y.forwardRef(function(n, a) {
453
+ const i = y.useContext(W), c = y.useContext(O), u = q(i, n), g = J({
454
+ props: u,
455
+ name: "MuiButton"
456
+ }), {
457
+ children: S,
458
+ color: f = "primary",
459
+ component: x = "button",
460
+ className: z,
461
+ disabled: I = !1,
462
+ disableElevation: L = !1,
463
+ disableFocusRipple: B = !1,
464
+ endIcon: C,
465
+ focusVisibleClassName: M,
466
+ fullWidth: k = !1,
467
+ id: P,
468
+ loading: s = null,
469
+ loadingIndicator: V,
470
+ loadingPosition: v = "center",
471
+ size: j = "medium",
472
+ startIcon: w,
473
+ type: h,
474
+ variant: D = "text",
475
+ ...F
476
+ } = g, m = Y(P), $ = V ?? /* @__PURE__ */ d(to, {
477
+ "aria-labelledby": m,
478
+ color: "inherit",
479
+ size: 16
480
+ }), l = {
481
+ ...g,
482
+ color: f,
483
+ component: x,
484
+ disabled: I,
485
+ disableElevation: L,
486
+ disableFocusRipple: B,
487
+ fullWidth: k,
488
+ loading: s,
489
+ loadingIndicator: $,
490
+ loadingPosition: v,
491
+ size: j,
492
+ type: h,
493
+ variant: D
494
+ }, e = io(l), G = (w || s && v === "start") && /* @__PURE__ */ d(eo, {
495
+ className: e.startIcon,
496
+ ownerState: l,
497
+ children: w || /* @__PURE__ */ d(E, {
498
+ className: e.loadingIconPlaceholder,
499
+ ownerState: l
500
+ })
501
+ }), U = (C || s && v === "end") && /* @__PURE__ */ d(so, {
502
+ className: e.endIcon,
503
+ ownerState: l,
504
+ children: C || /* @__PURE__ */ d(E, {
505
+ className: e.loadingIconPlaceholder,
506
+ ownerState: l
507
+ })
508
+ }), _ = c || "", N = typeof s == "boolean" ? (
509
+ // use plain HTML span to minimize the runtime overhead
510
+ /* @__PURE__ */ d("span", {
511
+ className: e.loadingWrapper,
512
+ style: {
513
+ display: "contents"
514
+ },
515
+ children: s && /* @__PURE__ */ d(lo, {
516
+ className: e.loadingIndicator,
517
+ ownerState: l,
518
+ children: $
519
+ })
520
+ })
521
+ ) : null;
522
+ return /* @__PURE__ */ no(ro, {
523
+ ownerState: l,
524
+ className: R(i.className, e.root, z, _),
525
+ component: x,
526
+ disabled: I || s,
527
+ focusRipple: !B,
528
+ focusVisibleClassName: R(e.focusVisible, M),
529
+ ref: a,
530
+ type: h,
531
+ id: s ? m : P,
532
+ ...F,
533
+ classes: e,
534
+ children: [G, v !== "end" && N, S, v === "end" && N, U]
535
+ });
536
+ });
537
+ process.env.NODE_ENV !== "production" && (po.propTypes = {
538
+ // ┌────────────────────────────── Warning ──────────────────────────────┐
539
+ // │ These PropTypes are generated from the TypeScript type definitions. │
540
+ // │ To update them, edit the d.ts file and run `pnpm proptypes`. │
541
+ // └─────────────────────────────────────────────────────────────────────┘
542
+ /**
543
+ * The content of the component.
544
+ */
545
+ children: t.node,
546
+ /**
547
+ * Override or extend the styles applied to the component.
548
+ */
549
+ classes: t.object,
550
+ /**
551
+ * @ignore
552
+ */
553
+ className: t.string,
554
+ /**
555
+ * The color of the component.
556
+ * It supports both default and custom theme colors, which can be added as shown in the
557
+ * [palette customization guide](https://mui.com/material-ui/customization/palette/#custom-colors).
558
+ * @default 'primary'
559
+ */
560
+ color: t.oneOfType([t.oneOf(["inherit", "primary", "secondary", "success", "error", "info", "warning"]), t.string]),
561
+ /**
562
+ * The component used for the root node.
563
+ * Either a string to use a HTML element or a component.
564
+ */
565
+ component: t.elementType,
566
+ /**
567
+ * If `true`, the component is disabled.
568
+ * @default false
569
+ */
570
+ disabled: t.bool,
571
+ /**
572
+ * If `true`, no elevation is used.
573
+ * @default false
574
+ */
575
+ disableElevation: t.bool,
576
+ /**
577
+ * If `true`, the keyboard focus ripple is disabled.
578
+ * @default false
579
+ */
580
+ disableFocusRipple: t.bool,
581
+ /**
582
+ * If `true`, the ripple effect is disabled.
583
+ *
584
+ * ⚠️ Without a ripple there is no styling for :focus-visible by default. Be sure
585
+ * to highlight the element by applying separate styles with the `.Mui-focusVisible` class.
586
+ * @default false
587
+ */
588
+ disableRipple: t.bool,
589
+ /**
590
+ * Element placed after the children.
591
+ */
592
+ endIcon: t.node,
593
+ /**
594
+ * @ignore
595
+ */
596
+ focusVisibleClassName: t.string,
597
+ /**
598
+ * If `true`, the button will take up the full width of its container.
599
+ * @default false
600
+ */
601
+ fullWidth: t.bool,
602
+ /**
603
+ * The URL to link to when the button is clicked.
604
+ * If defined, an `a` element will be used as the root node.
605
+ */
606
+ href: t.string,
607
+ /**
608
+ * @ignore
609
+ */
610
+ id: t.string,
611
+ /**
612
+ * If `true`, the loading indicator is visible and the button is disabled.
613
+ * If `true | false`, the loading wrapper is always rendered before the children to prevent [Google Translation Crash](https://github.com/mui/material-ui/issues/27853).
614
+ * @default null
615
+ */
616
+ loading: t.bool,
617
+ /**
618
+ * Element placed before the children if the button is in loading state.
619
+ * The node should contain an element with `role="progressbar"` with an accessible name.
620
+ * By default, it renders a `CircularProgress` that is labeled by the button itself.
621
+ * @default <CircularProgress color="inherit" size={16} />
622
+ */
623
+ loadingIndicator: t.node,
624
+ /**
625
+ * The loading indicator can be positioned on the start, end, or the center of the button.
626
+ * @default 'center'
627
+ */
628
+ loadingPosition: t.oneOf(["center", "end", "start"]),
629
+ /**
630
+ * The size of the component.
631
+ * `small` is equivalent to the dense button styling.
632
+ * @default 'medium'
633
+ */
634
+ size: t.oneOfType([t.oneOf(["small", "medium", "large"]), t.string]),
635
+ /**
636
+ * Element placed before the children.
637
+ */
638
+ startIcon: t.node,
639
+ /**
640
+ * The system prop that allows defining system overrides as well as additional CSS styles.
641
+ */
642
+ sx: t.oneOfType([t.arrayOf(t.oneOfType([t.func, t.object, t.bool])), t.func, t.object]),
643
+ /**
644
+ * @ignore
645
+ */
646
+ type: t.oneOfType([t.oneOf(["button", "reset", "submit"]), t.string]),
647
+ /**
648
+ * The variant to use.
649
+ * @default 'text'
650
+ */
651
+ variant: t.oneOfType([t.oneOf(["contained", "outlined", "text"]), t.string])
652
+ });
653
+ export {
654
+ po as B
655
+ };