laif-ds 0.1.24 → 0.1.26
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/components/ui/app-select.js +29 -0
- package/dist/components/ui/confirmer.js +4 -4
- package/dist/index.d.ts +26 -0
- package/dist/index.js +16 -13
- package/package.json +1 -1
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsxs as o, jsx as l } from "react/jsx-runtime";
|
|
3
|
+
import { Select as n, SelectTrigger as s, SelectValue as u, SelectContent as i, SelectItem as A } from "./select.js";
|
|
4
|
+
import { SelectGroup as h, SelectLabel as x, SelectScrollDownButton as B, SelectScrollUpButton as v, SelectSeparator as j } from "./select.js";
|
|
5
|
+
function b({
|
|
6
|
+
options: t,
|
|
7
|
+
placeholder: c,
|
|
8
|
+
children: p,
|
|
9
|
+
label: r,
|
|
10
|
+
className: S,
|
|
11
|
+
...a
|
|
12
|
+
}) {
|
|
13
|
+
return /* @__PURE__ */ o(n, { ...a, label: r, children: [
|
|
14
|
+
p || /* @__PURE__ */ l(s, { className: S, children: /* @__PURE__ */ l(u, { placeholder: c }) }),
|
|
15
|
+
/* @__PURE__ */ l(i, { children: t.map((e) => /* @__PURE__ */ l(A, { value: String(e.value), disabled: e.disabled, children: e.label }, e.value)) })
|
|
16
|
+
] });
|
|
17
|
+
}
|
|
18
|
+
export {
|
|
19
|
+
b as AppSelect,
|
|
20
|
+
i as AppSelectContent,
|
|
21
|
+
h as AppSelectGroup,
|
|
22
|
+
A as AppSelectItem,
|
|
23
|
+
x as AppSelectLabel,
|
|
24
|
+
B as AppSelectScrollDownButton,
|
|
25
|
+
v as AppSelectScrollUpButton,
|
|
26
|
+
j as AppSelectSeparator,
|
|
27
|
+
s as AppSelectTrigger,
|
|
28
|
+
u as AppSelectValue
|
|
29
|
+
};
|
|
@@ -3,14 +3,13 @@ import { jsx as o, jsxs as t } from "react/jsx-runtime";
|
|
|
3
3
|
import { createAsk as p } from "../../node_modules/use-ask/dist/index.js";
|
|
4
4
|
import { AlertDialog as d, AlertDialogContent as m, AlertDialogHeader as A, AlertDialogTitle as f, AlertDialogDescription as g, AlertDialogFooter as h, AlertDialogCancel as u } from "./alert-dialog.js";
|
|
5
5
|
import { Button as C } from "./button.js";
|
|
6
|
-
const [n, D] = p({});
|
|
7
|
-
n.ask;
|
|
6
|
+
const [n, D] = p({}), O = n.ask;
|
|
8
7
|
n.safeAsk;
|
|
9
8
|
const k = {
|
|
10
9
|
title: "Are you sure?",
|
|
11
10
|
cancelText: "Cancel",
|
|
12
11
|
actionText: "Continue"
|
|
13
|
-
},
|
|
12
|
+
}, P = () => {
|
|
14
13
|
const [{ key: r, payload: i }, { asking: l, cancel: c, ok: a }] = D(), e = { ...k, ...i };
|
|
15
14
|
return /* @__PURE__ */ o(
|
|
16
15
|
d,
|
|
@@ -30,5 +29,6 @@ const k = {
|
|
|
30
29
|
);
|
|
31
30
|
};
|
|
32
31
|
export {
|
|
33
|
-
|
|
32
|
+
P as Confirmer,
|
|
33
|
+
O as confirm
|
|
34
34
|
};
|
package/dist/index.d.ts
CHANGED
|
@@ -123,6 +123,20 @@ declare const alertVariants: (props?: ({
|
|
|
123
123
|
|
|
124
124
|
declare type Animation_2 = VariantProps<typeof chatBubbleVariants>["animation"];
|
|
125
125
|
|
|
126
|
+
export declare function AppSelect({ options, placeholder, children, label, className, ...props }: AppSelectProps): JSX.Element;
|
|
127
|
+
|
|
128
|
+
export declare interface AppSelectOption {
|
|
129
|
+
value: string | number;
|
|
130
|
+
label: string | React_2.ReactNode;
|
|
131
|
+
disabled?: boolean;
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
export declare interface AppSelectProps extends React_2.ComponentProps<typeof Select> {
|
|
135
|
+
options: AppSelectOption[];
|
|
136
|
+
placeholder?: string;
|
|
137
|
+
className?: string;
|
|
138
|
+
}
|
|
139
|
+
|
|
126
140
|
export declare function AppSidebar({ navigation, navigationFooter, versions, defaultVersion, headerContent, footerContent, showRail, linkComponent: LinkComponent, linkProps, ...props }: AppSidebarProps): JSX.Element;
|
|
127
141
|
|
|
128
142
|
declare interface AppSidebarProps extends React_2.ComponentProps<typeof Sidebar> {
|
|
@@ -464,8 +478,20 @@ export declare function CommandSeparator({ className, ...props }: React_2.Compon
|
|
|
464
478
|
|
|
465
479
|
export declare function CommandShortcut({ className, ...props }: React_2.ComponentProps<"span">): JSX.Element;
|
|
466
480
|
|
|
481
|
+
declare const confirm_2: (payload: ConfirmOptions) => Promise<boolean>;
|
|
482
|
+
export { confirm_2 as confirm }
|
|
483
|
+
|
|
467
484
|
export declare const Confirmer: () => JSX.Element;
|
|
468
485
|
|
|
486
|
+
declare interface ConfirmOptions {
|
|
487
|
+
title?: React.ReactNode;
|
|
488
|
+
description?: React.ReactNode;
|
|
489
|
+
cancelText?: React.ReactNode;
|
|
490
|
+
actionText?: React.ReactNode;
|
|
491
|
+
CancelProps?: React.ComponentProps<typeof AlertDialogCancel>;
|
|
492
|
+
ActionProps?: React.ComponentProps<typeof Button>;
|
|
493
|
+
}
|
|
494
|
+
|
|
469
495
|
export declare function ContextMenu({ ...props }: React_2.ComponentProps<typeof ContextMenuPrimitive.Root>): JSX.Element;
|
|
470
496
|
|
|
471
497
|
export declare function ContextMenuCheckboxItem({ className, children, checked, ...props }: React_2.ComponentProps<typeof ContextMenuPrimitive.CheckboxItem>): JSX.Element;
|
package/dist/index.js
CHANGED
|
@@ -70,13 +70,14 @@ import { GanttConsts as Va } from "./components/ui/gantt/constants/GanttConsts.j
|
|
|
70
70
|
import { DragStepSizes as Oa } from "./components/ui/gantt/enums/DragStepSizes.js";
|
|
71
71
|
import { DataRepeatTypes as qa } from "./components/ui/gantt/enums/DataRepeatTimes.js";
|
|
72
72
|
import { AppSidebar as Ka } from "./components/ui/app-sidebar.js";
|
|
73
|
-
import { Confirmer as Ua } from "./components/ui/confirmer.js";
|
|
74
|
-
import {
|
|
75
|
-
import {
|
|
76
|
-
import {
|
|
77
|
-
import {
|
|
78
|
-
import {
|
|
79
|
-
import {
|
|
73
|
+
import { Confirmer as Ua, confirm as Wa } from "./components/ui/confirmer.js";
|
|
74
|
+
import { AppSelect as Ya } from "./components/ui/app-select.js";
|
|
75
|
+
import { useAudioRecording as _a } from "./hooks/use-audio-recording.js";
|
|
76
|
+
import { useAutoScroll as en } from "./hooks/use-auto-scroll.js";
|
|
77
|
+
import { useAutosizeTextArea as on } from "./hooks/use-autosize-textarea.js";
|
|
78
|
+
import { useCopyToClipboard as an } from "./hooks/use-copy-to-clipboard.js";
|
|
79
|
+
import { useDebounce as pn } from "./hooks/use-debounce.js";
|
|
80
|
+
import { useIsMobile as ln } from "./hooks/use-mobile.js";
|
|
80
81
|
export {
|
|
81
82
|
ne as Accordion,
|
|
82
83
|
ie as AccordionContent,
|
|
@@ -94,6 +95,7 @@ export {
|
|
|
94
95
|
Te as AlertDialogTitle,
|
|
95
96
|
De as AlertDialogTrigger,
|
|
96
97
|
ge as AlertTitle,
|
|
98
|
+
Ya as AppSelect,
|
|
97
99
|
Ka as AppSidebar,
|
|
98
100
|
a as AspectRatio,
|
|
99
101
|
Ae as AsyncSelect,
|
|
@@ -319,13 +321,14 @@ export {
|
|
|
319
321
|
ke as Typo,
|
|
320
322
|
x as badgeVariants,
|
|
321
323
|
C as buttonVariants,
|
|
324
|
+
Wa as confirm,
|
|
322
325
|
W as toggleVariants,
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
326
|
+
_a as useAudioRecording,
|
|
327
|
+
en as useAutoScroll,
|
|
328
|
+
on as useAutosizeTextArea,
|
|
329
|
+
an as useCopyToClipboard,
|
|
330
|
+
pn as useDebounce,
|
|
328
331
|
Nr as useFormField,
|
|
329
|
-
|
|
332
|
+
ln as useIsMobile,
|
|
330
333
|
wa as useSidebar
|
|
331
334
|
};
|