@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,19 +1,19 @@
1
- import { defineComponent as ue, useSlots as se, ref as _, shallowRef as re, computed as s, onMounted as ie, watch as de, unref as o, createVNode as d, createElementBlock as M, createBlock as C, openBlock as c, toDisplayString as B, mergeProps as ce, h as pe, createSlots as fe, withCtx as p, normalizeClass as f, createCommentVNode as P, resolveDynamicComponent as D, withModifiers as me, renderList as he, renderSlot as ve, normalizeProps as ye, guardReactiveProps as ge, createElementVNode as k } from "vue";
2
- import { Select as we, Flex as T, Checkbox as q, Spin as Ce } from "@aplus-frontend/antdv";
3
- import { debounce as Se, isFunction as L, isArray as be, isNil as xe, omit as R, isNumber as Be } from "lodash-unified";
1
+ import { defineComponent as ie, useSlots as de, ref as I, shallowRef as ce, computed as s, onMounted as pe, watch as fe, unref as n, createVNode as c, createElementBlock as _, createBlock as C, openBlock as p, toDisplayString as N, mergeProps as me, h as he, createSlots as ve, withCtx as f, createElementVNode as x, normalizeClass as m, createCommentVNode as M, resolveDynamicComponent as P, withModifiers as ye, renderList as ge, renderSlot as Ce, normalizeProps as be, guardReactiveProps as we } from "vue";
2
+ import { Select as Se, Flex as D, Checkbox as T, Spin as ke } from "@aplus-frontend/antdv";
3
+ import { debounce as Be, isFunction as q, isArray as Ne, isNil as xe, omit as L, isNumber as Fe } from "lodash-unified";
4
4
  import "../../config-provider/index.mjs";
5
5
  import "../../utils/index.mjs";
6
6
  import "../../hooks/index.mjs";
7
- import { useDefaultPlaceholder as ke } from "../hooks/use-default-placeholder.mjs";
8
- import Ne from "../style/index.mjs";
9
- import { useSelectOptions as Oe } from "./use-select-options.mjs";
10
- import { useNamespace as Fe } from "../../config-provider/hooks/use-namespace.mjs";
11
- import { useLocale as Ae } from "../../config-provider/hooks/use-locale.mjs";
12
- import { useControllableValue as Ve } from "../../hooks/useControllableValue.mjs";
7
+ import { useDefaultPlaceholder as Oe } from "../hooks/use-default-placeholder.mjs";
8
+ import Ae from "../style/index.mjs";
9
+ import { useSelectOptions as Ve } from "./use-select-options.mjs";
10
+ import { useNamespace as R } from "../../config-provider/hooks/use-namespace.mjs";
11
+ import { useLocale as Ie } from "../../config-provider/hooks/use-locale.mjs";
12
+ import { useControllableValue as _e } from "../../hooks/useControllableValue.mjs";
13
13
  import { isDef as z } from "../../utils/is.mjs";
