@scripso-homepad/ui 0.4.26 → 0.4.28
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/{chunk-N73KHOZ4.js → chunk-AOBKWDGW.js} +17 -3
- package/dist/chunk-AOBKWDGW.js.map +1 -0
- package/dist/index.cjs +15 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +16 -1
- package/dist/index.d.ts +16 -1
- package/dist/index.js +2 -2
- package/dist/web/index.cjs +14 -7
- package/dist/web/index.cjs.map +1 -1
- package/dist/web/index.d.cts +3 -1
- package/dist/web/index.d.ts +3 -1
- package/dist/web/index.js +15 -8
- package/dist/web/index.js.map +1 -1
- package/package.json +1 -1
- package/src/index.ts +1 -0
- package/src/theme/tokens.ts +16 -0
- package/src/web/components/ConfirmModal.tsx +5 -2
- package/src/web/components/Modal.tsx +11 -5
- package/dist/chunk-N73KHOZ4.js.map +0 -1
package/dist/web/index.d.cts
CHANGED
|
@@ -436,6 +436,8 @@ type ModalProps = {
|
|
|
436
436
|
subtitle?: string;
|
|
437
437
|
icon?: ReactNode;
|
|
438
438
|
iconContainerClassName?: string;
|
|
439
|
+
titleClassName?: string;
|
|
440
|
+
subtitleClassName?: string;
|
|
439
441
|
children: ReactNode;
|
|
440
442
|
cancelText: string;
|
|
441
443
|
confirmText: string;
|
|
@@ -451,7 +453,7 @@ type ModalProps = {
|
|
|
451
453
|
contentClassName?: string;
|
|
452
454
|
buttonClassName?: string;
|
|
453
455
|
};
|
|
454
|
-
declare function Modal({ open, title, subtitle, icon, iconContainerClassName, children, cancelText, confirmText, onCancel, onConfirm, footerAlign, footerLayout, cancelDisabled, confirmDisabled, closeOnBackdrop, closeOnEscape, containerClassName, contentClassName, buttonClassName, }: ModalProps): react.JSX.Element | null;
|
|
456
|
+
declare function Modal({ open, title, subtitle, icon, iconContainerClassName, titleClassName, subtitleClassName, children, cancelText, confirmText, onCancel, onConfirm, footerAlign, footerLayout, cancelDisabled, confirmDisabled, closeOnBackdrop, closeOnEscape, containerClassName, contentClassName, buttonClassName, }: ModalProps): react.JSX.Element | null;
|
|
455
457
|
|
|
456
458
|
type DrawerProps = {
|
|
457
459
|
open: boolean;
|
package/dist/web/index.d.ts
CHANGED
|
@@ -436,6 +436,8 @@ type ModalProps = {
|
|
|
436
436
|
subtitle?: string;
|
|
437
437
|
icon?: ReactNode;
|
|
438
438
|
iconContainerClassName?: string;
|
|
439
|
+
titleClassName?: string;
|
|
440
|
+
subtitleClassName?: string;
|
|
439
441
|
children: ReactNode;
|
|
440
442
|
cancelText: string;
|
|
441
443
|
confirmText: string;
|
|
@@ -451,7 +453,7 @@ type ModalProps = {
|
|
|
451
453
|
contentClassName?: string;
|
|
452
454
|
buttonClassName?: string;
|
|
453
455
|
};
|
|
454
|
-
declare function Modal({ open, title, subtitle, icon, iconContainerClassName, children, cancelText, confirmText, onCancel, onConfirm, footerAlign, footerLayout, cancelDisabled, confirmDisabled, closeOnBackdrop, closeOnEscape, containerClassName, contentClassName, buttonClassName, }: ModalProps): react.JSX.Element | null;
|
|
456
|
+
declare function Modal({ open, title, subtitle, icon, iconContainerClassName, titleClassName, subtitleClassName, children, cancelText, confirmText, onCancel, onConfirm, footerAlign, footerLayout, cancelDisabled, confirmDisabled, closeOnBackdrop, closeOnEscape, containerClassName, contentClassName, buttonClassName, }: ModalProps): react.JSX.Element | null;
|
|
455
457
|
|
|
456
458
|
type DrawerProps = {
|
|
457
459
|
open: boolean;
|
package/dist/web/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { __commonJS, __require, __toESM, Input, Button } from '../chunk-
|
|
1
|
+
import { __commonJS, __require, __toESM, Input, Button } from '../chunk-AOBKWDGW.js';
|
|
2
2
|
import { ChevronsUpDown, Search, LogOut, PanelLeftClose, PanelLeftOpen, X, Menu, ChevronLeft, ChevronRight } from 'lucide-react';
|
|
3
3
|
import { clsx } from 'clsx';
|
|
4
4
|
import { twMerge } from 'tailwind-merge';
|
|
@@ -30322,6 +30322,8 @@ function Modal({
|
|
|
30322
30322
|
subtitle,
|
|
30323
30323
|
icon,
|
|
30324
30324
|
iconContainerClassName,
|
|
30325
|
+
titleClassName,
|
|
30326
|
+
subtitleClassName,
|
|
30325
30327
|
children,
|
|
30326
30328
|
cancelText,
|
|
30327
30329
|
confirmText,
|
|
@@ -30358,9 +30360,8 @@ function Modal({
|
|
|
30358
30360
|
return null;
|
|
30359
30361
|
}
|
|
30360
30362
|
const sharedButtonClassName = cn(
|
|
30361
|
-
"btn h-13 w-full justify-center!",
|
|
30362
|
-
|
|
30363
|
-
footerLayout !== "split" && buttonClassName
|
|
30363
|
+
"btn h-13 w-full! min-w-0! justify-center!",
|
|
30364
|
+
buttonClassName
|
|
30364
30365
|
);
|
|
30365
30366
|
const modal = /* @__PURE__ */ jsx(
|
|
30366
30367
|
"div",
|
|
@@ -30403,7 +30404,7 @@ function Modal({
|
|
|
30403
30404
|
"h2",
|
|
30404
30405
|
{
|
|
30405
30406
|
id: "homepad-modal-title",
|
|
30406
|
-
className: "typography-title-sm tracking-normal text-black",
|
|
30407
|
+
className: cn("typography-title-sm tracking-normal text-black", titleClassName),
|
|
30407
30408
|
children: title
|
|
30408
30409
|
}
|
|
30409
30410
|
),
|
|
@@ -30411,7 +30412,10 @@ function Modal({
|
|
|
30411
30412
|
"p",
|
|
30412
30413
|
{
|
|
30413
30414
|
id: "homepad-modal-subtitle",
|
|
30414
|
-
className:
|
|
30415
|
+
className: cn(
|
|
30416
|
+
"typography-caption tracking-normal text-storm-gray-400",
|
|
30417
|
+
subtitleClassName
|
|
30418
|
+
),
|
|
30415
30419
|
children: subtitle
|
|
30416
30420
|
}
|
|
30417
30421
|
) : null
|
|
@@ -30906,7 +30910,10 @@ function ConfirmModal({
|
|
|
30906
30910
|
if (!open) {
|
|
30907
30911
|
return null;
|
|
30908
30912
|
}
|
|
30909
|
-
const sharedButtonClassName = cn(
|
|
30913
|
+
const sharedButtonClassName = cn(
|
|
30914
|
+
"btn h-10! w-full! min-w-0! justify-center!",
|
|
30915
|
+
buttonClassName
|
|
30916
|
+
);
|
|
30910
30917
|
return /* @__PURE__ */ jsx(
|
|
30911
30918
|
"div",
|
|
30912
30919
|
{
|
|
@@ -30947,7 +30954,7 @@ function ConfirmModal({
|
|
|
30947
30954
|
}
|
|
30948
30955
|
)
|
|
30949
30956
|
] }),
|
|
30950
|
-
/* @__PURE__ */ jsxs("footer", { className: "
|
|
30957
|
+
/* @__PURE__ */ jsxs("footer", { className: "grid w-full grid-cols-2 gap-4", children: [
|
|
30951
30958
|
/* @__PURE__ */ jsx(
|
|
30952
30959
|
Button,
|
|
30953
30960
|
{
|