agilebuilder-ui 1.1.65-tmp26 → 1.1.65-tmp28

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (151) hide show
  1. package/dist/index.full.min.js +1381 -1349
  2. package/dist/style.css +42 -22
  3. package/es/IntervalSelection/src/sectionDate.vue.mjs +8 -8
  4. package/es/chat-embed/src/chat-addition-data.vue2.mjs +14 -11
  5. package/es/chat-embed/src/chat-ai-answer-tip.vue2.mjs +8 -8
  6. package/es/chat-embed/src/chat-bubble-footer.vue2.mjs +5 -5
  7. package/es/chat-embed/src/chat-sender.vue2.mjs +41 -41
  8. package/es/chat-embed/src/components/answer-auto-chart.vue2.mjs +1 -2
  9. package/es/chat-embed/src/components/answer-interaction-data.vue2.mjs +6 -7
  10. package/es/chat-embed/src/components/history-detail.vue2.mjs +18 -18
  11. package/es/chat-embed/src/header.vue2.mjs +16 -16
  12. package/es/chat-embed/src/index.vue2.mjs +161 -161
  13. package/es/chat-embed/src/recommendation-message.vue2.mjs +9 -6
  14. package/es/chat-embed/src/sidebar-item.vue2.mjs +65 -65
  15. package/es/chat-embed/src/voice/voice.vue.mjs +36 -35
  16. package/es/date-picker-range/index.vue2.mjs +39 -39
  17. package/es/department-tree-mobile/src/department-tree-app.vue.mjs +8 -7
  18. package/es/department-tree-mobile/src/department-tree-inline-app.vue.mjs +54 -54
  19. package/es/department-tree-mobile/src/dept-path.vue.mjs +7 -6
  20. package/es/department-tree-mobile/src/dept-result.vue.mjs +7 -6
  21. package/es/department-user-tree-inline/src/department-user-multiple-tree-inline.vue.mjs +5 -5
  22. package/es/department-user-tree-mobile/src/department-user-tree-app.vue.mjs +10 -9
  23. package/es/department-user-tree-mobile/src/department-user-tree-inline-app.vue.mjs +64 -64
  24. package/es/department-user-tree-mobile/src/dept-path.vue.mjs +7 -6
  25. package/es/department-user-tree-mobile/src/dept-result.vue.mjs +4 -3
  26. package/es/empty-state/index.vue.mjs +2 -2
  27. package/es/fs-upload/src/fs-upload-multi.vue.mjs +1 -1
  28. package/es/fs-upload-list/src/fs-upload-list.vue.mjs +1 -1
  29. package/es/fs-upload-new/src/file-upload-mobile/file-upload-app.vue.mjs +12 -12
  30. package/es/fs-upload-new/src/file-upload-mobile/file-upload-browser.vue.mjs +24 -24
  31. package/es/fs-upload-new/src/file-upload-mobile/file-upload-component.vue2.mjs +17 -17
  32. package/es/fs-upload-new/src/file-upload-mobile/file-upload.vue.mjs +12 -12
  33. package/es/fs-upload-new/src/fs-button-upload.vue2.mjs +23 -23
  34. package/es/fs-upload-new/src/fs-drag-upload.vue2.mjs +23 -23
  35. package/es/fs-upload-new/src/fs-preview-new.vue2.mjs +34 -34
  36. package/es/fs-upload-new/src/fs-upload-new.vue.mjs +15 -15
  37. package/es/json-view/json-view-dialog.vue.mjs +5 -5
  38. package/es/multipart-upload/src/multipart-upload-form.vue.mjs +1 -1
  39. package/es/multipart-upload/src/multipart-upload-list.vue.mjs +5 -5
  40. package/es/row-form/index.vue2.mjs +31 -31
  41. package/es/row-form/operation.vue.mjs +13 -13
  42. package/es/secret-info/index.vue.mjs +1 -1
  43. package/es/src/components/Affix/index.vue2.mjs +26 -26
  44. package/es/src/components/Scrollbar/index.vue.mjs +22 -22
  45. package/es/src/views/error-page/401.vue.mjs +8 -8
  46. package/es/src/views/error-page/404.vue.mjs +8 -8
  47. package/es/src/views/layout/components/Menubar/Item.vue.mjs +1 -1
  48. package/es/src/views/layout/components/Menubar/Item.vue2.mjs +2 -2
  49. package/es/src/views/super-icon/index.mjs +7 -0
  50. package/es/src/views/super-icon/src/index.vue.mjs +7 -0
  51. package/es/src/views/super-icon/src/index.vue2.mjs +13 -0
  52. package/es/src/views/super-icon/src/index.vue3.mjs +4 -0
  53. package/es/src/views/svg-icon/src/svg-icon.vue2.mjs +14 -0
  54. package/es/style.css +907 -887
  55. package/es/super-grid/src/columns-config.vue.mjs +1 -1
  56. package/es/super-grid/src/components/grid-radio-input.vue.mjs +5 -5
  57. package/es/super-grid/src/components/select-input.vue.mjs +55 -55
  58. package/es/super-grid/src/row-detail.vue.mjs +1 -1
  59. package/es/super-grid/src/search-form-advancedQuery.vue.mjs +1 -1
  60. package/es/super-grid/src/search-form-number.vue.mjs +4 -5
  61. package/es/super-grid/src/super-grid.vue.mjs +1 -1
  62. package/es/super-nine-grid/src/search-form-number.vue.mjs +4 -5
  63. package/es/super-nine-grid/src/search-form.vue.mjs +1 -1
  64. package/es/super-nine-grid/src/super-nine-grid.vue.mjs +1 -1
  65. package/es/workgroup-tree-inline/src/workgroup-tree-inline.vue.mjs +8 -8
  66. package/es/workgroup-tree-mobile/src/dept-result.vue.mjs +4 -3
  67. package/es/workgroup-tree-mobile/src/workgroup-tree-app.vue.mjs +8 -7
  68. package/es/workgroup-tree-mobile/src/workgroup-tree-inline-app.vue.mjs +51 -51
  69. package/es/workgroup-user-tree-inline/src/workgroup-user-tree-inline.vue.mjs +5 -5
  70. package/es/workgroup-user-tree-mobile/src/dept-path.vue.mjs +7 -6
  71. package/es/workgroup-user-tree-mobile/src/dept-result.vue.mjs +4 -3
  72. package/es/workgroup-user-tree-mobile/src/workgroup-user-tree-app.vue.mjs +7 -6
  73. package/es/workgroup-user-tree-mobile/src/workgroup-user-tree-inline-app.vue.mjs +65 -65
  74. package/es/year-range-picker/src/year-range-picker.vue.mjs +1 -1
  75. package/lib/IntervalSelection/src/sectionDate.vue.cjs +6 -6
  76. package/lib/chat-embed/src/chat-addition-data.vue2.cjs +13 -10
  77. package/lib/chat-embed/src/chat-ai-answer-tip.vue2.cjs +8 -8
  78. package/lib/chat-embed/src/chat-bubble-footer.vue2.cjs +5 -5
  79. package/lib/chat-embed/src/chat-sender.vue2.cjs +20 -20
  80. package/lib/chat-embed/src/components/answer-auto-chart.vue2.cjs +1 -2
  81. package/lib/chat-embed/src/components/answer-interaction-data.vue2.cjs +5 -6
  82. package/lib/chat-embed/src/components/history-detail.vue2.cjs +18 -18
  83. package/lib/chat-embed/src/header.vue2.cjs +17 -17
  84. package/lib/chat-embed/src/index.vue2.cjs +123 -123
  85. package/lib/chat-embed/src/recommendation-message.vue2.cjs +7 -4
  86. package/lib/chat-embed/src/sidebar-item.vue2.cjs +35 -35
  87. package/lib/chat-embed/src/voice/voice.vue.cjs +36 -35
  88. package/lib/date-picker-range/index.vue2.cjs +11 -11
  89. package/lib/department-tree-mobile/src/department-tree-app.vue.cjs +7 -6
  90. package/lib/department-tree-mobile/src/department-tree-inline-app.vue.cjs +53 -53
  91. package/lib/department-tree-mobile/src/dept-path.vue.cjs +6 -6
  92. package/lib/department-tree-mobile/src/dept-result.vue.cjs +7 -6
  93. package/lib/department-user-tree-inline/src/department-user-multiple-tree-inline.vue.cjs +5 -5
  94. package/lib/department-user-tree-mobile/src/department-user-tree-app.vue.cjs +9 -8
  95. package/lib/department-user-tree-mobile/src/department-user-tree-inline-app.vue.cjs +61 -61
  96. package/lib/department-user-tree-mobile/src/dept-path.vue.cjs +6 -6
  97. package/lib/department-user-tree-mobile/src/dept-result.vue.cjs +4 -3
  98. package/lib/empty-state/index.vue.cjs +2 -2
  99. package/lib/fs-upload/src/fs-upload-multi.vue.cjs +1 -1
  100. package/lib/fs-upload-list/src/fs-upload-list.vue.cjs +1 -1
  101. package/lib/fs-upload-new/src/file-upload-mobile/file-upload-app.vue.cjs +12 -12
  102. package/lib/fs-upload-new/src/file-upload-mobile/file-upload-browser.vue.cjs +24 -24
  103. package/lib/fs-upload-new/src/file-upload-mobile/file-upload-component.vue2.cjs +17 -17
  104. package/lib/fs-upload-new/src/file-upload-mobile/file-upload.vue.cjs +12 -12
  105. package/lib/fs-upload-new/src/fs-button-upload.vue2.cjs +23 -23
  106. package/lib/fs-upload-new/src/fs-drag-upload.vue2.cjs +23 -23
  107. package/lib/fs-upload-new/src/fs-preview-new.vue2.cjs +36 -36
  108. package/lib/fs-upload-new/src/fs-upload-new.vue.cjs +15 -15
  109. package/lib/json-view/json-view-dialog.vue.cjs +6 -6
  110. package/lib/multipart-upload/src/multipart-upload-form.vue.cjs +1 -1
  111. package/lib/multipart-upload/src/multipart-upload-list.vue.cjs +5 -5
  112. package/lib/row-form/index.vue2.cjs +31 -31
  113. package/lib/row-form/operation.vue.cjs +13 -13
  114. package/lib/secret-info/index.vue.cjs +1 -1
  115. package/lib/src/components/Affix/index.vue2.cjs +28 -28
  116. package/lib/src/components/Scrollbar/index.vue.cjs +22 -22
  117. package/lib/src/views/error-page/401.vue.cjs +7 -7
  118. package/lib/src/views/error-page/404.vue.cjs +4 -4
  119. package/lib/src/views/layout/components/Menubar/Item.vue.cjs +1 -1
  120. package/lib/src/views/layout/components/Menubar/Item.vue2.cjs +2 -2
  121. package/lib/src/views/super-icon/index.cjs +5 -0
  122. package/lib/src/views/super-icon/src/index.vue.cjs +5 -0
  123. package/lib/src/views/super-icon/src/index.vue2.cjs +10 -0
  124. package/lib/src/views/super-icon/src/index.vue3.cjs +2 -0
  125. package/lib/src/views/svg-icon/src/svg-icon.vue2.cjs +12 -0
  126. package/lib/style.css +920 -900
  127. package/lib/super-grid/src/columns-config.vue.cjs +1 -1
  128. package/lib/super-grid/src/components/grid-radio-input.vue.cjs +5 -5
  129. package/lib/super-grid/src/components/select-input.vue.cjs +56 -56
  130. package/lib/super-grid/src/row-detail.vue.cjs +1 -1
  131. package/lib/super-grid/src/search-form-advancedQuery.vue.cjs +1 -1
  132. package/lib/super-grid/src/search-form-number.vue.cjs +6 -6
  133. package/lib/super-grid/src/super-grid.vue.cjs +1 -1
  134. package/lib/super-nine-grid/src/search-form-number.vue.cjs +6 -6
  135. package/lib/super-nine-grid/src/search-form.vue.cjs +1 -1
  136. package/lib/super-nine-grid/src/super-nine-grid.vue.cjs +1 -1
  137. package/lib/workgroup-tree-inline/src/workgroup-tree-inline.vue.cjs +5 -5
  138. package/lib/workgroup-tree-mobile/src/dept-result.vue.cjs +4 -3
  139. package/lib/workgroup-tree-mobile/src/workgroup-tree-app.vue.cjs +9 -8
  140. package/lib/workgroup-tree-mobile/src/workgroup-tree-inline-app.vue.cjs +48 -48
  141. package/lib/workgroup-user-tree-inline/src/workgroup-user-tree-inline.vue.cjs +5 -5
  142. package/lib/workgroup-user-tree-mobile/src/dept-path.vue.cjs +6 -6
  143. package/lib/workgroup-user-tree-mobile/src/dept-result.vue.cjs +4 -3
  144. package/lib/workgroup-user-tree-mobile/src/workgroup-user-tree-app.vue.cjs +9 -8
  145. package/lib/workgroup-user-tree-mobile/src/workgroup-user-tree-inline-app.vue.cjs +63 -63
  146. package/lib/year-range-picker/src/year-range-picker.vue.cjs +1 -1
  147. package/package.json +2 -2
  148. package/src/views/layout/components/Menubar/Item.vue +1 -1
  149. package/src/views/super-icon/index.js +6 -0
  150. package/src/views/super-icon/src/index.vue +52 -0
  151. package/src/views/svg-icon/src/svg-icon.vue +5 -8
