@web-utils/form-ui 1.0.0-beta93 → 1.0.0-beta95

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 (139) hide show
  1. package/chunks/{6dpdFLpv2.mjs → B0i3ywbn2.mjs} +35 -44
  2. package/chunks/{Cv1iIzzy2.mjs → BanS-yUY2.mjs} +1 -1
  3. package/chunks/{BZw-uhPj.mjs → C23Qaggp.mjs} +27 -26
  4. package/chunks/{n1KViU9y2.mjs → CIVnqVAQ2.mjs} +12 -9
  5. package/chunks/{JUkvPXqc.mjs → CZxWWk4N.mjs} +8 -8
  6. package/chunks/{BKdkhZkk2.mjs → D7kTwnJK2.mjs} +1 -1
  7. package/chunks/{C6l7TFPU.mjs → D8C17D2k.mjs} +7 -7
  8. package/chunks/{DngNYJVa2.mjs → DzfHfYvS2.mjs} +1 -1
  9. package/chunks/{5BOS55Lv2.mjs → NYkLWtyw2.mjs} +1 -1
  10. package/chunks/{BpZ0yk642.mjs → bBwzYT0T2.mjs} +23 -18
  11. package/chunks/{-d4DuTH12.mjs → dgRz6V6p2.mjs} +1 -1
  12. package/chunks/qIca9lDu2.mjs +108 -0
  13. package/chunks/{DRkvaPr32.mjs → q_m3gw_j2.mjs} +11 -8
  14. package/chunks/{BTVXdtOG.mjs → sCsjgWvR.mjs} +104 -95
  15. package/chunks/{D6B1lNKn2.mjs → v2GLQDzI2.mjs} +18 -18
  16. package/data-table-picker/index.mjs +1 -1
  17. package/form-cascader/index.mjs +1 -1
  18. package/form-checkbox-group/index.mjs +1 -1
  19. package/form-input/index.d.ts +3 -3
  20. package/form-input/index.mjs +1 -1
  21. package/form-input-email/index.d.ts +3 -3
  22. package/form-input-email/index.mjs +1 -1
  23. package/form-input-id-card/index.d.ts +3 -3
  24. package/form-input-id-card/index.mjs +1 -1
  25. package/form-input-number/index.d.ts +2 -2
  26. package/form-input-number/index.mjs +1 -1
  27. package/form-input-phone-number/index.d.ts +3 -3
  28. package/form-input-phone-number/index.mjs +1 -1
  29. package/form-radio-group/index.mjs +1 -1
  30. package/form-select/index.mjs +1 -1
  31. package/form-table/index.d.ts +2 -0
  32. package/form-table/index.mjs +1 -1
  33. package/form-table-plus/index.d.ts +2 -2
  34. package/form-table-plus/index.mjs +1 -1
  35. package/form-textarea/index.d.ts +1 -1
  36. package/form-textarea/index.mjs +1 -1
  37. package/index.mjs +15 -15
  38. package/package.json +3 -4
  39. package/pageable-table/index.d.ts +2 -2
  40. package/pageable-table/index.mjs +1 -1
  41. package/props/input-number.d.ts +1 -1
  42. package/props/input-number.mjs +5 -1
  43. package/props/input.d.ts +1 -1
  44. package/props/input.mjs +3 -2
  45. package/sub-table/index.d.ts +2 -0
  46. package/sub-table/index.mjs +1 -1
  47. package/sub-table-plus/index.d.ts +2 -0
  48. package/sub-table-plus/index.mjs +1 -1
  49. package/table-view/index.d.ts +3 -0
  50. package/table-view/index.mjs +13 -18
  51. package/vue/directives/chat-drag.d.ts +2 -0
  52. package/vue/directives/chat-drag.mjs +12 -0
  53. package/vue/directives/click-outside.d.ts +10 -0
  54. package/vue/directives/click-outside.mjs +36 -0
  55. package/vue/directives/dialog-drag.d.ts +2 -0
  56. package/vue/directives/dialog-drag.mjs +15 -0
  57. package/vue/directives/drag-move.d.ts +10 -0
  58. package/vue/directives/drag-move.mjs +27 -0
  59. package/vue/directives/fix-fixed-column-height.d.ts +7 -0
  60. package/vue/directives/fix-fixed-column-height.mjs +20 -0
  61. package/vue/directives/index.d.ts +7 -0
  62. package/vue/directives/index.mjs +8 -0
  63. package/vue/directives/resize.d.ts +2 -0
  64. package/vue/directives/resize.mjs +12 -0
  65. package/vue/directives/scroll-bottom.d.ts +5 -0
  66. package/vue/directives/scroll-bottom.mjs +6 -0
  67. package/vue/hooks/index.d.ts +3 -0
  68. package/vue/hooks/index.mjs +4 -0
  69. package/{hook → vue/hooks}/useDictionary.d.ts +1 -1
  70. package/{hook → vue/hooks}/useDictionary.mjs +2 -2
  71. package/vue/hooks/useEventBus.d.ts +1 -0
  72. package/vue/hooks/useEventBus.mjs +20 -0
  73. package/{hook → vue/hooks}/useVisibilityChange.mjs +1 -1
  74. package/vue/index.d.ts +3 -0
  75. package/vue/index.mjs +83 -0
  76. package/vue/mixin/bus.d.ts +5 -0
  77. package/vue/mixin/bus.mjs +33 -0
  78. package/vue/mixin/dialog.d.ts +38 -0
  79. package/vue/mixin/dialog.mjs +2 -0
  80. package/vue/mixin/index.d.ts +6 -0
  81. package/vue/mixin/index.mjs +7 -0
  82. package/vue/mixin/message.d.ts +2 -0
  83. package/vue/mixin/message.mjs +27 -0
  84. package/vue/mixin/multi-items.d.ts +43 -0
  85. package/vue/mixin/multi-items.mjs +70 -0
  86. package/vue/mixin/page.d.ts +28 -0
  87. package/vue/mixin/page.mjs +38 -0
  88. package/vue/mixin/resize-mixin.d.ts +15 -0
  89. package/vue/mixin/resize-mixin.mjs +24 -0
  90. package/web-types.json +1 -1
  91. package/chunks/DML17Idh2.mjs +0 -108
  92. package/column/index.d.ts +0 -38
  93. package/column-default/index.d.ts +0 -77
  94. package/column-dynamic/index.d.ts +0 -8
  95. package/column-menu/index.d.ts +0 -81
  96. package/column-slot/index.d.ts +0 -21
  97. package/dialog-column/index.d.ts +0 -19
  98. package/dialog-excel/index.d.ts +0 -16
  99. package/dialog-filter/index.d.ts +0 -20
  100. package/element-base-info/index.d.ts +0 -35
  101. package/element-form/index.d.ts +0 -45
  102. package/element-listeners/index.d.ts +0 -42
  103. package/element-multi-instance/index.d.ts +0 -29
  104. package/element-other-config/index.d.ts +0 -14
  105. package/element-properties/index.d.ts +0 -21
  106. package/element-task-config/index.d.ts +0 -89
  107. package/flow-condition/index.d.ts +0 -16
  108. package/form-group/index.d.ts +0 -62
  109. package/form-temp/index.d.ts +0 -11286
  110. package/fy-dialog-form/index.d.ts +0 -1014
  111. package/fy-form-menu/index.d.ts +0 -9
  112. package/header-menu/index.d.ts +0 -86
  113. package/header-search/index.d.ts +0 -32
  114. package/process-designer/index.d.ts +0 -176
  115. package/process-palette/index.d.ts +0 -9
  116. package/properties-panel/index.d.ts +0 -97
  117. package/receive-task/index.d.ts +0 -20
  118. package/script-task/index.d.ts +0 -21
  119. package/signal-and-message/index.d.ts +0 -22
  120. package/table-column-filterable/index.d.ts +0 -163
  121. package/table-column-setting-panel/index.d.ts +0 -14
  122. package/table-page/index.d.ts +0 -23
  123. package/trigger/index.d.ts +0 -25
  124. package/user-task/index.d.ts +0 -24
  125. package/user-task-listeners/index.d.ts +0 -45
  126. package/vue-tree-select-arrow/index.d.ts +0 -2
  127. package/vue-tree-select-control/index.d.ts +0 -2
  128. package/vue-tree-select-delete/index.d.ts +0 -2
  129. package/vue-tree-select-hidden-fields/index.d.ts +0 -2
  130. package/vue-tree-select-input/index.d.ts +0 -2
  131. package/vue-tree-select-menu/index.d.ts +0 -2
  132. package/vue-tree-select-menu-portal/index.d.ts +0 -2
  133. package/vue-tree-select-multi-value/index.d.ts +0 -2
  134. package/vue-tree-select-multi-value-item/index.d.ts +0 -12
  135. package/vue-tree-select-option/index.d.ts +0 -12
  136. package/vue-tree-select-placeholder/index.d.ts +0 -2
  137. package/vue-tree-select-portal-target/index.d.ts +0 -2
  138. package/vue-tree-select-single-value/index.d.ts +0 -2
  139. /package/{hook → vue/hooks}/useVisibilityChange.d.ts +0 -0