14
- const Ie = {
14
+ const Me = {
15
15
  key: 0
16
- }, _e = ["onClick"], He = /* @__PURE__ */ ue({
16
+ }, Pe = ["onClick"], Ge = /* @__PURE__ */ ie({
17
17
  name: "ApFieldSelect",
18
18
  __name: "index",
19
19
  props: {
@@ -172,189 +172,192 @@ const Ie = {
172
172
  }
173
173
  },
174
174
  emits: ["update:value"],
175
- setup(N, {
175
+ setup(E, {
176
176
  expose: U,
177
177
  emit: $
178
178
  }) {
179
179
  let r = 0;
180
- const O = se(), e = N, {
181
- b: a
182
- } = Fe("field-select"), K = Ne("field"), F = _(!1), {
180
+ const F = de(), e = E, {
181
+ b
182
+ } = R("field-select"), {
183
+ b: i
184
+ } = R("field-select-popup-option"), K = Ae("field"), O = I(!1), {
183
185
  t: A
184
- } = Ae(), j = Se((t) => {
185
- if (!L(e.request))
186
+ } = Ie(), j = Be((t) => {
187
+ if (!q(e.request))
186
188
  return;
187
189
  r += 1;
188
- const l = r;
189
- v([]), u.value = !0, e.request(t).then((n) => {
190
- r === l && (v(n), u.value = !1);
190
+ const o = r;
191
+ y([]), u.value = !0, e.request(t).then((l) => {
192
+ r === o && (y(l), u.value = !1);
191
193
  });
192
- }, e.searchDelay), E = (t, l) => {
193
- const n = e.fieldNames?.label || "label";
194
- return typeof l?.[n] == "string" && l[n].toLowerCase().indexOf(t.toLowerCase()) > -1;
194
+ }, e.searchDelay), H = (t, o) => {
195
+ const l = e.fieldNames?.label || "label";
196
+ return typeof o?.[l] == "string" && o[l].toLowerCase().indexOf(t.toLowerCase()) > -1;
195
197
  }, {
196
198
  options: h,
197
- updateOptions: v
198
- } = Oe(e), S = re(), u = _(e?.loading || !1), H = $, W = s(() => {
199
+ updateOptions: y
200
+ } = Ve(e), w = ce(), u = I(e?.loading || !1), W = $, G = s(() => {
199
201
  if (e.multiple)
200
202
  return e.tokenSeparators ? "tags" : "multiple";
201
203
  });
202
- async function y(t = !0) {
203
- if (!L(e.request))
204
+ async function g(t = !0) {
205
+ if (!q(e.request))
204
206
  return;
205
207
  u.value = !0, r += 1;
206
- const l = r;
208
+ const o = r;
207
209
  try {
208
- t && v([]);
209
- const n = await e.request(void 0, e.params);
210
- if (l !== r)
210
+ t && y([]);
211
+ const l = await e.request(void 0, e.params);
212
+ if (o !== r)
211
213
  return;
212
- v(n);
214
+ y(l);
213
215
  } finally {
214
216
  u.value = !1;
215
217
  }
216
218
  }
217
- function G(t) {
218
- e.onFocus?.(t), e.refetchOnFocus && r > 0 && !u.value && y(!0);
219
+ function J(t) {
220
+ e.onFocus?.(t), e.refetchOnFocus && r > 0 && !u.value && g(!0);
219
221
  }
220
- ie(() => {
221
- e.lazy || y();
222
- }), de(() => e.params, () => {
223
- y();
222
+ pe(() => {
223
+ e.lazy || g();
224
+ }), fe(() => e.params, () => {
225
+ g();
224
226
  }, {
225
227
  deep: !0
226
228
  });
227
229
  const {
228
- value: i,
229
- updateValue: g
230
- } = Ve(e, H), J = ke("Select", e), Q = s(() => {
231
- const t = o(i);
230
+ value: d,
231
+ updateValue: S
232
+ } = _e(e, W), Q = Oe("Select", e), X = s(() => {
233
+ const t = n(d);
232
234
  if (!t)
233
235
  return e.emptyText;
234
- const l = e.fieldNames?.label || "label", n = e.fieldNames?.value || "value";
235
- return be(t) ? t.map((m) => o(h).find((ae) => ae[n] === m)?.[l]).filter(Boolean).join("、") || e.emptyText : o(h).find((m) => m[n] === t)?.[l] || e.emptyText;
236
- }), X = s(() => {
237
- const t = !!e?.showSearch, l = e.searchMode;
238
- let n = {};
239
- return t && (n = l === "request" ? {
236
+ const o = e.fieldNames?.label || "label", l = e.fieldNames?.value || "value";
237
+ return Ne(t) ? t.map((v) => n(h).find((re) => re[l] === v)?.[o]).filter(Boolean).join("、") || e.emptyText : n(h).find((v) => v[l] === t)?.[o] || e.emptyText;
238
+ }), Y = s(() => {
239
+ const t = !!e?.showSearch, o = e.searchMode;
240
+ let l = {};
241
+ return t && (l = o === "request" ? {
240
242
  defaultActiveFirstOption: !1,
241
243
  onSearch: j,
242
244
  notFoundContent: u.value ? void 0 : null,
243
245
  filterOption: !1,
244
246
  suffixIcon: null
245
247
  } : {
246
- filterOption: xe(e?.filterOption) ? E : e?.filterOption
248
+ filterOption: xe(e?.filterOption) ? H : e?.filterOption
247
249
  }), {
248
- ...R(e, ["mode", "value", "onUpdate:value", "onSearch", "request", "searchMode", "onFocus", "onBeforeSelect"]),
249
- placeholder: o(J),
250
- ...n
250
+ ...L(e, ["mode", "value", "onUpdate:value", "onSearch", "request", "searchMode", "onFocus", "onBeforeSelect"]),
251
+ placeholder: n(Q),
252
+ ...l
251
253
  };
252
- }), w = s(() => h.value.map((t) => t[e.fieldNames?.value || "value"])), V = s(() => !e.multiple || z(e.maxCount) ? !1 : Be(e.addAll) ? w.value.length >= e.addAll : !!e.addAll), Y = s(() => e.multiple && e.allowOnlySelect && (!z(e.maxCount) || e.maxCount >= 1));
253
- function Z() {
254
- S.value?.focus();
254
+ }), Z = s(() => h.value.map((t) => t[e.fieldNames?.value || "value"])), k = s(() => h.value.filter((t) => !t.disabled).map((t) => t[e.fieldNames?.value || "value"])), V = s(() => !e.multiple || z(e.maxCount) ? !1 : Fe(e.addAll) ? Z.value.length >= e.addAll : !!e.addAll), ee = s(() => e.multiple && e.allowOnlySelect && (!z(e.maxCount) || e.maxCount >= 1));
255
+ function te() {
256
+ w.value?.focus();
255
257
  }
256
- function ee() {
257
- S.value?.blur();
258
+ function oe() {
259
+ w.value?.blur();
258
260
  }
259
- function b(t, l) {
260
- const n = e.fieldNames?.[l] ?? l;
261
- return t[n];
261
+ function B(t, o) {
262
+ const l = e.fieldNames?.[o] ?? o;
263
+ return t[l];
262
264
  }
263
- function te(t) {
264
- const l = b(t, "value");
265
- g(e.multiple ? [l] : l);
265
+ function le(t) {
266
+ const o = B(t, "value");
267
+ S(e.multiple ? [o] : o);
266
268
  }
267
- function oe(t) {
268
- return console.log(t), O.option ? d("div", {
269
- class: a("popup-option-custom")
270
- }, [O.option(t)]) : d("span", {
271
- class: a("popup-option-label")
272
- }, [b(t, "label")]);
269
+ function ne(t) {
270
+ return F.option ? c("div", {
271
+ class: i("custom")
272
+ }, [F.option(t)]) : c("span", {
273
+ class: i("label")
274
+ }, [B(t, "label")]);
273
275
  }
274
- const I = s(() => {
275
- const t = o(i) || [], l = w.value;
276
- return l.length > 0 && l.every((n) => t.includes(n));
277
- }), ne = s(() => (o(i) || []).length > 0 && !I.value);
278
- function le() {
279
- console.log("123");
280
- const t = o(i) || [], l = w.value;
281
- l.length && l.every((n) => t?.includes(n)) ? g([]) : g(w.value);
276
+ const ae = s(() => {
277
+ const t = n(d) || [], o = k.value;
278
+ return o.length > 0 && o.every((l) => t.includes(l));
279
+ }), se = s(() => {
280
+ const t = n(d) || [], o = k.value, l = o.filter((a) => t.includes(a)).length;
281
+ return l > 0 && l < o.length;
282
+ });
283
+ function ue() {
284
+ const t = new Set(n(d) || []), o = k.value;
285
+ o.length > 0 && o.every((a) => t.has(a)) ? o.forEach((a) => t.delete(a)) : o.forEach((a) => t.add(a)), S([...t]);
282
286
  }
283
287
  return U({
284
- focus: Z,
285
- blur: ee,
286
- request: y
287
- }), (t, l) => N.mode === "read" ? (c(), M("span", Ie, B(Q.value), 1)) : (c(), C(o(we), ce({
288
+ focus: te,
289
+ blur: oe,
290
+ request: g
291
+ }), (t, o) => t.mode === "read" ? (p(), _("span", Me, N(X.value), 1)) : (p(), C(n(Se), me({
288
292
  key: 1,
289
293
  ref_key: "selectRef",
290
- ref: S,
294
+ ref: w,
291
295
  "allow-clear": ""
292
- }, X.value, {
293
- mode: W.value,
294
- value: o(i),
295
- options: o(h),
296
+ }, Y.value, {
297
+ mode: G.value,
298
+ value: n(d),
299
+ options: n(h),
296
300
  loading: u.value,
297
- "menu-item-selected-icon": pe("span"),
298
- "popup-class-name": `${o(a)("popup")} ${o(K)}`,
299
- open: F.value,
300
- virtual: !1,
301
- "onUpdate:value": o(g),
302
- onFocus: G,
303
- onDropdownVisibleChange: l[0] || (l[0] = (n) => F.value = n)
304
- }), fe({
305
- option: p((n) => [d(o(T), {
301
+ "menu-item-selected-icon": he("span"),
302
+ "popup-class-name": `${n(b)("popup")} ${n(K)}`,
303
+ open: O.value,
304
+ "onUpdate:value": n(S),
305
+ onFocus: J,
306
+ onDropdownVisibleChange: o[0] || (o[0] = (l) => O.value = l)
307
+ }), ve({
308
+ option: f((l) => [x("div", {
309
+ class: m(n(i)("outter"))
310
+ }, [c(n(D), {
306
311
  justify: "space-between",
307
312
  align: "center",
308
- class: f(o(a)("popup-option-wrapper")),
313
+ class: m(n(i)("wrapper")),
309
314
  gap: 8
310
315
  }, {
311
- default: p(() => [d(o(T), {
316
+ default: f(() => [c(n(D), {
312
317
  gap: 8,
313
318
  align: "center",
314
- class: f(o(a)("popup-option-content-wrapper"))
319
+ class: m(n(i)("content-wrapper"))
315
320
  }, {
316
- default: p(() => [V.value ? (c(), C(o(q), {
321
+ default: f(() => [V.value ? (p(), C(n(T), {
317
322
  key: 0,
318
- checked: o(i)?.includes(b(n, "value"))
319
- }, null, 8, ["checked"])) : P("", !0), (c(), C(D(oe(n))))]),
323
+ checked: n(d)?.includes(B(l, "value"))
324
+ }, null, 8, ["checked"])) : M("", !0), (p(), C(P(ne(l))))]),
320
325
  _: 2
321
- }, 1032, ["class"]), Y.value ? (c(), M("span", {
326
+ }, 1032, ["class"]), ee.value && !l?.disabled ? (p(), _("span", {
322
327
  key: 0,
323
- class: f(o(a)("popup-option-action")),
324
- onClick: me(() => te(n), ["stop"])
325
- }, B(o(A)("ap.field.chooseOnly")), 11, _e)) : P("", !0)]),
328
+ class: m(n(i)("action")),
329
+ onClick: ye(() => le(l), ["stop"])
330
+ }, N(n(A)("ap.field.chooseOnly")), 11, Pe)) : M("", !0)]),
326
331
  _: 2
327
- }, 1032, ["class"])]),
332
+ }, 1032, ["class"])], 2)]),
328
333
  _: 2
329
- }, [he(o(R)(t.$slots, ["option"]), (n, x) => ({
330
- name: x,
331
- fn: p((m) => [ve(t.$slots, x, ye(ge(m || {})))])
334
+ }, [ge(n(L)(t.$slots, ["option"]), (l, a) => ({
335
+ name: a,
336
+ fn: f((v) => [Ce(t.$slots, a, be(we(v || {})))])
332
337
  })), u.value ? {
333
338
  name: "notFoundContent",
334
- fn: p(() => [d(o(Ce), {
339
+ fn: f(() => [c(n(ke), {
335
340
  size: "small"
336
341
  })]),
337
342
  key: "0"
338
343
  } : void 0, V.value ? {
339
344
  name: "dropdownRender",
340
- fn: p(({
341
- menuNode: n
342
- }) => [k("div", {
343
- class: f(o(a)("popup-all-option-wrapper"))
344
- }, [k("div", {
345
+ fn: f(({
346
+ menuNode: l
347
+ }) => [x("div", {
345
348
  tabindex: -1,
346
- class: f(o(a)("popup-all-option")),
347
- onClick: le
348
- }, [d(o(q), {
349
- checked: I.value,
350
- indeterminate: ne.value
351
- }, null, 8, ["checked", "indeterminate"]), k("span", {
352
- class: f(o(a)("popup-all-option-label"))
353
- }, B(o(A)("ap.field.selectAll")), 3)], 2)], 2), (c(), C(D(n)))]),
349
+ class: m(n(b)("popup-all-option")),
350
+ onClick: ue
351
+ }, [c(n(T), {
352
+ checked: ae.value,
353
+ indeterminate: se.value
354
+ }, null, 8, ["checked", "indeterminate"]), x("span", {
355
+ class: m(n(b)("popup-all-option-label"))
356
+ }, N(n(A)("ap.field.selectAll")), 3)], 2), (p(), C(P(l)))]),
354
357
  key: "1"
355
358
  } : void 0]), 1040, ["mode", "value", "options", "loading", "menu-item-selected-icon", "popup-class-name", "open", "onUpdate:value"]));
356
359
  }
357
360
  });
358
361
  export {
359
- He as default
362
+ Ge as default
360
363
  };
@@ -96,19 +96,19 @@ const f = { key: 0 }, C = /* @__PURE__ */ i({
96
96
  searchDelay: {},
97
97
  allowOnlySelect: { type: Boolean }
98
98
  },
99
- setup(a) {
100
- const e = a, r = s(() => {
99
+ setup(l) {
100
+ const e = l, r = s(() => {
101
101
  const o = e.value;
102
102
  if (!o)
103
103
  return e.emptyText;
104
- const t = e.fieldNames?.label || "label", l = e.fieldNames?.value || "value";
104
+ const t = e.fieldNames?.label || "label", a = e.fieldNames?.value || "value";
105
105
  return y(o) ? o.map(
106
- (n) => e.options?.find((p) => p[l] === n)?.[t]
106
+ (n) => e.options?.find((p) => p[a] === n)?.[t]
107
107
  ).filter(Boolean).join("、") || e.emptyText : e.options?.find(
108
- (n) => n[l] === o
108
+ (n) => n[a] === o
109
109
  )?.[t] || e.emptyText;
110
110
  });
111
- return (o, t) => a.mode === "read" ? (u(), d("span", f, m(r.value), 1)) : c("", !0);
111
+ return (o, t) => o.mode === "read" ? (u(), d("span", f, m(r.value), 1)) : c("", !0);
112
112
  }
113
113
  });
114
114
  export {
@@ -1,4 +1,4 @@
1
- import { defineComponent as B, useSlots as x, shallowRef as C, computed as b, unref as t, createElementBlock as g, createBlock as k, openBlock as s, Fragment as F, createTextVNode as S, toDisplayString as h, mergeProps as T, createSlots as V, renderList as P, withCtx as R, renderSlot as _, normalizeProps as N, guardReactiveProps as U } from "vue";
1
+ import { defineComponent as B, useSlots as x, shallowRef as C, computed as b, unref as t, createElementBlock as g, createBlock as k, openBlock as n, Fragment as F, createTextVNode as S, toDisplayString as h, mergeProps as T, createSlots as V, renderList as _, withCtx as P, renderSlot as R, normalizeProps as N, guardReactiveProps as U } from "vue";
2
2
  import { Slider as A } from "@aplus-frontend/antdv";
3
3
  import { isNil as H, isArray as L, omit as $ } from "lodash-unified";
4
4
  import "../../hooks/index.mjs";
@@ -52,9 +52,9 @@ const G = /* @__PURE__ */ B({
52
52
  emptyText: { default: "--" }
53
53
  },
54
54
  emits: ["update:value"],
55
- setup(l, { expose: u, emit: i }) {
56
- const d = x(), o = C(), a = l, p = i, { value: r, updateValue: m } = w(a, p), c = b(() => {
57
- const e = t(r);
55
+ setup(s, { expose: u, emit: i }) {
56
+ const p = x(), o = C(), a = s, d = i, { value: l, updateValue: m } = w(a, d), c = b(() => {
57
+ const e = t(l);
58
58
  return H(e) ? a.emptyText : L(e) ? `${e[0]}-${e[1]}` : e;
59
59
  });
60
60
  function f() {
@@ -66,9 +66,9 @@ const G = /* @__PURE__ */ B({
66
66
  return u({
67
67
  focus: f,
68
68
  blur: y
69
- }), (e, j) => l.mode === "read" ? (s(), g(F, { key: 0 }, [
69
+ }), (e, j) => e.mode === "read" ? (n(), g(F, { key: 0 }, [
70
70
  S(h(c.value), 1)
71
- ], 64)) : (s(), k(t(A), T(
71
+ ], 64)) : (n(), k(t(A), T(
72
72
  { key: 1 },
73
73
  t($)(a, [
74
74
  "value",
@@ -80,14 +80,14 @@ const G = /* @__PURE__ */ B({
80
80
  {
81
81
  ref_key: "sliderRef",
82
82
  ref: o,
83
- value: t(r),
83
+ value: t(l),
84
84
  "onUpdate:value": t(m)
85
85
  }
86
86
  ), V({ _: 2 }, [
87
- P(d, (q, n) => ({
88
- name: n,
89
- fn: R((v) => [
90
- _(e.$slots, n, N(U(v || {})))
87
+ _(p, (q, r) => ({
88
+ name: r,
89
+ fn: P((v) => [
90
+ R(e.$slots, r, N(U(v || {})))
91
91
  ])
92
92
  }))
93
93
  ]), 1040, ["value", "onUpdate:value"]));
@@ -1,73 +1,90 @@
1
- import { singleRow as l } from "../../style/index.mjs";
2
- const o = (i) => {
3
- const { componentCls: a } = i, p = `${a}-select-popup`;
1
+ import { singleRow as n } from "../../style/index.mjs";
2
+ const a = (o) => {
3
+ const { componentCls: t } = o, i = `${t}-select-popup`;
4
4
  return {
5
- [`${p}`]: {
6
- padding: 0,
7
- [`${p}-all-option-wrapper`]: {
8
- padding: i.space,
9
- paddingBlockEnd: i.spaceXS,
10
- marginBlockEnd: i.calc(i.space).mul(-1).equal()
11
- },
12
- [`${p}-all-option`]: {
5
+ [`${i}`]: {
6
+ padding: o.space,
7
+ [`${i}-all-option`]: {
13
8
  width: "100%",
14
9
  display: "inline-flex",
15
10
  cursor: "pointer",
16
- paddingInline: i.space,
17
- paddingBlock: i.spaceSM,
18
- [`${p}-all-option-label`]: {
19
- paddingInline: i.space
11
+ paddingInline: o.space,
12
+ paddingBlock: o.spaceSM,
13
+ [`${i}-all-option-label`]: {
14
+ paddingInline: o.space
20
15
  }
21
16
  },
22
- [`${p}-option-wrapper`]: {
23
- height: "22px"
17
+ [`${i}-option-outter`]: {
18
+ borderRadius: o.antdv.borderRadiusSM,
19
+ paddingInline: o.space
20
+ },
21
+ [`${i}-option-wrapper`]: {
22
+ height: "30px"
24
23
  },
25
- [`${p}-option-content-wrapper`]: {
24
+ [`${i}-option-content-wrapper`]: {
26
25
  flex: 1,
27
26
  flexShrink: 1,
28
27
  minWidth: 0
29
28
  },
30
- [`${p}-option-label`]: {
31
- ...l(i),
29
+ [`${i}-option-label`]: {
30
+ ...n(o),
32
31
  color: "inherit"
33
32
  },
34
- [`${p}-option-custom`]: {
33
+ [`${i}-option-custom`]: {
35
34
  flex: 1,
36
35
  flexShrink: 1,
37
36
  minWidth: 0
38
37
  },
39
- [`${p}-option-action`]: {
38
+ [`${i}-option-action`]: {
40
39
  display: "none",
41
- color: i.colorPrimary,
42
- paddingInline: i.spaceSM,
43
- paddingBlock: i.spaceXXS,
40
+ color: o.colorPrimary,
41
+ paddingInline: o.spaceSM,
42
+ paddingBlock: o.spaceXXS,
44
43
  "&:hover": {
45
- background: i.colorPrimary,
44
+ background: o.colorPrimary,
46
45
  color: "#fff",
47
46
  borderRadius: "2px"
48
47
  }
49
48
  },
50
49
  "div.ant-select-item": {
51
- paddingInline: i.space,
52
- paddingBlock: i.spaceXS,
50
+ padding: 0,
51
+ paddingBlockEnd: o.spaceXS,
53
52
  fontWeight: "normal !important",
54
- marginBottom: i.spaceXS,
55
- marginInline: i.space,
53
+ "&.ant-select-item-option-active:not(.ant-select-item-option-disabled)": {
54
+ backgroundColor: "unset",
55
+ [`& ${i}-option-outter`]: {
56
+ backgroundColor: o.antdv.controlItemBgHover
57
+ }
58
+ },
59
+ "&.ant-select-item-option-selected:not(.ant-select-item-option-disabled)": {
60
+ backgroundColor: "unset",
61
+ [`& ${i}-option-outter`]: {
62
+ backgroundColor: o.antdv.controlItemBgActive
63
+ }
64
+ },
65
+ "&.ant-select-item-option-disabled.ant-select-item-option-selected": {
66
+ backgroundColor: "unset",
67
+ [`& ${i}-option-outter`]: {
68
+ backgroundColor: o.antdv.colorBgContainerDisabled
69
+ }
70
+ },
56
71
  "&:hover": {
57
- [`${p}-option-action`]: {
72
+ [`${i}-option-action`]: {
58
73
  display: "inline"
59
74
  }
60
75
  },
61
76
  "&:last-child": {
62
- marginBottom: i.space
63
- },
64
- "&:first-child": {
65
- marginTop: i.space
77
+ paddingBlockEnd: 0
78
+ }
79
+ },
80
+ [`&:has(${i}-all-option)`]: {
81
+ "div.ant-select-item:first-child": {
82
+ paddingBlockStart: o.spaceXS
66
83
  }
67
84
  }
68
85
  }
69
86
  };
70
87
  };
71
88
  export {
72
- o as genSelectStyle
89
+ a as genSelectStyle
73
90
  };