@oneflowui/ui 0.4.1 → 0.4.3

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 (233) hide show
  1. package/dist/_virtual/_commonjsHelpers.js +6 -0
  2. package/dist/_virtual/_plugin-vue_export-helper.js +9 -0
  3. package/dist/components/ContextMenu/index.vue.js +7 -0
  4. package/dist/components/ContextMenu/index.vue2.js +91 -0
  5. package/dist/components/Dashboard/charts/BarChart.vue.js +7 -0
  6. package/dist/components/Dashboard/charts/BarChart.vue2.js +43 -0
  7. package/dist/components/Dashboard/charts/DoughnutChart.vue.js +23 -0
  8. package/dist/components/Dashboard/charts/DoughnutChart.vue2.js +4 -0
  9. package/dist/components/Dashboard/charts/NumberCard.vue.js +7 -0
  10. package/dist/components/Dashboard/charts/NumberCard.vue2.js +41 -0
  11. package/dist/components/Dashboard/charts/PieChart.vue.js +7 -0
  12. package/dist/components/Dashboard/charts/PieChart.vue2.js +53 -0
  13. package/dist/components/Dashboard/charts/TableChart.vue.js +7 -0
  14. package/dist/components/Dashboard/charts/TableChart.vue2.js +50 -0
  15. package/dist/components/Dashboard/index.vue.js +7 -0
  16. package/dist/components/Dashboard/index.vue2.js +104 -0
  17. package/dist/components/ai/AiMessageBubble.vue.js +7 -0
  18. package/dist/components/ai/AiMessageBubble.vue2.js +47 -0
  19. package/dist/components/ai/AiMessageList.vue.js +7 -0
  20. package/dist/components/ai/AiMessageList.vue2.js +78 -0
  21. package/dist/components/ai/AiSender.vue.js +7 -0
  22. package/dist/components/ai/AiSender.vue2.js +86 -0
  23. package/dist/components/ai/AiStreamingCursor.vue.js +7 -0
  24. package/dist/components/ai/AiStreamingCursor.vue2.js +16 -0
  25. package/dist/components/ai/AiThinking.vue.js +7 -0
  26. package/dist/components/ai/AiThinking.vue2.js +19 -0
  27. package/dist/components/ai/UserMessageBubble.vue.js +7 -0
  28. package/dist/components/ai/UserMessageBubble.vue2.js +34 -0
  29. package/dist/components/auxiliary/ColorPanel.vue.js +7 -0
  30. package/dist/components/auxiliary/ColorPanel.vue2.js +65 -0
  31. package/dist/components/auxiliary/FileUpload.vue.js +7 -0
  32. package/dist/components/auxiliary/FileUpload.vue2.js +90 -0
  33. package/dist/components/auxiliary/PersonPanel.vue.js +7 -0
  34. package/dist/components/auxiliary/PersonPanel.vue2.js +66 -0
  35. package/dist/components/base/Accordion.vue.js +7 -0
  36. package/dist/components/base/Accordion.vue2.js +78 -0
  37. package/dist/components/base/AddViewBtn.vue.js +7 -0
  38. package/dist/components/base/AddViewBtn.vue2.js +25 -0
  39. package/dist/components/base/Avatar.vue.js +7 -0
  40. package/dist/components/base/Avatar.vue2.js +72 -0
  41. package/dist/components/base/Badge.vue.js +7 -0
  42. package/dist/components/base/Badge.vue2.js +70 -0
  43. package/dist/components/base/ButtonGroup.vue.js +7 -0
  44. package/dist/components/base/ButtonGroup.vue2.js +40 -0
  45. package/dist/components/base/ChainItem.vue.js +7 -0
  46. package/dist/components/base/ChainItem.vue2.js +68 -0
  47. package/dist/components/base/DescBlock.vue.js +7 -0
  48. package/dist/components/base/DescBlock.vue2.js +13 -0
  49. package/dist/components/base/DropdownMenu.vue.js +7 -0
  50. package/dist/components/base/DropdownMenu.vue2.js +92 -0
  51. package/dist/components/base/EmptyState.vue.js +7 -0
  52. package/dist/components/base/EmptyState.vue2.js +38 -0
  53. package/dist/components/base/InfoCard.vue.js +7 -0
  54. package/dist/components/base/InfoCard.vue2.js +167 -0
  55. package/dist/components/base/MonitorItem.vue.js +7 -0
  56. package/dist/components/base/MonitorItem.vue2.js +56 -0
  57. package/dist/components/base/PersonaCard.vue.js +7 -0
  58. package/dist/components/base/PersonaCard.vue2.js +173 -0
  59. package/dist/components/base/ProgressBar.vue.js +7 -0
  60. package/dist/components/base/ProgressBar.vue2.js +49 -0
  61. package/dist/components/base/RangeSlider.vue.js +7 -0
  62. package/dist/components/base/RangeSlider.vue2.js +35 -0
  63. package/dist/components/base/RefTag.vue.js +7 -0
  64. package/dist/components/base/RefTag.vue2.js +52 -0
  65. package/dist/components/base/SectionBlock.vue.js +7 -0
  66. package/dist/components/base/SectionBlock.vue2.js +115 -0
  67. package/dist/components/base/SelectBadge.vue.js +7 -0
  68. package/dist/components/base/SelectBadge.vue2.js +81 -0
  69. package/dist/components/base/StatisticCard.vue.js +7 -0
  70. package/dist/components/base/StatisticCard.vue2.js +57 -0
  71. package/dist/components/base/StatusIndicator.vue.js +7 -0
  72. package/dist/components/base/StatusIndicator.vue2.js +54 -0
  73. package/dist/components/base/StatusSummary.vue.js +7 -0
  74. package/dist/components/base/StatusSummary.vue2.js +64 -0
  75. package/dist/components/base/Stepper.vue.js +7 -0
  76. package/dist/components/base/Stepper.vue2.js +70 -0
  77. package/dist/components/base/Switch.vue.js +7 -0
  78. package/dist/components/base/Switch.vue2.js +43 -0
  79. package/dist/components/base/ToolbarBtn.vue.js +7 -0
  80. package/dist/components/base/ToolbarBtn.vue2.js +30 -0
  81. package/dist/components/base/ViewModeGroup.vue.js +7 -0
  82. package/dist/components/base/ViewModeGroup.vue2.js +32 -0
  83. package/dist/components/base/ViewSwitcher.vue.js +7 -0
  84. package/dist/components/base/ViewSwitcher.vue2.js +73 -0
  85. package/dist/components/base/ViewTab.vue.js +7 -0
  86. package/dist/components/base/ViewTab.vue2.js +42 -0
  87. package/dist/components/breadcrumb/Breadcrumb.vue.js +7 -0
  88. package/dist/components/breadcrumb/Breadcrumb.vue2.js +52 -0
  89. package/dist/components/breadcrumb/BreadcrumbItem.vue.js +7 -0
  90. package/dist/components/breadcrumb/BreadcrumbItem.vue2.js +35 -0
  91. package/dist/components/detail/CommentItem.vue.js +7 -0
  92. package/dist/components/detail/CommentItem.vue2.js +29 -0
  93. package/dist/components/detail/DetailLayout.vue.js +7 -0
  94. package/dist/components/detail/DetailLayout.vue2.js +118 -0
  95. package/dist/components/detail/PropPanel.vue.js +7 -0
  96. package/dist/components/detail/PropPanel.vue2.js +51 -0
  97. package/dist/components/detail/PropRow.vue.js +7 -0
  98. package/dist/components/detail/PropRow.vue2.js +51 -0
  99. package/dist/components/editor/BlockQuote.vue.js +7 -0
  100. package/dist/components/editor/BlockQuote.vue2.js +45 -0
  101. package/dist/components/editor/CodeBlock.vue.js +7 -0
  102. package/dist/components/editor/CodeBlock.vue2.js +48 -0
  103. package/dist/components/editor/ContentBlock.vue.js +7 -0
  104. package/dist/components/editor/ContentBlock.vue2.js +49 -0
  105. package/dist/components/editor/RefLink.vue.js +7 -0
  106. package/dist/components/editor/RefLink.vue2.js +37 -0
  107. package/dist/components/editor/RichTextEditor.vue.js +7 -0
  108. package/dist/components/editor/RichTextEditor.vue2.js +132 -0
  109. package/dist/components/field/FieldCheckbox.vue.js +7 -0
  110. package/dist/{FieldCheckbox-CV3QtQ4Y.js → components/field/FieldCheckbox.vue2.js} +8 -9
  111. package/dist/components/field/FieldDate.vue.js +7 -0
  112. package/dist/{FieldDate-Bljx4jb7.js → components/field/FieldDate.vue2.js} +9 -10
  113. package/dist/components/field/FieldDatetime.vue.js +7 -0
  114. package/dist/{FieldDatetime-B52GfWrK.js → components/field/FieldDatetime.vue2.js} +11 -12
  115. package/dist/components/field/FieldEmail.vue.js +7 -0
  116. package/dist/{FieldEmail-UREMoue-.js → components/field/FieldEmail.vue2.js} +12 -13
  117. package/dist/components/field/FieldMultiSelect.vue.js +7 -0
  118. package/dist/{FieldMultiSelect-Dlay1Fop.js → components/field/FieldMultiSelect.vue2.js} +32 -33
  119. package/dist/components/field/FieldNumber.vue.js +7 -0
  120. package/dist/{FieldNumber-BjhfFhs6.js → components/field/FieldNumber.vue2.js} +8 -9
  121. package/dist/components/field/FieldRating.vue.js +7 -0
  122. package/dist/components/field/FieldRating.vue2.js +31 -0
  123. package/dist/components/field/FieldSelect.vue.js +7 -0
  124. package/dist/{FieldSelect-B39Ad8VH.js → components/field/FieldSelect.vue2.js} +34 -35
  125. package/dist/components/field/FieldText.vue.js +7 -0
  126. package/dist/{FieldText-Ry7f72Ug.js → components/field/FieldText.vue2.js} +13 -14
  127. package/dist/components/field/FieldUrl.vue.js +7 -0
  128. package/dist/components/field/FieldUrl.vue2.js +33 -0
  129. package/dist/components/form/FormDesigner.vue.js +7 -0
  130. package/dist/components/form/FormDesigner.vue2.js +245 -0
  131. package/dist/components/gallery/GalleryCard.vue.js +7 -0
  132. package/dist/components/gallery/GalleryCard.vue2.js +87 -0
  133. package/dist/components/gallery/GalleryView.vue.js +7 -0
  134. package/dist/components/gallery/GalleryView.vue2.js +48 -0
  135. package/dist/components/kanban/KanbanBoard.vue.js +7 -0
  136. package/dist/components/kanban/KanbanBoard.vue2.js +86 -0
  137. package/dist/components/kanban/KanbanCard.vue.js +7 -0
  138. package/dist/components/kanban/KanbanCard.vue2.js +56 -0
  139. package/dist/components/kanban/KanbanColumn.vue.js +7 -0
  140. package/dist/components/kanban/KanbanColumn.vue2.js +103 -0
  141. package/dist/components/kanban/QuickAddRow.vue.js +7 -0
  142. package/dist/components/kanban/QuickAddRow.vue2.js +58 -0
  143. package/dist/components/layout/AppLayout.vue.js +7 -0
  144. package/dist/components/layout/AppLayout.vue2.js +98 -0
  145. package/dist/components/layout/Navbar.vue.js +7 -0
  146. package/dist/components/layout/Navbar.vue2.js +70 -0
  147. package/dist/components/layout/Sidebar.vue.js +7 -0
  148. package/dist/components/layout/Sidebar.vue2.js +88 -0
  149. package/dist/components/layout/StatusBar.vue.js +7 -0
  150. package/dist/components/layout/StatusBar.vue2.js +37 -0
  151. package/dist/components/mermaid/MermaidChart.vue.js +7 -0
  152. package/dist/components/mermaid/MermaidChart.vue2.js +75 -0
  153. package/dist/components/overlay/Dialog.vue.js +7 -0
  154. package/dist/components/overlay/Dialog.vue2.js +89 -0
  155. package/dist/components/overlay/Drawer.vue.js +7 -0
  156. package/dist/components/overlay/Drawer.vue2.js +112 -0
  157. package/dist/components/overlay/Modal.vue.js +7 -0
  158. package/dist/components/overlay/Modal.vue2.js +115 -0
  159. package/dist/components/overlay/SidePanel.vue.js +7 -0
  160. package/dist/components/overlay/SidePanel.vue2.js +137 -0
  161. package/dist/components/split/SplitPane.vue.js +8 -0
  162. package/dist/components/split/SplitPane.vue2.js +68 -0
  163. package/dist/components/table/DataTable.vue.js +7 -0
  164. package/dist/components/table/DataTable.vue2.js +234 -0
  165. package/dist/components/table/FieldCell.vue.js +7 -0
  166. package/dist/components/table/FieldCell.vue2.js +71 -0
  167. package/dist/components/table/NewRowBtn.vue.js +7 -0
  168. package/dist/components/table/NewRowBtn.vue2.js +22 -0
  169. package/dist/components/table/TableColumnManager.vue.js +7 -0
  170. package/dist/components/table/TableColumnManager.vue2.js +100 -0
  171. package/dist/components/table/TableDataRow.vue.js +7 -0
  172. package/dist/components/table/TableDataRow.vue2.js +115 -0
  173. package/dist/components/table/TableFilterPanel.vue.js +7 -0
  174. package/dist/components/table/TableFilterPanel.vue2.js +142 -0
  175. package/dist/components/table/TableGroupRow.vue.js +7 -0
  176. package/dist/components/table/TableGroupRow.vue2.js +48 -0
  177. package/dist/components/table/TableHeaderRow.vue.js +7 -0
  178. package/dist/components/table/TableHeaderRow.vue2.js +69 -0
  179. package/dist/components/tabs/TabPanel.vue.js +7 -0
  180. package/dist/components/tabs/TabPanel.vue2.js +26 -0
  181. package/dist/components/tabs/Tabs.vue.js +7 -0
  182. package/dist/components/tabs/Tabs.vue2.js +87 -0
  183. package/dist/components/timeline/ActivityTimeline.vue.js +7 -0
  184. package/dist/components/timeline/ActivityTimeline.vue2.js +104 -0
  185. package/dist/components/timeline/GanttRow.vue.js +7 -0
  186. package/dist/components/timeline/GanttRow.vue2.js +110 -0
  187. package/dist/components/timeline/GanttTimeline.vue.js +7 -0
  188. package/dist/components/timeline/GanttTimeline.vue2.js +185 -0
  189. package/dist/components/toast/ToastContainer.vue.js +34 -0
  190. package/dist/components/toast/ToastContainer.vue3.js +5 -0
  191. package/dist/components/toast/ToastItem.vue.js +7 -0
  192. package/dist/components/toast/ToastItem.vue2.js +78 -0
  193. package/dist/composables/useAiChat.js +103 -0
  194. package/dist/composables/useBadge.js +76 -0
  195. package/dist/composables/useBreakpoint.js +16 -0
  196. package/dist/composables/useInlineEdit.js +28 -0
  197. package/dist/composables/useMarkdown.js +69 -0
  198. package/dist/composables/useStream.js +80 -0
  199. package/dist/composables/useTable.js +115 -0
  200. package/dist/composables/useTableColumns.js +24 -0
  201. package/dist/composables/useTableData.js +16 -0
  202. package/dist/composables/useTableFilter.js +97 -0
  203. package/dist/composables/useTableGroup.js +46 -0
  204. package/dist/composables/useToast.js +38 -0
  205. package/dist/composables/useTypewriter.js +56 -0
  206. package/dist/composables/useVirtualList.js +117 -0
  207. package/dist/constants/table.js +11 -0
  208. package/dist/index.js +301 -0
  209. package/dist/node_modules/.pnpm/highlight.js@11.11.1/node_modules/highlight.js/es/core.js +5 -0
  210. package/dist/node_modules/.pnpm/highlight.js@11.11.1/node_modules/highlight.js/es/languages/bash.js +377 -0
  211. package/dist/node_modules/.pnpm/highlight.js@11.11.1/node_modules/highlight.js/es/languages/css.js +923 -0
  212. package/dist/node_modules/.pnpm/highlight.js@11.11.1/node_modules/highlight.js/es/languages/go.js +151 -0
  213. package/dist/node_modules/.pnpm/highlight.js@11.11.1/node_modules/highlight.js/es/languages/java.js +240 -0
  214. package/dist/node_modules/.pnpm/highlight.js@11.11.1/node_modules/highlight.js/es/languages/javascript.js +658 -0
  215. package/dist/node_modules/.pnpm/highlight.js@11.11.1/node_modules/highlight.js/es/languages/json.js +38 -0
  216. package/dist/node_modules/.pnpm/highlight.js@11.11.1/node_modules/highlight.js/es/languages/markdown.js +216 -0
  217. package/dist/node_modules/.pnpm/highlight.js@11.11.1/node_modules/highlight.js/es/languages/plaintext.js +13 -0
  218. package/dist/node_modules/.pnpm/highlight.js@11.11.1/node_modules/highlight.js/es/languages/python.js +399 -0
  219. package/dist/node_modules/.pnpm/highlight.js@11.11.1/node_modules/highlight.js/es/languages/rust.js +305 -0
  220. package/dist/node_modules/.pnpm/highlight.js@11.11.1/node_modules/highlight.js/es/languages/sql.js +615 -0
  221. package/dist/node_modules/.pnpm/highlight.js@11.11.1/node_modules/highlight.js/es/languages/typescript.js +753 -0
  222. package/dist/node_modules/.pnpm/highlight.js@11.11.1/node_modules/highlight.js/es/languages/xml.js +219 -0
  223. package/dist/node_modules/.pnpm/highlight.js@11.11.1/node_modules/highlight.js/es/languages/yaml.js +183 -0
  224. package/dist/node_modules/.pnpm/highlight.js@11.11.1/node_modules/highlight.js/lib/core.js +1063 -0
  225. package/dist/style.css +1 -1
  226. package/dist/types/index.js +77 -0
  227. package/dist/utils/icon.js +15 -0
  228. package/package.json +13 -6
  229. package/dist/FieldRating-BKHUu-A1.js +0 -32
  230. package/dist/FieldUrl-bv0EB9sh.js +0 -34
  231. package/dist/index-DQph5iTq.js +0 -12936
  232. package/dist/oneflow-ui.js +0 -111
  233. package/dist/oneflow-ui.umd.cjs +0 -13
