@oneflowui/ui 0.5.5 → 0.5.7

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 (203) hide show
  1. package/dist/components/ContextMenu/index.vue.js +2 -2
  2. package/dist/components/Dashboard/charts/BarChart.vue.js +2 -2
  3. package/dist/components/Dashboard/charts/PieChart.vue.js +2 -2
  4. package/dist/components/Dashboard/index.vue.d.ts +2 -1
  5. package/dist/components/Dashboard/index.vue.js +2 -2
  6. package/dist/components/ai/AiSender.vue.js +2 -2
  7. package/dist/components/ai/AiSender.vue2.js +8 -7
  8. package/dist/components/auxiliary/ColorPanel.vue.js +2 -2
  9. package/dist/components/auxiliary/ColorPanel.vue2.js +25 -23
  10. package/dist/components/auxiliary/FileUpload.vue.js +2 -2
  11. package/dist/components/auxiliary/FileUpload.vue2.js +1 -0
  12. package/dist/components/auxiliary/PersonPanel.vue.js +1 -1
  13. package/dist/components/auxiliary/PersonPanel.vue2.js +2 -1
  14. package/dist/components/base/Accordion.vue.js +1 -1
  15. package/dist/components/base/Avatar.vue.d.ts +3 -0
  16. package/dist/components/base/Avatar.vue.js +4 -4
  17. package/dist/components/base/Avatar.vue2.js +8 -8
  18. package/dist/components/base/Badge.vue.d.ts +2 -0
  19. package/dist/components/base/Badge.vue.js +2 -2
  20. package/dist/components/base/Badge.vue2.js +2 -2
  21. package/dist/components/base/ButtonGroup.vue.js +2 -2
  22. package/dist/components/base/ButtonGroup.vue2.js +2 -2
  23. package/dist/components/base/ChainItem.vue.d.ts +6 -0
  24. package/dist/components/base/ChainItem.vue.js +2 -2
  25. package/dist/components/base/ChainItem.vue2.js +17 -17
  26. package/dist/components/base/DropdownMenu.vue.js +2 -2
  27. package/dist/components/base/DropdownMenu.vue2.js +22 -20
  28. package/dist/components/base/EmptyState.vue.js +2 -2
  29. package/dist/components/base/EmptyState.vue2.js +2 -2
  30. package/dist/components/base/InfoCard.vue.d.ts +9 -0
  31. package/dist/components/base/InfoCard.vue.js +2 -2
  32. package/dist/components/base/InfoCard.vue2.js +65 -57
  33. package/dist/components/base/MonitorItem.vue.js +2 -2
  34. package/dist/components/base/MonitorItem.vue2.js +33 -25
  35. package/dist/components/base/PersonaCard.vue.d.ts +5 -0
  36. package/dist/components/base/PersonaCard.vue.js +3 -3
  37. package/dist/components/base/PersonaCard.vue2.js +56 -50
  38. package/dist/components/base/ProgressBar.vue.d.ts +1 -0
  39. package/dist/components/base/ProgressBar.vue.js +2 -2
  40. package/dist/components/base/ProgressBar.vue2.js +10 -10
  41. package/dist/components/base/RangeSlider.vue.d.ts +15 -0
  42. package/dist/components/base/RangeSlider.vue.js +1 -1
  43. package/dist/components/base/RangeSlider.vue2.js +22 -15
  44. package/dist/components/base/RefTag.vue.d.ts +4 -0
  45. package/dist/components/base/RefTag.vue.js +3 -3
  46. package/dist/components/base/RefTag.vue2.js +14 -14
  47. package/dist/components/base/SearchHighlight.vue.js +1 -1
  48. package/dist/components/base/SectionBlock.vue.js +2 -2
  49. package/dist/components/base/SectionBlock.vue2.js +54 -48
  50. package/dist/components/base/SelectBadge.vue.d.ts +5 -0
  51. package/dist/components/base/SelectBadge.vue.js +3 -3
  52. package/dist/components/base/SelectBadge.vue2.js +36 -28
  53. package/dist/components/base/StatisticCard.vue.js +1 -1
  54. package/dist/components/base/StatusIndicator.vue.js +2 -2
  55. package/dist/components/base/StatusIndicator.vue2.js +2 -2
  56. package/dist/components/base/StatusSummary.vue.js +2 -2
  57. package/dist/components/base/Stepper.vue.js +2 -2
  58. package/dist/components/base/Switch.vue.js +2 -2
  59. package/dist/components/base/ToolbarBtn.vue.js +2 -2
  60. package/dist/components/base/ViewModeGroup.vue.js +1 -1
  61. package/dist/components/base/ViewModeGroup.vue2.js +3 -3
  62. package/dist/components/base/ViewSwitcher.vue.js +1 -1
  63. package/dist/components/base/ViewSwitcher.vue2.js +3 -3
  64. package/dist/components/base/ViewTab.vue.js +1 -1
  65. package/dist/components/base/ViewTab.vue2.js +5 -6
  66. package/dist/components/breadcrumb/Breadcrumb.vue.js +2 -2
  67. package/dist/components/breadcrumb/BreadcrumbItem.vue.js +2 -2
  68. package/dist/components/detail/PropPanel.vue.js +2 -2
  69. package/dist/components/detail/PropPanel.vue2.js +34 -30
  70. package/dist/components/detail/PropRow.vue.d.ts +6 -0
  71. package/dist/components/detail/PropRow.vue.js +2 -2
  72. package/dist/components/detail/PropRow.vue2.js +24 -24
  73. package/dist/components/editor/BlockQuote.vue.d.ts +2 -1
  74. package/dist/components/editor/BlockQuote.vue.js +1 -1
  75. package/dist/components/editor/BlockQuote.vue2.js +43 -29
  76. package/dist/components/editor/ContentBlock.vue.d.ts +4 -2
  77. package/dist/components/editor/ContentBlock.vue.js +2 -2
  78. package/dist/components/editor/ContentBlock.vue2.js +54 -33
  79. package/dist/components/editor/RichTextEditor.vue.js +2 -2
  80. package/dist/components/editor/RichTextEditor.vue2.js +10 -14
  81. package/dist/components/field/FieldAttachment.vue.js +2 -2
  82. package/dist/components/field/FieldAttachment.vue2.js +30 -32
  83. package/dist/components/field/FieldAutoNumber.vue.js +2 -2
  84. package/dist/components/field/FieldCheckbox.vue.js +2 -2
  85. package/dist/components/field/FieldCheckbox.vue2.js +13 -11
  86. package/dist/components/field/FieldCreator.vue.js +2 -2
  87. package/dist/components/field/FieldCurrency.vue.js +2 -2
  88. package/dist/components/field/FieldCurrency.vue2.js +15 -14
  89. package/dist/components/field/FieldDate.vue.js +1 -1
  90. package/dist/components/field/FieldDate.vue2.js +14 -16
  91. package/dist/components/field/FieldDatetime.vue.js +1 -1
  92. package/dist/components/field/FieldDatetime.vue2.js +12 -11
  93. package/dist/components/field/FieldEmail.vue.js +2 -2
  94. package/dist/components/field/FieldEmail.vue2.js +14 -13
  95. package/dist/components/field/FieldMarkdownPreview.vue.js +2 -2
  96. package/dist/components/field/FieldMultiSelect.vue.d.ts +2 -2
  97. package/dist/components/field/FieldMultiSelect.vue.js +2 -2
  98. package/dist/components/field/FieldMultiSelect.vue2.js +80 -75
  99. package/dist/components/field/FieldNumber.vue.js +3 -3
  100. package/dist/components/field/FieldNumber.vue2.js +19 -18
  101. package/dist/components/field/FieldPhone.vue.js +2 -2
  102. package/dist/components/field/FieldPhone.vue2.js +12 -11
  103. package/dist/components/field/FieldProgress.vue.js +1 -1
  104. package/dist/components/field/FieldProgress.vue2.js +18 -17
  105. package/dist/components/field/FieldRating.vue.js +2 -2
  106. package/dist/components/field/FieldRating.vue2.js +22 -16
  107. package/dist/components/field/FieldRelation.vue.js +1 -1
  108. package/dist/components/field/FieldRelation.vue2.js +25 -22
  109. package/dist/components/field/FieldRichText.vue.js +1 -1
  110. package/dist/components/field/FieldRichText.vue2.js +10 -7
  111. package/dist/components/field/FieldSelect.vue.js +2 -2
  112. package/dist/components/field/FieldSelect.vue2.js +81 -63
  113. package/dist/components/field/FieldText.vue.js +2 -2
  114. package/dist/components/field/FieldText.vue2.js +17 -16
  115. package/dist/components/field/FieldUrl.vue.js +2 -2
  116. package/dist/components/field/FieldUrl.vue2.js +17 -16
  117. package/dist/components/form/FormDesigner.vue.js +2 -2
  118. package/dist/components/form/FormDesigner.vue2.js +83 -78
  119. package/dist/components/gallery/GalleryCard.vue.d.ts +1 -1
  120. package/dist/components/gallery/GalleryCard.vue.js +2 -2
  121. package/dist/components/gallery/GalleryCard.vue2.js +2 -1
  122. package/dist/components/kanban/KanbanCard.vue.d.ts +3 -1
  123. package/dist/components/kanban/KanbanCard.vue.js +1 -1
  124. package/dist/components/kanban/KanbanCard.vue2.js +15 -14
  125. package/dist/components/kanban/KanbanColumn.vue.d.ts +2 -0
  126. package/dist/components/kanban/KanbanColumn.vue.js +2 -2
  127. package/dist/components/kanban/KanbanColumn.vue2.js +9 -9
  128. package/dist/components/kanban/QuickAddRow.vue.js +2 -2
  129. package/dist/components/kanban/QuickAddRow.vue2.js +15 -14
  130. package/dist/components/layout/Navbar.vue.js +3 -3
  131. package/dist/components/layout/Navbar.vue2.js +5 -4
  132. package/dist/components/layout/Sidebar.vue.js +2 -2
  133. package/dist/components/layout/Sidebar.vue2.js +1 -1
  134. package/dist/components/mermaid/MermaidChart.vue.js +2 -2
  135. package/dist/components/mermaid/MermaidChart.vue2.js +17 -17
  136. package/dist/components/overlay/Dialog.vue.d.ts +1 -0
  137. package/dist/components/overlay/Dialog.vue.js +1 -1
  138. package/dist/components/overlay/Dialog.vue2.js +9 -9
  139. package/dist/components/overlay/Drawer.vue.d.ts +1 -0
  140. package/dist/components/overlay/Drawer.vue.js +2 -2
  141. package/dist/components/overlay/Drawer.vue2.js +35 -29
  142. package/dist/components/overlay/Modal.vue.d.ts +1 -0
  143. package/dist/components/overlay/Modal.vue.js +1 -1
  144. package/dist/components/overlay/Modal.vue2.js +34 -28
  145. package/dist/components/overlay/SidePanel.vue.d.ts +1 -0
  146. package/dist/components/overlay/SidePanel.vue.js +1 -1
  147. package/dist/components/overlay/SidePanel.vue2.js +6 -6
  148. package/dist/components/split/SplitPane.vue.js +2 -2
  149. package/dist/components/split/SplitPane.vue2.js +11 -9
  150. package/dist/components/table/ColumnHeaderMenu.vue.d.ts +2 -0
  151. package/dist/components/table/ColumnHeaderMenu.vue.js +1 -1
  152. package/dist/components/table/ColumnHeaderMenu.vue2.js +42 -36
  153. package/dist/components/table/DataTable.vue.d.ts +12 -5
  154. package/dist/components/table/DataTable.vue.js +4 -4
  155. package/dist/components/table/DataTable.vue2.js +535 -477
  156. package/dist/components/table/DetailSheet.vue.js +2 -2
  157. package/dist/components/table/DetailSheet.vue2.js +45 -40
  158. package/dist/components/table/FieldCell.vue.d.ts +2 -1
  159. package/dist/components/table/FieldCell.vue.js +1 -1
  160. package/dist/components/table/FieldCell.vue2.js +57 -48
  161. package/dist/components/table/FieldTypePicker.vue.d.ts +1 -0
  162. package/dist/components/table/FieldTypePicker.vue.js +4 -4
  163. package/dist/components/table/FieldTypePicker.vue2.js +1 -1
  164. package/dist/components/table/MobileListView.vue.d.ts +26 -3
  165. package/dist/components/table/MobileListView.vue.js +2 -2
  166. package/dist/components/table/MobileListView.vue2.js +65 -49
  167. package/dist/components/table/TableColumnManager.vue.js +1 -1
  168. package/dist/components/table/TableColumnManager.vue2.js +29 -28
  169. package/dist/components/table/TableDataRow.vue.d.ts +2 -0
  170. package/dist/components/table/TableDataRow.vue.js +4 -4
  171. package/dist/components/table/TableDataRow.vue2.js +70 -58
  172. package/dist/components/table/TableFilterPanel.vue.js +2 -2
  173. package/dist/components/table/TableFilterPanel.vue2.js +3 -0
  174. package/dist/components/table/TableGroupRow.vue.d.ts +2 -0
  175. package/dist/components/table/TableGroupRow.vue.js +2 -2
  176. package/dist/components/table/TableGroupRow.vue2.js +35 -30
  177. package/dist/components/table/TableHeaderRow.vue.js +3 -3
  178. package/dist/components/table/TableHeaderRow.vue2.js +63 -46
  179. package/dist/components/table/TableToolbar.vue.js +1 -1
  180. package/dist/components/table/TableToolbar.vue2.js +2 -2
  181. package/dist/components/tabs/TabPanel.vue.js +4 -4
  182. package/dist/components/tabs/TabPanel.vue2.js +1 -1
  183. package/dist/components/tabs/Tabs.vue.js +2 -2
  184. package/dist/components/tabs/Tabs.vue2.js +2 -2
  185. package/dist/components/timeline/GanttRow.vue.d.ts +2 -0
  186. package/dist/components/timeline/GanttRow.vue.js +2 -2
  187. package/dist/components/timeline/GanttRow.vue2.js +68 -52
  188. package/dist/components/timeline/GanttTimeline.vue.d.ts +6 -0
  189. package/dist/components/timeline/GanttTimeline.vue.js +2 -2
  190. package/dist/components/timeline/GanttTimeline.vue2.js +24 -24
  191. package/dist/composables/useKeyboardNavigation.d.ts +1 -1
  192. package/dist/composables/useRowDrag.d.ts +6 -4
  193. package/dist/composables/useRowDrag.js +24 -24
  194. package/dist/composables/useSupabaseProvider.d.ts +8 -1
  195. package/dist/composables/useTableData.d.ts +5 -3
  196. package/dist/composables/useTableGroup.d.ts +2 -2
  197. package/dist/composables/useViewPersistence.d.ts +32 -3
  198. package/dist/composables/useVirtualList.js +60 -59
  199. package/dist/plugin.js +103 -102
  200. package/dist/style.css +1 -1
  201. package/dist/utils/echarts.d.ts +1 -0
  202. package/dist/utils/supabaseSchema.d.ts +12 -0
  203. package/package.json +1 -1
