@solostylist/ui-kit 1.0.228 → 1.0.230

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 (69) hide show
  1. package/dist/{FormControl-BbzvApma.js → FormControl-DsRIRfTs.js} +204 -177
  2. package/dist/{MenuItem-CwAhn4sd.js → MenuItem-IOMcBScJ.js} +2 -2
  3. package/dist/{MenuList-5C2nFAWS.js → MenuList-vtqACjea.js} +1 -1
  4. package/dist/{Modal-Cu5Cgh-q.js → Modal-CLdC2-Th.js} +372 -395
  5. package/dist/Popover-ZneFWo2r.js +333 -0
  6. package/dist/{checkbox-B5GlJYcB.js → checkbox-DC-OoGvh.js} +1 -1
  7. package/dist/s-chat-message/index.js +1 -1
  8. package/dist/s-chat-message/s-chat-message.js +1 -1
  9. package/dist/{s-chat-message-B9JOBvzP.js → s-chat-message-C-d9amiC.js} +2 -2
  10. package/dist/s-code-block/index.js +1 -1
  11. package/dist/s-code-block/s-code-block.js +1 -1
  12. package/dist/{s-code-block-B5k-1Acd.js → s-code-block-DEojINTt.js} +16 -11
  13. package/dist/s-comment-message/index.js +1 -1
  14. package/dist/s-comment-message/s-comment-message.js +1 -1
  15. package/dist/{s-comment-message-BPE5a6p6.js → s-comment-message-Dum0P6de.js} +2 -2
  16. package/dist/s-data-table/index.js +1 -1
  17. package/dist/s-data-table/s-data-table.d.ts +1 -5
  18. package/dist/s-data-table/s-data-table.js +1 -1
  19. package/dist/{s-data-table-D-esZw_W.js → s-data-table-DfGYIIvn.js} +202 -172
  20. package/dist/s-date-picker/index.js +1 -1
  21. package/dist/s-date-picker/picker-action-bar.d.ts +3 -7
  22. package/dist/s-date-picker/picker-action-bar.js +33 -19
  23. package/dist/s-date-picker/s-date-picker.js +1 -1
  24. package/dist/{s-date-picker-CdH1pta6.js → s-date-picker-C06rlE6_.js} +1 -1
  25. package/dist/s-datetime-picker/index.js +1 -1
  26. package/dist/s-datetime-picker/s-datetime-picker.js +1 -1
  27. package/dist/{s-datetime-picker-BHkWSJKj.js → s-datetime-picker-DnIK-QnQ.js} +24 -24
  28. package/dist/s-error-layout/s-error-layout.d.ts +2 -2
  29. package/dist/s-error-layout/s-error-layout.js +1 -1
  30. package/dist/s-language-switcher/index.js +1 -1
  31. package/dist/s-language-switcher/s-language-switcher.d.ts +2 -5
  32. package/dist/s-language-switcher/s-language-switcher.js +1 -1
  33. package/dist/s-language-switcher-B96dUknj.js +192 -0
  34. package/dist/s-link/s-link.d.ts +2 -2
  35. package/dist/s-link/s-link.js +8 -5
  36. package/dist/s-moving-border/s-moving-border.d.ts +6 -9
  37. package/dist/s-moving-border/s-moving-border.js +73 -81
  38. package/dist/s-pagination/index.d.ts +1 -0
  39. package/dist/s-pagination/s-pagination.d.ts +43 -6
  40. package/dist/s-pagination/s-pagination.js +46 -28
  41. package/dist/s-pagination/types.d.ts +9 -0
  42. package/dist/s-pagination/types.js +27 -0
  43. package/dist/s-review/index.js +1 -1
  44. package/dist/s-review/s-review.js +1 -1
  45. package/dist/{s-review-CRnakHRo.js → s-review-CvTVBxTZ.js} +3 -3
  46. package/dist/s-skeleton/index.d.ts +1 -1
  47. package/dist/s-skeleton/s-skeleton.d.ts +25 -9
  48. package/dist/s-skeleton/s-skeleton.js +59 -63
  49. package/dist/s-text-editor/index.js +1 -1
  50. package/dist/s-text-editor/s-text-editor-toolbar.js +1 -1
  51. package/dist/s-text-editor/s-text-editor.js +1 -1
  52. package/dist/{s-text-editor-toolbar-BEFVwZ-B.js → s-text-editor-toolbar-ChtNCg2A.js} +900 -736
  53. package/dist/s-theme-demo/index.js +1 -1
  54. package/dist/s-theme-demo/s-theme-demo.js +1 -1
  55. package/dist/s-theme-demo-Bnv7lPIh.js +867 -0
  56. package/dist/theme/components/checkbox.d.ts +0 -9
  57. package/dist/theme/components/checkbox.js +1 -1
  58. package/dist/theme/components/components.js +94 -92
  59. package/dist/theme/components/pagination-item.d.ts +1077 -1015
  60. package/dist/theme/components/pagination-item.js +81 -6
  61. package/dist/theme/components/pagination.d.ts +14 -0
  62. package/dist/theme/components/pagination.js +5 -0
  63. package/dist/theme/components/pickers-calendar-header.d.ts +14 -1
  64. package/dist/theme/components/pickers-calendar-header.js +5 -2
  65. package/dist/{useMobilePicker-Dw1IxoE6.js → useMobilePicker-CQA6fYLQ.js} +384 -384
  66. package/package.json +1 -1
  67. package/dist/Menu-Ct_sL_Dg.js +0 -497
  68. package/dist/s-language-switcher-UgSBC_n_.js +0 -199
  69. package/dist/s-theme-demo-Fktc-UlY.js +0 -857
