@solostylist/ui-kit 1.0.60 → 1.0.61

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/main.d.ts CHANGED
@@ -60,5 +60,9 @@ export { default as SDatePicker } from './s-date-picker/index';
60
60
  export type { SDatePickerProps } from './s-date-picker/index';
61
61
  export { default as SLocalizationProvider } from './s-localization-provider/index';
62
62
  export type { SLocalizationProviderProps } from './s-localization-provider/index';
63
+ export { default as SGradientIcon } from './s-gradient-icon/index';
64
+ export type { GradientIconProps } from './s-gradient-icon/index';
65
+ export { default as SGlowButton } from './s-glow-button/index';
66
+ export type { GlowButtonProps } from './s-glow-button/index';
63
67
  export * from './hooks';
64
68
  export * from './utils';
package/dist/main.js CHANGED
@@ -10,12 +10,12 @@ import { default as k } from "./s-error/s-error.js";
10
10
  import { default as C } from "./s-empty/s-empty.js";
11
11
  import { default as M } from "./s-dialog/s-dialog.js";
12
12
  import { default as y } from "./s-file-dropzone/s-file-dropzone.js";
13
- import { default as h } from "./s-file-icon/s-file-icon.js";
14
- import { default as I } from "./s-i18n-provider/s-i18n-provider.js";
15
- import { default as N } from "./s-icon-button/s-icon-button.js";
16
- import { default as A } from "./s-label/s-label.js";
17
- import { default as q } from "./s-multi-select/s-multi-select.js";
18
- import { default as G } from "./s-no-ssr/s-no-ssr.js";
13
+ import { default as I } from "./s-file-icon/s-file-icon.js";
14
+ import { default as z } from "./s-i18n-provider/s-i18n-provider.js";
15
+ import { default as G } from "./s-icon-button/s-icon-button.js";
16
+ import { default as j } from "./s-label/s-label.js";
17
+ import { default as A } from "./s-multi-select/s-multi-select.js";
18
+ import { default as q } from "./s-no-ssr/s-no-ssr.js";
19
19
  import { default as J } from "./s-text-field/s-text-field.js";
20
20
  import { default as O } from "./s-pagination/s-pagination.js";
21
21
  import { default as R } from "./s-select/s-select.js";
@@ -30,17 +30,19 @@ import { default as ue } from "./s-theme-provider/s-theme-provider.js";
30
30
  import { default as ge } from "./s-datetime-picker/s-datetime-picker.js";
31
31
  import { default as ce } from "./s-date-picker/s-date-picker.js";
32
32
  import { default as Pe } from "./s-localization-provider/s-localization-provider.js";