@@ -35,10 +35,19 @@ declare const __VLS_component: import('vue').DefineComponent<InfoCardProps, {},
35
35
  }, string, import('vue').PublicProps, Readonly<InfoCardProps> & Readonly<{
36
36
  onClick?: ((e: MouseEvent) => any) | undefined;
37
37
  }>, {
38
+ date: string;
39
+ tags: string[];
40
+ type: string;
41
+ meta: string;
42
+ borderColor: string;
38
43
  variant: "memo" | "notify" | "history";
44
+ content: string;
39
45
  contentLines: number;
40
46
  importance: "normal" | "high";
47
+ author: string;
41
48
  unread: boolean;
49
+ subtitle: string;
50
+ typeColor: string;
42
51
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
43
52
  declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
44
53
  export default _default;
@@ -1,7 +1,7 @@
1
1
  import o from "./InfoCard.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-79431801"]]);
4
+ const e = /* @__PURE__ */ r(o, [["__scopeId", "data-v-e865ef8d"]]);
5
5
  export {
6
- m as default
6
+ e as default
7
7
  };
@@ -1,61 +1,61 @@
1
- import { defineComponent as S, useCssVars as E, computed as b, openBlock as t, createElementBlock as r, mergeProps as L, Fragment as f, renderSlot as s, createCommentVNode as n, createElementVNode as c, toDisplayString as i, normalizeStyle as u, renderList as B } from "vue";
1
+ import { defineComponent as E, useCssVars as L, computed as b, openBlock as t, createElementBlock as r, mergeProps as w, Fragment as f, renderSlot as c, createCommentVNode as n, createElementVNode as d, toDisplayString as i, normalizeStyle as u, renderList as B } from "vue";
2
2
  const P = {
3
3
  key: 0,
4
4
  class: "of-info-card__icon-area"
5
- }, A = { class: "of-info-card__body" }, T = { class: "of-info-card__title" }, V = { class: "of-info-card__footer" }, I = {
5
+ }, A = { class: "of-info-card__body" }, T = { class: "of-info-card__title" }, V = { class: "of-info-card__footer" }, D = {
6
6
  key: 1,
7
7
  class: "of-info-card__meta-text"
8
- }, N = {
8
+ }, I = {
9
9
  key: 2,
10
10
  class: "of-info-card__meta-text"
11
- }, O = { class: "of-info-card__body" }, w = { class: "of-info-card__title" }, z = {
11
+ }, K = { class: "of-info-card__body" }, M = { class: "of-info-card__title" }, N = {
12
12
  key: 1,
13
13
  class: "of-info-card__notify-meta"
14
- }, D = {
14
+ }, O = {
15
15
  key: 0,
16
16
  class: "of-info-card__actions"
17
- }, F = {
17
+ }, z = {
18
18
  key: 0,
19
19
  class: "of-info-card__icon-area"
20
- }, M = { class: "of-info-card__body" }, R = { class: "of-info-card__title" }, Y = {
20
+ }, F = { class: "of-info-card__body" }, R = { class: "of-info-card__title" }, Y = {
21
21
  key: 0,
22
22
  class: "of-info-card__subtitle"
23
23
  }, j = {
24
24
  key: 1,
25
25
  class: "of-info-card__actions"
26
- }, G = /* @__PURE__ */ S({
26
+ }, G = /* @__PURE__ */ E({
27
27
  name: "InfoCard",
28
28
  inheritAttrs: !1,
29
29
  __name: "InfoCard",
30
30
  props: {
31
31
  variant: { default: "memo" },
32
32
  title: {},
33
- content: {},
33
+ content: { default: void 0 },
34
34
  contentLines: { default: 3 },
35
- borderColor: {},
36
- tags: {},
35
+ borderColor: { default: void 0 },
36
+ tags: { default: void 0 },
37
37
  importance: { default: "normal" },
38
- author: {},
39
- date: {},
38
+ author: { default: void 0 },
39
+ date: { default: void 0 },
40
40
  unread: { type: Boolean, default: !1 },
41
- meta: {},
42
- subtitle: {},
43
- type: {},
44
- typeColor: {}
41
+ meta: { default: void 0 },
42
+ subtitle: { default: void 0 },
43
+ type: { default: void 0 },
44
+ typeColor: { default: void 0 }
45
45
  },
46
46
  emits: ["click"],
47
- setup(o, { emit: y }) {
48
- E((e) => ({
49
- v4daa9b0a: e.unread ? "var(--of-color-warning-light)" : "var(--of-color-bg-elevated)"
47
+ setup(o, { emit: m }) {
48
+ L((e) => ({
49
+ e6754980: e.unread ? "var(--of-color-warning-light)" : "var(--of-color-bg-elevated)"
50
50
  }));
51
- const a = o, m = y, g = {
51
+ const a = o, h = m, g = {
52
52
  模板: "var(--of-color-primary-500)",
53
53
  template: "var(--of-color-primary-500)",
54
54
  会话: "var(--of-color-success)",
55
55
  session: "var(--of-color-success)"
56
- }, h = b(() => a.variant === "memo" ? a.importance === "high" ? "var(--of-color-error)" : a.borderColor ?? "var(--of-color-info)" : a.variant === "history" ? a.typeColor ? a.typeColor : a.type && g[a.type] ? g[a.type] : a.borderColor ?? "var(--of-color-primary-500)" : "transparent"), k = b(() => {
56
+ }, k = b(() => a.variant === "memo" ? a.importance === "high" ? "var(--of-color-error)" : a.borderColor ?? "var(--of-color-info)" : a.variant === "history" ? a.typeColor ? a.typeColor : a.type && g[a.type] ? g[a.type] : a.borderColor ?? "var(--of-color-primary-500)" : "transparent"), _ = b(() => {
57
57
  const e = {
58
- "--of-ic-border": h.value
58
+ "--of-ic-border": k.value
59
59
  };
60
60
  return a.variant === "notify" && (e["--of-ic-unread-dot"] = a.unread ? "var(--of-color-info)" : "var(--of-color-text-tertiary)"), e;
61
61
  }), v = b(
@@ -63,7 +63,7 @@ const P = {
63
63
  "--of-ic-clamp": String(a.contentLines ?? 3)
64
64
  })
65
65
  );
66
- function _(e) {
66
+ function C(e) {
67
67
  const l = [
68
68
  {
69
69
  bg: "var(--of-badge-blue-bg)",
@@ -90,73 +90,81 @@ const P = {
90
90
  color: "var(--of-badge-gray-text)",
91
91
  border: "var(--of-badge-gray-border)"
92
92
  }
93
- ], d = l[e % l.length];
93
+ ], s = l[e % l.length];
94
94
  return {
95
- "--of-ic-tag-bg": d.bg,
96
- "--of-ic-tag-color": d.color,
97
- "--of-ic-tag-border": d.border
95
+ "--of-ic-tag-bg": s.bg,
96
+ "--of-ic-tag-color": s.color,
97
+ "--of-ic-tag-border": s.border
98
98
  };
99
99
  }
100
- function C(e) {
101
- m("click", e);
100
+ function y(e) {
101
+ h("click", e);
102
+ }
103
+ function $(e) {
104
+ e.key !== "Enter" && e.key !== " " || (e.preventDefault(), y(new MouseEvent("click")));
102
105
  }
103
- return (e, l) => (t(), r("div", L({
106
+ return (e, l) => (t(), r("div", w({
104
107
  class: ["of-info-card", `of-info-card--${o.variant}`],
105
- style: k.value
106
- }, e.$attrs, { onClick: C }), [
108
+ style: _.value,
109
+ role: "button",
110
+ tabindex: "0"
111
+ }, e.$attrs, {
112
+ onClick: y,
113
+ onKeydown: $
114
+ }), [
107
115
  o.variant === "memo" ? (t(), r(f, { key: 0 }, [
108
116
  e.$slots.icon ? (t(), r("div", P, [
109
- s(e.$slots, "icon", {}, void 0, !0)
117
+ c(e.$slots, "icon", {}, void 0, !0)
110
118
  ])) : n("", !0),
111
- c("div", A, [
112
- c("div", T, i(o.title), 1),
119
+ d("div", A, [
120
+ d("div", T, i(o.title), 1),
113
121
  o.content ? (t(), r("div", {
114
122
  key: 0,
115
123
  class: "of-info-card__content of-info-card__content--clamp",
116
124
  style: u(v.value)
117
125
  }, i(o.content), 5)) : n("", !0),
118
- c("div", V, [
119
- o.tags && o.tags.length ? (t(!0), r(f, { key: 0 }, B(o.tags, (d, $) => (t(), r("span", {
120
- key: d,
126
+ d("div", V, [
127
+ o.tags && o.tags.length ? (t(!0), r(f, { key: 0 }, B(o.tags, (s, S) => (t(), r("span", {
128
+ key: s,
121
129
  class: "of-info-card__tag",
122
- style: u(_($))
123
- }, i(d), 5))), 128)) : n("", !0),
124
- o.author ? (t(), r("span", I, i(o.author), 1)) : n("", !0),
125
- o.date ? (t(), r("span", N, i(o.date), 1)) : n("", !0),
126
- s(e.$slots, "footer", {}, void 0, !0)
130
+ style: u(C(S))
131
+ }, i(s), 5))), 128)) : n("", !0),
132
+ o.author ? (t(), r("span", D, i(o.author), 1)) : n("", !0),
133
+ o.date ? (t(), r("span", I, i(o.date), 1)) : n("", !0),
134
+ c(e.$slots, "footer", {}, void 0, !0)
127
135
  ])
128
136
  ])
129
137
  ], 64)) : o.variant === "notify" ? (t(), r(f, { key: 1 }, [
130
- l[0] || (l[0] = c("span", { class: "of-info-card__dot" }, null, -1)),
131
- c("div", O, [
132
- c("div", w, i(o.title), 1),
138
+ l[0] || (l[0] = d("span", { class: "of-info-card__dot" }, null, -1)),
139
+ d("div", K, [
140
+ d("div", M, i(o.title), 1),
133
141
  o.content ? (t(), r("div", {
134
142
  key: 0,
135
143
  class: "of-info-card__content of-info-card__content--clamp",
136
144
  style: u(v.value)
137
145
  }, i(o.content), 5)) : n("", !0),
138
- o.meta ? (t(), r("div", z, i(o.meta), 1)) : n("", !0),
139
- s(e.$slots, "footer", {}, void 0, !0)
146
+ o.meta ? (t(), r("div", N, i(o.meta), 1)) : n("", !0),
147
+ c(e.$slots, "footer", {}, void 0, !0)
140
148
  ]),
141
- e.$slots.actions ? (t(), r("div", D, [
142
- s(e.$slots, "actions", {}, void 0, !0)
149
+ e.$slots.actions ? (t(), r("div", O, [
150
+ c(e.$slots, "actions", {}, void 0, !0)
143
151
  ])) : n("", !0)
144
152
  ], 64)) : o.variant === "history" ? (t(), r(f, { key: 2 }, [
145
- e.$slots.icon ? (t(), r("div", F, [
146
- s(e.$slots, "icon", {}, void 0, !0)
153
+ e.$slots.icon ? (t(), r("div", z, [
154
+ c(e.$slots, "icon", {}, void 0, !0)
147
155
  ])) : n("", !0),
148
- c("div", M, [
149
- c("div", R, i(o.title), 1),
156
+ d("div", F, [
157
+ d("div", R, i(o.title), 1),
150
158
  o.subtitle ? (t(), r("div", Y, i(o.subtitle), 1)) : n("", !0),
151
159
  o.content ? (t(), r("div", {
152
160
  key: 1,
153
161
  class: "of-info-card__content of-info-card__content--clamp",
154
162
  style: u(v.value)
155
163
  }, i(o.content), 5)) : n("", !0),
156
- s(e.$slots, "footer", {}, void 0, !0)
164
+ c(e.$slots, "footer", {}, void 0, !0)
157
165
  ]),
158
166
  e.$slots.actions ? (t(), r("div", j, [
159
- s(e.$slots, "actions", {}, void 0, !0)
167
+ c(e.$slots, "actions", {}, void 0, !0)
160
168
  ])) : n("", !0)
161
169
  ], 64)) : n("", !0)
162
170
  ], 16));
@@ -1,7 +1,7 @@
1
1
  import o from "./MonitorItem.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-ce396706"]]);
4
+ const _ = /* @__PURE__ */ t(o, [["__scopeId", "data-v-264421cd"]]);
5
5
  export {
6
- p as default
6
+ _ as default
7
7
  };
@@ -1,11 +1,11 @@
1
- import { defineComponent as b, computed as o, openBlock as a, createElementBlock as n, mergeProps as h, toDisplayString as l, createCommentVNode as s, createElementVNode as e, normalizeStyle as r } from "vue";
2
- const y = {
1
+ import { defineComponent as y, computed as o, openBlock as a, createElementBlock as s, mergeProps as p, withKeys as r, withModifiers as m, toDisplayString as i, createCommentVNode as d, createElementVNode as t, normalizeStyle as u } from "vue";
2
+ const g = ["onKeydown"], C = {
3
3
  key: 0,
4
4
  class: "of-monitor-item__subtitle"
5
- }, g = { class: "of-monitor-item__label" }, p = { class: "of-monitor-item__progress" }, C = { class: "of-monitor-item__percentage" }, M = {
5
+ }, w = { class: "of-monitor-item__label" }, M = { class: "of-monitor-item__progress" }, S = { class: "of-monitor-item__percentage" }, x = {
6
6
  key: 1,
7
7
  class: "of-monitor-item__count"
8
- }, V = /* @__PURE__ */ b({
8
+ }, V = /* @__PURE__ */ y({
9
9
  name: "MonitorItem",
10
10
  inheritAttrs: !1,
11
11
  __name: "MonitorItem",
@@ -18,37 +18,45 @@ const y = {
18
18
  clickable: { type: Boolean, default: !1 }
19
19
  },
20
20
  emits: ["click"],
21
- setup(t, { emit: m }) {
22
- const i = t, u = m, c = o(() => Math.min(100, Math.max(0, i.value))), d = o(
23
- () => c.value === 100 ? "var(--of-color-success)" : i.color ?? "var(--of-color-primary-500)"
24
- ), f = o(() => ({
21
+ setup(e, { emit: f }) {
22
+ const l = e, v = f, c = o(() => Math.min(100, Math.max(0, l.value))), _ = o(
23
+ () => c.value === 100 ? "var(--of-color-success)" : l.color ?? "var(--of-color-primary-500)"
24
+ ), k = o(() => ({
25
25
  backgroundColor: "var(--of-color-gray-100)"
26
- })), v = o(() => ({
26
+ })), b = o(() => ({
27
27
  width: `${c.value}%`,
28
- background: d.value
28
+ background: _.value
29
29
  }));
30
- function _() {
31
- i.clickable && u("click");
30
+ function n() {
31
+ l.clickable && v("click");
32
32
  }
33
- return (k, S) => (a(), n("div", h({
34
- class: ["of-monitor-item", { "of-monitor-item--clickable": t.clickable }]
35
- }, k.$attrs, { onClick: _ }), [
36
- t.subtitle !== void 0 ? (a(), n("div", y, l(t.subtitle), 1)) : s("", !0),
37
- e("div", g, l(t.label), 1),
38
- e("div", p, [
39
- e("div", {
33
+ return (h, B) => (a(), s("div", p({
34
+ class: ["of-monitor-item", { "of-monitor-item--clickable": e.clickable }],
35
+ role: "button",
36
+ tabindex: "0"
37
+ }, h.$attrs, {
38
+ onClick: n,
39
+ onKeydown: [
40
+ r(m(n, ["prevent"]), ["enter"]),
41
+ r(m(n, ["prevent"]), ["space"])
42
+ ]
43
+ }), [
44
+ e.subtitle !== void 0 ? (a(), s("div", C, i(e.subtitle), 1)) : d("", !0),
45
+ t("div", w, i(e.label), 1),
46
+ t("div", M, [
47
+ t("div", {
40
48
  class: "of-monitor-item__track",
41
- style: r(f.value)
49
+ style: u(k.value)
42
50
  }, [
43
- e("div", {
51
+ t("div", {
44
52
  class: "of-monitor-item__fill",
45
- style: r(v.value)
53
+ style: u(b.value)
46
54
  }, null, 4)
47
55
  ], 4)
48
56
  ]),
49
- e("div", C, l(c.value) + "%", 1),
50
- t.count !== void 0 ? (a(), n("div", M, l(t.count), 1)) : s("", !0)
51
- ], 16));
57
+ t("div", S, i(c.value) + "%", 1),
58
+ e.count !== void 0 ? (a(), s("div", x, i(e.count), 1)) : d("", !0)
59
+ ], 16, g));
52
60
  }
53
61
  });
54
62
  export {
@@ -30,10 +30,15 @@ declare const __VLS_component: import('vue').DefineComponent<PersonaCardProps, {
30
30
  onClick?: (() => any) | undefined;
31
31
  "onUpdate:expanded"?: ((value: boolean) => any) | undefined;
32
32
  }>, {
33
+ title: string;
34
+ tags: string[];
33
35
  done: boolean;
34
36
  size: "sm" | "md";
37
+ color: string;
38
+ icon: string | Component;
35
39
  active: boolean;
36
40
  disabled: boolean;
41
+ subtitle: string;
37
42
  expanded: boolean;
38
43
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
39
44
  declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
@@ -1,7 +1,7 @@
1
1
  import o from "./PersonaCard.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-0c8a7d5a"]]);
3
+ import r from "../../_virtual/_plugin-vue_export-helper.js";
4
+ const m = /* @__PURE__ */ r(o, [["__scopeId", "data-v-b283c2cd"]]);
5
5
  export {
6
- p as default
6
+ m as default
7
7
  };
@@ -1,9 +1,9 @@
1
- import { defineComponent as w, computed as r, openBlock as t, createElementBlock as n, mergeProps as A, createElementVNode as c, normalizeStyle as f, createBlock as E, resolveDynamicComponent as F, Fragment as y, createTextVNode as N, toDisplayString as l, renderSlot as b, createCommentVNode as i, renderList as T } from "vue";
1
+ import { defineComponent as P, computed as r, openBlock as t, createElementBlock as n, mergeProps as A, createElementVNode as c, normalizeStyle as g, createBlock as F, resolveDynamicComponent as D, Fragment as _, createTextVNode as N, toDisplayString as l, renderSlot as v, createCommentVNode as i, renderList as T } from "vue";
2
2
  import { resolveIcon as V } from "../../utils/icon.js";
3
- const D = { class: "of-persona-card__body" }, I = { class: "of-persona-card__name-row" }, L = {
3
+ const H = { class: "of-persona-card__body" }, I = { class: "of-persona-card__name-row" }, K = {
4
4
  key: 0,
5
5
  class: "of-persona-card__title-badge"
6
- }, H = {
6
+ }, L = {
7
7
  key: 1,
8
8
  class: "of-persona-card__tags"
9
9
  }, M = { class: "of-persona-card__right" }, j = {
@@ -12,17 +12,17 @@ const D = { class: "of-persona-card__body" }, I = { class: "of-persona-card__nam
12
12
  }, q = { class: "of-persona-card__chevron" }, G = {
13
13
  key: 0,
14
14
  class: "of-persona-card__detail"
15
- }, O = /* @__PURE__ */ w({
15
+ }, Q = /* @__PURE__ */ P({
16
16
  name: "PersonaCard",
17
17
  inheritAttrs: !1,
18
18
  __name: "PersonaCard",
19
19
  props: {
20
20
  name: {},
21
- title: {},
22
- icon: {},
23
- color: {},
24
- subtitle: {},
25
- tags: {},
21
+ title: { default: void 0 },
22
+ icon: { default: void 0 },
23
+ color: { default: void 0 },
24
+ subtitle: { default: void 0 },
25
+ tags: { default: void 0 },
26
26
  expanded: { type: Boolean, default: !1 },
27
27
  active: { type: Boolean, default: !1 },
28
28
  done: { type: Boolean, default: !1 },
@@ -30,8 +30,8 @@ const D = { class: "of-persona-card__body" }, I = { class: "of-persona-card__nam
30
30
  size: { default: "md" }
31
31
  },
32
32
  emits: ["update:expanded", "click"],
33
- setup(o, { emit: _ }) {
34
- const e = o, v = _, u = [
33
+ setup(o, { emit: k }) {
34
+ const e = o, u = k, b = [
35
35
  {
36
36
  accent: "var(--of-color-warning)",
37
37
  bg: "var(--of-color-warning-light)",
@@ -81,13 +81,13 @@ const D = { class: "of-persona-card__body" }, I = { class: "of-persona-card__nam
81
81
  tagBg: "var(--of-badge-green-bg)"
82
82
  }
83
83
  ];
84
- function B(a) {
85
- let s = 0;
86
- for (let d = 0; d < a.length; d++)
87
- s = (s << 5) - s + a.charCodeAt(d), s |= 0;
88
- return Math.abs(s);
84
+ function x(a) {
85
+ let d = 0;
86
+ for (let s = 0; s < a.length; s++)
87
+ d = (d << 5) - d + a.charCodeAt(s), d |= 0;
88
+ return Math.abs(d);
89
89
  }
90
- const g = r(() => {
90
+ const f = r(() => {
91
91
  if (e.color) {
92
92
  const a = e.color.replace("#", "");
93
93
  return {
@@ -97,16 +97,16 @@ const D = { class: "of-persona-card__body" }, I = { class: "of-persona-card__nam
97
97
  tagBg: `#${a}1a`
98
98
  };
99
99
  }
100
- return u[B(e.name) % u.length];
101
- }), p = r(() => e.size === "sm" ? 24 : 32), m = r(() => e.size === "sm" ? 12 : 16), k = r(() => e.size === "sm" ? 12 : 13), x = r(() => e.size === "sm" ? 11 : 12), h = r(() => {
100
+ return b[x(e.name) % b.length];
101
+ }), p = r(() => e.size === "sm" ? 24 : 32), m = r(() => e.size === "sm" ? 12 : 16), B = r(() => e.size === "sm" ? 12 : 13), z = r(() => e.size === "sm" ? 11 : 12), h = r(() => {
102
102
  if (e.icon)
103
103
  return V(e.icon);
104
- }), z = r(() => {
104
+ }), S = r(() => {
105
105
  if (e.icon && typeof e.icon == "string") return e.icon;
106
106
  if (e.icon) return "";
107
107
  const a = e.name.trim();
108
108
  return a ? a.charAt(0) : "?";
109
- }), S = r(() => [
109
+ }), $ = r(() => [
110
110
  "of-persona-card",
111
111
  `of-persona-card--${e.size}`,
112
112
  {
@@ -115,71 +115,77 @@ const D = { class: "of-persona-card__body" }, I = { class: "of-persona-card__nam
115
115
  "of-persona-card--disabled": e.disabled,
116
116
  "of-persona-card--expanded": e.expanded
117
117
  }
118
- ]), $ = r(() => ({
119
- "--pc-accent": g.value.accent,
120
- "--pc-accent-bg": g.value.bg,
121
- "--pc-accent-border": g.value.border,
122
- "--pc-accent-tag-bg": g.value.tagBg
123
- })), C = r(() => ({
118
+ ]), C = r(() => ({
119
+ "--pc-accent": f.value.accent,
120
+ "--pc-accent-bg": f.value.bg,
121
+ "--pc-accent-border": f.value.border,
122
+ "--pc-accent-tag-bg": f.value.tagBg
123
+ })), w = r(() => ({
124
124
  width: `${p.value}px`,
125
125
  height: `${p.value}px`,
126
126
  fontSize: `${m.value}px`
127
127
  }));
128
- function P() {
129
- e.disabled || (v("update:expanded", !e.expanded), v("click"));
128
+ function y() {
129
+ e.disabled || (u("update:expanded", !e.expanded), u("click"));
130
130
  }
131
- return (a, s) => (t(), n("div", A({
132
- class: S.value,
133
- style: $.value
131
+ function E(a) {
132
+ a.key !== "Enter" && a.key !== " " || (a.preventDefault(), y());
133
+ }
134
+ return (a, d) => (t(), n("div", A({
135
+ class: $.value,
136
+ style: C.value
134
137
  }, a.$attrs), [
135
138
  c("div", {
136
139
  class: "of-persona-card__header",
137
- onClick: P
140
+ role: "button",
141
+ tabindex: "0",
142
+ onClick: y,
143
+ onKeydown: E
138
144
  }, [
139
145
  c("span", {
140
146
  class: "of-persona-card__avatar",
141
- style: f(C.value)
147
+ style: g(w.value)
142
148
  }, [
143
- h.value ? (t(), E(F(h.value), {
149
+ h.value ? (t(), F(D(h.value), {
144
150
  key: 0,
145
151
  size: m.value
146
- }, null, 8, ["size"])) : (t(), n(y, { key: 1 }, [
147
- N(l(z.value), 1)
152
+ }, null, 8, ["size"])) : (t(), n(_, { key: 1 }, [
153
+ N(l(S.value), 1)
148
154
  ], 64))
149
155
  ], 4),
150
- c("div", D, [
156
+ c("div", H, [
151
157
  c("div", I, [
152
158
  c("span", {
153
159
  class: "of-persona-card__name",
154
- style: f({ fontSize: `${k.value}px` })
160
+ style: g({ fontSize: `${B.value}px` })
155
161
  }, l(o.name), 5),
156
- b(a.$slots, "badge", {}, void 0, !0),
157
- o.title ? (t(), n("span", L, l(o.title), 1)) : i("", !0)
162
+ v(a.$slots, "badge", {}, void 0, !0),
163
+ o.title ? (t(), n("span", K, l(o.title), 1)) : i("", !0)
158
164
  ]),
159
165
  o.subtitle ? (t(), n("span", {
160
166
  key: 0,
161
167
  class: "of-persona-card__subtitle",
162
- style: f({ fontSize: `${x.value}px` })
168
+ style: g({ fontSize: `${z.value}px` })
163
169
  }, l(o.subtitle), 5)) : i("", !0),
164
- o.tags && o.tags.length > 0 ? (t(), n("div", H, [
165
- (t(!0), n(y, null, T(o.tags, (d) => (t(), n("span", {
166
- key: d,
170
+ o.tags && o.tags.length > 0 ? (t(), n("div", L, [
171
+ (t(!0), n(_, null, T(o.tags, (s) => (t(), n("span", {
172
+ key: s,
167
173
  class: "of-persona-card__tag"
168
- }, l(d), 1))), 128))
174
+ }, l(s), 1))), 128))
169
175
  ])) : i("", !0)
170
176
  ]),
171
177
  c("div", M, [
172
- b(a.$slots, "actions", {}, void 0, !0),
178
+ v(a.$slots, "actions", {}, void 0, !0),
173
179
  o.done ? (t(), n("span", j, "✓")) : i("", !0),
174
180
  c("span", q, l(o.expanded ? "▲" : "▼"), 1)
175
181
  ])
176
- ]),
182
+ ], 32),
177
183
  o.expanded ? (t(), n("div", G, [
178
- b(a.$slots, "default", {}, void 0, !0)
184
+ v(a.$slots, "default", {}, void 0, !0)
179
185
  ])) : i("", !0)
180
186
  ], 16));
181
187
  }
182
188
  });
183
189
  export {
184
- O as default
190
+ Q as default
185
191
  };
@@ -19,6 +19,7 @@ declare function __VLS_template(): {
19
19
  };
20
20
  type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
21
21
  declare const __VLS_component: import('vue').DefineComponent<ProgressBarProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<ProgressBarProps> & Readonly<{}>, {
22
+ color: string;
22
23
  height: number;
23
24
  bgColor: string;
24
25
  showLabel: boolean;
@@ -1,7 +1,7 @@
1
1
  import o from "./ProgressBar.vue2.js";
2
2
  /* empty css */
3
3
  import r from "../../_virtual/_plugin-vue_export-helper.js";
4
- const e = /* @__PURE__ */ r(o, [["__scopeId", "data-v-1aeb6aa3"]]);
4
+ const m = /* @__PURE__ */ r(o, [["__scopeId", "data-v-893c13d7"]]);
5
5
  export {
6
- e as default
6
+ m as default
7
7
  };
@@ -1,4 +1,4 @@
1
- import { defineComponent as p, computed as r, openBlock as t, createElementBlock as c, mergeProps as f, createElementVNode as a, normalizeStyle as d, normalizeClass as b, renderSlot as v, toDisplayString as m, createCommentVNode as _ } from "vue";
1
+ import { defineComponent as p, computed as r, openBlock as t, createElementBlock as d, mergeProps as f, createElementVNode as a, normalizeStyle as c, normalizeClass as v, renderSlot as b, toDisplayString as m, createCommentVNode as _ } from "vue";
2
2
  const g = {
3
3
  key: 0,
4
4
  class: "of-progress-bar__label"
@@ -8,7 +8,7 @@ const g = {
8
8
  props: {
9
9
  value: {},
10
10
  height: { default: 4 },
11
- color: {},
11
+ color: { default: void 0 },
12
12
  bgColor: { default: "var(--of-color-gray-100)" },
13
13
  showLabel: { type: Boolean, default: !1 },
14
14
  borderRadius: { default: 2 }
@@ -16,28 +16,28 @@ const g = {
16
16
  setup(s) {
17
17
  const e = s, o = r(() => Math.min(100, Math.max(0, e.value))), u = r(
18
18
  () => o.value === 100 ? "var(--of-color-success)" : e.color ?? "var(--of-color-primary-500)"
19
- ), n = r(() => ({
19
+ ), i = r(() => ({
20
20
  height: `${e.height}px`,
21
21
  backgroundColor: e.bgColor,
22
22
  borderRadius: `${e.borderRadius}px`
23
- })), i = r(() => ({
23
+ })), n = r(() => ({
24
24
  width: `${o.value}%`,
25
25
  background: u.value,
26
26
  borderRadius: `${e.borderRadius}px`
27
27
  }));
28
- return (l, k) => (t(), c("div", f({ class: "of-progress-bar" }, l.$attrs), [
28
+ return (l, k) => (t(), d("div", f({ class: "of-progress-bar" }, l.$attrs), [
29
29
  a("div", {
30
30
  class: "of-progress-bar__track pb",
31
- style: d(n.value)
31
+ style: c(i.value)
32
32
  }, [
33
33
  a("div", {
34
- class: b(["of-progress-bar__fill pf", { dn: o.value === 100 }]),
35
- style: d(i.value)
34
+ class: v(["of-progress-bar__fill pf", { dn: o.value === 100 }]),
35
+ style: c(n.value)
36
36
  }, null, 6)
37
37
  ], 4),
38
- s.showLabel ? (t(), c("div", g, [
38
+ s.showLabel ? (t(), d("div", g, [
39
39
  a("div", h, [
40
- v(l.$slots, "default", {}, void 0, !0)
40
+ b(l.$slots, "default", {}, void 0, !0)
41
41
  ]),
42
42
  a("span", y, m(o.value) + "%", 1)
43
43
  ])) : _("", !0)
@@ -1,3 +1,18 @@
1
+ /**
2
+ * RangeSlider 组件 - 范围滑块输入
3
+ *
4
+ * 用于快速创建 label + range input + description 三件套
5
+ *
6
+ * @example
7
+ * <RangeSlider
8
+ * label="最大长度"
9
+ * v-model="maxLength"
10
+ * :min="100"
11
+ * :max="2000"
12
+ * :step="100"
13
+ * description="调整文本长度限制"
14
+ * />
15
+ */
1
16
  type __VLS_Props = {
2
17
  label: string;
3
18
  modelValue: number;