@aplus-frontend/ui 7.13.6 → 7.13.8
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.
- package/es/src/ag-grid/components/body-cell/index.vue2.mjs +7 -7
- package/es/src/ag-grid/components/empty/index.vue2.mjs +10 -10
- package/es/src/ag-grid/components/header-cell/index.vue2.mjs +37 -37
- package/es/src/ag-grid/components/row/index.vue2.mjs +5 -5
- package/es/src/ag-grid/components/tooltip/index.vue2.mjs +12 -12
- package/es/src/ag-grid/editable/form-item.vue.mjs +49 -49
- package/es/src/ag-grid/editable/index.vue.mjs +27 -27
- package/es/src/ag-grid/index.vue.mjs +249 -249
- package/es/src/ap-action/group/index.vue.mjs +15 -15
- package/es/src/ap-action/item/index.vue2.mjs +28 -28
- package/es/src/ap-action/item-dropdown/index.vue.mjs +39 -39
- package/es/src/ap-field/checkbox/index.vue.mjs +19 -19
- package/es/src/ap-field/checkbox/read.vue2.mjs +9 -9
- package/es/src/ap-field/date/index.vue.mjs +50 -50
- package/es/src/ap-field/date/read.vue2.mjs +7 -7
- package/es/src/ap-field/date-range/index.vue.mjs +30 -30
- package/es/src/ap-field/date-range/read.vue2.mjs +20 -20
- package/es/src/ap-field/number/index.vue.mjs +24 -24
- package/es/src/ap-field/radio/index.vue.mjs +24 -24
- package/es/src/ap-field/second/index.vue.mjs +15 -15
- package/es/src/ap-field/second/read.vue2.mjs +7 -7
- package/es/src/ap-field/segmented/index.vue.mjs +24 -24
- package/es/src/ap-field/select/index.vue.d.ts +1 -1
- package/es/src/ap-field/select/index.vue.mjs +246 -206
- package/es/src/ap-field/select/read.vue2.mjs +6 -6
- package/es/src/ap-field/slider/index.vue.mjs +11 -11
- package/es/src/ap-field/style/select.mjs +17 -4
- package/es/src/ap-field/switch/index.vue.mjs +45 -45
- package/es/src/ap-field/text/read-password.vue2.mjs +13 -13
- package/es/src/ap-field/text/read.vue2.mjs +3 -3
- package/es/src/ap-field/text-area/index.vue.mjs +29 -29
- package/es/src/ap-field/text-area/read.vue2.mjs +12 -12
- package/es/src/ap-field/tree-select/index.vue.mjs +31 -31
- package/es/src/ap-form/ap-form.vue2.mjs +46 -46
- package/es/src/ap-form/drawer-form/index.vue.mjs +30 -30
- package/es/src/ap-form/item/index.vue.mjs +75 -75
- package/es/src/ap-form/items/checkbox/index.vue.mjs +10 -10
- package/es/src/ap-form/items/number/index.vue.mjs +17 -17
- package/es/src/ap-form/items/radio/index.vue.mjs +13 -13
- package/es/src/ap-form/items/select/index.vue.d.ts +4 -4
- package/es/src/ap-form/items/switch/index.vue.mjs +14 -14
- package/es/src/ap-form/items/text/index.vue2.mjs +26 -26
- package/es/src/ap-form/items/text/password.vue.mjs +19 -19
- package/es/src/ap-form/items/text-area/index.vue.mjs +17 -17
- package/es/src/ap-form/modal-form/index.vue.mjs +34 -34
- package/es/src/ap-form/search-form/components/popover-filter.vue2.mjs +39 -39
- package/es/src/ap-form/search-form/components/popover-sorter/sortable-item.vue2.mjs +7 -7
- package/es/src/ap-grid/editable/form-item.vue.mjs +46 -46
- package/es/src/ap-grid/editable/index.vue.mjs +19 -19
- package/es/src/ap-grid/index.vue.mjs +212 -212
- package/es/src/ap-list/index.vue.mjs +116 -116
- package/es/src/ap-table/ap-table.vue2.mjs +217 -217
- package/es/src/ap-table/components/index/index.vue2.mjs +9 -9
- package/es/src/ap-table/components/setting/modal/index.vue2.mjs +42 -42
- package/es/src/ap-table/components/setting/select-group/index.vue2.mjs +21 -21
- package/es/src/ap-table/components/setting/sortable/index.vue2.mjs +15 -15
- package/es/src/ap-table/components/setting/sortable/item.vue2.mjs +69 -69
- package/es/src/ap-table/components/setting/template/edit-form.vue2.mjs +22 -22
- package/es/src/ap-table/components/setting/template/index.vue2.mjs +25 -25
- package/es/src/ap-table/components/setting/template/item.vue2.mjs +40 -40
- package/es/src/ap-table/components/setting/tree-select/index.vue2.mjs +13 -13
- package/es/src/ap-table/constants.d.ts +2 -2
- package/es/src/business/ag-grid-modal/modal-layout/index.vue2.mjs +54 -54
- package/es/src/business/ag-grid-modal/selected-items/default.vue2.mjs +13 -13
- package/es/src/business/ag-grid-modal/wrapper/index.vue2.mjs +20 -20
- package/es/src/business/ap-descriptions/ap-descriptions.vue.mjs +33 -33
- package/es/src/business/ap-descriptions/help-message/index.vue2.mjs +13 -13
- package/es/src/business/ap-download/ap-download.vue.mjs +24 -24
- package/es/src/business/ap-expand-alert/ApExpandAlert.vue.mjs +77 -77
- package/es/src/business/ap-export-group/ApExportGroup.vue2.mjs +168 -157
- package/es/src/business/ap-radio-group/ap-radio-group.vue2.mjs +33 -33
- package/es/src/business/ap-status/group/ApStatusGroup.vue2.mjs +12 -12
- package/es/src/business/ap-table-modal/table-layout/index.vue2.mjs +43 -43
- package/es/src/business/ap-table-modal/table-modal.vue2.mjs +57 -57
- package/es/src/business/ap-tag/ap-tag-group.vue.mjs +37 -37
- package/es/src/business/ap-tag/ap-tag.vue.mjs +24 -24
- package/es/src/business/ap-title/ApTitle.vue2.mjs +27 -27
- package/es/src/business/ap-value-select-card/index.vue2.mjs +98 -98
- package/es/src/business/ap-view/components/main-button-content.vue.d.ts +1 -1
- package/es/src/business/batch-input-group/form-item.vue.mjs +25 -25
- package/es/src/business/batch-input-group/index.vue.mjs +60 -60
- package/es/src/business/batch-input-group/popover-input/index.vue2.mjs +29 -29
- package/es/src/editable-table/form-item.vue.mjs +35 -35
- package/es/src/editable-table/index.vue.mjs +19 -19
- package/es/src/full-screen/index.vue.mjs +46 -46
- package/es/src/mask/index.vue.mjs +48 -48
- package/es/src/portal/index.vue.mjs +5 -5
- package/es/src/scroll-bar/internal.vue.mjs +62 -62
- package/es/src/scroll-view/index.vue.mjs +66 -66
- package/es/src/skeleton/components/desc/index.vue2.mjs +9 -9
- package/es/src/skeleton/components/desc/item-large.vue2.mjs +25 -25
- package/es/src/skeleton/components/desc/item.vue2.mjs +13 -13
- package/es/src/skeleton/components/list/index.vue2.mjs +14 -14
- package/es/src/skeleton/components/list/item.vue2.mjs +12 -12
- package/es/src/skeleton/components/page-header/index.vue2.mjs +8 -8
- package/es/src/skeleton/components/search-form/index.vue2.mjs +35 -35
- package/es/src/skeleton/components/table/index.vue2.mjs +17 -17
- package/es/src/skeleton/components/table/item.vue2.mjs +23 -23
- package/es/src/skeleton/descriptions.vue2.mjs +15 -15
- package/es/src/skeleton/list-page.vue2.mjs +12 -12
- package/es/src/splitter/Panel.vue2.mjs +11 -11
- package/es/src/splitter/SplitBar.vue2.mjs +79 -79
- package/es/src/splitter/Splitter.vue2.mjs +50 -50
- package/es/src/text/group.vue.mjs +8 -8
- package/es/src/text/index.vue.mjs +48 -48
- package/es/src/version.d.ts +1 -1
- package/es/src/version.mjs +1 -1
- package/lib/src/ag-grid/components/body-cell/index.vue2.js +1 -1
- package/lib/src/ag-grid/components/empty/index.vue2.js +1 -1
- package/lib/src/ag-grid/components/header-cell/index.vue2.js +1 -1
- package/lib/src/ag-grid/components/row/index.vue2.js +1 -1
- package/lib/src/ag-grid/components/tooltip/index.vue2.js +1 -1
- package/lib/src/ag-grid/editable/form-item.vue.js +1 -1
- package/lib/src/ag-grid/editable/index.vue.js +1 -1
- package/lib/src/ag-grid/index.vue.js +1 -1
- package/lib/src/ap-action/group/index.vue.js +1 -1
- package/lib/src/ap-action/item/index.vue2.js +1 -1
- package/lib/src/ap-action/item-dropdown/index.vue.js +1 -1
- package/lib/src/ap-field/checkbox/index.vue.js +1 -1
- package/lib/src/ap-field/checkbox/read.vue2.js +1 -1
- package/lib/src/ap-field/date/index.vue.js +1 -1
- package/lib/src/ap-field/date/read.vue2.js +1 -1
- package/lib/src/ap-field/date-range/index.vue.js +1 -1
- package/lib/src/ap-field/date-range/read.vue2.js +1 -1
- package/lib/src/ap-field/number/index.vue.js +1 -1
- package/lib/src/ap-field/radio/index.vue.js +1 -1
- package/lib/src/ap-field/second/index.vue.js +1 -1
- package/lib/src/ap-field/second/read.vue2.js +1 -1
- package/lib/src/ap-field/segmented/index.vue.js +1 -1
- package/lib/src/ap-field/select/index.vue.d.ts +1 -1
- package/lib/src/ap-field/select/index.vue.js +1 -1
- package/lib/src/ap-field/select/read.vue2.js +1 -1
- package/lib/src/ap-field/slider/index.vue.js +1 -1
- package/lib/src/ap-field/style/select.js +1 -1
- package/lib/src/ap-field/switch/index.vue.js +1 -1
- package/lib/src/ap-field/text/read-password.vue2.js +1 -1
- package/lib/src/ap-field/text/read.vue2.js +1 -1
- package/lib/src/ap-field/text-area/index.vue.js +1 -1
- package/lib/src/ap-field/text-area/read.vue2.js +1 -1
- package/lib/src/ap-field/tree-select/index.vue.js +1 -1
- package/lib/src/ap-form/ap-form.vue2.js +1 -1
- package/lib/src/ap-form/drawer-form/index.vue.js +1 -1
- package/lib/src/ap-form/item/index.vue.js +1 -1
- package/lib/src/ap-form/items/checkbox/index.vue.js +1 -1
- package/lib/src/ap-form/items/number/index.vue.js +1 -1
- package/lib/src/ap-form/items/radio/index.vue.js +1 -1
- package/lib/src/ap-form/items/select/index.vue.d.ts +4 -4
- package/lib/src/ap-form/items/switch/index.vue.js +1 -1
- package/lib/src/ap-form/items/text/index.vue2.js +1 -1
- package/lib/src/ap-form/items/text/password.vue.js +1 -1
- package/lib/src/ap-form/items/text-area/index.vue.js +1 -1
- package/lib/src/ap-form/modal-form/index.vue.js +1 -1
- package/lib/src/ap-form/search-form/components/popover-filter.vue2.js +1 -1
- package/lib/src/ap-form/search-form/components/popover-sorter/sortable-item.vue2.js +1 -1
- package/lib/src/ap-grid/editable/form-item.vue.js +1 -1
- package/lib/src/ap-grid/editable/index.vue.js +1 -1
- package/lib/src/ap-grid/index.vue.js +1 -1
- package/lib/src/ap-list/index.vue.js +1 -1
- package/lib/src/ap-table/ap-table.vue2.js +1 -1
- package/lib/src/ap-table/components/index/index.vue2.js +1 -1
- package/lib/src/ap-table/components/setting/modal/index.vue2.js +1 -1
- package/lib/src/ap-table/components/setting/select-group/index.vue2.js +1 -1
- package/lib/src/ap-table/components/setting/sortable/index.vue2.js +1 -1
- package/lib/src/ap-table/components/setting/sortable/item.vue2.js +1 -1
- package/lib/src/ap-table/components/setting/template/edit-form.vue2.js +1 -1
- package/lib/src/ap-table/components/setting/template/index.vue2.js +1 -1
- package/lib/src/ap-table/components/setting/template/item.vue2.js +1 -1
- package/lib/src/ap-table/components/setting/tree-select/index.vue2.js +1 -1
- package/lib/src/ap-table/constants.d.ts +2 -2
- package/lib/src/business/ag-grid-modal/modal-layout/index.vue2.js +1 -1
- package/lib/src/business/ag-grid-modal/selected-items/default.vue2.js +1 -1
- package/lib/src/business/ag-grid-modal/wrapper/index.vue2.js +1 -1
- package/lib/src/business/ap-descriptions/ap-descriptions.vue.js +1 -1
- package/lib/src/business/ap-descriptions/help-message/index.vue2.js +1 -1
- package/lib/src/business/ap-download/ap-download.vue.js +1 -1
- package/lib/src/business/ap-expand-alert/ApExpandAlert.vue.js +1 -1
- package/lib/src/business/ap-export-group/ApExportGroup.vue2.js +1 -1
- package/lib/src/business/ap-radio-group/ap-radio-group.vue2.js +1 -1
- package/lib/src/business/ap-status/group/ApStatusGroup.vue2.js +1 -1
- package/lib/src/business/ap-table-modal/table-layout/index.vue2.js +1 -1
- package/lib/src/business/ap-table-modal/table-modal.vue2.js +1 -1
- package/lib/src/business/ap-tag/ap-tag-group.vue.js +1 -1
- package/lib/src/business/ap-tag/ap-tag.vue.js +1 -1
- package/lib/src/business/ap-title/ApTitle.vue2.js +1 -1
- package/lib/src/business/ap-value-select-card/index.vue2.js +1 -1
- package/lib/src/business/ap-view/components/main-button-content.vue.d.ts +1 -1
- package/lib/src/business/batch-input-group/form-item.vue.js +1 -1
- package/lib/src/business/batch-input-group/index.vue.js +2 -2
- package/lib/src/business/batch-input-group/popover-input/index.vue2.js +2 -2
- package/lib/src/editable-table/form-item.vue.js +1 -1
- package/lib/src/editable-table/index.vue.js +1 -1
- package/lib/src/full-screen/index.vue.js +1 -1
- package/lib/src/mask/index.vue.js +1 -1
- package/lib/src/portal/index.vue.js +1 -1
- package/lib/src/scroll-bar/internal.vue.js +1 -1
- package/lib/src/scroll-view/index.vue.js +1 -1
- package/lib/src/skeleton/components/desc/index.vue2.js +1 -1
- package/lib/src/skeleton/components/desc/item-large.vue2.js +1 -1
- package/lib/src/skeleton/components/desc/item.vue2.js +1 -1
- package/lib/src/skeleton/components/list/index.vue2.js +1 -1
- package/lib/src/skeleton/components/list/item.vue2.js +1 -1
- package/lib/src/skeleton/components/page-header/index.vue2.js +1 -1
- package/lib/src/skeleton/components/search-form/index.vue2.js +1 -1
- package/lib/src/skeleton/components/table/index.vue2.js +1 -1
- package/lib/src/skeleton/components/table/item.vue2.js +1 -1
- package/lib/src/skeleton/descriptions.vue2.js +1 -1
- package/lib/src/skeleton/list-page.vue2.js +1 -1
- package/lib/src/splitter/Panel.vue2.js +1 -1
- package/lib/src/splitter/SplitBar.vue2.js +1 -1
- package/lib/src/splitter/Splitter.vue2.js +1 -1
- package/lib/src/text/group.vue.js +1 -1
- package/lib/src/text/index.vue.js +1 -1
- package/lib/src/version.d.ts +1 -1
- package/lib/src/version.js +1 -1
- package/package.json +1 -1
|
@@ -1,21 +1,25 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { Select as
|
|
3
|
-
import { debounce as
|
|
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";
|
|
4
4
|
import "../../config-provider/index.mjs";
|
|
5
5
|
import "../../utils/index.mjs";
|
|
6
6
|
import "../../hooks/index.mjs";
|
|
7
|
-
import { useDefaultPlaceholder as
|
|
8
|
-
import
|
|
9
|
-
import { useSelectOptions as
|
|
10
|
-
import { useNamespace as
|
|
11
|
-
import { useLocale as
|
|
12
|
-
import { useControllableValue as
|
|
13
|
-
import { isDef as
|
|
14
|
-
const
|
|
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";
|
|
13
|
+
import { isDef as z } from "../../utils/is.mjs";
|
|
14
|
+
const Ie = {
|
|
15
|
+
key: 0
|
|
16
|
+
}, _e = ["onClick"], He = /* @__PURE__ */ ue({
|
|
15
17
|
name: "ApFieldSelect",
|
|
16
18
|
__name: "index",
|
|
17
19
|
props: {
|
|
18
|
-
mode: {
|
|
20
|
+
mode: {
|
|
21
|
+
default: "edit"
|
|
22
|
+
},
|
|
19
23
|
class: {},
|
|
20
24
|
style: {},
|
|
21
25
|
defaultValue: {},
|
|
@@ -23,8 +27,14 @@ const Ne = { key: 0 }, Ae = ["onClick"], Ke = /* @__PURE__ */ te({
|
|
|
23
27
|
suffixIcon: {},
|
|
24
28
|
itemIcon: {},
|
|
25
29
|
size: {},
|
|
26
|
-
bordered: {
|
|
27
|
-
|
|
30
|
+
bordered: {
|
|
31
|
+
type: Boolean,
|
|
32
|
+
default: void 0
|
|
33
|
+
},
|
|
34
|
+
showArrow: {
|
|
35
|
+
type: Boolean,
|
|
36
|
+
default: void 0
|
|
37
|
+
},
|
|
28
38
|
variant: {},
|
|
29
39
|
maxCount: {},
|
|
30
40
|
transitionName: {},
|
|
@@ -46,25 +56,46 @@ const Ne = { key: 0 }, Ae = ["onClick"], Ke = /* @__PURE__ */ te({
|
|
|
46
56
|
onKeyup: {},
|
|
47
57
|
onMousedown: {},
|
|
48
58
|
onSelect: {},
|
|
49
|
-
open: {
|
|
59
|
+
open: {
|
|
60
|
+
type: Boolean,
|
|
61
|
+
default: void 0
|
|
62
|
+
},
|
|
50
63
|
animation: {},
|
|
51
64
|
direction: {},
|
|
52
|
-
disabled: {
|
|
65
|
+
disabled: {
|
|
66
|
+
type: Boolean,
|
|
67
|
+
default: void 0
|
|
68
|
+
},
|
|
53
69
|
prefixCls: {},
|
|
54
70
|
id: {},
|
|
55
|
-
autofocus: {
|
|
71
|
+
autofocus: {
|
|
72
|
+
type: Boolean,
|
|
73
|
+
default: void 0
|
|
74
|
+
},
|
|
56
75
|
getPopupContainer: {},
|
|
57
|
-
virtual: {
|
|
76
|
+
virtual: {
|
|
77
|
+
type: Boolean,
|
|
78
|
+
default: void 0
|
|
79
|
+
},
|
|
58
80
|
dropdownMatchSelectWidth: {},
|
|
59
81
|
placeholder: {},
|
|
60
|
-
loading: {
|
|
82
|
+
loading: {
|
|
83
|
+
type: Boolean,
|
|
84
|
+
default: void 0
|
|
85
|
+
},
|
|
61
86
|
prefix: {},
|
|
62
87
|
clearIcon: {},
|
|
63
|
-
allowClear: {
|
|
88
|
+
allowClear: {
|
|
89
|
+
type: Boolean,
|
|
90
|
+
default: !0
|
|
91
|
+
},
|
|
64
92
|
fieldNames: {},
|
|
65
93
|
inputValue: {},
|
|
66
94
|
searchValue: {},
|
|
67
|
-
autoClearSearchValue: {
|
|
95
|
+
autoClearSearchValue: {
|
|
96
|
+
type: Boolean,
|
|
97
|
+
default: void 0
|
|
98
|
+
},
|
|
68
99
|
onDeselect: {},
|
|
69
100
|
onActive: {},
|
|
70
101
|
filterOption: {},
|
|
@@ -72,16 +103,28 @@ const Ne = { key: 0 }, Ae = ["onClick"], Ke = /* @__PURE__ */ te({
|
|
|
72
103
|
optionFilterProp: {},
|
|
73
104
|
optionLabelProp: {},
|
|
74
105
|
options: {},
|
|
75
|
-
defaultActiveFirstOption: {
|
|
106
|
+
defaultActiveFirstOption: {
|
|
107
|
+
type: Boolean,
|
|
108
|
+
default: void 0
|
|
109
|
+
},
|
|
76
110
|
listItemHeight: {},
|
|
77
111
|
onClickOption: {},
|
|
78
112
|
menuItemSelectedIcon: {},
|
|
79
|
-
labelInValue: {
|
|
80
|
-
|
|
113
|
+
labelInValue: {
|
|
114
|
+
type: Boolean,
|
|
115
|
+
default: void 0
|
|
116
|
+
},
|
|
117
|
+
showSearch: {
|
|
118
|
+
type: Boolean,
|
|
119
|
+
default: void 0
|
|
120
|
+
},
|
|
81
121
|
tagRender: {},
|
|
82
122
|
optionLabelRender: {},
|
|
83
123
|
onClear: {},
|
|
84
|
-
defaultOpen: {
|
|
124
|
+
defaultOpen: {
|
|
125
|
+
type: Boolean,
|
|
126
|
+
default: void 0
|
|
127
|
+
},
|
|
85
128
|
onDropdownVisibleChange: {},
|
|
86
129
|
maxTagTextLength: {},
|
|
87
130
|
maxTagCount: {},
|
|
@@ -94,227 +137,224 @@ const Ne = { key: 0 }, Ae = ["onClick"], Ke = /* @__PURE__ */ te({
|
|
|
94
137
|
showAction: {},
|
|
95
138
|
onPopupScroll: {},
|
|
96
139
|
onInputKeyDown: {},
|
|
97
|
-
emptyText: {
|
|
140
|
+
emptyText: {
|
|
141
|
+
default: "--"
|
|
142
|
+
},
|
|
98
143
|
request: {},
|
|
99
|
-
multiple: {
|
|
144
|
+
multiple: {
|
|
145
|
+
type: Boolean,
|
|
146
|
+
default: void 0
|
|
147
|
+
},
|
|
100
148
|
value: {},
|
|
101
149
|
"onUpdate:value": {},
|
|
102
|
-
searchMode: {
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
150
|
+
searchMode: {
|
|
151
|
+
default: "filter"
|
|
152
|
+
},
|
|
153
|
+
refetchOnFocus: {
|
|
154
|
+
type: Boolean,
|
|
155
|
+
default: !1
|
|
156
|
+
},
|
|
157
|
+
lazy: {
|
|
158
|
+
type: Boolean,
|
|
159
|
+
default: !1
|
|
160
|
+
},
|
|
161
|
+
addAll: {
|
|
162
|
+
type: [Boolean, Number],
|
|
163
|
+
default: 5
|
|
164
|
+
},
|
|
106
165
|
params: {},
|
|
107
|
-
searchDelay: {
|
|
108
|
-
|
|
166
|
+
searchDelay: {
|
|
167
|
+
default: 300
|
|
168
|
+
},
|
|
169
|
+
allowOnlySelect: {
|
|
170
|
+
type: Boolean,
|
|
171
|
+
default: !0
|
|
172
|
+
}
|
|
109
173
|
},
|
|
110
174
|
emits: ["update:value"],
|
|
111
|
-
setup(
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
175
|
+
setup(N, {
|
|
176
|
+
expose: U,
|
|
177
|
+
emit: $
|
|
178
|
+
}) {
|
|
179
|
+
let r = 0;
|
|
180
|
+
const O = se(), e = N, {
|
|
181
|
+
b: a
|
|
182
|
+
} = Fe("field-select"), K = Ne("field"), F = _(!1), {
|
|
183
|
+
t: A
|
|
184
|
+
} = Ae(), j = Se((t) => {
|
|
185
|
+
if (!L(e.request))
|
|
115
186
|
return;
|
|
116
|
-
|
|
117
|
-
const
|
|
118
|
-
v([]),
|
|
119
|
-
|
|
187
|
+
r += 1;
|
|
188
|
+
const l = r;
|
|
189
|
+
v([]), u.value = !0, e.request(t).then((n) => {
|
|
190
|
+
r === l && (v(n), u.value = !1);
|
|
120
191
|
});
|
|
121
|
-
}, e.searchDelay),
|
|
122
|
-
const
|
|
123
|
-
return typeof
|
|
124
|
-
}, {
|
|
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;
|
|
195
|
+
}, {
|
|
196
|
+
options: h,
|
|
197
|
+
updateOptions: v
|
|
198
|
+
} = Oe(e), S = re(), u = _(e?.loading || !1), H = $, W = s(() => {
|
|
125
199
|
if (e.multiple)
|
|
126
200
|
return e.tokenSeparators ? "tags" : "multiple";
|
|
127
201
|
});
|
|
128
|
-
async function
|
|
129
|
-
if (!
|
|
202
|
+
async function y(t = !0) {
|
|
203
|
+
if (!L(e.request))
|
|
130
204
|
return;
|
|
131
|
-
|
|
132
|
-
const
|
|
205
|
+
u.value = !0, r += 1;
|
|
206
|
+
const l = r;
|
|
133
207
|
try {
|
|
134
|
-
|
|
135
|
-
const
|
|
136
|
-
if (
|
|
208
|
+
t && v([]);
|
|
209
|
+
const n = await e.request(void 0, e.params);
|
|
210
|
+
if (l !== r)
|
|
137
211
|
return;
|
|
138
|
-
v(
|
|
212
|
+
v(n);
|
|
139
213
|
} finally {
|
|
140
|
-
|
|
214
|
+
u.value = !1;
|
|
141
215
|
}
|
|
142
216
|
}
|
|
143
|
-
function
|
|
144
|
-
e.onFocus?.(
|
|
217
|
+
function G(t) {
|
|
218
|
+
e.onFocus?.(t), e.refetchOnFocus && r > 0 && !u.value && y(!0);
|
|
145
219
|
}
|
|
146
|
-
|
|
147
|
-
e.lazy ||
|
|
148
|
-
}),
|
|
149
|
-
()
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
)
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
if (!o)
|
|
220
|
+
ie(() => {
|
|
221
|
+
e.lazy || y();
|
|
222
|
+
}), de(() => e.params, () => {
|
|
223
|
+
y();
|
|
224
|
+
}, {
|
|
225
|
+
deep: !0
|
|
226
|
+
});
|
|
227
|
+
const {
|
|
228
|
+
value: i,
|
|
229
|
+
updateValue: g
|
|
230
|
+
} = Ve(e, H), J = ke("Select", e), Q = s(() => {
|
|
231
|
+
const t = o(i);
|
|
232
|
+
if (!t)
|
|
160
233
|
return e.emptyText;
|
|
161
|
-
const
|
|
162
|
-
return
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
}), G = r(() => {
|
|
168
|
-
const o = !!e?.showSearch, a = e.searchMode;
|
|
169
|
-
let t = {};
|
|
170
|
-
return o && (t = a === "request" ? {
|
|
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" ? {
|
|
171
240
|
defaultActiveFirstOption: !1,
|
|
172
|
-
onSearch:
|
|
173
|
-
notFoundContent:
|
|
241
|
+
onSearch: j,
|
|
242
|
+
notFoundContent: u.value ? void 0 : null,
|
|
174
243
|
filterOption: !1,
|
|
175
244
|
suffixIcon: null
|
|
176
245
|
} : {
|
|
177
|
-
filterOption:
|
|
246
|
+
filterOption: xe(e?.filterOption) ? E : e?.filterOption
|
|
178
247
|
}), {
|
|
179
|
-
...
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
"onUpdate:value",
|
|
183
|
-
"onSearch",
|
|
184
|
-
"request",
|
|
185
|
-
"searchMode",
|
|
186
|
-
"onFocus",
|
|
187
|
-
"onBeforeSelect"
|
|
188
|
-
]),
|
|
189
|
-
placeholder: l(H),
|
|
190
|
-
...t
|
|
248
|
+
...R(e, ["mode", "value", "onUpdate:value", "onSearch", "request", "searchMode", "onFocus", "onBeforeSelect"]),
|
|
249
|
+
placeholder: o(J),
|
|
250
|
+
...n
|
|
191
251
|
};
|
|
192
|
-
}),
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
() => e.multiple && e.allowOnlySelect && (!T(e.maxCount) || e.maxCount >= 1)
|
|
196
|
-
);
|
|
197
|
-
function Q() {
|
|
198
|
-
b.value?.focus();
|
|
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();
|
|
199
255
|
}
|
|
200
|
-
function
|
|
201
|
-
|
|
256
|
+
function ee() {
|
|
257
|
+
S.value?.blur();
|
|
202
258
|
}
|
|
203
|
-
function
|
|
204
|
-
const
|
|
205
|
-
return
|
|
259
|
+
function b(t, l) {
|
|
260
|
+
const n = e.fieldNames?.[l] ?? l;
|
|
261
|
+
return t[n];
|
|
206
262
|
}
|
|
207
|
-
function
|
|
208
|
-
const
|
|
209
|
-
|
|
263
|
+
function te(t) {
|
|
264
|
+
const l = b(t, "value");
|
|
265
|
+
g(e.multiple ? [l] : l);
|
|
210
266
|
}
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
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")]);
|
|
273
|
+
}
|
|
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() {
|
|
216
279
|
console.log("123");
|
|
217
|
-
const
|
|
218
|
-
|
|
280
|
+
const t = o(i) || [], l = w.value;
|
|
281
|
+
l.length && l.every((n) => t?.includes(n)) ? g([]) : g(w.value);
|
|
219
282
|
}
|
|
220
|
-
return
|
|
221
|
-
focus:
|
|
222
|
-
blur:
|
|
223
|
-
request:
|
|
224
|
-
}), (
|
|
283
|
+
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({
|
|
225
288
|
key: 1,
|
|
226
289
|
ref_key: "selectRef",
|
|
227
|
-
ref:
|
|
290
|
+
ref: S,
|
|
228
291
|
"allow-clear": ""
|
|
229
|
-
},
|
|
230
|
-
mode:
|
|
231
|
-
value:
|
|
232
|
-
options:
|
|
233
|
-
loading:
|
|
234
|
-
"menu-item-selected-icon":
|
|
235
|
-
"popup-class-name": `${
|
|
236
|
-
open:
|
|
292
|
+
}, X.value, {
|
|
293
|
+
mode: W.value,
|
|
294
|
+
value: o(i),
|
|
295
|
+
options: o(h),
|
|
296
|
+
loading: u.value,
|
|
297
|
+
"menu-item-selected-icon": pe("span"),
|
|
298
|
+
"popup-class-name": `${o(a)("popup")} ${o(K)}`,
|
|
299
|
+
open: F.value,
|
|
237
300
|
virtual: !1,
|
|
238
|
-
"onUpdate:value":
|
|
239
|
-
onFocus:
|
|
240
|
-
onDropdownVisibleChange:
|
|
241
|
-
}),
|
|
242
|
-
option:
|
|
243
|
-
|
|
244
|
-
|
|
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), {
|
|
306
|
+
justify: "space-between",
|
|
307
|
+
align: "center",
|
|
308
|
+
class: f(o(a)("popup-option-wrapper")),
|
|
309
|
+
gap: 8
|
|
310
|
+
}, {
|
|
311
|
+
default: p(() => [d(o(T), {
|
|
312
|
+
gap: 8,
|
|
245
313
|
align: "center",
|
|
246
|
-
class:
|
|
247
|
-
gap: 8
|
|
314
|
+
class: f(o(a)("popup-option-content-wrapper"))
|
|
248
315
|
}, {
|
|
249
|
-
default:
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
}, {
|
|
254
|
-
default: c(() => [
|
|
255
|
-
N.value ? (f(), x(l(P), {
|
|
256
|
-
key: 0,
|
|
257
|
-
checked: l(i)?.includes(
|
|
258
|
-
B(t, "value")
|
|
259
|
-
)
|
|
260
|
-
}, null, 8, ["checked"])) : _("", !0),
|
|
261
|
-
S("span", {
|
|
262
|
-
class: p(l(u)("popup-option-label"))
|
|
263
|
-
}, C(B(t, "label")), 3)
|
|
264
|
-
]),
|
|
265
|
-
_: 2
|
|
266
|
-
}, 1024),
|
|
267
|
-
J.value ? (f(), I("span", {
|
|
268
|
-
key: 0,
|
|
269
|
-
class: p(l(u)("popup-option-action")),
|
|
270
|
-
onClick: ie(() => Y(t), ["stop"])
|
|
271
|
-
}, C(l(F)("ap.field.chooseOnly")), 11, Ae)) : _("", !0)
|
|
272
|
-
]),
|
|
316
|
+
default: p(() => [V.value ? (c(), C(o(q), {
|
|
317
|
+
key: 0,
|
|
318
|
+
checked: o(i)?.includes(b(n, "value"))
|
|
319
|
+
}, null, 8, ["checked"])) : P("", !0), (c(), C(D(oe(n))))]),
|
|
273
320
|
_: 2
|
|
274
|
-
}, 1032, ["class"])
|
|
275
|
-
|
|
321
|
+
}, 1032, ["class"]), Y.value ? (c(), M("span", {
|
|
322
|
+
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)]),
|
|
326
|
+
_: 2
|
|
327
|
+
}, 1032, ["class"])]),
|
|
276
328
|
_: 2
|
|
277
|
-
}, [
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
}
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
indeterminate: Z.value
|
|
305
|
-
}, null, 8, ["checked", "indeterminate"]),
|
|
306
|
-
S("span", {
|
|
307
|
-
class: p(l(u)("popup-all-option-label"))
|
|
308
|
-
}, C(l(F)("ap.field.selectAll")), 3)
|
|
309
|
-
], 2)
|
|
310
|
-
], 2),
|
|
311
|
-
(f(), x(me(t)))
|
|
312
|
-
]),
|
|
313
|
-
key: "1"
|
|
314
|
-
} : void 0
|
|
315
|
-
]), 1040, ["mode", "value", "options", "loading", "menu-item-selected-icon", "popup-class-name", "open", "onUpdate:value"]));
|
|
329
|
+
}, [he(o(R)(t.$slots, ["option"]), (n, x) => ({
|
|
330
|
+
name: x,
|
|
331
|
+
fn: p((m) => [ve(t.$slots, x, ye(ge(m || {})))])
|
|
332
|
+
})), u.value ? {
|
|
333
|
+
name: "notFoundContent",
|
|
334
|
+
fn: p(() => [d(o(Ce), {
|
|
335
|
+
size: "small"
|
|
336
|
+
})]),
|
|
337
|
+
key: "0"
|
|
338
|
+
} : void 0, V.value ? {
|
|
339
|
+
name: "dropdownRender",
|
|
340
|
+
fn: p(({
|
|
341
|
+
menuNode: n
|
|
342
|
+
}) => [k("div", {
|
|
343
|
+
class: f(o(a)("popup-all-option-wrapper"))
|
|
344
|
+
}, [k("div", {
|
|
345
|
+
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)))]),
|
|
354
|
+
key: "1"
|
|
355
|
+
} : void 0]), 1040, ["mode", "value", "options", "loading", "menu-item-selected-icon", "popup-class-name", "open", "onUpdate:value"]));
|
|
316
356
|
}
|
|
317
357
|
});
|
|
318
358
|
export {
|
|
319
|
-
|
|
359
|
+
He as default
|
|
320
360
|
};
|
|
@@ -96,19 +96,19 @@ const f = { key: 0 }, C = /* @__PURE__ */ i({
|
|
|
96
96
|
searchDelay: {},
|
|
97
97
|
allowOnlySelect: { type: Boolean }
|
|
98
98
|
},
|
|
99
|
-
setup(
|
|
100
|
-
const e =
|
|
99
|
+
setup(a) {
|
|
100
|
+
const e = a, r = s(() => {
|
|
101
101
|
const o = e.value;
|
|
102
102
|
if (!o)
|
|
103
103
|
return e.emptyText;
|
|
104
|
-
const t = e.fieldNames?.label || "label",
|
|
104
|
+
const t = e.fieldNames?.label || "label", l = e.fieldNames?.value || "value";
|
|
105
105
|
return y(o) ? o.map(
|
|
106
|
-
(n) => e.options?.find((p) => p[
|
|
106
|
+
(n) => e.options?.find((p) => p[l] === n)?.[t]
|
|
107
107
|
).filter(Boolean).join("、") || e.emptyText : e.options?.find(
|
|
108
|
-
(n) => n[
|
|
108
|
+
(n) => n[l] === o
|
|
109
109
|
)?.[t] || e.emptyText;
|
|
110
110
|
});
|
|
111
|
-
return (o, t) =>
|
|
111
|
+
return (o, t) => a.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
|
|
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";
|
|
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(
|
|
56
|
-
const
|
|
57
|
-
const e = t(
|
|
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);
|
|
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) =>
|
|
69
|
+
}), (e, j) => l.mode === "read" ? (s(), g(F, { key: 0 }, [
|
|
70
70
|
S(h(c.value), 1)
|
|
71
|
-
], 64)) : (
|
|
71
|
+
], 64)) : (s(), 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(
|
|
83
|
+
value: t(r),
|
|
84
84
|
"onUpdate:value": t(m)
|
|
85
85
|
}
|
|
86
86
|
), V({ _: 2 }, [
|
|
87
|
-
|
|
88
|
-
name:
|
|
89
|
-
fn:
|
|
90
|
-
|
|
87
|
+
P(d, (q, n) => ({
|
|
88
|
+
name: n,
|
|
89
|
+
fn: R((v) => [
|
|
90
|
+
_(e.$slots, n, N(U(v || {})))
|
|
91
91
|
])
|
|
92
92
|
}))
|
|
93
93
|
]), 1040, ["value", "onUpdate:value"]));
|