33
- import { useDialog as be } from "./hooks/use-dialog.js";
34
- import { usePopover as ve } from "./hooks/use-popover.js";
35
- import { formatDatePosted as Le } from "./utils/dayjs.js";
36
- import { bytesToSize as Fe } from "./utils/bytes-to-size.js";
37
- import { LogLevel as Ee, Logger as he, createLogger as ze, logger as Ie } from "./utils/logger.js";
38
- import { default as Ne } from "dayjs";
33
+ import { default as be } from "./s-gradient-icon/s-gradient-icon.js";
34
+ import { default as ve } from "./s-glow-button/s-glow-button.js";
35
+ import { useDialog as Le } from "./hooks/use-dialog.js";
36
+ import { usePopover as Fe } from "./hooks/use-popover.js";
37
+ import { formatDatePosted as Ee } from "./utils/dayjs.js";
38
+ import { bytesToSize as he } from "./utils/bytes-to-size.js";
39
+ import { LogLevel as Be, Logger as Ge, createLogger as Ne, logger as je } from "./utils/logger.js";
40
+ import { default as Ae } from "dayjs";
39
41
  export {
40
42
  i as DialogConfirmProvider,
41
43
  D as DialogMessageProvider,
42
- Ee as LogLevel,
43
- he as Logger,
44
+ Be as LogLevel,
45
+ Ge as Logger,
44
46
  r as SAutocomplete,
45
47
  a as SButtonLink,
46
48
  m as SCheckbox,
@@ -54,14 +56,16 @@ export {
54
56
  C as SEmpty,
55
57
  k as SError,
56
58
  y as SFileDropzone,
57
- h as SFileIcon,
59
+ I as SFileIcon,
58
60
  ae as SForm,
59
- I as SI18nProvider,
60
- N as SIconButton,
61
- A as SLabel,
61
+ ve as SGlowButton,
62
+ be as SGradientIcon,
63
+ z as SI18nProvider,
64
+ G as SIconButton,
65
+ j as SLabel,
62
66
  Pe as SLocalizationProvider,
63
- q as SMultiSelect,
64
- G as SNoSsr,
67
+ A as SMultiSelect,
68
+ q as SNoSsr,
65
69
  O as SPagination,
66
70
  R as SSelect,
67
71
  W as SSkeleton,
@@ -77,14 +81,14 @@ export {
77
81
  Y as STip,
78
82
  oe as SnackbarMessageProvider,
79
83
  xe as StripeTextField,
80
- Fe as bytesToSize,
81
- ze as createLogger,
82
- Ne as dayjs,
83
- Le as formatDatePosted,
84
- Ie as logger,
85
- be as useDialog,
84
+ he as bytesToSize,
85
+ Ne as createLogger,
86
+ Ae as dayjs,
87
+ Ee as formatDatePosted,
88
+ je as logger,
89
+ Le as useDialog,
86
90
  n as useDialogConfirm,
87
91
  T as useDialogMessage,
88
- ve as usePopover,
92
+ Fe as usePopover,
89
93
  re as useSnackbarMessage
90
94
  };
@@ -0,0 +1,2 @@
1
+ export { default } from './s-glow-button';
2
+ export type { GlowButtonProps } from './s-glow-button';
@@ -0,0 +1,4 @@
1
+ import { default as o } from "./s-glow-button.js";
2
+ export {
3
+ o as default
4
+ };
@@ -0,0 +1,5 @@
1
+ {
2
+ "main": "./index.js",
3
+ "types": "./index.d.ts",
4
+ "sideEffects": false
5
+ }
@@ -0,0 +1,9 @@
1
+ import { default as React } from 'react';
2
+ import { ButtonProps } from '@mui/material';
3
+ export interface GlowButtonProps extends ButtonProps {
4
+ borderRadius?: string | number;
5
+ children: React.ReactNode;
6
+ duration?: number;
7
+ }
8
+ declare const GlowButton: ({ borderRadius, children, duration, ...props }: GlowButtonProps) => import("react/jsx-runtime").JSX.Element;
9
+ export default GlowButton;
@@ -0,0 +1,203 @@
1
+ import { j as n } from "../jsx-runtime-C5mzlN2N.js";
2
+ import { useRef as u, useEffect as A } from "react";
3
+ import { Box as c, Button as $ } from "@mui/material";
4
+ import { useMotionValue as E, useAnimationFrame as F, useTransform as b, useMotionTemplate as z, motion as B } from "framer-motion";
5
+ const w = 120, m = {
6
+ background: "#0f172acc",
7
+ glowColor: "#38bdf8"
8
+ }, y = {
9
+ position: "absolute",
10
+ left: "50%",
11
+ top: "50%",
12
+ width: `${w}px`,
13
+ height: `${w}px`,
14
+ transform: "translate(-50%, -50%)",
15
+ opacity: 0.5,
16
+ background: `radial-gradient(${m.glowColor} 40%, transparent 60%)`,
17
+ filter: "blur(12px)",
18
+ pointerEvents: "none"
19
+ };
20
+ function v({
21
+ children: s,
22
+ duration: p,
23
+ rx: a,
24
+ ry: f,
25
+ phase: l = 0
26
+ }) {
27
+ const t = u(null), e = E(0);
28
+ F((o) => {
29
+ var i;
30
+ const r = (i = t.current) == null ? void 0 : i.getTotalLength();
31
+ if (r) {
32
+ const h = r / p;
33
+ e.set((o * h + r * l) % r);
34
+ }
35
+ });
36
+ const d = b(e, (o) => {
37
+ var r, i;
38
+ return (i = (r = t.current) == null ? void 0 : r.getPointAtLength(o)) == null ? void 0 : i.x;
39
+ }), x = b(e, (o) => {
40
+ var r, i;
41
+ return (i = (r = t.current) == null ? void 0 : r.getPointAtLength(o)) == null ? void 0 : i.y;
42
+ }), g = z`translateX(${d}px) translateY(${x}px) translateX(-50%) translateY(-50%)`;
43
+ return /* @__PURE__ */ n.jsxs(n.Fragment, { children: [
44
+ /* @__PURE__ */ n.jsx(
45
+ "svg",
46
+ {
47
+ xmlns: "http://www.w3.org/2000/svg",
48
+ preserveAspectRatio: "none",
49
+ width: "100%",
50
+ height: "100%",
51
+ style: { position: "absolute", inset: 0 },
52
+ children: /* @__PURE__ */ n.jsx("rect", { fill: "none", width: "100%", height: "100%", rx: a, ry: f, ref: t })
53
+ }
54
+ ),
55
+ /* @__PURE__ */ n.jsx(
56
+ B.div,
57
+ {
58
+ style: {
59
+ position: "absolute",
60
+ top: 0,
61
+ left: 0,
62
+ display: "inline-block",
63
+ transform: g
64
+ },
65
+ children: s
66
+ }
67
+ )
68
+ ] });
69
+ }
70
+ const X = ({ borderRadius: s = 2, children: p, duration: a = 5e3, ...f }) => {
71
+ const l = u(null), t = u(null), e = u(null), d = () => {
72
+ t.current && (e.current !== null && (window.cancelAnimationFrame(e.current), e.current = null), t.current.style.left = "50%", t.current.style.top = "50%", t.current.style.opacity = "0.7");
73
+ }, x = (o) => {
74
+ if (l.current && t.current) {
75
+ const r = l.current.getBoundingClientRect(), i = o.clientX - r.left, h = o.clientY - r.top;
76
+ e.current !== null && window.cancelAnimationFrame(e.current), e.current = window.requestAnimationFrame(() => {
77
+ if (t.current && l.current) {
78
+ const { left: j, top: k, right: M, bottom: C } = l.current.getBoundingClientRect();
79
+ o.clientX >= j && o.clientX <= M && o.clientY >= k && o.clientY <= C && (t.current.style.left = `${i}px`, t.current.style.top = `${h}px`, t.current.style.opacity = "0.7");
80
+ }
81
+ });
82
+ }
83
+ }, g = () => {
84
+ e.current !== null && (window.cancelAnimationFrame(e.current), e.current = null), t.current && (t.current.style.opacity = "0", t.current.style.left = "50%", t.current.style.top = "50%");
85
+ };
86
+ return A(() => () => {
87
+ e.current !== null && window.cancelAnimationFrame(e.current);
88
+ }, []), /* @__PURE__ */ n.jsxs(
89
+ c,
90
+ {
91
+ position: "relative",
92
+ overflow: "hidden",
93
+ height: "60px",
94
+ width: "100%",
95
+ padding: 0.125,
96
+ sx: {
97
+ borderRadius: s,
98
+ backgroundColor: "transparent"
99
+ },
100
+ children: [
101
+ /* @__PURE__ */ n.jsxs(
102
+ c,
103
+ {
104
+ position: "absolute",
105
+ top: 0,
106
+ left: 0,
107
+ right: 0,
108
+ bottom: 0,
109
+ sx: {
110
+ borderRadius: `calc(${s}px * 0.7)`
111
+ },
112
+ children: [
113
+ /* @__PURE__ */ n.jsx(v, { duration: a, rx: "100%", ry: "100%", phase: 0, children: /* @__PURE__ */ n.jsx(c, { sx: { ...y, borderRadius: s } }) }),
114
+ /* @__PURE__ */ n.jsx(v, { duration: a, rx: "100%", ry: "100%", phase: 0.5, children: /* @__PURE__ */ n.jsx(c, { sx: { ...y, borderRadius: s } }) })
115
+ ]
116
+ }
117
+ ),
118
+ /* @__PURE__ */ n.jsx(
119
+ c,
120
+ {
121
+ sx: {
122
+ position: "absolute",
123
+ pointerEvents: "none",
124
+ left: 0,
125
+ top: 0,
126
+ width: "100%",
127
+ height: "100%",
128
+ zIndex: 2
129
+ },
130
+ children: /* @__PURE__ */ n.jsx(
131
+ c,
132
+ {
133
+ ref: t,
134
+ sx: {
135
+ position: "absolute",
136
+ left: "50%",
137
+ top: "50%",
138
+ width: 120,
139
+ height: 120,
140
+ background: `radial-gradient(circle, ${m.glowColor} 0%, transparent 70%)`,
141
+ opacity: 0,
142
+ filter: "blur(16px)",
143
+ borderRadius: "50%",
144
+ transform: "translate(-50%, -50%)",
145
+ transition: "left 0.15s cubic-bezier(.4,2,.6,1), top 0.15s cubic-bezier(.4,2,.6,1), opacity 0.2s"
146
+ }
147
+ }
148
+ )
149
+ }
150
+ ),
151
+ /* @__PURE__ */ n.jsx(
152
+ $,
153
+ {
154
+ ref: l,
155
+ fullWidth: !0,
156
+ disableRipple: !0,
157
+ onMouseMove: x,
158
+ onMouseLeave: g,
159
+ onMouseEnter: d,
160
+ ...f,
161
+ sx: {
162
+ position: "relative",
163
+ zIndex: 1,
164
+ height: "100%",
165
+ borderRadius: s,
166
+ backgroundColor: m.background,
167
+ color: "var(--s-palette-text-main)",
168
+ backdropFilter: "blur(20px)",
169
+ fontSize: "0.875rem",
170
+ textTransform: "none",
171
+ fontWeight: 700,
172
+ overflow: "hidden",
173
+ "&:before": {
174
+ content: '""',
175
+ position: "absolute",
176
+ inset: 0,
177
+ zIndex: 0,
178
+ borderRadius: s,
179
+ padding: "2px",
180
+ background: "var(--s-palette-gradient-primary)",
181
+ WebkitMask: "linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0)",
182
+ WebkitMaskComposite: "xor",
183
+ maskComposite: "exclude",
184
+ pointerEvents: "none"
185
+ },
186
+ "& > *": {
187
+ position: "relative",
188
+ zIndex: 1
189
+ },
190
+ "&:hover": {
191
+ backgroundColor: "var(--s-palette-background-paper)"
192
+ }
193
+ },
194
+ children: /* @__PURE__ */ n.jsx(c, { className: "gradient-text", children: p })
195
+ }
196
+ )
197
+ ]
198
+ }
199
+ );
200
+ };
201
+ export {
202
+ X as default
203
+ };
@@ -0,0 +1,2 @@
1
+ export { default } from './s-gradient-icon';
2
+ export type { GradientIconProps } from './s-gradient-icon';
@@ -0,0 +1,4 @@
1
+ import { default as o } from "./s-gradient-icon.js";
2
+ export {
3
+ o as default
4
+ };
@@ -0,0 +1,5 @@
1
+ {
2
+ "main": "./index.js",
3
+ "types": "./index.d.ts",
4
+ "sideEffects": false
5
+ }
@@ -0,0 +1,12 @@
1
+ import { SvgIconProps, SvgIconTypeMap, SxProps } from '@mui/material';
2
+ import { OverridableComponent } from '@mui/material/OverridableComponent';
3
+ type IconComponent = OverridableComponent<SvgIconTypeMap<{}, 'svg'>> & {
4
+ muiName: string;
5
+ };
6
+ export interface GradientIconProps extends SvgIconProps {
7
+ hovered: boolean;
8
+ IconComponent: IconComponent;
9
+ sx?: SxProps;
10
+ }
11
+ declare const GradientIcon: ({ hovered, IconComponent, sx, ...props }: GradientIconProps) => import("react/jsx-runtime").JSX.Element | null;
12
+ export default GradientIcon;
@@ -0,0 +1,22 @@
1
+ import { j as e } from "../jsx-runtime-C5mzlN2N.js";
2
+ const l = ({ hovered: t, IconComponent: r, sx: s, ...i }) => r ? /* @__PURE__ */ e.jsxs(e.Fragment, { children: [
3
+ /* @__PURE__ */ e.jsx("svg", { width: 0, height: 0, children: /* @__PURE__ */ e.jsxs("linearGradient", { id: "headerGradient", x1: "0", y1: "0", x2: "1", y2: "1", children: [
4
+ /* @__PURE__ */ e.jsx("stop", { offset: "0%", stopColor: "#1469be" }),
5
+ /* @__PURE__ */ e.jsx("stop", { offset: "100%", stopColor: "#43ecff" })
6
+ ] }) }),
7
+ /* @__PURE__ */ e.jsx(
8
+ r,
9
+ {
10
+ ...i,
11
+ sx: {
12
+ fontSize: "1rem",
13
+ fill: t ? "url(#headerGradient)" : "var(--s-palette-text-primary)",
14
+ transition: "fill 0.3s",
15
+ ...s
16
+ }
17
+ }
18
+ )
19
+ ] }) : null;
20
+ export {
21
+ l as default
22
+ };
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "publishConfig": {
4
4
  "registry": "https://registry.npmjs.org"
5
5
  },
6
- "version": "1.0.60",
6
+ "version": "1.0.61",
7
7
  "description": "advanced ui kit for solostylist",
8
8
  "private": false,
9
9
  "type": "module",
@@ -49,7 +49,8 @@
49
49
  "react-dom": "^19.1.0",
50
50
  "react-dropzone": "^14.3.8",
51
51
  "react-i18next": "^15.5.1",
52
- "uuid": "^11.1.0"
52
+ "uuid": "^11.1.0",
53
+ "framer-motion": "^12.23.3"
53
54
  },
54
55
  "devDependencies": {
55
56
  "@ianvs/prettier-plugin-sort-imports": "^4.4.2",