@solostylist/ui-kit 1.0.72 → 1.0.74
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 +2 -0
- package/dist/main.js +29 -27
- package/dist/s-copyable-text/index.d.ts +2 -0
- package/dist/s-copyable-text/index.js +4 -0
- package/dist/s-copyable-text/package.json +5 -0
- package/dist/s-copyable-text/s-copyable-text.d.ts +7 -0
- package/dist/s-copyable-text/s-copyable-text.js +55 -0
- package/dist/theme/customizations/inputs.js +23 -17
- package/package.json +1 -1
package/dist/main.d.ts
CHANGED
|
@@ -68,5 +68,7 @@ export { default as SGlowButton } from './s-glow-button/index';
|
|
|
68
68
|
export type { GlowButtonProps } from './s-glow-button/index';
|
|
69
69
|
export { default as SMovingBorder } from './s-moving-border/index';
|
|
70
70
|
export type { SMovingBorderProps } from './s-moving-border/index';
|
|
71
|
+
export { default as SCopyableText } from './s-copyable-text/index';
|
|
72
|
+
export type { SCopyableTextProps } from './s-copyable-text/index';
|
|
71
73
|
export * from './hooks';
|
|
72
74
|
export * from './utils';
|
package/dist/main.js
CHANGED
|
@@ -3,11 +3,11 @@ import { default as a } from "./s-button-link/s-button-link.js";
|
|
|
3
3
|
import { default as l } from "./s-text-editor/s-text-editor.js";
|
|
4
4
|
import { default as p } from "./s-checkbox/s-checkbox.js";
|
|
5
5
|
import { default as S } from "./s-chips/s-chips.js";
|
|
6
|
-
import { default as
|
|
7
|
-
import { DialogConfirmProvider as
|
|
6
|
+
import { default as d } from "./s-data-table/s-data-table.js";
|
|
7
|
+
import { DialogConfirmProvider as i, default as g, useDialogConfirm as n } from "./s-dialog-confirm/s-dialog-confirm.js";
|
|
8
8
|
import { DialogMessageProvider as D, default as P, useDialogMessage as T } from "./s-dialog-message/s-dialog-message.js";
|
|
9
9
|
import { default as b } from "./s-error/s-error.js";
|
|
10
|
-
import { default as
|
|
10
|
+
import { default as k } from "./s-empty/s-empty.js";
|
|
11
11
|
import { default as L } from "./s-dialog/s-dialog.js";
|
|
12
12
|
import { default as y } from "./s-file-dropzone/s-file-dropzone.js";
|
|
13
13
|
import { default as E } from "./s-file-icon/s-file-icon.js";
|
|
@@ -26,43 +26,45 @@ import { default as ee, SnackbarMessageProvider as oe, useSnackbarMessage as re
|
|
|
26
26
|
import { default as ae } from "./s-form/s-form.js";
|
|
27
27
|
import { SSmartTextField as le } from "./s-smart-text-field/s-smart-text-field.js";
|
|
28
28
|
import { SCopilotKitProvider as pe } from "./s-copilot-kit-provider/s-copilot-kit-provider.js";
|
|
29
|
-
import { SStripeCVC as Se, SStripeExpiry as
|
|
29
|
+
import { SStripeCVC as Se, SStripeExpiry as xe, SStripeNumber as de, StripeTextField as ue } from "./s-stripe/s-stripe.js";
|
|
30
30
|
import { default as ge } from "./s-theme-provider/s-theme-provider.js";
|
|
31
31
|
import { default as ce } from "./s-datetime-picker/s-datetime-picker.js";
|
|
32
32
|
import { default as Pe } from "./s-date-picker/s-date-picker.js";
|
|
33
33
|
import { default as ve } from "./s-localization-provider/s-localization-provider.js";
|
|
34
|
-
import { default as
|
|
34
|
+
import { default as Ce } from "./s-gradient-icon/s-gradient-icon.js";
|
|
35
35
|
import { default as Me } from "./s-glow-button/s-glow-button.js";
|
|
36
36
|
import { default as Fe } from "./s-moving-border/s-moving-border.js";
|
|
37
|
-
import {
|
|
38
|
-
import {
|
|
39
|
-
import {
|
|
40
|
-
import {
|
|
41
|
-
import {
|
|
42
|
-
import {
|
|
37
|
+
import { default as Be } from "./s-copyable-text/s-copyable-text.js";
|
|
38
|
+
import { useDialog as Ie } from "./hooks/use-dialog.js";
|
|
39
|
+
import { usePopover as ze } from "./hooks/use-popover.js";
|
|
40
|
+
import { formatDatePosted as Ne } from "./utils/dayjs.js";
|
|
41
|
+
import { bytesToSize as we } from "./utils/bytes-to-size.js";
|
|
42
|
+
import { LogLevel as Ke, Logger as Ve, createLogger as qe, logger as He } from "./utils/logger.js";
|
|
43
|
+
import { default as Oe } from "dayjs";
|
|
43
44
|
export {
|
|
44
|
-
|
|
45
|
+
i as DialogConfirmProvider,
|
|
45
46
|
D as DialogMessageProvider,
|
|
46
|
-
|
|
47
|
-
|
|
47
|
+
Ke as LogLevel,
|
|
48
|
+
Ve as Logger,
|
|
48
49
|
r as SAutocomplete,
|
|
49
50
|
a as SButtonLink,
|
|
50
51
|
p as SCheckbox,
|
|
51
52
|
S as SChips,
|
|
52
53
|
pe as SCopilotKitProvider,
|
|
53
|
-
|
|
54
|
+
Be as SCopyableText,
|
|
55
|
+
d as SDataTable,
|
|
54
56
|
Pe as SDatePicker,
|
|
55
57
|
ce as SDateTimePicker,
|
|
56
58
|
L as SDialog,
|
|
57
59
|
g as SDialogConfirm,
|
|
58
60
|
P as SDialogMessage,
|
|
59
|
-
|
|
61
|
+
k as SEmpty,
|
|
60
62
|
b as SError,
|
|
61
63
|
y as SFileDropzone,
|
|
62
64
|
E as SFileIcon,
|
|
63
65
|
ae as SForm,
|
|
64
66
|
Me as SGlowButton,
|
|
65
|
-
|
|
67
|
+
Ce as SGradientIcon,
|
|
66
68
|
h as SI18nProvider,
|
|
67
69
|
G as SIconButton,
|
|
68
70
|
j as SLabel,
|
|
@@ -76,23 +78,23 @@ export {
|
|
|
76
78
|
le as SSmartTextField,
|
|
77
79
|
ee as SSnackbarMessage,
|
|
78
80
|
Se as SStripeCVC,
|
|
79
|
-
|
|
80
|
-
|
|
81
|
+
xe as SStripeExpiry,
|
|
82
|
+
de as SStripeNumber,
|
|
81
83
|
l as STextEditor,
|
|
82
84
|
H as STextField,
|
|
83
85
|
_ as STextTruncation,
|
|
84
86
|
ge as SThemeProvider,
|
|
85
87
|
Y as STip,
|
|
86
88
|
oe as SnackbarMessageProvider,
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
89
|
+
ue as StripeTextField,
|
|
90
|
+
we as bytesToSize,
|
|
91
|
+
qe as createLogger,
|
|
92
|
+
Oe as dayjs,
|
|
93
|
+
Ne as formatDatePosted,
|
|
94
|
+
He as logger,
|
|
95
|
+
Ie as useDialog,
|
|
94
96
|
n as useDialogConfirm,
|
|
95
97
|
T as useDialogMessage,
|
|
96
|
-
|
|
98
|
+
ze as usePopover,
|
|
97
99
|
re as useSnackbarMessage
|
|
98
100
|
};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { TypographyProps } from '@mui/material';
|
|
2
|
+
export interface SCopyableTextProps {
|
|
3
|
+
text?: string;
|
|
4
|
+
typographyProps?: TypographyProps;
|
|
5
|
+
}
|
|
6
|
+
declare const SCopyableText: ({ text, typographyProps }: SCopyableTextProps) => import("react/jsx-runtime").JSX.Element | null;
|
|
7
|
+
export default SCopyableText;
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import { j as e } from "../jsx-runtime-DywqP_6a.js";
|
|
2
|
+
import { useState as a } from "react";
|
|
3
|
+
import { Box as l, IconButton as d, Typography as x } from "@mui/material";
|
|
4
|
+
import { c as s } from "../createSvgIcon-DN-sh_sr.js";
|
|
5
|
+
const m = s(/* @__PURE__ */ e.jsx("path", {
|
|
6
|
+
d: "M9 16.17 4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"
|
|
7
|
+
}), "Check"), h = s(/* @__PURE__ */ e.jsx("path", {
|
|
8
|
+
d: "M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12zm3 4H8c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h11c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2m0 16H8V7h11z"
|
|
9
|
+
}), "ContentCopy"), j = ({ text: t, typographyProps: o }) => {
|
|
10
|
+
const [r, i] = a(!1), n = async () => {
|
|
11
|
+
try {
|
|
12
|
+
await navigator.clipboard.writeText(t || ""), i(!0), setTimeout(() => i(!1), 2e3);
|
|
13
|
+
} catch (c) {
|
|
14
|
+
console.error("Failed to copy text:", c);
|
|
15
|
+
}
|
|
16
|
+
};
|
|
17
|
+
return t ? /* @__PURE__ */ e.jsxs(l, { sx: { position: "relative" }, children: [
|
|
18
|
+
/* @__PURE__ */ e.jsx(
|
|
19
|
+
d,
|
|
20
|
+
{
|
|
21
|
+
onClick: n,
|
|
22
|
+
size: "small",
|
|
23
|
+
sx: {
|
|
24
|
+
position: "absolute",
|
|
25
|
+
top: 8,
|
|
26
|
+
right: 8,
|
|
27
|
+
zIndex: 1,
|
|
28
|
+
color: r ? "success.main" : "inherit"
|
|
29
|
+
},
|
|
30
|
+
children: r ? /* @__PURE__ */ e.jsx(m, { fontSize: "small" }) : /* @__PURE__ */ e.jsx(h, { fontSize: "small" })
|
|
31
|
+
}
|
|
32
|
+
),
|
|
33
|
+
/* @__PURE__ */ e.jsx(
|
|
34
|
+
x,
|
|
35
|
+
{
|
|
36
|
+
variant: "body1",
|
|
37
|
+
sx: {
|
|
38
|
+
marginBottom: 0,
|
|
39
|
+
whiteSpace: "pre-wrap",
|
|
40
|
+
padding: 2,
|
|
41
|
+
borderRadius: 1,
|
|
42
|
+
border: "1px solid var(--s-palette-divider)",
|
|
43
|
+
wordBreak: "break-word",
|
|
44
|
+
...o == null ? void 0 : o.sx
|
|
45
|
+
},
|
|
46
|
+
color: "text.secondary",
|
|
47
|
+
...o,
|
|
48
|
+
children: t
|
|
49
|
+
}
|
|
50
|
+
)
|
|
51
|
+
] }) : null;
|
|
52
|
+
};
|
|
53
|
+
export {
|
|
54
|
+
j as default
|
|
55
|
+
};
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import { j as a } from "../../jsx-runtime-DywqP_6a.js";
|
|
2
|
-
import { c as i, s
|
|
2
|
+
import { c as i, s } from "../../createSvgIcon-DN-sh_sr.js";
|
|
3
3
|
import { brand as r, gray as e } from "../theme-primitives.js";
|
|
4
|
-
import { o as
|
|
5
|
-
import { g as
|
|
4
|
+
import { o as p } from "../../outlinedInputClasses-E4FwVkZh.js";
|
|
5
|
+
import { g as n } from "../../generateUtilityClasses-BpNk3DNr.js";
|
|
6
6
|
import { a as t } from "../../createTheme-DuP3DZSF.js";
|
|
7
|
-
const
|
|
7
|
+
const c = i(/* @__PURE__ */ a.jsx("path", {
|
|
8
8
|
d: "M18 19H6c-.55 0-1-.45-1-1V6c0-.55.45-1 1-1h12c.55 0 1 .45 1 1v12c0 .55-.45 1-1 1m1-16H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2"
|
|
9
|
-
}), "CheckBoxOutlineBlankRounded"),
|
|
9
|
+
}), "CheckBoxOutlineBlankRounded"), u = i(/* @__PURE__ */ a.jsx("path", {
|
|
10
10
|
d: "M9 16.17 5.53 12.7a.996.996 0 0 0-1.41 0c-.39.39-.39 1.02 0 1.41l4.18 4.18c.39.39 1.02.39 1.41 0L20.29 7.71c.39-.39.39-1.02 0-1.41a.996.996 0 0 0-1.41 0z"
|
|
11
|
-
}), "CheckRounded"),
|
|
11
|
+
}), "CheckRounded"), b = i(/* @__PURE__ */ a.jsx("path", {
|
|
12
12
|
d: "M18 13H6c-.55 0-1-.45-1-1s.45-1 1-1h12c.55 0 1 .45 1 1s-.45 1-1 1"
|
|
13
|
-
}), "RemoveRounded"),
|
|
13
|
+
}), "RemoveRounded"), g = n("MuiToggleButton", ["root", "disabled", "selected", "standard", "primary", "secondary", "sizeSmall", "sizeMedium", "sizeLarge", "fullWidth"]), d = n("MuiToggleButtonGroup", ["root", "selected", "horizontal", "vertical", "disabled", "grouped", "groupedHorizontal", "groupedVertical", "fullWidth", "firstButton", "lastButton", "middleButton"]), m = {
|
|
14
14
|
MuiButtonBase: {
|
|
15
15
|
defaultProps: {
|
|
16
16
|
disableTouchRipple: !0,
|
|
@@ -268,7 +268,7 @@ const p = i(/* @__PURE__ */ a.jsx("path", {
|
|
|
268
268
|
width: "2.25rem",
|
|
269
269
|
height: "2.25rem",
|
|
270
270
|
padding: "0.25rem",
|
|
271
|
-
[`& .${
|
|
271
|
+
[`& .${s.root}`]: { fontSize: "1rem" }
|
|
272
272
|
}
|
|
273
273
|
},
|
|
274
274
|
{
|
|
@@ -289,11 +289,11 @@ const p = i(/* @__PURE__ */ a.jsx("path", {
|
|
|
289
289
|
root: ({ theme: o }) => ({
|
|
290
290
|
borderRadius: "10px",
|
|
291
291
|
boxShadow: `0 4px 16px ${t(e[400], 0.2)}`,
|
|
292
|
-
[`& .${
|
|
292
|
+
[`& .${d.selected}`]: {
|
|
293
293
|
color: r[500]
|
|
294
294
|
},
|
|
295
295
|
...o.applyStyles("dark", {
|
|
296
|
-
[`& .${
|
|
296
|
+
[`& .${d.selected}`]: {
|
|
297
297
|
color: "#fff"
|
|
298
298
|
},
|
|
299
299
|
boxShadow: `0 4px 16px ${t(r[700], 0.5)}`
|
|
@@ -311,7 +311,7 @@ const p = i(/* @__PURE__ */ a.jsx("path", {
|
|
|
311
311
|
...o.applyStyles("dark", {
|
|
312
312
|
color: e[400],
|
|
313
313
|
boxShadow: "0 4px 16px rgba(0, 0, 0, 0.5)",
|
|
314
|
-
[`&.${
|
|
314
|
+
[`&.${g.selected}`]: {
|
|
315
315
|
color: r[300]
|
|
316
316
|
}
|
|
317
317
|
})
|
|
@@ -321,9 +321,9 @@ const p = i(/* @__PURE__ */ a.jsx("path", {
|
|
|
321
321
|
MuiCheckbox: {
|
|
322
322
|
defaultProps: {
|
|
323
323
|
disableRipple: !0,
|
|
324
|
-
icon: /* @__PURE__ */ a.jsx(
|
|
325
|
-
checkedIcon: /* @__PURE__ */ a.jsx(
|
|
326
|
-
indeterminateIcon: /* @__PURE__ */ a.jsx(
|
|
324
|
+
icon: /* @__PURE__ */ a.jsx(c, { sx: { color: "hsla(210, 0%, 0%, 0.0)" } }),
|
|
325
|
+
checkedIcon: /* @__PURE__ */ a.jsx(u, { sx: { height: 14, width: 14 } }),
|
|
326
|
+
indeterminateIcon: /* @__PURE__ */ a.jsx(b, { sx: { height: 14, width: 14 } })
|
|
327
327
|
},
|
|
328
328
|
styleOverrides: {
|
|
329
329
|
root: ({ theme: o }) => ({
|
|
@@ -410,7 +410,7 @@ const p = i(/* @__PURE__ */ a.jsx("path", {
|
|
|
410
410
|
},
|
|
411
411
|
MuiOutlinedInput: {
|
|
412
412
|
styleOverrides: {
|
|
413
|
-
input: ({ ownerState: o }) => ({
|
|
413
|
+
input: ({ ownerState: o, theme: l }) => ({
|
|
414
414
|
padding: 0,
|
|
415
415
|
...o.type === "number" && {
|
|
416
416
|
// Remove spinner buttons (cross-browser)
|
|
@@ -420,6 +420,12 @@ const p = i(/* @__PURE__ */ a.jsx("path", {
|
|
|
420
420
|
},
|
|
421
421
|
MozAppearance: "textfield"
|
|
422
422
|
// Firefox
|
|
423
|
+
},
|
|
424
|
+
"&:-webkit-autofill": {
|
|
425
|
+
boxShadow: `${(l.vars || l).palette.background.default} 0px 0px 0px 100px inset !important`
|
|
426
|
+
},
|
|
427
|
+
"&:-moz-autofill": {
|
|
428
|
+
boxShadow: `${(l.vars || l).palette.background.default} 0px 0px 0px 100px inset !important`
|
|
423
429
|
}
|
|
424
430
|
}),
|
|
425
431
|
root: ({ theme: o }) => ({
|
|
@@ -432,7 +438,7 @@ const p = i(/* @__PURE__ */ a.jsx("path", {
|
|
|
432
438
|
"&:hover": {
|
|
433
439
|
borderColor: e[400]
|
|
434
440
|
},
|
|
435
|
-
[`&.${
|
|
441
|
+
[`&.${p.focused}`]: {
|
|
436
442
|
outline: `3px solid ${t(r[500], 0.5)}`,
|
|
437
443
|
borderColor: r[400]
|
|
438
444
|
},
|
|
@@ -485,5 +491,5 @@ const p = i(/* @__PURE__ */ a.jsx("path", {
|
|
|
485
491
|
}
|
|
486
492
|
};
|
|
487
493
|
export {
|
|
488
|
-
|
|
494
|
+
m as inputsCustomizations
|
|
489
495
|
};
|