@solostylist/ui-kit 1.0.78 → 1.0.80
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/{Box-reWd7MO-.js → Box-Bfkq7uIw.js} +23 -21
- package/dist/{Close-CVFQMMUW.js → Close-C1lLcTQu.js} +1 -1
- package/dist/{Menu-CGTDGEoX.js → Menu-DbldWmqB.js} +94 -93
- package/dist/{MenuItem-Bdna3McP.js → MenuItem-BHTJlag0.js} +8 -7
- package/dist/{Select-D54ugORZ.js → Select-CT0Hpudx.js} +14 -13
- package/dist/{Stack-ISlVeD89.js → Stack-W0weBtf9.js} +29 -28
- package/dist/{TransitionGroup-DuMpOHcM.js → TransitionGroup-q306siJs.js} +1 -1
- package/dist/{Typography-D38zoHJr.js → Typography-CeAbQ9LX.js} +17 -17
- package/dist/{buttonBaseClasses-CF7RfAgE.js → buttonBaseClasses-CR6HkqQ3.js} +2 -2
- package/dist/colorManipulator-CPZHCebU.js +178 -0
- package/dist/{createSvgIcon-DN-sh_sr.js → createSvgIcon-9XY7lJan.js} +129 -131
- package/dist/createTheme-wt8sY36y.js +2837 -0
- package/dist/{defaultTheme-BDQAWvCM.js → defaultTheme-YL2LZ-0U.js} +7 -7
- package/dist/emotion-serialize.esm-lgBmL_7o.js +195 -0
- package/dist/{extendSxProp-KtEeHd8h.js → extendSxProp-B1pEE-ot.js} +1 -1
- package/dist/generateUtilityClasses-D-O3RBPF.js +10 -0
- package/dist/hooks/use-dialog.d.ts +21 -0
- package/dist/hooks/use-dialog.js +10 -2
- package/dist/hooks/use-popover.d.ts +24 -0
- package/dist/hooks/use-popover.js +7 -1
- package/dist/{iconButtonClasses-DMst1jJO.js → iconButtonClasses-WmsPyI4v.js} +2 -2
- package/dist/index-B6k9mhKf.js +30 -0
- package/dist/{index-x815ub0T.js → index-DAXzX0k9.js} +5 -5
- package/dist/main.d.ts +5 -1
- package/dist/main.js +109 -104
- package/dist/{outlinedInputClasses-E4FwVkZh.js → outlinedInputClasses-Cor6Mcxo.js} +2 -2
- package/dist/s-autocomplete/s-autocomplete.d.ts +31 -0
- package/dist/s-autocomplete/s-autocomplete.js +23 -20
- package/dist/s-button/index.d.ts +2 -0
- package/dist/s-button/index.js +4 -0
- package/dist/s-button/package.json +5 -0
- package/dist/s-button/s-button.d.ts +6 -0
- package/dist/s-button/s-button.js +7 -0
- package/dist/s-button-link/s-button-link.d.ts +37 -1
- package/dist/s-checkbox/s-checkbox.d.ts +21 -0
- package/dist/s-checkbox/s-checkbox.js +9 -9
- package/dist/s-chip/index.d.ts +2 -0
- package/dist/s-chip/index.js +4 -0
- package/dist/s-chip/package.json +5 -0
- package/dist/s-chip/s-chip.d.ts +6 -0
- package/dist/s-chip/s-chip.js +7 -0
- package/dist/s-chips/s-chips.d.ts +26 -1
- package/dist/s-chips/s-chips.js +28 -23
- package/dist/s-copilot-kit-provider/s-copilot-kit-provider.d.ts +28 -0
- package/dist/s-copyable-text/s-copyable-text.d.ts +43 -2
- package/dist/s-copyable-text/s-copyable-text.js +30 -22
- package/dist/s-data-table/s-data-table.d.ts +87 -0
- package/dist/s-data-table/s-data-table.js +33 -22
- package/dist/s-date-picker/s-date-picker.d.ts +25 -0
- package/dist/s-date-picker/s-date-picker.js +109 -92
- package/dist/s-datetime-picker/s-datetime-picker.d.ts +26 -0
- package/dist/s-datetime-picker/s-datetime-picker.js +209 -192
- package/dist/s-dialog/s-dialog.d.ts +27 -0
- package/dist/s-dialog/s-dialog.js +1 -1
- package/dist/s-dialog-confirm/s-dialog-confirm.d.ts +54 -0
- package/dist/s-dialog-confirm/s-dialog-confirm.js +2 -2
- package/dist/s-dialog-message/s-dialog-message.d.ts +51 -0
- package/dist/s-dialog-message/s-dialog-message.js +3 -2
- package/dist/s-empty/s-empty.d.ts +25 -1
- package/dist/s-error/s-error.d.ts +19 -0
- package/dist/s-file-dropzone/s-file-dropzone.d.ts +67 -0
- package/dist/s-file-dropzone/s-file-dropzone.js +6 -4
- package/dist/s-file-icon/s-file-icon.d.ts +28 -0
- package/dist/s-file-icon/s-file-icon.js +5 -2
- package/dist/s-form/s-form.d.ts +22 -0
- package/dist/s-form/s-form.js +9 -10
- package/dist/s-glow-button/index.d.ts +1 -1
- package/dist/s-glow-button/s-glow-button.d.ts +39 -3
- package/dist/s-glow-button/s-glow-button.js +11 -2
- package/dist/s-gradient-icon/s-gradient-icon.d.ts +43 -0
- package/dist/s-gradient-icon/s-gradient-icon.js +6 -1
- package/dist/s-i18n-provider/s-i18n-provider.d.ts +37 -0
- package/dist/s-i18n-provider/s-i18n-provider.js +8 -1
- package/dist/s-icon-button/s-icon-button.d.ts +23 -0
- package/dist/s-interactive-gallery/s-interactive-gallery.d.ts +96 -0
- package/dist/s-interactive-gallery/s-interactive-gallery.js +175 -82
- package/dist/s-label/s-label.d.ts +30 -2
- package/dist/s-label/s-label.js +8 -18
- package/dist/s-lazy-image/s-lazy-image.d.ts +28 -1
- package/dist/s-localization-provider/s-localization-provider.d.ts +30 -0
- package/dist/s-localization-provider/s-localization-provider.js +5 -2
- package/dist/s-moving-border/s-moving-border.d.ts +41 -0
- package/dist/s-moving-border/s-moving-border.js +5 -1
- package/dist/s-multi-select/s-multi-select.d.ts +23 -0
- package/dist/s-multi-select/s-multi-select.js +3 -3
- package/dist/s-no-ssr/s-no-ssr.d.ts +38 -0
- package/dist/s-pagination/s-pagination.d.ts +29 -0
- package/dist/s-select/s-select.d.ts +35 -0
- package/dist/s-select/s-select.js +41 -37
- package/dist/s-skeleton/s-skeleton.d.ts +31 -1
- package/dist/s-smart-text-field/s-smart-text-field.d.ts +28 -0
- package/dist/s-smart-text-field/s-smart-text-field.js +1425 -1399
- package/dist/s-snackbar-message/s-snackbar-message.d.ts +56 -2
- package/dist/s-stripe/s-stripe.d.ts +93 -0
- package/dist/s-stripe/s-stripe.js +3 -0
- package/dist/s-stripe/stripe-input.d.ts +23 -0
- package/dist/s-stripe/stripe-input.js +1 -0
- package/dist/s-text-editor/index.d.ts +2 -0
- package/dist/s-text-editor/index.js +4 -2
- package/dist/s-text-editor/s-text-editor-toolbar.d.ts +33 -0
- package/dist/s-text-editor/s-text-editor-toolbar.js +4 -4
- package/dist/s-text-editor/s-text-editor.js +1 -1
- package/dist/s-text-field/s-text-field.d.ts +23 -0
- package/dist/s-text-truncation/s-text-truncation.d.ts +30 -0
- package/dist/s-theme-provider/s-theme-provider.d.ts +24 -3
- package/dist/s-theme-provider/s-theme-provider.js +9 -2
- package/dist/s-tip/s-tip.d.ts +27 -0
- package/dist/s-tip/s-tip.js +5 -3
- package/dist/svgIconClasses-BYFQaEQ7.js +10 -0
- package/dist/{tabClasses-LXCeUS4i.js → tabClasses-CXQXD3XZ.js} +2 -2
- package/dist/theme/components/avatar.js +1 -1
- package/dist/theme/components/button.d.ts +5834 -0
- package/dist/theme/components/button.js +186 -0
- package/dist/theme/components/chip.d.ts +117 -0
- package/dist/theme/components/chip.js +168 -0
- package/dist/theme/components/components.d.ts +5944 -0
- package/dist/theme/components/components.js +16 -12
- package/dist/theme/customizations/data-display.d.ts +0 -5
- package/dist/theme/customizations/data-display.js +15 -144
- package/dist/theme/customizations/feedback.js +1 -1
- package/dist/theme/customizations/inputs.js +29 -226
- package/dist/theme/customizations/navigation.js +26 -12
- package/dist/theme/customizations/surfaces.js +5 -5
- package/dist/theme/theme-primitives.d.ts +24 -0
- package/dist/theme/theme-primitives.js +73 -48
- package/dist/{typographyClasses-QAKcrTAX.js → typographyClasses-DTwotNbm.js} +2 -2
- package/dist/{useMobilePicker-DlmTFHhN.js → useMobilePicker-CYRSYIKP.js} +1852 -1848
- package/dist/{useSlot-CiHsL61G.js → useSlot-B_4ipGBP.js} +6 -6
- package/dist/{useTheme-Dy5JmnOe.js → useTheme-D1MJ3g_i.js} +1 -1
- package/dist/{useThemeProps-BGjjVPlJ.js → useThemeProps-CTcSO3lC.js} +2 -2
- package/dist/{warning-DWsjz4u6.js → warning-DyDdgu8-.js} +3 -3
- package/package.json +6 -4
- package/dist/HelpOutlineOutlined-Dw_XSjYK.js +0 -8
- package/dist/chipClasses-WFcUH6gU.js +0 -10
- package/dist/createTheme-DuP3DZSF.js +0 -3005
- package/dist/generateUtilityClasses-BpNk3DNr.js +0 -230
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { a as r } from "./createTheme-wt8sY36y.js";
|
|
2
2
|
function f(t) {
|
|
3
3
|
var n, s, e = "";
|
|
4
4
|
if (typeof t == "string" || typeof t == "number") e += t;
|
|
@@ -34,10 +34,10 @@ function h(t, n, s = !1) {
|
|
|
34
34
|
e[c] = {
|
|
35
35
|
...l
|
|
36
36
|
};
|
|
37
|
-
for (const
|
|
38
|
-
if (Object.prototype.hasOwnProperty.call(o,
|
|
39
|
-
const
|
|
40
|
-
e[c][
|
|
37
|
+
for (const y in o)
|
|
38
|
+
if (Object.prototype.hasOwnProperty.call(o, y)) {
|
|
39
|
+
const a = y;
|
|
40
|
+
e[c][a] = h(o[a], l[a], s);
|
|
41
41
|
}
|
|
42
42
|
}
|
|
43
43
|
} else c === "className" && s && n.className ? e.className = m(t == null ? void 0 : t.className, n == null ? void 0 : n.className) : c === "style" && s && n.style ? e.style = {
|
|
@@ -47,9 +47,9 @@ function h(t, n, s = !1) {
|
|
|
47
47
|
}
|
|
48
48
|
return e;
|
|
49
49
|
}
|
|
50
|
-
const
|
|
50
|
+
const b = r();
|
|
51
51
|
export {
|
|
52
52
|
m as c,
|
|
53
|
-
|
|
53
|
+
b as d,
|
|
54
54
|
h as r
|
|
55
55
|
};
|
|
@@ -0,0 +1,195 @@
|
|
|
1
|
+
function C(r) {
|
|
2
|
+
for (var e = 0, n, t = 0, a = r.length; a >= 4; ++t, a -= 4)
|
|
3
|
+
n = r.charCodeAt(t) & 255 | (r.charCodeAt(++t) & 255) << 8 | (r.charCodeAt(++t) & 255) << 16 | (r.charCodeAt(++t) & 255) << 24, n = /* Math.imul(k, m): */
|
|
4
|
+
(n & 65535) * 1540483477 + ((n >>> 16) * 59797 << 16), n ^= /* k >>> r: */
|
|
5
|
+
n >>> 24, e = /* Math.imul(k, m): */
|
|
6
|
+
(n & 65535) * 1540483477 + ((n >>> 16) * 59797 << 16) ^ /* Math.imul(h, m): */
|
|
7
|
+
(e & 65535) * 1540483477 + ((e >>> 16) * 59797 << 16);
|
|
8
|
+
switch (a) {
|
|
9
|
+
case 3:
|
|
10
|
+
e ^= (r.charCodeAt(t + 2) & 255) << 16;
|
|
11
|
+
case 2:
|
|
12
|
+
e ^= (r.charCodeAt(t + 1) & 255) << 8;
|
|
13
|
+
case 1:
|
|
14
|
+
e ^= r.charCodeAt(t) & 255, e = /* Math.imul(h, m): */
|
|
15
|
+
(e & 65535) * 1540483477 + ((e >>> 16) * 59797 << 16);
|
|
16
|
+
}
|
|
17
|
+
return e ^= e >>> 13, e = /* Math.imul(h, m): */
|
|
18
|
+
(e & 65535) * 1540483477 + ((e >>> 16) * 59797 << 16), ((e ^ e >>> 15) >>> 0).toString(36);
|
|
19
|
+
}
|
|
20
|
+
var y = {
|
|
21
|
+
animationIterationCount: 1,
|
|
22
|
+
aspectRatio: 1,
|
|
23
|
+
borderImageOutset: 1,
|
|
24
|
+
borderImageSlice: 1,
|
|
25
|
+
borderImageWidth: 1,
|
|
26
|
+
boxFlex: 1,
|
|
27
|
+
boxFlexGroup: 1,
|
|
28
|
+
boxOrdinalGroup: 1,
|
|
29
|
+
columnCount: 1,
|
|
30
|
+
columns: 1,
|
|
31
|
+
flex: 1,
|
|
32
|
+
flexGrow: 1,
|
|
33
|
+
flexPositive: 1,
|
|
34
|
+
flexShrink: 1,
|
|
35
|
+
flexNegative: 1,
|
|
36
|
+
flexOrder: 1,
|
|
37
|
+
gridRow: 1,
|
|
38
|
+
gridRowEnd: 1,
|
|
39
|
+
gridRowSpan: 1,
|
|
40
|
+
gridRowStart: 1,
|
|
41
|
+
gridColumn: 1,
|
|
42
|
+
gridColumnEnd: 1,
|
|
43
|
+
gridColumnSpan: 1,
|
|
44
|
+
gridColumnStart: 1,
|
|
45
|
+
msGridRow: 1,
|
|
46
|
+
msGridRowSpan: 1,
|
|
47
|
+
msGridColumn: 1,
|
|
48
|
+
msGridColumnSpan: 1,
|
|
49
|
+
fontWeight: 1,
|
|
50
|
+
lineHeight: 1,
|
|
51
|
+
opacity: 1,
|
|
52
|
+
order: 1,
|
|
53
|
+
orphans: 1,
|
|
54
|
+
scale: 1,
|
|
55
|
+
tabSize: 1,
|
|
56
|
+
widows: 1,
|
|
57
|
+
zIndex: 1,
|
|
58
|
+
zoom: 1,
|
|
59
|
+
WebkitLineClamp: 1,
|
|
60
|
+
// SVG-related properties
|
|
61
|
+
fillOpacity: 1,
|
|
62
|
+
floodOpacity: 1,
|
|
63
|
+
stopOpacity: 1,
|
|
64
|
+
strokeDasharray: 1,
|
|
65
|
+
strokeDashoffset: 1,
|
|
66
|
+
strokeMiterlimit: 1,
|
|
67
|
+
strokeOpacity: 1,
|
|
68
|
+
strokeWidth: 1
|
|
69
|
+
};
|
|
70
|
+
function w(r) {
|
|
71
|
+
var e = /* @__PURE__ */ Object.create(null);
|
|
72
|
+
return function(n) {
|
|
73
|
+
return e[n] === void 0 && (e[n] = r(n)), e[n];
|
|
74
|
+
};
|
|
75
|
+
}
|
|
76
|
+
var A = /[A-Z]|^ms/g, S = /_EMO_([^_]+?)_([^]*?)_EMO_/g, v = function(e) {
|
|
77
|
+
return e.charCodeAt(1) === 45;
|
|
78
|
+
}, x = function(e) {
|
|
79
|
+
return e != null && typeof e != "boolean";
|
|
80
|
+
}, d = /* @__PURE__ */ w(function(r) {
|
|
81
|
+
return v(r) ? r : r.replace(A, "-$&").toLowerCase();
|
|
82
|
+
}), h = function(e, n) {
|
|
83
|
+
switch (e) {
|
|
84
|
+
case "animation":
|
|
85
|
+
case "animationName":
|
|
86
|
+
if (typeof n == "string")
|
|
87
|
+
return n.replace(S, function(t, a, f) {
|
|
88
|
+
return u = {
|
|
89
|
+
name: a,
|
|
90
|
+
styles: f,
|
|
91
|
+
next: u
|
|
92
|
+
}, a;
|
|
93
|
+
});
|
|
94
|
+
}
|
|
95
|
+
return y[e] !== 1 && !v(e) && typeof n == "number" && n !== 0 ? n + "px" : n;
|
|
96
|
+
};
|
|
97
|
+
function s(r, e, n) {
|
|
98
|
+
if (n == null)
|
|
99
|
+
return "";
|
|
100
|
+
var t = n;
|
|
101
|
+
if (t.__emotion_styles !== void 0)
|
|
102
|
+
return t;
|
|
103
|
+
switch (typeof n) {
|
|
104
|
+
case "boolean":
|
|
105
|
+
return "";
|
|
106
|
+
case "object": {
|
|
107
|
+
var a = n;
|
|
108
|
+
if (a.anim === 1)
|
|
109
|
+
return u = {
|
|
110
|
+
name: a.name,
|
|
111
|
+
styles: a.styles,
|
|
112
|
+
next: u
|
|
113
|
+
}, a.name;
|
|
114
|
+
var f = n;
|
|
115
|
+
if (f.styles !== void 0) {
|
|
116
|
+
var o = f.next;
|
|
117
|
+
if (o !== void 0)
|
|
118
|
+
for (; o !== void 0; )
|
|
119
|
+
u = {
|
|
120
|
+
name: o.name,
|
|
121
|
+
styles: o.styles,
|
|
122
|
+
next: u
|
|
123
|
+
}, o = o.next;
|
|
124
|
+
var i = f.styles + ";";
|
|
125
|
+
return i;
|
|
126
|
+
}
|
|
127
|
+
return O(r, e, n);
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
var c = n;
|
|
131
|
+
if (e == null)
|
|
132
|
+
return c;
|
|
133
|
+
var l = e[c];
|
|
134
|
+
return l !== void 0 ? l : c;
|
|
135
|
+
}
|
|
136
|
+
function O(r, e, n) {
|
|
137
|
+
var t = "";
|
|
138
|
+
if (Array.isArray(n))
|
|
139
|
+
for (var a = 0; a < n.length; a++)
|
|
140
|
+
t += s(r, e, n[a]) + ";";
|
|
141
|
+
else
|
|
142
|
+
for (var f in n) {
|
|
143
|
+
var o = n[f];
|
|
144
|
+
if (typeof o != "object") {
|
|
145
|
+
var i = o;
|
|
146
|
+
e != null && e[i] !== void 0 ? t += f + "{" + e[i] + "}" : x(i) && (t += d(f) + ":" + h(f, i) + ";");
|
|
147
|
+
} else if (Array.isArray(o) && typeof o[0] == "string" && (e == null || e[o[0]] === void 0))
|
|
148
|
+
for (var c = 0; c < o.length; c++)
|
|
149
|
+
x(o[c]) && (t += d(f) + ":" + h(f, o[c]) + ";");
|
|
150
|
+
else {
|
|
151
|
+
var l = s(r, e, o);
|
|
152
|
+
switch (f) {
|
|
153
|
+
case "animation":
|
|
154
|
+
case "animationName": {
|
|
155
|
+
t += d(f) + ":" + l + ";";
|
|
156
|
+
break;
|
|
157
|
+
}
|
|
158
|
+
default:
|
|
159
|
+
t += f + "{" + l + "}";
|
|
160
|
+
}
|
|
161
|
+
}
|
|
162
|
+
}
|
|
163
|
+
return t;
|
|
164
|
+
}
|
|
165
|
+
var p = /label:\s*([^\s;{]+)\s*(;|$)/g, u;
|
|
166
|
+
function R(r, e, n) {
|
|
167
|
+
if (r.length === 1 && typeof r[0] == "object" && r[0] !== null && r[0].styles !== void 0)
|
|
168
|
+
return r[0];
|
|
169
|
+
var t = !0, a = "";
|
|
170
|
+
u = void 0;
|
|
171
|
+
var f = r[0];
|
|
172
|
+
if (f == null || f.raw === void 0)
|
|
173
|
+
t = !1, a += s(n, e, f);
|
|
174
|
+
else {
|
|
175
|
+
var o = f;
|
|
176
|
+
a += o[0];
|
|
177
|
+
}
|
|
178
|
+
for (var i = 1; i < r.length; i++)
|
|
179
|
+
if (a += s(n, e, r[i]), t) {
|
|
180
|
+
var c = f;
|
|
181
|
+
a += c[i];
|
|
182
|
+
}
|
|
183
|
+
p.lastIndex = 0;
|
|
184
|
+
for (var l = "", m; (m = p.exec(a)) !== null; )
|
|
185
|
+
l += "-" + m[1];
|
|
186
|
+
var b = C(a) + l;
|
|
187
|
+
return {
|
|
188
|
+
name: b,
|
|
189
|
+
styles: a,
|
|
190
|
+
next: u
|
|
191
|
+
};
|
|
192
|
+
}
|
|
193
|
+
export {
|
|
194
|
+
R as s
|
|
195
|
+
};
|
|
@@ -1,7 +1,28 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Interface for dialog state management controller
|
|
3
|
+
* @template T - Type of data that can be passed to the dialog
|
|
4
|
+
*/
|
|
1
5
|
export interface DialogController<T> {
|
|
6
|
+
/** Optional data passed when opening the dialog */
|
|
2
7
|
data?: T;
|
|
8
|
+
/** Function to close the dialog */
|
|
3
9
|
handleClose: () => void;
|
|
10
|
+
/** Function to open the dialog with optional data */
|
|
4
11
|
handleOpen: (data?: T) => void;
|
|
12
|
+
/** Current open state of the dialog */
|
|
5
13
|
open: boolean;
|
|
6
14
|
}
|
|
15
|
+
/**
|
|
16
|
+
* useDialog - A React hook for managing dialog/modal state and data.
|
|
17
|
+
*
|
|
18
|
+
* Features:
|
|
19
|
+
* - Generic type support for passing data to dialogs
|
|
20
|
+
* - Memoized open/close handlers for performance
|
|
21
|
+
* - Simple boolean state management
|
|
22
|
+
* - Optional data payload when opening
|
|
23
|
+
* - Consistent API across all dialog components
|
|
24
|
+
*
|
|
25
|
+
* @template T - Type of data that can be passed to the dialog
|
|
26
|
+
* @returns DialogController<T> - Object with state and handlers
|
|
27
|
+
*/
|
|
7
28
|
export declare function useDialog<T = unknown>(): DialogController<T>;
|
package/dist/hooks/use-dialog.js
CHANGED
|
@@ -1,11 +1,19 @@
|
|
|
1
1
|
import * as e from "react";
|
|
2
2
|
function l() {
|
|
3
|
-
const [a, t] = e.useState({
|
|
3
|
+
const [a, t] = e.useState({
|
|
4
|
+
open: !1,
|
|
5
|
+
data: void 0
|
|
6
|
+
}), o = e.useCallback((s) => {
|
|
4
7
|
t({ open: !0, data: s });
|
|
5
8
|
}, []), n = e.useCallback(() => {
|
|
6
9
|
t({ open: !1 });
|
|
7
10
|
}, []);
|
|
8
|
-
return {
|
|
11
|
+
return {
|
|
12
|
+
data: a.data,
|
|
13
|
+
handleClose: n,
|
|
14
|
+
handleOpen: o,
|
|
15
|
+
open: a.open
|
|
16
|
+
};
|
|
9
17
|
}
|
|
10
18
|
export {
|
|
11
19
|
l as useDialog
|
|
@@ -1,10 +1,34 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* Interface for popover state management controller
|
|
4
|
+
* @template T - Type of the anchor element (defaults to HTMLElement)
|
|
5
|
+
*/
|
|
2
6
|
interface PopoverController<T> {
|
|
7
|
+
/** Ref to the anchor element for positioning */
|
|
3
8
|
anchorRef: React.RefObject<T | null>;
|
|
9
|
+
/** Function to open the popover */
|
|
4
10
|
handleOpen: () => void;
|
|
11
|
+
/** Function to close the popover */
|
|
5
12
|
handleClose: () => void;
|
|
13
|
+
/** Function to toggle the popover state */
|
|
6
14
|
handleToggle: () => void;
|
|
15
|
+
/** Current open state of the popover */
|
|
7
16
|
open: boolean;
|
|
8
17
|
}
|
|
18
|
+
/**
|
|
19
|
+
* usePopover - A React hook for managing popover/dropdown state with anchor positioning.
|
|
20
|
+
*
|
|
21
|
+
* Features:
|
|
22
|
+
* - Ref management for anchor element positioning
|
|
23
|
+
* - Memoized state handlers for performance
|
|
24
|
+
* - Toggle functionality for convenience
|
|
25
|
+
* - Generic type support for different anchor elements
|
|
26
|
+
* - Consistent API across popover components
|
|
27
|
+
*
|
|
28
|
+
* Commonly used with Material-UI Popover, Menu, or custom dropdown components.
|
|
29
|
+
*
|
|
30
|
+
* @template T - Type of the anchor element (defaults to HTMLElement)
|
|
31
|
+
* @returns PopoverController<T> - Object with state, handlers, and anchor ref
|
|
32
|
+
*/
|
|
9
33
|
export declare function usePopover<T = HTMLElement>(): PopoverController<T>;
|
|
10
34
|
export {};
|
|
@@ -7,7 +7,13 @@ function u() {
|
|
|
7
7
|
}, []), t = e.useCallback(() => {
|
|
8
8
|
n((c) => !c);
|
|
9
9
|
}, []);
|
|
10
|
-
return {
|
|
10
|
+
return {
|
|
11
|
+
anchorRef: s,
|
|
12
|
+
handleClose: o,
|
|
13
|
+
handleOpen: l,
|
|
14
|
+
handleToggle: t,
|
|
15
|
+
open: a
|
|
16
|
+
};
|
|
11
17
|
}
|
|
12
18
|
export {
|
|
13
19
|
u as usePopover
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { g as r } from "./generateUtilityClasses-
|
|
2
|
-
import { g as t } from "./
|
|
1
|
+
import { g as r } from "./generateUtilityClasses-D-O3RBPF.js";
|
|
2
|
+
import { g as t } from "./colorManipulator-CPZHCebU.js";
|
|
3
3
|
function n(o) {
|
|
4
4
|
return t("MuiIconButton", o);
|
|
5
5
|
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import l from "@emotion/styled";
|
|
2
|
+
import { s as a } from "./emotion-serialize.esm-lgBmL_7o.js";
|
|
3
|
+
import "@emotion/react";
|
|
4
|
+
/**
|
|
5
|
+
* @mui/styled-engine v7.3.1
|
|
6
|
+
*
|
|
7
|
+
* @license MIT
|
|
8
|
+
* This source code is licensed under the MIT license found in the
|
|
9
|
+
* LICENSE file in the root directory of this source tree.
|
|
10
|
+
*/
|
|
11
|
+
function c(e, t) {
|
|
12
|
+
const r = l(e, t);
|
|
13
|
+
return process.env.NODE_ENV !== "production" ? (...o) => {
|
|
14
|
+
const s = typeof e == "string" ? `"${e}"` : "component";
|
|
15
|
+
return o.length === 0 ? console.error([`MUI: Seems like you called \`styled(${s})()\` without a \`style\` argument.`, 'You must provide a `styles` argument: `styled("div")(styleYouForgotToPass)`.'].join(`
|
|
16
|
+
`)) : o.some((i) => i === void 0) && console.error(`MUI: the styled(${s})(...args) API requires all its args to be defined.`), r(...o);
|
|
17
|
+
} : r;
|
|
18
|
+
}
|
|
19
|
+
function d(e, t) {
|
|
20
|
+
Array.isArray(e.__emotion_styles) && (e.__emotion_styles = t(e.__emotion_styles));
|
|
21
|
+
}
|
|
22
|
+
const n = [];
|
|
23
|
+
function f(e) {
|
|
24
|
+
return n[0] = e, a(n);
|
|
25
|
+
}
|
|
26
|
+
export {
|
|
27
|
+
d as a,
|
|
28
|
+
f as i,
|
|
29
|
+
c as s
|
|
30
|
+
};
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import "react";
|
|
2
2
|
import { j as i } from "./jsx-runtime-DywqP_6a.js";
|
|
3
|
-
import { e as m } from "./extendSxProp-
|
|
4
|
-
import { P as e } from "./createTheme-
|
|
5
|
-
import { d as y } from "./defaultTheme-
|
|
3
|
+
import { e as m } from "./extendSxProp-B1pEE-ot.js";
|
|
4
|
+
import { P as e } from "./createTheme-wt8sY36y.js";
|
|
5
|
+
import { d as y } from "./defaultTheme-YL2LZ-0U.js";
|
|
6
6
|
import { T as d } from "./identifier-BKLqN993.js";
|
|
7
|
-
import { i as b } from "./
|
|
8
|
-
import { u as T } from "./useTheme-
|
|
7
|
+
import { i as b } from "./index-B6k9mhKf.js";
|
|
8
|
+
import { u as T } from "./useTheme-D1MJ3g_i.js";
|
|
9
9
|
import { Global as x } from "@emotion/react";
|
|
10
10
|
function E(r) {
|
|
11
11
|
return r == null || Object.keys(r).length === 0;
|
package/dist/main.d.ts
CHANGED
|
@@ -1,11 +1,15 @@
|
|
|
1
1
|
export { default as SAutocomplete } from './s-autocomplete/index';
|
|
2
2
|
export type { SAutocompleteProps } from './s-autocomplete/index';
|
|
3
|
+
export { default as SButton } from './s-button/index';
|
|
4
|
+
export type { SButtonProps } from './s-button/index';
|
|
3
5
|
export { default as SButtonLink } from './s-button-link/index';
|
|
4
6
|
export type { SButtonLinkProps } from './s-button-link/index';
|
|
5
7
|
export { default as STextEditor } from './s-text-editor/index';
|
|
6
8
|
export type { STextEditorProps } from './s-text-editor/index';
|
|
7
9
|
export { default as SCheckbox } from './s-checkbox/index';
|
|
8
10
|
export type { SCheckboxProps } from './s-checkbox/index';
|
|
11
|
+
export { default as SChip } from './s-chip/index';
|
|
12
|
+
export type { SChipProps } from './s-chip/index';
|
|
9
13
|
export { default as SChips } from './s-chips/index';
|
|
10
14
|
export type { SChipsProps } from './s-chips/index';
|
|
11
15
|
export { default as SDataTable } from './s-data-table/index';
|
|
@@ -65,7 +69,7 @@ export type { SLocalizationProviderProps } from './s-localization-provider/index
|
|
|
65
69
|
export { default as SGradientIcon } from './s-gradient-icon/index';
|
|
66
70
|
export type { GradientIconProps } from './s-gradient-icon/index';
|
|
67
71
|
export { default as SGlowButton } from './s-glow-button/index';
|
|
68
|
-
export type {
|
|
72
|
+
export type { SGlowButtonProps } from './s-glow-button/index';
|
|
69
73
|
export { default as SMovingBorder } from './s-moving-border/index';
|
|
70
74
|
export type { SMovingBorderProps } from './s-moving-border/index';
|
|
71
75
|
export { default as SCopyableText } from './s-copyable-text/index';
|
package/dist/main.js
CHANGED
|
@@ -1,106 +1,111 @@
|
|
|
1
|
-
import { default as
|
|
2
|
-
import { default as
|
|
3
|
-
import { default as
|
|
4
|
-
import { default as
|
|
5
|
-
import
|
|
6
|
-
import { default as
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import { default as
|
|
10
|
-
import { default as
|
|
11
|
-
import { default as
|
|
12
|
-
import { default as
|
|
13
|
-
import { default as
|
|
14
|
-
import { default as
|
|
15
|
-
import { default as
|
|
16
|
-
import { default as
|
|
17
|
-
import { default as
|
|
18
|
-
import { default as
|
|
19
|
-
import { default as
|
|
20
|
-
import { default as
|
|
21
|
-
import { default as
|
|
22
|
-
import { default as
|
|
23
|
-
import { default as
|
|
24
|
-
import { default as
|
|
25
|
-
import { default as
|
|
26
|
-
import { default as
|
|
27
|
-
import {
|
|
28
|
-
import {
|
|
29
|
-
import {
|
|
30
|
-
import {
|
|
31
|
-
import {
|
|
32
|
-
import {
|
|
33
|
-
import { default as
|
|
34
|
-
import { default as
|
|
35
|
-
import { default as
|
|
36
|
-
import { default as
|
|
37
|
-
import { default as
|
|
38
|
-
import {
|
|
39
|
-
import { default as
|
|
40
|
-
import {
|
|
41
|
-
import {
|
|
42
|
-
import {
|
|
43
|
-
import {
|
|
44
|
-
import {
|
|
45
|
-
import {
|
|
1
|
+
import { default as t } from "./s-autocomplete/s-autocomplete.js";
|
|
2
|
+
import { default as f } from "./s-button/s-button.js";
|
|
3
|
+
import { default as p } from "./s-button-link/s-button-link.js";
|
|
4
|
+
import { default as s } from "./s-text-editor/s-text-editor.js";
|
|
5
|
+
import "./s-text-editor/s-text-editor-toolbar.js";
|
|
6
|
+
import { default as S } from "./s-checkbox/s-checkbox.js";
|
|
7
|
+
import { default as u } from "./s-chip/s-chip.js";
|
|
8
|
+
import { default as n } from "./s-chips/s-chips.js";
|
|
9
|
+
import { default as c } from "./s-data-table/s-data-table.js";
|
|
10
|
+
import { DialogConfirmProvider as P, default as T, useDialogConfirm as v } from "./s-dialog-confirm/s-dialog-confirm.js";
|
|
11
|
+
import { DialogMessageProvider as M, default as b, useDialogMessage as k } from "./s-dialog-message/s-dialog-message.js";
|
|
12
|
+
import { default as L } from "./s-error/s-error.js";
|
|
13
|
+
import { default as F } from "./s-empty/s-empty.js";
|
|
14
|
+
import { default as h } from "./s-dialog/s-dialog.js";
|
|
15
|
+
import { default as E } from "./s-file-dropzone/s-file-dropzone.js";
|
|
16
|
+
import { default as N } from "./s-file-icon/s-file-icon.js";
|
|
17
|
+
import { default as w } from "./s-i18n-provider/s-i18n-provider.js";
|
|
18
|
+
import { default as K } from "./s-icon-button/s-icon-button.js";
|
|
19
|
+
import { default as q } from "./s-label/s-label.js";
|
|
20
|
+
import { default as J } from "./s-multi-select/s-multi-select.js";
|
|
21
|
+
import { default as Q } from "./s-no-ssr/s-no-ssr.js";
|
|
22
|
+
import { default as U } from "./s-text-field/s-text-field.js";
|
|
23
|
+
import { default as X } from "./s-pagination/s-pagination.js";
|
|
24
|
+
import { default as Z } from "./s-select/s-select.js";
|
|
25
|
+
import { default as $ } from "./s-skeleton/s-skeleton.js";
|
|
26
|
+
import { default as oe } from "./s-tip/s-tip.js";
|
|
27
|
+
import { default as te } from "./s-text-truncation/s-text-truncation.js";
|
|
28
|
+
import { default as fe, SnackbarMessageProvider as le, useSnackbarMessage as pe } from "./s-snackbar-message/s-snackbar-message.js";
|
|
29
|
+
import { default as se } from "./s-form/s-form.js";
|
|
30
|
+
import { SSmartTextField as Se } from "./s-smart-text-field/s-smart-text-field.js";
|
|
31
|
+
import { SCopilotKitProvider as ue } from "./s-copilot-kit-provider/s-copilot-kit-provider.js";
|
|
32
|
+
import { SStripeCVC as ne, SStripeExpiry as ge, SStripeNumber as ce, StripeTextField as De } from "./s-stripe/s-stripe.js";
|
|
33
|
+
import { default as Te } from "./s-theme-provider/s-theme-provider.js";
|
|
34
|
+
import { default as Ce } from "./s-datetime-picker/s-datetime-picker.js";
|
|
35
|
+
import { default as be } from "./s-date-picker/s-date-picker.js";
|
|
36
|
+
import { default as ye } from "./s-localization-provider/s-localization-provider.js";
|
|
37
|
+
import { default as Ie } from "./s-gradient-icon/s-gradient-icon.js";
|
|
38
|
+
import { default as Be } from "./s-glow-button/s-glow-button.js";
|
|
39
|
+
import { default as ze } from "./s-moving-border/s-moving-border.js";
|
|
40
|
+
import { default as Ge } from "./s-copyable-text/s-copyable-text.js";
|
|
41
|
+
import { GalleryModal as je, MediaItem as we, default as Ae } from "./s-interactive-gallery/s-interactive-gallery.js";
|
|
42
|
+
import { default as Ve } from "./s-lazy-image/s-lazy-image.js";
|
|
43
|
+
import { useDialog as He } from "./hooks/use-dialog.js";
|
|
44
|
+
import { usePopover as Oe } from "./hooks/use-popover.js";
|
|
45
|
+
import { formatDatePosted as Re } from "./utils/dayjs.js";
|
|
46
|
+
import { bytesToSize as We } from "./utils/bytes-to-size.js";
|
|
47
|
+
import { LogLevel as Ye, Logger as Ze, createLogger as _e, logger as $e } from "./utils/logger.js";
|
|
48
|
+
import { default as oo } from "dayjs";
|
|
46
49
|
export {
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
50
|
+
P as DialogConfirmProvider,
|
|
51
|
+
M as DialogMessageProvider,
|
|
52
|
+
je as GalleryModal,
|
|
53
|
+
Ye as LogLevel,
|
|
54
|
+
Ze as Logger,
|
|
55
|
+
we as MediaItem,
|
|
56
|
+
t as SAutocomplete,
|
|
57
|
+
f as SButton,
|
|
58
|
+
p as SButtonLink,
|
|
59
|
+
S as SCheckbox,
|
|
60
|
+
u as SChip,
|
|
61
|
+
n as SChips,
|
|
62
|
+
ue as SCopilotKitProvider,
|
|
63
|
+
Ge as SCopyableText,
|
|
64
|
+
c as SDataTable,
|
|
65
|
+
be as SDatePicker,
|
|
66
|
+
Ce as SDateTimePicker,
|
|
67
|
+
h as SDialog,
|
|
68
|
+
T as SDialogConfirm,
|
|
69
|
+
b as SDialogMessage,
|
|
70
|
+
F as SEmpty,
|
|
71
|
+
L as SError,
|
|
72
|
+
E as SFileDropzone,
|
|
73
|
+
N as SFileIcon,
|
|
74
|
+
se as SForm,
|
|
75
|
+
Be as SGlowButton,
|
|
76
|
+
Ie as SGradientIcon,
|
|
77
|
+
w as SI18nProvider,
|
|
78
|
+
K as SIconButton,
|
|
79
|
+
Ae as SInteractiveGallery,
|
|
80
|
+
q as SLabel,
|
|
81
|
+
Ve as SLazyImage,
|
|
82
|
+
ye as SLocalizationProvider,
|
|
83
|
+
ze as SMovingBorder,
|
|
84
|
+
J as SMultiSelect,
|
|
85
|
+
Q as SNoSsr,
|
|
86
|
+
X as SPagination,
|
|
87
|
+
Z as SSelect,
|
|
88
|
+
$ as SSkeleton,
|
|
89
|
+
Se as SSmartTextField,
|
|
90
|
+
fe as SSnackbarMessage,
|
|
91
|
+
ne as SStripeCVC,
|
|
92
|
+
ge as SStripeExpiry,
|
|
93
|
+
ce as SStripeNumber,
|
|
94
|
+
s as STextEditor,
|
|
95
|
+
U as STextField,
|
|
96
|
+
te as STextTruncation,
|
|
97
|
+
Te as SThemeProvider,
|
|
98
|
+
oe as STip,
|
|
99
|
+
le as SnackbarMessageProvider,
|
|
100
|
+
De as StripeTextField,
|
|
101
|
+
We as bytesToSize,
|
|
102
|
+
_e as createLogger,
|
|
103
|
+
oo as dayjs,
|
|
104
|
+
Re as formatDatePosted,
|
|
105
|
+
$e as logger,
|
|
106
|
+
He as useDialog,
|
|
107
|
+
v as useDialogConfirm,
|
|
108
|
+
k as useDialogMessage,
|
|
109
|
+
Oe as usePopover,
|
|
110
|
+
pe as useSnackbarMessage
|
|
106
111
|
};
|