@aplus-frontend/ui 7.13.8 → 7.13.9

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 (217) hide show
  1. package/es/src/ag-grid/components/body-cell/index.vue2.mjs +7 -7
  2. package/es/src/ag-grid/components/empty/index.vue2.mjs +10 -10
  3. package/es/src/ag-grid/components/header-cell/index.vue2.mjs +37 -37
  4. package/es/src/ag-grid/components/row/index.vue2.mjs +5 -5
  5. package/es/src/ag-grid/components/tooltip/index.vue2.mjs +12 -12
  6. package/es/src/ag-grid/editable/form-item.vue.mjs +49 -49
  7. package/es/src/ag-grid/editable/index.vue.mjs +27 -27
  8. package/es/src/ag-grid/index.vue.mjs +249 -249
  9. package/es/src/ap-action/group/index.vue.mjs +15 -15
  10. package/es/src/ap-action/item/index.vue2.mjs +28 -28
  11. package/es/src/ap-action/item-dropdown/index.vue.mjs +39 -39
  12. package/es/src/ap-field/checkbox/index.vue.mjs +19 -19
  13. package/es/src/ap-field/checkbox/read.vue2.mjs +9 -9
  14. package/es/src/ap-field/date/index.vue.mjs +50 -50
  15. package/es/src/ap-field/date/read.vue2.mjs +7 -7
  16. package/es/src/ap-field/date-range/index.vue.mjs +30 -30
  17. package/es/src/ap-field/date-range/read.vue2.mjs +20 -20
  18. package/es/src/ap-field/number/index.vue.mjs +24 -24
  19. package/es/src/ap-field/radio/index.vue.mjs +24 -24
  20. package/es/src/ap-field/second/index.vue.mjs +15 -15
  21. package/es/src/ap-field/second/read.vue2.mjs +7 -7
  22. package/es/src/ap-field/segmented/index.vue.mjs +24 -24
  23. package/es/src/ap-field/select/index.vue.d.ts +12 -2
  24. package/es/src/ap-field/select/index.vue.mjs +127 -124
  25. package/es/src/ap-field/select/read.vue2.mjs +6 -6
  26. package/es/src/ap-field/slider/index.vue.mjs +11 -11
  27. package/es/src/ap-field/style/select.mjs +53 -36
  28. package/es/src/ap-field/switch/index.vue.mjs +45 -45
  29. package/es/src/ap-field/text/read-password.vue2.mjs +13 -13
  30. package/es/src/ap-field/text/read.vue2.mjs +3 -3
  31. package/es/src/ap-field/text-area/index.vue.mjs +29 -29
  32. package/es/src/ap-field/text-area/read.vue2.mjs +12 -12
  33. package/es/src/ap-field/tree-select/index.vue.mjs +31 -31
  34. package/es/src/ap-form/ap-form.vue2.mjs +46 -46
  35. package/es/src/ap-form/drawer-form/index.vue.mjs +30 -30
  36. package/es/src/ap-form/item/index.vue.mjs +75 -75
  37. package/es/src/ap-form/items/checkbox/index.vue.mjs +10 -10
  38. package/es/src/ap-form/items/number/index.vue.mjs +17 -17
  39. package/es/src/ap-form/items/radio/index.vue.mjs +13 -13
  40. package/es/src/ap-form/items/switch/index.vue.mjs +14 -14
  41. package/es/src/ap-form/items/text/index.vue2.mjs +26 -26
  42. package/es/src/ap-form/items/text/password.vue.mjs +19 -19
  43. package/es/src/ap-form/items/text-area/index.vue.mjs +17 -17
  44. package/es/src/ap-form/modal-form/index.vue.mjs +34 -34
  45. package/es/src/ap-form/search-form/components/popover-filter.vue2.mjs +39 -39
  46. package/es/src/ap-form/search-form/components/popover-sorter/sortable-item.vue2.mjs +7 -7
  47. package/es/src/ap-grid/editable/form-item.vue.mjs +46 -46
  48. package/es/src/ap-grid/editable/index.vue.mjs +19 -19
  49. package/es/src/ap-grid/index.vue.mjs +212 -212
  50. package/es/src/ap-list/index.vue.mjs +116 -116
  51. package/es/src/ap-table/ap-table.vue2.mjs +217 -217
  52. package/es/src/ap-table/components/index/index.vue2.mjs +9 -9
  53. package/es/src/ap-table/components/setting/modal/index.vue2.mjs +52 -51
  54. package/es/src/ap-table/components/setting/select-group/index.vue2.mjs +21 -21
  55. package/es/src/ap-table/components/setting/sortable/index.vue2.mjs +15 -15
  56. package/es/src/ap-table/components/setting/sortable/item.vue2.mjs +69 -69
  57. package/es/src/ap-table/components/setting/template/edit-form.vue.d.ts +1 -0
  58. package/es/src/ap-table/components/setting/template/edit-form.vue2.mjs +31 -30
  59. package/es/src/ap-table/components/setting/template/index.vue2.mjs +25 -25
  60. package/es/src/ap-table/components/setting/template/item.vue2.mjs +41 -40
  61. package/es/src/ap-table/components/setting/tree-select/index.vue2.mjs +14 -14
  62. package/es/src/ap-table/style/setting.mjs +2 -2
  63. package/es/src/business/ag-grid-modal/modal-layout/index.vue2.mjs +54 -54
  64. package/es/src/business/ag-grid-modal/selected-items/default.vue2.mjs +13 -13
  65. package/es/src/business/ag-grid-modal/wrapper/index.vue2.mjs +20 -20
  66. package/es/src/business/ap-descriptions/ap-descriptions.vue.mjs +33 -33
  67. package/es/src/business/ap-descriptions/help-message/index.vue2.mjs +13 -13
  68. package/es/src/business/ap-download/ap-download.vue.mjs +24 -24
  69. package/es/src/business/ap-expand-alert/ApExpandAlert.vue.mjs +77 -77
  70. package/es/src/business/ap-radio-group/ap-radio-group.vue2.mjs +33 -33
  71. package/es/src/business/ap-status/group/ApStatusGroup.vue2.mjs +12 -12
  72. package/es/src/business/ap-table-modal/table-layout/index.vue2.mjs +43 -43
  73. package/es/src/business/ap-table-modal/table-modal.vue2.mjs +57 -57
  74. package/es/src/business/ap-tag/ap-tag-group.vue.mjs +37 -37
  75. package/es/src/business/ap-tag/ap-tag.vue.mjs +24 -24
  76. package/es/src/business/ap-title/ApTitle.vue2.mjs +27 -27
  77. package/es/src/business/ap-value-select-card/index.vue2.mjs +98 -98
  78. package/es/src/business/ap-view/components/main-button-content.vue.d.ts +1 -1
  79. package/es/src/business/batch-input-group/form-item.vue.mjs +25 -25
  80. package/es/src/business/batch-input-group/index.vue.mjs +60 -60
  81. package/es/src/business/batch-input-group/popover-input/index.vue2.mjs +29 -29
  82. package/es/src/editable-table/form-item.vue.mjs +35 -35
  83. package/es/src/editable-table/index.vue.mjs +19 -19
  84. package/es/src/full-screen/index.vue.mjs +46 -46
  85. package/es/src/locale/lang/en.mjs +2 -1
  86. package/es/src/locale/lang/zh-cn.mjs +2 -1
  87. package/es/src/mask/index.vue.mjs +48 -48
  88. package/es/src/portal/index.vue.mjs +5 -5
  89. package/es/src/scroll-bar/internal.vue.mjs +62 -62
  90. package/es/src/scroll-view/index.vue.mjs +66 -66
  91. package/es/src/skeleton/components/desc/index.vue2.mjs +9 -9
  92. package/es/src/skeleton/components/desc/item-large.vue2.mjs +25 -25
  93. package/es/src/skeleton/components/desc/item.vue2.mjs +13 -13
  94. package/es/src/skeleton/components/list/index.vue2.mjs +14 -14
  95. package/es/src/skeleton/components/list/item.vue2.mjs +12 -12
  96. package/es/src/skeleton/components/page-header/index.vue2.mjs +8 -8
  97. package/es/src/skeleton/components/search-form/index.vue2.mjs +35 -35
  98. package/es/src/skeleton/components/table/index.vue2.mjs +17 -17
  99. package/es/src/skeleton/components/table/item.vue2.mjs +23 -23
  100. package/es/src/skeleton/descriptions.vue2.mjs +15 -15
  101. package/es/src/skeleton/list-page.vue2.mjs +12 -12
  102. package/es/src/splitter/Panel.vue2.mjs +11 -11
  103. package/es/src/splitter/SplitBar.vue2.mjs +79 -79
  104. package/es/src/splitter/Splitter.vue2.mjs +50 -50
  105. package/es/src/text/group.vue.mjs +8 -8
  106. package/es/src/text/index.vue.mjs +48 -48
  107. package/es/src/version.d.ts +1 -1
  108. package/es/src/version.mjs +1 -1
  109. package/lib/src/ag-grid/components/body-cell/index.vue2.js +1 -1
  110. package/lib/src/ag-grid/components/empty/index.vue2.js +1 -1
  111. package/lib/src/ag-grid/components/header-cell/index.vue2.js +1 -1
  112. package/lib/src/ag-grid/components/row/index.vue2.js +1 -1
  113. package/lib/src/ag-grid/components/tooltip/index.vue2.js +1 -1
  114. package/lib/src/ag-grid/editable/form-item.vue.js +1 -1
  115. package/lib/src/ag-grid/editable/index.vue.js +1 -1
  116. package/lib/src/ag-grid/index.vue.js +1 -1
  117. package/lib/src/ap-action/group/index.vue.js +1 -1
  118. package/lib/src/ap-action/item/index.vue2.js +1 -1
  119. package/lib/src/ap-action/item-dropdown/index.vue.js +1 -1
  120. package/lib/src/ap-field/checkbox/index.vue.js +1 -1
  121. package/lib/src/ap-field/checkbox/read.vue2.js +1 -1
  122. package/lib/src/ap-field/date/index.vue.js +1 -1
  123. package/lib/src/ap-field/date/read.vue2.js +1 -1
  124. package/lib/src/ap-field/date-range/index.vue.js +1 -1
  125. package/lib/src/ap-field/date-range/read.vue2.js +1 -1
  126. package/lib/src/ap-field/number/index.vue.js +1 -1
  127. package/lib/src/ap-field/radio/index.vue.js +1 -1
  128. package/lib/src/ap-field/second/index.vue.js +1 -1
  129. package/lib/src/ap-field/second/read.vue2.js +1 -1
  130. package/lib/src/ap-field/segmented/index.vue.js +1 -1
  131. package/lib/src/ap-field/select/index.vue.d.ts +12 -2
  132. package/lib/src/ap-field/select/index.vue.js +1 -1
  133. package/lib/src/ap-field/select/read.vue2.js +1 -1
  134. package/lib/src/ap-field/slider/index.vue.js +1 -1
  135. package/lib/src/ap-field/style/select.js +1 -1
  136. package/lib/src/ap-field/switch/index.vue.js +1 -1
  137. package/lib/src/ap-field/text/read-password.vue2.js +1 -1
  138. package/lib/src/ap-field/text/read.vue2.js +1 -1
  139. package/lib/src/ap-field/text-area/index.vue.js +1 -1
  140. package/lib/src/ap-field/text-area/read.vue2.js +1 -1
  141. package/lib/src/ap-field/tree-select/index.vue.js +1 -1
  142. package/lib/src/ap-form/ap-form.vue2.js +1 -1
  143. package/lib/src/ap-form/drawer-form/index.vue.js +1 -1
  144. package/lib/src/ap-form/item/index.vue.js +1 -1
  145. package/lib/src/ap-form/items/checkbox/index.vue.js +1 -1
  146. package/lib/src/ap-form/items/number/index.vue.js +1 -1
  147. package/lib/src/ap-form/items/radio/index.vue.js +1 -1
  148. package/lib/src/ap-form/items/switch/index.vue.js +1 -1
  149. package/lib/src/ap-form/items/text/index.vue2.js +1 -1
  150. package/lib/src/ap-form/items/text/password.vue.js +1 -1
  151. package/lib/src/ap-form/items/text-area/index.vue.js +1 -1
  152. package/lib/src/ap-form/modal-form/index.vue.js +1 -1
  153. package/lib/src/ap-form/search-form/components/popover-filter.vue2.js +1 -1
  154. package/lib/src/ap-form/search-form/components/popover-sorter/sortable-item.vue2.js +1 -1
  155. package/lib/src/ap-grid/editable/form-item.vue.js +1 -1
  156. package/lib/src/ap-grid/editable/index.vue.js +1 -1
  157. package/lib/src/ap-grid/index.vue.js +1 -1
  158. package/lib/src/ap-list/index.vue.js +1 -1
  159. package/lib/src/ap-table/ap-table.vue2.js +1 -1
  160. package/lib/src/ap-table/components/index/index.vue2.js +1 -1
  161. package/lib/src/ap-table/components/setting/modal/index.vue2.js +1 -1
  162. package/lib/src/ap-table/components/setting/select-group/index.vue2.js +1 -1
  163. package/lib/src/ap-table/components/setting/sortable/index.vue2.js +1 -1
  164. package/lib/src/ap-table/components/setting/sortable/item.vue2.js +1 -1
  165. package/lib/src/ap-table/components/setting/template/edit-form.vue.d.ts +1 -0
  166. package/lib/src/ap-table/components/setting/template/edit-form.vue2.js +1 -1
  167. package/lib/src/ap-table/components/setting/template/index.vue2.js +1 -1
  168. package/lib/src/ap-table/components/setting/template/item.vue2.js +1 -1
  169. package/lib/src/ap-table/components/setting/tree-select/index.vue2.js +1 -1
  170. package/lib/src/ap-table/style/setting.js +1 -1
  171. package/lib/src/business/ag-grid-modal/modal-layout/index.vue2.js +1 -1
  172. package/lib/src/business/ag-grid-modal/selected-items/default.vue2.js +1 -1
  173. package/lib/src/business/ag-grid-modal/wrapper/index.vue2.js +1 -1
  174. package/lib/src/business/ap-descriptions/ap-descriptions.vue.js +1 -1
  175. package/lib/src/business/ap-descriptions/help-message/index.vue2.js +1 -1
  176. package/lib/src/business/ap-download/ap-download.vue.js +1 -1
  177. package/lib/src/business/ap-expand-alert/ApExpandAlert.vue.js +1 -1
  178. package/lib/src/business/ap-radio-group/ap-radio-group.vue2.js +1 -1
  179. package/lib/src/business/ap-status/group/ApStatusGroup.vue2.js +1 -1
  180. package/lib/src/business/ap-table-modal/table-layout/index.vue2.js +1 -1
  181. package/lib/src/business/ap-table-modal/table-modal.vue2.js +1 -1
  182. package/lib/src/business/ap-tag/ap-tag-group.vue.js +1 -1
  183. package/lib/src/business/ap-tag/ap-tag.vue.js +1 -1
  184. package/lib/src/business/ap-title/ApTitle.vue2.js +1 -1
  185. package/lib/src/business/ap-value-select-card/index.vue2.js +1 -1
  186. package/lib/src/business/ap-view/components/main-button-content.vue.d.ts +1 -1
  187. package/lib/src/business/batch-input-group/form-item.vue.js +1 -1
  188. package/lib/src/business/batch-input-group/index.vue.js +2 -2
  189. package/lib/src/business/batch-input-group/popover-input/index.vue2.js +2 -2
  190. package/lib/src/editable-table/form-item.vue.js +1 -1
  191. package/lib/src/editable-table/index.vue.js +1 -1
  192. package/lib/src/full-screen/index.vue.js +1 -1
  193. package/lib/src/locale/lang/en.js +1 -1
  194. package/lib/src/locale/lang/zh-cn.js +1 -1
  195. package/lib/src/mask/index.vue.js +1 -1
  196. package/lib/src/portal/index.vue.js +1 -1
  197. package/lib/src/scroll-bar/internal.vue.js +1 -1
  198. package/lib/src/scroll-view/index.vue.js +1 -1
  199. package/lib/src/skeleton/components/desc/index.vue2.js +1 -1
  200. package/lib/src/skeleton/components/desc/item-large.vue2.js +1 -1
  201. package/lib/src/skeleton/components/desc/item.vue2.js +1 -1
  202. package/lib/src/skeleton/components/list/index.vue2.js +1 -1
  203. package/lib/src/skeleton/components/list/item.vue2.js +1 -1
  204. package/lib/src/skeleton/components/page-header/index.vue2.js +1 -1
  205. package/lib/src/skeleton/components/search-form/index.vue2.js +1 -1
  206. package/lib/src/skeleton/components/table/index.vue2.js +1 -1
  207. package/lib/src/skeleton/components/table/item.vue2.js +1 -1
  208. package/lib/src/skeleton/descriptions.vue2.js +1 -1
  209. package/lib/src/skeleton/list-page.vue2.js +1 -1
  210. package/lib/src/splitter/Panel.vue2.js +1 -1
  211. package/lib/src/splitter/SplitBar.vue2.js +1 -1
  212. package/lib/src/splitter/Splitter.vue2.js +1 -1
  213. package/lib/src/text/group.vue.js +1 -1
  214. package/lib/src/text/index.vue.js +1 -1
  215. package/lib/src/version.d.ts +1 -1
  216. package/lib/src/version.js +1 -1
  217. package/package.json +1 -1
