laif-ds 0.2.74 → 0.2.75

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.
Files changed (151) hide show
  1. package/dist/CHANGELOG.md +431 -0
  2. package/dist/agent-docs/adoption-report.json +614 -0
  3. package/dist/agent-docs/components/Accordion.md +46 -16
  4. package/dist/agent-docs/components/Alert.md +90 -95
  5. package/dist/agent-docs/components/AlertDialog.md +132 -126
  6. package/dist/agent-docs/components/AppEditor.md +90 -90
  7. package/dist/agent-docs/components/AppRadioGroup.md +18 -18
  8. package/dist/agent-docs/components/AppSidebar.md +129 -122
  9. package/dist/agent-docs/components/AppStepper.md +81 -77
  10. package/dist/agent-docs/components/AspectRatio.md +70 -62
  11. package/dist/agent-docs/components/AudioVisualizer.md +5 -5
  12. package/dist/agent-docs/components/Avatar.md +112 -113
  13. package/dist/agent-docs/components/Badge.md +123 -118
  14. package/dist/agent-docs/components/Breadcrumb.md +8 -1
  15. package/dist/agent-docs/components/Button.md +131 -129
  16. package/dist/agent-docs/components/Card.md +172 -147
  17. package/dist/agent-docs/components/Carousel.md +148 -129
  18. package/dist/agent-docs/components/Chat.md +121 -109
  19. package/dist/agent-docs/components/ChatMessage.md +72 -61
  20. package/dist/agent-docs/components/Checkbox.md +150 -135
  21. package/dist/agent-docs/components/CircularProgress.md +53 -49
  22. package/dist/agent-docs/components/CodeHighlighter.md +4 -4
  23. package/dist/agent-docs/components/Collapsible.md +114 -95
  24. package/dist/agent-docs/components/Command.md +141 -142
  25. package/dist/agent-docs/components/Confirmer.md +182 -175
  26. package/dist/agent-docs/components/ContextMenu.md +196 -191
  27. package/dist/agent-docs/components/DataCrossTable.md +114 -94
  28. package/dist/agent-docs/components/DataTable.md +29 -24
  29. package/dist/agent-docs/components/Dialog.md +130 -125
  30. package/dist/agent-docs/components/Drawer.md +141 -127
  31. package/dist/agent-docs/components/FilePreviewer.md +138 -139
  32. package/dist/agent-docs/components/FileUploader.md +143 -129
  33. package/dist/agent-docs/components/Form.md +3 -1
  34. package/dist/agent-docs/components/FormComposer.md +163 -137
  35. package/dist/agent-docs/components/GanttChart.md +125 -122
  36. package/dist/agent-docs/components/HoverCard.md +1 -1
  37. package/dist/agent-docs/components/Icon.md +98 -99
  38. package/dist/agent-docs/components/Input.md +173 -138
  39. package/dist/agent-docs/components/InputOtp.md +6 -1
  40. package/dist/agent-docs/components/InputSelector.md +94 -97
  41. package/dist/agent-docs/components/InterruptPrompt.md +4 -4
  42. package/dist/agent-docs/components/MarkdownRenderer.md +5 -2
  43. package/dist/agent-docs/components/Menubar.md +60 -57
  44. package/dist/agent-docs/components/MessageInput.md +134 -131
  45. package/dist/agent-docs/components/MessageList.md +110 -96
  46. package/dist/agent-docs/components/MultipleSelector.md +147 -146
  47. package/dist/agent-docs/components/NavigationMenu.md +6 -2
  48. package/dist/agent-docs/components/Popover.md +112 -103
  49. package/dist/agent-docs/components/PromptSuggestions.md +5 -5
  50. package/dist/agent-docs/components/RadioGroup.md +97 -90
  51. package/dist/agent-docs/components/Resizable.md +4 -1
  52. package/dist/agent-docs/components/ResizePrompt.md +12 -13
  53. package/dist/agent-docs/components/ScrollArea.md +6 -2
  54. package/dist/agent-docs/components/SecurePdfViewer.md +10 -6
  55. package/dist/agent-docs/components/Select.md +131 -132
  56. package/dist/agent-docs/components/Sheet.md +8 -1
  57. package/dist/agent-docs/components/ShikiHighlighter.md +5 -5
  58. package/dist/agent-docs/components/Sidebar.md +94 -85
  59. package/dist/agent-docs/components/Slider.md +62 -58
  60. package/dist/agent-docs/components/Sonner.md +1 -0
  61. package/dist/agent-docs/components/Spinner.md +14 -14
  62. package/dist/agent-docs/components/Stepper.md +93 -67
  63. package/dist/agent-docs/components/Switch.md +41 -42
  64. package/dist/agent-docs/components/TableSkeleton.md +8 -8
  65. package/dist/agent-docs/components/Tabs.md +106 -86
  66. package/dist/agent-docs/components/TextArea.md +51 -52
  67. package/dist/agent-docs/components/ThemeSwitcher.md +72 -69
  68. package/dist/agent-docs/components/Toaster.md +1 -0
  69. package/dist/agent-docs/components/Tooltip.md +102 -91
  70. package/dist/agent-docs/components/Typo.md +68 -65
  71. package/dist/agent-docs/components/WeeklyCalendar.md +63 -64
  72. package/dist/agent-docs/manifest.json +5979 -0
  73. package/dist/components/editor/editor-hooks/use-update-toolbar.js +6 -6
  74. package/dist/components/editor/plugins/actions/counter-character-plugin.js +6 -6
  75. package/dist/components/editor/plugins/toolbar/font-format-toolbar-plugin.js +18 -18
  76. package/dist/components/editor/plugins/toolbar/history-toolbar-plugin.js +10 -10
  77. package/dist/components/editor/plugins/toolbar/toolbar-plugin.js +9 -9
  78. package/dist/components/ui/app-checkbox.js +1 -1
  79. package/dist/components/ui/app-dialog.js +70 -64
  80. package/dist/components/ui/app-editor.js +51 -51
  81. package/dist/components/ui/app-form.js +81 -81
  82. package/dist/components/ui/app-multiple-select-dropdown.js +36 -36
  83. package/dist/components/ui/app-select.js +109 -104
  84. package/dist/components/ui/app-sidebar.js +41 -41
  85. package/dist/components/ui/app-stepper.js +1 -1
  86. package/dist/components/ui/app-time-picker.js +18 -18
  87. package/dist/components/ui/app-tooltip.js +1 -1
  88. package/dist/components/ui/async-select.js +5 -5
  89. package/dist/components/ui/audio-visualizer.js +61 -58
  90. package/dist/components/ui/card.js +1 -1
  91. package/dist/components/ui/carousel.js +2 -2
  92. package/dist/components/ui/chart.js +1 -1
  93. package/dist/components/ui/chat-message.js +8 -8
  94. package/dist/components/ui/chat.js +86 -88
  95. package/dist/components/ui/command.js +2 -2
  96. package/dist/components/ui/copy-button.js +4 -4
  97. package/dist/components/ui/date-picker.js +20 -20
  98. package/dist/components/ui/file-preview/index.js +13 -13
  99. package/dist/components/ui/file-previewer.js +12 -11
  100. package/dist/components/ui/form.js +2 -2
  101. package/dist/components/ui/gantt/components/Chart/Bars/Bars.js +56 -56
  102. package/dist/components/ui/gantt/components/Chart/Bars/BarsRow/BarItem/BarItem.js +12 -12
  103. package/dist/components/ui/gantt/components/Chart/Bars/BarsRow/BarsItems/BarItems.js +1 -1
  104. package/dist/components/ui/gantt/components/Chart/Bars/BarsRow/BarsRow.js +4 -4
  105. package/dist/components/ui/gantt/components/Chart/Bars/BarsRow/RepeteadBars/RepeteadBars.js +2 -2
  106. package/dist/components/ui/gantt/components/Chart/Chart.js +23 -23
  107. package/dist/components/ui/gantt/components/Chart/Scale/Scale.js +1 -1
  108. package/dist/components/ui/gantt/components/Chart/Tree/Tree.js +34 -34
  109. package/dist/components/ui/gantt/components/Controls/Controls.js +5 -5
  110. package/dist/components/ui/gantt/components/Gantt/Gantt.js +4 -4
  111. package/dist/components/ui/gantt/hooks/useGanttCalculate.js +25 -18
  112. package/dist/components/ui/input-selector.js +1 -1
  113. package/dist/components/ui/input.js +23 -23
  114. package/dist/components/ui/kanban.js +8 -9
  115. package/dist/components/ui/markdown-renderer.js +41 -35
  116. package/dist/components/ui/message-input.js +45 -44
  117. package/dist/components/ui/multiple-selector.js +91 -82
  118. package/dist/components/ui/secure-pdf-viewer.js +19 -7
  119. package/dist/components/ui/sidebar.js +1 -1
  120. package/dist/components/ui/slider.js +1 -1
  121. package/dist/components/ui/spinner.js +4 -4
  122. package/dist/components/ui/stepper.js +157 -138
  123. package/dist/components/ui/tables/data-cross-table/data-cross-table-buttons.js +29 -29
  124. package/dist/components/ui/tables/data-cross-table/data-cross-table.js +258 -246
  125. package/dist/components/ui/tables/data-table/components/data-table-advanced-filter.js +4 -1
  126. package/dist/components/ui/tables/data-table/components/data-table-body.js +204 -368
  127. package/dist/components/ui/tables/data-table/components/data-table-filter-inputs.js +114 -112
  128. package/dist/components/ui/tables/data-table/components/data-table-filters.js +116 -96
  129. package/dist/components/ui/tables/data-table/components/data-table-header.js +210 -0
  130. package/dist/components/ui/tables/data-table/components/data-table-searchbar.js +8 -8
  131. package/dist/components/ui/tables/data-table/components/data-table-skeleton-rows.js +33 -0
  132. package/dist/components/ui/tables/data-table/data-table.js +256 -250
  133. package/dist/components/ui/tables/data-table/data-table.service.js +112 -97
  134. package/dist/components/ui/tables/data-table/data-table.utils.js +2 -0
  135. package/dist/components/ui/textarea.js +2 -2
  136. package/dist/components/ui/theme-switcher.js +1 -1
  137. package/dist/components/ui/toggle-group.js +2 -2
  138. package/dist/components/ui/weekly-calendar/appointment-card.js +16 -16
  139. package/dist/components/ui/weekly-calendar/calendar-context.js +6 -6
  140. package/dist/components/ui/weekly-calendar/calendar-header.js +12 -12
  141. package/dist/components/ui/weekly-calendar/day-column.js +16 -16
  142. package/dist/components/ui/weekly-calendar/time-column.js +4 -4
  143. package/dist/components/ui/weekly-calendar/weekly-calendar.js +4 -4
  144. package/dist/hooks/use-audio-recording.js +1 -1
  145. package/dist/hooks/use-auto-scroll.js +18 -18
  146. package/dist/hooks/use-autosize-textarea.js +12 -13
  147. package/dist/index.d.ts +67 -43
  148. package/dist/index.js +229 -229
  149. package/dist/lib/utils.js +6 -6
  150. package/dist/styles.v3.css +1 -1
  151. package/package.json +14 -4
