laif-ds 0.1.24 → 0.1.25

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.
@@ -1,8 +1,5 @@
1
1
  "use client";
2
- import { getDefaultExportFromCjs as r } from "./_commonjsHelpers.js";
3
- import { __require as e } from "../node_modules/classnames/index.js";
4
- var s = e();
5
- const o = /* @__PURE__ */ r(s);
2
+ var e = {};
6
3
  export {
7
- o as default
4
+ e as __exports
8
5
  };
@@ -1,5 +1,8 @@
1
1
  "use client";
2
- var e = {};
2
+ import { getDefaultExportFromCjs as r } from "./_commonjsHelpers.js";
3
+ import { __require as e } from "../node_modules/classnames/index.js";
4
+ var s = e();
5
+ const o = /* @__PURE__ */ r(s);
3
6
  export {
4
- e as __exports
7
+ o as default
5
8
  };
@@ -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
- }, O = () => {
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
- O as Confirmer
32
+ P as Confirmer,
33
+ O as confirm
34
34
  };
@@ -1,7 +1,7 @@
1
1
  "use client";
2
2
  import { jsx as o, jsxs as M, Fragment as N } from "react/jsx-runtime";
3
3
  import { useContext as R, useRef as a, useState as s, useCallback as k, useMemo as y, useEffect as u } from "react";
4
- import A from "../../../../../_virtual/index5.js";
4
+ import A from "../../../../../_virtual/index6.js";
5
5
  import B from "../../../../../_virtual/debounce.js";
6
6
  import { GanttContext as F } from "../Gantt/GanttContext.js";
7
7
  import { transformData as O } from "../../utils/transformData.js";
package/dist/index.d.ts CHANGED
@@ -464,8 +464,20 @@ export declare function CommandSeparator({ className, ...props }: React_2.Compon
464
464
 
465
465
  export declare function CommandShortcut({ className, ...props }: React_2.ComponentProps<"span">): JSX.Element;
466
466
 
467
+ declare const confirm_2: (payload: ConfirmOptions) => Promise<boolean>;
468
+ export { confirm_2 as confirm }
469
+
467
470
  export declare const Confirmer: () => JSX.Element;
468
471
 
472
+ declare interface ConfirmOptions {
473
+ title?: React.ReactNode;
474
+ description?: React.ReactNode;
475
+ cancelText?: React.ReactNode;
476
+ actionText?: React.ReactNode;
477
+ CancelProps?: React.ComponentProps<typeof AlertDialogCancel>;
478
+ ActionProps?: React.ComponentProps<typeof Button>;
479
+ }
480
+
469
481
  export declare function ContextMenu({ ...props }: React_2.ComponentProps<typeof ContextMenuPrimitive.Root>): JSX.Element;
470
482
 
471
483
  export declare function ContextMenuCheckboxItem({ className, children, checked, ...props }: React_2.ComponentProps<typeof ContextMenuPrimitive.CheckboxItem>): JSX.Element;
package/dist/index.js CHANGED
@@ -70,13 +70,13 @@ 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 { useAudioRecording as Xa } from "./hooks/use-audio-recording.js";
75
- import { useAutoScroll as Za } from "./hooks/use-auto-scroll.js";
76
- import { useAutosizeTextArea as $a } from "./hooks/use-autosize-textarea.js";
77
- import { useCopyToClipboard as rn } from "./hooks/use-copy-to-clipboard.js";
78
- import { useDebounce as tn } from "./hooks/use-debounce.js";
79
- import { useIsMobile as nn } from "./hooks/use-mobile.js";
73
+ import { Confirmer as Ua, confirm as Wa } from "./components/ui/confirmer.js";
74
+ import { useAudioRecording as Ya } from "./hooks/use-audio-recording.js";
75
+ import { useAutoScroll as _a } from "./hooks/use-auto-scroll.js";
76
+ import { useAutosizeTextArea as en } from "./hooks/use-autosize-textarea.js";
77
+ import { useCopyToClipboard as on } from "./hooks/use-copy-to-clipboard.js";
78
+ import { useDebounce as an } from "./hooks/use-debounce.js";
79
+ import { useIsMobile as pn } from "./hooks/use-mobile.js";
80
80
  export {
81
81
  ne as Accordion,
82
82
  ie as AccordionContent,
@@ -319,13 +319,14 @@ export {
319
319
  ke as Typo,
320
320
  x as badgeVariants,
321
321
  C as buttonVariants,
322
+ Wa as confirm,
322
323
  W as toggleVariants,
323
- Xa as useAudioRecording,
324
- Za as useAutoScroll,
325
- $a as useAutosizeTextArea,
326
- rn as useCopyToClipboard,
327
- tn as useDebounce,
324
+ Ya as useAudioRecording,
325
+ _a as useAutoScroll,
326
+ en as useAutosizeTextArea,
327
+ on as useCopyToClipboard,
328
+ an as useDebounce,
328
329
  Nr as useFormField,
329
- nn as useIsMobile,
330
+ pn as useIsMobile,
330
331
  wa as useSidebar
331
332
  };
@@ -1,5 +1,5 @@
1
1
  "use client";
2
- import { __exports as r } from "../../../_virtual/index6.js";
2
+ import { __exports as r } from "../../../_virtual/index5.js";
3
3
  import { __require as c } from "../../inline-style-parser/index.js";
4
4
  var f;
5
5
  function j() {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "laif-ds",
3
3
  "private": false,
4
- "version": "0.1.24",
4
+ "version": "0.1.25",
5
5
  "type": "module",
6
6
  "main": "dist/index.es.js",
7
7
  "module": "dist/index.es.js",