@farris/ui-vue 1.3.5 → 1.3.6

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 (147) hide show
  1. package/components/accordion/index.esm.js +16 -16
  2. package/components/accordion/index.umd.cjs +1 -1
  3. package/components/avatar/index.esm.js +65 -65
  4. package/components/avatar/index.umd.cjs +1 -1
  5. package/components/button-edit/index.esm.js +13 -13
  6. package/components/button-edit/index.umd.cjs +1 -1
  7. package/components/calendar/index.esm.js +504 -490
  8. package/components/calendar/index.umd.cjs +1 -1
  9. package/components/capsule/index.esm.js +247 -233
  10. package/components/capsule/index.umd.cjs +1 -1
  11. package/components/checkbox/index.esm.js +356 -344
  12. package/components/checkbox/index.umd.cjs +1 -1
  13. package/components/color-picker/index.esm.js +159 -145
  14. package/components/color-picker/index.umd.cjs +2 -2
  15. package/components/combo-list/index.esm.js +127 -128
  16. package/components/combo-list/index.umd.cjs +1 -1
  17. package/components/combo-tree/index.esm.js +15 -15
  18. package/components/combo-tree/index.umd.cjs +1 -1
  19. package/components/component/index.esm.js +101 -87
  20. package/components/component/index.umd.cjs +1 -1
  21. package/components/condition/index.esm.js +7 -5
  22. package/components/condition/index.umd.cjs +1 -1
  23. package/components/content-container/index.esm.js +181 -167
  24. package/components/content-container/index.umd.cjs +1 -1
  25. package/components/data-grid/index.esm.js +4057 -4304
  26. package/components/data-grid/index.umd.cjs +1 -1
  27. package/components/data-view/index.esm.js +2450 -2467
  28. package/components/data-view/index.umd.cjs +1 -1
  29. package/components/date-picker/index.esm.js +789 -777
  30. package/components/date-picker/index.umd.cjs +1 -1
  31. package/components/designer-canvas/index.esm.js +3593 -3585
  32. package/components/designer-canvas/index.umd.cjs +1 -1
  33. package/components/dropdown/index.esm.js +257 -243
  34. package/components/dropdown/index.umd.cjs +2 -2
  35. package/components/dynamic-form/index.esm.js +322 -306
  36. package/components/dynamic-form/index.umd.cjs +1 -1
  37. package/components/dynamic-resolver/index.esm.js +177 -163
  38. package/components/dynamic-resolver/index.umd.cjs +1 -1
  39. package/components/event-parameter/index.esm.js +163 -2643
  40. package/components/event-parameter/index.umd.cjs +1 -1
  41. package/components/events-editor/index.esm.js +500 -486
  42. package/components/events-editor/index.umd.cjs +1 -1
  43. package/components/expression-editor/index.esm.js +37 -37
  44. package/components/expression-editor/index.umd.cjs +1 -1
  45. package/components/external-container/index.esm.js +485 -470
  46. package/components/external-container/index.umd.cjs +1 -1
  47. package/components/field-selector/index.esm.js +2611 -2623
  48. package/components/field-selector/index.umd.cjs +1 -1
  49. package/components/filter-bar/index.esm.js +3825 -3837
  50. package/components/filter-bar/index.umd.cjs +1 -1
  51. package/components/flow-canvas/index.esm.js +3720 -3712
  52. package/components/flow-canvas/index.umd.cjs +1 -1
  53. package/components/image-cropper/index.esm.js +402 -388
  54. package/components/image-cropper/index.umd.cjs +1 -1
  55. package/components/input-group/index.esm.js +201 -202
  56. package/components/input-group/index.umd.cjs +1 -1
  57. package/components/layout/index.esm.js +264 -245
  58. package/components/layout/index.umd.cjs +1 -1
  59. package/components/list-nav/index.esm.js +157 -143
  60. package/components/list-nav/index.umd.cjs +1 -1
  61. package/components/list-view/index.esm.js +312 -296
  62. package/components/list-view/index.umd.cjs +1 -1
  63. package/components/lookup/index.esm.js +4748 -4992
  64. package/components/lookup/index.umd.cjs +1 -1
  65. package/components/mapping-editor/index.esm.js +4215 -4462
  66. package/components/mapping-editor/index.umd.cjs +1 -1
  67. package/components/nav/index.esm.js +169 -155
  68. package/components/nav/index.umd.cjs +2 -2
  69. package/components/number-range/index.esm.js +150 -137
  70. package/components/number-range/index.umd.cjs +1 -1
  71. package/components/number-spinner/index.esm.js +207 -194
  72. package/components/number-spinner/index.umd.cjs +1 -1
  73. package/components/order/index.esm.js +427 -414
  74. package/components/order/index.umd.cjs +1 -1
  75. package/components/page-footer/index.esm.js +22 -22
  76. package/components/page-footer/index.umd.cjs +1 -1
  77. package/components/page-header/index.esm.js +510 -492
  78. package/components/page-header/index.umd.cjs +1 -1
  79. package/components/pagination/index.esm.js +192 -178
  80. package/components/pagination/index.umd.cjs +1 -1
  81. package/components/progress/index.esm.js +234 -220
  82. package/components/progress/index.umd.cjs +3 -3
  83. package/components/property-editor/index.esm.js +288 -277
  84. package/components/property-editor/index.umd.cjs +2 -2
  85. package/components/property-panel/index.esm.js +62 -61
  86. package/components/property-panel/index.umd.cjs +1 -1
  87. package/components/query-solution/index.esm.js +3015 -3027
  88. package/components/query-solution/index.umd.cjs +5 -5
  89. package/components/radio-button/index.esm.js +64 -64
  90. package/components/radio-button/index.umd.cjs +1 -1
  91. package/components/radio-group/index.esm.js +293 -280
  92. package/components/radio-group/index.umd.cjs +1 -1
  93. package/components/rate/index.esm.js +222 -208
  94. package/components/rate/index.umd.cjs +1 -1
  95. package/components/response-layout/index.esm.js +187 -173
  96. package/components/response-layout/index.umd.cjs +1 -1
  97. package/components/response-layout-editor/index.esm.js +554 -542
  98. package/components/response-layout-editor/index.umd.cjs +1 -1
  99. package/components/response-toolbar/index.esm.js +483 -469
  100. package/components/response-toolbar/index.umd.cjs +1 -1
  101. package/components/schema-selector/index.esm.js +632 -617
  102. package/components/schema-selector/index.umd.cjs +2 -2
  103. package/components/search-box/index.esm.js +228 -214
  104. package/components/search-box/index.umd.cjs +1 -1
  105. package/components/section/index.esm.js +419 -406
  106. package/components/section/index.umd.cjs +1 -1
  107. package/components/smoke-detector/index.esm.js +162 -148
  108. package/components/smoke-detector/index.umd.cjs +1 -1
  109. package/components/splitter/index.esm.js +308 -284
  110. package/components/splitter/index.umd.cjs +1 -1
  111. package/components/step/index.esm.js +279 -265
  112. package/components/step/index.umd.cjs +1 -1
  113. package/components/switch/index.esm.js +183 -170
  114. package/components/switch/index.umd.cjs +1 -1
  115. package/components/tabs/index.esm.js +307 -294
  116. package/components/tabs/index.umd.cjs +1 -1
  117. package/components/tags/index.esm.js +320 -306
  118. package/components/tags/index.umd.cjs +1 -1
  119. package/components/text/index.esm.js +245 -231
  120. package/components/text/index.umd.cjs +1 -1
  121. package/components/textarea/index.esm.js +260 -247
  122. package/components/textarea/index.umd.cjs +1 -1
  123. package/components/time-picker/index.esm.js +409 -396
  124. package/components/time-picker/index.umd.cjs +1 -1
  125. package/components/transfer/index.esm.js +424 -410
  126. package/components/transfer/index.umd.cjs +1 -1
  127. package/components/tree-grid/index.esm.js +2994 -3006
  128. package/components/tree-grid/index.umd.cjs +1 -1
  129. package/components/tree-view/index.esm.js +749 -733
  130. package/components/tree-view/index.umd.cjs +1 -1
  131. package/components/uploader/index.esm.js +325 -311
  132. package/components/uploader/index.umd.cjs +2 -2
  133. package/components/verify-detail/index.esm.js +304 -290
  134. package/components/verify-detail/index.umd.cjs +1 -1
  135. package/components/video/index.esm.js +99 -85
  136. package/components/video/index.umd.cjs +1 -1
  137. package/components/weather/index.esm.js +947 -933
  138. package/components/weather/index.umd.cjs +4 -4
  139. package/farris.all.esm.js +7750 -7990
  140. package/farris.all.umd.cjs +12 -12
  141. package/package.json +1 -1
  142. package/types/data-view/composition/types.d.ts +0 -1
  143. package/types/entity-binding-selector/composition/use-entity-tree.d.ts +3 -0
  144. package/types/entity-binding-selector/composition/use-field-tree.d.ts +1 -0
  145. package/components/event-parameter/index.css +0 -1
  146. package/types/data-grid/src/components/data/data-grid-area.component.d.ts +0 -8
  147. package/types/data-grid/src/components/data/data-grid-area.props.d.ts +0 -3