@@ -1,13 +1,13 @@
1
- import { defineComponent as E, ref as i, watch as S, unref as l, computed as n, createBlock as v, openBlock as w, withCtx as b, resolveDynamicComponent as z, mergeProps as C, renderSlot as F, createElementVNode as I, normalizeClass as N } from "vue";
2
- import { useScrollLock as $ } from "@vueuse/core";
1
+ import { defineComponent as h, ref as f, watch as E, unref as l, computed as n, createBlock as d, openBlock as v, withCtx as w, resolveDynamicComponent as S, mergeProps as z, renderSlot as C, createElementVNode as F, normalizeClass as I } from "vue";
2
+ import { useScrollLock as N } from "@vueuse/core";
3
3
  import "../config-provider/index.mjs";
4
4
  import "../hooks/index.mjs";
5
5
  import "../portal/index.mjs";
6
- import B from "./style/index.mjs";
7
- import { useFullScreen as L } from "../hooks/useFullScreen.mjs";
8
- import { useNamespace as D } from "../config-provider/hooks/use-namespace.mjs";
9
- import M from "../portal/index.vue.mjs";
10
- const O = /* @__PURE__ */ E({
6
+ import $ from "./style/index.mjs";
7
+ import { useFullScreen as B } from "../hooks/useFullScreen.mjs";
8
+ import { useNamespace as L } from "../config-provider/hooks/use-namespace.mjs";
9
+ import D from "../portal/index.vue.mjs";
10
+ const O = /* @__PURE__ */ h({
11
11
  name: "FullScreen",
12
12
  __name: "index",
13
13
  props: {
@@ -15,66 +15,66 @@ const O = /* @__PURE__ */ E({
15
15
  zIndex: { default: 2147483647 },
16
16
  to: { default: "body" }
17
17
  },
18
- setup(u, { expose: y }) {
18
+ setup(M, { expose: b }) {
19
19
  const {
20
- target: c,
21
- full: x,
22
- enter: g,
23
- exit: k
24
- } = L(), { b: m, bm: R, be: _ } = D("full-screen"), h = B("full-screen"), a = i(!1), t = i(), d = $(document.body), f = i();
25
- S(
26
- () => l(x),
20
+ target: i,
21
+ full: y,
22
+ enter: _,
23
+ exit: g
24
+ } = B(), { b: p, bm: k, be: x } = L("full-screen"), R = $("full-screen"), t = f(!1), a = f(), c = N(document.body), u = f();
25
+ E(
26
+ () => l(y),
27
27
  (e) => {
28
- e || (a.value = !1, t.value = void 0);
28
+ e || (t.value = !1, a.value = void 0);
29
29
  }
30
30
  );
31
31
  async function r(e, o = !1) {
32
- await s(), a.value = !0, t.value = e, e === "browser" ? g(o) : d.value = !0;
32
+ await s(), t.value = !0, a.value = e, e === "browser" ? _(o) : c.value = !0;
33
33
  }
34
34
  async function s(e = !1) {
35
- a.value = !1, t.value === "browser" ? await k(e) : d.value = !1, t.value = void 0;
35
+ t.value = !1, a.value === "browser" ? await g(e) : c.value = !1, a.value = void 0;
36
36
  }
37
- async function p(e, o = !1) {
38
- a.value ? t.value !== e ? await r(e, o) : await s(o) : await r(e, o);
37
+ async function m(e, o = !1) {
38
+ t.value ? a.value !== e ? await r(e, o) : await s(o) : await r(e, o);
39
39
  }
40
- return y({
41
- target: n(() => l(c)),
42
- portalRoot: n(() => l(f)),
43
- full: n(() => l(a)),
44
- mode: n(() => l(t)),
40
+ return b({
41
+ target: n(() => l(i)),
42
+ portalRoot: n(() => l(u)),
43
+ full: n(() => l(t)),
44
+ mode: n(() => l(a)),
45
45
  enter: r,
46
46
  exit: s,
47
- toggle: p
48
- }), (e, o) => (w(), v(l(M), {
49
- to: u.to,
50
- disabled: t.value !== "window"
47
+ toggle: m
48
+ }), (e, o) => (v(), d(l(D), {
49
+ to: e.to,
50
+ disabled: a.value !== "window"
51
51
  }, {
52
- default: b(() => [
53
- (w(), v(z(u.wrapperElementName), C({
52
+ default: w(() => [
53
+ (v(), d(S(e.wrapperElementName), z({
54
54
  ref_key: "target",
55
- ref: c
55
+ ref: i
56
56
  }, e.$attrs, {
57
57
  class: [
58
- l(m)(),
59
- l(m)("wrapper"),
60
- a.value && t.value === "window" ? l(R)("wrapper", "full") : null,
61
- l(h)
58
+ l(p)(),
59
+ l(p)("wrapper"),
60
+ t.value && a.value === "window" ? l(k)("wrapper", "full") : null,
61
+ l(R)
62
62
  ],
63
- style: { zIndex: a.value && t.value === "window" ? u.zIndex : "unset" }
63
+ style: { zIndex: t.value && a.value === "window" ? e.zIndex : "unset" }
64
64
  }), {
65
- default: b(() => [
66
- F(e.$slots, "default", {
67
- full: a.value,
65
+ default: w(() => [
66
+ C(e.$slots, "default", {
67
+ full: t.value,
68
68
  enter: r,
69
69
  exit: s,
70
- toggle: p,
71
- mode: t.value,
72
- portalRoot: f.value
70
+ toggle: m,
71
+ mode: a.value,
72
+ portalRoot: u.value
73
73
  }),
74
- I("div", {
74
+ F("div", {
75
75
  ref_key: "portalRootRef",
76
- ref: f,
77
- class: N(l(_)("wrapper", "portal-root"))
76
+ ref: u,
77
+ class: I(l(x)("wrapper", "portal-root"))
78
78
  }, null, 2)
79
79
  ]),
80
80
  _: 3
@@ -69,7 +69,8 @@ const a = {
69
69
  saveAndApply: "Save and Apply",
70
70
  modifyNotification: "The current template has been modified. You can save it as a new template.",
71
71
  templateSetting: "Column Configuration Template",
72
- templateName: "New Template Name",
72
+ templateName: "Template Name",
73
+ newTemplateName: "New Template Name",
73
74
  templateNamePlaceholder: "Please enter a template name"
74
75
  },
75
76
  paragraphEllipsis: {
@@ -78,7 +78,8 @@ const a = {
78
78
  saveAndApply: "保存并应用",
79
79
  modifyNotification: "当前模板存在变更,可保存为新模板",
80
80
  templateSetting: "列配置模板",
81
- templateName: "新模板名称",
81
+ templateName: "模板名称",
82
+ newTemplateName: "新模板名称",
82
83
  templateNamePlaceholder: "请输入模板名称"
83
84
  },
84
85
  paragraphEllipsis: {
@@ -1,11 +1,11 @@
1
- import { defineComponent as A, ref as v, watch as y, watchEffect as M, onMounted as V, onUnmounted as g, createBlock as O, createCommentVNode as i, openBlock as k, Teleport as P, createElementVNode as c, normalizeStyle as C, unref as o, normalizeClass as u, createVNode as b, Transition as h, withCtx as B, createElementBlock as T, renderSlot as w } from "vue";
1
+ import { defineComponent as M, ref as f, watch as v, watchEffect as V, onMounted as _, onUnmounted as g, createBlock as O, createCommentVNode as d, openBlock as y, Teleport as x, createElementVNode as i, normalizeStyle as k, unref as o, normalizeClass as u, createVNode as C, Transition as b, withCtx as h, createElementBlock as P, renderSlot as B } from "vue";
2
2
  import "../config-provider/index.mjs";
3
3
  import "../hooks/index.mjs";
4
- import U from "./style/index.mjs";
5
- import { getMaskZIndex as $, lockScrollable as j } from "./utils.mjs";
6
- import { useNamespace as D } from "../config-provider/hooks/use-namespace.mjs";
7
- import { useControllableValue as Z } from "../hooks/useControllableValue.mjs";
8
- const Q = /* @__PURE__ */ A({
4
+ import T from "./style/index.mjs";
5
+ import { getMaskZIndex as U, lockScrollable as $ } from "./utils.mjs";
6
+ import { useNamespace as j } from "../config-provider/hooks/use-namespace.mjs";
7
+ import { useControllableValue as D } from "../hooks/useControllableValue.mjs";
8
+ const Q = /* @__PURE__ */ M({
9
9
  name: "ApMask",
10
10
  __name: "index",
11
11
  props: {
@@ -20,97 +20,97 @@ const Q = /* @__PURE__ */ A({
20
20
  escClosable: { type: Boolean, default: !0 }
21
21
  },
22
22
  emits: ["update:open"],
23
- setup(l, { emit: E }) {
24
- const t = l, { b: r, e: m, em: S } = D("mask"), z = U("mask"), I = E, x = t.zIndex || $(), { value: a, updateValue: d } = Z(
23
+ setup(w, { emit: E }) {
24
+ const t = w, { b: s, e: c, em: S } = j("mask"), z = T("mask"), I = E, L = t.zIndex || U(), { value: a, updateValue: r } = D(
25
25
  t,
26
26
  I,
27
27
  {
28
28
  valuePropName: "open"
29
29
  }
30
- ), s = v(t.open);
31
- y(
30
+ ), l = f(t.open);
31
+ v(
32
32
  () => a.value,
33
33
  (e) => {
34
- e && (s.value = e);
34
+ e && (l.value = e);
35
35
  }
36
36
  );
37
- const f = v();
38
- y(f, (e) => {
37
+ const p = f();
38
+ v(p, (e) => {
39
39
  e && e.addEventListener("wheel", (n) => {
40
40
  n.stopPropagation(), n.preventDefault();
41
41
  });
42
- }), M((e) => {
42
+ }), V((e) => {
43
43
  if (!a.value)
44
44
  return;
45
- const n = j();
45
+ const n = $();
46
46
  e(() => {
47
47
  n?.();
48
48
  });
49
- }), V(() => {
50
- document.addEventListener("keydown", p);
49
+ }), _(() => {
50
+ document.addEventListener("keydown", m);
51
51
  }), g(() => {
52
- document.removeEventListener("keydown", p);
52
+ document.removeEventListener("keydown", m);
53
53
  });
54
- function L() {
55
- s.value = !1;
54
+ function N() {
55
+ l.value = !1;
56
56
  }
57
- async function N() {
57
+ async function A() {
58
58
  if (t.closable) {
59
59
  if (t.onBeforeClose) {
60
- await t.onBeforeClose() && d(!1);
60
+ await t.onBeforeClose() && r(!1);
61
61
  return;
62
62
  }
63
- d(!1);
63
+ r(!1);
64
64
  }
65
65
  }
66
- function p(e) {
67
- !a.value || !(t.closable && t.escClosable) || e.key === "Escape" && d(!1);
66
+ function m(e) {
67
+ !a.value || !(t.closable && t.escClosable) || e.key === "Escape" && r(!1);
68
68
  }
69
- return (e, n) => !l.deleteOnClose || s.value ? (k(), O(P, {
69
+ return (e, n) => !e.deleteOnClose || l.value ? (y(), O(x, {
70
70
  key: 0,
71
71
  to: "body"
72
72
  }, [
73
- c("div", {
73
+ i("div", {
74
74
  ref_key: "wrapper",
75
- ref: f,
76
- class: u([o(r)(), o(z)]),
77
- style: C({ zIndex: o(x), visibility: s.value ? void 0 : "hidden" })
75
+ ref: p,
76
+ class: u([o(s)(), o(z)]),
77
+ style: k({ zIndex: o(L), visibility: l.value ? void 0 : "hidden" })
78
78
  }, [
79
- b(h, {
79
+ C(b, {
80
80
  appear: "",
81
- name: o(r)("fade"),
82
- onAfterLeave: L
81
+ name: o(s)("fade"),
82
+ onAfterLeave: N
83
83
  }, {
84
- default: B(() => [
85
- o(a) ? (k(), T("div", {
84
+ default: h(() => [
85
+ o(a) ? (y(), P("div", {
86
86
  key: 0,
87
- class: u([o(m)("mask"), { [o(S)("mask", "disabled")]: l.disabled }]),
88
- onClick: N
87
+ class: u([o(c)("mask"), { [o(S)("mask", "disabled")]: e.disabled }]),
88
+ onClick: A
89
89
  }, [
90
- w(e.$slots, "mask", {}, () => [
91
- c("div", {
92
- class: u(o(m)("mask-inner"))
90
+ B(e.$slots, "mask", {}, () => [
91
+ i("div", {
92
+ class: u(o(c)("mask-inner"))
93
93
  }, null, 2)
94
94
  ])
95
- ], 2)) : i("", !0)
95
+ ], 2)) : d("", !0)
96
96
  ]),
97
97
  _: 3
98
98
  }, 8, ["name"]),
99
- c("div", {
100
- style: C(l.contentStyle)
99
+ i("div", {
100
+ style: k(e.contentStyle)
101
101
  }, [
102
- b(h, {
102
+ C(b, {
103
103
  appear: "",
104
- name: o(r)("fade")
104
+ name: o(s)("fade")
105
105
  }, {
106
- default: B(() => [
107
- o(a) ? w(e.$slots, "default", { key: 0 }) : i("", !0)
106
+ default: h(() => [
107
+ o(a) ? B(e.$slots, "default", { key: 0 }) : d("", !0)
108
108
  ]),
109
109
  _: 3
110
110
  }, 8, ["name"])
111
111
  ], 4)
112
112
  ], 6)
113
- ])) : i("", !0);
113
+ ])) : d("", !0);
114
114
  }
115
115
  });
116
116
  export {
@@ -1,4 +1,4 @@
1
- import { defineComponent as r, createBlock as n, openBlock as a, Teleport as l, mergeProps as p, renderSlot as s } from "vue";
1
+ import { defineComponent as r, createBlock as n, openBlock as p, Teleport as a, mergeProps as l, renderSlot as s } from "vue";
2
2
  const m = /* @__PURE__ */ r({
3
3
  name: "Portal",
4
4
  __name: "index",
@@ -7,12 +7,12 @@ const m = /* @__PURE__ */ r({
7
7
  disabled: { type: Boolean },
8
8
  defer: { type: Boolean }
9
9
  },
10
- setup(e) {
11
- const o = e;
12
- return (t, d) => (a(), n(l, p(o, {
10
+ setup(o) {
11
+ const t = o;
12
+ return (e, d) => (p(), n(a, l(t, {
13
13
  to: e.to || "body"
14
14
  }), [
15
- s(t.$slots, "default")
15
+ s(e.$slots, "default")
16
16
  ], 16, ["to"]));
17
17
  }
18
18
  });
@@ -1,10 +1,10 @@
1
- import { defineComponent as x, shallowRef as m, ref as V, toRef as h, watch as W, watchEffect as z, unref as o, createElementBlock as A, openBlock as N, normalizeStyle as U, normalizeClass as k, createElementVNode as L } from "vue";
1
+ import { defineComponent as V, shallowRef as h, ref as W, toRef as f, watch as z, watchEffect as A, unref as o, createElementBlock as N, openBlock as U, normalizeStyle as X, normalizeClass as b, createElementVNode as E } from "vue";
2
2
  import "../config-provider/index.mjs";
3
- import { useTrack as X } from "./hooks/use-track.mjs";
4
- import Y from "./style/index.mjs";
5
- import { ensureRangeValue as C } from "./utils/index.mjs";
6
- import { useNamespace as I } from "../config-provider/hooks/use-namespace.mjs";
7
- const K = /* @__PURE__ */ x({
3
+ import { useTrack as Y } from "./hooks/use-track.mjs";
4
+ import I from "./style/index.mjs";
5
+ import { ensureRangeValue as L } from "./utils/index.mjs";
6
+ import { useNamespace as j } from "../config-provider/hooks/use-namespace.mjs";
7
+ const O = /* @__PURE__ */ V({
8
8
  __name: "internal",
9
9
  props: {
10
10
  direction: { default: "vertical" },
@@ -21,15 +21,15 @@ const K = /* @__PURE__ */ x({
21
21
  onScroll: {},
22
22
  onScrollEnd: {}
23
23
  },
24
- setup(r, { expose: D }) {
25
- const t = r, v = m(), i = m(), a = m(), { b: M, e: p, m: R, em: s, cssVar: B } = I("scroll-bar"), P = Y("scroll-bar"), l = V(t.scroll), { handleMouseDown: g } = X({
26
- currentScroll: l,
24
+ setup(C, { expose: D }) {
25
+ const t = C, m = h(), i = h(), l = h(), { b: M, e: k, m: R, em: c, cssVar: B } = j("scroll-bar"), P = I("scroll-bar"), n = W(t.scroll), { handleMouseDown: v } = Y({
26
+ currentScroll: n,
27
27
  track: i,
28
- bar: a,
29
- type: h(t, "direction"),
30
- trackSpeed: h(t, "trackSpeed"),
31
- barLength: h(t, "barLength"),
32
- disabled: h(t, "disabled"),
28
+ bar: l,
29
+ type: f(t, "direction"),
30
+ trackSpeed: f(t, "trackSpeed"),
31
+ barLength: f(t, "barLength"),
32
+ disabled: f(t, "disabled"),
33
33
  onDown: (e) => {
34
34
  t.onScrollStart?.(e);
35
35
  },
@@ -40,91 +40,91 @@ const K = /* @__PURE__ */ x({
40
40
  t.onScroll?.(e);
41
41
  }
42
42
  });
43
- W(
43
+ z(
44
44
  () => t.scroll,
45
45
  (e) => {
46
- l.value = e;
46
+ n.value = e;
47
47
  }
48
- ), z(() => {
49
- if (!o(a)) return;
50
- const e = `${(100 - t.barLength) * l.value / t.barLength}%`, n = `${t.barLength}%`;
51
- t.direction === "vertical" ? (a.value.style.height = n, a.value.style.transform = `translate3d(0, ${e}, 0)`) : (a.value.style.width = n, a.value.style.transform = `translate3d(${e}, 0, 0)`);
48
+ ), A(() => {
49
+ if (!o(l)) return;
50
+ const e = `${(100 - t.barLength) * n.value / t.barLength}%`, r = `${t.barLength}%`;
51
+ t.direction === "vertical" ? (l.value.style.height = r, l.value.style.transform = `translate3d(0, ${e}, 0)`) : (l.value.style.width = r, l.value.style.transform = `translate3d(${e}, 0, 0)`);
52
52
  });
53
- let b, d, u;
53
+ let p, s, d;
54
54
  function T(e) {
55
55
  if (t.disabled || e.button !== 0) return;
56
56
  e.preventDefault(), e.stopPropagation();
57
- const n = o(i), c = o(a);
58
- if (!n || !c)
57
+ const r = o(i), a = o(l);
58
+ if (!r || !a)
59
59
  return;
60
- document.addEventListener("pointermove", S), document.addEventListener("pointerup", w);
61
- const f = n.getBoundingClientRect(), E = c.getBoundingClientRect();
62
- t.direction === "vertical" ? (b = f.height, d = E.top - f.top, u = e.clientY) : (b = f.width, d = E.left - f.left, u = e.clientX), t.onScrollStart?.(o(l));
60
+ document.addEventListener("pointermove", g), document.addEventListener("pointerup", S);
61
+ const u = r.getBoundingClientRect(), y = a.getBoundingClientRect();
62
+ t.direction === "vertical" ? (p = u.height, s = y.top - u.top, d = e.clientY) : (p = u.width, s = y.left - u.left, d = e.clientX), t.onScrollStart?.(o(n));
63
63
  }
64
- function S(e) {
64
+ function g(e) {
65
65
  e.stopPropagation(), e.preventDefault();
66
- let n;
67
- t.direction === "vertical" ? n = d + e.clientY - u : n = d + e.clientX - u;
68
- const c = n / b / (100 - t.barLength) * 1e4;
69
- l.value = C(c), t.onScroll?.(o(l));
66
+ let r;
67
+ t.direction === "vertical" ? r = s + e.clientY - d : r = s + e.clientX - d;
68
+ const a = r / p / (100 - t.barLength) * 1e4;
69
+ n.value = L(a), t.onScroll?.(o(n));
70
70
  }
71
- function w(e) {
72
- e.preventDefault(), document.removeEventListener("pointermove", S), document.removeEventListener("pointerup", w), t.onScrollEnd?.(o(l));
71
+ function S(e) {
72
+ e.preventDefault(), document.removeEventListener("pointermove", g), document.removeEventListener("pointerup", S), t.onScrollEnd?.(o(n));
73
73
  }
74
- function y(e) {
74
+ function w(e) {
75
75
  e.cancelable && (e.stopPropagation(), e.preventDefault());
76
76
  }
77
77
  function $(e) {
78
- Math.abs(o(l) - e) <= 1e-3 || (l.value = C(e));
78
+ Math.abs(o(n) - e) <= 1e-3 || (n.value = L(e));
79
79
  }
80
80
  return D({
81
- currentScroll: l,
82
- container: v,
83
- bar: a,
81
+ currentScroll: n,
82
+ container: m,
83
+ bar: l,
84
84
  track: i,
85
85
  scroll: $
86
- }), (e, n) => (N(), A("div", {
86
+ }), (e, r) => (U(), N("div", {
87
87
  ref_key: "container",
88
- ref: v,
89
- class: k([o(M)(), o(R)(r.direction), o(P)]),
90
- style: U(
88
+ ref: m,
89
+ class: b([o(M)(), o(R)(e.direction), o(P)]),
90
+ style: X(
91
91
  o(B)(
92
92
  {
93
- "bar-color": r.barColor,
94
- "track-color": r.trackColor,
95
- "bar-width": r.width ? `${r.width}px` : void 0,
96
- "track-width": r.trackWidth ? `${r.trackWidth}px` : void 0
93
+ "bar-color": e.barColor,
94
+ "track-color": e.trackColor,
95
+ "bar-width": e.width ? `${e.width}px` : void 0,
96
+ "track-width": e.trackWidth ? `${e.trackWidth}px` : void 0
97
97
  },
98
98
  !1
99
99
  )
100
100
  )
101
101
  }, [
102
- L("div", {
102
+ E("div", {
103
103
  ref_key: "track",
104
104
  ref: i,
105
- class: k([
106
- o(p)("track"),
107
- r.disabled ? o(s)("track", "disabled") : null,
108
- r.showTrack ? null : o(s)("track", "hidden")
105
+ class: b([
106
+ o(k)("track"),
107
+ e.disabled ? o(c)("track", "disabled") : null,
108
+ e.showTrack ? null : o(c)("track", "hidden")
109
109
  ]),
110
- onPointerdown: n[0] || (n[0] = //@ts-ignore
111
- (...c) => o(g) && o(g)(...c)),
112
- onTouchstart: y
110
+ onPointerdown: r[0] || (r[0] = //@ts-ignore
111
+ (...a) => o(v) && o(v)(...a)),
112
+ onTouchstart: w
113
113
  }, null, 34),
114
- L("div", {
114
+ E("div", {
115
115
  ref_key: "bar",
116
- ref: a,
117
- class: k([
118
- o(p)("bar"),
119
- o(s)("bar", r.direction),
120
- r.disabled ? o(s)("bar", "disabled") : null
116
+ ref: l,
117
+ class: b([
118
+ o(k)("bar"),
119
+ o(c)("bar", e.direction),
120
+ e.disabled ? o(c)("bar", "disabled") : null
121
121
  ]),
122
122
  onPointerdown: T,
123
- onTouchstart: y
123
+ onTouchstart: w
124
124
  }, null, 34)
125
125
  ], 6));
126
126
  }
127
127
  });
128
128
  export {
129
- K as default
129
+ O as default
130
130
  };