@@ -1,50 +1,50 @@
1
- import { defineComponent as e, ref as a, watch as t, resolveComponent as l, openBlock as s, createElementBlock as i, Fragment as o, withDirectives as n, createElementVNode as u, createVNode as c, withCtx as d, unref as r, vShow as m, toDisplayString as f, createBlock as h, createCommentVNode as v, normalizeClass as y, renderList as p, createTextVNode as g, pushScopeId as b, popScopeId as k } from "vue";
2
- import { ArrowDown as w, ArrowRight as _, StarFilled as A, Star as E, MoreFilled as T } from "@element-plus/icons-vue";
3
- import { useI18n as D } from "vue-i18n";
4
- import { AI_MODELS as I } from "./type.mjs";
5
- import { formatAiPptHistoryMessage as C, formatBailianHistoryMessage as P, formatDatabaseHistoryMessage as M, formatRagflowHistoryMessage as $, collectById as N, usefuleById as S, deleteByIds as x, getBySessionId as R } from "./util/history-message-util.mjs";
6
- import j from "dayjs";
7
- import { ElMessage as O } from "element-plus";
8
- import V from "../../src/assets/chat-embed/robot.svg.mjs";
9
- const F = (e2) => (b("data-v-1e62eff8"), e2 = e2(), k(), e2), Y = { class: "flex-avatar" }, B = ["src"], G = { class: "flex-function-icon" }, z = { class: "chat-embed__sidebar" }, L = { class: "sidebar-header" }, W = ["src"], H = { class: "sidebar-menu" }, K = F(() => u("span", null, "我的收藏", -1)), q = F(() => u("span", null, "查看有用", -1)), J = F(() => u("span", null, "历史记录", -1)), Q = { key: 0, class: "date-group" }, U = { key: 0, class: "date-group-item" }, X = { key: 1, class: "date-group-item" }, Z = { key: 2, class: "date-group-item" }, ee = { key: 3, class: "date-group-item" }, ae = { key: 4, class: "date-group-item" }, te = ["onClick"], le = e({ __name: "sidebar-item", props: { aiModel: { type: String, default: null }, dialogFullScreen: { type: Boolean, default: null } }, emits: ["new-chat-session", "select-history-item", "update-ai-history"], setup(e2, { expose: b2, emit: k2 }) {
10
- const F2 = e2, { t: le2 } = D();
11
- let se = 1;
12
- const ie = a(/* @__PURE__ */ new Map()), oe = a("history"), ne = a(""), ue = a(false), ce = a(true);
13
- t(() => F2.aiModel, (e3, a2) => {
14
- se = 1, oe.value = "history", ne.value = "", fe();
1
+ import { defineComponent as e, ref as a, watch as t, resolveComponent as l, openBlock as s, createElementBlock as i, Fragment as o, withDirectives as n, createElementVNode as u, createVNode as c, withCtx as d, unref as r, vShow as m, toDisplayString as h, createBlock as f, createCommentVNode as v, normalizeClass as y, renderList as p, createTextVNode as g } from "vue";
2
+ import { ArrowDown as b, ArrowRight as k, StarFilled as w, Star as _, MoreFilled as A } from "@element-plus/icons-vue";
3
+ import { useI18n as E } from "vue-i18n";
4
+ import { AI_MODELS as T } from "./type.mjs";
5
+ import { formatAiPptHistoryMessage as D, formatBailianHistoryMessage as I, formatDatabaseHistoryMessage as C, formatRagflowHistoryMessage as P, collectById as M, usefuleById as $, deleteByIds as N, getBySessionId as S } from "./util/history-message-util.mjs";
6
+ import x from "dayjs";
7
+ import { ElMessage as R } from "element-plus";
8
+ import j from "../../src/assets/chat-embed/robot.svg.mjs";
9
+ const O = { class: "flex-avatar" }, V = ["src"], F = { class: "flex-function-icon" }, Y = { class: "chat-embed__sidebar" }, B = { class: "sidebar-header" }, G = ["src"], z = { class: "sidebar-menu" }, L = { key: 0, class: "date-group" }, W = { key: 0, class: "date-group-item" }, H = { key: 1, class: "date-group-item" }, K = { key: 2, class: "date-group-item" }, q = { key: 3, class: "date-group-item" }, J = { key: 4, class: "date-group-item" }, Q = ["onClick"], U = e({ __name: "sidebar-item", props: { aiModel: { type: String, default: null }, dialogFullScreen: { type: Boolean, default: null } }, emits: ["new-chat-session", "select-history-item", "update-ai-history"], setup(e2, { expose: U2, emit: X }) {
10
+ const Z = X, { t: ee } = E(), ae = e2;
11
+ let te = 1;
12
+ const le = a(/* @__PURE__ */ new Map()), se = a("history"), ie = a(""), oe = a(false), ne = a(true);
13
+ t(() => ae.aiModel, (e3, a2) => {
14
+ te = 1, se.value = "history", ie.value = "", re();
15
15
  }, { immediate: true });
16
- const de = (e3) => {
17
- se++, ue.value || fe();
16
+ const ue = (e3) => {
17
+ te++, oe.value || re();
18
18
  };
19
- function re() {
20
- ne.value = "", k2("new-chat-session");
19
+ function ce() {
20
+ ie.value = "", Z("new-chat-session");
21
21
  }
22
- function me(e3) {
23
- e3 !== oe.value && (se = 1, oe.value = e3, ue.value = false, fe());
22
+ function de(e3) {
23
+ e3 !== se.value && (te = 1, se.value = e3, oe.value = false, re());
24
24
  }
25
- function fe() {
25
+ function re() {
26
26
  let e3 = "";
27
- if (F2.aiModel === I.INTERACTION)
28
- return ie.value = /* @__PURE__ */ new Map(), void re();
29
- switch (F2.aiModel) {
30
- case I.RAGFLOW:
27
+ if (ae.aiModel === T.INTERACTION)
28
+ return le.value = /* @__PURE__ */ new Map(), void ce();
29
+ switch (ae.aiModel) {
30
+ case T.RAGFLOW:
31
31
  e3 = "RAGFLOW";
32
32
  break;
33
- case I.DATABASE:
33
+ case T.DATABASE:
34
34
  e3 = "DATABASE";
35
35
  break;
36
- case I.DEEPSEEK:
36
+ case T.DEEPSEEK:
37
37
  e3 = "BAILIAN";
38
38
  break;
39
- case I.INTERACTION:
39
+ case T.INTERACTION:
40
40
  break;
41
- case I.PPT_GENERATION:
41
+ case T.PPT_GENERATION:
42
42
  e3 = "AIPPT";
43
43
  }
44
44
  let a2 = 0, t2 = 0;
45
- "useful" === oe.value ? a2 = 1 : "collected" === oe.value && (t2 = 1), window.$vueApp.config.globalProperties.$http.post(window.$vueApp.config.globalProperties.baseAPI + `/mc/ai-history/list/${e3}/${a2}/${t2}`, { pagination: { currentPage: se, pageSize: 30, isShowTotal: false } }).then((e4) => {
46
- if (0 === e4.data.length && se > 1)
47
- return O.info("没有更多历史记录了"), void (ue.value = true);
45
+ "useful" === se.value ? a2 = 1 : "collected" === se.value && (t2 = 1), window.$vueApp.config.globalProperties.$http.post(window.$vueApp.config.globalProperties.baseAPI + `/mc/ai-history/list/${e3}/${a2}/${t2}`, { pagination: { currentPage: te, pageSize: 30, isShowTotal: false } }).then((e4) => {
46
+ if (0 === e4.data.length && te > 1)
47
+ return R.info("没有更多历史记录了"), void (oe.value = true);
48
48
  const a3 = function(e5) {
49
49
  const a4 = /* @__PURE__ */ new Map(), t3 = /* @__PURE__ */ new Date(), l2 = new Date(t3.getFullYear(), t3.getMonth(), t3.getDate()).getTime(), s2 = l2 - 864e5, i2 = l2 - 6048e5, o2 = l2 - 2592e6;
50
50
  return e5.forEach((e6) => {
@@ -58,61 +58,61 @@ const F = (e2) => (b("data-v-1e62eff8"), e2 = e2(), k(), e2), Y = { class: "flex
58
58
  else if (t4 >= o2)
59
59
  a4.has("thirtyDays") || a4.set("thirtyDays", []), a4.get("thirtyDays").push(e6);
60
60
  else {
61
- const l3 = new Date(t4), s3 = j(`${l3.getFullYear()}-${l3.getMonth() + 1}`).format("YYYY-MM");
61
+ const l3 = new Date(t4), s3 = x(`${l3.getFullYear()}-${l3.getMonth() + 1}`).format("YYYY-MM");
62
62
  a4.has(s3) || a4.set(s3, []), a4.get(s3).push(e6);
63
63
  }
64
64
  }), a4;
65
65
  }(e4.data);
66
- 1 === se ? (e4.data.length < 30 && (ue.value = true), ie.value = a3) : a3.forEach((e5, a4) => {
67
- ie.value.has(a4) ? ie.value.get(a4).push(...e5) : ie.value.set(a4, e5);
66
+ 1 === te ? (e4.data.length < 30 && (oe.value = true), le.value = a3) : a3.forEach((e5, a4) => {
67
+ le.value.has(a4) ? le.value.get(a4).push(...e5) : le.value.set(a4, e5);
68
68
  });
69
69
  }).catch((e4) => {
70
70
  });
71
71
  }
72
- return b2({ getHistory: fe, addCurrentToSessionHistory: function(e3, a2 = []) {
72
+ return U2({ getHistory: re, addCurrentToSessionHistory: function(e3, a2 = []) {
73
73
  e3 && setTimeout(() => {
74
- R(e3).then((e4) => {
75
- e4 && (ne.value = e4.id, ie.value.has("today") || (ie.value = new Map([["today", []], ...ie.value])), ie.value.get("today").unshift(e4), a2.length > 0 ? k2("select-history-item", e4, a2) : k2("select-history-item", e4, []));
74
+ S(e3).then((e4) => {
75
+ e4 && (ie.value = e4.id, le.value.has("today") || (le.value = new Map([["today", []], ...le.value])), le.value.get("today").unshift(e4), a2.length > 0 ? Z("select-history-item", e4, a2) : Z("select-history-item", e4, []));
76
76
  }).catch((e4) => {
77
77
  });
78
78
  }, 100);
79
79
  } }), (e3, a2) => {
80
- const t2 = l("el-avatar"), b3 = l("SuperIcon"), D2 = l("el-tooltip"), R2 = l("el-icon"), j2 = l("el-dropdown-item"), se2 = l("el-dropdown-menu"), ue2 = l("el-dropdown"), fe2 = l("el-scrollbar"), he = l("el-button");
81
- return s(), i(o, null, [n(u("div", Y, [c(t2, { size: 40, fit: "cover" }, { default: d(() => [u("img", { src: r(V), alt: "AI Avatar" }, null, 8, B)]), _: 1 }), u("div", G, [c(D2, { class: "box-item", effect: "dark", content: "打开侧边栏" }, { default: d(() => [c(b3, { class: "shousuo-icon", onClick: a2[0] || (a2[0] = (e4) => ce.value = true), iconValue: "amb-icon-zhankaibianlan" })]), _: 1 }), c(D2, { class: "box-item", effect: "dark", content: "新建会话" }, { default: d(() => [c(b3, { class: "shousuo-icon", iconValue: "amb-icon-xinjianhuihua", onClick: re })]), _: 1 })])], 512), [[m, !ce.value]]), n(u("div", z, [u("div", L, [c(t2, { class: "chat-embed__header_avatar", size: 40, fit: "cover" }, { default: d(() => [u("img", { src: r(V), alt: "AI Avatar" }, null, 8, W)]), _: 1 }), u("span", null, f(r(le2)("chatEmbed.name")), 1), c(D2, { class: "box-item", effect: "dark", content: "收起侧边栏" }, { default: d(() => [ce.value ? (s(), h(b3, { key: 0, onClick: a2[1] || (a2[1] = (e4) => ce.value = false), class: "right-icon", iconValue: "amb-icon-shouqibianlan" })) : v("", true)]), _: 1 })]), u("div", H, [u("div", { class: y(["menu-item", { "active-item": "collected" === oe.value }]), onClick: a2[2] || (a2[2] = (e4) => me("collected")) }, [c(b3, { iconValue: "amb-icon-shoucang" }), K, "collected" === oe.value ? (s(), h(R2, { key: 0, class: "dropdown-right" }, { default: d(() => [c(r(w))]), _: 1 })) : (s(), h(R2, { key: 1, class: "dropdown-right" }, { default: d(() => [c(r(_))]), _: 1 }))], 2), u("div", { class: y(["menu-item", { "active-item": "useful" === oe.value }]), onClick: a2[3] || (a2[3] = (e4) => me("useful")) }, [c(b3, { iconValue: "amb-icon-youyong" }), q, "useful" === oe.value ? (s(), h(R2, { key: 0, class: "dropdown-right" }, { default: d(() => [c(r(w))]), _: 1 })) : (s(), h(R2, { key: 1, class: "dropdown-right" }, { default: d(() => [c(r(_))]), _: 1 }))], 2), u("div", { class: y(["menu-item", { "active-item": "history" === oe.value }]), onClick: a2[4] || (a2[4] = (e4) => me("history")) }, [c(b3, { iconValue: "amb-icon-lishihuihua" }), J, "history" === oe.value ? (s(), h(R2, { key: 0, class: "dropdown-right" }, { default: d(() => [c(r(w))]), _: 1 })) : (s(), h(R2, { key: 1, class: "dropdown-right" }, { default: d(() => [c(r(_))]), _: 1 }))], 2)]), c(fe2, { class: "scrollbar-container", onEndReached: de }, { default: d(() => [(s(true), i(o, null, p(ie.value, ([e4, a3]) => (s(), i(o, { key: e4 }, [(a3 == null ? void 0 : a3.length) > 0 ? (s(), i("div", Q, ["today" === e4 ? (s(), i("div", U, "今天")) : "yesterday" === e4 ? (s(), i("div", X, "昨天")) : "sevenDays" === e4 ? (s(), i("div", Z, "七天内")) : "thirtyDays" === e4 ? (s(), i("div", ee, "三十天内")) : (s(), i("div", ae, f(e4), 1)), (s(true), i(o, null, p(a3, (e5) => (s(), i("div", { class: y(["history-item", { "active-item": ne.value === e5.id }]) }, [e5.useful ? (s(), h(b3, { key: 0, iconValue: "amb-icon-youyong" })) : v("", true), e5.collected ? (s(), h(R2, { key: 1 }, { default: d(() => [c(r(A))]), _: 1 })) : v("", true), u("div", { class: "history-subject", onClick: (a4) => function(e6) {
82
- ne.value !== e6.id && (ne.value = e6.id, window.$vueApp.config.globalProperties.$http.get(window.$vueApp.config.globalProperties.baseAPI + `/mc/ai-history/content/${e6.id}`).then((a5) => {
83
- let t3 = [];
84
- switch (F2.aiModel) {
85
- case I.RAGFLOW:
86
- t3 = $(a5);
80
+ const t2 = l("el-avatar"), E2 = l("SuperIcon"), S2 = l("el-tooltip"), x2 = l("el-icon"), U3 = l("el-dropdown-item"), X2 = l("el-dropdown-menu"), te2 = l("el-dropdown"), oe2 = l("el-scrollbar"), re2 = l("el-button");
81
+ return s(), i(o, null, [n(u("div", O, [c(t2, { size: 40, fit: "cover" }, { default: d(() => [u("img", { src: r(j), alt: "AI Avatar" }, null, 8, V)]), _: 1 }), u("div", F, [c(S2, { class: "box-item", effect: "dark", content: "打开侧边栏" }, { default: d(() => [c(E2, { class: "shousuo-icon", onClick: a2[0] || (a2[0] = (e4) => ne.value = true), iconValue: "amb-icon-zhankaibianlan" })]), _: 1 }), c(S2, { class: "box-item", effect: "dark", content: "新建会话" }, { default: d(() => [c(E2, { class: "shousuo-icon", iconValue: "amb-icon-xinjianhuihua", onClick: ce })]), _: 1 })])], 512), [[m, !ne.value]]), n(u("div", Y, [u("div", B, [c(t2, { class: "chat-embed__header_avatar", size: 40, fit: "cover" }, { default: d(() => [u("img", { src: r(j), alt: "AI Avatar" }, null, 8, G)]), _: 1 }), u("span", null, h(r(ee)("chatEmbed.name")), 1), c(S2, { class: "box-item", effect: "dark", content: "收起侧边栏" }, { default: d(() => [ne.value ? (s(), f(E2, { key: 0, onClick: a2[1] || (a2[1] = (e4) => ne.value = false), class: "right-icon", iconValue: "amb-icon-shouqibianlan" })) : v("", true)]), _: 1 })]), u("div", z, [u("div", { class: y(["menu-item", { "active-item": "collected" === se.value }]), onClick: a2[2] || (a2[2] = (e4) => de("collected")) }, [c(E2, { iconValue: "amb-icon-shoucang" }), a2[5] || (a2[5] = u("span", null, "我的收藏", -1)), "collected" === se.value ? (s(), f(x2, { key: 0, class: "dropdown-right" }, { default: d(() => [c(r(b))]), _: 1 })) : (s(), f(x2, { key: 1, class: "dropdown-right" }, { default: d(() => [c(r(k))]), _: 1 }))], 2), u("div", { class: y(["menu-item", { "active-item": "useful" === se.value }]), onClick: a2[3] || (a2[3] = (e4) => de("useful")) }, [c(E2, { iconValue: "amb-icon-youyong" }), a2[6] || (a2[6] = u("span", null, "查看有用", -1)), "useful" === se.value ? (s(), f(x2, { key: 0, class: "dropdown-right" }, { default: d(() => [c(r(b))]), _: 1 })) : (s(), f(x2, { key: 1, class: "dropdown-right" }, { default: d(() => [c(r(k))]), _: 1 }))], 2), u("div", { class: y(["menu-item", { "active-item": "history" === se.value }]), onClick: a2[4] || (a2[4] = (e4) => de("history")) }, [c(E2, { iconValue: "amb-icon-lishihuihua" }), a2[7] || (a2[7] = u("span", null, "历史记录", -1)), "history" === se.value ? (s(), f(x2, { key: 0, class: "dropdown-right" }, { default: d(() => [c(r(b))]), _: 1 })) : (s(), f(x2, { key: 1, class: "dropdown-right" }, { default: d(() => [c(r(k))]), _: 1 }))], 2)]), c(oe2, { class: "scrollbar-container", onEndReached: ue }, { default: d(() => [(s(true), i(o, null, p(le.value, ([e4, t3]) => (s(), i(o, { key: e4 }, [(t3 == null ? void 0 : t3.length) > 0 ? (s(), i("div", L, ["today" === e4 ? (s(), i("div", W, "今天")) : "yesterday" === e4 ? (s(), i("div", H, "昨天")) : "sevenDays" === e4 ? (s(), i("div", K, "七天内")) : "thirtyDays" === e4 ? (s(), i("div", q, "三十天内")) : (s(), i("div", J, h(e4), 1)), (s(true), i(o, null, p(t3, (e5) => (s(), i("div", { class: y(["history-item", { "active-item": ie.value === e5.id }]) }, [e5.useful ? (s(), f(E2, { key: 0, iconValue: "amb-icon-youyong" })) : v("", true), e5.collected ? (s(), f(x2, { key: 1 }, { default: d(() => [c(r(w))]), _: 1 })) : v("", true), u("div", { class: "history-subject", onClick: (a3) => function(e6) {
82
+ ie.value !== e6.id && (ie.value = e6.id, window.$vueApp.config.globalProperties.$http.get(window.$vueApp.config.globalProperties.baseAPI + `/mc/ai-history/content/${e6.id}`).then((a4) => {
83
+ let t4 = [];
84
+ switch (ae.aiModel) {
85
+ case T.RAGFLOW:
86
+ t4 = P(a4);
87
87
  break;
88
- case I.DATABASE:
89
- t3 = M(a5);
88
+ case T.DATABASE:
89
+ t4 = C(a4);
90
90
  break;
91
- case I.DEEPSEEK:
92
- t3 = P(a5);
91
+ case T.DEEPSEEK:
92
+ t4 = I(a4);
93
93
  break;
94
- case I.INTERACTION:
94
+ case T.INTERACTION:
95
95
  break;
96
- case I.PPT_GENERATION:
97
- t3 = C(a5);
96
+ case T.PPT_GENERATION:
97
+ t4 = D(a4);
98
98
  }
99
- k2("select-history-item", e6, t3);
99
+ Z("select-history-item", e6, t4);
100
100
  }).catch((e7) => {
101
101
  }));
102
- }(e5) }, f(e5.subject), 9, te), c(ue2, { class: "dropdown-right", onCommand: (a4) => function(e6, a5) {
103
- "collect" === e6 || "uncollect" === e6 ? N(a5.id).then(() => {
104
- a5.collected = !a5.collected, k2("update-ai-history", a5);
105
- }) : "useful" === e6 || "unuseful" === e6 ? S(a5.id).then(() => {
106
- a5.useful = !a5.useful, k2("update-ai-history", a5);
107
- }) : "delete" === e6 && x([a5.id]).then(() => {
108
- O.success("已删除该会话"), ie.value.forEach((e7) => {
109
- const t3 = e7.findIndex((e8) => e8.id === a5.id);
110
- -1 !== t3 && e7.splice(t3, 1);
111
- }), ne.value === a5.id && re();
102
+ }(e5) }, h(e5.subject), 9, Q), c(te2, { class: "dropdown-right", onCommand: (a3) => function(e6, a4) {
103
+ "collect" === e6 || "uncollect" === e6 ? M(a4.id).then(() => {
104
+ a4.collected = !a4.collected, Z("update-ai-history", a4);
105
+ }) : "useful" === e6 || "unuseful" === e6 ? $(a4.id).then(() => {
106
+ a4.useful = !a4.useful, Z("update-ai-history", a4);
107
+ }) : "delete" === e6 && N([a4.id]).then(() => {
108
+ R.success("已删除该会话"), le.value.forEach((e7) => {
109
+ const t4 = e7.findIndex((e8) => e8.id === a4.id);
110
+ -1 !== t4 && e7.splice(t4, 1);
111
+ }), ie.value === a4.id && ce();
112
112
  });
113
- }(a4, e5), trigger: "click" }, { dropdown: d(() => [c(se2, null, { default: d(() => [e5.collected ? v("", true) : (s(), h(j2, { key: 0, command: "collect" }, { default: d(() => [c(R2, null, { default: d(() => [c(r(A))]), _: 1 }), g("收藏 ")]), _: 1 })), e5.collected ? (s(), h(j2, { key: 1, command: "uncollect" }, { default: d(() => [c(R2, null, { default: d(() => [c(r(E))]), _: 1 }), g("取消收藏 ")]), _: 1 })) : v("", true), e5.useful ? v("", true) : (s(), h(j2, { key: 2, command: "useful" }, { default: d(() => [g("有用")]), _: 1 })), e5.useful ? (s(), h(j2, { key: 3, command: "unuseful" }, { default: d(() => [g("取消有用")]), _: 1 })) : v("", true), c(j2, { command: "delete" }, { default: d(() => [g("删除")]), _: 1 })]), _: 2 }, 1024)]), default: d(() => [c(R2, { class: "more-filled" }, { default: d(() => [c(r(T))]), _: 1 })]), _: 2 }, 1032, ["onCommand"])], 2))), 256))])) : v("", true)], 64))), 128))]), _: 1 }), c(he, { type: "primary", class: "new-session-button", onClick: re }, { icon: d(() => [c(b3, { iconValue: "amb-icon-xinjianhuihua" })]), default: d(() => [g(" 新建会话 ")]), _: 1 })], 512), [[m, ce.value]])], 64);
113
+ }(a3, e5), trigger: "click" }, { dropdown: d(() => [c(X2, null, { default: d(() => [e5.collected ? v("", true) : (s(), f(U3, { key: 0, command: "collect" }, { default: d(() => [c(x2, null, { default: d(() => [c(r(w))]), _: 1 }), a2[8] || (a2[8] = g("收藏 ", -1))]), _: 1 })), e5.collected ? (s(), f(U3, { key: 1, command: "uncollect" }, { default: d(() => [c(x2, null, { default: d(() => [c(r(_))]), _: 1 }), a2[9] || (a2[9] = g("取消收藏 ", -1))]), _: 1 })) : v("", true), e5.useful ? v("", true) : (s(), f(U3, { key: 2, command: "useful" }, { default: d(() => [...a2[10] || (a2[10] = [g("有用", -1)])]), _: 1 })), e5.useful ? (s(), f(U3, { key: 3, command: "unuseful" }, { default: d(() => [...a2[11] || (a2[11] = [g("取消有用", -1)])]), _: 1 })) : v("", true), c(U3, { command: "delete" }, { default: d(() => [...a2[12] || (a2[12] = [g("删除", -1)])]), _: 1 })]), _: 2 }, 1024)]), default: d(() => [c(x2, { class: "more-filled" }, { default: d(() => [c(r(A))]), _: 1 })]), _: 2 }, 1032, ["onCommand"])], 2))), 256))])) : v("", true)], 64))), 128))]), _: 1 }), c(re2, { type: "primary", class: "new-session-button", onClick: ce }, { icon: d(() => [c(E2, { iconValue: "amb-icon-xinjianhuihua" })]), default: d(() => [a2[13] || (a2[13] = g(" 新建会话 ", -1))]), _: 1 })], 512), [[m, ne.value]])], 64);
114
114
  };
115
115
  } });
116
116
  export {
117
- le as default
117
+ U as default
118
118
  };
@@ -11,6 +11,7 @@ import "js-base64";
11
11
  import "../../../src/utils/request.mjs";
12
12
  import { ElMessage as N } from "element-plus";
13
13
  const S = { key: 0 }, O = { __name: "voice", props: { paramMsg: { type: String, default: false } }, emits: ["userMessage"], setup(O2, { emit: E }) {
14
+ const b = E;
14
15
  window.$http.get(window.$vueApp.config.globalProperties.baseAPI + "/bs/ai-voice-command/permission-json").then((e2) => {
15
16
  m(e2 ? JSON.stringify(e2) : "EMPTY_VALUE");
16
17
  }).catch((e2) => {
@@ -20,67 +21,67 @@ const S = { key: 0 }, O = { __name: "voice", props: { paramMsg: { type: String,
20
21
  }).catch((e2) => {
21
22
  d(JSON.stringify([])), console.error("获取语音命令所需叶子菜单失败", e2);
22
23
  });
23
- let b = e("UNDEFINED"), h = e("开始录音"), y = e(""), C = e("");
24
+ let h = e("UNDEFINED"), y = e("开始录音"), C = e(""), j = e("");
24
25
  e(false);
25
- const j = "https:" === window.location.protocol || window.location.href.indexOf("//localhost") > 0 || window.location.href.indexOf("//127.0.0.1") > 0;
26
- let L;
27
- const D = e("");
26
+ const L = "https:" === window.location.protocol || window.location.href.indexOf("//localhost") > 0 || window.location.href.indexOf("//127.0.0.1") > 0;
27
+ let D;
28
+ const P = e("");
28
29
  o(() => {
29
- L = new RecorderManager(), L.constructor(window.$vueApp.config.globalProperties.portalUrl + "/js/processor"), L.onStart = () => {
30
- D.value ? D.value = "" : F("OPEN");
31
- }, L.onFrameRecorded = ({ isLastFrame: e2, frameBuffer: o2 }) => {
32
- P.readyState === P.OPEN && (P.send(JSON.stringify({ data: { status: e2 ? 2 : 1, format: "audio/L16;rate=16000", encoding: "raw", audio: A(o2) } })), e2 && F("CLOSING"));
33
- }, L.onStop = () => {
30
+ D = new RecorderManager(), D.constructor(window.$vueApp.config.globalProperties.portalUrl + "/js/processor"), D.onStart = () => {
31
+ P.value ? P.value = "" : M("OPEN");
32
+ }, D.onFrameRecorded = ({ isLastFrame: e2, frameBuffer: o2 }) => {
33
+ k.readyState === k.OPEN && (k.send(JSON.stringify({ data: { status: e2 ? 2 : 1, format: "audio/L16;rate=16000", encoding: "raw", audio: $(o2) } })), e2 && M("CLOSING"));
34
+ }, D.onStop = () => {
34
35
  p();
35
36
  };
36
37
  });
37
- let P = e(), k = e(), I = e();
38
- function A(e2) {
38
+ let k = e(), I = e(), A = e();
39
+ function $(e2) {
39
40
  for (var o2 = "", r2 = new Uint8Array(e2), t2 = r2.byteLength, a2 = 0; a2 < t2; a2++)
40
41
  o2 += String.fromCharCode(r2[a2]);
41
42
  return window.btoa(o2);
42
43
  }
43
- let $ = 60;
44
- function _() {
45
- $ -= 1, $ <= 0 ? (p(), L.stop()) : h.value = `录音中(${$}s)`;
44
+ let _ = 60;
45
+ function F() {
46
+ _ -= 1, _ <= 0 ? (p(), D.stop()) : y.value = `录音中(${_}s)`;
46
47
  }
47
- function F(e2) {
48
- b.value = e2, "CONNECTING" === e2 ? (h.value = "建立连接中", k = "", I = "") : "OPEN" === e2 ? ($ = 60, h.value = `录音中(${$}s)`, u(_)) : "CLOSING" === e2 ? h.value = "关闭连接中" : "CLOSED" === e2 && (h.value = "开始录音", J());
48
+ function M(e2) {
49
+ h.value = e2, "CONNECTING" === e2 ? (y.value = "建立连接中", I = "", A = "") : "OPEN" === e2 ? (_ = 60, y.value = `录音中(${_}s)`, u(F)) : "CLOSING" === e2 ? y.value = "关闭连接中" : "CLOSED" === e2 && (y.value = "开始录音", x());
49
50
  }
50
- function M() {
51
+ function U() {
51
52
  let e2 = f();
52
53
  e2 || (e2 = 1);
53
54
  const o2 = v(), r2 = window.$vueApp.config.globalProperties.voiceSockerUrl + e2 + "?jwt=" + o2;
54
55
  if ("WebSocket" in window)
55
- P = new WebSocket(r2);
56
+ k = new WebSocket(r2);
56
57
  else {
57
58
  if (!("MozWebSocket" in window))
58
59
  return void alert("浏览器不支持WebSocket");
59
- P = new MozWebSocket(r2);
60
+ k = new MozWebSocket(r2);
60
61
  }
61
- F("CONNECTING"), P.onopen = (e3) => {
62
- L.start({ sampleRate: 16e3, frameSize: 1280 });
63
- P.send(JSON.stringify({ common: { app_id: "c4b3002b" }, business: { language: "zh_cn", domain: "iat", accent: "mandarin", vad_eos: 5e3, dwa: "wpgs" }, data: { status: 0, format: "audio/L16;rate=16000", encoding: "raw" } }));
64
- }, P.onmessage = (e3) => {
62
+ M("CONNECTING"), k.onopen = (e3) => {
63
+ D.start({ sampleRate: 16e3, frameSize: 1280 });
64
+ k.send(JSON.stringify({ common: { app_id: "c4b3002b" }, business: { language: "zh_cn", domain: "iat", accent: "mandarin", vad_eos: 5e3, dwa: "wpgs" }, data: { status: 0, format: "audio/L16;rate=16000", encoding: "raw" } }));
65
+ }, k.onmessage = (e3) => {
65
66
  !function(e4) {
66
67
  let o3 = e4;
67
68
  if (o3 = JSON.parse(e4), o3 && o3.error)
68
- P.close(), D.value = o3.error, N.error(o3.error);
69
+ k.close(), P.value = o3.error, N.error(o3.error);
69
70
  else if (o3.data && o3.data.result) {
70
71
  let e5 = o3.data.result, r3 = "", t2 = e5.ws;
71
72
  for (let e6 = 0; e6 < t2.length; e6++)
72
73
  r3 += t2[e6].cw[0].w;
73
- e5.pgs ? ("apd" === e5.pgs && (k = I), I = k + r3) : k += r3, y.value = I || k || "";
74
+ e5.pgs ? ("apd" === e5.pgs && (I = A), A = I + r3) : I += r3, C.value = A || I || "";
74
75
  }
75
- 0 === o3.code && 2 === o3.data.status && P.close(), 0 !== o3.code && (P.close(), console.error(o3));
76
+ 0 === o3.code && 2 === o3.data.status && k.close(), 0 !== o3.code && (k.close(), console.error(o3));
76
77
  }(e3.data);
77
- }, P.onerror = (e3) => {
78
- console.error(e3), L.stop(), F("CLOSED");
79
- }, P.onclose = (e3) => {
80
- L.stop(), F("CLOSED");
78
+ }, k.onerror = (e3) => {
79
+ console.error(e3), D.stop(), M("CLOSED");
80
+ }, k.onclose = (e3) => {
81
+ D.stop(), M("CLOSED");
81
82
  };
82
83
  }
83
- const U = () => {
84
+ const J = () => {
84
85
  !async function() {
85
86
  if (!navigator.permissions || !navigator.permissions.query)
86
87
  return "unsupported";
@@ -90,13 +91,13 @@ const S = { key: 0 }, O = { __name: "voice", props: { paramMsg: { type: String,
90
91
  } catch (e2) {
91
92
  return console.error("查询权限时发生错误:", e2), "error";
92
93
  }
93
- }(), "UNDEFINED" === b.value || "CLOSED" === b.value ? M() : "CONNECTING" !== b.value && "OPEN" !== b.value || L.stop();
94
- }, J = () => {
95
- C.value = C.value + y.value, y.value = "", "" != C.value ? (E("userMessage", C.value), C.value = "") : (C.value = "", y.value = "");
94
+ }(), "UNDEFINED" === h.value || "CLOSED" === h.value ? U() : "CONNECTING" !== h.value && "OPEN" !== h.value || D.stop();
95
+ }, x = () => {
96
+ j.value = j.value + C.value, C.value = "", "" != j.value ? (b("userMessage", j.value), j.value = "") : (j.value = "", C.value = "");
96
97
  };
97
98
  return (e2, o2) => {
98
99
  const u2 = r("el-icon");
99
- return t(j) ? (a(), s("span", S, ["UNDEFINED" === t(b) || "CLOSED" === t(b) ? (a(), n(u2, { key: 0, color: "#409EFF", onClick: U }, { default: i(() => [c(t(w))]), _: 1 })) : (a(), n(u2, { key: 1, class: "send-icon", color: "red" }, { default: i(() => [c(t(g))]), _: 1 }))])) : l("", true);
100
+ return t(L) ? (a(), s("span", S, ["UNDEFINED" === t(h) || "CLOSED" === t(h) ? (a(), n(u2, { key: 0, color: "#409EFF", onClick: J }, { default: i(() => [c(t(w))]), _: 1 })) : (a(), n(u2, { key: 1, class: "send-icon", color: "red" }, { default: i(() => [c(t(g))]), _: 1 }))])) : l("", true);
100
101
  };
101
102
  } };
102
103
  export {
@@ -1,15 +1,15 @@
1
- import { defineComponent as e, ref as a, watch as l, computed as t, resolveComponent as r, openBlock as n, createElementBlock as u, createVNode as o, pushScopeId as i, popScopeId as d, createElementVNode as s } from "vue";
2
- import c from "dayjs";
3
- import { useI18n as m } from "vue-i18n";
4
- const f = { class: "ab-date-range" }, v = ((e2) => (i("data-v-2aeaa81d"), e2 = e2(), d(), e2))(() => s("span", { class: "sep" }, "-", -1)), p = e({ __name: "index", props: { modelValue: { type: Array, default: () => [] }, type: { type: String, default: "daterange" }, format: { type: String, default: void 0 }, valueFormat: { type: String, default: void 0 }, disabled: { type: Boolean, default: false }, clearable: { type: Boolean, default: true }, readonly: { type: Boolean, default: false }, shortcuts: { type: Array, default: void 0 }, startPlaceholder: { type: String, default: void 0 }, endPlaceholder: { type: String, default: void 0 }, size: { type: String, default: "medium" } }, emits: ["update:modelValue", "change", "blur", "focus", "visible-change", "panel-change", "clear"], setup(e2, { emit: i2 }) {
5
- const d2 = e2, { t: s2 } = m(), p2 = a(d2.startPlaceholder ?? s2("imatrixUIMessage.startDate")), g = a(d2.endPlaceholder ?? s2("imatrixUIMessage.endDate")), y = a(d2.modelValue && d2.modelValue[0]), h = a(d2.modelValue && d2.modelValue[1]);
6
- l(() => d2.modelValue && d2.modelValue[0], (e3) => {
7
- y.value = e3;
8
- }), l(() => d2.modelValue && d2.modelValue[1], (e3) => {
1
+ import { defineComponent as e, ref as a, watch as l, computed as t, resolveComponent as r, openBlock as n, createElementBlock as u, createVNode as o, createElementVNode as i } from "vue";
2
+ import d from "dayjs";
3
+ import { useI18n as s } from "vue-i18n";
4
+ const c = { class: "ab-date-range" }, m = e({ __name: "index", props: { modelValue: { type: Array, default: () => [] }, type: { type: String, default: "daterange" }, format: { type: String, default: void 0 }, valueFormat: { type: String, default: void 0 }, disabled: { type: Boolean, default: false }, clearable: { type: Boolean, default: true }, readonly: { type: Boolean, default: false }, shortcuts: { type: Array, default: void 0 }, startPlaceholder: { type: String, default: void 0 }, endPlaceholder: { type: String, default: void 0 }, size: { type: String, default: "medium" } }, emits: ["update:modelValue", "change", "blur", "focus", "visible-change", "panel-change", "clear"], setup(e2, { emit: m2 }) {
5
+ const { t: f } = s(), v = e2, p = a(v.startPlaceholder ?? f("imatrixUIMessage.startDate")), g = a(v.endPlaceholder ?? f("imatrixUIMessage.endDate")), y = m2, h = a(v.modelValue && v.modelValue[0]), b = a(v.modelValue && v.modelValue[1]);
6
+ l(() => v.modelValue && v.modelValue[0], (e3) => {
9
7
  h.value = e3;
8
+ }), l(() => v.modelValue && v.modelValue[1], (e3) => {
9
+ b.value = e3;
10
10
  });
11
- const b = t(() => {
12
- switch (d2.type) {
11
+ const V = t(() => {
12
+ switch (v.type) {
13
13
  case "daterange":
14
14
  default:
15
15
  return "date";
@@ -21,40 +21,40 @@ const f = { class: "ab-date-range" }, v = ((e2) => (i("data-v-2aeaa81d"), e2 = e
21
21
  return "year";
22
22
  }
23
23
  });
24
- function V(e3, a2) {
25
- i2(e3, a2);
24
+ function C(e3, a2) {
25
+ y(e3, a2);
26
26
  }
27
- function C(e3) {
28
- if (d2.valueFormat) {
29
- const a2 = c(e3);
30
- return a2.isValid() ? a2.format(d2.valueFormat) : e3;
27
+ function A(e3) {
28
+ if (v.valueFormat) {
29
+ const a2 = d(e3);
30
+ return a2.isValid() ? a2.format(v.valueFormat) : e3;
31
31
  }
32
32
  if (e3 instanceof Date)
33
33
  return e3;
34
34
  if ("number" == typeof e3)
35
35
  return new Date(e3);
36
36
  if ("string" == typeof e3) {
37
- const a2 = c(e3);
37
+ const a2 = d(e3);
38
38
  return a2.isValid() ? a2.toDate() : e3;
39
39
  }
40
40
  return e3;
41
41
  }
42
- const A = t(() => {
43
- if (d2.shortcuts && Array.isArray(d2.shortcuts))
44
- return d2.shortcuts.map((e3) => e3 && e3.value ? { text: e3.text, onClick() {
42
+ const D = t(() => {
43
+ if (v.shortcuts && Array.isArray(v.shortcuts))
44
+ return v.shortcuts.map((e3) => e3 && e3.value ? { text: e3.text, onClick() {
45
45
  !function(e4) {
46
46
  let a2 = null;
47
47
  if (Array.isArray(e4)) {
48
48
  a2 = [];
49
49
  for (const l2 of e4)
50
- a2.push(C(l2));
50
+ a2.push(A(l2));
51
51
  } else
52
- a2 = C(e4);
53
- Array.isArray(a2) && a2.length >= 2 ? (y.value = a2[0], h.value = a2[1]) : (y.value = a2, h.value = a2), x();
52
+ a2 = A(e4);
53
+ Array.isArray(a2) && a2.length >= 2 ? (h.value = a2[0], b.value = a2[1]) : (h.value = a2, b.value = a2), P();
54
54
  }("function" == typeof e3.value ? e3.value() : e3.value);
55
55
  } } : e3);
56
56
  });
57
- function D(e3) {
57
+ function T(e3) {
58
58
  if (null == e3)
59
59
  return null;
60
60
  if (e3 instanceof Date)
@@ -62,32 +62,32 @@ const f = { class: "ab-date-range" }, v = ((e2) => (i("data-v-2aeaa81d"), e2 = e
62
62
  const a2 = "number" == typeof e3 ? e3 : Date.parse(String(e3));
63
63
  return isNaN(a2) ? null : new Date(a2);
64
64
  }
65
- function T(e3) {
66
- const a2 = D(h.value);
67
- return !!a2 && e3.getTime() > a2.getTime();
68
- }
69
65
  function z(e3) {
70
- const a2 = D(y.value);
71
- return !!a2 && e3.getTime() < a2.getTime();
66
+ const a2 = T(b.value);
67
+ return !!a2 && e3.getTime() > a2.getTime();
72
68
  }
73
69
  function F(e3) {
74
- y.value = e3;
75
- const a2 = D(e3), l2 = D(h.value);
76
- a2 && l2 && a2.getTime() > l2.getTime() && (h.value = e3), x();
70
+ const a2 = T(h.value);
71
+ return !!a2 && e3.getTime() < a2.getTime();
77
72
  }
78
73
  function S(e3) {
79
74
  h.value = e3;
80
- const a2 = D(y.value), l2 = D(e3);
81
- a2 && l2 && l2.getTime() < a2.getTime() && (y.value = e3), x();
75
+ const a2 = T(e3), l2 = T(b.value);
76
+ a2 && l2 && a2.getTime() > l2.getTime() && (b.value = e3), P();
77
+ }
78
+ function x(e3) {
79
+ b.value = e3;
80
+ const a2 = T(h.value), l2 = T(e3);
81
+ a2 && l2 && l2.getTime() < a2.getTime() && (h.value = e3), P();
82
82
  }
83
- function x() {
84
- i2("update:modelValue", [y.value, h.value]), i2("change", [y.value, h.value]);
83
+ function P() {
84
+ y("update:modelValue", [h.value, b.value]), y("change", [h.value, b.value]);
85
85
  }
86
86
  return (a2, l2) => {
87
87
  const t2 = r("el-date-picker");
88
- return n(), u("div", f, [o(t2, { modelValue: y.value, "onUpdate:modelValue": l2[0] || (l2[0] = (e3) => y.value = e3), type: b.value, format: e2.format, "value-format": e2.valueFormat, disabled: e2.disabled, clearable: e2.clearable, readonly: e2.readonly, shortcuts: A.value, placeholder: p2.value, size: e2.size, "disabled-date": T, onChange: F, onBlur: l2[1] || (l2[1] = (e3) => V("blur", e3)), onFocus: l2[2] || (l2[2] = (e3) => V("focus", e3)), onVisibleChange: l2[3] || (l2[3] = (e3) => V("visible-change", e3)), onPanelChange: l2[4] || (l2[4] = (e3) => V("panel-change", e3)), onClear: l2[5] || (l2[5] = (e3) => V("clear", e3)) }, null, 8, ["modelValue", "type", "format", "value-format", "disabled", "clearable", "readonly", "shortcuts", "placeholder", "size"]), v, o(t2, { modelValue: h.value, "onUpdate:modelValue": l2[6] || (l2[6] = (e3) => h.value = e3), type: b.value, format: e2.format, "value-format": e2.valueFormat, disabled: e2.disabled, clearable: e2.clearable, readonly: e2.readonly, shortcuts: A.value, placeholder: g.value, size: e2.size, "disabled-date": z, onChange: S, onBlur: l2[7] || (l2[7] = (e3) => V("blur", e3)), onFocus: l2[8] || (l2[8] = (e3) => V("focus", e3)), onVisibleChange: l2[9] || (l2[9] = (e3) => V("visible-change", e3)), onPanelChange: l2[10] || (l2[10] = (e3) => V("panel-change", e3)), onClear: l2[11] || (l2[11] = (e3) => V("clear", e3)) }, null, 8, ["modelValue", "type", "format", "value-format", "disabled", "clearable", "readonly", "shortcuts", "placeholder", "size"])]);
88
+ return n(), u("div", c, [o(t2, { modelValue: h.value, "onUpdate:modelValue": l2[0] || (l2[0] = (e3) => h.value = e3), type: V.value, format: e2.format, "value-format": e2.valueFormat, disabled: e2.disabled, clearable: e2.clearable, readonly: e2.readonly, shortcuts: D.value, placeholder: p.value, size: e2.size, "disabled-date": z, onChange: S, onBlur: l2[1] || (l2[1] = (e3) => C("blur", e3)), onFocus: l2[2] || (l2[2] = (e3) => C("focus", e3)), onVisibleChange: l2[3] || (l2[3] = (e3) => C("visible-change", e3)), onPanelChange: l2[4] || (l2[4] = (e3) => C("panel-change", e3)), onClear: l2[5] || (l2[5] = (e3) => C("clear", e3)) }, null, 8, ["modelValue", "type", "format", "value-format", "disabled", "clearable", "readonly", "shortcuts", "placeholder", "size"]), l2[12] || (l2[12] = i("span", { class: "sep" }, "-", -1)), o(t2, { modelValue: b.value, "onUpdate:modelValue": l2[6] || (l2[6] = (e3) => b.value = e3), type: V.value, format: e2.format, "value-format": e2.valueFormat, disabled: e2.disabled, clearable: e2.clearable, readonly: e2.readonly, shortcuts: D.value, placeholder: g.value, size: e2.size, "disabled-date": F, onChange: x, onBlur: l2[7] || (l2[7] = (e3) => C("blur", e3)), onFocus: l2[8] || (l2[8] = (e3) => C("focus", e3)), onVisibleChange: l2[9] || (l2[9] = (e3) => C("visible-change", e3)), onPanelChange: l2[10] || (l2[10] = (e3) => C("panel-change", e3)), onClear: l2[11] || (l2[11] = (e3) => C("clear", e3)) }, null, 8, ["modelValue", "type", "format", "value-format", "disabled", "clearable", "readonly", "shortcuts", "placeholder", "size"])]);
89
89
  };
90
90
  } });
91
91
  export {
92
- p as default
92
+ m as default
93
93
  };
@@ -1,13 +1,14 @@
1
- import { defineComponent as e, ref as t, resolveComponent as l, openBlock as r, createBlock as o, unref as a, isRef as n, withCtx as i, createElementVNode as m, toDisplayString as s, createCommentVNode as p } from "vue";
1
+ import { defineComponent as e, ref as t, resolveComponent as l, openBlock as o, createBlock as r, unref as a, isRef as n, withCtx as i, createElementVNode as s, toDisplayString as m, createCommentVNode as p } from "vue";
2
2
  import c from "./department-tree-inline-app.vue.mjs";
3
3
  const d = { style: { "text-align": "center" } }, u = e({ name: "DepartmentTreeMobile", props: { multiple: {}, departmentInfo: {}, selectDepartmentInfo: {}, searchField: {}, separator: {}, limitFilterColumn: {} }, emits: ["close"], setup(e2, { emit: u2 }) {
4
- let f = t(true);
5
- function I(e3) {
6
- u2("close", e3), f.value = false;
4
+ const f = u2;
5
+ let I = t(true);
6
+ function F(e3) {
7
+ f("close", e3), I.value = false;
7
8
  }
8
- return (e3, t2) => {
9
- const u3 = l("el-drawer");
10
- return r(), o(u3, { modelValue: a(f), "onUpdate:modelValue": t2[0] || (t2[0] = (e4) => n(f) ? f.value = e4 : f = e4), "append-to-body": "", "close-on-click-modal": false, "close-on-press-escape": false, direction: "btt", size: "100%", class: "organization-tree", onClose: t2[1] || (t2[1] = (e4) => I()) }, { header: i(() => [m("div", d, s(e3.$t("imatrixUIMessage.pleaseSelect")), 1)]), default: i(() => [a(f) ? (r(), o(c, { key: 0, multiple: e3.multiple, departmentInfo: e3.departmentInfo, selectDepartmentInfo: e3.selectDepartmentInfo, searchField: e3.searchField, separator: e3.separator, limitFilterColumn: e3.limitFilterColumn, onClose: I }, null, 8, ["multiple", "departmentInfo", "selectDepartmentInfo", "searchField", "separator", "limitFilterColumn"])) : p("", true)]), _: 1 }, 8, ["modelValue"]);
9
+ return (t2, u3) => {
10
+ const f2 = l("el-drawer");
11
+ return o(), r(f2, { modelValue: a(I), "onUpdate:modelValue": u3[0] || (u3[0] = (e3) => n(I) ? I.value = e3 : I = e3), "append-to-body": "", "close-on-click-modal": false, "close-on-press-escape": false, direction: "btt", size: "100%", class: "organization-tree", onClose: u3[1] || (u3[1] = (e3) => F()) }, { header: i(() => [s("div", d, m(t2.$t("imatrixUIMessage.pleaseSelect")), 1)]), default: i(() => [a(I) ? (o(), r(c, { key: 0, multiple: e2.multiple, departmentInfo: e2.departmentInfo, selectDepartmentInfo: e2.selectDepartmentInfo, searchField: e2.searchField, separator: e2.separator, limitFilterColumn: e2.limitFilterColumn, onClose: F }, null, 8, ["multiple", "departmentInfo", "selectDepartmentInfo", "searchField", "separator", "limitFilterColumn"])) : p("", true)]), _: 1 }, 8, ["modelValue"]);
11
12
  };
12
13
  } });
13
14
  export {