@@ -1,49 +1,39 @@
1
1
  import { i as e } from "./ClVh1Lek.mjs";
2
2
  import { commonAutoBindProps as t, commonManualBindProps as n } from "../props/common.mjs";
3
3
  import { n as r, o as i } from "./_7MDfW_y.mjs";
4
- import { n as a } from "./BZw-uhPj.mjs";
5
- import { n as o, t as s } from "./DRkvaPr32.mjs";
4
+ import { n as a } from "./C23Qaggp.mjs";
5
+ import { n as o, t as s } from "./q_m3gw_j2.mjs";
6
6
  import { computed as c, createVNode as l, getCurrentInstance as u, mergeProps as d, useModel as f, useTemplateRef as p } from "vue";
7
- import { isArray as m, isString as h, trace as g, warning as _ } from "@web-utils/core";
8
- import { useEventBus as v } from "@web-utils/vue/hooks/useEventBus";
9
7
  //#region src/components/table/form-table-plus.ts
10
- var y = {
8
+ var m = {
11
9
  ...n,
12
10
  ...t,
13
11
  ...o,
14
12
  rowDbClick: Function,
15
- viewId: [String, Array],
16
13
  formPath: [String, Function]
17
- }, b = {
14
+ }, h = {
18
15
  readonly: !0,
19
- block: !0
20
- }, x = (e) => n[e] === void 0 && b[e] !== !0, S = {
16
+ block: !0,
17
+ viewId: !0
18
+ }, g = (e) => n[e] === void 0 && h[e] !== !0, _ = {
21
19
  name: "FormTablePlus",
22
- props: { ...y },
20
+ props: { ...m },
23
21
  emits: { ...r },
24
- setup(t, { emit: n, slots: r, attrs: o, expose: y }) {
25
- let b = f(t, "modelValue"), S = p("table"), C = [];
26
- t.viewId && C.push(t.viewId);
27
- let w = u();
28
- C.includes(w.parent.proxy.$options.name) || C.push(w.parent.proxy.$options.name);
29
- let T = () => {
22
+ setup(t, { emit: n, slots: r, attrs: o, expose: m }) {
23
+ let h = f(t, "modelValue"), _ = p("table"), v = u(), y = c(() => {
24
+ let e = [];
25
+ return t.viewId && e.push(t.viewId), e.includes(v.parent.proxy.$options.name) || e.push(v.parent.proxy.$options.name), e;
26
+ }), b = () => {
30
27
  var e;
31
- return (e = S.value.table) == null ? void 0 : e.reloadTable();
32
- }, E = async () => {
28
+ return (e = _.value.table) == null ? void 0 : e.reloadTable();
29
+ }, x = async () => {
33
30
  var e;
34
- return await ((e = S.value.table) == null ? void 0 : e.refreshTable());
35
- };
36
- v("reloadTableView", (e) => {
37
- if (C) if (h(e) || m(e)) {
38
- let t = e;
39
- h(t) && (t = t.split(",")), C.some((e) => t.includes(e)) && (g.call(w.parent.proxy || {}, "reloadTableView"), T());
40
- } else _.call(w.parent.proxy || {}, "`viewId`的类型必须是字符串或数组");
41
- });
42
- let D = (...n) => {
43
- t.rowDbClick ? t.rowDbClick(...n) : t.formPath && w.proxy.$router.push(e(t.formPath, n[0]));
44
- }, O = () => {
45
- w.proxy.$router.push(e(t.formPath));
46
- }, { render: k, placeholder: A, disabled: j, listeners: M, inputProps: N } = i(t, {
31
+ return await ((e = _.value.table) == null ? void 0 : e.refreshTable());
32
+ }, S = (...n) => {
33
+ t.rowDbClick ? t.rowDbClick(...n) : t.formPath && v.proxy.$router.push(e(t.formPath, n[0]));
34
+ }, C = () => {
35
+ v.proxy.$router.push(e(t.formPath));
36
+ }, { render: w, placeholder: T, disabled: E, listeners: D, inputProps: O } = i(t, {
47
37
  rules: c(() => [t.fetchApi ? {
48
38
  required: !0,
49
39
  validator: a
@@ -51,12 +41,12 @@ var y = {
51
41
  emit: n,
52
42
  slots: r,
53
43
  attrs: o,
54
- predicate: x,
44
+ predicate: g,
55
45
  block: t.block === void 0 ? !0 : t.block
56
46
  });
57
- return y({
58
- reloadTable: T,
59
- refreshTable: E
47
+ return m({
48
+ reloadTable: b,
49
+ refreshTable: x
60
50
  }), () => {
61
51
  var e;
62
52
  let n = {};
@@ -73,15 +63,16 @@ var y = {
73
63
  });
74
64
  };
75
65
  }
76
- return k({ vNodes: l(s, d({ ref: "table" }, M.value, N.value, {
66
+ return w({ vNodes: l(s, d({ ref: "table" }, D.value, O.value, {
77
67
  prop: t.prop,
78
- disabled: j.value,
79
- onRowDbClick: D,
80
- rowDbClick: D,
81
- modelValue: b.value,
82
- "onUpdate:modelValue": (e) => b.value = e,
83
- placeholder: A.value,
84
- onAddRow: O
68
+ disabled: E.value,
69
+ onRowDbClick: S,
70
+ rowDbClick: S,
71
+ modelValue: h.value,
72
+ "onUpdate:modelValue": (e) => h.value = e,
73
+ viewId: y.value,
74
+ placeholder: T.value,
75
+ onAddRow: C
85
76
  }), {
86
77
  ...n,
87
78
  columns: ({ columns: e }) => {
@@ -142,4 +133,4 @@ var y = {
142
133
  }
143
134
  };
144
135
  //#endregion
145
- export { S as t };
136
+ export { _ as t };
@@ -27,7 +27,7 @@ var l = {
27
27
  placeholder: p.value
28
28
  }), {
29
29
  prefix: l.prefix || e.prefix ? () => e.prefix : null,
30
- suffix: l.suffix || e.suffix ? () => e.suffix : e.append,
30
+ suffix: l.suffix || e.suffix ? () => e.suffix : () => e.append,
31
31
  "decrease-icon": l["decrease-icon"],
32
32
  "increase-icon": l["increase-icon"]
33
33
  }) });
@@ -4,14 +4,14 @@ import { ElInput as a } from "element-plus/es";
4
4
  import "element-plus/es/components/base/style/css";
5
5
  import "element-plus/es/components/input/style/css";
6
6
  import { computed as o, createVNode as s, mergeProps as c, useModel as l } from "vue";
7
- import { validatePhoneNum as u } from "@web-utils/core";
7
+ import { isString as u, validatePhoneNum as d } from "@web-utils/core";
8
8
  import "../form-input/style.css";
9
9
  //#region src/utils/form-validate.ts
10
- var d = (e, t, n) => t && !/^[A-Za-z0-9\u4e00-\u9fa5_-]+@[a-zA-Z0-9_-]+(\.[a-zA-Z0-9_-]+)+$/.test(t) ? n(/* @__PURE__ */ Error("invalid")) : n();
11
- function f(e, t, n) {
10
+ var f = (e, t, n) => t && !/^[A-Za-z0-9\u4e00-\u9fa5_-]+@[a-zA-Z0-9_-]+(\.[a-zA-Z0-9_-]+)+$/.test(t) ? n(/* @__PURE__ */ Error("invalid")) : n();
11
+ function p(e, t, n) {
12
12
  t && !/^[1-9][0-9]{5}(18|19|(2[0-9]))[0-9]{2}((0[1-9])|(10|11|12))(([0-2][1-9])|10|20|30|31)[0-9]{3}[0-9Xx]$/.test(t) ? n(/* @__PURE__ */ Error("invalid")) : n();
13
13
  }
14
- function p(e, t, n) {
14
+ function m(e, t, n) {
15
15
  if (this.$refs.table.$refs.table.records.length === 0) {
16
16
  n(Error(e.message || `请添加${e.label}`));
17
17
  return;
@@ -20,50 +20,51 @@ function p(e, t, n) {
20
20
  }
21
21
  //#endregion
22
22
  //#region src/components/form/FormInput.vue
23
- var m = {
23
+ var h = {
24
24
  name: "FormInput",
25
25
  inheritAttrs: !1,
26
26
  props: { ...r },
27
27
  emits: { ...e },
28
- setup(e, { emit: r, slots: p, attrs: m }) {
29
- let h = l(e, "modelValue"), g = `请输入正确的${e.label}!`, { render: _, placeholder: v, disabled: y, listeners: b, inputProps: x, printing: S } = t(e, {
28
+ setup(e, { emit: r, slots: m, attrs: h }) {
29
+ let g = l(e, "modelValue"), _ = `请输入正确的${e.label}!`, { render: v, placeholder: y, disabled: b, listeners: x, inputProps: S, printing: C } = t(e, {
30
30
  emit: r,
31
- slots: p,
32
- attrs: m,
31
+ slots: m,
32
+ attrs: h,
33
33
  rules: o(() => {
34
34
  if (!e.type || e.type === "textarea") return null;
35
35
  let t = {
36
- message: g,
36
+ message: _,
37
37
  trigger: "blur"
38
38
  };
39
- if (e.type === "email") t.validator = d;
40
- else if (e.type === "idcard") t.validator = f;
41
- else if (e.type === "phone") t.validator = u;
39
+ if (e.type === "email") t.validator = f;
40
+ else if (e.type === "idcard") t.validator = p;
41
+ else if (e.type === "phone") t.validator = d;
42
42
  else return null;
43
43
  return [t];
44
44
  }),
45
45
  predicate: i
46
- });
47
- return () => _({ vNodes: S.value ? e.modelValue : s(a, c(b.value, x.value, {
46
+ }), w = o(() => u(e.rows) ? Number(e.rows) : e.rows);
47
+ return () => v({ vNodes: C.value ? e.modelValue : s(a, c(x.value, S.value, {
48
48
  class: ["form-input", {
49
49
  "is-readonly": e.readonlyGrey && e.readonly && !e.picker,
50
- "el-input-cursor-pointer": e.picker && !y.value
50
+ "el-input-cursor-pointer": e.picker && !b.value
51
51
  }],
52
- modelValue: h.value,
53
- "onUpdate:modelValue": (e) => h.value = e,
54
- disabled: y.value,
55
- placeholder: v.value,
52
+ modelValue: g.value,
53
+ "onUpdate:modelValue": (e) => g.value = e,
54
+ disabled: b.value,
55
+ rows: w.value,
56
+ placeholder: y.value,
56
57
  readonly: e.readonly || e.picker,
57
58
  "prefix-icon": n({ icon: e.picker ? "el-icon-search" : e.prefixIcon }),
58
59
  "suffix-icon": n({ icon: e.suffixIcon })
59
60
  }), {
60
- prefix: p.prefix || e.prefix ? () => e.prefix : null,
61
- suffix: p.suffix || e.suffix ? () => e.suffix : null,
62
- "password-icon": p["password-icon"],
63
- prepend: p.prepend || e.prepend ? () => e.prepend : null,
64
- append: p.append || e.append ? () => e.append : null
61
+ prefix: m.prefix || e.prefix ? () => e.prefix : null,
62
+ suffix: m.suffix || e.suffix ? () => e.suffix : null,
63
+ "password-icon": m["password-icon"],
64
+ prepend: m.prepend || e.prepend ? () => e.prepend : null,
65
+ append: m.append || e.append ? () => e.append : null
65
66
  }) });
66
67
  }
67
68
  };
68
69
  //#endregion
69
- export { p as n, m as t };
70
+ export { m as n, h as t };
@@ -1,17 +1,17 @@
1
1
  import { t as e } from "./B1MSrc6f.mjs";
2
2
  import { t } from "./DTeHffqJ.mjs";
3
- import { t as n } from "./BTVXdtOG.mjs";
3
+ import { t as n } from "./sCsjgWvR.mjs";
4
4
  import { t as r } from "./tzjUpVIj.mjs";
5
5
  import { n as i } from "./_7MDfW_y.mjs";
6
- import { t as a } from "./C6l7TFPU.mjs";
7
- import { t as o } from "./BZw-uhPj.mjs";
8
- import { t as s } from "./JUkvPXqc.mjs";
6
+ import { t as a } from "./D8C17D2k.mjs";
7
+ import { t as o } from "./C23Qaggp.mjs";
8
+ import { t as s } from "./CZxWWk4N.mjs";
9
9
  import { t as c } from "./CCkHwxt7.mjs";
10
- import { t as l } from "./Cv1iIzzy2.mjs";
11
- import { t as u } from "./-d4DuTH12.mjs";
12
- import { t as d } from "./DML17Idh2.mjs";
10
+ import { t as l } from "./BanS-yUY2.mjs";
11
+ import { t as u } from "./dgRz6V6p2.mjs";
12
+ import { t as d } from "./qIca9lDu2.mjs";
13
13
  import f from "../table-column-def/index.mjs";
14
- import { t as p } from "./BKdkhZkk2.mjs";
14
+ import { t as p } from "./D7kTwnJK2.mjs";
15
15
  import { ElMessage as m, formContextKey as h, formItemContextKey as g } from "element-plus/es";
16
16
  import "element-plus/es/components/base/style/css";
17
17
  import { Fragment as _, createBlock as v, createCommentVNode as y, createElementBlock as b, createElementVNode as x, createSlots as S, createTextVNode as C, createVNode as w, mergeProps as T, openBlock as E, renderList as D, renderSlot as O, resolveComponent as k, toDisplayString as A, withCtx as j, withModifiers as M } from "vue";
@@ -57,7 +57,8 @@ var I = {
57
57
  rowKey: {
58
58
  type: [Function, String],
59
59
  default: "id"
60
- }
60
+ },
61
+ viewId: [String, Array]
61
62
  }, L = {
62
63
  name: "SubTable",
63
64
  emits: {
@@ -196,6 +197,7 @@ function V(e, i, m, h, g, N) {
196
197
  "show-summary": e.showSummary,
197
198
  "selection-width": e.selectionWidth
198
199
  }, e.$attrs, {
200
+ "view-id": e.viewId,
199
201
  "row-key": e.rowKey,
200
202
  "hide-on-single-page": "",
201
203
  selection: N.enabled,
@@ -415,6 +417,7 @@ function V(e, i, m, h, g, N) {
415
417
  "api",
416
418
  "show-summary",
417
419
  "selection-width",
420
+ "view-id",
418
421
  "row-key",
419
422
  "selection",
420
423
  "row-db-click",
@@ -1,7 +1,7 @@
1
1
  import { allProps as e, predicate as t } from "../props/checkbox-group.mjs";
2
- import { n, o as r } from "./_7MDfW_y.mjs";
3
- import { useDictionary as i } from "../hook/useDictionary.mjs";
4
- import { t as a } from "./BZw-uhPj.mjs";
2
+ import { useDictionary as n } from "../vue/hooks/useDictionary.mjs";
3
+ import { n as r, o as i } from "./_7MDfW_y.mjs";
4
+ import { t as a } from "./C23Qaggp.mjs";
5
5
  import { ElCheckbox as o, ElCheckboxButton as s, ElCheckboxGroup as c } from "element-plus/es";
6
6
  import "element-plus/es/components/base/style/css";
7
7
  import { computed as l, createVNode as u, defineComponent as d, isVNode as f, mergeProps as p, useModel as m } from "vue";
@@ -20,12 +20,12 @@ var g = /* @__PURE__ */ d({
20
20
  inheritAttrs: !1,
21
21
  props: { ...e },
22
22
  emits: {
23
- ...n,
23
+ ...r,
24
24
  "update:other": null
25
25
  },
26
- setup(e, { emit: n, slots: d, attrs: f }) {
27
- let g = m(e, "other"), { emitInput: _, render: v, disabled: y, listeners: b, inputProps: x } = r(e, {
28
- emit: n,
26
+ setup(e, { emit: r, slots: d, attrs: f }) {
27
+ let g = m(e, "other"), { emitInput: _, render: v, disabled: y, listeners: b, inputProps: x } = i(e, {
28
+ emit: r,
29
29
  slots: d,
30
30
  attrs: f,
31
31
  predicate: t,
@@ -44,7 +44,7 @@ var g = /* @__PURE__ */ d({
44
44
  return Array.isArray(e.modelValue) ? e.modelValue.filter((e) => e) : ((t = e.modelValue) == null ? void 0 : t.split(e.delimiter).filter((e) => e)) ?? [];
45
45
  }
46
46
  return e.modelValue || [];
47
- }), w = l(() => e.classic ? "label" : e.labelProp), T = l(() => e.classic ? "value" : e.valueProp), { dictItems: E } = i(e), D = l(() => e.dictType ? E.value : e.gender ? [{
47
+ }), w = l(() => e.classic ? "label" : e.labelProp), T = l(() => e.classic ? "value" : e.valueProp), { dictItems: E } = n(e), D = l(() => e.dictType ? E.value : e.gender ? [{
48
48
  [w.value]: "男",
49
49
  [T.value]: "男"
50
50
  }, {
@@ -1,5 +1,5 @@
1
1
  import { n as e } from "./_7MDfW_y.mjs";
2
- import { t } from "./BZw-uhPj.mjs";
2
+ import { t } from "./C23Qaggp.mjs";
3
3
  import { allProps as n } from "../props/textarea.mjs";
4
4
  import { createVNode as r, isVNode as i, mergeProps as a, useModel as o } from "vue";
5
5
  //#region src/components/form/FormTextarea.vue?vue&type=script&lang.jsx
@@ -1,6 +1,6 @@
1
1
  import { allProps as e, predicate as t } from "../props/cascader.mjs";
2
- import { n, o as r } from "./_7MDfW_y.mjs";
3
- import { useDictionary as i } from "../hook/useDictionary.mjs";
2
+ import { useDictionary as n } from "../vue/hooks/useDictionary.mjs";
3
+ import { n as r, o as i } from "./_7MDfW_y.mjs";
4
4
  import { ElCascader as a } from "element-plus/es";
5
5
  import "element-plus/es/components/base/style/css";
6
6
  import "element-plus/es/components/cascader/style/css";
@@ -12,14 +12,14 @@ import { cloneDeep as p } from "@web-utils/integrations/lodash";
12
12
  var m = {
13
13
  name: "FormCascader",
14
14
  props: { ...e },
15
- emits: { ...n },
16
- setup(e, { emit: n, slots: m, attrs: h }) {
17
- let { emitInput: g, render: _, placeholder: v, disabled: y, listeners: b, inputProps: x } = r(e, {
18
- emit: n,
15
+ emits: { ...r },
16
+ setup(e, { emit: r, slots: m, attrs: h }) {
17
+ let { emitInput: g, render: _, placeholder: v, disabled: y, listeners: b, inputProps: x } = i(e, {
18
+ emit: r,
19
19
  slots: m,
20
20
  attrs: h,
21
21
  predicate: t
22
- }), { dictItems: S } = i(e), C = o(() => {
22
+ }), { dictItems: S } = n(e), C = o(() => {
23
23
  if (e.dictType) return S.value;
24
24
  if (e.options) {
25
25
  let t = p(e.options);
@@ -1,5 +1,5 @@
1
1
  import { n as e } from "./_7MDfW_y.mjs";
2
- import { t } from "./BZw-uhPj.mjs";
2
+ import { t } from "./C23Qaggp.mjs";
3
3
  import { allProps as n } from "../props/input.mjs";
4
4
  import { createVNode as r, isVNode as i, mergeProps as a, useModel as o } from "vue";
5
5
  //#region src/components/form/FormInputIdCard.vue?vue&type=script&lang.jsx
@@ -1,5 +1,5 @@
1
1
  import { n as e } from "./_7MDfW_y.mjs";
2
- import { t } from "./BZw-uhPj.mjs";
2
+ import { t } from "./C23Qaggp.mjs";
3
3
  import { allProps as n } from "../props/input.mjs";
4
4
  import { createVNode as r, isVNode as i, mergeProps as a, useModel as o } from "vue";
5
5
  //#region src/components/form/FormInputEmail.vue?vue&type=script&lang.jsx
@@ -1,30 +1,34 @@
1
1
  import { commonAutoBindProps as e, commonManualBindProps as t } from "../props/common.mjs";
2
2
  import { n, o as r } from "./_7MDfW_y.mjs";
3
- import { n as i, t as a } from "./n1KViU9y2.mjs";
4
- import { createVNode as o, mergeProps as s, ref as c, useModel as l } from "vue";
3
+ import { n as i, t as a } from "./CIVnqVAQ2.mjs";
4
+ import { computed as o, createVNode as s, getCurrentInstance as c, mergeProps as l, ref as u, useModel as d } from "vue";
5
5
  //#region src/components/table/form-table.ts
6
- var u = {
6
+ var f = {
7
7
  ...t,
8
8
  ...e,
9
9
  ...i
10
- }, d = {
10
+ }, p = {
11
11
  modelValue: !0,
12
- block: !0
13
- }, f = (e) => t[e] === void 0 && d[e] !== !0, p = {
12
+ block: !0,
13
+ viewId: !0
14
+ }, m = (e) => t[e] === void 0 && p[e] !== !0, h = {
14
15
  name: "FormTable",
15
- props: { ...u },
16
+ props: { ...f },
16
17
  emits: {
17
18
  ...n,
18
19
  "add-row": null
19
20
  },
20
21
  setup(e, { emit: t, attrs: n, slots: i }) {
21
- let u = l(e, "modelValue"), d = c([]), p = (e) => {
22
- d.value = e;
23
- }, { render: m, placeholder: h, disabled: g, listeners: _, inputProps: v } = r(e, {
22
+ let f = d(e, "modelValue"), p = c(), h = o(() => {
23
+ let t = [];
24
+ return e.viewId && t.push(e.viewId), t.includes(p.parent.proxy.$options.name) || t.push(p.parent.proxy.$options.name), t;
25
+ }), g = u([]), _ = (e) => {
26
+ g.value = e;
27
+ }, { render: v, placeholder: y, disabled: b, listeners: x, inputProps: S } = r(e, {
24
28
  emit: t,
25
29
  slots: i,
26
30
  attrs: n,
27
- predicate: f,
31
+ predicate: m,
28
32
  block: e.block === void 0 ? !0 : e.block
29
33
  });
30
34
  return () => {
@@ -37,12 +41,13 @@ var u = {
37
41
  return (a = i[t.prop]) == null ? void 0 : a.call(i, e, n, r);
38
42
  };
39
43
  }
40
- return m({ vNodes: o(a, s(_.value, v.value, {
41
- disabled: g.value,
42
- modelValue: u.value,
43
- "onUpdate:modelValue": (e) => u.value = e,
44
- placeholder: h.value,
45
- onSelectionChange: p
44
+ return v({ vNodes: s(a, l(x.value, S.value, {
45
+ disabled: b.value,
46
+ viewId: h.value,
47
+ modelValue: f.value,
48
+ "onUpdate:modelValue": (e) => f.value = e,
49
+ placeholder: y.value,
50
+ onSelectionChange: _
46
51
  }), {
47
52
  ...n,
48
53
  columns: ({ columns: e }) => {
@@ -84,4 +89,4 @@ var u = {
84
89
  }
85
90
  };
86
91
  //#endregion
87
- export { p as t };
92
+ export { h as t };
@@ -1,5 +1,5 @@
1
1
  import { n as e } from "./_7MDfW_y.mjs";
2
- import { t } from "./BZw-uhPj.mjs";
2
+ import { t } from "./C23Qaggp.mjs";
3
3
  import { allProps as n } from "../props/input.mjs";
4
4
  import { createVNode as r, isVNode as i, mergeProps as a, useModel as o } from "vue";
5
5
  //#region src/components/form/FormInputPhoneNumber.vue?vue&type=script&lang.jsx
@@ -0,0 +1,108 @@
1
+ import { useDictionary as e } from "../vue/hooks/useDictionary.mjs";
2
+ import { n as t, o as n } from "./_7MDfW_y.mjs";
3
+ import { allProps as r, predicate as i } from "../props/select.mjs";
4
+ import { ElOption as a, ElSelect as o } from "element-plus/es";
5
+ import "element-plus/es/components/base/style/css";
6
+ import { computed as s, createVNode as c, mergeProps as l, ref as u, watchEffect as d } from "vue";
7
+ import { isNumber as f, isPlainObject as p, isString as m } from "@web-utils/core";
8
+ import "element-plus/es/components/select/style/css";
9
+ import "element-plus/es/components/option/style/css";
10
+ //#endregion
11
+ //#region src/components/form/FormSelect.vue
12
+ var h = {
13
+ name: "FormSelect",
14
+ inheritAttrs: !1,
15
+ props: { ...r },
16
+ emits: { ...t },
17
+ setup(t, { emit: r, slots: h, attrs: g }) {
18
+ let { emitInput: _, render: v, placeholder: y, disabled: b, listeners: x, inputProps: S } = n(t, {
19
+ emit: r,
20
+ slots: h,
21
+ attrs: g,
22
+ predicate: i,
23
+ messagePrefix: "请选择"
24
+ }), C = u(null), w = u(!1);
25
+ d(() => {
26
+ if (t.multiple && t.multipleStringMode) {
27
+ var e;
28
+ C.value = (e = t.modelValue) == null ? void 0 : e.split(",").filter((e) => e);
29
+ } else C.value = t.modelValue;
30
+ });
31
+ let T = (e) => {
32
+ if (t.multiple && t.multipleStringMode ? _(e.join(t.multipleStringSeparator)) : _(e), t.emitLabel) {
33
+ let n = O.value.find((n) => n[t.props.value] === e), i = n == null ? void 0 : n[t.props.label];
34
+ i !== t.optionLabel && r("update:optionLabel", i);
35
+ }
36
+ }, { dictItems: E } = e(t), D = u([]), O = s(() => {
37
+ if (t.dictType) return E.value;
38
+ if (t.remote) return D.value;
39
+ if (t.gender) return [{
40
+ [t.props.label]: "男",
41
+ [t.props.value]: t.chinese ? "男" : t.typing ? 1 : "1"
42
+ }, {
43
+ [t.props.label]: "女",
44
+ [t.props.value]: t.chinese ? "女" : t.typing ? 2 : "2"
45
+ }];
46
+ if (t.confirm) return [{
47
+ [t.props.label]: "是",
48
+ [t.props.value]: t.chinese ? "是" : t.english ? "Y" : t.typing ? 1 : "1"
49
+ }, {
50
+ [t.props.label]: "否",
51
+ [t.props.value]: t.chinese ? "否" : t.english ? "N" : t.typing ? 0 : "0"
52
+ }];
53
+ if (t.all) return [{
54
+ [t.props.value]: "",
55
+ [t.props.label]: "全部"
56
+ }, ...t.options];
57
+ if (t.start && t.end) return Array(t.end - t.start + 1).fill(1).map((e, n) => ({
58
+ [t.props.label]: t.start + n,
59
+ [t.props.value]: t.start + n
60
+ }));
61
+ if (t.year) {
62
+ let e = (/* @__PURE__ */ new Date()).getFullYear(), n = [], r = 10;
63
+ f(t.year) && (r = t.year);
64
+ for (let i = -r; i <= r; i++) {
65
+ let r = e + i;
66
+ n.push({
67
+ [t.props.label]: r,
68
+ [t.props.value]: r
69
+ });
70
+ }
71
+ return n;
72
+ }
73
+ return t.options ? t.options.map((e) => (e[t.props.value] = e[t.props.value] ?? e[t.props.label], e)) : [];
74
+ }), k = async (e) => {
75
+ try {
76
+ var n;
77
+ w.value = !0;
78
+ let r = await t.remoteMethod(e, t.prop);
79
+ ((n = r.data.data) == null ? void 0 : n.length) >= 0 ? m(r.data.data[0]) ? D.value = r.data.data.map((e) => ({
80
+ [t.props.value]: e,
81
+ [t.props.label]: e
82
+ })) : p(r.data.data[0]) && (D.value = r.data.data) : D.value = [];
83
+ } catch {}
84
+ w.value = !1;
85
+ };
86
+ return d(() => {
87
+ t.remote && k();
88
+ }), () => v({ vNodes: c(o, l(x.value, S.value, {
89
+ offset: t.dropDownOffset,
90
+ "model-value": C.value,
91
+ "onUpdate:modelValue": T,
92
+ disabled: b.value,
93
+ placeholder: y.value
94
+ }), {
95
+ ...h,
96
+ default: h.default || (() => {
97
+ var e;
98
+ return (e = O.value) == null ? void 0 : e.map(({ value: e, label: t }) => c(a, {
99
+ key: e,
100
+ label: t,
101
+ value: e
102
+ }, null));
103
+ })
104
+ }) });
105
+ }
106
+ };
107
+ //#endregion
108
+ export { h as t };
@@ -2,17 +2,17 @@ import { s as e } from "./ClVh1Lek.mjs";
2
2
  import { t } from "./B1MSrc6f.mjs";
3
3
  import { cellClickHandlerContextKey as n } from "../constants/index.mjs";
4
4
  import { t as r } from "./DTeHffqJ.mjs";
5
- import { t as i } from "./BTVXdtOG.mjs";
5
+ import { t as i } from "./sCsjgWvR.mjs";
6
6
  import { t as a } from "./tzjUpVIj.mjs";
7
7
  import { n as o } from "./_7MDfW_y.mjs";
8
- import { t as s } from "./C6l7TFPU.mjs";
8
+ import { t as s } from "./D8C17D2k.mjs";
9
9
  import { t as c } from "./CA_-hYlN.mjs";
10
- import { t as l } from "./BZw-uhPj.mjs";
11
- import { t as u } from "./JUkvPXqc.mjs";
10
+ import { t as l } from "./C23Qaggp.mjs";
11
+ import { t as u } from "./CZxWWk4N.mjs";
12
12
  import { t as d } from "./CCkHwxt7.mjs";
13
- import { t as f } from "./Cv1iIzzy2.mjs";
14
- import { t as p } from "./-d4DuTH12.mjs";
15
- import { t as m } from "./DML17Idh2.mjs";
13
+ import { t as f } from "./BanS-yUY2.mjs";
14
+ import { t as p } from "./dgRz6V6p2.mjs";
15
+ import { t as m } from "./qIca9lDu2.mjs";
16
16
  import ee from "../table-column-def/index.mjs";
17
17
  import { ElMessage as h, formContextKey as g, formItemContextKey as _ } from "element-plus/es";
18
18
  import "element-plus/es/components/base/style/css";
@@ -52,7 +52,8 @@ var z = {
52
52
  rowKey: {
53
53
  type: [Function, String],
54
54
  default: "id"
55
- }
55
+ },
56
+ viewId: [String, Array]
56
57
  }, B = {
57
58
  name: "SubTablePlus",
58
59
  inject: {
@@ -230,6 +231,7 @@ function J(e, t, n, o, h, g) {
230
231
  "auto-height": "",
231
232
  data: e.fetchApi ? null : h.rows,
232
233
  api: e.fetchApi,
234
+ "view-id": e.viewId,
233
235
  "payload-style": "body",
234
236
  "show-summary": e.showSummary,
235
237
  descs: e.descs,
@@ -490,6 +492,7 @@ function J(e, t, n, o, h, g) {
490
492
  } : void 0]), 1040, [
491
493
  "data",
492
494
  "api",
495
+ "view-id",
493
496
  "show-summary",
494
497
  "descs",
495
498
  "ascs",