@oneflowui/ui 0.5.9 → 0.7.0

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 (134) hide show
  1. package/README.en.md +19 -0
  2. package/README.md +23 -0
  3. package/dist/components/Dashboard/charts/BarChart.vue.js +2 -2
  4. package/dist/components/Dashboard/charts/BarChart.vue2.js +56 -23
  5. package/dist/components/Dashboard/charts/NumberCard.vue.js +2 -2
  6. package/dist/components/Dashboard/charts/NumberCard.vue2.js +14 -14
  7. package/dist/components/Dashboard/charts/PieChart.vue.js +1 -1
  8. package/dist/components/Dashboard/charts/PieChart.vue2.js +49 -23
  9. package/dist/components/Dashboard/charts/TableChart.vue.js +1 -1
  10. package/dist/components/Dashboard/index.vue.d.ts +3 -1
  11. package/dist/components/Dashboard/index.vue.js +2 -2
  12. package/dist/components/Dashboard/index.vue2.js +59 -30
  13. package/dist/components/ai/AiMessageBubble.vue.js +3 -3
  14. package/dist/components/ai/AiSender.vue.js +2 -2
  15. package/dist/components/ai/AiThinking.vue.js +1 -1
  16. package/dist/components/ai/UserMessageBubble.vue.js +3 -3
  17. package/dist/components/auxiliary/ColorPanel.vue.js +3 -3
  18. package/dist/components/auxiliary/ColorPanel.vue2.js +9 -9
  19. package/dist/components/auxiliary/FileUpload.vue.js +2 -2
  20. package/dist/components/auxiliary/PersonPanel.vue.js +1 -1
  21. package/dist/components/auxiliary/PersonPanel.vue2.js +10 -10
  22. package/dist/components/base/Accordion.vue.js +1 -1
  23. package/dist/components/base/Avatar.vue.js +3 -3
  24. package/dist/components/base/Avatar.vue2.js +43 -43
  25. package/dist/components/base/Badge.vue.js +1 -1
  26. package/dist/components/base/Badge.vue2.js +35 -35
  27. package/dist/components/base/ButtonGroup.vue.js +2 -2
  28. package/dist/components/base/ChainItem.vue.js +2 -2
  29. package/dist/components/base/ChainItem.vue2.js +30 -30
  30. package/dist/components/base/DescBlock.vue.js +3 -3
  31. package/dist/components/base/DropdownMenu.vue.js +2 -2
  32. package/dist/components/base/EmptyState.vue.js +1 -1
  33. package/dist/components/base/InfoCard.vue.js +2 -2
  34. package/dist/components/base/InfoCard.vue2.js +66 -66
  35. package/dist/components/base/MonitorItem.vue.js +1 -1
  36. package/dist/components/base/MonitorItem.vue2.js +16 -16
  37. package/dist/components/base/PersonaCard.vue.js +1 -1
  38. package/dist/components/base/PersonaCard.vue2.js +81 -81
  39. package/dist/components/base/ProgressBar.vue.js +2 -2
  40. package/dist/components/base/ProgressBar.vue2.js +16 -16
  41. package/dist/components/base/RangeSlider.vue.js +1 -1
  42. package/dist/components/base/RefTag.vue.js +2 -2
  43. package/dist/components/base/RefTag.vue2.js +20 -20
  44. package/dist/components/base/SearchHighlight.vue.js +1 -1
  45. package/dist/components/base/SectionBlock.vue.js +1 -1
  46. package/dist/components/base/SectionBlock.vue2.js +44 -44
  47. package/dist/components/base/StatisticCard.vue.js +2 -2
  48. package/dist/components/base/StatisticCard.vue2.js +24 -24
  49. package/dist/components/base/StatusIndicator.vue.js +2 -2
  50. package/dist/components/base/StatusIndicator.vue2.js +30 -30
  51. package/dist/components/base/StatusSummary.vue.js +2 -2
  52. package/dist/components/base/StatusSummary.vue2.js +23 -23
  53. package/dist/components/base/Stepper.vue.js +2 -2
  54. package/dist/components/base/Switch.vue.js +2 -2
  55. package/dist/components/base/ToolbarBtn.vue.js +1 -1
  56. package/dist/components/base/ViewModeGroup.vue.js +3 -3
  57. package/dist/components/base/ViewSwitcher.vue.js +2 -2
  58. package/dist/components/base/ViewTab.vue.js +4 -4
  59. package/dist/components/breadcrumb/Breadcrumb.vue.js +2 -2
  60. package/dist/components/breadcrumb/BreadcrumbItem.vue.js +1 -1
  61. package/dist/components/database/DatabaseView.vue.js +2 -2
  62. package/dist/components/database/DatabaseView.vue2.js +482 -412
  63. package/dist/components/detail/CommentItem.vue.js +2 -2
  64. package/dist/components/detail/CommentItem.vue2.js +8 -8
  65. package/dist/components/detail/DetailLayout.vue.d.ts +12 -1
  66. package/dist/components/detail/DetailLayout.vue.js +2 -2
  67. package/dist/components/detail/DetailLayout.vue2.js +115 -68
  68. package/dist/components/editor/BlockQuote.vue.js +2 -2
  69. package/dist/components/editor/CodeBlock.vue.js +2 -2
  70. package/dist/components/editor/ContentBlock.vue.js +2 -2
  71. package/dist/components/editor/RefLink.vue.js +2 -2
  72. package/dist/components/editor/RichTextEditor.vue.js +1 -1
  73. package/dist/components/field/FieldAttachment.vue.js +1 -1
  74. package/dist/components/field/FieldCreator.vue.js +1 -1
  75. package/dist/components/field/FieldCurrency.vue.js +2 -2
  76. package/dist/components/field/FieldMarkdownPreview.vue.js +2 -2
  77. package/dist/components/field/FieldMultiSelect.vue.js +2 -2
  78. package/dist/components/field/FieldProgress.vue.js +2 -2
  79. package/dist/components/field/FieldRating.vue.js +2 -2
  80. package/dist/components/field/FieldRelation.vue.js +1 -1
  81. package/dist/components/field/FieldRichText.vue.js +1 -1
  82. package/dist/components/field/FieldSelect.vue.js +2 -2
  83. package/dist/components/gallery/GalleryCard.vue.js +2 -2
  84. package/dist/components/gallery/GalleryCard.vue2.js +34 -30
  85. package/dist/components/gallery/GalleryView.vue.d.ts +3 -1
  86. package/dist/components/gallery/GalleryView.vue.js +1 -1
  87. package/dist/components/gallery/GalleryView.vue2.js +51 -27
  88. package/dist/components/kanban/KanbanBoard.vue.js +4 -4
  89. package/dist/components/kanban/KanbanCard.vue.js +2 -2
  90. package/dist/components/kanban/KanbanColumn.vue.js +2 -2
  91. package/dist/components/kanban/KanbanColumn.vue2.js +16 -16
  92. package/dist/components/kanban/QuickAddRow.vue.js +1 -1
  93. package/dist/components/layout/AppLayout.vue.js +2 -2
  94. package/dist/components/layout/Navbar.vue.js +3 -3
  95. package/dist/components/layout/Sidebar.vue.js +2 -2
  96. package/dist/components/layout/StatusBar.vue.js +2 -2
  97. package/dist/components/mermaid/MermaidChart.vue.js +2 -2
  98. package/dist/components/overlay/Dialog.vue.js +2 -2
  99. package/dist/components/overlay/Drawer.vue.d.ts +2 -0
  100. package/dist/components/overlay/Drawer.vue.js +2 -2
  101. package/dist/components/overlay/Drawer.vue2.js +25 -24
  102. package/dist/components/overlay/Modal.vue.js +1 -1
  103. package/dist/components/overlay/SidePanel.vue.js +2 -2
  104. package/dist/components/overlay/SidePanel.vue2.js +3 -2
  105. package/dist/components/split/SplitPane.vue.js +2 -2
  106. package/dist/components/table/ColumnHeaderMenu.vue.js +1 -1
  107. package/dist/components/table/DataTable.vue.d.ts +26 -2
  108. package/dist/components/table/DataTable.vue.js +2 -2
  109. package/dist/components/table/DataTable.vue2.js +738 -603
  110. package/dist/components/table/DetailSheet.vue.js +1 -1
  111. package/dist/components/table/FieldCell.vue.js +2 -2
  112. package/dist/components/table/FieldCell.vue2.js +26 -24
  113. package/dist/components/table/FieldTypePicker.vue.js +4 -4
  114. package/dist/components/table/MobileListView.vue.js +2 -2
  115. package/dist/components/table/NewRowBtn.vue.js +2 -2
  116. package/dist/components/table/TableColumnManager.vue.js +2 -2
  117. package/dist/components/table/TableDataRow.vue.d.ts +19 -0
  118. package/dist/components/table/TableDataRow.vue.js +1 -1
  119. package/dist/components/table/TableDataRow.vue2.js +110 -73
  120. package/dist/components/table/TableFilterPanel.vue.js +2 -2
  121. package/dist/components/table/TableGroupRow.vue.js +2 -2
  122. package/dist/components/table/TableHeaderRow.vue.js +2 -2
  123. package/dist/components/table/TableToolbar.vue.js +2 -2
  124. package/dist/components/tabs/Tabs.vue.js +1 -1
  125. package/dist/components/timeline/ActivityTimeline.vue.js +1 -1
  126. package/dist/components/timeline/ActivityTimeline.vue2.js +27 -27
  127. package/dist/components/timeline/GanttRow.vue.js +2 -2
  128. package/dist/components/timeline/GanttRow.vue2.js +21 -18
  129. package/dist/components/timeline/GanttTimeline.vue.js +2 -2
  130. package/dist/components/toast/ToastItem.vue.js +2 -2
  131. package/dist/components/toast/ToastItem.vue2.js +39 -39
  132. package/dist/plugin.js +5 -3
  133. package/dist/style.css +1 -1
  134. package/package.json +1 -1