@@ -3,19 +3,37 @@ import { Fragment as t, jsx as n, jsxs as r } from "react/jsx-runtime";
3
3
  import { Box as i } from "@mui/material";
4
4
  import { motion as a, useAnimationFrame as o, useMotionTemplate as s, useMotionValue as c, useTransform as l } from "framer-motion";
5
5
  //#region lib/s-moving-border/s-moving-border.tsx
6
- var u = 250, d = (e, t) => ({
7
- position: "absolute",
8
- left: "50%",
9
- top: "50%",
10
- width: `${e}px`,
11
- height: `${e}px`,
12
- transform: "translate(-50%, -50%)",
13
- opacity: .5,
14
- background: `radial-gradient(${t} 40%, transparent 60%)`,
15
- filter: "blur(12px)",
16
- pointerEvents: "none"
6
+ var u = 250, d = 24, f = Array.from({ length: d }, (e, t) => {
7
+ let n = t / (d - 1);
8
+ return {
9
+ scale: 1 - n * .76,
10
+ opacity: .006 + n * .044
11
+ };
12
+ }), p = ({ color: e, size: t }) => /* @__PURE__ */ n(i, {
13
+ sx: {
14
+ position: "absolute",
15
+ left: "50%",
16
+ top: "50%",
17
+ width: t,
18
+ height: t,
19
+ transform: "translate(-50%, -50%)",
20
+ pointerEvents: "none"
21
+ },
22
+ children: f.map(({ scale: r, opacity: a }) => {
23
+ let o = t * r, s = (t - o) / 2;
24
+ return /* @__PURE__ */ n(i, { sx: {
25
+ position: "absolute",
26
+ backgroundColor: e,
27
+ borderRadius: "50%",
28
+ height: o,
29
+ left: s,
30
+ opacity: a,
31
+ top: s,
32
+ width: o
33
+ } }, r);
34
+ })
17
35
  });
18
- function f({ children: i, duration: u, rx: d, ry: f, phase: p = 0 }) {
36
+ function m({ children: i, duration: u, rx: d, ry: f, phase: p = 0 }) {
19
37
  let m = e(null), h = c(0);
20
38
  o((e) => {
21
39
  let t = m.current?.getTotalLength();
@@ -53,73 +71,47 @@ function f({ children: i, duration: u, rx: d, ry: f, phase: p = 0 }) {
53
71
  children: i
54
72
  })] });
55
73
  }
56
- var p = ({ borderRadius: t, className: a, duration: o = 6e3, children: s, glowColor: c = "var(--s-palette-primary-main)", glowSize: l = u, height: p, padding: m, width: h, ...g }) => {
57
- let _ = e(null);
58
- return /* @__PURE__ */ r(i, {
59
- className: a,
60
- ...g,
61
- sx: [{
62
- position: "relative",
63
- overflow: "hidden",
64
- height: p ?? "100%",
65
- width: h ?? "100%",
66
- padding: m ?? .125,
67
- borderRadius: t,
68
- backgroundColor: "transparent"
69
- }, ...Array.isArray(g.sx) ? g.sx : [g.sx]],
70
- children: [
71
- /* @__PURE__ */ r(i, {
72
- sx: {
73
- position: "absolute",
74
- top: 0,
75
- left: 0,
76
- right: 0,
77
- bottom: 0
78
- },
79
- children: [/* @__PURE__ */ n(f, {
80
- duration: o,
81
- rx: "100%",
82
- ry: "100%",
83
- phase: 0,
84
- children: /* @__PURE__ */ n(i, { sx: d(l, c) })
85
- }), /* @__PURE__ */ n(f, {
86
- duration: o,
87
- rx: "100%",
88
- ry: "100%",
89
- phase: .5,
90
- children: /* @__PURE__ */ n(i, { sx: d(l, c) })
91
- })]
92
- }),
93
- /* @__PURE__ */ n(i, {
94
- sx: {
95
- position: "absolute",
96
- pointerEvents: "none",
97
- left: 0,
98
- top: 0,
99
- width: "100%",
100
- height: "100%",
101
- zIndex: 2
102
- },
103
- children: /* @__PURE__ */ n(i, {
104
- ref: _,
105
- sx: {
106
- position: "absolute",
107
- left: "50%",
108
- top: "50%",
109
- width: 120,
110
- height: 120,
111
- opacity: 0,
112
- filter: "blur(16px)",
113
- borderRadius: "50%",
114
- transform: "translate(-50%, -50%)",
115
- transition: "left 0.15s cubic-bezier(.4,2,.6,1), top 0.15s cubic-bezier(.4,2,.6,1), opacity 0.2s"
116
- }
117
- })
118
- }),
119
- s
120
- ]
121
- });
122
- };
123
- p.displayName = "SMovingBorder";
74
+ var h = ({ borderRadius: e, className: t, duration: a = 6e3, children: o, glowColor: s = "var(--s-palette-primary-main)", glowSize: c = u, height: l, padding: d, width: f, ...h }) => /* @__PURE__ */ r(i, {
75
+ className: t,
76
+ ...h,
77
+ sx: [{
78
+ position: "relative",
79
+ overflow: "hidden",
80
+ height: l ?? "100%",
81
+ width: f ?? "100%",
82
+ padding: d ?? .125,
83
+ borderRadius: e,
84
+ backgroundColor: "transparent"
85
+ }, ...Array.isArray(h.sx) ? h.sx : [h.sx]],
86
+ children: [/* @__PURE__ */ r(i, {
87
+ sx: {
88
+ position: "absolute",
89
+ top: 0,
90
+ left: 0,
91
+ right: 0,
92
+ bottom: 0
93
+ },
94
+ children: [/* @__PURE__ */ n(m, {
95
+ duration: a,
96
+ rx: "100%",
97
+ ry: "100%",
98
+ phase: 0,
99
+ children: /* @__PURE__ */ n(p, {
100
+ color: s,
101
+ size: c
102
+ })
103
+ }), /* @__PURE__ */ n(m, {
104
+ duration: a,
105
+ rx: "100%",
106
+ ry: "100%",
107
+ phase: .5,
108
+ children: /* @__PURE__ */ n(p, {
109
+ color: s,
110
+ size: c
111
+ })
112
+ })]
113
+ }), o]
114
+ });
115
+ h.displayName = "SMovingBorder";
124
116
  //#endregion
125
- export { p as SMovingBorder, p as default };
117
+ export { h as SMovingBorder, h as default };
@@ -1,2 +1,3 @@
1
1
  export { default, default as SPagination } from './s-pagination';
2
2
  export type { SPaginationProps } from './s-pagination';
3
+ export type { SPaginationColor, SPaginationSize } from './types';
@@ -1,16 +1,53 @@
1
1
  import { default as React } from 'react';
2
2
  import { PaginationProps } from '@mui/material';
3
+ import { SPaginationColor, SPaginationSize } from './types';
4
+ export type { SPaginationColor, SPaginationSize } from './types';
3
5
  /**
4
- * Props for the SPagination component, extending Material-UI's PaginationProps
6
+ * Props for SPagination. Web behavior is sourced from MUI Pagination; custom
7
+ * SoloStylist props stay local to the web package.
5
8
  */
6
- export interface SPaginationProps extends PaginationProps {
7
- /** Whether the pagination is in a loading state - shows skeleton when true */
8
- loading?: boolean;
9
- /** Total number of pages - component returns empty fragment when 0 */
9
+ export interface SPaginationProps extends Omit<PaginationProps, 'color' | 'count' | 'shape' | 'size' | 'variant'> {
10
+ /** Accessible label for the complete pagination control. */
11
+ accessibilityLabel?: string;
12
+ /** Number of always-visible pages at the beginning and end. */
13
+ boundaryCount?: number;
14
+ /** Total number of pages. The component is hidden when count is 0 or less. */
10
15
  count?: number;
16
+ /** Page selected initially when the component is uncontrolled. */
17
+ defaultPage?: number;
18
+ /** Whether the complete pagination control is disabled. */
19
+ disabled?: boolean;
20
+ /** Returns the accessible label for an item. */
21
+ getItemAriaLabel?: PaginationProps['getItemAriaLabel'];
22
+ /** Whether to hide the next-page button. */
23
+ hideNextButton?: boolean;
24
+ /** Whether to hide the previous-page button. */
25
+ hidePrevButton?: boolean;
26
+ /** Whether to show the pagination skeleton. */
27
+ loading?: boolean;
28
+ /** Callback fired when the page changes. */
29
+ onChange?: PaginationProps['onChange'];
30
+ /** Current page for controlled usage (1-indexed). */
31
+ page?: number;
32
+ /** Custom item renderer. */
33
+ renderItem?: PaginationProps['renderItem'];
34
+ /** Active-page color, using the same semantic palette as SButton. */
35
+ color?: SPaginationColor;
36
+ /** Shape of every pagination item. Defaults to the rounded SIconButton shape. */
37
+ shape?: 'circular' | 'rounded';
38
+ /** Whether to show the first-page button. */
39
+ showFirstButton?: boolean;
40
+ /** Whether to show the last-page button. */
41
+ showLastButton?: boolean;
42
+ /** Number of visible pages before and after the current page. */
43
+ siblingCount?: number;
44
+ /** Size of pagination items. */
45
+ size?: SPaginationSize;
46
+ /** Inactive-page visual variant. The active page always uses the contained SButton treatment. */
47
+ variant?: 'text' | 'outlined';
11
48
  }
12
49
  export declare const SPagination: {
13
- ({ loading, count, ...props }: SPaginationProps): React.JSX.Element;
50
+ ({ loading, count, color, shape, size, variant, accessibilityLabel, sx, ...props }: SPaginationProps): React.JSX.Element;
14
51
  displayName: string;
15
52
  };
16
53
  export default SPagination;
@@ -1,32 +1,50 @@
1
- import { SSkeleton as e } from "../s-skeleton/s-skeleton.js";
1
+ import { paginationDimensions as e } from "./types.js";
2
+ import { SSkeleton as t } from "../s-skeleton/s-skeleton.js";
2
3
  import "react";
3
- import { Fragment as t, jsx as n, jsxs as r } from "react/jsx-runtime";
4
- import { Pagination as i, Stack as a, useMediaQuery as o, useTheme as s } from "@mui/material";
4
+ import { Fragment as n, jsx as r, jsxs as i } from "react/jsx-runtime";
5
+ import { Pagination as a, Stack as o } from "@mui/material";
5
6
  //#region lib/s-pagination/s-pagination.tsx
6
- var c = ({ style: t }) => /* @__PURE__ */ r(a, {
7
- direction: "row",
8
- style: t,
9
- sx: {
10
- display: "inline-flex",
11
- flexWrap: "wrap",
12
- gap: 1
13
- },
14
- children: [
15
- /* @__PURE__ */ n(e, { component: "icon-button" }),
16
- /* @__PURE__ */ n(e, {
17
- variant: "rounded",
18
- width: 120
19
- }),
20
- /* @__PURE__ */ n(e, { component: "icon-button" })
21
- ]
22
- }), l = ({ loading: e, count: r = 0, ...a }) => {
23
- let l = o(s().breakpoints.down("sm"));
24
- return r === 0 ? /* @__PURE__ */ n(t, {}) : e ? /* @__PURE__ */ n(c, { style: a.style }) : /* @__PURE__ */ n(i, {
25
- size: l ? "small" : "medium",
26
- count: r,
27
- ...a
7
+ var s = ({ size: n, style: a }) => {
8
+ let s = e[n];
9
+ return /* @__PURE__ */ i(o, {
10
+ direction: "row",
11
+ style: a,
12
+ sx: {
13
+ alignItems: "center",
14
+ display: "inline-flex",
15
+ gap: `${s.gap}px`
16
+ },
17
+ children: [
18
+ /* @__PURE__ */ r(t, {
19
+ variant: "rounded",
20
+ width: s.item,
21
+ height: s.item
22
+ }),
23
+ /* @__PURE__ */ r(t, {
24
+ variant: "rounded",
25
+ width: s.bar,
26
+ height: s.item
27
+ }),
28
+ /* @__PURE__ */ r(t, {
29
+ variant: "rounded",
30
+ width: s.item,
31
+ height: s.item
32
+ })
33
+ ]
28
34
  });
29
- };
30
- l.displayName = "SPagination";
35
+ }, c = ({ loading: e = !1, count: t = 0, color: i = "primary", shape: o = "rounded", size: c = "medium", variant: l = "text", accessibilityLabel: u = "pagination navigation", sx: d, ...f }) => t <= 0 ? /* @__PURE__ */ r(n, {}) : e ? /* @__PURE__ */ r(s, {
36
+ size: c,
37
+ style: f.style
38
+ }) : /* @__PURE__ */ r(a, {
39
+ count: t,
40
+ "aria-label": u,
41
+ color: i,
42
+ shape: o,
43
+ size: c,
44
+ variant: l,
45
+ sx: d,
46
+ ...f
47
+ });
48
+ c.displayName = "SPagination";
31
49
  //#endregion
32
- export { l as SPagination, l as default };
50
+ export { c as SPagination, c as default };
@@ -0,0 +1,9 @@
1
+ import { PaginationProps } from '@mui/material';
2
+ export type SPaginationSize = NonNullable<PaginationProps['size']>;
3
+ export type SPaginationColor = 'primary' | 'secondary' | 'success' | 'error' | 'info' | 'warning';
4
+ export declare const paginationColors: readonly ["primary", "secondary", "success", "error", "info", "warning"];
5
+ export declare const paginationDimensions: Record<SPaginationSize, {
6
+ item: number;
7
+ gap: number;
8
+ bar: number;
9
+ }>;
@@ -0,0 +1,27 @@
1
+ //#region lib/s-pagination/types.ts
2
+ var e = [
3
+ "primary",
4
+ "secondary",
5
+ "success",
6
+ "error",
7
+ "info",
8
+ "warning"
9
+ ], t = {
10
+ small: {
11
+ item: 26,
12
+ gap: 2,
13
+ bar: 90
14
+ },
15
+ medium: {
16
+ item: 32,
17
+ gap: 6,
18
+ bar: 120
19
+ },
20
+ large: {
21
+ item: 40,
22
+ gap: 6,
23
+ bar: 150
24
+ }
25
+ };
26
+ //#endregion
27
+ export { e as paginationColors, t as paginationDimensions };
@@ -1,2 +1,2 @@
1
- import { t as e } from "../s-review-CRnakHRo.js";
1
+ import { t as e } from "../s-review-CvTVBxTZ.js";
2
2
  export { e as SReview, e as default };
@@ -1,2 +1,2 @@
1
- import { t as e } from "../s-review-CRnakHRo.js";
1
+ import { t as e } from "../s-review-CvTVBxTZ.js";
2
2
  export { e as SReview, e as default };
@@ -39,7 +39,7 @@ var _ = t(/* @__PURE__ */ u("path", { d: "M15 3H6c-.83 0-1.54.5-1.84 1.22l-3.02
39
39
  spacing: 2,
40
40
  sx: { alignItems: "flex-start" },
41
41
  children: [/* @__PURE__ */ u(i, {
42
- component: "rounded-avatar",
42
+ variant: "circular",
43
43
  width: A,
44
44
  height: A
45
45
  }), /* @__PURE__ */ d(f, {
@@ -84,12 +84,12 @@ var _ = t(/* @__PURE__ */ u("path", { d: "M15 3H6c-.83 0-1.54.5-1.84 1.22l-3.02
84
84
  height: 16,
85
85
  sx: { mr: 2 }
86
86
  }),
87
- /* @__PURE__ */ u(i, { component: "icon-button" }),
87
+ /* @__PURE__ */ u(i, { preset: "icon-button" }),
88
88
  /* @__PURE__ */ u(i, {
89
89
  width: 20,
90
90
  height: 16
91
91
  }),
92
- /* @__PURE__ */ u(i, { component: "icon-button" }),
92
+ /* @__PURE__ */ u(i, { preset: "icon-button" }),
93
93
  /* @__PURE__ */ u(i, {
94
94
  width: 20,
95
95
  height: 16
@@ -1,2 +1,2 @@
1
1
  export { default, default as SSkeleton } from './s-skeleton';
2
- export type { SSkeletonProps } from './s-skeleton';
2
+ export type { SSkeletonAnimation, SSkeletonCustomProps, SSkeletonPreset, SSkeletonPresetProps, SSkeletonProps, SSkeletonVariant, } from './s-skeleton';
@@ -1,22 +1,38 @@
1
1
  import { default as React } from 'react';
2
2
  import { SkeletonProps } from '@mui/material';
3
- /**
4
- * Props interface for SSkeleton component
5
- */
6
- export interface SSkeletonProps extends Omit<SkeletonProps, 'variant' | 'height' | 'width' | 'component'> {
3
+ export type SSkeletonVariant = 'circular' | 'rectangular' | 'rounded' | 'text';
4
+ export type SSkeletonPreset = 'avatar' | 'button' | 'checkbox' | 'icon-button';
5
+ export type SSkeletonAnimation = 'pulse' | 'wave' | false;
6
+ type SSkeletonBaseProps = Omit<SkeletonProps, 'animation' | 'component' | 'height' | 'variant' | 'width'> & {
7
+ /** Loading animation. Set to false to disable animation. */
8
+ animation?: SSkeletonAnimation;
9
+ };
10
+ export type SSkeletonCustomProps = SSkeletonBaseProps & {
11
+ /** Pre-defined skeleton preset. Cannot be combined with custom shape/size props. */
12
+ preset?: never;
7
13
  /** Visual variant of the skeleton */
8
- variant?: 'circular' | 'rectangular' | 'rounded' | 'text';
14
+ variant?: SSkeletonVariant;
9
15
  /** Height of the skeleton (number for px, string for CSS units) */
10
16
  height?: number | string;
11
17
  /** Width of the skeleton (number for px, string for CSS units) */
12
18
  width?: number | string;
13
19
  /** Font size for text variant skeletons */
14
20
  fontSize?: number | string;
15
- /** Pre-defined component preset for common UI elements */
16
- component?: 'button' | 'checkbox' | 'radio-button' | 'avatar' | 'rounded-avatar' | 'icon-button' | 'typography' | 'title-typography';
17
- }
21
+ };
22
+ export type SSkeletonPresetProps = SSkeletonBaseProps & {
23
+ /** Pre-defined skeleton preset for common UI elements */
24
+ preset: SSkeletonPreset;
25
+ variant?: never;
26
+ height?: never;
27
+ width?: never;
28
+ fontSize?: never;
29
+ };
30
+ /**
31
+ * Props interface for SSkeleton component
32
+ */
33
+ export type SSkeletonProps = SSkeletonCustomProps | SSkeletonPresetProps;
18
34
  export declare const SSkeleton: {
19
- ({ variant, width, height, fontSize, component, ...props }: SSkeletonProps): React.JSX.Element;
35
+ (props: SSkeletonProps): React.JSX.Element;
20
36
  displayName: string;
21
37
  };
22
38
  export default SSkeleton;
@@ -1,70 +1,66 @@
1
1
  import "react";
2
2
  import { jsx as e } from "react/jsx-runtime";
3
- import { Skeleton as t } from "@mui/material";
3
+ import { Skeleton as t, useTheme as n } from "@mui/material";
4
4
  //#region lib/s-skeleton/s-skeleton.tsx
5
- var n = ({ variant: n = "text", width: r = "100%", height: i = 32, fontSize: a = "16px", component: o, ...s }) => {
6
- switch (o) {
7
- case "button": return /* @__PURE__ */ e(t, {
8
- height: 32,
9
- variant: "rounded",
10
- width: r,
11
- ...s
12
- });
13
- case "checkbox": return /* @__PURE__ */ e(t, {
14
- height: 24,
15
- variant: "rounded",
16
- width: 24,
17
- ...s
18
- });
19
- case "radio-button": return /* @__PURE__ */ e(t, {
20
- height: 24,
21
- variant: "circular",
22
- width: 24,
23
- ...s
24
- });
25
- case "avatar": return /* @__PURE__ */ e(t, {
26
- height: 54,
27
- variant: "rectangular",
28
- width: 54,
29
- ...s
30
- });
31
- case "rounded-avatar": return /* @__PURE__ */ e(t, {
32
- height: 48,
33
- variant: "circular",
34
- width: 48,
35
- ...s
36
- });
37
- case "icon-button": return /* @__PURE__ */ e(t, {
38
- height: 32,
39
- variant: "circular",
40
- width: 32,
41
- ...s
42
- });
43
- case "typography": return /* @__PURE__ */ e(t, {
44
- sx: { fontSize: a },
45
- variant: "text",
46
- width: "100%",
47
- ...s
48
- });
49
- case "title-typography": return /* @__PURE__ */ e(t, {
50
- sx: { fontSize: a },
51
- variant: "text",
52
- width: 200,
53
- ...s
54
- });
55
- default: return n === "text" ? /* @__PURE__ */ e(t, {
56
- sx: { fontSize: a },
57
- variant: n,
58
- width: r,
59
- ...s
60
- }) : /* @__PURE__ */ e(t, {
61
- height: i,
62
- variant: n,
63
- width: r,
64
- ...s
5
+ var r = {
6
+ avatar: {
7
+ height: 40,
8
+ variant: "circular",
9
+ width: 40
10
+ },
11
+ button: {
12
+ height: 40,
13
+ variant: "rounded",
14
+ width: 100
15
+ },
16
+ checkbox: {
17
+ borderRadius: "sm",
18
+ height: 20,
19
+ variant: "rounded",
20
+ width: 20
21
+ },
22
+ "icon-button": {
23
+ height: 32,
24
+ variant: "rounded",
25
+ width: 32
26
+ }
27
+ }, i = ({ fontSize: n = "16px", height: r, presetBorderRadius: i, style: a, variant: o, width: s, ...c }) => {
28
+ let l = i === void 0 ? a : {
29
+ ...a,
30
+ borderRadius: i
31
+ };
32
+ return o === "text" ? /* @__PURE__ */ e(t, {
33
+ style: l,
34
+ sx: { fontSize: n },
35
+ variant: o,
36
+ width: s,
37
+ ...c
38
+ }) : /* @__PURE__ */ e(t, {
39
+ height: r,
40
+ style: l,
41
+ variant: o,
42
+ width: s,
43
+ ...c
44
+ });
45
+ }, a = (e) => {
46
+ let t = n();
47
+ if (e.preset) {
48
+ let { preset: n, ...a } = e, { borderRadius: o, ...s } = r[n];
49
+ return i({
50
+ ...a,
51
+ ...s,
52
+ presetBorderRadius: o ? t.radius[o] : void 0
65
53
  });
66
54
  }
55
+ let { fontSize: a = "16px", height: o = 32, variant: s = "text", width: c = "100%", ...l } = e;
56
+ return i({
57
+ ...l,
58
+ fontSize: a,
59
+ height: o,
60
+ variant: s,
61
+ width: c
62
+ });
67
63
  };
68
- n.displayName = "SSkeleton";
64
+ a.displayName = "SSkeleton";
69
65
  //#endregion
70
- export { n as SSkeleton, n as default };
66
+ export { a as SSkeleton, a as default };
@@ -1,3 +1,3 @@
1
- import { t as e } from "../s-text-editor-toolbar-BEFVwZ-B.js";
1
+ import { t as e } from "../s-text-editor-toolbar-ChtNCg2A.js";
2
2
  import { STextEditor as t } from "./s-text-editor.js";
3
3
  export { t as STextEditor, t as default, e as STextEditorToolbar };
@@ -1,2 +1,2 @@
1
- import { t as e } from "../s-text-editor-toolbar-BEFVwZ-B.js";
1
+ import { t as e } from "../s-text-editor-toolbar-ChtNCg2A.js";
2
2
  export { e as STextEditorToolbar };
@@ -1,6 +1,6 @@
1
1
  import { tint as e } from "../theme/utils.js";
2
2
  import { t } from "../Box-BlmynALm.js";
3
- import { t as n } from "../s-text-editor-toolbar-BEFVwZ-B.js";
3
+ import { t as n } from "../s-text-editor-toolbar-ChtNCg2A.js";
4
4
  import * as r from "react";
5
5
  import { forwardRef as i } from "react";
6
6
  import { jsx as a, jsxs as o } from "react/jsx-runtime";