@@ -0,0 +1,86 @@
1
+ import { defineComponent as B, ref as f, computed as H, openBlock as o, createElementBlock as a, normalizeClass as m, renderSlot as h, createCommentVNode as v, createElementVNode as l, withDirectives as S, vModelText as $, createBlock as b, unref as y, nextTick as p } from "vue";
2
+ import { Square as z, ArrowUp as A } from "lucide-vue-next";
3
+ const E = {
4
+ key: 0,
5
+ class: "of-ai-sender__tools"
6
+ }, K = { class: "of-ai-sender__inner" }, V = {
7
+ key: 0,
8
+ class: "of-ai-sender__prefix"
9
+ }, D = ["placeholder", "disabled"], I = ["title"], M = 22, U = /* @__PURE__ */ B({
10
+ __name: "AiSender",
11
+ props: {
12
+ placeholder: {},
13
+ disabled: { type: Boolean },
14
+ maxRows: {}
15
+ },
16
+ emits: ["send", "cancel"],
17
+ setup(t, { emit: x }) {
18
+ const i = t, d = x, n = f(""), r = f(null), k = H(() => i.maxRows ?? 6);
19
+ function c() {
20
+ const e = r.value;
21
+ if (!e) return;
22
+ e.style.height = "auto";
23
+ const s = M * k.value + 16;
24
+ e.style.height = Math.min(e.scrollHeight, s) + "px";
25
+ }
26
+ async function w() {
27
+ await p(), c();
28
+ }
29
+ function _(e) {
30
+ e.key === "Enter" && !e.shiftKey && (e.preventDefault(), u());
31
+ }
32
+ function u() {
33
+ const e = n.value.trim();
34
+ !e || i.disabled || (d("send", e), n.value = "", p(() => {
35
+ c();
36
+ }));
37
+ }
38
+ function g() {
39
+ d("cancel");
40
+ }
41
+ function C() {
42
+ i.disabled ? g() : u();
43
+ }
44
+ return (e, s) => (o(), a("div", {
45
+ class: m(["of-ai-sender", { "is-disabled": t.disabled }])
46
+ }, [
47
+ e.$slots.tools ? (o(), a("div", E, [
48
+ h(e.$slots, "tools", {}, void 0, !0)
49
+ ])) : v("", !0),
50
+ l("div", K, [
51
+ e.$slots.prefix ? (o(), a("div", V, [
52
+ h(e.$slots, "prefix", {}, void 0, !0)
53
+ ])) : v("", !0),
54
+ S(l("textarea", {
55
+ ref_key: "textareaRef",
56
+ ref: r,
57
+ "onUpdate:modelValue": s[0] || (s[0] = (R) => n.value = R),
58
+ class: "of-ai-sender__textarea",
59
+ placeholder: t.placeholder ?? "输入消息...",
60
+ disabled: t.disabled,
61
+ rows: "1",
62
+ onInput: w,
63
+ onKeydown: _
64
+ }, null, 40, D), [
65
+ [$, n.value]
66
+ ]),
67
+ l("button", {
68
+ class: m(["of-ai-sender__action-btn", { "is-stop": t.disabled, "is-empty": !n.value.trim() && !t.disabled }]),
69
+ title: t.disabled ? "停止" : "发送",
70
+ onClick: C
71
+ }, [
72
+ t.disabled ? (o(), b(y(z), {
73
+ key: 0,
74
+ size: 16
75
+ })) : (o(), b(y(A), {
76
+ key: 1,
77
+ size: 16
78
+ }))
79
+ ], 10, I)
80
+ ])
81
+ ], 2));
82
+ }
83
+ });
84
+ export {
85
+ U as default
86
+ };
@@ -0,0 +1,7 @@
1
+ import o from "./AiStreamingCursor.vue2.js";
2
+ /* empty css */
3
+ import r from "../../_virtual/_plugin-vue_export-helper.js";
4
+ const f = /* @__PURE__ */ r(o, [["__scopeId", "data-v-d71a6f39"]]);
5
+ export {
6
+ f as default
7
+ };
@@ -0,0 +1,16 @@
1
+ import { defineComponent as o, openBlock as t, createElementBlock as r, createCommentVNode as n } from "vue";
2
+ const s = {
3
+ key: 0,
4
+ class: "of-streaming-cursor"
5
+ }, m = /* @__PURE__ */ o({
6
+ __name: "AiStreamingCursor",
7
+ props: {
8
+ visible: { type: Boolean }
9
+ },
10
+ setup(e) {
11
+ return (a, c) => e.visible !== !1 ? (t(), r("span", s)) : n("", !0);
12
+ }
13
+ });
14
+ export {
15
+ m as default
16
+ };
@@ -0,0 +1,7 @@
1
+ import o from "./AiThinking.vue2.js";
2
+ /* empty css */
3
+ import t from "../../_virtual/_plugin-vue_export-helper.js";
4
+ const m = /* @__PURE__ */ t(o, [["__scopeId", "data-v-f40004bf"]]);
5
+ export {
6
+ m as default
7
+ };
@@ -0,0 +1,19 @@
1
+ import { defineComponent as s, openBlock as t, createElementBlock as o, normalizeClass as a, createElementVNode as n } from "vue";
2
+ const p = /* @__PURE__ */ s({
3
+ __name: "AiThinking",
4
+ props: {
5
+ size: {}
6
+ },
7
+ setup(e) {
8
+ return (l, i) => (t(), o("div", {
9
+ class: a(["of-ai-thinking", e.size])
10
+ }, [...i[0] || (i[0] = [
11
+ n("span", { class: "of-ai-thinking__dot" }, null, -1),
12
+ n("span", { class: "of-ai-thinking__dot" }, null, -1),
13
+ n("span", { class: "of-ai-thinking__dot" }, null, -1)
14
+ ])], 2));
15
+ }
16
+ });
17
+ export {
18
+ p as default
19
+ };
@@ -0,0 +1,7 @@
1
+ import o from "./UserMessageBubble.vue2.js";
2
+ /* empty css */
3
+ import e from "../../_virtual/_plugin-vue_export-helper.js";
4
+ const a = /* @__PURE__ */ e(o, [["__scopeId", "data-v-0a14f8b1"]]);
5
+ export {
6
+ a as default
7
+ };
@@ -0,0 +1,34 @@
1
+ import { defineComponent as c, openBlock as s, createElementBlock as t, createElementVNode as a, toDisplayString as o, createCommentVNode as m } from "vue";
2
+ const n = { class: "of-user-message" }, r = { class: "of-user-message__body" }, i = { class: "of-user-message__bubble" }, _ = {
3
+ key: 0,
4
+ class: "of-user-message__timestamp"
5
+ }, l = { class: "of-user-message__avatar" }, d = ["src"], u = {
6
+ key: 1,
7
+ class: "of-user-message__avatar-emoji"
8
+ }, h = /* @__PURE__ */ c({
9
+ __name: "UserMessageBubble",
10
+ props: {
11
+ content: {},
12
+ timestamp: {},
13
+ avatar: {}
14
+ },
15
+ setup(e) {
16
+ return (f, g) => (s(), t("div", n, [
17
+ a("div", r, [
18
+ a("div", i, o(e.content), 1),
19
+ e.timestamp ? (s(), t("div", _, o(e.timestamp), 1)) : m("", !0)
20
+ ]),
21
+ a("div", l, [
22
+ e.avatar ? (s(), t("img", {
23
+ key: 0,
24
+ src: e.avatar,
25
+ alt: "User",
26
+ class: "of-user-message__avatar-img"
27
+ }, null, 8, d)) : (s(), t("span", u, "👤"))
28
+ ])
29
+ ]));
30
+ }
31
+ });
32
+ export {
33
+ h as default
34
+ };
@@ -0,0 +1,7 @@
1
+ import o from "./ColorPanel.vue2.js";
2
+ /* empty css */
3
+ import r from "../../_virtual/_plugin-vue_export-helper.js";
4
+ const m = /* @__PURE__ */ r(o, [["__scopeId", "data-v-94d43df3"]]);
5
+ export {
6
+ m as default
7
+ };
@@ -0,0 +1,65 @@
1
+ import { defineComponent as m, computed as _, openBlock as s, createElementBlock as d, normalizeClass as h, createElementVNode as t, toDisplayString as u, withDirectives as r, vModelText as b, createCommentVNode as v, Fragment as k, renderList as y, normalizeStyle as V } from "vue";
2
+ const C = { class: "of-color-panel__header" }, g = { class: "of-color-panel__label" }, w = { class: "of-color-panel__value" }, x = { class: "of-color-panel__picker-row" }, B = ["disabled"], P = ["disabled"], z = { class: "of-color-panel__presets" }, D = ["title", "disabled", "onClick"], N = /* @__PURE__ */ m({
3
+ __name: "ColorPanel",
4
+ props: {
5
+ modelValue: {},
6
+ presets: { default: () => ["#3b82f6", "#10b981", "#f59e0b", "#ef4444", "#8b5cf6", "#06b6d4"] },
7
+ showInput: { type: Boolean, default: !0 },
8
+ disabled: { type: Boolean },
9
+ label: { default: "颜色" }
10
+ },
11
+ emits: ["update:modelValue", "change"],
12
+ setup(e, { emit: p }) {
13
+ const i = e, c = p, o = _({
14
+ get: () => i.modelValue || "#3b82f6",
15
+ set: (a) => {
16
+ c("update:modelValue", a), c("change", a);
17
+ }
18
+ });
19
+ function f(a) {
20
+ i.disabled || (o.value = a);
21
+ }
22
+ return (a, n) => (s(), d("div", {
23
+ class: h(["of-color-panel", { disabled: e.disabled }])
24
+ }, [
25
+ t("div", C, [
26
+ t("span", g, u(e.label), 1),
27
+ t("span", w, u(o.value), 1)
28
+ ]),
29
+ t("div", x, [
30
+ r(t("input", {
31
+ "onUpdate:modelValue": n[0] || (n[0] = (l) => o.value = l),
32
+ class: "of-color-panel__picker",
33
+ type: "color",
34
+ disabled: e.disabled
35
+ }, null, 8, B), [
36
+ [b, o.value]
37
+ ]),
38
+ e.showInput ? r((s(), d("input", {
39
+ key: 0,
40
+ "onUpdate:modelValue": n[1] || (n[1] = (l) => o.value = l),
41
+ class: "of-color-panel__input",
42
+ type: "text",
43
+ disabled: e.disabled,
44
+ placeholder: "#3b82f6"
45
+ }, null, 8, P)), [
46
+ [b, o.value]
47
+ ]) : v("", !0)
48
+ ]),
49
+ t("div", z, [
50
+ (s(!0), d(k, null, y(e.presets, (l) => (s(), d("button", {
51
+ key: l,
52
+ type: "button",
53
+ class: "of-color-panel__preset",
54
+ title: l,
55
+ style: V({ backgroundColor: l }),
56
+ disabled: e.disabled,
57
+ onClick: (E) => f(l)
58
+ }, null, 12, D))), 128))
59
+ ])
60
+ ], 2));
61
+ }
62
+ });
63
+ export {
64
+ N as default
65
+ };
@@ -0,0 +1,7 @@
1
+ import o from "./FileUpload.vue2.js";
2
+ /* empty css */
3
+ import t from "../../_virtual/_plugin-vue_export-helper.js";
4
+ const m = /* @__PURE__ */ t(o, [["__scopeId", "data-v-bb034782"]]);
5
+ export {
6
+ m as default
7
+ };
@@ -0,0 +1,90 @@
1
+ import { defineComponent as z, ref as p, openBlock as s, createElementBlock as u, createElementVNode as o, withModifiers as g, normalizeClass as x, createVNode as b, unref as v, toDisplayString as c, Fragment as B, renderList as D, createCommentVNode as F } from "vue";
2
+ import { Upload as $, X as N } from "lucide-vue-next";
3
+ const A = { class: "of-file-upload" }, E = ["multiple", "accept", "disabled"], I = ["disabled"], M = {
4
+ key: 0,
5
+ class: "of-file-upload__list"
6
+ }, S = { class: "of-file-upload__name" }, U = { class: "of-file-upload__size" }, w = ["disabled", "onClick"], T = /* @__PURE__ */ z({
7
+ __name: "FileUpload",
8
+ props: {
9
+ modelValue: { default: () => [] },
10
+ multiple: { type: Boolean, default: !1 },
11
+ accept: { default: "" },
12
+ maxCount: { default: 1 },
13
+ disabled: { type: Boolean },
14
+ hint: { default: "点击或拖拽文件到此处上传" }
15
+ },
16
+ emits: ["update:modelValue", "change"],
17
+ setup(t, { emit: h }) {
18
+ const a = t, i = h, d = p(!1), r = p(null);
19
+ function V(l) {
20
+ if (!l) return a.modelValue ?? [];
21
+ const e = Array.from(l);
22
+ return (a.multiple ? [...a.modelValue ?? [], ...e] : e.slice(0, 1)).slice(0, Math.max(a.maxCount, 1));
23
+ }
24
+ function f(l) {
25
+ if (a.disabled) return;
26
+ const e = V(l);
27
+ i("update:modelValue", e), i("change", e);
28
+ }
29
+ function _(l) {
30
+ f(l.target.files);
31
+ }
32
+ function k(l) {
33
+ var e;
34
+ l.preventDefault(), d.value = !1, f(((e = l.dataTransfer) == null ? void 0 : e.files) ?? null);
35
+ }
36
+ function y(l) {
37
+ if (a.disabled) return;
38
+ const e = [...a.modelValue ?? []];
39
+ e.splice(l, 1), i("update:modelValue", e), i("change", e);
40
+ }
41
+ function C() {
42
+ var l;
43
+ a.disabled || (l = r.value) == null || l.click();
44
+ }
45
+ return (l, e) => (s(), u("div", A, [
46
+ o("input", {
47
+ ref_key: "fileInput",
48
+ ref: r,
49
+ class: "of-file-upload__native",
50
+ type: "file",
51
+ multiple: t.multiple,
52
+ accept: t.accept,
53
+ disabled: t.disabled,
54
+ onChange: _
55
+ }, null, 40, E),
56
+ o("button", {
57
+ type: "button",
58
+ class: x(["of-file-upload__dropzone", { dragging: d.value, disabled: t.disabled }]),
59
+ disabled: t.disabled,
60
+ onClick: C,
61
+ onDragover: e[0] || (e[0] = g((n) => d.value = !0, ["prevent"])),
62
+ onDragleave: e[1] || (e[1] = g((n) => d.value = !1, ["prevent"])),
63
+ onDrop: k
64
+ }, [
65
+ b(v($), { size: 16 }),
66
+ o("span", null, c(t.hint), 1)
67
+ ], 42, I),
68
+ t.modelValue && t.modelValue.length ? (s(), u("ul", M, [
69
+ (s(!0), u(B, null, D(t.modelValue, (n, m) => (s(), u("li", {
70
+ key: `${n.name}-${m}`,
71
+ class: "of-file-upload__item"
72
+ }, [
73
+ o("span", S, c(n.name), 1),
74
+ o("span", U, c((n.size / 1024).toFixed(1)) + " KB", 1),
75
+ o("button", {
76
+ type: "button",
77
+ class: "of-file-upload__remove",
78
+ disabled: t.disabled,
79
+ onClick: (K) => y(m)
80
+ }, [
81
+ b(v(N), { size: 14 })
82
+ ], 8, w)
83
+ ]))), 128))
84
+ ])) : F("", !0)
85
+ ]));
86
+ }
87
+ });
88
+ export {
89
+ T as default
90
+ };
@@ -0,0 +1,7 @@
1
+ import o from "./PersonPanel.vue2.js";
2
+ /* empty css */
3
+ import r from "../../_virtual/_plugin-vue_export-helper.js";
4
+ const m = /* @__PURE__ */ r(o, [["__scopeId", "data-v-0693c313"]]);
5
+ export {
6
+ m as default
7
+ };
@@ -0,0 +1,66 @@
1
+ import { defineComponent as y, computed as p, openBlock as e, createElementBlock as l, normalizeClass as b, createElementVNode as d, normalizeStyle as k, toDisplayString as i, withDirectives as h, Fragment as m, renderList as V, createTextVNode as v, createCommentVNode as g, vModelSelect as x } from "vue";
2
+ const C = { class: "of-person-panel__row" }, B = ["src", "alt"], N = { key: 1 }, P = {
3
+ key: 1,
4
+ class: "of-person-panel__avatar empty"
5
+ }, S = ["disabled"], w = { value: null }, z = ["value"], E = /* @__PURE__ */ y({
6
+ __name: "PersonPanel",
7
+ props: {
8
+ modelValue: { default: null },
9
+ people: {},
10
+ placeholder: { default: "请选择负责人" },
11
+ disabled: { type: Boolean }
12
+ },
13
+ emits: ["update:modelValue", "change"],
14
+ setup(n, { emit: _ }) {
15
+ const c = n, u = _, r = p({
16
+ get: () => c.modelValue,
17
+ set: (a) => {
18
+ u("update:modelValue", a), u("change", a);
19
+ }
20
+ }), o = p(
21
+ () => c.people.find((a) => a.id === r.value) ?? null
22
+ );
23
+ function f(a) {
24
+ return (a || "?").trim().slice(0, 1).toUpperCase();
25
+ }
26
+ return (a, s) => (e(), l("div", {
27
+ class: b(["of-person-panel", { disabled: n.disabled }])
28
+ }, [
29
+ s[1] || (s[1] = d("label", { class: "of-person-panel__label" }, "负责人", -1)),
30
+ d("div", C, [
31
+ o.value ? (e(), l("div", {
32
+ key: 0,
33
+ class: "of-person-panel__avatar",
34
+ style: k({ background: o.value.color || "var(--of-color-primary-500)" })
35
+ }, [
36
+ o.value.avatar ? (e(), l("img", {
37
+ key: 0,
38
+ src: o.value.avatar,
39
+ alt: o.value.name
40
+ }, null, 8, B)) : (e(), l("span", N, i(f(o.value.name)), 1))
41
+ ], 4)) : (e(), l("div", P, "-")),
42
+ h(d("select", {
43
+ "onUpdate:modelValue": s[0] || (s[0] = (t) => r.value = t),
44
+ class: "of-person-panel__select",
45
+ disabled: n.disabled
46
+ }, [
47
+ d("option", w, i(n.placeholder), 1),
48
+ (e(!0), l(m, null, V(n.people, (t) => (e(), l("option", {
49
+ key: t.id,
50
+ value: t.id
51
+ }, [
52
+ v(i(t.name), 1),
53
+ t.title ? (e(), l(m, { key: 0 }, [
54
+ v(" · " + i(t.title), 1)
55
+ ], 64)) : g("", !0)
56
+ ], 8, z))), 128))
57
+ ], 8, S), [
58
+ [x, r.value]
59
+ ])
60
+ ])
61
+ ], 2));
62
+ }
63
+ });
64
+ export {
65
+ E as default
66
+ };
@@ -0,0 +1,7 @@
1
+ import o from "./Accordion.vue2.js";
2
+ /* empty css */
3
+ import r from "../../_virtual/_plugin-vue_export-helper.js";
4
+ const m = /* @__PURE__ */ r(o, [["__scopeId", "data-v-2ab50b87"]]);
5
+ export {
6
+ m as default
7
+ };
@@ -0,0 +1,78 @@
1
+ import { defineComponent as k, computed as g, openBlock as n, createElementBlock as l, mergeProps as m, Fragment as h, renderList as b, normalizeClass as V, createElementVNode as s, renderSlot as f, toDisplayString as i, createCommentVNode as p, withDirectives as v, vShow as $ } from "vue";
2
+ const C = ["disabled", "aria-expanded", "aria-controls", "onClick"], z = { class: "of-accordion__trigger-text" }, A = { class: "of-accordion__title" }, B = {
3
+ key: 0,
4
+ class: "of-accordion__subtitle"
5
+ }, S = {
6
+ class: "of-accordion__icon",
7
+ "aria-hidden": "true"
8
+ }, w = ["id"], E = /* @__PURE__ */ k({
9
+ inheritAttrs: !1,
10
+ __name: "Accordion",
11
+ props: {
12
+ items: {},
13
+ modelValue: { default: void 0 },
14
+ multiple: { type: Boolean, default: !1 },
15
+ lazy: { type: Boolean, default: !1 }
16
+ },
17
+ emits: ["update:modelValue"],
18
+ setup(r, { emit: y }) {
19
+ const a = r, u = y, d = g(() => Array.isArray(a.modelValue) ? a.modelValue : typeof a.modelValue == "string" && a.modelValue.length > 0 ? [a.modelValue] : []);
20
+ function t(o) {
21
+ return d.value.includes(o);
22
+ }
23
+ function _(o) {
24
+ if (o.disabled)
25
+ return;
26
+ const c = t(o.key);
27
+ if (a.multiple) {
28
+ u(
29
+ "update:modelValue",
30
+ c ? d.value.filter((e) => e !== o.key) : [...d.value, o.key]
31
+ );
32
+ return;
33
+ }
34
+ u("update:modelValue", c ? "" : o.key);
35
+ }
36
+ return (o, c) => (n(), l("div", m({ class: "of-accordion" }, o.$attrs), [
37
+ (n(!0), l(h, null, b(r.items, (e) => (n(), l("section", {
38
+ key: e.key,
39
+ class: V(["of-accordion__item", {
40
+ "of-accordion__item--open": t(e.key),
41
+ "of-accordion__item--disabled": e.disabled
42
+ }])
43
+ }, [
44
+ s("button", {
45
+ type: "button",
46
+ class: "of-accordion__trigger",
47
+ disabled: e.disabled,
48
+ "aria-expanded": t(e.key),
49
+ "aria-controls": `of-accordion-panel-${e.key}`,
50
+ onClick: (x) => _(e)
51
+ }, [
52
+ f(o.$slots, "trigger", {
53
+ item: e,
54
+ open: t(e.key)
55
+ }, () => [
56
+ s("span", z, [
57
+ s("span", A, i(e.title), 1),
58
+ e.subtitle ? (n(), l("span", B, i(e.subtitle), 1)) : p("", !0)
59
+ ])
60
+ ], !0),
61
+ s("span", S, i(t(e.key) ? "▲" : "▼"), 1)
62
+ ], 8, C),
63
+ !r.lazy || t(e.key) ? v((n(), l("div", {
64
+ key: 0,
65
+ id: `of-accordion-panel-${e.key}`,
66
+ class: "of-accordion__panel"
67
+ }, [
68
+ f(o.$slots, "default", { item: e }, void 0, !0)
69
+ ], 8, w)), [
70
+ [$, r.lazy ? !0 : t(e.key)]
71
+ ]) : p("", !0)
72
+ ], 2))), 128))
73
+ ], 16));
74
+ }
75
+ });
76
+ export {
77
+ E as default
78
+ };
@@ -0,0 +1,7 @@
1
+ import o from "./AddViewBtn.vue2.js";
2
+ /* empty css */
3
+ import t from "../../_virtual/_plugin-vue_export-helper.js";
4
+ const m = /* @__PURE__ */ t(o, [["__scopeId", "data-v-c05e5b5c"]]);
5
+ export {
6
+ m as default
7
+ };
@@ -0,0 +1,25 @@
1
+ import { defineComponent as i, openBlock as l, createElementBlock as s, createVNode as a, unref as r, createElementVNode as d } from "vue";
2
+ import { PlusIcon as m } from "lucide-vue-next";
3
+ const u = /* @__PURE__ */ i({
4
+ __name: "AddViewBtn",
5
+ emits: ["click"],
6
+ setup(f, { emit: n }) {
7
+ const o = n;
8
+ function c(e) {
9
+ o("click", e);
10
+ }
11
+ return (e, t) => (l(), s("button", {
12
+ class: "of-add-view-btn",
13
+ onClick: c
14
+ }, [
15
+ a(r(m), {
16
+ class: "of-add-view-btn__icon",
17
+ size: 12
18
+ }),
19
+ t[0] || (t[0] = d("span", { class: "of-add-view-btn__label" }, "添加视图", -1))
20
+ ]));
21
+ }
22
+ });
23
+ export {
24
+ u as default
25
+ };
@@ -0,0 +1,7 @@
1
+ import o from "./Avatar.vue2.js";
2
+ /* empty css */
3
+ import t from "../../_virtual/_plugin-vue_export-helper.js";
4
+ const e = /* @__PURE__ */ t(o, [["__scopeId", "data-v-5ece2c30"]]);
5
+ export {
6
+ e as default
7
+ };
@@ -0,0 +1,72 @@
1
+ import { defineComponent as v, computed as c, openBlock as p, createElementBlock as i, mergeProps as u, toDisplayString as m } from "vue";
2
+ const d = /* @__PURE__ */ v({
3
+ name: "Avatar",
4
+ inheritAttrs: !1,
5
+ __name: "Avatar",
6
+ props: {
7
+ name: {},
8
+ size: { default: 28 },
9
+ color: {},
10
+ bg: {},
11
+ role: {}
12
+ },
13
+ setup(n) {
14
+ const r = n, a = {
15
+ BE: { color: "var(--of-role-be-text, #4F46E5)", bg: "var(--of-role-be-bg, #EEF2FF)" },
16
+ FE: { color: "var(--of-role-fe-text, #059669)", bg: "var(--of-role-fe-bg, #ECFDF5)" },
17
+ PM: { color: "var(--of-role-pm-text, #db2777)", bg: "var(--of-role-pm-bg, #fce7f3)" },
18
+ DBA: { color: "var(--of-role-dba-text, #c2410c)", bg: "var(--of-role-dba-bg, #fff7ed)" },
19
+ ARCH: { color: "var(--of-role-arch-text, #7C3AED)", bg: "var(--of-role-arch-bg, #F5F3FF)" },
20
+ OPM: { color: "var(--of-role-pm-text, #db2777)", bg: "var(--of-role-pm-bg, #fce7f3)" }
21
+ }, l = [
22
+ { color: "var(--of-role-be-text, #4F46E5)", bg: "var(--of-role-be-bg, #EEF2FF)" },
23
+ { color: "var(--of-role-fe-text, #059669)", bg: "var(--of-role-fe-bg, #ECFDF5)" },
24
+ { color: "var(--of-role-pm-text, #db2777)", bg: "var(--of-role-pm-bg, #fce7f3)" },
25
+ { color: "var(--of-role-dba-text, #c2410c)", bg: "var(--of-role-dba-bg, #fff7ed)" },
26
+ { color: "var(--of-role-arch-text, #7C3AED)", bg: "var(--of-role-arch-bg, #F5F3FF)" },
27
+ { color: "var(--of-role-pm-text, #db2777)", bg: "var(--of-role-pm-bg, #fce7f3)" }
28
+ ];
29
+ function b(o) {
30
+ let e = 0;
31
+ for (let t = 0; t < o.length; t++)
32
+ e = (e << 5) - e + o.charCodeAt(t), e |= 0;
33
+ return Math.abs(e);
34
+ }
35
+ const f = c(() => {
36
+ var t;
37
+ if (r.color && r.bg)
38
+ return { color: r.color, bg: r.bg };
39
+ const o = (t = r.role) == null ? void 0 : t.toUpperCase();
40
+ if (o && a[o])
41
+ return {
42
+ color: r.color || a[o].color,
43
+ bg: r.bg || a[o].bg
44
+ };
45
+ const e = b(r.name) % l.length;
46
+ return {
47
+ color: r.color || l[e].color,
48
+ bg: r.bg || l[e].bg
49
+ };
50
+ }), s = c(() => {
51
+ if (r.role)
52
+ return r.role.slice(0, 2).toUpperCase();
53
+ const o = r.name.trim();
54
+ return o ? /[\u4e00-\u9fff]/.test(o.charAt(0)) ? o.charAt(0) : o.replace(/[^a-zA-Z]/g, "").slice(0, 2).toUpperCase() : "";
55
+ }), g = c(() => {
56
+ const o = r.size, e = Math.round(o * 0.36);
57
+ return {
58
+ "--one-avatar-size": `${o}px`,
59
+ "--one-avatar-bg": f.value.bg,
60
+ "--one-avatar-color": f.value.color,
61
+ "--one-avatar-font-size": `${e}px`
62
+ };
63
+ });
64
+ return (o, e) => (p(), i("span", u({
65
+ class: "one-avatar",
66
+ style: g.value
67
+ }, o.$attrs), m(s.value), 17));
68
+ }
69
+ });
70
+ export {
71
+ d as default
72
+ };
@@ -0,0 +1,7 @@
1
+ import o from "./Badge.vue2.js";
2
+ /* empty css */
3
+ import t from "../../_virtual/_plugin-vue_export-helper.js";
4
+ const f = /* @__PURE__ */ t(o, [["__scopeId", "data-v-1b71e2f8"]]);
5
+ export {
6
+ f as default
7
+ };