@@ -1,20 +1,20 @@
1
1
  "use client";
2
- import { useEffect as r } from "react";
3
2
  import { useLexicalComposerContext as n } from "../../../node_modules/@lexical/react/LexicalComposerContext.prod.js";
4
- import { SELECTION_CHANGE_COMMAND as m, $getSelection as i, COMMAND_PRIORITY_CRITICAL as f } from "../../../node_modules/lexical/Lexical.prod.js";
3
+ import { SELECTION_CHANGE_COMMAND as m, $getSelection as r, COMMAND_PRIORITY_CRITICAL as f } from "../../../node_modules/lexical/Lexical.prod.js";
4
+ import { useEffect as i } from "react";
5
5
  import { useToolbarContext as C } from "../context/toolbar-context.js";
6
6
  function c(t) {
7
7
  const [s] = n(), { activeEditor: o } = C();
8
- r(() => o.registerCommand(
8
+ i(() => o.registerCommand(
9
9
  m,
10
10
  () => {
11
- const e = i();
11
+ const e = r();
12
12
  return e && t(e), !1;
13
13
  },
14
14
  f
15
- ), [s, t]), r(() => {
15
+ ), [s, t, o]), i(() => {
16
16
  o.getEditorState().read(() => {
17
- const e = i();
17
+ const e = r();
18
18
  e && t(e);
19
19
  });
20
20
  }, [o, t]);
@@ -1,8 +1,8 @@
1
1
  "use client";
2
2
  import { jsxs as o } from "react/jsx-runtime";
3
- import { useState as a, useEffect as u } from "react";
4
- import { useLexicalComposerContext as d } from "../../../../node_modules/@lexical/react/LexicalComposerContext.prod.js";
5
- import { $rootTextContent as f } from "../../../../node_modules/@lexical/text/LexicalText.prod.js";
3
+ import { useLexicalComposerContext as a } from "../../../../node_modules/@lexical/react/LexicalComposerContext.prod.js";
4
+ import { $rootTextContent as u } from "../../../../node_modules/@lexical/text/LexicalText.prod.js";
5
+ import { useState as d, useEffect as f } from "react";
6
6
  let s = null;
7
7
  function h() {
8
8
  return window.TextEncoder === void 0 ? null : (s === null && (s = new window.TextEncoder()), s);
@@ -24,14 +24,14 @@ const c = (t, e) => {
24
24
  function T({
25
25
  charset: t = "UTF-16"
26
26
  }) {
27
- const [e] = d(), [n, l] = a(() => {
28
- const r = e.getEditorState().read(f);
27
+ const [e] = a(), [n, l] = d(() => {
28
+ const r = e.getEditorState().read(u);
29
29
  return {
30
30
  characters: c(r, t),
31
31
  words: i(r)
32
32
  };
33
33
  });
34
- return u(() => e.registerTextContentListener((r) => {
34
+ return f(() => e.registerTextContentListener((r) => {
35
35
  l({
36
36
  characters: c(r, t),
37
37
  words: i(r)
@@ -1,44 +1,44 @@
1
1
  "use client";
2
2
  import { jsx as i } from "react/jsx-runtime";
3
- import { useState as m } from "react";
4
- import { $isTableSelection as l } from "../../../../node_modules/@lexical/table/LexicalTable.prod.js";
5
- import { FORMAT_TEXT_COMMAND as n, $isRangeSelection as d } from "../../../../node_modules/lexical/Lexical.prod.js";
3
+ import { $isTableSelection as m } from "../../../../node_modules/@lexical/table/LexicalTable.prod.js";
4
+ import { FORMAT_TEXT_COMMAND as l, $isRangeSelection as n } from "../../../../node_modules/lexical/Lexical.prod.js";
5
+ import { useState as d } from "react";
6
6
  import { useToolbarContext as c } from "../../context/toolbar-context.js";
7
7
  import { useUpdateToolbarHandler as p } from "../../editor-hooks/use-update-toolbar.js";
8
8
  import { Toggle as f } from "../../../ui/toggle.js";
9
9
  import u from "../../../../node_modules/lucide-react/dist/esm/icons/code.js";
10
10
  import T from "../../../../node_modules/lucide-react/dist/esm/icons/strikethrough.js";
11
- import b from "../../../../node_modules/lucide-react/dist/esm/icons/underline.js";
12
- import g from "../../../../node_modules/lucide-react/dist/esm/icons/italic.js";
13
- import h from "../../../../node_modules/lucide-react/dist/esm/icons/bold.js";
11
+ import h from "../../../../node_modules/lucide-react/dist/esm/icons/underline.js";
12
+ import b from "../../../../node_modules/lucide-react/dist/esm/icons/italic.js";
13
+ import g from "../../../../node_modules/lucide-react/dist/esm/icons/bold.js";
14
14
  const C = {
15
- bold: h,
16
- italic: g,
17
- underline: b,
15
+ bold: g,
16
+ italic: b,
17
+ underline: h,
18
18
  strikethrough: T,
19
19
  code: u
20
20
  };
21
21
  function R({
22
- format: o
22
+ format: r
23
23
  }) {
24
- const { activeEditor: a } = c(), [r, t] = m(!1);
25
- p((e) => {
26
- (d(e) || l(e)) && t(e.hasFormat(o));
24
+ const { activeEditor: a } = c(), [e, t] = d(!1);
25
+ p((o) => {
26
+ (n(o) || m(o)) && "hasFormat" in o && t(o.hasFormat(r));
27
27
  });
28
- const s = C[o];
28
+ const s = C[r];
29
29
  return /* @__PURE__ */ i(
30
30
  f,
31
31
  {
32
32
  "aria-label": "Toggle bold",
33
33
  variant: "outline",
34
34
  size: "sm",
35
- defaultPressed: r,
36
- pressed: r,
35
+ defaultPressed: e,
36
+ pressed: e,
37
37
  onPressedChange: t,
38
38
  onClick: () => {
39
39
  a.dispatchCommand(
40
- n,
41
- o
40
+ l,
41
+ r
42
42
  );
43
43
  },
44
44
  children: /* @__PURE__ */ i(s, { className: "h-4 w-4" })
@@ -1,16 +1,16 @@
1
1
  "use client";
2
2
  import { jsxs as f, jsx as o } from "react/jsx-runtime";
3
- import { useState as s, useEffect as u } from "react";
4
- import { useLexicalComposerContext as N } from "../../../../node_modules/@lexical/react/LexicalComposerContext.prod.js";
5
- import { mergeRegister as b } from "../../../../node_modules/@lexical/utils/LexicalUtils.prod.js";
6
- import { CAN_REDO_COMMAND as R, COMMAND_PRIORITY_CRITICAL as n, CAN_UNDO_COMMAND as M, UNDO_COMMAND as O, REDO_COMMAND as D } from "../../../../node_modules/lexical/Lexical.prod.js";
3
+ import { useLexicalComposerContext as u } from "../../../../node_modules/@lexical/react/LexicalComposerContext.prod.js";
4
+ import { mergeRegister as N } from "../../../../node_modules/@lexical/utils/LexicalUtils.prod.js";
5
+ import { CAN_REDO_COMMAND as b, COMMAND_PRIORITY_CRITICAL as n, CAN_UNDO_COMMAND as R, UNDO_COMMAND as M, REDO_COMMAND as O } from "../../../../node_modules/lexical/Lexical.prod.js";
6
+ import { useState as s, useEffect as D } from "react";
7
7
  import { useToolbarContext as g } from "../../context/toolbar-context.js";
8
8
  import { Button as d } from "../../../ui/button.js";
9
9
  import x from "../../../../node_modules/lucide-react/dist/esm/icons/undo.js";
10
10
  import A from "../../../../node_modules/lucide-react/dist/esm/icons/redo.js";
11
11
  function j() {
12
- const [i] = N(), { activeEditor: t, $updateToolbar: a } = g(), [r, l] = s(i.isEditable()), [m, c] = s(!1), [C, p] = s(!1);
13
- return u(() => b(
12
+ const [i] = u(), { activeEditor: t, $updateToolbar: a } = g(), [r, l] = s(i.isEditable()), [m, c] = s(!1), [C, p] = s(!1);
13
+ return D(() => N(
14
14
  i.registerEditableListener((e) => {
15
15
  l(e);
16
16
  }),
@@ -20,12 +20,12 @@ function j() {
20
20
  });
21
21
  }),
22
22
  t.registerCommand(
23
- M,
23
+ R,
24
24
  (e) => (c(e), !1),
25
25
  n
26
26
  ),
27
27
  t.registerCommand(
28
- R,
28
+ b,
29
29
  (e) => (p(e), !1),
30
30
  n
31
31
  )
@@ -35,7 +35,7 @@ function j() {
35
35
  {
36
36
  disabled: !m || !r,
37
37
  onClick: () => {
38
- t.dispatchCommand(O, void 0);
38
+ t.dispatchCommand(M, void 0);
39
39
  },
40
40
  title: "Undo (⌘Z)",
41
41
  type: "button",
@@ -51,7 +51,7 @@ function j() {
51
51
  {
52
52
  disabled: !C || !r,
53
53
  onClick: () => {
54
- t.dispatchCommand(D, void 0);
54
+ t.dispatchCommand(O, void 0);
55
55
  },
56
56
  title: "Redo (⇧⌘Z)",
57
57
  type: "button",
@@ -1,23 +1,23 @@
1
1
  "use client";
2
2
  import { jsxs as p } from "react/jsx-runtime";
3
- import { useState as e, useEffect as d } from "react";
4
- import { useLexicalComposerContext as u } from "../../../../node_modules/@lexical/react/LexicalComposerContext.prod.js";
5
- import { SELECTION_CHANGE_COMMAND as f, COMMAND_PRIORITY_CRITICAL as C } from "../../../../node_modules/lexical/Lexical.prod.js";
3
+ import { useLexicalComposerContext as d } from "../../../../node_modules/@lexical/react/LexicalComposerContext.prod.js";
4
+ import { SELECTION_CHANGE_COMMAND as u, COMMAND_PRIORITY_CRITICAL as f } from "../../../../node_modules/lexical/Lexical.prod.js";
5
+ import { useState as e, useEffect as C } from "react";
6
6
  import { ToolbarContext as T } from "../../context/toolbar-context.js";
7
7
  import { useEditorModal as E } from "../../editor-hooks/use-modal.js";
8
8
  function O({
9
9
  children: s
10
10
  }) {
11
- const [o] = u(), [t, a] = e(o), [r, i] = e("paragraph"), [m, n] = E(), l = () => {
11
+ const [t] = d(), [o, a] = e(t), [r, i] = e("paragraph"), [m, n] = E(), l = () => {
12
12
  };
13
- return d(() => t.registerCommand(
14
- f,
13
+ return C(() => o.registerCommand(
14
+ u,
15
15
  (M, c) => (a(c), !1),
16
- C
17
- ), [o]), /* @__PURE__ */ p(
16
+ f
17
+ ), [t, o]), /* @__PURE__ */ p(
18
18
  T,
19
19
  {
20
- activeEditor: t,
20
+ activeEditor: o,
21
21
  $updateToolbar: l,
22
22
  blockType: r,
23
23
  setBlockType: i,
@@ -1,8 +1,8 @@
1
1
  "use client";
2
2
  import { jsxs as s, jsx as e, Fragment as $ } from "react/jsx-runtime";
3
+ import * as A from "react";
3
4
  import { designTokens as v } from "../design-tokens.js";
4
5
  import { cn as r } from "../../lib/utils.js";
5
- import * as A from "react";
6
6
  import { Checkbox as H } from "./checkbox.js";
7
7
  import { Icon as L } from "./icon.js";
8
8
  import { Label as R } from "./label.js";
@@ -1,12 +1,12 @@
1
1
  "use client";
2
- import { jsx as l, jsxs as a } from "react/jsx-runtime";
3
- import { DialogTitle as N, DialogDescription as C } from "../../node_modules/@radix-ui/react-dialog/dist/index.js";
4
- import { cva as b } from "../../node_modules/class-variance-authority/dist/index.js";
5
- import { Button as y } from "./button.js";
6
- import { Dialog as z, DialogTrigger as j, DialogContent as T, DialogHeader as A, DialogClose as B, DialogFooter as V } from "./dialog.js";
7
- import { Typo as d } from "./typo.js";
8
- import { cn as s } from "../../lib/utils.js";
9
- const k = b(
2
+ import { jsx as l, jsxs as i } from "react/jsx-runtime";
3
+ import { DialogTitle as C, DialogDescription as b } from "../../node_modules/@radix-ui/react-dialog/dist/index.js";
4
+ import { cva as z } from "../../node_modules/class-variance-authority/dist/index.js";
5
+ import { Button as j } from "./button.js";
6
+ import { Dialog as T, DialogTrigger as A, DialogContent as B, DialogHeader as E, DialogClose as I, DialogFooter as K } from "./dialog.js";
7
+ import { Typo as c } from "./typo.js";
8
+ import { cn as f } from "../../lib/utils.js";
9
+ const V = z(
10
10
  [
11
11
  "flex flex-col justify-between gap-2 w-full h-dvh max-w-[initial] p-6",
12
12
  "max-sm:rounded-none max-sm:px-2 max-sm:py-3 max-sm:min-w-full max-sm:min-h-full max-sm:w-full max-sm:h-full max-sm:max-w-full max-sm:max-h-full"
@@ -26,90 +26,96 @@ const k = b(
26
26
  }
27
27
  }
28
28
  );
29
- function J({
30
- children: o,
31
- trigger: e,
32
- title: n,
33
- description: m,
34
- footer: i,
35
- size: u = "default",
36
- open: r,
37
- defaultOpen: c,
38
- onOpenChange: f,
39
- triggerClassName: t,
40
- headerClassName: w,
41
- bodyClassName: p,
42
- footerClassName: g,
43
- disabled: x = !1,
44
- asChild: v = !1,
45
- preventClose: F,
46
- ...h
29
+ function G({
30
+ children: r,
31
+ trigger: m,
32
+ title: t,
33
+ description: o,
34
+ footer: s,
35
+ size: w = "default",
36
+ open: u,
37
+ defaultOpen: p,
38
+ onOpenChange: x,
39
+ triggerClassName: d,
40
+ headerClassName: D,
41
+ bodyClassName: g,
42
+ footerClassName: v,
43
+ disabled: h = !1,
44
+ asChild: N = !1,
45
+ preventClose: n,
46
+ ...e
47
47
  }) {
48
- const D = r !== void 0;
49
- return x ? /* @__PURE__ */ l("div", { className: t, children: e }) : /* @__PURE__ */ a(
50
- z,
48
+ const y = u !== void 0;
49
+ return h ? /* @__PURE__ */ l("div", { className: d, children: m }) : /* @__PURE__ */ i(
50
+ T,
51
51
  {
52
- open: D ? r : void 0,
53
- defaultOpen: c,
54
- onOpenChange: f,
52
+ open: y ? u : void 0,
53
+ defaultOpen: p,
54
+ onOpenChange: x,
55
55
  children: [
56
- e && /* @__PURE__ */ l(
57
- j,
56
+ m && /* @__PURE__ */ l(
57
+ A,
58
58
  {
59
- asChild: v,
60
- className: t,
61
- disabled: x,
62
- children: e
59
+ asChild: N,
60
+ className: d,
61
+ disabled: h,
62
+ children: m
63
63
  }
64
64
  ),
65
- /* @__PURE__ */ a(
66
- T,
65
+ /* @__PURE__ */ i(
66
+ B,
67
67
  {
68
- ...h,
69
- className: s(
70
- k({
71
- size: u
68
+ ...e,
69
+ className: f(
70
+ V({
71
+ size: w
72
72
  }),
73
- h.className
73
+ e.className
74
74
  ),
75
+ onInteractOutside: (a) => {
76
+ e.onInteractOutside?.(a), (n === "overlay" || n === "all") && a.preventDefault();
77
+ },
78
+ onEscapeKeyDown: (a) => {
79
+ e.onEscapeKeyDown?.(a), n === "all" && a.preventDefault();
80
+ },
75
81
  showCloseButton: !1,
76
82
  children: [
77
- /* @__PURE__ */ a(A, { className: s("gap-1", w), children: [
78
- /* @__PURE__ */ a("div", { className: "flex w-full flex-row items-start gap-2", children: [
79
- /* @__PURE__ */ l(N, { asChild: !0, children: /* @__PURE__ */ l(d, { variant: "h5", className: "flex flex-1", children: n }) }),
80
- /* @__PURE__ */ l(B, { asChild: !0, children: /* @__PURE__ */ l(
81
- y,
83
+ /* @__PURE__ */ i(E, { className: f("gap-1", D), children: [
84
+ /* @__PURE__ */ i("div", { className: "flex w-full flex-row items-start gap-2", children: [
85
+ /* @__PURE__ */ l(C, { asChild: !0, children: /* @__PURE__ */ l(c, { variant: "h5", className: "flex flex-1", children: t }) }),
86
+ /* @__PURE__ */ l(I, { asChild: !0, children: /* @__PURE__ */ l(
87
+ j,
82
88
  {
83
89
  iconLeft: "X",
84
90
  variant: "ghost",
85
91
  size: "icon",
86
92
  className: "size-7",
87
- onClick: () => f?.(!1)
93
+ onClick: () => x?.(!1)
88
94
  }
89
95
  ) })
90
96
  ] }),
91
- m && /* @__PURE__ */ l(C, { asChild: !0, children: /* @__PURE__ */ l(
92
- d,
97
+ o && /* @__PURE__ */ l(b, { asChild: !0, children: /* @__PURE__ */ l(
98
+ c,
93
99
  {
94
100
  variant: "caption",
95
101
  className: "text-d-secondary-foreground flex flex-1",
96
- children: m
102
+ children: o
97
103
  }
98
104
  ) })
99
105
  ] }),
100
- o && /* @__PURE__ */ l(
106
+ r && /* @__PURE__ */ l(
101
107
  "div",
102
108
  {
103
- className: s(
109
+ className: f(
104
110
  "border-d-border flex min-h-0 w-full flex-1 flex-col gap-2 overflow-auto py-2",
105
- (!!n || !!m) && "border-t",
106
- !!i && "border-b",
107
- p
111
+ (!!t || !!o) && "border-t",
112
+ !!s && "border-b",
113
+ g
108
114
  ),
109
- children: o
115
+ children: r
110
116
  }
111
117
  ),
112
- i && /* @__PURE__ */ l(V, { className: g, children: i })
118
+ s && /* @__PURE__ */ l(K, { className: v, children: s })
113
119
  ]
114
120
  }
115
121
  )
@@ -118,7 +124,7 @@ function J({
118
124
  );
119
125
  }
120
126
  export {
121
- J as AppDialog,
122
- B as AppDialogClose,
123
- J as default
127
+ G as AppDialog,
128
+ I as AppDialogClose,
129
+ G as default
124
130
  };
@@ -1,32 +1,32 @@
1
1
  "use client";
2
2
  import { jsx as r, jsxs as t, Fragment as s } from "react/jsx-runtime";
3
- import { LexicalComposer as w } from "../../node_modules/@lexical/react/LexicalComposer.prod.js";
4
- import { OnChangePlugin as L } from "../../node_modules/@lexical/react/LexicalOnChangePlugin.prod.js";
5
- import { LexicalErrorBoundary as S } from "../../node_modules/@lexical/react/LexicalErrorBoundary.prod.js";
6
- import { RichTextPlugin as T } from "../../node_modules/@lexical/react/LexicalRichTextPlugin.prod.js";
7
- import { HeadingNode as j, QuoteNode as A } from "../../node_modules/@lexical/rich-text/LexicalRichText.prod.js";
3
+ import { ListNode as w, ListItemNode as L } from "../../node_modules/@lexical/list/LexicalList.prod.js";
4
+ import { $convertToMarkdownString as S, $convertFromMarkdownString as T, TRANSFORMERS as C } from "../../node_modules/@lexical/markdown/LexicalMarkdown.prod.js";
5
+ import { CheckListPlugin as j } from "../../node_modules/@lexical/react/LexicalCheckListPlugin.prod.js";
6
+ import { ClearEditorPlugin as A } from "../../node_modules/@lexical/react/LexicalClearEditorPlugin.prod.js";
7
+ import { LexicalComposer as B } from "../../node_modules/@lexical/react/LexicalComposer.prod.js";
8
+ import { useLexicalComposerContext as H } from "../../node_modules/@lexical/react/LexicalComposerContext.prod.js";
9
+ import { LexicalErrorBoundary as R } from "../../node_modules/@lexical/react/LexicalErrorBoundary.prod.js";
10
+ import { HistoryPlugin as $ } from "../../node_modules/@lexical/react/LexicalHistoryPlugin.prod.js";
11
+ import { ListPlugin as O } from "../../node_modules/@lexical/react/LexicalListPlugin.prod.js";
12
+ import { OnChangePlugin as z } from "../../node_modules/@lexical/react/LexicalOnChangePlugin.prod.js";
13
+ import { RichTextPlugin as D } from "../../node_modules/@lexical/react/LexicalRichTextPlugin.prod.js";
14
+ import { HeadingNode as I, QuoteNode as M } from "../../node_modules/@lexical/rich-text/LexicalRichText.prod.js";
8
15
  import { ParagraphNode as d, TextNode as p, $getRoot as f } from "../../node_modules/lexical/Lexical.prod.js";
9
- import { $convertToMarkdownString as B, $convertFromMarkdownString as H, TRANSFORMERS as C } from "../../node_modules/@lexical/markdown/LexicalMarkdown.prod.js";
10
- import { useState as R, useEffect as $ } from "react";
11
- import { useLexicalComposerContext as O } from "../../node_modules/@lexical/react/LexicalComposerContext.prod.js";
12
- import { HistoryPlugin as z } from "../../node_modules/@lexical/react/LexicalHistoryPlugin.prod.js";
13
- import { ContentEditable as D } from "../editor/editor-ui/content-editable.js";
14
- import { ActionsPlugin as I } from "../editor/plugins/actions/actions-plugin.js";
15
- import { ClearEditorActionPlugin as _ } from "../editor/plugins/actions/clear-editor-plugin.js";
16
- import { ClearEditorPlugin as M } from "../../node_modules/@lexical/react/LexicalClearEditorPlugin.prod.js";
17
- import { CounterCharacterPlugin as Q } from "../editor/plugins/actions/counter-character-plugin.js";
18
- import { ToolbarPlugin as c } from "../editor/plugins/toolbar/toolbar-plugin.js";
19
- import { BlockFormatDropDown as J } from "../editor/plugins/toolbar/block-format-toolbar-plugin.js";
20
- import { FormatParagraph as U } from "../editor/plugins/toolbar/block-format/format-paragraph.js";
21
- import { FormatHeading as q } from "../editor/plugins/toolbar/block-format/format-heading.js";
22
- import { FormatNumberedList as G } from "../editor/plugins/toolbar/block-format/format-numbered-list.js";
16
+ import { useState as Q, useEffect as _ } from "react";
17
+ import { ContentEditable as J } from "../editor/editor-ui/content-editable.js";
18
+ import { ActionsPlugin as U } from "../editor/plugins/actions/actions-plugin.js";
19
+ import { ClearEditorActionPlugin as q } from "../editor/plugins/actions/clear-editor-plugin.js";
20
+ import { CounterCharacterPlugin as G } from "../editor/plugins/actions/counter-character-plugin.js";
23
21
  import { FormatBulletedList as K } from "../editor/plugins/toolbar/block-format/format-bulleted-list.js";
24
22
  import { FormatCheckList as W } from "../editor/plugins/toolbar/block-format/format-check-list.js";
25
- import { FormatQuote as X } from "../editor/plugins/toolbar/block-format/format-quote.js";
23
+ import { FormatHeading as X } from "../editor/plugins/toolbar/block-format/format-heading.js";
24
+ import { FormatNumberedList as Y } from "../editor/plugins/toolbar/block-format/format-numbered-list.js";
25
+ import { FormatParagraph as Z } from "../editor/plugins/toolbar/block-format/format-paragraph.js";
26
+ import { FormatQuote as V } from "../editor/plugins/toolbar/block-format/format-quote.js";
27
+ import { BlockFormatDropDown as rr } from "../editor/plugins/toolbar/block-format-toolbar-plugin.js";
26
28
  import { FontFormatToolbarPlugin as l } from "../editor/plugins/toolbar/font-format-toolbar-plugin.js";
27
- import { ListPlugin as Y } from "../../node_modules/@lexical/react/LexicalListPlugin.prod.js";
28
- import { CheckListPlugin as Z } from "../../node_modules/@lexical/react/LexicalCheckListPlugin.prod.js";
29
- import { ListNode as V, ListItemNode as rr } from "../../node_modules/@lexical/list/LexicalList.prod.js";
29
+ import { ToolbarPlugin as c } from "../editor/plugins/toolbar/toolbar-plugin.js";
30
30
  import { editorTheme as or } from "../editor/themes/editor-theme.js";
31
31
  import { TooltipProvider as tr } from "./tooltip.js";
32
32
  import { HistoryToolbarPlugin as er } from "../editor/plugins/toolbar/history-toolbar-plugin.js";
@@ -35,10 +35,10 @@ function nr({
35
35
  defaultValue: o,
36
36
  onlyMarkdown: i
37
37
  }) {
38
- const [n] = O();
39
- return $(() => {
38
+ const [n] = H();
39
+ return _(() => {
40
40
  o && n.update(() => {
41
- i ? H(o, C) : f().append(
41
+ i ? T(o, C) : f().append(
42
42
  new d().append(new p(o))
43
43
  );
44
44
  const a = f();
@@ -46,7 +46,7 @@ function nr({
46
46
  });
47
47
  }, [n, o, i]), null;
48
48
  }
49
- function zr({
49
+ function Or({
50
50
  defaultValue: o,
51
51
  onMarkdownEdit: i,
52
52
  plugins: n = [],
@@ -55,16 +55,16 @@ function zr({
55
55
  onlyMarkdown: h = !0,
56
56
  className: F = "overflow-hidden rounded-lg border border-d-border"
57
57
  }) {
58
- const [ar, P] = R(null), y = {
58
+ const [, P] = Q(null), y = {
59
59
  namespace: "AppEditor",
60
60
  theme: or,
61
61
  nodes: [
62
- j,
62
+ I,
63
63
  d,
64
64
  p,
65
- A,
66
- V,
67
- rr
65
+ M,
66
+ w,
67
+ L
68
68
  ],
69
69
  onError: (e) => {
70
70
  console.error(e);
@@ -77,7 +77,7 @@ function zr({
77
77
  }
78
78
  } : {}
79
79
  }, u = (e) => n.includes(e), m = (e) => a.includes(e), g = u("clear"), v = u("counter"), b = m("block-format"), E = m("font-format"), x = m("history");
80
- return /* @__PURE__ */ r("div", { className: "bg-d-background", children: /* @__PURE__ */ r(w, { initialConfig: y, children: /* @__PURE__ */ t(tr, { children: [
80
+ return /* @__PURE__ */ r("div", { className: "bg-d-background", children: /* @__PURE__ */ r(B, { initialConfig: y, children: /* @__PURE__ */ t(tr, { children: [
81
81
  o && /* @__PURE__ */ r(
82
82
  nr,
83
83
  {
@@ -87,13 +87,13 @@ function zr({
87
87
  ),
88
88
  /* @__PURE__ */ t("div", { className: "border-d-border flex items-center border-b", children: [
89
89
  x && /* @__PURE__ */ r(c, { children: () => /* @__PURE__ */ r("div", { className: "vertical-align-middle sticky top-0 z-10 flex gap-2 overflow-auto p-1", children: /* @__PURE__ */ r(er, {}) }) }),
90
- b && /* @__PURE__ */ r(c, { children: () => /* @__PURE__ */ r(s, { children: /* @__PURE__ */ r("div", { className: "vertical-align-middle sticky top-0 z-10 flex gap-2 overflow-auto p-1", children: /* @__PURE__ */ t(J, { children: [
91
- /* @__PURE__ */ r(U, {}),
92
- /* @__PURE__ */ r(q, { levels: ["h1", "h2", "h3"] }),
93
- /* @__PURE__ */ r(G, {}),
90
+ b && /* @__PURE__ */ r(c, { children: () => /* @__PURE__ */ r(s, { children: /* @__PURE__ */ r("div", { className: "vertical-align-middle sticky top-0 z-10 flex gap-2 overflow-auto p-1", children: /* @__PURE__ */ t(rr, { children: [
91
+ /* @__PURE__ */ r(Z, {}),
92
+ /* @__PURE__ */ r(X, { levels: ["h1", "h2", "h3"] }),
93
+ /* @__PURE__ */ r(Y, {}),
94
94
  /* @__PURE__ */ r(K, {}),
95
95
  /* @__PURE__ */ r(W, {}),
96
- /* @__PURE__ */ r(X, {})
96
+ /* @__PURE__ */ r(V, {})
97
97
  ] }) }) }) }),
98
98
  E && /* @__PURE__ */ r(c, { children: () => /* @__PURE__ */ t("div", { className: "vertical-align-middle sticky top-0 z-10 flex gap-2 overflow-auto p-1", children: [
99
99
  /* @__PURE__ */ r(l, { format: "bold" }),
@@ -103,13 +103,13 @@ function zr({
103
103
  ] }) })
104
104
  ] }),
105
105
  /* @__PURE__ */ t("div", { className: "relative", children: [
106
- x && /* @__PURE__ */ r(z, {}),
106
+ x && /* @__PURE__ */ r($, {}),
107
107
  /* @__PURE__ */ r(
108
- T,
108
+ D,
109
109
  {
110
- ErrorBoundary: S,
110
+ ErrorBoundary: R,
111
111
  contentEditable: /* @__PURE__ */ r("div", { children: /* @__PURE__ */ r("div", { ref: P, children: /* @__PURE__ */ r(
112
- D,
112
+ J,
113
113
  {
114
114
  placeholder: N,
115
115
  className: `ContentEditable__root relative block h-72 min-h-full overflow-auto px-8 py-4 focus:outline-none ${F}`
@@ -118,26 +118,26 @@ function zr({
118
118
  }
119
119
  ),
120
120
  b && /* @__PURE__ */ t(s, { children: [
121
- /* @__PURE__ */ r(Y, {}),
122
- /* @__PURE__ */ r(Z, {})
121
+ /* @__PURE__ */ r(O, {}),
122
+ /* @__PURE__ */ r(j, {})
123
123
  ] }),
124
- (g || v) && /* @__PURE__ */ r(I, { children: /* @__PURE__ */ t("div", { className: "clear-both flex items-center justify-between gap-2 p-1", children: [
124
+ (g || v) && /* @__PURE__ */ r(U, { children: /* @__PURE__ */ t("div", { className: "clear-both flex items-center justify-between gap-2 p-1", children: [
125
125
  /* @__PURE__ */ r("div", { className: "flex flex-1 justify-start" }),
126
- /* @__PURE__ */ r("div", { children: v && /* @__PURE__ */ r(Q, { charset: "UTF-16" }) }),
126
+ /* @__PURE__ */ r("div", { children: v && /* @__PURE__ */ r(G, { charset: "UTF-16" }) }),
127
127
  /* @__PURE__ */ r("div", { className: "flex flex-1 justify-end gap-2", children: g && /* @__PURE__ */ t(s, { children: [
128
- /* @__PURE__ */ r(_, {}),
129
- /* @__PURE__ */ r(M, {})
128
+ /* @__PURE__ */ r(q, {}),
129
+ /* @__PURE__ */ r(A, {})
130
130
  ] }) })
131
131
  ] }) })
132
132
  ] }),
133
133
  /* @__PURE__ */ r(
134
- L,
134
+ z,
135
135
  {
136
136
  ignoreSelectionChange: !0,
137
137
  onChange: (e) => {
138
138
  if (!i) return;
139
139
  const k = e.read(
140
- () => B(C)
140
+ () => S(C)
141
141
  );
142
142
  i(k);
143
143
  }
@@ -146,5 +146,5 @@ function zr({
146
146
  ] }) }) });
147
147
  }
148
148
  export {
149
- zr as AppEditor
149
+ Or as AppEditor
150
150
  };