@@ -1,7 +1,7 @@
1
1
  import o from "./GalleryView.vue2.js";
2
2
  /* empty css */
3
3
  import r from "../../_virtual/_plugin-vue_export-helper.js";
4
- const m = /* @__PURE__ */ r(o, [["__scopeId", "data-v-b432e370"]]);
4
+ const m = /* @__PURE__ */ r(o, [["__scopeId", "data-v-047984a4"]]);
5
5
  export {
6
6
  m as default
7
7
  };
@@ -1,8 +1,8 @@
1
- import { defineComponent as g, computed as t, openBlock as i, createElementBlock as o, normalizeStyle as p, Fragment as I, renderList as w, createBlock as C, createVNode as k, unref as b, createElementVNode as _, createCommentVNode as B } from "vue";
2
- import { PlusIcon as V } from "lucide-vue-next";
3
- import h from "./GalleryCard.vue.js";
4
- import { buildGalleryItems as G } from "../../types/index.js";
5
- const S = /* @__PURE__ */ g({
1
+ import { defineComponent as k, ref as p, computed as d, onMounted as M, onBeforeUnmount as _, openBlock as a, createElementBlock as s, normalizeStyle as B, Fragment as R, renderList as x, createBlock as G, createVNode as V, unref as z, createElementVNode as N, createCommentVNode as S } from "vue";
2
+ import { PlusIcon as E } from "lucide-vue-next";
3
+ import W from "./GalleryCard.vue.js";
4
+ import { buildGalleryItems as $ } from "../../types/index.js";
5
+ const j = /* @__PURE__ */ k({
6
6
  __name: "GalleryView",
7
7
  props: {
8
8
  items: { default: () => [] },
@@ -15,44 +15,68 @@ const S = /* @__PURE__ */ g({
15
15
  addable: { type: Boolean, default: !0 }
16
16
  },
17
17
  emits: ["card-click", "add"],
18
- setup(n, { emit: v }) {
19
- const e = n, s = v, m = t(() => ({
20
- "--columns": e.columns
21
- })), c = t(
18
+ setup(c, { emit: w }) {
19
+ const t = c, v = w, i = p(null), o = p(0);
20
+ let n = null;
21
+ const h = d(() => Math.max(1, Math.floor(t.columns))), f = d(() => {
22
+ const e = o.value, l = h.value;
23
+ return e ? e < 520 ? 1 : e < 820 ? Math.min(l, 2) : e < 1120 ? Math.min(l, 3) : l : l;
24
+ }), F = d(() => ({
25
+ "--gallery-columns": String(f.value),
26
+ "--gallery-card-min-width": f.value <= 1 ? "0px" : "220px"
27
+ }));
28
+ function m(e) {
29
+ var l;
30
+ if (e) {
31
+ o.value = Math.round(e.contentRect.width);
32
+ return;
33
+ }
34
+ o.value = Math.round(((l = i.value) == null ? void 0 : l.getBoundingClientRect().width) ?? 0);
35
+ }
36
+ M(() => {
37
+ m(), !(typeof ResizeObserver > "u" || !i.value) && (n = new ResizeObserver((e) => {
38
+ e[0] && m(e[0]);
39
+ }), n.observe(i.value));
40
+ }), _(() => {
41
+ n == null || n.disconnect(), n = null;
42
+ });
43
+ const y = d(
22
44
  () => {
23
- var d;
24
- return e.coverFieldId || ((d = e.view) == null ? void 0 : d.galleryCoverFieldId) || "";
45
+ var e;
46
+ return t.coverFieldId || ((e = t.view) == null ? void 0 : e.galleryCoverFieldId) || "";
25
47
  }
26
- ), f = t(() => {
27
- var d, l, r, a, u;
28
- return (d = e.cardFieldIds) != null && d.length ? e.cardFieldIds : (r = (l = e.view) == null ? void 0 : l.galleryCardFields) != null && r.length ? e.view.galleryCardFields : (u = (a = e.view) == null ? void 0 : a.visibleFields) != null && u.length ? e.view.visibleFields.filter((F) => F !== c.value) : [];
29
- }), y = t(() => e.items.length > 0 ? e.items : e.records.length > 0 ? G(e.records, {
30
- coverFieldId: c.value || void 0,
31
- cardFieldIds: f.value
48
+ ), C = d(() => {
49
+ var e, l, r, u, g;
50
+ return (e = t.cardFieldIds) != null && e.length ? t.cardFieldIds : (r = (l = t.view) == null ? void 0 : l.galleryCardFields) != null && r.length ? t.view.galleryCardFields : (g = (u = t.view) == null ? void 0 : u.visibleFields) != null && g.length ? t.view.visibleFields.filter((b) => b !== y.value) : [];
51
+ }), I = d(() => t.items.length > 0 ? t.items : t.records.length > 0 ? $(t.records, {
52
+ coverFieldId: y.value || void 0,
53
+ cardFieldIds: C.value
32
54
  }) : []);
33
- return (d, l) => (i(), o("div", {
55
+ return (e, l) => (a(), s("div", {
56
+ ref_key: "galleryRef",
57
+ ref: i,
34
58
  class: "gallery-view",
35
- style: p(m.value)
59
+ style: B(F.value)
36
60
  }, [
37
- (i(!0), o(I, null, w(y.value, (r) => (i(), C(h, {
61
+ (a(!0), s(R, null, x(I.value, (r) => (a(), G(W, {
38
62
  key: r.id,
39
63
  item: r,
40
- onClick: (a) => s("card-click", r)
64
+ onClick: (u) => v("card-click", r)
41
65
  }, null, 8, ["item", "onClick"]))), 128)),
42
- n.addable ? (i(), o("button", {
66
+ c.addable ? (a(), s("button", {
43
67
  key: 0,
44
68
  class: "gallery-view__add-btn",
45
- onClick: l[0] || (l[0] = (r) => s("add"))
69
+ onClick: l[0] || (l[0] = (r) => v("add"))
46
70
  }, [
47
- k(b(V), {
71
+ V(z(E), {
48
72
  size: 18,
49
73
  class: "gallery-view__add-icon"
50
74
  }),
51
- l[1] || (l[1] = _("span", { class: "gallery-view__add-label" }, "添加", -1))
52
- ])) : B("", !0)
75
+ l[1] || (l[1] = N("span", { class: "gallery-view__add-label" }, "添加", -1))
76
+ ])) : S("", !0)
53
77
  ], 4));
54
78
  }
55
79
  });
56
80
  export {
57
- S as default
81
+ j as default
58
82
  };
@@ -1,7 +1,7 @@
1
- import a from "./KanbanBoard.vue2.js";
1
+ import o from "./KanbanBoard.vue2.js";
2
2
  /* empty css */
3
- import o from "../../_virtual/_plugin-vue_export-helper.js";
4
- const p = /* @__PURE__ */ o(a, [["__scopeId", "data-v-5b7aa191"]]);
3
+ import a from "../../_virtual/_plugin-vue_export-helper.js";
4
+ const m = /* @__PURE__ */ a(o, [["__scopeId", "data-v-f7c07951"]]);
5
5
  export {
6
- p as default
6
+ m as default
7
7
  };
@@ -1,7 +1,7 @@
1
1
  import a from "./KanbanCard.vue2.js";
2
2
  /* empty css */
3
3
  import o from "../../_virtual/_plugin-vue_export-helper.js";
4
- const p = /* @__PURE__ */ o(a, [["__scopeId", "data-v-560dac24"]]);
4
+ const m = /* @__PURE__ */ o(a, [["__scopeId", "data-v-f48f4a85"]]);
5
5
  export {
6
- p as default
6
+ m as default
7
7
  };
@@ -1,7 +1,7 @@
1
1
  import o from "./KanbanColumn.vue2.js";
2
2
  /* empty css */
3
3
  import a from "../../_virtual/_plugin-vue_export-helper.js";
4
- const f = /* @__PURE__ */ a(o, [["__scopeId", "data-v-f34d289a"]]);
4
+ const p = /* @__PURE__ */ a(o, [["__scopeId", "data-v-daa8ed09"]]);
5
5
  export {
6
- f as default
6
+ p as default
7
7
  };
@@ -1,4 +1,4 @@
1
- import { defineComponent as D, ref as g, watch as k, computed as C, openBlock as r, createElementBlock as d, createElementVNode as n, normalizeStyle as m, toDisplayString as y, createVNode as E, unref as c, createBlock as f, withCtx as H, Fragment as h, renderList as b } from "vue";
1
+ import { defineComponent as D, ref as g, watch as k, computed as y, openBlock as r, createElementBlock as d, createElementVNode as n, normalizeStyle as m, toDisplayString as C, createVNode as E, unref as c, createBlock as f, withCtx as H, Fragment as h, renderList as b } from "vue";
2
2
  import { Plus as L } from "lucide-vue-next";
3
3
  import { VueDraggable as R } from "vue-draggable-plus";
4
4
  import { useVirtualList as U } from "../../composables/useVirtualList.js";
@@ -14,19 +14,19 @@ const z = { class: "of-kanban-column" }, F = { class: "of-col-header" }, I = { c
14
14
  },
15
15
  emits: ["add-card", "card-click", "update:column"],
16
16
  setup(i, { emit: x }) {
17
- const a = i, u = x, l = g([...a.column.tasks]);
17
+ const s = i, u = x, l = g([...s.column.tasks]);
18
18
  k(
19
- () => a.column.tasks,
20
- (s) => {
21
- s.length === l.value.length && s.every((o, e) => {
19
+ () => s.column.tasks,
20
+ (a) => {
21
+ a.length === l.value.length && a.every((o, e) => {
22
22
  var v;
23
23
  return o.id === ((v = l.value[e]) == null ? void 0 : v.id);
24
- }) || (l.value = [...s]);
24
+ }) || (l.value = [...a]);
25
25
  }
26
- ), k(l, (s) => {
27
- u("update:column", { ...a.column, tasks: s });
26
+ ), k(l, (a) => {
27
+ u("update:column", { ...s.column, tasks: a });
28
28
  });
29
- const S = C(() => l.value.length > 50), p = g(null), {
29
+ const S = y(() => l.value.length > 50), p = g(null), {
30
30
  visibleItems: T,
31
31
  totalHeight: M,
32
32
  offsetY: A
@@ -35,19 +35,19 @@ const z = { class: "of-kanban-column" }, F = { class: "of-col-header" }, I = { c
35
35
  itemHeight: 120,
36
36
  overscan: 3,
37
37
  containerRef: p
38
- }), B = C(() => {
39
- if (a.column.color) return a.column.color;
40
- const s = Y(w, a.statusColorMap), t = s[a.column.id], o = s[a.column.title], e = t ?? o;
41
- return (e == null ? void 0 : e.dot) ?? (e == null ? void 0 : e.text) ?? "var(--of-color-gray-400)";
38
+ }), B = y(() => {
39
+ if (s.column.color) return s.column.color;
40
+ const a = Y(w, s.statusColorMap), t = a[s.column.id], o = a[s.column.title], e = t ?? o;
41
+ return (e == null ? void 0 : e.dot) ?? (e == null ? void 0 : e.text) ?? "var(--of-text-tertiary, var(--of-color-gray-400))";
42
42
  });
43
- return (s, t) => (r(), d("div", z, [
43
+ return (a, t) => (r(), d("div", z, [
44
44
  n("div", F, [
45
45
  n("span", {
46
46
  class: "of-col-dot",
47
47
  style: m({ background: B.value })
48
48
  }, null, 4),
49
- n("span", I, y(i.column.title), 1),
50
- n("span", K, y(l.value.length), 1),
49
+ n("span", I, C(i.column.title), 1),
50
+ n("span", K, C(l.value.length), 1),
51
51
  t[4] || (t[4] = n("span", { class: "of-col-spacer" }, null, -1)),
52
52
  n("button", {
53
53
  class: "of-col-add-btn",
@@ -1,7 +1,7 @@
1
1
  import o from "./QuickAddRow.vue2.js";
2
2
  /* empty css */
3
3
  import t from "../../_virtual/_plugin-vue_export-helper.js";
4
- const p = /* @__PURE__ */ t(o, [["__scopeId", "data-v-47c0eb81"]]);
4
+ const p = /* @__PURE__ */ t(o, [["__scopeId", "data-v-8eaba792"]]);
5
5
  export {
6
6
  p as default
7
7
  };
@@ -1,7 +1,7 @@
1
1
  import o from "./AppLayout.vue2.js";
2
2
  /* empty css */
3
3
  import t from "../../_virtual/_plugin-vue_export-helper.js";
4
- const f = /* @__PURE__ */ t(o, [["__scopeId", "data-v-8488617f"]]);
4
+ const m = /* @__PURE__ */ t(o, [["__scopeId", "data-v-8bdb327a"]]);
5
5
  export {
6
- f as default
6
+ m as default
7
7
  };
@@ -1,7 +1,7 @@
1
1
  import o from "./Navbar.vue2.js";
2
2
  /* empty css */
3
- import a from "../../_virtual/_plugin-vue_export-helper.js";
4
- const p = /* @__PURE__ */ a(o, [["__scopeId", "data-v-ed7a40bd"]]);
3
+ import r from "../../_virtual/_plugin-vue_export-helper.js";
4
+ const m = /* @__PURE__ */ r(o, [["__scopeId", "data-v-e6532c9f"]]);
5
5
  export {
6
- p as default
6
+ m as default
7
7
  };
@@ -1,7 +1,7 @@
1
1
  import o from "./Sidebar.vue2.js";
2
2
  /* empty css */
3
3
  import r from "../../_virtual/_plugin-vue_export-helper.js";
4
- const f = /* @__PURE__ */ r(o, [["__scopeId", "data-v-9ea7f9dc"]]);
4
+ const e = /* @__PURE__ */ r(o, [["__scopeId", "data-v-19ff2e4b"]]);
5
5
  export {
6
- f as default
6
+ e as default
7
7
  };
@@ -1,7 +1,7 @@
1
1
  import t from "./StatusBar.vue2.js";
2
2
  /* empty css */
3
3
  import o from "../../_virtual/_plugin-vue_export-helper.js";
4
- const m = /* @__PURE__ */ o(t, [["__scopeId", "data-v-06dfdfe7"]]);
4
+ const f = /* @__PURE__ */ o(t, [["__scopeId", "data-v-e56cdf6e"]]);
5
5
  export {
6
- m as default
6
+ f as default
7
7
  };
@@ -1,7 +1,7 @@
1
1
  import o from "./MermaidChart.vue2.js";
2
2
  /* empty css */
3
3
  import r from "../../_virtual/_plugin-vue_export-helper.js";
4
- const c = /* @__PURE__ */ r(o, [["__scopeId", "data-v-cc130f1a"]]);
4
+ const e = /* @__PURE__ */ r(o, [["__scopeId", "data-v-e3840a02"]]);
5
5
  export {
6
- c as default
6
+ e as default
7
7
  };
@@ -1,7 +1,7 @@
1
1
  import o from "./Dialog.vue2.js";
2
2
  /* empty css */
3
3
  import t from "../../_virtual/_plugin-vue_export-helper.js";
4
- const p = /* @__PURE__ */ t(o, [["__scopeId", "data-v-118545d6"]]);
4
+ const f = /* @__PURE__ */ t(o, [["__scopeId", "data-v-9e87dcef"]]);
5
5
  export {
6
- p as default
6
+ f as default
7
7
  };
@@ -5,6 +5,7 @@ type __VLS_Props = {
5
5
  showClose?: boolean;
6
6
  maskClosable?: boolean;
7
7
  zIndex?: number;
8
+ fullscreen?: boolean;
8
9
  };
9
10
  declare function __VLS_template(): {
10
11
  attrs: Partial<{}>;
@@ -25,6 +26,7 @@ declare const __VLS_component: import('vue').DefineComponent<__VLS_Props, {}, {}
25
26
  }>, {
26
27
  title: string;
27
28
  width: number;
29
+ fullscreen: boolean;
28
30
  zIndex: number;
29
31
  maskClosable: boolean;
30
32
  showClose: boolean;
@@ -1,7 +1,7 @@
1
1
  import o from "./Drawer.vue2.js";
2
2
  /* empty css */
3
3
  import r from "../../_virtual/_plugin-vue_export-helper.js";
4
- const f = /* @__PURE__ */ r(o, [["__scopeId", "data-v-10de0e6f"]]);
4
+ const m = /* @__PURE__ */ r(o, [["__scopeId", "data-v-1f598ba6"]]);
5
5
  export {
6
- f as default
6
+ m as default
7
7
  };
@@ -1,13 +1,13 @@
1
- import { defineComponent as _, useSlots as p, computed as V, onMounted as B, watch as x, onBeforeUnmount as z, openBlock as o, createBlock as E, Teleport as S, createVNode as u, Transition as T, withCtx as I, createElementBlock as a, normalizeStyle as c, createCommentVNode as l, createElementVNode as d, withModifiers as N, unref as f, renderSlot as m, toDisplayString as R } from "vue";
2
- import { X as $ } from "lucide-vue-next";
3
- import { useFocusTrap as g } from "../../composables/useFocusTrap.js";
4
- const D = ["aria-label"], L = { class: "of-drawer__inner" }, M = {
1
+ import { defineComponent as p, useSlots as _, computed as V, onMounted as B, watch as x, onBeforeUnmount as z, openBlock as o, createBlock as E, Teleport as S, createVNode as u, Transition as T, withCtx as I, createElementBlock as a, normalizeStyle as f, createCommentVNode as l, createElementVNode as r, withModifiers as N, normalizeClass as R, unref as c, renderSlot as m, toDisplayString as $ } from "vue";
2
+ import { X as g } from "lucide-vue-next";
3
+ import { useFocusTrap as D } from "../../composables/useFocusTrap.js";
4
+ const L = ["aria-label"], M = { class: "of-drawer__inner" }, F = {
5
5
  key: 0,
6
6
  class: "of-drawer__header"
7
- }, F = { class: "of-drawer__title" }, K = {
7
+ }, K = { class: "of-drawer__title" }, U = {
8
8
  key: 0,
9
9
  class: "of-drawer__title-text"
10
- }, U = { class: "of-drawer__body" }, A = /* @__PURE__ */ _({
10
+ }, X = { class: "of-drawer__body" }, G = /* @__PURE__ */ p({
11
11
  __name: "Drawer",
12
12
  props: {
13
13
  modelValue: { type: Boolean },
@@ -15,27 +15,28 @@ const D = ["aria-label"], L = { class: "of-drawer__inner" }, M = {
15
15
  title: { default: void 0 },
16
16
  showClose: { type: Boolean, default: !0 },
17
17
  maskClosable: { type: Boolean, default: !0 },
18
- zIndex: { default: 1e3 }
18
+ zIndex: { default: 1e3 },
19
+ fullscreen: { type: Boolean, default: !1 }
19
20
  },
20
21
  emits: ["update:modelValue"],
21
22
  setup(e, { emit: y }) {
22
- const r = e, w = y, h = p(), v = V(() => ({
23
- width: `${r.width}px`
23
+ const d = e, w = y, h = _(), v = V(() => ({
24
+ "--of-drawer-width": `${d.width}px`
24
25
  })), {
25
26
  containerRef: k,
26
27
  activate: b,
27
28
  deactivate: C
28
- } = g();
29
+ } = D();
29
30
  function n() {
30
31
  w("update:modelValue", !1);
31
32
  }
32
33
  function i(t) {
33
- t.key === "Escape" && r.modelValue && n();
34
+ t.key === "Escape" && d.modelValue && n();
34
35
  }
35
36
  return B(() => {
36
37
  typeof document > "u" || document.addEventListener("keydown", i);
37
38
  }), x(
38
- () => r.modelValue,
39
+ () => d.modelValue,
39
40
  (t) => {
40
41
  typeof document > "u" || (document.body.style.overflow = t ? "hidden" : "", t ? b() : C());
41
42
  },
@@ -48,7 +49,7 @@ const D = ["aria-label"], L = { class: "of-drawer__inner" }, M = {
48
49
  e.modelValue ? (o(), a("div", {
49
50
  key: 0,
50
51
  class: "of-drawer-overlay",
51
- style: c({ zIndex: e.zIndex })
52
+ style: f({ zIndex: e.zIndex })
52
53
  }, [
53
54
  e.maskClosable ? (o(), a("button", {
54
55
  key: 0,
@@ -57,22 +58,22 @@ const D = ["aria-label"], L = { class: "of-drawer__inner" }, M = {
57
58
  "aria-label": "关闭抽屉",
58
59
  onClick: n
59
60
  })) : l("", !0),
60
- d("aside", {
61
+ r("aside", {
61
62
  ref_key: "drawerRef",
62
63
  ref: k,
63
- class: "of-drawer",
64
+ class: R(["of-drawer", { "of-drawer--fullscreen": e.fullscreen }]),
64
65
  role: "dialog",
65
66
  "aria-modal": "true",
66
67
  "aria-label": e.title,
67
- style: c(v.value),
68
+ style: f(v.value),
68
69
  onClick: s[0] || (s[0] = N(() => {
69
70
  }, ["stop"]))
70
71
  }, [
71
- d("div", L, [
72
- f(h).title || e.title || e.showClose ? (o(), a("div", M, [
73
- d("div", F, [
72
+ r("div", M, [
73
+ c(h).title || e.title || e.showClose ? (o(), a("div", F, [
74
+ r("div", K, [
74
75
  m(t.$slots, "title", {}, () => [
75
- e.title ? (o(), a("h3", K, R(e.title), 1)) : l("", !0)
76
+ e.title ? (o(), a("h3", U, $(e.title), 1)) : l("", !0)
76
77
  ], !0)
77
78
  ]),
78
79
  e.showClose ? (o(), a("button", {
@@ -82,14 +83,14 @@ const D = ["aria-label"], L = { class: "of-drawer__inner" }, M = {
82
83
  "aria-label": "关闭",
83
84
  onClick: n
84
85
  }, [
85
- u(f($), { size: 18 })
86
+ u(c(g), { size: 18 })
86
87
  ])) : l("", !0)
87
88
  ])) : l("", !0),
88
- d("div", U, [
89
+ r("div", X, [
89
90
  m(t.$slots, "default", {}, void 0, !0)
90
91
  ])
91
92
  ])
92
- ], 12, D)
93
+ ], 14, L)
93
94
  ], 4)) : l("", !0)
94
95
  ]),
95
96
  _: 3
@@ -98,5 +99,5 @@ const D = ["aria-label"], L = { class: "of-drawer__inner" }, M = {
98
99
  }
99
100
  });
100
101
  export {
101
- A as default
102
+ G as default
102
103
  };
@@ -1,7 +1,7 @@
1
1
  import o from "./Modal.vue2.js";
2
2
  /* empty css */
3
3
  import t from "../../_virtual/_plugin-vue_export-helper.js";
4
- const m = /* @__PURE__ */ t(o, [["__scopeId", "data-v-3d6d6bd1"]]);
4
+ const m = /* @__PURE__ */ t(o, [["__scopeId", "data-v-d941ad2e"]]);
5
5
  export {
6
6
  m as default
7
7
  };
@@ -1,7 +1,7 @@
1
1
  import o from "./SidePanel.vue2.js";
2
2
  /* empty css */
3
3
  import t from "../../_virtual/_plugin-vue_export-helper.js";
4
- const e = /* @__PURE__ */ t(o, [["__scopeId", "data-v-bf2b5d9f"]]);
4
+ const m = /* @__PURE__ */ t(o, [["__scopeId", "data-v-e3756298"]]);
5
5
  export {
6
- e as default
6
+ m as default
7
7
  };
@@ -31,7 +31,7 @@ const T = ["aria-label"], N = {
31
31
  emits: ["update:modelValue"],
32
32
  setup(e, { emit: k }) {
33
33
  const i = e, w = k, n = V(() => ({
34
- width: `${i.width}px`
34
+ "--of-side-panel-width": `${i.width}px`
35
35
  })), {
36
36
  containerRef: r,
37
37
  activate: b,
@@ -46,7 +46,8 @@ const T = ["aria-label"], N = {
46
46
  () => i.modelValue,
47
47
  (o) => {
48
48
  typeof document > "u" || (document.body.style.overflow = o ? "hidden" : "", o ? b() : p());
49
- }
49
+ },
50
+ { immediate: !0 }
50
51
  ), B(() => {
51
52
  typeof document > "u" || (document.removeEventListener("keydown", c), document.body.style.overflow = "");
52
53
  });
@@ -2,7 +2,7 @@ import o from "./SplitPane.vue2.js";
2
2
  /* empty css */
3
3
  /* empty css */
4
4
  import t from "../../_virtual/_plugin-vue_export-helper.js";
5
- const i = /* @__PURE__ */ t(o, [["__scopeId", "data-v-9ba00779"]]);
5
+ const m = /* @__PURE__ */ t(o, [["__scopeId", "data-v-5fcfe2e7"]]);
6
6
  export {
7
- i as default
7
+ m as default
8
8
  };
@@ -1,7 +1,7 @@
1
1
  import o from "./ColumnHeaderMenu.vue2.js";
2
2
  /* empty css */
3
3
  import r from "../../_virtual/_plugin-vue_export-helper.js";
4
- const a = /* @__PURE__ */ r(o, [["__scopeId", "data-v-7d9517c4"]]);
4
+ const a = /* @__PURE__ */ r(o, [["__scopeId", "data-v-5c015f78"]]);
5
5
  export {
6
6
  a as default
7
7
  };
@@ -1,5 +1,12 @@
1
1
  import { FieldDef as CellFieldDef } from './FieldCell.vue';
2
2
  import { Density, Task, TableColumn, ColorMap, DataRecord, TableSchema, ViewConfig, ActiveCell, AggregationConfig, GroupConfig } from '../../types';
3
+ export interface BulkActionItem {
4
+ key: string;
5
+ label: string;
6
+ variant?: "default" | "danger";
7
+ disabled?: boolean;
8
+ clearSelectionAfter?: boolean;
9
+ }
3
10
  declare const _default: <T extends {
4
11
  id: string;
5
12
  } & Record<string, unknown>>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
@@ -55,7 +62,12 @@ declare const _default: <T extends {
55
62
  readonly "onSchema-hide-field"?: ((fieldId: string) => any) | undefined;
56
63
  readonly "onSchema-delete-field"?: ((fieldId: string) => any) | undefined;
57
64
  readonly "onSchema-duplicate-field"?: ((fieldId: string) => any) | undefined;
58
- } & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps, never>, "onPaste" | "onRow-click" | "onAdd-row" | "onCell-edit" | "onRow-click-record" | "onSelection-change" | "onColumn-resize" | "onActive-cell-change" | "onRow-reorder" | "onRow-group-change" | "onDraft-commit" | "onDraft-discard" | "onDrafts-commit-all" | "onRow-delete" | "onSchema-add-field" | "onSchema-rename-field" | "onSchema-change-field-type" | "onSchema-hide-field" | "onSchema-delete-field" | "onSchema-duplicate-field"> & {
65
+ readonly "onBulk-action"?: ((payload: {
66
+ actionKey: string;
67
+ rowIds: string[];
68
+ rows: (T | DataRecord)[];
69
+ }) => any) | undefined;
70
+ } & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps, never>, "onPaste" | "onRow-click" | "onAdd-row" | "onCell-edit" | "onRow-click-record" | "onSelection-change" | "onColumn-resize" | "onActive-cell-change" | "onRow-reorder" | "onRow-group-change" | "onDraft-commit" | "onDraft-discard" | "onDrafts-commit-all" | "onRow-delete" | "onSchema-add-field" | "onSchema-rename-field" | "onSchema-change-field-type" | "onSchema-hide-field" | "onSchema-delete-field" | "onSchema-duplicate-field" | "onBulk-action"> & {
59
71
  tasks?: Task[];
60
72
  records?: DataRecord[];
61
73
  schema?: TableSchema;
@@ -90,6 +102,14 @@ declare const _default: <T extends {
90
102
  enableFieldManagement?: boolean;
91
103
  /** Density preset used for table, list, and detail affordances */
92
104
  density?: Density;
105
+ /** 显示默认行级快捷操作 */
106
+ showRowActions?: boolean;
107
+ /** 显示批量操作条 */
108
+ showSelectionBar?: boolean;
109
+ /** 批量操作定义,默认仅提供清空选择 */
110
+ bulkActionItems?: BulkActionItem[];
111
+ /** 开启表格容器感知密度收缩 */
112
+ containerResponsive?: boolean;
93
113
  } & Partial<{}>> & import('vue').PublicProps;
94
114
  expose(exposed: import('vue').ShallowUnwrapRef<{}>): void;
95
115
  attrs: any;
@@ -168,7 +188,11 @@ declare const _default: <T extends {
168
188
  }) => void) & ((evt: "schema-change-field-type", payload: {
169
189
  fieldId: string;
170
190
  newType: string;
171
- }) => void) & ((evt: "schema-hide-field", fieldId: string) => void) & ((evt: "schema-delete-field", fieldId: string) => void) & ((evt: "schema-duplicate-field", fieldId: string) => void);
191
+ }) => void) & ((evt: "schema-hide-field", fieldId: string) => void) & ((evt: "schema-delete-field", fieldId: string) => void) & ((evt: "schema-duplicate-field", fieldId: string) => void) & ((evt: "bulk-action", payload: {
192
+ actionKey: string;
193
+ rowIds: string[];
194
+ rows: (T | DataRecord)[];
195
+ }) => void);
172
196
  }>) => import('vue').VNode & {
173
197
  __ctx?: Awaited<typeof __VLS_setup>;
174
198
  };
@@ -1,7 +1,7 @@
1
1
  import o from "./DataTable.vue2.js";
2
2
  /* empty css */
3
3
  import t from "../../_virtual/_plugin-vue_export-helper.js";
4
- const p = /* @__PURE__ */ t(o, [["__scopeId", "data-v-204347d4"]]);
4
+ const m = /* @__PURE__ */ t(o, [["__scopeId", "data-v-c743201c"]]);
5
5
  export {
6
- p as default
6
+ m as default
7
7
  };