vue-devui 1.0.0-rc.12 → 1.0.0-rc.15
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/README.md +161 -149
- package/alert/index.umd.js +1 -1
- package/auto-complete/index.es.js +243 -83
- package/auto-complete/index.umd.js +29 -18
- package/auto-complete/style.css +1 -1
- package/avatar/index.umd.js +1 -1
- package/badge/index.umd.js +1 -1
- package/button/index.es.js +23 -43
- package/button/index.umd.js +9 -9
- package/button/style.css +1 -1
- package/card/index.umd.js +1 -1
- package/checkbox/index.es.js +94 -77
- package/checkbox/index.umd.js +26 -15
- package/checkbox/style.css +1 -1
- package/collapse/index.es.js +3 -21
- package/collapse/index.umd.js +1 -1
- package/countdown/index.umd.js +1 -1
- package/date-picker-pro/index.es.js +1423 -248
- package/date-picker-pro/index.umd.js +25 -14
- package/date-picker-pro/style.css +1 -1
- package/drawer/index.es.js +4 -17
- package/drawer/index.umd.js +1 -1
- package/dropdown/index.es.js +12 -23
- package/dropdown/index.umd.js +1 -1
- package/editable-select/index.es.js +260 -105
- package/editable-select/index.umd.js +1 -1
- package/editable-select/style.css +1 -1
- package/form/index.es.js +85 -71
- package/form/index.umd.js +21 -10
- package/fullscreen/index.umd.js +1 -1
- package/grid/index.es.js +7 -20
- package/grid/index.umd.js +1 -1
- package/icon/index.es.js +2 -1
- package/icon/index.umd.js +1 -1
- package/icon/style.css +1 -1
- package/image-preview/index.es.js +12 -23
- package/image-preview/index.umd.js +1 -1
- package/image-preview/style.css +1 -1
- package/input/index.es.js +241 -76
- package/input/index.umd.js +27 -16
- package/input/style.css +1 -1
- package/input-number/index.es.js +2 -20
- package/input-number/index.umd.js +1 -1
- package/layout/index.es.js +1 -1
- package/layout/index.umd.js +1 -1
- package/loading/index.es.js +15 -38
- package/loading/index.umd.js +1 -1
- package/message/index.d.ts +7 -0
- package/message/index.es.js +534 -0
- package/message/index.umd.js +1 -0
- package/message/package.json +7 -0
- package/message/style.css +1 -0
- package/modal/index.es.js +13 -44
- package/modal/index.umd.js +1 -1
- package/modal/style.css +1 -1
- package/notification/index.es.js +45 -54
- package/notification/index.umd.js +1 -1
- package/notification/style.css +1 -1
- package/nuxt/components/Message.js +3 -0
- package/nuxt/components/animationInjectionKey.js +3 -0
- package/nuxt/components/messageProps.js +3 -0
- package/nuxt/components/roundInjectionKey.js +3 -0
- package/nuxt/components/skeletonItemProps.js +3 -0
- package/overlay/index.es.js +1 -1
- package/overlay/index.umd.js +1 -1
- package/package.json +2 -2
- package/pagination/index.es.js +152 -2
- package/pagination/index.umd.js +1 -1
- package/panel/index.umd.js +1 -1
- package/popover/index.es.js +1 -1
- package/popover/index.umd.js +4 -4
- package/progress/index.umd.js +3 -3
- package/radio/index.es.js +91 -75
- package/radio/index.umd.js +28 -17
- package/radio/style.css +1 -1
- package/rate/index.umd.js +1 -1
- package/result/index.es.js +2 -1
- package/result/index.umd.js +1 -1
- package/result/style.css +1 -1
- package/ripple/index.es.js +5 -18
- package/ripple/index.umd.js +1 -1
- package/search/index.es.js +258 -80
- package/search/index.umd.js +27 -16
- package/search/style.css +1 -1
- package/select/index.es.js +352 -146
- package/select/index.umd.js +28 -17
- package/select/style.css +1 -1
- package/skeleton/index.es.js +87 -261
- package/skeleton/index.umd.js +1 -1
- package/skeleton/style.css +1 -1
- package/slider/index.umd.js +1 -1
- package/splitter/index.es.js +175 -32
- package/splitter/index.umd.js +13 -13
- package/statistic/index.es.js +0 -21
- package/statistic/index.umd.js +1 -1
- package/status/index.umd.js +1 -1
- package/steps/index.es.js +2 -1
- package/steps/index.umd.js +1 -1
- package/steps/style.css +1 -1
- package/style.css +1 -1
- package/switch/index.es.js +85 -71
- package/switch/index.umd.js +25 -14
- package/table/index.es.js +465 -130
- package/table/index.umd.js +24 -13
- package/table/style.css +1 -1
- package/tabs/index.es.js +21 -11
- package/tabs/index.umd.js +1 -1
- package/tabs/style.css +1 -1
- package/tag/index.umd.js +1 -1
- package/textarea/index.es.js +88 -72
- package/textarea/index.umd.js +26 -15
- package/time-picker/index.es.js +289 -116
- package/time-picker/index.umd.js +27 -16
- package/time-picker/style.css +1 -1
- package/time-select/index.es.js +352 -146
- package/time-select/index.umd.js +26 -15
- package/time-select/style.css +1 -1
- package/timeline/index.es.js +2 -1
- package/timeline/index.umd.js +1 -1
- package/timeline/style.css +1 -1
- package/tooltip/index.es.js +1 -1
- package/tooltip/index.umd.js +4 -4
- package/tree/index.es.js +515 -144
- package/tree/index.umd.js +26 -15
- package/tree/style.css +1 -1
- package/upload/index.es.js +197 -81
- package/upload/index.umd.js +1 -1
- package/upload/style.css +1 -1
- package/vue-devui.es.js +13710 -12898
- package/vue-devui.umd.js +30 -19
package/select/index.es.js
CHANGED
|
@@ -1,35 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
var __defProps = Object.defineProperties;
|
|
3
|
-
var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
|
|
4
|
-
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
5
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
-
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
7
|
-
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
8
|
-
var __spreadValues = (a, b) => {
|
|
9
|
-
for (var prop in b || (b = {}))
|
|
10
|
-
if (__hasOwnProp.call(b, prop))
|
|
11
|
-
__defNormalProp(a, prop, b[prop]);
|
|
12
|
-
if (__getOwnPropSymbols)
|
|
13
|
-
for (var prop of __getOwnPropSymbols(b)) {
|
|
14
|
-
if (__propIsEnum.call(b, prop))
|
|
15
|
-
__defNormalProp(a, prop, b[prop]);
|
|
16
|
-
}
|
|
17
|
-
return a;
|
|
18
|
-
};
|
|
19
|
-
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
|
-
var __objRest = (source, exclude) => {
|
|
21
|
-
var target = {};
|
|
22
|
-
for (var prop in source)
|
|
23
|
-
if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
24
|
-
target[prop] = source[prop];
|
|
25
|
-
if (source != null && __getOwnPropSymbols)
|
|
26
|
-
for (var prop of __getOwnPropSymbols(source)) {
|
|
27
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
|
|
28
|
-
target[prop] = source[prop];
|
|
29
|
-
}
|
|
30
|
-
return target;
|
|
31
|
-
};
|
|
32
|
-
import { defineComponent, watch, provide, reactive, toRefs, createVNode, onUnmounted, Transition, mergeProps, ref, unref, nextTick, Comment, Text, h, Fragment, inject, withDirectives, cloneVNode, computed, onMounted, Teleport, createTextVNode, onBeforeUnmount, toRef, onBeforeMount, vShow, resolveComponent, getCurrentInstance } from "vue";
|
|
1
|
+
import { defineComponent, watch, provide, reactive, toRefs, createVNode, onUnmounted, Transition, mergeProps, ref, nextTick, unref, Comment, Text, Fragment, h, inject, withDirectives, cloneVNode, computed, onMounted, Teleport, createTextVNode, onBeforeUnmount, toRef, onBeforeMount, vShow, resolveComponent, getCurrentInstance } from "vue";
|
|
33
2
|
import { onClickOutside } from "@vueuse/core";
|
|
34
3
|
import { offset, autoPlacement, arrow, shift, computePosition } from "@floating-ui/dom";
|
|
35
4
|
function className(classStr, classOpt) {
|
|
@@ -775,7 +744,7 @@ var lodash = { exports: {} };
|
|
|
775
744
|
var objectCtorString = funcToString.call(Object2);
|
|
776
745
|
var oldDash = root._;
|
|
777
746
|
var reIsNative = RegExp2("^" + funcToString.call(hasOwnProperty).replace(reRegExpChar, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$");
|
|
778
|
-
var
|
|
747
|
+
var Buffer = moduleExports ? context.Buffer : undefined$1, Symbol2 = context.Symbol, Uint8Array = context.Uint8Array, allocUnsafe = Buffer ? Buffer.allocUnsafe : undefined$1, getPrototype = overArg(Object2.getPrototypeOf, Object2), objectCreate = Object2.create, propertyIsEnumerable = objectProto.propertyIsEnumerable, splice = arrayProto.splice, spreadableSymbol = Symbol2 ? Symbol2.isConcatSpreadable : undefined$1, symIterator = Symbol2 ? Symbol2.iterator : undefined$1, symToStringTag = Symbol2 ? Symbol2.toStringTag : undefined$1;
|
|
779
748
|
var defineProperty = function() {
|
|
780
749
|
try {
|
|
781
750
|
var func = getNative(Object2, "defineProperty");
|
|
@@ -785,11 +754,11 @@ var lodash = { exports: {} };
|
|
|
785
754
|
}
|
|
786
755
|
}();
|
|
787
756
|
var ctxClearTimeout = context.clearTimeout !== root.clearTimeout && context.clearTimeout, ctxNow = Date2 && Date2.now !== root.Date.now && Date2.now, ctxSetTimeout = context.setTimeout !== root.setTimeout && context.setTimeout;
|
|
788
|
-
var nativeCeil = Math2.ceil, nativeFloor = Math2.floor, nativeGetSymbols = Object2.getOwnPropertySymbols, nativeIsBuffer =
|
|
789
|
-
var DataView = getNative(context, "DataView"), Map2 = getNative(context, "Map"), Promise2 = getNative(context, "Promise"),
|
|
790
|
-
var metaMap =
|
|
757
|
+
var nativeCeil = Math2.ceil, nativeFloor = Math2.floor, nativeGetSymbols = Object2.getOwnPropertySymbols, nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined$1, nativeIsFinite = context.isFinite, nativeJoin = arrayProto.join, nativeKeys = overArg(Object2.keys, Object2), nativeMax = Math2.max, nativeMin = Math2.min, nativeNow = Date2.now, nativeParseInt = context.parseInt, nativeRandom = Math2.random, nativeReverse = arrayProto.reverse;
|
|
758
|
+
var DataView = getNative(context, "DataView"), Map2 = getNative(context, "Map"), Promise2 = getNative(context, "Promise"), Set2 = getNative(context, "Set"), WeakMap = getNative(context, "WeakMap"), nativeCreate = getNative(Object2, "create");
|
|
759
|
+
var metaMap = WeakMap && new WeakMap();
|
|
791
760
|
var realNames = {};
|
|
792
|
-
var dataViewCtorString = toSource(DataView), mapCtorString = toSource(Map2), promiseCtorString = toSource(Promise2), setCtorString = toSource(
|
|
761
|
+
var dataViewCtorString = toSource(DataView), mapCtorString = toSource(Map2), promiseCtorString = toSource(Promise2), setCtorString = toSource(Set2), weakMapCtorString = toSource(WeakMap);
|
|
793
762
|
var symbolProto = Symbol2 ? Symbol2.prototype : undefined$1, symbolValueOf = symbolProto ? symbolProto.valueOf : undefined$1, symbolToString = symbolProto ? symbolProto.toString : undefined$1;
|
|
794
763
|
function lodash2(value) {
|
|
795
764
|
if (isObjectLike(value) && !isArray(value) && !(value instanceof LazyWrapper)) {
|
|
@@ -1244,7 +1213,7 @@ var lodash = { exports: {} };
|
|
|
1244
1213
|
if (typeof func != "function") {
|
|
1245
1214
|
throw new TypeError2(FUNC_ERROR_TEXT);
|
|
1246
1215
|
}
|
|
1247
|
-
return
|
|
1216
|
+
return setTimeout2(function() {
|
|
1248
1217
|
func.apply(undefined$1, args);
|
|
1249
1218
|
}, wait);
|
|
1250
1219
|
}
|
|
@@ -2037,7 +2006,7 @@ var lodash = { exports: {} };
|
|
|
2037
2006
|
}
|
|
2038
2007
|
function cloneArrayBuffer(arrayBuffer) {
|
|
2039
2008
|
var result2 = new arrayBuffer.constructor(arrayBuffer.byteLength);
|
|
2040
|
-
new
|
|
2009
|
+
new Uint8Array(result2).set(new Uint8Array(arrayBuffer));
|
|
2041
2010
|
return result2;
|
|
2042
2011
|
}
|
|
2043
2012
|
function cloneDataView(dataView, isDeep) {
|
|
@@ -2481,8 +2450,8 @@ var lodash = { exports: {} };
|
|
|
2481
2450
|
return func(number4);
|
|
2482
2451
|
};
|
|
2483
2452
|
}
|
|
2484
|
-
var createSet = !(
|
|
2485
|
-
return new
|
|
2453
|
+
var createSet = !(Set2 && 1 / setToArray(new Set2([, -0]))[1] == INFINITY) ? noop : function(values2) {
|
|
2454
|
+
return new Set2(values2);
|
|
2486
2455
|
};
|
|
2487
2456
|
function createToPairs(keysFunc) {
|
|
2488
2457
|
return function(object4) {
|
|
@@ -2619,7 +2588,7 @@ var lodash = { exports: {} };
|
|
|
2619
2588
|
object4 = object4.buffer;
|
|
2620
2589
|
other = other.buffer;
|
|
2621
2590
|
case arrayBufferTag:
|
|
2622
|
-
if (object4.byteLength != other.byteLength || !equalFunc(new
|
|
2591
|
+
if (object4.byteLength != other.byteLength || !equalFunc(new Uint8Array(object4), new Uint8Array(other))) {
|
|
2623
2592
|
return false;
|
|
2624
2593
|
}
|
|
2625
2594
|
return true;
|
|
@@ -2781,7 +2750,7 @@ var lodash = { exports: {} };
|
|
|
2781
2750
|
return result2;
|
|
2782
2751
|
};
|
|
2783
2752
|
var getTag = baseGetTag;
|
|
2784
|
-
if (DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag || Map2 && getTag(new Map2()) != mapTag || Promise2 && getTag(Promise2.resolve()) != promiseTag ||
|
|
2753
|
+
if (DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag || Map2 && getTag(new Map2()) != mapTag || Promise2 && getTag(Promise2.resolve()) != promiseTag || Set2 && getTag(new Set2()) != setTag || WeakMap && getTag(new WeakMap()) != weakMapTag) {
|
|
2785
2754
|
getTag = function(value) {
|
|
2786
2755
|
var result2 = baseGetTag(value), Ctor = result2 == objectTag ? value.constructor : undefined$1, ctorString = Ctor ? toSource(Ctor) : "";
|
|
2787
2756
|
if (ctorString) {
|
|
@@ -3053,7 +3022,7 @@ var lodash = { exports: {} };
|
|
|
3053
3022
|
return object4[key];
|
|
3054
3023
|
}
|
|
3055
3024
|
var setData = shortOut(baseSetData);
|
|
3056
|
-
var
|
|
3025
|
+
var setTimeout2 = ctxSetTimeout || function(func, wait) {
|
|
3057
3026
|
return root.setTimeout(func, wait);
|
|
3058
3027
|
};
|
|
3059
3028
|
var setToString = shortOut(baseSetToString);
|
|
@@ -3845,7 +3814,7 @@ var lodash = { exports: {} };
|
|
|
3845
3814
|
}
|
|
3846
3815
|
function leadingEdge(time) {
|
|
3847
3816
|
lastInvokeTime = time;
|
|
3848
|
-
timerId =
|
|
3817
|
+
timerId = setTimeout2(timerExpired, wait);
|
|
3849
3818
|
return leading ? invokeFunc(time) : result2;
|
|
3850
3819
|
}
|
|
3851
3820
|
function remainingWait(time) {
|
|
@@ -3861,7 +3830,7 @@ var lodash = { exports: {} };
|
|
|
3861
3830
|
if (shouldInvoke(time)) {
|
|
3862
3831
|
return trailingEdge(time);
|
|
3863
3832
|
}
|
|
3864
|
-
timerId =
|
|
3833
|
+
timerId = setTimeout2(timerExpired, remainingWait(time));
|
|
3865
3834
|
}
|
|
3866
3835
|
function trailingEdge(time) {
|
|
3867
3836
|
timerId = undefined$1;
|
|
@@ -3892,12 +3861,12 @@ var lodash = { exports: {} };
|
|
|
3892
3861
|
}
|
|
3893
3862
|
if (maxing) {
|
|
3894
3863
|
clearTimeout(timerId);
|
|
3895
|
-
timerId =
|
|
3864
|
+
timerId = setTimeout2(timerExpired, wait);
|
|
3896
3865
|
return invokeFunc(lastCallTime);
|
|
3897
3866
|
}
|
|
3898
3867
|
}
|
|
3899
3868
|
if (timerId === undefined$1) {
|
|
3900
|
-
timerId =
|
|
3869
|
+
timerId = setTimeout2(timerExpired, wait);
|
|
3901
3870
|
}
|
|
3902
3871
|
return result2;
|
|
3903
3872
|
}
|
|
@@ -5553,7 +5522,10 @@ function useFormValidation(itemContexts) {
|
|
|
5553
5522
|
try {
|
|
5554
5523
|
await field.validate("");
|
|
5555
5524
|
} catch (err) {
|
|
5556
|
-
errors =
|
|
5525
|
+
errors = {
|
|
5526
|
+
...errors,
|
|
5527
|
+
...err
|
|
5528
|
+
};
|
|
5557
5529
|
}
|
|
5558
5530
|
}
|
|
5559
5531
|
if (!Object.keys(errors).length) {
|
|
@@ -5610,11 +5582,12 @@ defineComponent({
|
|
|
5610
5582
|
}, {
|
|
5611
5583
|
deep: true
|
|
5612
5584
|
});
|
|
5613
|
-
provide(FORM_TOKEN, reactive(
|
|
5585
|
+
provide(FORM_TOKEN, reactive({
|
|
5586
|
+
...toRefs(props),
|
|
5614
5587
|
emit: ctx.emit,
|
|
5615
5588
|
addItemContext,
|
|
5616
5589
|
removeItemContext
|
|
5617
|
-
}))
|
|
5590
|
+
}));
|
|
5618
5591
|
ctx.expose({
|
|
5619
5592
|
validate,
|
|
5620
5593
|
validateFields,
|
|
@@ -6491,7 +6464,7 @@ var FormControl = defineComponent({
|
|
|
6491
6464
|
}
|
|
6492
6465
|
});
|
|
6493
6466
|
function _extends() {
|
|
6494
|
-
_extends = Object.assign
|
|
6467
|
+
_extends = Object.assign ? Object.assign.bind() : function(target) {
|
|
6495
6468
|
for (var i = 1; i < arguments.length; i++) {
|
|
6496
6469
|
var source = arguments[i];
|
|
6497
6470
|
for (var key in source) {
|
|
@@ -6510,13 +6483,13 @@ function _inheritsLoose(subClass, superClass) {
|
|
|
6510
6483
|
_setPrototypeOf(subClass, superClass);
|
|
6511
6484
|
}
|
|
6512
6485
|
function _getPrototypeOf(o) {
|
|
6513
|
-
_getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf2(o2) {
|
|
6486
|
+
_getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf2(o2) {
|
|
6514
6487
|
return o2.__proto__ || Object.getPrototypeOf(o2);
|
|
6515
6488
|
};
|
|
6516
6489
|
return _getPrototypeOf(o);
|
|
6517
6490
|
}
|
|
6518
6491
|
function _setPrototypeOf(o, p) {
|
|
6519
|
-
_setPrototypeOf = Object.setPrototypeOf
|
|
6492
|
+
_setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf2(o2, p2) {
|
|
6520
6493
|
o2.__proto__ = p2;
|
|
6521
6494
|
return o2;
|
|
6522
6495
|
};
|
|
@@ -6539,7 +6512,7 @@ function _isNativeReflectConstruct() {
|
|
|
6539
6512
|
}
|
|
6540
6513
|
function _construct(Parent, args, Class) {
|
|
6541
6514
|
if (_isNativeReflectConstruct()) {
|
|
6542
|
-
_construct = Reflect.construct;
|
|
6515
|
+
_construct = Reflect.construct.bind();
|
|
6543
6516
|
} else {
|
|
6544
6517
|
_construct = function _construct2(Parent2, args2, Class2) {
|
|
6545
6518
|
var a = [null];
|
|
@@ -6817,9 +6790,45 @@ var whitespace = function whitespace2(rule, value, source, errors, options) {
|
|
|
6817
6790
|
errors.push(format(options.messages.whitespace, rule.fullField));
|
|
6818
6791
|
}
|
|
6819
6792
|
};
|
|
6793
|
+
var urlReg;
|
|
6794
|
+
var getUrlRegex = function() {
|
|
6795
|
+
if (urlReg) {
|
|
6796
|
+
return urlReg;
|
|
6797
|
+
}
|
|
6798
|
+
var word = "[a-fA-F\\d:]";
|
|
6799
|
+
var b = function b2(options) {
|
|
6800
|
+
return options && options.includeBoundaries ? "(?:(?<=\\s|^)(?=" + word + ")|(?<=" + word + ")(?=\\s|$))" : "";
|
|
6801
|
+
};
|
|
6802
|
+
var v4 = "(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)(?:\\.(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)){3}";
|
|
6803
|
+
var v6seg = "[a-fA-F\\d]{1,4}";
|
|
6804
|
+
var v6 = ("\n(?:\n(?:" + v6seg + ":){7}(?:" + v6seg + "|:)| // 1:2:3:4:5:6:7:: 1:2:3:4:5:6:7:8\n(?:" + v6seg + ":){6}(?:" + v4 + "|:" + v6seg + "|:)| // 1:2:3:4:5:6:: 1:2:3:4:5:6::8 1:2:3:4:5:6::8 1:2:3:4:5:6::1.2.3.4\n(?:" + v6seg + ":){5}(?::" + v4 + "|(?::" + v6seg + "){1,2}|:)| // 1:2:3:4:5:: 1:2:3:4:5::7:8 1:2:3:4:5::8 1:2:3:4:5::7:1.2.3.4\n(?:" + v6seg + ":){4}(?:(?::" + v6seg + "){0,1}:" + v4 + "|(?::" + v6seg + "){1,3}|:)| // 1:2:3:4:: 1:2:3:4::6:7:8 1:2:3:4::8 1:2:3:4::6:7:1.2.3.4\n(?:" + v6seg + ":){3}(?:(?::" + v6seg + "){0,2}:" + v4 + "|(?::" + v6seg + "){1,4}|:)| // 1:2:3:: 1:2:3::5:6:7:8 1:2:3::8 1:2:3::5:6:7:1.2.3.4\n(?:" + v6seg + ":){2}(?:(?::" + v6seg + "){0,3}:" + v4 + "|(?::" + v6seg + "){1,5}|:)| // 1:2:: 1:2::4:5:6:7:8 1:2::8 1:2::4:5:6:7:1.2.3.4\n(?:" + v6seg + ":){1}(?:(?::" + v6seg + "){0,4}:" + v4 + "|(?::" + v6seg + "){1,6}|:)| // 1:: 1::3:4:5:6:7:8 1::8 1::3:4:5:6:7:1.2.3.4\n(?::(?:(?::" + v6seg + "){0,5}:" + v4 + "|(?::" + v6seg + "){1,7}|:)) // ::2:3:4:5:6:7:8 ::2:3:4:5:6:7:8 ::8 ::1.2.3.4\n)(?:%[0-9a-zA-Z]{1,})? // %eth0 %1\n").replace(/\s*\/\/.*$/gm, "").replace(/\n/g, "").trim();
|
|
6805
|
+
var v46Exact = new RegExp("(?:^" + v4 + "$)|(?:^" + v6 + "$)");
|
|
6806
|
+
var v4exact = new RegExp("^" + v4 + "$");
|
|
6807
|
+
var v6exact = new RegExp("^" + v6 + "$");
|
|
6808
|
+
var ip = function ip2(options) {
|
|
6809
|
+
return options && options.exact ? v46Exact : new RegExp("(?:" + b(options) + v4 + b(options) + ")|(?:" + b(options) + v6 + b(options) + ")", "g");
|
|
6810
|
+
};
|
|
6811
|
+
ip.v4 = function(options) {
|
|
6812
|
+
return options && options.exact ? v4exact : new RegExp("" + b(options) + v4 + b(options), "g");
|
|
6813
|
+
};
|
|
6814
|
+
ip.v6 = function(options) {
|
|
6815
|
+
return options && options.exact ? v6exact : new RegExp("" + b(options) + v6 + b(options), "g");
|
|
6816
|
+
};
|
|
6817
|
+
var protocol = "(?:(?:[a-z]+:)?//)";
|
|
6818
|
+
var auth = "(?:\\S+(?::\\S*)?@)?";
|
|
6819
|
+
var ipv4 = ip.v4().source;
|
|
6820
|
+
var ipv6 = ip.v6().source;
|
|
6821
|
+
var host = "(?:(?:[a-z\\u00a1-\\uffff0-9][-_]*)*[a-z\\u00a1-\\uffff0-9]+)";
|
|
6822
|
+
var domain = "(?:\\.(?:[a-z\\u00a1-\\uffff0-9]-*)*[a-z\\u00a1-\\uffff0-9]+)*";
|
|
6823
|
+
var tld = "(?:\\.(?:[a-z\\u00a1-\\uffff]{2,}))";
|
|
6824
|
+
var port = "(?::\\d{2,5})?";
|
|
6825
|
+
var path = '(?:[/?#][^\\s"]*)?';
|
|
6826
|
+
var regex = "(?:" + protocol + "|www\\.)" + auth + "(?:localhost|" + ipv4 + "|" + ipv6 + "|" + host + domain + tld + ")" + port + path;
|
|
6827
|
+
urlReg = new RegExp("(?:^" + regex + "$)", "i");
|
|
6828
|
+
return urlReg;
|
|
6829
|
+
};
|
|
6820
6830
|
var pattern$2 = {
|
|
6821
6831
|
email: /^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+\.)+[a-zA-Z\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]{2,}))$/,
|
|
6822
|
-
url: new RegExp("^(?!mailto:)(?:(?:http|https|ftp)://|//)(?:\\S+(?::\\S*)?@)?(?:(?:(?:[1-9]\\d?|1\\d\\d|2[01]\\d|22[0-3])(?:\\.(?:1?\\d{1,2}|2[0-4]\\d|25[0-5])){2}(?:\\.(?:[0-9]\\d?|1\\d\\d|2[0-4]\\d|25[0-4]))|(?:(?:[a-z\\u00a1-\\uffff0-9]+-*)*[a-z\\u00a1-\\uffff0-9]+)(?:\\.(?:[a-z\\u00a1-\\uffff0-9]+-*)*[a-z\\u00a1-\\uffff0-9]+)*(?:\\.(?:[a-z\\u00a1-\\uffff]{2,})))|localhost)(?::\\d{2,5})?(?:(/|\\?|#)[^\\s]*)?$", "i"),
|
|
6823
6832
|
hex: /^#?([a-f0-9]{6}|[a-f0-9]{3})$/i
|
|
6824
6833
|
};
|
|
6825
6834
|
var types = {
|
|
@@ -6861,7 +6870,7 @@ var types = {
|
|
|
6861
6870
|
return typeof value === "string" && value.length <= 320 && !!value.match(pattern$2.email);
|
|
6862
6871
|
},
|
|
6863
6872
|
url: function url(value) {
|
|
6864
|
-
return typeof value === "string" && value.length <= 2048 && !!value.match(
|
|
6873
|
+
return typeof value === "string" && value.length <= 2048 && !!value.match(getUrlRegex());
|
|
6865
6874
|
},
|
|
6866
6875
|
hex: function hex(value) {
|
|
6867
6876
|
return typeof value === "string" && !!value.match(pattern$2.hex);
|
|
@@ -7436,7 +7445,17 @@ var Schema = /* @__PURE__ */ function() {
|
|
|
7436
7445
|
if (rule.asyncValidator) {
|
|
7437
7446
|
res = rule.asyncValidator(rule, data.value, cb, data.source, options);
|
|
7438
7447
|
} else if (rule.validator) {
|
|
7439
|
-
|
|
7448
|
+
try {
|
|
7449
|
+
res = rule.validator(rule, data.value, cb, data.source, options);
|
|
7450
|
+
} catch (error) {
|
|
7451
|
+
console.error == null ? void 0 : console.error(error);
|
|
7452
|
+
if (!options.suppressValidatorError) {
|
|
7453
|
+
setTimeout(function() {
|
|
7454
|
+
throw error;
|
|
7455
|
+
}, 0);
|
|
7456
|
+
}
|
|
7457
|
+
cb(error.message);
|
|
7458
|
+
}
|
|
7440
7459
|
if (res === true) {
|
|
7441
7460
|
cb();
|
|
7442
7461
|
} else if (res === false) {
|
|
@@ -7557,10 +7576,7 @@ function useFormItemValidate(props, _rules) {
|
|
|
7557
7576
|
} else {
|
|
7558
7577
|
return rule.trigger === triggerVal;
|
|
7559
7578
|
}
|
|
7560
|
-
}).map((
|
|
7561
|
-
var _b = _a, { trigger } = _b, rule = __objRest(_b, ["trigger"]);
|
|
7562
|
-
return rule;
|
|
7563
|
-
});
|
|
7579
|
+
}).map(({ ...rule }) => rule);
|
|
7564
7580
|
};
|
|
7565
7581
|
const onValidateSuccess = () => {
|
|
7566
7582
|
validateState.value = "success";
|
|
@@ -7633,15 +7649,12 @@ defineComponent({
|
|
|
7633
7649
|
props: formItemProps,
|
|
7634
7650
|
setup(props, ctx) {
|
|
7635
7651
|
const formContext = inject(FORM_TOKEN);
|
|
7636
|
-
const
|
|
7652
|
+
const {
|
|
7637
7653
|
messageType: itemMessageType,
|
|
7638
7654
|
popPosition: itemPopPosition,
|
|
7639
|
-
showFeedback: itemShowFeedback
|
|
7640
|
-
|
|
7641
|
-
|
|
7642
|
-
"popPosition",
|
|
7643
|
-
"showFeedback"
|
|
7644
|
-
]);
|
|
7655
|
+
showFeedback: itemShowFeedback,
|
|
7656
|
+
...otherProps
|
|
7657
|
+
} = toRefs(props);
|
|
7645
7658
|
const {
|
|
7646
7659
|
label,
|
|
7647
7660
|
helpTips,
|
|
@@ -7671,7 +7684,8 @@ defineComponent({
|
|
|
7671
7684
|
labelAlign: formContext.labelAlign
|
|
7672
7685
|
}));
|
|
7673
7686
|
provide(LABEL_DATA, labelData);
|
|
7674
|
-
const context = reactive(
|
|
7687
|
+
const context = reactive({
|
|
7688
|
+
...otherProps,
|
|
7675
7689
|
showFeedback,
|
|
7676
7690
|
messageType,
|
|
7677
7691
|
popPosition,
|
|
@@ -7681,7 +7695,7 @@ defineComponent({
|
|
|
7681
7695
|
validate,
|
|
7682
7696
|
resetField,
|
|
7683
7697
|
clearValidate
|
|
7684
|
-
})
|
|
7698
|
+
});
|
|
7685
7699
|
provide(FORM_ITEM_TOKEN, context);
|
|
7686
7700
|
ctx.expose({
|
|
7687
7701
|
resetField,
|
|
@@ -7706,8 +7720,8 @@ defineComponent({
|
|
|
7706
7720
|
"extra-info": extraInfo.value
|
|
7707
7721
|
}, {
|
|
7708
7722
|
default: () => {
|
|
7709
|
-
var
|
|
7710
|
-
return [(_b = (
|
|
7723
|
+
var _a, _b;
|
|
7724
|
+
return [(_b = (_a = ctx.slots).default) == null ? void 0 : _b.call(_a)];
|
|
7711
7725
|
}
|
|
7712
7726
|
})]);
|
|
7713
7727
|
}
|
|
@@ -7743,6 +7757,14 @@ function useSelect(props, ctx, focus, blur, isSelectFocus, t) {
|
|
|
7743
7757
|
const selectDisabled = computed(() => (formContext == null ? void 0 : formContext.disabled) || props.disabled);
|
|
7744
7758
|
const selectSize = computed(() => (formContext == null ? void 0 : formContext.size) || props.size);
|
|
7745
7759
|
const isObjectOption = ref(false);
|
|
7760
|
+
const originRef = ref();
|
|
7761
|
+
const dropdownWidth = computed(() => {
|
|
7762
|
+
var _a;
|
|
7763
|
+
if (!((_a = originRef == null ? void 0 : originRef.value) == null ? void 0 : _a.clientWidth)) {
|
|
7764
|
+
return "100%";
|
|
7765
|
+
}
|
|
7766
|
+
return originRef.value.clientWidth + "px";
|
|
7767
|
+
});
|
|
7746
7768
|
const isOpen = ref(false);
|
|
7747
7769
|
const toggleChange = (bool) => {
|
|
7748
7770
|
if (selectDisabled.value) {
|
|
@@ -7772,10 +7794,11 @@ function useSelect(props, ctx, focus, blur, isSelectFocus, t) {
|
|
|
7772
7794
|
return props.options.map((item) => {
|
|
7773
7795
|
let option;
|
|
7774
7796
|
if (typeof item === "object") {
|
|
7775
|
-
option =
|
|
7797
|
+
option = {
|
|
7776
7798
|
name: item.name ? item.name : item.value + "",
|
|
7777
|
-
_checked: false
|
|
7778
|
-
|
|
7799
|
+
_checked: false,
|
|
7800
|
+
...item
|
|
7801
|
+
};
|
|
7779
7802
|
} else {
|
|
7780
7803
|
option = {
|
|
7781
7804
|
name: item + "",
|
|
@@ -7824,18 +7847,14 @@ function useSelect(props, ctx, focus, blur, isSelectFocus, t) {
|
|
|
7824
7847
|
}
|
|
7825
7848
|
});
|
|
7826
7849
|
};
|
|
7827
|
-
const selectedOptions = ref([]);
|
|
7828
7850
|
const filterQuery = ref("");
|
|
7829
|
-
const
|
|
7830
|
-
var _a;
|
|
7851
|
+
const selectedOptions = computed(() => {
|
|
7831
7852
|
if (props.multiple && Array.isArray(props.modelValue)) {
|
|
7832
|
-
|
|
7833
|
-
return selectedOptions.value.map((item) => (item == null ? void 0 : item.name) || (item == null ? void 0 : item.value) || "").join(",");
|
|
7853
|
+
return getInjectOptions(props.modelValue).filter((item) => item ? true : false);
|
|
7834
7854
|
} else if (!Array.isArray(props.modelValue)) {
|
|
7835
|
-
|
|
7836
|
-
return ((_a = selectedOptions.value[0]) == null ? void 0 : _a.name) || "";
|
|
7855
|
+
return getInjectOptions([props.modelValue]).filter((item) => item ? true : false);
|
|
7837
7856
|
}
|
|
7838
|
-
return
|
|
7857
|
+
return [];
|
|
7839
7858
|
});
|
|
7840
7859
|
const onClick = function(e) {
|
|
7841
7860
|
e.preventDefault();
|
|
@@ -7892,8 +7911,8 @@ function useSelect(props, ctx, focus, blur, isSelectFocus, t) {
|
|
|
7892
7911
|
getMultipleSelected(checkedItems);
|
|
7893
7912
|
} else {
|
|
7894
7913
|
ctx.emit("update:modelValue", item.value);
|
|
7895
|
-
toggleChange(false);
|
|
7896
7914
|
getSingleSelected(item);
|
|
7915
|
+
toggleChange(false);
|
|
7897
7916
|
}
|
|
7898
7917
|
};
|
|
7899
7918
|
const handleClose = () => {
|
|
@@ -7916,9 +7935,11 @@ function useSelect(props, ctx, focus, blur, isSelectFocus, t) {
|
|
|
7916
7935
|
};
|
|
7917
7936
|
const tagDelete = (data) => {
|
|
7918
7937
|
let { modelValue } = props;
|
|
7919
|
-
data._checked = !data._checked;
|
|
7920
7938
|
const checkedItems = [];
|
|
7921
7939
|
for (const child of injectOptions.value.values()) {
|
|
7940
|
+
if (data.value === child.value) {
|
|
7941
|
+
child._checked = false;
|
|
7942
|
+
}
|
|
7922
7943
|
if (child._checked) {
|
|
7923
7944
|
checkedItems.push(child.value);
|
|
7924
7945
|
}
|
|
@@ -7996,16 +8017,17 @@ function useSelect(props, ctx, focus, blur, isSelectFocus, t) {
|
|
|
7996
8017
|
selectDisabled,
|
|
7997
8018
|
selectSize,
|
|
7998
8019
|
containerRef,
|
|
8020
|
+
originRef,
|
|
7999
8021
|
dropdownRef,
|
|
8000
8022
|
isOpen,
|
|
8001
8023
|
selectCls,
|
|
8002
8024
|
mergeOptions,
|
|
8003
|
-
inputValue,
|
|
8004
8025
|
selectedOptions,
|
|
8005
8026
|
filterQuery,
|
|
8006
8027
|
emptyText,
|
|
8007
8028
|
isLoading,
|
|
8008
8029
|
isShowEmptyText,
|
|
8030
|
+
dropdownWidth,
|
|
8009
8031
|
onClick,
|
|
8010
8032
|
handleClear,
|
|
8011
8033
|
valueChange,
|
|
@@ -8128,12 +8150,6 @@ const optionProps = {
|
|
|
8128
8150
|
default: false
|
|
8129
8151
|
}
|
|
8130
8152
|
};
|
|
8131
|
-
const selectContentProps = {
|
|
8132
|
-
value: {
|
|
8133
|
-
type: String,
|
|
8134
|
-
default: ""
|
|
8135
|
-
}
|
|
8136
|
-
};
|
|
8137
8153
|
const optionGroupProps = {
|
|
8138
8154
|
label: {
|
|
8139
8155
|
type: String
|
|
@@ -8182,7 +8198,8 @@ const commonProps = {
|
|
|
8182
8198
|
default: "md"
|
|
8183
8199
|
}
|
|
8184
8200
|
};
|
|
8185
|
-
const checkboxProps =
|
|
8201
|
+
const checkboxProps = {
|
|
8202
|
+
...commonProps,
|
|
8186
8203
|
checked: {
|
|
8187
8204
|
type: Boolean,
|
|
8188
8205
|
default: false
|
|
@@ -8212,8 +8229,9 @@ const checkboxProps = __spreadProps(__spreadValues({}, commonProps), {
|
|
|
8212
8229
|
type: Boolean,
|
|
8213
8230
|
default: false
|
|
8214
8231
|
}
|
|
8215
|
-
}
|
|
8216
|
-
const checkboxGroupProps =
|
|
8232
|
+
};
|
|
8233
|
+
const checkboxGroupProps = {
|
|
8234
|
+
...commonProps,
|
|
8217
8235
|
modelValue: {
|
|
8218
8236
|
type: Array,
|
|
8219
8237
|
required: true
|
|
@@ -8250,7 +8268,7 @@ const checkboxGroupProps = __spreadProps(__spreadValues({}, commonProps), {
|
|
|
8250
8268
|
type: String,
|
|
8251
8269
|
default: ""
|
|
8252
8270
|
}
|
|
8253
|
-
}
|
|
8271
|
+
};
|
|
8254
8272
|
const checkboxGroupInjectionKey = Symbol("d-checkbox-group");
|
|
8255
8273
|
function useCheckbox(props, ctx) {
|
|
8256
8274
|
const formContext = inject(FORM_TOKEN, void 0);
|
|
@@ -8526,9 +8544,10 @@ defineComponent({
|
|
|
8526
8544
|
value: opt
|
|
8527
8545
|
});
|
|
8528
8546
|
} else if (typeof opt === "object") {
|
|
8529
|
-
mergedOpt = Object.assign({}, defaultOpt,
|
|
8547
|
+
mergedOpt = Object.assign({}, defaultOpt, {
|
|
8548
|
+
...opt,
|
|
8530
8549
|
label: opt.name
|
|
8531
|
-
})
|
|
8550
|
+
});
|
|
8532
8551
|
}
|
|
8533
8552
|
return createVNode(Checkbox, mergedOpt, null);
|
|
8534
8553
|
});
|
|
@@ -8835,6 +8854,155 @@ var Tag = defineComponent({
|
|
|
8835
8854
|
};
|
|
8836
8855
|
}
|
|
8837
8856
|
});
|
|
8857
|
+
function deepAssign(...objects) {
|
|
8858
|
+
const isObject2 = (obj) => obj && typeof obj === "object";
|
|
8859
|
+
return objects.reduce((prev, from) => {
|
|
8860
|
+
Object.keys(from).forEach((key) => {
|
|
8861
|
+
const pVal = prev[key];
|
|
8862
|
+
const oVal = from[key];
|
|
8863
|
+
if (Array.isArray(pVal) && Array.isArray(oVal)) {
|
|
8864
|
+
prev[key] = Array.from(/* @__PURE__ */ new Set([...oVal, ...pVal]));
|
|
8865
|
+
} else if (isObject2(pVal) && isObject2(oVal)) {
|
|
8866
|
+
prev[key] = deepAssign(pVal, oVal);
|
|
8867
|
+
} else {
|
|
8868
|
+
prev[key] = oVal;
|
|
8869
|
+
}
|
|
8870
|
+
});
|
|
8871
|
+
return prev;
|
|
8872
|
+
}, {});
|
|
8873
|
+
}
|
|
8874
|
+
var zhCN = {
|
|
8875
|
+
pagination: {
|
|
8876
|
+
totalItemText: "\u6240\u6709\u6761\u76EE",
|
|
8877
|
+
goToText: "\u8DF3\u81F3"
|
|
8878
|
+
},
|
|
8879
|
+
accordion: {
|
|
8880
|
+
loading: "\u52A0\u8F7D\u4E2D",
|
|
8881
|
+
noData: "\u6CA1\u6709\u6570\u636E"
|
|
8882
|
+
},
|
|
8883
|
+
autoCompleteDropdown: {
|
|
8884
|
+
latestInput: "\u6700\u8FD1\u8F93\u5165"
|
|
8885
|
+
},
|
|
8886
|
+
cascaderList: {
|
|
8887
|
+
noData: "\u6CA1\u6709\u6570\u636E"
|
|
8888
|
+
},
|
|
8889
|
+
colorPicker: {
|
|
8890
|
+
foundationPanel: "\u57FA\u7840\u9762\u677F",
|
|
8891
|
+
advancedPanel: "\u9AD8\u7EA7\u9762\u677F"
|
|
8892
|
+
},
|
|
8893
|
+
datePickerPro: {
|
|
8894
|
+
ok: "\u786E\u5B9A",
|
|
8895
|
+
placeholder: "\u8BF7\u9009\u62E9\u65E5\u671F",
|
|
8896
|
+
month1: "1\u6708",
|
|
8897
|
+
month2: "2\u6708",
|
|
8898
|
+
month3: "3\u6708",
|
|
8899
|
+
month4: "4\u6708",
|
|
8900
|
+
month5: "5\u6708",
|
|
8901
|
+
month6: "6\u6708",
|
|
8902
|
+
month7: "7\u6708",
|
|
8903
|
+
month8: "8\u6708",
|
|
8904
|
+
month9: "9\u6708",
|
|
8905
|
+
month10: "10\u6708",
|
|
8906
|
+
month11: "11\u6708",
|
|
8907
|
+
month12: "12\u6708",
|
|
8908
|
+
year: "\u5E74",
|
|
8909
|
+
startPlaceholder: "\u8BF7\u9009\u62E9\u5F00\u59CB\u65E5\u671F",
|
|
8910
|
+
endPlaceholder: "\u8BF7\u9009\u62E9\u7ED3\u675F\u65E5\u671F",
|
|
8911
|
+
getWeekDays() {
|
|
8912
|
+
return ["\u65E5", "\u4E00", "\u4E8C", "\u4E09", "\u56DB", "\u4E94", "\u516D"];
|
|
8913
|
+
},
|
|
8914
|
+
getTimeArr() {
|
|
8915
|
+
return ["\u65F6", "\u5206", "\u79D2"];
|
|
8916
|
+
},
|
|
8917
|
+
getYearMonthStr(year, month) {
|
|
8918
|
+
return `${year}\u5E74${month}\u6708`;
|
|
8919
|
+
}
|
|
8920
|
+
},
|
|
8921
|
+
editableSelect: {
|
|
8922
|
+
noRelatedRecords: "\u627E\u4E0D\u5230\u76F8\u5173\u8BB0\u5F55",
|
|
8923
|
+
noData: "\u6CA1\u6709\u6570\u636E"
|
|
8924
|
+
},
|
|
8925
|
+
input: {
|
|
8926
|
+
placeholder: "\u8BF7\u8F93\u5165"
|
|
8927
|
+
},
|
|
8928
|
+
splitterBar: {
|
|
8929
|
+
collapse: "\u6536\u8D77",
|
|
8930
|
+
expand: "\u5C55\u5F00"
|
|
8931
|
+
},
|
|
8932
|
+
stepsGuide: {
|
|
8933
|
+
previous: "\u4E0A\u4E00\u6B65",
|
|
8934
|
+
continue: "\u6211\u77E5\u9053\u5566\uFF0C\u7EE7\u7EED",
|
|
8935
|
+
ok: "\u6211\u77E5\u9053\u5566"
|
|
8936
|
+
},
|
|
8937
|
+
table: {
|
|
8938
|
+
selectAll: "\u5168\u9009",
|
|
8939
|
+
ok: "\u786E\u5B9A"
|
|
8940
|
+
},
|
|
8941
|
+
timePopup: {
|
|
8942
|
+
ok: "\u786E\u5B9A"
|
|
8943
|
+
},
|
|
8944
|
+
transfer: {
|
|
8945
|
+
unit: "\u9879",
|
|
8946
|
+
panelUnit: "\u9879",
|
|
8947
|
+
headerUnit: "\u9879",
|
|
8948
|
+
noData: "\u6682\u65E0\u6570\u636E",
|
|
8949
|
+
placeholder: "\u8BF7\u8F93\u5165\u5173\u952E\u8BCD\u641C\u7D22"
|
|
8950
|
+
},
|
|
8951
|
+
tree: {
|
|
8952
|
+
loading: "\u52A0\u8F7D\u4E2D",
|
|
8953
|
+
newNode: "\u65B0\u8282\u70B9",
|
|
8954
|
+
selectPlaceholder: "\u8BF7\u9009\u62E9"
|
|
8955
|
+
},
|
|
8956
|
+
upload: {
|
|
8957
|
+
placeholder: "\u9009\u62E9\u6587\u4EF6",
|
|
8958
|
+
getExistSameNameFilesMsg(sameNames) {
|
|
8959
|
+
return `\u60A8\u4E0A\u4F20\u7684 "${sameNames}" \u5B58\u5728\u91CD\u540D\u6587\u4EF6, \u8BF7\u91CD\u65B0\u9009\u62E9\u6587\u4EF6`;
|
|
8960
|
+
},
|
|
8961
|
+
getAllFilesBeyondMaximalFileSizeMsg(maximalSize) {
|
|
8962
|
+
return `\u6700\u5927\u652F\u6301\u4E0A\u4F20${maximalSize}MB\u7684\u6587\u4EF6, \u60A8\u672C\u6B21\u4E0A\u4F20\u7684\u6240\u6709\u6587\u4EF6\u8D85\u8FC7\u53EF\u4E0A\u4F20\u6587\u4EF6\u5927\u5C0F`;
|
|
8963
|
+
},
|
|
8964
|
+
getBeyondMaximalFileSizeMsg(filename, maximalSize) {
|
|
8965
|
+
return `\u6700\u5927\u652F\u6301\u4E0A\u4F20${maximalSize}MB\u7684\u6587\u4EF6, \u60A8\u4E0A\u4F20\u7684\u6587\u4EF6"${filename}"\u8D85\u8FC7\u53EF\u4E0A\u4F20\u6587\u4EF6\u5927\u5C0F`;
|
|
8966
|
+
},
|
|
8967
|
+
getNotAllowedFileTypeMsg(filename, scope) {
|
|
8968
|
+
return `\u652F\u6301\u7684\u6587\u4EF6\u7C7B\u578B: "${scope}", \u60A8\u4E0A\u4F20\u7684\u6587\u4EF6"${filename}"\u4E0D\u5728\u5141\u8BB8\u8303\u56F4\u5185\uFF0C\u8BF7\u91CD\u65B0\u9009\u62E9\u6587\u4EF6`;
|
|
8969
|
+
}
|
|
8970
|
+
},
|
|
8971
|
+
search: {
|
|
8972
|
+
placeholder: "\u8BF7\u8F93\u5165\u5173\u952E\u5B57"
|
|
8973
|
+
},
|
|
8974
|
+
select: {
|
|
8975
|
+
placeholder: "\u8BF7\u9009\u62E9",
|
|
8976
|
+
noDataText: "\u65E0\u6570\u636E",
|
|
8977
|
+
noMatchText: "\u627E\u4E0D\u5230\u76F8\u5173\u8BB0\u5F55",
|
|
8978
|
+
loadingText: "\u52A0\u8F7D\u4E2D..."
|
|
8979
|
+
},
|
|
8980
|
+
tagInput: {
|
|
8981
|
+
maxTagsText: "\u5DF2\u8FBE\u5230\u6700\u5927\u4E2A\u6570\uFF1A"
|
|
8982
|
+
},
|
|
8983
|
+
timeSelect: {
|
|
8984
|
+
placeholder: "\u8BF7\u9009\u62E9\u65F6\u95F4"
|
|
8985
|
+
}
|
|
8986
|
+
};
|
|
8987
|
+
const lang = ref("zh-CN");
|
|
8988
|
+
let langMessages = reactive({
|
|
8989
|
+
[lang.value]: zhCN
|
|
8990
|
+
});
|
|
8991
|
+
const Locale = {
|
|
8992
|
+
messages() {
|
|
8993
|
+
return langMessages[lang.value];
|
|
8994
|
+
},
|
|
8995
|
+
lang() {
|
|
8996
|
+
return lang.value;
|
|
8997
|
+
},
|
|
8998
|
+
use(newLang, newMessages2) {
|
|
8999
|
+
lang.value = newLang;
|
|
9000
|
+
this.add({ [newLang]: newMessages2 });
|
|
9001
|
+
},
|
|
9002
|
+
add(newMessages2 = {}) {
|
|
9003
|
+
langMessages = deepAssign(langMessages, newMessages2);
|
|
9004
|
+
}
|
|
9005
|
+
};
|
|
8838
9006
|
const camelize = (name) => name.substring(1).replace(/^\S/, (s) => s.toLocaleLowerCase());
|
|
8839
9007
|
function get(object4, path) {
|
|
8840
9008
|
const keys = path.split(".");
|
|
@@ -8848,12 +9016,13 @@ function get(object4, path) {
|
|
|
8848
9016
|
function createI18nTranslate(name, app, newPrefix) {
|
|
8849
9017
|
const prefix = newPrefix || camelize(name) + ".";
|
|
8850
9018
|
return (path) => {
|
|
8851
|
-
|
|
9019
|
+
var _a;
|
|
9020
|
+
const messages2 = ((_a = app == null ? void 0 : app.appContext.config.globalProperties.langMessages) == null ? void 0 : _a.value) || Locale.messages();
|
|
8852
9021
|
const message = get(messages2, prefix + path) || get(messages2, path);
|
|
8853
9022
|
return message;
|
|
8854
9023
|
};
|
|
8855
9024
|
}
|
|
8856
|
-
function useSelectContent(
|
|
9025
|
+
function useSelectContent() {
|
|
8857
9026
|
const ns2 = useNamespace("select");
|
|
8858
9027
|
const select2 = inject(SELECT_TOKEN);
|
|
8859
9028
|
const formItemContext = inject(FORM_ITEM_TOKEN, void 0);
|
|
@@ -8874,8 +9043,16 @@ function useSelectContent(props) {
|
|
|
8874
9043
|
return true;
|
|
8875
9044
|
}
|
|
8876
9045
|
});
|
|
9046
|
+
const displayInputValue = computed(() => {
|
|
9047
|
+
var _a;
|
|
9048
|
+
if (select2 == null ? void 0 : select2.selectedOptions) {
|
|
9049
|
+
return select2.selectedOptions.length > 1 ? select2.selectedOptions.map((item) => (item == null ? void 0 : item.name) || (item == null ? void 0 : item.value) || "").join(",") : ((_a = select2.selectedOptions[0]) == null ? void 0 : _a.name) || "";
|
|
9050
|
+
} else {
|
|
9051
|
+
return "";
|
|
9052
|
+
}
|
|
9053
|
+
});
|
|
8877
9054
|
const mergeClearable = computed(() => {
|
|
8878
|
-
return !isSelectDisable.value && !!(select2 == null ? void 0 : select2.allowClear) &&
|
|
9055
|
+
return !isSelectDisable.value && !!(select2 == null ? void 0 : select2.allowClear) && (displayInputValue.value ? true : false);
|
|
8879
9056
|
});
|
|
8880
9057
|
const isDisabledTooltip = computed(() => {
|
|
8881
9058
|
return !isSupportTagsTooltip.value || !!(select2 == null ? void 0 : select2.isOpen);
|
|
@@ -8893,7 +9070,7 @@ function useSelectContent(props) {
|
|
|
8893
9070
|
});
|
|
8894
9071
|
});
|
|
8895
9072
|
const tagSize = computed(() => (select2 == null ? void 0 : select2.selectSize) || "sm");
|
|
8896
|
-
const placeholder = computed(() =>
|
|
9073
|
+
const placeholder = computed(() => displayInputValue.value ? "" : (select2 == null ? void 0 : select2.placeholder) || t("placeholder"));
|
|
8897
9074
|
const isMultiple = computed(() => !!(select2 == null ? void 0 : select2.multiple));
|
|
8898
9075
|
const handleClear = (e) => {
|
|
8899
9076
|
e.preventDefault();
|
|
@@ -8931,6 +9108,7 @@ function useSelectContent(props) {
|
|
|
8931
9108
|
tagSize,
|
|
8932
9109
|
placeholder,
|
|
8933
9110
|
isMultiple,
|
|
9111
|
+
displayInputValue,
|
|
8934
9112
|
handleClear,
|
|
8935
9113
|
tagDelete,
|
|
8936
9114
|
onFocus,
|
|
@@ -8940,8 +9118,7 @@ function useSelectContent(props) {
|
|
|
8940
9118
|
}
|
|
8941
9119
|
var SelectContent = defineComponent({
|
|
8942
9120
|
name: "SelectContent",
|
|
8943
|
-
|
|
8944
|
-
setup(props) {
|
|
9121
|
+
setup() {
|
|
8945
9122
|
const formItemContext = inject(FORM_ITEM_TOKEN, void 0);
|
|
8946
9123
|
const ns2 = useNamespace("select");
|
|
8947
9124
|
const clearCls = computed(() => ({
|
|
@@ -8966,12 +9143,13 @@ var SelectContent = defineComponent({
|
|
|
8966
9143
|
tagSize,
|
|
8967
9144
|
placeholder,
|
|
8968
9145
|
isMultiple,
|
|
9146
|
+
displayInputValue,
|
|
8969
9147
|
handleClear,
|
|
8970
9148
|
tagDelete,
|
|
8971
9149
|
onFocus,
|
|
8972
9150
|
onBlur,
|
|
8973
9151
|
queryFilter
|
|
8974
|
-
} = useSelectContent(
|
|
9152
|
+
} = useSelectContent();
|
|
8975
9153
|
return () => {
|
|
8976
9154
|
return createVNode("div", {
|
|
8977
9155
|
"class": selectionCls.value
|
|
@@ -9002,7 +9180,9 @@ var SelectContent = defineComponent({
|
|
|
9002
9180
|
"trigger": "hover",
|
|
9003
9181
|
"disabled": isDisabledTooltip.value
|
|
9004
9182
|
}, {
|
|
9005
|
-
default: () => createVNode(Tag,
|
|
9183
|
+
default: () => createVNode(Tag, {
|
|
9184
|
+
"size": tagSize.value
|
|
9185
|
+
}, {
|
|
9006
9186
|
default: () => [`+${selectedData.value.length - 1}`]
|
|
9007
9187
|
}),
|
|
9008
9188
|
content: () => createVNode("div", null, [selectedData.value.map((item) => createVNode(Tag, {
|
|
@@ -9032,7 +9212,7 @@ var SelectContent = defineComponent({
|
|
|
9032
9212
|
"onBlur": onBlur
|
|
9033
9213
|
}, null)])]) : createVNode("input", {
|
|
9034
9214
|
"ref": "input",
|
|
9035
|
-
"value":
|
|
9215
|
+
"value": displayInputValue.value,
|
|
9036
9216
|
"type": "text",
|
|
9037
9217
|
"class": inputCls.value,
|
|
9038
9218
|
"placeholder": placeholder.value,
|
|
@@ -9091,16 +9271,17 @@ var Select = defineComponent({
|
|
|
9091
9271
|
selectDisabled,
|
|
9092
9272
|
selectSize,
|
|
9093
9273
|
containerRef,
|
|
9274
|
+
originRef,
|
|
9094
9275
|
dropdownRef,
|
|
9095
9276
|
isOpen,
|
|
9096
9277
|
selectCls,
|
|
9097
9278
|
mergeOptions,
|
|
9098
|
-
inputValue,
|
|
9099
9279
|
selectedOptions,
|
|
9100
9280
|
filterQuery,
|
|
9101
9281
|
emptyText,
|
|
9102
9282
|
isLoading,
|
|
9103
9283
|
isShowEmptyText,
|
|
9284
|
+
dropdownWidth,
|
|
9104
9285
|
onClick,
|
|
9105
9286
|
valueChange,
|
|
9106
9287
|
handleClear,
|
|
@@ -9126,7 +9307,13 @@ var Select = defineComponent({
|
|
|
9126
9307
|
blur,
|
|
9127
9308
|
toggleChange
|
|
9128
9309
|
});
|
|
9129
|
-
|
|
9310
|
+
const isRender = ref(false);
|
|
9311
|
+
const position = ref(["bottom-start", "top-start"]);
|
|
9312
|
+
onMounted(() => {
|
|
9313
|
+
isRender.value = true;
|
|
9314
|
+
});
|
|
9315
|
+
provide(SELECT_TOKEN, reactive({
|
|
9316
|
+
...toRefs(props),
|
|
9130
9317
|
selectDisabled,
|
|
9131
9318
|
selectSize,
|
|
9132
9319
|
isOpen,
|
|
@@ -9139,49 +9326,66 @@ var Select = defineComponent({
|
|
|
9139
9326
|
onFocus,
|
|
9140
9327
|
onBlur,
|
|
9141
9328
|
debounceQueryFilter
|
|
9142
|
-
}))
|
|
9329
|
+
}));
|
|
9143
9330
|
return () => {
|
|
9144
9331
|
return createVNode("div", {
|
|
9145
9332
|
"class": selectCls.value,
|
|
9146
9333
|
"ref": containerRef,
|
|
9147
9334
|
"onClick": onClick
|
|
9335
|
+
}, [createVNode("div", {
|
|
9336
|
+
"ref": originRef
|
|
9148
9337
|
}, [createVNode(SelectContent, {
|
|
9149
|
-
"ref": selectRef
|
|
9150
|
-
|
|
9151
|
-
|
|
9152
|
-
"name": "fade",
|
|
9153
|
-
"ref": dropdownRef
|
|
9338
|
+
"ref": selectRef
|
|
9339
|
+
}, null)]), createVNode(Transition, {
|
|
9340
|
+
"name": "fade"
|
|
9154
9341
|
}, {
|
|
9155
|
-
default: () => {
|
|
9156
|
-
|
|
9157
|
-
|
|
9158
|
-
|
|
9159
|
-
|
|
9160
|
-
|
|
9161
|
-
|
|
9162
|
-
|
|
9163
|
-
"
|
|
9164
|
-
"
|
|
9165
|
-
}
|
|
9166
|
-
|
|
9167
|
-
|
|
9168
|
-
|
|
9169
|
-
|
|
9170
|
-
|
|
9171
|
-
|
|
9172
|
-
|
|
9173
|
-
|
|
9174
|
-
|
|
9175
|
-
|
|
9176
|
-
|
|
9177
|
-
|
|
9178
|
-
"
|
|
9342
|
+
default: () => [createVNode(FlexibleOverlay, {
|
|
9343
|
+
"modelValue": isRender.value,
|
|
9344
|
+
"onUpdate:modelValue": ($event) => isRender.value = $event,
|
|
9345
|
+
"ref": dropdownRef,
|
|
9346
|
+
"origin": originRef.value,
|
|
9347
|
+
"align": "start",
|
|
9348
|
+
"position": position.value,
|
|
9349
|
+
"style": {
|
|
9350
|
+
visibility: isOpen.value ? "visible" : "hidden",
|
|
9351
|
+
"z-index": isOpen.value ? 1e3 : -1
|
|
9352
|
+
}
|
|
9353
|
+
}, {
|
|
9354
|
+
default: () => {
|
|
9355
|
+
var _a, _b, _c, _d;
|
|
9356
|
+
return [createVNode("div", {
|
|
9357
|
+
"class": dropdownCls,
|
|
9358
|
+
"style": {
|
|
9359
|
+
width: `${dropdownWidth.value}`,
|
|
9360
|
+
visibility: isOpen.value ? "visible" : "hidden"
|
|
9361
|
+
}
|
|
9362
|
+
}, [withDirectives(createVNode("ul", {
|
|
9363
|
+
"class": listCls
|
|
9364
|
+
}, [isShowCreateOption.value && createVNode(Option, {
|
|
9365
|
+
"value": filterQuery.value,
|
|
9366
|
+
"name": filterQuery.value,
|
|
9367
|
+
"create": true
|
|
9368
|
+
}, {
|
|
9369
|
+
default: () => [props.multiple ? createVNode(Checkbox, {
|
|
9370
|
+
"modelValue": false,
|
|
9371
|
+
"label": filterQuery.value
|
|
9372
|
+
}, null) : filterQuery.value]
|
|
9373
|
+
}), ((_a = ctx.slots) == null ? void 0 : _a.default) && ctx.slots.default(), !((_b = ctx.slots) == null ? void 0 : _b.default) && mergeOptions.value.length >= 1 && mergeOptions.value.map((item) => createVNode(Option, {
|
|
9374
|
+
"key": item.value,
|
|
9375
|
+
"value": item.value,
|
|
9376
|
+
"name": item.name,
|
|
9179
9377
|
"disabled": isDisabled(item)
|
|
9180
|
-
},
|
|
9181
|
-
|
|
9182
|
-
|
|
9183
|
-
|
|
9184
|
-
|
|
9378
|
+
}, {
|
|
9379
|
+
default: () => [props.multiple ? createVNode(Checkbox, {
|
|
9380
|
+
"modelValue": item._checked,
|
|
9381
|
+
"label": item.name,
|
|
9382
|
+
"disabled": isDisabled(item)
|
|
9383
|
+
}, null) : item.name || item.value]
|
|
9384
|
+
}))]), [[vShow, !isLoading.value]]), isShowEmptyText.value && createVNode("div", null, [((_c = ctx.slots) == null ? void 0 : _c.empty) && ctx.slots.empty(), !((_d = ctx.slots) == null ? void 0 : _d.empty) && createVNode("p", {
|
|
9385
|
+
"class": dropdownEmptyCls
|
|
9386
|
+
}, [emptyText.value])])])];
|
|
9387
|
+
}
|
|
9388
|
+
})]
|
|
9185
9389
|
})]);
|
|
9186
9390
|
};
|
|
9187
9391
|
}
|
|
@@ -9191,7 +9395,9 @@ var OptionGroup = defineComponent({
|
|
|
9191
9395
|
props: optionGroupProps,
|
|
9192
9396
|
setup(props, ctx) {
|
|
9193
9397
|
const ns2 = useNamespace("select");
|
|
9194
|
-
provide(OPTION_GROUP_TOKEN, reactive(
|
|
9398
|
+
provide(OPTION_GROUP_TOKEN, reactive({
|
|
9399
|
+
...toRefs(props)
|
|
9400
|
+
}));
|
|
9195
9401
|
return () => {
|
|
9196
9402
|
var _a;
|
|
9197
9403
|
return createVNode("ul", {
|