@@ -1,59 +1,73 @@
1
- import { ref as m, watch as M, createVNode as r, computed as d, defineComponent as J, watchEffect as oe, Fragment as A, createTextVNode as R, inject as re, onMounted as ie } from "vue";
2
- import { isPlainObject as H, cloneDeep as ue } from "lodash-es";
1
+ import { ref as m, watch as M, createVNode as r, computed as d, defineComponent as J, watchEffect as re, Fragment as A, createTextVNode as R, inject as ie, onMounted as ue } from "vue";
2
+ import { isPlainObject as H, cloneDeep as Q } from "lodash-es";
3
3
  import { withInstall as ce } from "../common/index.esm.js";
4
- const Q = {}, U = {};
5
- function q(t) {
6
- const { properties: e, title: p, ignore: i } = t, l = i && Array.isArray(i), c = Object.keys(e).reduce((a, n) => ((!l || !i.find((u) => u === n)) && (a[n] = e[n].type === "object" && e[n].properties ? q(e[n]) : ue(e[n].default)), a), {});
7
- if (p && (!l || !i.find((a) => a === "id"))) {
4
+ const U = {}, X = {};
5
+ function G(t) {
6
+ const { properties: e, title: p, ignore: i } = t, n = i && Array.isArray(i), c = Object.keys(e).reduce((a, l) => ((!n || !i.find((u) => u === l)) && (a[l] = e[l].type === "object" && e[l].properties ? G(e[l]) : Q(e[l].default)), a), {});
7
+ if (p && (!n || !i.find((a) => a === "id"))) {
8
8
  const a = p.toLowerCase().replace(/-/g, "_");
9
9
  c.id = `${a}_${Math.random().toString().slice(2, 6)}`;
10
10
  }
11
11
  return c;
12
12
  }
13
- function X(t, e = {}, p) {
14
- const i = Q[t];
13
+ function pe(t) {
14
+ const { properties: e, title: p, required: i } = t;
15
+ if (i && Array.isArray(i)) {
16
+ const n = i.reduce((c, a) => (c[a] = e[a].type === "object" && e[a].properties ? G(e[a]) : Q(e[a].default), c), {});
17
+ if (p && i.find((c) => c === "id")) {
18
+ const c = p.toLowerCase().replace(/-/g, "_");
19
+ n.id = `${c}_${Math.random().toString().slice(2, 6)}`;
20
+ }
21
+ return n;
22
+ }
23
+ return {
24
+ type: p
25
+ };
26
+ }
27
+ function Y(t, e = {}, p) {
28
+ const i = U[t];
15
29
  if (i) {
16
- let l = q(i);
17
- const c = U[t];
18
- return l = c ? c({ getSchemaByType: X }, l, e, p) : l, l;
30
+ let n = pe(i);
31
+ const c = X[t];
32
+ return n = c ? c({ getSchemaByType: Y }, n, e, p) : n, n;
19
33
  }
20
34
  return null;
21
35
  }
22
- function pe(t, e) {
23
- const p = q(e);
24
- return Object.keys(p).reduce((i, l) => (i[l] && H(i[l]) && H(t[l] || !t[l]) ? Object.assign(i[l], t[l] || {}) : i[l] = t[l], i), p), p;
25
- }
26
36
  function fe(t, e) {
27
- return Object.keys(t).filter((i) => t[i] != null).reduce((i, l) => {
28
- if (e.has(l)) {
29
- const c = e.get(l);
37
+ const p = G(e);
38
+ return Object.keys(p).reduce((i, n) => (Object.prototype.hasOwnProperty.call(t, n) && (i[n] && H(i[n]) && H(t[n] || !t[n]) ? Object.assign(i[n], t[n] || {}) : i[n] = t[n]), i), p), p;
39
+ }
40
+ function ve(t, e) {
41
+ return Object.keys(t).filter((i) => t[i] != null).reduce((i, n) => {
42
+ if (e.has(n)) {
43
+ const c = e.get(n);
30
44
  if (typeof c == "string")
31
- i[c] = t[l];
45
+ i[c] = t[n];
32
46
  else {
33
- const a = c(l, t[l], t);
47
+ const a = c(n, t[n], t);
34
48
  Object.assign(i, a);
35
49
  }
36
50
  } else
37
- i[l] = t[l];
51
+ i[n] = t[n];
38
52
  return i;
39
53
  }, {});
40
54
  }
41
- function ve(t, e, p = /* @__PURE__ */ new Map()) {
42
- const i = pe(t, e);
43
- return fe(i, p);
55
+ function ge(t, e, p = /* @__PURE__ */ new Map()) {
56
+ const i = fe(t, e);
57
+ return ve(i, p);
44
58
  }
45
- function ge(t = {}) {
59
+ function de(t = {}) {
46
60
  function e(o, s, f, v) {
47
61
  if (typeof f == "number")
48
62
  return v[o].length === f;
49
63
  if (typeof f == "object") {
50
- const h = Object.keys(f)[0], y = f[h];
64
+ const h = Object.keys(f)[0], b = f[h];
51
65
  if (h === "not")
52
- return Number(v[o].length) !== Number(y);
66
+ return Number(v[o].length) !== Number(b);
53
67
  if (h === "moreThan")
54
- return Number(v[o].length) >= Number(y);
68
+ return Number(v[o].length) >= Number(b);
55
69
  if (h === "lessThan")
56
- return Number(v[o].length) <= Number(y);
70
+ return Number(v[o].length) <= Number(b);
57
71
  }
58
72
  return !1;
59
73
  }
@@ -65,18 +79,18 @@ function ge(t = {}) {
65
79
  ["getProperty", p]
66
80
  ]);
67
81
  Object.keys(t).reduce((o, s) => (o.set(s, t[s]), o), i);
68
- function l(o, s) {
82
+ function n(o, s) {
69
83
  const f = o;
70
84
  return typeof s == "number" ? [{ target: f, operator: "length", param: null, value: Number(s) }] : typeof s == "boolean" ? [{ target: f, operator: "getProperty", param: o, value: !!s }] : typeof s == "object" ? Object.keys(s).map((v) => {
71
85
  if (v === "length")
72
86
  return { target: f, operator: "length", param: null, value: s[v] };
73
- const h = v, y = s[v];
74
- return { target: f, operator: "getProperty", param: h, value: y };
87
+ const h = v, b = s[v];
88
+ return { target: f, operator: "getProperty", param: h, value: b };
75
89
  }) : [];
76
90
  }
77
91
  function c(o) {
78
92
  return Object.keys(o).reduce((f, v) => {
79
- const h = l(v, o[v]);
93
+ const h = n(v, o[v]);
80
94
  return f.push(...h), f;
81
95
  }, []);
82
96
  }
@@ -87,29 +101,29 @@ function ge(t = {}) {
87
101
  }
88
102
  return !1;
89
103
  }
90
- function n(o, s) {
91
- return c(o).reduce((h, y) => h && a(y, s), !0);
104
+ function l(o, s) {
105
+ return c(o).reduce((h, b) => h && a(b, s), !0);
92
106
  }
93
107
  function u(o, s) {
94
- const f = Object.keys(o), v = f.includes("allOf"), h = f.includes("anyOf"), y = v || h, w = (y ? o[y ? v ? "allOf" : "anyOf" : "allOf"] : [o]).map((O) => n(O, s));
108
+ const f = Object.keys(o), v = f.includes("allOf"), h = f.includes("anyOf"), b = v || h, w = (b ? o[b ? v ? "allOf" : "anyOf" : "allOf"] : [o]).map((O) => l(O, s));
95
109
  return v ? !w.includes(!1) : w.includes(!0);
96
110
  }
97
111
  return { parseValueSchema: u };
98
112
  }
99
- const de = {}, me = {};
100
- ge();
101
- function he(t, e, p = /* @__PURE__ */ new Map(), i = (a, n, u, o) => n, l = {}, c = (a) => a) {
102
- return Q[e.title] = e, U[e.title] = i, de[e.title] = l, me[e.title] = c, (a = {}) => {
103
- const n = ve(a, e, p), u = Object.keys(t).reduce((o, s) => (o[s] = t[s].default, o), {});
104
- return Object.assign(u, n);
113
+ const me = {}, he = {};
114
+ de();
115
+ function ye(t, e, p = /* @__PURE__ */ new Map(), i = (a, l, u, o) => l, n = {}, c = (a) => a) {
116
+ return U[e.title] = e, X[e.title] = i, me[e.title] = n, he[e.title] = c, (a = {}) => {
117
+ const l = ge(a, e, p), u = Object.keys(t).reduce((o, s) => (o[s] = t[s].default, o), {});
118
+ return Object.assign(u, l);
105
119
  };
106
120
  }
107
121
  function be(t, e) {
108
122
  return { customClass: e.class, customStyle: e.style };
109
123
  }
110
- const ye = /* @__PURE__ */ new Map([
124
+ const Pe = /* @__PURE__ */ new Map([
111
125
  ["appearance", be]
112
- ]), Pe = "https://json-schema.org/draft/2020-12/schema", we = "https://farris-design.gitee.io/pagination.schema.json", Se = "pagination", je = "A Farris Component", ke = "object", Ne = {
126
+ ]), we = "https://json-schema.org/draft/2020-12/schema", Se = "https://farris-design.gitee.io/pagination.schema.json", je = "pagination", ke = "A Farris Component", Ne = "object", Oe = {
113
127
  id: {
114
128
  description: "The unique identifier for a pagination",
115
129
  type: "string"
@@ -201,18 +215,18 @@ const ye = /* @__PURE__ */ new Map([
201
215
  type: "sting",
202
216
  default: ""
203
217
  }
204
- }, Oe = [
218
+ }, Me = [
205
219
  "id",
206
220
  "type"
207
- ], Me = {
208
- $schema: Pe,
209
- $id: we,
210
- title: Se,
211
- description: je,
212
- type: ke,
213
- properties: Ne,
214
- required: Oe
215
- }, Le = "pagination", Te = "A Farris Component", Be = "object", Ee = {
221
+ ], Le = {
222
+ $schema: we,
223
+ $id: Se,
224
+ title: je,
225
+ description: ke,
226
+ type: Ne,
227
+ properties: Oe,
228
+ required: Me
229
+ }, Te = "pagination", Be = "A Farris Component", Ee = "object", $e = {
216
230
  basic: {
217
231
  description: "Basic Infomation",
218
232
  title: "基本信息",
@@ -295,15 +309,15 @@ const ye = /* @__PURE__ */ new Map([
295
309
  }
296
310
  }
297
311
  }, ze = {
298
- title: Le,
299
- description: Te,
300
- type: Be,
301
- categories: Ee
312
+ title: Te,
313
+ description: Be,
314
+ type: Ee,
315
+ categories: $e
302
316
  };
303
- function $e(t, e, p) {
317
+ function De(t, e, p) {
304
318
  return e;
305
319
  }
306
- const W = {
320
+ const _ = {
307
321
  /**
308
322
  * 当前页码
309
323
  */
@@ -336,15 +350,15 @@ const W = {
336
350
  * 自定义每页数量
337
351
  */
338
352
  pageList: { type: Array, default: [20, 50, 100] }
339
- }, Y = he(W, Me, ye, $e, ze);
340
- function Z(t, e, p, i) {
341
- const l = m("跳转至"), c = m(""), a = m(t.value);
353
+ }, Z = ye(_, Le, Pe, De, ze);
354
+ function I(t, e, p, i) {
355
+ const n = m("跳转至"), c = m(""), a = m(t.value);
342
356
  M(a, (s, f) => {
343
357
  s >= 1 && s <= e.value ? t.value = s : a.value = f;
344
358
  }), M(t, (s) => {
345
359
  a.value !== s && (a.value = s);
346
360
  });
347
- function n(s) {
361
+ function l(s) {
348
362
  a.value = s.target.valueAsNumber, i.emit("change", {
349
363
  pageIndex: a.value,
350
364
  pageSize: p.value
@@ -362,14 +376,14 @@ function Z(t, e, p, i) {
362
376
  style: "padding-left: 10px; white-space: nowrap;"
363
377
  }, [r("span", {
364
378
  class: "pg-message-text"
365
- }, [l.value]), r("input", {
379
+ }, [n.value]), r("input", {
366
380
  type: "number",
367
381
  class: "form-control farris-gotopagenumber",
368
382
  value: a.value,
369
383
  min: "1",
370
384
  max: e.value,
371
385
  style: "display: inline-block;margin-left:3px;",
372
- onBlur: (s) => n(s),
386
+ onBlur: (s) => l(s),
373
387
  onKeyup: (s) => u(s)
374
388
  }, null), c.value]);
375
389
  }
@@ -377,19 +391,19 @@ function Z(t, e, p, i) {
377
391
  renderGotoButton: o
378
392
  };
379
393
  }
380
- function I(t, e, p, i, l) {
394
+ function K(t, e, p, i, n) {
381
395
  const c = d(() => ({
382
396
  "page-item": !0,
383
397
  disabled: e.value
384
398
  }));
385
399
  function a(s) {
386
- t.value = t.value < p.value ? t.value + 1 : p.value, l.emit("change", {
400
+ t.value = t.value < p.value ? t.value + 1 : p.value, n.emit("change", {
387
401
  pageIndex: t.value,
388
402
  pageSize: i.value
389
403
  });
390
404
  }
391
- function n(s) {
392
- t.value = p.value, l.emit("change", {
405
+ function l(s) {
406
+ t.value = p.value, n.emit("change", {
393
407
  pageIndex: t.value,
394
408
  pageSize: i.value
395
409
  });
@@ -415,7 +429,7 @@ function I(t, e, p, i, l) {
415
429
  }, [!e.value && r("a", {
416
430
  class: "page-link",
417
431
  tabindex: "0",
418
- onClick: (s) => n()
432
+ onClick: (s) => l()
419
433
  }, [r("span", {
420
434
  class: "f-icon f-page-last"
421
435
  }, null)]), e.value && r("span", {
@@ -429,8 +443,8 @@ function I(t, e, p, i, l) {
429
443
  renderNextPage: u
430
444
  };
431
445
  }
432
- function K(t, e) {
433
- const p = m("共"), i = m("条"), l = d(() => ({
446
+ function ee(t, e) {
447
+ const p = m("共"), i = m("条"), n = d(() => ({
434
448
  "pagination-message": !0,
435
449
  "text-truncate": !0,
436
450
  "d-flex": !0,
@@ -439,7 +453,7 @@ function K(t, e) {
439
453
  }));
440
454
  function c() {
441
455
  return r("li", {
442
- class: l.value
456
+ class: n.value
443
457
  }, [r("div", {
444
458
  class: "text-truncate",
445
459
  style: "line-height: 26px"
@@ -455,8 +469,8 @@ function K(t, e) {
455
469
  renderPageInfo: c
456
470
  };
457
471
  }
458
- function ee(t, e, p, i, l) {
459
- const c = m(!1), a = m("显示"), n = m("条"), u = d(() => ({
472
+ function te(t, e, p, i, n) {
473
+ const c = m(!1), a = m("显示"), l = m("条"), u = d(() => ({
460
474
  dropup: !0,
461
475
  "dropdown-right": !0,
462
476
  "pg-pagelist": !0,
@@ -465,23 +479,23 @@ function ee(t, e, p, i, l) {
465
479
  })), o = d(() => ({
466
480
  "dropdown-menu": !0,
467
481
  show: c.value
468
- })), s = (b) => ({
482
+ })), s = (y) => ({
469
483
  "w-100": !0,
470
484
  "dropdown-item": !0,
471
- active: e.value === b
485
+ active: e.value === y
472
486
  });
473
- function f(b) {
487
+ function f(y) {
474
488
  c.value = !0;
475
489
  }
476
- function v(b) {
490
+ function v(y) {
477
491
  c.value = !1;
478
492
  }
479
- function h(b, w, N) {
480
- const T = b * w - w + 1;
493
+ function h(y, w, N) {
494
+ const T = y * w - w + 1;
481
495
  return Math.ceil(T / N);
482
496
  }
483
- function y(b, w) {
484
- t.value = h(t.value, e.value, w), e.value = w, c.value = !1, l.emit("change", {
497
+ function b(y, w) {
498
+ t.value = h(t.value, e.value, w), e.value = w, c.value = !1, n.emit("change", {
485
499
  pageIndex: t.value,
486
500
  pageSize: e.value
487
501
  });
@@ -491,8 +505,8 @@ function ee(t, e, p, i, l) {
491
505
  class: "pagination-pagelist"
492
506
  }, [r("div", {
493
507
  class: u.value,
494
- onMouseenter: (b) => f(),
495
- onMouseleave: (b) => v()
508
+ onMouseenter: (y) => f(),
509
+ onMouseleave: (y) => v()
496
510
  }, [r("div", {
497
511
  class: "pg-pagelist-info"
498
512
  }, [r("span", {
@@ -501,22 +515,22 @@ function ee(t, e, p, i, l) {
501
515
  class: "cur-pagesize"
502
516
  }, [e.value]), r("span", {
503
517
  class: "pagelist-text"
504
- }, [n.value]), r("i", {
518
+ }, [l.value]), r("i", {
505
519
  class: "f-icon f-icon-dropdown"
506
520
  }, null)]), r("div", {
507
521
  class: o.value,
508
522
  style: "margin-bottom: -1px;"
509
- }, [p.value.map((b) => r("li", {
510
- class: s(b),
511
- onClick: (w) => y(w, b)
512
- }, [r("span", null, [b])]))])])]);
523
+ }, [p.value.map((y) => r("li", {
524
+ class: s(y),
525
+ onClick: (w) => b(w, y)
526
+ }, [r("span", null, [y])]))])])]);
513
527
  }
514
528
  return {
515
529
  renderPageList: k
516
530
  };
517
531
  }
518
- function te(t, e, p, i) {
519
- const l = (u) => ({
532
+ function ae(t, e, p, i) {
533
+ const n = (u) => ({
520
534
  "page-item": !0,
521
535
  current: t.value === u.value,
522
536
  ellipsis: u.label === "..."
@@ -531,9 +545,9 @@ function te(t, e, p, i) {
531
545
  pageSize: p.value
532
546
  });
533
547
  }
534
- function n() {
548
+ function l() {
535
549
  return e.value.map((u) => r("li", {
536
- class: l(u)
550
+ class: n(u)
537
551
  }, [t.value !== u.value && r("a", {
538
552
  class: "page-link",
539
553
  tabindex: "0",
@@ -547,22 +561,22 @@ function te(t, e, p, i) {
547
561
  }, [u.label])]));
548
562
  }
549
563
  return {
550
- renderPageNumbers: n
564
+ renderPageNumbers: l
551
565
  };
552
566
  }
553
- function ae(t, e, p, i, l) {
567
+ function ne(t, e, p, i, n) {
554
568
  const c = d(() => ({
555
569
  "page-item": !0,
556
570
  disabled: e.value
557
571
  }));
558
572
  function a(s) {
559
- t.value = 1, l.emit("change", {
573
+ t.value = 1, n.emit("change", {
560
574
  pageIndex: t.value,
561
575
  pageSize: i.value
562
576
  });
563
577
  }
564
- function n(s) {
565
- t.value = t.value > 2 ? t.value - 1 : 1, l.emit("change", {
578
+ function l(s) {
579
+ t.value = t.value > 2 ? t.value - 1 : 1, n.emit("change", {
566
580
  pageIndex: t.value,
567
581
  pageSize: i.value
568
582
  });
@@ -588,7 +602,7 @@ function ae(t, e, p, i, l) {
588
602
  }, [p.value && r("a", {
589
603
  tabindex: "0",
590
604
  class: "page-link",
591
- onClick: (s) => n()
605
+ onClick: (s) => l()
592
606
  }, [r("span", {
593
607
  class: "f-icon f-page-pre"
594
608
  }, null)]), e.value && r("span", {
@@ -602,18 +616,18 @@ function ae(t, e, p, i, l) {
602
616
  renderPreviousPage: o
603
617
  };
604
618
  }
605
- function ne(t) {
619
+ function le(t) {
606
620
  const e = m([]);
607
- function p(l, c, a, n) {
621
+ function p(n, c, a, l) {
608
622
  const u = Math.ceil(a / 2);
609
- return l === a ? n : l === 1 ? l : a < n ? n - u < c ? n - a + l : u < c ? c - u + l : l : l;
623
+ return n === a ? l : n === 1 ? n : a < l ? l - u < c ? l - a + n : u < c ? c - u + n : n : n;
610
624
  }
611
- function i(l, c, a, n) {
612
- const u = [], o = Math.ceil(a / c), s = Math.ceil(n / 2), f = l <= s, v = o - s < l, h = !f && !v, y = n < o;
625
+ function i(n, c, a, l) {
626
+ const u = [], o = Math.ceil(a / c), s = Math.ceil(l / 2), f = n <= s, v = o - s < n, h = !f && !v, b = l < o;
613
627
  let k = 1;
614
- for (; k <= o && k <= n; ) {
615
- const b = p(k, l, n, o), w = k === 2 && (h || v), N = k === n - 1 && (h || f), O = y && (w || N) ? "..." : "" + b;
616
- u.push({ label: O, value: b }), k++;
628
+ for (; k <= o && k <= l; ) {
629
+ const y = p(k, n, l, o), w = k === 2 && (h || v), N = k === l - 1 && (h || f), O = b && (w || N) ? "..." : "" + y;
630
+ u.push({ label: O, value: y }), k++;
617
631
  }
618
632
  e.value = u;
619
633
  }
@@ -621,48 +635,48 @@ function ne(t) {
621
635
  }
622
636
  const V = /* @__PURE__ */ J({
623
637
  name: "FPagination",
624
- props: W,
638
+ props: _,
625
639
  emits: ["change", "pageIndexChanged", "pageSizeChanged", "update:currentPage", "update:pageSize"],
626
640
  setup(t, e) {
627
- const p = m(!1), i = m(t.mode), l = m(""), c = m(!1), a = m(t.pageSize), n = m(t.currentPage), u = m(t.totalItems), {
641
+ const p = m(!1), i = m(t.mode), n = m(""), c = m(!1), a = m(t.pageSize), l = m(t.currentPage), u = m(t.totalItems), {
628
642
  pages: o,
629
643
  updatePages: s
630
- } = ne(), f = d(() => n.value === 1), v = d(() => t.pageList), h = d(() => Math.ceil(u.value / a.value)), y = d(() => n.value === h.value), k = d(() => t.showGoButton), b = d(() => n.value > 1), w = d(() => !(c.value && o.value.length <= 1)), N = d(() => !0), O = d(() => t.showPageList), T = d(() => t.showPageNumbers), g = d(() => !0), {
644
+ } = le(), f = d(() => l.value === 1), v = d(() => t.pageList), h = d(() => Math.ceil(u.value / a.value)), b = d(() => l.value === h.value), k = d(() => t.showGoButton), y = d(() => l.value > 1), w = d(() => !(c.value && o.value.length <= 1)), N = d(() => !0), O = d(() => t.showPageList), T = d(() => t.showPageNumbers), g = d(() => !0), {
631
645
  renderFirstPage: j,
632
646
  renderPreviousPage: S
633
- } = ae(n, f, b, a, e), {
647
+ } = ne(l, f, y, a, e), {
634
648
  renderLastPage: P,
635
649
  renderNextPage: B
636
- } = I(n, y, h, a, e), {
650
+ } = K(l, b, h, a, e), {
637
651
  renderPageInfo: E
638
- } = K(l, u), {
639
- renderPageList: z
640
- } = ee(n, a, v, u, e), {
641
- renderPageNumbers: $
642
- } = te(n, o, a, e), {
652
+ } = ee(n, u), {
653
+ renderPageList: $
654
+ } = te(l, a, v, u, e), {
655
+ renderPageNumbers: z
656
+ } = ae(l, o, a, e), {
643
657
  renderGotoButton: D
644
- } = Z(n, h, a, e);
645
- s(n.value, a.value, u.value, 7), M(() => t.totalItems, (L) => {
658
+ } = I(l, h, a, e);
659
+ s(l.value, a.value, u.value, 7), M(() => t.totalItems, (L) => {
646
660
  u.value = L;
647
- }), M([n, a, u], () => {
648
- s(n.value, a.value, u.value, 7);
649
- }), M(n, () => {
650
- e.emit("update:currentPage", n.value), e.emit("pageIndexChanged", {
651
- pageIndex: n.value,
661
+ }), M([l, a, u], () => {
662
+ s(l.value, a.value, u.value, 7);
663
+ }), M(l, () => {
664
+ e.emit("update:currentPage", l.value), e.emit("pageIndexChanged", {
665
+ pageIndex: l.value,
652
666
  pageSize: a.value
653
667
  });
654
668
  }), M(a, () => {
655
669
  e.emit("update:pageSize", a.value), e.emit("pageSizeChanged", {
656
- pageIndex: n.value,
670
+ pageIndex: l.value,
657
671
  pageSize: a.value
658
672
  });
659
673
  }), M(() => t.totalItems, (L) => {
660
- u.value = L, s(n.value, a.value, u.value, 7);
661
- }), oe(() => {
674
+ u.value = L, s(l.value, a.value, u.value, 7);
675
+ }), re(() => {
662
676
  const L = v.value.includes(a.value);
663
677
  a.value = L ? a.value : v.value[0];
664
678
  })();
665
- const x = d(() => ({
679
+ const q = d(() => ({
666
680
  "ngx-pagination": !0,
667
681
  pagination: !0,
668
682
  responsive: p.value,
@@ -670,12 +684,12 @@ const V = /* @__PURE__ */ J({
670
684
  "pager-viewmode-simple": i.value === "simple"
671
685
  })), F = d(() => ({
672
686
  position: "relative",
673
- "justify-content": l.value === "center" ? "center" : "start"
687
+ "justify-content": n.value === "center" ? "center" : "start"
674
688
  }));
675
- function C() {
676
- return r(A, null, [N.value && E(), O.value && z(), g.value && j(), g.value && S(), T.value && $(), g.value && B(), g.value && P(), k.value && D()]);
689
+ function x() {
690
+ return r(A, null, [N.value && E(), O.value && $(), g.value && j(), g.value && S(), T.value && z(), g.value && B(), g.value && P(), k.value && D()]);
677
691
  }
678
- function G() {
692
+ function C() {
679
693
  return r(A, null, [r("li", {
680
694
  class: "page-item d-flex flex-fill"
681
695
  }, null), g.value && j(), g.value && S(), D(), r("li", {
@@ -694,18 +708,18 @@ const V = /* @__PURE__ */ J({
694
708
  class: "pagination-container"
695
709
  }, [w.value && r("ul", {
696
710
  role: "navigation",
697
- class: x.value,
711
+ class: q.value,
698
712
  style: F.value
699
- }, [i.value === "default" ? C() : G()])]);
713
+ }, [i.value === "default" ? x() : C()])]);
700
714
  }
701
715
  });
702
- function De(t, e, p) {
716
+ function Fe(t, e, p) {
703
717
  var T;
704
- const i = "", l = "", c = m();
718
+ const i = "", n = "", c = m();
705
719
  function a() {
706
720
  return (e == null ? void 0 : e.schema.componentType) !== "frame";
707
721
  }
708
- function n() {
722
+ function l() {
709
723
  return !1;
710
724
  }
711
725
  function u() {
@@ -732,13 +746,13 @@ function De(t, e, p) {
732
746
  function h() {
733
747
  return (e == null ? void 0 : e.schema.label) || (e == null ? void 0 : e.schema.title) || (e == null ? void 0 : e.schema.name);
734
748
  }
735
- function y() {
749
+ function b() {
736
750
  }
737
751
  function k(g, j) {
738
752
  }
739
- function b(g, j) {
753
+ function y(g, j) {
740
754
  const { componentType: S } = g;
741
- let P = X(S, g, j);
755
+ let P = Y(S, g, j);
742
756
  const B = S.toLowerCase().replace(/-/g, "_");
743
757
  return P && !P.id && P.type === S && (P.id = `${B}_${Math.random().toString().slice(2, 6)}`), P;
744
758
  }
@@ -757,7 +771,7 @@ function De(t, e, p) {
757
771
  }
758
772
  return c.value = {
759
773
  canMove: a(),
760
- canSelectParent: n(),
774
+ canSelectParent: l(),
761
775
  canDelete: u(),
762
776
  canNested: !o(),
763
777
  contents: e == null ? void 0 : e.schema.contents,
@@ -765,69 +779,69 @@ function De(t, e, p) {
765
779
  parent: (T = e == null ? void 0 : e.parent) == null ? void 0 : T.componentInstance,
766
780
  schema: e == null ? void 0 : e.schema,
767
781
  styles: i,
768
- designerClass: l,
782
+ designerClass: n,
769
783
  canAccepts: v,
770
784
  getBelongedComponentInstance: s,
771
785
  getDraggableDesignItemElement: f,
772
786
  getDraggingDisplayText: h,
773
787
  getPropConfig: N,
774
- getDragScopeElement: y,
788
+ getDragScopeElement: b,
775
789
  onAcceptMovedChildElement: k,
776
790
  onChildElementMovedOut: w,
777
- addNewChildComponentSchema: b,
791
+ addNewChildComponentSchema: y,
778
792
  triggerBelongedComponentToMoveWhenMoved: m(!1),
779
793
  triggerBelongedComponentToDeleteWhenDeleted: m(!1),
780
794
  onRemoveComponent: O
781
795
  }, c;
782
796
  }
783
- const Fe = /* @__PURE__ */ J({
797
+ const Ae = /* @__PURE__ */ J({
784
798
  name: "FPagination",
785
- props: W,
799
+ props: _,
786
800
  emits: ["pageIndexChanged", "pageSizeChanged"],
787
801
  setup(t, e) {
788
- const p = m(!1), i = m(t.mode), l = m(""), c = m(!1), a = m(t.pageSize), n = m(t.currentPage), u = m(t.totalItems), o = m(), s = re("design-item-context"), f = De(o, s);
789
- ie(() => {
802
+ const p = m(!1), i = m(t.mode), n = m(""), c = m(!1), a = m(t.pageSize), l = m(t.currentPage), u = m(t.totalItems), o = m(), s = ie("design-item-context"), f = Fe(o, s);
803
+ ue(() => {
790
804
  o.value.componentInstance = f;
791
805
  }), e.expose(f.value);
792
806
  const {
793
807
  pages: v,
794
808
  updatePages: h
795
- } = ne(), y = d(() => n.value === 1), k = d(() => [20, 50, 100]), b = d(() => Math.ceil(u.value / a.value)), w = d(() => n.value === b.value), N = d(() => !0), O = d(() => n.value > 1), T = d(() => !(c.value && v.value.length <= 1)), g = d(() => !0), j = d(() => !0), S = d(() => !0), P = d(() => !0), {
809
+ } = le(), b = d(() => l.value === 1), k = d(() => [20, 50, 100]), y = d(() => Math.ceil(u.value / a.value)), w = d(() => l.value === y.value), N = d(() => !0), O = d(() => l.value > 1), T = d(() => !(c.value && v.value.length <= 1)), g = d(() => !0), j = d(() => !0), S = d(() => !0), P = d(() => !0), {
796
810
  renderFirstPage: B,
797
811
  renderPreviousPage: E
798
- } = ae(n, y, O, a, e), {
799
- renderLastPage: z,
800
- renderNextPage: $
801
- } = I(n, w, b, a, e), {
812
+ } = ne(l, b, O, a, e), {
813
+ renderLastPage: $,
814
+ renderNextPage: z
815
+ } = K(l, w, y, a, e), {
802
816
  renderPageInfo: D
803
- } = K(l, u), {
804
- renderPageList: _
805
- } = ee(n, a, k, u, e), {
806
- renderPageNumbers: x
807
- } = te(n, v, a, e), {
817
+ } = ee(n, u), {
818
+ renderPageList: W
819
+ } = te(l, a, k, u, e), {
820
+ renderPageNumbers: q
821
+ } = ae(l, v, a, e), {
808
822
  renderGotoButton: F
809
- } = Z(n, b, a, e);
810
- h(n.value, a.value, u.value, 7), M([n, a], () => {
811
- h(n.value, a.value, u.value, 7);
812
- }), M(n, () => {
813
- e.emit("pageIndexChanged", n.value);
823
+ } = I(l, y, a, e);
824
+ h(l.value, a.value, u.value, 7), M([l, a], () => {
825
+ h(l.value, a.value, u.value, 7);
826
+ }), M(l, () => {
827
+ e.emit("pageIndexChanged", l.value);
814
828
  }), M(a, () => {
815
829
  e.emit("pageSizeChanged", a.value);
816
830
  });
817
- const C = d(() => ({
831
+ const x = d(() => ({
818
832
  "ngx-pagination": !0,
819
833
  pagination: !0,
820
834
  responsive: p.value,
821
835
  "pager-viewmode-default": i.value === "default",
822
836
  "pager-viewmode-simple": i.value === "simple"
823
- })), G = d(() => ({
837
+ })), C = d(() => ({
824
838
  position: "relative",
825
- "justify-content": l.value === "center" ? "center" : "start"
839
+ "justify-content": n.value === "center" ? "center" : "start"
826
840
  }));
827
841
  function L() {
828
- return r(A, null, [g.value && D(), j.value && _(), P.value && B(), P.value && E(), S.value && x(), P.value && $(), P.value && z(), N.value && F()]);
842
+ return r(A, null, [g.value && D(), j.value && W(), P.value && B(), P.value && E(), S.value && q(), P.value && z(), P.value && $(), N.value && F()]);
829
843
  }
830
- function le() {
844
+ function se() {
831
845
  return r(A, null, [r("li", {
832
846
  class: "page-item d-flex flex-fill"
833
847
  }, null), P.value && B(), P.value && E(), F(), r("li", {
@@ -840,28 +854,28 @@ const Fe = /* @__PURE__ */ J({
840
854
  style: "margin-left: 5px"
841
855
  }, [r("span", {
842
856
  style: "font-size: 16px; font-weight: 600;"
843
- }, [R(" "), b.value])]), P.value && $(), P.value && z()]);
857
+ }, [R(" "), y.value])]), P.value && z(), P.value && $()]);
844
858
  }
845
859
  return () => r("div", {
846
860
  ref: o,
847
861
  class: "pagination-container"
848
862
  }, [T.value && r("ul", {
849
863
  role: "navigation",
850
- class: C.value,
851
- style: G.value
852
- }, [i.value === "default" ? L() : le()])]);
864
+ class: x.value,
865
+ style: C.value
866
+ }, [i.value === "default" ? L() : se()])]);
853
867
  }
854
868
  });
855
869
  V.register = (t, e, p) => {
856
- t.pagination = V, e.pagination = Y;
870
+ t.pagination = V, e.pagination = Z;
857
871
  };
858
872
  V.registerDesigner = (t, e, p) => {
859
- t.pagination = Fe, e.pagination = Y;
873
+ t.pagination = Ae, e.pagination = Z;
860
874
  };
861
875
  const xe = ce(V);
862
876
  export {
863
877
  V as FPagination,
864
878
  xe as default,
865
- W as paginationProps,
866
- Y as propsResolver
879
+ _ as paginationProps,
880
+ Z as propsResolver
867
881
  };