import * as Vue from 'vue' import { shallowRef, watchEffect, readonly, ref, watch as watch$1, customRef, effectScope, getCurrentScope, onScopeDispose, isRef, unref, computed, reactive, toRefs as toRefs$2, toRef, getCurrentInstance, onBeforeMount, nextTick, onBeforeUnmount, onMounted, onUnmounted, provide, inject, isReactive, defineComponent, openBlock, createElementBlock, createElementVNode, createStaticVNode, warn as warn$2, isVNode as isVNode$1, Fragment, Comment, camelize as camelize$1, h as h$4, Teleport, normalizeClass, normalizeStyle as normalizeStyle$1, renderSlot, mergeProps, useSlots, createBlock, Transition, withCtx, withDirectives, resolveDynamicComponent, createCommentVNode, createTextVNode, toDisplayString as toDisplayString$1, createVNode as createVNode$1, vShow, useAttrs as useAttrs$1, onUpdated, withModifiers, resolveComponent, cloneVNode, Text, renderList, withKeys, createSlots, resolveDirective, normalizeProps, guardReactiveProps, vModelCheckbox, vModelRadio, onBeforeUpdate, vModelText, toHandlers, markRaw, toRaw, triggerRef, TransitionGroup, createApp as createApp$1, render as render$1, isReadonly, shallowReactive, onDeactivated, onActivated, pushScopeId, popScopeId, defineAsyncComponent, useCssVars, } from 'vue' function _mergeNamespaces(n2, m2) { m2.forEach(function (e2) { e2 && typeof e2 !== 'string' && !Array.isArray(e2) && Object.keys(e2).forEach(function (k2) { if (k2 !== 'default' && !(k2 in n2)) { var d3 = Object.getOwnPropertyDescriptor(e2, k2) Object.defineProperty( n2, k2, d3.get ? d3 : { enumerable: true, get: function () { return e2[k2] }, } ) } }) }) return Object.freeze( Object.defineProperty(n2, Symbol.toStringTag, { value: 'Module' }) ) } var freeGlobal$2 = typeof global == 'object' && global && global.Object === Object && global var freeGlobal$3 = freeGlobal$2 var freeSelf$1 = typeof self == 'object' && self && self.Object === Object && self var root$a = freeGlobal$3 || freeSelf$1 || Function('return this')() var root$b = root$a var Symbol$7 = root$b.Symbol var Symbol$8 = Symbol$7 var objectProto$r = Object.prototype var hasOwnProperty$p = objectProto$r.hasOwnProperty var nativeObjectToString$3 = objectProto$r.toString var symToStringTag$3 = Symbol$8 ? Symbol$8.toStringTag : void 0 function getRawTag$2(value2) { var isOwn = hasOwnProperty$p.call(value2, symToStringTag$3), tag = value2[symToStringTag$3] try { value2[symToStringTag$3] = void 0 var unmasked = true } catch (e2) {} var result = nativeObjectToString$3.call(value2) if (unmasked) { if (isOwn) { value2[symToStringTag$3] = tag } else { delete value2[symToStringTag$3] } } return result } var objectProto$q = Object.prototype var nativeObjectToString$2 = objectProto$q.toString function objectToString$7(value2) { return nativeObjectToString$2.call(value2) } var nullTag$1 = '[object Null]', undefinedTag$1 = '[object Undefined]' var symToStringTag$2 = Symbol$8 ? Symbol$8.toStringTag : void 0 function baseGetTag$5(value2) { if (value2 == null) { return value2 === void 0 ? undefinedTag$1 : nullTag$1 } return symToStringTag$2 && symToStringTag$2 in Object(value2) ? getRawTag$2(value2) : objectToString$7(value2) } function isObjectLike$6(value2) { return value2 != null && typeof value2 == 'object' } var symbolTag$5 = '[object Symbol]' function isSymbol$6(value2) { return ( typeof value2 == 'symbol' || (isObjectLike$6(value2) && baseGetTag$5(value2) == symbolTag$5) ) } function arrayMap(array4, iteratee) { var index2 = -1, length2 = array4 == null ? 0 : array4.length, result = Array(length2) while (++index2 < length2) { result[index2] = iteratee(array4[index2], index2, array4) } return result } var isArray$E = Array.isArray var isArray$F = isArray$E var INFINITY$3 = 1 / 0 var symbolProto$3 = Symbol$8 ? Symbol$8.prototype : void 0, symbolToString = symbolProto$3 ? symbolProto$3.toString : void 0 function baseToString(value2) { if (typeof value2 == 'string') { return value2 } if (isArray$F(value2)) { return arrayMap(value2, baseToString) + '' } if (isSymbol$6(value2)) { return symbolToString ? symbolToString.call(value2) : '' } var result = value2 + '' return result == '0' && 1 / value2 == -INFINITY$3 ? '-0' : result } var reWhitespace = /\s/ function trimmedEndIndex(string3) { var index2 = string3.length while (index2-- && reWhitespace.test(string3.charAt(index2))) {} return index2 } var reTrimStart = /^\s+/ function baseTrim(string3) { return string3 ? string3.slice(0, trimmedEndIndex(string3) + 1).replace(reTrimStart, '') : string3 } function isObject$x(value2) { var type4 = typeof value2 return value2 != null && (type4 == 'object' || type4 == 'function') } var NAN = 0 / 0 var reIsBadHex = /^[-+]0x[0-9a-f]+$/i var reIsBinary = /^0b[01]+$/i var reIsOctal = /^0o[0-7]+$/i var freeParseInt = parseInt function toNumber$8(value2) { if (typeof value2 == 'number') { return value2 } if (isSymbol$6(value2)) { return NAN } if (isObject$x(value2)) { var other = typeof value2.valueOf == 'function' ? value2.valueOf() : value2 value2 = isObject$x(other) ? other + '' : other } if (typeof value2 != 'string') { return value2 === 0 ? value2 : +value2 } value2 = baseTrim(value2) var isBinary = reIsBinary.test(value2) return isBinary || reIsOctal.test(value2) ? freeParseInt(value2.slice(2), isBinary ? 2 : 8) : reIsBadHex.test(value2) ? NAN : +value2 } function identity$3(value2) { return value2 } var asyncTag$1 = '[object AsyncFunction]', funcTag$5 = '[object Function]', genTag$3 = '[object GeneratorFunction]', proxyTag$1 = '[object Proxy]' function isFunction$n(value2) { if (!isObject$x(value2)) { return false } var tag = baseGetTag$5(value2) return ( tag == funcTag$5 || tag == genTag$3 || tag == asyncTag$1 || tag == proxyTag$1 ) } var coreJsData$2 = root$b['__core-js_shared__'] var coreJsData$3 = coreJsData$2 var maskSrcKey$1 = (function () { var uid2 = /[^.]+$/.exec( (coreJsData$3 && coreJsData$3.keys && coreJsData$3.keys.IE_PROTO) || '' ) return uid2 ? 'Symbol(src)_1.' + uid2 : '' })() function isMasked$2(func) { return !!maskSrcKey$1 && maskSrcKey$1 in func } var funcProto$3 = Function.prototype var funcToString$3 = funcProto$3.toString function toSource$3(func) { if (func != null) { try { return funcToString$3.call(func) } catch (e2) {} try { return func + '' } catch (e2) {} } return '' } var reRegExpChar$1 = /[\\^$.*+?()[\]{}|]/g var reIsHostCtor$1 = /^\[object .+?Constructor\]$/ var funcProto$2 = Function.prototype, objectProto$p = Object.prototype var funcToString$2 = funcProto$2.toString var hasOwnProperty$o = objectProto$p.hasOwnProperty var reIsNative$1 = RegExp( '^' + funcToString$2 .call(hasOwnProperty$o) .replace(reRegExpChar$1, '\\$&') .replace( /hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?' ) + '$' ) function baseIsNative$2(value2) { if (!isObject$x(value2) || isMasked$2(value2)) { return false } var pattern4 = isFunction$n(value2) ? reIsNative$1 : reIsHostCtor$1 return pattern4.test(toSource$3(value2)) } function getValue$4(object4, key2) { return object4 == null ? void 0 : object4[key2] } function getNative$8(object4, key2) { var value2 = getValue$4(object4, key2) return baseIsNative$2(value2) ? value2 : void 0 } var WeakMap$7 = getNative$8(root$b, 'WeakMap') var WeakMap$8 = WeakMap$7 var objectCreate$2 = Object.create var baseCreate$2 = (function () { function object4() {} return function (proto2) { if (!isObject$x(proto2)) { return {} } if (objectCreate$2) { return objectCreate$2(proto2) } object4.prototype = proto2 var result = new object4() object4.prototype = void 0 return result } })() var baseCreate$3 = baseCreate$2 function apply$6(func, thisArg, args) { switch (args.length) { case 0: return func.call(thisArg) case 1: return func.call(thisArg, args[0]) case 2: return func.call(thisArg, args[0], args[1]) case 3: return func.call(thisArg, args[0], args[1], args[2]) } return func.apply(thisArg, args) } function noop$8() {} function copyArray$2(source2, array4) { var index2 = -1, length2 = source2.length array4 || (array4 = Array(length2)) while (++index2 < length2) { array4[index2] = source2[index2] } return array4 } var HOT_COUNT = 800, HOT_SPAN = 16 var nativeNow = Date.now function shortOut(func) { var count2 = 0, lastCalled = 0 return function () { var stamp2 = nativeNow(), remaining = HOT_SPAN - (stamp2 - lastCalled) lastCalled = stamp2 if (remaining > 0) { if (++count2 >= HOT_COUNT) { return arguments[0] } } else { count2 = 0 } return func.apply(void 0, arguments) } } function constant(value2) { return function () { return value2 } } var defineProperty$8 = (function () { try { var func = getNative$8(Object, 'defineProperty') func({}, '', {}) return func } catch (e2) {} })() var defineProperty$9 = defineProperty$8 var baseSetToString = !defineProperty$9 ? identity$3 : function (func, string3) { return defineProperty$9(func, 'toString', { configurable: true, enumerable: false, value: constant(string3), writable: true, }) } var baseSetToString$1 = baseSetToString var setToString = shortOut(baseSetToString$1) var setToString$1 = setToString function arrayEach$h(array4, iteratee) { var index2 = -1, length2 = array4 == null ? 0 : array4.length while (++index2 < length2) { if (iteratee(array4[index2], index2, array4) === false) { break } } return array4 } function baseFindIndex(array4, predicate, fromIndex, fromRight) { var length2 = array4.length, index2 = fromIndex + (fromRight ? 1 : -1) while (fromRight ? index2-- : ++index2 < length2) { if (predicate(array4[index2], index2, array4)) { return index2 } } return -1 } function baseIsNaN(value2) { return value2 !== value2 } function strictIndexOf(array4, value2, fromIndex) { var index2 = fromIndex - 1, length2 = array4.length while (++index2 < length2) { if (array4[index2] === value2) { return index2 } } return -1 } function baseIndexOf(array4, value2, fromIndex) { return value2 === value2 ? strictIndexOf(array4, value2, fromIndex) : baseFindIndex(array4, baseIsNaN, fromIndex) } function arrayIncludes$1(array4, value2) { var length2 = array4 == null ? 0 : array4.length return !!length2 && baseIndexOf(array4, value2, 0) > -1 } var MAX_SAFE_INTEGER$4 = 9007199254740991 var reIsUint$1 = /^(?:0|[1-9]\d*)$/ function isIndex$2(value2, length2) { var type4 = typeof value2 length2 = length2 == null ? MAX_SAFE_INTEGER$4 : length2 return ( !!length2 && (type4 == 'number' || (type4 != 'symbol' && reIsUint$1.test(value2))) && value2 > -1 && value2 % 1 == 0 && value2 < length2 ) } function baseAssignValue$3(object4, key2, value2) { if (key2 == '__proto__' && defineProperty$9) { defineProperty$9(object4, key2, { configurable: true, enumerable: true, value: value2, writable: true, }) } else { object4[key2] = value2 } } function eq$3(value2, other) { return value2 === other || (value2 !== value2 && other !== other) } var objectProto$o = Object.prototype var hasOwnProperty$n = objectProto$o.hasOwnProperty function assignValue$3(object4, key2, value2) { var objValue = object4[key2] if ( !(hasOwnProperty$n.call(object4, key2) && eq$3(objValue, value2)) || (value2 === void 0 && !(key2 in object4)) ) { baseAssignValue$3(object4, key2, value2) } } function copyObject$5(source2, props2, object4, customizer) { var isNew = !object4 object4 || (object4 = {}) var index2 = -1, length2 = props2.length while (++index2 < length2) { var key2 = props2[index2] var newValue = customizer ? customizer(object4[key2], source2[key2], key2, object4, source2) : void 0 if (newValue === void 0) { newValue = source2[key2] } if (isNew) { baseAssignValue$3(object4, key2, newValue) } else { assignValue$3(object4, key2, newValue) } } return object4 } var nativeMax$1 = Math.max function overRest(func, start2, transform3) { start2 = nativeMax$1(start2 === void 0 ? func.length - 1 : start2, 0) return function () { var args = arguments, index2 = -1, length2 = nativeMax$1(args.length - start2, 0), array4 = Array(length2) while (++index2 < length2) { array4[index2] = args[start2 + index2] } index2 = -1 var otherArgs = Array(start2 + 1) while (++index2 < start2) { otherArgs[index2] = args[index2] } otherArgs[start2] = transform3(array4) return apply$6(func, this, otherArgs) } } function baseRest(func, start2) { return setToString$1(overRest(func, start2, identity$3), func + '') } var MAX_SAFE_INTEGER$3 = 9007199254740991 function isLength$4(value2) { return ( typeof value2 == 'number' && value2 > -1 && value2 % 1 == 0 && value2 <= MAX_SAFE_INTEGER$3 ) } function isArrayLike$4(value2) { return value2 != null && isLength$4(value2.length) && !isFunction$n(value2) } var objectProto$n = Object.prototype function isPrototype$4(value2) { var Ctor = value2 && value2.constructor, proto2 = (typeof Ctor == 'function' && Ctor.prototype) || objectProto$n return value2 === proto2 } function baseTimes$2(n2, iteratee) { var index2 = -1, result = Array(n2) while (++index2 < n2) { result[index2] = iteratee(index2) } return result } var argsTag$6 = '[object Arguments]' function baseIsArguments$2(value2) { return isObjectLike$6(value2) && baseGetTag$5(value2) == argsTag$6 } var objectProto$m = Object.prototype var hasOwnProperty$m = objectProto$m.hasOwnProperty var propertyIsEnumerable$3 = objectProto$m.propertyIsEnumerable var isArguments$4 = baseIsArguments$2( (function () { return arguments })() ) ? baseIsArguments$2 : function (value2) { return ( isObjectLike$6(value2) && hasOwnProperty$m.call(value2, 'callee') && !propertyIsEnumerable$3.call(value2, 'callee') ) } var isArguments$5 = isArguments$4 function stubFalse$1() { return false } var freeExports$2 = typeof exports == 'object' && exports && !exports.nodeType && exports var freeModule$2 = freeExports$2 && typeof module == 'object' && module && !module.nodeType && module var moduleExports$2 = freeModule$2 && freeModule$2.exports === freeExports$2 var Buffer$2 = moduleExports$2 ? root$b.Buffer : void 0 var nativeIsBuffer = Buffer$2 ? Buffer$2.isBuffer : void 0 var isBuffer$4 = nativeIsBuffer || stubFalse$1 var isBuffer$5 = isBuffer$4 var argsTag$5 = '[object Arguments]', arrayTag$4 = '[object Array]', boolTag$6 = '[object Boolean]', dateTag$6 = '[object Date]', errorTag$4 = '[object Error]', funcTag$4 = '[object Function]', mapTag$a = '[object Map]', numberTag$6 = '[object Number]', objectTag$6 = '[object Object]', regexpTag$6 = '[object RegExp]', setTag$a = '[object Set]', stringTag$6 = '[object String]', weakMapTag$5 = '[object WeakMap]' var arrayBufferTag$6 = '[object ArrayBuffer]', dataViewTag$8 = '[object DataView]', float32Tag$5 = '[object Float32Array]', float64Tag$5 = '[object Float64Array]', int8Tag$5 = '[object Int8Array]', int16Tag$5 = '[object Int16Array]', int32Tag$5 = '[object Int32Array]', uint8Tag$5 = '[object Uint8Array]', uint8ClampedTag$5 = '[object Uint8ClampedArray]', uint16Tag$5 = '[object Uint16Array]', uint32Tag$5 = '[object Uint32Array]' var typedArrayTags$1 = {} typedArrayTags$1[float32Tag$5] = typedArrayTags$1[float64Tag$5] = typedArrayTags$1[int8Tag$5] = typedArrayTags$1[int16Tag$5] = typedArrayTags$1[int32Tag$5] = typedArrayTags$1[uint8Tag$5] = typedArrayTags$1[uint8ClampedTag$5] = typedArrayTags$1[uint16Tag$5] = typedArrayTags$1[uint32Tag$5] = true typedArrayTags$1[argsTag$5] = typedArrayTags$1[arrayTag$4] = typedArrayTags$1[arrayBufferTag$6] = typedArrayTags$1[boolTag$6] = typedArrayTags$1[dataViewTag$8] = typedArrayTags$1[dateTag$6] = typedArrayTags$1[errorTag$4] = typedArrayTags$1[funcTag$4] = typedArrayTags$1[mapTag$a] = typedArrayTags$1[numberTag$6] = typedArrayTags$1[objectTag$6] = typedArrayTags$1[regexpTag$6] = typedArrayTags$1[setTag$a] = typedArrayTags$1[stringTag$6] = typedArrayTags$1[weakMapTag$5] = false function baseIsTypedArray$2(value2) { return ( isObjectLike$6(value2) && isLength$4(value2.length) && !!typedArrayTags$1[baseGetTag$5(value2)] ) } function baseUnary$4(func) { return function (value2) { return func(value2) } } var freeExports$1 = typeof exports == 'object' && exports && !exports.nodeType && exports var freeModule$1 = freeExports$1 && typeof module == 'object' && module && !module.nodeType && module var moduleExports$1 = freeModule$1 && freeModule$1.exports === freeExports$1 var freeProcess = moduleExports$1 && freeGlobal$3.process var nodeUtil$3 = (function () { try { var types2 = freeModule$1 && freeModule$1.require && freeModule$1.require('util').types if (types2) { return types2 } return freeProcess && freeProcess.binding && freeProcess.binding('util') } catch (e2) {} })() var nodeUtil$4 = nodeUtil$3 var nodeIsTypedArray$1 = nodeUtil$4 && nodeUtil$4.isTypedArray var isTypedArray$3 = nodeIsTypedArray$1 ? baseUnary$4(nodeIsTypedArray$1) : baseIsTypedArray$2 var isTypedArray$4 = isTypedArray$3 var objectProto$l = Object.prototype var hasOwnProperty$l = objectProto$l.hasOwnProperty function arrayLikeKeys$3(value2, inherited) { var isArr = isArray$F(value2), isArg = !isArr && isArguments$5(value2), isBuff = !isArr && !isArg && isBuffer$5(value2), isType = !isArr && !isArg && !isBuff && isTypedArray$4(value2), skipIndexes = isArr || isArg || isBuff || isType, result = skipIndexes ? baseTimes$2(value2.length, String) : [], length2 = result.length for (var key2 in value2) { if ( (inherited || hasOwnProperty$l.call(value2, key2)) && !( skipIndexes && (key2 == 'length' || (isBuff && (key2 == 'offset' || key2 == 'parent')) || (isType && (key2 == 'buffer' || key2 == 'byteLength' || key2 == 'byteOffset')) || isIndex$2(key2, length2)) ) ) { result.push(key2) } } return result } function overArg$3(func, transform3) { return function (arg) { return func(transform3(arg)) } } var nativeKeys$2 = overArg$3(Object.keys, Object) var nativeKeys$3 = nativeKeys$2 var objectProto$k = Object.prototype var hasOwnProperty$k = objectProto$k.hasOwnProperty function baseKeys$2(object4) { if (!isPrototype$4(object4)) { return nativeKeys$3(object4) } var result = [] for (var key2 in Object(object4)) { if (hasOwnProperty$k.call(object4, key2) && key2 != 'constructor') { result.push(key2) } } return result } function keys$i(object4) { return isArrayLike$4(object4) ? arrayLikeKeys$3(object4) : baseKeys$2(object4) } function nativeKeysIn$2(object4) { var result = [] if (object4 != null) { for (var key2 in Object(object4)) { result.push(key2) } } return result } var objectProto$j = Object.prototype var hasOwnProperty$j = objectProto$j.hasOwnProperty function baseKeysIn$2(object4) { if (!isObject$x(object4)) { return nativeKeysIn$2(object4) } var isProto = isPrototype$4(object4), result = [] for (var key2 in object4) { if ( !( key2 == 'constructor' && (isProto || !hasOwnProperty$j.call(object4, key2)) ) ) { result.push(key2) } } return result } function keysIn$4(object4) { return isArrayLike$4(object4) ? arrayLikeKeys$3(object4, true) : baseKeysIn$2(object4) } var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, reIsPlainProp = /^\w*$/ function isKey(value2, object4) { if (isArray$F(value2)) { return false } var type4 = typeof value2 if ( type4 == 'number' || type4 == 'symbol' || type4 == 'boolean' || value2 == null || isSymbol$6(value2) ) { return true } return ( reIsPlainProp.test(value2) || !reIsDeepProp.test(value2) || (object4 != null && value2 in Object(object4)) ) } var nativeCreate$5 = getNative$8(Object, 'create') var nativeCreate$6 = nativeCreate$5 function hashClear$2() { this.__data__ = nativeCreate$6 ? nativeCreate$6(null) : {} this.size = 0 } function hashDelete$2(key2) { var result = this.has(key2) && delete this.__data__[key2] this.size -= result ? 1 : 0 return result } var HASH_UNDEFINED$4 = '__lodash_hash_undefined__' var objectProto$i = Object.prototype var hasOwnProperty$i = objectProto$i.hasOwnProperty function hashGet$2(key2) { var data2 = this.__data__ if (nativeCreate$6) { var result = data2[key2] return result === HASH_UNDEFINED$4 ? void 0 : result } return hasOwnProperty$i.call(data2, key2) ? data2[key2] : void 0 } var objectProto$h = Object.prototype var hasOwnProperty$h = objectProto$h.hasOwnProperty function hashHas$2(key2) { var data2 = this.__data__ return nativeCreate$6 ? data2[key2] !== void 0 : hasOwnProperty$h.call(data2, key2) } var HASH_UNDEFINED$3 = '__lodash_hash_undefined__' function hashSet$2(key2, value2) { var data2 = this.__data__ this.size += this.has(key2) ? 0 : 1 data2[key2] = nativeCreate$6 && value2 === void 0 ? HASH_UNDEFINED$3 : value2 return this } function Hash$2(entries2) { var index2 = -1, length2 = entries2 == null ? 0 : entries2.length this.clear() while (++index2 < length2) { var entry = entries2[index2] this.set(entry[0], entry[1]) } } Hash$2.prototype.clear = hashClear$2 Hash$2.prototype['delete'] = hashDelete$2 Hash$2.prototype.get = hashGet$2 Hash$2.prototype.has = hashHas$2 Hash$2.prototype.set = hashSet$2 function listCacheClear$2() { this.__data__ = [] this.size = 0 } function assocIndexOf$5(array4, key2) { var length2 = array4.length while (length2--) { if (eq$3(array4[length2][0], key2)) { return length2 } } return -1 } var arrayProto$2 = Array.prototype var splice$1 = arrayProto$2.splice function listCacheDelete$2(key2) { var data2 = this.__data__, index2 = assocIndexOf$5(data2, key2) if (index2 < 0) { return false } var lastIndex = data2.length - 1 if (index2 == lastIndex) { data2.pop() } else { splice$1.call(data2, index2, 1) } --this.size return true } function listCacheGet$3(key2) { var data2 = this.__data__, index2 = assocIndexOf$5(data2, key2) return index2 < 0 ? void 0 : data2[index2][1] } function listCacheHas$2(key2) { return assocIndexOf$5(this.__data__, key2) > -1 } function listCacheSet$3(key2, value2) { var data2 = this.__data__, index2 = assocIndexOf$5(data2, key2) if (index2 < 0) { ++this.size data2.push([key2, value2]) } else { data2[index2][1] = value2 } return this } function ListCache$5(entries2) { var index2 = -1, length2 = entries2 == null ? 0 : entries2.length this.clear() while (++index2 < length2) { var entry = entries2[index2] this.set(entry[0], entry[1]) } } ListCache$5.prototype.clear = listCacheClear$2 ListCache$5.prototype['delete'] = listCacheDelete$2 ListCache$5.prototype.get = listCacheGet$3 ListCache$5.prototype.has = listCacheHas$2 ListCache$5.prototype.set = listCacheSet$3 var Map$5 = getNative$8(root$b, 'Map') var Map$6 = Map$5 function mapCacheClear$2() { this.size = 0 this.__data__ = { hash: new Hash$2(), map: new (Map$6 || ListCache$5)(), string: new Hash$2(), } } function isKeyable$2(value2) { var type4 = typeof value2 return type4 == 'string' || type4 == 'number' || type4 == 'symbol' || type4 == 'boolean' ? value2 !== '__proto__' : value2 === null } function getMapData$5(map2, key2) { var data2 = map2.__data__ return isKeyable$2(key2) ? data2[typeof key2 == 'string' ? 'string' : 'hash'] : data2.map } function mapCacheDelete$2(key2) { var result = getMapData$5(this, key2)['delete'](key2) this.size -= result ? 1 : 0 return result } function mapCacheGet$2(key2) { return getMapData$5(this, key2).get(key2) } function mapCacheHas$2(key2) { return getMapData$5(this, key2).has(key2) } function mapCacheSet$2(key2, value2) { var data2 = getMapData$5(this, key2), size = data2.size data2.set(key2, value2) this.size += data2.size == size ? 0 : 1 return this } function MapCache$2(entries2) { var index2 = -1, length2 = entries2 == null ? 0 : entries2.length this.clear() while (++index2 < length2) { var entry = entries2[index2] this.set(entry[0], entry[1]) } } MapCache$2.prototype.clear = mapCacheClear$2 MapCache$2.prototype['delete'] = mapCacheDelete$2 MapCache$2.prototype.get = mapCacheGet$2 MapCache$2.prototype.has = mapCacheHas$2 MapCache$2.prototype.set = mapCacheSet$2 var FUNC_ERROR_TEXT$2 = 'Expected a function' function memoize(func, resolver) { if ( typeof func != 'function' || (resolver != null && typeof resolver != 'function') ) { throw new TypeError(FUNC_ERROR_TEXT$2) } var memoized = function () { var args = arguments, key2 = resolver ? resolver.apply(this, args) : args[0], cache2 = memoized.cache if (cache2.has(key2)) { return cache2.get(key2) } var result = func.apply(this, args) memoized.cache = cache2.set(key2, result) || cache2 return result } memoized.cache = new (memoize.Cache || MapCache$2)() return memoized } memoize.Cache = MapCache$2 var MAX_MEMOIZE_SIZE = 500 function memoizeCapped(func) { var result = memoize(func, function (key2) { if (cache2.size === MAX_MEMOIZE_SIZE) { cache2.clear() } return key2 }) var cache2 = result.cache return result } var rePropName = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g var reEscapeChar = /\\(\\)?/g var stringToPath = memoizeCapped(function (string3) { var result = [] if (string3.charCodeAt(0) === 46) { result.push('') } string3.replace(rePropName, function (match2, number4, quote, subString) { result.push( quote ? subString.replace(reEscapeChar, '$1') : number4 || match2 ) }) return result }) var stringToPath$1 = stringToPath function toString$f(value2) { return value2 == null ? '' : baseToString(value2) } function castPath(value2, object4) { if (isArray$F(value2)) { return value2 } return isKey(value2, object4) ? [value2] : stringToPath$1(toString$f(value2)) } var INFINITY$2 = 1 / 0 function toKey(value2) { if (typeof value2 == 'string' || isSymbol$6(value2)) { return value2 } var result = value2 + '' return result == '0' && 1 / value2 == -INFINITY$2 ? '-0' : result } function baseGet(object4, path) { path = castPath(path, object4) var index2 = 0, length2 = path.length while (object4 != null && index2 < length2) { object4 = object4[toKey(path[index2++])] } return index2 && index2 == length2 ? object4 : void 0 } function get$a(object4, path, defaultValue) { var result = object4 == null ? void 0 : baseGet(object4, path) return result === void 0 ? defaultValue : result } function arrayPush$4(array4, values2) { var index2 = -1, length2 = values2.length, offset2 = array4.length while (++index2 < length2) { array4[offset2 + index2] = values2[index2] } return array4 } var spreadableSymbol = Symbol$8 ? Symbol$8.isConcatSpreadable : void 0 function isFlattenable(value2) { return ( isArray$F(value2) || isArguments$5(value2) || !!(spreadableSymbol && value2 && value2[spreadableSymbol]) ) } function baseFlatten(array4, depth, predicate, isStrict, result) { var index2 = -1, length2 = array4.length predicate || (predicate = isFlattenable) result || (result = []) while (++index2 < length2) { var value2 = array4[index2] if (depth > 0 && predicate(value2)) { if (depth > 1) { baseFlatten(value2, depth - 1, predicate, isStrict, result) } else { arrayPush$4(result, value2) } } else if (!isStrict) { result[result.length] = value2 } } return result } function flatten$2(array4) { var length2 = array4 == null ? 0 : array4.length return length2 ? baseFlatten(array4, 1) : [] } function flatRest(func) { return setToString$1(overRest(func, void 0, flatten$2), func + '') } var getPrototype$3 = overArg$3(Object.getPrototypeOf, Object) var getPrototype$4 = getPrototype$3 function castArray$1() { if (!arguments.length) { return [] } var value2 = arguments[0] return isArray$F(value2) ? value2 : [value2] } function stackClear$2() { this.__data__ = new ListCache$5() this.size = 0 } function stackDelete$2(key2) { var data2 = this.__data__, result = data2['delete'](key2) this.size = data2.size return result } function stackGet$2(key2) { return this.__data__.get(key2) } function stackHas$2(key2) { return this.__data__.has(key2) } var LARGE_ARRAY_SIZE$2 = 200 function stackSet$2(key2, value2) { var data2 = this.__data__ if (data2 instanceof ListCache$5) { var pairs = data2.__data__ if (!Map$6 || pairs.length < LARGE_ARRAY_SIZE$2 - 1) { pairs.push([key2, value2]) this.size = ++data2.size return this } data2 = this.__data__ = new MapCache$2(pairs) } data2.set(key2, value2) this.size = data2.size return this } function Stack$2(entries2) { var data2 = (this.__data__ = new ListCache$5(entries2)) this.size = data2.size } Stack$2.prototype.clear = stackClear$2 Stack$2.prototype['delete'] = stackDelete$2 Stack$2.prototype.get = stackGet$2 Stack$2.prototype.has = stackHas$2 Stack$2.prototype.set = stackSet$2 function baseAssign$2(object4, source2) { return object4 && copyObject$5(source2, keys$i(source2), object4) } function baseAssignIn$2(object4, source2) { return object4 && copyObject$5(source2, keysIn$4(source2), object4) } var freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports var freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module var moduleExports = freeModule && freeModule.exports === freeExports var Buffer$1 = moduleExports ? root$b.Buffer : void 0, allocUnsafe = Buffer$1 ? Buffer$1.allocUnsafe : void 0 function cloneBuffer$1(buffer, isDeep) { if (isDeep) { return buffer.slice() } var length2 = buffer.length, result = allocUnsafe ? allocUnsafe(length2) : new buffer.constructor(length2) buffer.copy(result) return result } function arrayFilter$2(array4, predicate) { var index2 = -1, length2 = array4 == null ? 0 : array4.length, resIndex = 0, result = [] while (++index2 < length2) { var value2 = array4[index2] if (predicate(value2, index2, array4)) { result[resIndex++] = value2 } } return result } function stubArray$3() { return [] } var objectProto$g = Object.prototype var propertyIsEnumerable$2 = objectProto$g.propertyIsEnumerable var nativeGetSymbols$3 = Object.getOwnPropertySymbols var getSymbols$4 = !nativeGetSymbols$3 ? stubArray$3 : function (object4) { if (object4 == null) { return [] } object4 = Object(object4) return arrayFilter$2(nativeGetSymbols$3(object4), function (symbol) { return propertyIsEnumerable$2.call(object4, symbol) }) } var getSymbols$5 = getSymbols$4 function copySymbols$2(source2, object4) { return copyObject$5(source2, getSymbols$5(source2), object4) } var nativeGetSymbols$2 = Object.getOwnPropertySymbols var getSymbolsIn$3 = !nativeGetSymbols$2 ? stubArray$3 : function (object4) { var result = [] while (object4) { arrayPush$4(result, getSymbols$5(object4)) object4 = getPrototype$4(object4) } return result } var getSymbolsIn$4 = getSymbolsIn$3 function copySymbolsIn$2(source2, object4) { return copyObject$5(source2, getSymbolsIn$4(source2), object4) } function baseGetAllKeys$3(object4, keysFunc, symbolsFunc) { var result = keysFunc(object4) return isArray$F(object4) ? result : arrayPush$4(result, symbolsFunc(object4)) } function getAllKeys$2(object4) { return baseGetAllKeys$3(object4, keys$i, getSymbols$5) } function getAllKeysIn$2(object4) { return baseGetAllKeys$3(object4, keysIn$4, getSymbolsIn$4) } var DataView$5 = getNative$8(root$b, 'DataView') var DataView$6 = DataView$5 var Promise$4 = getNative$8(root$b, 'Promise') var Promise$5 = Promise$4 var Set$3 = getNative$8(root$b, 'Set') var Set$4 = Set$3 var mapTag$9 = '[object Map]', objectTag$5 = '[object Object]', promiseTag$1 = '[object Promise]', setTag$9 = '[object Set]', weakMapTag$4 = '[object WeakMap]' var dataViewTag$7 = '[object DataView]' var dataViewCtorString$1 = toSource$3(DataView$6), mapCtorString$1 = toSource$3(Map$6), promiseCtorString$1 = toSource$3(Promise$5), setCtorString$1 = toSource$3(Set$4), weakMapCtorString$1 = toSource$3(WeakMap$8) var getTag$4 = baseGetTag$5 if ( (DataView$6 && getTag$4(new DataView$6(new ArrayBuffer(1))) != dataViewTag$7) || (Map$6 && getTag$4(new Map$6()) != mapTag$9) || (Promise$5 && getTag$4(Promise$5.resolve()) != promiseTag$1) || (Set$4 && getTag$4(new Set$4()) != setTag$9) || (WeakMap$8 && getTag$4(new WeakMap$8()) != weakMapTag$4) ) { getTag$4 = function (value2) { var result = baseGetTag$5(value2), Ctor = result == objectTag$5 ? value2.constructor : void 0, ctorString = Ctor ? toSource$3(Ctor) : '' if (ctorString) { switch (ctorString) { case dataViewCtorString$1: return dataViewTag$7 case mapCtorString$1: return mapTag$9 case promiseCtorString$1: return promiseTag$1 case setCtorString$1: return setTag$9 case weakMapCtorString$1: return weakMapTag$4 } } return result } } var getTag$5 = getTag$4 var objectProto$f = Object.prototype var hasOwnProperty$g = objectProto$f.hasOwnProperty function initCloneArray$2(array4) { var length2 = array4.length, result = new array4.constructor(length2) if ( length2 && typeof array4[0] == 'string' && hasOwnProperty$g.call(array4, 'index') ) { result.index = array4.index result.input = array4.input } return result } var Uint8Array$3 = root$b.Uint8Array var Uint8Array$4 = Uint8Array$3 function cloneArrayBuffer$4(arrayBuffer) { var result = new arrayBuffer.constructor(arrayBuffer.byteLength) new Uint8Array$4(result).set(new Uint8Array$4(arrayBuffer)) return result } function cloneDataView$2(dataView, isDeep) { var buffer = isDeep ? cloneArrayBuffer$4(dataView.buffer) : dataView.buffer return new dataView.constructor( buffer, dataView.byteOffset, dataView.byteLength ) } var reFlags$1 = /\w*$/ function cloneRegExp$2(regexp4) { var result = new regexp4.constructor(regexp4.source, reFlags$1.exec(regexp4)) result.lastIndex = regexp4.lastIndex return result } var symbolProto$2 = Symbol$8 ? Symbol$8.prototype : void 0, symbolValueOf$2 = symbolProto$2 ? symbolProto$2.valueOf : void 0 function cloneSymbol$2(symbol) { return symbolValueOf$2 ? Object(symbolValueOf$2.call(symbol)) : {} } function cloneTypedArray$2(typedArray, isDeep) { var buffer = isDeep ? cloneArrayBuffer$4(typedArray.buffer) : typedArray.buffer return new typedArray.constructor( buffer, typedArray.byteOffset, typedArray.length ) } var boolTag$5 = '[object Boolean]', dateTag$5 = '[object Date]', mapTag$8 = '[object Map]', numberTag$5 = '[object Number]', regexpTag$5 = '[object RegExp]', setTag$8 = '[object Set]', stringTag$5 = '[object String]', symbolTag$4 = '[object Symbol]' var arrayBufferTag$5 = '[object ArrayBuffer]', dataViewTag$6 = '[object DataView]', float32Tag$4 = '[object Float32Array]', float64Tag$4 = '[object Float64Array]', int8Tag$4 = '[object Int8Array]', int16Tag$4 = '[object Int16Array]', int32Tag$4 = '[object Int32Array]', uint8Tag$4 = '[object Uint8Array]', uint8ClampedTag$4 = '[object Uint8ClampedArray]', uint16Tag$4 = '[object Uint16Array]', uint32Tag$4 = '[object Uint32Array]' function initCloneByTag$2(object4, tag, isDeep) { var Ctor = object4.constructor switch (tag) { case arrayBufferTag$5: return cloneArrayBuffer$4(object4) case boolTag$5: case dateTag$5: return new Ctor(+object4) case dataViewTag$6: return cloneDataView$2(object4, isDeep) case float32Tag$4: case float64Tag$4: case int8Tag$4: case int16Tag$4: case int32Tag$4: case uint8Tag$4: case uint8ClampedTag$4: case uint16Tag$4: case uint32Tag$4: return cloneTypedArray$2(object4, isDeep) case mapTag$8: return new Ctor() case numberTag$5: case stringTag$5: return new Ctor(object4) case regexpTag$5: return cloneRegExp$2(object4) case setTag$8: return new Ctor() case symbolTag$4: return cloneSymbol$2(object4) } } function initCloneObject$2(object4) { return typeof object4.constructor == 'function' && !isPrototype$4(object4) ? baseCreate$3(getPrototype$4(object4)) : {} } var mapTag$7 = '[object Map]' function baseIsMap$2(value2) { return isObjectLike$6(value2) && getTag$5(value2) == mapTag$7 } var nodeIsMap$1 = nodeUtil$4 && nodeUtil$4.isMap var isMap$4 = nodeIsMap$1 ? baseUnary$4(nodeIsMap$1) : baseIsMap$2 var isMap$5 = isMap$4 var setTag$7 = '[object Set]' function baseIsSet$2(value2) { return isObjectLike$6(value2) && getTag$5(value2) == setTag$7 } var nodeIsSet$1 = nodeUtil$4 && nodeUtil$4.isSet var isSet$4 = nodeIsSet$1 ? baseUnary$4(nodeIsSet$1) : baseIsSet$2 var isSet$5 = isSet$4 var CLONE_DEEP_FLAG$2 = 1, CLONE_FLAT_FLAG$1 = 2, CLONE_SYMBOLS_FLAG$3 = 4 var argsTag$4 = '[object Arguments]', arrayTag$3 = '[object Array]', boolTag$4 = '[object Boolean]', dateTag$4 = '[object Date]', errorTag$3 = '[object Error]', funcTag$3 = '[object Function]', genTag$2 = '[object GeneratorFunction]', mapTag$6 = '[object Map]', numberTag$4 = '[object Number]', objectTag$4 = '[object Object]', regexpTag$4 = '[object RegExp]', setTag$6 = '[object Set]', stringTag$4 = '[object String]', symbolTag$3 = '[object Symbol]', weakMapTag$3 = '[object WeakMap]' var arrayBufferTag$4 = '[object ArrayBuffer]', dataViewTag$5 = '[object DataView]', float32Tag$3 = '[object Float32Array]', float64Tag$3 = '[object Float64Array]', int8Tag$3 = '[object Int8Array]', int16Tag$3 = '[object Int16Array]', int32Tag$3 = '[object Int32Array]', uint8Tag$3 = '[object Uint8Array]', uint8ClampedTag$3 = '[object Uint8ClampedArray]', uint16Tag$3 = '[object Uint16Array]', uint32Tag$3 = '[object Uint32Array]' var cloneableTags$1 = {} cloneableTags$1[argsTag$4] = cloneableTags$1[arrayTag$3] = cloneableTags$1[arrayBufferTag$4] = cloneableTags$1[dataViewTag$5] = cloneableTags$1[boolTag$4] = cloneableTags$1[dateTag$4] = cloneableTags$1[float32Tag$3] = cloneableTags$1[float64Tag$3] = cloneableTags$1[int8Tag$3] = cloneableTags$1[int16Tag$3] = cloneableTags$1[int32Tag$3] = cloneableTags$1[mapTag$6] = cloneableTags$1[numberTag$4] = cloneableTags$1[objectTag$4] = cloneableTags$1[regexpTag$4] = cloneableTags$1[setTag$6] = cloneableTags$1[stringTag$4] = cloneableTags$1[symbolTag$3] = cloneableTags$1[uint8Tag$3] = cloneableTags$1[uint8ClampedTag$3] = cloneableTags$1[uint16Tag$3] = cloneableTags$1[uint32Tag$3] = true cloneableTags$1[errorTag$3] = cloneableTags$1[funcTag$3] = cloneableTags$1[weakMapTag$3] = false function baseClone$2(value2, bitmask, customizer, key2, object4, stack) { var result, isDeep = bitmask & CLONE_DEEP_FLAG$2, isFlat = bitmask & CLONE_FLAT_FLAG$1, isFull = bitmask & CLONE_SYMBOLS_FLAG$3 if (customizer) { result = object4 ? customizer(value2, key2, object4, stack) : customizer(value2) } if (result !== void 0) { return result } if (!isObject$x(value2)) { return value2 } var isArr = isArray$F(value2) if (isArr) { result = initCloneArray$2(value2) if (!isDeep) { return copyArray$2(value2, result) } } else { var tag = getTag$5(value2), isFunc = tag == funcTag$3 || tag == genTag$2 if (isBuffer$5(value2)) { return cloneBuffer$1(value2, isDeep) } if (tag == objectTag$4 || tag == argsTag$4 || (isFunc && !object4)) { result = isFlat || isFunc ? {} : initCloneObject$2(value2) if (!isDeep) { return isFlat ? copySymbolsIn$2(value2, baseAssignIn$2(result, value2)) : copySymbols$2(value2, baseAssign$2(result, value2)) } } else { if (!cloneableTags$1[tag]) { return object4 ? value2 : {} } result = initCloneByTag$2(value2, tag, isDeep) } } stack || (stack = new Stack$2()) var stacked = stack.get(value2) if (stacked) { return stacked } stack.set(value2, result) if (isSet$5(value2)) { value2.forEach(function (subValue) { result.add( baseClone$2(subValue, bitmask, customizer, subValue, value2, stack) ) }) } else if (isMap$5(value2)) { value2.forEach(function (subValue, key3) { result.set( key3, baseClone$2(subValue, bitmask, customizer, key3, value2, stack) ) }) } var keysFunc = isFull ? isFlat ? getAllKeysIn$2 : getAllKeys$2 : isFlat ? keysIn$4 : keys$i var props2 = isArr ? void 0 : keysFunc(value2) arrayEach$h(props2 || value2, function (subValue, key3) { if (props2) { key3 = subValue subValue = value2[key3] } assignValue$3( result, key3, baseClone$2(subValue, bitmask, customizer, key3, value2, stack) ) }) return result } var CLONE_SYMBOLS_FLAG$2 = 4 function clone$b(value2) { return baseClone$2(value2, CLONE_SYMBOLS_FLAG$2) } var HASH_UNDEFINED$2 = '__lodash_hash_undefined__' function setCacheAdd(value2) { this.__data__.set(value2, HASH_UNDEFINED$2) return this } function setCacheHas(value2) { return this.__data__.has(value2) } function SetCache(values2) { var index2 = -1, length2 = values2 == null ? 0 : values2.length this.__data__ = new MapCache$2() while (++index2 < length2) { this.add(values2[index2]) } } SetCache.prototype.add = SetCache.prototype.push = setCacheAdd SetCache.prototype.has = setCacheHas function arraySome(array4, predicate) { var index2 = -1, length2 = array4 == null ? 0 : array4.length while (++index2 < length2) { if (predicate(array4[index2], index2, array4)) { return true } } return false } function cacheHas(cache2, key2) { return cache2.has(key2) } var COMPARE_PARTIAL_FLAG$3 = 1, COMPARE_UNORDERED_FLAG$1 = 2 function equalArrays(array4, other, bitmask, customizer, equalFunc, stack) { var isPartial = bitmask & COMPARE_PARTIAL_FLAG$3, arrLength = array4.length, othLength = other.length if (arrLength != othLength && !(isPartial && othLength > arrLength)) { return false } var arrStacked = stack.get(array4) var othStacked = stack.get(other) if (arrStacked && othStacked) { return arrStacked == other && othStacked == array4 } var index2 = -1, result = true, seen = bitmask & COMPARE_UNORDERED_FLAG$1 ? new SetCache() : void 0 stack.set(array4, other) stack.set(other, array4) while (++index2 < arrLength) { var arrValue = array4[index2], othValue = other[index2] if (customizer) { var compared = isPartial ? customizer(othValue, arrValue, index2, other, array4, stack) : customizer(arrValue, othValue, index2, array4, other, stack) } if (compared !== void 0) { if (compared) { continue } result = false break } if (seen) { if ( !arraySome(other, function (othValue2, othIndex) { if ( !cacheHas(seen, othIndex) && (arrValue === othValue2 || equalFunc(arrValue, othValue2, bitmask, customizer, stack)) ) { return seen.push(othIndex) } }) ) { result = false break } } else if ( !( arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack) ) ) { result = false break } } stack['delete'](array4) stack['delete'](other) return result } function mapToArray(map2) { var index2 = -1, result = Array(map2.size) map2.forEach(function (value2, key2) { result[++index2] = [key2, value2] }) return result } function setToArray(set2) { var index2 = -1, result = Array(set2.size) set2.forEach(function (value2) { result[++index2] = value2 }) return result } var COMPARE_PARTIAL_FLAG$2 = 1, COMPARE_UNORDERED_FLAG = 2 var boolTag$3 = '[object Boolean]', dateTag$3 = '[object Date]', errorTag$2 = '[object Error]', mapTag$5 = '[object Map]', numberTag$3 = '[object Number]', regexpTag$3 = '[object RegExp]', setTag$5 = '[object Set]', stringTag$3 = '[object String]', symbolTag$2 = '[object Symbol]' var arrayBufferTag$3 = '[object ArrayBuffer]', dataViewTag$4 = '[object DataView]' var symbolProto$1 = Symbol$8 ? Symbol$8.prototype : void 0, symbolValueOf$1 = symbolProto$1 ? symbolProto$1.valueOf : void 0 function equalByTag( object4, other, tag, bitmask, customizer, equalFunc, stack ) { switch (tag) { case dataViewTag$4: if ( object4.byteLength != other.byteLength || object4.byteOffset != other.byteOffset ) { return false } object4 = object4.buffer other = other.buffer case arrayBufferTag$3: if ( object4.byteLength != other.byteLength || !equalFunc(new Uint8Array$4(object4), new Uint8Array$4(other)) ) { return false } return true case boolTag$3: case dateTag$3: case numberTag$3: return eq$3(+object4, +other) case errorTag$2: return object4.name == other.name && object4.message == other.message case regexpTag$3: case stringTag$3: return object4 == other + '' case mapTag$5: var convert = mapToArray case setTag$5: var isPartial = bitmask & COMPARE_PARTIAL_FLAG$2 convert || (convert = setToArray) if (object4.size != other.size && !isPartial) { return false } var stacked = stack.get(object4) if (stacked) { return stacked == other } bitmask |= COMPARE_UNORDERED_FLAG stack.set(object4, other) var result = equalArrays( convert(object4), convert(other), bitmask, customizer, equalFunc, stack ) stack['delete'](object4) return result case symbolTag$2: if (symbolValueOf$1) { return symbolValueOf$1.call(object4) == symbolValueOf$1.call(other) } } return false } var COMPARE_PARTIAL_FLAG$1 = 1 var objectProto$e = Object.prototype var hasOwnProperty$f = objectProto$e.hasOwnProperty function equalObjects(object4, other, bitmask, customizer, equalFunc, stack) { var isPartial = bitmask & COMPARE_PARTIAL_FLAG$1, objProps = getAllKeys$2(object4), objLength = objProps.length, othProps = getAllKeys$2(other), othLength = othProps.length if (objLength != othLength && !isPartial) { return false } var index2 = objLength while (index2--) { var key2 = objProps[index2] if (!(isPartial ? key2 in other : hasOwnProperty$f.call(other, key2))) { return false } } var objStacked = stack.get(object4) var othStacked = stack.get(other) if (objStacked && othStacked) { return objStacked == other && othStacked == object4 } var result = true stack.set(object4, other) stack.set(other, object4) var skipCtor = isPartial while (++index2 < objLength) { key2 = objProps[index2] var objValue = object4[key2], othValue = other[key2] if (customizer) { var compared = isPartial ? customizer(othValue, objValue, key2, other, object4, stack) : customizer(objValue, othValue, key2, object4, other, stack) } if ( !(compared === void 0 ? objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack) : compared) ) { result = false break } skipCtor || (skipCtor = key2 == 'constructor') } if (result && !skipCtor) { var objCtor = object4.constructor, othCtor = other.constructor if ( objCtor != othCtor && 'constructor' in object4 && 'constructor' in other && !( typeof objCtor == 'function' && objCtor instanceof objCtor && typeof othCtor == 'function' && othCtor instanceof othCtor ) ) { result = false } } stack['delete'](object4) stack['delete'](other) return result } var COMPARE_PARTIAL_FLAG = 1 var argsTag$3 = '[object Arguments]', arrayTag$2 = '[object Array]', objectTag$3 = '[object Object]' var objectProto$d = Object.prototype var hasOwnProperty$e = objectProto$d.hasOwnProperty function baseIsEqualDeep( object4, other, bitmask, customizer, equalFunc, stack ) { var objIsArr = isArray$F(object4), othIsArr = isArray$F(other), objTag = objIsArr ? arrayTag$2 : getTag$5(object4), othTag = othIsArr ? arrayTag$2 : getTag$5(other) objTag = objTag == argsTag$3 ? objectTag$3 : objTag othTag = othTag == argsTag$3 ? objectTag$3 : othTag var objIsObj = objTag == objectTag$3, othIsObj = othTag == objectTag$3, isSameTag = objTag == othTag if (isSameTag && isBuffer$5(object4)) { if (!isBuffer$5(other)) { return false } objIsArr = true objIsObj = false } if (isSameTag && !objIsObj) { stack || (stack = new Stack$2()) return objIsArr || isTypedArray$4(object4) ? equalArrays(object4, other, bitmask, customizer, equalFunc, stack) : equalByTag( object4, other, objTag, bitmask, customizer, equalFunc, stack ) } if (!(bitmask & COMPARE_PARTIAL_FLAG)) { var objIsWrapped = objIsObj && hasOwnProperty$e.call(object4, '__wrapped__'), othIsWrapped = othIsObj && hasOwnProperty$e.call(other, '__wrapped__') if (objIsWrapped || othIsWrapped) { var objUnwrapped = objIsWrapped ? object4.value() : object4, othUnwrapped = othIsWrapped ? other.value() : other stack || (stack = new Stack$2()) return equalFunc(objUnwrapped, othUnwrapped, bitmask, customizer, stack) } } if (!isSameTag) { return false } stack || (stack = new Stack$2()) return equalObjects(object4, other, bitmask, customizer, equalFunc, stack) } function baseIsEqual(value2, other, bitmask, customizer, stack) { if (value2 === other) { return true } if ( value2 == null || other == null || (!isObjectLike$6(value2) && !isObjectLike$6(other)) ) { return value2 !== value2 && other !== other } return baseIsEqualDeep(value2, other, bitmask, customizer, baseIsEqual, stack) } function baseHasIn(object4, key2) { return object4 != null && key2 in Object(object4) } function hasPath(object4, path, hasFunc) { path = castPath(path, object4) var index2 = -1, length2 = path.length, result = false while (++index2 < length2) { var key2 = toKey(path[index2]) if (!(result = object4 != null && hasFunc(object4, key2))) { break } object4 = object4[key2] } if (result || ++index2 != length2) { return result } length2 = object4 == null ? 0 : object4.length return ( !!length2 && isLength$4(length2) && isIndex$2(key2, length2) && (isArray$F(object4) || isArguments$5(object4)) ) } function hasIn(object4, path) { return object4 != null && hasPath(object4, path, baseHasIn) } var now$7 = function () { return root$b.Date.now() } var now$8 = now$7 var FUNC_ERROR_TEXT$1 = 'Expected a function' var nativeMax = Math.max, nativeMin = Math.min function debounce$3(func, wait, options2) { var lastArgs, lastThis, maxWait, result, timerId, lastCallTime, lastInvokeTime = 0, leading = false, maxing = false, trailing = true if (typeof func != 'function') { throw new TypeError(FUNC_ERROR_TEXT$1) } wait = toNumber$8(wait) || 0 if (isObject$x(options2)) { leading = !!options2.leading maxing = 'maxWait' in options2 maxWait = maxing ? nativeMax(toNumber$8(options2.maxWait) || 0, wait) : maxWait trailing = 'trailing' in options2 ? !!options2.trailing : trailing } function invokeFunc(time2) { var args = lastArgs, thisArg = lastThis lastArgs = lastThis = void 0 lastInvokeTime = time2 result = func.apply(thisArg, args) return result } function leadingEdge(time2) { lastInvokeTime = time2 timerId = setTimeout(timerExpired, wait) return leading ? invokeFunc(time2) : result } function remainingWait(time2) { var timeSinceLastCall = time2 - lastCallTime, timeSinceLastInvoke = time2 - lastInvokeTime, timeWaiting = wait - timeSinceLastCall return maxing ? nativeMin(timeWaiting, maxWait - timeSinceLastInvoke) : timeWaiting } function shouldInvoke(time2) { var timeSinceLastCall = time2 - lastCallTime, timeSinceLastInvoke = time2 - lastInvokeTime return ( lastCallTime === void 0 || timeSinceLastCall >= wait || timeSinceLastCall < 0 || (maxing && timeSinceLastInvoke >= maxWait) ) } function timerExpired() { var time2 = now$8() if (shouldInvoke(time2)) { return trailingEdge(time2) } timerId = setTimeout(timerExpired, remainingWait(time2)) } function trailingEdge(time2) { timerId = void 0 if (trailing && lastArgs) { return invokeFunc(time2) } lastArgs = lastThis = void 0 return result } function cancel2() { if (timerId !== void 0) { clearTimeout(timerId) } lastInvokeTime = 0 lastArgs = lastCallTime = lastThis = timerId = void 0 } function flush2() { return timerId === void 0 ? result : trailingEdge(now$8()) } function debounced() { var time2 = now$8(), isInvoking = shouldInvoke(time2) lastArgs = arguments lastThis = this lastCallTime = time2 if (isInvoking) { if (timerId === void 0) { return leadingEdge(lastCallTime) } if (maxing) { clearTimeout(timerId) timerId = setTimeout(timerExpired, wait) return invokeFunc(lastCallTime) } } if (timerId === void 0) { timerId = setTimeout(timerExpired, wait) } return result } debounced.cancel = cancel2 debounced.flush = flush2 return debounced } function isArrayLikeObject(value2) { return isObjectLike$6(value2) && isArrayLike$4(value2) } function arrayIncludesWith(array4, value2, comparator) { var index2 = -1, length2 = array4 == null ? 0 : array4.length while (++index2 < length2) { if (comparator(value2, array4[index2])) { return true } } return false } var INFINITY$1 = 1 / 0 function flattenDeep$1(array4) { var length2 = array4 == null ? 0 : array4.length return length2 ? baseFlatten(array4, INFINITY$1) : [] } function fromPairs(pairs) { var index2 = -1, length2 = pairs == null ? 0 : pairs.length, result = {} while (++index2 < length2) { var pair = pairs[index2] result[pair[0]] = pair[1] } return result } function isEqual$4(value2, other) { return baseIsEqual(value2, other) } function isNil$1(value2) { return value2 == null } function baseSet(object4, path, value2, customizer) { if (!isObject$x(object4)) { return object4 } path = castPath(path, object4) var index2 = -1, length2 = path.length, lastIndex = length2 - 1, nested = object4 while (nested != null && ++index2 < length2) { var key2 = toKey(path[index2]), newValue = value2 if ( key2 === '__proto__' || key2 === 'constructor' || key2 === 'prototype' ) { return object4 } if (index2 != lastIndex) { var objValue = nested[key2] newValue = customizer ? customizer(objValue, key2, nested) : void 0 if (newValue === void 0) { newValue = isObject$x(objValue) ? objValue : isIndex$2(path[index2 + 1]) ? [] : {} } } assignValue$3(nested, key2, newValue) nested = nested[key2] } return object4 } function basePickBy(object4, paths, predicate) { var index2 = -1, length2 = paths.length, result = {} while (++index2 < length2) { var path = paths[index2], value2 = baseGet(object4, path) if (predicate(value2, path)) { baseSet(result, castPath(path, object4), value2) } } return result } function basePick(object4, paths) { return basePickBy(object4, paths, function (value2, path) { return hasIn(object4, path) }) } var pick$2 = flatRest(function (object4, paths) { return object4 == null ? {} : basePick(object4, paths) }) var pick$3 = pick$2 function set$8(object4, path, value2) { return object4 == null ? object4 : baseSet(object4, path, value2) } var FUNC_ERROR_TEXT = 'Expected a function' function throttle$4(func, wait, options2) { var leading = true, trailing = true if (typeof func != 'function') { throw new TypeError(FUNC_ERROR_TEXT) } if (isObject$x(options2)) { leading = 'leading' in options2 ? !!options2.leading : leading trailing = 'trailing' in options2 ? !!options2.trailing : trailing } return debounce$3(func, wait, { leading: leading, maxWait: wait, trailing: trailing, }) } var INFINITY = 1 / 0 var createSet = !(Set$4 && 1 / setToArray(new Set$4([, -0]))[1] == INFINITY) ? noop$8 : function (values2) { return new Set$4(values2) } var createSet$1 = createSet var LARGE_ARRAY_SIZE$1 = 200 function baseUniq(array4, iteratee, comparator) { var index2 = -1, includes3 = arrayIncludes$1, length2 = array4.length, isCommon = true, result = [], seen = result if (comparator) { isCommon = false includes3 = arrayIncludesWith } else if (length2 >= LARGE_ARRAY_SIZE$1) { var set2 = iteratee ? null : createSet$1(array4) if (set2) { return setToArray(set2) } isCommon = false includes3 = cacheHas seen = new SetCache() } else { seen = iteratee ? [] : result } outer: while (++index2 < length2) { var value2 = array4[index2], computed2 = iteratee ? iteratee(value2) : value2 value2 = comparator || value2 !== 0 ? value2 : 0 if (isCommon && computed2 === computed2) { var seenIndex = seen.length while (seenIndex--) { if (seen[seenIndex] === computed2) { continue outer } } if (iteratee) { seen.push(computed2) } result.push(value2) } else if (!includes3(seen, computed2, comparator)) { if (seen !== result) { seen.push(computed2) } result.push(value2) } } return result } var union$2 = baseRest(function (arrays) { return baseUniq(baseFlatten(arrays, 1, isArrayLikeObject, true)) }) var union$3 = union$2 const FOCUSABLE_ELEMENT_SELECTORS = `a[href],button:not([disabled]),button:not([hidden]),:not([tabindex="-1"]),input:not([disabled]),input:not([type="hidden"]),select:not([disabled]),textarea:not([disabled])` const isVisible = (element) => { const computed2 = getComputedStyle(element) return computed2.position === 'fixed' ? false : element.offsetParent !== null } const obtainAllFocusableElements$1 = (element) => { return Array.from( element.querySelectorAll(FOCUSABLE_ELEMENT_SELECTORS) ).filter((item2) => isFocusable(item2) && isVisible(item2)) } const isFocusable = (element) => { if ( element.tabIndex > 0 || (element.tabIndex === 0 && element.getAttribute('tabIndex') !== null) ) { return true } if (element.disabled) { return false } switch (element.nodeName) { case 'A': { return !!element.href && element.rel !== 'ignore' } case 'INPUT': { return !(element.type === 'hidden' || element.type === 'file') } case 'BUTTON': case 'SELECT': case 'TEXTAREA': { return true } default: { return false } } } const triggerEvent$1 = function (elm, name2, ...opts) { let eventName if (name2.includes('mouse') || name2.includes('click')) { eventName = 'MouseEvents' } else if (name2.includes('key')) { eventName = 'KeyboardEvent' } else { eventName = 'HTMLEvents' } const evt = document.createEvent(eventName) evt.initEvent(name2, ...opts) elm.dispatchEvent(evt) return elm } const isLeaf = (el2) => !el2.getAttribute('aria-owns') const getSibling = (el2, distance2, elClass) => { const { parentNode: parentNode2 } = el2 if (!parentNode2) return null const siblings = parentNode2.querySelectorAll(elClass) const index2 = Array.prototype.indexOf.call(siblings, el2) return siblings[index2 + distance2] || null } const focusNode = (el2) => { if (!el2) return el2.focus() !isLeaf(el2) && el2.click() } const on$2 = (element, event, handler, useCapture = false) => { if (element && event && handler) { element == null ? void 0 : element.addEventListener(event, handler, useCapture) } } const off$1 = (element, event, handler, useCapture = false) => { if (element && event && handler) { element == null ? void 0 : element.removeEventListener(event, handler, useCapture) } } const once$2 = (el2, event, fn2) => { const listener = function (...args) { if (fn2) { fn2.apply(this, args) } off$1(el2, event, listener) } on$2(el2, event, listener) } const composeEventHandlers = ( theirsHandler, oursHandler, { checkForDefaultPrevented = true } = {} ) => { const handleEvent2 = (event) => { const shouldPrevent = theirsHandler == null ? void 0 : theirsHandler(event) if (checkForDefaultPrevented === false || !shouldPrevent) { return oursHandler == null ? void 0 : oursHandler(event) } } return handleEvent2 } const whenMouse = (handler) => { return (e2) => (e2.pointerType === 'mouse' ? handler(e2) : void 0) } var __defProp$9$2 = Object.defineProperty var __defProps$6$2 = Object.defineProperties var __getOwnPropDescs$6$2 = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$b$2 = Object.getOwnPropertySymbols var __hasOwnProp$b$2 = Object.prototype.hasOwnProperty var __propIsEnum$b$2 = Object.prototype.propertyIsEnumerable var __defNormalProp$9$2 = (obj, key2, value2) => key2 in obj ? __defProp$9$2(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$9$2 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$b$2.call(b2, prop)) __defNormalProp$9$2(a2, prop, b2[prop]) if (__getOwnPropSymbols$b$2) for (var prop of __getOwnPropSymbols$b$2(b2)) { if (__propIsEnum$b$2.call(b2, prop)) __defNormalProp$9$2(a2, prop, b2[prop]) } return a2 } var __spreadProps$6$2 = (a2, b2) => __defProps$6$2(a2, __getOwnPropDescs$6$2(b2)) function computedEager$1(fn2, options2) { var _a2 const result = shallowRef() watchEffect( () => { result.value = fn2() }, __spreadProps$6$2(__spreadValues$9$2({}, options2), { flush: (_a2 = options2 == null ? void 0 : options2.flush) != null ? _a2 : 'sync', }) ) return readonly(result) } var _a$4 const isClient$1 = typeof window !== 'undefined' const isDef$2 = (val2) => typeof val2 !== 'undefined' const assert$2 = (condition2, ...infos) => { if (!condition2) console.warn(...infos) } const toString$e = Object.prototype.toString const isBoolean$5 = (val2) => typeof val2 === 'boolean' const isFunction$m = (val2) => typeof val2 === 'function' const isNumber$h = (val2) => typeof val2 === 'number' const isString$g = (val2) => typeof val2 === 'string' const isObject$w = (val2) => toString$e.call(val2) === '[object Object]' const isWindow$3 = (val2) => typeof window !== 'undefined' && toString$e.call(val2) === '[object Window]' const now$6 = () => Date.now() const timestamp$3 = () => +Date.now() const clamp$2 = (n2, min3, max3) => Math.min(max3, Math.max(min3, n2)) const noop$7 = () => {} const rand$1 = (min3, max3) => { min3 = Math.ceil(min3) max3 = Math.floor(max3) return Math.floor(Math.random() * (max3 - min3 + 1)) + min3 } const isIOS$1 = isClient$1 && ((_a$4 = window == null ? void 0 : window.navigator) == null ? void 0 : _a$4.userAgent) && /iP(ad|hone|od)/.test(window.navigator.userAgent) function createFilterWrapper$1(filter2, fn2) { function wrapper(...args) { filter2(() => fn2.apply(this, args), { fn: fn2, thisArg: this, args }) } return wrapper } const bypassFilter$1 = (invoke2) => { return invoke2() } function debounceFilter$1(ms, options2 = {}) { let timer2 let maxTimer const filter2 = (invoke2) => { const duration2 = unref(ms) const maxDuration = unref(options2.maxWait) if (timer2) clearTimeout(timer2) if (duration2 <= 0 || (maxDuration !== void 0 && maxDuration <= 0)) { if (maxTimer) { clearTimeout(maxTimer) maxTimer = null } return invoke2() } if (maxDuration && !maxTimer) { maxTimer = setTimeout(() => { if (timer2) clearTimeout(timer2) maxTimer = null invoke2() }, maxDuration) } timer2 = setTimeout(() => { if (maxTimer) clearTimeout(maxTimer) maxTimer = null invoke2() }, duration2) } return filter2 } function throttleFilter$1(ms, trailing = true, leading = true) { let lastExec = 0 let timer2 let isLeading = true const clear2 = () => { if (timer2) { clearTimeout(timer2) timer2 = void 0 } } const filter2 = (invoke2) => { const duration2 = unref(ms) const elapsed = Date.now() - lastExec clear2() if (duration2 <= 0) { lastExec = Date.now() return invoke2() } if (elapsed > duration2 && (leading || !isLeading)) { lastExec = Date.now() invoke2() } else if (trailing) { timer2 = setTimeout(() => { lastExec = Date.now() isLeading = true clear2() invoke2() }, duration2) } if (!leading && !timer2) timer2 = setTimeout(() => (isLeading = true), duration2) isLeading = false } return filter2 } function pausableFilter$1(extendFilter = bypassFilter$1) { const isActive = ref(true) function pause() { isActive.value = false } function resume() { isActive.value = true } const eventFilter = (...args) => { if (isActive.value) extendFilter(...args) } return { isActive, pause, resume, eventFilter } } function __onlyVue3$1(name2 = 'this function') { return } const directiveHooks$1 = { mounted: 'mounted', updated: 'updated', unmounted: 'unmounted', } function promiseTimeout$1(ms, throwOnTimeout = false, reason = 'Timeout') { return new Promise((resolve2, reject2) => { if (throwOnTimeout) setTimeout(() => reject2(reason), ms) else setTimeout(resolve2, ms) }) } function identity$2(arg) { return arg } function createSingletonPromise$1(fn2) { let _promise function wrapper() { if (!_promise) _promise = fn2() return _promise } wrapper.reset = async () => { const _prev = _promise _promise = void 0 if (_prev) await _prev } return wrapper } function invoke$3(fn2) { return fn2() } function containsProp$1(obj, ...props2) { return props2.some((k2) => k2 in obj) } function increaseWithUnit$1(target2, delta) { var _a2 if (typeof target2 === 'number') return target2 + delta const value2 = ((_a2 = target2.match(/^-?[0-9]+\.?[0-9]*/)) == null ? void 0 : _a2[0]) || '' const unit = target2.slice(value2.length) const result = parseFloat(value2) + delta if (Number.isNaN(result)) return target2 return result + unit } function objectPick$1(obj, keys3, omitUndefined = false) { return keys3.reduce((n2, k2) => { if (k2 in obj) { if (!omitUndefined || obj[k2] !== void 0) n2[k2] = obj[k2] } return n2 }, {}) } function computedWithControl$1(source2, fn2) { let v4 = void 0 let track2 let trigger2 const dirty = ref(true) const update3 = () => { dirty.value = true trigger2() } watch$1(source2, update3, { flush: 'sync' }) const get3 = isFunction$m(fn2) ? fn2 : fn2.get const set2 = isFunction$m(fn2) ? void 0 : fn2.set const result = customRef((_track, _trigger) => { track2 = _track trigger2 = _trigger return { get() { if (dirty.value) { v4 = get3() dirty.value = false } track2() return v4 }, set(v22) { set2 == null ? void 0 : set2(v22) }, } }) if (Object.isExtensible(result)) result.trigger = update3 return result } function createEventHook$1() { const fns = [] const off2 = (fn2) => { const index2 = fns.indexOf(fn2) if (index2 !== -1) fns.splice(index2, 1) } const on2 = (fn2) => { fns.push(fn2) return { off: () => off2(fn2), } } const trigger2 = (param) => { fns.forEach((fn2) => fn2(param)) } return { on: on2, off: off2, trigger: trigger2, } } function createGlobalState$1(stateFactory) { let initialized = false let state2 const scope = effectScope(true) return () => { if (!initialized) { state2 = scope.run(stateFactory) initialized = true } return state2 } } function createInjectionState$1(composable) { const key2 = Symbol('InjectionState') const useProvidingState = (...args) => { provide(key2, composable(...args)) } const useInjectedState = () => inject(key2) return [useProvidingState, useInjectedState] } function tryOnScopeDispose$1(fn2) { if (getCurrentScope()) { onScopeDispose(fn2) return true } return false } function createSharedComposable$1(composable) { let subscribers = 0 let state2 let scope const dispose2 = () => { subscribers -= 1 if (scope && subscribers <= 0) { scope.stop() state2 = void 0 scope = void 0 } } return (...args) => { subscribers += 1 if (!state2) { scope = effectScope(true) state2 = scope.run(() => composable(...args)) } tryOnScopeDispose$1(dispose2) return state2 } } function extendRef$1( ref2, extend2, { enumerable: enumerable4 = false, unwrap = true } = {} ) { for (const [key2, value2] of Object.entries(extend2)) { if (key2 === 'value') continue if (isRef(value2) && unwrap) { Object.defineProperty(ref2, key2, { get() { return value2.value }, set(v4) { value2.value = v4 }, enumerable: enumerable4, }) } else { Object.defineProperty(ref2, key2, { value: value2, enumerable: enumerable4, }) } } return ref2 } function get$9(obj, key2) { if (key2 == null) return unref(obj) return unref(obj)[key2] } function isDefined$1(v4) { return unref(v4) != null } function logicAnd(...args) { return computed(() => args.every((i2) => unref(i2))) } function logicNot(v4) { return computed(() => !unref(v4)) } function logicOr(...args) { return computed(() => args.some((i2) => unref(i2))) } var __defProp$8$2 = Object.defineProperty var __getOwnPropSymbols$a$2 = Object.getOwnPropertySymbols var __hasOwnProp$a$2 = Object.prototype.hasOwnProperty var __propIsEnum$a$2 = Object.prototype.propertyIsEnumerable var __defNormalProp$8$2 = (obj, key2, value2) => key2 in obj ? __defProp$8$2(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$8$2 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$a$2.call(b2, prop)) __defNormalProp$8$2(a2, prop, b2[prop]) if (__getOwnPropSymbols$a$2) for (var prop of __getOwnPropSymbols$a$2(b2)) { if (__propIsEnum$a$2.call(b2, prop)) __defNormalProp$8$2(a2, prop, b2[prop]) } return a2 } function makeDestructurable$1(obj, arr) { if (typeof Symbol !== 'undefined') { const clone2 = __spreadValues$8$2({}, obj) Object.defineProperty(clone2, Symbol.iterator, { enumerable: false, value() { let index2 = 0 return { next: () => ({ value: arr[index2++], done: index2 > arr.length, }), } }, }) return clone2 } else { return Object.assign([...arr], obj) } } function reactify$1(fn2) { return function (...args) { return computed(() => fn2.apply( this, args.map((i2) => unref(i2)) ) ) } } function reactifyObject$1(obj, optionsOrKeys = {}) { let keys3 = [] if (Array.isArray(optionsOrKeys)) { keys3 = optionsOrKeys } else { const { includeOwnProperties = true } = optionsOrKeys keys3.push(...Object.keys(obj)) if (includeOwnProperties) keys3.push(...Object.getOwnPropertyNames(obj)) } return Object.fromEntries( keys3.map((key2) => { const value2 = obj[key2] return [ key2, typeof value2 === 'function' ? reactify$1(value2.bind(obj)) : value2, ] }) ) } function toReactive$1(objectRef) { if (!isRef(objectRef)) return reactive(objectRef) const proxy = new Proxy( {}, { get(_2, p2, receiver) { return unref(Reflect.get(objectRef.value, p2, receiver)) }, set(_2, p2, value2) { if (isRef(objectRef.value[p2]) && !isRef(value2)) objectRef.value[p2].value = value2 else objectRef.value[p2] = value2 return true }, deleteProperty(_2, p2) { return Reflect.deleteProperty(objectRef.value, p2) }, has(_2, p2) { return Reflect.has(objectRef.value, p2) }, ownKeys() { return Object.keys(objectRef.value) }, getOwnPropertyDescriptor() { return { enumerable: true, configurable: true, } }, } ) return reactive(proxy) } function reactiveComputed$1(fn2) { return toReactive$1(computed(fn2)) } function reactiveOmit$1(obj, ...keys3) { const flatKeys = keys3.flat() return reactiveComputed$1(() => Object.fromEntries( Object.entries(toRefs$2(obj)).filter((e2) => !flatKeys.includes(e2[0])) ) ) } function reactivePick$1(obj, ...keys3) { const flatKeys = keys3.flat() return reactive( Object.fromEntries(flatKeys.map((k2) => [k2, toRef(obj, k2)])) ) } function refAutoReset$1(defaultValue, afterMs = 1e4) { return customRef((track2, trigger2) => { let value2 = defaultValue let timer2 const resetAfter = () => setTimeout(() => { value2 = defaultValue trigger2() }, unref(afterMs)) tryOnScopeDispose$1(() => { clearTimeout(timer2) }) return { get() { track2() return value2 }, set(newValue) { value2 = newValue trigger2() clearTimeout(timer2) timer2 = resetAfter() }, } }) } function useDebounceFn$1(fn2, ms = 200, options2 = {}) { return createFilterWrapper$1(debounceFilter$1(ms, options2), fn2) } function refDebounced$1(value2, ms = 200, options2 = {}) { if (ms <= 0) return value2 const debounced = ref(value2.value) const updater = useDebounceFn$1( () => { debounced.value = value2.value }, ms, options2 ) watch$1(value2, () => updater()) return debounced } function refDefault$1(source2, defaultValue) { return computed({ get() { var _a2 return (_a2 = source2.value) != null ? _a2 : defaultValue }, set(value2) { source2.value = value2 }, }) } function useThrottleFn$1(fn2, ms = 200, trailing = true, leading = true) { return createFilterWrapper$1(throttleFilter$1(ms, trailing, leading), fn2) } function refThrottled$1(value2, delay2 = 200, trailing = true, leading = true) { if (delay2 <= 0) return value2 const throttled = ref(value2.value) const updater = useThrottleFn$1( () => { throttled.value = value2.value }, delay2, trailing, leading ) watch$1(value2, () => updater()) return throttled } function refWithControl$1(initial, options2 = {}) { let source2 = initial let track2 let trigger2 const ref2 = customRef((_track, _trigger) => { track2 = _track trigger2 = _trigger return { get() { return get3() }, set(v4) { set2(v4) }, } }) function get3(tracking = true) { if (tracking) track2() return source2 } function set2(value2, triggering = true) { var _a2, _b2 if (value2 === source2) return const old = source2 if ( ((_a2 = options2.onBeforeChange) == null ? void 0 : _a2.call(options2, value2, old)) === false ) return source2 = value2 ;(_b2 = options2.onChanged) == null ? void 0 : _b2.call(options2, value2, old) if (triggering) trigger2() } const untrackedGet = () => get3(false) const silentSet = (v4) => set2(v4, false) const peek = () => get3(false) const lay = (v4) => set2(v4, false) return extendRef$1( ref2, { get: get3, set: set2, untrackedGet, silentSet, peek, lay, }, { enumerable: true } ) } const controlledRef$1 = refWithControl$1 function resolveRef$1(r2) { return typeof r2 === 'function' ? computed(r2) : ref(r2) } function resolveUnref$1(r2) { return typeof r2 === 'function' ? r2() : unref(r2) } function set$7(...args) { if (args.length === 2) { const [ref2, value2] = args ref2.value = value2 } if (args.length === 3) { { const [target2, key2, value2] = args target2[key2] = value2 } } } function syncRef$1(left2, right2, options2 = {}) { const { flush: flush2 = 'sync', deep = false, immediate = true, direction: direction2 = 'both', } = options2 let stop1, stop2 if (direction2 === 'both' || direction2 === 'ltr') { stop1 = watch$1(left2, (newValue) => (right2.value = newValue), { flush: flush2, deep, immediate, }) } if (direction2 === 'both' || direction2 === 'rtl') { stop2 = watch$1(right2, (newValue) => (left2.value = newValue), { flush: flush2, deep, immediate, }) } return () => { stop1 == null ? void 0 : stop1() stop2 == null ? void 0 : stop2() } } function syncRefs$1(source2, targets, options2 = {}) { const { flush: flush2 = 'sync', deep = false, immediate = true } = options2 if (!Array.isArray(targets)) targets = [targets] return watch$1( source2, (newValue) => targets.forEach((target2) => (target2.value = newValue)), { flush: flush2, deep, immediate } ) } var __defProp$7$2 = Object.defineProperty var __defProps$5$2 = Object.defineProperties var __getOwnPropDescs$5$2 = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$9$2 = Object.getOwnPropertySymbols var __hasOwnProp$9$2 = Object.prototype.hasOwnProperty var __propIsEnum$9$2 = Object.prototype.propertyIsEnumerable var __defNormalProp$7$2 = (obj, key2, value2) => key2 in obj ? __defProp$7$2(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$7$2 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$9$2.call(b2, prop)) __defNormalProp$7$2(a2, prop, b2[prop]) if (__getOwnPropSymbols$9$2) for (var prop of __getOwnPropSymbols$9$2(b2)) { if (__propIsEnum$9$2.call(b2, prop)) __defNormalProp$7$2(a2, prop, b2[prop]) } return a2 } var __spreadProps$5$2 = (a2, b2) => __defProps$5$2(a2, __getOwnPropDescs$5$2(b2)) function toRefs$1(objectRef) { if (!isRef(objectRef)) return toRefs$2(objectRef) const result = Array.isArray(objectRef.value) ? new Array(objectRef.value.length) : {} for (const key2 in objectRef.value) { result[key2] = customRef(() => ({ get() { return objectRef.value[key2] }, set(v4) { if (Array.isArray(objectRef.value)) { const copy2 = [...objectRef.value] copy2[key2] = v4 objectRef.value = copy2 } else { const newObject = __spreadProps$5$2( __spreadValues$7$2({}, objectRef.value), { [key2]: v4 } ) Object.setPrototypeOf(newObject, objectRef.value) objectRef.value = newObject } }, })) } return result } function tryOnBeforeMount$1(fn2, sync = true) { if (getCurrentInstance()) onBeforeMount(fn2) else if (sync) fn2() else nextTick(fn2) } function tryOnBeforeUnmount$1(fn2) { if (getCurrentInstance()) onBeforeUnmount(fn2) } function tryOnMounted$1(fn2, sync = true) { if (getCurrentInstance()) onMounted(fn2) else if (sync) fn2() else nextTick(fn2) } function tryOnUnmounted$1(fn2) { if (getCurrentInstance()) onUnmounted(fn2) } function until$1(r2) { let isNot = false function toMatch( condition2, { flush: flush2 = 'sync', deep = false, timeout, throwOnTimeout } = {} ) { let stop2 = null const watcher = new Promise((resolve2) => { stop2 = watch$1( r2, (v4) => { if (condition2(v4) !== isNot) { stop2 == null ? void 0 : stop2() resolve2(v4) } }, { flush: flush2, deep, immediate: true, } ) }) const promises = [watcher] if (timeout != null) { promises.push( promiseTimeout$1(timeout, throwOnTimeout) .then(() => unref(r2)) .finally(() => (stop2 == null ? void 0 : stop2())) ) } return Promise.race(promises) } function toBe(value2, options2) { if (!isRef(value2)) return toMatch((v4) => v4 === value2, options2) const { flush: flush2 = 'sync', deep = false, timeout, throwOnTimeout, } = options2 != null ? options2 : {} let stop2 = null const watcher = new Promise((resolve2) => { stop2 = watch$1( [r2, value2], ([v12, v22]) => { if (isNot !== (v12 === v22)) { stop2 == null ? void 0 : stop2() resolve2(v12) } }, { flush: flush2, deep, immediate: true, } ) }) const promises = [watcher] if (timeout != null) { promises.push( promiseTimeout$1(timeout, throwOnTimeout) .then(() => unref(r2)) .finally(() => { stop2 == null ? void 0 : stop2() return unref(r2) }) ) } return Promise.race(promises) } function toBeTruthy(options2) { return toMatch((v4) => Boolean(v4), options2) } function toBeNull(options2) { return toBe(null, options2) } function toBeUndefined(options2) { return toBe(void 0, options2) } function toBeNaN(options2) { return toMatch(Number.isNaN, options2) } function toContains(value2, options2) { return toMatch((v4) => { const array4 = Array.from(v4) return array4.includes(value2) || array4.includes(unref(value2)) }, options2) } function changed(options2) { return changedTimes(1, options2) } function changedTimes(n2 = 1, options2) { let count2 = -1 return toMatch(() => { count2 += 1 return count2 >= n2 }, options2) } if (Array.isArray(unref(r2))) { const instance = { toMatch, toContains, changed, changedTimes, get not() { isNot = !isNot return this }, } return instance } else { const instance = { toMatch, toBe, toBeTruthy, toBeNull, toBeNaN, toBeUndefined, changed, changedTimes, get not() { isNot = !isNot return this }, } return instance } } function useCounter$1(initialValue = 0, options2 = {}) { const count2 = ref(initialValue) const { max: max3 = Infinity, min: min3 = -Infinity } = options2 const inc2 = (delta = 1) => (count2.value = Math.min(max3, count2.value + delta)) const dec = (delta = 1) => (count2.value = Math.max(min3, count2.value - delta)) const get3 = () => count2.value const set2 = (val2) => (count2.value = val2) const reset2 = (val2 = initialValue) => { initialValue = val2 return set2(val2) } return { count: count2, inc: inc2, dec, get: get3, set: set2, reset: reset2 } } const REGEX_PARSE$1 = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/ const REGEX_FORMAT$1 = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g const formatDate$2 = (date4, formatStr) => { const years = date4.getFullYear() const month = date4.getMonth() const days = date4.getDate() const hours = date4.getHours() const minutes = date4.getMinutes() const seconds = date4.getSeconds() const milliseconds = date4.getMilliseconds() const day = date4.getDay() const matches2 = { YY: String(years).slice(-2), YYYY: years, M: month + 1, MM: `${month + 1}`.padStart(2, '0'), D: String(days), DD: `${days}`.padStart(2, '0'), H: String(hours), HH: `${hours}`.padStart(2, '0'), h: `${hours % 12 || 12}`.padStart(1, '0'), hh: `${hours % 12 || 12}`.padStart(2, '0'), m: String(minutes), mm: `${minutes}`.padStart(2, '0'), s: String(seconds), ss: `${seconds}`.padStart(2, '0'), SSS: `${milliseconds}`.padStart(3, '0'), d: day, } return formatStr.replace( REGEX_FORMAT$1, (match2, $1) => $1 || matches2[match2] ) } const normalizeDate$1 = (date4) => { if (date4 === null) return new Date(NaN) if (date4 === void 0) return new Date() if (date4 instanceof Date) return new Date(date4) if (typeof date4 === 'string' && !/Z$/i.test(date4)) { const d3 = date4.match(REGEX_PARSE$1) if (d3) { const m2 = d3[2] - 1 || 0 const ms = (d3[7] || '0').substring(0, 3) return new Date( d3[1], m2, d3[3] || 1, d3[4] || 0, d3[5] || 0, d3[6] || 0, ms ) } } return new Date(date4) } function useDateFormat$1(date4, formatStr = 'HH:mm:ss') { return computed(() => formatDate$2(normalizeDate$1(unref(date4)), unref(formatStr)) ) } function useIntervalFn$1(cb, interval = 1e3, options2 = {}) { const { immediate = true, immediateCallback = false } = options2 let timer2 = null const isActive = ref(false) function clean() { if (timer2) { clearInterval(timer2) timer2 = null } } function pause() { isActive.value = false clean() } function resume() { if (unref(interval) <= 0) return isActive.value = true if (immediateCallback) cb() clean() timer2 = setInterval(cb, unref(interval)) } if (immediate && isClient$1) resume() if (isRef(interval)) { const stopWatch = watch$1(interval, () => { if (isActive.value && isClient$1) resume() }) tryOnScopeDispose$1(stopWatch) } tryOnScopeDispose$1(pause) return { isActive, pause, resume, } } var __defProp$6$2 = Object.defineProperty var __getOwnPropSymbols$8$2 = Object.getOwnPropertySymbols var __hasOwnProp$8$2 = Object.prototype.hasOwnProperty var __propIsEnum$8$2 = Object.prototype.propertyIsEnumerable var __defNormalProp$6$2 = (obj, key2, value2) => key2 in obj ? __defProp$6$2(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$6$2 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$8$2.call(b2, prop)) __defNormalProp$6$2(a2, prop, b2[prop]) if (__getOwnPropSymbols$8$2) for (var prop of __getOwnPropSymbols$8$2(b2)) { if (__propIsEnum$8$2.call(b2, prop)) __defNormalProp$6$2(a2, prop, b2[prop]) } return a2 } function useInterval$1(interval = 1e3, options2 = {}) { const { controls: exposeControls = false, immediate = true } = options2 const counter2 = ref(0) const controls = useIntervalFn$1(() => (counter2.value += 1), interval, { immediate, }) if (exposeControls) { return __spreadValues$6$2( { counter: counter2, }, controls ) } else { return counter2 } } function useLastChanged$1(source2, options2 = {}) { var _a2 const ms = ref((_a2 = options2.initialValue) != null ? _a2 : null) watch$1(source2, () => (ms.value = timestamp$3()), options2) return ms } function useTimeoutFn$1(cb, interval, options2 = {}) { const { immediate = true } = options2 const isPending = ref(false) let timer2 = null function clear2() { if (timer2) { clearTimeout(timer2) timer2 = null } } function stop2() { isPending.value = false clear2() } function start2(...args) { clear2() isPending.value = true timer2 = setTimeout(() => { isPending.value = false timer2 = null cb(...args) }, unref(interval)) } if (immediate) { isPending.value = true if (isClient$1) start2() } tryOnScopeDispose$1(stop2) return { isPending, start: start2, stop: stop2, } } var __defProp$5$2 = Object.defineProperty var __getOwnPropSymbols$7$2 = Object.getOwnPropertySymbols var __hasOwnProp$7$2 = Object.prototype.hasOwnProperty var __propIsEnum$7$2 = Object.prototype.propertyIsEnumerable var __defNormalProp$5$2 = (obj, key2, value2) => key2 in obj ? __defProp$5$2(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$5$2 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$7$2.call(b2, prop)) __defNormalProp$5$2(a2, prop, b2[prop]) if (__getOwnPropSymbols$7$2) for (var prop of __getOwnPropSymbols$7$2(b2)) { if (__propIsEnum$7$2.call(b2, prop)) __defNormalProp$5$2(a2, prop, b2[prop]) } return a2 } function useTimeout$2(interval = 1e3, options2 = {}) { const { controls: exposeControls = false } = options2 const controls = useTimeoutFn$1(noop$7, interval, options2) const ready = computed(() => !controls.isPending.value) if (exposeControls) { return __spreadValues$5$2( { ready, }, controls ) } else { return ready } } function useToggle$1(initialValue = false, options2 = {}) { const { truthyValue = true, falsyValue = false } = options2 const valueIsRef = isRef(initialValue) const innerValue = ref(initialValue) function toggle2(value2) { if (arguments.length) { innerValue.value = value2 return innerValue.value } else { innerValue.value = innerValue.value === unref(truthyValue) ? unref(falsyValue) : unref(truthyValue) return innerValue.value } } if (valueIsRef) return toggle2 else return [innerValue, toggle2] } function watchArray$1(source2, cb, options2) { let oldList = (options2 == null ? void 0 : options2.immediate) ? [] : [ ...(source2 instanceof Function ? source2() : Array.isArray(source2) ? source2 : unref(source2)), ] return watch$1( source2, (newList, _2, onCleanup) => { const oldListRemains = new Array(oldList.length) const added = [] for (const obj of newList) { let found = false for (let i2 = 0; i2 < oldList.length; i2++) { if (!oldListRemains[i2] && obj === oldList[i2]) { oldListRemains[i2] = true found = true break } } if (!found) added.push(obj) } const removed = oldList.filter((_22, i2) => !oldListRemains[i2]) cb(newList, oldList, added, removed, onCleanup) oldList = [...newList] }, options2 ) } var __getOwnPropSymbols$6$2 = Object.getOwnPropertySymbols var __hasOwnProp$6$2 = Object.prototype.hasOwnProperty var __propIsEnum$6$2 = Object.prototype.propertyIsEnumerable var __objRest$5$1 = (source2, exclude) => { var target2 = {} for (var prop in source2) if (__hasOwnProp$6$2.call(source2, prop) && exclude.indexOf(prop) < 0) target2[prop] = source2[prop] if (source2 != null && __getOwnPropSymbols$6$2) for (var prop of __getOwnPropSymbols$6$2(source2)) { if (exclude.indexOf(prop) < 0 && __propIsEnum$6$2.call(source2, prop)) target2[prop] = source2[prop] } return target2 } function watchWithFilter$1(source2, cb, options2 = {}) { const _a2 = options2, { eventFilter = bypassFilter$1 } = _a2, watchOptions = __objRest$5$1(_a2, ['eventFilter']) return watch$1(source2, createFilterWrapper$1(eventFilter, cb), watchOptions) } var __getOwnPropSymbols$5$2 = Object.getOwnPropertySymbols var __hasOwnProp$5$2 = Object.prototype.hasOwnProperty var __propIsEnum$5$2 = Object.prototype.propertyIsEnumerable var __objRest$4$1 = (source2, exclude) => { var target2 = {} for (var prop in source2) if (__hasOwnProp$5$2.call(source2, prop) && exclude.indexOf(prop) < 0) target2[prop] = source2[prop] if (source2 != null && __getOwnPropSymbols$5$2) for (var prop of __getOwnPropSymbols$5$2(source2)) { if (exclude.indexOf(prop) < 0 && __propIsEnum$5$2.call(source2, prop)) target2[prop] = source2[prop] } return target2 } function watchAtMost$1(source2, cb, options2) { const _a2 = options2, { count: count2 } = _a2, watchOptions = __objRest$4$1(_a2, ['count']) const current2 = ref(0) const stop2 = watchWithFilter$1( source2, (...args) => { current2.value += 1 if (current2.value >= unref(count2)) nextTick(() => stop2()) cb(...args) }, watchOptions ) return { count: current2, stop: stop2 } } var __defProp$4$2 = Object.defineProperty var __defProps$4$2 = Object.defineProperties var __getOwnPropDescs$4$2 = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$4$2 = Object.getOwnPropertySymbols var __hasOwnProp$4$2 = Object.prototype.hasOwnProperty var __propIsEnum$4$2 = Object.prototype.propertyIsEnumerable var __defNormalProp$4$2 = (obj, key2, value2) => key2 in obj ? __defProp$4$2(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$4$2 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$4$2.call(b2, prop)) __defNormalProp$4$2(a2, prop, b2[prop]) if (__getOwnPropSymbols$4$2) for (var prop of __getOwnPropSymbols$4$2(b2)) { if (__propIsEnum$4$2.call(b2, prop)) __defNormalProp$4$2(a2, prop, b2[prop]) } return a2 } var __spreadProps$4$2 = (a2, b2) => __defProps$4$2(a2, __getOwnPropDescs$4$2(b2)) var __objRest$3$1 = (source2, exclude) => { var target2 = {} for (var prop in source2) if (__hasOwnProp$4$2.call(source2, prop) && exclude.indexOf(prop) < 0) target2[prop] = source2[prop] if (source2 != null && __getOwnPropSymbols$4$2) for (var prop of __getOwnPropSymbols$4$2(source2)) { if (exclude.indexOf(prop) < 0 && __propIsEnum$4$2.call(source2, prop)) target2[prop] = source2[prop] } return target2 } function watchDebounced$1(source2, cb, options2 = {}) { const _a2 = options2, { debounce: debounce2 = 0, maxWait = void 0 } = _a2, watchOptions = __objRest$3$1(_a2, ['debounce', 'maxWait']) return watchWithFilter$1( source2, cb, __spreadProps$4$2(__spreadValues$4$2({}, watchOptions), { eventFilter: debounceFilter$1(debounce2, { maxWait }), }) ) } var __defProp$3$2 = Object.defineProperty var __defProps$3$2 = Object.defineProperties var __getOwnPropDescs$3$2 = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$3$2 = Object.getOwnPropertySymbols var __hasOwnProp$3$2 = Object.prototype.hasOwnProperty var __propIsEnum$3$2 = Object.prototype.propertyIsEnumerable var __defNormalProp$3$2 = (obj, key2, value2) => key2 in obj ? __defProp$3$2(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$3$2 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$3$2.call(b2, prop)) __defNormalProp$3$2(a2, prop, b2[prop]) if (__getOwnPropSymbols$3$2) for (var prop of __getOwnPropSymbols$3$2(b2)) { if (__propIsEnum$3$2.call(b2, prop)) __defNormalProp$3$2(a2, prop, b2[prop]) } return a2 } var __spreadProps$3$2 = (a2, b2) => __defProps$3$2(a2, __getOwnPropDescs$3$2(b2)) var __objRest$2$3 = (source2, exclude) => { var target2 = {} for (var prop in source2) if (__hasOwnProp$3$2.call(source2, prop) && exclude.indexOf(prop) < 0) target2[prop] = source2[prop] if (source2 != null && __getOwnPropSymbols$3$2) for (var prop of __getOwnPropSymbols$3$2(source2)) { if (exclude.indexOf(prop) < 0 && __propIsEnum$3$2.call(source2, prop)) target2[prop] = source2[prop] } return target2 } function watchIgnorable$1(source2, cb, options2 = {}) { const _a2 = options2, { eventFilter = bypassFilter$1 } = _a2, watchOptions = __objRest$2$3(_a2, ['eventFilter']) const filteredCb = createFilterWrapper$1(eventFilter, cb) let ignoreUpdates let ignorePrevAsyncUpdates let stop2 if (watchOptions.flush === 'sync') { const ignore = ref(false) ignorePrevAsyncUpdates = () => {} ignoreUpdates = (updater) => { ignore.value = true updater() ignore.value = false } stop2 = watch$1( source2, (...args) => { if (!ignore.value) filteredCb(...args) }, watchOptions ) } else { const disposables = [] const ignoreCounter = ref(0) const syncCounter = ref(0) ignorePrevAsyncUpdates = () => { ignoreCounter.value = syncCounter.value } disposables.push( watch$1( source2, () => { syncCounter.value++ }, __spreadProps$3$2(__spreadValues$3$2({}, watchOptions), { flush: 'sync', }) ) ) ignoreUpdates = (updater) => { const syncCounterPrev = syncCounter.value updater() ignoreCounter.value += syncCounter.value - syncCounterPrev } disposables.push( watch$1( source2, (...args) => { const ignore = ignoreCounter.value > 0 && ignoreCounter.value === syncCounter.value ignoreCounter.value = 0 syncCounter.value = 0 if (ignore) return filteredCb(...args) }, watchOptions ) ) stop2 = () => { disposables.forEach((fn2) => fn2()) } } return { stop: stop2, ignoreUpdates, ignorePrevAsyncUpdates } } function watchOnce$1(source2, cb, options2) { const stop2 = watch$1( source2, (...args) => { nextTick(() => stop2()) return cb(...args) }, options2 ) } var __defProp$2$2 = Object.defineProperty var __defProps$2$2 = Object.defineProperties var __getOwnPropDescs$2$2 = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$2$2 = Object.getOwnPropertySymbols var __hasOwnProp$2$2 = Object.prototype.hasOwnProperty var __propIsEnum$2$2 = Object.prototype.propertyIsEnumerable var __defNormalProp$2$2 = (obj, key2, value2) => key2 in obj ? __defProp$2$2(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$2$2 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$2$2.call(b2, prop)) __defNormalProp$2$2(a2, prop, b2[prop]) if (__getOwnPropSymbols$2$2) for (var prop of __getOwnPropSymbols$2$2(b2)) { if (__propIsEnum$2$2.call(b2, prop)) __defNormalProp$2$2(a2, prop, b2[prop]) } return a2 } var __spreadProps$2$2 = (a2, b2) => __defProps$2$2(a2, __getOwnPropDescs$2$2(b2)) var __objRest$1$2 = (source2, exclude) => { var target2 = {} for (var prop in source2) if (__hasOwnProp$2$2.call(source2, prop) && exclude.indexOf(prop) < 0) target2[prop] = source2[prop] if (source2 != null && __getOwnPropSymbols$2$2) for (var prop of __getOwnPropSymbols$2$2(source2)) { if (exclude.indexOf(prop) < 0 && __propIsEnum$2$2.call(source2, prop)) target2[prop] = source2[prop] } return target2 } function watchPausable$1(source2, cb, options2 = {}) { const _a2 = options2, { eventFilter: filter2 } = _a2, watchOptions = __objRest$1$2(_a2, ['eventFilter']) const { eventFilter, pause, resume, isActive } = pausableFilter$1(filter2) const stop2 = watchWithFilter$1( source2, cb, __spreadProps$2$2(__spreadValues$2$2({}, watchOptions), { eventFilter, }) ) return { stop: stop2, pause, resume, isActive } } var __defProp$1$2 = Object.defineProperty var __defProps$1$2 = Object.defineProperties var __getOwnPropDescs$1$2 = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$1$2 = Object.getOwnPropertySymbols var __hasOwnProp$1$2 = Object.prototype.hasOwnProperty var __propIsEnum$1$2 = Object.prototype.propertyIsEnumerable var __defNormalProp$1$2 = (obj, key2, value2) => key2 in obj ? __defProp$1$2(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$1$2 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$1$2.call(b2, prop)) __defNormalProp$1$2(a2, prop, b2[prop]) if (__getOwnPropSymbols$1$2) for (var prop of __getOwnPropSymbols$1$2(b2)) { if (__propIsEnum$1$2.call(b2, prop)) __defNormalProp$1$2(a2, prop, b2[prop]) } return a2 } var __spreadProps$1$2 = (a2, b2) => __defProps$1$2(a2, __getOwnPropDescs$1$2(b2)) var __objRest$7 = (source2, exclude) => { var target2 = {} for (var prop in source2) if (__hasOwnProp$1$2.call(source2, prop) && exclude.indexOf(prop) < 0) target2[prop] = source2[prop] if (source2 != null && __getOwnPropSymbols$1$2) for (var prop of __getOwnPropSymbols$1$2(source2)) { if (exclude.indexOf(prop) < 0 && __propIsEnum$1$2.call(source2, prop)) target2[prop] = source2[prop] } return target2 } function watchThrottled$1(source2, cb, options2 = {}) { const _a2 = options2, { throttle: throttle2 = 0, trailing = true, leading = true } = _a2, watchOptions = __objRest$7(_a2, ['throttle', 'trailing', 'leading']) return watchWithFilter$1( source2, cb, __spreadProps$1$2(__spreadValues$1$2({}, watchOptions), { eventFilter: throttleFilter$1(throttle2, trailing, leading), }) ) } var __defProp$p = Object.defineProperty var __defProps$b = Object.defineProperties var __getOwnPropDescs$b = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$r = Object.getOwnPropertySymbols var __hasOwnProp$r = Object.prototype.hasOwnProperty var __propIsEnum$r = Object.prototype.propertyIsEnumerable var __defNormalProp$p = (obj, key2, value2) => key2 in obj ? __defProp$p(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$p = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$r.call(b2, prop)) __defNormalProp$p(a2, prop, b2[prop]) if (__getOwnPropSymbols$r) for (var prop of __getOwnPropSymbols$r(b2)) { if (__propIsEnum$r.call(b2, prop)) __defNormalProp$p(a2, prop, b2[prop]) } return a2 } var __spreadProps$b = (a2, b2) => __defProps$b(a2, __getOwnPropDescs$b(b2)) function watchTriggerable$1(source2, cb, options2 = {}) { let cleanupFn function onEffect() { if (!cleanupFn) return const fn2 = cleanupFn cleanupFn = void 0 fn2() } function onCleanup(callback) { cleanupFn = callback } const _cb = (value2, oldValue) => { onEffect() return cb(value2, oldValue, onCleanup) } const res = watchIgnorable$1(source2, _cb, options2) const { ignoreUpdates } = res const trigger2 = () => { let res2 ignoreUpdates(() => { res2 = _cb(getWatchSources$1(source2), getOldValue$1(source2)) }) return res2 } return __spreadProps$b(__spreadValues$p({}, res), { trigger: trigger2, }) } function getWatchSources$1(sources) { if (isReactive(sources)) return sources if (Array.isArray(sources)) return sources.map((item2) => getOneWatchSource$1(item2)) return getOneWatchSource$1(sources) } function getOneWatchSource$1(source2) { return typeof source2 === 'function' ? source2() : unref(source2) } function getOldValue$1(source2) { return Array.isArray(source2) ? source2.map(() => void 0) : void 0 } function whenever$1(source2, cb, options2) { return watch$1( source2, (v4, ov, onInvalidate) => { if (v4) cb(v4, ov, onInvalidate) }, options2 ) } var index$t = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, __onlyVue3: __onlyVue3$1, and: logicAnd, assert: assert$2, autoResetRef: refAutoReset$1, bypassFilter: bypassFilter$1, clamp: clamp$2, computedEager: computedEager$1, computedWithControl: computedWithControl$1, containsProp: containsProp$1, controlledComputed: computedWithControl$1, controlledRef: controlledRef$1, createEventHook: createEventHook$1, createFilterWrapper: createFilterWrapper$1, createGlobalState: createGlobalState$1, createInjectionState: createInjectionState$1, createReactiveFn: reactify$1, createSharedComposable: createSharedComposable$1, createSingletonPromise: createSingletonPromise$1, debounceFilter: debounceFilter$1, debouncedRef: refDebounced$1, debouncedWatch: watchDebounced$1, directiveHooks: directiveHooks$1, eagerComputed: computedEager$1, extendRef: extendRef$1, formatDate: formatDate$2, get: get$9, identity: identity$2, ignorableWatch: watchIgnorable$1, increaseWithUnit: increaseWithUnit$1, invoke: invoke$3, isBoolean: isBoolean$5, isClient: isClient$1, isDef: isDef$2, isDefined: isDefined$1, isFunction: isFunction$m, isIOS: isIOS$1, isNumber: isNumber$h, isObject: isObject$w, isString: isString$g, isWindow: isWindow$3, logicAnd, logicNot, logicOr, makeDestructurable: makeDestructurable$1, noop: noop$7, normalizeDate: normalizeDate$1, not: logicNot, now: now$6, objectPick: objectPick$1, or: logicOr, pausableFilter: pausableFilter$1, pausableWatch: watchPausable$1, promiseTimeout: promiseTimeout$1, rand: rand$1, reactify: reactify$1, reactifyObject: reactifyObject$1, reactiveComputed: reactiveComputed$1, reactiveOmit: reactiveOmit$1, reactivePick: reactivePick$1, refAutoReset: refAutoReset$1, refDebounced: refDebounced$1, refDefault: refDefault$1, refThrottled: refThrottled$1, refWithControl: refWithControl$1, resolveRef: resolveRef$1, resolveUnref: resolveUnref$1, set: set$7, syncRef: syncRef$1, syncRefs: syncRefs$1, throttleFilter: throttleFilter$1, throttledRef: refThrottled$1, throttledWatch: watchThrottled$1, timestamp: timestamp$3, toReactive: toReactive$1, toRefs: toRefs$1, tryOnBeforeMount: tryOnBeforeMount$1, tryOnBeforeUnmount: tryOnBeforeUnmount$1, tryOnMounted: tryOnMounted$1, tryOnScopeDispose: tryOnScopeDispose$1, tryOnUnmounted: tryOnUnmounted$1, until: until$1, useCounter: useCounter$1, useDateFormat: useDateFormat$1, useDebounce: refDebounced$1, useDebounceFn: useDebounceFn$1, useInterval: useInterval$1, useIntervalFn: useIntervalFn$1, useLastChanged: useLastChanged$1, useThrottle: refThrottled$1, useThrottleFn: useThrottleFn$1, useTimeout: useTimeout$2, useTimeoutFn: useTimeoutFn$1, useToggle: useToggle$1, watchArray: watchArray$1, watchAtMost: watchAtMost$1, watchDebounced: watchDebounced$1, watchIgnorable: watchIgnorable$1, watchOnce: watchOnce$1, watchPausable: watchPausable$1, watchThrottled: watchThrottled$1, watchTriggerable: watchTriggerable$1, watchWithFilter: watchWithFilter$1, whenever: whenever$1, }, Symbol.toStringTag, { value: 'Module' } ) ) function unrefElement$1(elRef) { var _a2 const plain = unref(elRef) return (_a2 = plain == null ? void 0 : plain.$el) != null ? _a2 : plain } const defaultWindow$2 = isClient$1 ? window : void 0 const defaultDocument$1 = isClient$1 ? window.document : void 0 function useEventListener$1(...args) { let target2 let event let listener let options2 if (isString$g(args[0])) { ;[event, listener, options2] = args target2 = defaultWindow$2 } else { ;[target2, event, listener, options2] = args } if (!target2) return noop$7 let cleanup = noop$7 const stopWatch = watch$1( () => unrefElement$1(target2), (el2) => { cleanup() if (!el2) return el2.addEventListener(event, listener, options2) cleanup = () => { el2.removeEventListener(event, listener, options2) cleanup = noop$7 } }, { immediate: true, flush: 'post' } ) const stop2 = () => { stopWatch() cleanup() } tryOnScopeDispose$1(stop2) return stop2 } function onClickOutside$1(target2, handler, options2 = {}) { const { window: window2 = defaultWindow$2, ignore, capture = true, detectIframe = false, } = options2 if (!window2) return const shouldListen = ref(true) let fallback const listener = (event) => { window2.clearTimeout(fallback) const el2 = unrefElement$1(target2) const composedPath = event.composedPath() if ( !el2 || el2 === event.target || composedPath.includes(el2) || !shouldListen.value ) return if (ignore && ignore.length > 0) { if ( ignore.some((target22) => { const el22 = unrefElement$1(target22) return el22 && (event.target === el22 || composedPath.includes(el22)) }) ) return } handler(event) } const cleanup = [ useEventListener$1(window2, 'click', listener, { passive: true, capture }), useEventListener$1( window2, 'pointerdown', (e2) => { const el2 = unrefElement$1(target2) shouldListen.value = !!el2 && !e2.composedPath().includes(el2) }, { passive: true } ), useEventListener$1( window2, 'pointerup', (e2) => { if (e2.button === 0) { const path = e2.composedPath() e2.composedPath = () => path fallback = window2.setTimeout(() => listener(e2), 50) } }, { passive: true } ), detectIframe && useEventListener$1(window2, 'blur', (event) => { var _a2 const el2 = unrefElement$1(target2) if ( ((_a2 = document.activeElement) == null ? void 0 : _a2.tagName) === 'IFRAME' && !(el2 == null ? void 0 : el2.contains(document.activeElement)) ) handler(event) }), ].filter(Boolean) const stop2 = () => cleanup.forEach((fn2) => fn2()) return stop2 } const _global$1 = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {} const globalKey$1 = '__vueuse_ssr_handlers__' _global$1[globalKey$1] = _global$1[globalKey$1] || {} _global$1[globalKey$1] function useDocumentVisibility$1({ document: document2 = defaultDocument$1, } = {}) { if (!document2) return ref('visible') const visibility2 = ref(document2.visibilityState) useEventListener$1(document2, 'visibilitychange', () => { visibility2.value = document2.visibilityState }) return visibility2 } var __getOwnPropSymbols$e$1 = Object.getOwnPropertySymbols var __hasOwnProp$e$1 = Object.prototype.hasOwnProperty var __propIsEnum$e$1 = Object.prototype.propertyIsEnumerable var __objRest$2$2 = (source2, exclude) => { var target2 = {} for (var prop in source2) if (__hasOwnProp$e$1.call(source2, prop) && exclude.indexOf(prop) < 0) target2[prop] = source2[prop] if (source2 != null && __getOwnPropSymbols$e$1) for (var prop of __getOwnPropSymbols$e$1(source2)) { if (exclude.indexOf(prop) < 0 && __propIsEnum$e$1.call(source2, prop)) target2[prop] = source2[prop] } return target2 } function useResizeObserver$1(target2, callback, options2 = {}) { const _a2 = options2, { window: window2 = defaultWindow$2 } = _a2, observerOptions = __objRest$2$2(_a2, ['window']) let observer const isSupported = window2 && 'ResizeObserver' in window2 const cleanup = () => { if (observer) { observer.disconnect() observer = void 0 } } const stopWatch = watch$1( () => unrefElement$1(target2), (el2) => { cleanup() if (isSupported && window2 && el2) { observer = new ResizeObserver(callback) observer.observe(el2, observerOptions) } }, { immediate: true, flush: 'post' } ) const stop2 = () => { cleanup() stopWatch() } tryOnScopeDispose$1(stop2) return { isSupported, stop: stop2, } } function useElementBounding$1(target2, options2 = {}) { const { reset: reset2 = true, windowResize = true, windowScroll = true, immediate = true, } = options2 const height = ref(0) const bottom2 = ref(0) const left2 = ref(0) const right2 = ref(0) const top2 = ref(0) const width = ref(0) const x2 = ref(0) const y2 = ref(0) function update3() { const el2 = unrefElement$1(target2) if (!el2) { if (reset2) { height.value = 0 bottom2.value = 0 left2.value = 0 right2.value = 0 top2.value = 0 width.value = 0 x2.value = 0 y2.value = 0 } return } const rect = el2.getBoundingClientRect() height.value = rect.height bottom2.value = rect.bottom left2.value = rect.left right2.value = rect.right top2.value = rect.top width.value = rect.width x2.value = rect.x y2.value = rect.y } useResizeObserver$1(target2, update3) watch$1( () => unrefElement$1(target2), (ele) => !ele && update3() ) if (windowScroll) useEventListener$1('scroll', update3, { passive: true }) if (windowResize) useEventListener$1('resize', update3, { passive: true }) tryOnMounted$1(() => { if (immediate) update3() }) return { height, bottom: bottom2, left: left2, right: right2, top: top2, width, x: x2, y: y2, update: update3, } } var SwipeDirection$1 ;(function (SwipeDirection2) { SwipeDirection2['UP'] = 'UP' SwipeDirection2['RIGHT'] = 'RIGHT' SwipeDirection2['DOWN'] = 'DOWN' SwipeDirection2['LEFT'] = 'LEFT' SwipeDirection2['NONE'] = 'NONE' })(SwipeDirection$1 || (SwipeDirection$1 = {})) function useWindowFocus$1({ window: window2 = defaultWindow$2 } = {}) { if (!window2) return ref(false) const focused = ref(window2.document.hasFocus()) useEventListener$1(window2, 'blur', () => { focused.value = false }) useEventListener$1(window2, 'focus', () => { focused.value = true }) return focused } function useWindowSize$1(options2 = {}) { const { window: window2 = defaultWindow$2, initialWidth = Infinity, initialHeight = Infinity, listenOrientation = true, } = options2 const width = ref(initialWidth) const height = ref(initialHeight) const update3 = () => { if (window2) { width.value = window2.innerWidth height.value = window2.innerHeight } } update3() tryOnMounted$1(update3) useEventListener$1('resize', update3, { passive: true }) if (listenOrientation) useEventListener$1('orientationchange', update3, { passive: true }) return { width, height } } const isInContainer = (el2, container) => { if (!isClient$1 || !el2 || !container) return false const elRect = el2.getBoundingClientRect() let containerRect if (container instanceof Element) { containerRect = container.getBoundingClientRect() } else { containerRect = { top: 0, right: window.innerWidth, bottom: window.innerHeight, left: 0, } } return ( elRect.top < containerRect.bottom && elRect.bottom > containerRect.top && elRect.right > containerRect.left && elRect.left < containerRect.right ) } const getOffsetTop = (el2) => { let offset2 = 0 let parent2 = el2 while (parent2) { offset2 += parent2.offsetTop parent2 = parent2.offsetParent } return offset2 } const getOffsetTopDistance = (el2, containerEl) => { return Math.abs(getOffsetTop(el2) - getOffsetTop(containerEl)) } const getClientXY = (event) => { let clientX let clientY if (event.type === 'touchend') { clientY = event.changedTouches[0].clientY clientX = event.changedTouches[0].clientX } else if (event.type.startsWith('touch')) { clientY = event.touches[0].clientY clientX = event.touches[0].clientX } else { clientY = event.clientY clientX = event.clientX } return { clientX, clientY, } } const resizeHandler = function (entries2) { for (const entry of entries2) { const listeners = entry.target.__resizeListeners__ || [] if (listeners.length) { listeners.forEach((fn2) => { fn2() }) } } } const addResizeListener = function (element, fn2) { if (!isClient$1 || !element) return if (!element.__resizeListeners__) { element.__resizeListeners__ = [] element.__ro__ = new ResizeObserver(resizeHandler) element.__ro__.observe(element) } element.__resizeListeners__.push(fn2) } const removeResizeListener = function (element, fn2) { var _a2 if (!element || !element.__resizeListeners__) return element.__resizeListeners__.splice( element.__resizeListeners__.indexOf(fn2), 1 ) if (!element.__resizeListeners__.length) { ;(_a2 = element.__ro__) == null ? void 0 : _a2.disconnect() } } const NOOP = () => {} const hasOwnProperty$d = Object.prototype.hasOwnProperty const hasOwn$e = (val2, key2) => hasOwnProperty$d.call(val2, key2) const isArray$D = Array.isArray const isFunction$l = (val2) => typeof val2 === 'function' const isString$f = (val2) => typeof val2 === 'string' const isObject$v = (val2) => val2 !== null && typeof val2 === 'object' const isPromise$1 = (val2) => { return isObject$v(val2) && isFunction$l(val2.then) && isFunction$l(val2.catch) } const objectToString$6 = Object.prototype.toString const toTypeString$1 = (value2) => objectToString$6.call(value2) const toRawType = (value2) => { return toTypeString$1(value2).slice(8, -1) } const cacheStringFunction = (fn2) => { const cache2 = /* @__PURE__ */ Object.create(null) return (str) => { const hit = cache2[str] return hit || (cache2[str] = fn2(str)) } } const camelizeRE = /-(\w)/g const camelize = cacheStringFunction((str) => { return str.replace(camelizeRE, (_2, c2) => (c2 ? c2.toUpperCase() : '')) }) const hyphenateRE = /\B([A-Z])/g const hyphenate = cacheStringFunction((str) => str.replace(hyphenateRE, '-$1').toLowerCase() ) const capitalize$2 = cacheStringFunction( (str) => str.charAt(0).toUpperCase() + str.slice(1) ) const isUndefined$c = (val2) => val2 === void 0 const isEmpty$3 = (val2) => (!val2 && val2 !== 0) || (isArray$D(val2) && val2.length === 0) || (isObject$v(val2) && !Object.keys(val2).length) const isElement$3 = (e2) => { if (typeof Element === 'undefined') return false return e2 instanceof Element } const isPropAbsent = (prop) => { return isNil$1(prop) } const escapeStringRegexp = (string3 = '') => string3.replace(/[|\\{}()[\]^$+*?.]/g, '\\$&').replace(/-/g, '\\x2d') const keysOf = (arr) => Object.keys(arr) const entriesOf = (arr) => Object.entries(arr) const getProp = (obj, path, defaultValue) => { return { get value() { return get$a(obj, path, defaultValue) }, set value(val2) { set$8(obj, path, val2) }, } } const classNameToArray = (cls = '') => cls.split(' ').filter((item2) => !!item2.trim()) const hasClass$1 = (el2, cls) => { if (!el2 || !cls) return false if (cls.includes(' ')) throw new Error('className should not contain space.') return el2.classList.contains(cls) } const addClass$1 = (el2, cls) => { if (!el2 || !cls.trim()) return el2.classList.add(...classNameToArray(cls)) } const removeClass$1 = (el2, cls) => { if (!el2 || !cls.trim()) return el2.classList.remove(...classNameToArray(cls)) } const getStyle$1 = (element, styleName) => { var _a2 if (!isClient$1 || !element || !styleName) return '' camelize(styleName) try { const style2 = element.style[styleName] if (style2) return style2 const computed2 = (_a2 = document.defaultView) == null ? void 0 : _a2.getComputedStyle(element, '') return computed2 ? computed2[styleName] : '' } catch (e2) { return element.style[styleName] } } const isScroll = (el2, isVertical) => { if (!isClient$1) return false const key2 = { undefined: 'overflow', true: 'overflow-y', false: 'overflow-x', }[String(isVertical)] const overflow2 = getStyle$1(el2, key2) return ['scroll', 'auto', 'overlay'].some((s2) => overflow2.includes(s2)) } const getScrollContainer = (el2, isVertical) => { if (!isClient$1) return let parent2 = el2 while (parent2) { if ([window, document, document.documentElement].includes(parent2)) return window if (isScroll(parent2, isVertical)) return parent2 parent2 = parent2.parentNode } return parent2 } let scrollBarWidth const getScrollBarWidth = () => { var _a2 if (!isClient$1) return 0 if (scrollBarWidth !== void 0) return scrollBarWidth const outer = document.createElement('div') outer.className = 'el-scrollbar__wrap' outer.style.visibility = 'hidden' outer.style.width = '100px' outer.style.position = 'absolute' outer.style.top = '-9999px' document.body.appendChild(outer) const widthNoScroll = outer.offsetWidth outer.style.overflow = 'scroll' const inner2 = document.createElement('div') inner2.style.width = '100%' outer.appendChild(inner2) const widthWithScroll = inner2.offsetWidth ;(_a2 = outer.parentNode) == null ? void 0 : _a2.removeChild(outer) scrollBarWidth = widthNoScroll - widthWithScroll return scrollBarWidth } function scrollIntoView$1(container, selected) { if (!isClient$1) return if (!selected) { container.scrollTop = 0 return } const offsetParents = [] let pointer2 = selected.offsetParent while ( pointer2 !== null && container !== pointer2 && container.contains(pointer2) ) { offsetParents.push(pointer2) pointer2 = pointer2.offsetParent } const top2 = selected.offsetTop + offsetParents.reduce((prev, curr) => prev + curr.offsetTop, 0) const bottom2 = top2 + selected.offsetHeight const viewRectTop = container.scrollTop const viewRectBottom = viewRectTop + container.clientHeight if (top2 < viewRectTop) { container.scrollTop = top2 } else if (bottom2 > viewRectBottom) { container.scrollTop = bottom2 - container.clientHeight } } const globalNodes = [] let target = !isClient$1 ? void 0 : document.body function createGlobalNode(id2) { const el2 = document.createElement('div') if (id2 !== void 0) { el2.setAttribute('id', id2) } target.appendChild(el2) globalNodes.push(el2) return el2 } function removeGlobalNode(el2) { globalNodes.splice(globalNodes.indexOf(el2), 1) el2.remove() } var _export_sfc$2 = (sfc, props2) => { const target2 = sfc.__vccOpts || sfc for (const [key2, val2] of props2) { target2[key2] = val2 } return target2 } const _sfc_main$dN = defineComponent({ name: 'AddLocation', }) const _hoisted_1$bq = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$a0 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M288 896h448q32 0 32 32t-32 32H288q-32 0-32-32t32-32z', }, null, -1 ) const _hoisted_3$9f = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M800 416a288 288 0 1 0-576 0c0 118.144 94.528 272.128 288 456.576C705.472 688.128 800 534.144 800 416zM512 960C277.312 746.688 160 565.312 160 416a352 352 0 0 1 704 0c0 149.312-117.312 330.688-352 544z', }, null, -1 ) const _hoisted_4$5p = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M544 384h96a32 32 0 1 1 0 64h-96v96a32 32 0 0 1-64 0v-96h-96a32 32 0 0 1 0-64h96v-96a32 32 0 0 1 64 0v96z', }, null, -1 ) const _hoisted_5$3$ = [_hoisted_2$a0, _hoisted_3$9f, _hoisted_4$5p] function _sfc_render$68(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$bq, _hoisted_5$3$) } var addLocation = /* @__PURE__ */ _export_sfc$2(_sfc_main$dN, [ ['render', _sfc_render$68], ]) const _sfc_main$dM = defineComponent({ name: 'Aim', }) const _hoisted_1$bp = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9$ = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 896a384 384 0 1 0 0-768 384 384 0 0 0 0 768zm0 64a448 448 0 1 1 0-896 448 448 0 0 1 0 896z', }, null, -1 ) const _hoisted_3$9e = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 96a32 32 0 0 1 32 32v192a32 32 0 0 1-64 0V128a32 32 0 0 1 32-32zm0 576a32 32 0 0 1 32 32v192a32 32 0 1 1-64 0V704a32 32 0 0 1 32-32zM96 512a32 32 0 0 1 32-32h192a32 32 0 0 1 0 64H128a32 32 0 0 1-32-32zm576 0a32 32 0 0 1 32-32h192a32 32 0 1 1 0 64H704a32 32 0 0 1-32-32z', }, null, -1 ) const _hoisted_4$5o = [_hoisted_2$9$, _hoisted_3$9e] function _sfc_render$67(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$bp, _hoisted_4$5o) } var aim = /* @__PURE__ */ _export_sfc$2(_sfc_main$dM, [ ['render', _sfc_render$67], ]) const _sfc_main$dL = defineComponent({ name: 'AlarmClock', }) const _hoisted_1$bo = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9_ = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 832a320 320 0 1 0 0-640 320 320 0 0 0 0 640zm0 64a384 384 0 1 1 0-768 384 384 0 0 1 0 768z', }, null, -1 ) const _hoisted_3$9d = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm292.288 824.576 55.424 32-48 83.136a32 32 0 1 1-55.424-32l48-83.136zm439.424 0-55.424 32 48 83.136a32 32 0 1 0 55.424-32l-48-83.136zM512 512h160a32 32 0 1 1 0 64H480a32 32 0 0 1-32-32V320a32 32 0 0 1 64 0v192zM90.496 312.256A160 160 0 0 1 312.32 90.496l-46.848 46.848a96 96 0 0 0-128 128L90.56 312.256zm835.264 0A160 160 0 0 0 704 90.496l46.848 46.848a96 96 0 0 1 128 128l46.912 46.912z', }, null, -1 ) const _hoisted_4$5n = [_hoisted_2$9_, _hoisted_3$9d] function _sfc_render$66(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$bo, _hoisted_4$5n) } var alarmClock = /* @__PURE__ */ _export_sfc$2(_sfc_main$dL, [ ['render', _sfc_render$66], ]) const _sfc_main$dK = defineComponent({ name: 'Apple', }) const _hoisted_1$bn = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9Z = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M599.872 203.776a189.44 189.44 0 0 1 64.384-4.672l2.624.128c31.168 1.024 51.2 4.096 79.488 16.32 37.632 16.128 74.496 45.056 111.488 89.344 96.384 115.264 82.752 372.8-34.752 521.728-7.68 9.728-32 41.6-30.72 39.936a426.624 426.624 0 0 1-30.08 35.776c-31.232 32.576-65.28 49.216-110.08 50.048-31.36.64-53.568-5.312-84.288-18.752l-6.528-2.88c-20.992-9.216-30.592-11.904-47.296-11.904-18.112 0-28.608 2.88-51.136 12.672l-6.464 2.816c-28.416 12.224-48.32 18.048-76.16 19.2-74.112 2.752-116.928-38.08-180.672-132.16-96.64-142.08-132.608-349.312-55.04-486.4 46.272-81.92 129.92-133.632 220.672-135.04 32.832-.576 60.288 6.848 99.648 22.72 27.136 10.88 34.752 13.76 37.376 14.272 16.256-20.16 27.776-36.992 34.56-50.24 13.568-26.304 27.2-59.968 40.704-100.8a32 32 0 1 1 60.8 20.224c-12.608 37.888-25.408 70.4-38.528 97.664zm-51.52 78.08c-14.528 17.792-31.808 37.376-51.904 58.816a32 32 0 1 1-46.72-43.776l12.288-13.248c-28.032-11.2-61.248-26.688-95.68-26.112-70.4 1.088-135.296 41.6-171.648 105.792C121.6 492.608 176 684.16 247.296 788.992c34.816 51.328 76.352 108.992 130.944 106.944 52.48-2.112 72.32-34.688 135.872-34.688 63.552 0 81.28 34.688 136.96 33.536 56.448-1.088 75.776-39.04 126.848-103.872 107.904-136.768 107.904-362.752 35.776-449.088-72.192-86.272-124.672-84.096-151.68-85.12-41.472-4.288-81.6 12.544-113.664 25.152z', }, null, -1 ) const _hoisted_3$9c = [_hoisted_2$9Z] function _sfc_render$65(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$bn, _hoisted_3$9c) } var apple = /* @__PURE__ */ _export_sfc$2(_sfc_main$dK, [ ['render', _sfc_render$65], ]) const _sfc_main$dJ = defineComponent({ name: 'ArrowDownBold', }) const _hoisted_1$bm = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9Y = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M104.704 338.752a64 64 0 0 1 90.496 0l316.8 316.8 316.8-316.8a64 64 0 0 1 90.496 90.496L557.248 791.296a64 64 0 0 1-90.496 0L104.704 429.248a64 64 0 0 1 0-90.496z', }, null, -1 ) const _hoisted_3$9b = [_hoisted_2$9Y] function _sfc_render$64(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$bm, _hoisted_3$9b) } var arrowDownBold = /* @__PURE__ */ _export_sfc$2(_sfc_main$dJ, [ ['render', _sfc_render$64], ]) const _sfc_main$dI = defineComponent({ name: 'ArrowDown', }) const _hoisted_1$bl = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9X = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M831.872 340.864 512 652.672 192.128 340.864a30.592 30.592 0 0 0-42.752 0 29.12 29.12 0 0 0 0 41.6L489.664 714.24a32 32 0 0 0 44.672 0l340.288-331.712a29.12 29.12 0 0 0 0-41.728 30.592 30.592 0 0 0-42.752 0z', }, null, -1 ) const _hoisted_3$9a = [_hoisted_2$9X] function _sfc_render$63(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$bl, _hoisted_3$9a) } var arrowDown = /* @__PURE__ */ _export_sfc$2(_sfc_main$dI, [ ['render', _sfc_render$63], ]) const _sfc_main$dH = defineComponent({ name: 'ArrowLeftBold', }) const _hoisted_1$bk = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9W = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M685.248 104.704a64 64 0 0 1 0 90.496L368.448 512l316.8 316.8a64 64 0 0 1-90.496 90.496L232.704 557.248a64 64 0 0 1 0-90.496l362.048-362.048a64 64 0 0 1 90.496 0z', }, null, -1 ) const _hoisted_3$99 = [_hoisted_2$9W] function _sfc_render$62(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$bk, _hoisted_3$99) } var arrowLeftBold = /* @__PURE__ */ _export_sfc$2(_sfc_main$dH, [ ['render', _sfc_render$62], ]) const _sfc_main$dG = defineComponent({ name: 'ArrowLeft', }) const _hoisted_1$bj = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9V = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M609.408 149.376 277.76 489.6a32 32 0 0 0 0 44.672l331.648 340.352a29.12 29.12 0 0 0 41.728 0 30.592 30.592 0 0 0 0-42.752L339.264 511.936l311.872-319.872a30.592 30.592 0 0 0 0-42.688 29.12 29.12 0 0 0-41.728 0z', }, null, -1 ) const _hoisted_3$98 = [_hoisted_2$9V] function _sfc_render$61(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$bj, _hoisted_3$98) } var arrowLeft = /* @__PURE__ */ _export_sfc$2(_sfc_main$dG, [ ['render', _sfc_render$61], ]) const _sfc_main$dF = defineComponent({ name: 'ArrowRightBold', }) const _hoisted_1$bi = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9U = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M338.752 104.704a64 64 0 0 0 0 90.496l316.8 316.8-316.8 316.8a64 64 0 0 0 90.496 90.496l362.048-362.048a64 64 0 0 0 0-90.496L429.248 104.704a64 64 0 0 0-90.496 0z', }, null, -1 ) const _hoisted_3$97 = [_hoisted_2$9U] function _sfc_render$60(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$bi, _hoisted_3$97) } var arrowRightBold = /* @__PURE__ */ _export_sfc$2(_sfc_main$dF, [ ['render', _sfc_render$60], ]) const _sfc_main$dE = defineComponent({ name: 'ArrowRight', }) const _hoisted_1$bh = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9T = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M340.864 149.312a30.592 30.592 0 0 0 0 42.752L652.736 512 340.864 831.872a30.592 30.592 0 0 0 0 42.752 29.12 29.12 0 0 0 41.728 0L714.24 534.336a32 32 0 0 0 0-44.672L382.592 149.376a29.12 29.12 0 0 0-41.728 0z', }, null, -1 ) const _hoisted_3$96 = [_hoisted_2$9T] function _sfc_render$5$(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$bh, _hoisted_3$96) } var arrowRight = /* @__PURE__ */ _export_sfc$2(_sfc_main$dE, [ ['render', _sfc_render$5$], ]) const _sfc_main$dD = defineComponent({ name: 'ArrowUpBold', }) const _hoisted_1$bg = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9S = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M104.704 685.248a64 64 0 0 0 90.496 0l316.8-316.8 316.8 316.8a64 64 0 0 0 90.496-90.496L557.248 232.704a64 64 0 0 0-90.496 0L104.704 594.752a64 64 0 0 0 0 90.496z', }, null, -1 ) const _hoisted_3$95 = [_hoisted_2$9S] function _sfc_render$5_(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$bg, _hoisted_3$95) } var arrowUpBold = /* @__PURE__ */ _export_sfc$2(_sfc_main$dD, [ ['render', _sfc_render$5_], ]) const _sfc_main$dC = defineComponent({ name: 'ArrowUp', }) const _hoisted_1$bf = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9R = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm488.832 344.32-339.84 356.672a32 32 0 0 0 0 44.16l.384.384a29.44 29.44 0 0 0 42.688 0l320-335.872 319.872 335.872a29.44 29.44 0 0 0 42.688 0l.384-.384a32 32 0 0 0 0-44.16L535.168 344.32a32 32 0 0 0-46.336 0z', }, null, -1 ) const _hoisted_3$94 = [_hoisted_2$9R] function _sfc_render$5Z(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$bf, _hoisted_3$94) } var arrowUp = /* @__PURE__ */ _export_sfc$2(_sfc_main$dC, [ ['render', _sfc_render$5Z], ]) const _sfc_main$dB = defineComponent({ name: 'Avatar', }) const _hoisted_1$be = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9Q = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M628.736 528.896A416 416 0 0 1 928 928H96a415.872 415.872 0 0 1 299.264-399.104L512 704l116.736-175.104zM720 304a208 208 0 1 1-416 0 208 208 0 0 1 416 0z', }, null, -1 ) const _hoisted_3$93 = [_hoisted_2$9Q] function _sfc_render$5Y(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$be, _hoisted_3$93) } var avatar = /* @__PURE__ */ _export_sfc$2(_sfc_main$dB, [ ['render', _sfc_render$5Y], ]) const _sfc_main$dA = defineComponent({ name: 'Back', }) const _hoisted_1$bd = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9P = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M224 480h640a32 32 0 1 1 0 64H224a32 32 0 0 1 0-64z', }, null, -1 ) const _hoisted_3$92 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm237.248 512 265.408 265.344a32 32 0 0 1-45.312 45.312l-288-288a32 32 0 0 1 0-45.312l288-288a32 32 0 1 1 45.312 45.312L237.248 512z', }, null, -1 ) const _hoisted_4$5m = [_hoisted_2$9P, _hoisted_3$92] function _sfc_render$5X(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$bd, _hoisted_4$5m) } var back$1 = /* @__PURE__ */ _export_sfc$2(_sfc_main$dA, [ ['render', _sfc_render$5X], ]) const _sfc_main$dz = defineComponent({ name: 'Baseball', }) const _hoisted_1$bc = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9O = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M195.2 828.8a448 448 0 1 1 633.6-633.6 448 448 0 0 1-633.6 633.6zm45.248-45.248a384 384 0 1 0 543.104-543.104 384 384 0 0 0-543.104 543.104z', }, null, -1 ) const _hoisted_3$91 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M497.472 96.896c22.784 4.672 44.416 9.472 64.896 14.528a256.128 256.128 0 0 0 350.208 350.208c5.056 20.48 9.856 42.112 14.528 64.896A320.128 320.128 0 0 1 497.472 96.896zM108.48 491.904a320.128 320.128 0 0 1 423.616 423.68c-23.04-3.648-44.992-7.424-65.728-11.52a256.128 256.128 0 0 0-346.496-346.432 1736.64 1736.64 0 0 1-11.392-65.728z', }, null, -1 ) const _hoisted_4$5l = [_hoisted_2$9O, _hoisted_3$91] function _sfc_render$5W(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$bc, _hoisted_4$5l) } var baseball = /* @__PURE__ */ _export_sfc$2(_sfc_main$dz, [ ['render', _sfc_render$5W], ]) const _sfc_main$dy = defineComponent({ name: 'Basketball', }) const _hoisted_1$bb = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9N = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M778.752 788.224a382.464 382.464 0 0 0 116.032-245.632 256.512 256.512 0 0 0-241.728-13.952 762.88 762.88 0 0 1 125.696 259.584zm-55.04 44.224a699.648 699.648 0 0 0-125.056-269.632 256.128 256.128 0 0 0-56.064 331.968 382.72 382.72 0 0 0 181.12-62.336zm-254.08 61.248A320.128 320.128 0 0 1 557.76 513.6a715.84 715.84 0 0 0-48.192-48.128 320.128 320.128 0 0 1-379.264 88.384 382.4 382.4 0 0 0 110.144 229.696 382.4 382.4 0 0 0 229.184 110.08zM129.28 481.088a256.128 256.128 0 0 0 331.072-56.448 699.648 699.648 0 0 0-268.8-124.352 382.656 382.656 0 0 0-62.272 180.8zm106.56-235.84a762.88 762.88 0 0 1 258.688 125.056 256.512 256.512 0 0 0-13.44-241.088A382.464 382.464 0 0 0 235.84 245.248zm318.08-114.944c40.576 89.536 37.76 193.92-8.448 281.344a779.84 779.84 0 0 1 66.176 66.112 320.832 320.832 0 0 1 282.112-8.128 382.4 382.4 0 0 0-110.144-229.12 382.4 382.4 0 0 0-229.632-110.208zM828.8 828.8a448 448 0 1 1-633.6-633.6 448 448 0 0 1 633.6 633.6z', }, null, -1 ) const _hoisted_3$90 = [_hoisted_2$9N] function _sfc_render$5V(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$bb, _hoisted_3$90) } var basketball = /* @__PURE__ */ _export_sfc$2(_sfc_main$dy, [ ['render', _sfc_render$5V], ]) const _sfc_main$dx = defineComponent({ name: 'BellFilled', }) const _hoisted_1$ba = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9M = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M640 832a128 128 0 0 1-256 0h256zm192-64H134.4a38.4 38.4 0 0 1 0-76.8H192V448c0-154.88 110.08-284.16 256.32-313.6a64 64 0 1 1 127.36 0A320.128 320.128 0 0 1 832 448v243.2h57.6a38.4 38.4 0 0 1 0 76.8H832z', }, null, -1 ) const _hoisted_3$8$ = [_hoisted_2$9M] function _sfc_render$5U(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$ba, _hoisted_3$8$) } var bellFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$dx, [ ['render', _sfc_render$5U], ]) const _sfc_main$dw = defineComponent({ name: 'Bell', }) const _hoisted_1$b9 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9L = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 64a64 64 0 0 1 64 64v64H448v-64a64 64 0 0 1 64-64z', }, null, -1 ) const _hoisted_3$8_ = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M256 768h512V448a256 256 0 1 0-512 0v320zm256-640a320 320 0 0 1 320 320v384H192V448a320 320 0 0 1 320-320z', }, null, -1 ) const _hoisted_4$5k = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M96 768h832q32 0 32 32t-32 32H96q-32 0-32-32t32-32zm352 128h128a64 64 0 0 1-128 0z', }, null, -1 ) const _hoisted_5$3_ = [_hoisted_2$9L, _hoisted_3$8_, _hoisted_4$5k] function _sfc_render$5T(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$b9, _hoisted_5$3_) } var bell = /* @__PURE__ */ _export_sfc$2(_sfc_main$dw, [ ['render', _sfc_render$5T], ]) const _sfc_main$dv = defineComponent({ name: 'Bicycle', }) const _hoisted_1$b8 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9K = /* @__PURE__ */ createStaticVNode( '', 5 ) const _hoisted_7$2U = [_hoisted_2$9K] function _sfc_render$5S(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$b8, _hoisted_7$2U) } var bicycle = /* @__PURE__ */ _export_sfc$2(_sfc_main$dv, [ ['render', _sfc_render$5S], ]) const _sfc_main$du = defineComponent({ name: 'BottomLeft', }) const _hoisted_1$b7 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9J = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M256 768h416a32 32 0 1 1 0 64H224a32 32 0 0 1-32-32V352a32 32 0 0 1 64 0v416z', }, null, -1 ) const _hoisted_3$8Z = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M246.656 822.656a32 32 0 0 1-45.312-45.312l544-544a32 32 0 0 1 45.312 45.312l-544 544z', }, null, -1 ) const _hoisted_4$5j = [_hoisted_2$9J, _hoisted_3$8Z] function _sfc_render$5R(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$b7, _hoisted_4$5j) } var bottomLeft = /* @__PURE__ */ _export_sfc$2(_sfc_main$du, [ ['render', _sfc_render$5R], ]) const _sfc_main$dt = defineComponent({ name: 'BottomRight', }) const _hoisted_1$b6 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9I = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M352 768a32 32 0 1 0 0 64h448a32 32 0 0 0 32-32V352a32 32 0 0 0-64 0v416H352z', }, null, -1 ) const _hoisted_3$8Y = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M777.344 822.656a32 32 0 0 0 45.312-45.312l-544-544a32 32 0 0 0-45.312 45.312l544 544z', }, null, -1 ) const _hoisted_4$5i = [_hoisted_2$9I, _hoisted_3$8Y] function _sfc_render$5Q(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$b6, _hoisted_4$5i) } var bottomRight = /* @__PURE__ */ _export_sfc$2(_sfc_main$dt, [ ['render', _sfc_render$5Q], ]) const _sfc_main$ds = defineComponent({ name: 'Bottom', }) const _hoisted_1$b5 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9H = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M544 805.888V168a32 32 0 1 0-64 0v637.888L246.656 557.952a30.72 30.72 0 0 0-45.312 0 35.52 35.52 0 0 0 0 48.064l288 306.048a30.72 30.72 0 0 0 45.312 0l288-306.048a35.52 35.52 0 0 0 0-48 30.72 30.72 0 0 0-45.312 0L544 805.824z', }, null, -1 ) const _hoisted_3$8X = [_hoisted_2$9H] function _sfc_render$5P(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$b5, _hoisted_3$8X) } var bottom$1 = /* @__PURE__ */ _export_sfc$2(_sfc_main$ds, [ ['render', _sfc_render$5P], ]) const _sfc_main$dr = defineComponent({ name: 'Bowl', }) const _hoisted_1$b4 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9G = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M714.432 704a351.744 351.744 0 0 0 148.16-256H161.408a351.744 351.744 0 0 0 148.16 256h404.864zM288 766.592A415.68 415.68 0 0 1 96 416a32 32 0 0 1 32-32h768a32 32 0 0 1 32 32 415.68 415.68 0 0 1-192 350.592V832a64 64 0 0 1-64 64H352a64 64 0 0 1-64-64v-65.408zM493.248 320h-90.496l254.4-254.4a32 32 0 1 1 45.248 45.248L493.248 320zm187.328 0h-128l269.696-155.712a32 32 0 0 1 32 55.424L680.576 320zM352 768v64h320v-64H352z', }, null, -1 ) const _hoisted_3$8W = [_hoisted_2$9G] function _sfc_render$5O(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$b4, _hoisted_3$8W) } var bowl = /* @__PURE__ */ _export_sfc$2(_sfc_main$dr, [ ['render', _sfc_render$5O], ]) const _sfc_main$dq = defineComponent({ name: 'Box', }) const _hoisted_1$b3 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9F = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M317.056 128 128 344.064V896h768V344.064L706.944 128H317.056zm-14.528-64h418.944a32 32 0 0 1 24.064 10.88l206.528 236.096A32 32 0 0 1 960 332.032V928a32 32 0 0 1-32 32H96a32 32 0 0 1-32-32V332.032a32 32 0 0 1 7.936-21.12L278.4 75.008A32 32 0 0 1 302.528 64z', }, null, -1 ) const _hoisted_3$8V = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M64 320h896v64H64z', }, null, -1 ) const _hoisted_4$5h = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M448 327.872V640h128V327.872L526.08 128h-28.16L448 327.872zM448 64h128l64 256v352a32 32 0 0 1-32 32H416a32 32 0 0 1-32-32V320l64-256z', }, null, -1 ) const _hoisted_5$3Z = [_hoisted_2$9F, _hoisted_3$8V, _hoisted_4$5h] function _sfc_render$5N(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$b3, _hoisted_5$3Z) } var box$1 = /* @__PURE__ */ _export_sfc$2(_sfc_main$dq, [ ['render', _sfc_render$5N], ]) const _sfc_main$dp = defineComponent({ name: 'Briefcase', }) const _hoisted_1$b2 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9E = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M320 320V128h384v192h192v192H128V320h192zM128 576h768v320H128V576zm256-256h256.064V192H384v128z', }, null, -1 ) const _hoisted_3$8U = [_hoisted_2$9E] function _sfc_render$5M(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$b2, _hoisted_3$8U) } var briefcase = /* @__PURE__ */ _export_sfc$2(_sfc_main$dp, [ ['render', _sfc_render$5M], ]) const _sfc_main$do = defineComponent({ name: 'BrushFilled', }) const _hoisted_1$b1 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9D = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M608 704v160a96 96 0 0 1-192 0V704h-96a128 128 0 0 1-128-128h640a128 128 0 0 1-128 128h-96zM192 512V128.064h640V512H192z', }, null, -1 ) const _hoisted_3$8T = [_hoisted_2$9D] function _sfc_render$5L(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$b1, _hoisted_3$8T) } var brushFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$do, [ ['render', _sfc_render$5L], ]) const _sfc_main$dn = defineComponent({ name: 'Brush', }) const _hoisted_1$b0 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9C = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M896 448H128v192a64 64 0 0 0 64 64h192v192h256V704h192a64 64 0 0 0 64-64V448zm-770.752-64c0-47.552 5.248-90.24 15.552-128 14.72-54.016 42.496-107.392 83.2-160h417.28l-15.36 70.336L736 96h211.2c-24.832 42.88-41.92 96.256-51.2 160a663.872 663.872 0 0 0-6.144 128H960v256a128 128 0 0 1-128 128H704v160a32 32 0 0 1-32 32H352a32 32 0 0 1-32-32V768H192A128 128 0 0 1 64 640V384h61.248zm64 0h636.544c-2.048-45.824.256-91.584 6.848-137.216 4.48-30.848 10.688-59.776 18.688-86.784h-96.64l-221.12 141.248L561.92 160H256.512c-25.856 37.888-43.776 75.456-53.952 112.832-8.768 32.064-13.248 69.12-13.312 111.168z', }, null, -1 ) const _hoisted_3$8S = [_hoisted_2$9C] function _sfc_render$5K(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$b0, _hoisted_3$8S) } var brush$2 = /* @__PURE__ */ _export_sfc$2(_sfc_main$dn, [ ['render', _sfc_render$5K], ]) const _sfc_main$dm = defineComponent({ name: 'Burger', }) const _hoisted_1$a$ = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9B = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M160 512a32 32 0 0 0-32 32v64a32 32 0 0 0 30.08 32H864a32 32 0 0 0 32-32v-64a32 32 0 0 0-32-32H160zm736-58.56A96 96 0 0 1 960 544v64a96 96 0 0 1-51.968 85.312L855.36 833.6a96 96 0 0 1-89.856 62.272H258.496A96 96 0 0 1 168.64 833.6l-52.608-140.224A96 96 0 0 1 64 608v-64a96 96 0 0 1 64-90.56V448a384 384 0 1 1 768 5.44zM832 448a320 320 0 0 0-640 0h640zM512 704H188.352l40.192 107.136a32 32 0 0 0 29.952 20.736h507.008a32 32 0 0 0 29.952-20.736L835.648 704H512z', }, null, -1 ) const _hoisted_3$8R = [_hoisted_2$9B] function _sfc_render$5J(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$a$, _hoisted_3$8R) } var burger = /* @__PURE__ */ _export_sfc$2(_sfc_main$dm, [ ['render', _sfc_render$5J], ]) const _sfc_main$dl = defineComponent({ name: 'Calendar', }) const _hoisted_1$a_ = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9A = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M128 384v512h768V192H768v32a32 32 0 1 1-64 0v-32H320v32a32 32 0 0 1-64 0v-32H128v128h768v64H128zm192-256h384V96a32 32 0 1 1 64 0v32h160a32 32 0 0 1 32 32v768a32 32 0 0 1-32 32H96a32 32 0 0 1-32-32V160a32 32 0 0 1 32-32h160V96a32 32 0 0 1 64 0v32zm-32 384h64a32 32 0 0 1 0 64h-64a32 32 0 0 1 0-64zm0 192h64a32 32 0 1 1 0 64h-64a32 32 0 1 1 0-64zm192-192h64a32 32 0 0 1 0 64h-64a32 32 0 0 1 0-64zm0 192h64a32 32 0 1 1 0 64h-64a32 32 0 1 1 0-64zm192-192h64a32 32 0 1 1 0 64h-64a32 32 0 1 1 0-64zm0 192h64a32 32 0 1 1 0 64h-64a32 32 0 1 1 0-64z', }, null, -1 ) const _hoisted_3$8Q = [_hoisted_2$9A] function _sfc_render$5I(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$a_, _hoisted_3$8Q) } var calendar = /* @__PURE__ */ _export_sfc$2(_sfc_main$dl, [ ['render', _sfc_render$5I], ]) const _sfc_main$dk = defineComponent({ name: 'CameraFilled', }) const _hoisted_1$aZ = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9z = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M160 224a64 64 0 0 0-64 64v512a64 64 0 0 0 64 64h704a64 64 0 0 0 64-64V288a64 64 0 0 0-64-64H748.416l-46.464-92.672A64 64 0 0 0 644.736 96H379.328a64 64 0 0 0-57.216 35.392L275.776 224H160zm352 435.2a115.2 115.2 0 1 0 0-230.4 115.2 115.2 0 0 0 0 230.4zm0 140.8a256 256 0 1 1 0-512 256 256 0 0 1 0 512z', }, null, -1 ) const _hoisted_3$8P = [_hoisted_2$9z] function _sfc_render$5H(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aZ, _hoisted_3$8P) } var cameraFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$dk, [ ['render', _sfc_render$5H], ]) const _sfc_main$dj = defineComponent({ name: 'Camera', }) const _hoisted_1$aY = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9y = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M896 256H128v576h768V256zm-199.424-64-32.064-64h-304.96l-32 64h369.024zM96 192h160l46.336-92.608A64 64 0 0 1 359.552 64h304.96a64 64 0 0 1 57.216 35.328L768.192 192H928a32 32 0 0 1 32 32v640a32 32 0 0 1-32 32H96a32 32 0 0 1-32-32V224a32 32 0 0 1 32-32zm416 512a160 160 0 1 0 0-320 160 160 0 0 0 0 320zm0 64a224 224 0 1 1 0-448 224 224 0 0 1 0 448z', }, null, -1 ) const _hoisted_3$8O = [_hoisted_2$9y] function _sfc_render$5G(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aY, _hoisted_3$8O) } var camera = /* @__PURE__ */ _export_sfc$2(_sfc_main$dj, [ ['render', _sfc_render$5G], ]) const _sfc_main$di = defineComponent({ name: 'CaretBottom', }) const _hoisted_1$aX = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9x = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm192 384 320 384 320-384z', }, null, -1 ) const _hoisted_3$8N = [_hoisted_2$9x] function _sfc_render$5F(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aX, _hoisted_3$8N) } var caretBottom = /* @__PURE__ */ _export_sfc$2(_sfc_main$di, [ ['render', _sfc_render$5F], ]) const _sfc_main$dh = defineComponent({ name: 'CaretLeft', }) const _hoisted_1$aW = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9w = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M672 192 288 511.936 672 832z', }, null, -1 ) const _hoisted_3$8M = [_hoisted_2$9w] function _sfc_render$5E(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aW, _hoisted_3$8M) } var caretLeft = /* @__PURE__ */ _export_sfc$2(_sfc_main$dh, [ ['render', _sfc_render$5E], ]) const _sfc_main$dg = defineComponent({ name: 'CaretRight', }) const _hoisted_1$aV = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9v = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M384 192v640l384-320.064z', }, null, -1 ) const _hoisted_3$8L = [_hoisted_2$9v] function _sfc_render$5D(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aV, _hoisted_3$8L) } var caretRight = /* @__PURE__ */ _export_sfc$2(_sfc_main$dg, [ ['render', _sfc_render$5D], ]) const _sfc_main$df = defineComponent({ name: 'CaretTop', }) const _hoisted_1$aU = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9u = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 320 192 704h639.936z', }, null, -1 ) const _hoisted_3$8K = [_hoisted_2$9u] function _sfc_render$5C(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aU, _hoisted_3$8K) } var caretTop = /* @__PURE__ */ _export_sfc$2(_sfc_main$df, [ ['render', _sfc_render$5C], ]) const _sfc_main$de = defineComponent({ name: 'Cellphone', }) const _hoisted_1$aT = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9t = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M256 128a64 64 0 0 0-64 64v640a64 64 0 0 0 64 64h512a64 64 0 0 0 64-64V192a64 64 0 0 0-64-64H256zm0-64h512a128 128 0 0 1 128 128v640a128 128 0 0 1-128 128H256a128 128 0 0 1-128-128V192A128 128 0 0 1 256 64zm128 128h256a32 32 0 1 1 0 64H384a32 32 0 0 1 0-64zm128 640a64 64 0 1 1 0-128 64 64 0 0 1 0 128z', }, null, -1 ) const _hoisted_3$8J = [_hoisted_2$9t] function _sfc_render$5B(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aT, _hoisted_3$8J) } var cellphone = /* @__PURE__ */ _export_sfc$2(_sfc_main$de, [ ['render', _sfc_render$5B], ]) const _sfc_main$dd = defineComponent({ name: 'ChatDotRound', }) const _hoisted_1$aS = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9s = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm174.72 855.68 135.296-45.12 23.68 11.84C388.096 849.536 448.576 864 512 864c211.84 0 384-166.784 384-352S723.84 160 512 160 128 326.784 128 512c0 69.12 24.96 139.264 70.848 199.232l22.08 28.8-46.272 115.584zm-45.248 82.56A32 32 0 0 1 89.6 896l58.368-145.92C94.72 680.32 64 596.864 64 512 64 299.904 256 96 512 96s448 203.904 448 416-192 416-448 416a461.056 461.056 0 0 1-206.912-48.384l-175.616 58.56z', }, null, -1 ) const _hoisted_3$8I = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 563.2a51.2 51.2 0 1 1 0-102.4 51.2 51.2 0 0 1 0 102.4zm192 0a51.2 51.2 0 1 1 0-102.4 51.2 51.2 0 0 1 0 102.4zm-384 0a51.2 51.2 0 1 1 0-102.4 51.2 51.2 0 0 1 0 102.4z', }, null, -1 ) const _hoisted_4$5g = [_hoisted_2$9s, _hoisted_3$8I] function _sfc_render$5A(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aS, _hoisted_4$5g) } var chatDotRound = /* @__PURE__ */ _export_sfc$2(_sfc_main$dd, [ ['render', _sfc_render$5A], ]) const _sfc_main$dc = defineComponent({ name: 'ChatDotSquare', }) const _hoisted_1$aR = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9r = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M273.536 736H800a64 64 0 0 0 64-64V256a64 64 0 0 0-64-64H224a64 64 0 0 0-64 64v570.88L273.536 736zM296 800 147.968 918.4A32 32 0 0 1 96 893.44V256a128 128 0 0 1 128-128h576a128 128 0 0 1 128 128v416a128 128 0 0 1-128 128H296z', }, null, -1 ) const _hoisted_3$8H = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 499.2a51.2 51.2 0 1 1 0-102.4 51.2 51.2 0 0 1 0 102.4zm192 0a51.2 51.2 0 1 1 0-102.4 51.2 51.2 0 0 1 0 102.4zm-384 0a51.2 51.2 0 1 1 0-102.4 51.2 51.2 0 0 1 0 102.4z', }, null, -1 ) const _hoisted_4$5f = [_hoisted_2$9r, _hoisted_3$8H] function _sfc_render$5z(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aR, _hoisted_4$5f) } var chatDotSquare = /* @__PURE__ */ _export_sfc$2(_sfc_main$dc, [ ['render', _sfc_render$5z], ]) const _sfc_main$db = defineComponent({ name: 'ChatLineRound', }) const _hoisted_1$aQ = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9q = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm174.72 855.68 135.296-45.12 23.68 11.84C388.096 849.536 448.576 864 512 864c211.84 0 384-166.784 384-352S723.84 160 512 160 128 326.784 128 512c0 69.12 24.96 139.264 70.848 199.232l22.08 28.8-46.272 115.584zm-45.248 82.56A32 32 0 0 1 89.6 896l58.368-145.92C94.72 680.32 64 596.864 64 512 64 299.904 256 96 512 96s448 203.904 448 416-192 416-448 416a461.056 461.056 0 0 1-206.912-48.384l-175.616 58.56z', }, null, -1 ) const _hoisted_3$8G = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M352 576h320q32 0 32 32t-32 32H352q-32 0-32-32t32-32zm32-192h256q32 0 32 32t-32 32H384q-32 0-32-32t32-32z', }, null, -1 ) const _hoisted_4$5e = [_hoisted_2$9q, _hoisted_3$8G] function _sfc_render$5y(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aQ, _hoisted_4$5e) } var chatLineRound = /* @__PURE__ */ _export_sfc$2(_sfc_main$db, [ ['render', _sfc_render$5y], ]) const _sfc_main$da = defineComponent({ name: 'ChatLineSquare', }) const _hoisted_1$aP = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9p = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M160 826.88 273.536 736H800a64 64 0 0 0 64-64V256a64 64 0 0 0-64-64H224a64 64 0 0 0-64 64v570.88zM296 800 147.968 918.4A32 32 0 0 1 96 893.44V256a128 128 0 0 1 128-128h576a128 128 0 0 1 128 128v416a128 128 0 0 1-128 128H296z', }, null, -1 ) const _hoisted_3$8F = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M352 512h320q32 0 32 32t-32 32H352q-32 0-32-32t32-32zm0-192h320q32 0 32 32t-32 32H352q-32 0-32-32t32-32z', }, null, -1 ) const _hoisted_4$5d = [_hoisted_2$9p, _hoisted_3$8F] function _sfc_render$5x(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aP, _hoisted_4$5d) } var chatLineSquare = /* @__PURE__ */ _export_sfc$2(_sfc_main$da, [ ['render', _sfc_render$5x], ]) const _sfc_main$d9 = defineComponent({ name: 'ChatRound', }) const _hoisted_1$aO = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9o = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm174.72 855.68 130.048-43.392 23.424 11.392C382.4 849.984 444.352 864 512 864c223.744 0 384-159.872 384-352 0-192.832-159.104-352-384-352S128 319.168 128 512a341.12 341.12 0 0 0 69.248 204.288l21.632 28.8-44.16 110.528zm-45.248 82.56A32 32 0 0 1 89.6 896l56.512-141.248A405.12 405.12 0 0 1 64 512C64 299.904 235.648 96 512 96s448 203.904 448 416-173.44 416-448 416c-79.68 0-150.848-17.152-211.712-46.72l-170.88 56.96z', }, null, -1 ) const _hoisted_3$8E = [_hoisted_2$9o] function _sfc_render$5w(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aO, _hoisted_3$8E) } var chatRound = /* @__PURE__ */ _export_sfc$2(_sfc_main$d9, [ ['render', _sfc_render$5w], ]) const _sfc_main$d8 = defineComponent({ name: 'ChatSquare', }) const _hoisted_1$aN = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9n = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M273.536 736H800a64 64 0 0 0 64-64V256a64 64 0 0 0-64-64H224a64 64 0 0 0-64 64v570.88L273.536 736zM296 800 147.968 918.4A32 32 0 0 1 96 893.44V256a128 128 0 0 1 128-128h576a128 128 0 0 1 128 128v416a128 128 0 0 1-128 128H296z', }, null, -1 ) const _hoisted_3$8D = [_hoisted_2$9n] function _sfc_render$5v(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aN, _hoisted_3$8D) } var chatSquare = /* @__PURE__ */ _export_sfc$2(_sfc_main$d8, [ ['render', _sfc_render$5v], ]) const _sfc_main$d7 = defineComponent({ name: 'Check', }) const _hoisted_1$aM = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9m = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M406.656 706.944 195.84 496.256a32 32 0 1 0-45.248 45.248l256 256 512-512a32 32 0 0 0-45.248-45.248L406.592 706.944z', }, null, -1 ) const _hoisted_3$8C = [_hoisted_2$9m] function _sfc_render$5u(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aM, _hoisted_3$8C) } var check$1 = /* @__PURE__ */ _export_sfc$2(_sfc_main$d7, [ ['render', _sfc_render$5u], ]) const _sfc_main$d6 = defineComponent({ name: 'Checked', }) const _hoisted_1$aL = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9l = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M704 192h160v736H160V192h160.064v64H704v-64zM311.616 537.28l-45.312 45.248L447.36 763.52l316.8-316.8-45.312-45.184L447.36 673.024 311.616 537.28zM384 192V96h256v96H384z', }, null, -1 ) const _hoisted_3$8B = [_hoisted_2$9l] function _sfc_render$5t(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aL, _hoisted_3$8B) } var checked = /* @__PURE__ */ _export_sfc$2(_sfc_main$d6, [ ['render', _sfc_render$5t], ]) const _sfc_main$d5 = defineComponent({ name: 'Cherry', }) const _hoisted_1$aK = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9k = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M261.056 449.6c13.824-69.696 34.88-128.96 63.36-177.728 23.744-40.832 61.12-88.64 112.256-143.872H320a32 32 0 0 1 0-64h384a32 32 0 1 1 0 64H554.752c14.912 39.168 41.344 86.592 79.552 141.76 47.36 68.48 84.8 106.752 106.304 114.304a224 224 0 1 1-84.992 14.784c-22.656-22.912-47.04-53.76-73.92-92.608-38.848-56.128-67.008-105.792-84.352-149.312-55.296 58.24-94.528 107.52-117.76 147.2-23.168 39.744-41.088 88.768-53.568 147.072a224.064 224.064 0 1 1-64.96-1.6zM288 832a160 160 0 1 0 0-320 160 160 0 0 0 0 320zm448-64a160 160 0 1 0 0-320 160 160 0 0 0 0 320z', }, null, -1 ) const _hoisted_3$8A = [_hoisted_2$9k] function _sfc_render$5s(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aK, _hoisted_3$8A) } var cherry = /* @__PURE__ */ _export_sfc$2(_sfc_main$d5, [ ['render', _sfc_render$5s], ]) const _sfc_main$d4 = defineComponent({ name: 'Chicken', }) const _hoisted_1$aJ = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9j = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M349.952 716.992 478.72 588.16a106.688 106.688 0 0 1-26.176-19.072 106.688 106.688 0 0 1-19.072-26.176L304.704 671.744c.768 3.072 1.472 6.144 2.048 9.216l2.048 31.936 31.872 1.984c3.136.64 6.208 1.28 9.28 2.112zm57.344 33.152a128 128 0 1 1-216.32 114.432l-1.92-32-32-1.92a128 128 0 1 1 114.432-216.32L416.64 469.248c-2.432-101.44 58.112-239.104 149.056-330.048 107.328-107.328 231.296-85.504 316.8 0 85.44 85.44 107.328 209.408 0 316.8-91.008 90.88-228.672 151.424-330.112 149.056L407.296 750.08zm90.496-226.304c49.536 49.536 233.344-7.04 339.392-113.088 78.208-78.208 63.232-163.072 0-226.304-63.168-63.232-148.032-78.208-226.24 0C504.896 290.496 448.32 474.368 497.792 523.84zM244.864 708.928a64 64 0 1 0-59.84 59.84l56.32-3.52 3.52-56.32zm8.064 127.68a64 64 0 1 0 59.84-59.84l-56.32 3.52-3.52 56.32z', }, null, -1 ) const _hoisted_3$8z = [_hoisted_2$9j] function _sfc_render$5r(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aJ, _hoisted_3$8z) } var chicken = /* @__PURE__ */ _export_sfc$2(_sfc_main$d4, [ ['render', _sfc_render$5r], ]) const _sfc_main$d3 = defineComponent({ name: 'CircleCheckFilled', }) const _hoisted_1$aI = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9i = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896zm-55.808 536.384-99.52-99.584a38.4 38.4 0 1 0-54.336 54.336l126.72 126.72a38.272 38.272 0 0 0 54.336 0l262.4-262.464a38.4 38.4 0 1 0-54.272-54.336L456.192 600.384z', }, null, -1 ) const _hoisted_3$8y = [_hoisted_2$9i] function _sfc_render$5q(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aI, _hoisted_3$8y) } var circleCheckFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$d3, [ ['render', _sfc_render$5q], ]) const _sfc_main$d2 = defineComponent({ name: 'CircleCheck', }) const _hoisted_1$aH = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9h = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 896a384 384 0 1 0 0-768 384 384 0 0 0 0 768zm0 64a448 448 0 1 1 0-896 448 448 0 0 1 0 896z', }, null, -1 ) const _hoisted_3$8x = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M745.344 361.344a32 32 0 0 1 45.312 45.312l-288 288a32 32 0 0 1-45.312 0l-160-160a32 32 0 1 1 45.312-45.312L480 626.752l265.344-265.408z', }, null, -1 ) const _hoisted_4$5c = [_hoisted_2$9h, _hoisted_3$8x] function _sfc_render$5p(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aH, _hoisted_4$5c) } var circleCheck = /* @__PURE__ */ _export_sfc$2(_sfc_main$d2, [ ['render', _sfc_render$5p], ]) const _sfc_main$d1 = defineComponent({ name: 'CircleCloseFilled', }) const _hoisted_1$aG = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9g = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896zm0 393.664L407.936 353.6a38.4 38.4 0 1 0-54.336 54.336L457.664 512 353.6 616.064a38.4 38.4 0 1 0 54.336 54.336L512 566.336 616.064 670.4a38.4 38.4 0 1 0 54.336-54.336L566.336 512 670.4 407.936a38.4 38.4 0 1 0-54.336-54.336L512 457.664z', }, null, -1 ) const _hoisted_3$8w = [_hoisted_2$9g] function _sfc_render$5o(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aG, _hoisted_3$8w) } var circleCloseFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$d1, [ ['render', _sfc_render$5o], ]) const _sfc_main$d0 = defineComponent({ name: 'CircleClose', }) const _hoisted_1$aF = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9f = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm466.752 512-90.496-90.496a32 32 0 0 1 45.248-45.248L512 466.752l90.496-90.496a32 32 0 1 1 45.248 45.248L557.248 512l90.496 90.496a32 32 0 1 1-45.248 45.248L512 557.248l-90.496 90.496a32 32 0 0 1-45.248-45.248L466.752 512z', }, null, -1 ) const _hoisted_3$8v = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 896a384 384 0 1 0 0-768 384 384 0 0 0 0 768zm0 64a448 448 0 1 1 0-896 448 448 0 0 1 0 896z', }, null, -1 ) const _hoisted_4$5b = [_hoisted_2$9f, _hoisted_3$8v] function _sfc_render$5n(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aF, _hoisted_4$5b) } var circleClose = /* @__PURE__ */ _export_sfc$2(_sfc_main$d0, [ ['render', _sfc_render$5n], ]) const _sfc_main$c$ = defineComponent({ name: 'CirclePlusFilled', }) const _hoisted_1$aE = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9e = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896zm-38.4 409.6H326.4a38.4 38.4 0 1 0 0 76.8h147.2v147.2a38.4 38.4 0 0 0 76.8 0V550.4h147.2a38.4 38.4 0 0 0 0-76.8H550.4V326.4a38.4 38.4 0 1 0-76.8 0v147.2z', }, null, -1 ) const _hoisted_3$8u = [_hoisted_2$9e] function _sfc_render$5m(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aE, _hoisted_3$8u) } var circlePlusFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$c$, [ ['render', _sfc_render$5m], ]) const _sfc_main$c_ = defineComponent({ name: 'CirclePlus', }) const _hoisted_1$aD = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9d = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M352 480h320a32 32 0 1 1 0 64H352a32 32 0 0 1 0-64z', }, null, -1 ) const _hoisted_3$8t = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M480 672V352a32 32 0 1 1 64 0v320a32 32 0 0 1-64 0z', }, null, -1 ) const _hoisted_4$5a = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 896a384 384 0 1 0 0-768 384 384 0 0 0 0 768zm0 64a448 448 0 1 1 0-896 448 448 0 0 1 0 896z', }, null, -1 ) const _hoisted_5$3Y = [_hoisted_2$9d, _hoisted_3$8t, _hoisted_4$5a] function _sfc_render$5l(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aD, _hoisted_5$3Y) } var circlePlus = /* @__PURE__ */ _export_sfc$2(_sfc_main$c_, [ ['render', _sfc_render$5l], ]) const _sfc_main$cZ = defineComponent({ name: 'Clock', }) const _hoisted_1$aC = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9c = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 896a384 384 0 1 0 0-768 384 384 0 0 0 0 768zm0 64a448 448 0 1 1 0-896 448 448 0 0 1 0 896z', }, null, -1 ) const _hoisted_3$8s = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M480 256a32 32 0 0 1 32 32v256a32 32 0 0 1-64 0V288a32 32 0 0 1 32-32z', }, null, -1 ) const _hoisted_4$59 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M480 512h256q32 0 32 32t-32 32H480q-32 0-32-32t32-32z', }, null, -1 ) const _hoisted_5$3X = [_hoisted_2$9c, _hoisted_3$8s, _hoisted_4$59] function _sfc_render$5k(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aC, _hoisted_5$3X) } var clock = /* @__PURE__ */ _export_sfc$2(_sfc_main$cZ, [ ['render', _sfc_render$5k], ]) const _sfc_main$cY = defineComponent({ name: 'CloseBold', }) const _hoisted_1$aB = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9b = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M195.2 195.2a64 64 0 0 1 90.496 0L512 421.504 738.304 195.2a64 64 0 0 1 90.496 90.496L602.496 512 828.8 738.304a64 64 0 0 1-90.496 90.496L512 602.496 285.696 828.8a64 64 0 0 1-90.496-90.496L421.504 512 195.2 285.696a64 64 0 0 1 0-90.496z', }, null, -1 ) const _hoisted_3$8r = [_hoisted_2$9b] function _sfc_render$5j(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aB, _hoisted_3$8r) } var closeBold = /* @__PURE__ */ _export_sfc$2(_sfc_main$cY, [ ['render', _sfc_render$5j], ]) const _sfc_main$cX = defineComponent({ name: 'Close', }) const _hoisted_1$aA = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$9a = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M764.288 214.592 512 466.88 259.712 214.592a31.936 31.936 0 0 0-45.12 45.12L466.752 512 214.528 764.224a31.936 31.936 0 1 0 45.12 45.184L512 557.184l252.288 252.288a31.936 31.936 0 0 0 45.12-45.12L557.12 512.064l252.288-252.352a31.936 31.936 0 1 0-45.12-45.184z', }, null, -1 ) const _hoisted_3$8q = [_hoisted_2$9a] function _sfc_render$5i(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aA, _hoisted_3$8q) } var close$2 = /* @__PURE__ */ _export_sfc$2(_sfc_main$cX, [ ['render', _sfc_render$5i], ]) const _sfc_main$cW = defineComponent({ name: 'Cloudy', }) const _hoisted_1$az = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$99 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M598.4 831.872H328.192a256 256 0 0 1-34.496-510.528A352 352 0 1 1 598.4 831.872zm-271.36-64h272.256a288 288 0 1 0-248.512-417.664L335.04 381.44l-34.816 3.584a192 192 0 0 0 26.88 382.848z', }, null, -1 ) const _hoisted_3$8p = [_hoisted_2$99] function _sfc_render$5h(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$az, _hoisted_3$8p) } var cloudy = /* @__PURE__ */ _export_sfc$2(_sfc_main$cW, [ ['render', _sfc_render$5h], ]) const _sfc_main$cV = defineComponent({ name: 'CoffeeCup', }) const _hoisted_1$ay = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$98 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M768 192a192 192 0 1 1-8 383.808A256.128 256.128 0 0 1 512 768H320A256 256 0 0 1 64 512V160a32 32 0 0 1 32-32h640a32 32 0 0 1 32 32v32zm0 64v256a128 128 0 1 0 0-256zM96 832h640a32 32 0 1 1 0 64H96a32 32 0 1 1 0-64zm32-640v320a192 192 0 0 0 192 192h192a192 192 0 0 0 192-192V192H128z', }, null, -1 ) const _hoisted_3$8o = [_hoisted_2$98] function _sfc_render$5g(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$ay, _hoisted_3$8o) } var coffeeCup = /* @__PURE__ */ _export_sfc$2(_sfc_main$cV, [ ['render', _sfc_render$5g], ]) const _sfc_main$cU = defineComponent({ name: 'Coffee', }) const _hoisted_1$ax = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$97 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M822.592 192h14.272a32 32 0 0 1 31.616 26.752l21.312 128A32 32 0 0 1 858.24 384h-49.344l-39.04 546.304A32 32 0 0 1 737.92 960H285.824a32 32 0 0 1-32-29.696L214.912 384H165.76a32 32 0 0 1-31.552-37.248l21.312-128A32 32 0 0 1 187.136 192h14.016l-6.72-93.696A32 32 0 0 1 226.368 64h571.008a32 32 0 0 1 31.936 34.304L822.592 192zm-64.128 0 4.544-64H260.736l4.544 64h493.184zm-548.16 128H820.48l-10.688-64H214.208l-10.688 64h6.784zm68.736 64 36.544 512H708.16l36.544-512H279.04z', }, null, -1 ) const _hoisted_3$8n = [_hoisted_2$97] function _sfc_render$5f(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$ax, _hoisted_3$8n) } var coffee = /* @__PURE__ */ _export_sfc$2(_sfc_main$cU, [ ['render', _sfc_render$5f], ]) const _sfc_main$cT = defineComponent({ name: 'Coin', }) const _hoisted_1$aw = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$96 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm161.92 580.736 29.888 58.88C171.328 659.776 160 681.728 160 704c0 82.304 155.328 160 352 160s352-77.696 352-160c0-22.272-11.392-44.16-31.808-64.32l30.464-58.432C903.936 615.808 928 657.664 928 704c0 129.728-188.544 224-416 224S96 833.728 96 704c0-46.592 24.32-88.576 65.92-123.264z', }, null, -1 ) const _hoisted_3$8m = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm161.92 388.736 29.888 58.88C171.328 467.84 160 489.792 160 512c0 82.304 155.328 160 352 160s352-77.696 352-160c0-22.272-11.392-44.16-31.808-64.32l30.464-58.432C903.936 423.808 928 465.664 928 512c0 129.728-188.544 224-416 224S96 641.728 96 512c0-46.592 24.32-88.576 65.92-123.264z', }, null, -1 ) const _hoisted_4$58 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 544c-227.456 0-416-94.272-416-224S284.544 96 512 96s416 94.272 416 224-188.544 224-416 224zm0-64c196.672 0 352-77.696 352-160S708.672 160 512 160s-352 77.696-352 160 155.328 160 352 160z', }, null, -1 ) const _hoisted_5$3W = [_hoisted_2$96, _hoisted_3$8m, _hoisted_4$58] function _sfc_render$5e(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aw, _hoisted_5$3W) } var coin = /* @__PURE__ */ _export_sfc$2(_sfc_main$cT, [ ['render', _sfc_render$5e], ]) const _sfc_main$cS = defineComponent({ name: 'ColdDrink', }) const _hoisted_1$av = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$95 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M768 64a192 192 0 1 1-69.952 370.88L480 725.376V896h96a32 32 0 1 1 0 64H320a32 32 0 1 1 0-64h96V725.376L76.8 273.536a64 64 0 0 1-12.8-38.4v-10.688a32 32 0 0 1 32-32h71.808l-65.536-83.84a32 32 0 0 1 50.432-39.424l96.256 123.264h337.728A192.064 192.064 0 0 1 768 64zM656.896 192.448H800a32 32 0 0 1 32 32v10.624a64 64 0 0 1-12.8 38.4l-80.448 107.2a128 128 0 1 0-81.92-188.16v-.064zm-357.888 64 129.472 165.76a32 32 0 0 1-50.432 39.36l-160.256-205.12H144l304 404.928 304-404.928H299.008z', }, null, -1 ) const _hoisted_3$8l = [_hoisted_2$95] function _sfc_render$5d(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$av, _hoisted_3$8l) } var coldDrink = /* @__PURE__ */ _export_sfc$2(_sfc_main$cS, [ ['render', _sfc_render$5d], ]) const _sfc_main$cR = defineComponent({ name: 'CollectionTag', }) const _hoisted_1$au = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$94 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M256 128v698.88l196.032-156.864a96 96 0 0 1 119.936 0L768 826.816V128H256zm-32-64h576a32 32 0 0 1 32 32v797.44a32 32 0 0 1-51.968 24.96L531.968 720a32 32 0 0 0-39.936 0L243.968 918.4A32 32 0 0 1 192 893.44V96a32 32 0 0 1 32-32z', }, null, -1 ) const _hoisted_3$8k = [_hoisted_2$94] function _sfc_render$5c(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$au, _hoisted_3$8k) } var collectionTag = /* @__PURE__ */ _export_sfc$2(_sfc_main$cR, [ ['render', _sfc_render$5c], ]) const _sfc_main$cQ = defineComponent({ name: 'Collection', }) const _hoisted_1$at = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$93 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M192 736h640V128H256a64 64 0 0 0-64 64v544zm64-672h608a32 32 0 0 1 32 32v672a32 32 0 0 1-32 32H160l-32 57.536V192A128 128 0 0 1 256 64z', }, null, -1 ) const _hoisted_3$8j = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M240 800a48 48 0 1 0 0 96h592v-96H240zm0-64h656v160a64 64 0 0 1-64 64H240a112 112 0 0 1 0-224zm144-608v250.88l96-76.8 96 76.8V128H384zm-64-64h320v381.44a32 32 0 0 1-51.968 24.96L480 384l-108.032 86.4A32 32 0 0 1 320 445.44V64z', }, null, -1 ) const _hoisted_4$57 = [_hoisted_2$93, _hoisted_3$8j] function _sfc_render$5b(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$at, _hoisted_4$57) } var collection = /* @__PURE__ */ _export_sfc$2(_sfc_main$cQ, [ ['render', _sfc_render$5b], ]) const _sfc_main$cP = defineComponent({ name: 'Comment', }) const _hoisted_1$as = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$92 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M736 504a56 56 0 1 1 0-112 56 56 0 0 1 0 112zm-224 0a56 56 0 1 1 0-112 56 56 0 0 1 0 112zm-224 0a56 56 0 1 1 0-112 56 56 0 0 1 0 112zM128 128v640h192v160l224-160h352V128H128z', }, null, -1 ) const _hoisted_3$8i = [_hoisted_2$92] function _sfc_render$5a(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$as, _hoisted_3$8i) } var comment = /* @__PURE__ */ _export_sfc$2(_sfc_main$cP, [ ['render', _sfc_render$5a], ]) const _sfc_main$cO = defineComponent({ name: 'Compass', }) const _hoisted_1$ar = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$91 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 896a384 384 0 1 0 0-768 384 384 0 0 0 0 768zm0 64a448 448 0 1 1 0-896 448 448 0 0 1 0 896z', }, null, -1 ) const _hoisted_3$8h = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M725.888 315.008C676.48 428.672 624 513.28 568.576 568.64c-55.424 55.424-139.968 107.904-253.568 157.312a12.8 12.8 0 0 1-16.896-16.832c49.536-113.728 102.016-198.272 157.312-253.632 55.36-55.296 139.904-107.776 253.632-157.312a12.8 12.8 0 0 1 16.832 16.832z', }, null, -1 ) const _hoisted_4$56 = [_hoisted_2$91, _hoisted_3$8h] function _sfc_render$59(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$ar, _hoisted_4$56) } var compass = /* @__PURE__ */ _export_sfc$2(_sfc_main$cO, [ ['render', _sfc_render$59], ]) const _sfc_main$cN = defineComponent({ name: 'Connection', }) const _hoisted_1$aq = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$90 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M640 384v64H448a128 128 0 0 0-128 128v128a128 128 0 0 0 128 128h320a128 128 0 0 0 128-128V576a128 128 0 0 0-64-110.848V394.88c74.56 26.368 128 97.472 128 181.056v128a192 192 0 0 1-192 192H448a192 192 0 0 1-192-192V576a192 192 0 0 1 192-192h192z', }, null, -1 ) const _hoisted_3$8g = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M384 640v-64h192a128 128 0 0 0 128-128V320a128 128 0 0 0-128-128H256a128 128 0 0 0-128 128v128a128 128 0 0 0 64 110.848v70.272A192.064 192.064 0 0 1 64 448V320a192 192 0 0 1 192-192h320a192 192 0 0 1 192 192v128a192 192 0 0 1-192 192H384z', }, null, -1 ) const _hoisted_4$55 = [_hoisted_2$90, _hoisted_3$8g] function _sfc_render$58(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aq, _hoisted_4$55) } var connection = /* @__PURE__ */ _export_sfc$2(_sfc_main$cN, [ ['render', _sfc_render$58], ]) const _sfc_main$cM = defineComponent({ name: 'Coordinate', }) const _hoisted_1$ap = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8$ = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M480 512h64v320h-64z', }, null, -1 ) const _hoisted_3$8f = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M192 896h640a64 64 0 0 0-64-64H256a64 64 0 0 0-64 64zm64-128h512a128 128 0 0 1 128 128v64H128v-64a128 128 0 0 1 128-128zm256-256a192 192 0 1 0 0-384 192 192 0 0 0 0 384zm0 64a256 256 0 1 1 0-512 256 256 0 0 1 0 512z', }, null, -1 ) const _hoisted_4$54 = [_hoisted_2$8$, _hoisted_3$8f] function _sfc_render$57(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$ap, _hoisted_4$54) } var coordinate = /* @__PURE__ */ _export_sfc$2(_sfc_main$cM, [ ['render', _sfc_render$57], ]) const _sfc_main$cL = defineComponent({ name: 'CopyDocument', }) const _hoisted_1$ao = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8_ = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M768 832a128 128 0 0 1-128 128H192A128 128 0 0 1 64 832V384a128 128 0 0 1 128-128v64a64 64 0 0 0-64 64v448a64 64 0 0 0 64 64h448a64 64 0 0 0 64-64h64z', }, null, -1 ) const _hoisted_3$8e = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M384 128a64 64 0 0 0-64 64v448a64 64 0 0 0 64 64h448a64 64 0 0 0 64-64V192a64 64 0 0 0-64-64H384zm0-64h448a128 128 0 0 1 128 128v448a128 128 0 0 1-128 128H384a128 128 0 0 1-128-128V192A128 128 0 0 1 384 64z', }, null, -1 ) const _hoisted_4$53 = [_hoisted_2$8_, _hoisted_3$8e] function _sfc_render$56(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$ao, _hoisted_4$53) } var copyDocument = /* @__PURE__ */ _export_sfc$2(_sfc_main$cL, [ ['render', _sfc_render$56], ]) const _sfc_main$cK = defineComponent({ name: 'Cpu', }) const _hoisted_1$an = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8Z = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M320 256a64 64 0 0 0-64 64v384a64 64 0 0 0 64 64h384a64 64 0 0 0 64-64V320a64 64 0 0 0-64-64H320zm0-64h384a128 128 0 0 1 128 128v384a128 128 0 0 1-128 128H320a128 128 0 0 1-128-128V320a128 128 0 0 1 128-128z', }, null, -1 ) const _hoisted_3$8d = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 64a32 32 0 0 1 32 32v128h-64V96a32 32 0 0 1 32-32zm160 0a32 32 0 0 1 32 32v128h-64V96a32 32 0 0 1 32-32zm-320 0a32 32 0 0 1 32 32v128h-64V96a32 32 0 0 1 32-32zm160 896a32 32 0 0 1-32-32V800h64v128a32 32 0 0 1-32 32zm160 0a32 32 0 0 1-32-32V800h64v128a32 32 0 0 1-32 32zm-320 0a32 32 0 0 1-32-32V800h64v128a32 32 0 0 1-32 32zM64 512a32 32 0 0 1 32-32h128v64H96a32 32 0 0 1-32-32zm0-160a32 32 0 0 1 32-32h128v64H96a32 32 0 0 1-32-32zm0 320a32 32 0 0 1 32-32h128v64H96a32 32 0 0 1-32-32zm896-160a32 32 0 0 1-32 32H800v-64h128a32 32 0 0 1 32 32zm0-160a32 32 0 0 1-32 32H800v-64h128a32 32 0 0 1 32 32zm0 320a32 32 0 0 1-32 32H800v-64h128a32 32 0 0 1 32 32z', }, null, -1 ) const _hoisted_4$52 = [_hoisted_2$8Z, _hoisted_3$8d] function _sfc_render$55(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$an, _hoisted_4$52) } var cpu = /* @__PURE__ */ _export_sfc$2(_sfc_main$cK, [ ['render', _sfc_render$55], ]) const _sfc_main$cJ = defineComponent({ name: 'CreditCard', }) const _hoisted_1$am = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8Y = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M896 324.096c0-42.368-2.496-55.296-9.536-68.48a52.352 52.352 0 0 0-22.144-22.08c-13.12-7.04-26.048-9.536-68.416-9.536H228.096c-42.368 0-55.296 2.496-68.48 9.536a52.352 52.352 0 0 0-22.08 22.144c-7.04 13.12-9.536 26.048-9.536 68.416v375.808c0 42.368 2.496 55.296 9.536 68.48a52.352 52.352 0 0 0 22.144 22.08c13.12 7.04 26.048 9.536 68.416 9.536h567.808c42.368 0 55.296-2.496 68.48-9.536a52.352 52.352 0 0 0 22.08-22.144c7.04-13.12 9.536-26.048 9.536-68.416V324.096zm64 0v375.808c0 57.088-5.952 77.76-17.088 98.56-11.136 20.928-27.52 37.312-48.384 48.448-20.864 11.136-41.6 17.088-98.56 17.088H228.032c-57.088 0-77.76-5.952-98.56-17.088a116.288 116.288 0 0 1-48.448-48.384c-11.136-20.864-17.088-41.6-17.088-98.56V324.032c0-57.088 5.952-77.76 17.088-98.56 11.136-20.928 27.52-37.312 48.384-48.448 20.864-11.136 41.6-17.088 98.56-17.088H795.84c57.088 0 77.76 5.952 98.56 17.088 20.928 11.136 37.312 27.52 48.448 48.384 11.136 20.864 17.088 41.6 17.088 98.56z', }, null, -1 ) const _hoisted_3$8c = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M64 320h896v64H64v-64zm0 128h896v64H64v-64zm128 192h256v64H192z', }, null, -1 ) const _hoisted_4$51 = [_hoisted_2$8Y, _hoisted_3$8c] function _sfc_render$54(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$am, _hoisted_4$51) } var creditCard = /* @__PURE__ */ _export_sfc$2(_sfc_main$cJ, [ ['render', _sfc_render$54], ]) const _sfc_main$cI = defineComponent({ name: 'Crop', }) const _hoisted_1$al = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8X = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M256 768h672a32 32 0 1 1 0 64H224a32 32 0 0 1-32-32V96a32 32 0 0 1 64 0v672z', }, null, -1 ) const _hoisted_3$8b = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M832 224v704a32 32 0 1 1-64 0V256H96a32 32 0 0 1 0-64h704a32 32 0 0 1 32 32z', }, null, -1 ) const _hoisted_4$50 = [_hoisted_2$8X, _hoisted_3$8b] function _sfc_render$53(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$al, _hoisted_4$50) } var crop = /* @__PURE__ */ _export_sfc$2(_sfc_main$cI, [ ['render', _sfc_render$53], ]) const _sfc_main$cH = defineComponent({ name: 'DArrowLeft', }) const _hoisted_1$ak = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8W = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M529.408 149.376a29.12 29.12 0 0 1 41.728 0 30.592 30.592 0 0 1 0 42.688L259.264 511.936l311.872 319.936a30.592 30.592 0 0 1-.512 43.264 29.12 29.12 0 0 1-41.216-.512L197.76 534.272a32 32 0 0 1 0-44.672l331.648-340.224zm256 0a29.12 29.12 0 0 1 41.728 0 30.592 30.592 0 0 1 0 42.688L515.264 511.936l311.872 319.936a30.592 30.592 0 0 1-.512 43.264 29.12 29.12 0 0 1-41.216-.512L453.76 534.272a32 32 0 0 1 0-44.672l331.648-340.224z', }, null, -1 ) const _hoisted_3$8a = [_hoisted_2$8W] function _sfc_render$52(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$ak, _hoisted_3$8a) } var dArrowLeft = /* @__PURE__ */ _export_sfc$2(_sfc_main$cH, [ ['render', _sfc_render$52], ]) const _sfc_main$cG = defineComponent({ name: 'DArrowRight', }) const _hoisted_1$aj = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8V = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M452.864 149.312a29.12 29.12 0 0 1 41.728.064L826.24 489.664a32 32 0 0 1 0 44.672L494.592 874.624a29.12 29.12 0 0 1-41.728 0 30.592 30.592 0 0 1 0-42.752L764.736 512 452.864 192a30.592 30.592 0 0 1 0-42.688zm-256 0a29.12 29.12 0 0 1 41.728.064L570.24 489.664a32 32 0 0 1 0 44.672L238.592 874.624a29.12 29.12 0 0 1-41.728 0 30.592 30.592 0 0 1 0-42.752L508.736 512 196.864 192a30.592 30.592 0 0 1 0-42.688z', }, null, -1 ) const _hoisted_3$89 = [_hoisted_2$8V] function _sfc_render$51(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aj, _hoisted_3$89) } var dArrowRight = /* @__PURE__ */ _export_sfc$2(_sfc_main$cG, [ ['render', _sfc_render$51], ]) const _sfc_main$cF = defineComponent({ name: 'DCaret', }) const _hoisted_1$ai = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8U = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm512 128 288 320H224l288-320zM224 576h576L512 896 224 576z', }, null, -1 ) const _hoisted_3$88 = [_hoisted_2$8U] function _sfc_render$50(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$ai, _hoisted_3$88) } var dCaret = /* @__PURE__ */ _export_sfc$2(_sfc_main$cF, [ ['render', _sfc_render$50], ]) const _sfc_main$cE = defineComponent({ name: 'DataAnalysis', }) const _hoisted_1$ah = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8T = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm665.216 768 110.848 192h-73.856L591.36 768H433.024L322.176 960H248.32l110.848-192H160a32 32 0 0 1-32-32V192H64a32 32 0 0 1 0-64h896a32 32 0 1 1 0 64h-64v544a32 32 0 0 1-32 32H665.216zM832 192H192v512h640V192zM352 448a32 32 0 0 1 32 32v64a32 32 0 0 1-64 0v-64a32 32 0 0 1 32-32zm160-64a32 32 0 0 1 32 32v128a32 32 0 0 1-64 0V416a32 32 0 0 1 32-32zm160-64a32 32 0 0 1 32 32v192a32 32 0 1 1-64 0V352a32 32 0 0 1 32-32z', }, null, -1 ) const _hoisted_3$87 = [_hoisted_2$8T] function _sfc_render$4$(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$ah, _hoisted_3$87) } var dataAnalysis = /* @__PURE__ */ _export_sfc$2(_sfc_main$cE, [ ['render', _sfc_render$4$], ]) const _sfc_main$cD = defineComponent({ name: 'DataBoard', }) const _hoisted_1$ag = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8S = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M32 128h960v64H32z', }, null, -1 ) const _hoisted_3$86 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M192 192v512h640V192H192zm-64-64h768v608a32 32 0 0 1-32 32H160a32 32 0 0 1-32-32V128z', }, null, -1 ) const _hoisted_4$4$ = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M322.176 960H248.32l144.64-250.56 55.424 32L322.176 960zm453.888 0h-73.856L576 741.44l55.424-32L776.064 960z', }, null, -1 ) const _hoisted_5$3V = [_hoisted_2$8S, _hoisted_3$86, _hoisted_4$4$] function _sfc_render$4_(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$ag, _hoisted_5$3V) } var dataBoard = /* @__PURE__ */ _export_sfc$2(_sfc_main$cD, [ ['render', _sfc_render$4_], ]) const _sfc_main$cC = defineComponent({ name: 'DataLine', }) const _hoisted_1$af = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8R = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M359.168 768H160a32 32 0 0 1-32-32V192H64a32 32 0 0 1 0-64h896a32 32 0 1 1 0 64h-64v544a32 32 0 0 1-32 32H665.216l110.848 192h-73.856L591.36 768H433.024L322.176 960H248.32l110.848-192zM832 192H192v512h640V192zM342.656 534.656a32 32 0 1 1-45.312-45.312L444.992 341.76l125.44 94.08L679.04 300.032a32 32 0 1 1 49.92 39.936L581.632 524.224 451.008 426.24 342.656 534.592z', }, null, -1 ) const _hoisted_3$85 = [_hoisted_2$8R] function _sfc_render$4Z(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$af, _hoisted_3$85) } var dataLine = /* @__PURE__ */ _export_sfc$2(_sfc_main$cC, [ ['render', _sfc_render$4Z], ]) const _sfc_main$cB = defineComponent({ name: 'DeleteFilled', }) const _hoisted_1$ae = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8Q = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M352 192V95.936a32 32 0 0 1 32-32h256a32 32 0 0 1 32 32V192h256a32 32 0 1 1 0 64H96a32 32 0 0 1 0-64h256zm64 0h192v-64H416v64zM192 960a32 32 0 0 1-32-32V256h704v672a32 32 0 0 1-32 32H192zm224-192a32 32 0 0 0 32-32V416a32 32 0 0 0-64 0v320a32 32 0 0 0 32 32zm192 0a32 32 0 0 0 32-32V416a32 32 0 0 0-64 0v320a32 32 0 0 0 32 32z', }, null, -1 ) const _hoisted_3$84 = [_hoisted_2$8Q] function _sfc_render$4Y(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$ae, _hoisted_3$84) } var deleteFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$cB, [ ['render', _sfc_render$4Y], ]) const _sfc_main$cA = defineComponent({ name: 'DeleteLocation', }) const _hoisted_1$ad = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8P = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M288 896h448q32 0 32 32t-32 32H288q-32 0-32-32t32-32z', }, null, -1 ) const _hoisted_3$83 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M800 416a288 288 0 1 0-576 0c0 118.144 94.528 272.128 288 456.576C705.472 688.128 800 534.144 800 416zM512 960C277.312 746.688 160 565.312 160 416a352 352 0 0 1 704 0c0 149.312-117.312 330.688-352 544z', }, null, -1 ) const _hoisted_4$4_ = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M384 384h256q32 0 32 32t-32 32H384q-32 0-32-32t32-32z', }, null, -1 ) const _hoisted_5$3U = [_hoisted_2$8P, _hoisted_3$83, _hoisted_4$4_] function _sfc_render$4X(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$ad, _hoisted_5$3U) } var deleteLocation = /* @__PURE__ */ _export_sfc$2(_sfc_main$cA, [ ['render', _sfc_render$4X], ]) const _sfc_main$cz = defineComponent({ name: 'Delete', }) const _hoisted_1$ac = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8O = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M160 256H96a32 32 0 0 1 0-64h256V95.936a32 32 0 0 1 32-32h256a32 32 0 0 1 32 32V192h256a32 32 0 1 1 0 64h-64v672a32 32 0 0 1-32 32H192a32 32 0 0 1-32-32V256zm448-64v-64H416v64h192zM224 896h576V256H224v640zm192-128a32 32 0 0 1-32-32V416a32 32 0 0 1 64 0v320a32 32 0 0 1-32 32zm192 0a32 32 0 0 1-32-32V416a32 32 0 0 1 64 0v320a32 32 0 0 1-32 32z', }, null, -1 ) const _hoisted_3$82 = [_hoisted_2$8O] function _sfc_render$4W(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$ac, _hoisted_3$82) } var _delete = /* @__PURE__ */ _export_sfc$2(_sfc_main$cz, [ ['render', _sfc_render$4W], ]) const _sfc_main$cy = defineComponent({ name: 'Dessert', }) const _hoisted_1$ab = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8N = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M128 416v-48a144 144 0 0 1 168.64-141.888 224.128 224.128 0 0 1 430.72 0A144 144 0 0 1 896 368v48a384 384 0 0 1-352 382.72V896h-64v-97.28A384 384 0 0 1 128 416zm287.104-32.064h193.792a143.808 143.808 0 0 1 58.88-132.736 160.064 160.064 0 0 0-311.552 0 143.808 143.808 0 0 1 58.88 132.8zm-72.896 0a72 72 0 1 0-140.48 0h140.48zm339.584 0h140.416a72 72 0 1 0-140.48 0zM512 736a320 320 0 0 0 318.4-288.064H193.6A320 320 0 0 0 512 736zM384 896.064h256a32 32 0 1 1 0 64H384a32 32 0 1 1 0-64z', }, null, -1 ) const _hoisted_3$81 = [_hoisted_2$8N] function _sfc_render$4V(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$ab, _hoisted_3$81) } var dessert = /* @__PURE__ */ _export_sfc$2(_sfc_main$cy, [ ['render', _sfc_render$4V], ]) const _sfc_main$cx = defineComponent({ name: 'Discount', }) const _hoisted_1$aa = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8M = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M224 704h576V318.336L552.512 115.84a64 64 0 0 0-81.024 0L224 318.336V704zm0 64v128h576V768H224zM593.024 66.304l259.2 212.096A32 32 0 0 1 864 303.168V928a32 32 0 0 1-32 32H192a32 32 0 0 1-32-32V303.168a32 32 0 0 1 11.712-24.768l259.2-212.096a128 128 0 0 1 162.112 0z', }, null, -1 ) const _hoisted_3$80 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 448a64 64 0 1 0 0-128 64 64 0 0 0 0 128zm0 64a128 128 0 1 1 0-256 128 128 0 0 1 0 256z', }, null, -1 ) const _hoisted_4$4Z = [_hoisted_2$8M, _hoisted_3$80] function _sfc_render$4U(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$aa, _hoisted_4$4Z) } var discount = /* @__PURE__ */ _export_sfc$2(_sfc_main$cx, [ ['render', _sfc_render$4U], ]) const _sfc_main$cw = defineComponent({ name: 'DishDot', }) const _hoisted_1$a9 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8L = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm384.064 274.56.064-50.688A128 128 0 0 1 512.128 96c70.528 0 127.68 57.152 127.68 127.68v50.752A448.192 448.192 0 0 1 955.392 768H68.544A448.192 448.192 0 0 1 384 274.56zM96 832h832a32 32 0 1 1 0 64H96a32 32 0 1 1 0-64zm32-128h768a384 384 0 1 0-768 0zm447.808-448v-32.32a63.68 63.68 0 0 0-63.68-63.68 64 64 0 0 0-64 63.936V256h127.68z', }, null, -1 ) const _hoisted_3$7$ = [_hoisted_2$8L] function _sfc_render$4T(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$a9, _hoisted_3$7$) } var dishDot = /* @__PURE__ */ _export_sfc$2(_sfc_main$cw, [ ['render', _sfc_render$4T], ]) const _sfc_main$cv = defineComponent({ name: 'Dish', }) const _hoisted_1$a8 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8K = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M480 257.152V192h-96a32 32 0 0 1 0-64h256a32 32 0 1 1 0 64h-96v65.152A448 448 0 0 1 955.52 768H68.48A448 448 0 0 1 480 257.152zM128 704h768a384 384 0 1 0-768 0zM96 832h832a32 32 0 1 1 0 64H96a32 32 0 1 1 0-64z', }, null, -1 ) const _hoisted_3$7_ = [_hoisted_2$8K] function _sfc_render$4S(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$a8, _hoisted_3$7_) } var dish = /* @__PURE__ */ _export_sfc$2(_sfc_main$cv, [ ['render', _sfc_render$4S], ]) const _sfc_main$cu = defineComponent({ name: 'DocumentAdd', }) const _hoisted_1$a7 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8J = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M832 384H576V128H192v768h640V384zm-26.496-64L640 154.496V320h165.504zM160 64h480l256 256v608a32 32 0 0 1-32 32H160a32 32 0 0 1-32-32V96a32 32 0 0 1 32-32zm320 512V448h64v128h128v64H544v128h-64V640H352v-64h128z', }, null, -1 ) const _hoisted_3$7Z = [_hoisted_2$8J] function _sfc_render$4R(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$a7, _hoisted_3$7Z) } var documentAdd = /* @__PURE__ */ _export_sfc$2(_sfc_main$cu, [ ['render', _sfc_render$4R], ]) const _sfc_main$ct = defineComponent({ name: 'DocumentChecked', }) const _hoisted_1$a6 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8I = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M805.504 320 640 154.496V320h165.504zM832 384H576V128H192v768h640V384zM160 64h480l256 256v608a32 32 0 0 1-32 32H160a32 32 0 0 1-32-32V96a32 32 0 0 1 32-32zm318.4 582.144 180.992-180.992L704.64 510.4 478.4 736.64 320 578.304l45.248-45.312L478.4 646.144z', }, null, -1 ) const _hoisted_3$7Y = [_hoisted_2$8I] function _sfc_render$4Q(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$a6, _hoisted_3$7Y) } var documentChecked = /* @__PURE__ */ _export_sfc$2(_sfc_main$ct, [ ['render', _sfc_render$4Q], ]) const _sfc_main$cs = defineComponent({ name: 'DocumentCopy', }) const _hoisted_1$a5 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8H = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M128 320v576h576V320H128zm-32-64h640a32 32 0 0 1 32 32v640a32 32 0 0 1-32 32H96a32 32 0 0 1-32-32V288a32 32 0 0 1 32-32zM960 96v704a32 32 0 0 1-32 32h-96v-64h64V128H384v64h-64V96a32 32 0 0 1 32-32h576a32 32 0 0 1 32 32zM256 672h320v64H256v-64zm0-192h320v64H256v-64z', }, null, -1 ) const _hoisted_3$7X = [_hoisted_2$8H] function _sfc_render$4P(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$a5, _hoisted_3$7X) } var documentCopy = /* @__PURE__ */ _export_sfc$2(_sfc_main$cs, [ ['render', _sfc_render$4P], ]) const _sfc_main$cr = defineComponent({ name: 'DocumentDelete', }) const _hoisted_1$a4 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8G = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M805.504 320 640 154.496V320h165.504zM832 384H576V128H192v768h640V384zM160 64h480l256 256v608a32 32 0 0 1-32 32H160a32 32 0 0 1-32-32V96a32 32 0 0 1 32-32zm308.992 546.304-90.496-90.624 45.248-45.248 90.56 90.496 90.496-90.432 45.248 45.248-90.496 90.56 90.496 90.496-45.248 45.248-90.496-90.496-90.56 90.496-45.248-45.248 90.496-90.496z', }, null, -1 ) const _hoisted_3$7W = [_hoisted_2$8G] function _sfc_render$4O(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$a4, _hoisted_3$7W) } var documentDelete = /* @__PURE__ */ _export_sfc$2(_sfc_main$cr, [ ['render', _sfc_render$4O], ]) const _sfc_main$cq = defineComponent({ name: 'DocumentRemove', }) const _hoisted_1$a3 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8F = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M805.504 320 640 154.496V320h165.504zM832 384H576V128H192v768h640V384zM160 64h480l256 256v608a32 32 0 0 1-32 32H160a32 32 0 0 1-32-32V96a32 32 0 0 1 32-32zm192 512h320v64H352v-64z', }, null, -1 ) const _hoisted_3$7V = [_hoisted_2$8F] function _sfc_render$4N(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$a3, _hoisted_3$7V) } var documentRemove = /* @__PURE__ */ _export_sfc$2(_sfc_main$cq, [ ['render', _sfc_render$4N], ]) const _sfc_main$cp = defineComponent({ name: 'Document', }) const _hoisted_1$a2 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8E = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M832 384H576V128H192v768h640V384zm-26.496-64L640 154.496V320h165.504zM160 64h480l256 256v608a32 32 0 0 1-32 32H160a32 32 0 0 1-32-32V96a32 32 0 0 1 32-32zm160 448h384v64H320v-64zm0-192h160v64H320v-64zm0 384h384v64H320v-64z', }, null, -1 ) const _hoisted_3$7U = [_hoisted_2$8E] function _sfc_render$4M(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$a2, _hoisted_3$7U) } var document$4 = /* @__PURE__ */ _export_sfc$2(_sfc_main$cp, [ ['render', _sfc_render$4M], ]) const _sfc_main$co = defineComponent({ name: 'Download', }) const _hoisted_1$a1 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8D = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M160 832h704a32 32 0 1 1 0 64H160a32 32 0 1 1 0-64zm384-253.696 236.288-236.352 45.248 45.248L508.8 704 192 387.2l45.248-45.248L480 584.704V128h64v450.304z', }, null, -1 ) const _hoisted_3$7T = [_hoisted_2$8D] function _sfc_render$4L(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$a1, _hoisted_3$7T) } var download$1 = /* @__PURE__ */ _export_sfc$2(_sfc_main$co, [ ['render', _sfc_render$4L], ]) const _sfc_main$cn = defineComponent({ name: 'Drizzling', }) const _hoisted_1$a0 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8C = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm739.328 291.328-35.2-6.592-12.8-33.408a192.064 192.064 0 0 0-365.952 23.232l-9.92 40.896-41.472 7.04a176.32 176.32 0 0 0-146.24 173.568c0 97.28 78.72 175.936 175.808 175.936h400a192 192 0 0 0 35.776-380.672zM959.552 480a256 256 0 0 1-256 256h-400A239.808 239.808 0 0 1 63.744 496.192a240.32 240.32 0 0 1 199.488-236.8 256.128 256.128 0 0 1 487.872-30.976A256.064 256.064 0 0 1 959.552 480zM288 800h64v64h-64v-64zm192 0h64v64h-64v-64zm-96 96h64v64h-64v-64zm192 0h64v64h-64v-64zm96-96h64v64h-64v-64z', }, null, -1 ) const _hoisted_3$7S = [_hoisted_2$8C] function _sfc_render$4K(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$a0, _hoisted_3$7S) } var drizzling = /* @__PURE__ */ _export_sfc$2(_sfc_main$cn, [ ['render', _sfc_render$4K], ]) const _sfc_main$cm = defineComponent({ name: 'EditPen', }) const _hoisted_1$9$ = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8B = /* @__PURE__ */ createElementVNode( 'path', { d: 'm199.04 672.64 193.984 112 224-387.968-193.92-112-224 388.032zm-23.872 60.16 32.896 148.288 144.896-45.696L175.168 732.8zM455.04 229.248l193.92 112 56.704-98.112-193.984-112-56.64 98.112zM104.32 708.8l384-665.024 304.768 175.936L409.152 884.8h.064l-248.448 78.336L104.32 708.8zm384 254.272v-64h448v64h-448z', fill: 'currentColor', }, null, -1 ) const _hoisted_3$7R = [_hoisted_2$8B] function _sfc_render$4J(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9$, _hoisted_3$7R) } var editPen = /* @__PURE__ */ _export_sfc$2(_sfc_main$cm, [ ['render', _sfc_render$4J], ]) const _sfc_main$cl = defineComponent({ name: 'Edit', }) const _hoisted_1$9_ = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8A = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M832 512a32 32 0 1 1 64 0v352a32 32 0 0 1-32 32H160a32 32 0 0 1-32-32V160a32 32 0 0 1 32-32h352a32 32 0 0 1 0 64H192v640h640V512z', }, null, -1 ) const _hoisted_3$7Q = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm469.952 554.24 52.8-7.552L847.104 222.4a32 32 0 1 0-45.248-45.248L477.44 501.44l-7.552 52.8zm422.4-422.4a96 96 0 0 1 0 135.808l-331.84 331.84a32 32 0 0 1-18.112 9.088L436.8 623.68a32 32 0 0 1-36.224-36.224l15.104-105.6a32 32 0 0 1 9.024-18.112l331.904-331.84a96 96 0 0 1 135.744 0z', }, null, -1 ) const _hoisted_4$4Y = [_hoisted_2$8A, _hoisted_3$7Q] function _sfc_render$4I(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9_, _hoisted_4$4Y) } var edit = /* @__PURE__ */ _export_sfc$2(_sfc_main$cl, [ ['render', _sfc_render$4I], ]) const _sfc_main$ck = defineComponent({ name: 'ElemeFilled', }) const _hoisted_1$9Z = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8z = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M176 64h672c61.824 0 112 50.176 112 112v672a112 112 0 0 1-112 112H176A112 112 0 0 1 64 848V176c0-61.824 50.176-112 112-112zm150.528 173.568c-152.896 99.968-196.544 304.064-97.408 456.96a330.688 330.688 0 0 0 456.96 96.64c9.216-5.888 17.6-11.776 25.152-18.56a18.24 18.24 0 0 0 4.224-24.32L700.352 724.8a47.552 47.552 0 0 0-65.536-14.272A234.56 234.56 0 0 1 310.592 641.6C240 533.248 271.104 387.968 379.456 316.48a234.304 234.304 0 0 1 276.352 15.168c1.664.832 2.56 2.56 3.392 4.224 5.888 8.384 3.328 19.328-5.12 25.216L456.832 489.6a47.552 47.552 0 0 0-14.336 65.472l16 24.384c5.888 8.384 16.768 10.88 25.216 5.056l308.224-199.936a19.584 19.584 0 0 0 6.72-23.488v-.896c-4.992-9.216-10.048-17.6-15.104-26.88-99.968-151.168-304.064-194.88-456.96-95.744zM786.88 504.704l-62.208 40.32c-8.32 5.888-10.88 16.768-4.992 25.216L760 632.32c5.888 8.448 16.768 11.008 25.152 5.12l31.104-20.16a55.36 55.36 0 0 0 16-76.48l-20.224-31.04a19.52 19.52 0 0 0-25.152-5.12z', }, null, -1 ) const _hoisted_3$7P = [_hoisted_2$8z] function _sfc_render$4H(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9Z, _hoisted_3$7P) } var elemeFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$ck, [ ['render', _sfc_render$4H], ]) const _sfc_main$cj = defineComponent({ name: 'Eleme', }) const _hoisted_1$9Y = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8y = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M300.032 188.8c174.72-113.28 408-63.36 522.24 109.44 5.76 10.56 11.52 20.16 17.28 30.72v.96a22.4 22.4 0 0 1-7.68 26.88l-352.32 228.48c-9.6 6.72-22.08 3.84-28.8-5.76l-18.24-27.84a54.336 54.336 0 0 1 16.32-74.88l225.6-146.88c9.6-6.72 12.48-19.2 5.76-28.8-.96-1.92-1.92-3.84-3.84-4.8a267.84 267.84 0 0 0-315.84-17.28c-123.84 81.6-159.36 247.68-78.72 371.52a268.096 268.096 0 0 0 370.56 78.72 54.336 54.336 0 0 1 74.88 16.32l17.28 26.88c5.76 9.6 3.84 21.12-4.8 27.84-8.64 7.68-18.24 14.4-28.8 21.12a377.92 377.92 0 0 1-522.24-110.4c-113.28-174.72-63.36-408 111.36-522.24zm526.08 305.28a22.336 22.336 0 0 1 28.8 5.76l23.04 35.52a63.232 63.232 0 0 1-18.24 87.36l-35.52 23.04c-9.6 6.72-22.08 3.84-28.8-5.76l-46.08-71.04c-6.72-9.6-3.84-22.08 5.76-28.8l71.04-46.08z', }, null, -1 ) const _hoisted_3$7O = [_hoisted_2$8y] function _sfc_render$4G(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9Y, _hoisted_3$7O) } var eleme = /* @__PURE__ */ _export_sfc$2(_sfc_main$cj, [ ['render', _sfc_render$4G], ]) const _sfc_main$ci = defineComponent({ name: 'ElementPlus', }) const _hoisted_1$9X = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8x = /* @__PURE__ */ createElementVNode( 'path', { d: 'M839.7 734.7c0 33.3-17.9 41-17.9 41S519.7 949.8 499.2 960c-10.2 5.1-20.5 5.1-30.7 0 0 0-314.9-184.3-325.1-192-5.1-5.1-10.2-12.8-12.8-20.5V368.6c0-17.9 20.5-28.2 20.5-28.2L466 158.6c12.8-5.1 25.6-5.1 38.4 0 0 0 279 161.3 309.8 179.2 17.9 7.7 28.2 25.6 25.6 46.1-.1-5-.1 317.5-.1 350.8zM714.2 371.2c-64-35.8-217.6-125.4-217.6-125.4-7.7-5.1-20.5-5.1-30.7 0L217.6 389.1s-17.9 10.2-17.9 23v297c0 5.1 5.1 12.8 7.7 17.9 7.7 5.1 256 148.5 256 148.5 7.7 5.1 17.9 5.1 25.6 0 15.4-7.7 250.9-145.9 250.9-145.9s12.8-5.1 12.8-30.7v-74.2l-276.5 169v-64c0-17.9 7.7-30.7 20.5-46.1L745 535c5.1-7.7 10.2-20.5 10.2-30.7v-66.6l-279 169v-69.1c0-15.4 5.1-30.7 17.9-38.4l220.1-128zM919 135.7c0-5.1-5.1-7.7-7.7-7.7h-58.9V66.6c0-5.1-5.1-5.1-10.2-5.1l-30.7 5.1c-5.1 0-5.1 2.6-5.1 5.1V128h-56.3c-5.1 0-5.1 5.1-7.7 5.1v38.4h69.1v64c0 5.1 5.1 5.1 10.2 5.1l30.7-5.1c5.1 0 5.1-2.6 5.1-5.1v-56.3h64l-2.5-38.4z', fill: 'currentColor', }, null, -1 ) const _hoisted_3$7N = [_hoisted_2$8x] function _sfc_render$4F(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9X, _hoisted_3$7N) } var elementPlus = /* @__PURE__ */ _export_sfc$2(_sfc_main$ci, [ ['render', _sfc_render$4F], ]) const _sfc_main$ch = defineComponent({ name: 'Expand', }) const _hoisted_1$9W = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8w = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M128 192h768v128H128V192zm0 256h512v128H128V448zm0 256h768v128H128V704zm576-352 192 160-192 128V352z', }, null, -1 ) const _hoisted_3$7M = [_hoisted_2$8w] function _sfc_render$4E(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9W, _hoisted_3$7M) } var expand = /* @__PURE__ */ _export_sfc$2(_sfc_main$ch, [ ['render', _sfc_render$4E], ]) const _sfc_main$cg = defineComponent({ name: 'Failed', }) const _hoisted_1$9V = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8v = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm557.248 608 135.744-135.744-45.248-45.248-135.68 135.744-135.808-135.68-45.248 45.184L466.752 608l-135.68 135.68 45.184 45.312L512 653.248l135.744 135.744 45.248-45.248L557.312 608zM704 192h160v736H160V192h160v64h384v-64zm-320 0V96h256v96H384z', }, null, -1 ) const _hoisted_3$7L = [_hoisted_2$8v] function _sfc_render$4D(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9V, _hoisted_3$7L) } var failed = /* @__PURE__ */ _export_sfc$2(_sfc_main$cg, [ ['render', _sfc_render$4D], ]) const _sfc_main$cf = defineComponent({ name: 'Female', }) const _hoisted_1$9U = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8u = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 640a256 256 0 1 0 0-512 256 256 0 0 0 0 512zm0 64a320 320 0 1 1 0-640 320 320 0 0 1 0 640z', }, null, -1 ) const _hoisted_3$7K = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 640q32 0 32 32v256q0 32-32 32t-32-32V672q0-32 32-32z', }, null, -1 ) const _hoisted_4$4X = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M352 800h320q32 0 32 32t-32 32H352q-32 0-32-32t32-32z', }, null, -1 ) const _hoisted_5$3T = [_hoisted_2$8u, _hoisted_3$7K, _hoisted_4$4X] function _sfc_render$4C(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9U, _hoisted_5$3T) } var female = /* @__PURE__ */ _export_sfc$2(_sfc_main$cf, [ ['render', _sfc_render$4C], ]) const _sfc_main$ce = defineComponent({ name: 'Files', }) const _hoisted_1$9T = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8t = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M128 384v448h768V384H128zm-32-64h832a32 32 0 0 1 32 32v512a32 32 0 0 1-32 32H96a32 32 0 0 1-32-32V352a32 32 0 0 1 32-32zm64-128h704v64H160zm96-128h512v64H256z', }, null, -1 ) const _hoisted_3$7J = [_hoisted_2$8t] function _sfc_render$4B(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9T, _hoisted_3$7J) } var files$1 = /* @__PURE__ */ _export_sfc$2(_sfc_main$ce, [ ['render', _sfc_render$4B], ]) const _sfc_main$cd = defineComponent({ name: 'Film', }) const _hoisted_1$9S = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8s = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M160 160v704h704V160H160zm-32-64h768a32 32 0 0 1 32 32v768a32 32 0 0 1-32 32H128a32 32 0 0 1-32-32V128a32 32 0 0 1 32-32z', }, null, -1 ) const _hoisted_3$7I = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M320 288V128h64v352h256V128h64v160h160v64H704v128h160v64H704v128h160v64H704v160h-64V544H384v352h-64V736H128v-64h192V544H128v-64h192V352H128v-64h192z', }, null, -1 ) const _hoisted_4$4W = [_hoisted_2$8s, _hoisted_3$7I] function _sfc_render$4A(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9S, _hoisted_4$4W) } var film = /* @__PURE__ */ _export_sfc$2(_sfc_main$cd, [ ['render', _sfc_render$4A], ]) const _sfc_main$cc = defineComponent({ name: 'Filter', }) const _hoisted_1$9R = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8r = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M384 523.392V928a32 32 0 0 0 46.336 28.608l192-96A32 32 0 0 0 640 832V523.392l280.768-343.104a32 32 0 1 0-49.536-40.576l-288 352A32 32 0 0 0 576 512v300.224l-128 64V512a32 32 0 0 0-7.232-20.288L195.52 192H704a32 32 0 1 0 0-64H128a32 32 0 0 0-24.768 52.288L384 523.392z', }, null, -1 ) const _hoisted_3$7H = [_hoisted_2$8r] function _sfc_render$4z(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9R, _hoisted_3$7H) } var filter$3 = /* @__PURE__ */ _export_sfc$2(_sfc_main$cc, [ ['render', _sfc_render$4z], ]) const _sfc_main$cb = defineComponent({ name: 'Finished', }) const _hoisted_1$9Q = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8q = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M280.768 753.728 691.456 167.04a32 32 0 1 1 52.416 36.672L314.24 817.472a32 32 0 0 1-45.44 7.296l-230.4-172.8a32 32 0 0 1 38.4-51.2l203.968 152.96zM736 448a32 32 0 1 1 0-64h192a32 32 0 1 1 0 64H736zM608 640a32 32 0 0 1 0-64h319.936a32 32 0 1 1 0 64H608zM480 832a32 32 0 1 1 0-64h447.936a32 32 0 1 1 0 64H480z', }, null, -1 ) const _hoisted_3$7G = [_hoisted_2$8q] function _sfc_render$4y(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9Q, _hoisted_3$7G) } var finished = /* @__PURE__ */ _export_sfc$2(_sfc_main$cb, [ ['render', _sfc_render$4y], ]) const _sfc_main$ca = defineComponent({ name: 'FirstAidKit', }) const _hoisted_1$9P = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8p = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M192 256a64 64 0 0 0-64 64v448a64 64 0 0 0 64 64h640a64 64 0 0 0 64-64V320a64 64 0 0 0-64-64H192zm0-64h640a128 128 0 0 1 128 128v448a128 128 0 0 1-128 128H192A128 128 0 0 1 64 768V320a128 128 0 0 1 128-128z', }, null, -1 ) const _hoisted_3$7F = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M544 512h96a32 32 0 0 1 0 64h-96v96a32 32 0 0 1-64 0v-96h-96a32 32 0 0 1 0-64h96v-96a32 32 0 0 1 64 0v96zM352 128v64h320v-64H352zm-32-64h384a32 32 0 0 1 32 32v128a32 32 0 0 1-32 32H320a32 32 0 0 1-32-32V96a32 32 0 0 1 32-32z', }, null, -1 ) const _hoisted_4$4V = [_hoisted_2$8p, _hoisted_3$7F] function _sfc_render$4x(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9P, _hoisted_4$4V) } var firstAidKit = /* @__PURE__ */ _export_sfc$2(_sfc_main$ca, [ ['render', _sfc_render$4x], ]) const _sfc_main$c9 = defineComponent({ name: 'Flag', }) const _hoisted_1$9O = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8o = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M288 128h608L736 384l160 256H288v320h-96V64h96v64z', }, null, -1 ) const _hoisted_3$7E = [_hoisted_2$8o] function _sfc_render$4w(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9O, _hoisted_3$7E) } var flag = /* @__PURE__ */ _export_sfc$2(_sfc_main$c9, [ ['render', _sfc_render$4w], ]) const _sfc_main$c8 = defineComponent({ name: 'Fold', }) const _hoisted_1$9N = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8n = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M896 192H128v128h768V192zm0 256H384v128h512V448zm0 256H128v128h768V704zM320 384 128 512l192 128V384z', }, null, -1 ) const _hoisted_3$7D = [_hoisted_2$8n] function _sfc_render$4v(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9N, _hoisted_3$7D) } var fold = /* @__PURE__ */ _export_sfc$2(_sfc_main$c8, [ ['render', _sfc_render$4v], ]) const _sfc_main$c7 = defineComponent({ name: 'FolderAdd', }) const _hoisted_1$9M = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8m = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M128 192v640h768V320H485.76L357.504 192H128zm-32-64h287.872l128.384 128H928a32 32 0 0 1 32 32v576a32 32 0 0 1-32 32H96a32 32 0 0 1-32-32V160a32 32 0 0 1 32-32zm384 416V416h64v128h128v64H544v128h-64V608H352v-64h128z', }, null, -1 ) const _hoisted_3$7C = [_hoisted_2$8m] function _sfc_render$4u(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9M, _hoisted_3$7C) } var folderAdd = /* @__PURE__ */ _export_sfc$2(_sfc_main$c7, [ ['render', _sfc_render$4u], ]) const _sfc_main$c6 = defineComponent({ name: 'FolderChecked', }) const _hoisted_1$9L = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8l = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M128 192v640h768V320H485.76L357.504 192H128zm-32-64h287.872l128.384 128H928a32 32 0 0 1 32 32v576a32 32 0 0 1-32 32H96a32 32 0 0 1-32-32V160a32 32 0 0 1 32-32zm414.08 502.144 180.992-180.992L736.32 494.4 510.08 720.64l-158.4-158.336 45.248-45.312L510.08 630.144z', }, null, -1 ) const _hoisted_3$7B = [_hoisted_2$8l] function _sfc_render$4t(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9L, _hoisted_3$7B) } var folderChecked = /* @__PURE__ */ _export_sfc$2(_sfc_main$c6, [ ['render', _sfc_render$4t], ]) const _sfc_main$c5 = defineComponent({ name: 'FolderDelete', }) const _hoisted_1$9K = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8k = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M128 192v640h768V320H485.76L357.504 192H128zm-32-64h287.872l128.384 128H928a32 32 0 0 1 32 32v576a32 32 0 0 1-32 32H96a32 32 0 0 1-32-32V160a32 32 0 0 1 32-32zm370.752 448-90.496-90.496 45.248-45.248L512 530.752l90.496-90.496 45.248 45.248L557.248 576l90.496 90.496-45.248 45.248L512 621.248l-90.496 90.496-45.248-45.248L466.752 576z', }, null, -1 ) const _hoisted_3$7A = [_hoisted_2$8k] function _sfc_render$4s(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9K, _hoisted_3$7A) } var folderDelete = /* @__PURE__ */ _export_sfc$2(_sfc_main$c5, [ ['render', _sfc_render$4s], ]) const _sfc_main$c4 = defineComponent({ name: 'FolderOpened', }) const _hoisted_1$9J = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8j = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M878.08 448H241.92l-96 384h636.16l96-384zM832 384v-64H485.76L357.504 192H128v448l57.92-231.744A32 32 0 0 1 216.96 384H832zm-24.96 512H96a32 32 0 0 1-32-32V160a32 32 0 0 1 32-32h287.872l128.384 128H864a32 32 0 0 1 32 32v96h23.04a32 32 0 0 1 31.04 39.744l-112 448A32 32 0 0 1 807.04 896z', }, null, -1 ) const _hoisted_3$7z = [_hoisted_2$8j] function _sfc_render$4r(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9J, _hoisted_3$7z) } var folderOpened = /* @__PURE__ */ _export_sfc$2(_sfc_main$c4, [ ['render', _sfc_render$4r], ]) const _sfc_main$c3 = defineComponent({ name: 'FolderRemove', }) const _hoisted_1$9I = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8i = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M128 192v640h768V320H485.76L357.504 192H128zm-32-64h287.872l128.384 128H928a32 32 0 0 1 32 32v576a32 32 0 0 1-32 32H96a32 32 0 0 1-32-32V160a32 32 0 0 1 32-32zm256 416h320v64H352v-64z', }, null, -1 ) const _hoisted_3$7y = [_hoisted_2$8i] function _sfc_render$4q(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9I, _hoisted_3$7y) } var folderRemove = /* @__PURE__ */ _export_sfc$2(_sfc_main$c3, [ ['render', _sfc_render$4q], ]) const _sfc_main$c2 = defineComponent({ name: 'Folder', }) const _hoisted_1$9H = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8h = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M128 192v640h768V320H485.76L357.504 192H128zm-32-64h287.872l128.384 128H928a32 32 0 0 1 32 32v576a32 32 0 0 1-32 32H96a32 32 0 0 1-32-32V160a32 32 0 0 1 32-32z', }, null, -1 ) const _hoisted_3$7x = [_hoisted_2$8h] function _sfc_render$4p(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9H, _hoisted_3$7x) } var folder = /* @__PURE__ */ _export_sfc$2(_sfc_main$c2, [ ['render', _sfc_render$4p], ]) const _sfc_main$c1 = defineComponent({ name: 'Food', }) const _hoisted_1$9G = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8g = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M128 352.576V352a288 288 0 0 1 491.072-204.224 192 192 0 0 1 274.24 204.48 64 64 0 0 1 57.216 74.24C921.6 600.512 850.048 710.656 736 756.992V800a96 96 0 0 1-96 96H384a96 96 0 0 1-96-96v-43.008c-114.048-46.336-185.6-156.48-214.528-330.496A64 64 0 0 1 128 352.64zm64-.576h64a160 160 0 0 1 320 0h64a224 224 0 0 0-448 0zm128 0h192a96 96 0 0 0-192 0zm439.424 0h68.544A128.256 128.256 0 0 0 704 192c-15.36 0-29.952 2.688-43.52 7.616 11.328 18.176 20.672 37.76 27.84 58.304A64.128 64.128 0 0 1 759.424 352zM672 768H352v32a32 32 0 0 0 32 32h256a32 32 0 0 0 32-32v-32zm-342.528-64h365.056c101.504-32.64 165.76-124.928 192.896-288H136.576c27.136 163.072 91.392 255.36 192.896 288z', }, null, -1 ) const _hoisted_3$7w = [_hoisted_2$8g] function _sfc_render$4o(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9G, _hoisted_3$7w) } var food = /* @__PURE__ */ _export_sfc$2(_sfc_main$c1, [ ['render', _sfc_render$4o], ]) const _sfc_main$c0 = defineComponent({ name: 'Football', }) const _hoisted_1$9F = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8f = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 960a448 448 0 1 1 0-896 448 448 0 0 1 0 896zm0-64a384 384 0 1 0 0-768 384 384 0 0 0 0 768z', }, null, -1 ) const _hoisted_3$7v = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M186.816 268.288c16-16.384 31.616-31.744 46.976-46.08 17.472 30.656 39.808 58.112 65.984 81.28l-32.512 56.448a385.984 385.984 0 0 1-80.448-91.648zm653.696-5.312a385.92 385.92 0 0 1-83.776 96.96l-32.512-56.384a322.923 322.923 0 0 0 68.48-85.76c15.552 14.08 31.488 29.12 47.808 45.184zM465.984 445.248l11.136-63.104a323.584 323.584 0 0 0 69.76 0l11.136 63.104a387.968 387.968 0 0 1-92.032 0zm-62.72-12.8A381.824 381.824 0 0 1 320 396.544l32-55.424a319.885 319.885 0 0 0 62.464 27.712l-11.2 63.488zm300.8-35.84a381.824 381.824 0 0 1-83.328 35.84l-11.2-63.552A319.885 319.885 0 0 0 672 341.184l32 55.424zm-520.768 364.8a385.92 385.92 0 0 1 83.968-97.28l32.512 56.32c-26.88 23.936-49.856 52.352-67.52 84.032-16-13.44-32.32-27.712-48.96-43.072zm657.536.128a1442.759 1442.759 0 0 1-49.024 43.072 321.408 321.408 0 0 0-67.584-84.16l32.512-56.32c33.216 27.456 61.696 60.352 84.096 97.408zM465.92 578.752a387.968 387.968 0 0 1 92.032 0l-11.136 63.104a323.584 323.584 0 0 0-69.76 0l-11.136-63.104zm-62.72 12.8 11.2 63.552a319.885 319.885 0 0 0-62.464 27.712L320 627.392a381.824 381.824 0 0 1 83.264-35.84zm300.8 35.84-32 55.424a318.272 318.272 0 0 0-62.528-27.712l11.2-63.488c29.44 8.64 57.28 20.736 83.264 35.776z', }, null, -1 ) const _hoisted_4$4U = [_hoisted_2$8f, _hoisted_3$7v] function _sfc_render$4n(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9F, _hoisted_4$4U) } var football = /* @__PURE__ */ _export_sfc$2(_sfc_main$c0, [ ['render', _sfc_render$4n], ]) const _sfc_main$b$ = defineComponent({ name: 'ForkSpoon', }) const _hoisted_1$9E = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8e = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M256 410.304V96a32 32 0 0 1 64 0v314.304a96 96 0 0 0 64-90.56V96a32 32 0 0 1 64 0v223.744a160 160 0 0 1-128 156.8V928a32 32 0 1 1-64 0V476.544a160 160 0 0 1-128-156.8V96a32 32 0 0 1 64 0v223.744a96 96 0 0 0 64 90.56zM672 572.48C581.184 552.128 512 446.848 512 320c0-141.44 85.952-256 192-256s192 114.56 192 256c0 126.848-69.184 232.128-160 252.48V928a32 32 0 1 1-64 0V572.48zM704 512c66.048 0 128-82.56 128-192s-61.952-192-128-192-128 82.56-128 192 61.952 192 128 192z', }, null, -1 ) const _hoisted_3$7u = [_hoisted_2$8e] function _sfc_render$4m(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9E, _hoisted_3$7u) } var forkSpoon = /* @__PURE__ */ _export_sfc$2(_sfc_main$b$, [ ['render', _sfc_render$4m], ]) const _sfc_main$b_ = defineComponent({ name: 'Fries', }) const _hoisted_1$9D = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8d = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M608 224v-64a32 32 0 0 0-64 0v336h26.88A64 64 0 0 0 608 484.096V224zm101.12 160A64 64 0 0 0 672 395.904V384h64V224a32 32 0 1 0-64 0v160h37.12zm74.88 0a92.928 92.928 0 0 1 91.328 110.08l-60.672 323.584A96 96 0 0 1 720.32 896H303.68a96 96 0 0 1-94.336-78.336L148.672 494.08A92.928 92.928 0 0 1 240 384h-16V224a96 96 0 0 1 188.608-25.28A95.744 95.744 0 0 1 480 197.44V160a96 96 0 0 1 188.608-25.28A96 96 0 0 1 800 224v160h-16zM670.784 512a128 128 0 0 1-99.904 48H453.12a128 128 0 0 1-99.84-48H352v-1.536a128.128 128.128 0 0 1-9.984-14.976L314.88 448H240a28.928 28.928 0 0 0-28.48 34.304L241.088 640h541.824l29.568-157.696A28.928 28.928 0 0 0 784 448h-74.88l-27.136 47.488A132.405 132.405 0 0 1 672 510.464V512h-1.216zM480 288a32 32 0 0 0-64 0v196.096A64 64 0 0 0 453.12 496H480V288zm-128 96V224a32 32 0 0 0-64 0v160h64-37.12A64 64 0 0 1 352 395.904zm-98.88 320 19.072 101.888A32 32 0 0 0 303.68 832h416.64a32 32 0 0 0 31.488-26.112L770.88 704H253.12z', }, null, -1 ) const _hoisted_3$7t = [_hoisted_2$8d] function _sfc_render$4l(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9D, _hoisted_3$7t) } var fries = /* @__PURE__ */ _export_sfc$2(_sfc_main$b_, [ ['render', _sfc_render$4l], ]) const _sfc_main$bZ = defineComponent({ name: 'FullScreen', }) const _hoisted_1$9C = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8c = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm160 96.064 192 .192a32 32 0 0 1 0 64l-192-.192V352a32 32 0 0 1-64 0V96h64v.064zm0 831.872V928H96V672a32 32 0 1 1 64 0v191.936l192-.192a32 32 0 1 1 0 64l-192 .192zM864 96.064V96h64v256a32 32 0 1 1-64 0V160.064l-192 .192a32 32 0 1 1 0-64l192-.192zm0 831.872-192-.192a32 32 0 0 1 0-64l192 .192V672a32 32 0 1 1 64 0v256h-64v-.064z', }, null, -1 ) const _hoisted_3$7s = [_hoisted_2$8c] function _sfc_render$4k(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9C, _hoisted_3$7s) } var fullScreen = /* @__PURE__ */ _export_sfc$2(_sfc_main$bZ, [ ['render', _sfc_render$4k], ]) const _sfc_main$bY = defineComponent({ name: 'GobletFull', }) const _hoisted_1$9B = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8b = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M256 320h512c0-78.592-12.608-142.4-36.928-192h-434.24C269.504 192.384 256 256.256 256 320zm503.936 64H264.064a256.128 256.128 0 0 0 495.872 0zM544 638.4V896h96a32 32 0 1 1 0 64H384a32 32 0 1 1 0-64h96V638.4A320 320 0 0 1 192 320c0-85.632 21.312-170.944 64-256h512c42.688 64.32 64 149.632 64 256a320 320 0 0 1-288 318.4z', }, null, -1 ) const _hoisted_3$7r = [_hoisted_2$8b] function _sfc_render$4j(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9B, _hoisted_3$7r) } var gobletFull = /* @__PURE__ */ _export_sfc$2(_sfc_main$bY, [ ['render', _sfc_render$4j], ]) const _sfc_main$bX = defineComponent({ name: 'GobletSquareFull', }) const _hoisted_1$9A = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$8a = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M256 270.912c10.048 6.72 22.464 14.912 28.992 18.624a220.16 220.16 0 0 0 114.752 30.72c30.592 0 49.408-9.472 91.072-41.152l.64-.448c52.928-40.32 82.368-55.04 132.288-54.656 55.552.448 99.584 20.8 142.72 57.408l1.536 1.28V128H256v142.912zm.96 76.288C266.368 482.176 346.88 575.872 512 576c157.44.064 237.952-85.056 253.248-209.984a952.32 952.32 0 0 1-40.192-35.712c-32.704-27.776-63.36-41.92-101.888-42.24-31.552-.256-50.624 9.28-93.12 41.6l-.576.448c-52.096 39.616-81.024 54.208-129.792 54.208-54.784 0-100.48-13.376-142.784-37.056zM480 638.848C250.624 623.424 192 442.496 192 319.68V96a32 32 0 0 1 32-32h576a32 32 0 0 1 32 32v224c0 122.816-58.624 303.68-288 318.912V896h96a32 32 0 1 1 0 64H384a32 32 0 1 1 0-64h96V638.848z', }, null, -1 ) const _hoisted_3$7q = [_hoisted_2$8a] function _sfc_render$4i(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9A, _hoisted_3$7q) } var gobletSquareFull = /* @__PURE__ */ _export_sfc$2(_sfc_main$bX, [ ['render', _sfc_render$4i], ]) const _sfc_main$bW = defineComponent({ name: 'GobletSquare', }) const _hoisted_1$9z = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$89 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M544 638.912V896h96a32 32 0 1 1 0 64H384a32 32 0 1 1 0-64h96V638.848C250.624 623.424 192 442.496 192 319.68V96a32 32 0 0 1 32-32h576a32 32 0 0 1 32 32v224c0 122.816-58.624 303.68-288 318.912zM256 319.68c0 149.568 80 256.192 256 256.256C688.128 576 768 469.568 768 320V128H256v191.68z', }, null, -1 ) const _hoisted_3$7p = [_hoisted_2$89] function _sfc_render$4h(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9z, _hoisted_3$7p) } var gobletSquare = /* @__PURE__ */ _export_sfc$2(_sfc_main$bW, [ ['render', _sfc_render$4h], ]) const _sfc_main$bV = defineComponent({ name: 'Goblet', }) const _hoisted_1$9y = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$88 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M544 638.4V896h96a32 32 0 1 1 0 64H384a32 32 0 1 1 0-64h96V638.4A320 320 0 0 1 192 320c0-85.632 21.312-170.944 64-256h512c42.688 64.32 64 149.632 64 256a320 320 0 0 1-288 318.4zM256 320a256 256 0 1 0 512 0c0-78.592-12.608-142.4-36.928-192h-434.24C269.504 192.384 256 256.256 256 320z', }, null, -1 ) const _hoisted_3$7o = [_hoisted_2$88] function _sfc_render$4g(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9y, _hoisted_3$7o) } var goblet = /* @__PURE__ */ _export_sfc$2(_sfc_main$bV, [ ['render', _sfc_render$4g], ]) const _sfc_main$bU = defineComponent({ name: 'GoodsFilled', }) const _hoisted_1$9x = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$87 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M192 352h640l64 544H128l64-544zm128 224h64V448h-64v128zm320 0h64V448h-64v128zM384 288h-64a192 192 0 1 1 384 0h-64a128 128 0 1 0-256 0z', }, null, -1 ) const _hoisted_3$7n = [_hoisted_2$87] function _sfc_render$4f(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9x, _hoisted_3$7n) } var goodsFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$bU, [ ['render', _sfc_render$4f], ]) const _sfc_main$bT = defineComponent({ name: 'Goods', }) const _hoisted_1$9w = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$86 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M320 288v-22.336C320 154.688 405.504 64 512 64s192 90.688 192 201.664v22.4h131.072a32 32 0 0 1 31.808 28.8l57.6 576a32 32 0 0 1-31.808 35.2H131.328a32 32 0 0 1-31.808-35.2l57.6-576a32 32 0 0 1 31.808-28.8H320zm64 0h256v-22.336C640 189.248 582.272 128 512 128c-70.272 0-128 61.248-128 137.664v22.4zm-64 64H217.92l-51.2 512h690.56l-51.264-512H704v96a32 32 0 1 1-64 0v-96H384v96a32 32 0 0 1-64 0v-96z', }, null, -1 ) const _hoisted_3$7m = [_hoisted_2$86] function _sfc_render$4e(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9w, _hoisted_3$7m) } var goods = /* @__PURE__ */ _export_sfc$2(_sfc_main$bT, [ ['render', _sfc_render$4e], ]) const _sfc_main$bS = defineComponent({ name: 'Grape', }) const _hoisted_1$9v = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$85 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M544 195.2a160 160 0 0 1 96 60.8 160 160 0 1 1 146.24 254.976 160 160 0 0 1-128 224 160 160 0 1 1-292.48 0 160 160 0 0 1-128-224A160 160 0 1 1 384 256a160 160 0 0 1 96-60.8V128h-64a32 32 0 0 1 0-64h192a32 32 0 0 1 0 64h-64v67.2zM512 448a96 96 0 1 0 0-192 96 96 0 0 0 0 192zm-256 0a96 96 0 1 0 0-192 96 96 0 0 0 0 192zm128 224a96 96 0 1 0 0-192 96 96 0 0 0 0 192zm128 224a96 96 0 1 0 0-192 96 96 0 0 0 0 192zm128-224a96 96 0 1 0 0-192 96 96 0 0 0 0 192zm128-224a96 96 0 1 0 0-192 96 96 0 0 0 0 192z', }, null, -1 ) const _hoisted_3$7l = [_hoisted_2$85] function _sfc_render$4d(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9v, _hoisted_3$7l) } var grape = /* @__PURE__ */ _export_sfc$2(_sfc_main$bS, [ ['render', _sfc_render$4d], ]) const _sfc_main$bR = defineComponent({ name: 'Grid', }) const _hoisted_1$9u = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$84 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M640 384v256H384V384h256zm64 0h192v256H704V384zm-64 512H384V704h256v192zm64 0V704h192v192H704zm-64-768v192H384V128h256zm64 0h192v192H704V128zM320 384v256H128V384h192zm0 512H128V704h192v192zm0-768v192H128V128h192z', }, null, -1 ) const _hoisted_3$7k = [_hoisted_2$84] function _sfc_render$4c(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9u, _hoisted_3$7k) } var grid = /* @__PURE__ */ _export_sfc$2(_sfc_main$bR, [ ['render', _sfc_render$4c], ]) const _sfc_main$bQ = defineComponent({ name: 'Guide', }) const _hoisted_1$9t = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$83 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M640 608h-64V416h64v192zm0 160v160a32 32 0 0 1-32 32H416a32 32 0 0 1-32-32V768h64v128h128V768h64zM384 608V416h64v192h-64zm256-352h-64V128H448v128h-64V96a32 32 0 0 1 32-32h192a32 32 0 0 1 32 32v160z', }, null, -1 ) const _hoisted_3$7j = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm220.8 256-71.232 80 71.168 80H768V256H220.8zm-14.4-64H800a32 32 0 0 1 32 32v224a32 32 0 0 1-32 32H206.4a32 32 0 0 1-23.936-10.752l-99.584-112a32 32 0 0 1 0-42.496l99.584-112A32 32 0 0 1 206.4 192zm678.784 496-71.104 80H266.816V608h547.2l71.168 80zm-56.768-144H234.88a32 32 0 0 0-32 32v224a32 32 0 0 0 32 32h593.6a32 32 0 0 0 23.936-10.752l99.584-112a32 32 0 0 0 0-42.496l-99.584-112A32 32 0 0 0 828.48 544z', }, null, -1 ) const _hoisted_4$4T = [_hoisted_2$83, _hoisted_3$7j] function _sfc_render$4b(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9t, _hoisted_4$4T) } var guide = /* @__PURE__ */ _export_sfc$2(_sfc_main$bQ, [ ['render', _sfc_render$4b], ]) const _sfc_main$bP = defineComponent({ name: 'Headset', }) const _hoisted_1$9s = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$82 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M896 529.152V512a384 384 0 1 0-768 0v17.152A128 128 0 0 1 320 640v128a128 128 0 1 1-256 0V512a448 448 0 1 1 896 0v256a128 128 0 1 1-256 0V640a128 128 0 0 1 192-110.848zM896 640a64 64 0 0 0-128 0v128a64 64 0 0 0 128 0V640zm-768 0v128a64 64 0 0 0 128 0V640a64 64 0 1 0-128 0z', }, null, -1 ) const _hoisted_3$7i = [_hoisted_2$82] function _sfc_render$4a(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9s, _hoisted_3$7i) } var headset = /* @__PURE__ */ _export_sfc$2(_sfc_main$bP, [ ['render', _sfc_render$4a], ]) const _sfc_main$bO = defineComponent({ name: 'HelpFilled', }) const _hoisted_1$9r = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$81 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M926.784 480H701.312A192.512 192.512 0 0 0 544 322.688V97.216A416.064 416.064 0 0 1 926.784 480zm0 64A416.064 416.064 0 0 1 544 926.784V701.312A192.512 192.512 0 0 0 701.312 544h225.472zM97.28 544h225.472A192.512 192.512 0 0 0 480 701.312v225.472A416.064 416.064 0 0 1 97.216 544zm0-64A416.064 416.064 0 0 1 480 97.216v225.472A192.512 192.512 0 0 0 322.688 480H97.216z', }, null, -1 ) const _hoisted_3$7h = [_hoisted_2$81] function _sfc_render$49(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9r, _hoisted_3$7h) } var helpFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$bO, [ ['render', _sfc_render$49], ]) const _sfc_main$bN = defineComponent({ name: 'Help', }) const _hoisted_1$9q = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$80 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm759.936 805.248-90.944-91.008A254.912 254.912 0 0 1 512 768a254.912 254.912 0 0 1-156.992-53.76l-90.944 91.008A382.464 382.464 0 0 0 512 896c94.528 0 181.12-34.176 247.936-90.752zm45.312-45.312A382.464 382.464 0 0 0 896 512c0-94.528-34.176-181.12-90.752-247.936l-91.008 90.944C747.904 398.4 768 452.864 768 512c0 59.136-20.096 113.6-53.76 156.992l91.008 90.944zm-45.312-541.184A382.464 382.464 0 0 0 512 128c-94.528 0-181.12 34.176-247.936 90.752l90.944 91.008A254.912 254.912 0 0 1 512 256c59.136 0 113.6 20.096 156.992 53.76l90.944-91.008zm-541.184 45.312A382.464 382.464 0 0 0 128 512c0 94.528 34.176 181.12 90.752 247.936l91.008-90.944A254.912 254.912 0 0 1 256 512c0-59.136 20.096-113.6 53.76-156.992l-91.008-90.944zm417.28 394.496a194.56 194.56 0 0 0 22.528-22.528C686.912 602.56 704 559.232 704 512a191.232 191.232 0 0 0-67.968-146.56A191.296 191.296 0 0 0 512 320a191.232 191.232 0 0 0-146.56 67.968C337.088 421.44 320 464.768 320 512a191.232 191.232 0 0 0 67.968 146.56C421.44 686.912 464.768 704 512 704c47.296 0 90.56-17.088 124.032-45.44zM512 960a448 448 0 1 1 0-896 448 448 0 0 1 0 896z', }, null, -1 ) const _hoisted_3$7g = [_hoisted_2$80] function _sfc_render$48(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9q, _hoisted_3$7g) } var help = /* @__PURE__ */ _export_sfc$2(_sfc_main$bN, [ ['render', _sfc_render$48], ]) const _sfc_main$bM = defineComponent({ name: 'Hide', }) const _hoisted_1$9p = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7$ = /* @__PURE__ */ createElementVNode( 'path', { d: 'M876.8 156.8c0-9.6-3.2-16-9.6-22.4-6.4-6.4-12.8-9.6-22.4-9.6-9.6 0-16 3.2-22.4 9.6L736 220.8c-64-32-137.6-51.2-224-60.8-160 16-288 73.6-377.6 176C44.8 438.4 0 496 0 512s48 73.6 134.4 176c22.4 25.6 44.8 48 73.6 67.2l-86.4 89.6c-6.4 6.4-9.6 12.8-9.6 22.4 0 9.6 3.2 16 9.6 22.4 6.4 6.4 12.8 9.6 22.4 9.6 9.6 0 16-3.2 22.4-9.6l704-710.4c3.2-6.4 6.4-12.8 6.4-22.4Zm-646.4 528c-76.8-70.4-128-128-153.6-172.8 28.8-48 80-105.6 153.6-172.8C304 272 400 230.4 512 224c64 3.2 124.8 19.2 176 44.8l-54.4 54.4C598.4 300.8 560 288 512 288c-64 0-115.2 22.4-160 64s-64 96-64 160c0 48 12.8 89.6 35.2 124.8L256 707.2c-9.6-6.4-19.2-16-25.6-22.4Zm140.8-96c-12.8-22.4-19.2-48-19.2-76.8 0-44.8 16-83.2 48-112 32-28.8 67.2-48 112-48 28.8 0 54.4 6.4 73.6 19.2L371.2 588.8ZM889.599 336c-12.8-16-28.8-28.8-41.6-41.6l-48 48c73.6 67.2 124.8 124.8 150.4 169.6-28.8 48-80 105.6-153.6 172.8-73.6 67.2-172.8 108.8-284.8 115.2-51.2-3.2-99.2-12.8-140.8-28.8l-48 48c57.6 22.4 118.4 38.4 188.8 44.8 160-16 288-73.6 377.6-176C979.199 585.6 1024 528 1024 512s-48.001-73.6-134.401-176Z', fill: 'currentColor', }, null, -1 ) const _hoisted_3$7f = /* @__PURE__ */ createElementVNode( 'path', { d: 'M511.998 672c-12.8 0-25.6-3.2-38.4-6.4l-51.2 51.2c28.8 12.8 57.6 19.2 89.6 19.2 64 0 115.2-22.4 160-64 41.6-41.6 64-96 64-160 0-32-6.4-64-19.2-89.6l-51.2 51.2c3.2 12.8 6.4 25.6 6.4 38.4 0 44.8-16 83.2-48 112-32 28.8-67.2 48-112 48Z', fill: 'currentColor', }, null, -1 ) const _hoisted_4$4S = [_hoisted_2$7$, _hoisted_3$7f] function _sfc_render$47(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9p, _hoisted_4$4S) } var hide$2 = /* @__PURE__ */ _export_sfc$2(_sfc_main$bM, [ ['render', _sfc_render$47], ]) const _sfc_main$bL = defineComponent({ name: 'Histogram', }) const _hoisted_1$9o = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7_ = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M416 896V128h192v768H416zm-288 0V448h192v448H128zm576 0V320h192v576H704z', }, null, -1 ) const _hoisted_3$7e = [_hoisted_2$7_] function _sfc_render$46(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9o, _hoisted_3$7e) } var histogram = /* @__PURE__ */ _export_sfc$2(_sfc_main$bL, [ ['render', _sfc_render$46], ]) const _sfc_main$bK = defineComponent({ name: 'HomeFilled', }) const _hoisted_1$9n = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7Z = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 128 128 447.936V896h255.936V640H640v256h255.936V447.936z', }, null, -1 ) const _hoisted_3$7d = [_hoisted_2$7Z] function _sfc_render$45(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9n, _hoisted_3$7d) } var homeFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$bK, [ ['render', _sfc_render$45], ]) const _sfc_main$bJ = defineComponent({ name: 'HotWater', }) const _hoisted_1$9m = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7Y = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M273.067 477.867h477.866V409.6H273.067v68.267zm0 68.266v51.2A187.733 187.733 0 0 0 460.8 785.067h102.4a187.733 187.733 0 0 0 187.733-187.734v-51.2H273.067zm-34.134-204.8h546.134a34.133 34.133 0 0 1 34.133 34.134v221.866a256 256 0 0 1-256 256H460.8a256 256 0 0 1-256-256V375.467a34.133 34.133 0 0 1 34.133-34.134zM512 34.133a34.133 34.133 0 0 1 34.133 34.134v170.666a34.133 34.133 0 0 1-68.266 0V68.267A34.133 34.133 0 0 1 512 34.133zM375.467 102.4a34.133 34.133 0 0 1 34.133 34.133v102.4a34.133 34.133 0 0 1-68.267 0v-102.4a34.133 34.133 0 0 1 34.134-34.133zm273.066 0a34.133 34.133 0 0 1 34.134 34.133v102.4a34.133 34.133 0 1 1-68.267 0v-102.4a34.133 34.133 0 0 1 34.133-34.133zM170.667 921.668h682.666a34.133 34.133 0 1 1 0 68.267H170.667a34.133 34.133 0 1 1 0-68.267z', }, null, -1 ) const _hoisted_3$7c = [_hoisted_2$7Y] function _sfc_render$44(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9m, _hoisted_3$7c) } var hotWater = /* @__PURE__ */ _export_sfc$2(_sfc_main$bJ, [ ['render', _sfc_render$44], ]) const _sfc_main$bI = defineComponent({ name: 'House', }) const _hoisted_1$9l = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7X = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M192 413.952V896h640V413.952L512 147.328 192 413.952zM139.52 374.4l352-293.312a32 32 0 0 1 40.96 0l352 293.312A32 32 0 0 1 896 398.976V928a32 32 0 0 1-32 32H160a32 32 0 0 1-32-32V398.976a32 32 0 0 1 11.52-24.576z', }, null, -1 ) const _hoisted_3$7b = [_hoisted_2$7X] function _sfc_render$43(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9l, _hoisted_3$7b) } var house = /* @__PURE__ */ _export_sfc$2(_sfc_main$bI, [ ['render', _sfc_render$43], ]) const _sfc_main$bH = defineComponent({ name: 'IceCreamRound', }) const _hoisted_1$9k = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7W = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm308.352 489.344 226.304 226.304a32 32 0 0 0 45.248 0L783.552 512A192 192 0 1 0 512 240.448L308.352 444.16a32 32 0 0 0 0 45.248zm135.744 226.304L308.352 851.392a96 96 0 0 1-135.744-135.744l135.744-135.744-45.248-45.248a96 96 0 0 1 0-135.808L466.752 195.2A256 256 0 0 1 828.8 557.248L625.152 760.96a96 96 0 0 1-135.808 0l-45.248-45.248zM398.848 670.4 353.6 625.152 217.856 760.896a32 32 0 0 0 45.248 45.248L398.848 670.4zm248.96-384.64a32 32 0 0 1 0 45.248L466.624 512a32 32 0 1 1-45.184-45.248l180.992-181.056a32 32 0 0 1 45.248 0zm90.496 90.496a32 32 0 0 1 0 45.248L557.248 602.496A32 32 0 1 1 512 557.248l180.992-180.992a32 32 0 0 1 45.312 0z', }, null, -1 ) const _hoisted_3$7a = [_hoisted_2$7W] function _sfc_render$42(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9k, _hoisted_3$7a) } var iceCreamRound = /* @__PURE__ */ _export_sfc$2(_sfc_main$bH, [ ['render', _sfc_render$42], ]) const _sfc_main$bG = defineComponent({ name: 'IceCreamSquare', }) const _hoisted_1$9j = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7V = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M416 640h256a32 32 0 0 0 32-32V160a32 32 0 0 0-32-32H352a32 32 0 0 0-32 32v448a32 32 0 0 0 32 32h64zm192 64v160a96 96 0 0 1-192 0V704h-64a96 96 0 0 1-96-96V160a96 96 0 0 1 96-96h320a96 96 0 0 1 96 96v448a96 96 0 0 1-96 96h-64zm-64 0h-64v160a32 32 0 1 0 64 0V704z', }, null, -1 ) const _hoisted_3$79 = [_hoisted_2$7V] function _sfc_render$41(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9j, _hoisted_3$79) } var iceCreamSquare = /* @__PURE__ */ _export_sfc$2(_sfc_main$bG, [ ['render', _sfc_render$41], ]) const _sfc_main$bF = defineComponent({ name: 'IceCream', }) const _hoisted_1$9i = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7U = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M128.64 448a208 208 0 0 1 193.536-191.552 224 224 0 0 1 445.248 15.488A208.128 208.128 0 0 1 894.784 448H896L548.8 983.68a32 32 0 0 1-53.248.704L128 448h.64zm64.256 0h286.208a144 144 0 0 0-286.208 0zm351.36 0h286.272a144 144 0 0 0-286.272 0zm-294.848 64 271.808 396.608L778.24 512H249.408zM511.68 352.64a207.872 207.872 0 0 1 189.184-96.192 160 160 0 0 0-314.752 5.632c52.608 12.992 97.28 46.08 125.568 90.56z', }, null, -1 ) const _hoisted_3$78 = [_hoisted_2$7U] function _sfc_render$40(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9i, _hoisted_3$78) } var iceCream = /* @__PURE__ */ _export_sfc$2(_sfc_main$bF, [ ['render', _sfc_render$40], ]) const _sfc_main$bE = defineComponent({ name: 'IceDrink', }) const _hoisted_1$9h = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7T = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 448v128h239.68l16.064-128H512zm-64 0H256.256l16.064 128H448V448zm64-255.36V384h247.744A256.128 256.128 0 0 0 512 192.64zm-64 8.064A256.448 256.448 0 0 0 264.256 384H448V200.704zm64-72.064A320.128 320.128 0 0 1 825.472 384H896a32 32 0 1 1 0 64h-64v1.92l-56.96 454.016A64 64 0 0 1 711.552 960H312.448a64 64 0 0 1-63.488-56.064L192 449.92V448h-64a32 32 0 0 1 0-64h70.528A320.384 320.384 0 0 1 448 135.04V96a96 96 0 0 1 96-96h128a32 32 0 1 1 0 64H544a32 32 0 0 0-32 32v32.64zM743.68 640H280.32l32.128 256h399.104l32.128-256z', }, null, -1 ) const _hoisted_3$77 = [_hoisted_2$7T] function _sfc_render$3$(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9h, _hoisted_3$77) } var iceDrink = /* @__PURE__ */ _export_sfc$2(_sfc_main$bE, [ ['render', _sfc_render$3$], ]) const _sfc_main$bD = defineComponent({ name: 'IceTea', }) const _hoisted_1$9g = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7S = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M197.696 259.648a320.128 320.128 0 0 1 628.608 0A96 96 0 0 1 896 352v64a96 96 0 0 1-71.616 92.864l-49.408 395.072A64 64 0 0 1 711.488 960H312.512a64 64 0 0 1-63.488-56.064l-49.408-395.072A96 96 0 0 1 128 416v-64a96 96 0 0 1 69.696-92.352zM264.064 256h495.872a256.128 256.128 0 0 0-495.872 0zm495.424 256H264.512l48 384h398.976l48-384zM224 448h576a32 32 0 0 0 32-32v-64a32 32 0 0 0-32-32H224a32 32 0 0 0-32 32v64a32 32 0 0 0 32 32zm160 192h64v64h-64v-64zm192 64h64v64h-64v-64zm-128 64h64v64h-64v-64zm64-192h64v64h-64v-64z', }, null, -1 ) const _hoisted_3$76 = [_hoisted_2$7S] function _sfc_render$3_(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9g, _hoisted_3$76) } var iceTea = /* @__PURE__ */ _export_sfc$2(_sfc_main$bD, [ ['render', _sfc_render$3_], ]) const _sfc_main$bC = defineComponent({ name: 'InfoFilled', }) const _hoisted_1$9f = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7R = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 64a448 448 0 1 1 0 896.064A448 448 0 0 1 512 64zm67.2 275.072c33.28 0 60.288-23.104 60.288-57.344s-27.072-57.344-60.288-57.344c-33.28 0-60.16 23.104-60.16 57.344s26.88 57.344 60.16 57.344zM590.912 699.2c0-6.848 2.368-24.64 1.024-34.752l-52.608 60.544c-10.88 11.456-24.512 19.392-30.912 17.28a12.992 12.992 0 0 1-8.256-14.72l87.68-276.992c7.168-35.136-12.544-67.2-54.336-71.296-44.096 0-108.992 44.736-148.48 101.504 0 6.784-1.28 23.68.064 33.792l52.544-60.608c10.88-11.328 23.552-19.328 29.952-17.152a12.8 12.8 0 0 1 7.808 16.128L388.48 728.576c-10.048 32.256 8.96 63.872 55.04 71.04 67.84 0 107.904-43.648 147.456-100.416z', }, null, -1 ) const _hoisted_3$75 = [_hoisted_2$7R] function _sfc_render$3Z(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9f, _hoisted_3$75) } var infoFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$bC, [ ['render', _sfc_render$3Z], ]) const _sfc_main$bB = defineComponent({ name: 'Iphone', }) const _hoisted_1$9e = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7Q = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M224 768v96.064a64 64 0 0 0 64 64h448a64 64 0 0 0 64-64V768H224zm0-64h576V160a64 64 0 0 0-64-64H288a64 64 0 0 0-64 64v544zm32 288a96 96 0 0 1-96-96V128a96 96 0 0 1 96-96h512a96 96 0 0 1 96 96v768a96 96 0 0 1-96 96H256zm304-144a48 48 0 1 1-96 0 48 48 0 0 1 96 0z', }, null, -1 ) const _hoisted_3$74 = [_hoisted_2$7Q] function _sfc_render$3Y(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9e, _hoisted_3$74) } var iphone = /* @__PURE__ */ _export_sfc$2(_sfc_main$bB, [ ['render', _sfc_render$3Y], ]) const _sfc_main$bA = defineComponent({ name: 'Key', }) const _hoisted_1$9d = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7P = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M448 456.064V96a32 32 0 0 1 32-32.064L672 64a32 32 0 0 1 0 64H512v128h160a32 32 0 0 1 0 64H512v128a256 256 0 1 1-64 8.064zM512 896a192 192 0 1 0 0-384 192 192 0 0 0 0 384z', }, null, -1 ) const _hoisted_3$73 = [_hoisted_2$7P] function _sfc_render$3X(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9d, _hoisted_3$73) } var key = /* @__PURE__ */ _export_sfc$2(_sfc_main$bA, [ ['render', _sfc_render$3X], ]) const _sfc_main$bz = defineComponent({ name: 'KnifeFork', }) const _hoisted_1$9c = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7O = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M256 410.56V96a32 32 0 0 1 64 0v314.56A96 96 0 0 0 384 320V96a32 32 0 0 1 64 0v224a160 160 0 0 1-128 156.8V928a32 32 0 1 1-64 0V476.8A160 160 0 0 1 128 320V96a32 32 0 0 1 64 0v224a96 96 0 0 0 64 90.56zm384-250.24V544h126.72c-3.328-78.72-12.928-147.968-28.608-207.744-14.336-54.528-46.848-113.344-98.112-175.872zM640 608v320a32 32 0 1 1-64 0V64h64c85.312 89.472 138.688 174.848 160 256 21.312 81.152 32 177.152 32 288H640z', }, null, -1 ) const _hoisted_3$72 = [_hoisted_2$7O] function _sfc_render$3W(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9c, _hoisted_3$72) } var knifeFork = /* @__PURE__ */ _export_sfc$2(_sfc_main$bz, [ ['render', _sfc_render$3W], ]) const _sfc_main$by = defineComponent({ name: 'Lightning', }) const _hoisted_1$9b = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7N = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M288 671.36v64.128A239.808 239.808 0 0 1 63.744 496.192a240.32 240.32 0 0 1 199.488-236.8 256.128 256.128 0 0 1 487.872-30.976A256.064 256.064 0 0 1 736 734.016v-64.768a192 192 0 0 0 3.328-377.92l-35.2-6.592-12.8-33.408a192.064 192.064 0 0 0-365.952 23.232l-9.92 40.896-41.472 7.04a176.32 176.32 0 0 0-146.24 173.568c0 91.968 70.464 167.36 160.256 175.232z', }, null, -1 ) const _hoisted_3$71 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M416 736a32 32 0 0 1-27.776-47.872l128-224a32 32 0 1 1 55.552 31.744L471.168 672H608a32 32 0 0 1 27.776 47.872l-128 224a32 32 0 1 1-55.68-31.744L552.96 736H416z', }, null, -1 ) const _hoisted_4$4R = [_hoisted_2$7N, _hoisted_3$71] function _sfc_render$3V(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9b, _hoisted_4$4R) } var lightning = /* @__PURE__ */ _export_sfc$2(_sfc_main$by, [ ['render', _sfc_render$3V], ]) const _sfc_main$bx = defineComponent({ name: 'Link', }) const _hoisted_1$9a = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7M = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M715.648 625.152 670.4 579.904l90.496-90.56c75.008-74.944 85.12-186.368 22.656-248.896-62.528-62.464-173.952-52.352-248.96 22.656L444.16 353.6l-45.248-45.248 90.496-90.496c100.032-99.968 251.968-110.08 339.456-22.656 87.488 87.488 77.312 239.424-22.656 339.456l-90.496 90.496zm-90.496 90.496-90.496 90.496C434.624 906.112 282.688 916.224 195.2 828.8c-87.488-87.488-77.312-239.424 22.656-339.456l90.496-90.496 45.248 45.248-90.496 90.56c-75.008 74.944-85.12 186.368-22.656 248.896 62.528 62.464 173.952 52.352 248.96-22.656l90.496-90.496 45.248 45.248zm0-362.048 45.248 45.248L398.848 670.4 353.6 625.152 625.152 353.6z', }, null, -1 ) const _hoisted_3$70 = [_hoisted_2$7M] function _sfc_render$3U(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$9a, _hoisted_3$70) } var link = /* @__PURE__ */ _export_sfc$2(_sfc_main$bx, [ ['render', _sfc_render$3U], ]) const _sfc_main$bw = defineComponent({ name: 'List', }) const _hoisted_1$99 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7L = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M704 192h160v736H160V192h160v64h384v-64zM288 512h448v-64H288v64zm0 256h448v-64H288v64zm96-576V96h256v96H384z', }, null, -1 ) const _hoisted_3$6$ = [_hoisted_2$7L] function _sfc_render$3T(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$99, _hoisted_3$6$) } var list = /* @__PURE__ */ _export_sfc$2(_sfc_main$bw, [ ['render', _sfc_render$3T], ]) const _sfc_main$bv = defineComponent({ name: 'Loading', }) const _hoisted_1$98 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7K = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 64a32 32 0 0 1 32 32v192a32 32 0 0 1-64 0V96a32 32 0 0 1 32-32zm0 640a32 32 0 0 1 32 32v192a32 32 0 1 1-64 0V736a32 32 0 0 1 32-32zm448-192a32 32 0 0 1-32 32H736a32 32 0 1 1 0-64h192a32 32 0 0 1 32 32zm-640 0a32 32 0 0 1-32 32H96a32 32 0 0 1 0-64h192a32 32 0 0 1 32 32zM195.2 195.2a32 32 0 0 1 45.248 0L376.32 331.008a32 32 0 0 1-45.248 45.248L195.2 240.448a32 32 0 0 1 0-45.248zm452.544 452.544a32 32 0 0 1 45.248 0L828.8 783.552a32 32 0 0 1-45.248 45.248L647.744 692.992a32 32 0 0 1 0-45.248zM828.8 195.264a32 32 0 0 1 0 45.184L692.992 376.32a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0zm-452.544 452.48a32 32 0 0 1 0 45.248L240.448 828.8a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0z', }, null, -1 ) const _hoisted_3$6_ = [_hoisted_2$7K] function _sfc_render$3S(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$98, _hoisted_3$6_) } var loading = /* @__PURE__ */ _export_sfc$2(_sfc_main$bv, [ ['render', _sfc_render$3S], ]) const _sfc_main$bu = defineComponent({ name: 'LocationFilled', }) const _hoisted_1$97 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7J = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 928c23.936 0 117.504-68.352 192.064-153.152C803.456 661.888 864 535.808 864 416c0-189.632-155.84-320-352-320S160 226.368 160 416c0 120.32 60.544 246.4 159.936 359.232C394.432 859.84 488 928 512 928zm0-435.2a64 64 0 1 0 0-128 64 64 0 0 0 0 128zm0 140.8a204.8 204.8 0 1 1 0-409.6 204.8 204.8 0 0 1 0 409.6z', }, null, -1 ) const _hoisted_3$6Z = [_hoisted_2$7J] function _sfc_render$3R(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$97, _hoisted_3$6Z) } var locationFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$bu, [ ['render', _sfc_render$3R], ]) const _sfc_main$bt = defineComponent({ name: 'LocationInformation', }) const _hoisted_1$96 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7I = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M288 896h448q32 0 32 32t-32 32H288q-32 0-32-32t32-32z', }, null, -1 ) const _hoisted_3$6Y = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M800 416a288 288 0 1 0-576 0c0 118.144 94.528 272.128 288 456.576C705.472 688.128 800 534.144 800 416zM512 960C277.312 746.688 160 565.312 160 416a352 352 0 0 1 704 0c0 149.312-117.312 330.688-352 544z', }, null, -1 ) const _hoisted_4$4Q = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 512a96 96 0 1 0 0-192 96 96 0 0 0 0 192zm0 64a160 160 0 1 1 0-320 160 160 0 0 1 0 320z', }, null, -1 ) const _hoisted_5$3S = [_hoisted_2$7I, _hoisted_3$6Y, _hoisted_4$4Q] function _sfc_render$3Q(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$96, _hoisted_5$3S) } var locationInformation = /* @__PURE__ */ _export_sfc$2(_sfc_main$bt, [ ['render', _sfc_render$3Q], ]) const _sfc_main$bs = defineComponent({ name: 'Location', }) const _hoisted_1$95 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7H = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M800 416a288 288 0 1 0-576 0c0 118.144 94.528 272.128 288 456.576C705.472 688.128 800 534.144 800 416zM512 960C277.312 746.688 160 565.312 160 416a352 352 0 0 1 704 0c0 149.312-117.312 330.688-352 544z', }, null, -1 ) const _hoisted_3$6X = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 512a96 96 0 1 0 0-192 96 96 0 0 0 0 192zm0 64a160 160 0 1 1 0-320 160 160 0 0 1 0 320z', }, null, -1 ) const _hoisted_4$4P = [_hoisted_2$7H, _hoisted_3$6X] function _sfc_render$3P(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$95, _hoisted_4$4P) } var location$1 = /* @__PURE__ */ _export_sfc$2(_sfc_main$bs, [ ['render', _sfc_render$3P], ]) const _sfc_main$br = defineComponent({ name: 'Lock', }) const _hoisted_1$94 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7G = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M224 448a32 32 0 0 0-32 32v384a32 32 0 0 0 32 32h576a32 32 0 0 0 32-32V480a32 32 0 0 0-32-32H224zm0-64h576a96 96 0 0 1 96 96v384a96 96 0 0 1-96 96H224a96 96 0 0 1-96-96V480a96 96 0 0 1 96-96z', }, null, -1 ) const _hoisted_3$6W = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 544a32 32 0 0 1 32 32v192a32 32 0 1 1-64 0V576a32 32 0 0 1 32-32zm192-160v-64a192 192 0 1 0-384 0v64h384zM512 64a256 256 0 0 1 256 256v128H256V320A256 256 0 0 1 512 64z', }, null, -1 ) const _hoisted_4$4O = [_hoisted_2$7G, _hoisted_3$6W] function _sfc_render$3O(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$94, _hoisted_4$4O) } var lock = /* @__PURE__ */ _export_sfc$2(_sfc_main$br, [ ['render', _sfc_render$3O], ]) const _sfc_main$bq = defineComponent({ name: 'Lollipop', }) const _hoisted_1$93 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7F = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M513.28 448a64 64 0 1 1 76.544 49.728A96 96 0 0 0 768 448h64a160 160 0 0 1-320 0h1.28zm-126.976-29.696a256 256 0 1 0 43.52-180.48A256 256 0 0 1 832 448h-64a192 192 0 0 0-381.696-29.696zm105.664 249.472L285.696 874.048a96 96 0 0 1-135.68-135.744l206.208-206.272a320 320 0 1 1 135.744 135.744zm-54.464-36.032a321.92 321.92 0 0 1-45.248-45.248L195.2 783.552a32 32 0 1 0 45.248 45.248l197.056-197.12z', }, null, -1 ) const _hoisted_3$6V = [_hoisted_2$7F] function _sfc_render$3N(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$93, _hoisted_3$6V) } var lollipop = /* @__PURE__ */ _export_sfc$2(_sfc_main$bq, [ ['render', _sfc_render$3N], ]) const _sfc_main$bp = defineComponent({ name: 'MagicStick', }) const _hoisted_1$92 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7E = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 64h64v192h-64V64zm0 576h64v192h-64V640zM160 480v-64h192v64H160zm576 0v-64h192v64H736zM249.856 199.04l45.248-45.184L430.848 289.6 385.6 334.848 249.856 199.104zM657.152 606.4l45.248-45.248 135.744 135.744-45.248 45.248L657.152 606.4zM114.048 923.2 68.8 877.952l316.8-316.8 45.248 45.248-316.8 316.8zM702.4 334.848 657.152 289.6l135.744-135.744 45.248 45.248L702.4 334.848z', }, null, -1 ) const _hoisted_3$6U = [_hoisted_2$7E] function _sfc_render$3M(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$92, _hoisted_3$6U) } var magicStick = /* @__PURE__ */ _export_sfc$2(_sfc_main$bp, [ ['render', _sfc_render$3M], ]) const _sfc_main$bo = defineComponent({ name: 'Magnet', }) const _hoisted_1$91 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7D = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M832 320V192H704v320a192 192 0 1 1-384 0V192H192v128h128v64H192v128a320 320 0 0 0 640 0V384H704v-64h128zM640 512V128h256v384a384 384 0 1 1-768 0V128h256v384a128 128 0 1 0 256 0z', }, null, -1 ) const _hoisted_3$6T = [_hoisted_2$7D] function _sfc_render$3L(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$91, _hoisted_3$6T) } var magnet = /* @__PURE__ */ _export_sfc$2(_sfc_main$bo, [ ['render', _sfc_render$3L], ]) const _sfc_main$bn = defineComponent({ name: 'Male', }) const _hoisted_1$90 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7C = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M399.5 849.5a225 225 0 1 0 0-450 225 225 0 0 0 0 450zm0 56.25a281.25 281.25 0 1 1 0-562.5 281.25 281.25 0 0 1 0 562.5zm253.125-787.5h225q28.125 0 28.125 28.125T877.625 174.5h-225q-28.125 0-28.125-28.125t28.125-28.125z', }, null, -1 ) const _hoisted_3$6S = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M877.625 118.25q28.125 0 28.125 28.125v225q0 28.125-28.125 28.125T849.5 371.375v-225q0-28.125 28.125-28.125z', }, null, -1 ) const _hoisted_4$4N = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M604.813 458.9 565.1 419.131l292.613-292.668 39.825 39.824z', }, null, -1 ) const _hoisted_5$3R = [_hoisted_2$7C, _hoisted_3$6S, _hoisted_4$4N] function _sfc_render$3K(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$90, _hoisted_5$3R) } var male = /* @__PURE__ */ _export_sfc$2(_sfc_main$bn, [ ['render', _sfc_render$3K], ]) const _sfc_main$bm = defineComponent({ name: 'Management', }) const _hoisted_1$8$ = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7B = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M576 128v288l96-96 96 96V128h128v768H320V128h256zm-448 0h128v768H128V128z', }, null, -1 ) const _hoisted_3$6R = [_hoisted_2$7B] function _sfc_render$3J(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8$, _hoisted_3$6R) } var management = /* @__PURE__ */ _export_sfc$2(_sfc_main$bm, [ ['render', _sfc_render$3J], ]) const _sfc_main$bl = defineComponent({ name: 'MapLocation', }) const _hoisted_1$8_ = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7A = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M800 416a288 288 0 1 0-576 0c0 118.144 94.528 272.128 288 456.576C705.472 688.128 800 534.144 800 416zM512 960C277.312 746.688 160 565.312 160 416a352 352 0 0 1 704 0c0 149.312-117.312 330.688-352 544z', }, null, -1 ) const _hoisted_3$6Q = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 448a64 64 0 1 0 0-128 64 64 0 0 0 0 128zm0 64a128 128 0 1 1 0-256 128 128 0 0 1 0 256zm345.6 192L960 960H672v-64H352v64H64l102.4-256h691.2zm-68.928 0H235.328l-76.8 192h706.944l-76.8-192z', }, null, -1 ) const _hoisted_4$4M = [_hoisted_2$7A, _hoisted_3$6Q] function _sfc_render$3I(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8_, _hoisted_4$4M) } var mapLocation = /* @__PURE__ */ _export_sfc$2(_sfc_main$bl, [ ['render', _sfc_render$3I], ]) const _sfc_main$bk = defineComponent({ name: 'Medal', }) const _hoisted_1$8Z = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7z = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 896a256 256 0 1 0 0-512 256 256 0 0 0 0 512zm0 64a320 320 0 1 1 0-640 320 320 0 0 1 0 640z', }, null, -1 ) const _hoisted_3$6P = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M576 128H448v200a286.72 286.72 0 0 1 64-8c19.52 0 40.832 2.688 64 8V128zm64 0v219.648c24.448 9.088 50.56 20.416 78.4 33.92L757.44 128H640zm-256 0H266.624l39.04 253.568c27.84-13.504 53.888-24.832 78.336-33.92V128zM229.312 64h565.376a32 32 0 0 1 31.616 36.864L768 480c-113.792-64-199.104-96-256-96-56.896 0-142.208 32-256 96l-58.304-379.136A32 32 0 0 1 229.312 64z', }, null, -1 ) const _hoisted_4$4L = [_hoisted_2$7z, _hoisted_3$6P] function _sfc_render$3H(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8Z, _hoisted_4$4L) } var medal = /* @__PURE__ */ _export_sfc$2(_sfc_main$bk, [ ['render', _sfc_render$3H], ]) const _sfc_main$bj = defineComponent({ name: 'Menu', }) const _hoisted_1$8Y = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7y = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M160 448a32 32 0 0 1-32-32V160.064a32 32 0 0 1 32-32h256a32 32 0 0 1 32 32V416a32 32 0 0 1-32 32H160zm448 0a32 32 0 0 1-32-32V160.064a32 32 0 0 1 32-32h255.936a32 32 0 0 1 32 32V416a32 32 0 0 1-32 32H608zM160 896a32 32 0 0 1-32-32V608a32 32 0 0 1 32-32h256a32 32 0 0 1 32 32v256a32 32 0 0 1-32 32H160zm448 0a32 32 0 0 1-32-32V608a32 32 0 0 1 32-32h255.936a32 32 0 0 1 32 32v256a32 32 0 0 1-32 32H608z', }, null, -1 ) const _hoisted_3$6O = [_hoisted_2$7y] function _sfc_render$3G(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8Y, _hoisted_3$6O) } var menu = /* @__PURE__ */ _export_sfc$2(_sfc_main$bj, [ ['render', _sfc_render$3G], ]) const _sfc_main$bi = defineComponent({ name: 'MessageBox', }) const _hoisted_1$8X = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7x = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M288 384h448v64H288v-64zm96-128h256v64H384v-64zM131.456 512H384v128h256V512h252.544L721.856 192H302.144L131.456 512zM896 576H704v128H320V576H128v256h768V576zM275.776 128h472.448a32 32 0 0 1 28.608 17.664l179.84 359.552A32 32 0 0 1 960 519.552V864a32 32 0 0 1-32 32H96a32 32 0 0 1-32-32V519.552a32 32 0 0 1 3.392-14.336l179.776-359.552A32 32 0 0 1 275.776 128z', }, null, -1 ) const _hoisted_3$6N = [_hoisted_2$7x] function _sfc_render$3F(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8X, _hoisted_3$6N) } var messageBox = /* @__PURE__ */ _export_sfc$2(_sfc_main$bi, [ ['render', _sfc_render$3F], ]) const _sfc_main$bh = defineComponent({ name: 'Message', }) const _hoisted_1$8W = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7w = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M128 224v512a64 64 0 0 0 64 64h640a64 64 0 0 0 64-64V224H128zm0-64h768a64 64 0 0 1 64 64v512a128 128 0 0 1-128 128H192A128 128 0 0 1 64 736V224a64 64 0 0 1 64-64z', }, null, -1 ) const _hoisted_3$6M = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M904 224 656.512 506.88a192 192 0 0 1-289.024 0L120 224h784zm-698.944 0 210.56 240.704a128 128 0 0 0 192.704 0L818.944 224H205.056z', }, null, -1 ) const _hoisted_4$4K = [_hoisted_2$7w, _hoisted_3$6M] function _sfc_render$3E(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8W, _hoisted_4$4K) } var message$1 = /* @__PURE__ */ _export_sfc$2(_sfc_main$bh, [ ['render', _sfc_render$3E], ]) const _sfc_main$bg = defineComponent({ name: 'Mic', }) const _hoisted_1$8V = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7v = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M480 704h160a64 64 0 0 0 64-64v-32h-96a32 32 0 0 1 0-64h96v-96h-96a32 32 0 0 1 0-64h96v-96h-96a32 32 0 0 1 0-64h96v-32a64 64 0 0 0-64-64H384a64 64 0 0 0-64 64v32h96a32 32 0 0 1 0 64h-96v96h96a32 32 0 0 1 0 64h-96v96h96a32 32 0 0 1 0 64h-96v32a64 64 0 0 0 64 64h96zm64 64v128h192a32 32 0 1 1 0 64H288a32 32 0 1 1 0-64h192V768h-96a128 128 0 0 1-128-128V192A128 128 0 0 1 384 64h256a128 128 0 0 1 128 128v448a128 128 0 0 1-128 128h-96z', }, null, -1 ) const _hoisted_3$6L = [_hoisted_2$7v] function _sfc_render$3D(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8V, _hoisted_3$6L) } var mic = /* @__PURE__ */ _export_sfc$2(_sfc_main$bg, [ ['render', _sfc_render$3D], ]) const _sfc_main$bf = defineComponent({ name: 'Microphone', }) const _hoisted_1$8U = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7u = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 128a128 128 0 0 0-128 128v256a128 128 0 1 0 256 0V256a128 128 0 0 0-128-128zm0-64a192 192 0 0 1 192 192v256a192 192 0 1 1-384 0V256A192 192 0 0 1 512 64zm-32 832v-64a288 288 0 0 1-288-288v-32a32 32 0 0 1 64 0v32a224 224 0 0 0 224 224h64a224 224 0 0 0 224-224v-32a32 32 0 1 1 64 0v32a288 288 0 0 1-288 288v64h64a32 32 0 1 1 0 64H416a32 32 0 1 1 0-64h64z', }, null, -1 ) const _hoisted_3$6K = [_hoisted_2$7u] function _sfc_render$3C(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8U, _hoisted_3$6K) } var microphone = /* @__PURE__ */ _export_sfc$2(_sfc_main$bf, [ ['render', _sfc_render$3C], ]) const _sfc_main$be = defineComponent({ name: 'MilkTea', }) const _hoisted_1$8T = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7t = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M416 128V96a96 96 0 0 1 96-96h128a32 32 0 1 1 0 64H512a32 32 0 0 0-32 32v32h320a96 96 0 0 1 11.712 191.296l-39.68 581.056A64 64 0 0 1 708.224 960H315.776a64 64 0 0 1-63.872-59.648l-39.616-581.056A96 96 0 0 1 224 128h192zM276.48 320l39.296 576h392.448l4.8-70.784a224.064 224.064 0 0 1 30.016-439.808L747.52 320H276.48zM224 256h576a32 32 0 1 0 0-64H224a32 32 0 0 0 0 64zm493.44 503.872 21.12-309.12a160 160 0 0 0-21.12 309.12z', }, null, -1 ) const _hoisted_3$6J = [_hoisted_2$7t] function _sfc_render$3B(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8T, _hoisted_3$6J) } var milkTea = /* @__PURE__ */ _export_sfc$2(_sfc_main$be, [ ['render', _sfc_render$3B], ]) const _sfc_main$bd = defineComponent({ name: 'Minus', }) const _hoisted_1$8S = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7s = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M128 544h768a32 32 0 1 0 0-64H128a32 32 0 0 0 0 64z', }, null, -1 ) const _hoisted_3$6I = [_hoisted_2$7s] function _sfc_render$3A(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8S, _hoisted_3$6I) } var minus = /* @__PURE__ */ _export_sfc$2(_sfc_main$bd, [ ['render', _sfc_render$3A], ]) const _sfc_main$bc = defineComponent({ name: 'Money', }) const _hoisted_1$8R = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7r = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M256 640v192h640V384H768v-64h150.976c14.272 0 19.456 1.472 24.64 4.288a29.056 29.056 0 0 1 12.16 12.096c2.752 5.184 4.224 10.368 4.224 24.64v493.952c0 14.272-1.472 19.456-4.288 24.64a29.056 29.056 0 0 1-12.096 12.16c-5.184 2.752-10.368 4.224-24.64 4.224H233.024c-14.272 0-19.456-1.472-24.64-4.288a29.056 29.056 0 0 1-12.16-12.096c-2.688-5.184-4.224-10.368-4.224-24.576V640h64z', }, null, -1 ) const _hoisted_3$6H = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M768 192H128v448h640V192zm64-22.976v493.952c0 14.272-1.472 19.456-4.288 24.64a29.056 29.056 0 0 1-12.096 12.16c-5.184 2.752-10.368 4.224-24.64 4.224H105.024c-14.272 0-19.456-1.472-24.64-4.288a29.056 29.056 0 0 1-12.16-12.096C65.536 682.432 64 677.248 64 663.04V169.024c0-14.272 1.472-19.456 4.288-24.64a29.056 29.056 0 0 1 12.096-12.16C85.568 129.536 90.752 128 104.96 128h685.952c14.272 0 19.456 1.472 24.64 4.288a29.056 29.056 0 0 1 12.16 12.096c2.752 5.184 4.224 10.368 4.224 24.64z', }, null, -1 ) const _hoisted_4$4J = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M448 576a160 160 0 1 1 0-320 160 160 0 0 1 0 320zm0-64a96 96 0 1 0 0-192 96 96 0 0 0 0 192z', }, null, -1 ) const _hoisted_5$3Q = [_hoisted_2$7r, _hoisted_3$6H, _hoisted_4$4J] function _sfc_render$3z(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8R, _hoisted_5$3Q) } var money = /* @__PURE__ */ _export_sfc$2(_sfc_main$bc, [ ['render', _sfc_render$3z], ]) const _sfc_main$bb = defineComponent({ name: 'Monitor', }) const _hoisted_1$8Q = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7q = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M544 768v128h192a32 32 0 1 1 0 64H288a32 32 0 1 1 0-64h192V768H192A128 128 0 0 1 64 640V256a128 128 0 0 1 128-128h640a128 128 0 0 1 128 128v384a128 128 0 0 1-128 128H544zM192 192a64 64 0 0 0-64 64v384a64 64 0 0 0 64 64h640a64 64 0 0 0 64-64V256a64 64 0 0 0-64-64H192z', }, null, -1 ) const _hoisted_3$6G = [_hoisted_2$7q] function _sfc_render$3y(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8Q, _hoisted_3$6G) } var monitor = /* @__PURE__ */ _export_sfc$2(_sfc_main$bb, [ ['render', _sfc_render$3y], ]) const _sfc_main$ba = defineComponent({ name: 'MoonNight', }) const _hoisted_1$8P = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7p = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M384 512a448 448 0 0 1 215.872-383.296A384 384 0 0 0 213.76 640h188.8A448.256 448.256 0 0 1 384 512zM171.136 704a448 448 0 0 1 636.992-575.296A384 384 0 0 0 499.328 704h-328.32z', }, null, -1 ) const _hoisted_3$6F = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M32 640h960q32 0 32 32t-32 32H32q-32 0-32-32t32-32zm128 128h384a32 32 0 1 1 0 64H160a32 32 0 1 1 0-64zm160 127.68 224 .256a32 32 0 0 1 32 32V928a32 32 0 0 1-32 32l-224-.384a32 32 0 0 1-32-32v-.064a32 32 0 0 1 32-32z', }, null, -1 ) const _hoisted_4$4I = [_hoisted_2$7p, _hoisted_3$6F] function _sfc_render$3x(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8P, _hoisted_4$4I) } var moonNight = /* @__PURE__ */ _export_sfc$2(_sfc_main$ba, [ ['render', _sfc_render$3x], ]) const _sfc_main$b9 = defineComponent({ name: 'Moon', }) const _hoisted_1$8O = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7o = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M240.448 240.448a384 384 0 1 0 559.424 525.696 448 448 0 0 1-542.016-542.08 390.592 390.592 0 0 0-17.408 16.384zm181.056 362.048a384 384 0 0 0 525.632 16.384A448 448 0 1 1 405.056 76.8a384 384 0 0 0 16.448 525.696z', }, null, -1 ) const _hoisted_3$6E = [_hoisted_2$7o] function _sfc_render$3w(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8O, _hoisted_3$6E) } var moon = /* @__PURE__ */ _export_sfc$2(_sfc_main$b9, [ ['render', _sfc_render$3w], ]) const _sfc_main$b8 = defineComponent({ name: 'MoreFilled', }) const _hoisted_1$8N = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7n = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M176 416a112 112 0 1 1 0 224 112 112 0 0 1 0-224zm336 0a112 112 0 1 1 0 224 112 112 0 0 1 0-224zm336 0a112 112 0 1 1 0 224 112 112 0 0 1 0-224z', }, null, -1 ) const _hoisted_3$6D = [_hoisted_2$7n] function _sfc_render$3v(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8N, _hoisted_3$6D) } var moreFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$b8, [ ['render', _sfc_render$3v], ]) const _sfc_main$b7 = defineComponent({ name: 'More', }) const _hoisted_1$8M = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7m = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M176 416a112 112 0 1 0 0 224 112 112 0 0 0 0-224m0 64a48 48 0 1 1 0 96 48 48 0 0 1 0-96zm336-64a112 112 0 1 1 0 224 112 112 0 0 1 0-224zm0 64a48 48 0 1 0 0 96 48 48 0 0 0 0-96zm336-64a112 112 0 1 1 0 224 112 112 0 0 1 0-224zm0 64a48 48 0 1 0 0 96 48 48 0 0 0 0-96z', }, null, -1 ) const _hoisted_3$6C = [_hoisted_2$7m] function _sfc_render$3u(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8M, _hoisted_3$6C) } var more = /* @__PURE__ */ _export_sfc$2(_sfc_main$b7, [ ['render', _sfc_render$3u], ]) const _sfc_main$b6 = defineComponent({ name: 'MostlyCloudy', }) const _hoisted_1$8L = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7l = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M737.216 357.952 704 349.824l-11.776-32a192.064 192.064 0 0 0-367.424 23.04l-8.96 39.04-39.04 8.96A192.064 192.064 0 0 0 320 768h368a207.808 207.808 0 0 0 207.808-208 208.32 208.32 0 0 0-158.592-202.048zm15.168-62.208A272.32 272.32 0 0 1 959.744 560a271.808 271.808 0 0 1-271.552 272H320a256 256 0 0 1-57.536-505.536 256.128 256.128 0 0 1 489.92-30.72z', }, null, -1 ) const _hoisted_3$6B = [_hoisted_2$7l] function _sfc_render$3t(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8L, _hoisted_3$6B) } var mostlyCloudy = /* @__PURE__ */ _export_sfc$2(_sfc_main$b6, [ ['render', _sfc_render$3t], ]) const _sfc_main$b5 = defineComponent({ name: 'Mouse', }) const _hoisted_1$8K = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7k = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M438.144 256c-68.352 0-92.736 4.672-117.76 18.112-20.096 10.752-35.52 26.176-46.272 46.272C260.672 345.408 256 369.792 256 438.144v275.712c0 68.352 4.672 92.736 18.112 117.76 10.752 20.096 26.176 35.52 46.272 46.272C345.408 891.328 369.792 896 438.144 896h147.712c68.352 0 92.736-4.672 117.76-18.112 20.096-10.752 35.52-26.176 46.272-46.272C763.328 806.592 768 782.208 768 713.856V438.144c0-68.352-4.672-92.736-18.112-117.76a110.464 110.464 0 0 0-46.272-46.272C678.592 260.672 654.208 256 585.856 256H438.144zm0-64h147.712c85.568 0 116.608 8.96 147.904 25.6 31.36 16.768 55.872 41.344 72.576 72.64C823.104 321.536 832 352.576 832 438.08v275.84c0 85.504-8.96 116.544-25.6 147.84a174.464 174.464 0 0 1-72.64 72.576C702.464 951.104 671.424 960 585.92 960H438.08c-85.504 0-116.544-8.96-147.84-25.6a174.464 174.464 0 0 1-72.64-72.704c-16.768-31.296-25.664-62.336-25.664-147.84v-275.84c0-85.504 8.96-116.544 25.6-147.84a174.464 174.464 0 0 1 72.768-72.576c31.232-16.704 62.272-25.6 147.776-25.6z', }, null, -1 ) const _hoisted_3$6A = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 320q32 0 32 32v128q0 32-32 32t-32-32V352q0-32 32-32zm32-96a32 32 0 0 1-64 0v-64a32 32 0 0 0-32-32h-96a32 32 0 0 1 0-64h96a96 96 0 0 1 96 96v64z', }, null, -1 ) const _hoisted_4$4H = [_hoisted_2$7k, _hoisted_3$6A] function _sfc_render$3s(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8K, _hoisted_4$4H) } var mouse = /* @__PURE__ */ _export_sfc$2(_sfc_main$b5, [ ['render', _sfc_render$3s], ]) const _sfc_main$b4 = defineComponent({ name: 'Mug', }) const _hoisted_1$8J = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7j = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M736 800V160H160v640a64 64 0 0 0 64 64h448a64 64 0 0 0 64-64zm64-544h63.552a96 96 0 0 1 96 96v224a96 96 0 0 1-96 96H800v128a128 128 0 0 1-128 128H224A128 128 0 0 1 96 800V128a32 32 0 0 1 32-32h640a32 32 0 0 1 32 32v128zm0 64v288h63.552a32 32 0 0 0 32-32V352a32 32 0 0 0-32-32H800z', }, null, -1 ) const _hoisted_3$6z = [_hoisted_2$7j] function _sfc_render$3r(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8J, _hoisted_3$6z) } var mug = /* @__PURE__ */ _export_sfc$2(_sfc_main$b4, [ ['render', _sfc_render$3r], ]) const _sfc_main$b3 = defineComponent({ name: 'MuteNotification', }) const _hoisted_1$8I = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7i = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm241.216 832 63.616-64H768V448c0-42.368-10.24-82.304-28.48-117.504l46.912-47.232C815.36 331.392 832 387.84 832 448v320h96a32 32 0 1 1 0 64H241.216zm-90.24 0H96a32 32 0 1 1 0-64h96V448a320.128 320.128 0 0 1 256-313.6V128a64 64 0 1 1 128 0v6.4a319.552 319.552 0 0 1 171.648 97.088l-45.184 45.44A256 256 0 0 0 256 448v278.336L151.04 832zM448 896h128a64 64 0 0 1-128 0z', }, null, -1 ) const _hoisted_3$6y = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M150.72 859.072a32 32 0 0 1-45.44-45.056l704-708.544a32 32 0 0 1 45.44 45.056l-704 708.544z', }, null, -1 ) const _hoisted_4$4G = [_hoisted_2$7i, _hoisted_3$6y] function _sfc_render$3q(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8I, _hoisted_4$4G) } var muteNotification = /* @__PURE__ */ _export_sfc$2(_sfc_main$b3, [ ['render', _sfc_render$3q], ]) const _sfc_main$b2 = defineComponent({ name: 'Mute', }) const _hoisted_1$8H = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7h = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm412.16 592.128-45.44 45.44A191.232 191.232 0 0 1 320 512V256a192 192 0 1 1 384 0v44.352l-64 64V256a128 128 0 1 0-256 0v256c0 30.336 10.56 58.24 28.16 80.128zm51.968 38.592A128 128 0 0 0 640 512v-57.152l64-64V512a192 192 0 0 1-287.68 166.528l47.808-47.808zM314.88 779.968l46.144-46.08A222.976 222.976 0 0 0 480 768h64a224 224 0 0 0 224-224v-32a32 32 0 1 1 64 0v32a288 288 0 0 1-288 288v64h64a32 32 0 1 1 0 64H416a32 32 0 1 1 0-64h64v-64c-61.44 0-118.4-19.2-165.12-52.032zM266.752 737.6A286.976 286.976 0 0 1 192 544v-32a32 32 0 0 1 64 0v32c0 56.832 21.184 108.8 56.064 148.288L266.752 737.6z', }, null, -1 ) const _hoisted_3$6x = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M150.72 859.072a32 32 0 0 1-45.44-45.056l704-708.544a32 32 0 0 1 45.44 45.056l-704 708.544z', }, null, -1 ) const _hoisted_4$4F = [_hoisted_2$7h, _hoisted_3$6x] function _sfc_render$3p(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8H, _hoisted_4$4F) } var mute = /* @__PURE__ */ _export_sfc$2(_sfc_main$b2, [ ['render', _sfc_render$3p], ]) const _sfc_main$b1 = defineComponent({ name: 'NoSmoking', }) const _hoisted_1$8G = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7g = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M440.256 576H256v128h56.256l-64 64H224a32 32 0 0 1-32-32V544a32 32 0 0 1 32-32h280.256l-64 64zm143.488 128H704V583.744L775.744 512H928a32 32 0 0 1 32 32v192a32 32 0 0 1-32 32H519.744l64-64zM768 576v128h128V576H768zm-29.696-207.552 45.248 45.248-497.856 497.856-45.248-45.248zM256 64h64v320h-64zM128 192h64v192h-64zM64 512h64v256H64z', }, null, -1 ) const _hoisted_3$6w = [_hoisted_2$7g] function _sfc_render$3o(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8G, _hoisted_3$6w) } var noSmoking = /* @__PURE__ */ _export_sfc$2(_sfc_main$b1, [ ['render', _sfc_render$3o], ]) const _sfc_main$b0 = defineComponent({ name: 'Notebook', }) const _hoisted_1$8F = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7f = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M192 128v768h640V128H192zm-32-64h704a32 32 0 0 1 32 32v832a32 32 0 0 1-32 32H160a32 32 0 0 1-32-32V96a32 32 0 0 1 32-32z', }, null, -1 ) const _hoisted_3$6v = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M672 128h64v768h-64zM96 192h128q32 0 32 32t-32 32H96q-32 0-32-32t32-32zm0 192h128q32 0 32 32t-32 32H96q-32 0-32-32t32-32zm0 192h128q32 0 32 32t-32 32H96q-32 0-32-32t32-32zm0 192h128q32 0 32 32t-32 32H96q-32 0-32-32t32-32z', }, null, -1 ) const _hoisted_4$4E = [_hoisted_2$7f, _hoisted_3$6v] function _sfc_render$3n(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8F, _hoisted_4$4E) } var notebook = /* @__PURE__ */ _export_sfc$2(_sfc_main$b0, [ ['render', _sfc_render$3n], ]) const _sfc_main$a$ = defineComponent({ name: 'Notification', }) const _hoisted_1$8E = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7e = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 128v64H256a64 64 0 0 0-64 64v512a64 64 0 0 0 64 64h512a64 64 0 0 0 64-64V512h64v256a128 128 0 0 1-128 128H256a128 128 0 0 1-128-128V256a128 128 0 0 1 128-128h256z', }, null, -1 ) const _hoisted_3$6u = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M768 384a128 128 0 1 0 0-256 128 128 0 0 0 0 256zm0 64a192 192 0 1 1 0-384 192 192 0 0 1 0 384z', }, null, -1 ) const _hoisted_4$4D = [_hoisted_2$7e, _hoisted_3$6u] function _sfc_render$3m(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8E, _hoisted_4$4D) } var notification = /* @__PURE__ */ _export_sfc$2(_sfc_main$a$, [ ['render', _sfc_render$3m], ]) const _sfc_main$a_ = defineComponent({ name: 'Odometer', }) const _hoisted_1$8D = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7d = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 896a384 384 0 1 0 0-768 384 384 0 0 0 0 768zm0 64a448 448 0 1 1 0-896 448 448 0 0 1 0 896z', }, null, -1 ) const _hoisted_3$6t = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M192 512a320 320 0 1 1 640 0 32 32 0 1 1-64 0 256 256 0 1 0-512 0 32 32 0 0 1-64 0z', }, null, -1 ) const _hoisted_4$4C = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M570.432 627.84A96 96 0 1 1 509.568 608l60.992-187.776A32 32 0 1 1 631.424 440l-60.992 187.776zM502.08 734.464a32 32 0 1 0 19.84-60.928 32 32 0 0 0-19.84 60.928z', }, null, -1 ) const _hoisted_5$3P = [_hoisted_2$7d, _hoisted_3$6t, _hoisted_4$4C] function _sfc_render$3l(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8D, _hoisted_5$3P) } var odometer = /* @__PURE__ */ _export_sfc$2(_sfc_main$a_, [ ['render', _sfc_render$3l], ]) const _sfc_main$aZ = defineComponent({ name: 'OfficeBuilding', }) const _hoisted_1$8C = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7c = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M192 128v704h384V128H192zm-32-64h448a32 32 0 0 1 32 32v768a32 32 0 0 1-32 32H160a32 32 0 0 1-32-32V96a32 32 0 0 1 32-32z', }, null, -1 ) const _hoisted_3$6s = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M256 256h256v64H256v-64zm0 192h256v64H256v-64zm0 192h256v64H256v-64zm384-128h128v64H640v-64zm0 128h128v64H640v-64zM64 832h896v64H64v-64z', }, null, -1 ) const _hoisted_4$4B = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M640 384v448h192V384H640zm-32-64h256a32 32 0 0 1 32 32v512a32 32 0 0 1-32 32H608a32 32 0 0 1-32-32V352a32 32 0 0 1 32-32z', }, null, -1 ) const _hoisted_5$3O = [_hoisted_2$7c, _hoisted_3$6s, _hoisted_4$4B] function _sfc_render$3k(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8C, _hoisted_5$3O) } var officeBuilding = /* @__PURE__ */ _export_sfc$2(_sfc_main$aZ, [ ['render', _sfc_render$3k], ]) const _sfc_main$aY = defineComponent({ name: 'Open', }) const _hoisted_1$8B = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7b = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M329.956 257.138a254.862 254.862 0 0 0 0 509.724h364.088a254.862 254.862 0 0 0 0-509.724H329.956zm0-72.818h364.088a327.68 327.68 0 1 1 0 655.36H329.956a327.68 327.68 0 1 1 0-655.36z', }, null, -1 ) const _hoisted_3$6r = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M694.044 621.227a109.227 109.227 0 1 0 0-218.454 109.227 109.227 0 0 0 0 218.454zm0 72.817a182.044 182.044 0 1 1 0-364.088 182.044 182.044 0 0 1 0 364.088z', }, null, -1 ) const _hoisted_4$4A = [_hoisted_2$7b, _hoisted_3$6r] function _sfc_render$3j(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8B, _hoisted_4$4A) } var open$1 = /* @__PURE__ */ _export_sfc$2(_sfc_main$aY, [ ['render', _sfc_render$3j], ]) const _sfc_main$aX = defineComponent({ name: 'Operation', }) const _hoisted_1$8A = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$7a = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M389.44 768a96.064 96.064 0 0 1 181.12 0H896v64H570.56a96.064 96.064 0 0 1-181.12 0H128v-64h261.44zm192-288a96.064 96.064 0 0 1 181.12 0H896v64H762.56a96.064 96.064 0 0 1-181.12 0H128v-64h453.44zm-320-288a96.064 96.064 0 0 1 181.12 0H896v64H442.56a96.064 96.064 0 0 1-181.12 0H128v-64h133.44z', }, null, -1 ) const _hoisted_3$6q = [_hoisted_2$7a] function _sfc_render$3i(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8A, _hoisted_3$6q) } var operation = /* @__PURE__ */ _export_sfc$2(_sfc_main$aX, [ ['render', _sfc_render$3i], ]) const _sfc_main$aW = defineComponent({ name: 'Opportunity', }) const _hoisted_1$8z = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$79 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M384 960v-64h192.064v64H384zm448-544a350.656 350.656 0 0 1-128.32 271.424C665.344 719.04 640 763.776 640 813.504V832H320v-14.336c0-48-19.392-95.36-57.216-124.992a351.552 351.552 0 0 1-128.448-344.256c25.344-136.448 133.888-248.128 269.76-276.48A352.384 352.384 0 0 1 832 416zm-544 32c0-132.288 75.904-224 192-224v-64c-154.432 0-256 122.752-256 288h64z', }, null, -1 ) const _hoisted_3$6p = [_hoisted_2$79] function _sfc_render$3h(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8z, _hoisted_3$6p) } var opportunity = /* @__PURE__ */ _export_sfc$2(_sfc_main$aW, [ ['render', _sfc_render$3h], ]) const _sfc_main$aV = defineComponent({ name: 'Orange', }) const _hoisted_1$8y = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$78 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M544 894.72a382.336 382.336 0 0 0 215.936-89.472L577.024 622.272c-10.24 6.016-21.248 10.688-33.024 13.696v258.688zm261.248-134.784A382.336 382.336 0 0 0 894.656 544H635.968c-3.008 11.776-7.68 22.848-13.696 33.024l182.976 182.912zM894.656 480a382.336 382.336 0 0 0-89.408-215.936L622.272 446.976c6.016 10.24 10.688 21.248 13.696 33.024h258.688zm-134.72-261.248A382.336 382.336 0 0 0 544 129.344v258.688c11.776 3.008 22.848 7.68 33.024 13.696l182.912-182.976zM480 129.344a382.336 382.336 0 0 0-215.936 89.408l182.912 182.976c10.24-6.016 21.248-10.688 33.024-13.696V129.344zm-261.248 134.72A382.336 382.336 0 0 0 129.344 480h258.688c3.008-11.776 7.68-22.848 13.696-33.024L218.752 264.064zM129.344 544a382.336 382.336 0 0 0 89.408 215.936l182.976-182.912A127.232 127.232 0 0 1 388.032 544H129.344zm134.72 261.248A382.336 382.336 0 0 0 480 894.656V635.968a127.232 127.232 0 0 1-33.024-13.696L264.064 805.248zM512 960a448 448 0 1 1 0-896 448 448 0 0 1 0 896zm0-384a64 64 0 1 0 0-128 64 64 0 0 0 0 128z', }, null, -1 ) const _hoisted_3$6o = [_hoisted_2$78] function _sfc_render$3g(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8y, _hoisted_3$6o) } var orange = /* @__PURE__ */ _export_sfc$2(_sfc_main$aV, [ ['render', _sfc_render$3g], ]) const _sfc_main$aU = defineComponent({ name: 'Paperclip', }) const _hoisted_1$8x = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$77 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M602.496 240.448A192 192 0 1 1 874.048 512l-316.8 316.8A256 256 0 0 1 195.2 466.752L602.496 59.456l45.248 45.248L240.448 512A192 192 0 0 0 512 783.552l316.8-316.8a128 128 0 1 0-181.056-181.056L353.6 579.904a32 32 0 1 0 45.248 45.248l294.144-294.144 45.312 45.248L444.096 670.4a96 96 0 1 1-135.744-135.744l294.144-294.208z', }, null, -1 ) const _hoisted_3$6n = [_hoisted_2$77] function _sfc_render$3f(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8x, _hoisted_3$6n) } var paperclip = /* @__PURE__ */ _export_sfc$2(_sfc_main$aU, [ ['render', _sfc_render$3f], ]) const _sfc_main$aT = defineComponent({ name: 'PartlyCloudy', }) const _hoisted_1$8w = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$76 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M598.4 895.872H328.192a256 256 0 0 1-34.496-510.528A352 352 0 1 1 598.4 895.872zm-271.36-64h272.256a288 288 0 1 0-248.512-417.664L335.04 445.44l-34.816 3.584a192 192 0 0 0 26.88 382.848z', }, null, -1 ) const _hoisted_3$6m = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M139.84 501.888a256 256 0 1 1 417.856-277.12c-17.728 2.176-38.208 8.448-61.504 18.816A192 192 0 1 0 189.12 460.48a6003.84 6003.84 0 0 0-49.28 41.408z', }, null, -1 ) const _hoisted_4$4z = [_hoisted_2$76, _hoisted_3$6m] function _sfc_render$3e(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8w, _hoisted_4$4z) } var partlyCloudy = /* @__PURE__ */ _export_sfc$2(_sfc_main$aT, [ ['render', _sfc_render$3e], ]) const _sfc_main$aS = defineComponent({ name: 'Pear', }) const _hoisted_1$8v = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$75 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M542.336 258.816a443.255 443.255 0 0 0-9.024 25.088 32 32 0 1 1-60.8-20.032l1.088-3.328a162.688 162.688 0 0 0-122.048 131.392l-17.088 102.72-20.736 15.36C256.192 552.704 224 610.88 224 672c0 120.576 126.4 224 288 224s288-103.424 288-224c0-61.12-32.192-119.296-89.728-161.92l-20.736-15.424-17.088-102.72a162.688 162.688 0 0 0-130.112-133.12zm-40.128-66.56c7.936-15.552 16.576-30.08 25.92-43.776 23.296-33.92 49.408-59.776 78.528-77.12a32 32 0 1 1 32.704 55.04c-20.544 12.224-40.064 31.552-58.432 58.304a316.608 316.608 0 0 0-9.792 15.104 226.688 226.688 0 0 1 164.48 181.568l12.8 77.248C819.456 511.36 864 587.392 864 672c0 159.04-157.568 288-352 288S160 831.04 160 672c0-84.608 44.608-160.64 115.584-213.376l12.8-77.248a226.624 226.624 0 0 1 213.76-189.184z', }, null, -1 ) const _hoisted_3$6l = [_hoisted_2$75] function _sfc_render$3d(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8v, _hoisted_3$6l) } var pear = /* @__PURE__ */ _export_sfc$2(_sfc_main$aS, [ ['render', _sfc_render$3d], ]) const _sfc_main$aR = defineComponent({ name: 'PhoneFilled', }) const _hoisted_1$8u = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$74 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M199.232 125.568 90.624 379.008a32 32 0 0 0 6.784 35.2l512.384 512.384a32 32 0 0 0 35.2 6.784l253.44-108.608a32 32 0 0 0 10.048-52.032L769.6 633.92a32 32 0 0 0-36.928-5.952l-130.176 65.088-271.488-271.552 65.024-130.176a32 32 0 0 0-5.952-36.928L251.2 115.52a32 32 0 0 0-51.968 10.048z', }, null, -1 ) const _hoisted_3$6k = [_hoisted_2$74] function _sfc_render$3c(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8u, _hoisted_3$6k) } var phoneFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$aR, [ ['render', _sfc_render$3c], ]) const _sfc_main$aQ = defineComponent({ name: 'Phone', }) const _hoisted_1$8t = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$73 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M79.36 432.256 591.744 944.64a32 32 0 0 0 35.2 6.784l253.44-108.544a32 32 0 0 0 9.984-52.032l-153.856-153.92a32 32 0 0 0-36.928-6.016l-69.888 34.944L358.08 394.24l35.008-69.888a32 32 0 0 0-5.952-36.928L233.152 133.568a32 32 0 0 0-52.032 10.048L72.512 397.056a32 32 0 0 0 6.784 35.2zm60.48-29.952 81.536-190.08L325.568 316.48l-24.64 49.216-20.608 41.216 32.576 32.64 271.552 271.552 32.64 32.64 41.216-20.672 49.28-24.576 104.192 104.128-190.08 81.472L139.84 402.304zM512 320v-64a256 256 0 0 1 256 256h-64a192 192 0 0 0-192-192zm0-192V64a448 448 0 0 1 448 448h-64a384 384 0 0 0-384-384z', }, null, -1 ) const _hoisted_3$6j = [_hoisted_2$73] function _sfc_render$3b(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8t, _hoisted_3$6j) } var phone = /* @__PURE__ */ _export_sfc$2(_sfc_main$aQ, [ ['render', _sfc_render$3b], ]) const _sfc_main$aP = defineComponent({ name: 'PictureFilled', }) const _hoisted_1$8s = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$72 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M96 896a32 32 0 0 1-32-32V160a32 32 0 0 1 32-32h832a32 32 0 0 1 32 32v704a32 32 0 0 1-32 32H96zm315.52-228.48-68.928-68.928a32 32 0 0 0-45.248 0L128 768.064h778.688l-242.112-290.56a32 32 0 0 0-49.216 0L458.752 665.408a32 32 0 0 1-47.232 2.112zM256 384a96 96 0 1 0 192.064-.064A96 96 0 0 0 256 384z', }, null, -1 ) const _hoisted_3$6i = [_hoisted_2$72] function _sfc_render$3a(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8s, _hoisted_3$6i) } var pictureFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$aP, [ ['render', _sfc_render$3a], ]) const _sfc_main$aO = defineComponent({ name: 'PictureRounded', }) const _hoisted_1$8r = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$71 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 128a384 384 0 1 0 0 768 384 384 0 0 0 0-768zm0-64a448 448 0 1 1 0 896 448 448 0 0 1 0-896z', }, null, -1 ) const _hoisted_3$6h = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M640 288q64 0 64 64t-64 64q-64 0-64-64t64-64zM214.656 790.656l-45.312-45.312 185.664-185.6a96 96 0 0 1 123.712-10.24l138.24 98.688a32 32 0 0 0 39.872-2.176L906.688 422.4l42.624 47.744L699.52 693.696a96 96 0 0 1-119.808 6.592l-138.24-98.752a32 32 0 0 0-41.152 3.456l-185.664 185.6z', }, null, -1 ) const _hoisted_4$4y = [_hoisted_2$71, _hoisted_3$6h] function _sfc_render$39(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8r, _hoisted_4$4y) } var pictureRounded = /* @__PURE__ */ _export_sfc$2(_sfc_main$aO, [ ['render', _sfc_render$39], ]) const _sfc_main$aN = defineComponent({ name: 'Picture', }) const _hoisted_1$8q = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$70 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M160 160v704h704V160H160zm-32-64h768a32 32 0 0 1 32 32v768a32 32 0 0 1-32 32H128a32 32 0 0 1-32-32V128a32 32 0 0 1 32-32z', }, null, -1 ) const _hoisted_3$6g = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M384 288q64 0 64 64t-64 64q-64 0-64-64t64-64zM185.408 876.992l-50.816-38.912L350.72 556.032a96 96 0 0 1 134.592-17.856l1.856 1.472 122.88 99.136a32 32 0 0 0 44.992-4.864l216-269.888 49.92 39.936-215.808 269.824-.256.32a96 96 0 0 1-135.04 14.464l-122.88-99.072-.64-.512a32 32 0 0 0-44.8 5.952L185.408 876.992z', }, null, -1 ) const _hoisted_4$4x = [_hoisted_2$70, _hoisted_3$6g] function _sfc_render$38(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8q, _hoisted_4$4x) } var picture = /* @__PURE__ */ _export_sfc$2(_sfc_main$aN, [ ['render', _sfc_render$38], ]) const _sfc_main$aM = defineComponent({ name: 'PieChart', }) const _hoisted_1$8p = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6$ = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M448 68.48v64.832A384.128 384.128 0 0 0 512 896a384.128 384.128 0 0 0 378.688-320h64.768A448.128 448.128 0 0 1 64 512 448.128 448.128 0 0 1 448 68.48z', }, null, -1 ) const _hoisted_3$6f = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M576 97.28V448h350.72A384.064 384.064 0 0 0 576 97.28zM512 64V33.152A448 448 0 0 1 990.848 512H512V64z', }, null, -1 ) const _hoisted_4$4w = [_hoisted_2$6$, _hoisted_3$6f] function _sfc_render$37(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8p, _hoisted_4$4w) } var pieChart = /* @__PURE__ */ _export_sfc$2(_sfc_main$aM, [ ['render', _sfc_render$37], ]) const _sfc_main$aL = defineComponent({ name: 'Place', }) const _hoisted_1$8o = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6_ = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 512a192 192 0 1 0 0-384 192 192 0 0 0 0 384zm0 64a256 256 0 1 1 0-512 256 256 0 0 1 0 512z', }, null, -1 ) const _hoisted_3$6e = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 512a32 32 0 0 1 32 32v256a32 32 0 1 1-64 0V544a32 32 0 0 1 32-32z', }, null, -1 ) const _hoisted_4$4v = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M384 649.088v64.96C269.76 732.352 192 771.904 192 800c0 37.696 139.904 96 320 96s320-58.304 320-96c0-28.16-77.76-67.648-192-85.952v-64.96C789.12 671.04 896 730.368 896 800c0 88.32-171.904 160-384 160s-384-71.68-384-160c0-69.696 106.88-128.96 256-150.912z', }, null, -1 ) const _hoisted_5$3N = [_hoisted_2$6_, _hoisted_3$6e, _hoisted_4$4v] function _sfc_render$36(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8o, _hoisted_5$3N) } var place$1 = /* @__PURE__ */ _export_sfc$2(_sfc_main$aL, [ ['render', _sfc_render$36], ]) const _sfc_main$aK = defineComponent({ name: 'Platform', }) const _hoisted_1$8n = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6Z = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M448 832v-64h128v64h192v64H256v-64h192zM128 704V128h768v576H128z', }, null, -1 ) const _hoisted_3$6d = [_hoisted_2$6Z] function _sfc_render$35(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8n, _hoisted_3$6d) } var platform$1 = /* @__PURE__ */ _export_sfc$2(_sfc_main$aK, [ ['render', _sfc_render$35], ]) const _sfc_main$aJ = defineComponent({ name: 'Plus', }) const _hoisted_1$8m = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6Y = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M480 480V128a32 32 0 0 1 64 0v352h352a32 32 0 1 1 0 64H544v352a32 32 0 1 1-64 0V544H128a32 32 0 0 1 0-64h352z', }, null, -1 ) const _hoisted_3$6c = [_hoisted_2$6Y] function _sfc_render$34(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8m, _hoisted_3$6c) } var plus = /* @__PURE__ */ _export_sfc$2(_sfc_main$aJ, [ ['render', _sfc_render$34], ]) const _sfc_main$aI = defineComponent({ name: 'Pointer', }) const _hoisted_1$8l = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6X = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M511.552 128c-35.584 0-64.384 28.8-64.384 64.448v516.48L274.048 570.88a94.272 94.272 0 0 0-112.896-3.456 44.416 44.416 0 0 0-8.96 62.208L332.8 870.4A64 64 0 0 0 384 896h512V575.232a64 64 0 0 0-45.632-61.312l-205.952-61.76A96 96 0 0 1 576 360.192V192.448C576 156.8 547.2 128 511.552 128zM359.04 556.8l24.128 19.2V192.448a128.448 128.448 0 1 1 256.832 0v167.744a32 32 0 0 0 22.784 30.656l206.016 61.76A128 128 0 0 1 960 575.232V896a64 64 0 0 1-64 64H384a128 128 0 0 1-102.4-51.2L101.056 668.032A108.416 108.416 0 0 1 128 512.512a158.272 158.272 0 0 1 185.984 8.32L359.04 556.8z', }, null, -1 ) const _hoisted_3$6b = [_hoisted_2$6X] function _sfc_render$33(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8l, _hoisted_3$6b) } var pointer = /* @__PURE__ */ _export_sfc$2(_sfc_main$aI, [ ['render', _sfc_render$33], ]) const _sfc_main$aH = defineComponent({ name: 'Position', }) const _hoisted_1$8k = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6W = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm249.6 417.088 319.744 43.072 39.168 310.272L845.12 178.88 249.6 417.088zm-129.024 47.168a32 32 0 0 1-7.68-61.44l777.792-311.04a32 32 0 0 1 41.6 41.6l-310.336 775.68a32 32 0 0 1-61.44-7.808L512 516.992l-391.424-52.736z', }, null, -1 ) const _hoisted_3$6a = [_hoisted_2$6W] function _sfc_render$32(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8k, _hoisted_3$6a) } var position$2 = /* @__PURE__ */ _export_sfc$2(_sfc_main$aH, [ ['render', _sfc_render$32], ]) const _sfc_main$aG = defineComponent({ name: 'Postcard', }) const _hoisted_1$8j = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6V = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M160 224a32 32 0 0 0-32 32v512a32 32 0 0 0 32 32h704a32 32 0 0 0 32-32V256a32 32 0 0 0-32-32H160zm0-64h704a96 96 0 0 1 96 96v512a96 96 0 0 1-96 96H160a96 96 0 0 1-96-96V256a96 96 0 0 1 96-96z', }, null, -1 ) const _hoisted_3$69 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M704 320a64 64 0 1 1 0 128 64 64 0 0 1 0-128zM288 448h256q32 0 32 32t-32 32H288q-32 0-32-32t32-32zm0 128h256q32 0 32 32t-32 32H288q-32 0-32-32t32-32z', }, null, -1 ) const _hoisted_4$4u = [_hoisted_2$6V, _hoisted_3$69] function _sfc_render$31(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8j, _hoisted_4$4u) } var postcard = /* @__PURE__ */ _export_sfc$2(_sfc_main$aG, [ ['render', _sfc_render$31], ]) const _sfc_main$aF = defineComponent({ name: 'Pouring', }) const _hoisted_1$8i = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6U = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm739.328 291.328-35.2-6.592-12.8-33.408a192.064 192.064 0 0 0-365.952 23.232l-9.92 40.896-41.472 7.04a176.32 176.32 0 0 0-146.24 173.568c0 97.28 78.72 175.936 175.808 175.936h400a192 192 0 0 0 35.776-380.672zM959.552 480a256 256 0 0 1-256 256h-400A239.808 239.808 0 0 1 63.744 496.192a240.32 240.32 0 0 1 199.488-236.8 256.128 256.128 0 0 1 487.872-30.976A256.064 256.064 0 0 1 959.552 480zM224 800a32 32 0 0 1 32 32v96a32 32 0 1 1-64 0v-96a32 32 0 0 1 32-32zm192 0a32 32 0 0 1 32 32v96a32 32 0 1 1-64 0v-96a32 32 0 0 1 32-32zm192 0a32 32 0 0 1 32 32v96a32 32 0 1 1-64 0v-96a32 32 0 0 1 32-32zm192 0a32 32 0 0 1 32 32v96a32 32 0 1 1-64 0v-96a32 32 0 0 1 32-32z', }, null, -1 ) const _hoisted_3$68 = [_hoisted_2$6U] function _sfc_render$30(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8i, _hoisted_3$68) } var pouring = /* @__PURE__ */ _export_sfc$2(_sfc_main$aF, [ ['render', _sfc_render$30], ]) const _sfc_main$aE = defineComponent({ name: 'Present', }) const _hoisted_1$8h = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6T = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M480 896V640H192v-64h288V320H192v576h288zm64 0h288V320H544v256h288v64H544v256zM128 256h768v672a32 32 0 0 1-32 32H160a32 32 0 0 1-32-32V256z', }, null, -1 ) const _hoisted_3$67 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M96 256h832q32 0 32 32t-32 32H96q-32 0-32-32t32-32z', }, null, -1 ) const _hoisted_4$4t = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M416 256a64 64 0 1 0 0-128 64 64 0 0 0 0 128zm0 64a128 128 0 1 1 0-256 128 128 0 0 1 0 256z', }, null, -1 ) const _hoisted_5$3M = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M608 256a64 64 0 1 0 0-128 64 64 0 0 0 0 128zm0 64a128 128 0 1 1 0-256 128 128 0 0 1 0 256z', }, null, -1 ) const _hoisted_6$3h = [ _hoisted_2$6T, _hoisted_3$67, _hoisted_4$4t, _hoisted_5$3M, ] function _sfc_render$2$(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8h, _hoisted_6$3h) } var present = /* @__PURE__ */ _export_sfc$2(_sfc_main$aE, [ ['render', _sfc_render$2$], ]) const _sfc_main$aD = defineComponent({ name: 'PriceTag', }) const _hoisted_1$8g = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6S = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M224 318.336V896h576V318.336L552.512 115.84a64 64 0 0 0-81.024 0L224 318.336zM593.024 66.304l259.2 212.096A32 32 0 0 1 864 303.168V928a32 32 0 0 1-32 32H192a32 32 0 0 1-32-32V303.168a32 32 0 0 1 11.712-24.768l259.2-212.096a128 128 0 0 1 162.112 0z', }, null, -1 ) const _hoisted_3$66 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 448a64 64 0 1 0 0-128 64 64 0 0 0 0 128zm0 64a128 128 0 1 1 0-256 128 128 0 0 1 0 256z', }, null, -1 ) const _hoisted_4$4s = [_hoisted_2$6S, _hoisted_3$66] function _sfc_render$2_(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8g, _hoisted_4$4s) } var priceTag = /* @__PURE__ */ _export_sfc$2(_sfc_main$aD, [ ['render', _sfc_render$2_], ]) const _sfc_main$aC = defineComponent({ name: 'Printer', }) const _hoisted_1$8f = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6R = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M256 768H105.024c-14.272 0-19.456-1.472-24.64-4.288a29.056 29.056 0 0 1-12.16-12.096C65.536 746.432 64 741.248 64 727.04V379.072c0-42.816 4.48-58.304 12.8-73.984 8.384-15.616 20.672-27.904 36.288-36.288 15.68-8.32 31.168-12.8 73.984-12.8H256V64h512v192h68.928c42.816 0 58.304 4.48 73.984 12.8 15.616 8.384 27.904 20.672 36.288 36.288 8.32 15.68 12.8 31.168 12.8 73.984v347.904c0 14.272-1.472 19.456-4.288 24.64a29.056 29.056 0 0 1-12.096 12.16c-5.184 2.752-10.368 4.224-24.64 4.224H768v192H256V768zm64-192v320h384V576H320zm-64 128V512h512v192h128V379.072c0-29.376-1.408-36.48-5.248-43.776a23.296 23.296 0 0 0-10.048-10.048c-7.232-3.84-14.4-5.248-43.776-5.248H187.072c-29.376 0-36.48 1.408-43.776 5.248a23.296 23.296 0 0 0-10.048 10.048c-3.84 7.232-5.248 14.4-5.248 43.776V704h128zm64-448h384V128H320v128zm-64 128h64v64h-64v-64zm128 0h64v64h-64v-64z', }, null, -1 ) const _hoisted_3$65 = [_hoisted_2$6R] function _sfc_render$2Z(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8f, _hoisted_3$65) } var printer = /* @__PURE__ */ _export_sfc$2(_sfc_main$aC, [ ['render', _sfc_render$2Z], ]) const _sfc_main$aB = defineComponent({ name: 'Promotion', }) const _hoisted_1$8e = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6Q = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm64 448 832-320-128 704-446.08-243.328L832 192 242.816 545.472 64 448zm256 512V657.024L512 768 320 960z', }, null, -1 ) const _hoisted_3$64 = [_hoisted_2$6Q] function _sfc_render$2Y(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8e, _hoisted_3$64) } var promotion = /* @__PURE__ */ _export_sfc$2(_sfc_main$aB, [ ['render', _sfc_render$2Y], ]) const _sfc_main$aA = defineComponent({ name: 'QuestionFilled', }) const _hoisted_1$8d = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6P = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896zm23.744 191.488c-52.096 0-92.928 14.784-123.2 44.352-30.976 29.568-45.76 70.4-45.76 122.496h80.256c0-29.568 5.632-52.8 17.6-68.992 13.376-19.712 35.2-28.864 66.176-28.864 23.936 0 42.944 6.336 56.32 19.712 12.672 13.376 19.712 31.68 19.712 54.912 0 17.6-6.336 34.496-19.008 49.984l-8.448 9.856c-45.76 40.832-73.216 70.4-82.368 89.408-9.856 19.008-14.08 42.24-14.08 68.992v9.856h80.96v-9.856c0-16.896 3.52-31.68 10.56-45.76 6.336-12.672 15.488-24.64 28.16-35.2 33.792-29.568 54.208-48.576 60.544-55.616 16.896-22.528 26.048-51.392 26.048-86.592 0-42.944-14.08-76.736-42.24-101.376-28.16-25.344-65.472-37.312-111.232-37.312zm-12.672 406.208a54.272 54.272 0 0 0-38.72 14.784 49.408 49.408 0 0 0-15.488 38.016c0 15.488 4.928 28.16 15.488 38.016A54.848 54.848 0 0 0 523.072 768c15.488 0 28.16-4.928 38.72-14.784a51.52 51.52 0 0 0 16.192-38.72 51.968 51.968 0 0 0-15.488-38.016 55.936 55.936 0 0 0-39.424-14.784z', }, null, -1 ) const _hoisted_3$63 = [_hoisted_2$6P] function _sfc_render$2X(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8d, _hoisted_3$63) } var questionFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$aA, [ ['render', _sfc_render$2X], ]) const _sfc_main$az = defineComponent({ name: 'Rank', }) const _hoisted_1$8c = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6O = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm186.496 544 41.408 41.344a32 32 0 1 1-45.248 45.312l-96-96a32 32 0 0 1 0-45.312l96-96a32 32 0 1 1 45.248 45.312L186.496 480h290.816V186.432l-41.472 41.472a32 32 0 1 1-45.248-45.184l96-96.128a32 32 0 0 1 45.312 0l96 96.064a32 32 0 0 1-45.248 45.184l-41.344-41.28V480H832l-41.344-41.344a32 32 0 0 1 45.248-45.312l96 96a32 32 0 0 1 0 45.312l-96 96a32 32 0 0 1-45.248-45.312L832 544H541.312v293.44l41.344-41.28a32 32 0 1 1 45.248 45.248l-96 96a32 32 0 0 1-45.312 0l-96-96a32 32 0 1 1 45.312-45.248l41.408 41.408V544H186.496z', }, null, -1 ) const _hoisted_3$62 = [_hoisted_2$6O] function _sfc_render$2W(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8c, _hoisted_3$62) } var rank = /* @__PURE__ */ _export_sfc$2(_sfc_main$az, [ ['render', _sfc_render$2W], ]) const _sfc_main$ay = defineComponent({ name: 'ReadingLamp', }) const _hoisted_1$8b = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6N = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M352 896h320q32 0 32 32t-32 32H352q-32 0-32-32t32-32zm-44.672-768-99.52 448h608.384l-99.52-448H307.328zm-25.6-64h460.608a32 32 0 0 1 31.232 25.088l113.792 512A32 32 0 0 1 856.128 640H167.872a32 32 0 0 1-31.232-38.912l113.792-512A32 32 0 0 1 281.664 64z', }, null, -1 ) const _hoisted_3$61 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M672 576q32 0 32 32v128q0 32-32 32t-32-32V608q0-32 32-32zm-192-.064h64V960h-64z', }, null, -1 ) const _hoisted_4$4r = [_hoisted_2$6N, _hoisted_3$61] function _sfc_render$2V(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8b, _hoisted_4$4r) } var readingLamp = /* @__PURE__ */ _export_sfc$2(_sfc_main$ay, [ ['render', _sfc_render$2V], ]) const _sfc_main$ax = defineComponent({ name: 'Reading', }) const _hoisted_1$8a = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6M = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm512 863.36 384-54.848v-638.72L525.568 222.72a96 96 0 0 1-27.136 0L128 169.792v638.72l384 54.848zM137.024 106.432l370.432 52.928a32 32 0 0 0 9.088 0l370.432-52.928A64 64 0 0 1 960 169.792v638.72a64 64 0 0 1-54.976 63.36l-388.48 55.488a32 32 0 0 1-9.088 0l-388.48-55.488A64 64 0 0 1 64 808.512v-638.72a64 64 0 0 1 73.024-63.36z', }, null, -1 ) const _hoisted_3$60 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M480 192h64v704h-64z', }, null, -1 ) const _hoisted_4$4q = [_hoisted_2$6M, _hoisted_3$60] function _sfc_render$2U(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$8a, _hoisted_4$4q) } var reading = /* @__PURE__ */ _export_sfc$2(_sfc_main$ax, [ ['render', _sfc_render$2U], ]) const _sfc_main$aw = defineComponent({ name: 'RefreshLeft', }) const _hoisted_1$89 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6L = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M289.088 296.704h92.992a32 32 0 0 1 0 64H232.96a32 32 0 0 1-32-32V179.712a32 32 0 0 1 64 0v50.56a384 384 0 0 1 643.84 282.88 384 384 0 0 1-383.936 384 384 384 0 0 1-384-384h64a320 320 0 1 0 640 0 320 320 0 0 0-555.712-216.448z', }, null, -1 ) const _hoisted_3$5$ = [_hoisted_2$6L] function _sfc_render$2T(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$89, _hoisted_3$5$) } var refreshLeft = /* @__PURE__ */ _export_sfc$2(_sfc_main$aw, [ ['render', _sfc_render$2T], ]) const _sfc_main$av = defineComponent({ name: 'RefreshRight', }) const _hoisted_1$88 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6K = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M784.512 230.272v-50.56a32 32 0 1 1 64 0v149.056a32 32 0 0 1-32 32H667.52a32 32 0 1 1 0-64h92.992A320 320 0 1 0 524.8 833.152a320 320 0 0 0 320-320h64a384 384 0 0 1-384 384 384 384 0 0 1-384-384 384 384 0 0 1 643.712-282.88z', }, null, -1 ) const _hoisted_3$5_ = [_hoisted_2$6K] function _sfc_render$2S(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$88, _hoisted_3$5_) } var refreshRight = /* @__PURE__ */ _export_sfc$2(_sfc_main$av, [ ['render', _sfc_render$2S], ]) const _sfc_main$au = defineComponent({ name: 'Refresh', }) const _hoisted_1$87 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6J = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M771.776 794.88A384 384 0 0 1 128 512h64a320 320 0 0 0 555.712 216.448H654.72a32 32 0 1 1 0-64h149.056a32 32 0 0 1 32 32v148.928a32 32 0 1 1-64 0v-50.56zM276.288 295.616h92.992a32 32 0 0 1 0 64H220.16a32 32 0 0 1-32-32V178.56a32 32 0 0 1 64 0v50.56A384 384 0 0 1 896.128 512h-64a320 320 0 0 0-555.776-216.384z', }, null, -1 ) const _hoisted_3$5Z = [_hoisted_2$6J] function _sfc_render$2R(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$87, _hoisted_3$5Z) } var refresh = /* @__PURE__ */ _export_sfc$2(_sfc_main$au, [ ['render', _sfc_render$2R], ]) const _sfc_main$at = defineComponent({ name: 'Refrigerator', }) const _hoisted_1$86 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6I = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M256 448h512V160a32 32 0 0 0-32-32H288a32 32 0 0 0-32 32v288zm0 64v352a32 32 0 0 0 32 32h448a32 32 0 0 0 32-32V512H256zm32-448h448a96 96 0 0 1 96 96v704a96 96 0 0 1-96 96H288a96 96 0 0 1-96-96V160a96 96 0 0 1 96-96zm32 224h64v96h-64v-96zm0 288h64v96h-64v-96z', }, null, -1 ) const _hoisted_3$5Y = [_hoisted_2$6I] function _sfc_render$2Q(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$86, _hoisted_3$5Y) } var refrigerator = /* @__PURE__ */ _export_sfc$2(_sfc_main$at, [ ['render', _sfc_render$2Q], ]) const _sfc_main$as = defineComponent({ name: 'RemoveFilled', }) const _hoisted_1$85 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6H = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896zM288 512a38.4 38.4 0 0 0 38.4 38.4h371.2a38.4 38.4 0 0 0 0-76.8H326.4A38.4 38.4 0 0 0 288 512z', }, null, -1 ) const _hoisted_3$5X = [_hoisted_2$6H] function _sfc_render$2P(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$85, _hoisted_3$5X) } var removeFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$as, [ ['render', _sfc_render$2P], ]) const _sfc_main$ar = defineComponent({ name: 'Remove', }) const _hoisted_1$84 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6G = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M352 480h320a32 32 0 1 1 0 64H352a32 32 0 0 1 0-64z', }, null, -1 ) const _hoisted_3$5W = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 896a384 384 0 1 0 0-768 384 384 0 0 0 0 768zm0 64a448 448 0 1 1 0-896 448 448 0 0 1 0 896z', }, null, -1 ) const _hoisted_4$4p = [_hoisted_2$6G, _hoisted_3$5W] function _sfc_render$2O(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$84, _hoisted_4$4p) } var remove$3 = /* @__PURE__ */ _export_sfc$2(_sfc_main$ar, [ ['render', _sfc_render$2O], ]) const _sfc_main$aq = defineComponent({ name: 'Right', }) const _hoisted_1$83 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6F = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M754.752 480H160a32 32 0 1 0 0 64h594.752L521.344 777.344a32 32 0 0 0 45.312 45.312l288-288a32 32 0 0 0 0-45.312l-288-288a32 32 0 1 0-45.312 45.312L754.752 480z', }, null, -1 ) const _hoisted_3$5V = [_hoisted_2$6F] function _sfc_render$2N(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$83, _hoisted_3$5V) } var right$1 = /* @__PURE__ */ _export_sfc$2(_sfc_main$aq, [ ['render', _sfc_render$2N], ]) const _sfc_main$ap = defineComponent({ name: 'ScaleToOriginal', }) const _hoisted_1$82 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6E = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M813.176 180.706a60.235 60.235 0 0 1 60.236 60.235v481.883a60.235 60.235 0 0 1-60.236 60.235H210.824a60.235 60.235 0 0 1-60.236-60.235V240.94a60.235 60.235 0 0 1 60.236-60.235h602.352zm0-60.235H210.824A120.47 120.47 0 0 0 90.353 240.94v481.883a120.47 120.47 0 0 0 120.47 120.47h602.353a120.47 120.47 0 0 0 120.471-120.47V240.94a120.47 120.47 0 0 0-120.47-120.47zm-120.47 180.705a30.118 30.118 0 0 0-30.118 30.118v301.177a30.118 30.118 0 0 0 60.236 0V331.294a30.118 30.118 0 0 0-30.118-30.118zm-361.412 0a30.118 30.118 0 0 0-30.118 30.118v301.177a30.118 30.118 0 1 0 60.236 0V331.294a30.118 30.118 0 0 0-30.118-30.118zM512 361.412a30.118 30.118 0 0 0-30.118 30.117v30.118a30.118 30.118 0 0 0 60.236 0V391.53A30.118 30.118 0 0 0 512 361.412zM512 512a30.118 30.118 0 0 0-30.118 30.118v30.117a30.118 30.118 0 0 0 60.236 0v-30.117A30.118 30.118 0 0 0 512 512z', }, null, -1 ) const _hoisted_3$5U = [_hoisted_2$6E] function _sfc_render$2M(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$82, _hoisted_3$5U) } var scaleToOriginal = /* @__PURE__ */ _export_sfc$2(_sfc_main$ap, [ ['render', _sfc_render$2M], ]) const _sfc_main$ao = defineComponent({ name: 'School', }) const _hoisted_1$81 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6D = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M224 128v704h576V128H224zm-32-64h640a32 32 0 0 1 32 32v768a32 32 0 0 1-32 32H192a32 32 0 0 1-32-32V96a32 32 0 0 1 32-32z', }, null, -1 ) const _hoisted_3$5T = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M64 832h896v64H64zm256-640h128v96H320z', }, null, -1 ) const _hoisted_4$4o = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M384 832h256v-64a128 128 0 1 0-256 0v64zm128-256a192 192 0 0 1 192 192v128H320V768a192 192 0 0 1 192-192zM320 384h128v96H320zm256-192h128v96H576zm0 192h128v96H576z', }, null, -1 ) const _hoisted_5$3L = [_hoisted_2$6D, _hoisted_3$5T, _hoisted_4$4o] function _sfc_render$2L(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$81, _hoisted_5$3L) } var school = /* @__PURE__ */ _export_sfc$2(_sfc_main$ao, [ ['render', _sfc_render$2L], ]) const _sfc_main$an = defineComponent({ name: 'Scissor', }) const _hoisted_1$80 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6C = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm512.064 578.368-106.88 152.768a160 160 0 1 1-23.36-78.208L472.96 522.56 196.864 128.256a32 32 0 1 1 52.48-36.736l393.024 561.344a160 160 0 1 1-23.36 78.208l-106.88-152.704zm54.4-189.248 208.384-297.6a32 32 0 0 1 52.48 36.736l-221.76 316.672-39.04-55.808zm-376.32 425.856a96 96 0 1 0 110.144-157.248 96 96 0 0 0-110.08 157.248zm643.84 0a96 96 0 1 0-110.08-157.248 96 96 0 0 0 110.08 157.248z', }, null, -1 ) const _hoisted_3$5S = [_hoisted_2$6C] function _sfc_render$2K(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$80, _hoisted_3$5S) } var scissor = /* @__PURE__ */ _export_sfc$2(_sfc_main$an, [ ['render', _sfc_render$2K], ]) const _sfc_main$am = defineComponent({ name: 'Search', }) const _hoisted_1$7$ = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6B = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm795.904 750.72 124.992 124.928a32 32 0 0 1-45.248 45.248L750.656 795.904a416 416 0 1 1 45.248-45.248zM480 832a352 352 0 1 0 0-704 352 352 0 0 0 0 704z', }, null, -1 ) const _hoisted_3$5R = [_hoisted_2$6B] function _sfc_render$2J(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7$, _hoisted_3$5R) } var search = /* @__PURE__ */ _export_sfc$2(_sfc_main$am, [ ['render', _sfc_render$2J], ]) const _sfc_main$al = defineComponent({ name: 'Select', }) const _hoisted_1$7_ = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6A = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M77.248 415.04a64 64 0 0 1 90.496 0l226.304 226.304L846.528 188.8a64 64 0 1 1 90.56 90.496l-543.04 543.04-316.8-316.8a64 64 0 0 1 0-90.496z', }, null, -1 ) const _hoisted_3$5Q = [_hoisted_2$6A] function _sfc_render$2I(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7_, _hoisted_3$5Q) } var select$1 = /* @__PURE__ */ _export_sfc$2(_sfc_main$al, [ ['render', _sfc_render$2I], ]) const _sfc_main$ak = defineComponent({ name: 'Sell', }) const _hoisted_1$7Z = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6z = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M704 288h131.072a32 32 0 0 1 31.808 28.8L886.4 512h-64.384l-16-160H704v96a32 32 0 1 1-64 0v-96H384v96a32 32 0 0 1-64 0v-96H217.92l-51.2 512H512v64H131.328a32 32 0 0 1-31.808-35.2l57.6-576a32 32 0 0 1 31.808-28.8H320v-22.336C320 154.688 405.504 64 512 64s192 90.688 192 201.664v22.4zm-64 0v-22.336C640 189.248 582.272 128 512 128c-70.272 0-128 61.248-128 137.664v22.4h256zm201.408 483.84L768 698.496V928a32 32 0 1 1-64 0V698.496l-73.344 73.344a32 32 0 1 1-45.248-45.248l128-128a32 32 0 0 1 45.248 0l128 128a32 32 0 1 1-45.248 45.248z', }, null, -1 ) const _hoisted_3$5P = [_hoisted_2$6z] function _sfc_render$2H(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7Z, _hoisted_3$5P) } var sell = /* @__PURE__ */ _export_sfc$2(_sfc_main$ak, [ ['render', _sfc_render$2H], ]) const _sfc_main$aj = defineComponent({ name: 'SemiSelect', }) const _hoisted_1$7Y = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6y = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M128 448h768q64 0 64 64t-64 64H128q-64 0-64-64t64-64z', }, null, -1 ) const _hoisted_3$5O = [_hoisted_2$6y] function _sfc_render$2G(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7Y, _hoisted_3$5O) } var semiSelect = /* @__PURE__ */ _export_sfc$2(_sfc_main$aj, [ ['render', _sfc_render$2G], ]) const _sfc_main$ai = defineComponent({ name: 'Service', }) const _hoisted_1$7X = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6x = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M864 409.6a192 192 0 0 1-37.888 349.44A256.064 256.064 0 0 1 576 960h-96a32 32 0 1 1 0-64h96a192.064 192.064 0 0 0 181.12-128H736a32 32 0 0 1-32-32V416a32 32 0 0 1 32-32h32c10.368 0 20.544.832 30.528 2.432a288 288 0 0 0-573.056 0A193.235 193.235 0 0 1 256 384h32a32 32 0 0 1 32 32v320a32 32 0 0 1-32 32h-32a192 192 0 0 1-96-358.4 352 352 0 0 1 704 0zM256 448a128 128 0 1 0 0 256V448zm640 128a128 128 0 0 0-128-128v256a128 128 0 0 0 128-128z', }, null, -1 ) const _hoisted_3$5N = [_hoisted_2$6x] function _sfc_render$2F(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7X, _hoisted_3$5N) } var service$1 = /* @__PURE__ */ _export_sfc$2(_sfc_main$ai, [ ['render', _sfc_render$2F], ]) const _sfc_main$ah = defineComponent({ name: 'SetUp', }) const _hoisted_1$7W = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6w = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M224 160a64 64 0 0 0-64 64v576a64 64 0 0 0 64 64h576a64 64 0 0 0 64-64V224a64 64 0 0 0-64-64H224zm0-64h576a128 128 0 0 1 128 128v576a128 128 0 0 1-128 128H224A128 128 0 0 1 96 800V224A128 128 0 0 1 224 96z', }, null, -1 ) const _hoisted_3$5M = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M384 416a64 64 0 1 0 0-128 64 64 0 0 0 0 128zm0 64a128 128 0 1 1 0-256 128 128 0 0 1 0 256z', }, null, -1 ) const _hoisted_4$4n = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M480 320h256q32 0 32 32t-32 32H480q-32 0-32-32t32-32zm160 416a64 64 0 1 0 0-128 64 64 0 0 0 0 128zm0 64a128 128 0 1 1 0-256 128 128 0 0 1 0 256z', }, null, -1 ) const _hoisted_5$3K = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M288 640h256q32 0 32 32t-32 32H288q-32 0-32-32t32-32z', }, null, -1 ) const _hoisted_6$3g = [ _hoisted_2$6w, _hoisted_3$5M, _hoisted_4$4n, _hoisted_5$3K, ] function _sfc_render$2E(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7W, _hoisted_6$3g) } var setUp = /* @__PURE__ */ _export_sfc$2(_sfc_main$ah, [ ['render', _sfc_render$2E], ]) const _sfc_main$ag = defineComponent({ name: 'Setting', }) const _hoisted_1$7V = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6v = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M600.704 64a32 32 0 0 1 30.464 22.208l35.2 109.376c14.784 7.232 28.928 15.36 42.432 24.512l112.384-24.192a32 32 0 0 1 34.432 15.36L944.32 364.8a32 32 0 0 1-4.032 37.504l-77.12 85.12a357.12 357.12 0 0 1 0 49.024l77.12 85.248a32 32 0 0 1 4.032 37.504l-88.704 153.6a32 32 0 0 1-34.432 15.296L708.8 803.904c-13.44 9.088-27.648 17.28-42.368 24.512l-35.264 109.376A32 32 0 0 1 600.704 960H423.296a32 32 0 0 1-30.464-22.208L357.696 828.48a351.616 351.616 0 0 1-42.56-24.64l-112.32 24.256a32 32 0 0 1-34.432-15.36L79.68 659.2a32 32 0 0 1 4.032-37.504l77.12-85.248a357.12 357.12 0 0 1 0-48.896l-77.12-85.248A32 32 0 0 1 79.68 364.8l88.704-153.6a32 32 0 0 1 34.432-15.296l112.32 24.256c13.568-9.152 27.776-17.408 42.56-24.64l35.2-109.312A32 32 0 0 1 423.232 64H600.64zm-23.424 64H446.72l-36.352 113.088-24.512 11.968a294.113 294.113 0 0 0-34.816 20.096l-22.656 15.36-116.224-25.088-65.28 113.152 79.68 88.192-1.92 27.136a293.12 293.12 0 0 0 0 40.192l1.92 27.136-79.808 88.192 65.344 113.152 116.224-25.024 22.656 15.296a294.113 294.113 0 0 0 34.816 20.096l24.512 11.968L446.72 896h130.688l36.48-113.152 24.448-11.904a288.282 288.282 0 0 0 34.752-20.096l22.592-15.296 116.288 25.024 65.28-113.152-79.744-88.192 1.92-27.136a293.12 293.12 0 0 0 0-40.256l-1.92-27.136 79.808-88.128-65.344-113.152-116.288 24.96-22.592-15.232a287.616 287.616 0 0 0-34.752-20.096l-24.448-11.904L577.344 128zM512 320a192 192 0 1 1 0 384 192 192 0 0 1 0-384zm0 64a128 128 0 1 0 0 256 128 128 0 0 0 0-256z', }, null, -1 ) const _hoisted_3$5L = [_hoisted_2$6v] function _sfc_render$2D(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7V, _hoisted_3$5L) } var setting = /* @__PURE__ */ _export_sfc$2(_sfc_main$ag, [ ['render', _sfc_render$2D], ]) const _sfc_main$af = defineComponent({ name: 'Share', }) const _hoisted_1$7U = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6u = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm679.872 348.8-301.76 188.608a127.808 127.808 0 0 1 5.12 52.16l279.936 104.96a128 128 0 1 1-22.464 59.904l-279.872-104.96a128 128 0 1 1-16.64-166.272l301.696-188.608a128 128 0 1 1 33.92 54.272z', }, null, -1 ) const _hoisted_3$5K = [_hoisted_2$6u] function _sfc_render$2C(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7U, _hoisted_3$5K) } var share = /* @__PURE__ */ _export_sfc$2(_sfc_main$af, [ ['render', _sfc_render$2C], ]) const _sfc_main$ae = defineComponent({ name: 'Ship', }) const _hoisted_1$7T = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6t = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 386.88V448h405.568a32 32 0 0 1 30.72 40.768l-76.48 267.968A192 192 0 0 1 687.168 896H336.832a192 192 0 0 1-184.64-139.264L75.648 488.768A32 32 0 0 1 106.368 448H448V117.888a32 32 0 0 1 47.36-28.096l13.888 7.616L512 96v2.88l231.68 126.4a32 32 0 0 1-2.048 57.216L512 386.88zm0-70.272 144.768-65.792L512 171.84v144.768zM512 512H148.864l18.24 64H856.96l18.24-64H512zM185.408 640l28.352 99.2A128 128 0 0 0 336.832 832h350.336a128 128 0 0 0 123.072-92.8l28.352-99.2H185.408z', }, null, -1 ) const _hoisted_3$5J = [_hoisted_2$6t] function _sfc_render$2B(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7T, _hoisted_3$5J) } var ship = /* @__PURE__ */ _export_sfc$2(_sfc_main$ae, [ ['render', _sfc_render$2B], ]) const _sfc_main$ad = defineComponent({ name: 'Shop', }) const _hoisted_1$7S = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6s = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M704 704h64v192H256V704h64v64h384v-64zm188.544-152.192C894.528 559.616 896 567.616 896 576a96 96 0 1 1-192 0 96 96 0 1 1-192 0 96 96 0 1 1-192 0 96 96 0 1 1-192 0c0-8.384 1.408-16.384 3.392-24.192L192 128h640l60.544 423.808z', }, null, -1 ) const _hoisted_3$5I = [_hoisted_2$6s] function _sfc_render$2A(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7S, _hoisted_3$5I) } var shop = /* @__PURE__ */ _export_sfc$2(_sfc_main$ad, [ ['render', _sfc_render$2A], ]) const _sfc_main$ac = defineComponent({ name: 'ShoppingBag', }) const _hoisted_1$7R = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6r = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M704 320v96a32 32 0 0 1-32 32h-32V320H384v128h-32a32 32 0 0 1-32-32v-96H192v576h640V320H704zm-384-64a192 192 0 1 1 384 0h160a32 32 0 0 1 32 32v640a32 32 0 0 1-32 32H160a32 32 0 0 1-32-32V288a32 32 0 0 1 32-32h160zm64 0h256a128 128 0 1 0-256 0z', }, null, -1 ) const _hoisted_3$5H = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M192 704h640v64H192z', }, null, -1 ) const _hoisted_4$4m = [_hoisted_2$6r, _hoisted_3$5H] function _sfc_render$2z(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7R, _hoisted_4$4m) } var shoppingBag = /* @__PURE__ */ _export_sfc$2(_sfc_main$ac, [ ['render', _sfc_render$2z], ]) const _sfc_main$ab = defineComponent({ name: 'ShoppingCartFull', }) const _hoisted_1$7Q = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6q = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M432 928a48 48 0 1 1 0-96 48 48 0 0 1 0 96zm320 0a48 48 0 1 1 0-96 48 48 0 0 1 0 96zM96 128a32 32 0 0 1 0-64h160a32 32 0 0 1 31.36 25.728L320.64 256H928a32 32 0 0 1 31.296 38.72l-96 448A32 32 0 0 1 832 768H384a32 32 0 0 1-31.36-25.728L229.76 128H96zm314.24 576h395.904l82.304-384H333.44l76.8 384z', }, null, -1 ) const _hoisted_3$5G = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M699.648 256 608 145.984 516.352 256h183.296zm-140.8-151.04a64 64 0 0 1 98.304 0L836.352 320H379.648l179.2-215.04z', }, null, -1 ) const _hoisted_4$4l = [_hoisted_2$6q, _hoisted_3$5G] function _sfc_render$2y(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7Q, _hoisted_4$4l) } var shoppingCartFull = /* @__PURE__ */ _export_sfc$2(_sfc_main$ab, [ ['render', _sfc_render$2y], ]) const _sfc_main$aa = defineComponent({ name: 'ShoppingCart', }) const _hoisted_1$7P = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6p = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M432 928a48 48 0 1 1 0-96 48 48 0 0 1 0 96zm320 0a48 48 0 1 1 0-96 48 48 0 0 1 0 96zM96 128a32 32 0 0 1 0-64h160a32 32 0 0 1 31.36 25.728L320.64 256H928a32 32 0 0 1 31.296 38.72l-96 448A32 32 0 0 1 832 768H384a32 32 0 0 1-31.36-25.728L229.76 128H96zm314.24 576h395.904l82.304-384H333.44l76.8 384z', }, null, -1 ) const _hoisted_3$5F = [_hoisted_2$6p] function _sfc_render$2x(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7P, _hoisted_3$5F) } var shoppingCart = /* @__PURE__ */ _export_sfc$2(_sfc_main$aa, [ ['render', _sfc_render$2x], ]) const _sfc_main$a9 = defineComponent({ name: 'Smoking', }) const _hoisted_1$7O = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6o = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M256 576v128h640V576H256zm-32-64h704a32 32 0 0 1 32 32v192a32 32 0 0 1-32 32H224a32 32 0 0 1-32-32V544a32 32 0 0 1 32-32z', }, null, -1 ) const _hoisted_3$5E = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M704 576h64v128h-64zM256 64h64v320h-64zM128 192h64v192h-64zM64 512h64v256H64z', }, null, -1 ) const _hoisted_4$4k = [_hoisted_2$6o, _hoisted_3$5E] function _sfc_render$2w(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7O, _hoisted_4$4k) } var smoking = /* @__PURE__ */ _export_sfc$2(_sfc_main$a9, [ ['render', _sfc_render$2w], ]) const _sfc_main$a8 = defineComponent({ name: 'Soccer', }) const _hoisted_1$7N = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6n = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M418.496 871.04 152.256 604.8c-16.512 94.016-2.368 178.624 42.944 224 44.928 44.928 129.344 58.752 223.296 42.24zm72.32-18.176a573.056 573.056 0 0 0 224.832-137.216 573.12 573.12 0 0 0 137.216-224.832L533.888 171.84a578.56 578.56 0 0 0-227.52 138.496A567.68 567.68 0 0 0 170.432 532.48l320.384 320.384zM871.04 418.496c16.512-93.952 2.688-178.368-42.24-223.296-44.544-44.544-128.704-58.048-222.592-41.536L871.04 418.496zM149.952 874.048c-112.96-112.96-88.832-408.96 111.168-608.96C461.056 65.152 760.96 36.928 874.048 149.952c113.024 113.024 86.784 411.008-113.152 610.944-199.936 199.936-497.92 226.112-610.944 113.152zm452.544-497.792 22.656-22.656a32 32 0 0 1 45.248 45.248l-22.656 22.656 45.248 45.248A32 32 0 1 1 647.744 512l-45.248-45.248L557.248 512l45.248 45.248a32 32 0 1 1-45.248 45.248L512 557.248l-45.248 45.248L512 647.744a32 32 0 1 1-45.248 45.248l-45.248-45.248-22.656 22.656a32 32 0 1 1-45.248-45.248l22.656-22.656-45.248-45.248A32 32 0 1 1 376.256 512l45.248 45.248L466.752 512l-45.248-45.248a32 32 0 1 1 45.248-45.248L512 466.752l45.248-45.248L512 376.256a32 32 0 0 1 45.248-45.248l45.248 45.248z', }, null, -1 ) const _hoisted_3$5D = [_hoisted_2$6n] function _sfc_render$2v(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7N, _hoisted_3$5D) } var soccer = /* @__PURE__ */ _export_sfc$2(_sfc_main$a8, [ ['render', _sfc_render$2v], ]) const _sfc_main$a7 = defineComponent({ name: 'SoldOut', }) const _hoisted_1$7M = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6m = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M704 288h131.072a32 32 0 0 1 31.808 28.8L886.4 512h-64.384l-16-160H704v96a32 32 0 1 1-64 0v-96H384v96a32 32 0 0 1-64 0v-96H217.92l-51.2 512H512v64H131.328a32 32 0 0 1-31.808-35.2l57.6-576a32 32 0 0 1 31.808-28.8H320v-22.336C320 154.688 405.504 64 512 64s192 90.688 192 201.664v22.4zm-64 0v-22.336C640 189.248 582.272 128 512 128c-70.272 0-128 61.248-128 137.664v22.4h256zm201.408 476.16a32 32 0 1 1 45.248 45.184l-128 128a32 32 0 0 1-45.248 0l-128-128a32 32 0 1 1 45.248-45.248L704 837.504V608a32 32 0 1 1 64 0v229.504l73.408-73.408z', }, null, -1 ) const _hoisted_3$5C = [_hoisted_2$6m] function _sfc_render$2u(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7M, _hoisted_3$5C) } var soldOut = /* @__PURE__ */ _export_sfc$2(_sfc_main$a7, [ ['render', _sfc_render$2u], ]) const _sfc_main$a6 = defineComponent({ name: 'SortDown', }) const _hoisted_1$7L = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6l = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M576 96v709.568L333.312 562.816A32 32 0 1 0 288 608l297.408 297.344A32 32 0 0 0 640 882.688V96a32 32 0 0 0-64 0z', }, null, -1 ) const _hoisted_3$5B = [_hoisted_2$6l] function _sfc_render$2t(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7L, _hoisted_3$5B) } var sortDown = /* @__PURE__ */ _export_sfc$2(_sfc_main$a6, [ ['render', _sfc_render$2t], ]) const _sfc_main$a5 = defineComponent({ name: 'SortUp', }) const _hoisted_1$7K = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6k = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M384 141.248V928a32 32 0 1 0 64 0V218.56l242.688 242.688A32 32 0 1 0 736 416L438.592 118.656A32 32 0 0 0 384 141.248z', }, null, -1 ) const _hoisted_3$5A = [_hoisted_2$6k] function _sfc_render$2s(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7K, _hoisted_3$5A) } var sortUp = /* @__PURE__ */ _export_sfc$2(_sfc_main$a5, [ ['render', _sfc_render$2s], ]) const _sfc_main$a4 = defineComponent({ name: 'Sort', }) const _hoisted_1$7J = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6j = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M384 96a32 32 0 0 1 64 0v786.752a32 32 0 0 1-54.592 22.656L95.936 608a32 32 0 0 1 0-45.312h.128a32 32 0 0 1 45.184 0L384 805.632V96zm192 45.248a32 32 0 0 1 54.592-22.592L928.064 416a32 32 0 0 1 0 45.312h-.128a32 32 0 0 1-45.184 0L640 218.496V928a32 32 0 1 1-64 0V141.248z', }, null, -1 ) const _hoisted_3$5z = [_hoisted_2$6j] function _sfc_render$2r(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7J, _hoisted_3$5z) } var sort$3 = /* @__PURE__ */ _export_sfc$2(_sfc_main$a4, [ ['render', _sfc_render$2r], ]) const _sfc_main$a3 = defineComponent({ name: 'Stamp', }) const _hoisted_1$7I = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6i = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M624 475.968V640h144a128 128 0 0 1 128 128H128a128 128 0 0 1 128-128h144V475.968a192 192 0 1 1 224 0zM128 896v-64h768v64H128z', }, null, -1 ) const _hoisted_3$5y = [_hoisted_2$6i] function _sfc_render$2q(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7I, _hoisted_3$5y) } var stamp = /* @__PURE__ */ _export_sfc$2(_sfc_main$a3, [ ['render', _sfc_render$2q], ]) const _sfc_main$a2 = defineComponent({ name: 'StarFilled', }) const _hoisted_1$7H = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6h = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M283.84 867.84 512 747.776l228.16 119.936a6.4 6.4 0 0 0 9.28-6.72l-43.52-254.08 184.512-179.904a6.4 6.4 0 0 0-3.52-10.88l-255.104-37.12L517.76 147.904a6.4 6.4 0 0 0-11.52 0L392.192 379.072l-255.104 37.12a6.4 6.4 0 0 0-3.52 10.88L318.08 606.976l-43.584 254.08a6.4 6.4 0 0 0 9.28 6.72z', }, null, -1 ) const _hoisted_3$5x = [_hoisted_2$6h] function _sfc_render$2p(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7H, _hoisted_3$5x) } var starFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$a2, [ ['render', _sfc_render$2p], ]) const _sfc_main$a1 = defineComponent({ name: 'Star', }) const _hoisted_1$7G = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6g = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm512 747.84 228.16 119.936a6.4 6.4 0 0 0 9.28-6.72l-43.52-254.08 184.512-179.904a6.4 6.4 0 0 0-3.52-10.88l-255.104-37.12L517.76 147.904a6.4 6.4 0 0 0-11.52 0L392.192 379.072l-255.104 37.12a6.4 6.4 0 0 0-3.52 10.88L318.08 606.976l-43.584 254.08a6.4 6.4 0 0 0 9.28 6.72L512 747.84zM313.6 924.48a70.4 70.4 0 0 1-102.144-74.24l37.888-220.928L88.96 472.96A70.4 70.4 0 0 1 128 352.896l221.76-32.256 99.2-200.96a70.4 70.4 0 0 1 126.208 0l99.2 200.96 221.824 32.256a70.4 70.4 0 0 1 39.04 120.064L774.72 629.376l37.888 220.928a70.4 70.4 0 0 1-102.144 74.24L512 820.096l-198.4 104.32z', }, null, -1 ) const _hoisted_3$5w = [_hoisted_2$6g] function _sfc_render$2o(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7G, _hoisted_3$5w) } var star = /* @__PURE__ */ _export_sfc$2(_sfc_main$a1, [ ['render', _sfc_render$2o], ]) const _sfc_main$a0 = defineComponent({ name: 'Stopwatch', }) const _hoisted_1$7F = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6f = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 896a384 384 0 1 0 0-768 384 384 0 0 0 0 768zm0 64a448 448 0 1 1 0-896 448 448 0 0 1 0 896z', }, null, -1 ) const _hoisted_3$5v = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M672 234.88c-39.168 174.464-80 298.624-122.688 372.48-64 110.848-202.624 30.848-138.624-80C453.376 453.44 540.48 355.968 672 234.816z', }, null, -1 ) const _hoisted_4$4j = [_hoisted_2$6f, _hoisted_3$5v] function _sfc_render$2n(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7F, _hoisted_4$4j) } var stopwatch = /* @__PURE__ */ _export_sfc$2(_sfc_main$a0, [ ['render', _sfc_render$2n], ]) const _sfc_main$9$ = defineComponent({ name: 'SuccessFilled', }) const _hoisted_1$7E = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6e = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896zm-55.808 536.384-99.52-99.584a38.4 38.4 0 1 0-54.336 54.336l126.72 126.72a38.272 38.272 0 0 0 54.336 0l262.4-262.464a38.4 38.4 0 1 0-54.272-54.336L456.192 600.384z', }, null, -1 ) const _hoisted_3$5u = [_hoisted_2$6e] function _sfc_render$2m(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7E, _hoisted_3$5u) } var successFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$9$, [ ['render', _sfc_render$2m], ]) const _sfc_main$9_ = defineComponent({ name: 'Sugar', }) const _hoisted_1$7D = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6d = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm801.728 349.184 4.48 4.48a128 128 0 0 1 0 180.992L534.656 806.144a128 128 0 0 1-181.056 0l-4.48-4.48-19.392 109.696a64 64 0 0 1-108.288 34.176L78.464 802.56a64 64 0 0 1 34.176-108.288l109.76-19.328-4.544-4.544a128 128 0 0 1 0-181.056l271.488-271.488a128 128 0 0 1 181.056 0l4.48 4.48 19.392-109.504a64 64 0 0 1 108.352-34.048l142.592 143.04a64 64 0 0 1-34.24 108.16l-109.248 19.2zm-548.8 198.72h447.168v2.24l60.8-60.8a63.808 63.808 0 0 0 18.752-44.416h-426.88l-89.664 89.728a64.064 64.064 0 0 0-10.24 13.248zm0 64c2.752 4.736 6.144 9.152 10.176 13.248l135.744 135.744a64 64 0 0 0 90.496 0L638.4 611.904H252.928zm490.048-230.976L625.152 263.104a64 64 0 0 0-90.496 0L416.768 380.928h326.208zM123.712 757.312l142.976 142.976 24.32-137.6a25.6 25.6 0 0 0-29.696-29.632l-137.6 24.256zm633.6-633.344-24.32 137.472a25.6 25.6 0 0 0 29.632 29.632l137.28-24.064-142.656-143.04z', }, null, -1 ) const _hoisted_3$5t = [_hoisted_2$6d] function _sfc_render$2l(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7D, _hoisted_3$5t) } var sugar = /* @__PURE__ */ _export_sfc$2(_sfc_main$9_, [ ['render', _sfc_render$2l], ]) const _sfc_main$9Z = defineComponent({ name: 'Suitcase', }) const _hoisted_1$7C = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6c = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M128 384h768v-64a64 64 0 0 0-64-64H192a64 64 0 0 0-64 64v64zm0 64v320a64 64 0 0 0 64 64h640a64 64 0 0 0 64-64V448H128zm64-256h640a128 128 0 0 1 128 128v448a128 128 0 0 1-128 128H192A128 128 0 0 1 64 768V320a128 128 0 0 1 128-128z', }, null, -1 ) const _hoisted_3$5s = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M384 128v64h256v-64H384zm0-64h256a64 64 0 0 1 64 64v64a64 64 0 0 1-64 64H384a64 64 0 0 1-64-64v-64a64 64 0 0 1 64-64z', }, null, -1 ) const _hoisted_4$4i = [_hoisted_2$6c, _hoisted_3$5s] function _sfc_render$2k(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7C, _hoisted_4$4i) } var suitcase = /* @__PURE__ */ _export_sfc$2(_sfc_main$9Z, [ ['render', _sfc_render$2k], ]) const _sfc_main$9Y = defineComponent({ name: 'Sunny', }) const _hoisted_1$7B = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6b = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 704a192 192 0 1 0 0-384 192 192 0 0 0 0 384zm0 64a256 256 0 1 1 0-512 256 256 0 0 1 0 512zm0-704a32 32 0 0 1 32 32v64a32 32 0 0 1-64 0V96a32 32 0 0 1 32-32zm0 768a32 32 0 0 1 32 32v64a32 32 0 1 1-64 0v-64a32 32 0 0 1 32-32zM195.2 195.2a32 32 0 0 1 45.248 0l45.248 45.248a32 32 0 1 1-45.248 45.248L195.2 240.448a32 32 0 0 1 0-45.248zm543.104 543.104a32 32 0 0 1 45.248 0l45.248 45.248a32 32 0 0 1-45.248 45.248l-45.248-45.248a32 32 0 0 1 0-45.248zM64 512a32 32 0 0 1 32-32h64a32 32 0 0 1 0 64H96a32 32 0 0 1-32-32zm768 0a32 32 0 0 1 32-32h64a32 32 0 1 1 0 64h-64a32 32 0 0 1-32-32zM195.2 828.8a32 32 0 0 1 0-45.248l45.248-45.248a32 32 0 0 1 45.248 45.248L240.448 828.8a32 32 0 0 1-45.248 0zm543.104-543.104a32 32 0 0 1 0-45.248l45.248-45.248a32 32 0 0 1 45.248 45.248l-45.248 45.248a32 32 0 0 1-45.248 0z', }, null, -1 ) const _hoisted_3$5r = [_hoisted_2$6b] function _sfc_render$2j(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7B, _hoisted_3$5r) } var sunny = /* @__PURE__ */ _export_sfc$2(_sfc_main$9Y, [ ['render', _sfc_render$2j], ]) const _sfc_main$9X = defineComponent({ name: 'Sunrise', }) const _hoisted_1$7A = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$6a = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M32 768h960a32 32 0 1 1 0 64H32a32 32 0 1 1 0-64zm129.408-96a352 352 0 0 1 701.184 0h-64.32a288 288 0 0 0-572.544 0h-64.32zM512 128a32 32 0 0 1 32 32v96a32 32 0 0 1-64 0v-96a32 32 0 0 1 32-32zm407.296 168.704a32 32 0 0 1 0 45.248l-67.84 67.84a32 32 0 1 1-45.248-45.248l67.84-67.84a32 32 0 0 1 45.248 0zm-814.592 0a32 32 0 0 1 45.248 0l67.84 67.84a32 32 0 1 1-45.248 45.248l-67.84-67.84a32 32 0 0 1 0-45.248z', }, null, -1 ) const _hoisted_3$5q = [_hoisted_2$6a] function _sfc_render$2i(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7A, _hoisted_3$5q) } var sunrise = /* @__PURE__ */ _export_sfc$2(_sfc_main$9X, [ ['render', _sfc_render$2i], ]) const _sfc_main$9W = defineComponent({ name: 'Sunset', }) const _hoisted_1$7z = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$69 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M82.56 640a448 448 0 1 1 858.88 0h-67.2a384 384 0 1 0-724.288 0H82.56zM32 704h960q32 0 32 32t-32 32H32q-32 0-32-32t32-32zm256 128h448q32 0 32 32t-32 32H288q-32 0-32-32t32-32z', }, null, -1 ) const _hoisted_3$5p = [_hoisted_2$69] function _sfc_render$2h(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7z, _hoisted_3$5p) } var sunset = /* @__PURE__ */ _export_sfc$2(_sfc_main$9W, [ ['render', _sfc_render$2h], ]) const _sfc_main$9V = defineComponent({ name: 'SwitchButton', }) const _hoisted_1$7y = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$68 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M352 159.872V230.4a352 352 0 1 0 320 0v-70.528A416.128 416.128 0 0 1 512 960a416 416 0 0 1-160-800.128z', }, null, -1 ) const _hoisted_3$5o = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 64q32 0 32 32v320q0 32-32 32t-32-32V96q0-32 32-32z', }, null, -1 ) const _hoisted_4$4h = [_hoisted_2$68, _hoisted_3$5o] function _sfc_render$2g(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7y, _hoisted_4$4h) } var switchButton = /* @__PURE__ */ _export_sfc$2(_sfc_main$9V, [ ['render', _sfc_render$2g], ]) const _sfc_main$9U = defineComponent({ name: 'Switch', }) const _hoisted_1$7x = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$67 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M118.656 438.656a32 32 0 0 1 0-45.248L416 96l4.48-3.776A32 32 0 0 1 461.248 96l3.712 4.48a32.064 32.064 0 0 1-3.712 40.832L218.56 384H928a32 32 0 1 1 0 64H141.248a32 32 0 0 1-22.592-9.344zM64 608a32 32 0 0 1 32-32h786.752a32 32 0 0 1 22.656 54.592L608 928l-4.48 3.776a32.064 32.064 0 0 1-40.832-49.024L805.632 640H96a32 32 0 0 1-32-32z', }, null, -1 ) const _hoisted_3$5n = [_hoisted_2$67] function _sfc_render$2f(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7x, _hoisted_3$5n) } var _switch = /* @__PURE__ */ _export_sfc$2(_sfc_main$9U, [ ['render', _sfc_render$2f], ]) const _sfc_main$9T = defineComponent({ name: 'TakeawayBox', }) const _hoisted_1$7w = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$66 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M832 384H192v448h640V384zM96 320h832V128H96v192zm800 64v480a32 32 0 0 1-32 32H160a32 32 0 0 1-32-32V384H64a32 32 0 0 1-32-32V96a32 32 0 0 1 32-32h896a32 32 0 0 1 32 32v256a32 32 0 0 1-32 32h-64zM416 512h192a32 32 0 0 1 0 64H416a32 32 0 0 1 0-64z', }, null, -1 ) const _hoisted_3$5m = [_hoisted_2$66] function _sfc_render$2e(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7w, _hoisted_3$5m) } var takeawayBox = /* @__PURE__ */ _export_sfc$2(_sfc_main$9T, [ ['render', _sfc_render$2e], ]) const _sfc_main$9S = defineComponent({ name: 'Ticket', }) const _hoisted_1$7v = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$65 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M640 832H64V640a128 128 0 1 0 0-256V192h576v160h64V192h256v192a128 128 0 1 0 0 256v192H704V672h-64v160zm0-416v192h64V416h-64z', }, null, -1 ) const _hoisted_3$5l = [_hoisted_2$65] function _sfc_render$2d(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7v, _hoisted_3$5l) } var ticket = /* @__PURE__ */ _export_sfc$2(_sfc_main$9S, [ ['render', _sfc_render$2d], ]) const _sfc_main$9R = defineComponent({ name: 'Tickets', }) const _hoisted_1$7u = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$64 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M192 128v768h640V128H192zm-32-64h704a32 32 0 0 1 32 32v832a32 32 0 0 1-32 32H160a32 32 0 0 1-32-32V96a32 32 0 0 1 32-32zm160 448h384v64H320v-64zm0-192h192v64H320v-64zm0 384h384v64H320v-64z', }, null, -1 ) const _hoisted_3$5k = [_hoisted_2$64] function _sfc_render$2c(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7u, _hoisted_3$5k) } var tickets = /* @__PURE__ */ _export_sfc$2(_sfc_main$9R, [ ['render', _sfc_render$2c], ]) const _sfc_main$9Q = defineComponent({ name: 'Timer', }) const _hoisted_1$7t = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$63 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 896a320 320 0 1 0 0-640 320 320 0 0 0 0 640zm0 64a384 384 0 1 1 0-768 384 384 0 0 1 0 768z', }, null, -1 ) const _hoisted_3$5j = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 320a32 32 0 0 1 32 32l-.512 224a32 32 0 1 1-64 0L480 352a32 32 0 0 1 32-32z', }, null, -1 ) const _hoisted_4$4g = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M448 576a64 64 0 1 0 128 0 64 64 0 1 0-128 0zm96-448v128h-64V128h-96a32 32 0 0 1 0-64h256a32 32 0 1 1 0 64h-96z', }, null, -1 ) const _hoisted_5$3J = [_hoisted_2$63, _hoisted_3$5j, _hoisted_4$4g] function _sfc_render$2b(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7t, _hoisted_5$3J) } var timer = /* @__PURE__ */ _export_sfc$2(_sfc_main$9Q, [ ['render', _sfc_render$2b], ]) const _sfc_main$9P = defineComponent({ name: 'ToiletPaper', }) const _hoisted_1$7s = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$62 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M595.2 128H320a192 192 0 0 0-192 192v576h384V352c0-90.496 32.448-171.2 83.2-224zM736 64c123.712 0 224 128.96 224 288S859.712 640 736 640H576v320H64V320A256 256 0 0 1 320 64h416zM576 352v224h160c84.352 0 160-97.28 160-224s-75.648-224-160-224-160 97.28-160 224z', }, null, -1 ) const _hoisted_3$5i = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M736 448c-35.328 0-64-43.008-64-96s28.672-96 64-96 64 43.008 64 96-28.672 96-64 96z', }, null, -1 ) const _hoisted_4$4f = [_hoisted_2$62, _hoisted_3$5i] function _sfc_render$2a(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7s, _hoisted_4$4f) } var toiletPaper = /* @__PURE__ */ _export_sfc$2(_sfc_main$9P, [ ['render', _sfc_render$2a], ]) const _sfc_main$9O = defineComponent({ name: 'Tools', }) const _hoisted_1$7r = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$61 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M764.416 254.72a351.68 351.68 0 0 1 86.336 149.184H960v192.064H850.752a351.68 351.68 0 0 1-86.336 149.312l54.72 94.72-166.272 96-54.592-94.72a352.64 352.64 0 0 1-172.48 0L371.136 936l-166.272-96 54.72-94.72a351.68 351.68 0 0 1-86.336-149.312H64v-192h109.248a351.68 351.68 0 0 1 86.336-149.312L204.8 160l166.208-96h.192l54.656 94.592a352.64 352.64 0 0 1 172.48 0L652.8 64h.128L819.2 160l-54.72 94.72zM704 499.968a192 192 0 1 0-384 0 192 192 0 0 0 384 0z', }, null, -1 ) const _hoisted_3$5h = [_hoisted_2$61] function _sfc_render$29(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7r, _hoisted_3$5h) } var tools = /* @__PURE__ */ _export_sfc$2(_sfc_main$9O, [ ['render', _sfc_render$29], ]) const _sfc_main$9N = defineComponent({ name: 'TopLeft', }) const _hoisted_1$7q = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$60 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M256 256h416a32 32 0 1 0 0-64H224a32 32 0 0 0-32 32v448a32 32 0 0 0 64 0V256z', }, null, -1 ) const _hoisted_3$5g = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M246.656 201.344a32 32 0 0 0-45.312 45.312l544 544a32 32 0 0 0 45.312-45.312l-544-544z', }, null, -1 ) const _hoisted_4$4e = [_hoisted_2$60, _hoisted_3$5g] function _sfc_render$28(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7q, _hoisted_4$4e) } var topLeft = /* @__PURE__ */ _export_sfc$2(_sfc_main$9N, [ ['render', _sfc_render$28], ]) const _sfc_main$9M = defineComponent({ name: 'TopRight', }) const _hoisted_1$7p = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5$ = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M768 256H353.6a32 32 0 1 1 0-64H800a32 32 0 0 1 32 32v448a32 32 0 0 1-64 0V256z', }, null, -1 ) const _hoisted_3$5f = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M777.344 201.344a32 32 0 0 1 45.312 45.312l-544 544a32 32 0 0 1-45.312-45.312l544-544z', }, null, -1 ) const _hoisted_4$4d = [_hoisted_2$5$, _hoisted_3$5f] function _sfc_render$27(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7p, _hoisted_4$4d) } var topRight = /* @__PURE__ */ _export_sfc$2(_sfc_main$9M, [ ['render', _sfc_render$27], ]) const _sfc_main$9L = defineComponent({ name: 'Top', }) const _hoisted_1$7o = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5_ = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M572.235 205.282v600.365a30.118 30.118 0 1 1-60.235 0V205.282L292.382 438.633a28.913 28.913 0 0 1-42.646 0 33.43 33.43 0 0 1 0-45.236l271.058-288.045a28.913 28.913 0 0 1 42.647 0L834.5 393.397a33.43 33.43 0 0 1 0 45.176 28.913 28.913 0 0 1-42.647 0l-219.618-233.23z', }, null, -1 ) const _hoisted_3$5e = [_hoisted_2$5_] function _sfc_render$26(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7o, _hoisted_3$5e) } var top$1 = /* @__PURE__ */ _export_sfc$2(_sfc_main$9L, [ ['render', _sfc_render$26], ]) const _sfc_main$9K = defineComponent({ name: 'TrendCharts', }) const _hoisted_1$7n = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5Z = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M128 896V128h768v768H128zm291.712-327.296 128 102.4 180.16-201.792-47.744-42.624-139.84 156.608-128-102.4-180.16 201.792 47.744 42.624 139.84-156.608zM816 352a48 48 0 1 0-96 0 48 48 0 0 0 96 0z', }, null, -1 ) const _hoisted_3$5d = [_hoisted_2$5Z] function _sfc_render$25(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7n, _hoisted_3$5d) } var trendCharts = /* @__PURE__ */ _export_sfc$2(_sfc_main$9K, [ ['render', _sfc_render$25], ]) const _sfc_main$9J = defineComponent({ name: 'Trophy', }) const _hoisted_1$7m = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5Y = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M480 896V702.08A256.256 256.256 0 0 1 264.064 512h-32.64a96 96 0 0 1-91.968-68.416L93.632 290.88a76.8 76.8 0 0 1 73.6-98.88H256V96a32 32 0 0 1 32-32h448a32 32 0 0 1 32 32v96h88.768a76.8 76.8 0 0 1 73.6 98.88L884.48 443.52A96 96 0 0 1 792.576 512h-32.64A256.256 256.256 0 0 1 544 702.08V896h128a32 32 0 1 1 0 64H352a32 32 0 1 1 0-64h128zm224-448V128H320v320a192 192 0 1 0 384 0zm64 0h24.576a32 32 0 0 0 30.656-22.784l45.824-152.768A12.8 12.8 0 0 0 856.768 256H768v192zm-512 0V256h-88.768a12.8 12.8 0 0 0-12.288 16.448l45.824 152.768A32 32 0 0 0 231.424 448H256z', }, null, -1 ) const _hoisted_3$5c = [_hoisted_2$5Y] function _sfc_render$24(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7m, _hoisted_3$5c) } var trophy = /* @__PURE__ */ _export_sfc$2(_sfc_main$9J, [ ['render', _sfc_render$24], ]) const _sfc_main$9I = defineComponent({ name: 'TurnOff', }) const _hoisted_1$7l = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5X = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M329.956 257.138a254.862 254.862 0 0 0 0 509.724h364.088a254.862 254.862 0 0 0 0-509.724H329.956zm0-72.818h364.088a327.68 327.68 0 1 1 0 655.36H329.956a327.68 327.68 0 1 1 0-655.36z', }, null, -1 ) const _hoisted_3$5b = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M329.956 621.227a109.227 109.227 0 1 0 0-218.454 109.227 109.227 0 0 0 0 218.454zm0 72.817a182.044 182.044 0 1 1 0-364.088 182.044 182.044 0 0 1 0 364.088z', }, null, -1 ) const _hoisted_4$4c = [_hoisted_2$5X, _hoisted_3$5b] function _sfc_render$23(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7l, _hoisted_4$4c) } var turnOff = /* @__PURE__ */ _export_sfc$2(_sfc_main$9I, [ ['render', _sfc_render$23], ]) const _sfc_main$9H = defineComponent({ name: 'Umbrella', }) const _hoisted_1$7k = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5W = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M320 768a32 32 0 1 1 64 0 64 64 0 0 0 128 0V512H64a448 448 0 1 1 896 0H576v256a128 128 0 1 1-256 0zm570.688-320a384.128 384.128 0 0 0-757.376 0h757.376z', }, null, -1 ) const _hoisted_3$5a = [_hoisted_2$5W] function _sfc_render$22(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7k, _hoisted_3$5a) } var umbrella = /* @__PURE__ */ _export_sfc$2(_sfc_main$9H, [ ['render', _sfc_render$22], ]) const _sfc_main$9G = defineComponent({ name: 'Unlock', }) const _hoisted_1$7j = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5V = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M224 448a32 32 0 0 0-32 32v384a32 32 0 0 0 32 32h576a32 32 0 0 0 32-32V480a32 32 0 0 0-32-32H224zm0-64h576a96 96 0 0 1 96 96v384a96 96 0 0 1-96 96H224a96 96 0 0 1-96-96V480a96 96 0 0 1 96-96z', }, null, -1 ) const _hoisted_3$59 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 544a32 32 0 0 1 32 32v192a32 32 0 1 1-64 0V576a32 32 0 0 1 32-32zm178.304-295.296A192.064 192.064 0 0 0 320 320v64h352l96 38.4V448H256V320a256 256 0 0 1 493.76-95.104l-59.456 23.808z', }, null, -1 ) const _hoisted_4$4b = [_hoisted_2$5V, _hoisted_3$59] function _sfc_render$21(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7j, _hoisted_4$4b) } var unlock = /* @__PURE__ */ _export_sfc$2(_sfc_main$9G, [ ['render', _sfc_render$21], ]) const _sfc_main$9F = defineComponent({ name: 'UploadFilled', }) const _hoisted_1$7i = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5U = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M544 864V672h128L512 480 352 672h128v192H320v-1.6c-5.376.32-10.496 1.6-16 1.6A240 240 0 0 1 64 624c0-123.136 93.12-223.488 212.608-237.248A239.808 239.808 0 0 1 512 192a239.872 239.872 0 0 1 235.456 194.752c119.488 13.76 212.48 114.112 212.48 237.248a240 240 0 0 1-240 240c-5.376 0-10.56-1.28-16-1.6v1.6H544z', }, null, -1 ) const _hoisted_3$58 = [_hoisted_2$5U] function _sfc_render$20(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7i, _hoisted_3$58) } var uploadFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$9F, [ ['render', _sfc_render$20], ]) const _sfc_main$9E = defineComponent({ name: 'Upload', }) const _hoisted_1$7h = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5T = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M160 832h704a32 32 0 1 1 0 64H160a32 32 0 1 1 0-64zm384-578.304V704h-64V247.296L237.248 490.048 192 444.8 508.8 128l316.8 316.8-45.312 45.248L544 253.696z', }, null, -1 ) const _hoisted_3$57 = [_hoisted_2$5T] function _sfc_render$1$(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7h, _hoisted_3$57) } var upload = /* @__PURE__ */ _export_sfc$2(_sfc_main$9E, [ ['render', _sfc_render$1$], ]) const _sfc_main$9D = defineComponent({ name: 'UserFilled', }) const _hoisted_1$7g = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5S = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M288 320a224 224 0 1 0 448 0 224 224 0 1 0-448 0zm544 608H160a32 32 0 0 1-32-32v-96a160 160 0 0 1 160-160h448a160 160 0 0 1 160 160v96a32 32 0 0 1-32 32z', }, null, -1 ) const _hoisted_3$56 = [_hoisted_2$5S] function _sfc_render$1_(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7g, _hoisted_3$56) } var userFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$9D, [ ['render', _sfc_render$1_], ]) const _sfc_main$9C = defineComponent({ name: 'User', }) const _hoisted_1$7f = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5R = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 512a192 192 0 1 0 0-384 192 192 0 0 0 0 384zm0 64a256 256 0 1 1 0-512 256 256 0 0 1 0 512zm320 320v-96a96 96 0 0 0-96-96H288a96 96 0 0 0-96 96v96a32 32 0 1 1-64 0v-96a160 160 0 0 1 160-160h448a160 160 0 0 1 160 160v96a32 32 0 1 1-64 0z', }, null, -1 ) const _hoisted_3$55 = [_hoisted_2$5R] function _sfc_render$1Z(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7f, _hoisted_3$55) } var user = /* @__PURE__ */ _export_sfc$2(_sfc_main$9C, [ ['render', _sfc_render$1Z], ]) const _sfc_main$9B = defineComponent({ name: 'Van', }) const _hoisted_1$7e = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5Q = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M128.896 736H96a32 32 0 0 1-32-32V224a32 32 0 0 1 32-32h576a32 32 0 0 1 32 32v96h164.544a32 32 0 0 1 31.616 27.136l54.144 352A32 32 0 0 1 922.688 736h-91.52a144 144 0 1 1-286.272 0H415.104a144 144 0 1 1-286.272 0zm23.36-64a143.872 143.872 0 0 1 239.488 0H568.32c17.088-25.6 42.24-45.376 71.744-55.808V256H128v416h24.256zm655.488 0h77.632l-19.648-128H704v64.896A144 144 0 0 1 807.744 672zm48.128-192-14.72-96H704v96h151.872zM688 832a80 80 0 1 0 0-160 80 80 0 0 0 0 160zm-416 0a80 80 0 1 0 0-160 80 80 0 0 0 0 160z', }, null, -1 ) const _hoisted_3$54 = [_hoisted_2$5Q] function _sfc_render$1Y(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7e, _hoisted_3$54) } var van = /* @__PURE__ */ _export_sfc$2(_sfc_main$9B, [ ['render', _sfc_render$1Y], ]) const _sfc_main$9A = defineComponent({ name: 'VideoCameraFilled', }) const _hoisted_1$7d = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5P = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm768 576 192-64v320l-192-64v96a32 32 0 0 1-32 32H96a32 32 0 0 1-32-32V480a32 32 0 0 1 32-32h640a32 32 0 0 1 32 32v96zM192 768v64h384v-64H192zm192-480a160 160 0 0 1 320 0 160 160 0 0 1-320 0zm64 0a96 96 0 1 0 192.064-.064A96 96 0 0 0 448 288zm-320 32a128 128 0 1 1 256.064.064A128 128 0 0 1 128 320zm64 0a64 64 0 1 0 128 0 64 64 0 0 0-128 0z', }, null, -1 ) const _hoisted_3$53 = [_hoisted_2$5P] function _sfc_render$1X(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7d, _hoisted_3$53) } var videoCameraFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$9A, [ ['render', _sfc_render$1X], ]) const _sfc_main$9z = defineComponent({ name: 'VideoCamera', }) const _hoisted_1$7c = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5O = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M704 768V256H128v512h576zm64-416 192-96v512l-192-96v128a32 32 0 0 1-32 32H96a32 32 0 0 1-32-32V224a32 32 0 0 1 32-32h640a32 32 0 0 1 32 32v128zm0 71.552v176.896l128 64V359.552l-128 64zM192 320h192v64H192v-64z', }, null, -1 ) const _hoisted_3$52 = [_hoisted_2$5O] function _sfc_render$1W(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7c, _hoisted_3$52) } var videoCamera = /* @__PURE__ */ _export_sfc$2(_sfc_main$9z, [ ['render', _sfc_render$1W], ]) const _sfc_main$9y = defineComponent({ name: 'VideoPause', }) const _hoisted_1$7b = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5N = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896zm0 832a384 384 0 0 0 0-768 384 384 0 0 0 0 768zm-96-544q32 0 32 32v256q0 32-32 32t-32-32V384q0-32 32-32zm192 0q32 0 32 32v256q0 32-32 32t-32-32V384q0-32 32-32z', }, null, -1 ) const _hoisted_3$51 = [_hoisted_2$5N] function _sfc_render$1V(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7b, _hoisted_3$51) } var videoPause = /* @__PURE__ */ _export_sfc$2(_sfc_main$9y, [ ['render', _sfc_render$1V], ]) const _sfc_main$9x = defineComponent({ name: 'VideoPlay', }) const _hoisted_1$7a = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5M = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896zm0 832a384 384 0 0 0 0-768 384 384 0 0 0 0 768zm-48-247.616L668.608 512 464 375.616v272.768zm10.624-342.656 249.472 166.336a48 48 0 0 1 0 79.872L474.624 718.272A48 48 0 0 1 400 678.336V345.6a48 48 0 0 1 74.624-39.936z', }, null, -1 ) const _hoisted_3$50 = [_hoisted_2$5M] function _sfc_render$1U(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$7a, _hoisted_3$50) } var videoPlay = /* @__PURE__ */ _export_sfc$2(_sfc_main$9x, [ ['render', _sfc_render$1U], ]) const _sfc_main$9w = defineComponent({ name: 'View', }) const _hoisted_1$79 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5L = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 160c320 0 512 352 512 352S832 864 512 864 0 512 0 512s192-352 512-352zm0 64c-225.28 0-384.128 208.064-436.8 288 52.608 79.872 211.456 288 436.8 288 225.28 0 384.128-208.064 436.8-288-52.608-79.872-211.456-288-436.8-288zm0 64a224 224 0 1 1 0 448 224 224 0 0 1 0-448zm0 64a160.192 160.192 0 0 0-160 160c0 88.192 71.744 160 160 160s160-71.808 160-160-71.744-160-160-160z', }, null, -1 ) const _hoisted_3$4$ = [_hoisted_2$5L] function _sfc_render$1T(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$79, _hoisted_3$4$) } var view = /* @__PURE__ */ _export_sfc$2(_sfc_main$9w, [ ['render', _sfc_render$1T], ]) const _sfc_main$9v = defineComponent({ name: 'WalletFilled', }) const _hoisted_1$78 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5K = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M688 512a112 112 0 1 0 0 224h208v160H128V352h768v160H688zm32 160h-32a48 48 0 0 1 0-96h32a48 48 0 0 1 0 96zm-80-544 128 160H384l256-160z', }, null, -1 ) const _hoisted_3$4_ = [_hoisted_2$5K] function _sfc_render$1S(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$78, _hoisted_3$4_) } var walletFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$9v, [ ['render', _sfc_render$1S], ]) const _sfc_main$9u = defineComponent({ name: 'Wallet', }) const _hoisted_1$77 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5J = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M640 288h-64V128H128v704h384v32a32 32 0 0 0 32 32H96a32 32 0 0 1-32-32V96a32 32 0 0 1 32-32h512a32 32 0 0 1 32 32v192z', }, null, -1 ) const _hoisted_3$4Z = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M128 320v512h768V320H128zm-32-64h832a32 32 0 0 1 32 32v576a32 32 0 0 1-32 32H96a32 32 0 0 1-32-32V288a32 32 0 0 1 32-32z', }, null, -1 ) const _hoisted_4$4a = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M704 640a64 64 0 1 1 0-128 64 64 0 0 1 0 128z', }, null, -1 ) const _hoisted_5$3I = [_hoisted_2$5J, _hoisted_3$4Z, _hoisted_4$4a] function _sfc_render$1R(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$77, _hoisted_5$3I) } var wallet = /* @__PURE__ */ _export_sfc$2(_sfc_main$9u, [ ['render', _sfc_render$1R], ]) const _sfc_main$9t = defineComponent({ name: 'WarningFilled', }) const _hoisted_1$76 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5I = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896zm0 192a58.432 58.432 0 0 0-58.24 63.744l23.36 256.384a35.072 35.072 0 0 0 69.76 0l23.296-256.384A58.432 58.432 0 0 0 512 256zm0 512a51.2 51.2 0 1 0 0-102.4 51.2 51.2 0 0 0 0 102.4z', }, null, -1 ) const _hoisted_3$4Y = [_hoisted_2$5I] function _sfc_render$1Q(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$76, _hoisted_3$4Y) } var warningFilled = /* @__PURE__ */ _export_sfc$2(_sfc_main$9t, [ ['render', _sfc_render$1Q], ]) const _sfc_main$9s = defineComponent({ name: 'Warning', }) const _hoisted_1$75 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5H = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 64a448 448 0 1 1 0 896 448 448 0 0 1 0-896zm0 832a384 384 0 0 0 0-768 384 384 0 0 0 0 768zm48-176a48 48 0 1 1-96 0 48 48 0 0 1 96 0zm-48-464a32 32 0 0 1 32 32v288a32 32 0 0 1-64 0V288a32 32 0 0 1 32-32z', }, null, -1 ) const _hoisted_3$4X = [_hoisted_2$5H] function _sfc_render$1P(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$75, _hoisted_3$4X) } var warning$1 = /* @__PURE__ */ _export_sfc$2(_sfc_main$9s, [ ['render', _sfc_render$1P], ]) const _sfc_main$9r = defineComponent({ name: 'Watch', }) const _hoisted_1$74 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5G = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M512 768a256 256 0 1 0 0-512 256 256 0 0 0 0 512zm0 64a320 320 0 1 1 0-640 320 320 0 0 1 0 640z', }, null, -1 ) const _hoisted_3$4W = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M480 352a32 32 0 0 1 32 32v160a32 32 0 0 1-64 0V384a32 32 0 0 1 32-32z', }, null, -1 ) const _hoisted_4$49 = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M480 512h128q32 0 32 32t-32 32H480q-32 0-32-32t32-32zm128-256V128H416v128h-64V64h320v192h-64zM416 768v128h192V768h64v192H352V768h64z', }, null, -1 ) const _hoisted_5$3H = [_hoisted_2$5G, _hoisted_3$4W, _hoisted_4$49] function _sfc_render$1O(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$74, _hoisted_5$3H) } var watch = /* @__PURE__ */ _export_sfc$2(_sfc_main$9r, [ ['render', _sfc_render$1O], ]) const _sfc_main$9q = defineComponent({ name: 'Watermelon', }) const _hoisted_1$73 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5F = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm683.072 600.32-43.648 162.816-61.824-16.512 53.248-198.528L576 493.248l-158.4 158.4-45.248-45.248 158.4-158.4-55.616-55.616-198.528 53.248-16.512-61.824 162.816-43.648L282.752 200A384 384 0 0 0 824 741.248L683.072 600.32zm231.552 141.056a448 448 0 1 1-632-632l632 632z', }, null, -1 ) const _hoisted_3$4V = [_hoisted_2$5F] function _sfc_render$1N(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$73, _hoisted_3$4V) } var watermelon = /* @__PURE__ */ _export_sfc$2(_sfc_main$9q, [ ['render', _sfc_render$1N], ]) const _sfc_main$9p = defineComponent({ name: 'WindPower', }) const _hoisted_1$72 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5E = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'M160 64q32 0 32 32v832q0 32-32 32t-32-32V96q0-32 32-32zm416 354.624 128-11.584V168.96l-128-11.52v261.12zm-64 5.824V151.552L320 134.08V160h-64V64l616.704 56.064A96 96 0 0 1 960 215.68v144.64a96 96 0 0 1-87.296 95.616L256 512V224h64v217.92l192-17.472zm256-23.232 98.88-8.96A32 32 0 0 0 896 360.32V215.68a32 32 0 0 0-29.12-31.872l-98.88-8.96v226.368z', }, null, -1 ) const _hoisted_3$4U = [_hoisted_2$5E] function _sfc_render$1M(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$72, _hoisted_3$4U) } var windPower = /* @__PURE__ */ _export_sfc$2(_sfc_main$9p, [ ['render', _sfc_render$1M], ]) const _sfc_main$9o = defineComponent({ name: 'ZoomIn', }) const _hoisted_1$71 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5D = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm795.904 750.72 124.992 124.928a32 32 0 0 1-45.248 45.248L750.656 795.904a416 416 0 1 1 45.248-45.248zM480 832a352 352 0 1 0 0-704 352 352 0 0 0 0 704zm-32-384v-96a32 32 0 0 1 64 0v96h96a32 32 0 0 1 0 64h-96v96a32 32 0 0 1-64 0v-96h-96a32 32 0 0 1 0-64h96z', }, null, -1 ) const _hoisted_3$4T = [_hoisted_2$5D] function _sfc_render$1L(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$71, _hoisted_3$4T) } var zoomIn = /* @__PURE__ */ _export_sfc$2(_sfc_main$9o, [ ['render', _sfc_render$1L], ]) const _sfc_main$9n = defineComponent({ name: 'ZoomOut', }) const _hoisted_1$70 = { viewBox: '0 0 1024 1024', xmlns: 'http://www.w3.org/2000/svg', } const _hoisted_2$5C = /* @__PURE__ */ createElementVNode( 'path', { fill: 'currentColor', d: 'm795.904 750.72 124.992 124.928a32 32 0 0 1-45.248 45.248L750.656 795.904a416 416 0 1 1 45.248-45.248zM480 832a352 352 0 1 0 0-704 352 352 0 0 0 0 704zM352 448h256a32 32 0 0 1 0 64H352a32 32 0 0 1 0-64z', }, null, -1 ) const _hoisted_3$4S = [_hoisted_2$5C] function _sfc_render$1K(_ctx, _cache, $props2, $setup, $data, $options) { return openBlock(), createElementBlock('svg', _hoisted_1$70, _hoisted_3$4S) } var zoomOut = /* @__PURE__ */ _export_sfc$2(_sfc_main$9n, [ ['render', _sfc_render$1K], ]) var index$s = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, AddLocation: addLocation, Aim: aim, AlarmClock: alarmClock, Apple: apple, ArrowDownBold: arrowDownBold, ArrowDown: arrowDown, ArrowLeftBold: arrowLeftBold, ArrowLeft: arrowLeft, ArrowRightBold: arrowRightBold, ArrowRight: arrowRight, ArrowUpBold: arrowUpBold, ArrowUp: arrowUp, Avatar: avatar, Back: back$1, Baseball: baseball, Basketball: basketball, BellFilled: bellFilled, Bell: bell, Bicycle: bicycle, BottomLeft: bottomLeft, BottomRight: bottomRight, Bottom: bottom$1, Bowl: bowl, Box: box$1, Briefcase: briefcase, BrushFilled: brushFilled, Brush: brush$2, Burger: burger, Calendar: calendar, CameraFilled: cameraFilled, Camera: camera, CaretBottom: caretBottom, CaretLeft: caretLeft, CaretRight: caretRight, CaretTop: caretTop, Cellphone: cellphone, ChatDotRound: chatDotRound, ChatDotSquare: chatDotSquare, ChatLineRound: chatLineRound, ChatLineSquare: chatLineSquare, ChatRound: chatRound, ChatSquare: chatSquare, Check: check$1, Checked: checked, Cherry: cherry, Chicken: chicken, CircleCheckFilled: circleCheckFilled, CircleCheck: circleCheck, CircleCloseFilled: circleCloseFilled, CircleClose: circleClose, CirclePlusFilled: circlePlusFilled, CirclePlus: circlePlus, Clock: clock, CloseBold: closeBold, Close: close$2, Cloudy: cloudy, CoffeeCup: coffeeCup, Coffee: coffee, Coin: coin, ColdDrink: coldDrink, CollectionTag: collectionTag, Collection: collection, Comment: comment, Compass: compass, Connection: connection, Coordinate: coordinate, CopyDocument: copyDocument, Cpu: cpu, CreditCard: creditCard, Crop: crop, DArrowLeft: dArrowLeft, DArrowRight: dArrowRight, DCaret: dCaret, DataAnalysis: dataAnalysis, DataBoard: dataBoard, DataLine: dataLine, DeleteFilled: deleteFilled, DeleteLocation: deleteLocation, Delete: _delete, Dessert: dessert, Discount: discount, DishDot: dishDot, Dish: dish, DocumentAdd: documentAdd, DocumentChecked: documentChecked, DocumentCopy: documentCopy, DocumentDelete: documentDelete, DocumentRemove: documentRemove, Document: document$4, Download: download$1, Drizzling: drizzling, EditPen: editPen, Edit: edit, ElemeFilled: elemeFilled, Eleme: eleme, ElementPlus: elementPlus, Expand: expand, Failed: failed, Female: female, Files: files$1, Film: film, Filter: filter$3, Finished: finished, FirstAidKit: firstAidKit, Flag: flag, Fold: fold, FolderAdd: folderAdd, FolderChecked: folderChecked, FolderDelete: folderDelete, FolderOpened: folderOpened, FolderRemove: folderRemove, Folder: folder, Food: food, Football: football, ForkSpoon: forkSpoon, Fries: fries, FullScreen: fullScreen, GobletFull: gobletFull, GobletSquareFull: gobletSquareFull, GobletSquare: gobletSquare, Goblet: goblet, GoodsFilled: goodsFilled, Goods: goods, Grape: grape, Grid: grid, Guide: guide, Headset: headset, HelpFilled: helpFilled, Help: help, Hide: hide$2, Histogram: histogram, HomeFilled: homeFilled, HotWater: hotWater, House: house, IceCreamRound: iceCreamRound, IceCreamSquare: iceCreamSquare, IceCream: iceCream, IceDrink: iceDrink, IceTea: iceTea, InfoFilled: infoFilled, Iphone: iphone, Key: key, KnifeFork: knifeFork, Lightning: lightning, Link: link, List: list, Loading: loading, LocationFilled: locationFilled, LocationInformation: locationInformation, Location: location$1, Lock: lock, Lollipop: lollipop, MagicStick: magicStick, Magnet: magnet, Male: male, Management: management, MapLocation: mapLocation, Medal: medal, Menu: menu, MessageBox: messageBox, Message: message$1, Mic: mic, Microphone: microphone, MilkTea: milkTea, Minus: minus, Money: money, Monitor: monitor, MoonNight: moonNight, Moon: moon, MoreFilled: moreFilled, More: more, MostlyCloudy: mostlyCloudy, Mouse: mouse, Mug: mug, MuteNotification: muteNotification, Mute: mute, NoSmoking: noSmoking, Notebook: notebook, Notification: notification, Odometer: odometer, OfficeBuilding: officeBuilding, Open: open$1, Operation: operation, Opportunity: opportunity, Orange: orange, Paperclip: paperclip, PartlyCloudy: partlyCloudy, Pear: pear, PhoneFilled: phoneFilled, Phone: phone, PictureFilled: pictureFilled, PictureRounded: pictureRounded, Picture: picture, PieChart: pieChart, Place: place$1, Platform: platform$1, Plus: plus, Pointer: pointer, Position: position$2, Postcard: postcard, Pouring: pouring, Present: present, PriceTag: priceTag, Printer: printer, Promotion: promotion, QuestionFilled: questionFilled, Rank: rank, ReadingLamp: readingLamp, Reading: reading, RefreshLeft: refreshLeft, RefreshRight: refreshRight, Refresh: refresh, Refrigerator: refrigerator, RemoveFilled: removeFilled, Remove: remove$3, Right: right$1, ScaleToOriginal: scaleToOriginal, School: school, Scissor: scissor, Search: search, Select: select$1, Sell: sell, SemiSelect: semiSelect, Service: service$1, SetUp: setUp, Setting: setting, Share: share, Ship: ship, Shop: shop, ShoppingBag: shoppingBag, ShoppingCartFull: shoppingCartFull, ShoppingCart: shoppingCart, Smoking: smoking, Soccer: soccer, SoldOut: soldOut, SortDown: sortDown, SortUp: sortUp, Sort: sort$3, Stamp: stamp, StarFilled: starFilled, Star: star, Stopwatch: stopwatch, SuccessFilled: successFilled, Sugar: sugar, Suitcase: suitcase, Sunny: sunny, Sunrise: sunrise, Sunset: sunset, SwitchButton: switchButton, Switch: _switch, TakeawayBox: takeawayBox, Ticket: ticket, Tickets: tickets, Timer: timer, ToiletPaper: toiletPaper, Tools: tools, TopLeft: topLeft, TopRight: topRight, Top: top$1, TrendCharts: trendCharts, Trophy: trophy, TurnOff: turnOff, Umbrella: umbrella, Unlock: unlock, UploadFilled: uploadFilled, Upload: upload, UserFilled: userFilled, User: user, Van: van, VideoCameraFilled: videoCameraFilled, VideoCamera: videoCamera, VideoPause: videoPause, VideoPlay: videoPlay, View: view, WalletFilled: walletFilled, Wallet: wallet, WarningFilled: warningFilled, Warning: warning$1, Watch: watch, Watermelon: watermelon, WindPower: windPower, ZoomIn: zoomIn, ZoomOut: zoomOut, }, Symbol.toStringTag, { value: 'Module' } ) ) const wrapperKey = Symbol() const propKey = '__elPropsReservedKey' function buildProp(option2, key2) { if (!isObject$v(option2) || !!option2[propKey]) return option2 const { values: values2, required: required4, default: defaultValue, type: type4, validator: validator2, } = option2 const _validator = values2 || validator2 ? (val2) => { let valid = false let allowedValues = [] if (values2) { allowedValues = Array.from(values2) if (hasOwn$e(option2, 'default')) { allowedValues.push(defaultValue) } valid || (valid = allowedValues.includes(val2)) } if (validator2) valid || (valid = validator2(val2)) if (!valid && allowedValues.length > 0) { const allowValuesText = [...new Set(allowedValues)] .map((value2) => JSON.stringify(value2)) .join(', ') warn$2( `Invalid prop: validation failed${ key2 ? ` for prop "${key2}"` : '' }. Expected one of [${allowValuesText}], got value ${JSON.stringify( val2 )}.` ) } return valid } : void 0 const prop = { type: isObject$v(type4) && Object.getOwnPropertySymbols(type4).includes(wrapperKey) ? type4[wrapperKey] : type4, required: !!required4, validator: _validator, [propKey]: true, } if (hasOwn$e(option2, 'default')) prop.default = defaultValue return prop } const buildProps = (props2) => fromPairs( Object.entries(props2).map(([key2, option2]) => [ key2, buildProp(option2, key2), ]) ) const definePropType = (val2) => ({ [wrapperKey]: val2 }) const iconPropType = definePropType([String, Object, Function]) const CloseComponents = { Close: close$2, } const TypeComponents = { Close: close$2, SuccessFilled: successFilled, InfoFilled: infoFilled, WarningFilled: warningFilled, CircleCloseFilled: circleCloseFilled, } const TypeComponentsMap = { success: successFilled, warning: warningFilled, error: circleCloseFilled, info: infoFilled, } const ValidateComponentsMap = { validating: loading, success: circleCheck, error: circleClose, } const withInstall = (main2, extra) => { main2.install = (app2) => { for (const comp of [main2, ...Object.values(extra != null ? extra : {})]) { app2.component(comp.name, comp) } } if (extra) { for (const [key2, comp] of Object.entries(extra)) { main2[key2] = comp } } return main2 } const withInstallFunction = (fn2, name2) => { fn2.install = (app2) => { fn2._context = app2._context app2.config.globalProperties[name2] = fn2 } return fn2 } const withNoopInstall = (component2) => { component2.install = NOOP return component2 } const composeRefs = (...refs) => { return (el2) => { refs.forEach((ref2) => { if (isFunction$l(ref2)) { ref2(el2) } else { ref2.value = el2 } }) } } class ElementPlusError extends Error { constructor(m2) { super(m2) this.name = 'ElementPlusError' } } function throwError$1(scope, m2) { throw new ElementPlusError(`[${scope}] ${m2}`) } function debugWarn(scope, message2) {} function addUnit(value2, defaultUnit = 'px') { if (!value2) return '' if (isString$f(value2)) { return value2 } else if (isNumber$h(value2)) { return `${value2}${defaultUnit}` } } const EVENT_CODE = { tab: 'Tab', enter: 'Enter', space: 'Space', left: 'ArrowLeft', up: 'ArrowUp', right: 'ArrowRight', down: 'ArrowDown', esc: 'Escape', delete: 'Delete', backspace: 'Backspace', numpadEnter: 'NumpadEnter', pageUp: 'PageUp', pageDown: 'PageDown', home: 'Home', end: 'End', } const datePickTypes = [ 'year', 'month', 'date', 'dates', 'week', 'datetime', 'datetimerange', 'daterange', 'monthrange', ] const WEEK_DAYS = ['sun', 'mon', 'tue', 'wed', 'thu', 'fri', 'sat'] const UPDATE_MODEL_EVENT = 'update:modelValue' const CHANGE_EVENT = 'change' const INPUT_EVENT = 'input' const componentSizes = ['', 'default', 'small', 'large'] const isValidComponentSize = (val2) => ['', ...componentSizes].includes(val2) const isValidDatePickType = (val2) => [...datePickTypes].includes(val2) var PatchFlags = /* @__PURE__ */ ((PatchFlags2) => { PatchFlags2[(PatchFlags2['TEXT'] = 1)] = 'TEXT' PatchFlags2[(PatchFlags2['CLASS'] = 2)] = 'CLASS' PatchFlags2[(PatchFlags2['STYLE'] = 4)] = 'STYLE' PatchFlags2[(PatchFlags2['PROPS'] = 8)] = 'PROPS' PatchFlags2[(PatchFlags2['FULL_PROPS'] = 16)] = 'FULL_PROPS' PatchFlags2[(PatchFlags2['HYDRATE_EVENTS'] = 32)] = 'HYDRATE_EVENTS' PatchFlags2[(PatchFlags2['STABLE_FRAGMENT'] = 64)] = 'STABLE_FRAGMENT' PatchFlags2[(PatchFlags2['KEYED_FRAGMENT'] = 128)] = 'KEYED_FRAGMENT' PatchFlags2[(PatchFlags2['UNKEYED_FRAGMENT'] = 256)] = 'UNKEYED_FRAGMENT' PatchFlags2[(PatchFlags2['NEED_PATCH'] = 512)] = 'NEED_PATCH' PatchFlags2[(PatchFlags2['DYNAMIC_SLOTS'] = 1024)] = 'DYNAMIC_SLOTS' PatchFlags2[(PatchFlags2['HOISTED'] = -1)] = 'HOISTED' PatchFlags2[(PatchFlags2['BAIL'] = -2)] = 'BAIL' return PatchFlags2 })(PatchFlags || {}) function isFragment(node2) { return isVNode$1(node2) && node2.type === Fragment } function isComment(node2) { return isVNode$1(node2) && node2.type === Comment } function isValidElementNode(node2) { return isVNode$1(node2) && !isFragment(node2) && !isComment(node2) } const getNormalizedProps = (node2) => { if (!isVNode$1(node2)) { return {} } const raw = node2.props || {} const type4 = (isVNode$1(node2.type) ? node2.type.props : void 0) || {} const props2 = {} Object.keys(type4).forEach((key2) => { if (hasOwn$e(type4[key2], 'default')) { props2[key2] = type4[key2].default } }) Object.keys(raw).forEach((key2) => { props2[camelize$1(key2)] = raw[key2] }) return props2 } const ensureOnlyChild = (children) => { if (!isArray$D(children) || children.length > 1) { throw new Error('expect to receive a single Vue element child') } return children[0] } const cubic = (value2) => value2 ** 3 const easeInOutCubic = (value2) => value2 < 0.5 ? cubic(value2 * 2) / 2 : 1 - cubic((1 - value2) * 2) / 2 const unique = (arr) => [...new Set(arr)] const castArray = (arr) => { if (!arr && arr !== 0) return [] return Array.isArray(arr) ? arr : [arr] } const isFirefox = () => isClient$1 && /firefox/i.test(window.navigator.userAgent) const isKorean = (text2) => /([(\uAC00-\uD7AF)|(\u3130-\u318F)])+/gi.test(text2) const rAF = (fn2) => isClient$1 ? window.requestAnimationFrame(fn2) : setTimeout(fn2, 16) const cAF = (handle) => isClient$1 ? window.cancelAnimationFrame(handle) : clearTimeout(handle) const generateId = () => Math.floor(Math.random() * 1e4) const mutable = (val2) => val2 const DEFAULT_EXCLUDE_KEYS = ['class', 'style'] const LISTENER_PREFIX = /^on[A-Z]/ const useAttrs = (params2 = {}) => { const { excludeListeners = false, excludeKeys = [] } = params2 const allExcludeKeys = excludeKeys.concat(DEFAULT_EXCLUDE_KEYS) const instance = getCurrentInstance() if (!instance) { return computed(() => ({})) } return computed(() => { var _a2 return fromPairs( Object.entries( (_a2 = instance.proxy) == null ? void 0 : _a2.$attrs ).filter( ([key2]) => !allExcludeKeys.includes(key2) && !(excludeListeners && LISTENER_PREFIX.test(key2)) ) ) }) } const breadcrumbKey = Symbol('breadcrumbKey') const buttonGroupContextKey = Symbol('buttonGroupContextKey') const carouselContextKey = Symbol('carouselContextKey') const collapseContextKey = Symbol('collapseContextKey') const configProviderContextKey = Symbol() const dialogInjectionKey = Symbol('dialogInjectionKey') const formContextKey = Symbol('formContextKey') const formItemContextKey = Symbol('formItemContextKey') const elPaginationKey = Symbol('elPaginationKey') const radioGroupKey = Symbol('radioGroupKey') const rowContextKey = Symbol('rowContextKey') const scrollbarContextKey = Symbol('scrollbarContextKey') const tabsRootContextKey = Symbol('tabsRootContextKey') const uploadContextKey = Symbol('uploadContextKey') const POPPER_INJECTION_KEY = Symbol('popper') const POPPER_CONTENT_INJECTION_KEY = Symbol('popperContent') const tooltipV2RootKey = Symbol('tooltipV2') const tooltipV2ContentKey = Symbol('tooltipV2Content') const TOOLTIP_V2_OPEN = 'tooltip_v2.open' const useProp = (name2) => { const vm = getCurrentInstance() return computed(() => { var _a2, _b2 return (_b2 = (_a2 = vm.proxy) == null ? void 0 : _a2.$props[name2]) != null ? _b2 : void 0 }) } const globalConfig = ref() function useGlobalConfig(key2, defaultValue = void 0) { const config2 = getCurrentInstance() ? inject(configProviderContextKey, globalConfig) : globalConfig if (key2) { return computed(() => { var _a2, _b2 return (_b2 = (_a2 = config2.value) == null ? void 0 : _a2[key2]) != null ? _b2 : defaultValue }) } else { return config2 } } const provideGlobalConfig = (config2, app2, global2 = false) => { var _a2 const inSetup = !!getCurrentInstance() const oldConfig = inSetup ? useGlobalConfig() : void 0 const provideFn = (_a2 = app2 == null ? void 0 : app2.provide) != null ? _a2 : inSetup ? provide : void 0 if (!provideFn) { return } const context2 = computed(() => { const cfg = unref(config2) if (!(oldConfig == null ? void 0 : oldConfig.value)) return cfg return mergeConfig$3(oldConfig.value, cfg) }) provideFn(configProviderContextKey, context2) if (global2 || !globalConfig.value) { globalConfig.value = context2.value } return context2 } const mergeConfig$3 = (a2, b2) => { var _a2 const keys3 = [.../* @__PURE__ */ new Set([...keysOf(a2), ...keysOf(b2)])] const obj = {} for (const key2 of keys3) { obj[key2] = (_a2 = b2[key2]) != null ? _a2 : a2[key2] } return obj } const useSizeProp = buildProp({ type: String, values: componentSizes, required: false, }) const useSize$1 = (fallback, ignore = {}) => { const emptyRef = ref(void 0) const size = ignore.prop ? emptyRef : useProp('size') const globalConfig2 = ignore.global ? emptyRef : useGlobalConfig('size') const form2 = ignore.form ? { size: void 0 } : inject(formContextKey, void 0) const formItem = ignore.formItem ? { size: void 0 } : inject(formItemContextKey, void 0) return computed( () => size.value || unref(fallback) || (formItem == null ? void 0 : formItem.size) || (form2 == null ? void 0 : form2.size) || globalConfig2.value || '' ) } const useDisabled$1 = (fallback) => { const disabled = useProp('disabled') const form2 = inject(formContextKey, void 0) return computed( () => disabled.value || unref(fallback) || (form2 == null ? void 0 : form2.disabled) || false ) } const useDeprecated = ( { from, replacement: replacement2, scope, version: version2, ref: ref2, type: type4 = 'API', }, condition2 ) => { watch$1( () => unref(condition2), (val2) => {}, { immediate: true, } ) } const useDraggable$1 = (targetRef, dragRef, draggable2) => { let transform3 = { offsetX: 0, offsetY: 0, } const onMousedown = (e2) => { const downX = e2.clientX const downY = e2.clientY const { offsetX, offsetY } = transform3 const targetRect = targetRef.value.getBoundingClientRect() const targetLeft = targetRect.left const targetTop = targetRect.top const targetWidth = targetRect.width const targetHeight = targetRect.height const clientWidth = document.documentElement.clientWidth const clientHeight = document.documentElement.clientHeight const minLeft = -targetLeft + offsetX const minTop = -targetTop + offsetY const maxLeft = clientWidth - targetLeft - targetWidth + offsetX const maxTop = clientHeight - targetTop - targetHeight + offsetY const onMousemove = (e22) => { const moveX = Math.min( Math.max(offsetX + e22.clientX - downX, minLeft), maxLeft ) const moveY = Math.min( Math.max(offsetY + e22.clientY - downY, minTop), maxTop ) transform3 = { offsetX: moveX, offsetY: moveY, } targetRef.value.style.transform = `translate(${addUnit(moveX)}, ${addUnit( moveY )})` } const onMouseup = () => { document.removeEventListener('mousemove', onMousemove) document.removeEventListener('mouseup', onMouseup) } document.addEventListener('mousemove', onMousemove) document.addEventListener('mouseup', onMouseup) } const onDraggable = () => { if (dragRef.value && targetRef.value) { dragRef.value.addEventListener('mousedown', onMousedown) } } const offDraggable = () => { if (dragRef.value && targetRef.value) { dragRef.value.removeEventListener('mousedown', onMousedown) } } onMounted(() => { watchEffect(() => { if (draggable2.value) { onDraggable() } else { offDraggable() } }) }) onBeforeUnmount(() => { offDraggable() }) } const useFocus$1 = (el2) => { return { focus: () => { var _a2, _b2 ;(_b2 = (_a2 = el2.value) == null ? void 0 : _a2.focus) == null ? void 0 : _b2.call(_a2) }, } } const useFormItem = () => { const form2 = inject(formContextKey, void 0) const formItem = inject(formItemContextKey, void 0) return { form: form2, formItem, } } var English = { name: 'en', el: { colorpicker: { confirm: 'OK', clear: 'Clear', }, datepicker: { now: 'Now', today: 'Today', cancel: 'Cancel', clear: 'Clear', confirm: 'OK', selectDate: 'Select date', selectTime: 'Select time', startDate: 'Start Date', startTime: 'Start Time', endDate: 'End Date', endTime: 'End Time', prevYear: 'Previous Year', nextYear: 'Next Year', prevMonth: 'Previous Month', nextMonth: 'Next Month', year: '', month1: 'January', month2: 'February', month3: 'March', month4: 'April', month5: 'May', month6: 'June', month7: 'July', month8: 'August', month9: 'September', month10: 'October', month11: 'November', month12: 'December', week: 'week', weeks: { sun: 'Sun', mon: 'Mon', tue: 'Tue', wed: 'Wed', thu: 'Thu', fri: 'Fri', sat: 'Sat', }, months: { jan: 'Jan', feb: 'Feb', mar: 'Mar', apr: 'Apr', may: 'May', jun: 'Jun', jul: 'Jul', aug: 'Aug', sep: 'Sep', oct: 'Oct', nov: 'Nov', dec: 'Dec', }, }, select: { loading: 'Loading', noMatch: 'No matching data', noData: 'No data', placeholder: 'Select', }, cascader: { noMatch: 'No matching data', loading: 'Loading', placeholder: 'Select', noData: 'No data', }, pagination: { goto: 'Go to', pagesize: '/page', total: 'Total {total}', pageClassifier: '', deprecationWarning: 'Deprecated usages detected, please refer to the el-pagination documentation for more details', }, messagebox: { title: 'Message', confirm: 'OK', cancel: 'Cancel', error: 'Illegal input', }, upload: { deleteTip: 'press delete to remove', delete: 'Delete', preview: 'Preview', continue: 'Continue', }, table: { emptyText: 'No Data', confirmFilter: 'Confirm', resetFilter: 'Reset', clearFilter: 'All', sumText: 'Sum', }, tree: { emptyText: 'No Data', }, transfer: { noMatch: 'No matching data', noData: 'No data', titles: ['List 1', 'List 2'], filterPlaceholder: 'Enter keyword', noCheckedFormat: '{total} items', hasCheckedFormat: '{checked}/{total} checked', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_10 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: English, }, Symbol.toStringTag, { value: 'Module' } ) ) const buildTranslator = (locale) => (path, option2) => translate$2(path, option2, unref(locale)) const translate$2 = (path, option2, locale) => get$a(locale, path, path).replace(/\{(\w+)\}/g, (_2, key2) => { var _a2 return `${ (_a2 = option2 == null ? void 0 : option2[key2]) != null ? _a2 : `{${key2}}` }` }) const buildLocaleContext = (locale) => { const lang = computed(() => unref(locale).name) const localeRef = isRef(locale) ? locale : ref(locale) return { lang, locale: localeRef, t: buildTranslator(locale), } } const useLocale = () => { const locale = useGlobalConfig('locale') return buildLocaleContext(computed(() => locale.value || English)) } const useLockscreen = (trigger2) => { if (!isRef(trigger2)) { throwError$1( '[useLockscreen]', 'You need to pass a ref param to this function' ) } if (!isClient$1 || hasClass$1(document.body, 'el-popup-parent--hidden')) { return } let scrollBarWidth2 = 0 let withoutHiddenClass = false let bodyPaddingRight = '0' let computedBodyPaddingRight = 0 const cleanup = () => { removeClass$1(document.body, 'el-popup-parent--hidden') if (withoutHiddenClass) { document.body.style.paddingRight = bodyPaddingRight } } watch$1(trigger2, (val2) => { if (!val2) { cleanup() return } withoutHiddenClass = !hasClass$1(document.body, 'el-popup-parent--hidden') if (withoutHiddenClass) { bodyPaddingRight = document.body.style.paddingRight computedBodyPaddingRight = Number.parseInt( getStyle$1(document.body, 'paddingRight'), 10 ) } scrollBarWidth2 = getScrollBarWidth() const bodyHasOverflow = document.documentElement.clientHeight < document.body.scrollHeight const bodyOverflowY = getStyle$1(document.body, 'overflowY') if ( scrollBarWidth2 > 0 && (bodyHasOverflow || bodyOverflowY === 'scroll') && withoutHiddenClass ) { document.body.style.paddingRight = `${ computedBodyPaddingRight + scrollBarWidth2 }px` } addClass$1(document.body, 'el-popup-parent--hidden') }) onScopeDispose(() => cleanup()) } const modalStack = [] const closeModal$1 = (e2) => { if (modalStack.length === 0) return if (e2.code === EVENT_CODE.esc) { e2.stopPropagation() const topModal = modalStack[modalStack.length - 1] topModal.handleClose() } } const useModal = (instance, visibleRef) => { watch$1(visibleRef, (val2) => { if (val2) { modalStack.push(instance) } else { modalStack.splice(modalStack.indexOf(instance), 1) } }) } if (isClient$1) useEventListener$1(document, 'keydown', closeModal$1) const _prop = buildProp({ type: definePropType(Boolean), default: null, }) const _event = buildProp({ type: definePropType(Function), }) const createModelToggleComposable = (name2) => { const useModelToggleProps2 = { [name2]: _prop, [`onUpdate:${name2}`]: _event, } const useModelToggleEmits2 = [`update:${name2}`] const useModelToggle2 = ({ indicator, shouldHideWhenRouteChanges, shouldProceed, onShow, onHide, }) => { const instance = getCurrentInstance() const props2 = instance.props const { emit: emit2 } = instance const updateEventKey = `update:${name2}` const hasUpdateHandler = computed(() => isFunction$l(props2[`onUpdate:${name2}`]) ) const isModelBindingAbsent = computed(() => props2[name2] === null) const doShow = () => { if (indicator.value === true) { return } indicator.value = true if (isFunction$l(onShow)) { onShow() } } const doHide = () => { if (indicator.value === false) { return } indicator.value = false if (isFunction$l(onHide)) { onHide() } } const show = () => { if ( props2.disabled === true || (isFunction$l(shouldProceed) && !shouldProceed()) ) return const shouldEmit = hasUpdateHandler.value && isClient$1 if (shouldEmit) { emit2(updateEventKey, true) } if (isModelBindingAbsent.value || !shouldEmit) { doShow() } } const hide2 = () => { if (props2.disabled === true || !isClient$1) return const shouldEmit = hasUpdateHandler.value && isClient$1 if (shouldEmit) { emit2(updateEventKey, false) } if (isModelBindingAbsent.value || !shouldEmit) { doHide() } } const onChange = (val2) => { if (!isBoolean$5(val2)) return if (props2.disabled && val2) { if (hasUpdateHandler.value) { emit2(updateEventKey, false) } } else if (indicator.value !== val2) { if (val2) { doShow() } else { doHide() } } } const toggle2 = () => { if (indicator.value) { hide2() } else { show() } } watch$1(() => props2[name2], onChange) if ( shouldHideWhenRouteChanges && instance.appContext.config.globalProperties.$route !== void 0 ) { watch$1( () => ({ ...instance.proxy.$route, }), () => { if (shouldHideWhenRouteChanges.value && indicator.value) { hide2() } } ) } onMounted(() => { onChange(props2[name2]) }) return { hide: hide2, show, toggle: toggle2, } } return { useModelToggle: useModelToggle2, useModelToggleProps: useModelToggleProps2, useModelToggleEmits: useModelToggleEmits2, } } const { useModelToggle: useModelToggle$1, useModelToggleProps: useModelToggleProps$1, useModelToggleEmits: useModelToggleEmits$1, } = createModelToggleComposable('modelValue') const usePreventGlobal = (indicator, evt, cb) => { const prevent = (e2) => { if (cb(e2)) e2.stopImmediatePropagation() } let stop2 = void 0 watch$1( () => indicator.value, (val2) => { if (val2) { stop2 = useEventListener$1(document, evt, prevent, true) } else { stop2 == null ? void 0 : stop2() } }, { immediate: true } ) } const useRestoreActive = (toggle2, initialFocus) => { let previousActive watch$1( () => toggle2.value, (val2) => { var _a2, _b2 if (val2) { previousActive = document.activeElement if (isRef(initialFocus)) { ;(_b2 = (_a2 = initialFocus.value).focus) == null ? void 0 : _b2.call(_a2) } } else { { previousActive.focus() } } } ) } const useSameTarget = (handleClick2) => { if (!handleClick2) { return { onClick: NOOP, onMousedown: NOOP, onMouseup: NOOP } } let mousedownTarget = false let mouseupTarget = false const onClick = (e2) => { if (mousedownTarget && mouseupTarget) { handleClick2(e2) } mousedownTarget = mouseupTarget = false } const onMousedown = (e2) => { mousedownTarget = e2.target === e2.currentTarget } const onMouseup = (e2) => { mouseupTarget = e2.target === e2.currentTarget } return { onClick, onMousedown, onMouseup } } const useTeleport = (contentRenderer, appendToBody) => { const isTeleportVisible = ref(false) if (!isClient$1) { return { isTeleportVisible, showTeleport: NOOP, hideTeleport: NOOP, renderTeleport: NOOP, } } let $el = null const showTeleport = () => { isTeleportVisible.value = true if ($el !== null) return $el = createGlobalNode() } const hideTeleport = () => { isTeleportVisible.value = false if ($el !== null) { removeGlobalNode($el) $el = null } } const renderTeleport = () => { return appendToBody.value !== true ? contentRenderer() : isTeleportVisible.value ? [h$4(Teleport, { to: $el }, contentRenderer())] : void 0 } onUnmounted(hideTeleport) return { isTeleportVisible, showTeleport, hideTeleport, renderTeleport, } } const useThrottleRender = (loading2, throttle2 = 0) => { if (throttle2 === 0) return loading2 const throttled = ref(false) let timeoutHandle = 0 const dispatchThrottling = () => { if (timeoutHandle) { clearTimeout(timeoutHandle) } timeoutHandle = window.setTimeout(() => { throttled.value = loading2.value }, throttle2) } onMounted(dispatchThrottling) watch$1( () => loading2.value, (val2) => { if (val2) { dispatchThrottling() } else { throttled.value = val2 } } ) return throttled } function useTimeout$1() { let timeoutHandle const registerTimeout = (fn2, delay2) => { cancelTimeout() timeoutHandle = window.setTimeout(fn2, delay2) } const cancelTimeout = () => window.clearTimeout(timeoutHandle) tryOnScopeDispose$1(() => cancelTimeout()) return { registerTimeout, cancelTimeout, } } const AFTER_APPEAR = 'after-appear' const AFTER_ENTER = 'after-enter' const AFTER_LEAVE = 'after-leave' const APPEAR = 'appear' const APPEAR_CANCELLED = 'appear-cancelled' const BEFORE_ENTER = 'before-enter' const BEFORE_LEAVE = 'before-leave' const ENTER = 'enter' const ENTER_CANCELLED = 'enter-cancelled' const LEAVE = 'leave' const LEAVE_CANCELLED = 'leave-cancelled' const useTransitionFallthroughEmits = [ AFTER_APPEAR, AFTER_ENTER, AFTER_LEAVE, APPEAR, APPEAR_CANCELLED, BEFORE_ENTER, BEFORE_LEAVE, ENTER, ENTER_CANCELLED, LEAVE, LEAVE_CANCELLED, ] const useTransitionFallthrough = () => { const { emit: emit2 } = getCurrentInstance() return { onAfterAppear: () => { emit2(AFTER_APPEAR) }, onAfterEnter: () => { emit2(AFTER_ENTER) }, onAfterLeave: () => { emit2(AFTER_LEAVE) }, onAppearCancelled: () => { emit2(APPEAR_CANCELLED) }, onBeforeEnter: () => { emit2(BEFORE_ENTER) }, onBeforeLeave: () => { emit2(BEFORE_LEAVE) }, onEnter: () => { emit2(ENTER) }, onEnterCancelled: () => { emit2(ENTER_CANCELLED) }, onLeave: () => { emit2(LEAVE) }, onLeaveCancelled: () => { emit2(LEAVE_CANCELLED) }, } } const defaultIdInjection = { prefix: Math.floor(Math.random() * 1e4), current: 0, } const ID_INJECTION_KEY = Symbol('elIdInjection') const useId = (deterministicId) => { const idInjection = inject(ID_INJECTION_KEY, defaultIdInjection) const idRef = computed( () => unref(deterministicId) || `el-id-${idInjection.prefix}-${idInjection.current++}` ) return idRef } const useEscapeKeydown = (handler) => { const cachedHandler = (e2) => { const event = e2 if (event.key === EVENT_CODE.esc) { handler == null ? void 0 : handler(event) } } onMounted(() => { on$2(document, 'keydown', cachedHandler) }) onBeforeUnmount(() => { off$1(document, 'keydown', cachedHandler) }) } let cachedContainer const POPPER_CONTAINER_ID = `el-popper-container-${generateId()}` const POPPER_CONTAINER_SELECTOR = `#${POPPER_CONTAINER_ID}` const usePopperContainer = () => { onBeforeMount(() => { if (!isClient$1) return if (!cachedContainer) { const container = document.createElement('div') container.id = POPPER_CONTAINER_ID document.body.appendChild(container) cachedContainer = container } }) } const useDelayedRender = ({ indicator, intermediateIndicator, shouldSetIntermediate = () => true, beforeShow, afterShow, afterHide, beforeHide, }) => { watch$1( () => unref(indicator), (val2) => { if (val2) { beforeShow == null ? void 0 : beforeShow() nextTick(() => { if (!unref(indicator)) return if (shouldSetIntermediate('show')) { intermediateIndicator.value = true } }) } else { beforeHide == null ? void 0 : beforeHide() nextTick(() => { if (unref(indicator)) return if (shouldSetIntermediate('hide')) { intermediateIndicator.value = false } }) } } ) watch$1( () => intermediateIndicator.value, (val2) => { if (val2) { afterShow == null ? void 0 : afterShow() } else { afterHide == null ? void 0 : afterHide() } } ) } const useDelayedToggleProps = buildProps({ showAfter: { type: Number, default: 0, }, hideAfter: { type: Number, default: 200, }, }) const useDelayedToggle = ({ showAfter, hideAfter, open: open2, close: close2, }) => { const { registerTimeout } = useTimeout$1() const onOpen = () => { registerTimeout(() => { open2() }, unref(showAfter)) } const onClose = () => { registerTimeout(() => { close2() }, unref(hideAfter)) } return { onOpen, onClose, } } const FORWARD_REF_INJECTION_KEY = Symbol('elForwardRef') const useForwardRef = (forwardRef) => { const setForwardRef = (el2) => { forwardRef.value = el2 } provide(FORWARD_REF_INJECTION_KEY, { setForwardRef, }) } const useForwardRefDirective = (setForwardRef) => { return { mounted(el2) { setForwardRef(el2) }, updated(el2) { setForwardRef(el2) }, unmounted() { setForwardRef(null) }, } } const defaultNamespace = 'el' const statePrefix = 'is-' const _bem = (namespace, block, blockSuffix, element, modifier) => { let cls = `${namespace}-${block}` if (blockSuffix) { cls += `-${blockSuffix}` } if (element) { cls += `__${element}` } if (modifier) { cls += `--${modifier}` } return cls } const useNamespace = (block) => { const globalConfig2 = useGlobalConfig('namespace') const namespace = computed(() => globalConfig2.value || defaultNamespace) const b2 = (blockSuffix = '') => _bem(unref(namespace), block, blockSuffix, '', '') const e2 = (element) => element ? _bem(unref(namespace), block, '', element, '') : '' const m2 = (modifier) => modifier ? _bem(unref(namespace), block, '', '', modifier) : '' const be2 = (blockSuffix, element) => blockSuffix && element ? _bem(unref(namespace), block, blockSuffix, element, '') : '' const em = (element, modifier) => element && modifier ? _bem(unref(namespace), block, '', element, modifier) : '' const bm = (blockSuffix, modifier) => blockSuffix && modifier ? _bem(unref(namespace), block, blockSuffix, '', modifier) : '' const bem = (blockSuffix, element, modifier) => blockSuffix && element && modifier ? _bem(unref(namespace), block, blockSuffix, element, modifier) : '' const is2 = (name2, ...args) => { const state2 = args.length >= 1 ? args[0] : true return name2 && state2 ? `${statePrefix}${name2}` : '' } return { namespace, b: b2, e: e2, m: m2, be: be2, em, bm, bem, is: is2, } } const zIndex$1 = ref(0) const useZIndex = () => { const initialZIndex = useGlobalConfig('zIndex', 2e3) const currentZIndex = computed(() => initialZIndex.value + zIndex$1.value) const nextZIndex2 = () => { zIndex$1.value++ return currentZIndex.value } return { initialZIndex, currentZIndex, nextZIndex: nextZIndex2, } } function t$5(t3) { return t3.split('-')[0] } function e$3(t3) { return t3.split('-')[1] } function n$3(e2) { return ['top', 'bottom'].includes(t$5(e2)) ? 'x' : 'y' } function r$2(t3) { return 'y' === t3 ? 'height' : 'width' } function i$8(i2, o2, a2) { let { reference: l2, floating: s2 } = i2 const c2 = l2.x + l2.width / 2 - s2.width / 2, f2 = l2.y + l2.height / 2 - s2.height / 2, u2 = n$3(o2), m2 = r$2(u2), g2 = l2[m2] / 2 - s2[m2] / 2, d3 = 'x' === u2 let p2 switch (t$5(o2)) { case 'top': p2 = { x: c2, y: l2.y - s2.height } break case 'bottom': p2 = { x: c2, y: l2.y + l2.height } break case 'right': p2 = { x: l2.x + l2.width, y: f2 } break case 'left': p2 = { x: l2.x - s2.width, y: f2 } break default: p2 = { x: l2.x, y: l2.y } } switch (e$3(o2)) { case 'start': p2[u2] -= g2 * (a2 && d3 ? -1 : 1) break case 'end': p2[u2] += g2 * (a2 && d3 ? -1 : 1) } return p2 } const o$4 = async (t3, e2, n2) => { const { placement: r2 = 'bottom', strategy: o2 = 'absolute', middleware: a2 = [], platform: l2, } = n2, s2 = await (null == l2.isRTL ? void 0 : l2.isRTL(e2)) let c2 = await l2.getElementRects({ reference: t3, floating: e2, strategy: o2, }), { x: f2, y: u2 } = i$8(c2, r2, s2), m2 = r2, g2 = {} for (let n3 = 0; n3 < a2.length; n3++) { const { name: d3, fn: p2 } = a2[n3], { x: h2, y: y2, data: x2, reset: w2, } = await p2({ x: f2, y: u2, initialPlacement: r2, placement: m2, strategy: o2, middlewareData: g2, rects: c2, platform: l2, elements: { reference: t3, floating: e2 }, }) ;(f2 = null != h2 ? h2 : f2), (u2 = null != y2 ? y2 : u2), (g2 = { ...g2, [d3]: { ...g2[d3], ...x2 } }), w2 && ('object' == typeof w2 && (w2.placement && (m2 = w2.placement), w2.rects && (c2 = true === w2.rects ? await l2.getElementRects({ reference: t3, floating: e2, strategy: o2, }) : w2.rects), ({ x: f2, y: u2 } = i$8(c2, m2, s2))), (n3 = -1)) } return { x: f2, y: u2, placement: m2, strategy: o2, middlewareData: g2 } } function a$5(t3) { return 'number' != typeof t3 ? (function (t4) { return { top: 0, right: 0, bottom: 0, left: 0, ...t4 } })(t3) : { top: t3, right: t3, bottom: t3, left: t3 } } function l$4(t3) { return { ...t3, top: t3.y, left: t3.x, right: t3.x + t3.width, bottom: t3.y + t3.height, } } const c$5 = Math.min, f$5 = Math.max function u$5(t3, e2, n2) { return f$5(t3, c$5(e2, n2)) } const m$6 = (t3) => ({ name: 'arrow', options: t3, async fn(e2) { const { element: i2, padding: o2 = 0 } = null != t3 ? t3 : {}, { x: l2, y: s2, placement: c2, rects: f2, platform: m2 } = e2 if (null == i2) return {} const g2 = a$5(o2), d3 = { x: l2, y: s2 }, p2 = n$3(c2), h2 = r$2(p2), y2 = await m2.getDimensions(i2), x2 = 'y' === p2 ? 'top' : 'left', w2 = 'y' === p2 ? 'bottom' : 'right', v4 = f2.reference[h2] + f2.reference[p2] - d3[p2] - f2.floating[h2], b2 = d3[p2] - f2.reference[p2], R2 = await (null == m2.getOffsetParent ? void 0 : m2.getOffsetParent(i2)), A2 = R2 ? ('y' === p2 ? R2.clientHeight || 0 : R2.clientWidth || 0) : 0, P2 = v4 / 2 - b2 / 2, T2 = g2[x2], O2 = A2 - y2[h2] - g2[w2], D2 = A2 / 2 - y2[h2] / 2 + P2, L2 = u$5(T2, D2, O2) return { data: { [p2]: L2, centerOffset: D2 - L2 } } }, }) const x$4 = ['top', 'right', 'bottom', 'left'] x$4.reduce((t3, e2) => t3.concat(e2, e2 + '-start', e2 + '-end'), []) const T$5 = function (r2) { return ( void 0 === r2 && (r2 = 0), { name: 'offset', options: r2, async fn(i2) { const { x: o2, y: a2, placement: l2, rects: s2, platform: c2, elements: f2, } = i2, u2 = (function (r3, i3, o3, a3) { void 0 === a3 && (a3 = false) const l3 = t$5(r3), s3 = e$3(r3), c3 = 'x' === n$3(r3), f3 = ['left', 'top'].includes(l3) ? -1 : 1, u3 = a3 && c3 ? -1 : 1, m2 = 'function' == typeof o3 ? o3({ ...i3, placement: r3 }) : o3 let { mainAxis: g2, crossAxis: d3, alignmentAxis: p2, } = 'number' == typeof m2 ? { mainAxis: m2, crossAxis: 0, alignmentAxis: null } : { mainAxis: 0, crossAxis: 0, alignmentAxis: null, ...m2 } return ( s3 && 'number' == typeof p2 && (d3 = 'end' === s3 ? -1 * p2 : p2), c3 ? { x: d3 * u3, y: g2 * f3 } : { x: g2 * f3, y: d3 * u3 } ) })( l2, s2, r2, await (null == c2.isRTL ? void 0 : c2.isRTL(f2.floating)) ) return { x: o2 + u2.x, y: a2 + u2.y, data: u2 } }, } ) } function n$2(t3) { return t3 && t3.document && t3.location && t3.alert && t3.setInterval } function o$3(t3) { if (null == t3) return window if (!n$2(t3)) { const e2 = t3.ownerDocument return (e2 && e2.defaultView) || window } return t3 } function i$7(t3) { return o$3(t3).getComputedStyle(t3) } function r$1(t3) { return n$2(t3) ? '' : t3 ? (t3.nodeName || '').toLowerCase() : '' } function l$3(t3) { return t3 instanceof o$3(t3).HTMLElement } function c$4(t3) { return t3 instanceof o$3(t3).Element } function f$4(t3) { if ('undefined' == typeof ShadowRoot) return false return t3 instanceof o$3(t3).ShadowRoot || t3 instanceof ShadowRoot } function s$3(t3) { const { overflow: e2, overflowX: n2, overflowY: o2 } = i$7(t3) return /auto|scroll|overlay|hidden/.test(e2 + o2 + n2) } function u$4(t3) { return ['table', 'td', 'th'].includes(r$1(t3)) } function d$2(t3) { const e2 = navigator.userAgent.toLowerCase().includes('firefox'), n2 = i$7(t3) return ( 'none' !== n2.transform || 'none' !== n2.perspective || 'paint' === n2.contain || ['transform', 'perspective'].includes(n2.willChange) || (e2 && 'filter' === n2.willChange) || (e2 && !!n2.filter && 'none' !== n2.filter) ) } function h$3() { return !/^((?!chrome|android).)*safari/i.test(navigator.userAgent) } const a$4 = Math.min, g$1 = Math.max, p$3 = Math.round function m$5(t3, e2, n2) { var i2, r2, f2, s2 void 0 === e2 && (e2 = false), void 0 === n2 && (n2 = false) const u2 = t3.getBoundingClientRect() let d3 = 1, a2 = 1 e2 && l$3(t3) && ((d3 = (t3.offsetWidth > 0 && p$3(u2.width) / t3.offsetWidth) || 1), (a2 = (t3.offsetHeight > 0 && p$3(u2.height) / t3.offsetHeight) || 1)) const g2 = c$4(t3) ? o$3(t3) : window, m2 = !h$3() && n2, w2 = (u2.left + (m2 && null != (i2 = null == (r2 = g2.visualViewport) ? void 0 : r2.offsetLeft) ? i2 : 0)) / d3, v4 = (u2.top + (m2 && null != (f2 = null == (s2 = g2.visualViewport) ? void 0 : s2.offsetTop) ? f2 : 0)) / a2, y2 = u2.width / d3, x2 = u2.height / a2 return { width: y2, height: x2, top: v4, right: w2 + y2, bottom: v4 + x2, left: w2, x: w2, y: v4, } } function w$2(t3) { return ((e2 = t3), (e2 instanceof o$3(e2).Node ? t3.ownerDocument : t3.document) || window.document).documentElement var e2 } function v$4(t3) { return c$4(t3) ? { scrollLeft: t3.scrollLeft, scrollTop: t3.scrollTop } : { scrollLeft: t3.pageXOffset, scrollTop: t3.pageYOffset } } function y$2(t3) { return m$5(w$2(t3)).left + v$4(t3).scrollLeft } function x$3(t3, e2, n2) { const o2 = l$3(e2), i2 = w$2(e2), c2 = m$5( t3, o2 && (function (t4) { const e3 = m$5(t4) return ( p$3(e3.width) !== t4.offsetWidth || p$3(e3.height) !== t4.offsetHeight ) })(e2), 'fixed' === n2 ) let f2 = { scrollLeft: 0, scrollTop: 0 } const u2 = { x: 0, y: 0 } if (o2 || (!o2 && 'fixed' !== n2)) if ((('body' !== r$1(e2) || s$3(i2)) && (f2 = v$4(e2)), l$3(e2))) { const t4 = m$5(e2, true) ;(u2.x = t4.x + e2.clientLeft), (u2.y = t4.y + e2.clientTop) } else i2 && (u2.x = y$2(i2)) return { x: c2.left + f2.scrollLeft - u2.x, y: c2.top + f2.scrollTop - u2.y, width: c2.width, height: c2.height, } } function L$2(t3) { return 'html' === r$1(t3) ? t3 : t3.assignedSlot || t3.parentNode || (f$4(t3) ? t3.host : null) || w$2(t3) } function b$2(t3) { return l$3(t3) && 'fixed' !== getComputedStyle(t3).position ? t3.offsetParent : null } function R$1(t3) { const e2 = o$3(t3) let n2 = b$2(t3) for (; n2 && u$4(n2) && 'static' === getComputedStyle(n2).position; ) n2 = b$2(n2) return n2 && ('html' === r$1(n2) || ('body' === r$1(n2) && 'static' === getComputedStyle(n2).position && !d$2(n2))) ? e2 : n2 || (function (t4) { let e3 = L$2(t4) for ( f$4(e3) && (e3 = e3.host); l$3(e3) && !['html', 'body'].includes(r$1(e3)); ) { if (d$2(e3)) return e3 e3 = e3.parentNode } return null })(t3) || e2 } function T$4(t3) { if (l$3(t3)) return { width: t3.offsetWidth, height: t3.offsetHeight } const e2 = m$5(t3) return { width: e2.width, height: e2.height } } function W$1(t3) { const e2 = L$2(t3) return ['html', 'body', '#document'].includes(r$1(e2)) ? t3.ownerDocument.body : l$3(e2) && s$3(e2) ? e2 : W$1(e2) } function C$1(t3, e2) { var n2 void 0 === e2 && (e2 = []) const i2 = W$1(t3), r2 = i2 === (null == (n2 = t3.ownerDocument) ? void 0 : n2.body), l2 = o$3(i2), c2 = r2 ? [l2].concat(l2.visualViewport || [], s$3(i2) ? i2 : []) : i2, f2 = e2.concat(c2) return r2 ? f2 : f2.concat(C$1(c2)) } function E$3(e2, n2, r2) { return 'viewport' === n2 ? l$4( (function (t3, e3) { const n3 = o$3(t3), i2 = w$2(t3), r3 = n3.visualViewport let l2 = i2.clientWidth, c2 = i2.clientHeight, f2 = 0, s2 = 0 if (r3) { ;(l2 = r3.width), (c2 = r3.height) const t4 = h$3() ;(t4 || (!t4 && 'fixed' === e3)) && ((f2 = r3.offsetLeft), (s2 = r3.offsetTop)) } return { width: l2, height: c2, x: f2, y: s2 } })(e2, r2) ) : c$4(n2) ? (function (t3, e3) { const n3 = m$5(t3, false, 'fixed' === e3), o2 = n3.top + t3.clientTop, i2 = n3.left + t3.clientLeft return { top: o2, left: i2, x: i2, y: o2, right: i2 + t3.clientWidth, bottom: o2 + t3.clientHeight, width: t3.clientWidth, height: t3.clientHeight, } })(n2, r2) : l$4( (function (t3) { var e3 const n3 = w$2(t3), o2 = v$4(t3), r3 = null == (e3 = t3.ownerDocument) ? void 0 : e3.body, l2 = g$1( n3.scrollWidth, n3.clientWidth, r3 ? r3.scrollWidth : 0, r3 ? r3.clientWidth : 0 ), c2 = g$1( n3.scrollHeight, n3.clientHeight, r3 ? r3.scrollHeight : 0, r3 ? r3.clientHeight : 0 ) let f2 = -o2.scrollLeft + y$2(t3) const s2 = -o2.scrollTop return ( 'rtl' === i$7(r3 || n3).direction && (f2 += g$1(n3.clientWidth, r3 ? r3.clientWidth : 0) - l2), { width: l2, height: c2, x: f2, y: s2 } ) })(w$2(e2)) ) } function H$1(t3) { const e2 = C$1(t3), n2 = ['absolute', 'fixed'].includes(i$7(t3).position) && l$3(t3) ? R$1(t3) : t3 return c$4(n2) ? e2.filter( (t4) => c$4(t4) && (function (t5, e3) { const n3 = null == e3 || null == e3.getRootNode ? void 0 : e3.getRootNode() if (null != t5 && t5.contains(e3)) return true if (n3 && f$4(n3)) { let n4 = e3 do { if (n4 && t5 === n4) return true n4 = n4.parentNode || n4.host } while (n4) } return false })(t4, n2) && 'body' !== r$1(t4) ) : [] } const S$2 = { getClippingRect: function (t3) { let { element: e2, boundary: n2, rootBoundary: o2, strategy: i2 } = t3 const r2 = [...('clippingAncestors' === n2 ? H$1(e2) : [].concat(n2)), o2], l2 = r2[0], c2 = r2.reduce((t4, n3) => { const o3 = E$3(e2, n3, i2) return ( (t4.top = g$1(o3.top, t4.top)), (t4.right = a$4(o3.right, t4.right)), (t4.bottom = a$4(o3.bottom, t4.bottom)), (t4.left = g$1(o3.left, t4.left)), t4 ) }, E$3(e2, l2, i2)) return { width: c2.right - c2.left, height: c2.bottom - c2.top, x: c2.left, y: c2.top, } }, convertOffsetParentRelativeRectToViewportRelativeRect: function (t3) { let { rect: e2, offsetParent: n2, strategy: o2 } = t3 const i2 = l$3(n2), c2 = w$2(n2) if (n2 === c2) return e2 let f2 = { scrollLeft: 0, scrollTop: 0 } const u2 = { x: 0, y: 0 } if ( (i2 || (!i2 && 'fixed' !== o2)) && (('body' !== r$1(n2) || s$3(c2)) && (f2 = v$4(n2)), l$3(n2)) ) { const t4 = m$5(n2, true) ;(u2.x = t4.x + n2.clientLeft), (u2.y = t4.y + n2.clientTop) } return { ...e2, x: e2.x - f2.scrollLeft + u2.x, y: e2.y - f2.scrollTop + u2.y, } }, isElement: c$4, getDimensions: T$4, getOffsetParent: R$1, getDocumentElement: w$2, getElementRects: (t3) => { let { reference: e2, floating: n2, strategy: o2 } = t3 return { reference: x$3(e2, R$1(n2), o2), floating: { ...T$4(n2), x: 0, y: 0 }, } }, getClientRects: (t3) => Array.from(t3.getClientRects()), isRTL: (t3) => 'rtl' === i$7(t3).direction, } const N$3 = (t3, n2, o2) => o$4(t3, n2, { platform: S$2, ...o2 }) const useFloatingProps = buildProps({}) const unrefReference = (elRef) => { if (!isClient$1) return if (!elRef) return elRef const unrefEl = unrefElement$1(elRef) if (unrefEl) return unrefEl return isRef(elRef) ? unrefEl : elRef } const getPositionDataWithUnit = (record, key2) => { const value2 = record == null ? void 0 : record[key2] return isNil$1(value2) ? '' : `${value2}px` } const useFloating = ({ middleware, placement, strategy }) => { const referenceRef = ref() const contentRef = ref() const x2 = ref() const y2 = ref() const middlewareData = ref({}) const states = { x: x2, y: y2, placement, strategy, middlewareData, } const update3 = async () => { if (!isClient$1) return const referenceEl = unrefReference(referenceRef) const contentEl = unrefElement$1(contentRef) if (!referenceEl || !contentEl) return const data2 = await N$3(referenceEl, contentEl, { placement: unref(placement), strategy: unref(strategy), middleware: unref(middleware), }) Object.keys(states).forEach((key2) => { states[key2].value = data2[key2] }) } onMounted(() => { watchEffect(() => { update3() }) }) return { ...states, update: update3, referenceRef, contentRef, } } const arrowMiddleware = ({ arrowRef, padding }) => { return { name: 'arrow', options: { element: arrowRef, padding, }, fn(args) { const arrowEl = unref(arrowRef) if (!arrowEl) return {} return m$6({ element: arrowEl, padding, }).fn(args) }, } } const version$7 = '2.1.8' const INSTALLED_KEY = Symbol('INSTALLED_KEY') const makeInstaller = (components = []) => { const install3 = (app2, options2) => { if (app2[INSTALLED_KEY]) return app2[INSTALLED_KEY] = true components.forEach((c2) => app2.use(c2)) if (options2) provideGlobalConfig(options2, app2, true) } return { version: version$7, install: install3, } } const affixProps = buildProps({ zIndex: { type: definePropType([Number, String]), default: 100, }, target: { type: String, default: '', }, offset: { type: Number, default: 0, }, position: { type: String, values: ['top', 'bottom'], default: 'top', }, }) const affixEmits = { scroll: ({ scrollTop, fixed }) => typeof scrollTop === 'number' && typeof fixed === 'boolean', change: (fixed) => typeof fixed === 'boolean', } var _export_sfc$1 = (sfc, props2) => { const target2 = sfc.__vccOpts || sfc for (const [key2, val2] of props2) { target2[key2] = val2 } return target2 } const __default__$P = { name: 'ElAffix', } const _sfc_main$9m = /* @__PURE__ */ defineComponent({ ...__default__$P, props: affixProps, emits: affixEmits, setup(__props2, { expose, emit: emit2 }) { const props2 = __props2 const COMPONENT_NAME2 = 'ElAffix' const ns = useNamespace('affix') const target2 = shallowRef() const root2 = shallowRef() const scrollContainer = shallowRef() const { height: windowHeight } = useWindowSize$1() const { height: rootHeight, width: rootWidth, top: rootTop, bottom: rootBottom, update: updateRoot, } = useElementBounding$1(root2) const targetRect = useElementBounding$1(target2) const fixed = ref(false) const scrollTop = ref(0) const transform3 = ref(0) const rootStyle = computed(() => { return { height: fixed.value ? `${rootHeight.value}px` : '', width: fixed.value ? `${rootWidth.value}px` : '', } }) const affixStyle = computed(() => { if (!fixed.value) return {} const offset2 = props2.offset ? `${props2.offset}px` : 0 return { height: `${rootHeight.value}px`, width: `${rootWidth.value}px`, top: props2.position === 'top' ? offset2 : '', bottom: props2.position === 'bottom' ? offset2 : '', transform: transform3.value ? `translateY(${transform3.value}px)` : '', zIndex: props2.zIndex, } }) const update3 = () => { if (!scrollContainer.value) return scrollTop.value = scrollContainer.value instanceof Window ? document.documentElement.scrollTop : scrollContainer.value.scrollTop || 0 if (props2.position === 'top') { if (props2.target) { const difference = targetRect.bottom.value - props2.offset - rootHeight.value fixed.value = props2.offset > rootTop.value && targetRect.bottom.value > 0 transform3.value = difference < 0 ? difference : 0 } else { fixed.value = props2.offset > rootTop.value } } else if (props2.target) { const difference = windowHeight.value - targetRect.top.value - props2.offset - rootHeight.value fixed.value = windowHeight.value - props2.offset < rootBottom.value && windowHeight.value > targetRect.top.value transform3.value = difference < 0 ? -difference : 0 } else { fixed.value = windowHeight.value - props2.offset < rootBottom.value } } const handleScroll2 = () => { emit2('scroll', { scrollTop: scrollTop.value, fixed: fixed.value, }) } watch$1(fixed, (val2) => emit2('change', val2)) onMounted(() => { var _a2 if (props2.target) { target2.value = (_a2 = document.querySelector(props2.target)) != null ? _a2 : void 0 if (!target2.value) throwError$1( COMPONENT_NAME2, `Target is not existed: ${props2.target}` ) } else { target2.value = document.documentElement } scrollContainer.value = getScrollContainer(root2.value, true) updateRoot() }) useEventListener$1(scrollContainer, 'scroll', handleScroll2) watchEffect(update3) expose({ update: update3, }) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { ref_key: 'root', ref: root2, class: normalizeClass(unref(ns).b()), style: normalizeStyle$1(unref(rootStyle)), }, [ createElementVNode( 'div', { class: normalizeClass({ [unref(ns).m('fixed')]: fixed.value }), style: normalizeStyle$1(unref(affixStyle)), }, [renderSlot(_ctx.$slots, 'default')], 6 ), ], 6 ) ) } }, }) var Affix = /* @__PURE__ */ _export_sfc$1(_sfc_main$9m, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/affix/src/affix.vue', ], ]) const ElAffix = withInstall(Affix) const iconProps = buildProps({ size: { type: definePropType([Number, String]), }, color: { type: String, }, }) const __default__$O = { name: 'ElIcon', inheritAttrs: false, } const _sfc_main$9l = /* @__PURE__ */ defineComponent({ ...__default__$O, props: iconProps, setup(__props2) { const props2 = __props2 const ns = useNamespace('icon') const style2 = computed(() => { if (!props2.size && !props2.color) return {} return { fontSize: isUndefined$c(props2.size) ? void 0 : addUnit(props2.size), '--color': props2.color, } }) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'i', mergeProps( { class: unref(ns).b(), style: unref(style2), }, _ctx.$attrs ), [renderSlot(_ctx.$slots, 'default')], 16 ) ) } }, }) var Icon$3 = /* @__PURE__ */ _export_sfc$1(_sfc_main$9l, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/icon/src/icon.vue', ], ]) const ElIcon = withInstall(Icon$3) const alertEffects = ['light', 'dark'] const alertProps = buildProps({ title: { type: String, default: '', }, description: { type: String, default: '', }, type: { type: String, values: keysOf(TypeComponentsMap), default: 'info', }, closable: { type: Boolean, default: true, }, closeText: { type: String, default: '', }, showIcon: Boolean, center: Boolean, effect: { type: String, values: alertEffects, default: 'light', }, }) const alertEmits = { close: (evt) => evt instanceof MouseEvent, } const __default__$N = { name: 'ElAlert', } const _sfc_main$9k = /* @__PURE__ */ defineComponent({ ...__default__$N, props: alertProps, emits: alertEmits, setup(__props2, { emit: emit2 }) { const props2 = __props2 const { Close } = TypeComponents const slots = useSlots() const ns = useNamespace('alert') const visible = ref(true) const iconComponent = computed( () => TypeComponentsMap[props2.type] || TypeComponentsMap['info'] ) const isBigIcon = computed( () => props2.description || { [ns.is('big')]: slots.default } ) const isBoldTitle = computed( () => props2.description || { [ns.is('bold')]: slots.default } ) const close2 = (evt) => { visible.value = false emit2('close', evt) } return (_ctx, _cache) => { return ( openBlock(), createBlock( Transition, { name: unref(ns).b('fade'), }, { default: withCtx(() => [ withDirectives( createElementVNode( 'div', { class: normalizeClass([ unref(ns).b(), unref(ns).m(_ctx.type), unref(ns).is('center', _ctx.center), unref(ns).is(_ctx.effect), ]), role: 'alert', }, [ _ctx.showIcon && unref(iconComponent) ? (openBlock(), createBlock( unref(ElIcon), { key: 0, class: normalizeClass([ unref(ns).e('icon'), unref(isBigIcon), ]), }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent(unref(iconComponent)) )), ]), _: 1, }, 8, ['class'] )) : createCommentVNode('v-if', true), createElementVNode( 'div', { class: normalizeClass(unref(ns).e('content')), }, [ _ctx.title || _ctx.$slots.title ? (openBlock(), createElementBlock( 'span', { key: 0, class: normalizeClass([ unref(ns).e('title'), unref(isBoldTitle), ]), }, [ renderSlot(_ctx.$slots, 'title', {}, () => [ createTextVNode( toDisplayString$1(_ctx.title), 1 ), ]), ], 2 )) : createCommentVNode('v-if', true), _ctx.$slots.default || _ctx.description ? (openBlock(), createElementBlock( 'p', { key: 1, class: normalizeClass( unref(ns).e('description') ), }, [ renderSlot(_ctx.$slots, 'default', {}, () => [ createTextVNode( toDisplayString$1(_ctx.description), 1 ), ]), ], 2 )) : createCommentVNode('v-if', true), _ctx.closable ? (openBlock(), createElementBlock( Fragment, { key: 2 }, [ _ctx.closeText ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass([ unref(ns).e('close-btn'), unref(ns).is('customed'), ]), onClick: close2, }, toDisplayString$1(_ctx.closeText), 3 )) : (openBlock(), createBlock( unref(ElIcon), { key: 1, class: normalizeClass( unref(ns).e('close-btn') ), onClick: close2, }, { default: withCtx(() => [ createVNode$1(unref(Close)), ]), _: 1, }, 8, ['class'] )), ], 2112 )) : createCommentVNode('v-if', true), ], 2 ), ], 2 ), [[vShow, visible.value]] ), ]), _: 3, }, 8, ['name'] ) ) } }, }) var Alert = /* @__PURE__ */ _export_sfc$1(_sfc_main$9k, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/alert/src/alert.vue', ], ]) const ElAlert = withInstall(Alert) let hiddenTextarea = void 0 const HIDDEN_STYLE = ` height:0 !important; visibility:hidden !important; overflow:hidden !important; position:absolute !important; z-index:-1000 !important; top:0 !important; right:0 !important; ` const CONTEXT_STYLE = [ 'letter-spacing', 'line-height', 'padding-top', 'padding-bottom', 'font-family', 'font-weight', 'font-size', 'text-rendering', 'text-transform', 'width', 'text-indent', 'padding-left', 'padding-right', 'border-width', 'box-sizing', ] function calculateNodeStyling(targetElement) { const style2 = window.getComputedStyle(targetElement) const boxSizing = style2.getPropertyValue('box-sizing') const paddingSize = Number.parseFloat(style2.getPropertyValue('padding-bottom')) + Number.parseFloat(style2.getPropertyValue('padding-top')) const borderSize = Number.parseFloat(style2.getPropertyValue('border-bottom-width')) + Number.parseFloat(style2.getPropertyValue('border-top-width')) const contextStyle = CONTEXT_STYLE.map( (name2) => `${name2}:${style2.getPropertyValue(name2)}` ).join(';') return { contextStyle, paddingSize, borderSize, boxSizing } } function calcTextareaHeight(targetElement, minRows = 1, maxRows) { var _a2 if (!hiddenTextarea) { hiddenTextarea = document.createElement('textarea') document.body.appendChild(hiddenTextarea) } const { paddingSize, borderSize, boxSizing, contextStyle } = calculateNodeStyling(targetElement) hiddenTextarea.setAttribute('style', `${contextStyle};${HIDDEN_STYLE}`) hiddenTextarea.value = targetElement.value || targetElement.placeholder || '' let height = hiddenTextarea.scrollHeight const result = {} if (boxSizing === 'border-box') { height = height + borderSize } else if (boxSizing === 'content-box') { height = height - paddingSize } hiddenTextarea.value = '' const singleRowHeight = hiddenTextarea.scrollHeight - paddingSize if (isNumber$h(minRows)) { let minHeight = singleRowHeight * minRows if (boxSizing === 'border-box') { minHeight = minHeight + paddingSize + borderSize } height = Math.max(minHeight, height) result.minHeight = `${minHeight}px` } if (isNumber$h(maxRows)) { let maxHeight = singleRowHeight * maxRows if (boxSizing === 'border-box') { maxHeight = maxHeight + paddingSize + borderSize } height = Math.min(maxHeight, height) } result.height = `${height}px` ;(_a2 = hiddenTextarea.parentNode) == null ? void 0 : _a2.removeChild(hiddenTextarea) hiddenTextarea = void 0 return result } const inputProps = buildProps({ size: useSizeProp, disabled: Boolean, modelValue: { type: definePropType([String, Number, Object]), default: '', }, type: { type: String, default: 'text', }, resize: { type: String, values: ['none', 'both', 'horizontal', 'vertical'], }, autosize: { type: definePropType([Boolean, Object]), default: false, }, autocomplete: { type: String, default: 'off', }, placeholder: { type: String, }, form: { type: String, default: '', }, readonly: { type: Boolean, default: false, }, clearable: { type: Boolean, default: false, }, showPassword: { type: Boolean, default: false, }, showWordLimit: { type: Boolean, default: false, }, suffixIcon: { type: iconPropType, default: '', }, prefixIcon: { type: iconPropType, default: '', }, label: { type: String, }, tabindex: { type: [Number, String], }, validateEvent: { type: Boolean, default: true, }, inputStyle: { type: definePropType([Object, Array, String]), default: () => mutable({}), }, }) const inputEmits = { [UPDATE_MODEL_EVENT]: (value2) => isString$f(value2), input: (value2) => isString$f(value2), change: (value2) => isString$f(value2), focus: (evt) => evt instanceof FocusEvent, blur: (evt) => evt instanceof FocusEvent, clear: () => true, mouseleave: (evt) => evt instanceof MouseEvent, mouseenter: (evt) => evt instanceof MouseEvent, keydown: (evt) => evt instanceof Event, compositionstart: (evt) => evt instanceof CompositionEvent, compositionupdate: (evt) => evt instanceof CompositionEvent, compositionend: (evt) => evt instanceof CompositionEvent, } const _hoisted_1$6$ = [ 'type', 'disabled', 'readonly', 'autocomplete', 'tabindex', 'aria-label', 'placeholder', ] const _hoisted_2$5B = [ 'tabindex', 'disabled', 'readonly', 'autocomplete', 'aria-label', 'placeholder', ] const __default__$M = { name: 'ElInput', inheritAttrs: false, } const _sfc_main$9j = /* @__PURE__ */ defineComponent({ ...__default__$M, props: inputProps, emits: inputEmits, setup(__props2, { expose, emit: emit2 }) { const props2 = __props2 const PENDANT_MAP = { suffix: 'append', prefix: 'prepend', } const instance = getCurrentInstance() const rawAttrs = useAttrs$1() const slots = useSlots() const attrs = useAttrs() const { form: form2, formItem } = useFormItem() const inputSize = useSize$1() const inputDisabled = useDisabled$1() const nsInput = useNamespace('input') const nsTextarea = useNamespace('textarea') const input = shallowRef() const textarea = shallowRef() const focused = ref(false) const hovering = ref(false) const isComposing = ref(false) const passwordVisible = ref(false) const textareaCalcStyle = shallowRef(props2.inputStyle) const _ref2 = computed(() => input.value || textarea.value) const needStatusIcon = computed(() => { var _a2 return (_a2 = form2 == null ? void 0 : form2.statusIcon) != null ? _a2 : false }) const validateState = computed( () => (formItem == null ? void 0 : formItem.validateState) || '' ) const validateIcon = computed( () => ValidateComponentsMap[validateState.value] ) const passwordIcon = computed(() => (passwordVisible.value ? view : hide$2)) const containerStyle = computed(() => [rawAttrs.style, props2.inputStyle]) const textareaStyle = computed(() => [ props2.inputStyle, textareaCalcStyle.value, { resize: props2.resize }, ]) const nativeInputValue = computed(() => isNil$1(props2.modelValue) ? '' : String(props2.modelValue) ) const showClear = computed( () => props2.clearable && !inputDisabled.value && !props2.readonly && !!nativeInputValue.value && (focused.value || hovering.value) ) const showPwdVisible = computed( () => props2.showPassword && !inputDisabled.value && !props2.readonly && (!!nativeInputValue.value || focused.value) ) const isWordLimitVisible = computed( () => props2.showWordLimit && !!attrs.value.maxlength && (props2.type === 'text' || props2.type === 'textarea') && !inputDisabled.value && !props2.readonly && !props2.showPassword ) const textLength = computed(() => Array.from(nativeInputValue.value).length) const inputExceed = computed( () => !!isWordLimitVisible.value && textLength.value > Number(attrs.value.maxlength) ) const suffixVisible = computed( () => !!slots.suffix || !!props2.suffixIcon || showClear.value || props2.showPassword || isWordLimitVisible.value || (!!validateState.value && needStatusIcon.value) ) const resizeTextarea = () => { const { type: type4, autosize } = props2 if (!isClient$1 || type4 !== 'textarea') return if (autosize) { const minRows = isObject$v(autosize) ? autosize.minRows : void 0 const maxRows = isObject$v(autosize) ? autosize.maxRows : void 0 textareaCalcStyle.value = { ...calcTextareaHeight(textarea.value, minRows, maxRows), } } else { textareaCalcStyle.value = { minHeight: calcTextareaHeight(textarea.value).minHeight, } } } const setNativeInputValue = () => { const input2 = _ref2.value if (!input2 || input2.value === nativeInputValue.value) return input2.value = nativeInputValue.value } const calcIconOffset = (place2) => { const { el: el2 } = instance.vnode if (!el2) return const elList = Array.from(el2.querySelectorAll(`.${nsInput.e(place2)}`)) const target2 = elList.find((item2) => item2.parentNode === el2) if (!target2) return const pendant = PENDANT_MAP[place2] if (slots[pendant]) { target2.style.transform = `translateX(${ place2 === 'suffix' ? '-' : '' }${ el2.querySelector(`.${nsInput.be('group', pendant)}`).offsetWidth }px)` } else { target2.removeAttribute('style') } } const updateIconOffset = () => { calcIconOffset('prefix') calcIconOffset('suffix') } const handleInput = async (event) => { const { value: value2 } = event.target if (isComposing.value) return if (value2 === nativeInputValue.value) return emit2(UPDATE_MODEL_EVENT, value2) emit2('input', value2) await nextTick() setNativeInputValue() } const handleChange = (event) => { emit2('change', event.target.value) } const handleCompositionStart = (event) => { emit2('compositionstart', event) isComposing.value = true } const handleCompositionUpdate = (event) => { var _a2 emit2('compositionupdate', event) const text2 = (_a2 = event.target) == null ? void 0 : _a2.value const lastCharacter = text2[text2.length - 1] || '' isComposing.value = !isKorean(lastCharacter) } const handleCompositionEnd = (event) => { emit2('compositionend', event) if (isComposing.value) { isComposing.value = false handleInput(event) } } const handlePasswordVisible = () => { passwordVisible.value = !passwordVisible.value focus2() } const focus2 = async () => { var _a2 await nextTick() ;(_a2 = _ref2.value) == null ? void 0 : _a2.focus() } const blur = () => { var _a2 return (_a2 = _ref2.value) == null ? void 0 : _a2.blur() } const handleFocus = (event) => { focused.value = true emit2('focus', event) } const handleBlur = (event) => { var _a2 focused.value = false emit2('blur', event) if (props2.validateEvent) { ;(_a2 = formItem == null ? void 0 : formItem.validate) == null ? void 0 : _a2.call(formItem, 'blur').catch((err) => debugWarn()) } } const handleMouseLeave = (evt) => { hovering.value = false emit2('mouseleave', evt) } const handleMouseEnter = (evt) => { hovering.value = true emit2('mouseenter', evt) } const handleKeydown = (evt) => { emit2('keydown', evt) } const select2 = () => { var _a2 ;(_a2 = _ref2.value) == null ? void 0 : _a2.select() } const clear2 = () => { emit2(UPDATE_MODEL_EVENT, '') emit2('change', '') emit2('clear') emit2('input', '') } watch$1( () => props2.modelValue, () => { var _a2 nextTick(() => resizeTextarea()) if (props2.validateEvent) { ;(_a2 = formItem == null ? void 0 : formItem.validate) == null ? void 0 : _a2.call(formItem, 'change').catch((err) => debugWarn()) } } ) watch$1(nativeInputValue, () => setNativeInputValue()) watch$1( () => props2.type, async () => { await nextTick() setNativeInputValue() resizeTextarea() updateIconOffset() } ) onMounted(async () => { setNativeInputValue() updateIconOffset() await nextTick() resizeTextarea() }) onUpdated(async () => { await nextTick() updateIconOffset() }) expose({ input, textarea, ref: _ref2, textareaStyle, autosize: toRef(props2, 'autosize'), focus: focus2, blur, select: select2, clear: clear2, resizeTextarea, }) return (_ctx, _cache) => { return withDirectives( (openBlock(), createElementBlock( 'div', { class: normalizeClass([ _ctx.type === 'textarea' ? unref(nsTextarea).b() : unref(nsInput).b(), unref(nsInput).m(unref(inputSize)), unref(nsInput).is('disabled', unref(inputDisabled)), unref(nsInput).is('exceed', unref(inputExceed)), { [unref(nsInput).b('group')]: _ctx.$slots.prepend || _ctx.$slots.append, [unref(nsInput).bm('group', 'append')]: _ctx.$slots.append, [unref(nsInput).bm('group', 'prepend')]: _ctx.$slots.prepend, [unref(nsInput).m('prefix')]: _ctx.$slots.prefix || _ctx.prefixIcon, [unref(nsInput).m('suffix')]: _ctx.$slots.suffix || _ctx.suffixIcon || _ctx.clearable || _ctx.showPassword, [unref(nsInput).m('suffix--password-clear')]: unref(showClear) && unref(showPwdVisible), }, _ctx.$attrs.class, ]), style: normalizeStyle$1(unref(containerStyle)), onMouseenter: handleMouseEnter, onMouseleave: handleMouseLeave, }, [ createCommentVNode(' input '), _ctx.type !== 'textarea' ? (openBlock(), createElementBlock( Fragment, { key: 0 }, [ createCommentVNode(' prepend slot '), _ctx.$slots.prepend ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass( unref(nsInput).be('group', 'prepend') ), }, [renderSlot(_ctx.$slots, 'prepend')], 2 )) : createCommentVNode('v-if', true), createElementVNode( 'input', mergeProps( { ref_key: 'input', ref: input, class: unref(nsInput).e('inner'), }, unref(attrs), { type: _ctx.showPassword ? passwordVisible.value ? 'text' : 'password' : _ctx.type, disabled: unref(inputDisabled), readonly: _ctx.readonly, autocomplete: _ctx.autocomplete, tabindex: _ctx.tabindex, 'aria-label': _ctx.label, placeholder: _ctx.placeholder, style: _ctx.inputStyle, onCompositionstart: handleCompositionStart, onCompositionupdate: handleCompositionUpdate, onCompositionend: handleCompositionEnd, onInput: handleInput, onFocus: handleFocus, onBlur: handleBlur, onChange: handleChange, onKeydown: handleKeydown, } ), null, 16, _hoisted_1$6$ ), createCommentVNode(' prefix slot '), _ctx.$slots.prefix || _ctx.prefixIcon ? (openBlock(), createElementBlock( 'span', { key: 1, class: normalizeClass(unref(nsInput).e('prefix')), }, [ createElementVNode( 'span', { class: normalizeClass( unref(nsInput).e('prefix-inner') ), }, [ renderSlot(_ctx.$slots, 'prefix'), _ctx.prefixIcon ? (openBlock(), createBlock( unref(ElIcon), { key: 0, class: normalizeClass( unref(nsInput).e('icon') ), }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent( _ctx.prefixIcon ) )), ]), _: 1, }, 8, ['class'] )) : createCommentVNode('v-if', true), ], 2 ), ], 2 )) : createCommentVNode('v-if', true), createCommentVNode(' suffix slot '), unref(suffixVisible) ? (openBlock(), createElementBlock( 'span', { key: 2, class: normalizeClass(unref(nsInput).e('suffix')), }, [ createElementVNode( 'span', { class: normalizeClass( unref(nsInput).e('suffix-inner') ), }, [ !unref(showClear) || !unref(showPwdVisible) || !unref(isWordLimitVisible) ? (openBlock(), createElementBlock( Fragment, { key: 0 }, [ renderSlot(_ctx.$slots, 'suffix'), _ctx.suffixIcon ? (openBlock(), createBlock( unref(ElIcon), { key: 0, class: normalizeClass( unref(nsInput).e('icon') ), }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent( _ctx.suffixIcon ) )), ]), _: 1, }, 8, ['class'] )) : createCommentVNode('v-if', true), ], 64 )) : createCommentVNode('v-if', true), unref(showClear) ? (openBlock(), createBlock( unref(ElIcon), { key: 1, class: normalizeClass([ unref(nsInput).e('icon'), unref(nsInput).e('clear'), ]), onMousedown: _cache[0] || (_cache[0] = withModifiers(() => {}, [ 'prevent', ])), onClick: clear2, }, { default: withCtx(() => [ createVNode$1(unref(circleClose)), ]), _: 1, }, 8, ['class'] )) : createCommentVNode('v-if', true), unref(showPwdVisible) ? (openBlock(), createBlock( unref(ElIcon), { key: 2, class: normalizeClass([ unref(nsInput).e('icon'), unref(nsInput).e('clear'), ]), onClick: handlePasswordVisible, }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent( unref(passwordIcon) ) )), ]), _: 1, }, 8, ['class'] )) : createCommentVNode('v-if', true), unref(isWordLimitVisible) ? (openBlock(), createElementBlock( 'span', { key: 3, class: normalizeClass( unref(nsInput).e('count') ), }, [ createElementVNode( 'span', { class: normalizeClass( unref(nsInput).e('count-inner') ), }, toDisplayString$1(unref(textLength)) + ' / ' + toDisplayString$1( unref(attrs).maxlength ), 3 ), ], 2 )) : createCommentVNode('v-if', true), ], 2 ), unref(validateState) && unref(validateIcon) && unref(needStatusIcon) ? (openBlock(), createBlock( unref(ElIcon), { key: 0, class: normalizeClass([ unref(nsInput).e('icon'), unref(nsInput).e('validateIcon'), unref(nsInput).is( 'loading', unref(validateState) === 'validating' ), ]), }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent( unref(validateIcon) ) )), ]), _: 1, }, 8, ['class'] )) : createCommentVNode('v-if', true), ], 2 )) : createCommentVNode('v-if', true), createCommentVNode(' append slot '), _ctx.$slots.append ? (openBlock(), createElementBlock( 'div', { key: 3, class: normalizeClass( unref(nsInput).be('group', 'append') ), }, [renderSlot(_ctx.$slots, 'append')], 2 )) : createCommentVNode('v-if', true), ], 64 )) : (openBlock(), createElementBlock( Fragment, { key: 1 }, [ createCommentVNode(' textarea '), createElementVNode( 'textarea', mergeProps( { ref_key: 'textarea', ref: textarea, class: unref(nsTextarea).e('inner'), }, unref(attrs), { tabindex: _ctx.tabindex, disabled: unref(inputDisabled), readonly: _ctx.readonly, autocomplete: _ctx.autocomplete, style: unref(textareaStyle), 'aria-label': _ctx.label, placeholder: _ctx.placeholder, onCompositionstart: handleCompositionStart, onCompositionupdate: handleCompositionUpdate, onCompositionend: handleCompositionEnd, onInput: handleInput, onFocus: handleFocus, onBlur: handleBlur, onChange: handleChange, onKeydown: handleKeydown, } ), null, 16, _hoisted_2$5B ), unref(isWordLimitVisible) ? (openBlock(), createElementBlock( 'span', { key: 0, class: normalizeClass(unref(nsInput).e('count')), }, toDisplayString$1(unref(textLength)) + ' / ' + toDisplayString$1(unref(attrs).maxlength), 3 )) : createCommentVNode('v-if', true), ], 64 )), ], 38 )), [[vShow, _ctx.type !== 'hidden']] ) } }, }) var Input$2 = /* @__PURE__ */ _export_sfc$1(_sfc_main$9j, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/input/src/input.vue', ], ]) const ElInput = withInstall(Input$2) const BAR_MAP = { vertical: { offset: 'offsetHeight', scroll: 'scrollTop', scrollSize: 'scrollHeight', size: 'height', key: 'vertical', axis: 'Y', client: 'clientY', direction: 'top', }, horizontal: { offset: 'offsetWidth', scroll: 'scrollLeft', scrollSize: 'scrollWidth', size: 'width', key: 'horizontal', axis: 'X', client: 'clientX', direction: 'left', }, } const renderThumbStyle$1 = ({ move, size, bar }) => ({ [bar.size]: size, transform: `translate${bar.axis}(${move}%)`, }) const thumbProps = buildProps({ vertical: Boolean, size: String, move: Number, ratio: { type: Number, required: true, }, always: Boolean, }) const COMPONENT_NAME$c = 'Thumb' const _sfc_main$9i = defineComponent({ name: COMPONENT_NAME$c, props: thumbProps, setup(props2) { const scrollbar = inject(scrollbarContextKey) const ns = useNamespace('scrollbar') if (!scrollbar) throwError$1(COMPONENT_NAME$c, 'can not inject scrollbar context') const instance = ref() const thumb = ref() const thumbState = ref({}) const visible = ref(false) let cursorDown = false let cursorLeave = false let originalOnSelectStart = isClient$1 ? document.onselectstart : null const bar = computed( () => BAR_MAP[props2.vertical ? 'vertical' : 'horizontal'] ) const thumbStyle = computed(() => renderThumbStyle$1({ size: props2.size, move: props2.move, bar: bar.value, }) ) const offsetRatio = computed( () => instance.value[bar.value.offset] ** 2 / scrollbar.wrapElement[bar.value.scrollSize] / props2.ratio / thumb.value[bar.value.offset] ) const clickThumbHandler = (e2) => { var _a2 e2.stopPropagation() if (e2.ctrlKey || [1, 2].includes(e2.button)) return ;(_a2 = window.getSelection()) == null ? void 0 : _a2.removeAllRanges() startDrag(e2) const el2 = e2.currentTarget if (!el2) return thumbState.value[bar.value.axis] = el2[bar.value.offset] - (e2[bar.value.client] - el2.getBoundingClientRect()[bar.value.direction]) } const clickTrackHandler = (e2) => { if (!thumb.value || !instance.value || !scrollbar.wrapElement) return const offset2 = Math.abs( e2.target.getBoundingClientRect()[bar.value.direction] - e2[bar.value.client] ) const thumbHalf = thumb.value[bar.value.offset] / 2 const thumbPositionPercentage = ((offset2 - thumbHalf) * 100 * offsetRatio.value) / instance.value[bar.value.offset] scrollbar.wrapElement[bar.value.scroll] = (thumbPositionPercentage * scrollbar.wrapElement[bar.value.scrollSize]) / 100 } const startDrag = (e2) => { e2.stopImmediatePropagation() cursorDown = true document.addEventListener('mousemove', mouseMoveDocumentHandler) document.addEventListener('mouseup', mouseUpDocumentHandler) originalOnSelectStart = document.onselectstart document.onselectstart = () => false } const mouseMoveDocumentHandler = (e2) => { if (!instance.value || !thumb.value) return if (cursorDown === false) return const prevPage2 = thumbState.value[bar.value.axis] if (!prevPage2) return const offset2 = (instance.value.getBoundingClientRect()[bar.value.direction] - e2[bar.value.client]) * -1 const thumbClickPosition = thumb.value[bar.value.offset] - prevPage2 const thumbPositionPercentage = ((offset2 - thumbClickPosition) * 100 * offsetRatio.value) / instance.value[bar.value.offset] scrollbar.wrapElement[bar.value.scroll] = (thumbPositionPercentage * scrollbar.wrapElement[bar.value.scrollSize]) / 100 } const mouseUpDocumentHandler = () => { cursorDown = false thumbState.value[bar.value.axis] = 0 document.removeEventListener('mousemove', mouseMoveDocumentHandler) document.removeEventListener('mouseup', mouseUpDocumentHandler) restoreOnselectstart() if (cursorLeave) visible.value = false } const mouseMoveScrollbarHandler = () => { cursorLeave = false visible.value = !!props2.size } const mouseLeaveScrollbarHandler = () => { cursorLeave = true visible.value = cursorDown } onBeforeUnmount(() => { restoreOnselectstart() document.removeEventListener('mouseup', mouseUpDocumentHandler) }) const restoreOnselectstart = () => { if (document.onselectstart !== originalOnSelectStart) document.onselectstart = originalOnSelectStart } useEventListener$1( toRef(scrollbar, 'scrollbarElement'), 'mousemove', mouseMoveScrollbarHandler ) useEventListener$1( toRef(scrollbar, 'scrollbarElement'), 'mouseleave', mouseLeaveScrollbarHandler ) return { ns, instance, thumb, bar, thumbStyle, visible, clickTrackHandler, clickThumbHandler, } }, }) function _sfc_render$1J(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createBlock( Transition, { name: _ctx.ns.b('fade'), }, { default: withCtx(() => [ withDirectives( createElementVNode( 'div', { ref: 'instance', class: normalizeClass([ _ctx.ns.e('bar'), _ctx.ns.is(_ctx.bar.key), ]), onMousedown: _cache[1] || (_cache[1] = (...args) => _ctx.clickTrackHandler && _ctx.clickTrackHandler(...args)), }, [ createElementVNode( 'div', { ref: 'thumb', class: normalizeClass(_ctx.ns.e('thumb')), style: normalizeStyle$1(_ctx.thumbStyle), onMousedown: _cache[0] || (_cache[0] = (...args) => _ctx.clickThumbHandler && _ctx.clickThumbHandler(...args)), }, null, 38 ), ], 34 ), [[vShow, _ctx.always || _ctx.visible]] ), ]), _: 1, }, 8, ['name'] ) ) } var Thumb = /* @__PURE__ */ _export_sfc$1(_sfc_main$9i, [ ['render', _sfc_render$1J], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/scrollbar/src/thumb.vue', ], ]) const barProps = buildProps({ always: { type: Boolean, default: true, }, width: { type: String, default: '', }, height: { type: String, default: '', }, ratioX: { type: Number, default: 1, }, ratioY: { type: Number, default: 1, }, }) const _sfc_main$9h = defineComponent({ components: { Thumb, }, props: barProps, setup(props2) { const moveX = ref(0) const moveY = ref(0) const GAP = 4 const handleScroll2 = (wrap) => { if (wrap) { const offsetHeight = wrap.offsetHeight - GAP const offsetWidth = wrap.offsetWidth - GAP moveY.value = ((wrap.scrollTop * 100) / offsetHeight) * props2.ratioY moveX.value = ((wrap.scrollLeft * 100) / offsetWidth) * props2.ratioX } } return { handleScroll: handleScroll2, moveX, moveY, } }, }) function _sfc_render$1I(_ctx, _cache, $props2, $setup, $data, $options) { const _component_thumb = resolveComponent('thumb') return ( openBlock(), createElementBlock( Fragment, null, [ createVNode$1( _component_thumb, { move: _ctx.moveX, ratio: _ctx.ratioX, size: _ctx.width, always: _ctx.always, }, null, 8, ['move', 'ratio', 'size', 'always'] ), createVNode$1( _component_thumb, { move: _ctx.moveY, ratio: _ctx.ratioY, size: _ctx.height, vertical: '', always: _ctx.always, }, null, 8, ['move', 'ratio', 'size', 'always'] ), ], 64 ) ) } var Bar = /* @__PURE__ */ _export_sfc$1(_sfc_main$9h, [ ['render', _sfc_render$1I], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/scrollbar/src/bar.vue', ], ]) const scrollbarProps = buildProps({ height: { type: [String, Number], default: '', }, maxHeight: { type: [String, Number], default: '', }, native: { type: Boolean, default: false, }, wrapStyle: { type: definePropType([String, Object, Array]), default: '', }, wrapClass: { type: [String, Array], default: '', }, viewClass: { type: [String, Array], default: '', }, viewStyle: { type: [String, Array, Object], default: '', }, noresize: Boolean, tag: { type: String, default: 'div', }, always: { type: Boolean, default: false, }, minSize: { type: Number, default: 20, }, }) const scrollbarEmits = { scroll: ({ scrollTop, scrollLeft }) => isNumber$h(scrollTop) && isNumber$h(scrollLeft), } const _sfc_main$9g = defineComponent({ name: 'ElScrollbar', components: { Bar, }, props: scrollbarProps, emits: scrollbarEmits, setup(props2, { emit: emit2 }) { const ns = useNamespace('scrollbar') let stopResizeObserver = void 0 let stopResizeListener = void 0 const scrollbar$ = ref() const wrap$ = ref() const resize$ = ref() const sizeWidth = ref('0') const sizeHeight = ref('0') const barRef = ref() const moveX = ref(0) const moveY = ref(0) const ratioY = ref(1) const ratioX = ref(1) const GAP = 4 const style2 = computed(() => { const style22 = {} if (props2.height) style22.height = addUnit(props2.height) if (props2.maxHeight) style22.maxHeight = addUnit(props2.maxHeight) return [props2.wrapStyle, style22] }) const handleScroll2 = () => { var _a2 if (wrap$.value) { ;(_a2 = barRef.value) == null ? void 0 : _a2.handleScroll(wrap$.value) emit2('scroll', { scrollTop: wrap$.value.scrollTop, scrollLeft: wrap$.value.scrollLeft, }) } } function scrollTo(arg1, arg2) { if (isObject$v(arg1)) { wrap$.value.scrollTo(arg1) } else if (isNumber$h(arg1) && isNumber$h(arg2)) { wrap$.value.scrollTo(arg1, arg2) } } const setScrollTop2 = (value2) => { if (!isNumber$h(value2)) { return } wrap$.value.scrollTop = value2 } const setScrollLeft2 = (value2) => { if (!isNumber$h(value2)) { return } wrap$.value.scrollLeft = value2 } const update3 = () => { if (!wrap$.value) return const offsetHeight = wrap$.value.offsetHeight - GAP const offsetWidth = wrap$.value.offsetWidth - GAP const originalHeight = offsetHeight ** 2 / wrap$.value.scrollHeight const originalWidth = offsetWidth ** 2 / wrap$.value.scrollWidth const height = Math.max(originalHeight, props2.minSize) const width = Math.max(originalWidth, props2.minSize) ratioY.value = originalHeight / (offsetHeight - originalHeight) / (height / (offsetHeight - height)) ratioX.value = originalWidth / (offsetWidth - originalWidth) / (width / (offsetWidth - width)) sizeHeight.value = height + GAP < offsetHeight ? `${height}px` : '' sizeWidth.value = width + GAP < offsetWidth ? `${width}px` : '' } watch$1( () => props2.noresize, (noresize) => { if (noresize) { stopResizeObserver == null ? void 0 : stopResizeObserver() stopResizeListener == null ? void 0 : stopResizeListener() } else { ;({ stop: stopResizeObserver } = useResizeObserver$1( resize$, update3 )) stopResizeListener = useEventListener$1('resize', update3) } }, { immediate: true } ) watch$1( () => [props2.maxHeight, props2.height], () => { if (!props2.native) nextTick(() => { var _a2 update3() if (wrap$.value) { ;(_a2 = barRef.value) == null ? void 0 : _a2.handleScroll(wrap$.value) } }) } ) provide( scrollbarContextKey, reactive({ scrollbarElement: scrollbar$, wrapElement: wrap$, }) ) onMounted(() => { if (!props2.native) nextTick(() => update3()) }) return { ns, scrollbar$, wrap$, resize$, barRef, moveX, moveY, ratioX, ratioY, sizeWidth, sizeHeight, style: style2, update: update3, handleScroll: handleScroll2, scrollTo, setScrollTop: setScrollTop2, setScrollLeft: setScrollLeft2, } }, }) function _sfc_render$1H(_ctx, _cache, $props2, $setup, $data, $options) { const _component_bar = resolveComponent('bar') return ( openBlock(), createElementBlock( 'div', { ref: 'scrollbar$', class: normalizeClass(_ctx.ns.b()), }, [ createElementVNode( 'div', { ref: 'wrap$', class: normalizeClass([ _ctx.wrapClass, _ctx.ns.e('wrap'), { [_ctx.ns.em('wrap', 'hidden-default')]: !_ctx.native }, ]), style: normalizeStyle$1(_ctx.style), onScroll: _cache[0] || (_cache[0] = (...args) => _ctx.handleScroll && _ctx.handleScroll(...args)), }, [ (openBlock(), createBlock( resolveDynamicComponent(_ctx.tag), { ref: 'resize$', class: normalizeClass([_ctx.ns.e('view'), _ctx.viewClass]), style: normalizeStyle$1(_ctx.viewStyle), }, { default: withCtx(() => [renderSlot(_ctx.$slots, 'default')]), _: 3, }, 8, ['class', 'style'] )), ], 38 ), !_ctx.native ? (openBlock(), createBlock( _component_bar, { key: 0, ref: 'barRef', height: _ctx.sizeHeight, width: _ctx.sizeWidth, always: _ctx.always, 'ratio-x': _ctx.ratioX, 'ratio-y': _ctx.ratioY, }, null, 8, ['height', 'width', 'always', 'ratio-x', 'ratio-y'] )) : createCommentVNode('v-if', true), ], 2 ) ) } var Scrollbar = /* @__PURE__ */ _export_sfc$1(_sfc_main$9g, [ ['render', _sfc_render$1H], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/scrollbar/src/scrollbar.vue', ], ]) const ElScrollbar = withInstall(Scrollbar) const __default__$L = { name: 'ElPopperRoot', inheritAttrs: false, } const _sfc_main$9f = /* @__PURE__ */ defineComponent({ ...__default__$L, setup(__props2, { expose }) { const triggerRef2 = ref() const popperInstanceRef = ref() const contentRef = ref() const referenceRef = ref() const popperProvides = { triggerRef: triggerRef2, popperInstanceRef, contentRef, referenceRef, } expose(popperProvides) provide(POPPER_INJECTION_KEY, popperProvides) return (_ctx, _cache) => { return renderSlot(_ctx.$slots, 'default') } }, }) var Popper = /* @__PURE__ */ _export_sfc$1(_sfc_main$9f, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/popper/src/popper.vue', ], ]) const usePopperArrowProps = buildProps({ arrowOffset: { type: Number, default: 5, }, }) const __default__$K = { name: 'ElPopperArrow', inheritAttrs: false, } const _sfc_main$9e = /* @__PURE__ */ defineComponent({ ...__default__$K, props: usePopperArrowProps, setup(__props2, { expose }) { const props2 = __props2 const ns = useNamespace('popper') const { arrowOffset, arrowRef } = inject( POPPER_CONTENT_INJECTION_KEY, void 0 ) watch$1( () => props2.arrowOffset, (val2) => { arrowOffset.value = val2 } ) onBeforeUnmount(() => { arrowRef.value = void 0 }) expose({ arrowRef, }) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'span', { ref_key: 'arrowRef', ref: arrowRef, class: normalizeClass(unref(ns).e('arrow')), 'data-popper-arrow': '', }, null, 2 ) ) } }, }) var ElPopperArrow = /* @__PURE__ */ _export_sfc$1(_sfc_main$9e, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/popper/src/arrow.vue', ], ]) const NAME = 'ElOnlyChild' const OnlyChild = defineComponent({ name: NAME, setup(_2, { slots, attrs }) { var _a2 const forwardRefInjection = inject(FORWARD_REF_INJECTION_KEY) const forwardRefDirective = useForwardRefDirective( (_a2 = forwardRefInjection == null ? void 0 : forwardRefInjection.setForwardRef) != null ? _a2 : NOOP ) return () => { var _a22 const defaultSlot = (_a22 = slots.default) == null ? void 0 : _a22.call(slots, attrs) if (!defaultSlot) return null if (defaultSlot.length > 1) { return null } const firstLegitNode = findFirstLegitChild(defaultSlot) if (!firstLegitNode) { return null } return withDirectives(cloneVNode(firstLegitNode, attrs), [ [forwardRefDirective], ]) } }, }) function findFirstLegitChild(node2) { if (!node2) return null const children = node2 for (const child of children) { if (isObject$v(child)) { switch (child.type) { case Comment: continue case Text: return wrapTextContent(child) case 'svg': return wrapTextContent(child) case Fragment: return findFirstLegitChild(child.children) default: return child } } return wrapTextContent(child) } return null } function wrapTextContent(s2) { return createVNode$1( 'span', { class: 'el-only-child__content', }, [s2] ) } const usePopperTriggerProps = buildProps({ virtualRef: { type: definePropType(Object), }, virtualTriggering: Boolean, onMouseenter: Function, onMouseleave: Function, onClick: Function, onKeydown: Function, onFocus: Function, onBlur: Function, onContextmenu: Function, id: String, open: Boolean, }) const __default__$J = { name: 'ElPopperTrigger', inheritAttrs: false, } const _sfc_main$9d = /* @__PURE__ */ defineComponent({ ...__default__$J, props: usePopperTriggerProps, setup(__props2, { expose }) { const props2 = __props2 const { triggerRef: triggerRef2 } = inject(POPPER_INJECTION_KEY, void 0) useForwardRef(triggerRef2) onMounted(() => { watch$1( () => props2.virtualRef, (virtualEl) => { if (virtualEl) { triggerRef2.value = unrefElement$1(virtualEl) } }, { immediate: true, } ) watch$1( () => triggerRef2.value, (el2, prevEl) => { if (isElement$3(el2)) { ;[ 'onMouseenter', 'onMouseleave', 'onClick', 'onKeydown', 'onFocus', 'onBlur', 'onContextmenu', ].forEach((eventName) => { var _a2 const handler = props2[eventName] if (handler) { el2.addEventListener(eventName.slice(2).toLowerCase(), handler) ;(_a2 = prevEl == null ? void 0 : prevEl.removeEventListener) == null ? void 0 : _a2.call(prevEl, eventName.slice(2).toLowerCase(), handler) } }) } }, { immediate: true, } ) }) expose({ triggerRef: triggerRef2, }) return (_ctx, _cache) => { return !_ctx.virtualTriggering ? (openBlock(), createBlock( unref(OnlyChild), mergeProps({ key: 0 }, _ctx.$attrs, { 'aria-describedby': _ctx.open ? _ctx.id : void 0, }), { default: withCtx(() => [renderSlot(_ctx.$slots, 'default')]), _: 3, }, 16, ['aria-describedby'] )) : createCommentVNode('v-if', true) } }, }) var ElPopperTrigger = /* @__PURE__ */ _export_sfc$1(_sfc_main$9d, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/popper/src/trigger.vue', ], ]) var top = 'top' var bottom = 'bottom' var right = 'right' var left = 'left' var auto = 'auto' var basePlacements = [top, bottom, right, left] var start$1 = 'start' var end$2 = 'end' var clippingParents = 'clippingParents' var viewport = 'viewport' var popper = 'popper' var reference = 'reference' var variationPlacements = /* @__PURE__ */ basePlacements.reduce(function ( acc, placement ) { return acc.concat([placement + '-' + start$1, placement + '-' + end$2]) }, []) var placements = /* @__PURE__ */ [] .concat(basePlacements, [auto]) .reduce(function (acc, placement) { return acc.concat([ placement, placement + '-' + start$1, placement + '-' + end$2, ]) }, []) var beforeRead = 'beforeRead' var read = 'read' var afterRead = 'afterRead' var beforeMain = 'beforeMain' var main$1 = 'main' var afterMain = 'afterMain' var beforeWrite = 'beforeWrite' var write = 'write' var afterWrite = 'afterWrite' var modifierPhases = [ beforeRead, read, afterRead, beforeMain, main$1, afterMain, beforeWrite, write, afterWrite, ] function getNodeName(element) { return element ? (element.nodeName || '').toLowerCase() : null } function getWindow(node2) { if (node2 == null) { return window } if (node2.toString() !== '[object Window]') { var ownerDocument = node2.ownerDocument return ownerDocument ? ownerDocument.defaultView || window : window } return node2 } function isElement$2(node2) { var OwnElement = getWindow(node2).Element return node2 instanceof OwnElement || node2 instanceof Element } function isHTMLElement$1(node2) { var OwnElement = getWindow(node2).HTMLElement return node2 instanceof OwnElement || node2 instanceof HTMLElement } function isShadowRoot(node2) { if (typeof ShadowRoot === 'undefined') { return false } var OwnElement = getWindow(node2).ShadowRoot return node2 instanceof OwnElement || node2 instanceof ShadowRoot } function applyStyles(_ref2) { var state2 = _ref2.state Object.keys(state2.elements).forEach(function (name2) { var style2 = state2.styles[name2] || {} var attributes2 = state2.attributes[name2] || {} var element = state2.elements[name2] if (!isHTMLElement$1(element) || !getNodeName(element)) { return } Object.assign(element.style, style2) Object.keys(attributes2).forEach(function (name3) { var value2 = attributes2[name3] if (value2 === false) { element.removeAttribute(name3) } else { element.setAttribute(name3, value2 === true ? '' : value2) } }) }) } function effect$2(_ref2) { var state2 = _ref2.state var initialStyles = { popper: { position: state2.options.strategy, left: '0', top: '0', margin: '0', }, arrow: { position: 'absolute', }, reference: {}, } Object.assign(state2.elements.popper.style, initialStyles.popper) state2.styles = initialStyles if (state2.elements.arrow) { Object.assign(state2.elements.arrow.style, initialStyles.arrow) } return function () { Object.keys(state2.elements).forEach(function (name2) { var element = state2.elements[name2] var attributes2 = state2.attributes[name2] || {} var styleProperties = Object.keys( state2.styles.hasOwnProperty(name2) ? state2.styles[name2] : initialStyles[name2] ) var style2 = styleProperties.reduce(function (style3, property2) { style3[property2] = '' return style3 }, {}) if (!isHTMLElement$1(element) || !getNodeName(element)) { return } Object.assign(element.style, style2) Object.keys(attributes2).forEach(function (attribute) { element.removeAttribute(attribute) }) }) } } var applyStyles$1 = { name: 'applyStyles', enabled: true, phase: 'write', fn: applyStyles, effect: effect$2, requires: ['computeStyles'], } function getBasePlacement(placement) { return placement.split('-')[0] } var max$b = Math.max var min$b = Math.min var round$8 = Math.round function getUAString() { var uaData = navigator.userAgentData if (uaData != null && uaData.brands && Array.isArray(uaData.brands)) { return uaData.brands .map(function (item2) { return item2.brand + '/' + item2.version }) .join(' ') } return navigator.userAgent } function isLayoutViewport() { return !/^((?!chrome|android).)*safari/i.test(getUAString()) } function getBoundingClientRect(element, includeScale, isFixedStrategy) { if (includeScale === void 0) { includeScale = false } if (isFixedStrategy === void 0) { isFixedStrategy = false } var clientRect = element.getBoundingClientRect() var scaleX = 1 var scaleY = 1 if (includeScale && isHTMLElement$1(element)) { scaleX = element.offsetWidth > 0 ? round$8(clientRect.width) / element.offsetWidth || 1 : 1 scaleY = element.offsetHeight > 0 ? round$8(clientRect.height) / element.offsetHeight || 1 : 1 } var _ref2 = isElement$2(element) ? getWindow(element) : window, visualViewport = _ref2.visualViewport var addVisualOffsets = !isLayoutViewport() && isFixedStrategy var x2 = (clientRect.left + (addVisualOffsets && visualViewport ? visualViewport.offsetLeft : 0)) / scaleX var y2 = (clientRect.top + (addVisualOffsets && visualViewport ? visualViewport.offsetTop : 0)) / scaleY var width = clientRect.width / scaleX var height = clientRect.height / scaleY return { width, height, top: y2, right: x2 + width, bottom: y2 + height, left: x2, x: x2, y: y2, } } function getLayoutRect$1(element) { var clientRect = getBoundingClientRect(element) var width = element.offsetWidth var height = element.offsetHeight if (Math.abs(clientRect.width - width) <= 1) { width = clientRect.width } if (Math.abs(clientRect.height - height) <= 1) { height = clientRect.height } return { x: element.offsetLeft, y: element.offsetTop, width, height, } } function contains$1(parent2, child) { var rootNode = child.getRootNode && child.getRootNode() if (parent2.contains(child)) { return true } else if (rootNode && isShadowRoot(rootNode)) { var next = child do { if (next && parent2.isSameNode(next)) { return true } next = next.parentNode || next.host } while (next) } return false } function getComputedStyle$2(element) { return getWindow(element).getComputedStyle(element) } function isTableElement(element) { return ['table', 'td', 'th'].indexOf(getNodeName(element)) >= 0 } function getDocumentElement(element) { return ( (isElement$2(element) ? element.ownerDocument : element.document) || window.document ).documentElement } function getParentNode$2(element) { if (getNodeName(element) === 'html') { return element } return ( element.assignedSlot || element.parentNode || (isShadowRoot(element) ? element.host : null) || getDocumentElement(element) ) } function getTrueOffsetParent(element) { if ( !isHTMLElement$1(element) || getComputedStyle$2(element).position === 'fixed' ) { return null } return element.offsetParent } function getContainingBlock(element) { var isFirefox2 = /firefox/i.test(getUAString()) var isIE = /Trident/i.test(getUAString()) if (isIE && isHTMLElement$1(element)) { var elementCss = getComputedStyle$2(element) if (elementCss.position === 'fixed') { return null } } var currentNode = getParentNode$2(element) if (isShadowRoot(currentNode)) { currentNode = currentNode.host } while ( isHTMLElement$1(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0 ) { var css2 = getComputedStyle$2(currentNode) if ( css2.transform !== 'none' || css2.perspective !== 'none' || css2.contain === 'paint' || ['transform', 'perspective'].indexOf(css2.willChange) !== -1 || (isFirefox2 && css2.willChange === 'filter') || (isFirefox2 && css2.filter && css2.filter !== 'none') ) { return currentNode } else { currentNode = currentNode.parentNode } } return null } function getOffsetParent(element) { var window2 = getWindow(element) var offsetParent = getTrueOffsetParent(element) while ( offsetParent && isTableElement(offsetParent) && getComputedStyle$2(offsetParent).position === 'static' ) { offsetParent = getTrueOffsetParent(offsetParent) } if ( offsetParent && (getNodeName(offsetParent) === 'html' || (getNodeName(offsetParent) === 'body' && getComputedStyle$2(offsetParent).position === 'static')) ) { return window2 } return offsetParent || getContainingBlock(element) || window2 } function getMainAxisFromPlacement(placement) { return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y' } function within(min3, value2, max3) { return max$b(min3, min$b(value2, max3)) } function withinMaxClamp(min3, value2, max3) { var v4 = within(min3, value2, max3) return v4 > max3 ? max3 : v4 } function getFreshSideObject() { return { top: 0, right: 0, bottom: 0, left: 0, } } function mergePaddingObject(paddingObject) { return Object.assign({}, getFreshSideObject(), paddingObject) } function expandToHashMap(value2, keys3) { return keys3.reduce(function (hashMap, key2) { hashMap[key2] = value2 return hashMap }, {}) } var toPaddingObject = function toPaddingObject2(padding, state2) { padding = typeof padding === 'function' ? padding( Object.assign({}, state2.rects, { placement: state2.placement, }) ) : padding return mergePaddingObject( typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements) ) } function arrow(_ref2) { var _state$modifiersData$ var state2 = _ref2.state, name2 = _ref2.name, options2 = _ref2.options var arrowElement = state2.elements.arrow var popperOffsets2 = state2.modifiersData.popperOffsets var basePlacement = getBasePlacement(state2.placement) var axis = getMainAxisFromPlacement(basePlacement) var isVertical = [left, right].indexOf(basePlacement) >= 0 var len2 = isVertical ? 'height' : 'width' if (!arrowElement || !popperOffsets2) { return } var paddingObject = toPaddingObject(options2.padding, state2) var arrowRect = getLayoutRect$1(arrowElement) var minProp = axis === 'y' ? top : left var maxProp = axis === 'y' ? bottom : right var endDiff = state2.rects.reference[len2] + state2.rects.reference[axis] - popperOffsets2[axis] - state2.rects.popper[len2] var startDiff = popperOffsets2[axis] - state2.rects.reference[axis] var arrowOffsetParent = getOffsetParent(arrowElement) var clientSize = arrowOffsetParent ? axis === 'y' ? arrowOffsetParent.clientHeight || 0 : arrowOffsetParent.clientWidth || 0 : 0 var centerToReference = endDiff / 2 - startDiff / 2 var min3 = paddingObject[minProp] var max3 = clientSize - arrowRect[len2] - paddingObject[maxProp] var center2 = clientSize / 2 - arrowRect[len2] / 2 + centerToReference var offset2 = within(min3, center2, max3) var axisProp = axis state2.modifiersData[name2] = ((_state$modifiersData$ = {}), (_state$modifiersData$[axisProp] = offset2), (_state$modifiersData$.centerOffset = offset2 - center2), _state$modifiersData$) } function effect$1(_ref2) { var state2 = _ref2.state, options2 = _ref2.options var _options$element = options2.element, arrowElement = _options$element === void 0 ? '[data-popper-arrow]' : _options$element if (arrowElement == null) { return } if (typeof arrowElement === 'string') { arrowElement = state2.elements.popper.querySelector(arrowElement) if (!arrowElement) { return } } if (!contains$1(state2.elements.popper, arrowElement)) { return } state2.elements.arrow = arrowElement } var arrow$1 = { name: 'arrow', enabled: true, phase: 'main', fn: arrow, effect: effect$1, requires: ['popperOffsets'], requiresIfExists: ['preventOverflow'], } function getVariation(placement) { return placement.split('-')[1] } var unsetSides = { top: 'auto', right: 'auto', bottom: 'auto', left: 'auto', } function roundOffsetsByDPR(_ref2, win) { var x2 = _ref2.x, y2 = _ref2.y var dpr2 = win.devicePixelRatio || 1 return { x: round$8(x2 * dpr2) / dpr2 || 0, y: round$8(y2 * dpr2) / dpr2 || 0, } } function mapToStyles(_ref2) { var _Object$assign2 var popper2 = _ref2.popper, popperRect = _ref2.popperRect, placement = _ref2.placement, variation = _ref2.variation, offsets = _ref2.offsets, position2 = _ref2.position, gpuAcceleration = _ref2.gpuAcceleration, adaptive = _ref2.adaptive, roundOffsets = _ref2.roundOffsets, isFixed = _ref2.isFixed var _offsets$x = offsets.x, x2 = _offsets$x === void 0 ? 0 : _offsets$x, _offsets$y = offsets.y, y2 = _offsets$y === void 0 ? 0 : _offsets$y var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({ x: x2, y: y2, }) : { x: x2, y: y2, } x2 = _ref3.x y2 = _ref3.y var hasX = offsets.hasOwnProperty('x') var hasY = offsets.hasOwnProperty('y') var sideX = left var sideY = top var win = window if (adaptive) { var offsetParent = getOffsetParent(popper2) var heightProp = 'clientHeight' var widthProp = 'clientWidth' if (offsetParent === getWindow(popper2)) { offsetParent = getDocumentElement(popper2) if ( getComputedStyle$2(offsetParent).position !== 'static' && position2 === 'absolute' ) { heightProp = 'scrollHeight' widthProp = 'scrollWidth' } } offsetParent = offsetParent if ( placement === top || ((placement === left || placement === right) && variation === end$2) ) { sideY = bottom var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : offsetParent[heightProp] y2 -= offsetY - popperRect.height y2 *= gpuAcceleration ? 1 : -1 } if ( placement === left || ((placement === top || placement === bottom) && variation === end$2) ) { sideX = right var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : offsetParent[widthProp] x2 -= offsetX - popperRect.width x2 *= gpuAcceleration ? 1 : -1 } } var commonStyles = Object.assign( { position: position2, }, adaptive && unsetSides ) var _ref4 = roundOffsets === true ? roundOffsetsByDPR( { x: x2, y: y2, }, getWindow(popper2) ) : { x: x2, y: y2, } x2 = _ref4.x y2 = _ref4.y if (gpuAcceleration) { var _Object$assign return Object.assign( {}, commonStyles, ((_Object$assign = {}), (_Object$assign[sideY] = hasY ? '0' : ''), (_Object$assign[sideX] = hasX ? '0' : ''), (_Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? 'translate(' + x2 + 'px, ' + y2 + 'px)' : 'translate3d(' + x2 + 'px, ' + y2 + 'px, 0)'), _Object$assign) ) } return Object.assign( {}, commonStyles, ((_Object$assign2 = {}), (_Object$assign2[sideY] = hasY ? y2 + 'px' : ''), (_Object$assign2[sideX] = hasX ? x2 + 'px' : ''), (_Object$assign2.transform = ''), _Object$assign2) ) } function computeStyles(_ref5) { var state2 = _ref5.state, options2 = _ref5.options var _options$gpuAccelerat = options2.gpuAcceleration, gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat, _options$adaptive = options2.adaptive, adaptive = _options$adaptive === void 0 ? true : _options$adaptive, _options$roundOffsets = options2.roundOffsets, roundOffsets = _options$roundOffsets === void 0 ? true : _options$roundOffsets var commonStyles = { placement: getBasePlacement(state2.placement), variation: getVariation(state2.placement), popper: state2.elements.popper, popperRect: state2.rects.popper, gpuAcceleration, isFixed: state2.options.strategy === 'fixed', } if (state2.modifiersData.popperOffsets != null) { state2.styles.popper = Object.assign( {}, state2.styles.popper, mapToStyles( Object.assign({}, commonStyles, { offsets: state2.modifiersData.popperOffsets, position: state2.options.strategy, adaptive, roundOffsets, }) ) ) } if (state2.modifiersData.arrow != null) { state2.styles.arrow = Object.assign( {}, state2.styles.arrow, mapToStyles( Object.assign({}, commonStyles, { offsets: state2.modifiersData.arrow, position: 'absolute', adaptive: false, roundOffsets, }) ) ) } state2.attributes.popper = Object.assign({}, state2.attributes.popper, { 'data-popper-placement': state2.placement, }) } var computeStyles$1 = { name: 'computeStyles', enabled: true, phase: 'beforeWrite', fn: computeStyles, data: {}, } var passive = { passive: true, } function effect(_ref2) { var state2 = _ref2.state, instance = _ref2.instance, options2 = _ref2.options var _options$scroll = options2.scroll, scroll = _options$scroll === void 0 ? true : _options$scroll, _options$resize = options2.resize, resize = _options$resize === void 0 ? true : _options$resize var window2 = getWindow(state2.elements.popper) var scrollParents = [].concat( state2.scrollParents.reference, state2.scrollParents.popper ) if (scroll) { scrollParents.forEach(function (scrollParent) { scrollParent.addEventListener('scroll', instance.update, passive) }) } if (resize) { window2.addEventListener('resize', instance.update, passive) } return function () { if (scroll) { scrollParents.forEach(function (scrollParent) { scrollParent.removeEventListener('scroll', instance.update, passive) }) } if (resize) { window2.removeEventListener('resize', instance.update, passive) } } } var eventListeners = { name: 'eventListeners', enabled: true, phase: 'write', fn: function fn() {}, effect, data: {}, } var hash$1 = { left: 'right', right: 'left', bottom: 'top', top: 'bottom', } function getOppositePlacement(placement) { return placement.replace(/left|right|bottom|top/g, function (matched) { return hash$1[matched] }) } var hash = { start: 'end', end: 'start', } function getOppositeVariationPlacement(placement) { return placement.replace(/start|end/g, function (matched) { return hash[matched] }) } function getWindowScroll(node2) { var win = getWindow(node2) var scrollLeft = win.pageXOffset var scrollTop = win.pageYOffset return { scrollLeft, scrollTop, } } function getWindowScrollBarX(element) { return ( getBoundingClientRect(getDocumentElement(element)).left + getWindowScroll(element).scrollLeft ) } function getViewportRect(element, strategy) { var win = getWindow(element) var html2 = getDocumentElement(element) var visualViewport = win.visualViewport var width = html2.clientWidth var height = html2.clientHeight var x2 = 0 var y2 = 0 if (visualViewport) { width = visualViewport.width height = visualViewport.height var layoutViewport = isLayoutViewport() if (layoutViewport || (!layoutViewport && strategy === 'fixed')) { x2 = visualViewport.offsetLeft y2 = visualViewport.offsetTop } } return { width, height, x: x2 + getWindowScrollBarX(element), y: y2, } } function getDocumentRect(element) { var _element$ownerDocumen var html2 = getDocumentElement(element) var winScroll = getWindowScroll(element) var body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body var width = max$b( html2.scrollWidth, html2.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0 ) var height = max$b( html2.scrollHeight, html2.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0 ) var x2 = -winScroll.scrollLeft + getWindowScrollBarX(element) var y2 = -winScroll.scrollTop if (getComputedStyle$2(body || html2).direction === 'rtl') { x2 += max$b(html2.clientWidth, body ? body.clientWidth : 0) - width } return { width, height, x: x2, y: y2, } } function isScrollParent(element) { var _getComputedStyle = getComputedStyle$2(element), overflow2 = _getComputedStyle.overflow, overflowX = _getComputedStyle.overflowX, overflowY = _getComputedStyle.overflowY return /auto|scroll|overlay|hidden/.test(overflow2 + overflowY + overflowX) } function getScrollParent(node2) { if (['html', 'body', '#document'].indexOf(getNodeName(node2)) >= 0) { return node2.ownerDocument.body } if (isHTMLElement$1(node2) && isScrollParent(node2)) { return node2 } return getScrollParent(getParentNode$2(node2)) } function listScrollParents(element, list2) { var _element$ownerDocumen if (list2 === void 0) { list2 = [] } var scrollParent = getScrollParent(element) var isBody = scrollParent === ((_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body) var win = getWindow(scrollParent) var target2 = isBody ? [win].concat( win.visualViewport || [], isScrollParent(scrollParent) ? scrollParent : [] ) : scrollParent var updatedList = list2.concat(target2) return isBody ? updatedList : updatedList.concat(listScrollParents(getParentNode$2(target2))) } function rectToClientRect(rect) { return Object.assign({}, rect, { left: rect.x, top: rect.y, right: rect.x + rect.width, bottom: rect.y + rect.height, }) } function getInnerBoundingClientRect(element, strategy) { var rect = getBoundingClientRect(element, false, strategy === 'fixed') rect.top = rect.top + element.clientTop rect.left = rect.left + element.clientLeft rect.bottom = rect.top + element.clientHeight rect.right = rect.left + element.clientWidth rect.width = element.clientWidth rect.height = element.clientHeight rect.x = rect.left rect.y = rect.top return rect } function getClientRectFromMixedType(element, clippingParent, strategy) { return clippingParent === viewport ? rectToClientRect(getViewportRect(element, strategy)) : isElement$2(clippingParent) ? getInnerBoundingClientRect(clippingParent, strategy) : rectToClientRect(getDocumentRect(getDocumentElement(element))) } function getClippingParents(element) { var clippingParents2 = listScrollParents(getParentNode$2(element)) var canEscapeClipping = ['absolute', 'fixed'].indexOf(getComputedStyle$2(element).position) >= 0 var clipperElement = canEscapeClipping && isHTMLElement$1(element) ? getOffsetParent(element) : element if (!isElement$2(clipperElement)) { return [] } return clippingParents2.filter(function (clippingParent) { return ( isElement$2(clippingParent) && contains$1(clippingParent, clipperElement) && getNodeName(clippingParent) !== 'body' ) }) } function getClippingRect(element, boundary, rootBoundary, strategy) { var mainClippingParents = boundary === 'clippingParents' ? getClippingParents(element) : [].concat(boundary) var clippingParents2 = [].concat(mainClippingParents, [rootBoundary]) var firstClippingParent = clippingParents2[0] var clippingRect = clippingParents2.reduce(function ( accRect, clippingParent ) { var rect = getClientRectFromMixedType(element, clippingParent, strategy) accRect.top = max$b(rect.top, accRect.top) accRect.right = min$b(rect.right, accRect.right) accRect.bottom = min$b(rect.bottom, accRect.bottom) accRect.left = max$b(rect.left, accRect.left) return accRect }, getClientRectFromMixedType(element, firstClippingParent, strategy)) clippingRect.width = clippingRect.right - clippingRect.left clippingRect.height = clippingRect.bottom - clippingRect.top clippingRect.x = clippingRect.left clippingRect.y = clippingRect.top return clippingRect } function computeOffsets(_ref2) { var reference2 = _ref2.reference, element = _ref2.element, placement = _ref2.placement var basePlacement = placement ? getBasePlacement(placement) : null var variation = placement ? getVariation(placement) : null var commonX = reference2.x + reference2.width / 2 - element.width / 2 var commonY = reference2.y + reference2.height / 2 - element.height / 2 var offsets switch (basePlacement) { case top: offsets = { x: commonX, y: reference2.y - element.height, } break case bottom: offsets = { x: commonX, y: reference2.y + reference2.height, } break case right: offsets = { x: reference2.x + reference2.width, y: commonY, } break case left: offsets = { x: reference2.x - element.width, y: commonY, } break default: offsets = { x: reference2.x, y: reference2.y, } } var mainAxis = basePlacement ? getMainAxisFromPlacement(basePlacement) : null if (mainAxis != null) { var len2 = mainAxis === 'y' ? 'height' : 'width' switch (variation) { case start$1: offsets[mainAxis] = offsets[mainAxis] - (reference2[len2] / 2 - element[len2] / 2) break case end$2: offsets[mainAxis] = offsets[mainAxis] + (reference2[len2] / 2 - element[len2] / 2) break } } return offsets } function detectOverflow(state2, options2) { if (options2 === void 0) { options2 = {} } var _options = options2, _options$placement = _options.placement, placement = _options$placement === void 0 ? state2.placement : _options$placement, _options$strategy = _options.strategy, strategy = _options$strategy === void 0 ? state2.strategy : _options$strategy, _options$boundary = _options.boundary, boundary = _options$boundary === void 0 ? clippingParents : _options$boundary, _options$rootBoundary = _options.rootBoundary, rootBoundary = _options$rootBoundary === void 0 ? viewport : _options$rootBoundary, _options$elementConte = _options.elementContext, elementContext = _options$elementConte === void 0 ? popper : _options$elementConte, _options$altBoundary = _options.altBoundary, altBoundary = _options$altBoundary === void 0 ? false : _options$altBoundary, _options$padding = _options.padding, padding = _options$padding === void 0 ? 0 : _options$padding var paddingObject = mergePaddingObject( typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements) ) var altContext = elementContext === popper ? reference : popper var popperRect = state2.rects.popper var element = state2.elements[altBoundary ? altContext : elementContext] var clippingClientRect = getClippingRect( isElement$2(element) ? element : element.contextElement || getDocumentElement(state2.elements.popper), boundary, rootBoundary, strategy ) var referenceClientRect = getBoundingClientRect(state2.elements.reference) var popperOffsets2 = computeOffsets({ reference: referenceClientRect, element: popperRect, strategy: 'absolute', placement, }) var popperClientRect = rectToClientRect( Object.assign({}, popperRect, popperOffsets2) ) var elementClientRect = elementContext === popper ? popperClientRect : referenceClientRect var overflowOffsets = { top: clippingClientRect.top - elementClientRect.top + paddingObject.top, bottom: elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom, left: clippingClientRect.left - elementClientRect.left + paddingObject.left, right: elementClientRect.right - clippingClientRect.right + paddingObject.right, } var offsetData = state2.modifiersData.offset if (elementContext === popper && offsetData) { var offset2 = offsetData[placement] Object.keys(overflowOffsets).forEach(function (key2) { var multiply2 = [right, bottom].indexOf(key2) >= 0 ? 1 : -1 var axis = [top, bottom].indexOf(key2) >= 0 ? 'y' : 'x' overflowOffsets[key2] += offset2[axis] * multiply2 }) } return overflowOffsets } function computeAutoPlacement(state2, options2) { if (options2 === void 0) { options2 = {} } var _options = options2, placement = _options.placement, boundary = _options.boundary, rootBoundary = _options.rootBoundary, padding = _options.padding, flipVariations = _options.flipVariations, _options$allowedAutoP = _options.allowedAutoPlacements, allowedAutoPlacements = _options$allowedAutoP === void 0 ? placements : _options$allowedAutoP var variation = getVariation(placement) var placements$1 = variation ? flipVariations ? variationPlacements : variationPlacements.filter(function (placement2) { return getVariation(placement2) === variation }) : basePlacements var allowedPlacements = placements$1.filter(function (placement2) { return allowedAutoPlacements.indexOf(placement2) >= 0 }) if (allowedPlacements.length === 0) { allowedPlacements = placements$1 } var overflows = allowedPlacements.reduce(function (acc, placement2) { acc[placement2] = detectOverflow(state2, { placement: placement2, boundary, rootBoundary, padding, })[getBasePlacement(placement2)] return acc }, {}) return Object.keys(overflows).sort(function (a2, b2) { return overflows[a2] - overflows[b2] }) } function getExpandedFallbackPlacements(placement) { if (getBasePlacement(placement) === auto) { return [] } var oppositePlacement = getOppositePlacement(placement) return [ getOppositeVariationPlacement(placement), oppositePlacement, getOppositeVariationPlacement(oppositePlacement), ] } function flip(_ref2) { var state2 = _ref2.state, options2 = _ref2.options, name2 = _ref2.name if (state2.modifiersData[name2]._skip) { return } var _options$mainAxis = options2.mainAxis, checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis, _options$altAxis = options2.altAxis, checkAltAxis = _options$altAxis === void 0 ? true : _options$altAxis, specifiedFallbackPlacements = options2.fallbackPlacements, padding = options2.padding, boundary = options2.boundary, rootBoundary = options2.rootBoundary, altBoundary = options2.altBoundary, _options$flipVariatio = options2.flipVariations, flipVariations = _options$flipVariatio === void 0 ? true : _options$flipVariatio, allowedAutoPlacements = options2.allowedAutoPlacements var preferredPlacement = state2.options.placement var basePlacement = getBasePlacement(preferredPlacement) var isBasePlacement = basePlacement === preferredPlacement var fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipVariations ? [getOppositePlacement(preferredPlacement)] : getExpandedFallbackPlacements(preferredPlacement)) var placements2 = [preferredPlacement] .concat(fallbackPlacements) .reduce(function (acc, placement2) { return acc.concat( getBasePlacement(placement2) === auto ? computeAutoPlacement(state2, { placement: placement2, boundary, rootBoundary, padding, flipVariations, allowedAutoPlacements, }) : placement2 ) }, []) var referenceRect = state2.rects.reference var popperRect = state2.rects.popper var checksMap = /* @__PURE__ */ new Map() var makeFallbackChecks = true var firstFittingPlacement = placements2[0] for (var i2 = 0; i2 < placements2.length; i2++) { var placement = placements2[i2] var _basePlacement = getBasePlacement(placement) var isStartVariation = getVariation(placement) === start$1 var isVertical = [top, bottom].indexOf(_basePlacement) >= 0 var len2 = isVertical ? 'width' : 'height' var overflow2 = detectOverflow(state2, { placement, boundary, rootBoundary, altBoundary, padding, }) var mainVariationSide = isVertical ? isStartVariation ? right : left : isStartVariation ? bottom : top if (referenceRect[len2] > popperRect[len2]) { mainVariationSide = getOppositePlacement(mainVariationSide) } var altVariationSide = getOppositePlacement(mainVariationSide) var checks = [] if (checkMainAxis) { checks.push(overflow2[_basePlacement] <= 0) } if (checkAltAxis) { checks.push( overflow2[mainVariationSide] <= 0, overflow2[altVariationSide] <= 0 ) } if ( checks.every(function (check2) { return check2 }) ) { firstFittingPlacement = placement makeFallbackChecks = false break } checksMap.set(placement, checks) } if (makeFallbackChecks) { var numberOfChecks = flipVariations ? 3 : 1 var _loop = function _loop2(_i2) { var fittingPlacement = placements2.find(function (placement2) { var checks2 = checksMap.get(placement2) if (checks2) { return checks2.slice(0, _i2).every(function (check2) { return check2 }) } }) if (fittingPlacement) { firstFittingPlacement = fittingPlacement return 'break' } } for (var _i = numberOfChecks; _i > 0; _i--) { var _ret = _loop(_i) if (_ret === 'break') break } } if (state2.placement !== firstFittingPlacement) { state2.modifiersData[name2]._skip = true state2.placement = firstFittingPlacement state2.reset = true } } var flip$1 = { name: 'flip', enabled: true, phase: 'main', fn: flip, requiresIfExists: ['offset'], data: { _skip: false, }, } function getSideOffsets(overflow2, rect, preventedOffsets) { if (preventedOffsets === void 0) { preventedOffsets = { x: 0, y: 0, } } return { top: overflow2.top - rect.height - preventedOffsets.y, right: overflow2.right - rect.width + preventedOffsets.x, bottom: overflow2.bottom - rect.height + preventedOffsets.y, left: overflow2.left - rect.width - preventedOffsets.x, } } function isAnySideFullyClipped(overflow2) { return [top, right, bottom, left].some(function (side) { return overflow2[side] >= 0 }) } function hide(_ref2) { var state2 = _ref2.state, name2 = _ref2.name var referenceRect = state2.rects.reference var popperRect = state2.rects.popper var preventedOffsets = state2.modifiersData.preventOverflow var referenceOverflow = detectOverflow(state2, { elementContext: 'reference', }) var popperAltOverflow = detectOverflow(state2, { altBoundary: true, }) var referenceClippingOffsets = getSideOffsets( referenceOverflow, referenceRect ) var popperEscapeOffsets = getSideOffsets( popperAltOverflow, popperRect, preventedOffsets ) var isReferenceHidden = isAnySideFullyClipped(referenceClippingOffsets) var hasPopperEscaped = isAnySideFullyClipped(popperEscapeOffsets) state2.modifiersData[name2] = { referenceClippingOffsets, popperEscapeOffsets, isReferenceHidden, hasPopperEscaped, } state2.attributes.popper = Object.assign({}, state2.attributes.popper, { 'data-popper-reference-hidden': isReferenceHidden, 'data-popper-escaped': hasPopperEscaped, }) } var hide$1 = { name: 'hide', enabled: true, phase: 'main', requiresIfExists: ['preventOverflow'], fn: hide, } function distanceAndSkiddingToXY(placement, rects, offset2) { var basePlacement = getBasePlacement(placement) var invertDistance = [left, top].indexOf(basePlacement) >= 0 ? -1 : 1 var _ref2 = typeof offset2 === 'function' ? offset2( Object.assign({}, rects, { placement, }) ) : offset2, skidding = _ref2[0], distance2 = _ref2[1] skidding = skidding || 0 distance2 = (distance2 || 0) * invertDistance return [left, right].indexOf(basePlacement) >= 0 ? { x: distance2, y: skidding, } : { x: skidding, y: distance2, } } function offset(_ref2) { var state2 = _ref2.state, options2 = _ref2.options, name2 = _ref2.name var _options$offset = options2.offset, offset2 = _options$offset === void 0 ? [0, 0] : _options$offset var data2 = placements.reduce(function (acc, placement) { acc[placement] = distanceAndSkiddingToXY(placement, state2.rects, offset2) return acc }, {}) var _data$state$placement = data2[state2.placement], x2 = _data$state$placement.x, y2 = _data$state$placement.y if (state2.modifiersData.popperOffsets != null) { state2.modifiersData.popperOffsets.x += x2 state2.modifiersData.popperOffsets.y += y2 } state2.modifiersData[name2] = data2 } var offset$1 = { name: 'offset', enabled: true, phase: 'main', requires: ['popperOffsets'], fn: offset, } function popperOffsets(_ref2) { var state2 = _ref2.state, name2 = _ref2.name state2.modifiersData[name2] = computeOffsets({ reference: state2.rects.reference, element: state2.rects.popper, strategy: 'absolute', placement: state2.placement, }) } var popperOffsets$1 = { name: 'popperOffsets', enabled: true, phase: 'read', fn: popperOffsets, data: {}, } function getAltAxis(axis) { return axis === 'x' ? 'y' : 'x' } function preventOverflow(_ref2) { var state2 = _ref2.state, options2 = _ref2.options, name2 = _ref2.name var _options$mainAxis = options2.mainAxis, checkMainAxis = _options$mainAxis === void 0 ? true : _options$mainAxis, _options$altAxis = options2.altAxis, checkAltAxis = _options$altAxis === void 0 ? false : _options$altAxis, boundary = options2.boundary, rootBoundary = options2.rootBoundary, altBoundary = options2.altBoundary, padding = options2.padding, _options$tether = options2.tether, tether = _options$tether === void 0 ? true : _options$tether, _options$tetherOffset = options2.tetherOffset, tetherOffset = _options$tetherOffset === void 0 ? 0 : _options$tetherOffset var overflow2 = detectOverflow(state2, { boundary, rootBoundary, padding, altBoundary, }) var basePlacement = getBasePlacement(state2.placement) var variation = getVariation(state2.placement) var isBasePlacement = !variation var mainAxis = getMainAxisFromPlacement(basePlacement) var altAxis = getAltAxis(mainAxis) var popperOffsets2 = state2.modifiersData.popperOffsets var referenceRect = state2.rects.reference var popperRect = state2.rects.popper var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset( Object.assign({}, state2.rects, { placement: state2.placement, }) ) : tetherOffset var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? { mainAxis: tetherOffsetValue, altAxis: tetherOffsetValue, } : Object.assign( { mainAxis: 0, altAxis: 0, }, tetherOffsetValue ) var offsetModifierState = state2.modifiersData.offset ? state2.modifiersData.offset[state2.placement] : null var data2 = { x: 0, y: 0, } if (!popperOffsets2) { return } if (checkMainAxis) { var _offsetModifierState$ var mainSide = mainAxis === 'y' ? top : left var altSide = mainAxis === 'y' ? bottom : right var len2 = mainAxis === 'y' ? 'height' : 'width' var offset2 = popperOffsets2[mainAxis] var min3 = offset2 + overflow2[mainSide] var max3 = offset2 - overflow2[altSide] var additive = tether ? -popperRect[len2] / 2 : 0 var minLen = variation === start$1 ? referenceRect[len2] : popperRect[len2] var maxLen = variation === start$1 ? -popperRect[len2] : -referenceRect[len2] var arrowElement = state2.elements.arrow var arrowRect = tether && arrowElement ? getLayoutRect$1(arrowElement) : { width: 0, height: 0, } var arrowPaddingObject = state2.modifiersData['arrow#persistent'] ? state2.modifiersData['arrow#persistent'].padding : getFreshSideObject() var arrowPaddingMin = arrowPaddingObject[mainSide] var arrowPaddingMax = arrowPaddingObject[altSide] var arrowLen = within(0, referenceRect[len2], arrowRect[len2]) var minOffset = isBasePlacement ? referenceRect[len2] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis var maxOffset = isBasePlacement ? -referenceRect[len2] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis var arrowOffsetParent = state2.elements.arrow && getOffsetParent(state2.elements.arrow) var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0 var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0 var tetherMin = offset2 + minOffset - offsetModifierValue - clientOffset var tetherMax = offset2 + maxOffset - offsetModifierValue var preventedOffset = within( tether ? min$b(min3, tetherMin) : min3, offset2, tether ? max$b(max3, tetherMax) : max3 ) popperOffsets2[mainAxis] = preventedOffset data2[mainAxis] = preventedOffset - offset2 } if (checkAltAxis) { var _offsetModifierState$2 var _mainSide = mainAxis === 'x' ? top : left var _altSide = mainAxis === 'x' ? bottom : right var _offset = popperOffsets2[altAxis] var _len = altAxis === 'y' ? 'height' : 'width' var _min = _offset + overflow2[_mainSide] var _max = _offset - overflow2[_altSide] var isOriginSide = [top, left].indexOf(basePlacement) !== -1 var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0 var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within( tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max ) popperOffsets2[altAxis] = _preventedOffset data2[altAxis] = _preventedOffset - _offset } state2.modifiersData[name2] = data2 } var preventOverflow$1 = { name: 'preventOverflow', enabled: true, phase: 'main', fn: preventOverflow, requiresIfExists: ['offset'], } function getHTMLElementScroll(element) { return { scrollLeft: element.scrollLeft, scrollTop: element.scrollTop, } } function getNodeScroll(node2) { if (node2 === getWindow(node2) || !isHTMLElement$1(node2)) { return getWindowScroll(node2) } else { return getHTMLElementScroll(node2) } } function isElementScaled(element) { var rect = element.getBoundingClientRect() var scaleX = round$8(rect.width) / element.offsetWidth || 1 var scaleY = round$8(rect.height) / element.offsetHeight || 1 return scaleX !== 1 || scaleY !== 1 } function getCompositeRect(elementOrVirtualElement, offsetParent, isFixed) { if (isFixed === void 0) { isFixed = false } var isOffsetParentAnElement = isHTMLElement$1(offsetParent) var offsetParentIsScaled = isHTMLElement$1(offsetParent) && isElementScaled(offsetParent) var documentElement = getDocumentElement(offsetParent) var rect = getBoundingClientRect( elementOrVirtualElement, offsetParentIsScaled, isFixed ) var scroll = { scrollLeft: 0, scrollTop: 0, } var offsets = { x: 0, y: 0, } if (isOffsetParentAnElement || (!isOffsetParentAnElement && !isFixed)) { if ( getNodeName(offsetParent) !== 'body' || isScrollParent(documentElement) ) { scroll = getNodeScroll(offsetParent) } if (isHTMLElement$1(offsetParent)) { offsets = getBoundingClientRect(offsetParent, true) offsets.x += offsetParent.clientLeft offsets.y += offsetParent.clientTop } else if (documentElement) { offsets.x = getWindowScrollBarX(documentElement) } } return { x: rect.left + scroll.scrollLeft - offsets.x, y: rect.top + scroll.scrollTop - offsets.y, width: rect.width, height: rect.height, } } function order(modifiers) { var map2 = /* @__PURE__ */ new Map() var visited = /* @__PURE__ */ new Set() var result = [] modifiers.forEach(function (modifier) { map2.set(modifier.name, modifier) }) function sort3(modifier) { visited.add(modifier.name) var requires = [].concat( modifier.requires || [], modifier.requiresIfExists || [] ) requires.forEach(function (dep) { if (!visited.has(dep)) { var depModifier = map2.get(dep) if (depModifier) { sort3(depModifier) } } }) result.push(modifier) } modifiers.forEach(function (modifier) { if (!visited.has(modifier.name)) { sort3(modifier) } }) return result } function orderModifiers(modifiers) { var orderedModifiers = order(modifiers) return modifierPhases.reduce(function (acc, phase) { return acc.concat( orderedModifiers.filter(function (modifier) { return modifier.phase === phase }) ) }, []) } function debounce$2(fn2) { var pending return function () { if (!pending) { pending = new Promise(function (resolve2) { Promise.resolve().then(function () { pending = void 0 resolve2(fn2()) }) }) } return pending } } function mergeByName(modifiers) { var merged = modifiers.reduce(function (merged2, current2) { var existing = merged2[current2.name] merged2[current2.name] = existing ? Object.assign({}, existing, current2, { options: Object.assign({}, existing.options, current2.options), data: Object.assign({}, existing.data, current2.data), }) : current2 return merged2 }, {}) return Object.keys(merged).map(function (key2) { return merged[key2] }) } var DEFAULT_OPTIONS$1 = { placement: 'bottom', modifiers: [], strategy: 'absolute', } function areValidElements() { for ( var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++ ) { args[_key] = arguments[_key] } return !args.some(function (element) { return !(element && typeof element.getBoundingClientRect === 'function') }) } function popperGenerator(generatorOptions) { if (generatorOptions === void 0) { generatorOptions = {} } var _generatorOptions = generatorOptions, _generatorOptions$def = _generatorOptions.defaultModifiers, defaultModifiers2 = _generatorOptions$def === void 0 ? [] : _generatorOptions$def, _generatorOptions$def2 = _generatorOptions.defaultOptions, defaultOptions2 = _generatorOptions$def2 === void 0 ? DEFAULT_OPTIONS$1 : _generatorOptions$def2 return function createPopper2(reference2, popper2, options2) { if (options2 === void 0) { options2 = defaultOptions2 } var state2 = { placement: 'bottom', orderedModifiers: [], options: Object.assign({}, DEFAULT_OPTIONS$1, defaultOptions2), modifiersData: {}, elements: { reference: reference2, popper: popper2, }, attributes: {}, styles: {}, } var effectCleanupFns = [] var isDestroyed = false var instance = { state: state2, setOptions: function setOptions(setOptionsAction) { var options3 = typeof setOptionsAction === 'function' ? setOptionsAction(state2.options) : setOptionsAction cleanupModifierEffects() state2.options = Object.assign( {}, defaultOptions2, state2.options, options3 ) state2.scrollParents = { reference: isElement$2(reference2) ? listScrollParents(reference2) : reference2.contextElement ? listScrollParents(reference2.contextElement) : [], popper: listScrollParents(popper2), } var orderedModifiers = orderModifiers( mergeByName([].concat(defaultModifiers2, state2.options.modifiers)) ) state2.orderedModifiers = orderedModifiers.filter(function (m2) { return m2.enabled }) runModifierEffects() return instance.update() }, forceUpdate: function forceUpdate() { if (isDestroyed) { return } var _state$elements = state2.elements, reference3 = _state$elements.reference, popper3 = _state$elements.popper if (!areValidElements(reference3, popper3)) { return } state2.rects = { reference: getCompositeRect( reference3, getOffsetParent(popper3), state2.options.strategy === 'fixed' ), popper: getLayoutRect$1(popper3), } state2.reset = false state2.placement = state2.options.placement state2.orderedModifiers.forEach(function (modifier) { return (state2.modifiersData[modifier.name] = Object.assign( {}, modifier.data )) }) for ( var index2 = 0; index2 < state2.orderedModifiers.length; index2++ ) { if (state2.reset === true) { state2.reset = false index2 = -1 continue } var _state$orderedModifie = state2.orderedModifiers[index2], fn2 = _state$orderedModifie.fn, _state$orderedModifie2 = _state$orderedModifie.options, _options = _state$orderedModifie2 === void 0 ? {} : _state$orderedModifie2, name2 = _state$orderedModifie.name if (typeof fn2 === 'function') { state2 = fn2({ state: state2, options: _options, name: name2, instance, }) || state2 } } }, update: debounce$2(function () { return new Promise(function (resolve2) { instance.forceUpdate() resolve2(state2) }) }), destroy: function destroy2() { cleanupModifierEffects() isDestroyed = true }, } if (!areValidElements(reference2, popper2)) { return instance } instance.setOptions(options2).then(function (state3) { if (!isDestroyed && options2.onFirstUpdate) { options2.onFirstUpdate(state3) } }) function runModifierEffects() { state2.orderedModifiers.forEach(function (_ref2) { var name2 = _ref2.name, _ref$options = _ref2.options, options3 = _ref$options === void 0 ? {} : _ref$options, effect2 = _ref2.effect if (typeof effect2 === 'function') { var cleanupFn = effect2({ state: state2, name: name2, instance, options: options3, }) var noopFn = function noopFn2() {} effectCleanupFns.push(cleanupFn || noopFn) } }) } function cleanupModifierEffects() { effectCleanupFns.forEach(function (fn2) { return fn2() }) effectCleanupFns = [] } return instance } } var defaultModifiers = [ eventListeners, popperOffsets$1, computeStyles$1, applyStyles$1, offset$1, flip$1, preventOverflow$1, arrow$1, hide$1, ] var createPopper = /* @__PURE__ */ popperGenerator({ defaultModifiers, }) const POSITIONING_STRATEGIES = ['fixed', 'absolute'] const usePopperCoreConfigProps = buildProps({ boundariesPadding: { type: Number, default: 0, }, fallbackPlacements: { type: definePropType(Array), default: () => [], }, gpuAcceleration: { type: Boolean, default: true, }, offset: { type: Number, default: 12, }, placement: { type: String, values: placements, default: 'bottom', }, popperOptions: { type: definePropType(Object), default: () => ({}), }, strategy: { type: String, values: POSITIONING_STRATEGIES, default: 'absolute', }, }) const usePopperContentProps = buildProps({ ...usePopperCoreConfigProps, style: { type: definePropType([String, Array, Object]) }, className: { type: definePropType([String, Array, Object]) }, effect: { type: String, default: 'dark', }, visible: Boolean, enterable: { type: Boolean, default: true, }, pure: Boolean, popperClass: { type: definePropType([String, Array, Object]), }, popperStyle: { type: definePropType([String, Array, Object]), }, referenceEl: { type: definePropType(Object), }, stopPopperMouseEvent: { type: Boolean, default: true, }, zIndex: Number, }) const buildPopperOptions = (props2, arrowProps) => { const { placement, strategy, popperOptions: popperOptions2 } = props2 const options2 = { placement, strategy, ...popperOptions2, modifiers: genModifiers(props2), } attachArrow(options2, arrowProps) deriveExtraModifiers( options2, popperOptions2 == null ? void 0 : popperOptions2.modifiers ) return options2 } const unwrapMeasurableEl = ($el) => { if (!isClient$1) return return unrefElement$1($el) } function genModifiers(options2) { const { offset: offset2, gpuAcceleration, fallbackPlacements } = options2 return [ { name: 'offset', options: { offset: [0, offset2 != null ? offset2 : 12], }, }, { name: 'preventOverflow', options: { padding: { top: 2, bottom: 2, left: 5, right: 5, }, }, }, { name: 'flip', options: { padding: 5, fallbackPlacements: fallbackPlacements != null ? fallbackPlacements : [], }, }, { name: 'computeStyles', options: { gpuAcceleration, adaptive: gpuAcceleration, }, }, ] } function attachArrow(options2, { arrowEl, arrowOffset }) { options2.modifiers.push({ name: 'arrow', options: { element: arrowEl, padding: arrowOffset != null ? arrowOffset : 5, }, }) } function deriveExtraModifiers(options2, modifiers) { if (modifiers) { options2.modifiers = [ ...options2.modifiers, ...(modifiers != null ? modifiers : []), ] } } const __default__$I = { name: 'ElPopperContent', } const _sfc_main$9c = /* @__PURE__ */ defineComponent({ ...__default__$I, props: usePopperContentProps, emits: ['mouseenter', 'mouseleave'], setup(__props2, { expose }) { const props2 = __props2 const { popperInstanceRef, contentRef, triggerRef: triggerRef2, } = inject(POPPER_INJECTION_KEY, void 0) const { nextZIndex: nextZIndex2 } = useZIndex() const ns = useNamespace('popper') const popperContentRef = ref() const arrowRef = ref() const arrowOffset = ref() provide(POPPER_CONTENT_INJECTION_KEY, { arrowRef, arrowOffset, }) const contentZIndex = ref(props2.zIndex || nextZIndex2()) const computedReference = computed( () => unwrapMeasurableEl(props2.referenceEl) || unref(triggerRef2) ) const contentStyle = computed(() => [ { zIndex: unref(contentZIndex) }, props2.popperStyle, ]) const contentClass = computed(() => [ ns.b(), ns.is('pure', props2.pure), ns.is(props2.effect), props2.popperClass, ]) const createPopperInstance = ({ referenceEl, popperContentEl, arrowEl, }) => { const options2 = buildPopperOptions(props2, { arrowEl, arrowOffset: unref(arrowOffset), }) return createPopper(referenceEl, popperContentEl, options2) } const updatePopper = () => { var _a2 ;(_a2 = unref(popperInstanceRef)) == null ? void 0 : _a2.update() contentZIndex.value = props2.zIndex || nextZIndex2() } const togglePopperAlive = () => { var _a2, _b2 const monitorable = { name: 'eventListeners', enabled: props2.visible } ;(_b2 = (_a2 = unref(popperInstanceRef)) == null ? void 0 : _a2.setOptions) == null ? void 0 : _b2.call(_a2, (options2) => ({ ...options2, modifiers: [...(options2.modifiers || []), monitorable], })) updatePopper() } onMounted(() => { let updateHandle watch$1( computedReference, (referenceEl) => { var _a2 updateHandle == null ? void 0 : updateHandle() const popperInstance = unref(popperInstanceRef) ;(_a2 = popperInstance == null ? void 0 : popperInstance.destroy) == null ? void 0 : _a2.call(popperInstance) if (referenceEl) { const popperContentEl = unref(popperContentRef) contentRef.value = popperContentEl popperInstanceRef.value = createPopperInstance({ referenceEl, popperContentEl, arrowEl: unref(arrowRef), }) updateHandle = watch$1( () => referenceEl.getBoundingClientRect(), () => updatePopper(), { immediate: true, } ) } else { popperInstanceRef.value = void 0 } }, { immediate: true, } ) watch$1(() => props2.visible, togglePopperAlive, { immediate: true }) watch$1( () => buildPopperOptions(props2, { arrowEl: unref(arrowRef), arrowOffset: unref(arrowOffset), }), (option2) => { var _a2 return (_a2 = popperInstanceRef.value) == null ? void 0 : _a2.setOptions(option2) } ) }) expose({ popperContentRef, popperInstanceRef, updatePopper, contentStyle, }) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { ref_key: 'popperContentRef', ref: popperContentRef, style: normalizeStyle$1(unref(contentStyle)), class: normalizeClass(unref(contentClass)), role: 'tooltip', onMouseenter: _cache[0] || (_cache[0] = (e2) => _ctx.$emit('mouseenter', e2)), onMouseleave: _cache[1] || (_cache[1] = (e2) => _ctx.$emit('mouseleave', e2)), }, [renderSlot(_ctx.$slots, 'default')], 38 ) ) } }, }) var ElPopperContent = /* @__PURE__ */ _export_sfc$1(_sfc_main$9c, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/popper/src/content.vue', ], ]) const Effect = { LIGHT: 'light', DARK: 'dark', } const usePopperProps = buildProps({ autoClose: { type: Number, default: 0, }, cutoff: { type: Boolean, default: false, }, disabled: { type: Boolean, default: false, }, }) function useDeprecateAppendToBody(scope, from) { const vm = getCurrentInstance() const compatTeleported = computed(() => { return isBoolean$5(vm.props[from]) ? vm.props[from] : vm.props.teleported }) useDeprecated( { scope, from, replacement: 'teleported', version: '2.1.0', ref: 'https://element-plus.org/en-US/component/tooltip.html#attributes', }, computed(() => isBoolean$5(vm.props[from])) ) return { compatTeleported, } } const ElPopper = withInstall(Popper) const _sfc_main$9b = defineComponent({ name: 'ElVisuallyHidden', props: { style: { type: [String, Object, Array], }, }, setup(props2) { return { computedStyle: computed(() => { return [ props2.style, { position: 'absolute', border: 0, width: 1, height: 1, padding: 0, margin: -1, overflow: 'hidden', clip: 'rect(0, 0, 0, 0)', whiteSpace: 'nowrap', wordWrap: 'normal', }, ] }), } }, }) function _sfc_render$1G(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock( 'span', mergeProps(_ctx.$attrs, { style: _ctx.computedStyle }), [renderSlot(_ctx.$slots, 'default')], 16 ) ) } var ElVisuallyHidden = /* @__PURE__ */ _export_sfc$1(_sfc_main$9b, [ ['render', _sfc_render$1G], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/visual-hidden/src/visual-hidden.vue', ], ]) const useTooltipContentProps = buildProps({ ...useDelayedToggleProps, ...usePopperContentProps, appendTo: { type: definePropType([String, Object]), default: POPPER_CONTAINER_SELECTOR, }, content: { type: String, default: '', }, rawContent: { type: Boolean, default: false, }, persistent: Boolean, ariaLabel: String, visible: { type: definePropType(Boolean), default: null, }, transition: { type: String, default: 'el-fade-in-linear', }, teleported: { type: Boolean, default: true, }, disabled: { type: Boolean, }, }) const useTooltipTriggerProps = buildProps({ ...usePopperTriggerProps, disabled: Boolean, trigger: { type: definePropType([String, Array]), default: 'hover', }, }) const useTooltipProps = buildProps({ openDelay: { type: Number, }, visibleArrow: { type: Boolean, default: void 0, }, hideAfter: { type: Number, default: 200, }, showArrow: { type: Boolean, default: true, }, }) const TOOLTIP_INJECTION_KEY = Symbol('elTooltip') const _sfc_main$9a = defineComponent({ name: 'ElTooltipContent', components: { ElPopperContent, ElVisuallyHidden, }, inheritAttrs: false, props: useTooltipContentProps, setup(props2) { const contentRef = ref(null) const intermediateOpen = ref(false) const entering = ref(false) const leaving = ref(false) const destroyed = ref(false) const { controlled, id: id2, open: open2, trigger: trigger2, onClose, onOpen, onShow, onHide, onBeforeShow, onBeforeHide, } = inject(TOOLTIP_INJECTION_KEY, void 0) const persistentRef = computed(() => { return props2.persistent }) onBeforeUnmount(() => { destroyed.value = true }) const shouldRender = computed(() => { return unref(persistentRef) ? true : unref(open2) }) const shouldShow = computed(() => { return props2.disabled ? false : unref(open2) }) const contentStyle = computed(() => { var _a2 return (_a2 = props2.style) != null ? _a2 : {} }) const ariaHidden = computed(() => !unref(open2)) useEscapeKeydown(onClose) const onTransitionLeave = () => { onHide() } const stopWhenControlled = () => { if (unref(controlled)) return true } const onContentEnter = composeEventHandlers(stopWhenControlled, () => { if (props2.enterable && unref(trigger2) === 'hover') { onOpen() } }) const onContentLeave = composeEventHandlers(stopWhenControlled, () => { if (unref(trigger2) === 'hover') { onClose() } }) const onBeforeEnter = () => { var _a2, _b2 ;(_b2 = (_a2 = contentRef.value) == null ? void 0 : _a2.updatePopper) == null ? void 0 : _b2.call(_a2) onBeforeShow == null ? void 0 : onBeforeShow() } const onBeforeLeave = () => { onBeforeHide == null ? void 0 : onBeforeHide() } const onAfterShow = () => { onShow() } let stopHandle watch$1( () => unref(open2), (val2) => { if (val2) { stopHandle = onClickOutside$1( computed(() => { var _a2 return (_a2 = contentRef.value) == null ? void 0 : _a2.popperContentRef }), () => { if (unref(controlled)) return const $trigger = unref(trigger2) if ($trigger !== 'hover') { onClose() } } ) } else { stopHandle == null ? void 0 : stopHandle() } }, { flush: 'post', } ) return { ariaHidden, entering, leaving, id: id2, intermediateOpen, contentStyle, contentRef, destroyed, shouldRender, shouldShow, open: open2, onAfterShow, onBeforeEnter, onBeforeLeave, onContentEnter, onContentLeave, onTransitionLeave, } }, }) function _sfc_render$1F(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_visually_hidden = resolveComponent('el-visually-hidden') const _component_el_popper_content = resolveComponent('el-popper-content') return ( openBlock(), createBlock( Teleport, { disabled: !_ctx.teleported, to: _ctx.appendTo, }, [ createVNode$1( Transition, { name: _ctx.transition, onAfterLeave: _ctx.onTransitionLeave, onBeforeEnter: _ctx.onBeforeEnter, onAfterEnter: _ctx.onAfterShow, onBeforeLeave: _ctx.onBeforeLeave, }, { default: withCtx(() => [ _ctx.shouldRender ? withDirectives( (openBlock(), createBlock( _component_el_popper_content, mergeProps( { key: 0, ref: 'contentRef', }, _ctx.$attrs, { 'aria-hidden': _ctx.ariaHidden, 'boundaries-padding': _ctx.boundariesPadding, 'fallback-placements': _ctx.fallbackPlacements, 'gpu-acceleration': _ctx.gpuAcceleration, offset: _ctx.offset, placement: _ctx.placement, 'popper-options': _ctx.popperOptions, strategy: _ctx.strategy, effect: _ctx.effect, enterable: _ctx.enterable, pure: _ctx.pure, 'popper-class': _ctx.popperClass, 'popper-style': [_ctx.popperStyle, _ctx.contentStyle], 'reference-el': _ctx.referenceEl, visible: _ctx.shouldShow, 'z-index': _ctx.zIndex, onMouseenter: _ctx.onContentEnter, onMouseleave: _ctx.onContentLeave, } ), { default: withCtx(() => [ createCommentVNode(' Workaround bug #6378 '), !_ctx.destroyed ? (openBlock(), createElementBlock( Fragment, { key: 0 }, [ renderSlot(_ctx.$slots, 'default'), createVNode$1( _component_el_visually_hidden, { id: _ctx.id, role: 'tooltip', }, { default: withCtx(() => [ createTextVNode( toDisplayString$1(_ctx.ariaLabel), 1 ), ]), _: 1, }, 8, ['id'] ), ], 64 )) : createCommentVNode('v-if', true), ]), _: 3, }, 16, [ 'aria-hidden', 'boundaries-padding', 'fallback-placements', 'gpu-acceleration', 'offset', 'placement', 'popper-options', 'strategy', 'effect', 'enterable', 'pure', 'popper-class', 'popper-style', 'reference-el', 'visible', 'z-index', 'onMouseenter', 'onMouseleave', ] )), [[vShow, _ctx.shouldShow]] ) : createCommentVNode('v-if', true), ]), _: 3, }, 8, [ 'name', 'onAfterLeave', 'onBeforeEnter', 'onAfterEnter', 'onBeforeLeave', ] ), ], 8, ['disabled', 'to'] ) ) } var ElTooltipContent = /* @__PURE__ */ _export_sfc$1(_sfc_main$9a, [ ['render', _sfc_render$1F], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/tooltip/src/content.vue', ], ]) const isTriggerType = (trigger2, type4) => { if (isArray$D(trigger2)) { return trigger2.includes(type4) } return trigger2 === type4 } const whenTrigger = (trigger2, type4, handler) => { return (e2) => { isTriggerType(unref(trigger2), type4) && handler(e2) } } const _sfc_main$99 = defineComponent({ name: 'ElTooltipTrigger', components: { ElPopperTrigger, }, props: useTooltipTriggerProps, setup(props2) { const ns = useNamespace('tooltip') const { controlled, id: id2, open: open2, onOpen, onClose, onToggle, } = inject(TOOLTIP_INJECTION_KEY, void 0) const triggerRef2 = ref(null) const stopWhenControlledOrDisabled = () => { if (unref(controlled) || props2.disabled) { return true } } const trigger2 = toRef(props2, 'trigger') const onMouseenter = composeEventHandlers( stopWhenControlledOrDisabled, whenTrigger(trigger2, 'hover', onOpen) ) const onMouseleave = composeEventHandlers( stopWhenControlledOrDisabled, whenTrigger(trigger2, 'hover', onClose) ) const onClick = composeEventHandlers( stopWhenControlledOrDisabled, whenTrigger(trigger2, 'click', (e2) => { if (e2.button === 0) { onToggle(e2) } }) ) const onFocus = composeEventHandlers( stopWhenControlledOrDisabled, whenTrigger(trigger2, 'focus', onOpen) ) const onBlur = composeEventHandlers( stopWhenControlledOrDisabled, whenTrigger(trigger2, 'focus', onClose) ) const onContextMenu = composeEventHandlers( stopWhenControlledOrDisabled, whenTrigger(trigger2, 'contextmenu', (e2) => { e2.preventDefault() onToggle(e2) }) ) const onKeydown = composeEventHandlers( stopWhenControlledOrDisabled, (e2) => { const { code: code2 } = e2 if (code2 === EVENT_CODE.enter || code2 === EVENT_CODE.space) { onToggle(e2) } } ) return { onBlur, onContextMenu, onFocus, onMouseenter, onMouseleave, onClick, onKeydown, open: open2, id: id2, triggerRef: triggerRef2, ns, } }, }) function _sfc_render$1E(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_popper_trigger = resolveComponent('el-popper-trigger') return ( openBlock(), createBlock( _component_el_popper_trigger, { id: _ctx.id, 'virtual-ref': _ctx.virtualRef, open: _ctx.open, 'virtual-triggering': _ctx.virtualTriggering, class: normalizeClass(_ctx.ns.e('trigger')), onBlur: _ctx.onBlur, onClick: _ctx.onClick, onContextmenu: _ctx.onContextMenu, onFocus: _ctx.onFocus, onMouseenter: _ctx.onMouseenter, onMouseleave: _ctx.onMouseleave, onKeydown: _ctx.onKeydown, }, { default: withCtx(() => [renderSlot(_ctx.$slots, 'default')]), _: 3, }, 8, [ 'id', 'virtual-ref', 'open', 'virtual-triggering', 'class', 'onBlur', 'onClick', 'onContextmenu', 'onFocus', 'onMouseenter', 'onMouseleave', 'onKeydown', ] ) ) } var ElTooltipTrigger = /* @__PURE__ */ _export_sfc$1(_sfc_main$99, [ ['render', _sfc_render$1E], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/tooltip/src/trigger.vue', ], ]) const { useModelToggleProps, useModelToggle, useModelToggleEmits } = createModelToggleComposable('visible') const _sfc_main$98 = defineComponent({ name: 'ElTooltip', components: { ElPopper, ElPopperArrow, ElTooltipContent, ElTooltipTrigger, }, props: { ...useModelToggleProps, ...useTooltipContentProps, ...useTooltipTriggerProps, ...usePopperArrowProps, ...useTooltipProps, }, emits: [...useModelToggleEmits, 'before-show', 'before-hide', 'show', 'hide'], setup(props2, { emit: emit2 }) { usePopperContainer() const compatShowAfter = computed(() => { if (!isUndefined$c(props2.openDelay)); return props2.openDelay || props2.showAfter }) const compatShowArrow = computed(() => { if (!isUndefined$c(props2.visibleArrow)); return isBoolean$5(props2.visibleArrow) ? props2.visibleArrow : props2.showArrow }) const id2 = useId() const popperRef = ref(null) const updatePopper = () => { var _a2 const popperComponent = unref(popperRef) if (popperComponent) { ;(_a2 = popperComponent.popperInstanceRef) == null ? void 0 : _a2.update() } } const open2 = ref(false) const { show, hide: hide2 } = useModelToggle({ indicator: open2, }) const { onOpen, onClose } = useDelayedToggle({ showAfter: compatShowAfter, hideAfter: toRef(props2, 'hideAfter'), open: show, close: hide2, }) const controlled = computed(() => isBoolean$5(props2.visible)) provide(TOOLTIP_INJECTION_KEY, { controlled, id: id2, open: readonly(open2), trigger: toRef(props2, 'trigger'), onOpen, onClose, onToggle: () => { if (unref(open2)) { onClose() } else { onOpen() } }, onShow: () => { emit2('show') }, onHide: () => { emit2('hide') }, onBeforeShow: () => { emit2('before-show') }, onBeforeHide: () => { emit2('before-hide') }, updatePopper, }) watch$1( () => props2.disabled, (disabled) => { if (disabled && open2.value) { open2.value = false } } ) return { compatShowAfter, compatShowArrow, popperRef, open: open2, hide: hide2, updatePopper, onOpen, onClose, } }, }) const _hoisted_1$6_ = ['innerHTML'] const _hoisted_2$5A = { key: 1 } function _sfc_render$1D(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_tooltip_trigger = resolveComponent('el-tooltip-trigger') const _component_el_popper_arrow = resolveComponent('el-popper-arrow') const _component_el_tooltip_content = resolveComponent('el-tooltip-content') const _component_el_popper = resolveComponent('el-popper') return ( openBlock(), createBlock( _component_el_popper, { ref: 'popperRef' }, { default: withCtx(() => [ createVNode$1( _component_el_tooltip_trigger, { disabled: _ctx.disabled, trigger: _ctx.trigger, 'virtual-ref': _ctx.virtualRef, 'virtual-triggering': _ctx.virtualTriggering, }, { default: withCtx(() => [ _ctx.$slots.default ? renderSlot(_ctx.$slots, 'default', { key: 0 }) : createCommentVNode('v-if', true), ]), _: 3, }, 8, ['disabled', 'trigger', 'virtual-ref', 'virtual-triggering'] ), createVNode$1( _component_el_tooltip_content, { 'aria-label': _ctx.ariaLabel, 'boundaries-padding': _ctx.boundariesPadding, content: _ctx.content, disabled: _ctx.disabled, effect: _ctx.effect, enterable: _ctx.enterable, 'fallback-placements': _ctx.fallbackPlacements, 'hide-after': _ctx.hideAfter, 'gpu-acceleration': _ctx.gpuAcceleration, offset: _ctx.offset, persistent: _ctx.persistent, 'popper-class': _ctx.popperClass, 'popper-style': _ctx.popperStyle, placement: _ctx.placement, 'popper-options': _ctx.popperOptions, pure: _ctx.pure, 'raw-content': _ctx.rawContent, 'reference-el': _ctx.referenceEl, 'show-after': _ctx.compatShowAfter, strategy: _ctx.strategy, teleported: _ctx.teleported, transition: _ctx.transition, 'z-index': _ctx.zIndex, 'append-to': _ctx.appendTo, }, { default: withCtx(() => [ renderSlot(_ctx.$slots, 'content', {}, () => [ _ctx.rawContent ? (openBlock(), createElementBlock( 'span', { key: 0, innerHTML: _ctx.content, }, null, 8, _hoisted_1$6_ )) : (openBlock(), createElementBlock( 'span', _hoisted_2$5A, toDisplayString$1(_ctx.content), 1 )), ]), _ctx.compatShowArrow ? (openBlock(), createBlock( _component_el_popper_arrow, { key: 0, 'arrow-offset': _ctx.arrowOffset, }, null, 8, ['arrow-offset'] )) : createCommentVNode('v-if', true), ]), _: 3, }, 8, [ 'aria-label', 'boundaries-padding', 'content', 'disabled', 'effect', 'enterable', 'fallback-placements', 'hide-after', 'gpu-acceleration', 'offset', 'persistent', 'popper-class', 'popper-style', 'placement', 'popper-options', 'pure', 'raw-content', 'reference-el', 'show-after', 'strategy', 'teleported', 'transition', 'z-index', 'append-to', ] ), ]), _: 3, }, 512 ) ) } var Tooltip$1 = /* @__PURE__ */ _export_sfc$1(_sfc_main$98, [ ['render', _sfc_render$1D], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/tooltip/src/tooltip.vue', ], ]) const ElTooltip = withInstall(Tooltip$1) const autocompleteProps = buildProps({ valueKey: { type: String, default: 'value', }, modelValue: { type: [String, Number], default: '', }, debounce: { type: Number, default: 300, }, placement: { type: definePropType(String), values: [ 'top', 'top-start', 'top-end', 'bottom', 'bottom-start', 'bottom-end', ], default: 'bottom-start', }, fetchSuggestions: { type: definePropType([Function, Array]), default: NOOP, }, popperClass: { type: String, default: '', }, triggerOnFocus: { type: Boolean, default: true, }, selectWhenUnmatched: { type: Boolean, default: false, }, hideLoading: { type: Boolean, default: false, }, popperAppendToBody: { type: Boolean, default: void 0, }, teleported: useTooltipContentProps.teleported, highlightFirstItem: { type: Boolean, default: false, }, }) const autocompleteEmits = { [UPDATE_MODEL_EVENT]: (value2) => isString$f(value2), input: (value2) => isString$f(value2), change: (value2) => isString$f(value2), focus: (evt) => evt instanceof FocusEvent, blur: (evt) => evt instanceof FocusEvent, clear: () => true, select: (item2) => isObject$v(item2), } const _hoisted_1$6Z = ['aria-expanded', 'aria-owns'] const _hoisted_2$5z = { key: 0 } const _hoisted_3$4R = ['id', 'aria-selected', 'onClick'] const __default__$H = { name: 'ElAutocomplete', inheritAttrs: false, } const _sfc_main$97 = /* @__PURE__ */ defineComponent({ ...__default__$H, props: autocompleteProps, emits: autocompleteEmits, setup(__props2, { expose, emit: emit2 }) { const props2 = __props2 const COMPONENT_NAME2 = 'ElAutocomplete' const ns = useNamespace('autocomplete') const { compatTeleported } = useDeprecateAppendToBody( COMPONENT_NAME2, 'popperAppendToBody' ) let isClear = false const attrs = useAttrs() const compAttrs = useAttrs$1() const suggestions = ref([]) const highlightedIndex = ref(-1) const dropdownWidth = ref('') const activated = ref(false) const suggestionDisabled = ref(false) const loading$1 = ref(false) const inputRef = ref() const regionRef = ref() const popperRef = ref() const listboxRef = ref() const id2 = computed(() => { return ns.b(String(generateId())) }) const styles = computed(() => compAttrs.style) const suggestionVisible = computed(() => { const isValidData = isArray$D(suggestions.value) && suggestions.value.length > 0 return (isValidData || loading$1.value) && activated.value }) const suggestionLoading = computed(() => { return !props2.hideLoading && loading$1.value }) const onSuggestionShow = () => { nextTick(() => { if (suggestionVisible.value) { dropdownWidth.value = `${inputRef.value.$el.offsetWidth}px` } }) } const getData = (queryString) => { if (suggestionDisabled.value) { return } loading$1.value = true const cb = (suggestionsArg) => { loading$1.value = false if (suggestionDisabled.value) { return } if (isArray$D(suggestionsArg)) { suggestions.value = suggestionsArg highlightedIndex.value = props2.highlightFirstItem ? 0 : -1 } else { throwError$1( COMPONENT_NAME2, 'autocomplete suggestions must be an array' ) } } if (isArray$D(props2.fetchSuggestions)) { cb(props2.fetchSuggestions) } else { const result = props2.fetchSuggestions(queryString, cb) if (isArray$D(result)) { cb(result) } else if (isPromise$1(result)) { result.then(cb) } } } const debouncedGetData = debounce$3(getData, props2.debounce) const handleInput = (value2) => { const valuePresented = Boolean(value2) emit2('input', value2) emit2(UPDATE_MODEL_EVENT, value2) suggestionDisabled.value = false activated.value || (activated.value = isClear && valuePresented) if (!props2.triggerOnFocus && !value2) { suggestionDisabled.value = true suggestions.value = [] return } if (isClear && valuePresented) { isClear = false } debouncedGetData(value2) } const handleChange = (value2) => { emit2('change', value2) } const handleFocus = (evt) => { activated.value = true emit2('focus', evt) if (props2.triggerOnFocus) { debouncedGetData(String(props2.modelValue)) } } const handleBlur = (evt) => { emit2('blur', evt) } const handleClear = () => { activated.value = false isClear = true emit2(UPDATE_MODEL_EVENT, '') emit2('clear') } const handleKeyEnter = () => { if ( suggestionVisible.value && highlightedIndex.value >= 0 && highlightedIndex.value < suggestions.value.length ) { handleSelect(suggestions.value[highlightedIndex.value]) } else if (props2.selectWhenUnmatched) { emit2('select', { value: props2.modelValue }) nextTick(() => { suggestions.value = [] highlightedIndex.value = -1 }) } } const close2 = () => { activated.value = false } const focus2 = () => { var _a2 ;(_a2 = inputRef.value) == null ? void 0 : _a2.focus() } const handleSelect = (item2) => { emit2('input', item2[props2.valueKey]) emit2(UPDATE_MODEL_EVENT, item2[props2.valueKey]) emit2('select', item2) nextTick(() => { suggestions.value = [] highlightedIndex.value = -1 }) } const highlight = (index2) => { if (!suggestionVisible.value || loading$1.value) { return } if (index2 < 0) { highlightedIndex.value = -1 return } if (index2 >= suggestions.value.length) { index2 = suggestions.value.length - 1 } const suggestion = regionRef.value.querySelector( `.${ns.be('suggestion', 'wrap')}` ) const suggestionList = suggestion.querySelectorAll( `.${ns.be('suggestion', 'list')} li` ) const highlightItem = suggestionList[index2] const scrollTop = suggestion.scrollTop const { offsetTop, scrollHeight } = highlightItem if (offsetTop + scrollHeight > scrollTop + suggestion.clientHeight) { suggestion.scrollTop += scrollHeight } if (offsetTop < scrollTop) { suggestion.scrollTop -= scrollHeight } highlightedIndex.value = index2 inputRef.value.ref.setAttribute( 'aria-activedescendant', `${id2.value}-item-${highlightedIndex.value}` ) } onClickOutside$1(listboxRef, close2) onMounted(() => { inputRef.value.ref.setAttribute('role', 'textbox') inputRef.value.ref.setAttribute('aria-autocomplete', 'list') inputRef.value.ref.setAttribute('aria-controls', 'id') inputRef.value.ref.setAttribute( 'aria-activedescendant', `${id2.value}-item-${highlightedIndex.value}` ) }) expose({ highlightedIndex, activated, loading: loading$1, inputRef, popperRef, suggestions, handleSelect, handleKeyEnter, focus: focus2, close: close2, highlight, }) return (_ctx, _cache) => { return ( openBlock(), createBlock( unref(ElTooltip), { ref_key: 'popperRef', ref: popperRef, visible: unref(suggestionVisible), 'onUpdate:visible': _cache[2] || (_cache[2] = ($event) => isRef(suggestionVisible) ? (suggestionVisible.value = $event) : null), placement: _ctx.placement, 'fallback-placements': ['bottom-start', 'top-start'], 'popper-class': [unref(ns).e('popper'), _ctx.popperClass], teleported: unref(compatTeleported), 'gpu-acceleration': false, pure: '', 'manual-mode': '', effect: 'light', trigger: 'click', transition: `${unref(ns).namespace.value}-zoom-in-top`, persistent: '', onBeforeShow: onSuggestionShow, }, { content: withCtx(() => [ createElementVNode( 'div', { ref_key: 'regionRef', ref: regionRef, class: normalizeClass([ unref(ns).b('suggestion'), unref(ns).is('loading', unref(suggestionLoading)), ]), style: normalizeStyle$1({ minWidth: dropdownWidth.value, outline: 'none', }), role: 'region', }, [ createVNode$1( unref(ElScrollbar), { id: unref(id2), tag: 'ul', 'wrap-class': unref(ns).be('suggestion', 'wrap'), 'view-class': unref(ns).be('suggestion', 'list'), role: 'listbox', }, { default: withCtx(() => [ unref(suggestionLoading) ? (openBlock(), createElementBlock('li', _hoisted_2$5z, [ createVNode$1( unref(ElIcon), { class: normalizeClass( unref(ns).is('loading') ), }, { default: withCtx(() => [ createVNode$1(unref(loading)), ]), _: 1, }, 8, ['class'] ), ])) : (openBlock(true), createElementBlock( Fragment, { key: 1 }, renderList(suggestions.value, (item2, index2) => { return ( openBlock(), createElementBlock( 'li', { id: `${unref(id2)}-item-${index2}`, key: index2, class: normalizeClass({ highlighted: highlightedIndex.value === index2, }), role: 'option', 'aria-selected': highlightedIndex.value === index2, onClick: ($event) => handleSelect(item2), }, [ renderSlot( _ctx.$slots, 'default', { item: item2 }, () => [ createTextVNode( toDisplayString$1( item2[_ctx.valueKey] ), 1 ), ] ), ], 10, _hoisted_3$4R ) ) }), 128 )), ]), _: 3, }, 8, ['id', 'wrap-class', 'view-class'] ), ], 6 ), ]), default: withCtx(() => [ createElementVNode( 'div', { ref_key: 'listboxRef', ref: listboxRef, class: normalizeClass([unref(ns).b(), _ctx.$attrs.class]), style: normalizeStyle$1(unref(styles)), role: 'combobox', 'aria-haspopup': 'listbox', 'aria-expanded': unref(suggestionVisible), 'aria-owns': unref(id2), }, [ createVNode$1( unref(ElInput), mergeProps( { ref_key: 'inputRef', ref: inputRef, }, unref(attrs), { 'model-value': _ctx.modelValue, onInput: handleInput, onChange: handleChange, onFocus: handleFocus, onBlur: handleBlur, onClear: handleClear, onKeydown: [ _cache[0] || (_cache[0] = withKeys( withModifiers( ($event) => highlight(highlightedIndex.value - 1), ['prevent'] ), ['up'] )), _cache[1] || (_cache[1] = withKeys( withModifiers( ($event) => highlight(highlightedIndex.value + 1), ['prevent'] ), ['down'] )), withKeys(handleKeyEnter, ['enter']), withKeys(close2, ['tab']), ], } ), createSlots({ _: 2 }, [ _ctx.$slots.prepend ? { name: 'prepend', fn: withCtx(() => [ renderSlot(_ctx.$slots, 'prepend'), ]), } : void 0, _ctx.$slots.append ? { name: 'append', fn: withCtx(() => [ renderSlot(_ctx.$slots, 'append'), ]), } : void 0, _ctx.$slots.prefix ? { name: 'prefix', fn: withCtx(() => [ renderSlot(_ctx.$slots, 'prefix'), ]), } : void 0, _ctx.$slots.suffix ? { name: 'suffix', fn: withCtx(() => [ renderSlot(_ctx.$slots, 'suffix'), ]), } : void 0, ]), 1040, ['model-value', 'onKeydown'] ), ], 14, _hoisted_1$6Z ), ]), _: 3, }, 8, ['visible', 'placement', 'popper-class', 'teleported', 'transition'] ) ) } }, }) var Autocomplete = /* @__PURE__ */ _export_sfc$1(_sfc_main$97, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/autocomplete/src/autocomplete.vue', ], ]) const ElAutocomplete = withInstall(Autocomplete) const avatarProps = buildProps({ size: { type: [Number, String], values: componentSizes, default: '', validator: (val2) => typeof val2 === 'number', }, shape: { type: String, values: ['circle', 'square'], default: 'circle', }, icon: { type: iconPropType, }, src: { type: String, default: '', }, alt: String, srcSet: String, fit: { type: definePropType(String), default: 'cover', }, }) const avatarEmits = { error: (evt) => evt instanceof Event, } const _hoisted_1$6Y = ['src', 'alt', 'srcset'] const __default__$G = { name: 'ElAvatar', } const _sfc_main$96 = /* @__PURE__ */ defineComponent({ ...__default__$G, props: avatarProps, emits: avatarEmits, setup(__props2, { emit: emit2 }) { const props2 = __props2 const ns = useNamespace('avatar') const hasLoadError = ref(false) const avatarClass = computed(() => { const { size, icon, shape } = props2 const classList2 = [ns.b()] if (isString$f(size)) classList2.push(ns.m(size)) if (icon) classList2.push(ns.m('icon')) if (shape) classList2.push(ns.m(shape)) return classList2 }) const sizeStyle = computed(() => { const { size } = props2 return isNumber$h(size) ? { '--el-avatar-size': addUnit(size), } : void 0 }) const fitStyle = computed(() => ({ objectFit: props2.fit, })) watch$1( () => props2.src, () => (hasLoadError.value = false) ) function handleError(e2) { hasLoadError.value = true emit2('error', e2) } return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'span', { class: normalizeClass(unref(avatarClass)), style: normalizeStyle$1(unref(sizeStyle)), }, [ (_ctx.src || _ctx.srcSet) && !hasLoadError.value ? (openBlock(), createElementBlock( 'img', { key: 0, src: _ctx.src, alt: _ctx.alt, srcset: _ctx.srcSet, style: normalizeStyle$1(unref(fitStyle)), onError: handleError, }, null, 44, _hoisted_1$6Y )) : _ctx.icon ? (openBlock(), createBlock( unref(ElIcon), { key: 1 }, { default: withCtx(() => [ (openBlock(), createBlock(resolveDynamicComponent(_ctx.icon))), ]), _: 1, } )) : renderSlot(_ctx.$slots, 'default', { key: 2 }), ], 6 ) ) } }, }) var Avatar = /* @__PURE__ */ _export_sfc$1(_sfc_main$96, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/avatar/src/avatar.vue', ], ]) const ElAvatar = withInstall(Avatar) const backtopProps = { visibilityHeight: { type: Number, default: 200, }, target: { type: String, default: '', }, right: { type: Number, default: 40, }, bottom: { type: Number, default: 40, }, } const backtopEmits = { click: (evt) => evt instanceof MouseEvent, } const _hoisted_1$6X = ['onClick'] const __default__$F = { name: 'ElBacktop', } const _sfc_main$95 = /* @__PURE__ */ defineComponent({ ...__default__$F, props: backtopProps, emits: backtopEmits, setup(__props2, { emit: emit2 }) { const props2 = __props2 const COMPONENT_NAME2 = 'ElBacktop' const ns = useNamespace('backtop') const el2 = shallowRef() const container = shallowRef() const visible = ref(false) const backTopStyle = computed(() => ({ right: `${props2.right}px`, bottom: `${props2.bottom}px`, })) const scrollToTop = () => { if (!el2.value) return const beginTime = Date.now() const beginValue = el2.value.scrollTop const frameFunc = () => { if (!el2.value) return const progress = (Date.now() - beginTime) / 500 if (progress < 1) { el2.value.scrollTop = beginValue * (1 - easeInOutCubic(progress)) requestAnimationFrame(frameFunc) } else { el2.value.scrollTop = 0 } } requestAnimationFrame(frameFunc) } const handleScroll2 = () => { if (el2.value) visible.value = el2.value.scrollTop >= props2.visibilityHeight } const handleClick2 = (event) => { scrollToTop() emit2('click', event) } const handleScrollThrottled = useThrottleFn$1(handleScroll2, 300) onMounted(() => { var _a2 container.value = document el2.value = document.documentElement if (props2.target) { el2.value = (_a2 = document.querySelector(props2.target)) != null ? _a2 : void 0 if (!el2.value) { throwError$1( COMPONENT_NAME2, `target is not existed: ${props2.target}` ) } container.value = el2.value } useEventListener$1(container, 'scroll', handleScrollThrottled) }) return (_ctx, _cache) => { return ( openBlock(), createBlock( Transition, { name: `${unref(ns).namespace.value}-fade-in`, }, { default: withCtx(() => [ visible.value ? (openBlock(), createElementBlock( 'div', { key: 0, style: normalizeStyle$1(unref(backTopStyle)), class: normalizeClass(unref(ns).b()), onClick: withModifiers(handleClick2, ['stop']), }, [ renderSlot(_ctx.$slots, 'default', {}, () => [ createVNode$1( unref(ElIcon), { class: normalizeClass(unref(ns).e('icon')), }, { default: withCtx(() => [ createVNode$1(unref(caretTop)), ]), _: 1, }, 8, ['class'] ), ]), ], 14, _hoisted_1$6X )) : createCommentVNode('v-if', true), ]), _: 3, }, 8, ['name'] ) ) } }, }) var Backtop = /* @__PURE__ */ _export_sfc$1(_sfc_main$95, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/backtop/src/backtop.vue', ], ]) const ElBacktop = withInstall(Backtop) const badgeProps = buildProps({ value: { type: [String, Number], default: '', }, max: { type: Number, default: 99, }, isDot: Boolean, hidden: Boolean, type: { type: String, values: ['primary', 'success', 'warning', 'info', 'danger'], default: 'danger', }, }) const _hoisted_1$6W = ['textContent'] const __default__$E = { name: 'ElBadge', } const _sfc_main$94 = /* @__PURE__ */ defineComponent({ ...__default__$E, props: badgeProps, setup(__props2, { expose }) { const props2 = __props2 const ns = useNamespace('badge') const content2 = computed(() => { if (props2.isDot) return '' if (isNumber$h(props2.value) && isNumber$h(props2.max)) { return props2.max < props2.value ? `${props2.max}+` : `${props2.value}` } return `${props2.value}` }) expose({ content: content2, }) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { class: normalizeClass(unref(ns).b()), }, [ renderSlot(_ctx.$slots, 'default'), createVNode$1( Transition, { name: `${unref(ns).namespace.value}-zoom-in-center`, }, { default: withCtx(() => [ withDirectives( createElementVNode( 'sup', { class: normalizeClass([ unref(ns).e('content'), unref(ns).em('content', _ctx.type), unref(ns).is('fixed', !!_ctx.$slots.default), unref(ns).is('dot', _ctx.isDot), ]), textContent: toDisplayString$1(unref(content2)), }, null, 10, _hoisted_1$6W ), [ [ vShow, !_ctx.hidden && (unref(content2) || unref(content2) === '0' || _ctx.isDot), ], ] ), ]), _: 1, }, 8, ['name'] ), ], 2 ) ) } }, }) var Badge = /* @__PURE__ */ _export_sfc$1(_sfc_main$94, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/badge/src/badge.vue', ], ]) const ElBadge = withInstall(Badge) const breadcrumbProps = buildProps({ separator: { type: String, default: '/', }, separatorIcon: { type: iconPropType, default: '', }, }) const __default__$D = { name: 'ElBreadcrumb', } const _sfc_main$93 = /* @__PURE__ */ defineComponent({ ...__default__$D, props: breadcrumbProps, setup(__props2) { const props2 = __props2 const ns = useNamespace('breadcrumb') const breadcrumb = ref() provide(breadcrumbKey, props2) onMounted(() => { const items = breadcrumb.value.querySelectorAll(`.${ns.e('item')}`) if (items.length) { items[items.length - 1].setAttribute('aria-current', 'page') } }) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { ref_key: 'breadcrumb', ref: breadcrumb, class: normalizeClass(unref(ns).b()), 'aria-label': 'Breadcrumb', role: 'navigation', }, [renderSlot(_ctx.$slots, 'default')], 2 ) ) } }, }) var Breadcrumb$2 = /* @__PURE__ */ _export_sfc$1(_sfc_main$93, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/breadcrumb/src/breadcrumb.vue', ], ]) const breadcrumbItemProps = buildProps({ to: { type: definePropType([String, Object]), default: '', }, replace: { type: Boolean, default: false, }, }) const __default__$C = { name: 'ElBreadcrumbItem', } const _sfc_main$92 = /* @__PURE__ */ defineComponent({ ...__default__$C, props: breadcrumbItemProps, setup(__props2) { const props2 = __props2 const instance = getCurrentInstance() const router2 = instance.appContext.config.globalProperties.$router const breadcrumbInjection = inject(breadcrumbKey, {}) const ns = useNamespace('breadcrumb') const { separator, separatorIcon } = breadcrumbInjection const link2 = ref() const onClick = () => { if (!props2.to || !router2) return props2.replace ? router2.replace(props2.to) : router2.push(props2.to) } return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'span', { class: normalizeClass(unref(ns).e('item')), }, [ createElementVNode( 'span', { ref_key: 'link', ref: link2, class: normalizeClass([ unref(ns).e('inner'), unref(ns).is('link', !!_ctx.to), ]), role: 'link', onClick, }, [renderSlot(_ctx.$slots, 'default')], 2 ), unref(separatorIcon) ? (openBlock(), createBlock( unref(ElIcon), { key: 0, class: normalizeClass(unref(ns).e('separator')), }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent(unref(separatorIcon)) )), ]), _: 1, }, 8, ['class'] )) : (openBlock(), createElementBlock( 'span', { key: 1, class: normalizeClass(unref(ns).e('separator')), role: 'presentation', }, toDisplayString$1(unref(separator)), 3 )), ], 2 ) ) } }, }) var BreadcrumbItem = /* @__PURE__ */ _export_sfc$1(_sfc_main$92, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/breadcrumb/src/breadcrumb-item.vue', ], ]) const ElBreadcrumb = withInstall(Breadcrumb$2, { BreadcrumbItem, }) const ElBreadcrumbItem = withNoopInstall(BreadcrumbItem) function bound01$1(n2, max3) { if (isOnePointZero$1(n2)) { n2 = '100%' } var isPercent = isPercentage$1(n2) n2 = max3 === 360 ? n2 : Math.min(max3, Math.max(0, parseFloat(n2))) if (isPercent) { n2 = parseInt(String(n2 * max3), 10) / 100 } if (Math.abs(n2 - max3) < 1e-6) { return 1 } if (max3 === 360) { n2 = (n2 < 0 ? (n2 % max3) + max3 : n2 % max3) / parseFloat(String(max3)) } else { n2 = (n2 % max3) / parseFloat(String(max3)) } return n2 } function clamp01(val2) { return Math.min(1, Math.max(0, val2)) } function isOnePointZero$1(n2) { return ( typeof n2 === 'string' && n2.indexOf('.') !== -1 && parseFloat(n2) === 1 ) } function isPercentage$1(n2) { return typeof n2 === 'string' && n2.indexOf('%') !== -1 } function boundAlpha(a2) { a2 = parseFloat(a2) if (isNaN(a2) || a2 < 0 || a2 > 1) { a2 = 1 } return a2 } function convertToPercentage(n2) { if (n2 <= 1) { return ''.concat(Number(n2) * 100, '%') } return n2 } function pad2(c2) { return c2.length === 1 ? '0' + c2 : String(c2) } function rgbToRgb(r2, g2, b2) { return { r: bound01$1(r2, 255) * 255, g: bound01$1(g2, 255) * 255, b: bound01$1(b2, 255) * 255, } } function rgbToHsl(r2, g2, b2) { r2 = bound01$1(r2, 255) g2 = bound01$1(g2, 255) b2 = bound01$1(b2, 255) var max3 = Math.max(r2, g2, b2) var min3 = Math.min(r2, g2, b2) var h2 = 0 var s2 = 0 var l2 = (max3 + min3) / 2 if (max3 === min3) { s2 = 0 h2 = 0 } else { var d3 = max3 - min3 s2 = l2 > 0.5 ? d3 / (2 - max3 - min3) : d3 / (max3 + min3) switch (max3) { case r2: h2 = (g2 - b2) / d3 + (g2 < b2 ? 6 : 0) break case g2: h2 = (b2 - r2) / d3 + 2 break case b2: h2 = (r2 - g2) / d3 + 4 break } h2 /= 6 } return { h: h2, s: s2, l: l2 } } function hue2rgb$1(p2, q2, t3) { if (t3 < 0) { t3 += 1 } if (t3 > 1) { t3 -= 1 } if (t3 < 1 / 6) { return p2 + (q2 - p2) * (6 * t3) } if (t3 < 1 / 2) { return q2 } if (t3 < 2 / 3) { return p2 + (q2 - p2) * (2 / 3 - t3) * 6 } return p2 } function hslToRgb(h2, s2, l2) { var r2 var g2 var b2 h2 = bound01$1(h2, 360) s2 = bound01$1(s2, 100) l2 = bound01$1(l2, 100) if (s2 === 0) { g2 = l2 b2 = l2 r2 = l2 } else { var q2 = l2 < 0.5 ? l2 * (1 + s2) : l2 + s2 - l2 * s2 var p2 = 2 * l2 - q2 r2 = hue2rgb$1(p2, q2, h2 + 1 / 3) g2 = hue2rgb$1(p2, q2, h2) b2 = hue2rgb$1(p2, q2, h2 - 1 / 3) } return { r: r2 * 255, g: g2 * 255, b: b2 * 255 } } function rgbToHsv(r2, g2, b2) { r2 = bound01$1(r2, 255) g2 = bound01$1(g2, 255) b2 = bound01$1(b2, 255) var max3 = Math.max(r2, g2, b2) var min3 = Math.min(r2, g2, b2) var h2 = 0 var v4 = max3 var d3 = max3 - min3 var s2 = max3 === 0 ? 0 : d3 / max3 if (max3 === min3) { h2 = 0 } else { switch (max3) { case r2: h2 = (g2 - b2) / d3 + (g2 < b2 ? 6 : 0) break case g2: h2 = (b2 - r2) / d3 + 2 break case b2: h2 = (r2 - g2) / d3 + 4 break } h2 /= 6 } return { h: h2, s: s2, v: v4 } } function hsvToRgb(h2, s2, v4) { h2 = bound01$1(h2, 360) * 6 s2 = bound01$1(s2, 100) v4 = bound01$1(v4, 100) var i2 = Math.floor(h2) var f2 = h2 - i2 var p2 = v4 * (1 - s2) var q2 = v4 * (1 - f2 * s2) var t3 = v4 * (1 - (1 - f2) * s2) var mod = i2 % 6 var r2 = [v4, q2, p2, p2, t3, v4][mod] var g2 = [t3, v4, v4, q2, p2, p2][mod] var b2 = [p2, p2, t3, v4, v4, q2][mod] return { r: r2 * 255, g: g2 * 255, b: b2 * 255 } } function rgbToHex(r2, g2, b2, allow3Char) { var hex2 = [ pad2(Math.round(r2).toString(16)), pad2(Math.round(g2).toString(16)), pad2(Math.round(b2).toString(16)), ] if ( allow3Char && hex2[0].startsWith(hex2[0].charAt(1)) && hex2[1].startsWith(hex2[1].charAt(1)) && hex2[2].startsWith(hex2[2].charAt(1)) ) { return hex2[0].charAt(0) + hex2[1].charAt(0) + hex2[2].charAt(0) } return hex2.join('') } function rgbaToHex(r2, g2, b2, a2, allow4Char) { var hex2 = [ pad2(Math.round(r2).toString(16)), pad2(Math.round(g2).toString(16)), pad2(Math.round(b2).toString(16)), pad2(convertDecimalToHex(a2)), ] if ( allow4Char && hex2[0].startsWith(hex2[0].charAt(1)) && hex2[1].startsWith(hex2[1].charAt(1)) && hex2[2].startsWith(hex2[2].charAt(1)) && hex2[3].startsWith(hex2[3].charAt(1)) ) { return ( hex2[0].charAt(0) + hex2[1].charAt(0) + hex2[2].charAt(0) + hex2[3].charAt(0) ) } return hex2.join('') } function convertDecimalToHex(d3) { return Math.round(parseFloat(d3) * 255).toString(16) } function convertHexToDecimal(h2) { return parseIntFromHex(h2) / 255 } function parseIntFromHex(val2) { return parseInt(val2, 16) } function numberInputToObject(color2) { return { r: color2 >> 16, g: (color2 & 65280) >> 8, b: color2 & 255, } } var names = { aliceblue: '#f0f8ff', antiquewhite: '#faebd7', aqua: '#00ffff', aquamarine: '#7fffd4', azure: '#f0ffff', beige: '#f5f5dc', bisque: '#ffe4c4', black: '#000000', blanchedalmond: '#ffebcd', blue: '#0000ff', blueviolet: '#8a2be2', brown: '#a52a2a', burlywood: '#deb887', cadetblue: '#5f9ea0', chartreuse: '#7fff00', chocolate: '#d2691e', coral: '#ff7f50', cornflowerblue: '#6495ed', cornsilk: '#fff8dc', crimson: '#dc143c', cyan: '#00ffff', darkblue: '#00008b', darkcyan: '#008b8b', darkgoldenrod: '#b8860b', darkgray: '#a9a9a9', darkgreen: '#006400', darkgrey: '#a9a9a9', darkkhaki: '#bdb76b', darkmagenta: '#8b008b', darkolivegreen: '#556b2f', darkorange: '#ff8c00', darkorchid: '#9932cc', darkred: '#8b0000', darksalmon: '#e9967a', darkseagreen: '#8fbc8f', darkslateblue: '#483d8b', darkslategray: '#2f4f4f', darkslategrey: '#2f4f4f', darkturquoise: '#00ced1', darkviolet: '#9400d3', deeppink: '#ff1493', deepskyblue: '#00bfff', dimgray: '#696969', dimgrey: '#696969', dodgerblue: '#1e90ff', firebrick: '#b22222', floralwhite: '#fffaf0', forestgreen: '#228b22', fuchsia: '#ff00ff', gainsboro: '#dcdcdc', ghostwhite: '#f8f8ff', goldenrod: '#daa520', gold: '#ffd700', gray: '#808080', green: '#008000', greenyellow: '#adff2f', grey: '#808080', honeydew: '#f0fff0', hotpink: '#ff69b4', indianred: '#cd5c5c', indigo: '#4b0082', ivory: '#fffff0', khaki: '#f0e68c', lavenderblush: '#fff0f5', lavender: '#e6e6fa', lawngreen: '#7cfc00', lemonchiffon: '#fffacd', lightblue: '#add8e6', lightcoral: '#f08080', lightcyan: '#e0ffff', lightgoldenrodyellow: '#fafad2', lightgray: '#d3d3d3', lightgreen: '#90ee90', lightgrey: '#d3d3d3', lightpink: '#ffb6c1', lightsalmon: '#ffa07a', lightseagreen: '#20b2aa', lightskyblue: '#87cefa', lightslategray: '#778899', lightslategrey: '#778899', lightsteelblue: '#b0c4de', lightyellow: '#ffffe0', lime: '#00ff00', limegreen: '#32cd32', linen: '#faf0e6', magenta: '#ff00ff', maroon: '#800000', mediumaquamarine: '#66cdaa', mediumblue: '#0000cd', mediumorchid: '#ba55d3', mediumpurple: '#9370db', mediumseagreen: '#3cb371', mediumslateblue: '#7b68ee', mediumspringgreen: '#00fa9a', mediumturquoise: '#48d1cc', mediumvioletred: '#c71585', midnightblue: '#191970', mintcream: '#f5fffa', mistyrose: '#ffe4e1', moccasin: '#ffe4b5', navajowhite: '#ffdead', navy: '#000080', oldlace: '#fdf5e6', olive: '#808000', olivedrab: '#6b8e23', orange: '#ffa500', orangered: '#ff4500', orchid: '#da70d6', palegoldenrod: '#eee8aa', palegreen: '#98fb98', paleturquoise: '#afeeee', palevioletred: '#db7093', papayawhip: '#ffefd5', peachpuff: '#ffdab9', peru: '#cd853f', pink: '#ffc0cb', plum: '#dda0dd', powderblue: '#b0e0e6', purple: '#800080', rebeccapurple: '#663399', red: '#ff0000', rosybrown: '#bc8f8f', royalblue: '#4169e1', saddlebrown: '#8b4513', salmon: '#fa8072', sandybrown: '#f4a460', seagreen: '#2e8b57', seashell: '#fff5ee', sienna: '#a0522d', silver: '#c0c0c0', skyblue: '#87ceeb', slateblue: '#6a5acd', slategray: '#708090', slategrey: '#708090', snow: '#fffafa', springgreen: '#00ff7f', steelblue: '#4682b4', tan: '#d2b48c', teal: '#008080', thistle: '#d8bfd8', tomato: '#ff6347', turquoise: '#40e0d0', violet: '#ee82ee', wheat: '#f5deb3', white: '#ffffff', whitesmoke: '#f5f5f5', yellow: '#ffff00', yellowgreen: '#9acd32', } function inputToRGB(color2) { var rgb2 = { r: 0, g: 0, b: 0 } var a2 = 1 var s2 = null var v4 = null var l2 = null var ok = false var format2 = false if (typeof color2 === 'string') { color2 = stringInputToObject(color2) } if (typeof color2 === 'object') { if ( isValidCSSUnit(color2.r) && isValidCSSUnit(color2.g) && isValidCSSUnit(color2.b) ) { rgb2 = rgbToRgb(color2.r, color2.g, color2.b) ok = true format2 = String(color2.r).substr(-1) === '%' ? 'prgb' : 'rgb' } else if ( isValidCSSUnit(color2.h) && isValidCSSUnit(color2.s) && isValidCSSUnit(color2.v) ) { s2 = convertToPercentage(color2.s) v4 = convertToPercentage(color2.v) rgb2 = hsvToRgb(color2.h, s2, v4) ok = true format2 = 'hsv' } else if ( isValidCSSUnit(color2.h) && isValidCSSUnit(color2.s) && isValidCSSUnit(color2.l) ) { s2 = convertToPercentage(color2.s) l2 = convertToPercentage(color2.l) rgb2 = hslToRgb(color2.h, s2, l2) ok = true format2 = 'hsl' } if (Object.prototype.hasOwnProperty.call(color2, 'a')) { a2 = color2.a } } a2 = boundAlpha(a2) return { ok, format: color2.format || format2, r: Math.min(255, Math.max(rgb2.r, 0)), g: Math.min(255, Math.max(rgb2.g, 0)), b: Math.min(255, Math.max(rgb2.b, 0)), a: a2, } } var CSS_INTEGER = '[-\\+]?\\d+%?' var CSS_NUMBER = '[-\\+]?\\d*\\.\\d+%?' var CSS_UNIT = '(?:'.concat(CSS_NUMBER, ')|(?:').concat(CSS_INTEGER, ')') var PERMISSIVE_MATCH3 = '[\\s|\\(]+(' .concat(CSS_UNIT, ')[,|\\s]+(') .concat(CSS_UNIT, ')[,|\\s]+(') .concat(CSS_UNIT, ')\\s*\\)?') var PERMISSIVE_MATCH4 = '[\\s|\\(]+(' .concat(CSS_UNIT, ')[,|\\s]+(') .concat(CSS_UNIT, ')[,|\\s]+(') .concat(CSS_UNIT, ')[,|\\s]+(') .concat(CSS_UNIT, ')\\s*\\)?') var matchers = { CSS_UNIT: new RegExp(CSS_UNIT), rgb: new RegExp('rgb' + PERMISSIVE_MATCH3), rgba: new RegExp('rgba' + PERMISSIVE_MATCH4), hsl: new RegExp('hsl' + PERMISSIVE_MATCH3), hsla: new RegExp('hsla' + PERMISSIVE_MATCH4), hsv: new RegExp('hsv' + PERMISSIVE_MATCH3), hsva: new RegExp('hsva' + PERMISSIVE_MATCH4), hex3: /^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/, hex6: /^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/, hex4: /^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/, hex8: /^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/, } function stringInputToObject(color2) { color2 = color2.trim().toLowerCase() if (color2.length === 0) { return false } var named = false if (names[color2]) { color2 = names[color2] named = true } else if (color2 === 'transparent') { return { r: 0, g: 0, b: 0, a: 0, format: 'name' } } var match2 = matchers.rgb.exec(color2) if (match2) { return { r: match2[1], g: match2[2], b: match2[3] } } match2 = matchers.rgba.exec(color2) if (match2) { return { r: match2[1], g: match2[2], b: match2[3], a: match2[4] } } match2 = matchers.hsl.exec(color2) if (match2) { return { h: match2[1], s: match2[2], l: match2[3] } } match2 = matchers.hsla.exec(color2) if (match2) { return { h: match2[1], s: match2[2], l: match2[3], a: match2[4] } } match2 = matchers.hsv.exec(color2) if (match2) { return { h: match2[1], s: match2[2], v: match2[3] } } match2 = matchers.hsva.exec(color2) if (match2) { return { h: match2[1], s: match2[2], v: match2[3], a: match2[4] } } match2 = matchers.hex8.exec(color2) if (match2) { return { r: parseIntFromHex(match2[1]), g: parseIntFromHex(match2[2]), b: parseIntFromHex(match2[3]), a: convertHexToDecimal(match2[4]), format: named ? 'name' : 'hex8', } } match2 = matchers.hex6.exec(color2) if (match2) { return { r: parseIntFromHex(match2[1]), g: parseIntFromHex(match2[2]), b: parseIntFromHex(match2[3]), format: named ? 'name' : 'hex', } } match2 = matchers.hex4.exec(color2) if (match2) { return { r: parseIntFromHex(match2[1] + match2[1]), g: parseIntFromHex(match2[2] + match2[2]), b: parseIntFromHex(match2[3] + match2[3]), a: convertHexToDecimal(match2[4] + match2[4]), format: named ? 'name' : 'hex8', } } match2 = matchers.hex3.exec(color2) if (match2) { return { r: parseIntFromHex(match2[1] + match2[1]), g: parseIntFromHex(match2[2] + match2[2]), b: parseIntFromHex(match2[3] + match2[3]), format: named ? 'name' : 'hex', } } return false } function isValidCSSUnit(color2) { return Boolean(matchers.CSS_UNIT.exec(String(color2))) } var TinyColor = (function () { function TinyColor2(color2, opts) { if (color2 === void 0) { color2 = '' } if (opts === void 0) { opts = {} } var _a2 if (color2 instanceof TinyColor2) { return color2 } if (typeof color2 === 'number') { color2 = numberInputToObject(color2) } this.originalInput = color2 var rgb2 = inputToRGB(color2) this.originalInput = color2 this.r = rgb2.r this.g = rgb2.g this.b = rgb2.b this.a = rgb2.a this.roundA = Math.round(100 * this.a) / 100 this.format = (_a2 = opts.format) !== null && _a2 !== void 0 ? _a2 : rgb2.format this.gradientType = opts.gradientType if (this.r < 1) { this.r = Math.round(this.r) } if (this.g < 1) { this.g = Math.round(this.g) } if (this.b < 1) { this.b = Math.round(this.b) } this.isValid = rgb2.ok } TinyColor2.prototype.isDark = function () { return this.getBrightness() < 128 } TinyColor2.prototype.isLight = function () { return !this.isDark() } TinyColor2.prototype.getBrightness = function () { var rgb2 = this.toRgb() return (rgb2.r * 299 + rgb2.g * 587 + rgb2.b * 114) / 1e3 } TinyColor2.prototype.getLuminance = function () { var rgb2 = this.toRgb() var R2 var G2 var B3 var RsRGB = rgb2.r / 255 var GsRGB = rgb2.g / 255 var BsRGB = rgb2.b / 255 if (RsRGB <= 0.03928) { R2 = RsRGB / 12.92 } else { R2 = Math.pow((RsRGB + 0.055) / 1.055, 2.4) } if (GsRGB <= 0.03928) { G2 = GsRGB / 12.92 } else { G2 = Math.pow((GsRGB + 0.055) / 1.055, 2.4) } if (BsRGB <= 0.03928) { B3 = BsRGB / 12.92 } else { B3 = Math.pow((BsRGB + 0.055) / 1.055, 2.4) } return 0.2126 * R2 + 0.7152 * G2 + 0.0722 * B3 } TinyColor2.prototype.getAlpha = function () { return this.a } TinyColor2.prototype.setAlpha = function (alpha) { this.a = boundAlpha(alpha) this.roundA = Math.round(100 * this.a) / 100 return this } TinyColor2.prototype.isMonochrome = function () { var s2 = this.toHsl().s return s2 === 0 } TinyColor2.prototype.toHsv = function () { var hsv = rgbToHsv(this.r, this.g, this.b) return { h: hsv.h * 360, s: hsv.s, v: hsv.v, a: this.a } } TinyColor2.prototype.toHsvString = function () { var hsv = rgbToHsv(this.r, this.g, this.b) var h2 = Math.round(hsv.h * 360) var s2 = Math.round(hsv.s * 100) var v4 = Math.round(hsv.v * 100) return this.a === 1 ? 'hsv('.concat(h2, ', ').concat(s2, '%, ').concat(v4, '%)') : 'hsva(' .concat(h2, ', ') .concat(s2, '%, ') .concat(v4, '%, ') .concat(this.roundA, ')') } TinyColor2.prototype.toHsl = function () { var hsl2 = rgbToHsl(this.r, this.g, this.b) return { h: hsl2.h * 360, s: hsl2.s, l: hsl2.l, a: this.a } } TinyColor2.prototype.toHslString = function () { var hsl2 = rgbToHsl(this.r, this.g, this.b) var h2 = Math.round(hsl2.h * 360) var s2 = Math.round(hsl2.s * 100) var l2 = Math.round(hsl2.l * 100) return this.a === 1 ? 'hsl('.concat(h2, ', ').concat(s2, '%, ').concat(l2, '%)') : 'hsla(' .concat(h2, ', ') .concat(s2, '%, ') .concat(l2, '%, ') .concat(this.roundA, ')') } TinyColor2.prototype.toHex = function (allow3Char) { if (allow3Char === void 0) { allow3Char = false } return rgbToHex(this.r, this.g, this.b, allow3Char) } TinyColor2.prototype.toHexString = function (allow3Char) { if (allow3Char === void 0) { allow3Char = false } return '#' + this.toHex(allow3Char) } TinyColor2.prototype.toHex8 = function (allow4Char) { if (allow4Char === void 0) { allow4Char = false } return rgbaToHex(this.r, this.g, this.b, this.a, allow4Char) } TinyColor2.prototype.toHex8String = function (allow4Char) { if (allow4Char === void 0) { allow4Char = false } return '#' + this.toHex8(allow4Char) } TinyColor2.prototype.toHexShortString = function (allowShortChar) { if (allowShortChar === void 0) { allowShortChar = false } return this.a === 1 ? this.toHexString(allowShortChar) : this.toHex8String(allowShortChar) } TinyColor2.prototype.toRgb = function () { return { r: Math.round(this.r), g: Math.round(this.g), b: Math.round(this.b), a: this.a, } } TinyColor2.prototype.toRgbString = function () { var r2 = Math.round(this.r) var g2 = Math.round(this.g) var b2 = Math.round(this.b) return this.a === 1 ? 'rgb('.concat(r2, ', ').concat(g2, ', ').concat(b2, ')') : 'rgba(' .concat(r2, ', ') .concat(g2, ', ') .concat(b2, ', ') .concat(this.roundA, ')') } TinyColor2.prototype.toPercentageRgb = function () { var fmt = function (x2) { return ''.concat(Math.round(bound01$1(x2, 255) * 100), '%') } return { r: fmt(this.r), g: fmt(this.g), b: fmt(this.b), a: this.a, } } TinyColor2.prototype.toPercentageRgbString = function () { var rnd = function (x2) { return Math.round(bound01$1(x2, 255) * 100) } return this.a === 1 ? 'rgb(' .concat(rnd(this.r), '%, ') .concat(rnd(this.g), '%, ') .concat(rnd(this.b), '%)') : 'rgba(' .concat(rnd(this.r), '%, ') .concat(rnd(this.g), '%, ') .concat(rnd(this.b), '%, ') .concat(this.roundA, ')') } TinyColor2.prototype.toName = function () { if (this.a === 0) { return 'transparent' } if (this.a < 1) { return false } var hex2 = '#' + rgbToHex(this.r, this.g, this.b, false) for (var _i = 0, _a2 = Object.entries(names); _i < _a2.length; _i++) { var _b2 = _a2[_i], key2 = _b2[0], value2 = _b2[1] if (hex2 === value2) { return key2 } } return false } TinyColor2.prototype.toString = function (format2) { var formatSet = Boolean(format2) format2 = format2 !== null && format2 !== void 0 ? format2 : this.format var formattedString = false var hasAlpha = this.a < 1 && this.a >= 0 var needsAlphaFormat = !formatSet && hasAlpha && (format2.startsWith('hex') || format2 === 'name') if (needsAlphaFormat) { if (format2 === 'name' && this.a === 0) { return this.toName() } return this.toRgbString() } if (format2 === 'rgb') { formattedString = this.toRgbString() } if (format2 === 'prgb') { formattedString = this.toPercentageRgbString() } if (format2 === 'hex' || format2 === 'hex6') { formattedString = this.toHexString() } if (format2 === 'hex3') { formattedString = this.toHexString(true) } if (format2 === 'hex4') { formattedString = this.toHex8String(true) } if (format2 === 'hex8') { formattedString = this.toHex8String() } if (format2 === 'name') { formattedString = this.toName() } if (format2 === 'hsl') { formattedString = this.toHslString() } if (format2 === 'hsv') { formattedString = this.toHsvString() } return formattedString || this.toHexString() } TinyColor2.prototype.toNumber = function () { return ( (Math.round(this.r) << 16) + (Math.round(this.g) << 8) + Math.round(this.b) ) } TinyColor2.prototype.clone = function () { return new TinyColor2(this.toString()) } TinyColor2.prototype.lighten = function (amount) { if (amount === void 0) { amount = 10 } var hsl2 = this.toHsl() hsl2.l += amount / 100 hsl2.l = clamp01(hsl2.l) return new TinyColor2(hsl2) } TinyColor2.prototype.brighten = function (amount) { if (amount === void 0) { amount = 10 } var rgb2 = this.toRgb() rgb2.r = Math.max( 0, Math.min(255, rgb2.r - Math.round(255 * -(amount / 100))) ) rgb2.g = Math.max( 0, Math.min(255, rgb2.g - Math.round(255 * -(amount / 100))) ) rgb2.b = Math.max( 0, Math.min(255, rgb2.b - Math.round(255 * -(amount / 100))) ) return new TinyColor2(rgb2) } TinyColor2.prototype.darken = function (amount) { if (amount === void 0) { amount = 10 } var hsl2 = this.toHsl() hsl2.l -= amount / 100 hsl2.l = clamp01(hsl2.l) return new TinyColor2(hsl2) } TinyColor2.prototype.tint = function (amount) { if (amount === void 0) { amount = 10 } return this.mix('white', amount) } TinyColor2.prototype.shade = function (amount) { if (amount === void 0) { amount = 10 } return this.mix('black', amount) } TinyColor2.prototype.desaturate = function (amount) { if (amount === void 0) { amount = 10 } var hsl2 = this.toHsl() hsl2.s -= amount / 100 hsl2.s = clamp01(hsl2.s) return new TinyColor2(hsl2) } TinyColor2.prototype.saturate = function (amount) { if (amount === void 0) { amount = 10 } var hsl2 = this.toHsl() hsl2.s += amount / 100 hsl2.s = clamp01(hsl2.s) return new TinyColor2(hsl2) } TinyColor2.prototype.greyscale = function () { return this.desaturate(100) } TinyColor2.prototype.spin = function (amount) { var hsl2 = this.toHsl() var hue = (hsl2.h + amount) % 360 hsl2.h = hue < 0 ? 360 + hue : hue return new TinyColor2(hsl2) } TinyColor2.prototype.mix = function (color2, amount) { if (amount === void 0) { amount = 50 } var rgb1 = this.toRgb() var rgb2 = new TinyColor2(color2).toRgb() var p2 = amount / 100 var rgba = { r: (rgb2.r - rgb1.r) * p2 + rgb1.r, g: (rgb2.g - rgb1.g) * p2 + rgb1.g, b: (rgb2.b - rgb1.b) * p2 + rgb1.b, a: (rgb2.a - rgb1.a) * p2 + rgb1.a, } return new TinyColor2(rgba) } TinyColor2.prototype.analogous = function (results, slices) { if (results === void 0) { results = 6 } if (slices === void 0) { slices = 30 } var hsl2 = this.toHsl() var part = 360 / slices var ret = [this] for (hsl2.h = (hsl2.h - ((part * results) >> 1) + 720) % 360; --results; ) { hsl2.h = (hsl2.h + part) % 360 ret.push(new TinyColor2(hsl2)) } return ret } TinyColor2.prototype.complement = function () { var hsl2 = this.toHsl() hsl2.h = (hsl2.h + 180) % 360 return new TinyColor2(hsl2) } TinyColor2.prototype.monochromatic = function (results) { if (results === void 0) { results = 6 } var hsv = this.toHsv() var h2 = hsv.h var s2 = hsv.s var v4 = hsv.v var res = [] var modification = 1 / results while (results--) { res.push(new TinyColor2({ h: h2, s: s2, v: v4 })) v4 = (v4 + modification) % 1 } return res } TinyColor2.prototype.splitcomplement = function () { var hsl2 = this.toHsl() var h2 = hsl2.h return [ this, new TinyColor2({ h: (h2 + 72) % 360, s: hsl2.s, l: hsl2.l }), new TinyColor2({ h: (h2 + 216) % 360, s: hsl2.s, l: hsl2.l }), ] } TinyColor2.prototype.onBackground = function (background) { var fg = this.toRgb() var bg2 = new TinyColor2(background).toRgb() var alpha = fg.a + bg2.a * (1 - fg.a) return new TinyColor2({ r: (fg.r * fg.a + bg2.r * bg2.a * (1 - fg.a)) / alpha, g: (fg.g * fg.a + bg2.g * bg2.a * (1 - fg.a)) / alpha, b: (fg.b * fg.a + bg2.b * bg2.a * (1 - fg.a)) / alpha, a: alpha, }) } TinyColor2.prototype.triad = function () { return this.polyad(3) } TinyColor2.prototype.tetrad = function () { return this.polyad(4) } TinyColor2.prototype.polyad = function (n2) { var hsl2 = this.toHsl() var h2 = hsl2.h var result = [this] var increment = 360 / n2 for (var i2 = 1; i2 < n2; i2++) { result.push( new TinyColor2({ h: (h2 + i2 * increment) % 360, s: hsl2.s, l: hsl2.l }) ) } return result } TinyColor2.prototype.equals = function (color2) { return this.toRgbString() === new TinyColor2(color2).toRgbString() } return TinyColor2 })() const buttonTypes = [ 'default', 'primary', 'success', 'warning', 'info', 'danger', 'text', '', ] const buttonNativeTypes = ['button', 'submit', 'reset'] const buttonProps = buildProps({ size: useSizeProp, disabled: Boolean, type: { type: String, values: buttonTypes, default: '', }, icon: { type: iconPropType, default: '', }, nativeType: { type: String, values: buttonNativeTypes, default: 'button', }, loading: Boolean, loadingIcon: { type: iconPropType, default: () => loading, }, plain: Boolean, autofocus: Boolean, round: Boolean, circle: Boolean, color: String, autoInsertSpace: { type: Boolean, default: void 0, }, }) const buttonEmits = { click: (evt) => evt instanceof MouseEvent, } const _hoisted_1$6V = ['disabled', 'autofocus', 'type'] const __default__$B = { name: 'ElButton', } const _sfc_main$91 = /* @__PURE__ */ defineComponent({ ...__default__$B, props: buttonProps, emits: buttonEmits, setup(__props2, { expose, emit: emit2 }) { const props2 = __props2 const slots = useSlots() const buttonGroupContext = inject(buttonGroupContextKey, void 0) const globalConfig2 = useGlobalConfig('button') const ns = useNamespace('button') const { form: form2 } = useFormItem() const _size = useSize$1( computed(() => buttonGroupContext == null ? void 0 : buttonGroupContext.size ) ) const _disabled = useDisabled$1() const _ref2 = ref() const _type = computed( () => props2.type || (buttonGroupContext == null ? void 0 : buttonGroupContext.type) || '' ) const autoInsertSpace = computed(() => { var _a2, _b2, _c2 return (_c2 = (_b2 = props2.autoInsertSpace) != null ? _b2 : (_a2 = globalConfig2.value) == null ? void 0 : _a2.autoInsertSpace) != null ? _c2 : false }) const shouldAddSpace = computed(() => { var _a2 const defaultSlot = (_a2 = slots.default) == null ? void 0 : _a2.call(slots) if ( autoInsertSpace.value && (defaultSlot == null ? void 0 : defaultSlot.length) === 1 ) { const slot = defaultSlot[0] if ((slot == null ? void 0 : slot.type) === Text) { const text2 = slot.children return /^\p{Unified_Ideograph}{2}$/u.test(text2.trim()) } } return false }) const buttonStyle = computed(() => { let styles = {} const buttonColor = props2.color if (buttonColor) { const color2 = new TinyColor(buttonColor) const shadeBgColor = color2.shade(20).toString() if (props2.plain) { styles = { '--el-button-bg-color': color2.tint(90).toString(), '--el-button-text-color': buttonColor, '--el-button-hover-text-color': 'var(--el-color-white)', '--el-button-hover-bg-color': buttonColor, '--el-button-hover-border-color': buttonColor, '--el-button-active-bg-color': shadeBgColor, '--el-button-active-text-color': 'var(--el-color-white)', '--el-button-active-border-color': shadeBgColor, } } else { const tintBgColor = color2.tint(30).toString() styles = { '--el-button-bg-color': buttonColor, '--el-button-border-color': buttonColor, '--el-button-hover-bg-color': tintBgColor, '--el-button-hover-border-color': tintBgColor, '--el-button-active-bg-color': shadeBgColor, '--el-button-active-border-color': shadeBgColor, } } if (_disabled.value) { const disabledButtonColor = color2.tint(50).toString() styles['--el-button-disabled-bg-color'] = disabledButtonColor styles['--el-button-disabled-border-color'] = disabledButtonColor } } return styles }) const handleClick2 = (evt) => { if (props2.nativeType === 'reset') { form2 == null ? void 0 : form2.resetFields() } emit2('click', evt) } expose({ ref: _ref2, size: _size, type: _type, disabled: _disabled, shouldAddSpace, }) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'button', { ref_key: '_ref', ref: _ref2, class: normalizeClass([ unref(ns).b(), unref(ns).m(unref(_type)), unref(ns).m(unref(_size)), unref(ns).is('disabled', unref(_disabled)), unref(ns).is('loading', _ctx.loading), unref(ns).is('plain', _ctx.plain), unref(ns).is('round', _ctx.round), unref(ns).is('circle', _ctx.circle), ]), disabled: unref(_disabled) || _ctx.loading, autofocus: _ctx.autofocus, type: _ctx.nativeType, style: normalizeStyle$1(unref(buttonStyle)), onClick: handleClick2, }, [ _ctx.loading ? (openBlock(), createElementBlock( Fragment, { key: 0 }, [ _ctx.$slots.loading ? renderSlot(_ctx.$slots, 'loading', { key: 0 }) : (openBlock(), createBlock( unref(ElIcon), { key: 1, class: normalizeClass(unref(ns).is('loading')), }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent(_ctx.loadingIcon) )), ]), _: 1, }, 8, ['class'] )), ], 2112 )) : _ctx.icon || _ctx.$slots.icon ? (openBlock(), createBlock( unref(ElIcon), { key: 1 }, { default: withCtx(() => [ _ctx.icon ? (openBlock(), createBlock(resolveDynamicComponent(_ctx.icon), { key: 0, })) : renderSlot(_ctx.$slots, 'icon', { key: 1 }), ]), _: 3, } )) : createCommentVNode('v-if', true), _ctx.$slots.default ? (openBlock(), createElementBlock( 'span', { key: 2, class: normalizeClass({ [unref(ns).em('text', 'expand')]: unref(shouldAddSpace), }), }, [renderSlot(_ctx.$slots, 'default')], 2 )) : createCommentVNode('v-if', true), ], 14, _hoisted_1$6V ) ) } }, }) var Button$1 = /* @__PURE__ */ _export_sfc$1(_sfc_main$91, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/button/src/button.vue', ], ]) const buttonGroupProps = { size: buttonProps.size, type: buttonProps.type, } const __default__$A = { name: 'ElButtonGroup', } const _sfc_main$90 = /* @__PURE__ */ defineComponent({ ...__default__$A, props: buttonGroupProps, setup(__props2) { const props2 = __props2 provide( buttonGroupContextKey, reactive({ size: toRef(props2, 'size'), type: toRef(props2, 'type'), }) ) const ns = useNamespace('button') return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { class: normalizeClass(`${unref(ns).b('group')}`), }, [renderSlot(_ctx.$slots, 'default')], 2 ) ) } }, }) var ButtonGroup = /* @__PURE__ */ _export_sfc$1(_sfc_main$90, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/button/src/button-group.vue', ], ]) const ElButton = withInstall(Button$1, { ButtonGroup, }) const ElButtonGroup$1 = withNoopInstall(ButtonGroup) var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {} function getDefaultExportFromCjs(x2) { return x2 && x2.__esModule && Object.prototype.hasOwnProperty.call(x2, 'default') ? x2['default'] : x2 } function commonjsRequire(path) { throw new Error( 'Could not dynamically require "' + path + '". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.' ) } var dayjs_min$1 = { exports: {} } ;(function (module2, exports2) { !(function (t3, e2) { module2.exports = e2() })(commonjsGlobal, function () { var t3 = 1e3, e2 = 6e4, n2 = 36e5, r2 = 'millisecond', i2 = 'second', s2 = 'minute', u2 = 'hour', a2 = 'day', o2 = 'week', c2 = 'month', f2 = 'quarter', h2 = 'year', d3 = 'date', l2 = 'Invalid Date', $2 = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, y2 = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, M2 = { name: 'en', weekdays: 'Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday'.split('_'), months: 'January_February_March_April_May_June_July_August_September_October_November_December'.split( '_' ), ordinal: function (t4) { var e3 = ['th', 'st', 'nd', 'rd'], n3 = t4 % 100 return '[' + t4 + (e3[(n3 - 20) % 10] || e3[n3] || e3[0]) + ']' }, }, m2 = function (t4, e3, n3) { var r3 = String(t4) return !r3 || r3.length >= e3 ? t4 : '' + Array(e3 + 1 - r3.length).join(n3) + t4 }, v4 = { s: m2, z: function (t4) { var e3 = -t4.utcOffset(), n3 = Math.abs(e3), r3 = Math.floor(n3 / 60), i3 = n3 % 60 return (e3 <= 0 ? '+' : '-') + m2(r3, 2, '0') + ':' + m2(i3, 2, '0') }, m: function t4(e3, n3) { if (e3.date() < n3.date()) return -t4(n3, e3) var r3 = 12 * (n3.year() - e3.year()) + (n3.month() - e3.month()), i3 = e3.clone().add(r3, c2), s3 = n3 - i3 < 0, u3 = e3.clone().add(r3 + (s3 ? -1 : 1), c2) return +(-(r3 + (n3 - i3) / (s3 ? i3 - u3 : u3 - i3)) || 0) }, a: function (t4) { return t4 < 0 ? Math.ceil(t4) || 0 : Math.floor(t4) }, p: function (t4) { return ( { M: c2, y: h2, w: o2, d: a2, D: d3, h: u2, m: s2, s: i2, ms: r2, Q: f2, }[t4] || String(t4 || '') .toLowerCase() .replace(/s$/, '') ) }, u: function (t4) { return void 0 === t4 }, }, g2 = 'en', D2 = {} D2[g2] = M2 var p2 = '$isDayjsObject', S2 = function (t4) { return t4 instanceof _2 || !(!t4 || !t4[p2]) }, w2 = function t4(e3, n3, r3) { var i3 if (!e3) return g2 if ('string' == typeof e3) { var s3 = e3.toLowerCase() D2[s3] && (i3 = s3), n3 && ((D2[s3] = n3), (i3 = s3)) var u3 = e3.split('-') if (!i3 && u3.length > 1) return t4(u3[0]) } else { var a3 = e3.name ;(D2[a3] = e3), (i3 = a3) } return !r3 && i3 && (g2 = i3), i3 || (!r3 && g2) }, O2 = function (t4, e3) { if (S2(t4)) return t4.clone() var n3 = 'object' == typeof e3 ? e3 : {} return (n3.date = t4), (n3.args = arguments), new _2(n3) }, b2 = v4 ;(b2.l = w2), (b2.i = S2), (b2.w = function (t4, e3) { return O2(t4, { locale: e3.$L, utc: e3.$u, x: e3.$x, $offset: e3.$offset, }) }) var _2 = (function () { function M3(t4) { ;(this.$L = w2(t4.locale, null, true)), this.parse(t4), (this.$x = this.$x || t4.x || {}), (this[p2] = true) } var m3 = M3.prototype return ( (m3.parse = function (t4) { ;(this.$d = (function (t5) { var e3 = t5.date, n3 = t5.utc if (null === e3) return new Date(NaN) if (b2.u(e3)) return new Date() if (e3 instanceof Date) return new Date(e3) if ('string' == typeof e3 && !/Z$/i.test(e3)) { var r3 = e3.match($2) if (r3) { var i3 = r3[2] - 1 || 0, s3 = (r3[7] || '0').substring(0, 3) return n3 ? new Date( Date.UTC( r3[1], i3, r3[3] || 1, r3[4] || 0, r3[5] || 0, r3[6] || 0, s3 ) ) : new Date( r3[1], i3, r3[3] || 1, r3[4] || 0, r3[5] || 0, r3[6] || 0, s3 ) } } return new Date(e3) })(t4)), this.init() }), (m3.init = function () { var t4 = this.$d ;(this.$y = t4.getFullYear()), (this.$M = t4.getMonth()), (this.$D = t4.getDate()), (this.$W = t4.getDay()), (this.$H = t4.getHours()), (this.$m = t4.getMinutes()), (this.$s = t4.getSeconds()), (this.$ms = t4.getMilliseconds()) }), (m3.$utils = function () { return b2 }), (m3.isValid = function () { return !(this.$d.toString() === l2) }), (m3.isSame = function (t4, e3) { var n3 = O2(t4) return this.startOf(e3) <= n3 && n3 <= this.endOf(e3) }), (m3.isAfter = function (t4, e3) { return O2(t4) < this.startOf(e3) }), (m3.isBefore = function (t4, e3) { return this.endOf(e3) < O2(t4) }), (m3.$g = function (t4, e3, n3) { return b2.u(t4) ? this[e3] : this.set(n3, t4) }), (m3.unix = function () { return Math.floor(this.valueOf() / 1e3) }), (m3.valueOf = function () { return this.$d.getTime() }), (m3.startOf = function (t4, e3) { var n3 = this, r3 = !!b2.u(e3) || e3, f3 = b2.p(t4), l3 = function (t5, e4) { var i3 = b2.w( n3.$u ? Date.UTC(n3.$y, e4, t5) : new Date(n3.$y, e4, t5), n3 ) return r3 ? i3 : i3.endOf(a2) }, $3 = function (t5, e4) { return b2.w( n3 .toDate() [t5].apply( n3.toDate('s'), (r3 ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(e4) ), n3 ) }, y3 = this.$W, M4 = this.$M, m4 = this.$D, v5 = 'set' + (this.$u ? 'UTC' : '') switch (f3) { case h2: return r3 ? l3(1, 0) : l3(31, 11) case c2: return r3 ? l3(1, M4) : l3(0, M4 + 1) case o2: var g3 = this.$locale().weekStart || 0, D3 = (y3 < g3 ? y3 + 7 : y3) - g3 return l3(r3 ? m4 - D3 : m4 + (6 - D3), M4) case a2: case d3: return $3(v5 + 'Hours', 0) case u2: return $3(v5 + 'Minutes', 1) case s2: return $3(v5 + 'Seconds', 2) case i2: return $3(v5 + 'Milliseconds', 3) default: return this.clone() } }), (m3.endOf = function (t4) { return this.startOf(t4, false) }), (m3.$set = function (t4, e3) { var n3, o3 = b2.p(t4), f3 = 'set' + (this.$u ? 'UTC' : ''), l3 = ((n3 = {}), (n3[a2] = f3 + 'Date'), (n3[d3] = f3 + 'Date'), (n3[c2] = f3 + 'Month'), (n3[h2] = f3 + 'FullYear'), (n3[u2] = f3 + 'Hours'), (n3[s2] = f3 + 'Minutes'), (n3[i2] = f3 + 'Seconds'), (n3[r2] = f3 + 'Milliseconds'), n3)[o3], $3 = o3 === a2 ? this.$D + (e3 - this.$W) : e3 if (o3 === c2 || o3 === h2) { var y3 = this.clone().set(d3, 1) y3.$d[l3]($3), y3.init(), (this.$d = y3.set(d3, Math.min(this.$D, y3.daysInMonth())).$d) } else l3 && this.$d[l3]($3) return this.init(), this }), (m3.set = function (t4, e3) { return this.clone().$set(t4, e3) }), (m3.get = function (t4) { return this[b2.p(t4)]() }), (m3.add = function (r3, f3) { var d4, l3 = this r3 = Number(r3) var $3 = b2.p(f3), y3 = function (t4) { var e3 = O2(l3) return b2.w(e3.date(e3.date() + Math.round(t4 * r3)), l3) } if ($3 === c2) return this.set(c2, this.$M + r3) if ($3 === h2) return this.set(h2, this.$y + r3) if ($3 === a2) return y3(1) if ($3 === o2) return y3(7) var M4 = ((d4 = {}), (d4[s2] = e2), (d4[u2] = n2), (d4[i2] = t3), d4)[ $3 ] || 1, m4 = this.$d.getTime() + r3 * M4 return b2.w(m4, this) }), (m3.subtract = function (t4, e3) { return this.add(-1 * t4, e3) }), (m3.format = function (t4) { var e3 = this, n3 = this.$locale() if (!this.isValid()) return n3.invalidDate || l2 var r3 = t4 || 'YYYY-MM-DDTHH:mm:ssZ', i3 = b2.z(this), s3 = this.$H, u3 = this.$m, a3 = this.$M, o3 = n3.weekdays, c3 = n3.months, f3 = n3.meridiem, h3 = function (t5, n4, i4, s4) { return (t5 && (t5[n4] || t5(e3, r3))) || i4[n4].slice(0, s4) }, d4 = function (t5) { return b2.s(s3 % 12 || 12, t5, '0') }, $3 = f3 || function (t5, e4, n4) { var r4 = t5 < 12 ? 'AM' : 'PM' return n4 ? r4.toLowerCase() : r4 } return r3.replace(y2, function (t5, r4) { return ( r4 || (function (t6) { switch (t6) { case 'YY': return String(e3.$y).slice(-2) case 'YYYY': return b2.s(e3.$y, 4, '0') case 'M': return a3 + 1 case 'MM': return b2.s(a3 + 1, 2, '0') case 'MMM': return h3(n3.monthsShort, a3, c3, 3) case 'MMMM': return h3(c3, a3) case 'D': return e3.$D case 'DD': return b2.s(e3.$D, 2, '0') case 'd': return String(e3.$W) case 'dd': return h3(n3.weekdaysMin, e3.$W, o3, 2) case 'ddd': return h3(n3.weekdaysShort, e3.$W, o3, 3) case 'dddd': return o3[e3.$W] case 'H': return String(s3) case 'HH': return b2.s(s3, 2, '0') case 'h': return d4(1) case 'hh': return d4(2) case 'a': return $3(s3, u3, true) case 'A': return $3(s3, u3, false) case 'm': return String(u3) case 'mm': return b2.s(u3, 2, '0') case 's': return String(e3.$s) case 'ss': return b2.s(e3.$s, 2, '0') case 'SSS': return b2.s(e3.$ms, 3, '0') case 'Z': return i3 } return null })(t5) || i3.replace(':', '') ) }) }), (m3.utcOffset = function () { return 15 * -Math.round(this.$d.getTimezoneOffset() / 15) }), (m3.diff = function (r3, d4, l3) { var $3, y3 = this, M4 = b2.p(d4), m4 = O2(r3), v5 = (m4.utcOffset() - this.utcOffset()) * e2, g3 = this - m4, D3 = function () { return b2.m(y3, m4) } switch (M4) { case h2: $3 = D3() / 12 break case c2: $3 = D3() break case f2: $3 = D3() / 3 break case o2: $3 = (g3 - v5) / 6048e5 break case a2: $3 = (g3 - v5) / 864e5 break case u2: $3 = g3 / n2 break case s2: $3 = g3 / e2 break case i2: $3 = g3 / t3 break default: $3 = g3 } return l3 ? $3 : b2.a($3) }), (m3.daysInMonth = function () { return this.endOf(c2).$D }), (m3.$locale = function () { return D2[this.$L] }), (m3.locale = function (t4, e3) { if (!t4) return this.$L var n3 = this.clone(), r3 = w2(t4, e3, true) return r3 && (n3.$L = r3), n3 }), (m3.clone = function () { return b2.w(this.$d, this) }), (m3.toDate = function () { return new Date(this.valueOf()) }), (m3.toJSON = function () { return this.isValid() ? this.toISOString() : null }), (m3.toISOString = function () { return this.$d.toISOString() }), (m3.toString = function () { return this.$d.toUTCString() }), M3 ) })(), k2 = _2.prototype return ( (O2.prototype = k2), [ ['$ms', r2], ['$s', i2], ['$m', s2], ['$H', u2], ['$W', a2], ['$M', c2], ['$y', h2], ['$D', d3], ].forEach(function (t4) { k2[t4[1]] = function (e3) { return this.$g(e3, t4[0], t4[1]) } }), (O2.extend = function (t4, e3) { return t4.$i || (t4(e3, _2, O2), (t4.$i = true)), O2 }), (O2.locale = w2), (O2.isDayjs = S2), (O2.unix = function (t4) { return O2(1e3 * t4) }), (O2.en = D2[g2]), (O2.Ls = D2), (O2.p = {}), O2 ) }) })(dayjs_min$1) var dayjs = dayjs_min$1.exports var dayjs_min = /* @__PURE__ */ _mergeNamespaces( { __proto__: null, default: dayjs, }, [dayjs_min$1.exports] ) var localeData$1 = { exports: {} } ;(function (module2, exports2) { !(function (n2, e2) { module2.exports = e2() })(commonjsGlobal, function () { return function (n2, e2, t3) { var r2 = e2.prototype, o2 = function (n3) { return n3 && (n3.indexOf ? n3 : n3.s) }, u2 = function (n3, e3, t4, r3, u3) { var i3 = n3.name ? n3 : n3.$locale(), a3 = o2(i3[e3]), s3 = o2(i3[t4]), f2 = a3 || s3.map(function (n4) { return n4.slice(0, r3) }) if (!u3) return f2 var d3 = i3.weekStart return f2.map(function (n4, e4) { return f2[(e4 + (d3 || 0)) % 7] }) }, i2 = function () { return t3.Ls[t3.locale()] }, a2 = function (n3, e3) { return ( n3.formats[e3] || (function (n4) { return n4.replace( /(\[[^\]]+])|(MMMM|MM|DD|dddd)/g, function (n5, e4, t4) { return e4 || t4.slice(1) } ) })(n3.formats[e3.toUpperCase()]) ) }, s2 = function () { var n3 = this return { months: function (e3) { return e3 ? e3.format('MMMM') : u2(n3, 'months') }, monthsShort: function (e3) { return e3 ? e3.format('MMM') : u2(n3, 'monthsShort', 'months', 3) }, firstDayOfWeek: function () { return n3.$locale().weekStart || 0 }, weekdays: function (e3) { return e3 ? e3.format('dddd') : u2(n3, 'weekdays') }, weekdaysMin: function (e3) { return e3 ? e3.format('dd') : u2(n3, 'weekdaysMin', 'weekdays', 2) }, weekdaysShort: function (e3) { return e3 ? e3.format('ddd') : u2(n3, 'weekdaysShort', 'weekdays', 3) }, longDateFormat: function (e3) { return a2(n3.$locale(), e3) }, meridiem: this.$locale().meridiem, ordinal: this.$locale().ordinal, } } ;(r2.localeData = function () { return s2.bind(this)() }), (t3.localeData = function () { var n3 = i2() return { firstDayOfWeek: function () { return n3.weekStart || 0 }, weekdays: function () { return t3.weekdays() }, weekdaysShort: function () { return t3.weekdaysShort() }, weekdaysMin: function () { return t3.weekdaysMin() }, months: function () { return t3.months() }, monthsShort: function () { return t3.monthsShort() }, longDateFormat: function (e3) { return a2(n3, e3) }, meridiem: n3.meridiem, ordinal: n3.ordinal, } }), (t3.months = function () { return u2(i2(), 'months') }), (t3.monthsShort = function () { return u2(i2(), 'monthsShort', 'months', 3) }), (t3.weekdays = function (n3) { return u2(i2(), 'weekdays', null, null, n3) }), (t3.weekdaysShort = function (n3) { return u2(i2(), 'weekdaysShort', 'weekdays', 3, n3) }), (t3.weekdaysMin = function (n3) { return u2(i2(), 'weekdaysMin', 'weekdays', 2, n3) }) } }) })(localeData$1) var localeData = localeData$1.exports var customParseFormat$1 = { exports: {} } ;(function (module2, exports2) { !(function (e2, t3) { module2.exports = t3() })(commonjsGlobal, function () { var e2 = { LTS: 'h:mm:ss A', LT: 'h:mm A', L: 'MM/DD/YYYY', LL: 'MMMM D, YYYY', LLL: 'MMMM D, YYYY h:mm A', LLLL: 'dddd, MMMM D, YYYY h:mm A', }, t3 = /(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|YYYY|YY?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g, n2 = /\d\d/, r2 = /\d\d?/, i2 = /\d*[^-_:/,()\s\d]+/, o2 = {}, s2 = function (e3) { return (e3 = +e3) + (e3 > 68 ? 1900 : 2e3) } var a2 = function (e3) { return function (t4) { this[e3] = +t4 } }, f2 = [ /[+-]\d\d:?(\d\d)?|Z/, function (e3) { ;(this.zone || (this.zone = {})).offset = (function (e4) { if (!e4) return 0 if ('Z' === e4) return 0 var t4 = e4.match(/([+-]|\d\d)/g), n3 = 60 * t4[1] + (+t4[2] || 0) return 0 === n3 ? 0 : '+' === t4[0] ? -n3 : n3 })(e3) }, ], h2 = function (e3) { var t4 = o2[e3] return t4 && (t4.indexOf ? t4 : t4.s.concat(t4.f)) }, u2 = function (e3, t4) { var n3, r3 = o2.meridiem if (r3) { for (var i3 = 1; i3 <= 24; i3 += 1) if (e3.indexOf(r3(i3, 0, t4)) > -1) { n3 = i3 > 12 break } } else n3 = e3 === (t4 ? 'pm' : 'PM') return n3 }, d3 = { A: [ i2, function (e3) { this.afternoon = u2(e3, false) }, ], a: [ i2, function (e3) { this.afternoon = u2(e3, true) }, ], S: [ /\d/, function (e3) { this.milliseconds = 100 * +e3 }, ], SS: [ n2, function (e3) { this.milliseconds = 10 * +e3 }, ], SSS: [ /\d{3}/, function (e3) { this.milliseconds = +e3 }, ], s: [r2, a2('seconds')], ss: [r2, a2('seconds')], m: [r2, a2('minutes')], mm: [r2, a2('minutes')], H: [r2, a2('hours')], h: [r2, a2('hours')], HH: [r2, a2('hours')], hh: [r2, a2('hours')], D: [r2, a2('day')], DD: [n2, a2('day')], Do: [ i2, function (e3) { var t4 = o2.ordinal, n3 = e3.match(/\d+/) if (((this.day = n3[0]), t4)) for (var r3 = 1; r3 <= 31; r3 += 1) t4(r3).replace(/\[|\]/g, '') === e3 && (this.day = r3) }, ], M: [r2, a2('month')], MM: [n2, a2('month')], MMM: [ i2, function (e3) { var t4 = h2('months'), n3 = ( h2('monthsShort') || t4.map(function (e4) { return e4.slice(0, 3) }) ).indexOf(e3) + 1 if (n3 < 1) throw new Error() this.month = n3 % 12 || n3 }, ], MMMM: [ i2, function (e3) { var t4 = h2('months').indexOf(e3) + 1 if (t4 < 1) throw new Error() this.month = t4 % 12 || t4 }, ], Y: [/[+-]?\d+/, a2('year')], YY: [ n2, function (e3) { this.year = s2(e3) }, ], YYYY: [/\d{4}/, a2('year')], Z: f2, ZZ: f2, } function c2(n3) { var r3, i3 ;(r3 = n3), (i3 = o2 && o2.formats) for ( var s3 = (n3 = r3.replace( /(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g, function (t4, n4, r4) { var o3 = r4 && r4.toUpperCase() return ( n4 || i3[r4] || e2[r4] || i3[o3].replace( /(\[[^\]]+])|(MMMM|MM|DD|dddd)/g, function (e3, t5, n5) { return t5 || n5.slice(1) } ) ) } )).match(t3), a3 = s3.length, f3 = 0; f3 < a3; f3 += 1 ) { var h3 = s3[f3], u3 = d3[h3], c3 = u3 && u3[0], l2 = u3 && u3[1] s3[f3] = l2 ? { regex: c3, parser: l2 } : h3.replace(/^\[|\]$/g, '') } return function (e3) { for (var t4 = {}, n4 = 0, r4 = 0; n4 < a3; n4 += 1) { var i4 = s3[n4] if ('string' == typeof i4) r4 += i4.length else { var o3 = i4.regex, f4 = i4.parser, h4 = e3.slice(r4), u4 = o3.exec(h4)[0] f4.call(t4, u4), (e3 = e3.replace(u4, '')) } } return ( (function (e4) { var t5 = e4.afternoon if (void 0 !== t5) { var n5 = e4.hours t5 ? n5 < 12 && (e4.hours += 12) : 12 === n5 && (e4.hours = 0), delete e4.afternoon } })(t4), t4 ) } } return function (e3, t4, n3) { ;(n3.p.customParseFormat = true), e3 && e3.parseTwoDigitYear && (s2 = e3.parseTwoDigitYear) var r3 = t4.prototype, i3 = r3.parse r3.parse = function (e4) { var t5 = e4.date, r4 = e4.utc, s3 = e4.args this.$u = r4 var a3 = s3[1] if ('string' == typeof a3) { var f3 = true === s3[2], h3 = true === s3[3], u3 = f3 || h3, d4 = s3[2] h3 && (d4 = s3[2]), (o2 = this.$locale()), !f3 && d4 && (o2 = n3.Ls[d4]), (this.$d = (function (e5, t6, n4) { try { if (['x', 'X'].indexOf(t6) > -1) return new Date(('X' === t6 ? 1e3 : 1) * e5) var r5 = c2(t6)(e5), i4 = r5.year, o3 = r5.month, s4 = r5.day, a4 = r5.hours, f4 = r5.minutes, h4 = r5.seconds, u4 = r5.milliseconds, d5 = r5.zone, l3 = new Date(), m3 = s4 || (i4 || o3 ? 1 : l3.getDate()), M3 = i4 || l3.getFullYear(), Y2 = 0 ;(i4 && !o3) || (Y2 = o3 > 0 ? o3 - 1 : l3.getMonth()) var p2 = a4 || 0, v4 = f4 || 0, D2 = h4 || 0, g2 = u4 || 0 return d5 ? new Date( Date.UTC( M3, Y2, m3, p2, v4, D2, g2 + 60 * d5.offset * 1e3 ) ) : n4 ? new Date(Date.UTC(M3, Y2, m3, p2, v4, D2, g2)) : new Date(M3, Y2, m3, p2, v4, D2, g2) } catch (e6) { return new Date('') } })(t5, a3, r4)), this.init(), d4 && true !== d4 && (this.$L = this.locale(d4).$L), u3 && t5 != this.format(a3) && (this.$d = new Date('')), (o2 = {}) } else if (a3 instanceof Array) for (var l2 = a3.length, m2 = 1; m2 <= l2; m2 += 1) { s3[1] = a3[m2 - 1] var M2 = n3.apply(this, s3) if (M2.isValid()) { ;(this.$d = M2.$d), (this.$L = M2.$L), this.init() break } m2 === l2 && (this.$d = new Date('')) } else i3.call(this, e4) } } }) })(customParseFormat$1) var customParseFormat = customParseFormat$1.exports const DEFAULT_FORMATS_TIME = 'HH:mm:ss' const DEFAULT_FORMATS_DATE = 'YYYY-MM-DD' const DEFAULT_FORMATS_DATEPICKER = { date: DEFAULT_FORMATS_DATE, week: 'gggg[w]ww', year: 'YYYY', month: 'YYYY-MM', datetime: `${DEFAULT_FORMATS_DATE} ${DEFAULT_FORMATS_TIME}`, monthrange: 'YYYY-MM', daterange: DEFAULT_FORMATS_DATE, datetimerange: `${DEFAULT_FORMATS_DATE} ${DEFAULT_FORMATS_TIME}`, } const timePickerDefaultProps = { id: { type: [Array, String], }, name: { type: [Array, String], default: '', }, popperClass: { type: String, default: '', }, format: { type: String, }, valueFormat: { type: String, }, type: { type: String, default: '', }, clearable: { type: Boolean, default: true, }, clearIcon: { type: [String, Object], default: circleClose, }, editable: { type: Boolean, default: true, }, prefixIcon: { type: [String, Object], default: '', }, size: { type: String, validator: isValidComponentSize, }, readonly: { type: Boolean, default: false, }, disabled: { type: Boolean, default: false, }, placeholder: { type: String, default: '', }, popperOptions: { type: Object, default: () => ({}), }, modelValue: { type: [Date, Array, String, Number], default: '', }, rangeSeparator: { type: String, default: '-', }, startPlaceholder: String, endPlaceholder: String, defaultValue: { type: [Date, Array], }, defaultTime: { type: [Date, Array], }, isRange: { type: Boolean, default: false, }, disabledHours: { type: Function, }, disabledMinutes: { type: Function, }, disabledSeconds: { type: Function, }, disabledDate: { type: Function, }, cellClassName: { type: Function, }, shortcuts: { type: Array, default: () => [], }, arrowControl: { type: Boolean, default: false, }, validateEvent: { type: Boolean, default: true, }, unlinkPanels: Boolean, } const dateEquals = function (a2, b2) { const aIsDate = a2 instanceof Date const bIsDate = b2 instanceof Date if (aIsDate && bIsDate) { return a2.getTime() === b2.getTime() } if (!aIsDate && !bIsDate) { return a2 === b2 } return false } const valueEquals = function (a2, b2) { const aIsArray = Array.isArray(a2) const bIsArray = Array.isArray(b2) if (aIsArray && bIsArray) { if (a2.length !== b2.length) { return false } return a2.every((item2, index2) => dateEquals(item2, b2[index2])) } if (!aIsArray && !bIsArray) { return dateEquals(a2, b2) } return false } const parser = function (date4, format2, lang) { const day = isEmpty$3(format2) || format2 === 'x' ? dayjs(date4).locale(lang) : dayjs(date4, format2).locale(lang) return day.isValid() ? day : void 0 } const formatter = function (date4, format2, lang) { if (isEmpty$3(format2)) return date4 if (format2 === 'x') return +date4 return dayjs(date4).locale(lang).format(format2) } const _sfc_main$8$ = defineComponent({ name: 'Picker', components: { ElInput, ElTooltip, ElIcon, }, props: timePickerDefaultProps, emits: [ 'update:modelValue', 'change', 'focus', 'blur', 'calendar-change', 'panel-change', 'visible-change', ], setup(props2, ctx) { const { lang } = useLocale() const nsDate = useNamespace('date') const nsInput = useNamespace('input') const nsRange = useNamespace('range') const elForm = inject(formContextKey, {}) const elFormItem = inject(formItemContextKey, {}) const elPopperOptions = inject('ElPopperOptions', {}) const refPopper = ref() const inputRef = ref() const pickerVisible = ref(false) const pickerActualVisible = ref(false) const valueOnOpen = ref(null) watch$1(pickerVisible, (val2) => { var _a2 if (!val2) { userInput.value = null nextTick(() => { emitChange(props2.modelValue) }) ctx.emit('blur') blurInput() props2.validateEvent && ((_a2 = elFormItem.validate) == null ? void 0 : _a2.call(elFormItem, 'blur').catch((err) => debugWarn())) } else { valueOnOpen.value = props2.modelValue } }) const emitChange = (val2, isClear) => { var _a2 if (isClear || !valueEquals(val2, valueOnOpen.value)) { ctx.emit('change', val2) props2.validateEvent && ((_a2 = elFormItem.validate) == null ? void 0 : _a2.call(elFormItem, 'change').catch((err) => debugWarn())) } } const emitInput = (val2) => { if (!valueEquals(props2.modelValue, val2)) { let formatValue if (Array.isArray(val2)) { formatValue = val2.map((_2) => formatter(_2, props2.valueFormat, lang.value) ) } else if (val2) { formatValue = formatter(val2, props2.valueFormat, lang.value) } ctx.emit('update:modelValue', val2 ? formatValue : val2, lang.value) } } const refInput = computed(() => { if (inputRef.value) { const _r = isRangeInput.value ? inputRef.value : inputRef.value.$el return Array.from(_r.querySelectorAll('input')) } return [] }) const refStartInput = computed(() => { return refInput == null ? void 0 : refInput.value[0] }) const refEndInput = computed(() => { return refInput == null ? void 0 : refInput.value[1] }) const setSelectionRange = (start2, end2, pos) => { const _inputs = refInput.value if (!_inputs.length) return if (!pos || pos === 'min') { _inputs[0].setSelectionRange(start2, end2) _inputs[0].focus() } else if (pos === 'max') { _inputs[1].setSelectionRange(start2, end2) _inputs[1].focus() } } const onPick = (date4 = '', visible = false) => { pickerVisible.value = visible let result if (Array.isArray(date4)) { result = date4.map((_2) => _2.toDate()) } else { result = date4 ? date4.toDate() : date4 } userInput.value = null emitInput(result) } const onBeforeShow = () => { pickerActualVisible.value = true } const onShow = () => { ctx.emit('visible-change', true) } const onHide = () => { pickerActualVisible.value = false ctx.emit('visible-change', false) } const focus2 = (focusStartInput = true) => { let input = refStartInput.value if (!focusStartInput && isRangeInput.value) { input = refEndInput.value } if (input) { input.focus() } } const handleFocus = (e2) => { if (props2.readonly || pickerDisabled.value || pickerVisible.value) return pickerVisible.value = true ctx.emit('focus', e2) } const handleBlur = () => { var _a2 ;(_a2 = refPopper.value) == null ? void 0 : _a2.onClose() blurInput() } const pickerDisabled = computed(() => { return props2.disabled || elForm.disabled }) const parsedValue = computed(() => { let result if (valueIsEmpty.value) { if (pickerOptions.value.getDefaultValue) { result = pickerOptions.value.getDefaultValue() } } else { if (Array.isArray(props2.modelValue)) { result = props2.modelValue.map((_2) => parser(_2, props2.valueFormat, lang.value) ) } else { result = parser(props2.modelValue, props2.valueFormat, lang.value) } } if (pickerOptions.value.getRangeAvailableTime) { const availableResult = pickerOptions.value.getRangeAvailableTime(result) if (!isEqual$4(availableResult, result)) { result = availableResult emitInput( Array.isArray(result) ? result.map((_2) => _2.toDate()) : result.toDate() ) } } if (Array.isArray(result) && result.some((_2) => !_2)) { result = [] } return result }) const displayValue = computed(() => { if (!pickerOptions.value.panelReady) return const formattedValue = formatDayjsToString(parsedValue.value) if (Array.isArray(userInput.value)) { return [ userInput.value[0] || (formattedValue && formattedValue[0]) || '', userInput.value[1] || (formattedValue && formattedValue[1]) || '', ] } else if (userInput.value !== null) { return userInput.value } if (!isTimePicker.value && valueIsEmpty.value) return if (!pickerVisible.value && valueIsEmpty.value) return if (formattedValue) { return isDatesPicker.value ? formattedValue.join(', ') : formattedValue } return '' }) const isTimeLikePicker = computed(() => props2.type.includes('time')) const isTimePicker = computed(() => props2.type.startsWith('time')) const isDatesPicker = computed(() => props2.type === 'dates') const triggerIcon = computed( () => props2.prefixIcon || (isTimeLikePicker.value ? clock : calendar) ) const showClose = ref(false) const onClearIconClick = (event) => { if (props2.readonly || pickerDisabled.value) return if (showClose.value) { event.stopPropagation() emitInput(null) emitChange(null, true) showClose.value = false pickerVisible.value = false pickerOptions.value.handleClear && pickerOptions.value.handleClear() } } const valueIsEmpty = computed(() => { return ( !props2.modelValue || (Array.isArray(props2.modelValue) && !props2.modelValue.length) ) }) const onMouseEnter = () => { if (props2.readonly || pickerDisabled.value) return if (!valueIsEmpty.value && props2.clearable) { showClose.value = true } } const onMouseLeave = () => { showClose.value = false } const isRangeInput = computed(() => { return props2.type.includes('range') }) const pickerSize = useSize$1() const popperPaneRef = computed(() => { var _a2, _b2 return (_b2 = (_a2 = refPopper.value) == null ? void 0 : _a2.popperRef) == null ? void 0 : _b2.contentRef }) const popperEl = computed(() => { var _a2, _b2 return (_b2 = (_a2 = unref(refPopper)) == null ? void 0 : _a2.popperRef) == null ? void 0 : _b2.contentRef }) const actualInputRef = computed(() => { var _a2 if (unref(isRangeInput)) { return unref(inputRef) } return (_a2 = unref(inputRef)) == null ? void 0 : _a2.$el }) onClickOutside$1(actualInputRef, (e2) => { const unrefedPopperEl = unref(popperEl) const inputEl = unref(actualInputRef) if ( (unrefedPopperEl && (e2.target === unrefedPopperEl || e2.composedPath().includes(unrefedPopperEl))) || e2.target === inputEl || e2.composedPath().includes(inputEl) ) return pickerVisible.value = false }) const userInput = ref(null) const handleChange = () => { if (userInput.value) { const value2 = parseUserInputToDayjs(displayValue.value) if (value2) { if (isValidValue(value2)) { emitInput( Array.isArray(value2) ? value2.map((_2) => _2.toDate()) : value2.toDate() ) userInput.value = null } } } if (userInput.value === '') { emitInput(null) emitChange(null) userInput.value = null } } const blurInput = () => { refInput.value.forEach((input) => input.blur()) } const parseUserInputToDayjs = (value2) => { if (!value2) return null return pickerOptions.value.parseUserInput(value2) } const formatDayjsToString = (value2) => { if (!value2) return null return pickerOptions.value.formatToString(value2) } const isValidValue = (value2) => { return pickerOptions.value.isValidValue(value2) } const handleKeydown = (event) => { const code2 = event.code if (code2 === EVENT_CODE.esc) { pickerVisible.value = false event.stopPropagation() return } if (code2 === EVENT_CODE.tab) { if (!isRangeInput.value) { handleChange() pickerVisible.value = false event.stopPropagation() } else { setTimeout(() => { if (!refInput.value.includes(document.activeElement)) { pickerVisible.value = false blurInput() } }, 0) } return } if (code2 === EVENT_CODE.enter || code2 === EVENT_CODE.numpadEnter) { if ( userInput.value === null || userInput.value === '' || isValidValue(parseUserInputToDayjs(displayValue.value)) ) { handleChange() pickerVisible.value = false } event.stopPropagation() return } if (userInput.value) { event.stopPropagation() return } if (pickerOptions.value.handleKeydown) { pickerOptions.value.handleKeydown(event) } } const onUserInput = (e2) => { userInput.value = e2 } const handleStartInput = (event) => { if (userInput.value) { userInput.value = [event.target.value, userInput.value[1]] } else { userInput.value = [event.target.value, null] } } const handleEndInput = (event) => { if (userInput.value) { userInput.value = [userInput.value[0], event.target.value] } else { userInput.value = [null, event.target.value] } } const handleStartChange = () => { const value2 = parseUserInputToDayjs( userInput.value && userInput.value[0] ) if (value2 && value2.isValid()) { userInput.value = [formatDayjsToString(value2), displayValue.value[1]] const newValue = [value2, parsedValue.value && parsedValue.value[1]] if (isValidValue(newValue)) { emitInput(newValue) userInput.value = null } } } const handleEndChange = () => { const value2 = parseUserInputToDayjs( userInput.value && userInput.value[1] ) if (value2 && value2.isValid()) { userInput.value = [displayValue.value[0], formatDayjsToString(value2)] const newValue = [parsedValue.value && parsedValue.value[0], value2] if (isValidValue(newValue)) { emitInput(newValue) userInput.value = null } } } const pickerOptions = ref({}) const onSetPickerOption = (e2) => { pickerOptions.value[e2[0]] = e2[1] pickerOptions.value.panelReady = true } const onCalendarChange = (e2) => { ctx.emit('calendar-change', e2) } const onPanelChange = (value2, mode2, view2) => { ctx.emit('panel-change', value2, mode2, view2) } provide('EP_PICKER_BASE', { props: props2, }) return { nsDate, nsInput, nsRange, elPopperOptions, isDatesPicker, handleEndChange, handleStartChange, handleStartInput, handleEndInput, onUserInput, handleChange, handleKeydown, popperPaneRef, onClickOutside: onClickOutside$1, pickerSize, isRangeInput, onMouseLeave, onMouseEnter, onClearIconClick, showClose, triggerIcon, onPick, handleFocus, handleBlur, pickerVisible, pickerActualVisible, displayValue, parsedValue, setSelectionRange, refPopper, inputRef, pickerDisabled, onSetPickerOption, onCalendarChange, onPanelChange, focus: focus2, onShow, onBeforeShow, onHide, } }, }) const _hoisted_1$6U = [ 'id', 'name', 'placeholder', 'value', 'disabled', 'readonly', ] const _hoisted_2$5y = [ 'id', 'name', 'placeholder', 'value', 'disabled', 'readonly', ] function _sfc_render$1C(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_icon = resolveComponent('el-icon') const _component_el_input = resolveComponent('el-input') const _component_el_tooltip = resolveComponent('el-tooltip') return ( openBlock(), createBlock( _component_el_tooltip, mergeProps( { ref: 'refPopper', visible: _ctx.pickerVisible, 'onUpdate:visible': _cache[17] || (_cache[17] = ($event) => (_ctx.pickerVisible = $event)), effect: 'light', pure: '', trigger: 'click', }, _ctx.$attrs, { 'append-to-body': '', transition: `${_ctx.nsDate.namespace.value}-zoom-in-top`, 'popper-class': [ `${_ctx.nsDate.namespace.value}-picker__popper`, _ctx.popperClass, ], 'popper-options': _ctx.elPopperOptions, 'fallback-placements': ['bottom', 'top', 'right', 'left'], 'gpu-acceleration': false, 'stop-popper-mouse-event': false, 'hide-after': 0, persistent: '', onBeforeShow: _ctx.onBeforeShow, onShow: _ctx.onShow, onHide: _ctx.onHide, } ), { default: withCtx(() => [ !_ctx.isRangeInput ? (openBlock(), createBlock( _component_el_input, { key: 0, id: _ctx.id, ref: 'inputRef', 'model-value': _ctx.displayValue, name: _ctx.name, size: _ctx.pickerSize, disabled: _ctx.pickerDisabled, placeholder: _ctx.placeholder, class: normalizeClass([ _ctx.nsDate.b('editor'), _ctx.nsDate.bm('editor', _ctx.type), _ctx.$attrs.class, ]), style: normalizeStyle$1(_ctx.$attrs.style), readonly: !_ctx.editable || _ctx.readonly || _ctx.isDatesPicker || _ctx.type === 'week', onInput: _ctx.onUserInput, onFocus: _ctx.handleFocus, onKeydown: _ctx.handleKeydown, onChange: _ctx.handleChange, onMouseenter: _ctx.onMouseEnter, onMouseleave: _ctx.onMouseLeave, onClick: _cache[0] || (_cache[0] = withModifiers(() => {}, ['stop'])), }, { prefix: withCtx(() => [ _ctx.triggerIcon ? (openBlock(), createBlock( _component_el_icon, { key: 0, class: normalizeClass(_ctx.nsInput.e('icon')), onClick: _ctx.handleFocus, }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent(_ctx.triggerIcon) )), ]), _: 1, }, 8, ['class', 'onClick'] )) : createCommentVNode('v-if', true), ]), suffix: withCtx(() => [ _ctx.showClose && _ctx.clearIcon ? (openBlock(), createBlock( _component_el_icon, { key: 0, class: normalizeClass( `${_ctx.nsInput.e('icon')} clear-icon` ), onClick: _ctx.onClearIconClick, }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent(_ctx.clearIcon) )), ]), _: 1, }, 8, ['class', 'onClick'] )) : createCommentVNode('v-if', true), ]), _: 1, }, 8, [ 'id', 'model-value', 'name', 'size', 'disabled', 'placeholder', 'class', 'style', 'readonly', 'onInput', 'onFocus', 'onKeydown', 'onChange', 'onMouseenter', 'onMouseleave', ] )) : (openBlock(), createElementBlock( 'div', { key: 1, ref: 'inputRef', class: normalizeClass([ _ctx.nsDate.b('editor'), _ctx.nsDate.bm('editor', _ctx.type), _ctx.nsInput.e('inner'), _ctx.nsDate.is('disabled', _ctx.pickerDisabled), _ctx.nsDate.is('active', _ctx.pickerVisible), _ctx.nsRange.b('editor'), _ctx.pickerSize ? _ctx.nsRange.bm('editor', _ctx.pickerSize) : '', _ctx.$attrs.class, ]), style: normalizeStyle$1(_ctx.$attrs.style), onClick: _cache[7] || (_cache[7] = (...args) => _ctx.handleFocus && _ctx.handleFocus(...args)), onMouseenter: _cache[8] || (_cache[8] = (...args) => _ctx.onMouseEnter && _ctx.onMouseEnter(...args)), onMouseleave: _cache[9] || (_cache[9] = (...args) => _ctx.onMouseLeave && _ctx.onMouseLeave(...args)), onKeydown: _cache[10] || (_cache[10] = (...args) => _ctx.handleKeydown && _ctx.handleKeydown(...args)), }, [ _ctx.triggerIcon ? (openBlock(), createBlock( _component_el_icon, { key: 0, class: normalizeClass([ _ctx.nsInput.e('icon'), _ctx.nsRange.e('icon'), ]), onClick: _ctx.handleFocus, }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent(_ctx.triggerIcon) )), ]), _: 1, }, 8, ['class', 'onClick'] )) : createCommentVNode('v-if', true), createElementVNode( 'input', { id: _ctx.id && _ctx.id[0], autocomplete: 'off', name: _ctx.name && _ctx.name[0], placeholder: _ctx.startPlaceholder, value: _ctx.displayValue && _ctx.displayValue[0], disabled: _ctx.pickerDisabled, readonly: !_ctx.editable || _ctx.readonly, class: normalizeClass(_ctx.nsRange.b('input')), onInput: _cache[1] || (_cache[1] = (...args) => _ctx.handleStartInput && _ctx.handleStartInput(...args)), onChange: _cache[2] || (_cache[2] = (...args) => _ctx.handleStartChange && _ctx.handleStartChange(...args)), onFocus: _cache[3] || (_cache[3] = (...args) => _ctx.handleFocus && _ctx.handleFocus(...args)), }, null, 42, _hoisted_1$6U ), renderSlot(_ctx.$slots, 'range-separator', {}, () => [ createElementVNode( 'span', { class: normalizeClass(_ctx.nsRange.b('separator')), }, toDisplayString$1(_ctx.rangeSeparator), 3 ), ]), createElementVNode( 'input', { id: _ctx.id && _ctx.id[1], autocomplete: 'off', name: _ctx.name && _ctx.name[1], placeholder: _ctx.endPlaceholder, value: _ctx.displayValue && _ctx.displayValue[1], disabled: _ctx.pickerDisabled, readonly: !_ctx.editable || _ctx.readonly, class: normalizeClass(_ctx.nsRange.b('input')), onFocus: _cache[4] || (_cache[4] = (...args) => _ctx.handleFocus && _ctx.handleFocus(...args)), onInput: _cache[5] || (_cache[5] = (...args) => _ctx.handleEndInput && _ctx.handleEndInput(...args)), onChange: _cache[6] || (_cache[6] = (...args) => _ctx.handleEndChange && _ctx.handleEndChange(...args)), }, null, 42, _hoisted_2$5y ), _ctx.clearIcon ? (openBlock(), createBlock( _component_el_icon, { key: 1, class: normalizeClass([ _ctx.nsInput.e('icon'), _ctx.nsRange.e('close-icon'), { [_ctx.nsRange.e('close-icon--hidden')]: !_ctx.showClose, }, ]), onClick: _ctx.onClearIconClick, }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent(_ctx.clearIcon) )), ]), _: 1, }, 8, ['class', 'onClick'] )) : createCommentVNode('v-if', true), ], 38 )), ]), content: withCtx(() => [ renderSlot(_ctx.$slots, 'default', { visible: _ctx.pickerVisible, actualVisible: _ctx.pickerActualVisible, parsedValue: _ctx.parsedValue, format: _ctx.format, unlinkPanels: _ctx.unlinkPanels, type: _ctx.type, defaultValue: _ctx.defaultValue, onPick: _cache[11] || (_cache[11] = (...args) => _ctx.onPick && _ctx.onPick(...args)), onSelectRange: _cache[12] || (_cache[12] = (...args) => _ctx.setSelectionRange && _ctx.setSelectionRange(...args)), onSetPickerOption: _cache[13] || (_cache[13] = (...args) => _ctx.onSetPickerOption && _ctx.onSetPickerOption(...args)), onCalendarChange: _cache[14] || (_cache[14] = (...args) => _ctx.onCalendarChange && _ctx.onCalendarChange(...args)), onPanelChange: _cache[15] || (_cache[15] = (...args) => _ctx.onPanelChange && _ctx.onPanelChange(...args)), onMousedown: _cache[16] || (_cache[16] = withModifiers(() => {}, ['stop'])), }), ]), _: 3, }, 16, [ 'visible', 'transition', 'popper-class', 'popper-options', 'onBeforeShow', 'onShow', 'onHide', ] ) ) } var CommonPicker = /* @__PURE__ */ _export_sfc$1(_sfc_main$8$, [ ['render', _sfc_render$1C], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/time-picker/src/common/picker.vue', ], ]) const nodeList = /* @__PURE__ */ new Map() let startClick if (isClient$1) { document.addEventListener('mousedown', (e2) => (startClick = e2)) document.addEventListener('mouseup', (e2) => { for (const handlers2 of nodeList.values()) { for (const { documentHandler } of handlers2) { documentHandler(e2, startClick) } } }) } function createDocumentHandler(el2, binding) { let excludes = [] if (Array.isArray(binding.arg)) { excludes = binding.arg } else if (isElement$3(binding.arg)) { excludes.push(binding.arg) } return function (mouseup, mousedown) { const popperRef = binding.instance.popperRef const mouseUpTarget = mouseup.target const mouseDownTarget = mousedown == null ? void 0 : mousedown.target const isBound = !binding || !binding.instance const isTargetExists = !mouseUpTarget || !mouseDownTarget const isContainedByEl = el2.contains(mouseUpTarget) || el2.contains(mouseDownTarget) const isSelf = el2 === mouseUpTarget const isTargetExcluded = (excludes.length && excludes.some((item2) => item2 == null ? void 0 : item2.contains(mouseUpTarget) )) || (excludes.length && excludes.includes(mouseDownTarget)) const isContainedByPopper = popperRef && (popperRef.contains(mouseUpTarget) || popperRef.contains(mouseDownTarget)) if ( isBound || isTargetExists || isContainedByEl || isSelf || isTargetExcluded || isContainedByPopper ) { return } binding.value(mouseup, mousedown) } } const ClickOutside = { beforeMount(el2, binding) { if (!nodeList.has(el2)) { nodeList.set(el2, []) } nodeList.get(el2).push({ documentHandler: createDocumentHandler(el2, binding), bindingFn: binding.value, }) }, updated(el2, binding) { if (!nodeList.has(el2)) { nodeList.set(el2, []) } const handlers2 = nodeList.get(el2) const oldHandlerIndex = handlers2.findIndex( (item2) => item2.bindingFn === binding.oldValue ) const newHandler = { documentHandler: createDocumentHandler(el2, binding), bindingFn: binding.value, } if (oldHandlerIndex >= 0) { handlers2.splice(oldHandlerIndex, 1, newHandler) } else { handlers2.push(newHandler) } }, unmounted(el2) { nodeList.delete(el2) }, } var RepeatClick = { beforeMount(el2, binding) { let interval = null let startTime const handler = () => binding.value && binding.value() const clear2 = () => { if (Date.now() - startTime < 100) { handler() } clearInterval(interval) interval = null } on$2(el2, 'mousedown', (e2) => { if (e2.button !== 0) return startTime = Date.now() once$2(document, 'mouseup', clear2) clearInterval(interval) interval = setInterval(handler, 100) }) }, } const FOCUSABLE_CHILDREN = '_trap-focus-children' const FOCUS_STACK = [] const FOCUS_HANDLER = (e2) => { if (FOCUS_STACK.length === 0) return const focusableElement = FOCUS_STACK[FOCUS_STACK.length - 1][FOCUSABLE_CHILDREN] if (focusableElement.length > 0 && e2.code === EVENT_CODE.tab) { if (focusableElement.length === 1) { e2.preventDefault() if (document.activeElement !== focusableElement[0]) { focusableElement[0].focus() } return } const goingBackward = e2.shiftKey const isFirst = e2.target === focusableElement[0] const isLast = e2.target === focusableElement[focusableElement.length - 1] if (isFirst && goingBackward) { e2.preventDefault() focusableElement[focusableElement.length - 1].focus() } if (isLast && !goingBackward) { e2.preventDefault() focusableElement[0].focus() } } } const TrapFocus = { beforeMount(el2) { el2[FOCUSABLE_CHILDREN] = obtainAllFocusableElements$1(el2) FOCUS_STACK.push(el2) if (FOCUS_STACK.length <= 1) { on$2(document, 'keydown', FOCUS_HANDLER) } }, updated(el2) { nextTick(() => { el2[FOCUSABLE_CHILDREN] = obtainAllFocusableElements$1(el2) }) }, unmounted() { FOCUS_STACK.shift() if (FOCUS_STACK.length === 0) { off$1(document, 'keydown', FOCUS_HANDLER) } }, } var v$3 = false, o$2, f$3, s$2, u$3, d$1, N$2, l$2, p$2, m$4, w$1, D$1, x$2, E$2, M$1, F$2 function a$3() { if (!v$3) { v$3 = true var e2 = navigator.userAgent, n2 = /(?:MSIE.(\d+\.\d+))|(?:(?:Firefox|GranParadiso|Iceweasel).(\d+\.\d+))|(?:Opera(?:.+Version.|.)(\d+\.\d+))|(?:AppleWebKit.(\d+(?:\.\d+)?))|(?:Trident\/\d+\.\d+.*rv:(\d+\.\d+))/.exec( e2 ), i2 = /(Mac OS X)|(Windows)|(Linux)/.exec(e2) if ( ((x$2 = /\b(iPhone|iP[ao]d)/.exec(e2)), (E$2 = /\b(iP[ao]d)/.exec(e2)), (w$1 = /Android/i.exec(e2)), (M$1 = /FBAN\/\w+;/i.exec(e2)), (F$2 = /Mobile/i.exec(e2)), (D$1 = !!/Win64/.exec(e2)), n2) ) { ;(o$2 = n2[1] ? parseFloat(n2[1]) : n2[5] ? parseFloat(n2[5]) : NaN), o$2 && document && document.documentMode && (o$2 = document.documentMode) var r2 = /(?:Trident\/(\d+.\d+))/.exec(e2) ;(N$2 = r2 ? parseFloat(r2[1]) + 4 : o$2), (f$3 = n2[2] ? parseFloat(n2[2]) : NaN), (s$2 = n2[3] ? parseFloat(n2[3]) : NaN), (u$3 = n2[4] ? parseFloat(n2[4]) : NaN), u$3 ? ((n2 = /(?:Chrome\/(\d+\.\d+))/.exec(e2)), (d$1 = n2 && n2[1] ? parseFloat(n2[1]) : NaN)) : (d$1 = NaN) } else o$2 = f$3 = s$2 = d$1 = u$3 = NaN if (i2) { if (i2[1]) { var t3 = /(?:Mac OS X (\d+(?:[._]\d+)?))/.exec(e2) l$2 = t3 ? parseFloat(t3[1].replace('_', '.')) : true } else l$2 = false ;(p$2 = !!i2[2]), (m$4 = !!i2[3]) } else l$2 = p$2 = m$4 = false } } var _$3 = { ie: function () { return a$3() || o$2 }, ieCompatibilityMode: function () { return a$3() || N$2 > o$2 }, ie64: function () { return _$3.ie() && D$1 }, firefox: function () { return a$3() || f$3 }, opera: function () { return a$3() || s$2 }, webkit: function () { return a$3() || u$3 }, safari: function () { return _$3.webkit() }, chrome: function () { return a$3() || d$1 }, windows: function () { return a$3() || p$2 }, osx: function () { return a$3() || l$2 }, linux: function () { return a$3() || m$4 }, iphone: function () { return a$3() || x$2 }, mobile: function () { return a$3() || x$2 || E$2 || w$1 || F$2 }, nativeApp: function () { return a$3() || M$1 }, android: function () { return a$3() || w$1 }, ipad: function () { return a$3() || E$2 }, }, A$2 = _$3 var c$3 = !!( typeof window < 'u' && window.document && window.document.createElement ), U$2 = { canUseDOM: c$3, canUseWorkers: typeof Worker < 'u', canUseEventListeners: c$3 && !!(window.addEventListener || window.attachEvent), canUseViewport: c$3 && !!window.screen, isInWorker: !c$3, }, h$2 = U$2 var X$1 h$2.canUseDOM && (X$1 = document.implementation && document.implementation.hasFeature && document.implementation.hasFeature('', '') !== true) function S$1(e2, n2) { if (!h$2.canUseDOM || (n2 && !('addEventListener' in document))) return false var i2 = 'on' + e2, r2 = i2 in document if (!r2) { var t3 = document.createElement('div') t3.setAttribute(i2, 'return;'), (r2 = typeof t3[i2] == 'function') } return ( !r2 && X$1 && e2 === 'wheel' && (r2 = document.implementation.hasFeature('Events.wheel', '3.0')), r2 ) } var b$1 = S$1 var O$2 = 10, I$1 = 40, P$1 = 800 function T$3(e2) { var n2 = 0, i2 = 0, r2 = 0, t3 = 0 return ( 'detail' in e2 && (i2 = e2.detail), 'wheelDelta' in e2 && (i2 = -e2.wheelDelta / 120), 'wheelDeltaY' in e2 && (i2 = -e2.wheelDeltaY / 120), 'wheelDeltaX' in e2 && (n2 = -e2.wheelDeltaX / 120), 'axis' in e2 && e2.axis === e2.HORIZONTAL_AXIS && ((n2 = i2), (i2 = 0)), (r2 = n2 * O$2), (t3 = i2 * O$2), 'deltaY' in e2 && (t3 = e2.deltaY), 'deltaX' in e2 && (r2 = e2.deltaX), (r2 || t3) && e2.deltaMode && (e2.deltaMode == 1 ? ((r2 *= I$1), (t3 *= I$1)) : ((r2 *= P$1), (t3 *= P$1))), r2 && !n2 && (n2 = r2 < 1 ? -1 : 1), t3 && !i2 && (i2 = t3 < 1 ? -1 : 1), { spinX: n2, spinY: i2, pixelX: r2, pixelY: t3 } ) } T$3.getEventType = function () { return A$2.firefox() ? 'DOMMouseScroll' : b$1('wheel') ? 'wheel' : 'mousewheel' } var Y$1 = T$3 /** * Checks if an event is supported in the current execution environment. * * NOTE: This will not work correctly for non-generic events such as `change`, * `reset`, `load`, `error`, and `select`. * * Borrows from Modernizr. * * @param {string} eventNameSuffix Event name, e.g. "click". * @param {?boolean} capture Check if the capture phase is supported. * @return {boolean} True if the event is supported. * @internal * @license Modernizr 3.0.0pre (Custom Build) | MIT */ const mousewheel = function (element, callback) { if (element && element.addEventListener) { const fn2 = function (event) { const normalized = Y$1(event) callback && Reflect.apply(callback, this, [event, normalized]) } if (isFirefox()) { element.addEventListener('DOMMouseScroll', fn2) } else { element.onmousewheel = fn2 } } } const Mousewheel = { beforeMount(el2, binding) { mousewheel(el2, binding.value) }, } const Resize = { beforeMount(el2, binding) { el2._handleResize = () => { var _a2 el2 && ((_a2 = binding.value) == null ? void 0 : _a2.call(binding, el2)) } addResizeListener(el2, el2._handleResize) }, beforeUnmount(el2) { removeResizeListener(el2, el2._handleResize) }, } const makeList = (total2, method4, methodFunc) => { const arr = [] const disabledArr = method4 && methodFunc() for (let i2 = 0; i2 < total2; i2++) { arr[i2] = disabledArr ? disabledArr.includes(i2) : false } return arr } const makeAvailableArr = (list2) => { return list2 .map((_2, index2) => (!_2 ? index2 : _2)) .filter((_2) => _2 !== true) } const getTimeLists = (disabledHours, disabledMinutes, disabledSeconds) => { const getHoursList = (role, compare2) => { return makeList(24, disabledHours, () => disabledHours(role, compare2)) } const getMinutesList = (hour, role, compare2) => { return makeList(60, disabledMinutes, () => disabledMinutes(hour, role, compare2) ) } const getSecondsList = (hour, minute, role, compare2) => { return makeList(60, disabledSeconds, () => disabledSeconds(hour, minute, role, compare2) ) } return { getHoursList, getMinutesList, getSecondsList, } } const getAvailableArrs = (disabledHours, disabledMinutes, disabledSeconds) => { const { getHoursList, getMinutesList, getSecondsList } = getTimeLists( disabledHours, disabledMinutes, disabledSeconds ) const getAvailableHours = (role, compare2) => { return makeAvailableArr(getHoursList(role, compare2)) } const getAvailableMinutes = (hour, role, compare2) => { return makeAvailableArr(getMinutesList(hour, role, compare2)) } const getAvailableSeconds = (hour, minute, role, compare2) => { return makeAvailableArr(getSecondsList(hour, minute, role, compare2)) } return { getAvailableHours, getAvailableMinutes, getAvailableSeconds, } } const useOldValue = (props2) => { const oldValue = ref(props2.parsedValue) watch$1( () => props2.visible, (val2) => { if (!val2) { oldValue.value = props2.parsedValue } } ) return oldValue } const _sfc_main$8_ = defineComponent({ directives: { repeatClick: RepeatClick, }, components: { ElScrollbar, ElIcon, ArrowUp: arrowUp, ArrowDown: arrowDown, }, props: { role: { type: String, required: true, }, spinnerDate: { type: Object, required: true, }, showSeconds: { type: Boolean, default: true, }, arrowControl: Boolean, amPmMode: { type: String, default: '', }, disabledHours: { type: Function, }, disabledMinutes: { type: Function, }, disabledSeconds: { type: Function, }, }, emits: ['change', 'select-range', 'set-option'], setup(props2, ctx) { const ns = useNamespace('time') let isScrolling = false const debouncedResetScroll = debounce$3((type4) => { isScrolling = false adjustCurrentSpinner(type4) }, 200) const currentScrollbar = ref(null) const listHoursRef = ref(null) const listMinutesRef = ref(null) const listSecondsRef = ref(null) const listRefsMap = { hours: listHoursRef, minutes: listMinutesRef, seconds: listSecondsRef, } const spinnerItems = computed(() => { const arr = ['hours', 'minutes', 'seconds'] return props2.showSeconds ? arr : arr.slice(0, 2) }) const hours = computed(() => { return props2.spinnerDate.hour() }) const minutes = computed(() => { return props2.spinnerDate.minute() }) const seconds = computed(() => { return props2.spinnerDate.second() }) const timePartsMap = computed(() => ({ hours, minutes, seconds, })) const hoursList = computed(() => { return getHoursList(props2.role) }) const minutesList = computed(() => { return getMinutesList(hours.value, props2.role) }) const secondsList = computed(() => { return getSecondsList(hours.value, minutes.value, props2.role) }) const listMap = computed(() => ({ hours: hoursList, minutes: minutesList, seconds: secondsList, })) const arrowHourList = computed(() => { const hour = hours.value return [hour > 0 ? hour - 1 : void 0, hour, hour < 23 ? hour + 1 : void 0] }) const arrowMinuteList = computed(() => { const minute = minutes.value return [ minute > 0 ? minute - 1 : void 0, minute, minute < 59 ? minute + 1 : void 0, ] }) const arrowSecondList = computed(() => { const second = seconds.value return [ second > 0 ? second - 1 : void 0, second, second < 59 ? second + 1 : void 0, ] }) const arrowListMap = computed(() => ({ hours: arrowHourList, minutes: arrowMinuteList, seconds: arrowSecondList, })) const getAmPmFlag = (hour) => { const shouldShowAmPm = !!props2.amPmMode if (!shouldShowAmPm) return '' const isCapital = props2.amPmMode === 'A' let content2 = hour < 12 ? ' am' : ' pm' if (isCapital) content2 = content2.toUpperCase() return content2 } const emitSelectRange = (type4) => { if (type4 === 'hours') { ctx.emit('select-range', 0, 2) } else if (type4 === 'minutes') { ctx.emit('select-range', 3, 5) } else if (type4 === 'seconds') { ctx.emit('select-range', 6, 8) } currentScrollbar.value = type4 } const adjustCurrentSpinner = (type4) => { adjustSpinner(type4, timePartsMap.value[type4].value) } const adjustSpinners = () => { adjustCurrentSpinner('hours') adjustCurrentSpinner('minutes') adjustCurrentSpinner('seconds') } const getScrollbarElement = (el2) => el2.querySelector(`.${ns.namespace.value}-scrollbar__wrap`) const adjustSpinner = (type4, value2) => { if (props2.arrowControl) return const el2 = listRefsMap[type4] if (el2 && el2.$el) { getScrollbarElement(el2.$el).scrollTop = Math.max( 0, value2 * typeItemHeight(type4) ) } } const typeItemHeight = (type4) => { const el2 = listRefsMap[type4] return el2.$el.querySelector('li').offsetHeight } const onIncreaseClick = () => { scrollDown(1) } const onDecreaseClick = () => { scrollDown(-1) } const scrollDown = (step) => { if (!currentScrollbar.value) { emitSelectRange('hours') } const label = currentScrollbar.value let now2 = timePartsMap.value[label].value const total2 = currentScrollbar.value === 'hours' ? 24 : 60 now2 = (now2 + step + total2) % total2 modifyDateField(label, now2) adjustSpinner(label, now2) nextTick(() => emitSelectRange(currentScrollbar.value)) } const modifyDateField = (type4, value2) => { const list2 = listMap.value[type4].value const isDisabled = list2[value2] if (isDisabled) return switch (type4) { case 'hours': ctx.emit( 'change', props2.spinnerDate .hour(value2) .minute(minutes.value) .second(seconds.value) ) break case 'minutes': ctx.emit( 'change', props2.spinnerDate .hour(hours.value) .minute(value2) .second(seconds.value) ) break case 'seconds': ctx.emit( 'change', props2.spinnerDate .hour(hours.value) .minute(minutes.value) .second(value2) ) break } } const handleClick2 = (type4, { value: value2, disabled }) => { if (!disabled) { modifyDateField(type4, value2) emitSelectRange(type4) adjustSpinner(type4, value2) } } const handleScroll2 = (type4) => { isScrolling = true debouncedResetScroll(type4) const value2 = Math.min( Math.round( (getScrollbarElement(listRefsMap[type4].$el).scrollTop - (scrollBarHeight(type4) * 0.5 - 10) / typeItemHeight(type4) + 3) / typeItemHeight(type4) ), type4 === 'hours' ? 23 : 59 ) modifyDateField(type4, value2) } const scrollBarHeight = (type4) => { return listRefsMap[type4].$el.offsetHeight } const bindScrollEvent = () => { const bindFunction = (type4) => { if (listRefsMap[type4] && listRefsMap[type4].$el) { getScrollbarElement(listRefsMap[type4].$el).onscroll = () => { handleScroll2(type4) } } } bindFunction('hours') bindFunction('minutes') bindFunction('seconds') } onMounted(() => { nextTick(() => { !props2.arrowControl && bindScrollEvent() adjustSpinners() if (props2.role === 'start') emitSelectRange('hours') }) }) const setRef = (scrollbar, type4) => { listRefsMap[type4] = scrollbar } ctx.emit('set-option', [`${props2.role}_scrollDown`, scrollDown]) ctx.emit('set-option', [`${props2.role}_emitSelectRange`, emitSelectRange]) const { getHoursList, getMinutesList, getSecondsList } = getTimeLists( props2.disabledHours, props2.disabledMinutes, props2.disabledSeconds ) watch$1( () => props2.spinnerDate, () => { if (isScrolling) return adjustSpinners() } ) return { ns, setRef, spinnerItems, currentScrollbar, hours, minutes, seconds, hoursList, minutesList, arrowHourList, arrowMinuteList, arrowSecondList, getAmPmFlag, emitSelectRange, adjustCurrentSpinner, typeItemHeight, listHoursRef, listMinutesRef, listSecondsRef, onIncreaseClick, onDecreaseClick, handleClick: handleClick2, secondsList, timePartsMap, arrowListMap, listMap, } }, }) const _hoisted_1$6T = ['onClick'] const _hoisted_2$5x = ['onMouseenter'] function _sfc_render$1B(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_scrollbar = resolveComponent('el-scrollbar') const _component_arrow_up = resolveComponent('arrow-up') const _component_el_icon = resolveComponent('el-icon') const _component_arrow_down = resolveComponent('arrow-down') const _directive_repeat_click = resolveDirective('repeat-click') return ( openBlock(), createElementBlock( 'div', { class: normalizeClass([ _ctx.ns.b('spinner'), { 'has-seconds': _ctx.showSeconds }, ]), }, [ !_ctx.arrowControl ? (openBlock(true), createElementBlock( Fragment, { key: 0 }, renderList(_ctx.spinnerItems, (item2) => { return ( openBlock(), createBlock( _component_el_scrollbar, { key: item2, ref_for: true, ref: (scollbar) => _ctx.setRef(scollbar, item2), class: normalizeClass(_ctx.ns.be('spinner', 'wrapper')), 'wrap-style': 'max-height: inherit;', 'view-class': _ctx.ns.be('spinner', 'list'), noresize: '', tag: 'ul', onMouseenter: ($event) => _ctx.emitSelectRange(item2), onMousemove: ($event) => _ctx.adjustCurrentSpinner(item2), }, { default: withCtx(() => [ (openBlock(true), createElementBlock( Fragment, null, renderList( _ctx.listMap[item2].value, (disabled, key2) => { return ( openBlock(), createElementBlock( 'li', { key: key2, class: normalizeClass([ _ctx.ns.be('spinner', 'item'), _ctx.ns.is( 'active', key2 === _ctx.timePartsMap[item2].value ), _ctx.ns.is('disabled', disabled), ]), onClick: ($event) => _ctx.handleClick(item2, { value: key2, disabled, }), }, [ item2 === 'hours' ? (openBlock(), createElementBlock( Fragment, { key: 0 }, [ createTextVNode( toDisplayString$1( ( '0' + (_ctx.amPmMode ? key2 % 12 || 12 : key2) ).slice(-2) ) + toDisplayString$1( _ctx.getAmPmFlag(key2) ), 1 ), ], 2112 )) : (openBlock(), createElementBlock( Fragment, { key: 1 }, [ createTextVNode( toDisplayString$1( ('0' + key2).slice(-2) ), 1 ), ], 2112 )), ], 10, _hoisted_1$6T ) ) } ), 128 )), ]), _: 2, }, 1032, ['class', 'view-class', 'onMouseenter', 'onMousemove'] ) ) }), 128 )) : createCommentVNode('v-if', true), _ctx.arrowControl ? (openBlock(true), createElementBlock( Fragment, { key: 1 }, renderList(_ctx.spinnerItems, (item2) => { return ( openBlock(), createElementBlock( 'div', { key: item2, class: normalizeClass([ _ctx.ns.be('spinner', 'wrapper'), _ctx.ns.is('arrow'), ]), onMouseenter: ($event) => _ctx.emitSelectRange(item2), }, [ withDirectives( (openBlock(), createBlock( _component_el_icon, { class: normalizeClass([ 'arrow-up', _ctx.ns.be('spinner', 'arrow'), ]), }, { default: withCtx(() => [ createVNode$1(_component_arrow_up), ]), _: 1, }, 8, ['class'] )), [[_directive_repeat_click, _ctx.onDecreaseClick]] ), withDirectives( (openBlock(), createBlock( _component_el_icon, { class: normalizeClass([ 'arrow-down', _ctx.ns.be('spinner', 'arrow'), ]), }, { default: withCtx(() => [ createVNode$1(_component_arrow_down), ]), _: 1, }, 8, ['class'] )), [[_directive_repeat_click, _ctx.onIncreaseClick]] ), createElementVNode( 'ul', { class: normalizeClass(_ctx.ns.be('spinner', 'list')), }, [ (openBlock(true), createElementBlock( Fragment, null, renderList( _ctx.arrowListMap[item2].value, (time2, key2) => { return ( openBlock(), createElementBlock( 'li', { key: key2, class: normalizeClass([ _ctx.ns.be('spinner', 'item'), _ctx.ns.is( 'active', time2 === _ctx.timePartsMap[item2].value ), _ctx.ns.is( 'disabled', _ctx.listMap[item2].value[time2] ), ]), }, [ typeof time2 === 'number' ? (openBlock(), createElementBlock( Fragment, { key: 0 }, [ item2 === 'hours' ? (openBlock(), createElementBlock( Fragment, { key: 0 }, [ createTextVNode( toDisplayString$1( ( '0' + (_ctx.amPmMode ? time2 % 12 || 12 : time2) ).slice(-2) ) + toDisplayString$1( _ctx.getAmPmFlag( time2 ) ), 1 ), ], 2112 )) : (openBlock(), createElementBlock( Fragment, { key: 1 }, [ createTextVNode( toDisplayString$1( ('0' + time2).slice( -2 ) ), 1 ), ], 2112 )), ], 2112 )) : createCommentVNode('v-if', true), ], 2 ) ) } ), 128 )), ], 2 ), ], 42, _hoisted_2$5x ) ) }), 128 )) : createCommentVNode('v-if', true), ], 2 ) ) } var TimeSpinner = /* @__PURE__ */ _export_sfc$1(_sfc_main$8_, [ ['render', _sfc_render$1B], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/time-picker/src/time-picker-com/basic-time-spinner.vue', ], ]) const _sfc_main$8Z = defineComponent({ components: { TimeSpinner, }, props: { visible: Boolean, actualVisible: { type: Boolean, default: void 0, }, datetimeRole: { type: String, }, parsedValue: { type: [Object, String], }, format: { type: String, default: '', }, }, emits: ['pick', 'select-range', 'set-picker-option'], setup(props2, ctx) { const ns = useNamespace('time') const { t: t3, lang } = useLocale() const selectionRange = ref([0, 2]) const oldValue = useOldValue(props2) const transitionName = computed(() => { return isUndefined$c(props2.actualVisible) ? `${ns.namespace.value}-zoom-in-top` : '' }) const showSeconds = computed(() => { return props2.format.includes('ss') }) const amPmMode = computed(() => { if (props2.format.includes('A')) return 'A' if (props2.format.includes('a')) return 'a' return '' }) const isValidValue = (_date) => { const parsedDate = dayjs(_date).locale(lang.value) const result = getRangeAvailableTime(parsedDate) return parsedDate.isSame(result) } const handleCancel = () => { ctx.emit('pick', oldValue.value, false) } const handleConfirm = (visible = false, first2 = false) => { if (first2) return ctx.emit('pick', props2.parsedValue, visible) } const handleChange = (_date) => { if (!props2.visible) { return } const result = getRangeAvailableTime(_date).millisecond(0) ctx.emit('pick', result, true) } const setSelectionRange = (start2, end2) => { ctx.emit('select-range', start2, end2) selectionRange.value = [start2, end2] } const changeSelectionRange = (step) => { const list2 = [0, 3].concat(showSeconds.value ? [6] : []) const mapping = ['hours', 'minutes'].concat( showSeconds.value ? ['seconds'] : [] ) const index2 = list2.indexOf(selectionRange.value[0]) const next = (index2 + step + list2.length) % list2.length timePickerOptions['start_emitSelectRange'](mapping[next]) } const handleKeydown = (event) => { const code2 = event.code if (code2 === EVENT_CODE.left || code2 === EVENT_CODE.right) { const step = code2 === EVENT_CODE.left ? -1 : 1 changeSelectionRange(step) event.preventDefault() return } if (code2 === EVENT_CODE.up || code2 === EVENT_CODE.down) { const step = code2 === EVENT_CODE.up ? -1 : 1 timePickerOptions['start_scrollDown'](step) event.preventDefault() return } } const getRangeAvailableTime = (date4) => { const availableMap = { hour: getAvailableHours, minute: getAvailableMinutes, second: getAvailableSeconds, } let result = date4 ;['hour', 'minute', 'second'].forEach((_2) => { if (availableMap[_2]) { let availableArr const method4 = availableMap[_2] if (_2 === 'minute') { availableArr = method4(result.hour(), props2.datetimeRole) } else if (_2 === 'second') { availableArr = method4( result.hour(), result.minute(), props2.datetimeRole ) } else { availableArr = method4(props2.datetimeRole) } if ( availableArr && availableArr.length && !availableArr.includes(result[_2]()) ) { result = result[_2](availableArr[0]) } } }) return result } const parseUserInput = (value2) => { if (!value2) return null return dayjs(value2, props2.format).locale(lang.value) } const formatToString = (value2) => { if (!value2) return null return value2.format(props2.format) } const getDefaultValue = () => { return dayjs(defaultValue).locale(lang.value) } ctx.emit('set-picker-option', ['isValidValue', isValidValue]) ctx.emit('set-picker-option', ['formatToString', formatToString]) ctx.emit('set-picker-option', ['parseUserInput', parseUserInput]) ctx.emit('set-picker-option', ['handleKeydown', handleKeydown]) ctx.emit('set-picker-option', [ 'getRangeAvailableTime', getRangeAvailableTime, ]) ctx.emit('set-picker-option', ['getDefaultValue', getDefaultValue]) const timePickerOptions = {} const onSetOption = (e2) => { timePickerOptions[e2[0]] = e2[1] } const pickerBase = inject('EP_PICKER_BASE') const { arrowControl, disabledHours, disabledMinutes, disabledSeconds, defaultValue, } = pickerBase.props const { getAvailableHours, getAvailableMinutes, getAvailableSeconds } = getAvailableArrs(disabledHours, disabledMinutes, disabledSeconds) return { ns, transitionName, arrowControl, onSetOption, t: t3, handleConfirm, handleChange, setSelectionRange, amPmMode, showSeconds, handleCancel, disabledHours, disabledMinutes, disabledSeconds, } }, }) function _sfc_render$1A(_ctx, _cache, $props2, $setup, $data, $options) { const _component_time_spinner = resolveComponent('time-spinner') return ( openBlock(), createBlock( Transition, { name: _ctx.transitionName }, { default: withCtx(() => [ _ctx.actualVisible || _ctx.visible ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass(_ctx.ns.b('panel')), }, [ createElementVNode( 'div', { class: normalizeClass([ _ctx.ns.be('panel', 'content'), { 'has-seconds': _ctx.showSeconds }, ]), }, [ createVNode$1( _component_time_spinner, { ref: 'spinner', role: _ctx.datetimeRole || 'start', 'arrow-control': _ctx.arrowControl, 'show-seconds': _ctx.showSeconds, 'am-pm-mode': _ctx.amPmMode, 'spinner-date': _ctx.parsedValue, 'disabled-hours': _ctx.disabledHours, 'disabled-minutes': _ctx.disabledMinutes, 'disabled-seconds': _ctx.disabledSeconds, onChange: _ctx.handleChange, onSetOption: _ctx.onSetOption, onSelectRange: _ctx.setSelectionRange, }, null, 8, [ 'role', 'arrow-control', 'show-seconds', 'am-pm-mode', 'spinner-date', 'disabled-hours', 'disabled-minutes', 'disabled-seconds', 'onChange', 'onSetOption', 'onSelectRange', ] ), ], 2 ), createElementVNode( 'div', { class: normalizeClass(_ctx.ns.be('panel', 'footer')), }, [ createElementVNode( 'button', { type: 'button', class: normalizeClass([ _ctx.ns.be('panel', 'btn'), 'cancel', ]), onClick: _cache[0] || (_cache[0] = (...args) => _ctx.handleCancel && _ctx.handleCancel(...args)), }, toDisplayString$1(_ctx.t('el.datepicker.cancel')), 3 ), createElementVNode( 'button', { type: 'button', class: normalizeClass([ _ctx.ns.be('panel', 'btn'), 'confirm', ]), onClick: _cache[1] || (_cache[1] = ($event) => _ctx.handleConfirm()), }, toDisplayString$1(_ctx.t('el.datepicker.confirm')), 3 ), ], 2 ), ], 2 )) : createCommentVNode('v-if', true), ]), _: 1, }, 8, ['name'] ) ) } var TimePickPanel = /* @__PURE__ */ _export_sfc$1(_sfc_main$8Z, [ ['render', _sfc_render$1A], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/time-picker/src/time-picker-com/panel-time-pick.vue', ], ]) const makeSelectRange = (start2, end2) => { const result = [] for (let i2 = start2; i2 <= end2; i2++) { result.push(i2) } return result } const _sfc_main$8Y = defineComponent({ components: { TimeSpinner }, props: { visible: Boolean, actualVisible: Boolean, parsedValue: { type: [Array], }, format: { type: String, default: '', }, }, emits: ['pick', 'select-range', 'set-picker-option'], setup(props2, ctx) { const { t: t3, lang } = useLocale() const nsTime = useNamespace('time') const nsPicker = useNamespace('picker') const minDate = computed(() => props2.parsedValue[0]) const maxDate = computed(() => props2.parsedValue[1]) const oldValue = useOldValue(props2) const handleCancel = () => { ctx.emit('pick', oldValue.value, false) } const showSeconds = computed(() => { return props2.format.includes('ss') }) const amPmMode = computed(() => { if (props2.format.includes('A')) return 'A' if (props2.format.includes('a')) return 'a' return '' }) const minSelectableRange = ref([]) const maxSelectableRange = ref([]) const handleConfirm = (visible = false) => { ctx.emit('pick', [minDate.value, maxDate.value], visible) } const handleMinChange = (date4) => { handleChange(date4.millisecond(0), maxDate.value) } const handleMaxChange = (date4) => { handleChange(minDate.value, date4.millisecond(0)) } const isValidValue = (_date) => { const parsedDate = _date.map((_2) => dayjs(_2).locale(lang.value)) const result = getRangeAvailableTime(parsedDate) return parsedDate[0].isSame(result[0]) && parsedDate[1].isSame(result[1]) } const handleChange = (_minDate, _maxDate) => { ctx.emit('pick', [_minDate, _maxDate], true) } const btnConfirmDisabled = computed(() => { return minDate.value > maxDate.value }) const selectionRange = ref([0, 2]) const setMinSelectionRange = (start2, end2) => { ctx.emit('select-range', start2, end2, 'min') selectionRange.value = [start2, end2] } const offset2 = computed(() => (showSeconds.value ? 11 : 8)) const setMaxSelectionRange = (start2, end2) => { ctx.emit('select-range', start2, end2, 'max') selectionRange.value = [start2 + offset2.value, end2 + offset2.value] } const changeSelectionRange = (step) => { const list2 = showSeconds.value ? [0, 3, 6, 11, 14, 17] : [0, 3, 8, 11] const mapping = ['hours', 'minutes'].concat( showSeconds.value ? ['seconds'] : [] ) const index2 = list2.indexOf(selectionRange.value[0]) const next = (index2 + step + list2.length) % list2.length const half = list2.length / 2 if (next < half) { timePickerOptions['start_emitSelectRange'](mapping[next]) } else { timePickerOptions['end_emitSelectRange'](mapping[next - half]) } } const handleKeydown = (event) => { const code2 = event.code if (code2 === EVENT_CODE.left || code2 === EVENT_CODE.right) { const step = code2 === EVENT_CODE.left ? -1 : 1 changeSelectionRange(step) event.preventDefault() return } if (code2 === EVENT_CODE.up || code2 === EVENT_CODE.down) { const step = code2 === EVENT_CODE.up ? -1 : 1 const role = selectionRange.value[0] < offset2.value ? 'start' : 'end' timePickerOptions[`${role}_scrollDown`](step) event.preventDefault() return } } const disabledHours_ = (role, compare2) => { const defaultDisable = disabledHours ? disabledHours(role) : [] const isStart = role === 'start' const compareDate = compare2 || (isStart ? maxDate.value : minDate.value) const compareHour = compareDate.hour() const nextDisable = isStart ? makeSelectRange(compareHour + 1, 23) : makeSelectRange(0, compareHour - 1) return union$3(defaultDisable, nextDisable) } const disabledMinutes_ = (hour, role, compare2) => { const defaultDisable = disabledMinutes ? disabledMinutes(hour, role) : [] const isStart = role === 'start' const compareDate = compare2 || (isStart ? maxDate.value : minDate.value) const compareHour = compareDate.hour() if (hour !== compareHour) { return defaultDisable } const compareMinute = compareDate.minute() const nextDisable = isStart ? makeSelectRange(compareMinute + 1, 59) : makeSelectRange(0, compareMinute - 1) return union$3(defaultDisable, nextDisable) } const disabledSeconds_ = (hour, minute, role, compare2) => { const defaultDisable = disabledSeconds ? disabledSeconds(hour, minute, role) : [] const isStart = role === 'start' const compareDate = compare2 || (isStart ? maxDate.value : minDate.value) const compareHour = compareDate.hour() const compareMinute = compareDate.minute() if (hour !== compareHour || minute !== compareMinute) { return defaultDisable } const compareSecond = compareDate.second() const nextDisable = isStart ? makeSelectRange(compareSecond + 1, 59) : makeSelectRange(0, compareSecond - 1) return union$3(defaultDisable, nextDisable) } const getRangeAvailableTime = (dates) => { return dates.map((_2, index2) => getRangeAvailableTimeEach( dates[0], dates[1], index2 === 0 ? 'start' : 'end' ) ) } const { getAvailableHours, getAvailableMinutes, getAvailableSeconds } = getAvailableArrs(disabledHours_, disabledMinutes_, disabledSeconds_) const getRangeAvailableTimeEach = (startDate, endDate, role) => { const availableMap = { hour: getAvailableHours, minute: getAvailableMinutes, second: getAvailableSeconds, } const isStart = role === 'start' let result = isStart ? startDate : endDate const compareDate = isStart ? endDate : startDate ;['hour', 'minute', 'second'].forEach((_2) => { if (availableMap[_2]) { let availableArr const method4 = availableMap[_2] if (_2 === 'minute') { availableArr = method4(result.hour(), role, compareDate) } else if (_2 === 'second') { availableArr = method4( result.hour(), result.minute(), role, compareDate ) } else { availableArr = method4(role, compareDate) } if ( availableArr && availableArr.length && !availableArr.includes(result[_2]()) ) { const pos = isStart ? 0 : availableArr.length - 1 result = result[_2](availableArr[pos]) } } }) return result } const parseUserInput = (value2) => { if (!value2) return null if (Array.isArray(value2)) { return value2.map((_2) => dayjs(_2, props2.format).locale(lang.value)) } return dayjs(value2, props2.format).locale(lang.value) } const formatToString = (value2) => { if (!value2) return null if (Array.isArray(value2)) { return value2.map((_2) => _2.format(props2.format)) } return value2.format(props2.format) } const getDefaultValue = () => { if (Array.isArray(defaultValue)) { return defaultValue.map((_2) => dayjs(_2).locale(lang.value)) } const defaultDay = dayjs(defaultValue).locale(lang.value) return [defaultDay, defaultDay.add(60, 'm')] } ctx.emit('set-picker-option', ['formatToString', formatToString]) ctx.emit('set-picker-option', ['parseUserInput', parseUserInput]) ctx.emit('set-picker-option', ['isValidValue', isValidValue]) ctx.emit('set-picker-option', ['handleKeydown', handleKeydown]) ctx.emit('set-picker-option', ['getDefaultValue', getDefaultValue]) ctx.emit('set-picker-option', [ 'getRangeAvailableTime', getRangeAvailableTime, ]) const timePickerOptions = {} const onSetOption = (e2) => { timePickerOptions[e2[0]] = e2[1] } const pickerBase = inject('EP_PICKER_BASE') const { arrowControl, disabledHours, disabledMinutes, disabledSeconds, defaultValue, } = pickerBase.props return { nsTime, nsPicker, arrowControl, onSetOption, setMaxSelectionRange, setMinSelectionRange, btnConfirmDisabled, handleCancel, handleConfirm, t: t3, showSeconds, minDate, maxDate, amPmMode, handleMinChange, handleMaxChange, minSelectableRange, maxSelectableRange, disabledHours_, disabledMinutes_, disabledSeconds_, } }, }) const _hoisted_1$6S = ['disabled'] function _sfc_render$1z(_ctx, _cache, $props2, $setup, $data, $options) { const _component_time_spinner = resolveComponent('time-spinner') return _ctx.actualVisible ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass([ _ctx.nsTime.b('range-picker'), _ctx.nsPicker.b('panel'), ]), }, [ createElementVNode( 'div', { class: normalizeClass(_ctx.nsTime.be('range-picker', 'content')), }, [ createElementVNode( 'div', { class: normalizeClass(_ctx.nsTime.be('range-picker', 'cell')), }, [ createElementVNode( 'div', { class: normalizeClass( _ctx.nsTime.be('range-picker', 'header') ), }, toDisplayString$1(_ctx.t('el.datepicker.startTime')), 3 ), createElementVNode( 'div', { class: normalizeClass([ _ctx.nsTime.be('range-picker', 'body'), _ctx.nsTime.be('panel', 'content'), _ctx.nsTime.is('arrow', _ctx.arrowControl), { 'has-seconds': _ctx.showSeconds }, ]), }, [ createVNode$1( _component_time_spinner, { ref: 'minSpinner', role: 'start', 'show-seconds': _ctx.showSeconds, 'am-pm-mode': _ctx.amPmMode, 'arrow-control': _ctx.arrowControl, 'spinner-date': _ctx.minDate, 'disabled-hours': _ctx.disabledHours_, 'disabled-minutes': _ctx.disabledMinutes_, 'disabled-seconds': _ctx.disabledSeconds_, onChange: _ctx.handleMinChange, onSetOption: _ctx.onSetOption, onSelectRange: _ctx.setMinSelectionRange, }, null, 8, [ 'show-seconds', 'am-pm-mode', 'arrow-control', 'spinner-date', 'disabled-hours', 'disabled-minutes', 'disabled-seconds', 'onChange', 'onSetOption', 'onSelectRange', ] ), ], 2 ), ], 2 ), createElementVNode( 'div', { class: normalizeClass(_ctx.nsTime.be('range-picker', 'cell')), }, [ createElementVNode( 'div', { class: normalizeClass( _ctx.nsTime.be('range-picker', 'header') ), }, toDisplayString$1(_ctx.t('el.datepicker.endTime')), 3 ), createElementVNode( 'div', { class: normalizeClass([ _ctx.nsTime.be('range-picker', 'body'), _ctx.nsTime.be('panel', 'content'), _ctx.nsTime.is('arrow', _ctx.arrowControl), { 'has-seconds': _ctx.showSeconds }, ]), }, [ createVNode$1( _component_time_spinner, { ref: 'maxSpinner', role: 'end', 'show-seconds': _ctx.showSeconds, 'am-pm-mode': _ctx.amPmMode, 'arrow-control': _ctx.arrowControl, 'spinner-date': _ctx.maxDate, 'disabled-hours': _ctx.disabledHours_, 'disabled-minutes': _ctx.disabledMinutes_, 'disabled-seconds': _ctx.disabledSeconds_, onChange: _ctx.handleMaxChange, onSetOption: _ctx.onSetOption, onSelectRange: _ctx.setMaxSelectionRange, }, null, 8, [ 'show-seconds', 'am-pm-mode', 'arrow-control', 'spinner-date', 'disabled-hours', 'disabled-minutes', 'disabled-seconds', 'onChange', 'onSetOption', 'onSelectRange', ] ), ], 2 ), ], 2 ), ], 2 ), createElementVNode( 'div', { class: normalizeClass(_ctx.nsTime.be('panel', 'footer')), }, [ createElementVNode( 'button', { type: 'button', class: normalizeClass([ _ctx.nsTime.be('panel', 'btn'), 'cancel', ]), onClick: _cache[0] || (_cache[0] = ($event) => _ctx.handleCancel()), }, toDisplayString$1(_ctx.t('el.datepicker.cancel')), 3 ), createElementVNode( 'button', { type: 'button', class: normalizeClass([ _ctx.nsTime.be('panel', 'btn'), 'confirm', ]), disabled: _ctx.btnConfirmDisabled, onClick: _cache[1] || (_cache[1] = ($event) => _ctx.handleConfirm()), }, toDisplayString$1(_ctx.t('el.datepicker.confirm')), 11, _hoisted_1$6S ), ], 2 ), ], 2 )) : createCommentVNode('v-if', true) } var TimeRangePanel = /* @__PURE__ */ _export_sfc$1(_sfc_main$8Y, [ ['render', _sfc_render$1z], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/time-picker/src/time-picker-com/panel-time-range.vue', ], ]) dayjs.extend(customParseFormat) var TimePicker = defineComponent({ name: 'ElTimePicker', install: null, props: { ...timePickerDefaultProps, isRange: { type: Boolean, default: false, }, }, emits: ['update:modelValue'], setup(props2, ctx) { const commonPicker = ref(null) const type4 = props2.isRange ? 'timerange' : 'time' const panel = props2.isRange ? TimeRangePanel : TimePickPanel const refProps = { ...props2, focus: () => { var _a2 ;(_a2 = commonPicker.value) == null ? void 0 : _a2.handleFocus() }, blur: () => { var _a2 ;(_a2 = commonPicker.value) == null ? void 0 : _a2.handleBlur() }, } provide('ElPopperOptions', props2.popperOptions) ctx.expose(refProps) return () => { var _a2 const format2 = (_a2 = props2.format) != null ? _a2 : DEFAULT_FORMATS_TIME return h$4( CommonPicker, { ...props2, format: format2, type: type4, ref: commonPicker, 'onUpdate:modelValue': (value2) => ctx.emit('update:modelValue', value2), }, { default: (scopedProps) => h$4(panel, scopedProps), } ) } }, }) const rangeArr = (n2) => Array.from(Array.from({ length: n2 }).keys()) const extractDateFormat = (format2) => { return format2 .replace(/\W?m{1,2}|\W?ZZ/g, '') .replace(/\W?h{1,2}|\W?s{1,3}|\W?a/gi, '') .trim() } const extractTimeFormat = (format2) => { return format2 .replace(/\W?D{1,2}|\W?Do|\W?d{1,4}|\W?M{1,4}|\W?Y{2,4}/g, '') .trim() } const _TimePicker = TimePicker _TimePicker.install = (app2) => { app2.component(_TimePicker.name, _TimePicker) } const ElTimePicker = _TimePicker const getPrevMonthLastDays = (date4, count2) => { const lastDay = date4.subtract(1, 'month').endOf('month').date() return rangeArr(count2).map((_2, index2) => lastDay - (count2 - index2 - 1)) } const getMonthDays = (date4) => { const days = date4.daysInMonth() return rangeArr(days).map((_2, index2) => index2 + 1) } const toNestedArr = (days) => rangeArr(days.length / 7).map((index2) => { const start2 = index2 * 7 return days.slice(start2, start2 + 7) }) const dateTableProps = buildProps({ selectedDay: { type: definePropType(Object), }, range: { type: definePropType(Array), }, date: { type: definePropType(Object), required: true, }, hideHeader: { type: Boolean, }, }) const dateTableEmits = { pick: (value2) => isObject$v(value2), } const _hoisted_1$6R = { key: 0 } const _hoisted_2$5w = ['onClick'] const __default__$z = { name: 'DateTable', } const _sfc_main$8X = /* @__PURE__ */ defineComponent({ ...__default__$z, props: dateTableProps, emits: dateTableEmits, setup(__props2, { expose, emit: emit2 }) { const props2 = __props2 dayjs.extend(localeData) const { t: t3, lang } = useLocale() const nsTable = useNamespace('calendar-table') const nsDay = useNamespace('calendar-day') const now2 = dayjs().locale(lang.value) const firstDayOfWeek = now2.$locale().weekStart || 0 const isInRange = computed(() => !!props2.range && !!props2.range.length) const rows = computed(() => { let days = [] if (isInRange.value) { const [start2, end2] = props2.range const currentMonthRange = rangeArr(end2.date() - start2.date() + 1).map( (index2) => ({ text: start2.date() + index2, type: 'current', }) ) let remaining = currentMonthRange.length % 7 remaining = remaining === 0 ? 0 : 7 - remaining const nextMonthRange = rangeArr(remaining).map((_2, index2) => ({ text: index2 + 1, type: 'next', })) days = currentMonthRange.concat(nextMonthRange) } else { const firstDay = props2.date.startOf('month').day() || 7 const prevMonthDays = getPrevMonthLastDays( props2.date, firstDay - firstDayOfWeek ).map((day) => ({ text: day, type: 'prev', })) const currentMonthDays = getMonthDays(props2.date).map((day) => ({ text: day, type: 'current', })) days = [...prevMonthDays, ...currentMonthDays] const nextMonthDays = rangeArr(42 - days.length).map((_2, index2) => ({ text: index2 + 1, type: 'next', })) days = days.concat(nextMonthDays) } return toNestedArr(days) }) const weekDays = computed(() => { const start2 = firstDayOfWeek if (start2 === 0) { return WEEK_DAYS.map((_2) => t3(`el.datepicker.weeks.${_2}`)) } else { return WEEK_DAYS.slice(start2) .concat(WEEK_DAYS.slice(0, start2)) .map((_2) => t3(`el.datepicker.weeks.${_2}`)) } }) const getFormattedDate = (day, type4) => { switch (type4) { case 'prev': return props2.date.startOf('month').subtract(1, 'month').date(day) case 'next': return props2.date.startOf('month').add(1, 'month').date(day) case 'current': return props2.date.date(day) } } const getCellClass = ({ text: text2, type: type4 }) => { const classes = [type4] if (type4 === 'current') { const date4 = getFormattedDate(text2, type4) if (date4.isSame(props2.selectedDay, 'day')) { classes.push(nsDay.is('selected')) } if (date4.isSame(now2, 'day')) { classes.push(nsDay.is('today')) } } return classes } const handlePickDay = ({ text: text2, type: type4 }) => { const date4 = getFormattedDate(text2, type4) emit2('pick', date4) } const getSlotData = ({ text: text2, type: type4 }) => { const day = getFormattedDate(text2, type4) return { isSelected: day.isSame(props2.selectedDay), type: `${type4}-month`, day: day.format('YYYY-MM-DD'), date: day.toDate(), } } expose({ getFormattedDate, }) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'table', { class: normalizeClass([ unref(nsTable).b(), unref(nsTable).is('range', unref(isInRange)), ]), cellspacing: '0', cellpadding: '0', }, [ !_ctx.hideHeader ? (openBlock(), createElementBlock('thead', _hoisted_1$6R, [ (openBlock(true), createElementBlock( Fragment, null, renderList(unref(weekDays), (day) => { return ( openBlock(), createElementBlock( 'th', { key: day }, toDisplayString$1(day), 1 ) ) }), 128 )), ])) : createCommentVNode('v-if', true), createElementVNode('tbody', null, [ (openBlock(true), createElementBlock( Fragment, null, renderList(unref(rows), (row, index2) => { return ( openBlock(), createElementBlock( 'tr', { key: index2, class: normalizeClass({ [unref(nsTable).e('row')]: true, [unref(nsTable).em('row', 'hide-border')]: index2 === 0 && _ctx.hideHeader, }), }, [ (openBlock(true), createElementBlock( Fragment, null, renderList(row, (cell, key2) => { return ( openBlock(), createElementBlock( 'td', { key: key2, class: normalizeClass(getCellClass(cell)), onClick: ($event) => handlePickDay(cell), }, [ createElementVNode( 'div', { class: normalizeClass(unref(nsDay).b()), }, [ renderSlot( _ctx.$slots, 'dateCell', { data: getSlotData(cell), }, () => [ createElementVNode( 'span', null, toDisplayString$1(cell.text), 1 ), ] ), ], 2 ), ], 10, _hoisted_2$5w ) ) }), 128 )), ], 2 ) ) }), 128 )), ]), ], 2 ) ) } }, }) var DateTable$1 = /* @__PURE__ */ _export_sfc$1(_sfc_main$8X, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/calendar/src/date-table.vue', ], ]) const calendarProps = buildProps({ modelValue: { type: Date, }, range: { type: definePropType(Array), validator: (range3) => Array.isArray(range3) && range3.length === 2 && range3.every((item2) => item2 instanceof Date), }, }) const calendarEmits = { [UPDATE_MODEL_EVENT]: (value2) => value2 instanceof Date, input: (value2) => value2 instanceof Date, } const __default__$y = { name: 'ElCalendar', } const _sfc_main$8W = /* @__PURE__ */ defineComponent({ ...__default__$y, props: calendarProps, emits: calendarEmits, setup(__props2, { expose, emit: emit2 }) { const props2 = __props2 const ns = useNamespace('calendar') const { t: t3, lang } = useLocale() const selectedDay = ref() const now2 = dayjs().locale(lang.value) const prevMonthDayjs = computed(() => { return date4.value.subtract(1, 'month').date(1) }) const nextMonthDayjs = computed(() => { return date4.value.add(1, 'month').date(1) }) const prevYearDayjs = computed(() => { return date4.value.subtract(1, 'year').date(1) }) const nextYearDayjs = computed(() => { return date4.value.add(1, 'year').date(1) }) const i18nDate = computed(() => { const pickedMonth = `el.datepicker.month${date4.value.format('M')}` return `${date4.value.year()} ${t3('el.datepicker.year')} ${t3( pickedMonth )}` }) const realSelectedDay = computed({ get() { if (!props2.modelValue) return selectedDay.value return date4.value }, set(val2) { if (!val2) return selectedDay.value = val2 const result = val2.toDate() emit2('input', result) emit2('update:modelValue', result) }, }) const date4 = computed(() => { if (!props2.modelValue) { if (realSelectedDay.value) { return realSelectedDay.value } else if (validatedRange.value.length) { return validatedRange.value[0][0] } return now2 } else { return dayjs(props2.modelValue).locale(lang.value) } }) const calculateValidatedDateRange = (startDayjs, endDayjs) => { const firstDay = startDayjs.startOf('week') const lastDay = endDayjs.endOf('week') const firstMonth = firstDay.get('month') const lastMonth = lastDay.get('month') if (firstMonth === lastMonth) { return [[firstDay, lastDay]] } else if (firstMonth + 1 === lastMonth) { const firstMonthLastDay = firstDay.endOf('month') const lastMonthFirstDay = lastDay.startOf('month') const isSameWeek = firstMonthLastDay.isSame(lastMonthFirstDay, 'week') const lastMonthStartDay = isSameWeek ? lastMonthFirstDay.add(1, 'week') : lastMonthFirstDay return [ [firstDay, firstMonthLastDay], [lastMonthStartDay.startOf('week'), lastDay], ] } else if (firstMonth + 2 === lastMonth) { const firstMonthLastDay = firstDay.endOf('month') const secondMonthFirstDay = firstDay.add(1, 'month').startOf('month') const secondMonthStartDay = firstMonthLastDay.isSame( secondMonthFirstDay, 'week' ) ? secondMonthFirstDay.add(1, 'week') : secondMonthFirstDay const secondMonthLastDay = secondMonthStartDay.endOf('month') const lastMonthFirstDay = lastDay.startOf('month') const lastMonthStartDay = secondMonthLastDay.isSame( lastMonthFirstDay, 'week' ) ? lastMonthFirstDay.add(1, 'week') : lastMonthFirstDay return [ [firstDay, firstMonthLastDay], [secondMonthStartDay.startOf('week'), secondMonthLastDay], [lastMonthStartDay.startOf('week'), lastDay], ] } else { return [] } } const validatedRange = computed(() => { if (!props2.range) return [] const rangeArrDayjs = props2.range.map((_2) => dayjs(_2).locale(lang.value) ) const [startDayjs, endDayjs] = rangeArrDayjs if (startDayjs.isAfter(endDayjs)) { return [] } if (startDayjs.isSame(endDayjs, 'month')) { return calculateValidatedDateRange(startDayjs, endDayjs) } else { if (startDayjs.add(1, 'month').month() !== endDayjs.month()) { return [] } return calculateValidatedDateRange(startDayjs, endDayjs) } }) const pickDay = (day) => { realSelectedDay.value = day } const selectDate = (type4) => { let day if (type4 === 'prev-month') { day = prevMonthDayjs.value } else if (type4 === 'next-month') { day = nextMonthDayjs.value } else if (type4 === 'prev-year') { day = prevYearDayjs.value } else if (type4 === 'next-year') { day = nextYearDayjs.value } else { day = now2 } if (day.isSame(date4.value, 'day')) return pickDay(day) } expose({ selectedDay: realSelectedDay, pickDay, selectDate, calculateValidatedDateRange, }) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { class: normalizeClass(unref(ns).b()), }, [ createElementVNode( 'div', { class: normalizeClass(unref(ns).e('header')), }, [ renderSlot( _ctx.$slots, 'header', { date: unref(i18nDate) }, () => [ createElementVNode( 'div', { class: normalizeClass(unref(ns).e('title')), }, toDisplayString$1(unref(i18nDate)), 3 ), unref(validatedRange).length === 0 ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass(unref(ns).e('button-group')), }, [ createVNode$1(unref(ElButtonGroup$1), null, { default: withCtx(() => [ createVNode$1( unref(ElButton), { size: 'small', onClick: _cache[0] || (_cache[0] = ($event) => selectDate('prev-month')), }, { default: withCtx(() => [ createTextVNode( toDisplayString$1( unref(t3)('el.datepicker.prevMonth') ), 1 ), ]), _: 1, } ), createVNode$1( unref(ElButton), { size: 'small', onClick: _cache[1] || (_cache[1] = ($event) => selectDate('today')), }, { default: withCtx(() => [ createTextVNode( toDisplayString$1( unref(t3)('el.datepicker.today') ), 1 ), ]), _: 1, } ), createVNode$1( unref(ElButton), { size: 'small', onClick: _cache[2] || (_cache[2] = ($event) => selectDate('next-month')), }, { default: withCtx(() => [ createTextVNode( toDisplayString$1( unref(t3)('el.datepicker.nextMonth') ), 1 ), ]), _: 1, } ), ]), _: 1, }), ], 2 )) : createCommentVNode('v-if', true), ] ), ], 2 ), unref(validatedRange).length === 0 ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass(unref(ns).e('body')), }, [ createVNode$1( DateTable$1, { date: unref(date4), 'selected-day': unref(realSelectedDay), onPick: pickDay, }, createSlots({ _: 2 }, [ _ctx.$slots.dateCell ? { name: 'dateCell', fn: withCtx((data2) => [ renderSlot( _ctx.$slots, 'dateCell', normalizeProps(guardReactiveProps(data2)) ), ]), } : void 0, ]), 1032, ['date', 'selected-day'] ), ], 2 )) : (openBlock(), createElementBlock( 'div', { key: 1, class: normalizeClass(unref(ns).e('body')), }, [ (openBlock(true), createElementBlock( Fragment, null, renderList(unref(validatedRange), (range_, index2) => { return ( openBlock(), createBlock( DateTable$1, { key: index2, date: range_[0], 'selected-day': unref(realSelectedDay), range: range_, 'hide-header': index2 !== 0, onPick: pickDay, }, createSlots({ _: 2 }, [ _ctx.$slots.dateCell ? { name: 'dateCell', fn: withCtx((data2) => [ renderSlot( _ctx.$slots, 'dateCell', normalizeProps( guardReactiveProps(data2) ) ), ]), } : void 0, ]), 1032, ['date', 'selected-day', 'range', 'hide-header'] ) ) }), 128 )), ], 2 )), ], 2 ) ) } }, }) var Calendar$2 = /* @__PURE__ */ _export_sfc$1(_sfc_main$8W, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/calendar/src/calendar.vue', ], ]) const ElCalendar = withInstall(Calendar$2) const cardProps = buildProps({ header: { type: String, default: '', }, bodyStyle: { type: definePropType([String, Object, Array]), default: '', }, shadow: { type: String, default: 'always', }, }) const __default__$x = { name: 'ElCard', } const _sfc_main$8V = /* @__PURE__ */ defineComponent({ ...__default__$x, props: cardProps, setup(__props2) { const ns = useNamespace('card') return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { class: normalizeClass([ unref(ns).b(), unref(ns).is(`${_ctx.shadow}-shadow`), ]), }, [ _ctx.$slots.header || _ctx.header ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass(unref(ns).e('header')), }, [ renderSlot(_ctx.$slots, 'header', {}, () => [ createTextVNode(toDisplayString$1(_ctx.header), 1), ]), ], 2 )) : createCommentVNode('v-if', true), createElementVNode( 'div', { class: normalizeClass(unref(ns).e('body')), style: normalizeStyle$1(_ctx.bodyStyle), }, [renderSlot(_ctx.$slots, 'default')], 6 ), ], 2 ) ) } }, }) var Card = /* @__PURE__ */ _export_sfc$1(_sfc_main$8V, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/card/src/card.vue', ], ]) const ElCard = withInstall(Card) const carouselProps = buildProps({ initialIndex: { type: Number, default: 0, }, height: { type: String, default: '' }, trigger: { type: String, default: 'hover', }, autoplay: { type: Boolean, default: true, }, interval: { type: Number, default: 3e3, }, indicatorPosition: { type: String, default: '' }, indicator: { type: Boolean, default: true, }, arrow: { type: String, default: 'hover', }, type: { type: String, default: '' }, loop: { type: Boolean, default: true, }, direction: { type: String, default: 'horizontal', validator(val2) { return ['horizontal', 'vertical'].includes(val2) }, }, pauseOnHover: { type: Boolean, default: true, }, }) const carouselEmits = { change: (current2, prev) => [current2, prev].every(isNumber$h), } const _hoisted_1$6Q = ['onMouseenter', 'onMouseleave'] const _hoisted_2$5v = ['onMouseenter', 'onClick'] const _hoisted_3$4Q = { key: 0 } const __default__$w = { name: 'ElCarousel', } const _sfc_main$8U = /* @__PURE__ */ defineComponent({ ...__default__$w, props: carouselProps, emits: carouselEmits, setup(__props2, { expose, emit: emit2 }) { const props2 = __props2 const ns = useNamespace('carousel') const THROTTLE_TIME = 300 const activeIndex = ref(-1) const timer2 = ref(null) const hover = ref(false) const root2 = ref() const items = ref([]) const arrowDisplay = computed( () => props2.arrow !== 'never' && !unref(isVertical) ) const hasLabel = computed(() => { return items.value.some( (item2) => item2.props.label.toString().length > 0 ) }) const carouselClasses = computed(() => { const classes = [ns.b(), ns.m(props2.direction)] if (unref(isCardType)) { classes.push(ns.m('card')) } return classes }) const indicatorsClasses = computed(() => { const classes = [ ns.e('indicators'), ns.em('indicators', props2.direction), ] if (hasLabel.value) { classes.push(ns.em('indicators', 'labels')) } if (props2.indicatorPosition === 'outside' || unref(isCardType)) { classes.push(ns.em('indicators', 'outside')) } return classes }) const isCardType = computed(() => props2.type === 'card') const isVertical = computed(() => props2.direction === 'vertical') const throttledArrowClick = throttle$4( (index2) => { setActiveItem(index2) }, THROTTLE_TIME, { trailing: true } ) const throttledIndicatorHover = throttle$4((index2) => { handleIndicatorHover(index2) }, THROTTLE_TIME) function pauseTimer() { if (timer2.value) { clearInterval(timer2.value) timer2.value = null } } function startTimer2() { if (props2.interval <= 0 || !props2.autoplay || timer2.value) return timer2.value = setInterval(() => playSlides(), props2.interval) } const playSlides = () => { if (activeIndex.value < items.value.length - 1) { activeIndex.value = activeIndex.value + 1 } else if (props2.loop) { activeIndex.value = 0 } } function setActiveItem(index2) { if (isString$f(index2)) { const filteredItems = items.value.filter( (item2) => item2.props.name === index2 ) if (filteredItems.length > 0) { index2 = items.value.indexOf(filteredItems[0]) } } index2 = Number(index2) if (Number.isNaN(index2) || index2 !== Math.floor(index2)) { return } const itemCount = items.value.length const oldIndex2 = activeIndex.value if (index2 < 0) { activeIndex.value = props2.loop ? itemCount - 1 : 0 } else if (index2 >= itemCount) { activeIndex.value = props2.loop ? 0 : itemCount - 1 } else { activeIndex.value = index2 } if (oldIndex2 === activeIndex.value) { resetItemPosition(oldIndex2) } } function resetItemPosition(oldIndex2) { items.value.forEach((item2, index2) => { item2.translateItem(index2, activeIndex.value, oldIndex2) }) } function addItem(item2) { items.value.push(item2) } function removeItem(uid2) { const index2 = items.value.findIndex((item2) => item2.uid === uid2) if (index2 !== -1) { items.value.splice(index2, 1) if (activeIndex.value === index2) next() } } function itemInStage(item2, index2) { var _a2, _b2, _c2, _d const _items = unref(items) const itemCount = _items.length if (itemCount === 0 || !item2.states.inStage) return false const nextItemIndex = index2 + 1 const prevItemIndex = index2 - 1 const lastItemIndex = itemCount - 1 const isLastItemActive = _items[lastItemIndex].states.active const isFirstItemActive = _items[0].states.active const isNextItemActive = (_b2 = (_a2 = _items[nextItemIndex]) == null ? void 0 : _a2.states) == null ? void 0 : _b2.active const isPrevItemActive = (_d = (_c2 = _items[prevItemIndex]) == null ? void 0 : _c2.states) == null ? void 0 : _d.active if ((index2 === lastItemIndex && isFirstItemActive) || isNextItemActive) { return 'left' } else if ((index2 === 0 && isLastItemActive) || isPrevItemActive) { return 'right' } return false } function handleMouseEnter() { hover.value = true if (props2.pauseOnHover) { pauseTimer() } } function handleMouseLeave() { hover.value = false startTimer2() } function handleButtonEnter(arrow2) { if (unref(isVertical)) return items.value.forEach((item2, index2) => { if (arrow2 === itemInStage(item2, index2)) { item2.states.hover = true } }) } function handleButtonLeave() { if (unref(isVertical)) return items.value.forEach((item2) => { item2.states.hover = false }) } function handleIndicatorClick(index2) { activeIndex.value = index2 } function handleIndicatorHover(index2) { if (props2.trigger === 'hover' && index2 !== activeIndex.value) { activeIndex.value = index2 } } function prev() { setActiveItem(activeIndex.value - 1) } function next() { setActiveItem(activeIndex.value + 1) } watch$1( () => activeIndex.value, (current2, prev2) => { resetItemPosition(prev2) if (prev2 > -1) { emit2('change', current2, prev2) } } ) watch$1( () => props2.autoplay, (autoplay) => { autoplay ? startTimer2() : pauseTimer() } ) watch$1( () => props2.loop, () => { setActiveItem(activeIndex.value) } ) const resizeObserver = shallowRef() onMounted(async () => { await nextTick() resizeObserver.value = useResizeObserver$1(root2.value, () => { resetItemPosition() }) if ( props2.initialIndex < items.value.length && props2.initialIndex >= 0 ) { activeIndex.value = props2.initialIndex } startTimer2() }) onBeforeUnmount(() => { pauseTimer() if (root2.value && resizeObserver.value) resizeObserver.value.stop() }) provide(carouselContextKey, { root: root2, isCardType, isVertical, items, loop: props2.loop, addItem, removeItem, setActiveItem, }) expose({ setActiveItem, prev, next, }) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { ref_key: 'root', ref: root2, class: normalizeClass(unref(carouselClasses)), onMouseenter: withModifiers(handleMouseEnter, ['stop']), onMouseleave: withModifiers(handleMouseLeave, ['stop']), }, [ createElementVNode( 'div', { class: normalizeClass(unref(ns).e('container')), style: normalizeStyle$1({ height: _ctx.height }), }, [ unref(arrowDisplay) ? (openBlock(), createBlock( Transition, { key: 0, name: 'carousel-arrow-left', }, { default: withCtx(() => [ withDirectives( createElementVNode( 'button', { type: 'button', class: normalizeClass([ unref(ns).e('arrow'), unref(ns).em('arrow', 'left'), ]), onMouseenter: _cache[0] || (_cache[0] = ($event) => handleButtonEnter('left')), onMouseleave: handleButtonLeave, onClick: _cache[1] || (_cache[1] = withModifiers( ($event) => unref(throttledArrowClick)( activeIndex.value - 1 ), ['stop'] )), }, [ createVNode$1(unref(ElIcon), null, { default: withCtx(() => [ createVNode$1(unref(arrowLeft)), ]), _: 1, }), ], 34 ), [ [ vShow, (_ctx.arrow === 'always' || hover.value) && (props2.loop || activeIndex.value > 0), ], ] ), ]), _: 1, } )) : createCommentVNode('v-if', true), unref(arrowDisplay) ? (openBlock(), createBlock( Transition, { key: 1, name: 'carousel-arrow-right', }, { default: withCtx(() => [ withDirectives( createElementVNode( 'button', { type: 'button', class: normalizeClass([ unref(ns).e('arrow'), unref(ns).em('arrow', 'right'), ]), onMouseenter: _cache[2] || (_cache[2] = ($event) => handleButtonEnter('right')), onMouseleave: handleButtonLeave, onClick: _cache[3] || (_cache[3] = withModifiers( ($event) => unref(throttledArrowClick)( activeIndex.value + 1 ), ['stop'] )), }, [ createVNode$1(unref(ElIcon), null, { default: withCtx(() => [ createVNode$1(unref(arrowRight)), ]), _: 1, }), ], 34 ), [ [ vShow, (_ctx.arrow === 'always' || hover.value) && (props2.loop || activeIndex.value < items.value.length - 1), ], ] ), ]), _: 1, } )) : createCommentVNode('v-if', true), renderSlot(_ctx.$slots, 'default'), ], 6 ), _ctx.indicatorPosition !== 'none' ? (openBlock(), createElementBlock( 'ul', { key: 0, class: normalizeClass(unref(indicatorsClasses)), }, [ (openBlock(true), createElementBlock( Fragment, null, renderList(items.value, (item2, index2) => { return ( openBlock(), createElementBlock( 'li', { key: index2, class: normalizeClass([ unref(ns).e('indicator'), unref(ns).em('indicator', _ctx.direction), unref(ns).is( 'active', index2 === activeIndex.value ), ]), onMouseenter: ($event) => unref(throttledIndicatorHover)(index2), onClick: withModifiers( ($event) => handleIndicatorClick(index2), ['stop'] ), }, [ createElementVNode( 'button', { class: normalizeClass(unref(ns).e('button')), }, [ unref(hasLabel) ? (openBlock(), createElementBlock( 'span', _hoisted_3$4Q, toDisplayString$1(item2.props.label), 1 )) : createCommentVNode('v-if', true), ], 2 ), ], 42, _hoisted_2$5v ) ) }), 128 )), ], 2 )) : createCommentVNode('v-if', true), ], 42, _hoisted_1$6Q ) ) } }, }) var Carousel = /* @__PURE__ */ _export_sfc$1(_sfc_main$8U, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/carousel/src/carousel.vue', ], ]) const carouselItemProps = buildProps({ name: { type: String, default: '' }, label: { type: [String, Number], default: '', }, }) const __default__$v = { name: 'ElCarouselItem', } const _sfc_main$8T = /* @__PURE__ */ defineComponent({ ...__default__$v, props: carouselItemProps, setup(__props2) { const props2 = __props2 const ns = useNamespace('carousel') const carouselContext = inject(carouselContextKey) const instance = getCurrentInstance() const CARD_SCALE = 0.83 const hover = ref(false) const translate2 = ref(0) const scale2 = ref(1) const active = ref(false) const ready = ref(false) const inStage = ref(false) const animating = ref(false) const { isCardType, isVertical } = carouselContext const itemStyle = computed(() => { const translateType = `translate${unref(isVertical) ? 'Y' : 'X'}` const _translate = `${translateType}(${unref(translate2)}px)` const _scale = `scale(${unref(scale2)})` const transform3 = [_translate, _scale].join(' ') return { transform: transform3, } }) function processIndex(index2, activeIndex, length2) { const lastItemIndex = length2 - 1 const prevItemIndex = activeIndex - 1 const nextItemIndex = activeIndex + 1 const halfItemIndex = length2 / 2 if (activeIndex === 0 && index2 === lastItemIndex) { return -1 } else if (activeIndex === lastItemIndex && index2 === 0) { return length2 } else if ( index2 < prevItemIndex && activeIndex - index2 >= halfItemIndex ) { return length2 + 1 } else if ( index2 > nextItemIndex && index2 - activeIndex >= halfItemIndex ) { return -2 } return index2 } function calcCardTranslate(index2, activeIndex) { var _a2 const parentWidth = ((_a2 = carouselContext.root.value) == null ? void 0 : _a2.offsetWidth) || 0 if (inStage.value) { return ( (parentWidth * ((2 - CARD_SCALE) * (index2 - activeIndex) + 1)) / 4 ) } else if (index2 < activeIndex) { return (-(1 + CARD_SCALE) * parentWidth) / 4 } else { return ((3 + CARD_SCALE) * parentWidth) / 4 } } function calcTranslate(index2, activeIndex, isVertical2) { const rootEl2 = carouselContext.root.value if (!rootEl2) return 0 const distance2 = (isVertical2 ? rootEl2.offsetHeight : rootEl2.offsetWidth) || 0 return distance2 * (index2 - activeIndex) } const translateItem = (index2, activeIndex, oldIndex2) => { var _a2 const _isCardType = unref(isCardType) const carouselItemLength = (_a2 = carouselContext.items.value.length) != null ? _a2 : Number.NaN const isActive = index2 === activeIndex if (!_isCardType && !isUndefined$c(oldIndex2)) { animating.value = isActive || index2 === oldIndex2 } if (!isActive && carouselItemLength > 2 && carouselContext.loop) { index2 = processIndex(index2, activeIndex, carouselItemLength) } const _isVertical = unref(isVertical) active.value = isActive if (_isCardType) { inStage.value = Math.round(Math.abs(index2 - activeIndex)) <= 1 translate2.value = calcCardTranslate(index2, activeIndex) scale2.value = unref(active) ? 1 : CARD_SCALE } else { translate2.value = calcTranslate(index2, activeIndex, _isVertical) } ready.value = true } function handleItemClick() { if (carouselContext && unref(isCardType)) { const index2 = carouselContext.items.value.findIndex( ({ uid: uid2 }) => uid2 === instance.uid ) carouselContext.setActiveItem(index2) } } onMounted(() => { carouselContext.addItem({ props: props2, states: reactive({ hover, translate: translate2, scale: scale2, active, ready, inStage, animating, }), uid: instance.uid, translateItem, }) }) onUnmounted(() => { carouselContext.removeItem(instance.uid) }) return (_ctx, _cache) => { return withDirectives( (openBlock(), createElementBlock( 'div', { class: normalizeClass([ unref(ns).e('item'), unref(ns).is('active', active.value), unref(ns).is('in-stage', inStage.value), unref(ns).is('hover', hover.value), unref(ns).is('animating', animating.value), { [unref(ns).em('item', 'card')]: unref(isCardType) }, ]), style: normalizeStyle$1(unref(itemStyle)), onClick: handleItemClick, }, [ unref(isCardType) ? withDirectives( (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass(unref(ns).e('mask')), }, null, 2 )), [[vShow, !active.value]] ) : createCommentVNode('v-if', true), renderSlot(_ctx.$slots, 'default'), ], 6 )), [[vShow, ready.value]] ) } }, }) var CarouselItem = /* @__PURE__ */ _export_sfc$1(_sfc_main$8T, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/carousel/src/carousel-item.vue', ], ]) const ElCarousel = withInstall(Carousel, { CarouselItem, }) const ElCarouselItem = withNoopInstall(CarouselItem) const useCheckboxProps = { modelValue: { type: [Boolean, Number, String], default: () => void 0, }, label: { type: [String, Boolean, Number, Object], }, indeterminate: Boolean, disabled: Boolean, checked: Boolean, name: { type: String, default: void 0, }, trueLabel: { type: [String, Number], default: void 0, }, falseLabel: { type: [String, Number], default: void 0, }, tabindex: [String, Number], size: String, } const useCheckboxGroup = () => { const elForm = inject(formContextKey, {}) const elFormItem = inject(formItemContextKey, {}) const checkboxGroup2 = inject('CheckboxGroup', {}) const isGroup2 = computed( () => checkboxGroup2 && (checkboxGroup2 == null ? void 0 : checkboxGroup2.name) === 'ElCheckboxGroup' ) const elFormItemSize = computed(() => { return elFormItem.size }) return { isGroup: isGroup2, checkboxGroup: checkboxGroup2, elForm, elFormItemSize, elFormItem, } } const useModel = (props2) => { const selfModel = ref(false) const { emit: emit2 } = getCurrentInstance() const { isGroup: isGroup2, checkboxGroup: checkboxGroup2 } = useCheckboxGroup() const isLimitExceeded = ref(false) const model = computed({ get() { var _a2, _b2 return isGroup2.value ? (_a2 = checkboxGroup2.modelValue) == null ? void 0 : _a2.value : (_b2 = props2.modelValue) != null ? _b2 : selfModel.value }, set(val2) { var _a2 if (isGroup2.value && Array.isArray(val2)) { isLimitExceeded.value = checkboxGroup2.max !== void 0 && val2.length > checkboxGroup2.max.value isLimitExceeded.value === false && ((_a2 = checkboxGroup2 == null ? void 0 : checkboxGroup2.changeEvent) == null ? void 0 : _a2.call(checkboxGroup2, val2)) } else { emit2(UPDATE_MODEL_EVENT, val2) selfModel.value = val2 } }, }) return { model, isLimitExceeded, } } const useCheckboxStatus = (props2, { model }) => { const { isGroup: isGroup2, checkboxGroup: checkboxGroup2 } = useCheckboxGroup() const focus2 = ref(false) const size = useSize$1( checkboxGroup2 == null ? void 0 : checkboxGroup2.checkboxGroupSize, { prop: true } ) const isChecked = computed(() => { const value2 = model.value if (toTypeString$1(value2) === '[object Boolean]') { return value2 } else if (Array.isArray(value2)) { return value2.includes(props2.label) } else if (value2 !== null && value2 !== void 0) { return value2 === props2.trueLabel } else { return !!value2 } }) const checkboxSize = useSize$1( computed(() => { var _a2 return isGroup2.value ? (_a2 = checkboxGroup2 == null ? void 0 : checkboxGroup2.checkboxGroupSize) == null ? void 0 : _a2.value : void 0 }) ) return { isChecked, focus: focus2, size, checkboxSize, } } const useDisabled = (props2, { model, isChecked }) => { const { elForm, isGroup: isGroup2, checkboxGroup: checkboxGroup2, } = useCheckboxGroup() const isLimitDisabled = computed(() => { var _a2, _b2 const max3 = (_a2 = checkboxGroup2.max) == null ? void 0 : _a2.value const min3 = (_b2 = checkboxGroup2.min) == null ? void 0 : _b2.value return ( (!!(max3 || min3) && model.value.length >= max3 && !isChecked.value) || (model.value.length <= min3 && isChecked.value) ) }) const isDisabled = computed(() => { var _a2, _b2 const disabled = props2.disabled || elForm.disabled return (_b2 = isGroup2.value ? ((_a2 = checkboxGroup2.disabled) == null ? void 0 : _a2.value) || disabled || isLimitDisabled.value : props2.disabled || elForm.disabled) != null ? _b2 : false }) return { isDisabled, isLimitDisabled, } } const setStoreValue = (props2, { model }) => { function addToStore() { if (Array.isArray(model.value) && !model.value.includes(props2.label)) { model.value.push(props2.label) } else { model.value = props2.trueLabel || true } } props2.checked && addToStore() } const useEvent$1 = (props2, { isLimitExceeded }) => { const { elFormItem } = useCheckboxGroup() const { emit: emit2 } = getCurrentInstance() function handleChange(e2) { var _a2, _b2 if (isLimitExceeded.value) return const target2 = e2.target const value2 = target2.checked ? (_a2 = props2.trueLabel) != null ? _a2 : true : (_b2 = props2.falseLabel) != null ? _b2 : false emit2('change', value2, e2) } watch$1( () => props2.modelValue, () => { var _a2 ;(_a2 = elFormItem.validate) == null ? void 0 : _a2.call(elFormItem, 'change').catch((err) => debugWarn()) } ) return { handleChange, } } const useCheckbox = (props2) => { const { model, isLimitExceeded } = useModel(props2) const { focus: focus2, size, isChecked, checkboxSize, } = useCheckboxStatus(props2, { model, }) const { isDisabled } = useDisabled(props2, { model, isChecked }) const { handleChange } = useEvent$1(props2, { isLimitExceeded }) setStoreValue(props2, { model }) return { isChecked, isDisabled, checkboxSize, model, handleChange, focus: focus2, size, } } const _sfc_main$8S = defineComponent({ name: 'ElCheckbox', props: { modelValue: { type: [Number, String, Boolean], default: () => void 0, }, label: { type: [String, Boolean, Number, Object], }, indeterminate: Boolean, disabled: Boolean, checked: Boolean, name: { type: String, default: void 0, }, trueLabel: { type: [String, Number], default: void 0, }, falseLabel: { type: [String, Number], default: void 0, }, id: { type: String, default: void 0, }, controls: { type: String, default: void 0, }, border: Boolean, size: { type: String, validator: isValidComponentSize, }, tabindex: [String, Number], }, emits: [UPDATE_MODEL_EVENT, 'change'], setup(props2) { const ns = useNamespace('checkbox') return { ns, ...useCheckbox(props2), } }, }) const _hoisted_1$6P = ['id', 'aria-controls'] const _hoisted_2$5u = ['tabindex', 'role', 'aria-checked'] const _hoisted_3$4P = [ 'aria-hidden', 'name', 'tabindex', 'disabled', 'true-value', 'false-value', ] const _hoisted_4$48 = ['aria-hidden', 'disabled', 'value', 'name', 'tabindex'] function _sfc_render$1y(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock( 'label', { id: _ctx.id, class: normalizeClass([ _ctx.ns.b(), _ctx.ns.m(_ctx.checkboxSize), _ctx.ns.is('disabled', _ctx.isDisabled), _ctx.ns.is('bordered', _ctx.border), _ctx.ns.is('checked', _ctx.isChecked), ]), 'aria-controls': _ctx.indeterminate ? _ctx.controls : null, }, [ createElementVNode( 'span', { class: normalizeClass([ _ctx.ns.e('input'), _ctx.ns.is('disabled', _ctx.isDisabled), _ctx.ns.is('checked', _ctx.isChecked), _ctx.ns.is('indeterminate', _ctx.indeterminate), _ctx.ns.is('focus', _ctx.focus), ]), tabindex: _ctx.indeterminate ? 0 : void 0, role: _ctx.indeterminate ? 'checkbox' : void 0, 'aria-checked': _ctx.indeterminate ? 'mixed' : false, }, [ createElementVNode( 'span', { class: normalizeClass(_ctx.ns.e('inner')), }, null, 2 ), _ctx.trueLabel || _ctx.falseLabel ? withDirectives( (openBlock(), createElementBlock( 'input', { key: 0, 'onUpdate:modelValue': _cache[0] || (_cache[0] = ($event) => (_ctx.model = $event)), class: normalizeClass(_ctx.ns.e('original')), type: 'checkbox', 'aria-hidden': _ctx.indeterminate ? 'true' : 'false', name: _ctx.name, tabindex: _ctx.tabindex, disabled: _ctx.isDisabled, 'true-value': _ctx.trueLabel, 'false-value': _ctx.falseLabel, onChange: _cache[1] || (_cache[1] = (...args) => _ctx.handleChange && _ctx.handleChange(...args)), onFocus: _cache[2] || (_cache[2] = ($event) => (_ctx.focus = true)), onBlur: _cache[3] || (_cache[3] = ($event) => (_ctx.focus = false)), }, null, 42, _hoisted_3$4P )), [[vModelCheckbox, _ctx.model]] ) : withDirectives( (openBlock(), createElementBlock( 'input', { key: 1, 'onUpdate:modelValue': _cache[4] || (_cache[4] = ($event) => (_ctx.model = $event)), class: normalizeClass(_ctx.ns.e('original')), type: 'checkbox', 'aria-hidden': _ctx.indeterminate ? 'true' : 'false', disabled: _ctx.isDisabled, value: _ctx.label, name: _ctx.name, tabindex: _ctx.tabindex, onChange: _cache[5] || (_cache[5] = (...args) => _ctx.handleChange && _ctx.handleChange(...args)), onFocus: _cache[6] || (_cache[6] = ($event) => (_ctx.focus = true)), onBlur: _cache[7] || (_cache[7] = ($event) => (_ctx.focus = false)), }, null, 42, _hoisted_4$48 )), [[vModelCheckbox, _ctx.model]] ), ], 10, _hoisted_2$5u ), _ctx.$slots.default || _ctx.label ? (openBlock(), createElementBlock( 'span', { key: 0, class: normalizeClass(_ctx.ns.e('label')), }, [ renderSlot(_ctx.$slots, 'default'), !_ctx.$slots.default ? (openBlock(), createElementBlock( Fragment, { key: 0 }, [createTextVNode(toDisplayString$1(_ctx.label), 1)], 2112 )) : createCommentVNode('v-if', true), ], 2 )) : createCommentVNode('v-if', true), ], 10, _hoisted_1$6P ) ) } var Checkbox = /* @__PURE__ */ _export_sfc$1(_sfc_main$8S, [ ['render', _sfc_render$1y], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/checkbox/src/checkbox.vue', ], ]) const _sfc_main$8R = defineComponent({ name: 'ElCheckboxButton', props: useCheckboxProps, emits: [UPDATE_MODEL_EVENT, 'change'], setup(props2) { const { focus: focus2, isChecked, isDisabled, size, model, handleChange, } = useCheckbox(props2) const { checkboxGroup: checkboxGroup2 } = useCheckboxGroup() const ns = useNamespace('checkbox') const activeStyle = computed(() => { var _a2, _b2, _c2, _d const fillValue = (_b2 = (_a2 = checkboxGroup2 == null ? void 0 : checkboxGroup2.fill) == null ? void 0 : _a2.value) != null ? _b2 : '' return { backgroundColor: fillValue, borderColor: fillValue, color: (_d = (_c2 = checkboxGroup2 == null ? void 0 : checkboxGroup2.textColor) == null ? void 0 : _c2.value) != null ? _d : '', boxShadow: fillValue ? `-1px 0 0 0 ${fillValue}` : null, } }) return { focus: focus2, isChecked, isDisabled, model, handleChange, activeStyle, size, ns, } }, }) const _hoisted_1$6O = ['aria-checked', 'aria-disabled'] const _hoisted_2$5t = [ 'name', 'tabindex', 'disabled', 'true-value', 'false-value', ] const _hoisted_3$4O = ['name', 'tabindex', 'disabled', 'value'] function _sfc_render$1x(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock( 'label', { class: normalizeClass([ _ctx.ns.b('button'), _ctx.ns.bm('button', _ctx.size), _ctx.ns.is('disabled', _ctx.isDisabled), _ctx.ns.is('checked', _ctx.isChecked), _ctx.ns.is('focus', _ctx.focus), ]), role: 'checkbox', 'aria-checked': _ctx.isChecked, 'aria-disabled': _ctx.isDisabled, }, [ _ctx.trueLabel || _ctx.falseLabel ? withDirectives( (openBlock(), createElementBlock( 'input', { key: 0, 'onUpdate:modelValue': _cache[0] || (_cache[0] = ($event) => (_ctx.model = $event)), class: normalizeClass(_ctx.ns.be('button', 'original')), type: 'checkbox', name: _ctx.name, tabindex: _ctx.tabindex, disabled: _ctx.isDisabled, 'true-value': _ctx.trueLabel, 'false-value': _ctx.falseLabel, onChange: _cache[1] || (_cache[1] = (...args) => _ctx.handleChange && _ctx.handleChange(...args)), onFocus: _cache[2] || (_cache[2] = ($event) => (_ctx.focus = true)), onBlur: _cache[3] || (_cache[3] = ($event) => (_ctx.focus = false)), }, null, 42, _hoisted_2$5t )), [[vModelCheckbox, _ctx.model]] ) : withDirectives( (openBlock(), createElementBlock( 'input', { key: 1, 'onUpdate:modelValue': _cache[4] || (_cache[4] = ($event) => (_ctx.model = $event)), class: normalizeClass(_ctx.ns.be('button', 'original')), type: 'checkbox', name: _ctx.name, tabindex: _ctx.tabindex, disabled: _ctx.isDisabled, value: _ctx.label, onChange: _cache[5] || (_cache[5] = (...args) => _ctx.handleChange && _ctx.handleChange(...args)), onFocus: _cache[6] || (_cache[6] = ($event) => (_ctx.focus = true)), onBlur: _cache[7] || (_cache[7] = ($event) => (_ctx.focus = false)), }, null, 42, _hoisted_3$4O )), [[vModelCheckbox, _ctx.model]] ), _ctx.$slots.default || _ctx.label ? (openBlock(), createElementBlock( 'span', { key: 2, class: normalizeClass(_ctx.ns.be('button', 'inner')), style: normalizeStyle$1( _ctx.isChecked ? _ctx.activeStyle : null ), }, [ renderSlot(_ctx.$slots, 'default', {}, () => [ createTextVNode(toDisplayString$1(_ctx.label), 1), ]), ], 6 )) : createCommentVNode('v-if', true), ], 10, _hoisted_1$6O ) ) } var CheckboxButton = /* @__PURE__ */ _export_sfc$1(_sfc_main$8R, [ ['render', _sfc_render$1x], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/checkbox/src/checkbox-button.vue', ], ]) const _sfc_main$8Q = defineComponent({ name: 'ElCheckboxGroup', props: { modelValue: { type: Array, default: () => [], }, disabled: Boolean, min: { type: Number, default: void 0, }, max: { type: Number, default: void 0, }, size: { type: String, validator: isValidComponentSize, }, fill: { type: String, default: void 0, }, textColor: { type: String, default: void 0, }, tag: { type: String, default: 'div', }, }, emits: [UPDATE_MODEL_EVENT, 'change'], setup(props2, { emit: emit2, slots }) { const { elFormItem } = useCheckboxGroup() const checkboxGroupSize = useSize$1() const ns = useNamespace('checkbox') const changeEvent = (value2) => { emit2(UPDATE_MODEL_EVENT, value2) nextTick(() => { emit2('change', value2) }) } const modelValue = computed({ get() { return props2.modelValue }, set(val2) { changeEvent(val2) }, }) provide('CheckboxGroup', { name: 'ElCheckboxGroup', modelValue, ...toRefs$2(props2), checkboxGroupSize, changeEvent, }) watch$1( () => props2.modelValue, () => { var _a2 ;(_a2 = elFormItem.validate) == null ? void 0 : _a2.call(elFormItem, 'change').catch((err) => debugWarn()) } ) return () => { return h$4( props2.tag, { class: ns.b('group'), role: 'group', 'aria-label': 'checkbox-group', }, [renderSlot(slots, 'default')] ) } }, }) var CheckboxGroup = /* @__PURE__ */ _export_sfc$1(_sfc_main$8Q, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/checkbox/src/checkbox-group.vue', ], ]) const ElCheckbox = withInstall(Checkbox, { CheckboxButton, CheckboxGroup, }) const ElCheckboxButton = withNoopInstall(CheckboxButton) const ElCheckboxGroup$1 = withNoopInstall(CheckboxGroup) const radioPropsBase = buildProps({ size: useSizeProp, disabled: Boolean, label: { type: [String, Number, Boolean], default: '', }, }) const radioProps = buildProps({ ...radioPropsBase, modelValue: { type: [String, Number, Boolean], default: '', }, name: { type: String, default: '', }, border: Boolean, }) const radioEmits = { [UPDATE_MODEL_EVENT]: (val2) => isString$f(val2) || isNumber$h(val2) || isBoolean$5(val2), change: (val2) => isString$f(val2) || isNumber$h(val2) || isBoolean$5(val2), } const useRadio = (props2, emit2) => { const radioRef = ref() const radioGroup = inject(radioGroupKey, void 0) const isGroup2 = computed(() => !!radioGroup) const modelValue = computed({ get() { return isGroup2.value ? radioGroup.modelValue : props2.modelValue }, set(val2) { if (isGroup2.value) { radioGroup.changeEvent(val2) } else { emit2(UPDATE_MODEL_EVENT, val2) } radioRef.value.checked = props2.modelValue === props2.label }, }) const size = useSize$1( computed(() => (radioGroup == null ? void 0 : radioGroup.size)) ) const disabled = useDisabled$1( computed(() => (radioGroup == null ? void 0 : radioGroup.disabled)) ) const focus2 = ref(false) const tabIndex = computed(() => { return disabled.value || (isGroup2.value && modelValue.value !== props2.label) ? -1 : 0 }) return { radioRef, isGroup: isGroup2, radioGroup, focus: focus2, size, disabled, tabIndex, modelValue, } } const _sfc_main$8P = defineComponent({ name: 'ElRadio', props: radioProps, emits: radioEmits, setup(props2, { emit: emit2 }) { const ns = useNamespace('radio') const { radioRef, isGroup: isGroup2, focus: focus2, size, disabled, tabIndex, modelValue, } = useRadio(props2, emit2) function handleChange() { nextTick(() => emit2('change', modelValue.value)) } return { ns, focus: focus2, isGroup: isGroup2, modelValue, tabIndex, size, disabled, radioRef, handleChange, } }, }) const _hoisted_1$6N = ['aria-checked', 'aria-disabled', 'tabindex'] const _hoisted_2$5s = ['value', 'name', 'disabled'] function _sfc_render$1w(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock( 'label', { class: normalizeClass([ _ctx.ns.b(), _ctx.ns.is('disabled', _ctx.disabled), _ctx.ns.is('focus', _ctx.focus), _ctx.ns.is('bordered', _ctx.border), _ctx.ns.is('checked', _ctx.modelValue === _ctx.label), _ctx.ns.m(_ctx.size), ]), role: 'radio', 'aria-checked': _ctx.modelValue === _ctx.label, 'aria-disabled': _ctx.disabled, tabindex: _ctx.tabIndex, onKeydown: _cache[5] || (_cache[5] = withKeys( withModifiers( ($event) => (_ctx.modelValue = _ctx.disabled ? _ctx.modelValue : _ctx.label), ['stop', 'prevent'] ), ['space'] )), }, [ createElementVNode( 'span', { class: normalizeClass([ _ctx.ns.e('input'), _ctx.ns.is('disabled', _ctx.disabled), _ctx.ns.is('checked', _ctx.modelValue === _ctx.label), ]), }, [ createElementVNode( 'span', { class: normalizeClass(_ctx.ns.e('inner')), }, null, 2 ), withDirectives( createElementVNode( 'input', { ref: 'radioRef', 'onUpdate:modelValue': _cache[0] || (_cache[0] = ($event) => (_ctx.modelValue = $event)), class: normalizeClass(_ctx.ns.e('original')), value: _ctx.label, type: 'radio', 'aria-hidden': 'true', name: _ctx.name, disabled: _ctx.disabled, tabindex: '-1', onFocus: _cache[1] || (_cache[1] = ($event) => (_ctx.focus = true)), onBlur: _cache[2] || (_cache[2] = ($event) => (_ctx.focus = false)), onChange: _cache[3] || (_cache[3] = (...args) => _ctx.handleChange && _ctx.handleChange(...args)), }, null, 42, _hoisted_2$5s ), [[vModelRadio, _ctx.modelValue]] ), ], 2 ), createElementVNode( 'span', { class: normalizeClass(_ctx.ns.e('label')), onKeydown: _cache[4] || (_cache[4] = withModifiers(() => {}, ['stop'])), }, [ renderSlot(_ctx.$slots, 'default', {}, () => [ createTextVNode(toDisplayString$1(_ctx.label), 1), ]), ], 34 ), ], 42, _hoisted_1$6N ) ) } var Radio = /* @__PURE__ */ _export_sfc$1(_sfc_main$8P, [ ['render', _sfc_render$1w], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/radio/src/radio.vue', ], ]) const radioButtonProps = buildProps({ ...radioPropsBase, name: { type: String, default: '', }, }) const _sfc_main$8O = defineComponent({ name: 'ElRadioButton', props: radioButtonProps, setup(props2, { emit: emit2 }) { const ns = useNamespace('radio') const { radioRef, isGroup: isGroup2, focus: focus2, size, disabled, tabIndex, modelValue, radioGroup, } = useRadio(props2, emit2) const activeStyle = computed(() => { return { backgroundColor: (radioGroup == null ? void 0 : radioGroup.fill) || '', borderColor: (radioGroup == null ? void 0 : radioGroup.fill) || '', boxShadow: (radioGroup == null ? void 0 : radioGroup.fill) ? `-1px 0 0 0 ${radioGroup.fill}` : '', color: (radioGroup == null ? void 0 : radioGroup.textColor) || '', } }) return { ns, isGroup: isGroup2, size, disabled, tabIndex, modelValue, focus: focus2, activeStyle, radioRef, } }, }) const _hoisted_1$6M = ['aria-checked', 'aria-disabled', 'tabindex'] const _hoisted_2$5r = ['value', 'name', 'disabled'] function _sfc_render$1v(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock( 'label', { class: normalizeClass([ _ctx.ns.b('button'), _ctx.ns.is('active', _ctx.modelValue === _ctx.label), _ctx.ns.is('disabled', _ctx.disabled), _ctx.ns.is('focus', _ctx.focus), _ctx.ns.bm('button', _ctx.size), ]), role: 'radio', 'aria-checked': _ctx.modelValue === _ctx.label, 'aria-disabled': _ctx.disabled, tabindex: _ctx.tabIndex, onKeydown: _cache[4] || (_cache[4] = withKeys( withModifiers( ($event) => (_ctx.modelValue = _ctx.disabled ? _ctx.modelValue : _ctx.label), ['stop', 'prevent'] ), ['space'] )), }, [ withDirectives( createElementVNode( 'input', { ref: 'radioRef', 'onUpdate:modelValue': _cache[0] || (_cache[0] = ($event) => (_ctx.modelValue = $event)), class: normalizeClass(_ctx.ns.be('button', 'original-radio')), value: _ctx.label, type: 'radio', name: _ctx.name, disabled: _ctx.disabled, tabindex: '-1', onFocus: _cache[1] || (_cache[1] = ($event) => (_ctx.focus = true)), onBlur: _cache[2] || (_cache[2] = ($event) => (_ctx.focus = false)), }, null, 42, _hoisted_2$5r ), [[vModelRadio, _ctx.modelValue]] ), createElementVNode( 'span', { class: normalizeClass(_ctx.ns.be('button', 'inner')), style: normalizeStyle$1( _ctx.modelValue === _ctx.label ? _ctx.activeStyle : {} ), onKeydown: _cache[3] || (_cache[3] = withModifiers(() => {}, ['stop'])), }, [ renderSlot(_ctx.$slots, 'default', {}, () => [ createTextVNode(toDisplayString$1(_ctx.label), 1), ]), ], 38 ), ], 42, _hoisted_1$6M ) ) } var RadioButton = /* @__PURE__ */ _export_sfc$1(_sfc_main$8O, [ ['render', _sfc_render$1v], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/radio/src/radio-button.vue', ], ]) const radioGroupProps = buildProps({ size: useSizeProp, disabled: Boolean, modelValue: { type: [String, Number, Boolean], default: '', }, fill: { type: String, default: '', }, textColor: { type: String, default: '', }, }) const radioGroupEmits = radioEmits const _sfc_main$8N = defineComponent({ name: 'ElRadioGroup', props: radioGroupProps, emits: radioGroupEmits, setup(props2, ctx) { const ns = useNamespace('radio') const radioGroupRef = ref() const { formItem } = useFormItem() const changeEvent = (value2) => { ctx.emit(UPDATE_MODEL_EVENT, value2) nextTick(() => ctx.emit('change', value2)) } const handleKeydown = (e2) => { if (!radioGroupRef.value) return const target2 = e2.target const className = target2.nodeName === 'INPUT' ? '[type=radio]' : '[role=radio]' const radios = radioGroupRef.value.querySelectorAll(className) const length2 = radios.length const index2 = Array.from(radios).indexOf(target2) const roleRadios = radioGroupRef.value.querySelectorAll('[role=radio]') let nextIndex = null switch (e2.code) { case EVENT_CODE.left: case EVENT_CODE.up: e2.stopPropagation() e2.preventDefault() nextIndex = index2 === 0 ? length2 - 1 : index2 - 1 break case EVENT_CODE.right: case EVENT_CODE.down: e2.stopPropagation() e2.preventDefault() nextIndex = index2 === length2 - 1 ? 0 : index2 + 1 break } if (nextIndex === null) return roleRadios[nextIndex].click() roleRadios[nextIndex].focus() } onMounted(() => { const radios = radioGroupRef.value.querySelectorAll('[type=radio]') const firstLabel = radios[0] if (!Array.from(radios).some((radio2) => radio2.checked) && firstLabel) { firstLabel.tabIndex = 0 } }) provide( radioGroupKey, reactive({ ...toRefs$2(props2), changeEvent, }) ) watch$1( () => props2.modelValue, () => formItem == null ? void 0 : formItem.validate('change').catch((err) => debugWarn()) ) return { ns, radioGroupRef, handleKeydown, } }, }) function _sfc_render$1u(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock( 'div', { ref: 'radioGroupRef', class: normalizeClass(_ctx.ns.b('group')), role: 'radiogroup', onKeydown: _cache[0] || (_cache[0] = (...args) => _ctx.handleKeydown && _ctx.handleKeydown(...args)), }, [renderSlot(_ctx.$slots, 'default')], 34 ) ) } var RadioGroup = /* @__PURE__ */ _export_sfc$1(_sfc_main$8N, [ ['render', _sfc_render$1u], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/radio/src/radio-group.vue', ], ]) const ElRadio = withInstall(Radio, { RadioButton, RadioGroup, }) const ElRadioGroup = withNoopInstall(RadioGroup) const ElRadioButton = withNoopInstall(RadioButton) var NodeContent$1 = defineComponent({ name: 'NodeContent', setup() { const ns = useNamespace('cascader-node') return { ns, } }, render() { const { ns } = this const { node: node2, panel } = this.$parent const { data: data2, label } = node2 const { renderLabelFn } = panel return h$4( 'span', { class: ns.e('label') }, renderLabelFn ? renderLabelFn({ node: node2, data: data2 }) : label ) }, }) var ExpandTrigger$1 = /* @__PURE__ */ ((ExpandTrigger2) => { ExpandTrigger2['CLICK'] = 'click' ExpandTrigger2['HOVER'] = 'hover' return ExpandTrigger2 })(ExpandTrigger$1 || {}) const CASCADER_PANEL_INJECTION_KEY = Symbol() const _sfc_main$8M = defineComponent({ name: 'ElCascaderNode', components: { ElCheckbox, ElRadio, NodeContent: NodeContent$1, ElIcon, Check: check$1, Loading: loading, ArrowRight: arrowRight, }, props: { node: { type: Object, required: true, }, menuId: String, }, emits: ['expand'], setup(props2, { emit: emit2 }) { const panel = inject(CASCADER_PANEL_INJECTION_KEY) const ns = useNamespace('cascader-node') const isHoverMenu = computed(() => panel.isHoverMenu) const multiple = computed(() => panel.config.multiple) const checkStrictly = computed(() => panel.config.checkStrictly) const checkedNodeId = computed(() => { var _a2 return (_a2 = panel.checkedNodes[0]) == null ? void 0 : _a2.uid }) const isDisabled = computed(() => props2.node.isDisabled) const isLeaf2 = computed(() => props2.node.isLeaf) const expandable = computed( () => (checkStrictly.value && !isLeaf2.value) || !isDisabled.value ) const inExpandingPath = computed(() => isInPath(panel.expandingNode)) const inCheckedPath = computed( () => checkStrictly.value && panel.checkedNodes.some(isInPath) ) const isInPath = (node2) => { var _a2 const { level, uid: uid2 } = props2.node return ( ((_a2 = node2 == null ? void 0 : node2.pathNodes[level - 1]) == null ? void 0 : _a2.uid) === uid2 ) } const doExpand = () => { if (inExpandingPath.value) return panel.expandNode(props2.node) } const doCheck = (checked2) => { const { node: node2 } = props2 if (checked2 === node2.checked) return panel.handleCheckChange(node2, checked2) } const doLoad = () => { panel.lazyLoad(props2.node, () => { if (!isLeaf2.value) doExpand() }) } const handleHoverExpand = (e2) => { if (!isHoverMenu.value) return handleExpand() !isLeaf2.value && emit2('expand', e2) } const handleExpand = () => { const { node: node2 } = props2 if (!expandable.value || node2.loading) return node2.loaded ? doExpand() : doLoad() } const handleClick2 = () => { if (isHoverMenu.value && !isLeaf2.value) return if ( isLeaf2.value && !isDisabled.value && !checkStrictly.value && !multiple.value ) { handleCheck(true) } else { handleExpand() } } const handleSelectCheck = (checked2) => { if (checkStrictly.value) { doCheck(checked2) if (props2.node.loaded) { doExpand() } } else { handleCheck(checked2) } } const handleCheck = (checked2) => { if (!props2.node.loaded) { doLoad() } else { doCheck(checked2) !checkStrictly.value && doExpand() } } return { panel, isHoverMenu, multiple, checkStrictly, checkedNodeId, isDisabled, isLeaf: isLeaf2, expandable, inExpandingPath, inCheckedPath, ns, handleHoverExpand, handleExpand, handleClick: handleClick2, handleCheck, handleSelectCheck, } }, }) const _hoisted_1$6L = [ 'id', 'aria-haspopup', 'aria-owns', 'aria-expanded', 'tabindex', ] const _hoisted_2$5q = /* @__PURE__ */ createElementVNode('span', null, null, -1) function _sfc_render$1t(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_checkbox = resolveComponent('el-checkbox') const _component_el_radio = resolveComponent('el-radio') const _component_check = resolveComponent('check') const _component_el_icon = resolveComponent('el-icon') const _component_node_content = resolveComponent('node-content') const _component_loading = resolveComponent('loading') const _component_arrow_right = resolveComponent('arrow-right') return ( openBlock(), createElementBlock( 'li', { id: `${_ctx.menuId}-${_ctx.node.uid}`, role: 'menuitem', 'aria-haspopup': !_ctx.isLeaf, 'aria-owns': _ctx.isLeaf ? null : _ctx.menuId, 'aria-expanded': _ctx.inExpandingPath, tabindex: _ctx.expandable ? -1 : void 0, class: normalizeClass([ _ctx.ns.b(), _ctx.ns.is('selectable', _ctx.checkStrictly), _ctx.ns.is('active', _ctx.node.checked), _ctx.ns.is('disabled', !_ctx.expandable), _ctx.inExpandingPath && 'in-active-path', _ctx.inCheckedPath && 'in-checked-path', ]), onMouseenter: _cache[2] || (_cache[2] = (...args) => _ctx.handleHoverExpand && _ctx.handleHoverExpand(...args)), onFocus: _cache[3] || (_cache[3] = (...args) => _ctx.handleHoverExpand && _ctx.handleHoverExpand(...args)), onClick: _cache[4] || (_cache[4] = (...args) => _ctx.handleClick && _ctx.handleClick(...args)), }, [ createCommentVNode(' prefix '), _ctx.multiple ? (openBlock(), createBlock( _component_el_checkbox, { key: 0, 'model-value': _ctx.node.checked, indeterminate: _ctx.node.indeterminate, disabled: _ctx.isDisabled, onClick: _cache[0] || (_cache[0] = withModifiers(() => {}, ['stop'])), 'onUpdate:modelValue': _ctx.handleSelectCheck, }, null, 8, [ 'model-value', 'indeterminate', 'disabled', 'onUpdate:modelValue', ] )) : _ctx.checkStrictly ? (openBlock(), createBlock( _component_el_radio, { key: 1, 'model-value': _ctx.checkedNodeId, label: _ctx.node.uid, disabled: _ctx.isDisabled, 'onUpdate:modelValue': _ctx.handleSelectCheck, onClick: _cache[1] || (_cache[1] = withModifiers(() => {}, ['stop'])), }, { default: withCtx(() => [ createCommentVNode( '\n Add an empty element to avoid render label,\n do not use empty fragment here for https://github.com/vuejs/vue-next/pull/2485\n ' ), _hoisted_2$5q, ]), _: 1, }, 8, ['model-value', 'label', 'disabled', 'onUpdate:modelValue'] )) : _ctx.isLeaf && _ctx.node.checked ? (openBlock(), createBlock( _component_el_icon, { key: 2, class: normalizeClass(_ctx.ns.e('prefix')), }, { default: withCtx(() => [createVNode$1(_component_check)]), _: 1, }, 8, ['class'] )) : createCommentVNode('v-if', true), createCommentVNode(' content '), createVNode$1(_component_node_content), createCommentVNode(' postfix '), !_ctx.isLeaf ? (openBlock(), createElementBlock( Fragment, { key: 3 }, [ _ctx.node.loading ? (openBlock(), createBlock( _component_el_icon, { key: 0, class: normalizeClass([ _ctx.ns.is('loading'), _ctx.ns.e('postfix'), ]), }, { default: withCtx(() => [ createVNode$1(_component_loading), ]), _: 1, }, 8, ['class'] )) : (openBlock(), createBlock( _component_el_icon, { key: 1, class: normalizeClass([ 'arrow-right', _ctx.ns.e('postfix'), ]), }, { default: withCtx(() => [ createVNode$1(_component_arrow_right), ]), _: 1, }, 8, ['class'] )), ], 2112 )) : createCommentVNode('v-if', true), ], 42, _hoisted_1$6L ) ) } var ElCascaderNode = /* @__PURE__ */ _export_sfc$1(_sfc_main$8M, [ ['render', _sfc_render$1t], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/cascader-panel/src/node.vue', ], ]) const _sfc_main$8L = defineComponent({ name: 'ElCascaderMenu', components: { Loading: loading, ElIcon, ElScrollbar, ElCascaderNode, }, props: { nodes: { type: Array, required: true, }, index: { type: Number, required: true, }, }, setup(props2) { const instance = getCurrentInstance() const ns = useNamespace('cascader-menu') const { t: t3 } = useLocale() const id2 = generateId() let activeNode = null let hoverTimer = null const panel = inject(CASCADER_PANEL_INJECTION_KEY) const hoverZone = ref(null) const isEmpty2 = computed(() => !props2.nodes.length) const isLoading = computed(() => !panel.initialLoaded) const menuId = computed(() => `cascader-menu-${id2}-${props2.index}`) const handleExpand = (e2) => { activeNode = e2.target } const handleMouseMove = (e2) => { if (!panel.isHoverMenu || !activeNode || !hoverZone.value) return if (activeNode.contains(e2.target)) { clearHoverTimer() const el2 = instance.vnode.el const { left: left2 } = el2.getBoundingClientRect() const { offsetWidth, offsetHeight } = el2 const startX = e2.clientX - left2 const top2 = activeNode.offsetTop const bottom2 = top2 + activeNode.offsetHeight hoverZone.value.innerHTML = ` ` } else if (!hoverTimer) { hoverTimer = window.setTimeout( clearHoverZone, panel.config.hoverThreshold ) } } const clearHoverTimer = () => { if (!hoverTimer) return clearTimeout(hoverTimer) hoverTimer = null } const clearHoverZone = () => { if (!hoverZone.value) return hoverZone.value.innerHTML = '' clearHoverTimer() } return { ns, panel, hoverZone, isEmpty: isEmpty2, isLoading, menuId, t: t3, handleExpand, handleMouseMove, clearHoverZone, } }, }) function _sfc_render$1s(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_cascader_node = resolveComponent('el-cascader-node') const _component_loading = resolveComponent('loading') const _component_el_icon = resolveComponent('el-icon') const _component_el_scrollbar = resolveComponent('el-scrollbar') return ( openBlock(), createBlock( _component_el_scrollbar, { key: _ctx.menuId, tag: 'ul', role: 'menu', class: normalizeClass(_ctx.ns.b()), 'wrap-class': _ctx.ns.e('wrap'), 'view-class': [_ctx.ns.e('list'), _ctx.ns.is('empty', _ctx.isEmpty)], onMousemove: _ctx.handleMouseMove, onMouseleave: _ctx.clearHoverZone, }, { default: withCtx(() => { var _a2 return [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.nodes, (node2) => { return ( openBlock(), createBlock( _component_el_cascader_node, { key: node2.uid, node: node2, 'menu-id': _ctx.menuId, onExpand: _ctx.handleExpand, }, null, 8, ['node', 'menu-id', 'onExpand'] ) ) }), 128 )), _ctx.isLoading ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass(_ctx.ns.e('empty-text')), }, [ createVNode$1( _component_el_icon, { size: '14', class: normalizeClass(_ctx.ns.is('loading')), }, { default: withCtx(() => [ createVNode$1(_component_loading), ]), _: 1, }, 8, ['class'] ), createTextVNode( ' ' + toDisplayString$1(_ctx.t('el.cascader.loading')), 1 ), ], 2 )) : _ctx.isEmpty ? (openBlock(), createElementBlock( 'div', { key: 1, class: normalizeClass(_ctx.ns.e('empty-text')), }, toDisplayString$1(_ctx.t('el.cascader.noData')), 3 )) : ((_a2 = _ctx.panel) == null ? void 0 : _a2.isHoverMenu) ? (openBlock(), createElementBlock( 'svg', { key: 2, ref: 'hoverZone', class: normalizeClass(_ctx.ns.e('hover-zone')), }, null, 2 )) : createCommentVNode('v-if', true), ] }), _: 1, }, 8, ['class', 'wrap-class', 'view-class', 'onMousemove', 'onMouseleave'] ) ) } var ElCascaderMenu = /* @__PURE__ */ _export_sfc$1(_sfc_main$8L, [ ['render', _sfc_render$1s], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/cascader-panel/src/menu.vue', ], ]) var ExpandTrigger = /* @__PURE__ */ ((ExpandTrigger2) => { ExpandTrigger2['CLICK'] = 'click' ExpandTrigger2['HOVER'] = 'hover' return ExpandTrigger2 })(ExpandTrigger || {}) let uid$3 = 0 const calculatePathNodes = (node2) => { const nodes = [node2] let { parent: parent2 } = node2 while (parent2) { nodes.unshift(parent2) parent2 = parent2.parent } return nodes } class Node$3 { constructor(data2, config2, parent2, root2 = false) { this.data = data2 this.config = config2 this.parent = parent2 this.root = root2 this.uid = uid$3++ this.checked = false this.indeterminate = false this.loading = false const { value: valueKey, label: labelKey, children: childrenKey } = config2 const childrenData = data2[childrenKey] const pathNodes = calculatePathNodes(this) this.level = root2 ? 0 : parent2 ? parent2.level + 1 : 1 this.value = data2[valueKey] this.label = data2[labelKey] this.pathNodes = pathNodes this.pathValues = pathNodes.map((node2) => node2.value) this.pathLabels = pathNodes.map((node2) => node2.label) this.childrenData = childrenData this.children = (childrenData || []).map( (child) => new Node$3(child, config2, this) ) this.loaded = !config2.lazy || this.isLeaf || !isEmpty$3(childrenData) } get isDisabled() { const { data: data2, parent: parent2, config: config2 } = this const { disabled, checkStrictly } = config2 const isDisabled = isFunction$l(disabled) ? disabled(data2, this) : !!data2[disabled] return ( isDisabled || (!checkStrictly && (parent2 == null ? void 0 : parent2.isDisabled)) ) } get isLeaf() { const { data: data2, config: config2, childrenData, loaded } = this const { lazy, leaf } = config2 const isLeaf2 = isFunction$l(leaf) ? leaf(data2, this) : data2[leaf] return isUndefined$c(isLeaf2) ? lazy && !loaded ? false : !(Array.isArray(childrenData) && childrenData.length) : !!isLeaf2 } get valueByOption() { return this.config.emitPath ? this.pathValues : this.value } appendChild(childData) { const { childrenData, children } = this const node2 = new Node$3(childData, this.config, this) if (Array.isArray(childrenData)) { childrenData.push(childData) } else { this.childrenData = [childData] } children.push(node2) return node2 } calcText(allLevels, separator) { const text2 = allLevels ? this.pathLabels.join(separator) : this.label this.text = text2 return text2 } broadcast(event, ...args) { const handlerName = `onParent${capitalize$2(event)}` this.children.forEach((child) => { if (child) { child.broadcast(event, ...args) child[handlerName] && child[handlerName](...args) } }) } emit(event, ...args) { const { parent: parent2 } = this const handlerName = `onChild${capitalize$2(event)}` if (parent2) { parent2[handlerName] && parent2[handlerName](...args) parent2.emit(event, ...args) } } onParentCheck(checked2) { if (!this.isDisabled) { this.setCheckState(checked2) } } onChildCheck() { const { children } = this const validChildren = children.filter((child) => !child.isDisabled) const checked2 = validChildren.length ? validChildren.every((child) => child.checked) : false this.setCheckState(checked2) } setCheckState(checked2) { const totalNum = this.children.length const checkedNum = this.children.reduce((c2, p2) => { const num2 = p2.checked ? 1 : p2.indeterminate ? 0.5 : 0 return c2 + num2 }, 0) this.checked = this.loaded && this.children.every((child) => child.loaded && child.checked) && checked2 this.indeterminate = this.loaded && checkedNum !== totalNum && checkedNum > 0 } doCheck(checked2) { if (this.checked === checked2) return const { checkStrictly, multiple } = this.config if (checkStrictly || !multiple) { this.checked = checked2 } else { this.broadcast('check', checked2) this.setCheckState(checked2) this.emit('check') } } } const flatNodes = (nodes, leafOnly) => { return nodes.reduce((res, node2) => { if (node2.isLeaf) { res.push(node2) } else { !leafOnly && res.push(node2) res = res.concat(flatNodes(node2.children, leafOnly)) } return res }, []) } class Store$2 { constructor(data2, config2) { this.config = config2 const nodes = (data2 || []).map( (nodeData) => new Node$3(nodeData, this.config) ) this.nodes = nodes this.allNodes = flatNodes(nodes, false) this.leafNodes = flatNodes(nodes, true) } getNodes() { return this.nodes } getFlattedNodes(leafOnly) { return leafOnly ? this.leafNodes : this.allNodes } appendNode(nodeData, parentNode2) { const node2 = parentNode2 ? parentNode2.appendChild(nodeData) : new Node$3(nodeData, this.config) if (!parentNode2) this.nodes.push(node2) this.allNodes.push(node2) node2.isLeaf && this.leafNodes.push(node2) } appendNodes(nodeDataList, parentNode2) { nodeDataList.forEach((nodeData) => this.appendNode(nodeData, parentNode2)) } getNodeByValue(value2, leafOnly = false) { if (!value2 && value2 !== 0) return null const node2 = this.getFlattedNodes(leafOnly).find( (node22) => isEqual$4(node22.value, value2) || isEqual$4(node22.pathValues, value2) ) return node2 || null } getSameNode(node2) { if (!node2) return null const node_ = this.getFlattedNodes(false).find( ({ value: value2, level }) => isEqual$4(node2.value, value2) && node2.level === level ) return node_ || null } } const CommonProps = { modelValue: [Number, String, Array], options: { type: Array, default: () => [], }, props: { type: Object, default: () => ({}), }, } const DefaultProps = { expandTrigger: ExpandTrigger.CLICK, multiple: false, checkStrictly: false, emitPath: true, lazy: false, lazyLoad: NOOP, value: 'value', label: 'label', children: 'children', leaf: 'leaf', disabled: 'disabled', hoverThreshold: 500, } const useCascaderConfig = (props2) => { return computed(() => ({ ...DefaultProps, ...props2.props, })) } const getMenuIndex = (el2) => { if (!el2) return 0 const pieces = el2.id.split('-') return Number(pieces[pieces.length - 2]) } const checkNode = (el2) => { if (!el2) return const input = el2.querySelector('input') if (input) { input.click() } else if (isLeaf(el2)) { el2.click() } } const sortByOriginalOrder = (oldNodes, newNodes) => { const newNodesCopy = newNodes.slice(0) const newIds = newNodesCopy.map((node2) => node2.uid) const res = oldNodes.reduce((acc, item2) => { const index2 = newIds.indexOf(item2.uid) if (index2 > -1) { acc.push(item2) newNodesCopy.splice(index2, 1) newIds.splice(index2, 1) } return acc }, []) res.push(...newNodesCopy) return res } const _sfc_main$8K = defineComponent({ name: 'ElCascaderPanel', components: { ElCascaderMenu, }, props: { ...CommonProps, border: { type: Boolean, default: true, }, renderLabel: Function, }, emits: [UPDATE_MODEL_EVENT, CHANGE_EVENT, 'close', 'expand-change'], setup(props2, { emit: emit2, slots }) { let manualChecked = false const ns = useNamespace('cascader') const config2 = useCascaderConfig(props2) let store2 = null const initialLoaded = ref(true) const menuList = ref([]) const checkedValue = ref(null) const menus2 = ref([]) const expandingNode = ref(null) const checkedNodes = ref([]) const isHoverMenu = computed( () => config2.value.expandTrigger === ExpandTrigger.HOVER ) const renderLabelFn = computed(() => props2.renderLabel || slots.default) const initStore = () => { const { options: options2 } = props2 const cfg = config2.value manualChecked = false store2 = new Store$2(options2, cfg) menus2.value = [store2.getNodes()] if (cfg.lazy && isEmpty$3(props2.options)) { initialLoaded.value = false lazyLoad(void 0, (list2) => { if (list2) { store2 = new Store$2(list2, cfg) menus2.value = [store2.getNodes()] } initialLoaded.value = true syncCheckedValue(false, true) }) } else { syncCheckedValue(false, true) } } const lazyLoad = (node2, cb) => { const cfg = config2.value node2 = node2 || new Node$3({}, cfg, void 0, true) node2.loading = true const resolve2 = (dataList2) => { const _node = node2 const parent2 = _node.root ? null : _node dataList2 && (store2 == null ? void 0 : store2.appendNodes(dataList2, parent2)) _node.loading = false _node.loaded = true _node.childrenData = _node.childrenData || [] cb && cb(dataList2) } cfg.lazyLoad(node2, resolve2) } const expandNode = (node2, silent) => { var _a2 const { level } = node2 const newMenus = menus2.value.slice(0, level) let newExpandingNode if (node2.isLeaf) { newExpandingNode = node2.pathNodes[level - 2] } else { newExpandingNode = node2 newMenus.push(node2.children) } if ( ((_a2 = expandingNode.value) == null ? void 0 : _a2.uid) !== (newExpandingNode == null ? void 0 : newExpandingNode.uid) ) { expandingNode.value = node2 menus2.value = newMenus !silent && emit2( 'expand-change', (node2 == null ? void 0 : node2.pathValues) || [] ) } } const handleCheckChange = (node2, checked2, emitClose = true) => { const { checkStrictly, multiple } = config2.value const oldNode = checkedNodes.value[0] manualChecked = true !multiple && (oldNode == null ? void 0 : oldNode.doCheck(false)) node2.doCheck(checked2) calculateCheckedValue() emitClose && !multiple && !checkStrictly && emit2('close') !emitClose && !multiple && !checkStrictly && expandParentNode(node2) } const expandParentNode = (node2) => { if (!node2) return node2 = node2.parent expandParentNode(node2) node2 && expandNode(node2) } const getFlattedNodes = (leafOnly) => { return store2 == null ? void 0 : store2.getFlattedNodes(leafOnly) } const getCheckedNodes = (leafOnly) => { var _a2 return (_a2 = getFlattedNodes(leafOnly)) == null ? void 0 : _a2.filter((node2) => node2.checked !== false) } const clearCheckedNodes = () => { checkedNodes.value.forEach((node2) => node2.doCheck(false)) calculateCheckedValue() } const calculateCheckedValue = () => { var _a2 const { checkStrictly, multiple } = config2.value const oldNodes = checkedNodes.value const newNodes = getCheckedNodes(!checkStrictly) const nodes = sortByOriginalOrder(oldNodes, newNodes) const values2 = nodes.map((node2) => node2.valueByOption) checkedNodes.value = nodes checkedValue.value = multiple ? values2 : (_a2 = values2[0]) != null ? _a2 : null } const syncCheckedValue = (loaded = false, forced = false) => { const { modelValue } = props2 const { lazy, multiple, checkStrictly } = config2.value const leafOnly = !checkStrictly if ( !initialLoaded.value || manualChecked || (!forced && isEqual$4(modelValue, checkedValue.value)) ) return if (lazy && !loaded) { const values2 = unique(flattenDeep$1(castArray(modelValue))) const nodes = values2 .map((val2) => store2 == null ? void 0 : store2.getNodeByValue(val2) ) .filter((node2) => !!node2 && !node2.loaded && !node2.loading) if (nodes.length) { nodes.forEach((node2) => { lazyLoad(node2, () => syncCheckedValue(false, forced)) }) } else { syncCheckedValue(true, forced) } } else { const values2 = multiple ? castArray(modelValue) : [modelValue] const nodes = unique( values2.map((val2) => store2 == null ? void 0 : store2.getNodeByValue(val2, leafOnly) ) ) syncMenuState(nodes, false) checkedValue.value = modelValue } } const syncMenuState = (newCheckedNodes, reserveExpandingState = true) => { const { checkStrictly } = config2.value const oldNodes = checkedNodes.value const newNodes = newCheckedNodes.filter( (node2) => !!node2 && (checkStrictly || node2.isLeaf) ) const oldExpandingNode = store2 == null ? void 0 : store2.getSameNode(expandingNode.value) const newExpandingNode = (reserveExpandingState && oldExpandingNode) || newNodes[0] if (newExpandingNode) { newExpandingNode.pathNodes.forEach((node2) => expandNode(node2, true)) } else { expandingNode.value = null } oldNodes.forEach((node2) => node2.doCheck(false)) newNodes.forEach((node2) => node2.doCheck(true)) checkedNodes.value = newNodes nextTick(scrollToExpandingNode) } const scrollToExpandingNode = () => { if (!isClient$1) return menuList.value.forEach((menu2) => { const menuElement = menu2 == null ? void 0 : menu2.$el if (menuElement) { const container = menuElement.querySelector( `.${ns.namespace.value}-scrollbar__wrap` ) const activeNode = menuElement.querySelector(`.${ns.b('node')}.${ns.is('active')}`) || menuElement.querySelector(`.${ns.b('node')}.in-active-path`) scrollIntoView$1(container, activeNode) } }) } const handleKeyDown = (e2) => { const target2 = e2.target const { code: code2 } = e2 switch (code2) { case EVENT_CODE.up: case EVENT_CODE.down: { e2.preventDefault() const distance2 = code2 === EVENT_CODE.up ? -1 : 1 focusNode( getSibling(target2, distance2, `.${ns.b('node')}[tabindex="-1"]`) ) break } case EVENT_CODE.left: { e2.preventDefault() const preMenu = menuList.value[getMenuIndex(target2) - 1] const expandedNode = preMenu == null ? void 0 : preMenu.$el.querySelector( `.${ns.b('node')}[aria-expanded="true"]` ) focusNode(expandedNode) break } case EVENT_CODE.right: { e2.preventDefault() const nextMenu = menuList.value[getMenuIndex(target2) + 1] const firstNode = nextMenu == null ? void 0 : nextMenu.$el.querySelector(`.${ns.b('node')}[tabindex="-1"]`) focusNode(firstNode) break } case EVENT_CODE.enter: checkNode(target2) break case EVENT_CODE.esc: case EVENT_CODE.tab: emit2('close') break } } provide( CASCADER_PANEL_INJECTION_KEY, reactive({ config: config2, expandingNode, checkedNodes, isHoverMenu, initialLoaded, renderLabelFn, lazyLoad, expandNode, handleCheckChange, }) ) watch$1([config2, () => props2.options], initStore, { deep: true, immediate: true, }) watch$1( () => props2.modelValue, () => { manualChecked = false syncCheckedValue() } ) watch$1(checkedValue, (val2) => { if (!isEqual$4(val2, props2.modelValue)) { emit2(UPDATE_MODEL_EVENT, val2) emit2(CHANGE_EVENT, val2) } }) onBeforeUpdate(() => (menuList.value = [])) onMounted(() => !isEmpty$3(props2.modelValue) && syncCheckedValue()) return { ns, menuList, menus: menus2, checkedNodes, handleKeyDown, handleCheckChange, getFlattedNodes, getCheckedNodes, clearCheckedNodes, calculateCheckedValue, scrollToExpandingNode, } }, }) function _sfc_render$1r(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_cascader_menu = resolveComponent('el-cascader-menu') return ( openBlock(), createElementBlock( 'div', { class: normalizeClass([ _ctx.ns.b('panel'), _ctx.ns.is('bordered', _ctx.border), ]), onKeydown: _cache[0] || (_cache[0] = (...args) => _ctx.handleKeyDown && _ctx.handleKeyDown(...args)), }, [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.menus, (menu2, index2) => { return ( openBlock(), createBlock( _component_el_cascader_menu, { key: index2, ref_for: true, ref: (item2) => (_ctx.menuList[index2] = item2), index: index2, nodes: [...menu2], }, null, 8, ['index', 'nodes'] ) ) }), 128 )), ], 34 ) ) } var CascaderPanel = /* @__PURE__ */ _export_sfc$1(_sfc_main$8K, [ ['render', _sfc_render$1r], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/cascader-panel/src/index.vue', ], ]) CascaderPanel.install = (app2) => { app2.component(CascaderPanel.name, CascaderPanel) } const _CascaderPanel = CascaderPanel const ElCascaderPanel = _CascaderPanel const tagProps = buildProps({ closable: Boolean, type: { type: String, values: ['success', 'info', 'warning', 'danger', ''], default: '', }, hit: Boolean, disableTransitions: Boolean, color: { type: String, default: '', }, size: { type: String, values: componentSizes, default: '', }, effect: { type: String, values: ['dark', 'light', 'plain'], default: 'light', }, round: Boolean, }) const tagEmits = { close: (evt) => evt instanceof MouseEvent, click: (evt) => evt instanceof MouseEvent, } const __default__$u = { name: 'ElTag', } const _sfc_main$8J = /* @__PURE__ */ defineComponent({ ...__default__$u, props: tagProps, emits: tagEmits, setup(__props2, { emit: emit2 }) { const props2 = __props2 const tagSize = useSize$1() const ns = useNamespace('tag') const classes = computed(() => { const { type: type4, hit, effect: effect2, closable, round: round2, } = props2 return [ ns.b(), ns.is('closable', closable), ns.m(type4), ns.m(tagSize.value), ns.m(effect2), ns.is('hit', hit), ns.is('round', round2), ] }) const handleClose = (event) => { event.stopPropagation() emit2('close', event) } const handleClick2 = (event) => { emit2('click', event) } return (_ctx, _cache) => { return !_ctx.disableTransitions ? (openBlock(), createElementBlock( 'span', { key: 0, class: normalizeClass(unref(classes)), style: normalizeStyle$1({ backgroundColor: _ctx.color }), onClick: handleClick2, }, [ createElementVNode( 'span', { class: normalizeClass(unref(ns).e('content')), }, [renderSlot(_ctx.$slots, 'default')], 2 ), _ctx.closable ? (openBlock(), createBlock( unref(ElIcon), { key: 0, class: normalizeClass(unref(ns).e('close')), onClick: handleClose, }, { default: withCtx(() => [createVNode$1(unref(close$2))]), _: 1, }, 8, ['class'] )) : createCommentVNode('v-if', true), ], 6 )) : (openBlock(), createBlock( Transition, { key: 1, name: `${unref(ns).namespace.value}-zoom-in-center`, }, { default: withCtx(() => [ createElementVNode( 'span', { class: normalizeClass(unref(classes)), style: normalizeStyle$1({ backgroundColor: _ctx.color }), onClick: handleClick2, }, [ createElementVNode( 'span', { class: normalizeClass(unref(ns).e('content')), }, [renderSlot(_ctx.$slots, 'default')], 2 ), _ctx.closable ? (openBlock(), createBlock( unref(ElIcon), { key: 0, class: normalizeClass(unref(ns).e('close')), onClick: handleClose, }, { default: withCtx(() => [ createVNode$1(unref(close$2)), ]), _: 1, }, 8, ['class'] )) : createCommentVNode('v-if', true), ], 6 ), ]), _: 3, }, 8, ['name'] )) } }, }) var Tag = /* @__PURE__ */ _export_sfc$1(_sfc_main$8J, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/tag/src/tag.vue', ], ]) const ElTag = withInstall(Tag) const DEFAULT_INPUT_HEIGHT = 40 const INPUT_HEIGHT_MAP = { large: 36, default: 32, small: 28, } const popperOptions = { modifiers: [ { name: 'arrowPosition', enabled: true, phase: 'main', fn: ({ state: state2 }) => { const { modifiersData, placement } = state2 if (['right', 'left', 'bottom', 'top'].includes(placement)) return modifiersData.arrow.x = 35 }, requires: ['arrow'], }, ], } const COMPONENT_NAME$b = 'ElCascader' const _sfc_main$8I = defineComponent({ name: COMPONENT_NAME$b, components: { ElCascaderPanel: _CascaderPanel, ElInput, ElTooltip, ElScrollbar, ElTag, ElIcon, CircleClose: circleClose, Check: check$1, ArrowDown: arrowDown, }, directives: { Clickoutside: ClickOutside, }, props: { ...CommonProps, size: { type: String, validator: isValidComponentSize, }, placeholder: { type: String, }, disabled: Boolean, clearable: Boolean, filterable: Boolean, filterMethod: { type: Function, default: (node2, keyword) => node2.text.includes(keyword), }, separator: { type: String, default: ' / ', }, showAllLevels: { type: Boolean, default: true, }, collapseTags: Boolean, collapseTagsTooltip: { type: Boolean, default: false, }, debounce: { type: Number, default: 300, }, beforeFilter: { type: Function, default: () => true, }, popperClass: { type: String, default: '', }, popperAppendToBody: { type: Boolean, default: void 0, }, teleported: useTooltipContentProps.teleported, tagType: { ...tagProps.type, default: 'info' }, }, emits: [ UPDATE_MODEL_EVENT, CHANGE_EVENT, 'focus', 'blur', 'visible-change', 'expand-change', 'remove-tag', ], setup(props2, { emit: emit2 }) { let inputInitialHeight = 0 let pressDeleteCount = 0 const { compatTeleported } = useDeprecateAppendToBody( COMPONENT_NAME$b, 'popperAppendToBody' ) const nsCascader = useNamespace('cascader') const nsInput = useNamespace('input') const { t: t3 } = useLocale() const elForm = inject(formContextKey, {}) const elFormItem = inject(formItemContextKey, {}) const tooltipRef = ref(null) const input = ref(null) const tagWrapper = ref(null) const panel = ref(null) const suggestionPanel = ref(null) const popperVisible = ref(false) const inputHover = ref(false) const filtering = ref(false) const inputValue = ref('') const searchInputValue = ref('') const presentTags = ref([]) const allPresentTags = ref([]) const suggestions = ref([]) const isOnComposition = ref(false) const isDisabled = computed(() => props2.disabled || elForm.disabled) const inputPlaceholder = computed( () => props2.placeholder || t3('el.cascader.placeholder') ) const realSize = useSize$1() const tagSize = computed(() => ['small'].includes(realSize.value) ? 'small' : 'default' ) const multiple = computed(() => !!props2.props.multiple) const readonly2 = computed(() => !props2.filterable || multiple.value) const searchKeyword = computed(() => multiple.value ? searchInputValue.value : inputValue.value ) const checkedNodes = computed(() => { var _a2 return ((_a2 = panel.value) == null ? void 0 : _a2.checkedNodes) || [] }) const clearBtnVisible = computed(() => { if ( !props2.clearable || isDisabled.value || filtering.value || !inputHover.value ) return false return !!checkedNodes.value.length }) const presentText = computed(() => { const { showAllLevels, separator } = props2 const nodes = checkedNodes.value return nodes.length ? multiple.value ? ' ' : nodes[0].calcText(showAllLevels, separator) : '' }) const checkedValue = computed({ get() { return props2.modelValue }, set(val2) { var _a2 emit2(UPDATE_MODEL_EVENT, val2) emit2(CHANGE_EVENT, val2) ;(_a2 = elFormItem.validate) == null ? void 0 : _a2.call(elFormItem, 'change').catch((err) => debugWarn()) }, }) const popperPaneRef = computed(() => { var _a2, _b2 return (_b2 = (_a2 = tooltipRef.value) == null ? void 0 : _a2.popperRef) == null ? void 0 : _b2.contentRef }) const togglePopperVisible = (visible) => { var _a2, _b2, _c2 if (isDisabled.value) return visible = visible != null ? visible : !popperVisible.value if (visible !== popperVisible.value) { popperVisible.value = visible ;(_b2 = (_a2 = input.value) == null ? void 0 : _a2.input) == null ? void 0 : _b2.setAttribute('aria-expanded', `${visible}`) if (visible) { updatePopperPosition() nextTick( (_c2 = panel.value) == null ? void 0 : _c2.scrollToExpandingNode ) } else if (props2.filterable) { const { value: value2 } = presentText inputValue.value = value2 searchInputValue.value = value2 } emit2('visible-change', visible) } } const updatePopperPosition = () => { nextTick(() => { var _a2 ;(_a2 = tooltipRef.value) == null ? void 0 : _a2.updatePopper() }) } const hideSuggestionPanel = () => { filtering.value = false } const genTag2 = (node2) => { const { showAllLevels, separator } = props2 return { node: node2, key: node2.uid, text: node2.calcText(showAllLevels, separator), hitState: false, closable: !isDisabled.value && !node2.isDisabled, isCollapseTag: false, } } const deleteTag = (tag) => { var _a2 const node2 = tag.node node2.doCheck(false) ;(_a2 = panel.value) == null ? void 0 : _a2.calculateCheckedValue() emit2('remove-tag', node2.valueByOption) } const calculatePresentTags = () => { if (!multiple.value) return const nodes = checkedNodes.value const tags = [] const allTags = [] nodes.forEach((node2) => allTags.push(genTag2(node2))) allPresentTags.value = allTags if (nodes.length) { const [first2, ...rest] = nodes const restCount = rest.length tags.push(genTag2(first2)) if (restCount) { if (props2.collapseTags) { tags.push({ key: -1, text: `+ ${restCount}`, closable: false, isCollapseTag: true, }) } else { rest.forEach((node2) => tags.push(genTag2(node2))) } } } presentTags.value = tags } const calculateSuggestions = () => { var _a2, _b2 const { filterMethod, showAllLevels, separator } = props2 const res = (_b2 = (_a2 = panel.value) == null ? void 0 : _a2.getFlattedNodes(!props2.props.checkStrictly)) == null ? void 0 : _b2.filter((node2) => { if (node2.isDisabled) return false node2.calcText(showAllLevels, separator) return filterMethod(node2, searchKeyword.value) }) if (multiple.value) { presentTags.value.forEach((tag) => { tag.hitState = false }) allPresentTags.value.forEach((tag) => { tag.hitState = false }) } filtering.value = true suggestions.value = res updatePopperPosition() } const focusFirstNode = () => { var _a2 let firstNode if (filtering.value && suggestionPanel.value) { firstNode = suggestionPanel.value.$el.querySelector( `.${nsCascader.e('suggestion-item')}` ) } else { firstNode = (_a2 = panel.value) == null ? void 0 : _a2.$el.querySelector(`.${nsCascader.b('node')}[tabindex="-1"]`) } if (firstNode) { firstNode.focus() !filtering.value && firstNode.click() } } const updateStyle2 = () => { var _a2, _b2 const inputInner = (_a2 = input.value) == null ? void 0 : _a2.input const tagWrapperEl = tagWrapper.value const suggestionPanelEl = (_b2 = suggestionPanel.value) == null ? void 0 : _b2.$el if (!isClient$1 || !inputInner) return if (suggestionPanelEl) { const suggestionList = suggestionPanelEl.querySelector( `.${nsCascader.e('suggestion-list')}` ) suggestionList.style.minWidth = `${inputInner.offsetWidth}px` } if (tagWrapperEl) { const { offsetHeight } = tagWrapperEl const height = presentTags.value.length > 0 ? `${Math.max(offsetHeight + 6, inputInitialHeight)}px` : `${inputInitialHeight}px` inputInner.style.height = height updatePopperPosition() } } const getCheckedNodes = (leafOnly) => { var _a2 return (_a2 = panel.value) == null ? void 0 : _a2.getCheckedNodes(leafOnly) } const handleExpandChange = (value2) => { updatePopperPosition() emit2('expand-change', value2) } const handleComposition = (event) => { var _a2 const text2 = (_a2 = event.target) == null ? void 0 : _a2.value if (event.type === 'compositionend') { isOnComposition.value = false nextTick(() => handleInput(text2)) } else { const lastCharacter = text2[text2.length - 1] || '' isOnComposition.value = !isKorean(lastCharacter) } } const handleKeyDown = (e2) => { if (isOnComposition.value) return switch (e2.code) { case EVENT_CODE.enter: togglePopperVisible() break case EVENT_CODE.down: togglePopperVisible(true) nextTick(focusFirstNode) e2.preventDefault() break case EVENT_CODE.esc: case EVENT_CODE.tab: togglePopperVisible(false) break } } const handleClear = () => { var _a2 ;(_a2 = panel.value) == null ? void 0 : _a2.clearCheckedNodes() togglePopperVisible(false) } const handleSuggestionClick = (node2) => { var _a2, _b2 const { checked: checked2 } = node2 if (multiple.value) { ;(_a2 = panel.value) == null ? void 0 : _a2.handleCheckChange(node2, !checked2, false) } else { !checked2 && ((_b2 = panel.value) == null ? void 0 : _b2.handleCheckChange(node2, true, false)) togglePopperVisible(false) } } const handleSuggestionKeyDown = (e2) => { const target2 = e2.target const { code: code2 } = e2 switch (code2) { case EVENT_CODE.up: case EVENT_CODE.down: { const distance2 = code2 === EVENT_CODE.up ? -1 : 1 focusNode( getSibling( target2, distance2, `.${nsCascader.e('suggestion-item')}[tabindex="-1"]` ) ) break } case EVENT_CODE.enter: target2.click() break case EVENT_CODE.esc: case EVENT_CODE.tab: togglePopperVisible(false) break } } const handleDelete = () => { const tags = presentTags.value const lastTag = tags[tags.length - 1] pressDeleteCount = searchInputValue.value ? 0 : pressDeleteCount + 1 if (!lastTag || !pressDeleteCount) return if (lastTag.hitState) { deleteTag(lastTag) } else { lastTag.hitState = true } } const handleFilter = debounce$3(() => { const { value: value2 } = searchKeyword if (!value2) return const passed = props2.beforeFilter(value2) if (isPromise$1(passed)) { passed.then(calculateSuggestions).catch(() => {}) } else if (passed !== false) { calculateSuggestions() } else { hideSuggestionPanel() } }, props2.debounce) const handleInput = (val2, e2) => { !popperVisible.value && togglePopperVisible(true) if (e2 == null ? void 0 : e2.isComposing) return val2 ? handleFilter() : hideSuggestionPanel() } watch$1(filtering, updatePopperPosition) watch$1([checkedNodes, isDisabled], calculatePresentTags) watch$1(presentTags, () => { nextTick(() => updateStyle2()) }) watch$1(presentText, (val2) => (inputValue.value = val2), { immediate: true, }) onMounted(() => { var _a2 const inputEl = (_a2 = input.value) == null ? void 0 : _a2.$el inputInitialHeight = (inputEl == null ? void 0 : inputEl.offsetHeight) || INPUT_HEIGHT_MAP[realSize.value] || DEFAULT_INPUT_HEIGHT addResizeListener(inputEl, updateStyle2) }) onBeforeUnmount(() => { var _a2 removeResizeListener( (_a2 = input.value) == null ? void 0 : _a2.$el, updateStyle2 ) }) return { popperOptions, tooltipRef, popperPaneRef, input, tagWrapper, panel, suggestionPanel, popperVisible, inputHover, inputPlaceholder, filtering, presentText, checkedValue, inputValue, searchInputValue, presentTags, allPresentTags, suggestions, isDisabled, isOnComposition, realSize, tagSize, multiple, readonly: readonly2, clearBtnVisible, compatTeleported, nsCascader, nsInput, t: t3, togglePopperVisible, hideSuggestionPanel, deleteTag, focusFirstNode, getCheckedNodes, handleExpandChange, handleKeyDown, handleComposition, handleClear, handleSuggestionClick, handleSuggestionKeyDown, handleDelete, handleInput, } }, }) const _hoisted_1$6K = { key: 0 } const _hoisted_2$5p = { class: 'el-cascader__collapse-tags' } const _hoisted_3$4N = ['placeholder'] const _hoisted_4$47 = ['onClick'] function _sfc_render$1q(_ctx, _cache, $props2, $setup, $data, $options) { const _component_circle_close = resolveComponent('circle-close') const _component_el_icon = resolveComponent('el-icon') const _component_arrow_down = resolveComponent('arrow-down') const _component_el_input = resolveComponent('el-input') const _component_el_tag = resolveComponent('el-tag') const _component_el_tooltip = resolveComponent('el-tooltip') const _component_el_cascader_panel = resolveComponent('el-cascader-panel') const _component_check = resolveComponent('check') const _component_el_scrollbar = resolveComponent('el-scrollbar') const _directive_clickoutside = resolveDirective('clickoutside') return ( openBlock(), createBlock( _component_el_tooltip, { ref: 'tooltipRef', visible: _ctx.popperVisible, 'onUpdate:visible': _cache[17] || (_cache[17] = ($event) => (_ctx.popperVisible = $event)), teleported: _ctx.compatTeleported, 'popper-class': [_ctx.nsCascader.e('dropdown'), _ctx.popperClass], 'popper-options': _ctx.popperOptions, 'fallback-placements': [ 'bottom-start', 'bottom', 'top-start', 'top', 'right', 'left', ], 'stop-popper-mouse-event': false, 'gpu-acceleration': false, placement: 'bottom-start', transition: `${_ctx.nsCascader.namespace.value}-zoom-in-top`, effect: 'light', pure: '', persistent: '', onHide: _ctx.hideSuggestionPanel, }, { default: withCtx(() => [ withDirectives( (openBlock(), createElementBlock( 'div', { class: normalizeClass([ _ctx.nsCascader.b(), _ctx.nsCascader.m(_ctx.realSize), _ctx.nsCascader.is('disabled', _ctx.isDisabled), _ctx.$attrs.class, ]), style: normalizeStyle$1(_ctx.$attrs.style), onClick: _cache[11] || (_cache[11] = () => _ctx.togglePopperVisible(_ctx.readonly ? void 0 : true)), onKeydown: _cache[12] || (_cache[12] = (...args) => _ctx.handleKeyDown && _ctx.handleKeyDown(...args)), onMouseenter: _cache[13] || (_cache[13] = ($event) => (_ctx.inputHover = true)), onMouseleave: _cache[14] || (_cache[14] = ($event) => (_ctx.inputHover = false)), }, [ createVNode$1( _component_el_input, { ref: 'input', modelValue: _ctx.inputValue, 'onUpdate:modelValue': _cache[1] || (_cache[1] = ($event) => (_ctx.inputValue = $event)), placeholder: _ctx.inputPlaceholder, readonly: _ctx.readonly, disabled: _ctx.isDisabled, 'validate-event': false, size: _ctx.realSize, class: normalizeClass( _ctx.nsCascader.is('focus', _ctx.popperVisible) ), onCompositionstart: _ctx.handleComposition, onCompositionupdate: _ctx.handleComposition, onCompositionend: _ctx.handleComposition, onFocus: _cache[2] || (_cache[2] = (e2) => _ctx.$emit('focus', e2)), onBlur: _cache[3] || (_cache[3] = (e2) => _ctx.$emit('blur', e2)), onInput: _ctx.handleInput, }, { suffix: withCtx(() => [ _ctx.clearBtnVisible ? (openBlock(), createBlock( _component_el_icon, { key: 'clear', class: normalizeClass([ _ctx.nsInput.e('icon'), 'icon-circle-close', ]), onClick: withModifiers(_ctx.handleClear, [ 'stop', ]), }, { default: withCtx(() => [ createVNode$1(_component_circle_close), ]), _: 1, }, 8, ['class', 'onClick'] )) : (openBlock(), createBlock( _component_el_icon, { key: 'arrow-down', class: normalizeClass([ _ctx.nsInput.e('icon'), 'icon-arrow-down', _ctx.nsCascader.is( 'reverse', _ctx.popperVisible ), ]), onClick: _cache[0] || (_cache[0] = withModifiers( ($event) => _ctx.togglePopperVisible(), ['stop'] )), }, { default: withCtx(() => [ createVNode$1(_component_arrow_down), ]), _: 1, }, 8, ['class'] )), ]), _: 1, }, 8, [ 'modelValue', 'placeholder', 'readonly', 'disabled', 'size', 'class', 'onCompositionstart', 'onCompositionupdate', 'onCompositionend', 'onInput', ] ), _ctx.multiple ? (openBlock(), createElementBlock( 'div', { key: 0, ref: 'tagWrapper', class: normalizeClass(_ctx.nsCascader.e('tags')), }, [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.presentTags, (tag) => { return ( openBlock(), createBlock( _component_el_tag, { key: tag.key, type: _ctx.tagType, size: _ctx.tagSize, hit: tag.hitState, closable: tag.closable, 'disable-transitions': '', onClose: ($event) => _ctx.deleteTag(tag), }, { default: withCtx(() => [ tag.isCollapseTag === false ? (openBlock(), createElementBlock( 'span', _hoisted_1$6K, toDisplayString$1(tag.text), 1 )) : (openBlock(), createBlock( _component_el_tooltip, { key: 1, teleported: false, disabled: _ctx.popperVisible || !_ctx.collapseTagsTooltip, 'fallback-placements': [ 'bottom', 'top', 'right', 'left', ], placement: 'bottom', effect: 'light', }, { default: withCtx(() => [ createElementVNode( 'span', null, toDisplayString$1(tag.text), 1 ), ]), content: withCtx(() => [ createElementVNode( 'div', _hoisted_2$5p, [ (openBlock(true), createElementBlock( Fragment, null, renderList( _ctx.allPresentTags, (tag2, idx) => { return ( openBlock(), createElementBlock( 'div', { key: idx, class: 'el-cascader__collapse-tag', }, [ (openBlock(), createBlock( _component_el_tag, { key: tag2.key, class: 'in-tooltip', type: _ctx.tagType, size: _ctx.tagSize, hit: tag2.hitState, closable: tag2.closable, 'disable-transitions': '', onClose: ( $event ) => _ctx.deleteTag( tag2 ), }, { default: withCtx( () => [ createElementVNode( 'span', null, toDisplayString$1( tag2.text ), 1 ), ] ), _: 2, }, 1032, [ 'type', 'size', 'hit', 'closable', 'onClose', ] )), ] ) ) } ), 128 )), ] ), ]), _: 2, }, 1032, ['disabled'] )), ]), _: 2, }, 1032, ['type', 'size', 'hit', 'closable', 'onClose'] ) ) }), 128 )), _ctx.filterable && !_ctx.isDisabled ? withDirectives( (openBlock(), createElementBlock( 'input', { key: 0, 'onUpdate:modelValue': _cache[4] || (_cache[4] = ($event) => (_ctx.searchInputValue = $event)), type: 'text', class: normalizeClass( _ctx.nsCascader.e('search-input') ), placeholder: _ctx.presentText ? '' : _ctx.inputPlaceholder, onInput: _cache[5] || (_cache[5] = (e2) => _ctx.handleInput( _ctx.searchInputValue, e2 )), onClick: _cache[6] || (_cache[6] = withModifiers( ($event) => _ctx.togglePopperVisible(true), ['stop'] )), onKeydown: _cache[7] || (_cache[7] = withKeys( (...args) => _ctx.handleDelete && _ctx.handleDelete(...args), ['delete'] )), onCompositionstart: _cache[8] || (_cache[8] = (...args) => _ctx.handleComposition && _ctx.handleComposition(...args)), onCompositionupdate: _cache[9] || (_cache[9] = (...args) => _ctx.handleComposition && _ctx.handleComposition(...args)), onCompositionend: _cache[10] || (_cache[10] = (...args) => _ctx.handleComposition && _ctx.handleComposition(...args)), }, null, 42, _hoisted_3$4N )), [[vModelText, _ctx.searchInputValue]] ) : createCommentVNode('v-if', true), ], 2 )) : createCommentVNode('v-if', true), ], 38 )), [ [ _directive_clickoutside, () => _ctx.togglePopperVisible(false), _ctx.popperPaneRef, ], ] ), ]), content: withCtx(() => [ withDirectives( createVNode$1( _component_el_cascader_panel, { ref: 'panel', modelValue: _ctx.checkedValue, 'onUpdate:modelValue': _cache[15] || (_cache[15] = ($event) => (_ctx.checkedValue = $event)), options: _ctx.options, props: _ctx.props, border: false, 'render-label': _ctx.$slots.default, onExpandChange: _ctx.handleExpandChange, onClose: _cache[16] || (_cache[16] = ($event) => _ctx.$nextTick(() => _ctx.togglePopperVisible(false))), }, null, 8, [ 'modelValue', 'options', 'props', 'render-label', 'onExpandChange', ] ), [[vShow, !_ctx.filtering]] ), _ctx.filterable ? withDirectives( (openBlock(), createBlock( _component_el_scrollbar, { key: 0, ref: 'suggestionPanel', tag: 'ul', class: normalizeClass( _ctx.nsCascader.e('suggestion-panel') ), 'view-class': _ctx.nsCascader.e('suggestion-list'), onKeydown: _ctx.handleSuggestionKeyDown, }, { default: withCtx(() => [ _ctx.suggestions.length ? (openBlock(true), createElementBlock( Fragment, { key: 0 }, renderList(_ctx.suggestions, (item2) => { return ( openBlock(), createElementBlock( 'li', { key: item2.uid, class: normalizeClass([ _ctx.nsCascader.e('suggestion-item'), _ctx.nsCascader.is( 'checked', item2.checked ), ]), tabindex: -1, onClick: ($event) => _ctx.handleSuggestionClick(item2), }, [ createElementVNode( 'span', null, toDisplayString$1(item2.text), 1 ), item2.checked ? (openBlock(), createBlock( _component_el_icon, { key: 0 }, { default: withCtx(() => [ createVNode$1(_component_check), ]), _: 1, } )) : createCommentVNode('v-if', true), ], 10, _hoisted_4$47 ) ) }), 128 )) : renderSlot(_ctx.$slots, 'empty', { key: 1 }, () => [ createElementVNode( 'li', { class: normalizeClass( _ctx.nsCascader.e('empty-text') ), }, toDisplayString$1(_ctx.t('el.cascader.noMatch')), 3 ), ]), ]), _: 3, }, 8, ['class', 'view-class', 'onKeydown'] )), [[vShow, _ctx.filtering]] ) : createCommentVNode('v-if', true), ]), _: 3, }, 8, [ 'visible', 'teleported', 'popper-class', 'popper-options', 'transition', 'onHide', ] ) ) } var Cascader = /* @__PURE__ */ _export_sfc$1(_sfc_main$8I, [ ['render', _sfc_render$1q], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/cascader/src/index.vue', ], ]) Cascader.install = (app2) => { app2.component(Cascader.name, Cascader) } const _Cascader = Cascader const ElCascader = _Cascader const checkTagProps = buildProps({ checked: { type: Boolean, default: false, }, }) const checkTagEmits = { 'update:checked': (value2) => isBoolean$5(value2), change: (value2) => isBoolean$5(value2), } const __default__$t = { name: 'ElCheckTag', } const _sfc_main$8H = /* @__PURE__ */ defineComponent({ ...__default__$t, props: checkTagProps, emits: checkTagEmits, setup(__props2, { emit: emit2 }) { const props2 = __props2 const ns = useNamespace('check-tag') const handleChange = () => { const checked2 = !props2.checked emit2('change', checked2) emit2('update:checked', checked2) } return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'span', { class: normalizeClass([ unref(ns).b(), unref(ns).is('checked', _ctx.checked), ]), onClick: handleChange, }, [renderSlot(_ctx.$slots, 'default')], 2 ) ) } }, }) var CheckTag = /* @__PURE__ */ _export_sfc$1(_sfc_main$8H, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/check-tag/src/check-tag.vue', ], ]) const ElCheckTag = withInstall(CheckTag) const colProps = buildProps({ tag: { type: String, default: 'div', }, span: { type: Number, default: 24, }, offset: { type: Number, default: 0, }, pull: { type: Number, default: 0, }, push: { type: Number, default: 0, }, xs: { type: definePropType([Number, Object]), default: () => mutable({}), }, sm: { type: definePropType([Number, Object]), default: () => mutable({}), }, md: { type: definePropType([Number, Object]), default: () => mutable({}), }, lg: { type: definePropType([Number, Object]), default: () => mutable({}), }, xl: { type: definePropType([Number, Object]), default: () => mutable({}), }, }) var Col = defineComponent({ name: 'ElCol', props: colProps, setup(props2, { slots }) { const { gutter } = inject(rowContextKey, { gutter: computed(() => 0), }) const ns = useNamespace('col') const style2 = computed(() => { if (gutter.value) { return { paddingLeft: `${gutter.value / 2}px`, paddingRight: `${gutter.value / 2}px`, } } return {} }) const classes = computed(() => { const classes2 = [] const pos = ['span', 'offset', 'pull', 'push'] pos.forEach((prop) => { const size = props2[prop] if (typeof size === 'number') { if (prop === 'span') classes2.push(ns.b(`${props2[prop]}`)) else if (size > 0) classes2.push(ns.b(`${prop}-${props2[prop]}`)) } }) const sizes2 = ['xs', 'sm', 'md', 'lg', 'xl'] sizes2.forEach((size) => { if (typeof props2[size] === 'number') { classes2.push(ns.b(`${size}-${props2[size]}`)) } else if (typeof props2[size] === 'object') { const sizeProps = props2[size] Object.keys(sizeProps).forEach((prop) => { classes2.push( prop !== 'span' ? ns.b(`${size}-${prop}-${sizeProps[prop]}`) : ns.b(`${size}-${sizeProps[prop]}`) ) }) } }) if (gutter.value) { classes2.push(ns.is('guttered')) } return classes2 }) return () => createVNode$1( props2.tag, { class: [ns.b(), classes.value], style: style2.value, }, slots ) }, }) const ElCol = withInstall(Col) const emitChangeFn = (value2) => typeof isNumber$h(value2) const collapseProps = buildProps({ accordion: Boolean, modelValue: { type: definePropType([Array, String, Number]), default: () => mutable([]), }, }) const collapseEmits = { [UPDATE_MODEL_EVENT]: emitChangeFn, [CHANGE_EVENT]: emitChangeFn, } const __default__$s = { name: 'ElCollapse', } const _sfc_main$8G = /* @__PURE__ */ defineComponent({ ...__default__$s, props: collapseProps, emits: collapseEmits, setup(__props2, { expose, emit: emit2 }) { const props2 = __props2 const ns = useNamespace('collapse') const activeNames = ref(castArray$1(props2.modelValue)) const setActiveNames = (_activeNames) => { activeNames.value = _activeNames const value2 = props2.accordion ? activeNames.value[0] : activeNames.value emit2(UPDATE_MODEL_EVENT, value2) emit2(CHANGE_EVENT, value2) } const handleItemClick = (name2) => { if (props2.accordion) { setActiveNames([ (activeNames.value[0] || activeNames.value[0] === 0) && activeNames.value[0] === name2 ? '' : name2, ]) } else { const _activeNames = [...activeNames.value] const index2 = _activeNames.indexOf(name2) if (index2 > -1) { _activeNames.splice(index2, 1) } else { _activeNames.push(name2) } setActiveNames(_activeNames) } } watch$1( () => props2.modelValue, () => (activeNames.value = castArray$1(props2.modelValue)), { deep: true } ) provide(collapseContextKey, { activeNames, handleItemClick, }) expose({ activeNames, setActiveNames, }) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { class: normalizeClass(unref(ns).b()), role: 'tablist', 'aria-multiselectable': 'true', }, [renderSlot(_ctx.$slots, 'default')], 2 ) ) } }, }) var Collapse = /* @__PURE__ */ _export_sfc$1(_sfc_main$8G, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/collapse/src/collapse.vue', ], ]) const _sfc_main$8F = defineComponent({ name: 'ElCollapseTransition', setup() { const ns = useNamespace('collapse-transition') return { ns, on: { beforeEnter(el2) { if (!el2.dataset) el2.dataset = {} el2.dataset.oldPaddingTop = el2.style.paddingTop el2.dataset.oldPaddingBottom = el2.style.paddingBottom el2.style.maxHeight = 0 el2.style.paddingTop = 0 el2.style.paddingBottom = 0 }, enter(el2) { el2.dataset.oldOverflow = el2.style.overflow if (el2.scrollHeight !== 0) { el2.style.maxHeight = `${el2.scrollHeight}px` el2.style.paddingTop = el2.dataset.oldPaddingTop el2.style.paddingBottom = el2.dataset.oldPaddingBottom } else { el2.style.maxHeight = 0 el2.style.paddingTop = el2.dataset.oldPaddingTop el2.style.paddingBottom = el2.dataset.oldPaddingBottom } el2.style.overflow = 'hidden' }, afterEnter(el2) { el2.style.maxHeight = '' el2.style.overflow = el2.dataset.oldOverflow }, beforeLeave(el2) { if (!el2.dataset) el2.dataset = {} el2.dataset.oldPaddingTop = el2.style.paddingTop el2.dataset.oldPaddingBottom = el2.style.paddingBottom el2.dataset.oldOverflow = el2.style.overflow el2.style.maxHeight = `${el2.scrollHeight}px` el2.style.overflow = 'hidden' }, leave(el2) { if (el2.scrollHeight !== 0) { el2.style.maxHeight = 0 el2.style.paddingTop = 0 el2.style.paddingBottom = 0 } }, afterLeave(el2) { el2.style.maxHeight = '' el2.style.overflow = el2.dataset.oldOverflow el2.style.paddingTop = el2.dataset.oldPaddingTop el2.style.paddingBottom = el2.dataset.oldPaddingBottom }, }, } }, }) function _sfc_render$1p(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createBlock( Transition, mergeProps( { name: _ctx.ns.b(), }, toHandlers(_ctx.on) ), { default: withCtx(() => [renderSlot(_ctx.$slots, 'default')]), _: 3, }, 16, ['name'] ) ) } var CollapseTransition = /* @__PURE__ */ _export_sfc$1(_sfc_main$8F, [ ['render', _sfc_render$1p], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/collapse-transition/src/collapse-transition.vue', ], ]) CollapseTransition.install = (app2) => { app2.component(CollapseTransition.name, CollapseTransition) } const _CollapseTransition = CollapseTransition const ElCollapseTransition = _CollapseTransition const collapseItemProps = buildProps({ title: { type: String, default: '', }, name: { type: definePropType([String, Number]), default: () => generateId(), }, disabled: Boolean, }) const _hoisted_1$6J = ['aria-expanded', 'aria-controls', 'aria-describedby'] const _hoisted_2$5o = ['id', 'tabindex', 'onKeypress'] const _hoisted_3$4M = ['id', 'aria-hidden', 'aria-labelledby'] const __default__$r = { name: 'ElCollapseItem', } const _sfc_main$8E = /* @__PURE__ */ defineComponent({ ...__default__$r, props: collapseItemProps, setup(__props2, { expose }) { const props2 = __props2 const collapse2 = inject(collapseContextKey) const ns = useNamespace('collapse') const focusing = ref(false) const isClick = ref(false) const id2 = ref(generateId()) const isActive = computed(() => collapse2 == null ? void 0 : collapse2.activeNames.value.includes(props2.name) ) const handleFocus = () => { setTimeout(() => { if (!isClick.value) { focusing.value = true } else { isClick.value = false } }, 50) } const handleHeaderClick = () => { if (props2.disabled) return collapse2 == null ? void 0 : collapse2.handleItemClick(props2.name) focusing.value = false isClick.value = true } const handleEnterClick = () => { collapse2 == null ? void 0 : collapse2.handleItemClick(props2.name) } expose({ isActive, }) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { class: normalizeClass([ unref(ns).b('item'), unref(ns).is('active', unref(isActive)), unref(ns).is('disabled', _ctx.disabled), ]), }, [ createElementVNode( 'div', { role: 'tab', 'aria-expanded': unref(isActive), 'aria-controls': unref(ns).b(`content-${id2.value}`), 'aria-describedby': unref(ns).b(`content-${id2.value}`), }, [ createElementVNode( 'div', { id: unref(ns).b(`head-${id2.value}`), class: normalizeClass([ unref(ns).be('item', 'header'), unref(ns).is('active', unref(isActive)), { focusing: focusing.value }, ]), role: 'button', tabindex: _ctx.disabled ? -1 : 0, onClick: handleHeaderClick, onKeypress: withKeys( withModifiers(handleEnterClick, ['stop', 'prevent']), ['space', 'enter'] ), onFocus: handleFocus, onBlur: _cache[0] || (_cache[0] = ($event) => (focusing.value = false)), }, [ renderSlot(_ctx.$slots, 'title', {}, () => [ createTextVNode(toDisplayString$1(_ctx.title), 1), ]), createVNode$1( unref(ElIcon), { class: normalizeClass([ unref(ns).be('item', 'arrow'), unref(ns).is('active', unref(isActive)), ]), }, { default: withCtx(() => [ createVNode$1(unref(arrowRight)), ]), _: 1, }, 8, ['class'] ), ], 42, _hoisted_2$5o ), ], 8, _hoisted_1$6J ), createVNode$1(unref(_CollapseTransition), null, { default: withCtx(() => [ withDirectives( createElementVNode( 'div', { id: unref(ns).b(`content-${id2.value}`), class: normalizeClass(unref(ns).be('item', 'wrap')), role: 'tabpanel', 'aria-hidden': !unref(isActive), 'aria-labelledby': unref(ns).b(`head-${id2.value}`), }, [ createElementVNode( 'div', { class: normalizeClass( unref(ns).be('item', 'content') ), }, [renderSlot(_ctx.$slots, 'default')], 2 ), ], 10, _hoisted_3$4M ), [[vShow, unref(isActive)]] ), ]), _: 3, }), ], 2 ) ) } }, }) var CollapseItem = /* @__PURE__ */ _export_sfc$1(_sfc_main$8E, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/collapse/src/collapse-item.vue', ], ]) const ElCollapse = withInstall(Collapse, { CollapseItem, }) const ElCollapseItem = withNoopInstall(CollapseItem) let isDragging = false function draggable$2(element, options2) { if (!isClient$1) return const moveFn = function (event) { var _a2 ;(_a2 = options2.drag) == null ? void 0 : _a2.call(options2, event) } const upFn = function (event) { var _a2 off$1(document, 'mousemove', moveFn) off$1(document, 'mouseup', upFn) off$1(document, 'touchmove', moveFn) off$1(document, 'touchend', upFn) document.onselectstart = null document.ondragstart = null isDragging = false ;(_a2 = options2.end) == null ? void 0 : _a2.call(options2, event) } const downFn = function (event) { var _a2 if (isDragging) return event.preventDefault() document.onselectstart = () => false document.ondragstart = () => false on$2(document, 'mousemove', moveFn) on$2(document, 'mouseup', upFn) on$2(document, 'touchmove', moveFn) on$2(document, 'touchend', upFn) isDragging = true ;(_a2 = options2.start) == null ? void 0 : _a2.call(options2, event) } on$2(element, 'mousedown', downFn) on$2(element, 'touchstart', downFn) } const _sfc_main$8D = defineComponent({ name: 'ElColorAlphaSlider', props: { color: { type: Object, required: true, }, vertical: { type: Boolean, default: false, }, }, setup(props2) { const instance = getCurrentInstance() const thumb = shallowRef(null) const bar = shallowRef(null) const thumbLeft = ref(0) const thumbTop = ref(0) const background = ref(null) watch$1( () => props2.color.get('alpha'), () => { update3() } ) watch$1( () => props2.color.value, () => { update3() } ) function getThumbLeft() { if (props2.vertical) return 0 const el2 = instance.vnode.el const alpha = props2.color.get('alpha') if (!el2) return 0 return Math.round( (alpha * (el2.offsetWidth - thumb.value.offsetWidth / 2)) / 100 ) } function getThumbTop() { const el2 = instance.vnode.el if (!props2.vertical) return 0 const alpha = props2.color.get('alpha') if (!el2) return 0 return Math.round( (alpha * (el2.offsetHeight - thumb.value.offsetHeight / 2)) / 100 ) } function getBackground() { if (props2.color && props2.color.value) { const { r: r2, g: g2, b: b2 } = props2.color.toRgb() return `linear-gradient(to right, rgba(${r2}, ${g2}, ${b2}, 0) 0%, rgba(${r2}, ${g2}, ${b2}, 1) 100%)` } return null } function handleClick2(event) { const target2 = event.target if (target2 !== thumb.value) { handleDrag(event) } } function handleDrag(event) { const el2 = instance.vnode.el const rect = el2.getBoundingClientRect() const { clientX, clientY } = getClientXY(event) if (!props2.vertical) { let left2 = clientX - rect.left left2 = Math.max(thumb.value.offsetWidth / 2, left2) left2 = Math.min(left2, rect.width - thumb.value.offsetWidth / 2) props2.color.set( 'alpha', Math.round( ((left2 - thumb.value.offsetWidth / 2) / (rect.width - thumb.value.offsetWidth)) * 100 ) ) } else { let top2 = clientY - rect.top top2 = Math.max(thumb.value.offsetHeight / 2, top2) top2 = Math.min(top2, rect.height - thumb.value.offsetHeight / 2) props2.color.set( 'alpha', Math.round( ((top2 - thumb.value.offsetHeight / 2) / (rect.height - thumb.value.offsetHeight)) * 100 ) ) } } function update3() { thumbLeft.value = getThumbLeft() thumbTop.value = getThumbTop() background.value = getBackground() } onMounted(() => { const dragConfig = { drag: (event) => { handleDrag(event) }, end: (event) => { handleDrag(event) }, } draggable$2(bar.value, dragConfig) draggable$2(thumb.value, dragConfig) update3() }) return { thumb, bar, thumbLeft, thumbTop, background, handleClick: handleClick2, update: update3, } }, }) function _sfc_render$1o(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock( 'div', { class: normalizeClass([ 'el-color-alpha-slider', { 'is-vertical': _ctx.vertical }, ]), }, [ createElementVNode( 'div', { ref: 'bar', class: 'el-color-alpha-slider__bar', style: normalizeStyle$1({ background: _ctx.background, }), onClick: _cache[0] || (_cache[0] = (...args) => _ctx.handleClick && _ctx.handleClick(...args)), }, null, 4 ), createElementVNode( 'div', { ref: 'thumb', class: 'el-color-alpha-slider__thumb', style: normalizeStyle$1({ left: _ctx.thumbLeft + 'px', top: _ctx.thumbTop + 'px', }), }, null, 4 ), ], 2 ) ) } var AlphaSlider = /* @__PURE__ */ _export_sfc$1(_sfc_main$8D, [ ['render', _sfc_render$1o], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/color-picker/src/components/alpha-slider.vue', ], ]) const _sfc_main$8C = defineComponent({ name: 'ElColorHueSlider', props: { color: { type: Object, required: true, }, vertical: Boolean, }, setup(props2) { const instance = getCurrentInstance() const thumb = ref(null) const bar = ref(null) const thumbLeft = ref(0) const thumbTop = ref(0) const hueValue = computed(() => { return props2.color.get('hue') }) watch$1( () => hueValue.value, () => { update3() } ) function handleClick2(event) { const target2 = event.target if (target2 !== thumb.value) { handleDrag(event) } } function handleDrag(event) { const el2 = instance.vnode.el const rect = el2.getBoundingClientRect() const { clientX, clientY } = getClientXY(event) let hue if (!props2.vertical) { let left2 = clientX - rect.left left2 = Math.min(left2, rect.width - thumb.value.offsetWidth / 2) left2 = Math.max(thumb.value.offsetWidth / 2, left2) hue = Math.round( ((left2 - thumb.value.offsetWidth / 2) / (rect.width - thumb.value.offsetWidth)) * 360 ) } else { let top2 = clientY - rect.top top2 = Math.min(top2, rect.height - thumb.value.offsetHeight / 2) top2 = Math.max(thumb.value.offsetHeight / 2, top2) hue = Math.round( ((top2 - thumb.value.offsetHeight / 2) / (rect.height - thumb.value.offsetHeight)) * 360 ) } props2.color.set('hue', hue) } function getThumbLeft() { const el2 = instance.vnode.el if (props2.vertical) return 0 const hue = props2.color.get('hue') if (!el2) return 0 return Math.round( (hue * (el2.offsetWidth - thumb.value.offsetWidth / 2)) / 360 ) } function getThumbTop() { const el2 = instance.vnode.el if (!props2.vertical) return 0 const hue = props2.color.get('hue') if (!el2) return 0 return Math.round( (hue * (el2.offsetHeight - thumb.value.offsetHeight / 2)) / 360 ) } function update3() { thumbLeft.value = getThumbLeft() thumbTop.value = getThumbTop() } onMounted(() => { const dragConfig = { drag: (event) => { handleDrag(event) }, end: (event) => { handleDrag(event) }, } draggable$2(bar.value, dragConfig) draggable$2(thumb.value, dragConfig) update3() }) return { bar, thumb, thumbLeft, thumbTop, hueValue, handleClick: handleClick2, update: update3, } }, }) function _sfc_render$1n(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock( 'div', { class: normalizeClass([ 'el-color-hue-slider', { 'is-vertical': _ctx.vertical }, ]), }, [ createElementVNode( 'div', { ref: 'bar', class: 'el-color-hue-slider__bar', onClick: _cache[0] || (_cache[0] = (...args) => _ctx.handleClick && _ctx.handleClick(...args)), }, null, 512 ), createElementVNode( 'div', { ref: 'thumb', class: 'el-color-hue-slider__thumb', style: normalizeStyle$1({ left: _ctx.thumbLeft + 'px', top: _ctx.thumbTop + 'px', }), }, null, 4 ), ], 2 ) ) } var HueSlider = /* @__PURE__ */ _export_sfc$1(_sfc_main$8C, [ ['render', _sfc_render$1n], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/color-picker/src/components/hue-slider.vue', ], ]) const OPTIONS_KEY = Symbol() const useOptions = () => { return inject(OPTIONS_KEY) } const hsv2hsl = function (hue, sat, val2) { return [ hue, (sat * val2) / ((hue = (2 - sat) * val2) < 1 ? hue : 2 - hue) || 0, hue / 2, ] } const isOnePointZero = function (n2) { return ( typeof n2 === 'string' && n2.includes('.') && Number.parseFloat(n2) === 1 ) } const isPercentage = function (n2) { return typeof n2 === 'string' && n2.includes('%') } const bound01 = function (value2, max3) { if (isOnePointZero(value2)) value2 = '100%' const processPercent = isPercentage(value2) value2 = Math.min(max3, Math.max(0, Number.parseFloat(`${value2}`))) if (processPercent) { value2 = Number.parseInt(`${value2 * max3}`, 10) / 100 } if (Math.abs(value2 - max3) < 1e-6) { return 1 } return (value2 % max3) / Number.parseFloat(max3) } const INT_HEX_MAP = { 10: 'A', 11: 'B', 12: 'C', 13: 'D', 14: 'E', 15: 'F' } const hexOne = function (value2) { value2 = Math.min(Math.round(value2), 255) const high = Math.floor(value2 / 16) const low = value2 % 16 return `${INT_HEX_MAP[high] || high}${INT_HEX_MAP[low] || low}` } const toHex$1 = function ({ r: r2, g: g2, b: b2 }) { if (Number.isNaN(+r2) || Number.isNaN(+g2) || Number.isNaN(+b2)) return '' return `#${hexOne(r2)}${hexOne(g2)}${hexOne(b2)}` } const HEX_INT_MAP = { A: 10, B: 11, C: 12, D: 13, E: 14, F: 15 } const parseHexChannel = function (hex2) { if (hex2.length === 2) { return ( (HEX_INT_MAP[hex2[0].toUpperCase()] || +hex2[0]) * 16 + (HEX_INT_MAP[hex2[1].toUpperCase()] || +hex2[1]) ) } return HEX_INT_MAP[hex2[1].toUpperCase()] || +hex2[1] } const hsl2hsv = function (hue, sat, light) { sat = sat / 100 light = light / 100 let smin = sat const lmin = Math.max(light, 0.01) light *= 2 sat *= light <= 1 ? light : 2 - light smin *= lmin <= 1 ? lmin : 2 - lmin const v4 = (light + sat) / 2 const sv2 = light === 0 ? (2 * smin) / (lmin + smin) : (2 * sat) / (light + sat) return { h: hue, s: sv2 * 100, v: v4 * 100, } } const rgb2hsv = function (r2, g2, b2) { r2 = bound01(r2, 255) g2 = bound01(g2, 255) b2 = bound01(b2, 255) const max3 = Math.max(r2, g2, b2) const min3 = Math.min(r2, g2, b2) let h2 const v4 = max3 const d3 = max3 - min3 const s2 = max3 === 0 ? 0 : d3 / max3 if (max3 === min3) { h2 = 0 } else { switch (max3) { case r2: { h2 = (g2 - b2) / d3 + (g2 < b2 ? 6 : 0) break } case g2: { h2 = (b2 - r2) / d3 + 2 break } case b2: { h2 = (r2 - g2) / d3 + 4 break } } h2 /= 6 } return { h: h2 * 360, s: s2 * 100, v: v4 * 100 } } const hsv2rgb = function (h2, s2, v4) { h2 = bound01(h2, 360) * 6 s2 = bound01(s2, 100) v4 = bound01(v4, 100) const i2 = Math.floor(h2) const f2 = h2 - i2 const p2 = v4 * (1 - s2) const q2 = v4 * (1 - f2 * s2) const t3 = v4 * (1 - (1 - f2) * s2) const mod = i2 % 6 const r2 = [v4, q2, p2, p2, t3, v4][mod] const g2 = [t3, v4, v4, q2, p2, p2][mod] const b2 = [p2, p2, t3, v4, v4, q2][mod] return { r: Math.round(r2 * 255), g: Math.round(g2 * 255), b: Math.round(b2 * 255), } } class Color { constructor(options2) { this._hue = 0 this._saturation = 100 this._value = 100 this._alpha = 100 this.enableAlpha = false this.format = 'hex' this.value = '' options2 = options2 || {} for (const option2 in options2) { if (hasOwn$e(options2, option2)) { this[option2] = options2[option2] } } if (options2.value) { this.fromString(options2.value) } else { this.doOnChange() } } set(prop, value2) { if (arguments.length === 1 && typeof prop === 'object') { for (const p2 in prop) { if (hasOwn$e(prop, p2)) { this.set(p2, prop[p2]) } } return } this[`_${prop}`] = value2 this.doOnChange() } get(prop) { if (prop === 'alpha') { return Math.floor(this[`_${prop}`]) } return this[`_${prop}`] } toRgb() { return hsv2rgb(this._hue, this._saturation, this._value) } fromString(value2) { if (!value2) { this._hue = 0 this._saturation = 100 this._value = 100 this.doOnChange() return } const fromHSV = (h2, s2, v4) => { this._hue = Math.max(0, Math.min(360, h2)) this._saturation = Math.max(0, Math.min(100, s2)) this._value = Math.max(0, Math.min(100, v4)) this.doOnChange() } if (value2.includes('hsl')) { const parts = value2 .replace(/hsla|hsl|\(|\)/gm, '') .split(/\s|,/g) .filter((val2) => val2 !== '') .map((val2, index2) => index2 > 2 ? Number.parseFloat(val2) : Number.parseInt(val2, 10) ) if (parts.length === 4) { this._alpha = Number.parseFloat(parts[3]) * 100 } else if (parts.length === 3) { this._alpha = 100 } if (parts.length >= 3) { const { h: h2, s: s2, v: v4 } = hsl2hsv(parts[0], parts[1], parts[2]) fromHSV(h2, s2, v4) } } else if (value2.includes('hsv')) { const parts = value2 .replace(/hsva|hsv|\(|\)/gm, '') .split(/\s|,/g) .filter((val2) => val2 !== '') .map((val2, index2) => index2 > 2 ? Number.parseFloat(val2) : Number.parseInt(val2, 10) ) if (parts.length === 4) { this._alpha = Number.parseFloat(parts[3]) * 100 } else if (parts.length === 3) { this._alpha = 100 } if (parts.length >= 3) { fromHSV(parts[0], parts[1], parts[2]) } } else if (value2.includes('rgb')) { const parts = value2 .replace(/rgba|rgb|\(|\)/gm, '') .split(/\s|,/g) .filter((val2) => val2 !== '') .map((val2, index2) => index2 > 2 ? Number.parseFloat(val2) : Number.parseInt(val2, 10) ) if (parts.length === 4) { this._alpha = Number.parseFloat(parts[3]) * 100 } else if (parts.length === 3) { this._alpha = 100 } if (parts.length >= 3) { const { h: h2, s: s2, v: v4 } = rgb2hsv(parts[0], parts[1], parts[2]) fromHSV(h2, s2, v4) } } else if (value2.includes('#')) { const hex2 = value2.replace('#', '').trim() if (!/^[0-9a-fA-F]{3}$|^[0-9a-fA-F]{6}$|^[0-9a-fA-F]{8}$/.test(hex2)) return let r2, g2, b2 if (hex2.length === 3) { r2 = parseHexChannel(hex2[0] + hex2[0]) g2 = parseHexChannel(hex2[1] + hex2[1]) b2 = parseHexChannel(hex2[2] + hex2[2]) } else if (hex2.length === 6 || hex2.length === 8) { r2 = parseHexChannel(hex2.slice(0, 2)) g2 = parseHexChannel(hex2.slice(2, 4)) b2 = parseHexChannel(hex2.slice(4, 6)) } if (hex2.length === 8) { this._alpha = (parseHexChannel(hex2.slice(6)) / 255) * 100 } else if (hex2.length === 3 || hex2.length === 6) { this._alpha = 100 } const { h: h2, s: s2, v: v4 } = rgb2hsv(r2, g2, b2) fromHSV(h2, s2, v4) } } compare(color2) { return ( Math.abs(color2._hue - this._hue) < 2 && Math.abs(color2._saturation - this._saturation) < 1 && Math.abs(color2._value - this._value) < 1 && Math.abs(color2._alpha - this._alpha) < 1 ) } doOnChange() { const { _hue, _saturation, _value, _alpha, format: format2 } = this if (this.enableAlpha) { switch (format2) { case 'hsl': { const hsl2 = hsv2hsl(_hue, _saturation / 100, _value / 100) this.value = `hsla(${_hue}, ${Math.round( hsl2[1] * 100 )}%, ${Math.round(hsl2[2] * 100)}%, ${this.get('alpha') / 100})` break } case 'hsv': { this.value = `hsva(${_hue}, ${Math.round(_saturation)}%, ${Math.round( _value )}%, ${this.get('alpha') / 100})` break } case 'hex': { this.value = `${toHex$1(hsv2rgb(_hue, _saturation, _value))}${hexOne( (_alpha * 255) / 100 )}` break } default: { const { r: r2, g: g2, b: b2 } = hsv2rgb(_hue, _saturation, _value) this.value = `rgba(${r2}, ${g2}, ${b2}, ${this.get('alpha') / 100})` } } } else { switch (format2) { case 'hsl': { const hsl2 = hsv2hsl(_hue, _saturation / 100, _value / 100) this.value = `hsl(${_hue}, ${Math.round( hsl2[1] * 100 )}%, ${Math.round(hsl2[2] * 100)}%)` break } case 'hsv': { this.value = `hsv(${_hue}, ${Math.round(_saturation)}%, ${Math.round( _value )}%)` break } case 'rgb': { const { r: r2, g: g2, b: b2 } = hsv2rgb(_hue, _saturation, _value) this.value = `rgb(${r2}, ${g2}, ${b2})` break } default: { this.value = toHex$1(hsv2rgb(_hue, _saturation, _value)) } } } } } const _sfc_main$8B = defineComponent({ props: { colors: { type: Array, required: true }, color: { type: Object, required: true, }, }, setup(props2) { const { currentColor } = useOptions() const rgbaColors = ref(parseColors(props2.colors, props2.color)) watch$1( () => currentColor.value, (val2) => { const color2 = new Color() color2.fromString(val2) rgbaColors.value.forEach((item2) => { item2.selected = color2.compare(item2) }) } ) watchEffect(() => { rgbaColors.value = parseColors(props2.colors, props2.color) }) function handleSelect(index2) { props2.color.fromString(props2.colors[index2]) } function parseColors(colors, color2) { return colors.map((value2) => { const c2 = new Color() c2.enableAlpha = true c2.format = 'rgba' c2.fromString(value2) c2.selected = c2.value === color2.value return c2 }) } return { rgbaColors, handleSelect, } }, }) const _hoisted_1$6I = { class: 'el-color-predefine' } const _hoisted_2$5n = { class: 'el-color-predefine__colors' } const _hoisted_3$4L = ['onClick'] function _sfc_render$1m(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock('div', _hoisted_1$6I, [ createElementVNode('div', _hoisted_2$5n, [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.rgbaColors, (item2, index2) => { return ( openBlock(), createElementBlock( 'div', { key: _ctx.colors[index2], class: normalizeClass([ 'el-color-predefine__color-selector', { selected: item2.selected, 'is-alpha': item2._alpha < 100, }, ]), onClick: ($event) => _ctx.handleSelect(index2), }, [ createElementVNode( 'div', { style: normalizeStyle$1({ backgroundColor: item2.value }), }, null, 4 ), ], 10, _hoisted_3$4L ) ) }), 128 )), ]), ]) ) } var Predefine = /* @__PURE__ */ _export_sfc$1(_sfc_main$8B, [ ['render', _sfc_render$1m], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/color-picker/src/components/predefine.vue', ], ]) const _sfc_main$8A = defineComponent({ name: 'ElSlPanel', props: { color: { type: Object, required: true, }, }, setup(props2) { const instance = getCurrentInstance() const cursorTop = ref(0) const cursorLeft = ref(0) const background = ref('hsl(0, 100%, 50%)') const colorValue = computed(() => { const hue = props2.color.get('hue') const value2 = props2.color.get('value') return { hue, value: value2 } }) function update3() { const saturation = props2.color.get('saturation') const value2 = props2.color.get('value') const el2 = instance.vnode.el const { clientWidth: width, clientHeight: height } = el2 cursorLeft.value = (saturation * width) / 100 cursorTop.value = ((100 - value2) * height) / 100 background.value = `hsl(${props2.color.get('hue')}, 100%, 50%)` } function handleDrag(event) { const el2 = instance.vnode.el const rect = el2.getBoundingClientRect() const { clientX, clientY } = getClientXY(event) let left2 = clientX - rect.left let top2 = clientY - rect.top left2 = Math.max(0, left2) left2 = Math.min(left2, rect.width) top2 = Math.max(0, top2) top2 = Math.min(top2, rect.height) cursorLeft.value = left2 cursorTop.value = top2 props2.color.set({ saturation: (left2 / rect.width) * 100, value: 100 - (top2 / rect.height) * 100, }) } watch$1( () => colorValue.value, () => { update3() } ) onMounted(() => { draggable$2(instance.vnode.el, { drag: (event) => { handleDrag(event) }, end: (event) => { handleDrag(event) }, }) update3() }) return { cursorTop, cursorLeft, background, colorValue, handleDrag, update: update3, } }, }) const _hoisted_1$6H = /* @__PURE__ */ createElementVNode( 'div', { class: 'el-color-svpanel__white' }, null, -1 ) const _hoisted_2$5m = /* @__PURE__ */ createElementVNode( 'div', { class: 'el-color-svpanel__black' }, null, -1 ) const _hoisted_3$4K = /* @__PURE__ */ createElementVNode('div', null, null, -1) const _hoisted_4$46 = [_hoisted_3$4K] function _sfc_render$1l(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock( 'div', { class: 'el-color-svpanel', style: normalizeStyle$1({ backgroundColor: _ctx.background, }), }, [ _hoisted_1$6H, _hoisted_2$5m, createElementVNode( 'div', { class: 'el-color-svpanel__cursor', style: normalizeStyle$1({ top: _ctx.cursorTop + 'px', left: _ctx.cursorLeft + 'px', }), }, _hoisted_4$46, 4 ), ], 4 ) ) } var SvPanel = /* @__PURE__ */ _export_sfc$1(_sfc_main$8A, [ ['render', _sfc_render$1l], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/color-picker/src/components/sv-panel.vue', ], ]) const _sfc_main$8z = defineComponent({ name: 'ElColorPicker', components: { ElButton, ElTooltip, ElInput, ElIcon, Close: close$2, ArrowDown: arrowDown, SvPanel, HueSlider, AlphaSlider, Predefine, }, directives: { ClickOutside, }, props: { modelValue: String, showAlpha: Boolean, colorFormat: String, disabled: Boolean, size: { type: String, validator: isValidComponentSize, }, popperClass: String, predefine: Array, }, emits: ['change', 'active-change', UPDATE_MODEL_EVENT], setup(props2, { emit: emit2 }) { const { t: t3 } = useLocale() const ns = useNamespace('color') const elForm = inject(formContextKey, {}) const elFormItem = inject(formItemContextKey, {}) const hue = ref(null) const svPanel = ref(null) const alpha = ref(null) const popper2 = ref(null) const color2 = reactive( new Color({ enableAlpha: props2.showAlpha, format: props2.colorFormat, value: props2.modelValue, }) ) const showPicker = ref(false) const showPanelColor = ref(false) const customInput = ref('') const displayedColor = computed(() => { if (!props2.modelValue && !showPanelColor.value) { return 'transparent' } return displayedRgb(color2, props2.showAlpha) }) const colorSize = useSize$1() const colorDisabled = computed(() => { return !!(props2.disabled || elForm.disabled) }) const currentColor = computed(() => { return !props2.modelValue && !showPanelColor.value ? '' : color2.value }) watch$1( () => props2.modelValue, (newVal) => { if (!newVal) { showPanelColor.value = false } else if (newVal && newVal !== color2.value) { color2.fromString(newVal) } } ) watch$1( () => currentColor.value, (val2) => { customInput.value = val2 emit2('active-change', val2) } ) watch$1( () => color2.value, () => { if (!props2.modelValue && !showPanelColor.value) { showPanelColor.value = true } } ) function displayedRgb(color22, showAlpha) { if (!(color22 instanceof Color)) { throw new TypeError('color should be instance of _color Class') } const { r: r2, g: g2, b: b2 } = color22.toRgb() return showAlpha ? `rgba(${r2}, ${g2}, ${b2}, ${color22.get('alpha') / 100})` : `rgb(${r2}, ${g2}, ${b2})` } function setShowPicker(value2) { showPicker.value = value2 } const debounceSetShowPicker = debounce$3(setShowPicker, 100) function hide2() { debounceSetShowPicker(false) resetColor() } function resetColor() { nextTick(() => { if (props2.modelValue) { color2.fromString(props2.modelValue) } else { showPanelColor.value = false } }) } function handleTrigger() { if (colorDisabled.value) return debounceSetShowPicker(!showPicker.value) } function handleConfirm() { color2.fromString(customInput.value) } function confirmValue() { var _a2 const value2 = color2.value emit2(UPDATE_MODEL_EVENT, value2) emit2('change', value2) ;(_a2 = elFormItem.validate) == null ? void 0 : _a2.call(elFormItem, 'change').catch((err) => debugWarn()) debounceSetShowPicker(false) nextTick(() => { const newColor = new Color({ enableAlpha: props2.showAlpha, format: props2.colorFormat, value: props2.modelValue, }) if (!color2.compare(newColor)) { resetColor() } }) } function clear2() { var _a2 debounceSetShowPicker(false) emit2(UPDATE_MODEL_EVENT, null) emit2('change', null) if (props2.modelValue !== null) { ;(_a2 = elFormItem.validate) == null ? void 0 : _a2.call(elFormItem, 'change').catch((err) => debugWarn()) } resetColor() } onMounted(() => { if (props2.modelValue) { customInput.value = currentColor.value } }) watch$1( () => showPicker.value, () => { nextTick(() => { var _a2, _b2, _c2 ;(_a2 = hue.value) == null ? void 0 : _a2.update() ;(_b2 = svPanel.value) == null ? void 0 : _b2.update() ;(_c2 = alpha.value) == null ? void 0 : _c2.update() }) } ) provide(OPTIONS_KEY, { currentColor, }) return { color: color2, colorDisabled, colorSize, displayedColor, showPanelColor, showPicker, customInput, handleConfirm, hide: hide2, handleTrigger, clear: clear2, confirmValue, t: t3, ns, hue, svPanel, alpha, popper: popper2, } }, }) function _sfc_render$1k(_ctx, _cache, $props2, $setup, $data, $options) { const _component_hue_slider = resolveComponent('hue-slider') const _component_sv_panel = resolveComponent('sv-panel') const _component_alpha_slider = resolveComponent('alpha-slider') const _component_predefine = resolveComponent('predefine') const _component_el_input = resolveComponent('el-input') const _component_el_button = resolveComponent('el-button') const _component_arrow_down = resolveComponent('arrow-down') const _component_el_icon = resolveComponent('el-icon') const _component_close = resolveComponent('close') const _component_el_tooltip = resolveComponent('el-tooltip') const _directive_click_outside = resolveDirective('click-outside') return ( openBlock(), createBlock( _component_el_tooltip, { ref: 'popper', visible: _ctx.showPicker, 'onUpdate:visible': _cache[2] || (_cache[2] = ($event) => (_ctx.showPicker = $event)), 'show-arrow': false, 'fallback-placements': ['bottom', 'top', 'right', 'left'], offset: 0, 'gpu-acceleration': false, 'popper-class': [ _ctx.ns.be('picker', 'panel'), _ctx.ns.b('dropdown'), _ctx.popperClass, ], 'stop-popper-mouse-event': false, effect: 'light', trigger: 'click', transition: 'el-zoom-in-top', persistent: '', }, { content: withCtx(() => [ withDirectives( (openBlock(), createElementBlock('div', null, [ createElementVNode( 'div', { class: normalizeClass(_ctx.ns.be('dropdown', 'main-wrapper')), }, [ createVNode$1( _component_hue_slider, { ref: 'hue', class: 'hue-slider', color: _ctx.color, vertical: '', }, null, 8, ['color'] ), createVNode$1( _component_sv_panel, { ref: 'svPanel', color: _ctx.color, }, null, 8, ['color'] ), ], 2 ), _ctx.showAlpha ? (openBlock(), createBlock( _component_alpha_slider, { key: 0, ref: 'alpha', color: _ctx.color, }, null, 8, ['color'] )) : createCommentVNode('v-if', true), _ctx.predefine ? (openBlock(), createBlock( _component_predefine, { key: 1, ref: 'predefine', color: _ctx.color, colors: _ctx.predefine, }, null, 8, ['color', 'colors'] )) : createCommentVNode('v-if', true), createElementVNode( 'div', { class: normalizeClass(_ctx.ns.be('dropdown', 'btns')), }, [ createElementVNode( 'span', { class: normalizeClass(_ctx.ns.be('dropdown', 'value')), }, [ createVNode$1( _component_el_input, { modelValue: _ctx.customInput, 'onUpdate:modelValue': _cache[0] || (_cache[0] = ($event) => (_ctx.customInput = $event)), 'validate-event': false, size: 'small', onKeyup: withKeys(_ctx.handleConfirm, ['enter']), onBlur: _ctx.handleConfirm, }, null, 8, ['modelValue', 'onKeyup', 'onBlur'] ), ], 2 ), createVNode$1( _component_el_button, { size: 'small', type: 'text', class: normalizeClass(_ctx.ns.be('dropdown', 'link-btn')), onClick: _ctx.clear, }, { default: withCtx(() => [ createTextVNode( toDisplayString$1(_ctx.t('el.colorpicker.clear')), 1 ), ]), _: 1, }, 8, ['class', 'onClick'] ), createVNode$1( _component_el_button, { plain: '', size: 'small', class: normalizeClass(_ctx.ns.be('dropdown', 'btn')), onClick: _ctx.confirmValue, }, { default: withCtx(() => [ createTextVNode( toDisplayString$1(_ctx.t('el.colorpicker.confirm')), 1 ), ]), _: 1, }, 8, ['class', 'onClick'] ), ], 2 ), ])), [[_directive_click_outside, _ctx.hide]] ), ]), default: withCtx(() => [ createElementVNode( 'div', { class: normalizeClass([ _ctx.ns.b('picker'), _ctx.ns.is('disabled', _ctx.colorDisabled), _ctx.ns.bm('picker', _ctx.colorSize), ]), }, [ _ctx.colorDisabled ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass(_ctx.ns.be('picker', 'mask')), }, null, 2 )) : createCommentVNode('v-if', true), createElementVNode( 'div', { class: normalizeClass(_ctx.ns.be('picker', 'trigger')), onClick: _cache[1] || (_cache[1] = (...args) => _ctx.handleTrigger && _ctx.handleTrigger(...args)), }, [ createElementVNode( 'span', { class: normalizeClass([ _ctx.ns.be('picker', 'color'), _ctx.ns.is('alpha', _ctx.showAlpha), ]), }, [ createElementVNode( 'span', { class: normalizeClass( _ctx.ns.be('picker', 'color-inner') ), style: normalizeStyle$1({ backgroundColor: _ctx.displayedColor, }), }, [ withDirectives( createVNode$1( _component_el_icon, { class: normalizeClass([ _ctx.ns.be('picker', 'icon'), _ctx.ns.is('icon-arrow-down'), ]), }, { default: withCtx(() => [ createVNode$1(_component_arrow_down), ]), _: 1, }, 8, ['class'] ), [[vShow, _ctx.modelValue || _ctx.showPanelColor]] ), !_ctx.modelValue && !_ctx.showPanelColor ? (openBlock(), createBlock( _component_el_icon, { key: 0, class: normalizeClass([ _ctx.ns.be('picker', 'empty'), _ctx.ns.is('icon-close'), ]), }, { default: withCtx(() => [ createVNode$1(_component_close), ]), _: 1, }, 8, ['class'] )) : createCommentVNode('v-if', true), ], 6 ), ], 2 ), ], 2 ), ], 2 ), ]), _: 1, }, 8, ['visible', 'popper-class'] ) ) } var ColorPicker = /* @__PURE__ */ _export_sfc$1(_sfc_main$8z, [ ['render', _sfc_render$1k], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/color-picker/src/index.vue', ], ]) ColorPicker.install = (app2) => { app2.component(ColorPicker.name, ColorPicker) } const _ColorPicker = ColorPicker const ElColorPicker = _ColorPicker const messageConfig = {} const configProviderProps = buildProps({ a11y: { type: Boolean, default: true, }, locale: { type: definePropType(Object), }, size: { type: String, values: componentSizes, default: '', }, button: { type: definePropType(Object), }, experimentalFeatures: { type: definePropType(Object), }, keyboardNavigation: { type: Boolean, default: true, }, message: { type: definePropType(Object), }, zIndex: { type: Number, }, namespace: { type: String, default: 'el', }, }) var ConfigProvider = defineComponent({ name: 'ElConfigProvider', props: configProviderProps, setup(props2, { slots }) { watch$1( () => props2.message, (val2) => { Object.assign(messageConfig, val2 != null ? val2 : {}) }, { immediate: true, deep: true } ) const config2 = provideGlobalConfig(props2) return () => renderSlot(slots, 'default', { config: config2 == null ? void 0 : config2.value, }) }, }) const ElConfigProvider = withInstall(ConfigProvider) const _sfc_main$8y = defineComponent({ name: 'ElContainer', props: { direction: { type: String, default: '', }, }, setup(props2, { slots }) { const ns = useNamespace('container') const isVertical = computed(() => { if (props2.direction === 'vertical') { return true } else if (props2.direction === 'horizontal') { return false } if (slots && slots.default) { const vNodes = slots.default() return vNodes.some((vNode) => { const tag = vNode.type.name return tag === 'ElHeader' || tag === 'ElFooter' }) } else { return false } }) return { isVertical, ns, } }, }) function _sfc_render$1j(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock( 'section', { class: normalizeClass([ _ctx.ns.b(), _ctx.ns.is('vertical', _ctx.isVertical), ]), }, [renderSlot(_ctx.$slots, 'default')], 2 ) ) } var Container = /* @__PURE__ */ _export_sfc$1(_sfc_main$8y, [ ['render', _sfc_render$1j], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/container/src/container.vue', ], ]) const _sfc_main$8x = defineComponent({ name: 'ElAside', props: { width: { type: String, default: null, }, }, setup(props2) { const ns = useNamespace('aside') return { style: computed(() => { return props2.width ? { '--el-aside-width': props2.width } : {} }), ns, } }, }) function _sfc_render$1i(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock( 'aside', { class: normalizeClass(_ctx.ns.b()), style: normalizeStyle$1(_ctx.style), }, [renderSlot(_ctx.$slots, 'default')], 6 ) ) } var Aside = /* @__PURE__ */ _export_sfc$1(_sfc_main$8x, [ ['render', _sfc_render$1i], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/container/src/aside.vue', ], ]) const _sfc_main$8w = defineComponent({ name: 'ElFooter', props: { height: { type: String, default: null, }, }, setup(props2) { const ns = useNamespace('footer') return { style: computed(() => props2.height ? { '--el-footer-height': props2.height, } : {} ), ns, } }, }) function _sfc_render$1h(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock( 'footer', { class: normalizeClass(_ctx.ns.b()), style: normalizeStyle$1(_ctx.style), }, [renderSlot(_ctx.$slots, 'default')], 6 ) ) } var Footer$3 = /* @__PURE__ */ _export_sfc$1(_sfc_main$8w, [ ['render', _sfc_render$1h], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/container/src/footer.vue', ], ]) const _sfc_main$8v = defineComponent({ name: 'ElHeader', props: { height: { type: String, default: null, }, }, setup(props2) { const ns = useNamespace('header') return { style: computed(() => props2.height ? { '--el-header-height': props2.height, } : {} ), ns, } }, }) function _sfc_render$1g(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock( 'header', { class: normalizeClass(_ctx.ns.b()), style: normalizeStyle$1(_ctx.style), }, [renderSlot(_ctx.$slots, 'default')], 6 ) ) } var Header$7 = /* @__PURE__ */ _export_sfc$1(_sfc_main$8v, [ ['render', _sfc_render$1g], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/container/src/header.vue', ], ]) const _sfc_main$8u = defineComponent({ name: 'ElMain', setup() { const ns = useNamespace('main') return { ns, } }, }) function _sfc_render$1f(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock( 'main', { class: normalizeClass(_ctx.ns.b()), }, [renderSlot(_ctx.$slots, 'default')], 2 ) ) } var Main = /* @__PURE__ */ _export_sfc$1(_sfc_main$8u, [ ['render', _sfc_render$1f], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/container/src/main.vue', ], ]) const ElContainer = withInstall(Container, { Aside, Footer: Footer$3, Header: Header$7, Main, }) const ElAside = withNoopInstall(Aside) const ElFooter = withNoopInstall(Footer$3) const ElHeader = withNoopInstall(Header$7) const ElMain = withNoopInstall(Main) var advancedFormat$1 = { exports: {} } ;(function (module2, exports2) { !(function (e2, t3) { module2.exports = t3() })(commonjsGlobal, function () { return function (e2, t3) { var r2 = t3.prototype, n2 = r2.format r2.format = function (e3) { var t4 = this, r3 = this.$locale() if (!this.isValid()) return n2.bind(this)(e3) var s2 = this.$utils(), a2 = (e3 || 'YYYY-MM-DDTHH:mm:ssZ').replace( /\[([^\]]+)]|Q|wo|ww|w|WW|W|zzz|z|gggg|GGGG|Do|X|x|k{1,2}|S/g, function (e4) { switch (e4) { case 'Q': return Math.ceil((t4.$M + 1) / 3) case 'Do': return r3.ordinal(t4.$D) case 'gggg': return t4.weekYear() case 'GGGG': return t4.isoWeekYear() case 'wo': return r3.ordinal(t4.week(), 'W') case 'w': case 'ww': return s2.s(t4.week(), 'w' === e4 ? 1 : 2, '0') case 'W': case 'WW': return s2.s(t4.isoWeek(), 'W' === e4 ? 1 : 2, '0') case 'k': case 'kk': return s2.s( String(0 === t4.$H ? 24 : t4.$H), 'k' === e4 ? 1 : 2, '0' ) case 'X': return Math.floor(t4.$d.getTime() / 1e3) case 'x': return t4.$d.getTime() case 'z': return '[' + t4.offsetName() + ']' case 'zzz': return '[' + t4.offsetName('long') + ']' default: return e4 } } ) return n2.bind(this)(a2) } } }) })(advancedFormat$1) var advancedFormat = advancedFormat$1.exports var weekOfYear$1 = { exports: {} } ;(function (module2, exports2) { !(function (e2, t3) { module2.exports = t3() })(commonjsGlobal, function () { var e2 = 'week', t3 = 'year' return function (i2, n2, r2) { var f2 = n2.prototype ;(f2.week = function (i3) { if ((void 0 === i3 && (i3 = null), null !== i3)) return this.add(7 * (i3 - this.week()), 'day') var n3 = this.$locale().yearStart || 1 if (11 === this.month() && this.date() > 25) { var f3 = r2(this).startOf(t3).add(1, t3).date(n3), s2 = r2(this).endOf(e2) if (f3.isBefore(s2)) return 1 } var a2 = r2(this) .startOf(t3) .date(n3) .startOf(e2) .subtract(1, 'millisecond'), o2 = this.diff(a2, e2, true) return o2 < 0 ? r2(this).startOf('week').week() : Math.ceil(o2) }), (f2.weeks = function (e3) { return void 0 === e3 && (e3 = null), this.week(e3) }) } }) })(weekOfYear$1) var weekOfYear = weekOfYear$1.exports var weekYear$1 = { exports: {} } ;(function (module2, exports2) { !(function (e2, t3) { module2.exports = t3() })(commonjsGlobal, function () { return function (e2, t3) { t3.prototype.weekYear = function () { var e3 = this.month(), t4 = this.week(), n2 = this.year() return 1 === t4 && 11 === e3 ? n2 + 1 : 0 === e3 && t4 >= 52 ? n2 - 1 : n2 } } }) })(weekYear$1) var weekYear = weekYear$1.exports var dayOfYear$1 = { exports: {} } ;(function (module2, exports2) { !(function (e2, t3) { module2.exports = t3() })(commonjsGlobal, function () { return function (e2, t3, n2) { t3.prototype.dayOfYear = function (e3) { var t4 = Math.round( (n2(this).startOf('day') - n2(this).startOf('year')) / 864e5 ) + 1 return null == e3 ? t4 : this.add(e3 - t4, 'day') } } }) })(dayOfYear$1) var dayOfYear = dayOfYear$1.exports var isSameOrAfter$1 = { exports: {} } ;(function (module2, exports2) { !(function (e2, t3) { module2.exports = t3() })(commonjsGlobal, function () { return function (e2, t3) { t3.prototype.isSameOrAfter = function (e3, t4) { return this.isSame(e3, t4) || this.isAfter(e3, t4) } } }) })(isSameOrAfter$1) var isSameOrAfter = isSameOrAfter$1.exports var isSameOrBefore$1 = { exports: {} } ;(function (module2, exports2) { !(function (e2, i2) { module2.exports = i2() })(commonjsGlobal, function () { return function (e2, i2) { i2.prototype.isSameOrBefore = function (e3, i3) { return this.isSame(e3, i3) || this.isBefore(e3, i3) } } }) })(isSameOrBefore$1) var isSameOrBefore = isSameOrBefore$1.exports const ROOT_PICKER_INJECTION_KEY = Symbol() var ElDatePickerCell = defineComponent({ name: 'ElDatePickerCell', props: buildProps({ cell: { type: definePropType(Object), }, }), setup(props2) { const picker = inject(ROOT_PICKER_INJECTION_KEY) return () => { const cell = props2.cell if (picker == null ? void 0 : picker.ctx.slots.default) { const list2 = picker.ctx.slots.default(cell).filter((item2) => { return ( item2.patchFlag !== -2 && item2.type.toString() !== 'Symbol(Comment)' ) }) if (list2.length) { return list2 } } return h$4( 'div', { class: 'el-date-table-cell', }, [ h$4( 'span', { class: 'el-date-table-cell__text', }, [cell == null ? void 0 : cell.text] ), ] ) } }, }) const _sfc_main$8t = defineComponent({ components: { ElDatePickerCell, }, props: { date: { type: Object, }, minDate: { type: Object, }, maxDate: { type: Object, }, parsedValue: { type: [Object, Array], }, selectionMode: { type: String, default: 'day', }, showWeekNumber: { type: Boolean, default: false, }, disabledDate: { type: Function, }, cellClassName: { type: Function, }, rangeState: { type: Object, default: () => ({ endDate: null, selecting: false, }), }, }, emits: ['changerange', 'pick', 'select'], setup(props2, ctx) { const { t: t3, lang } = useLocale() const lastRow = ref(null) const lastColumn = ref(null) const tableRows = ref([[], [], [], [], [], []]) const firstDayOfWeek = props2.date.$locale().weekStart || 7 const WEEKS_CONSTANT = props2.date .locale('en') .localeData() .weekdaysShort() .map((_2) => _2.toLowerCase()) const offsetDay = computed(() => { return firstDayOfWeek > 3 ? 7 - firstDayOfWeek : -firstDayOfWeek }) const startDate = computed(() => { const startDayOfMonth = props2.date.startOf('month') return startDayOfMonth.subtract(startDayOfMonth.day() || 7, 'day') }) const WEEKS = computed(() => { return WEEKS_CONSTANT.concat(WEEKS_CONSTANT).slice( firstDayOfWeek, firstDayOfWeek + 7 ) }) const rows = computed(() => { var _a2 const startOfMonth = props2.date.startOf('month') const startOfMonthDay = startOfMonth.day() || 7 const dateCountOfMonth = startOfMonth.daysInMonth() const dateCountOfLastMonth = startOfMonth .subtract(1, 'month') .daysInMonth() const offset2 = offsetDay.value const rows_ = tableRows.value let count2 = 1 const selectedDate = props2.selectionMode === 'dates' ? castArray(props2.parsedValue) : [] const calNow = dayjs().locale(lang.value).startOf('day') for (let i2 = 0; i2 < 6; i2++) { const row = rows_[i2] if (props2.showWeekNumber) { if (!row[0]) { row[0] = { type: 'week', text: startDate.value.add(i2 * 7 + 1, 'day').week(), } } } for (let j2 = 0; j2 < 7; j2++) { let cell = row[props2.showWeekNumber ? j2 + 1 : j2] if (!cell) { cell = { row: i2, column: j2, type: 'normal', inRange: false, start: false, end: false, } } const index2 = i2 * 7 + j2 const calTime = startDate.value.add(index2 - offset2, 'day') cell.dayjs = calTime cell.date = calTime.toDate() cell.timestamp = calTime.valueOf() cell.type = 'normal' const calEndDate = props2.rangeState.endDate || props2.maxDate || (props2.rangeState.selecting && props2.minDate) cell.inRange = (props2.minDate && calTime.isSameOrAfter(props2.minDate, 'day') && calEndDate && calTime.isSameOrBefore(calEndDate, 'day')) || (props2.minDate && calTime.isSameOrBefore(props2.minDate, 'day') && calEndDate && calTime.isSameOrAfter(calEndDate, 'day')) if ( (_a2 = props2.minDate) == null ? void 0 : _a2.isSameOrAfter(calEndDate) ) { cell.start = calEndDate && calTime.isSame(calEndDate, 'day') cell.end = props2.minDate && calTime.isSame(props2.minDate, 'day') } else { cell.start = props2.minDate && calTime.isSame(props2.minDate, 'day') cell.end = calEndDate && calTime.isSame(calEndDate, 'day') } const isToday = calTime.isSame(calNow, 'day') if (isToday) { cell.type = 'today' } if (i2 >= 0 && i2 <= 1) { const numberOfDaysFromPreviousMonth = startOfMonthDay + offset2 < 0 ? 7 + startOfMonthDay + offset2 : startOfMonthDay + offset2 if (j2 + i2 * 7 >= numberOfDaysFromPreviousMonth) { cell.text = count2++ } else { cell.text = dateCountOfLastMonth - (numberOfDaysFromPreviousMonth - (j2 % 7)) + 1 + i2 * 7 cell.type = 'prev-month' } } else { if (count2 <= dateCountOfMonth) { cell.text = count2++ } else { cell.text = count2++ - dateCountOfMonth cell.type = 'next-month' } } const cellDate = calTime.toDate() cell.selected = selectedDate.find( (_2) => _2.valueOf() === calTime.valueOf() ) cell.isSelected = !!cell.selected cell.isCurrent = isCurrent(cell) cell.disabled = props2.disabledDate && props2.disabledDate(cellDate) cell.customClass = props2.cellClassName && props2.cellClassName(cellDate) row[props2.showWeekNumber ? j2 + 1 : j2] = cell } if (props2.selectionMode === 'week') { const start2 = props2.showWeekNumber ? 1 : 0 const end2 = props2.showWeekNumber ? 7 : 6 const isActive = isWeekActive(row[start2 + 1]) row[start2].inRange = isActive row[start2].start = isActive row[end2].inRange = isActive row[end2].end = isActive } } return rows_ }) const isCurrent = (cell) => { return ( props2.selectionMode === 'day' && (cell.type === 'normal' || cell.type === 'today') && cellMatchesDate(cell, props2.parsedValue) ) } const cellMatchesDate = (cell, date4) => { if (!date4) return false return dayjs(date4) .locale(lang.value) .isSame(props2.date.date(Number(cell.text)), 'day') } const getCellClasses = (cell) => { const classes = [] if ((cell.type === 'normal' || cell.type === 'today') && !cell.disabled) { classes.push('available') if (cell.type === 'today') { classes.push('today') } } else { classes.push(cell.type) } if (isCurrent(cell)) { classes.push('current') } if ( cell.inRange && (cell.type === 'normal' || cell.type === 'today' || props2.selectionMode === 'week') ) { classes.push('in-range') if (cell.start) { classes.push('start-date') } if (cell.end) { classes.push('end-date') } } if (cell.disabled) { classes.push('disabled') } if (cell.selected) { classes.push('selected') } if (cell.customClass) { classes.push(cell.customClass) } return classes.join(' ') } const getDateOfCell = (row, column) => { const offsetFromStart = row * 7 + (column - (props2.showWeekNumber ? 1 : 0)) - offsetDay.value return startDate.value.add(offsetFromStart, 'day') } const handleMouseMove = (event) => { if (!props2.rangeState.selecting) return let target2 = event.target if (target2.tagName === 'SPAN') { target2 = target2.parentNode.parentNode } if (target2.tagName === 'DIV') { target2 = target2.parentNode } if (target2.tagName !== 'TD') return const row = target2.parentNode.rowIndex - 1 const column = target2.cellIndex if (rows.value[row][column].disabled) return if (row !== lastRow.value || column !== lastColumn.value) { lastRow.value = row lastColumn.value = column ctx.emit('changerange', { selecting: true, endDate: getDateOfCell(row, column), }) } } const handleClick2 = (event) => { let target2 = event.target while (target2) { if (target2.tagName === 'TD') { break } target2 = target2.parentNode } if (!target2 || target2.tagName !== 'TD') return const row = target2.parentNode.rowIndex - 1 const column = target2.cellIndex const cell = rows.value[row][column] if (cell.disabled || cell.type === 'week') return const newDate = getDateOfCell(row, column) if (props2.selectionMode === 'range') { if (!props2.rangeState.selecting) { ctx.emit('pick', { minDate: newDate, maxDate: null }) ctx.emit('select', true) } else { if (newDate >= props2.minDate) { ctx.emit('pick', { minDate: props2.minDate, maxDate: newDate }) } else { ctx.emit('pick', { minDate: newDate, maxDate: props2.minDate }) } ctx.emit('select', false) } } else if (props2.selectionMode === 'day') { ctx.emit('pick', newDate) } else if (props2.selectionMode === 'week') { const weekNumber = newDate.week() const value2 = `${newDate.year()}w${weekNumber}` ctx.emit('pick', { year: newDate.year(), week: weekNumber, value: value2, date: newDate.startOf('week'), }) } else if (props2.selectionMode === 'dates') { const newValue = cell.selected ? castArray(props2.parsedValue).filter( (_2) => _2.valueOf() !== newDate.valueOf() ) : castArray(props2.parsedValue).concat([newDate]) ctx.emit('pick', newValue) } } const isWeekActive = (cell) => { if (props2.selectionMode !== 'week') return false let newDate = props2.date.startOf('day') if (cell.type === 'prev-month') { newDate = newDate.subtract(1, 'month') } if (cell.type === 'next-month') { newDate = newDate.add(1, 'month') } newDate = newDate.date(Number.parseInt(cell.text, 10)) if (props2.parsedValue && !Array.isArray(props2.parsedValue)) { const dayOffset = ((props2.parsedValue.day() - firstDayOfWeek + 7) % 7) - 1 const weekDate = props2.parsedValue.subtract(dayOffset, 'day') return weekDate.isSame(newDate, 'day') } return false } return { handleMouseMove, t: t3, rows, isWeekActive, getCellClasses, WEEKS, handleClick: handleClick2, } }, }) const _hoisted_1$6G = { key: 0 } function _sfc_render$1e(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_date_picker_cell = resolveComponent('el-date-picker-cell') return ( openBlock(), createElementBlock( 'table', { cellspacing: '0', cellpadding: '0', class: normalizeClass([ 'el-date-table', { 'is-week-mode': _ctx.selectionMode === 'week' }, ]), onClick: _cache[0] || (_cache[0] = (...args) => _ctx.handleClick && _ctx.handleClick(...args)), onMousemove: _cache[1] || (_cache[1] = (...args) => _ctx.handleMouseMove && _ctx.handleMouseMove(...args)), }, [ createElementVNode('tbody', null, [ createElementVNode('tr', null, [ _ctx.showWeekNumber ? (openBlock(), createElementBlock( 'th', _hoisted_1$6G, toDisplayString$1(_ctx.t('el.datepicker.week')), 1 )) : createCommentVNode('v-if', true), (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.WEEKS, (week, key2) => { return ( openBlock(), createElementBlock( 'th', { key: key2 }, toDisplayString$1(_ctx.t('el.datepicker.weeks.' + week)), 1 ) ) }), 128 )), ]), (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.rows, (row, key2) => { return ( openBlock(), createElementBlock( 'tr', { key: key2, class: normalizeClass([ 'el-date-table__row', { current: _ctx.isWeekActive(row[1]) }, ]), }, [ (openBlock(true), createElementBlock( Fragment, null, renderList(row, (cell, key_) => { return ( openBlock(), createElementBlock( 'td', { key: key_, class: normalizeClass(_ctx.getCellClasses(cell)), }, [ createVNode$1( _component_el_date_picker_cell, { cell }, null, 8, ['cell'] ), ], 2 ) ) }), 128 )), ], 2 ) ) }), 128 )), ]), ], 34 ) ) } var DateTable = /* @__PURE__ */ _export_sfc$1(_sfc_main$8t, [ ['render', _sfc_render$1e], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/date-picker/src/date-picker-com/basic-date-table.vue', ], ]) const datesInMonth = (year, month, lang) => { const firstDay = dayjs().locale(lang).startOf('month').month(month).year(year) const numOfDays = firstDay.daysInMonth() return rangeArr(numOfDays).map((n2) => firstDay.add(n2, 'day').toDate()) } const _sfc_main$8s = defineComponent({ props: { disabledDate: { type: Function, }, selectionMode: { type: String, default: 'month', }, minDate: { type: Object, }, maxDate: { type: Object, }, date: { type: Object, }, parsedValue: { type: Object, }, rangeState: { type: Object, default: () => ({ endDate: null, selecting: false, }), }, }, emits: ['changerange', 'pick', 'select'], setup(props2, ctx) { const { t: t3, lang } = useLocale() const months = ref( props2.date .locale('en') .localeData() .monthsShort() .map((_2) => _2.toLowerCase()) ) const tableRows = ref([[], [], []]) const lastRow = ref(null) const lastColumn = ref(null) const rows = computed(() => { var _a2 const rows2 = tableRows.value const now2 = dayjs().locale(lang.value).startOf('month') for (let i2 = 0; i2 < 3; i2++) { const row = rows2[i2] for (let j2 = 0; j2 < 4; j2++) { let cell = row[j2] if (!cell) { cell = { row: i2, column: j2, type: 'normal', inRange: false, start: false, end: false, } } cell.type = 'normal' const index2 = i2 * 4 + j2 const calTime = props2.date.startOf('year').month(index2) const calEndDate = props2.rangeState.endDate || props2.maxDate || (props2.rangeState.selecting && props2.minDate) cell.inRange = (props2.minDate && calTime.isSameOrAfter(props2.minDate, 'month') && calEndDate && calTime.isSameOrBefore(calEndDate, 'month')) || (props2.minDate && calTime.isSameOrBefore(props2.minDate, 'month') && calEndDate && calTime.isSameOrAfter(calEndDate, 'month')) if ( (_a2 = props2.minDate) == null ? void 0 : _a2.isSameOrAfter(calEndDate) ) { cell.start = calEndDate && calTime.isSame(calEndDate, 'month') cell.end = props2.minDate && calTime.isSame(props2.minDate, 'month') } else { cell.start = props2.minDate && calTime.isSame(props2.minDate, 'month') cell.end = calEndDate && calTime.isSame(calEndDate, 'month') } const isToday = now2.isSame(calTime) if (isToday) { cell.type = 'today' } cell.text = index2 const cellDate = calTime.toDate() cell.disabled = props2.disabledDate && props2.disabledDate(cellDate) row[j2] = cell } } return rows2 }) const getCellStyle = (cell) => { const style2 = {} const year = props2.date.year() const today = new Date() const month = cell.text style2.disabled = props2.disabledDate ? datesInMonth(year, month, lang.value).every(props2.disabledDate) : false style2.current = castArray(props2.parsedValue).findIndex( (date4) => date4.year() === year && date4.month() === month ) >= 0 style2.today = today.getFullYear() === year && today.getMonth() === month if (cell.inRange) { style2['in-range'] = true if (cell.start) { style2['start-date'] = true } if (cell.end) { style2['end-date'] = true } } return style2 } const handleMouseMove = (event) => { if (!props2.rangeState.selecting) return let target2 = event.target if (target2.tagName === 'A') { target2 = target2.parentNode.parentNode } if (target2.tagName === 'DIV') { target2 = target2.parentNode } if (target2.tagName !== 'TD') return const row = target2.parentNode.rowIndex const column = target2.cellIndex if (rows.value[row][column].disabled) return if (row !== lastRow.value || column !== lastColumn.value) { lastRow.value = row lastColumn.value = column ctx.emit('changerange', { selecting: true, endDate: props2.date.startOf('year').month(row * 4 + column), }) } } const handleMonthTableClick = (event) => { let target2 = event.target if (target2.tagName === 'A') { target2 = target2.parentNode.parentNode } if (target2.tagName === 'DIV') { target2 = target2.parentNode } if (target2.tagName !== 'TD') return if (hasClass$1(target2, 'disabled')) return const column = target2.cellIndex const row = target2.parentNode.rowIndex const month = row * 4 + column const newDate = props2.date.startOf('year').month(month) if (props2.selectionMode === 'range') { if (!props2.rangeState.selecting) { ctx.emit('pick', { minDate: newDate, maxDate: null }) ctx.emit('select', true) } else { if (newDate >= props2.minDate) { ctx.emit('pick', { minDate: props2.minDate, maxDate: newDate }) } else { ctx.emit('pick', { minDate: newDate, maxDate: props2.minDate }) } ctx.emit('select', false) } } else { ctx.emit('pick', month) } } return { handleMouseMove, handleMonthTableClick, rows, getCellStyle, t: t3, months, } }, }) const _hoisted_1$6F = { class: 'cell' } function _sfc_render$1d(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock( 'table', { class: 'el-month-table', onClick: _cache[0] || (_cache[0] = (...args) => _ctx.handleMonthTableClick && _ctx.handleMonthTableClick(...args)), onMousemove: _cache[1] || (_cache[1] = (...args) => _ctx.handleMouseMove && _ctx.handleMouseMove(...args)), }, [ createElementVNode('tbody', null, [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.rows, (row, key2) => { return ( openBlock(), createElementBlock('tr', { key: key2 }, [ (openBlock(true), createElementBlock( Fragment, null, renderList(row, (cell, key_) => { return ( openBlock(), createElementBlock( 'td', { key: key_, class: normalizeClass(_ctx.getCellStyle(cell)), }, [ createElementVNode('div', null, [ createElementVNode( 'a', _hoisted_1$6F, toDisplayString$1( _ctx.t( 'el.datepicker.months.' + _ctx.months[cell.text] ) ), 1 ), ]), ], 2 ) ) }), 128 )), ]) ) }), 128 )), ]), ], 32 ) ) } var MonthTable = /* @__PURE__ */ _export_sfc$1(_sfc_main$8s, [ ['render', _sfc_render$1d], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/date-picker/src/date-picker-com/basic-month-table.vue', ], ]) const datesInYear = (year, lang) => { const firstDay = dayjs(String(year)).locale(lang).startOf('year') const lastDay = firstDay.endOf('year') const numOfDays = lastDay.dayOfYear() return rangeArr(numOfDays).map((n2) => firstDay.add(n2, 'day').toDate()) } const _sfc_main$8r = defineComponent({ props: { disabledDate: { type: Function, }, parsedValue: { type: Object, }, date: { type: Object, }, }, emits: ['pick'], setup(props2, ctx) { const { lang } = useLocale() const startYear = computed(() => { return Math.floor(props2.date.year() / 10) * 10 }) const getCellStyle = (year) => { const style2 = {} const today = dayjs().locale(lang.value) style2.disabled = props2.disabledDate ? datesInYear(year, lang.value).every(props2.disabledDate) : false style2.current = castArray(props2.parsedValue).findIndex((_2) => _2.year() === year) >= 0 style2.today = today.year() === year return style2 } const handleYearTableClick = (event) => { const target2 = event.target if (target2.tagName === 'A') { if (hasClass$1(target2.parentNode, 'disabled')) return const year = target2.textContent || target2.innerText ctx.emit('pick', Number(year)) } } return { startYear, getCellStyle, handleYearTableClick, } }, }) const _hoisted_1$6E = { class: 'cell' } const _hoisted_2$5l = { class: 'cell' } const _hoisted_3$4J = { class: 'cell' } const _hoisted_4$45 = { class: 'cell' } const _hoisted_5$3G = { class: 'cell' } const _hoisted_6$3f = { class: 'cell' } const _hoisted_7$2T = { class: 'cell' } const _hoisted_8$2z = { class: 'cell' } const _hoisted_9$2n = { class: 'cell' } const _hoisted_10$29 = { class: 'cell' } const _hoisted_11$1Z = /* @__PURE__ */ createElementVNode('td', null, null, -1) const _hoisted_12$1T = /* @__PURE__ */ createElementVNode('td', null, null, -1) function _sfc_render$1c(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock( 'table', { class: 'el-year-table', onClick: _cache[0] || (_cache[0] = (...args) => _ctx.handleYearTableClick && _ctx.handleYearTableClick(...args)), }, [ createElementVNode('tbody', null, [ createElementVNode('tr', null, [ createElementVNode( 'td', { class: normalizeClass([ 'available', _ctx.getCellStyle(_ctx.startYear + 0), ]), }, [ createElementVNode( 'a', _hoisted_1$6E, toDisplayString$1(_ctx.startYear), 1 ), ], 2 ), createElementVNode( 'td', { class: normalizeClass([ 'available', _ctx.getCellStyle(_ctx.startYear + 1), ]), }, [ createElementVNode( 'a', _hoisted_2$5l, toDisplayString$1(_ctx.startYear + 1), 1 ), ], 2 ), createElementVNode( 'td', { class: normalizeClass([ 'available', _ctx.getCellStyle(_ctx.startYear + 2), ]), }, [ createElementVNode( 'a', _hoisted_3$4J, toDisplayString$1(_ctx.startYear + 2), 1 ), ], 2 ), createElementVNode( 'td', { class: normalizeClass([ 'available', _ctx.getCellStyle(_ctx.startYear + 3), ]), }, [ createElementVNode( 'a', _hoisted_4$45, toDisplayString$1(_ctx.startYear + 3), 1 ), ], 2 ), ]), createElementVNode('tr', null, [ createElementVNode( 'td', { class: normalizeClass([ 'available', _ctx.getCellStyle(_ctx.startYear + 4), ]), }, [ createElementVNode( 'a', _hoisted_5$3G, toDisplayString$1(_ctx.startYear + 4), 1 ), ], 2 ), createElementVNode( 'td', { class: normalizeClass([ 'available', _ctx.getCellStyle(_ctx.startYear + 5), ]), }, [ createElementVNode( 'a', _hoisted_6$3f, toDisplayString$1(_ctx.startYear + 5), 1 ), ], 2 ), createElementVNode( 'td', { class: normalizeClass([ 'available', _ctx.getCellStyle(_ctx.startYear + 6), ]), }, [ createElementVNode( 'a', _hoisted_7$2T, toDisplayString$1(_ctx.startYear + 6), 1 ), ], 2 ), createElementVNode( 'td', { class: normalizeClass([ 'available', _ctx.getCellStyle(_ctx.startYear + 7), ]), }, [ createElementVNode( 'a', _hoisted_8$2z, toDisplayString$1(_ctx.startYear + 7), 1 ), ], 2 ), ]), createElementVNode('tr', null, [ createElementVNode( 'td', { class: normalizeClass([ 'available', _ctx.getCellStyle(_ctx.startYear + 8), ]), }, [ createElementVNode( 'a', _hoisted_9$2n, toDisplayString$1(_ctx.startYear + 8), 1 ), ], 2 ), createElementVNode( 'td', { class: normalizeClass([ 'available', _ctx.getCellStyle(_ctx.startYear + 9), ]), }, [ createElementVNode( 'a', _hoisted_10$29, toDisplayString$1(_ctx.startYear + 9), 1 ), ], 2 ), _hoisted_11$1Z, _hoisted_12$1T, ]), ]), ] ) ) } var YearTable = /* @__PURE__ */ _export_sfc$1(_sfc_main$8r, [ ['render', _sfc_render$1c], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/date-picker/src/date-picker-com/basic-year-table.vue', ], ]) const timeWithinRange = (_2, __, ___) => true const _sfc_main$8q = defineComponent({ components: { DateTable, ElInput, ElButton, ElIcon, TimePickPanel, MonthTable, YearTable, DArrowLeft: dArrowLeft, ArrowLeft: arrowLeft, DArrowRight: dArrowRight, ArrowRight: arrowRight, }, directives: { clickoutside: ClickOutside }, props: { visible: { type: Boolean, default: false, }, parsedValue: { type: [Object, Array], }, format: { type: String, default: '', }, type: { type: String, required: true, validator: isValidDatePickType, }, }, emits: ['pick', 'set-picker-option', 'panel-change'], setup(props2, ctx) { const { t: t3, lang } = useLocale() const pickerBase = inject('EP_PICKER_BASE') const popper2 = inject(TOOLTIP_INJECTION_KEY) const { shortcuts, disabledDate, cellClassName, defaultTime, arrowControl, } = pickerBase.props const defaultValue = toRef(pickerBase.props, 'defaultValue') const innerDate = ref(dayjs().locale(lang.value)) const defaultTimeD = computed(() => { return dayjs(defaultTime).locale(lang.value) }) const month = computed(() => { return innerDate.value.month() }) const year = computed(() => { return innerDate.value.year() }) const selectableRange = ref([]) const userInputDate = ref(null) const userInputTime = ref(null) const checkDateWithinRange = (date4) => { return selectableRange.value.length > 0 ? timeWithinRange( date4, selectableRange.value, props2.format || 'HH:mm:ss' ) : true } const formatEmit = (emitDayjs) => { if (defaultTime && !visibleTime.value) { return defaultTimeD.value .year(emitDayjs.year()) .month(emitDayjs.month()) .date(emitDayjs.date()) } if (showTime.value) return emitDayjs.millisecond(0) return emitDayjs.startOf('day') } const emit2 = (value2, ...args) => { if (!value2) { ctx.emit('pick', value2, ...args) } else if (Array.isArray(value2)) { const dates = value2.map(formatEmit) ctx.emit('pick', dates, ...args) } else { ctx.emit('pick', formatEmit(value2), ...args) } userInputDate.value = null userInputTime.value = null } const handleDatePick = (value2) => { if (selectionMode.value === 'day') { let newDate = props2.parsedValue ? props2.parsedValue .year(value2.year()) .month(value2.month()) .date(value2.date()) : value2 if (!checkDateWithinRange(newDate)) { newDate = selectableRange.value[0][0] .year(value2.year()) .month(value2.month()) .date(value2.date()) } innerDate.value = newDate emit2(newDate, showTime.value) } else if (selectionMode.value === 'week') { emit2(value2.date) } else if (selectionMode.value === 'dates') { emit2(value2, true) } } const prevMonth_ = () => { innerDate.value = innerDate.value.subtract(1, 'month') handlePanelChange('month') } const nextMonth_ = () => { innerDate.value = innerDate.value.add(1, 'month') handlePanelChange('month') } const prevYear_ = () => { if (currentView.value === 'year') { innerDate.value = innerDate.value.subtract(10, 'year') } else { innerDate.value = innerDate.value.subtract(1, 'year') } handlePanelChange('year') } const nextYear_ = () => { if (currentView.value === 'year') { innerDate.value = innerDate.value.add(10, 'year') } else { innerDate.value = innerDate.value.add(1, 'year') } handlePanelChange('year') } const currentView = ref('date') const yearLabel = computed(() => { const yearTranslation = t3('el.datepicker.year') if (currentView.value === 'year') { const startYear = Math.floor(year.value / 10) * 10 if (yearTranslation) { return `${startYear} ${yearTranslation} - ${ startYear + 9 } ${yearTranslation}` } return `${startYear} - ${startYear + 9}` } return `${year.value} ${yearTranslation}` }) const handleShortcutClick = (shortcut) => { const shortcutValue = typeof shortcut.value === 'function' ? shortcut.value() : shortcut.value if (shortcutValue) { emit2(dayjs(shortcutValue).locale(lang.value)) return } if (shortcut.onClick) { shortcut.onClick(ctx) } } const selectionMode = computed(() => { if (['week', 'month', 'year', 'dates'].includes(props2.type)) { return props2.type } return 'day' }) watch$1( () => selectionMode.value, (val2) => { if (['month', 'year'].includes(val2)) { currentView.value = val2 return } currentView.value = 'date' }, { immediate: true } ) watch$1( () => currentView.value, () => { popper2 == null ? void 0 : popper2.updatePopper() } ) const hasShortcuts = computed(() => !!shortcuts.length) const handleMonthPick = (month2) => { innerDate.value = innerDate.value.startOf('month').month(month2) if (selectionMode.value === 'month') { emit2(innerDate.value) } else { currentView.value = 'date' } handlePanelChange('month') } const handleYearPick = (year2) => { if (selectionMode.value === 'year') { innerDate.value = innerDate.value.startOf('year').year(year2) emit2(innerDate.value) } else { innerDate.value = innerDate.value.year(year2) currentView.value = 'month' } handlePanelChange('year') } const showMonthPicker = () => { currentView.value = 'month' } const showYearPicker = () => { currentView.value = 'year' } const showTime = computed( () => props2.type === 'datetime' || props2.type === 'datetimerange' ) const footerVisible = computed(() => { return showTime.value || selectionMode.value === 'dates' }) const onConfirm = () => { if (selectionMode.value === 'dates') { emit2(props2.parsedValue) } else { let result = props2.parsedValue if (!result) { const defaultTimeD2 = dayjs(defaultTime).locale(lang.value) const defaultValueD = getDefaultValue() result = defaultTimeD2 .year(defaultValueD.year()) .month(defaultValueD.month()) .date(defaultValueD.date()) } innerDate.value = result emit2(result) } } const changeToNow = () => { const now2 = dayjs().locale(lang.value) const nowDate = now2.toDate() if ( (!disabledDate || !disabledDate(nowDate)) && checkDateWithinRange(nowDate) ) { innerDate.value = dayjs().locale(lang.value) emit2(innerDate.value) } } const timeFormat = computed(() => { return extractTimeFormat(props2.format) }) const dateFormat = computed(() => { return extractDateFormat(props2.format) }) const visibleTime = computed(() => { if (userInputTime.value) return userInputTime.value if (!props2.parsedValue && !defaultValue.value) return return (props2.parsedValue || innerDate.value).format(timeFormat.value) }) const visibleDate = computed(() => { if (userInputDate.value) return userInputDate.value if (!props2.parsedValue && !defaultValue.value) return return (props2.parsedValue || innerDate.value).format(dateFormat.value) }) const timePickerVisible = ref(false) const onTimePickerInputFocus = () => { timePickerVisible.value = true } const handleTimePickClose = () => { timePickerVisible.value = false } const handleTimePick = (value2, visible, first2) => { const newDate = props2.parsedValue ? props2.parsedValue .hour(value2.hour()) .minute(value2.minute()) .second(value2.second()) : value2 innerDate.value = newDate emit2(innerDate.value, true) if (!first2) { timePickerVisible.value = visible } } const handleVisibleTimeChange = (value2) => { const newDate = dayjs(value2, timeFormat.value).locale(lang.value) if (newDate.isValid() && checkDateWithinRange(newDate)) { innerDate.value = newDate .year(innerDate.value.year()) .month(innerDate.value.month()) .date(innerDate.value.date()) userInputTime.value = null timePickerVisible.value = false emit2(innerDate.value, true) } } const handleVisibleDateChange = (value2) => { const newDate = dayjs(value2, dateFormat.value).locale(lang.value) if (newDate.isValid()) { if (disabledDate && disabledDate(newDate.toDate())) { return } innerDate.value = newDate .hour(innerDate.value.hour()) .minute(innerDate.value.minute()) .second(innerDate.value.second()) userInputDate.value = null emit2(innerDate.value, true) } } const isValidValue = (date4) => { return ( dayjs.isDayjs(date4) && date4.isValid() && (disabledDate ? !disabledDate(date4.toDate()) : true) ) } const formatToString = (value2) => { if (selectionMode.value === 'dates') { return value2.map((_2) => _2.format(props2.format)) } return value2.format(props2.format) } const parseUserInput = (value2) => { return dayjs(value2, props2.format).locale(lang.value) } const getDefaultValue = () => { const parseDate2 = dayjs(defaultValue.value).locale(lang.value) if (!defaultValue.value) { const defaultTimeDValue = defaultTimeD.value return dayjs() .hour(defaultTimeDValue.hour()) .minute(defaultTimeDValue.minute()) .second(defaultTimeDValue.second()) .locale(lang.value) } return parseDate2 } const handleKeydown = (event) => { const { code: code2, keyCode } = event const list2 = [ EVENT_CODE.up, EVENT_CODE.down, EVENT_CODE.left, EVENT_CODE.right, ] if (props2.visible && !timePickerVisible.value) { if (list2.includes(code2)) { handleKeyControl(keyCode) event.stopPropagation() event.preventDefault() } if ( code2 === EVENT_CODE.enter && userInputDate.value === null && userInputTime.value === null ) { emit2(innerDate, false) } } } const handleKeyControl = (keyCode) => { const mapping = { year: { 38: -4, 40: 4, 37: -1, 39: 1, offset: (date4, step) => date4.setFullYear(date4.getFullYear() + step), }, month: { 38: -4, 40: 4, 37: -1, 39: 1, offset: (date4, step) => date4.setMonth(date4.getMonth() + step), }, week: { 38: -1, 40: 1, 37: -1, 39: 1, offset: (date4, step) => date4.setDate(date4.getDate() + step * 7), }, day: { 38: -7, 40: 7, 37: -1, 39: 1, offset: (date4, step) => date4.setDate(date4.getDate() + step), }, } const newDate = innerDate.value.toDate() while (Math.abs(innerDate.value.diff(newDate, 'year', true)) < 1) { const map2 = mapping[selectionMode.value] map2.offset(newDate, map2[keyCode]) if (disabledDate && disabledDate(newDate)) { continue } const result = dayjs(newDate).locale(lang.value) innerDate.value = result ctx.emit('pick', result, true) break } } const handlePanelChange = (mode2) => { ctx.emit( 'panel-change', innerDate.value.toDate(), mode2, currentView.value ) } ctx.emit('set-picker-option', ['isValidValue', isValidValue]) ctx.emit('set-picker-option', ['formatToString', formatToString]) ctx.emit('set-picker-option', ['parseUserInput', parseUserInput]) ctx.emit('set-picker-option', ['handleKeydown', handleKeydown]) watch$1( () => defaultValue.value, (val2) => { if (val2) { innerDate.value = getDefaultValue() } }, { immediate: true } ) watch$1( () => props2.parsedValue, (val2) => { if (val2) { if (selectionMode.value === 'dates') return if (Array.isArray(val2)) return innerDate.value = val2 } else { innerDate.value = getDefaultValue() } }, { immediate: true } ) return { handleTimePick, handleTimePickClose, onTimePickerInputFocus, timePickerVisible, visibleTime, visibleDate, showTime, changeToNow, onConfirm, footerVisible, handleYearPick, showMonthPicker, showYearPicker, handleMonthPick, hasShortcuts, shortcuts, arrowControl, disabledDate, cellClassName, selectionMode, handleShortcutClick, prevYear_, nextYear_, prevMonth_, nextMonth_, innerDate, t: t3, yearLabel, currentView, month, handleDatePick, handleVisibleTimeChange, handleVisibleDateChange, timeFormat, userInputTime, userInputDate, } }, }) const _hoisted_1$6D = { class: 'el-picker-panel__body-wrapper' } const _hoisted_2$5k = { key: 0, class: 'el-picker-panel__sidebar', } const _hoisted_3$4I = ['onClick'] const _hoisted_4$44 = { class: 'el-picker-panel__body' } const _hoisted_5$3F = { key: 0, class: 'el-date-picker__time-header', } const _hoisted_6$3e = { class: 'el-date-picker__editor-wrap' } const _hoisted_7$2S = { class: 'el-date-picker__editor-wrap' } const _hoisted_8$2y = ['aria-label'] const _hoisted_9$2m = ['aria-label'] const _hoisted_10$28 = ['aria-label'] const _hoisted_11$1Y = ['aria-label'] const _hoisted_12$1S = { class: 'el-picker-panel__content' } const _hoisted_13$1G = { class: 'el-picker-panel__footer' } function _sfc_render$1b(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_input = resolveComponent('el-input') const _component_time_pick_panel = resolveComponent('time-pick-panel') const _component_d_arrow_left = resolveComponent('d-arrow-left') const _component_el_icon = resolveComponent('el-icon') const _component_arrow_left = resolveComponent('arrow-left') const _component_d_arrow_right = resolveComponent('d-arrow-right') const _component_arrow_right = resolveComponent('arrow-right') const _component_date_table = resolveComponent('date-table') const _component_year_table = resolveComponent('year-table') const _component_month_table = resolveComponent('month-table') const _component_el_button = resolveComponent('el-button') const _directive_clickoutside = resolveDirective('clickoutside') return ( openBlock(), createElementBlock( 'div', { class: normalizeClass([ 'el-picker-panel el-date-picker', [ { 'has-sidebar': _ctx.$slots.sidebar || _ctx.hasShortcuts, 'has-time': _ctx.showTime, }, ], ]), }, [ createElementVNode('div', _hoisted_1$6D, [ renderSlot(_ctx.$slots, 'sidebar', { class: 'el-picker-panel__sidebar', }), _ctx.hasShortcuts ? (openBlock(), createElementBlock('div', _hoisted_2$5k, [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.shortcuts, (shortcut, key2) => { return ( openBlock(), createElementBlock( 'button', { key: key2, type: 'button', class: 'el-picker-panel__shortcut', onClick: ($event) => _ctx.handleShortcutClick(shortcut), }, toDisplayString$1(shortcut.text), 9, _hoisted_3$4I ) ) }), 128 )), ])) : createCommentVNode('v-if', true), createElementVNode('div', _hoisted_4$44, [ _ctx.showTime ? (openBlock(), createElementBlock('div', _hoisted_5$3F, [ createElementVNode('span', _hoisted_6$3e, [ createVNode$1( _component_el_input, { placeholder: _ctx.t('el.datepicker.selectDate'), 'model-value': _ctx.visibleDate, size: 'small', onInput: _cache[0] || (_cache[0] = (val2) => (_ctx.userInputDate = val2)), onChange: _ctx.handleVisibleDateChange, }, null, 8, ['placeholder', 'model-value', 'onChange'] ), ]), withDirectives( (openBlock(), createElementBlock('span', _hoisted_7$2S, [ createVNode$1( _component_el_input, { placeholder: _ctx.t('el.datepicker.selectTime'), 'model-value': _ctx.visibleTime, size: 'small', onFocus: _ctx.onTimePickerInputFocus, onInput: _cache[1] || (_cache[1] = (val2) => (_ctx.userInputTime = val2)), onChange: _ctx.handleVisibleTimeChange, }, null, 8, ['placeholder', 'model-value', 'onFocus', 'onChange'] ), createVNode$1( _component_time_pick_panel, { visible: _ctx.timePickerVisible, format: _ctx.timeFormat, 'time-arrow-control': _ctx.arrowControl, 'parsed-value': _ctx.innerDate, onPick: _ctx.handleTimePick, }, null, 8, [ 'visible', 'format', 'time-arrow-control', 'parsed-value', 'onPick', ] ), ])), [[_directive_clickoutside, _ctx.handleTimePickClose]] ), ])) : createCommentVNode('v-if', true), withDirectives( createElementVNode( 'div', { class: normalizeClass([ 'el-date-picker__header', { 'el-date-picker__header--bordered': _ctx.currentView === 'year' || _ctx.currentView === 'month', }, ]), }, [ createElementVNode( 'button', { type: 'button', 'aria-label': _ctx.t(`el.datepicker.prevYear`), class: 'el-picker-panel__icon-btn el-date-picker__prev-btn d-arrow-left', onClick: _cache[2] || (_cache[2] = (...args) => _ctx.prevYear_ && _ctx.prevYear_(...args)), }, [ createVNode$1(_component_el_icon, null, { default: withCtx(() => [ createVNode$1(_component_d_arrow_left), ]), _: 1, }), ], 8, _hoisted_8$2y ), withDirectives( createElementVNode( 'button', { type: 'button', 'aria-label': _ctx.t(`el.datepicker.prevMonth`), class: 'el-picker-panel__icon-btn el-date-picker__prev-btn arrow-left', onClick: _cache[3] || (_cache[3] = (...args) => _ctx.prevMonth_ && _ctx.prevMonth_(...args)), }, [ createVNode$1(_component_el_icon, null, { default: withCtx(() => [ createVNode$1(_component_arrow_left), ]), _: 1, }), ], 8, _hoisted_9$2m ), [[vShow, _ctx.currentView === 'date']] ), createElementVNode( 'span', { role: 'button', class: 'el-date-picker__header-label', onClick: _cache[4] || (_cache[4] = (...args) => _ctx.showYearPicker && _ctx.showYearPicker(...args)), }, toDisplayString$1(_ctx.yearLabel), 1 ), withDirectives( createElementVNode( 'span', { role: 'button', class: normalizeClass([ 'el-date-picker__header-label', { active: _ctx.currentView === 'month' }, ]), onClick: _cache[5] || (_cache[5] = (...args) => _ctx.showMonthPicker && _ctx.showMonthPicker(...args)), }, toDisplayString$1( _ctx.t(`el.datepicker.month${_ctx.month + 1}`) ), 3 ), [[vShow, _ctx.currentView === 'date']] ), createElementVNode( 'button', { type: 'button', 'aria-label': _ctx.t(`el.datepicker.nextYear`), class: 'el-picker-panel__icon-btn el-date-picker__next-btn d-arrow-right', onClick: _cache[6] || (_cache[6] = (...args) => _ctx.nextYear_ && _ctx.nextYear_(...args)), }, [ createVNode$1(_component_el_icon, null, { default: withCtx(() => [ createVNode$1(_component_d_arrow_right), ]), _: 1, }), ], 8, _hoisted_10$28 ), withDirectives( createElementVNode( 'button', { type: 'button', 'aria-label': _ctx.t(`el.datepicker.nextMonth`), class: 'el-picker-panel__icon-btn el-date-picker__next-btn arrow-right', onClick: _cache[7] || (_cache[7] = (...args) => _ctx.nextMonth_ && _ctx.nextMonth_(...args)), }, [ createVNode$1(_component_el_icon, null, { default: withCtx(() => [ createVNode$1(_component_arrow_right), ]), _: 1, }), ], 8, _hoisted_11$1Y ), [[vShow, _ctx.currentView === 'date']] ), ], 2 ), [[vShow, _ctx.currentView !== 'time']] ), createElementVNode('div', _hoisted_12$1S, [ _ctx.currentView === 'date' ? (openBlock(), createBlock( _component_date_table, { key: 0, 'selection-mode': _ctx.selectionMode, date: _ctx.innerDate, 'parsed-value': _ctx.parsedValue, 'disabled-date': _ctx.disabledDate, onPick: _ctx.handleDatePick, }, null, 8, [ 'selection-mode', 'date', 'parsed-value', 'disabled-date', 'onPick', ] )) : createCommentVNode('v-if', true), _ctx.currentView === 'year' ? (openBlock(), createBlock( _component_year_table, { key: 1, date: _ctx.innerDate, 'disabled-date': _ctx.disabledDate, 'parsed-value': _ctx.parsedValue, onPick: _ctx.handleYearPick, }, null, 8, ['date', 'disabled-date', 'parsed-value', 'onPick'] )) : createCommentVNode('v-if', true), _ctx.currentView === 'month' ? (openBlock(), createBlock( _component_month_table, { key: 2, date: _ctx.innerDate, 'parsed-value': _ctx.parsedValue, 'disabled-date': _ctx.disabledDate, onPick: _ctx.handleMonthPick, }, null, 8, ['date', 'parsed-value', 'disabled-date', 'onPick'] )) : createCommentVNode('v-if', true), ]), ]), ]), withDirectives( createElementVNode( 'div', _hoisted_13$1G, [ withDirectives( createVNode$1( _component_el_button, { size: 'small', type: 'text', class: 'el-picker-panel__link-btn', onClick: _ctx.changeToNow, }, { default: withCtx(() => [ createTextVNode( toDisplayString$1(_ctx.t('el.datepicker.now')), 1 ), ]), _: 1, }, 8, ['onClick'] ), [[vShow, _ctx.selectionMode !== 'dates']] ), createVNode$1( _component_el_button, { plain: '', size: 'small', class: 'el-picker-panel__link-btn', onClick: _ctx.onConfirm, }, { default: withCtx(() => [ createTextVNode( toDisplayString$1(_ctx.t('el.datepicker.confirm')), 1 ), ]), _: 1, }, 8, ['onClick'] ), ], 512 ), [[vShow, _ctx.footerVisible && _ctx.currentView === 'date']] ), ], 2 ) ) } var DatePickPanel = /* @__PURE__ */ _export_sfc$1(_sfc_main$8q, [ ['render', _sfc_render$1b], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/date-picker/src/date-picker-com/panel-date-pick.vue', ], ]) const _sfc_main$8p = defineComponent({ directives: { clickoutside: ClickOutside }, components: { TimePickPanel, DateTable, ElInput, ElButton, ElIcon, DArrowLeft: dArrowLeft, ArrowLeft: arrowLeft, DArrowRight: dArrowRight, ArrowRight: arrowRight, }, props: { unlinkPanels: Boolean, parsedValue: { type: Array, }, type: { type: String, required: true, validator: isValidDatePickType, }, }, emits: ['pick', 'set-picker-option', 'calendar-change', 'panel-change'], setup(props2, ctx) { const { t: t3, lang } = useLocale() const leftDate = ref(dayjs().locale(lang.value)) const rightDate = ref(dayjs().locale(lang.value).add(1, 'month')) const minDate = ref(null) const maxDate = ref(null) const dateUserInput = ref({ min: null, max: null, }) const timeUserInput = ref({ min: null, max: null, }) const leftLabel = computed(() => { return `${leftDate.value.year()} ${t3('el.datepicker.year')} ${t3( `el.datepicker.month${leftDate.value.month() + 1}` )}` }) const rightLabel = computed(() => { return `${rightDate.value.year()} ${t3('el.datepicker.year')} ${t3( `el.datepicker.month${rightDate.value.month() + 1}` )}` }) const leftYear = computed(() => { return leftDate.value.year() }) const leftMonth = computed(() => { return leftDate.value.month() }) const rightYear = computed(() => { return rightDate.value.year() }) const rightMonth = computed(() => { return rightDate.value.month() }) const hasShortcuts = computed(() => !!shortcuts.length) const minVisibleDate = computed(() => { if (dateUserInput.value.min !== null) return dateUserInput.value.min if (minDate.value) return minDate.value.format(dateFormat.value) return '' }) const maxVisibleDate = computed(() => { if (dateUserInput.value.max !== null) return dateUserInput.value.max if (maxDate.value || minDate.value) return (maxDate.value || minDate.value).format(dateFormat.value) return '' }) const minVisibleTime = computed(() => { if (timeUserInput.value.min !== null) return timeUserInput.value.min if (minDate.value) return minDate.value.format(timeFormat.value) return '' }) const maxVisibleTime = computed(() => { if (timeUserInput.value.max !== null) return timeUserInput.value.max if (maxDate.value || minDate.value) return (maxDate.value || minDate.value).format(timeFormat.value) return '' }) const timeFormat = computed(() => { return extractTimeFormat(format2) }) const dateFormat = computed(() => { return extractDateFormat(format2) }) const leftPrevYear = () => { leftDate.value = leftDate.value.subtract(1, 'year') if (!props2.unlinkPanels) { rightDate.value = leftDate.value.add(1, 'month') } handlePanelChange('year') } const leftPrevMonth = () => { leftDate.value = leftDate.value.subtract(1, 'month') if (!props2.unlinkPanels) { rightDate.value = leftDate.value.add(1, 'month') } handlePanelChange('month') } const rightNextYear = () => { if (!props2.unlinkPanels) { leftDate.value = leftDate.value.add(1, 'year') rightDate.value = leftDate.value.add(1, 'month') } else { rightDate.value = rightDate.value.add(1, 'year') } handlePanelChange('year') } const rightNextMonth = () => { if (!props2.unlinkPanels) { leftDate.value = leftDate.value.add(1, 'month') rightDate.value = leftDate.value.add(1, 'month') } else { rightDate.value = rightDate.value.add(1, 'month') } handlePanelChange('month') } const leftNextYear = () => { leftDate.value = leftDate.value.add(1, 'year') handlePanelChange('year') } const leftNextMonth = () => { leftDate.value = leftDate.value.add(1, 'month') handlePanelChange('month') } const rightPrevYear = () => { rightDate.value = rightDate.value.subtract(1, 'year') handlePanelChange('year') } const rightPrevMonth = () => { rightDate.value = rightDate.value.subtract(1, 'month') handlePanelChange('month') } const handlePanelChange = (mode2) => { ctx.emit( 'panel-change', [leftDate.value.toDate(), rightDate.value.toDate()], mode2 ) } const enableMonthArrow = computed(() => { const nextMonth = (leftMonth.value + 1) % 12 const yearOffset = leftMonth.value + 1 >= 12 ? 1 : 0 return ( props2.unlinkPanels && new Date(leftYear.value + yearOffset, nextMonth) < new Date(rightYear.value, rightMonth.value) ) }) const enableYearArrow = computed(() => { return ( props2.unlinkPanels && rightYear.value * 12 + rightMonth.value - (leftYear.value * 12 + leftMonth.value + 1) >= 12 ) }) const isValidValue = (value2) => { return ( Array.isArray(value2) && value2[0] && value2[1] && value2[0].valueOf() <= value2[1].valueOf() ) } const rangeState = ref({ endDate: null, selecting: false, }) const btnDisabled = computed(() => { return !( minDate.value && maxDate.value && !rangeState.value.selecting && isValidValue([minDate.value, maxDate.value]) ) }) const handleChangeRange = (val2) => { rangeState.value = val2 } const onSelect = (selecting) => { rangeState.value.selecting = selecting if (!selecting) { rangeState.value.endDate = null } } const showTime = computed( () => props2.type === 'datetime' || props2.type === 'datetimerange' ) const handleConfirm = (visible = false) => { if (isValidValue([minDate.value, maxDate.value])) { ctx.emit('pick', [minDate.value, maxDate.value], visible) } } const formatEmit = (emitDayjs, index2) => { if (!emitDayjs) return if (defaultTime) { const defaultTimeD = dayjs(defaultTime[index2] || defaultTime).locale( lang.value ) return defaultTimeD .year(emitDayjs.year()) .month(emitDayjs.month()) .date(emitDayjs.date()) } return emitDayjs } const handleRangePick = (val2, close2 = true) => { const min_ = val2.minDate const max_ = val2.maxDate const minDate_ = formatEmit(min_, 0) const maxDate_ = formatEmit(max_, 1) if (maxDate.value === maxDate_ && minDate.value === minDate_) { return } ctx.emit('calendar-change', [min_.toDate(), max_ && max_.toDate()]) maxDate.value = maxDate_ minDate.value = minDate_ if (!close2 || showTime.value) return handleConfirm() } const handleShortcutClick = (shortcut) => { const shortcutValues = typeof shortcut.value === 'function' ? shortcut.value() : shortcut.value if (shortcutValues) { ctx.emit('pick', [ dayjs(shortcutValues[0]).locale(lang.value), dayjs(shortcutValues[1]).locale(lang.value), ]) return } if (shortcut.onClick) { shortcut.onClick(ctx) } } const minTimePickerVisible = ref(false) const maxTimePickerVisible = ref(false) const handleMinTimeClose = () => { minTimePickerVisible.value = false } const handleMaxTimeClose = () => { maxTimePickerVisible.value = false } const handleDateInput = (value2, type4) => { dateUserInput.value[type4] = value2 const parsedValueD = dayjs(value2, dateFormat.value).locale(lang.value) if (parsedValueD.isValid()) { if (disabledDate && disabledDate(parsedValueD.toDate())) { return } if (type4 === 'min') { leftDate.value = parsedValueD minDate.value = (minDate.value || leftDate.value) .year(parsedValueD.year()) .month(parsedValueD.month()) .date(parsedValueD.date()) if (!props2.unlinkPanels) { rightDate.value = parsedValueD.add(1, 'month') maxDate.value = minDate.value.add(1, 'month') } } else { rightDate.value = parsedValueD maxDate.value = (maxDate.value || rightDate.value) .year(parsedValueD.year()) .month(parsedValueD.month()) .date(parsedValueD.date()) if (!props2.unlinkPanels) { leftDate.value = parsedValueD.subtract(1, 'month') minDate.value = maxDate.value.subtract(1, 'month') } } } } const handleDateChange = (_2, type4) => { dateUserInput.value[type4] = null } const handleTimeInput = (value2, type4) => { timeUserInput.value[type4] = value2 const parsedValueD = dayjs(value2, timeFormat.value).locale(lang.value) if (parsedValueD.isValid()) { if (type4 === 'min') { minTimePickerVisible.value = true minDate.value = (minDate.value || leftDate.value) .hour(parsedValueD.hour()) .minute(parsedValueD.minute()) .second(parsedValueD.second()) if (!maxDate.value || maxDate.value.isBefore(minDate.value)) { maxDate.value = minDate.value } } else { maxTimePickerVisible.value = true maxDate.value = (maxDate.value || rightDate.value) .hour(parsedValueD.hour()) .minute(parsedValueD.minute()) .second(parsedValueD.second()) rightDate.value = maxDate.value if (maxDate.value && maxDate.value.isBefore(minDate.value)) { minDate.value = maxDate.value } } } } const handleTimeChange = (value2, type4) => { timeUserInput.value[type4] = null if (type4 === 'min') { leftDate.value = minDate.value minTimePickerVisible.value = false } else { rightDate.value = maxDate.value maxTimePickerVisible.value = false } } const handleMinTimePick = (value2, visible, first2) => { if (timeUserInput.value.min) return if (value2) { leftDate.value = value2 minDate.value = (minDate.value || leftDate.value) .hour(value2.hour()) .minute(value2.minute()) .second(value2.second()) } if (!first2) { minTimePickerVisible.value = visible } if (!maxDate.value || maxDate.value.isBefore(minDate.value)) { maxDate.value = minDate.value rightDate.value = value2 } } const handleMaxTimePick = (value2, visible, first2) => { if (timeUserInput.value.max) return if (value2) { rightDate.value = value2 maxDate.value = (maxDate.value || rightDate.value) .hour(value2.hour()) .minute(value2.minute()) .second(value2.second()) } if (!first2) { maxTimePickerVisible.value = visible } if (maxDate.value && maxDate.value.isBefore(minDate.value)) { minDate.value = maxDate.value } } const handleClear = () => { leftDate.value = getDefaultValue()[0] rightDate.value = leftDate.value.add(1, 'month') ctx.emit('pick', null) } const formatToString = (value2) => { return Array.isArray(value2) ? value2.map((_2) => _2.format(format2)) : value2.format(format2) } const parseUserInput = (value2) => { return Array.isArray(value2) ? value2.map((_2) => dayjs(_2, format2).locale(lang.value)) : dayjs(value2, format2).locale(lang.value) } const getDefaultValue = () => { let start2 if (Array.isArray(defaultValue.value)) { const left2 = dayjs(defaultValue.value[0]) let right2 = dayjs(defaultValue.value[1]) if (!props2.unlinkPanels) { right2 = left2.add(1, 'month') } return [left2, right2] } else if (defaultValue.value) { start2 = dayjs(defaultValue.value) } else { start2 = dayjs() } start2 = start2.locale(lang.value) return [start2, start2.add(1, 'month')] } ctx.emit('set-picker-option', ['isValidValue', isValidValue]) ctx.emit('set-picker-option', ['parseUserInput', parseUserInput]) ctx.emit('set-picker-option', ['formatToString', formatToString]) ctx.emit('set-picker-option', ['handleClear', handleClear]) const pickerBase = inject('EP_PICKER_BASE') const { shortcuts, disabledDate, cellClassName, format: format2, defaultTime, arrowControl, clearable, } = pickerBase.props const defaultValue = toRef(pickerBase.props, 'defaultValue') watch$1( () => defaultValue.value, (val2) => { if (val2) { const defaultArr = getDefaultValue() minDate.value = null maxDate.value = null leftDate.value = defaultArr[0] rightDate.value = defaultArr[1] } }, { immediate: true } ) watch$1( () => props2.parsedValue, (newVal) => { if (newVal && newVal.length === 2) { minDate.value = newVal[0] maxDate.value = newVal[1] leftDate.value = minDate.value if (props2.unlinkPanels && maxDate.value) { const minDateYear = minDate.value.year() const minDateMonth = minDate.value.month() const maxDateYear = maxDate.value.year() const maxDateMonth = maxDate.value.month() rightDate.value = minDateYear === maxDateYear && minDateMonth === maxDateMonth ? maxDate.value.add(1, 'month') : maxDate.value } else { rightDate.value = leftDate.value.add(1, 'month') if (maxDate.value) { rightDate.value = rightDate.value .hour(maxDate.value.hour()) .minute(maxDate.value.minute()) .second(maxDate.value.second()) } } } else { const defaultArr = getDefaultValue() minDate.value = null maxDate.value = null leftDate.value = defaultArr[0] rightDate.value = defaultArr[1] } }, { immediate: true } ) return { shortcuts, disabledDate, cellClassName, minTimePickerVisible, maxTimePickerVisible, handleMinTimeClose, handleMaxTimeClose, handleShortcutClick, rangeState, minDate, maxDate, handleRangePick, onSelect, handleChangeRange, btnDisabled, enableYearArrow, enableMonthArrow, rightPrevMonth, rightPrevYear, rightNextMonth, rightNextYear, leftPrevMonth, leftPrevYear, leftNextMonth, leftNextYear, hasShortcuts, leftLabel, rightLabel, leftDate, rightDate, showTime, t: t3, minVisibleDate, maxVisibleDate, minVisibleTime, maxVisibleTime, arrowControl, handleDateInput, handleDateChange, handleTimeInput, handleTimeChange, handleMinTimePick, handleMaxTimePick, handleClear, handleConfirm, timeFormat, clearable, } }, }) const _hoisted_1$6C = { class: 'el-picker-panel__body-wrapper' } const _hoisted_2$5j = { key: 0, class: 'el-picker-panel__sidebar', } const _hoisted_3$4H = ['onClick'] const _hoisted_4$43 = { class: 'el-picker-panel__body' } const _hoisted_5$3E = { key: 0, class: 'el-date-range-picker__time-header', } const _hoisted_6$3d = { class: 'el-date-range-picker__editors-wrap' } const _hoisted_7$2R = { class: 'el-date-range-picker__time-picker-wrap' } const _hoisted_8$2x = { class: 'el-date-range-picker__time-picker-wrap' } const _hoisted_9$2l = { class: 'el-date-range-picker__editors-wrap is-right' } const _hoisted_10$27 = { class: 'el-date-range-picker__time-picker-wrap' } const _hoisted_11$1X = { class: 'el-date-range-picker__time-picker-wrap' } const _hoisted_12$1R = { class: 'el-picker-panel__content el-date-range-picker__content is-left', } const _hoisted_13$1F = { class: 'el-date-range-picker__header' } const _hoisted_14$1s = ['disabled'] const _hoisted_15$1n = ['disabled'] const _hoisted_16$1l = { class: 'el-picker-panel__content el-date-range-picker__content is-right', } const _hoisted_17$1d = { class: 'el-date-range-picker__header' } const _hoisted_18$15 = ['disabled'] const _hoisted_19$10 = ['disabled'] const _hoisted_20$W = { key: 0, class: 'el-picker-panel__footer', } function _sfc_render$1a(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_input = resolveComponent('el-input') const _component_time_pick_panel = resolveComponent('time-pick-panel') const _component_arrow_right = resolveComponent('arrow-right') const _component_el_icon = resolveComponent('el-icon') const _component_d_arrow_left = resolveComponent('d-arrow-left') const _component_arrow_left = resolveComponent('arrow-left') const _component_d_arrow_right = resolveComponent('d-arrow-right') const _component_date_table = resolveComponent('date-table') const _component_el_button = resolveComponent('el-button') const _directive_clickoutside = resolveDirective('clickoutside') return ( openBlock(), createElementBlock( 'div', { class: normalizeClass([ 'el-picker-panel el-date-range-picker', [ { 'has-sidebar': _ctx.$slots.sidebar || _ctx.hasShortcuts, 'has-time': _ctx.showTime, }, ], ]), }, [ createElementVNode('div', _hoisted_1$6C, [ renderSlot(_ctx.$slots, 'sidebar', { class: 'el-picker-panel__sidebar', }), _ctx.hasShortcuts ? (openBlock(), createElementBlock('div', _hoisted_2$5j, [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.shortcuts, (shortcut, key2) => { return ( openBlock(), createElementBlock( 'button', { key: key2, type: 'button', class: 'el-picker-panel__shortcut', onClick: ($event) => _ctx.handleShortcutClick(shortcut), }, toDisplayString$1(shortcut.text), 9, _hoisted_3$4H ) ) }), 128 )), ])) : createCommentVNode('v-if', true), createElementVNode('div', _hoisted_4$43, [ _ctx.showTime ? (openBlock(), createElementBlock('div', _hoisted_5$3E, [ createElementVNode('span', _hoisted_6$3d, [ createElementVNode('span', _hoisted_7$2R, [ createVNode$1( _component_el_input, { size: 'small', disabled: _ctx.rangeState.selecting, placeholder: _ctx.t('el.datepicker.startDate'), class: 'el-date-range-picker__editor', 'model-value': _ctx.minVisibleDate, onInput: _cache[0] || (_cache[0] = (val2) => _ctx.handleDateInput(val2, 'min')), onChange: _cache[1] || (_cache[1] = (val2) => _ctx.handleDateChange(val2, 'min')), }, null, 8, ['disabled', 'placeholder', 'model-value'] ), ]), withDirectives( (openBlock(), createElementBlock('span', _hoisted_8$2x, [ createVNode$1( _component_el_input, { size: 'small', class: 'el-date-range-picker__editor', disabled: _ctx.rangeState.selecting, placeholder: _ctx.t('el.datepicker.startTime'), 'model-value': _ctx.minVisibleTime, onFocus: _cache[2] || (_cache[2] = ($event) => (_ctx.minTimePickerVisible = true)), onInput: _cache[3] || (_cache[3] = (val2) => _ctx.handleTimeInput(val2, 'min')), onChange: _cache[4] || (_cache[4] = (val2) => _ctx.handleTimeChange(val2, 'min')), }, null, 8, ['disabled', 'placeholder', 'model-value'] ), createVNode$1( _component_time_pick_panel, { visible: _ctx.minTimePickerVisible, format: _ctx.timeFormat, 'datetime-role': 'start', 'time-arrow-control': _ctx.arrowControl, 'parsed-value': _ctx.leftDate, onPick: _ctx.handleMinTimePick, }, null, 8, [ 'visible', 'format', 'time-arrow-control', 'parsed-value', 'onPick', ] ), ])), [[_directive_clickoutside, _ctx.handleMinTimeClose]] ), ]), createElementVNode('span', null, [ createVNode$1(_component_el_icon, null, { default: withCtx(() => [ createVNode$1(_component_arrow_right), ]), _: 1, }), ]), createElementVNode('span', _hoisted_9$2l, [ createElementVNode('span', _hoisted_10$27, [ createVNode$1( _component_el_input, { size: 'small', class: 'el-date-range-picker__editor', disabled: _ctx.rangeState.selecting, placeholder: _ctx.t('el.datepicker.endDate'), 'model-value': _ctx.maxVisibleDate, readonly: !_ctx.minDate, onInput: _cache[5] || (_cache[5] = (val2) => _ctx.handleDateInput(val2, 'max')), onChange: _cache[6] || (_cache[6] = (val2) => _ctx.handleDateChange(val2, 'max')), }, null, 8, ['disabled', 'placeholder', 'model-value', 'readonly'] ), ]), withDirectives( (openBlock(), createElementBlock('span', _hoisted_11$1X, [ createVNode$1( _component_el_input, { size: 'small', class: 'el-date-range-picker__editor', disabled: _ctx.rangeState.selecting, placeholder: _ctx.t('el.datepicker.endTime'), 'model-value': _ctx.maxVisibleTime, readonly: !_ctx.minDate, onFocus: _cache[7] || (_cache[7] = ($event) => _ctx.minDate && (_ctx.maxTimePickerVisible = true)), onInput: _cache[8] || (_cache[8] = (val2) => _ctx.handleTimeInput(val2, 'max')), onChange: _cache[9] || (_cache[9] = (val2) => _ctx.handleTimeChange(val2, 'max')), }, null, 8, ['disabled', 'placeholder', 'model-value', 'readonly'] ), createVNode$1( _component_time_pick_panel, { 'datetime-role': 'end', visible: _ctx.maxTimePickerVisible, format: _ctx.timeFormat, 'time-arrow-control': _ctx.arrowControl, 'parsed-value': _ctx.rightDate, onPick: _ctx.handleMaxTimePick, }, null, 8, [ 'visible', 'format', 'time-arrow-control', 'parsed-value', 'onPick', ] ), ])), [[_directive_clickoutside, _ctx.handleMaxTimeClose]] ), ]), ])) : createCommentVNode('v-if', true), createElementVNode('div', _hoisted_12$1R, [ createElementVNode('div', _hoisted_13$1F, [ createElementVNode( 'button', { type: 'button', class: 'el-picker-panel__icon-btn d-arrow-left', onClick: _cache[10] || (_cache[10] = (...args) => _ctx.leftPrevYear && _ctx.leftPrevYear(...args)), }, [ createVNode$1(_component_el_icon, null, { default: withCtx(() => [ createVNode$1(_component_d_arrow_left), ]), _: 1, }), ] ), createElementVNode( 'button', { type: 'button', class: 'el-picker-panel__icon-btn arrow-left', onClick: _cache[11] || (_cache[11] = (...args) => _ctx.leftPrevMonth && _ctx.leftPrevMonth(...args)), }, [ createVNode$1(_component_el_icon, null, { default: withCtx(() => [ createVNode$1(_component_arrow_left), ]), _: 1, }), ] ), _ctx.unlinkPanels ? (openBlock(), createElementBlock( 'button', { key: 0, type: 'button', disabled: !_ctx.enableYearArrow, class: normalizeClass([ { 'is-disabled': !_ctx.enableYearArrow }, 'el-picker-panel__icon-btn d-arrow-right', ]), onClick: _cache[12] || (_cache[12] = (...args) => _ctx.leftNextYear && _ctx.leftNextYear(...args)), }, [ createVNode$1(_component_el_icon, null, { default: withCtx(() => [ createVNode$1(_component_d_arrow_right), ]), _: 1, }), ], 10, _hoisted_14$1s )) : createCommentVNode('v-if', true), _ctx.unlinkPanels ? (openBlock(), createElementBlock( 'button', { key: 1, type: 'button', disabled: !_ctx.enableMonthArrow, class: normalizeClass([ { 'is-disabled': !_ctx.enableMonthArrow }, 'el-picker-panel__icon-btn arrow-right', ]), onClick: _cache[13] || (_cache[13] = (...args) => _ctx.leftNextMonth && _ctx.leftNextMonth(...args)), }, [ createVNode$1(_component_el_icon, null, { default: withCtx(() => [ createVNode$1(_component_arrow_right), ]), _: 1, }), ], 10, _hoisted_15$1n )) : createCommentVNode('v-if', true), createElementVNode( 'div', null, toDisplayString$1(_ctx.leftLabel), 1 ), ]), createVNode$1( _component_date_table, { 'selection-mode': 'range', date: _ctx.leftDate, 'min-date': _ctx.minDate, 'max-date': _ctx.maxDate, 'range-state': _ctx.rangeState, 'disabled-date': _ctx.disabledDate, 'cell-class-name': _ctx.cellClassName, onChangerange: _ctx.handleChangeRange, onPick: _ctx.handleRangePick, onSelect: _ctx.onSelect, }, null, 8, [ 'date', 'min-date', 'max-date', 'range-state', 'disabled-date', 'cell-class-name', 'onChangerange', 'onPick', 'onSelect', ] ), ]), createElementVNode('div', _hoisted_16$1l, [ createElementVNode('div', _hoisted_17$1d, [ _ctx.unlinkPanels ? (openBlock(), createElementBlock( 'button', { key: 0, type: 'button', disabled: !_ctx.enableYearArrow, class: normalizeClass([ { 'is-disabled': !_ctx.enableYearArrow }, 'el-picker-panel__icon-btn d-arrow-left', ]), onClick: _cache[14] || (_cache[14] = (...args) => _ctx.rightPrevYear && _ctx.rightPrevYear(...args)), }, [ createVNode$1(_component_el_icon, null, { default: withCtx(() => [ createVNode$1(_component_d_arrow_left), ]), _: 1, }), ], 10, _hoisted_18$15 )) : createCommentVNode('v-if', true), _ctx.unlinkPanels ? (openBlock(), createElementBlock( 'button', { key: 1, type: 'button', disabled: !_ctx.enableMonthArrow, class: normalizeClass([ { 'is-disabled': !_ctx.enableMonthArrow }, 'el-picker-panel__icon-btn arrow-left', ]), onClick: _cache[15] || (_cache[15] = (...args) => _ctx.rightPrevMonth && _ctx.rightPrevMonth(...args)), }, [ createVNode$1(_component_el_icon, null, { default: withCtx(() => [ createVNode$1(_component_arrow_left), ]), _: 1, }), ], 10, _hoisted_19$10 )) : createCommentVNode('v-if', true), createElementVNode( 'button', { type: 'button', class: 'el-picker-panel__icon-btn d-arrow-right', onClick: _cache[16] || (_cache[16] = (...args) => _ctx.rightNextYear && _ctx.rightNextYear(...args)), }, [ createVNode$1(_component_el_icon, null, { default: withCtx(() => [ createVNode$1(_component_d_arrow_right), ]), _: 1, }), ] ), createElementVNode( 'button', { type: 'button', class: 'el-picker-panel__icon-btn arrow-right', onClick: _cache[17] || (_cache[17] = (...args) => _ctx.rightNextMonth && _ctx.rightNextMonth(...args)), }, [ createVNode$1(_component_el_icon, null, { default: withCtx(() => [ createVNode$1(_component_arrow_right), ]), _: 1, }), ] ), createElementVNode( 'div', null, toDisplayString$1(_ctx.rightLabel), 1 ), ]), createVNode$1( _component_date_table, { 'selection-mode': 'range', date: _ctx.rightDate, 'min-date': _ctx.minDate, 'max-date': _ctx.maxDate, 'range-state': _ctx.rangeState, 'disabled-date': _ctx.disabledDate, 'cell-class-name': _ctx.cellClassName, onChangerange: _ctx.handleChangeRange, onPick: _ctx.handleRangePick, onSelect: _ctx.onSelect, }, null, 8, [ 'date', 'min-date', 'max-date', 'range-state', 'disabled-date', 'cell-class-name', 'onChangerange', 'onPick', 'onSelect', ] ), ]), ]), ]), _ctx.showTime ? (openBlock(), createElementBlock('div', _hoisted_20$W, [ _ctx.clearable ? (openBlock(), createBlock( _component_el_button, { key: 0, size: 'small', type: 'text', class: 'el-picker-panel__link-btn', onClick: _ctx.handleClear, }, { default: withCtx(() => [ createTextVNode( toDisplayString$1(_ctx.t('el.datepicker.clear')), 1 ), ]), _: 1, }, 8, ['onClick'] )) : createCommentVNode('v-if', true), createVNode$1( _component_el_button, { plain: '', size: 'small', class: 'el-picker-panel__link-btn', disabled: _ctx.btnDisabled, onClick: _cache[18] || (_cache[18] = ($event) => _ctx.handleConfirm(false)), }, { default: withCtx(() => [ createTextVNode( toDisplayString$1(_ctx.t('el.datepicker.confirm')), 1 ), ]), _: 1, }, 8, ['disabled'] ), ])) : createCommentVNode('v-if', true), ], 2 ) ) } var DateRangePickPanel = /* @__PURE__ */ _export_sfc$1(_sfc_main$8p, [ ['render', _sfc_render$1a], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/date-picker/src/date-picker-com/panel-date-range.vue', ], ]) const _sfc_main$8o = defineComponent({ components: { MonthTable, ElIcon, DArrowLeft: dArrowLeft, DArrowRight: dArrowRight, }, props: { unlinkPanels: Boolean, parsedValue: { type: Array, }, }, emits: ['pick', 'set-picker-option'], setup(props2, ctx) { const { t: t3, lang } = useLocale() const leftDate = ref(dayjs().locale(lang.value)) const rightDate = ref(dayjs().locale(lang.value).add(1, 'year')) const hasShortcuts = computed(() => !!shortcuts.length) const handleShortcutClick = (shortcut) => { const shortcutValues = typeof shortcut.value === 'function' ? shortcut.value() : shortcut.value if (shortcutValues) { ctx.emit('pick', [ dayjs(shortcutValues[0]).locale(lang.value), dayjs(shortcutValues[1]).locale(lang.value), ]) return } if (shortcut.onClick) { shortcut.onClick(ctx) } } const leftPrevYear = () => { leftDate.value = leftDate.value.subtract(1, 'year') if (!props2.unlinkPanels) { rightDate.value = rightDate.value.subtract(1, 'year') } } const rightNextYear = () => { if (!props2.unlinkPanels) { leftDate.value = leftDate.value.add(1, 'year') } rightDate.value = rightDate.value.add(1, 'year') } const leftNextYear = () => { leftDate.value = leftDate.value.add(1, 'year') } const rightPrevYear = () => { rightDate.value = rightDate.value.subtract(1, 'year') } const leftLabel = computed(() => { return `${leftDate.value.year()} ${t3('el.datepicker.year')}` }) const rightLabel = computed(() => { return `${rightDate.value.year()} ${t3('el.datepicker.year')}` }) const leftYear = computed(() => { return leftDate.value.year() }) const rightYear = computed(() => { return rightDate.value.year() === leftDate.value.year() ? leftDate.value.year() + 1 : rightDate.value.year() }) const enableYearArrow = computed(() => { return props2.unlinkPanels && rightYear.value > leftYear.value + 1 }) const minDate = ref(null) const maxDate = ref(null) const rangeState = ref({ endDate: null, selecting: false, }) const handleChangeRange = (val2) => { rangeState.value = val2 } const handleRangePick = (val2, close2 = true) => { const minDate_ = val2.minDate const maxDate_ = val2.maxDate if (maxDate.value === maxDate_ && minDate.value === minDate_) { return } maxDate.value = maxDate_ minDate.value = minDate_ if (!close2) return handleConfirm() } const isValidValue = (value2) => { return ( Array.isArray(value2) && value2 && value2[0] && value2[1] && value2[0].valueOf() <= value2[1].valueOf() ) } const handleConfirm = (visible = false) => { if (isValidValue([minDate.value, maxDate.value])) { ctx.emit('pick', [minDate.value, maxDate.value], visible) } } const onSelect = (selecting) => { rangeState.value.selecting = selecting if (!selecting) { rangeState.value.endDate = null } } const formatToString = (value2) => { return value2.map((_2) => _2.format(format2)) } const getDefaultValue = () => { let start2 if (Array.isArray(defaultValue.value)) { const left2 = dayjs(defaultValue.value[0]) let right2 = dayjs(defaultValue.value[1]) if (!props2.unlinkPanels) { right2 = left2.add(1, 'year') } return [left2, right2] } else if (defaultValue.value) { start2 = dayjs(defaultValue.value) } else { start2 = dayjs() } start2 = start2.locale(lang.value) return [start2, start2.add(1, 'year')] } ctx.emit('set-picker-option', ['formatToString', formatToString]) const pickerBase = inject('EP_PICKER_BASE') const { shortcuts, disabledDate, format: format2 } = pickerBase.props const defaultValue = toRef(pickerBase.props, 'defaultValue') watch$1( () => defaultValue.value, (val2) => { if (val2) { const defaultArr = getDefaultValue() leftDate.value = defaultArr[0] rightDate.value = defaultArr[1] } }, { immediate: true } ) watch$1( () => props2.parsedValue, (newVal) => { if (newVal && newVal.length === 2) { minDate.value = newVal[0] maxDate.value = newVal[1] leftDate.value = minDate.value if (props2.unlinkPanels && maxDate.value) { const minDateYear = minDate.value.year() const maxDateYear = maxDate.value.year() rightDate.value = minDateYear === maxDateYear ? maxDate.value.add(1, 'year') : maxDate.value } else { rightDate.value = leftDate.value.add(1, 'year') } } else { const defaultArr = getDefaultValue() minDate.value = null maxDate.value = null leftDate.value = defaultArr[0] rightDate.value = defaultArr[1] } }, { immediate: true } ) return { shortcuts, disabledDate, onSelect, handleRangePick, rangeState, handleChangeRange, minDate, maxDate, enableYearArrow, leftLabel, rightLabel, leftNextYear, leftPrevYear, rightNextYear, rightPrevYear, t: t3, leftDate, rightDate, hasShortcuts, handleShortcutClick, } }, }) const _hoisted_1$6B = { class: 'el-picker-panel__body-wrapper' } const _hoisted_2$5i = { key: 0, class: 'el-picker-panel__sidebar', } const _hoisted_3$4G = ['onClick'] const _hoisted_4$42 = { class: 'el-picker-panel__body' } const _hoisted_5$3D = { class: 'el-picker-panel__content el-date-range-picker__content is-left', } const _hoisted_6$3c = { class: 'el-date-range-picker__header' } const _hoisted_7$2Q = ['disabled'] const _hoisted_8$2w = { class: 'el-picker-panel__content el-date-range-picker__content is-right', } const _hoisted_9$2k = { class: 'el-date-range-picker__header' } const _hoisted_10$26 = ['disabled'] function _sfc_render$19(_ctx, _cache, $props2, $setup, $data, $options) { const _component_d_arrow_left = resolveComponent('d-arrow-left') const _component_el_icon = resolveComponent('el-icon') const _component_d_arrow_right = resolveComponent('d-arrow-right') const _component_month_table = resolveComponent('month-table') return ( openBlock(), createElementBlock( 'div', { class: normalizeClass([ 'el-picker-panel el-date-range-picker', [ { 'has-sidebar': _ctx.$slots.sidebar || _ctx.hasShortcuts, }, ], ]), }, [ createElementVNode('div', _hoisted_1$6B, [ renderSlot(_ctx.$slots, 'sidebar', { class: 'el-picker-panel__sidebar', }), _ctx.hasShortcuts ? (openBlock(), createElementBlock('div', _hoisted_2$5i, [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.shortcuts, (shortcut, key2) => { return ( openBlock(), createElementBlock( 'button', { key: key2, type: 'button', class: 'el-picker-panel__shortcut', onClick: ($event) => _ctx.handleShortcutClick(shortcut), }, toDisplayString$1(shortcut.text), 9, _hoisted_3$4G ) ) }), 128 )), ])) : createCommentVNode('v-if', true), createElementVNode('div', _hoisted_4$42, [ createElementVNode('div', _hoisted_5$3D, [ createElementVNode('div', _hoisted_6$3c, [ createElementVNode( 'button', { type: 'button', class: 'el-picker-panel__icon-btn d-arrow-left', onClick: _cache[0] || (_cache[0] = (...args) => _ctx.leftPrevYear && _ctx.leftPrevYear(...args)), }, [ createVNode$1(_component_el_icon, null, { default: withCtx(() => [ createVNode$1(_component_d_arrow_left), ]), _: 1, }), ] ), _ctx.unlinkPanels ? (openBlock(), createElementBlock( 'button', { key: 0, type: 'button', disabled: !_ctx.enableYearArrow, class: normalizeClass([ { 'is-disabled': !_ctx.enableYearArrow }, 'el-picker-panel__icon-btn d-arrow-right', ]), onClick: _cache[1] || (_cache[1] = (...args) => _ctx.leftNextYear && _ctx.leftNextYear(...args)), }, [ createVNode$1(_component_el_icon, null, { default: withCtx(() => [ createVNode$1(_component_d_arrow_right), ]), _: 1, }), ], 10, _hoisted_7$2Q )) : createCommentVNode('v-if', true), createElementVNode( 'div', null, toDisplayString$1(_ctx.leftLabel), 1 ), ]), createVNode$1( _component_month_table, { 'selection-mode': 'range', date: _ctx.leftDate, 'min-date': _ctx.minDate, 'max-date': _ctx.maxDate, 'range-state': _ctx.rangeState, 'disabled-date': _ctx.disabledDate, onChangerange: _ctx.handleChangeRange, onPick: _ctx.handleRangePick, onSelect: _ctx.onSelect, }, null, 8, [ 'date', 'min-date', 'max-date', 'range-state', 'disabled-date', 'onChangerange', 'onPick', 'onSelect', ] ), ]), createElementVNode('div', _hoisted_8$2w, [ createElementVNode('div', _hoisted_9$2k, [ _ctx.unlinkPanels ? (openBlock(), createElementBlock( 'button', { key: 0, type: 'button', disabled: !_ctx.enableYearArrow, class: normalizeClass([ { 'is-disabled': !_ctx.enableYearArrow }, 'el-picker-panel__icon-btn d-arrow-left', ]), onClick: _cache[2] || (_cache[2] = (...args) => _ctx.rightPrevYear && _ctx.rightPrevYear(...args)), }, [ createVNode$1(_component_el_icon, null, { default: withCtx(() => [ createVNode$1(_component_d_arrow_left), ]), _: 1, }), ], 10, _hoisted_10$26 )) : createCommentVNode('v-if', true), createElementVNode( 'button', { type: 'button', class: 'el-picker-panel__icon-btn d-arrow-right', onClick: _cache[3] || (_cache[3] = (...args) => _ctx.rightNextYear && _ctx.rightNextYear(...args)), }, [ createVNode$1(_component_el_icon, null, { default: withCtx(() => [ createVNode$1(_component_d_arrow_right), ]), _: 1, }), ] ), createElementVNode( 'div', null, toDisplayString$1(_ctx.rightLabel), 1 ), ]), createVNode$1( _component_month_table, { 'selection-mode': 'range', date: _ctx.rightDate, 'min-date': _ctx.minDate, 'max-date': _ctx.maxDate, 'range-state': _ctx.rangeState, 'disabled-date': _ctx.disabledDate, onChangerange: _ctx.handleChangeRange, onPick: _ctx.handleRangePick, onSelect: _ctx.onSelect, }, null, 8, [ 'date', 'min-date', 'max-date', 'range-state', 'disabled-date', 'onChangerange', 'onPick', 'onSelect', ] ), ]), ]), ]), ], 2 ) ) } var MonthRangePickPanel = /* @__PURE__ */ _export_sfc$1(_sfc_main$8o, [ ['render', _sfc_render$19], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/date-picker/src/date-picker-com/panel-month-range.vue', ], ]) dayjs.extend(localeData) dayjs.extend(advancedFormat) dayjs.extend(customParseFormat) dayjs.extend(weekOfYear) dayjs.extend(weekYear) dayjs.extend(dayOfYear) dayjs.extend(isSameOrAfter) dayjs.extend(isSameOrBefore) const getPanel = function (type4) { if (type4 === 'daterange' || type4 === 'datetimerange') { return DateRangePickPanel } else if (type4 === 'monthrange') { return MonthRangePickPanel } return DatePickPanel } var DatePicker = defineComponent({ name: 'ElDatePicker', install: null, props: { ...timePickerDefaultProps, type: { type: String, default: 'date', }, }, emits: ['update:modelValue'], setup(props2, ctx) { provide('ElPopperOptions', props2.popperOptions) provide(ROOT_PICKER_INJECTION_KEY, { ctx, }) const commonPicker = ref(null) const refProps = { ...props2, focus: (focusStartInput = true) => { var _a2 ;(_a2 = commonPicker.value) == null ? void 0 : _a2.focus(focusStartInput) }, } ctx.expose(refProps) return () => { var _a2 const format2 = (_a2 = props2.format) != null ? _a2 : DEFAULT_FORMATS_DATEPICKER[props2.type] || DEFAULT_FORMATS_DATE return h$4( CommonPicker, { ...props2, format: format2, type: props2.type, ref: commonPicker, 'onUpdate:modelValue': (value2) => ctx.emit('update:modelValue', value2), }, { default: (scopedProps) => h$4(getPanel(props2.type), scopedProps), 'range-separator': () => renderSlot(ctx.slots, 'range-separator'), } ) } }, }) const _DatePicker = DatePicker _DatePicker.install = (app2) => { app2.component(_DatePicker.name, _DatePicker) } const ElDatePicker = _DatePicker const elDescriptionsKey = 'elDescriptions' var DescriptionsCell = defineComponent({ name: 'ElDescriptionsCell', props: { cell: { type: Object, }, tag: { type: String, }, type: { type: String, }, }, setup() { const descriptions = inject(elDescriptionsKey, {}) return { descriptions, } }, render() { var _a2, _b2, _c2, _d, _e, _f const item2 = getNormalizedProps(this.cell) const { border, direction: direction2 } = this.descriptions const isVertical = direction2 === 'vertical' const label = ((_c2 = (_b2 = (_a2 = this.cell) == null ? void 0 : _a2.children) == null ? void 0 : _b2.label) == null ? void 0 : _c2.call(_b2)) || item2.label const content2 = (_f = (_e = (_d = this.cell) == null ? void 0 : _d.children) == null ? void 0 : _e.default) == null ? void 0 : _f.call(_e) const span = item2.span const align = item2.align ? `is-${item2.align}` : '' const labelAlign = item2.labelAlign ? `is-${item2.labelAlign}` : align const className = item2.className const labelClassName = item2.labelClassName const style2 = { width: addUnit(item2.width), minWidth: addUnit(item2.minWidth), } const ns = useNamespace('descriptions') switch (this.type) { case 'label': return h$4( this.tag, { style: style2, class: [ ns.e('cell'), ns.e('label'), ns.is('bordered-label', border), ns.is('vertical-label', isVertical), labelAlign, labelClassName, ], colSpan: isVertical ? span : 1, }, label ) case 'content': return h$4( this.tag, { style: style2, class: [ ns.e('cell'), ns.e('content'), ns.is('bordered-content', border), ns.is('vertical-content', isVertical), align, className, ], colSpan: isVertical ? span : span * 2 - 1, }, content2 ) default: return h$4( 'td', { style: style2, class: [ns.e('cell'), align], colSpan: span, }, [ h$4( 'span', { class: [ns.e('label'), labelClassName], }, label ), h$4( 'span', { class: [ns.e('content'), className], }, content2 ), ] ) } }, }) const _sfc_main$8n = defineComponent({ name: 'ElDescriptionsRow', components: { [DescriptionsCell.name]: DescriptionsCell, }, props: { row: { type: Array, }, }, setup() { const descriptions = inject(elDescriptionsKey, {}) return { descriptions, } }, }) const _hoisted_1$6A = { key: 1 } function _sfc_render$18(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_descriptions_cell = resolveComponent( 'el-descriptions-cell' ) return _ctx.descriptions.direction === 'vertical' ? (openBlock(), createElementBlock( Fragment, { key: 0 }, [ createElementVNode('tr', null, [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.row, (cell, index2) => { return ( openBlock(), createBlock( _component_el_descriptions_cell, { key: `tr1-${index2}`, cell, tag: 'th', type: 'label', }, null, 8, ['cell'] ) ) }), 128 )), ]), createElementVNode('tr', null, [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.row, (cell, index2) => { return ( openBlock(), createBlock( _component_el_descriptions_cell, { key: `tr2-${index2}`, cell, tag: 'td', type: 'content', }, null, 8, ['cell'] ) ) }), 128 )), ]), ], 64 )) : (openBlock(), createElementBlock('tr', _hoisted_1$6A, [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.row, (cell, index2) => { return ( openBlock(), createElementBlock( Fragment, { key: `tr3-${index2}`, }, [ _ctx.descriptions.border ? (openBlock(), createElementBlock( Fragment, { key: 0 }, [ createVNode$1( _component_el_descriptions_cell, { cell, tag: 'td', type: 'label', }, null, 8, ['cell'] ), createVNode$1( _component_el_descriptions_cell, { cell, tag: 'td', type: 'content', }, null, 8, ['cell'] ), ], 64 )) : (openBlock(), createBlock( _component_el_descriptions_cell, { key: 1, cell, tag: 'td', type: 'both', }, null, 8, ['cell'] )), ], 64 ) ) }), 128 )), ])) } var DescriptionsRow = /* @__PURE__ */ _export_sfc$1(_sfc_main$8n, [ ['render', _sfc_render$18], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/descriptions/src/descriptions-row.vue', ], ]) const _sfc_main$8m = defineComponent({ name: 'ElDescriptions', components: { [DescriptionsRow.name]: DescriptionsRow, }, props: { border: { type: Boolean, default: false, }, column: { type: Number, default: 3, }, direction: { type: String, default: 'horizontal', }, size: { type: String, validator: isValidComponentSize, }, title: { type: String, default: '', }, extra: { type: String, default: '', }, }, setup(props2, { slots }) { provide(elDescriptionsKey, props2) const descriptionsSize = useSize$1() const ns = useNamespace('descriptions') const descriptionKls = computed(() => [ ns.b(), ns.is(ns.m(descriptionsSize.value), !!descriptionsSize.value), ]) const flattedChildren = (children) => { const temp = Array.isArray(children) ? children : [children] const res = [] temp.forEach((child) => { if (Array.isArray(child.children)) { res.push(...flattedChildren(child.children)) } else { res.push(child) } }) return res } const filledNode = (node2, span, count2, isLast = false) => { if (!node2.props) { node2.props = {} } if (span > count2) { node2.props.span = count2 } if (isLast) { node2.props.span = span } return node2 } const getRows = () => { var _a2 const children = flattedChildren( (_a2 = slots.default) == null ? void 0 : _a2.call(slots) ).filter((node2) => { var _a22 return ( ((_a22 = node2 == null ? void 0 : node2.type) == null ? void 0 : _a22.name) === 'ElDescriptionsItem' ) }) const rows = [] let temp = [] let count2 = props2.column let totalSpan = 0 children.forEach((node2, index2) => { var _a22 const span = ((_a22 = node2.props) == null ? void 0 : _a22.span) || 1 if (index2 < children.length - 1) { totalSpan += span > count2 ? count2 : span } if (index2 === children.length - 1) { const lastSpan = props2.column - (totalSpan % props2.column) temp.push(filledNode(node2, lastSpan, count2, true)) rows.push(temp) return } if (span < count2) { count2 -= span temp.push(node2) } else { temp.push(filledNode(node2, span, count2)) rows.push(temp) count2 = props2.column temp = [] } }) return rows } return { descriptionKls, getRows, ns, } }, }) function _sfc_render$17(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_descriptions_row = resolveComponent('el-descriptions-row') return ( openBlock(), createElementBlock( 'div', { class: normalizeClass(_ctx.descriptionKls), }, [ _ctx.title || _ctx.extra || _ctx.$slots.title || _ctx.$slots.extra ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass(_ctx.ns.e('header')), }, [ createElementVNode( 'div', { class: normalizeClass(_ctx.ns.e('title')), }, [ renderSlot(_ctx.$slots, 'title', {}, () => [ createTextVNode(toDisplayString$1(_ctx.title), 1), ]), ], 2 ), createElementVNode( 'div', { class: normalizeClass(_ctx.ns.e('extra')), }, [ renderSlot(_ctx.$slots, 'extra', {}, () => [ createTextVNode(toDisplayString$1(_ctx.extra), 1), ]), ], 2 ), ], 2 )) : createCommentVNode('v-if', true), createElementVNode( 'div', { class: normalizeClass(_ctx.ns.e('body')), }, [ createElementVNode( 'table', { class: normalizeClass([ _ctx.ns.e('table'), _ctx.ns.is('bordered', _ctx.border), ]), }, [ createElementVNode('tbody', null, [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.getRows(), (row, index2) => { return ( openBlock(), createBlock( _component_el_descriptions_row, { key: index2, row, }, null, 8, ['row'] ) ) }), 128 )), ]), ], 2 ), ], 2 ), ], 2 ) ) } var Descriptions = /* @__PURE__ */ _export_sfc$1(_sfc_main$8m, [ ['render', _sfc_render$17], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/descriptions/src/index.vue', ], ]) var DescriptionsItem = defineComponent({ name: 'ElDescriptionsItem', props: { label: { type: String, default: '', }, span: { type: Number, default: 1, }, width: { type: [String, Number], default: '', }, minWidth: { type: [String, Number], default: '', }, align: { type: String, default: 'left', }, labelAlign: { type: String, default: '', }, className: { type: String, default: '', }, labelClassName: { type: String, default: '', }, }, }) const ElDescriptions = withInstall(Descriptions, { DescriptionsItem, }) const ElDescriptionsItem = withNoopInstall(DescriptionsItem) const overlayProps = buildProps({ mask: { type: Boolean, default: true, }, customMaskEvent: { type: Boolean, default: false, }, overlayClass: { type: definePropType([String, Array, Object]), }, zIndex: { type: definePropType([String, Number]), }, }) const overlayEmits = { click: (evt) => evt instanceof MouseEvent, } var Overlay = defineComponent({ name: 'ElOverlay', props: overlayProps, emits: overlayEmits, setup(props2, { slots, emit: emit2 }) { const ns = useNamespace('overlay') const onMaskClick = (e2) => { emit2('click', e2) } const { onClick, onMousedown, onMouseup } = useSameTarget( props2.customMaskEvent ? void 0 : onMaskClick ) return () => { return props2.mask ? createVNode$1( 'div', { class: [ns.b(), props2.overlayClass], style: { zIndex: props2.zIndex, }, onClick, onMousedown, onMouseup, }, [renderSlot(slots, 'default')], PatchFlags.STYLE | PatchFlags.CLASS | PatchFlags.PROPS, ['onClick', 'onMouseup', 'onMousedown'] ) : h$4( 'div', { class: props2.overlayClass, style: { zIndex: props2.zIndex, position: 'fixed', top: '0px', right: '0px', bottom: '0px', left: '0px', }, }, [renderSlot(slots, 'default')] ) } }, }) const ElOverlay = Overlay const dialogContentProps = buildProps({ center: { type: Boolean, default: false, }, closeIcon: { type: iconPropType, default: '', }, customClass: { type: String, default: '', }, draggable: { type: Boolean, default: false, }, fullscreen: { type: Boolean, default: false, }, showClose: { type: Boolean, default: true, }, title: { type: String, default: '', }, }) const dialogContentEmits = { close: () => true, } const _hoisted_1$6z = ['aria-label'] const __default__$q = { name: 'ElDialogContent' } const _sfc_main$8l = /* @__PURE__ */ defineComponent({ ...__default__$q, props: dialogContentProps, emits: dialogContentEmits, setup(__props2) { const { Close } = CloseComponents const { dialogRef, headerRef, ns, style: style2, } = inject(dialogInjectionKey) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { ref_key: 'dialogRef', ref: dialogRef, class: normalizeClass([ unref(ns).b(), unref(ns).is('fullscreen', _ctx.fullscreen), unref(ns).is('draggable', _ctx.draggable), { [unref(ns).m('center')]: _ctx.center }, _ctx.customClass, ]), 'aria-modal': 'true', role: 'dialog', 'aria-label': _ctx.title || 'dialog', style: normalizeStyle$1(unref(style2)), onClick: _cache[1] || (_cache[1] = withModifiers(() => {}, ['stop'])), }, [ createElementVNode( 'div', { ref_key: 'headerRef', ref: headerRef, class: normalizeClass(unref(ns).e('header')), }, [ renderSlot(_ctx.$slots, 'title', {}, () => [ createElementVNode( 'span', { class: normalizeClass(unref(ns).e('title')), }, toDisplayString$1(_ctx.title), 3 ), ]), ], 2 ), createElementVNode( 'div', { class: normalizeClass(unref(ns).e('body')), }, [renderSlot(_ctx.$slots, 'default')], 2 ), _ctx.$slots.footer ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass(unref(ns).e('footer')), }, [renderSlot(_ctx.$slots, 'footer')], 2 )) : createCommentVNode('v-if', true), _ctx.showClose ? (openBlock(), createElementBlock( 'button', { key: 1, 'aria-label': 'close', class: normalizeClass(unref(ns).e('headerbtn')), type: 'button', onClick: _cache[0] || (_cache[0] = ($event) => _ctx.$emit('close')), }, [ createVNode$1( unref(ElIcon), { class: normalizeClass(unref(ns).e('close')), }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent( _ctx.closeIcon || unref(Close) ) )), ]), _: 1, }, 8, ['class'] ), ], 2 )) : createCommentVNode('v-if', true), ], 14, _hoisted_1$6z ) ) } }, }) var ElDialogContent = /* @__PURE__ */ _export_sfc$1(_sfc_main$8l, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/dialog/src/dialog-content.vue', ], ]) const dialogProps = buildProps({ ...dialogContentProps, appendToBody: { type: Boolean, default: false, }, beforeClose: { type: definePropType(Function), }, destroyOnClose: { type: Boolean, default: false, }, closeOnClickModal: { type: Boolean, default: true, }, closeOnPressEscape: { type: Boolean, default: true, }, lockScroll: { type: Boolean, default: true, }, modal: { type: Boolean, default: true, }, openDelay: { type: Number, default: 0, }, closeDelay: { type: Number, default: 0, }, top: { type: String, }, modelValue: { type: Boolean, required: true, }, modalClass: String, width: { type: [String, Number], }, zIndex: { type: Number, }, trapFocus: { type: Boolean, default: false, }, }) const dialogEmits = { open: () => true, opened: () => true, close: () => true, closed: () => true, [UPDATE_MODEL_EVENT]: (value2) => isBoolean$5(value2), openAutoFocus: () => true, closeAutoFocus: () => true, } const useDialog = (props2, targetRef) => { const instance = getCurrentInstance() const emit2 = instance.emit const { nextZIndex: nextZIndex2 } = useZIndex() let lastPosition = '' const visible = ref(false) const closed = ref(false) const rendered = ref(false) const zIndex2 = ref(props2.zIndex || nextZIndex2()) let openTimer = void 0 let closeTimer = void 0 const normalizeWidth = computed(() => isNumber$h(props2.width) ? `${props2.width}px` : props2.width ) const style2 = computed(() => { const style22 = {} const varPrefix = `--el-dialog` if (!props2.fullscreen) { if (props2.top) { style22[`${varPrefix}-margin-top`] = props2.top } if (props2.width) { style22[`${varPrefix}-width`] = normalizeWidth.value } } return style22 }) function afterEnter() { emit2('opened') } function afterLeave() { emit2('closed') emit2(UPDATE_MODEL_EVENT, false) if (props2.destroyOnClose) { rendered.value = false } } function beforeLeave() { emit2('close') } function open2() { closeTimer == null ? void 0 : closeTimer() openTimer == null ? void 0 : openTimer() if (props2.openDelay && props2.openDelay > 0) { ;({ stop: openTimer } = useTimeoutFn$1(() => doOpen(), props2.openDelay)) } else { doOpen() } } function close2() { openTimer == null ? void 0 : openTimer() closeTimer == null ? void 0 : closeTimer() if (props2.closeDelay && props2.closeDelay > 0) { ;({ stop: closeTimer } = useTimeoutFn$1( () => doClose(), props2.closeDelay )) } else { doClose() } } function handleClose() { function hide2(shouldCancel) { if (shouldCancel) return closed.value = true visible.value = false } if (props2.beforeClose) { props2.beforeClose(hide2) } else { close2() } } function onModalClick() { if (props2.closeOnClickModal) { handleClose() } } function doOpen() { if (!isClient$1) return visible.value = true } function doClose() { visible.value = false } if (props2.lockScroll) { useLockscreen(visible) } if (props2.closeOnPressEscape) { useModal( { handleClose, }, visible ) } useRestoreActive(visible) watch$1( () => props2.modelValue, (val2) => { if (val2) { closed.value = false open2() rendered.value = true emit2('open') zIndex2.value = props2.zIndex ? zIndex2.value++ : nextZIndex2() nextTick(() => { if (targetRef.value) { targetRef.value.scrollTop = 0 } }) } else { if (visible.value) { close2() } } } ) watch$1( () => props2.fullscreen, (val2) => { if (!targetRef.value) return if (val2) { lastPosition = targetRef.value.style.transform targetRef.value.style.transform = '' } else { targetRef.value.style.transform = lastPosition } } ) onMounted(() => { if (props2.modelValue) { visible.value = true rendered.value = true open2() } }) return { afterEnter, afterLeave, beforeLeave, handleClose, onModalClick, close: close2, doClose, closed, style: style2, rendered, visible, zIndex: zIndex2, } } const __default__$p = { name: 'ElDialog', } const _sfc_main$8k = /* @__PURE__ */ defineComponent({ ...__default__$p, props: dialogProps, emits: dialogEmits, setup(__props2, { expose }) { const props2 = __props2 const ns = useNamespace('dialog') const dialogRef = ref() const headerRef = ref() const { visible, style: style2, rendered, zIndex: zIndex2, afterEnter, afterLeave, beforeLeave, handleClose, onModalClick, } = useDialog(props2, dialogRef) provide(dialogInjectionKey, { dialogRef, headerRef, ns, rendered, style: style2, }) const overlayEvent = useSameTarget(onModalClick) const draggable2 = computed(() => props2.draggable && !props2.fullscreen) useDraggable$1(dialogRef, headerRef, draggable2) expose({ visible, }) return (_ctx, _cache) => { return ( openBlock(), createBlock( Teleport, { to: 'body', disabled: !_ctx.appendToBody, }, [ createVNode$1( Transition, { name: 'dialog-fade', onAfterEnter: unref(afterEnter), onAfterLeave: unref(afterLeave), onBeforeLeave: unref(beforeLeave), }, { default: withCtx(() => [ withDirectives( createVNode$1( unref(ElOverlay), { 'custom-mask-event': '', mask: _ctx.modal, 'overlay-class': _ctx.modalClass, 'z-index': unref(zIndex2), }, { default: withCtx(() => [ createElementVNode( 'div', { class: normalizeClass( `${unref(ns).namespace.value}-overlay-dialog` ), onClick: _cache[0] || (_cache[0] = (...args) => unref(overlayEvent).onClick && unref(overlayEvent).onClick(...args)), onMousedown: _cache[1] || (_cache[1] = (...args) => unref(overlayEvent).onMousedown && unref(overlayEvent).onMousedown(...args)), onMouseup: _cache[2] || (_cache[2] = (...args) => unref(overlayEvent).onMouseup && unref(overlayEvent).onMouseup(...args)), }, [ unref(rendered) ? (openBlock(), createBlock( ElDialogContent, { key: 0, 'custom-class': _ctx.customClass, center: _ctx.center, 'close-icon': _ctx.closeIcon, draggable: unref(draggable2), fullscreen: _ctx.fullscreen, 'show-close': _ctx.showClose, style: normalizeStyle$1(unref(style2)), title: _ctx.title, onClose: unref(handleClose), }, createSlots( { title: withCtx(() => [ renderSlot(_ctx.$slots, 'title'), ]), default: withCtx(() => [ renderSlot(_ctx.$slots, 'default'), ]), _: 2, }, [ _ctx.$slots.footer ? { name: 'footer', fn: withCtx(() => [ renderSlot( _ctx.$slots, 'footer' ), ]), } : void 0, ] ), 1032, [ 'custom-class', 'center', 'close-icon', 'draggable', 'fullscreen', 'show-close', 'style', 'title', 'onClose', ] )) : createCommentVNode('v-if', true), ], 34 ), ]), _: 3, }, 8, ['mask', 'overlay-class', 'z-index'] ), [[vShow, unref(visible)]] ), ]), _: 3, }, 8, ['onAfterEnter', 'onAfterLeave', 'onBeforeLeave'] ), ], 8, ['disabled'] ) ) } }, }) var Dialog$5 = /* @__PURE__ */ _export_sfc$1(_sfc_main$8k, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/dialog/src/dialog.vue', ], ]) const ElDialog = withInstall(Dialog$5) const dividerProps = buildProps({ direction: { type: String, values: ['horizontal', 'vertical'], default: 'horizontal', }, contentPosition: { type: String, values: ['left', 'center', 'right'], default: 'center', }, borderStyle: { type: definePropType(String), default: 'solid', }, }) const __default__$o = { name: 'ElDivider', } const _sfc_main$8j = /* @__PURE__ */ defineComponent({ ...__default__$o, props: dividerProps, setup(__props2) { const props2 = __props2 const ns = useNamespace('divider') const dividerStyle = computed(() => { return { '--el-border-style': props2.borderStyle, } }) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { class: normalizeClass([unref(ns).b(), unref(ns).m(_ctx.direction)]), style: normalizeStyle$1(unref(dividerStyle)), }, [ _ctx.$slots.default && _ctx.direction !== 'vertical' ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass([ unref(ns).e('text'), unref(ns).is(_ctx.contentPosition), ]), }, [renderSlot(_ctx.$slots, 'default')], 2 )) : createCommentVNode('v-if', true), ], 6 ) ) } }, }) var Divider = /* @__PURE__ */ _export_sfc$1(_sfc_main$8j, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/divider/src/divider.vue', ], ]) const ElDivider = withInstall(Divider) const drawerProps = buildProps({ ...dialogProps, direction: { type: String, default: 'rtl', values: ['ltr', 'rtl', 'ttb', 'btt'], }, size: { type: [String, Number], default: '30%', }, withHeader: { type: Boolean, default: true, }, modalFade: { type: Boolean, default: true, }, }) const drawerEmits = dialogEmits const _sfc_main$8i = defineComponent({ name: 'ElDrawer', components: { ElOverlay, ElIcon, Close: close$2, }, directives: { TrapFocus, }, props: drawerProps, emits: drawerEmits, setup(props2, ctx) { const drawerRef = ref() const ns = useNamespace('drawer') const isHorizontal2 = computed( () => props2.direction === 'rtl' || props2.direction === 'ltr' ) const drawerSize = computed(() => typeof props2.size === 'number' ? `${props2.size}px` : props2.size ) return { ...useDialog(props2, ctx), drawerRef, isHorizontal: isHorizontal2, drawerSize, ns, } }, }) const _hoisted_1$6y = ['aria-labelledby', 'aria-label'] const _hoisted_2$5h = ['id'] const _hoisted_3$4F = ['title'] const _hoisted_4$41 = ['aria-label'] function _sfc_render$16(_ctx, _cache, $props2, $setup, $data, $options) { const _component_close = resolveComponent('close') const _component_el_icon = resolveComponent('el-icon') const _component_el_overlay = resolveComponent('el-overlay') const _directive_trap_focus = resolveDirective('trap-focus') return ( openBlock(), createBlock( Teleport, { to: 'body', disabled: !_ctx.appendToBody, }, [ createVNode$1( Transition, { name: _ctx.ns.b('fade'), onAfterEnter: _ctx.afterEnter, onAfterLeave: _ctx.afterLeave, onBeforeLeave: _ctx.beforeLeave, }, { default: withCtx(() => [ withDirectives( createVNode$1( _component_el_overlay, { mask: _ctx.modal, 'overlay-class': _ctx.modalClass, 'z-index': _ctx.zIndex, onClick: _ctx.onModalClick, }, { default: withCtx(() => [ withDirectives( (openBlock(), createElementBlock( 'div', { ref: 'drawerRef', 'aria-modal': 'true', 'aria-labelledby': _ctx.ns.e('title'), 'aria-label': _ctx.title, class: normalizeClass([ _ctx.ns.b(), _ctx.direction, _ctx.visible && 'open', _ctx.customClass, ]), style: normalizeStyle$1( _ctx.isHorizontal ? 'width: ' + _ctx.drawerSize : 'height: ' + _ctx.drawerSize ), role: 'dialog', onClick: _cache[1] || (_cache[1] = withModifiers(() => {}, ['stop'])), }, [ _ctx.withHeader ? (openBlock(), createElementBlock( 'header', { key: 0, id: _ctx.ns.e('title'), class: normalizeClass(_ctx.ns.e('header')), }, [ renderSlot(_ctx.$slots, 'title', {}, () => [ createElementVNode( 'span', { role: 'heading', title: _ctx.title, }, toDisplayString$1(_ctx.title), 9, _hoisted_3$4F ), ]), _ctx.showClose ? (openBlock(), createElementBlock( 'button', { key: 0, 'aria-label': 'close ' + (_ctx.title || 'drawer'), class: normalizeClass( _ctx.ns.e('close-btn') ), type: 'button', onClick: _cache[0] || (_cache[0] = (...args) => _ctx.handleClose && _ctx.handleClose(...args)), }, [ createVNode$1( _component_el_icon, { class: normalizeClass( _ctx.ns.e('close') ), }, { default: withCtx(() => [ createVNode$1( _component_close ), ]), _: 1, }, 8, ['class'] ), ], 10, _hoisted_4$41 )) : createCommentVNode('v-if', true), ], 10, _hoisted_2$5h )) : createCommentVNode('v-if', true), _ctx.rendered ? (openBlock(), createElementBlock( 'section', { key: 1, class: normalizeClass(_ctx.ns.e('body')), }, [renderSlot(_ctx.$slots, 'default')], 2 )) : createCommentVNode('v-if', true), _ctx.$slots.footer ? (openBlock(), createElementBlock( 'div', { key: 2, class: normalizeClass(_ctx.ns.e('footer')), }, [renderSlot(_ctx.$slots, 'footer')], 2 )) : createCommentVNode('v-if', true), ], 14, _hoisted_1$6y )), [[_directive_trap_focus]] ), ]), _: 3, }, 8, ['mask', 'overlay-class', 'z-index', 'onClick'] ), [[vShow, _ctx.visible]] ), ]), _: 3, }, 8, ['name', 'onAfterEnter', 'onAfterLeave', 'onBeforeLeave'] ), ], 8, ['disabled'] ) ) } var Drawer = /* @__PURE__ */ _export_sfc$1(_sfc_main$8i, [ ['render', _sfc_render$16], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/drawer/src/drawer.vue', ], ]) const ElDrawer = withInstall(Drawer) const obtainAllFocusableElements = (element) => { const nodes = [] const walker = document.createTreeWalker(element, NodeFilter.SHOW_ELEMENT, { acceptNode: (node2) => { const isHiddenInput = node2.tagName === 'INPUT' && node2.type === 'hidden' if (node2.disabled || node2.hidden || isHiddenInput) return NodeFilter.FILTER_SKIP return node2.tabIndex >= 0 ? NodeFilter.FILTER_ACCEPT : NodeFilter.FILTER_SKIP }, }) while (walker.nextNode()) nodes.push(walker.currentNode) return nodes } const getVisibleElement = (elements2, container) => { for (const element of elements2) { if (!isHidden(element, container)) return element } } const isHidden = (element, container) => { if (getComputedStyle(element).visibility === 'hidden') return true while (element) { if (container && element === container) return false if (getComputedStyle(element).display === 'none') return true element = element.parentElement } return false } const getEdges = (container) => { const focusable = obtainAllFocusableElements(container) const first2 = getVisibleElement(focusable, container) const last2 = getVisibleElement(focusable.reverse(), container) return [first2, last2] } const isSelectable = (element) => { return element instanceof HTMLInputElement && 'select' in element } const tryFocus = (element, shouldSelect) => { if (element && element.focus) { const prevFocusedElement = document.activeElement element.focus({ preventScroll: true }) if ( element !== prevFocusedElement && isSelectable(element) && shouldSelect ) { element.select() } } } function removeFromStack(list2, item2) { const copy2 = [...list2] const idx = list2.indexOf(item2) if (idx !== -1) { copy2.splice(idx, 1) } return copy2 } const createFocusableStack = () => { let stack = [] const push2 = (layer) => { const currentLayer = stack[0] if (currentLayer && layer !== currentLayer) { currentLayer.pause() } stack = removeFromStack(stack, layer) stack.unshift(layer) } const remove2 = (layer) => { var _a2, _b2 stack = removeFromStack(stack, layer) ;(_b2 = (_a2 = stack[0]) == null ? void 0 : _a2.resume) == null ? void 0 : _b2.call(_a2) } return { push: push2, remove: remove2, } } const focusFirstDescendant = (elements2, shouldSelect = false) => { const prevFocusedElement = document.activeElement for (const element of elements2) { tryFocus(element, shouldSelect) if (document.activeElement !== prevFocusedElement) return } } const focusableStack = createFocusableStack() const FOCUS_ON_MOUNT = 'focus-trap.focus-on-mount' const FOCUS_ON_UNMOUNT = 'focus-trap.focus-on-unmount' const FOCUS_ON_MOUNT_OPTS = { cancelable: true, bubbles: false, } const ON_MOUNT_FOCUS_EVT = 'mountOnFocus' const ON_UNMOUNT_FOCUS_EVT = 'unmountOnFocus' const FOCUS_TRAP_INJECTION_KEY = Symbol('elFocusTrap') const _sfc_main$8h = defineComponent({ name: 'ElFocusTrap', inheritAttrs: false, props: { loop: Boolean, trapped: Boolean, }, emits: [ON_MOUNT_FOCUS_EVT, ON_UNMOUNT_FOCUS_EVT], setup(props2, { emit: emit2 }) { const focusTrapRef = ref() const forwardRef = ref(null) let lastFocusBeforeMounted let lastFocusAfterMounted const focusLayer = { paused: false, pause() { this.paused = true }, resume() { this.paused = false }, } const onKeydown = (e2) => { if (!props2.loop && !props2.trapped) return if (focusLayer.paused) return const { key: key2, altKey, ctrlKey, metaKey, currentTarget, shiftKey, } = e2 const { loop } = props2 const isTabbing = key2 === EVENT_CODE.tab && !altKey && !ctrlKey && !metaKey const currentFocusingEl = document.activeElement if (isTabbing && currentFocusingEl) { const container = currentTarget const [first2, last2] = getEdges(container) const isTabbable = first2 && last2 if (!isTabbable) { if (currentFocusingEl === container) e2.preventDefault() } else { if (!shiftKey && currentFocusingEl === last2) { e2.preventDefault() if (loop) tryFocus(first2, true) } else if (shiftKey && currentFocusingEl === first2) { e2.preventDefault() if (loop) tryFocus(last2, true) } } } } provide(FOCUS_TRAP_INJECTION_KEY, { focusTrapRef: forwardRef, onKeydown, }) const focusOnMount = (e2) => { emit2(ON_MOUNT_FOCUS_EVT, e2) } const focusOnUnmount = (e2) => emit2(ON_UNMOUNT_FOCUS_EVT, e2) const onFocusIn = (e2) => { const trapContainer = unref(forwardRef) if (focusLayer.paused || !trapContainer) return const target2 = e2.target if (target2 && trapContainer.contains(target2)) { lastFocusAfterMounted = target2 } else { tryFocus(lastFocusAfterMounted, true) } } const onFocusOut = (e2) => { const trapContainer = unref(forwardRef) if (focusLayer.paused || !trapContainer) return if (!trapContainer.contains(e2.relatedTarget)) { tryFocus(lastFocusAfterMounted, true) } } const cleanupDocumentListeners = () => { document.removeEventListener('focusin', onFocusIn) document.removeEventListener('focusout', onFocusOut) } onMounted(() => { const trapContainer = unref(forwardRef) if (trapContainer) { focusableStack.push(focusLayer) const prevFocusedElement = document.activeElement lastFocusBeforeMounted = prevFocusedElement const isPrevFocusContained = trapContainer.contains(prevFocusedElement) if (!isPrevFocusContained) { const mountEvent = new Event(FOCUS_ON_MOUNT, FOCUS_ON_MOUNT_OPTS) trapContainer.addEventListener(FOCUS_ON_MOUNT, focusOnMount) trapContainer.dispatchEvent(mountEvent) if (!mountEvent.defaultPrevented) { nextTick(() => { focusFirstDescendant( obtainAllFocusableElements(trapContainer), true ) if (document.activeElement === prevFocusedElement) { tryFocus(trapContainer) } }) } } } watch$1( () => props2.trapped, (trapped) => { if (trapped) { document.addEventListener('focusin', onFocusIn) document.addEventListener('focusout', onFocusOut) } else { cleanupDocumentListeners() } }, { immediate: true } ) }) onBeforeUnmount(() => { cleanupDocumentListeners() const trapContainer = unref(forwardRef) if (trapContainer) { trapContainer.removeEventListener(FOCUS_ON_MOUNT, focusOnMount) const unmountEvent = new Event(FOCUS_ON_UNMOUNT, FOCUS_ON_MOUNT_OPTS) trapContainer.addEventListener(FOCUS_ON_UNMOUNT, focusOnUnmount) trapContainer.dispatchEvent(unmountEvent) if (!unmountEvent.defaultPrevented) { tryFocus( lastFocusBeforeMounted != null ? lastFocusBeforeMounted : document.body, true ) } trapContainer.removeEventListener(FOCUS_ON_UNMOUNT, focusOnMount) focusableStack.remove(focusLayer) } }) return { focusTrapRef, forwardRef, onKeydown, } }, }) function _sfc_render$15(_ctx, _cache, $props2, $setup, $data, $options) { return renderSlot(_ctx.$slots, 'default') } var ElFocusTrap = /* @__PURE__ */ _export_sfc$1(_sfc_main$8h, [ ['render', _sfc_render$15], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/focus-trap/src/focus-trap.vue', ], ]) const _sfc_main$8g = defineComponent({ inheritAttrs: false, }) function _sfc_render$14(_ctx, _cache, $props2, $setup, $data, $options) { return renderSlot(_ctx.$slots, 'default') } var Collection = /* @__PURE__ */ _export_sfc$1(_sfc_main$8g, [ ['render', _sfc_render$14], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/collection/src/collection.vue', ], ]) const _sfc_main$8f = defineComponent({ name: 'ElCollectionItem', inheritAttrs: false, }) function _sfc_render$13(_ctx, _cache, $props2, $setup, $data, $options) { return renderSlot(_ctx.$slots, 'default') } var CollectionItem = /* @__PURE__ */ _export_sfc$1(_sfc_main$8f, [ ['render', _sfc_render$13], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/collection/src/collection-item.vue', ], ]) const COLLECTION_ITEM_SIGN = `data-el-collection-item` const createCollectionWithScope = (name2) => { const COLLECTION_NAME2 = `El${name2}Collection` const COLLECTION_ITEM_NAME = `${COLLECTION_NAME2}Item` const COLLECTION_INJECTION_KEY2 = Symbol(COLLECTION_NAME2) const COLLECTION_ITEM_INJECTION_KEY2 = Symbol(COLLECTION_ITEM_NAME) const ElCollection2 = { ...Collection, name: COLLECTION_NAME2, setup() { const collectionRef = ref(null) const itemMap = /* @__PURE__ */ new Map() const getItems = () => { const collectionEl = unref(collectionRef) if (!collectionEl) return [] const orderedNodes = Array.from( collectionEl.querySelectorAll(`[${COLLECTION_ITEM_SIGN}]`) ) const items = [...itemMap.values()] const orderedItems = items.sort( (a2, b2) => orderedNodes.indexOf(a2.ref) - orderedNodes.indexOf(b2.ref) ) return orderedItems } provide(COLLECTION_INJECTION_KEY2, { itemMap, getItems, collectionRef, }) }, } const ElCollectionItem2 = { ...CollectionItem, name: COLLECTION_ITEM_NAME, setup(_2, { attrs }) { const collectionItemRef = ref(null) const collectionInjection = inject(COLLECTION_INJECTION_KEY2, void 0) provide(COLLECTION_ITEM_INJECTION_KEY2, { collectionItemRef, }) onMounted(() => { const collectionItemEl = unref(collectionItemRef) if (collectionItemEl) { collectionInjection.itemMap.set(collectionItemEl, { ref: collectionItemEl, ...attrs, }) } }) onBeforeUnmount(() => { const collectionItemEl = unref(collectionItemRef) collectionInjection.itemMap.delete(collectionItemEl) }) }, } return { COLLECTION_INJECTION_KEY: COLLECTION_INJECTION_KEY2, COLLECTION_ITEM_INJECTION_KEY: COLLECTION_ITEM_INJECTION_KEY2, ElCollection: ElCollection2, ElCollectionItem: ElCollectionItem2, } } const rovingFocusGroupProps = buildProps({ style: { type: definePropType([String, Array, Object]) }, currentTabId: { type: definePropType(String), }, defaultCurrentTabId: String, loop: Boolean, dir: { type: String, values: ['ltr', 'rtl'], default: 'ltr', }, orientation: { type: definePropType(String), }, onBlur: Function, onFocus: Function, onMousedown: Function, }) const { ElCollection: ElCollection$1, ElCollectionItem: ElCollectionItem$1, COLLECTION_INJECTION_KEY: COLLECTION_INJECTION_KEY$1, COLLECTION_ITEM_INJECTION_KEY: COLLECTION_ITEM_INJECTION_KEY$1, } = createCollectionWithScope('RovingFocusGroup') const ROVING_FOCUS_GROUP_INJECTION_KEY = Symbol('elRovingFocusGroup') const ROVING_FOCUS_GROUP_ITEM_INJECTION_KEY = Symbol('elRovingFocusGroupItem') const MAP_KEY_TO_FOCUS_INTENT = { ArrowLeft: 'prev', ArrowUp: 'prev', ArrowRight: 'next', ArrowDown: 'next', PageUp: 'first', Home: 'first', PageDown: 'last', End: 'last', } const getDirectionAwareKey = (key2, dir3) => { if (dir3 !== 'rtl') return key2 switch (key2) { case EVENT_CODE.right: return EVENT_CODE.left case EVENT_CODE.left: return EVENT_CODE.right default: return key2 } } const getFocusIntent = (event, orientation, dir3) => { const key2 = getDirectionAwareKey(event.key, dir3) if ( orientation === 'vertical' && [EVENT_CODE.left, EVENT_CODE.right].includes(key2) ) return void 0 if ( orientation === 'horizontal' && [EVENT_CODE.up, EVENT_CODE.down].includes(key2) ) return void 0 return MAP_KEY_TO_FOCUS_INTENT[key2] } const reorderArray = (array4, atIdx) => { return array4.map((_2, idx) => array4[(idx + atIdx) % array4.length]) } const focusFirst = (elements2) => { const { activeElement: prevActive } = document for (const element of elements2) { if (element === prevActive) return element.focus() if (prevActive !== document.activeElement) return } } const CURRENT_TAB_ID_CHANGE_EVT = 'currentTabIdChange' const ENTRY_FOCUS_EVT = 'rovingFocusGroup.entryFocus' const EVT_OPTS = { bubbles: false, cancelable: true } const _sfc_main$8e = defineComponent({ name: 'ElRovingFocusGroupImpl', inheritAttrs: false, props: rovingFocusGroupProps, emits: [CURRENT_TAB_ID_CHANGE_EVT, 'entryFocus'], setup(props2, { emit: emit2 }) { var _a2 const currentTabbedId = ref( (_a2 = props2.currentTabId || props2.defaultCurrentTabId) != null ? _a2 : null ) const isBackingOut = ref(false) const isClickFocus = ref(false) const rovingFocusGroupRef = ref(null) const { getItems } = inject(COLLECTION_INJECTION_KEY$1, void 0) const rovingFocusGroupRootStyle = computed(() => { return [ { outline: 'none', }, props2.style, ] }) const onItemFocus = (tabbedId) => { emit2(CURRENT_TAB_ID_CHANGE_EVT, tabbedId) } const onItemShiftTab = () => { isBackingOut.value = true } const onMousedown = composeEventHandlers( (e2) => { var _a22 ;(_a22 = props2.onMousedown) == null ? void 0 : _a22.call(props2, e2) }, () => { isClickFocus.value = true } ) const onFocus = composeEventHandlers( (e2) => { var _a22 ;(_a22 = props2.onFocus) == null ? void 0 : _a22.call(props2, e2) }, (e2) => { const isKeyboardFocus = !unref(isClickFocus) const { target: target2, currentTarget } = e2 if ( target2 === currentTarget && isKeyboardFocus && !unref(isBackingOut) ) { const entryFocusEvt = new Event(ENTRY_FOCUS_EVT, EVT_OPTS) currentTarget == null ? void 0 : currentTarget.dispatchEvent(entryFocusEvt) if (!entryFocusEvt.defaultPrevented) { const items = getItems().filter((item2) => item2.focusable) const activeItem = items.find((item2) => item2.active) const currentItem = items.find( (item2) => item2.id === unref(currentTabbedId) ) const candidates = [activeItem, currentItem, ...items].filter( Boolean ) const candidateNodes = candidates.map((item2) => item2.ref) focusFirst(candidateNodes) } } isClickFocus.value = false } ) const onBlur = composeEventHandlers( (e2) => { var _a22 ;(_a22 = props2.onBlur) == null ? void 0 : _a22.call(props2, e2) }, () => { isBackingOut.value = false } ) const handleEntryFocus = (...args) => { emit2('entryFocus', ...args) } provide(ROVING_FOCUS_GROUP_INJECTION_KEY, { currentTabbedId: readonly(currentTabbedId), loop: toRef(props2, 'loop'), tabIndex: computed(() => { return unref(isBackingOut) ? -1 : 0 }), rovingFocusGroupRef, rovingFocusGroupRootStyle, orientation: toRef(props2, 'orientation'), dir: toRef(props2, 'dir'), onItemFocus, onItemShiftTab, onBlur, onFocus, onMousedown, }) watch$1( () => props2.currentTabId, (val2) => { currentTabbedId.value = val2 != null ? val2 : null } ) onMounted(() => { const rovingFocusGroupEl = unref(rovingFocusGroupRef) on$2(rovingFocusGroupEl, ENTRY_FOCUS_EVT, handleEntryFocus) }) onBeforeUnmount(() => { const rovingFocusGroupEl = unref(rovingFocusGroupRef) off$1(rovingFocusGroupEl, ENTRY_FOCUS_EVT, handleEntryFocus) }) }, }) function _sfc_render$12(_ctx, _cache, $props2, $setup, $data, $options) { return renderSlot(_ctx.$slots, 'default') } var ElRovingFocusGroupImpl = /* @__PURE__ */ _export_sfc$1(_sfc_main$8e, [ ['render', _sfc_render$12], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/roving-focus-group/src/roving-focus-group-impl.vue', ], ]) const _sfc_main$8d = defineComponent({ name: 'ElRovingFocusGroup', components: { ElFocusGroupCollection: ElCollection$1, ElRovingFocusGroupImpl, }, }) function _sfc_render$11(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_roving_focus_group_impl = resolveComponent( 'el-roving-focus-group-impl' ) const _component_el_focus_group_collection = resolveComponent( 'el-focus-group-collection' ) return ( openBlock(), createBlock(_component_el_focus_group_collection, null, { default: withCtx(() => [ createVNode$1( _component_el_roving_focus_group_impl, normalizeProps(guardReactiveProps(_ctx.$attrs)), { default: withCtx(() => [renderSlot(_ctx.$slots, 'default')]), _: 3, }, 16 ), ]), _: 3, }) ) } var ElRovingFocusGroup = /* @__PURE__ */ _export_sfc$1(_sfc_main$8d, [ ['render', _sfc_render$11], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/roving-focus-group/src/roving-focus-group.vue', ], ]) const _sfc_main$8c = defineComponent({ components: { ElRovingFocusCollectionItem: ElCollectionItem$1, }, props: { focusable: { type: Boolean, default: true, }, active: { type: Boolean, default: false, }, }, emits: ['mousedown', 'focus', 'keydown'], setup(props2, { emit: emit2 }) { const { currentTabbedId, loop, onItemFocus, onItemShiftTab } = inject( ROVING_FOCUS_GROUP_INJECTION_KEY, void 0 ) const { getItems } = inject(COLLECTION_INJECTION_KEY$1, void 0) const id2 = useId() const rovingFocusGroupItemRef = ref(null) const handleMousedown = composeEventHandlers( (e2) => { emit2('mousedown', e2) }, (e2) => { if (!props2.focusable) { e2.preventDefault() } else { onItemFocus(unref(id2)) } } ) const handleFocus = composeEventHandlers( (e2) => { emit2('focus', e2) }, () => { onItemFocus(unref(id2)) } ) const handleKeydown = composeEventHandlers( (e2) => { emit2('keydown', e2) }, (e2) => { const { key: key2, shiftKey, target: target2, currentTarget } = e2 if (key2 === EVENT_CODE.tab && shiftKey) { onItemShiftTab() return } if (target2 !== currentTarget) return const focusIntent = getFocusIntent(e2) if (focusIntent) { e2.preventDefault() const items = getItems().filter((item2) => item2.focusable) let elements2 = items.map((item2) => item2.ref) switch (focusIntent) { case 'last': { elements2.reverse() break } case 'prev': case 'next': { if (focusIntent === 'prev') { elements2.reverse() } const currentIdx = elements2.indexOf(currentTarget) elements2 = loop.value ? reorderArray(elements2, currentIdx + 1) : elements2.slice(currentIdx + 1) break } } nextTick(() => { focusFirst(elements2) }) } } ) const isCurrentTab = computed(() => currentTabbedId.value === unref(id2)) provide(ROVING_FOCUS_GROUP_ITEM_INJECTION_KEY, { rovingFocusGroupItemRef, tabIndex: computed(() => (unref(isCurrentTab) ? 0 : -1)), handleMousedown, handleFocus, handleKeydown, }) return { id: id2, handleKeydown, handleFocus, handleMousedown, } }, }) function _sfc_render$10(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_roving_focus_collection_item = resolveComponent( 'el-roving-focus-collection-item' ) return ( openBlock(), createBlock( _component_el_roving_focus_collection_item, { id: _ctx.id, focusable: _ctx.focusable, active: _ctx.active, }, { default: withCtx(() => [renderSlot(_ctx.$slots, 'default')]), _: 3, }, 8, ['id', 'focusable', 'active'] ) ) } var ElRovingFocusItem = /* @__PURE__ */ _export_sfc$1(_sfc_main$8c, [ ['render', _sfc_render$10], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/roving-focus-group/src/roving-focus-item.vue', ], ]) const dropdownProps = buildProps({ trigger: useTooltipTriggerProps.trigger, effect: { ...useTooltipContentProps.effect, default: 'light', }, type: { type: definePropType(String), }, placement: { type: definePropType(String), default: 'bottom', }, popperOptions: { type: definePropType(Object), default: () => ({}), }, size: { type: String, default: '', }, splitButton: Boolean, hideOnClick: { type: Boolean, default: true, }, loop: { type: Boolean, }, showTimeout: { type: Number, default: 150, }, hideTimeout: { type: Number, default: 150, }, tabindex: { type: definePropType([Number, String]), default: 0, }, maxHeight: { type: definePropType([Number, String]), default: '', }, popperClass: { type: String, default: '', }, disabled: { type: Boolean, default: false, }, buttonProps: { type: definePropType(Object), }, }) const dropdownItemProps = buildProps({ command: { type: [Object, String, Number], default: () => ({}), }, disabled: Boolean, divided: Boolean, textValue: String, icon: { type: iconPropType, }, }) const dropdownMenuProps = buildProps({ onKeydown: { type: definePropType(Function) }, }) const FIRST_KEYS = [EVENT_CODE.down, EVENT_CODE.pageDown, EVENT_CODE.home] const LAST_KEYS = [EVENT_CODE.up, EVENT_CODE.pageUp, EVENT_CODE.end] const FIRST_LAST_KEYS = [...FIRST_KEYS, ...LAST_KEYS] const { ElCollection, ElCollectionItem, COLLECTION_INJECTION_KEY, COLLECTION_ITEM_INJECTION_KEY, } = createCollectionWithScope('Dropdown') const DROPDOWN_INJECTION_KEY = Symbol('elDropdown') const { ButtonGroup: ElButtonGroup } = ElButton const _sfc_main$8b = defineComponent({ name: 'ElDropdown', components: { ElButton, ElFocusTrap, ElButtonGroup, ElScrollbar, ElDropdownCollection: ElCollection, ElTooltip, ElRovingFocusGroup, ElIcon, ArrowDown: arrowDown, }, props: dropdownProps, emits: ['visible-change', 'click', 'command'], setup(props2, { emit: emit2 }) { const _instance = getCurrentInstance() const ns = useNamespace('dropdown') const triggeringElementRef = ref() const referenceElementRef = ref() const popperRef = ref(null) const contentRef = ref(null) const scrollbar = ref(null) const currentTabId = ref(null) const isUsingKeyboard = ref(false) const wrapStyle = computed(() => ({ maxHeight: addUnit(props2.maxHeight), })) const dropdownTriggerKls = computed(() => [ns.m(dropdownSize.value)]) function handleClick2() { handleClose() } function handleClose() { var _a2 ;(_a2 = popperRef.value) == null ? void 0 : _a2.onClose() } function handleOpen2() { var _a2 ;(_a2 = popperRef.value) == null ? void 0 : _a2.onOpen() } const dropdownSize = useSize$1() function commandHandler(...args) { emit2('command', ...args) } function onItemEnter() {} function onItemLeave() { const contentEl = unref(contentRef) contentEl == null ? void 0 : contentEl.focus() currentTabId.value = null } function handleCurrentTabIdChange(id2) { currentTabId.value = id2 } function handleEntryFocus(e2) { if (!isUsingKeyboard.value) { e2.preventDefault() e2.stopImmediatePropagation() } } provide(DROPDOWN_INJECTION_KEY, { contentRef, isUsingKeyboard, onItemEnter, onItemLeave, }) provide('elDropdown', { instance: _instance, dropdownSize, handleClick: handleClick2, commandHandler, trigger: toRef(props2, 'trigger'), hideOnClick: toRef(props2, 'hideOnClick'), }) const onMountOnFocus = (e2) => { var _a2, _b2 e2.preventDefault() ;(_b2 = (_a2 = contentRef.value) == null ? void 0 : _a2.focus) == null ? void 0 : _b2.call(_a2, { preventScroll: true, }) } const handlerMainButtonClick = (event) => { emit2('click', event) } return { ns, scrollbar, wrapStyle, dropdownTriggerKls, dropdownSize, currentTabId, handleCurrentTabIdChange, handlerMainButtonClick, handleEntryFocus, handleClose, handleOpen: handleOpen2, onMountOnFocus, popperRef, triggeringElementRef, referenceElementRef, } }, }) function _sfc_render$$(_ctx, _cache, $props2, $setup, $data, $options) { var _a2 const _component_el_dropdown_collection = resolveComponent( 'el-dropdown-collection' ) const _component_el_roving_focus_group = resolveComponent( 'el-roving-focus-group' ) const _component_el_focus_trap = resolveComponent('el-focus-trap') const _component_el_scrollbar = resolveComponent('el-scrollbar') const _component_el_tooltip = resolveComponent('el-tooltip') const _component_el_button = resolveComponent('el-button') const _component_arrow_down = resolveComponent('arrow-down') const _component_el_icon = resolveComponent('el-icon') const _component_el_button_group = resolveComponent('el-button-group') return ( openBlock(), createElementBlock( 'div', { class: normalizeClass([ _ctx.ns.b(), _ctx.ns.is('disabled', _ctx.disabled), ]), }, [ createVNode$1( _component_el_tooltip, { ref: 'popperRef', effect: _ctx.effect, 'fallback-placements': ['bottom', 'top'], 'popper-options': _ctx.popperOptions, 'gpu-acceleration': false, 'hide-after': _ctx.trigger === 'hover' ? _ctx.hideTimeout : 0, 'manual-mode': true, placement: _ctx.placement, 'popper-class': [_ctx.ns.e('popper'), _ctx.popperClass], 'reference-element': (_a2 = _ctx.referenceElementRef) == null ? void 0 : _a2.$el, trigger: _ctx.trigger, 'show-after': _ctx.trigger === 'hover' ? _ctx.showTimeout : 0, 'stop-popper-mouse-event': false, 'virtual-ref': _ctx.triggeringElementRef, 'virtual-triggering': _ctx.splitButton, disabled: _ctx.disabled, 'append-to-body': '', pure: '', transition: `${_ctx.ns.namespace.value}-zoom-in-top`, persistent: '', onShow: _cache[0] || (_cache[0] = ($event) => _ctx.$emit('visible-change', true)), onHide: _cache[1] || (_cache[1] = ($event) => _ctx.$emit('visible-change', false)), }, createSlots( { content: withCtx(() => [ createVNode$1( _component_el_scrollbar, { ref: 'scrollbar', 'wrap-style': _ctx.wrapStyle, tag: 'div', 'view-class': _ctx.ns.e('list'), }, { default: withCtx(() => [ createVNode$1( _component_el_focus_trap, { trapped: '', onMountOnFocus: _ctx.onMountOnFocus, }, { default: withCtx(() => [ createVNode$1( _component_el_roving_focus_group, { loop: _ctx.loop, 'current-tab-id': _ctx.currentTabId, orientation: 'horizontal', onCurrentTabIdChange: _ctx.handleCurrentTabIdChange, onEntryFocus: _ctx.handleEntryFocus, }, { default: withCtx(() => [ createVNode$1( _component_el_dropdown_collection, null, { default: withCtx(() => [ renderSlot(_ctx.$slots, 'dropdown'), ]), _: 3, } ), ]), _: 3, }, 8, [ 'loop', 'current-tab-id', 'onCurrentTabIdChange', 'onEntryFocus', ] ), ]), _: 3, }, 8, ['onMountOnFocus'] ), ]), _: 3, }, 8, ['wrap-style', 'view-class'] ), ]), _: 2, }, [ !_ctx.splitButton ? { name: 'default', fn: withCtx(() => [ createElementVNode( 'div', { class: normalizeClass(_ctx.dropdownTriggerKls), }, [renderSlot(_ctx.$slots, 'default')], 2 ), ]), } : void 0, ] ), 1032, [ 'effect', 'popper-options', 'hide-after', 'placement', 'popper-class', 'reference-element', 'trigger', 'show-after', 'virtual-ref', 'virtual-triggering', 'disabled', 'transition', ] ), _ctx.splitButton ? (openBlock(), createBlock( _component_el_button_group, { key: 0 }, { default: withCtx(() => [ createVNode$1( _component_el_button, mergeProps( { ref: 'referenceElementRef' }, _ctx.buttonProps, { size: _ctx.dropdownSize, type: _ctx.type, disabled: _ctx.disabled, onClick: _ctx.handlerMainButtonClick, } ), { default: withCtx(() => [ renderSlot(_ctx.$slots, 'default'), ]), _: 3, }, 16, ['size', 'type', 'disabled', 'onClick'] ), createVNode$1( _component_el_button, mergeProps( { ref: 'triggeringElementRef' }, _ctx.buttonProps, { size: _ctx.dropdownSize, type: _ctx.type, class: _ctx.ns.e('caret-button'), disabled: _ctx.disabled, } ), { default: withCtx(() => [ createVNode$1( _component_el_icon, { class: normalizeClass(_ctx.ns.e('icon')), }, { default: withCtx(() => [ createVNode$1(_component_arrow_down), ]), _: 1, }, 8, ['class'] ), ]), _: 1, }, 16, ['size', 'type', 'class', 'disabled'] ), ]), _: 3, } )) : createCommentVNode('v-if', true), ], 2 ) ) } var Dropdown = /* @__PURE__ */ _export_sfc$1(_sfc_main$8b, [ ['render', _sfc_render$$], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/dropdown/src/dropdown.vue', ], ]) const _sfc_main$8a = defineComponent({ name: 'DropdownItemImpl', components: { ElIcon, }, props: dropdownItemProps, emits: ['pointermove', 'pointerleave', 'click', 'clickimpl'], setup(_2, { emit: emit2 }) { const ns = useNamespace('dropdown') const { collectionItemRef: dropdownCollectionItemRef } = inject( COLLECTION_ITEM_INJECTION_KEY, void 0 ) const { collectionItemRef: rovingFocusCollectionItemRef } = inject( COLLECTION_ITEM_INJECTION_KEY$1, void 0 ) const { rovingFocusGroupItemRef, tabIndex, handleFocus, handleKeydown: handleItemKeydown, handleMousedown, } = inject(ROVING_FOCUS_GROUP_ITEM_INJECTION_KEY, void 0) const itemRef = composeRefs( dropdownCollectionItemRef, rovingFocusCollectionItemRef, rovingFocusGroupItemRef ) const handleKeydown = composeEventHandlers((e2) => { const { code: code2 } = e2 if (code2 === EVENT_CODE.enter || code2 === EVENT_CODE.space) { e2.preventDefault() e2.stopImmediatePropagation() emit2('clickimpl', e2) return true } }, handleItemKeydown) return { ns, itemRef, dataset: { [COLLECTION_ITEM_SIGN]: '', }, tabIndex, handleFocus, handleKeydown, handleMousedown, } }, }) const _hoisted_1$6x = ['aria-disabled', 'tabindex'] function _sfc_render$_(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_icon = resolveComponent('el-icon') return ( openBlock(), createElementBlock( Fragment, null, [ _ctx.divided ? (openBlock(), createElementBlock( 'li', mergeProps( { key: 0, class: _ctx.ns.bem('menu', 'item', 'divided'), }, _ctx.$attrs ), null, 16 )) : createCommentVNode('v-if', true), createElementVNode( 'li', mergeProps( { ref: _ctx.itemRef }, { ..._ctx.dataset, ..._ctx.$attrs }, { 'aria-disabled': _ctx.disabled, class: [ _ctx.ns.be('menu', 'item'), _ctx.ns.is('disabled', _ctx.disabled), ], tabindex: _ctx.tabIndex, role: 'menuitem', onClick: _cache[0] || (_cache[0] = (e2) => _ctx.$emit('clickimpl', e2)), onFocus: _cache[1] || (_cache[1] = (...args) => _ctx.handleFocus && _ctx.handleFocus(...args)), onKeydown: _cache[2] || (_cache[2] = (...args) => _ctx.handleKeydown && _ctx.handleKeydown(...args)), onMousedown: _cache[3] || (_cache[3] = (...args) => _ctx.handleMousedown && _ctx.handleMousedown(...args)), onPointermove: _cache[4] || (_cache[4] = (e2) => _ctx.$emit('pointermove', e2)), onPointerleave: _cache[5] || (_cache[5] = (e2) => _ctx.$emit('pointerleave', e2)), } ), [ _ctx.icon ? (openBlock(), createBlock( _component_el_icon, { key: 0 }, { default: withCtx(() => [ (openBlock(), createBlock(resolveDynamicComponent(_ctx.icon))), ]), _: 1, } )) : createCommentVNode('v-if', true), renderSlot(_ctx.$slots, 'default'), ], 16, _hoisted_1$6x ), ], 64 ) ) } var ElDropdownItemImpl = /* @__PURE__ */ _export_sfc$1(_sfc_main$8a, [ ['render', _sfc_render$_], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/dropdown/src/dropdown-item-impl.vue', ], ]) const useDropdown = () => { const elDropdown = inject('elDropdown', {}) const _elDropdownSize = computed(() => elDropdown == null ? void 0 : elDropdown.dropdownSize ) return { elDropdown, _elDropdownSize, } } const _sfc_main$89 = defineComponent({ name: 'ElDropdownItem', components: { ElDropdownCollectionItem: ElCollectionItem, ElRovingFocusItem, ElDropdownItemImpl, }, inheritAttrs: false, props: dropdownItemProps, emits: ['pointermove', 'pointerleave', 'click'], setup(props2, { emit: emit2, attrs }) { const { elDropdown } = useDropdown() const _instance = getCurrentInstance() const itemRef = ref(null) const textContent = computed(() => { var _a2, _b2 return (_b2 = (_a2 = unref(itemRef)) == null ? void 0 : _a2.textContent) != null ? _b2 : '' }) const { onItemEnter, onItemLeave } = inject(DROPDOWN_INJECTION_KEY, void 0) const handlePointerMove = composeEventHandlers( (e2) => { emit2('pointermove', e2) return e2.defaultPrevented }, whenMouse((e2) => { var _a2 if (props2.disabled) { onItemLeave(e2) } else { onItemEnter(e2) if (!e2.defaultPrevented) { ;(_a2 = e2.currentTarget) == null ? void 0 : _a2.focus() } } }) ) const handlePointerLeave = composeEventHandlers( (e2) => { emit2('pointerleave', e2) return e2.defaultPrevented }, whenMouse((e2) => { onItemLeave(e2) }) ) const handleClick2 = composeEventHandlers( (e2) => { emit2('click', e2) return e2.defaultPrevented }, (e2) => { var _a2, _b2, _c2 if (props2.disabled) { e2.stopImmediatePropagation() return } if ( (_a2 = elDropdown == null ? void 0 : elDropdown.hideOnClick) == null ? void 0 : _a2.value ) { ;(_b2 = elDropdown.handleClick) == null ? void 0 : _b2.call(elDropdown) } ;(_c2 = elDropdown.commandHandler) == null ? void 0 : _c2.call(elDropdown, props2.command, _instance, e2) } ) const propsAndAttrs = computed(() => { return { ...props2, ...attrs } }) return { handleClick: handleClick2, handlePointerMove, handlePointerLeave, textContent, propsAndAttrs, } }, }) function _sfc_render$Z(_ctx, _cache, $props2, $setup, $data, $options) { var _a2 const _component_el_dropdown_item_impl = resolveComponent( 'el-dropdown-item-impl' ) const _component_el_roving_focus_item = resolveComponent( 'el-roving-focus-item' ) const _component_el_dropdown_collection_item = resolveComponent( 'el-dropdown-collection-item' ) return ( openBlock(), createBlock( _component_el_dropdown_collection_item, { disabled: _ctx.disabled, 'text-value': (_a2 = _ctx.textValue) != null ? _a2 : _ctx.textContent, }, { default: withCtx(() => [ createVNode$1( _component_el_roving_focus_item, { focusable: !_ctx.disabled, }, { default: withCtx(() => [ createVNode$1( _component_el_dropdown_item_impl, mergeProps(_ctx.propsAndAttrs, { onPointerleave: _ctx.handlePointerLeave, onPointermove: _ctx.handlePointerMove, onClickimpl: _ctx.handleClick, }), { default: withCtx(() => [ renderSlot(_ctx.$slots, 'default'), ]), _: 3, }, 16, ['onPointerleave', 'onPointermove', 'onClickimpl'] ), ]), _: 3, }, 8, ['focusable'] ), ]), _: 3, }, 8, ['disabled', 'text-value'] ) ) } var DropdownItem = /* @__PURE__ */ _export_sfc$1(_sfc_main$89, [ ['render', _sfc_render$Z], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/dropdown/src/dropdown-item.vue', ], ]) const _sfc_main$88 = defineComponent({ name: 'ElDropdownMenu', props: dropdownMenuProps, setup(props2) { const ns = useNamespace('dropdown') const { _elDropdownSize } = useDropdown() const size = _elDropdownSize.value const { focusTrapRef, onKeydown } = inject(FOCUS_TRAP_INJECTION_KEY, void 0) const { contentRef } = inject(DROPDOWN_INJECTION_KEY, void 0) const { collectionRef: dropdownCollectionRef, getItems } = inject( COLLECTION_INJECTION_KEY, void 0 ) const { rovingFocusGroupRef, rovingFocusGroupRootStyle, tabIndex, onBlur, onFocus, onMousedown, } = inject(ROVING_FOCUS_GROUP_INJECTION_KEY, void 0) const { collectionRef: rovingFocusGroupCollectionRef } = inject( COLLECTION_INJECTION_KEY$1, void 0 ) const dropdownKls = computed(() => { return [ns.b('menu'), ns.bm('menu', size == null ? void 0 : size.value)] }) const dropdownListWrapperRef = composeRefs( contentRef, dropdownCollectionRef, focusTrapRef, rovingFocusGroupRef, rovingFocusGroupCollectionRef ) const composedKeydown = composeEventHandlers( (e2) => { var _a2 ;(_a2 = props2.onKeydown) == null ? void 0 : _a2.call(props2, e2) }, (e2) => { const { currentTarget, code: code2, target: target2 } = e2 currentTarget.contains(target2) if (EVENT_CODE.tab === code2) { e2.stopImmediatePropagation() } e2.preventDefault() if (target2 !== unref(contentRef)) return if (!FIRST_LAST_KEYS.includes(code2)) return const items = getItems().filter((item2) => !item2.disabled) const targets = items.map((item2) => item2.ref) if (LAST_KEYS.includes(code2)) { targets.reverse() } focusFirst(targets) } ) const handleKeydown = (e2) => { composedKeydown(e2) onKeydown(e2) } return { size, rovingFocusGroupRootStyle, tabIndex, dropdownKls, dropdownListWrapperRef, handleKeydown, onBlur, onFocus, onMousedown, } }, }) function _sfc_render$Y(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock( 'ul', { ref: _ctx.dropdownListWrapperRef, class: normalizeClass(_ctx.dropdownKls), style: normalizeStyle$1(_ctx.rovingFocusGroupRootStyle), tabindex: -1, role: 'menu', onBlur: _cache[0] || (_cache[0] = (...args) => _ctx.onBlur && _ctx.onBlur(...args)), onFocus: _cache[1] || (_cache[1] = (...args) => _ctx.onFocus && _ctx.onFocus(...args)), onKeydown: _cache[2] || (_cache[2] = (...args) => _ctx.handleKeydown && _ctx.handleKeydown(...args)), onMousedown: _cache[3] || (_cache[3] = (...args) => _ctx.onMousedown && _ctx.onMousedown(...args)), }, [renderSlot(_ctx.$slots, 'default')], 38 ) ) } var DropdownMenu$1 = /* @__PURE__ */ _export_sfc$1(_sfc_main$88, [ ['render', _sfc_render$Y], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/dropdown/src/dropdown-menu.vue', ], ]) const ElDropdown = withInstall(Dropdown, { DropdownItem, DropdownMenu: DropdownMenu$1, }) const ElDropdownItem = withNoopInstall(DropdownItem) const ElDropdownMenu = withNoopInstall(DropdownMenu$1) let id$3 = 0 const _sfc_main$87 = defineComponent({ name: 'ImgEmpty', setup() { return { id: ++id$3, } }, }) const _hoisted_1$6w = { viewBox: '0 0 79 86', version: '1.1', xmlns: 'http://www.w3.org/2000/svg', 'xmlns:xlink': 'http://www.w3.org/1999/xlink', } const _hoisted_2$5g = ['id'] const _hoisted_3$4E = /* @__PURE__ */ createElementVNode( 'stop', { 'stop-color': 'var(--el-empty-fill-color-1)', offset: '0%', }, null, -1 ) const _hoisted_4$40 = /* @__PURE__ */ createElementVNode( 'stop', { 'stop-color': 'var(--el-empty-fill-color-4)', offset: '100%', }, null, -1 ) const _hoisted_5$3C = [_hoisted_3$4E, _hoisted_4$40] const _hoisted_6$3b = ['id'] const _hoisted_7$2P = /* @__PURE__ */ createElementVNode( 'stop', { 'stop-color': 'var(--el-empty-fill-color-1)', offset: '0%', }, null, -1 ) const _hoisted_8$2v = /* @__PURE__ */ createElementVNode( 'stop', { 'stop-color': 'var(--el-empty-fill-color-6)', offset: '100%', }, null, -1 ) const _hoisted_9$2j = [_hoisted_7$2P, _hoisted_8$2v] const _hoisted_10$25 = ['id'] const _hoisted_11$1W = { id: 'Illustrations', stroke: 'none', 'stroke-width': '1', fill: 'none', 'fill-rule': 'evenodd', } const _hoisted_12$1Q = { id: 'B-type', transform: 'translate(-1268.000000, -535.000000)', } const _hoisted_13$1E = { id: 'Group-2', transform: 'translate(1268.000000, 535.000000)', } const _hoisted_14$1r = /* @__PURE__ */ createElementVNode( 'path', { id: 'Oval-Copy-2', d: 'M39.5,86 C61.3152476,86 79,83.9106622 79,81.3333333 C79,78.7560045 57.3152476,78 35.5,78 C13.6847524,78 0,78.7560045 0,81.3333333 C0,83.9106622 17.6847524,86 39.5,86 Z', fill: 'var(--el-empty-fill-color-3)', }, null, -1 ) const _hoisted_15$1m = /* @__PURE__ */ createElementVNode( 'polygon', { id: 'Rectangle-Copy-14', fill: 'var(--el-empty-fill-color-7)', transform: 'translate(27.500000, 51.500000) scale(1, -1) translate(-27.500000, -51.500000) ', points: '13 58 53 58 42 45 2 45', }, null, -1 ) const _hoisted_16$1k = { id: 'Group-Copy', transform: 'translate(34.500000, 31.500000) scale(-1, 1) rotate(-25.000000) translate(-34.500000, -31.500000) translate(7.000000, 10.000000)', } const _hoisted_17$1c = /* @__PURE__ */ createElementVNode( 'polygon', { id: 'Rectangle-Copy-10', fill: 'var(--el-empty-fill-color-7)', transform: 'translate(11.500000, 5.000000) scale(1, -1) translate(-11.500000, -5.000000) ', points: '2.84078316e-14 3 18 3 23 7 5 7', }, null, -1 ) const _hoisted_18$14 = /* @__PURE__ */ createElementVNode( 'polygon', { id: 'Rectangle-Copy-11', fill: 'var(--el-empty-fill-color-5)', points: '-3.69149156e-15 7 38 7 38 43 -3.69149156e-15 43', }, null, -1 ) const _hoisted_19$$ = ['fill'] const _hoisted_20$V = /* @__PURE__ */ createElementVNode( 'polygon', { id: 'Rectangle-Copy-13', fill: 'var(--el-empty-fill-color-2)', transform: 'translate(39.500000, 3.500000) scale(-1, 1) translate(-39.500000, -3.500000) ', points: '24 7 41 7 55 -3.63806207e-12 38 -3.63806207e-12', }, null, -1 ) const _hoisted_21$L = ['fill'] const _hoisted_22$J = { id: 'Rectangle-Copy-17', transform: 'translate(53.000000, 45.000000)', } const _hoisted_23$F = ['id'] const _hoisted_24$D = ['xlink:href'] const _hoisted_25$x = ['xlink:href'] const _hoisted_26$u = ['mask'] const _hoisted_27$t = /* @__PURE__ */ createElementVNode( 'polygon', { id: 'Rectangle-Copy-18', fill: 'var(--el-empty-fill-color-2)', transform: 'translate(66.000000, 51.500000) scale(-1, 1) translate(-66.000000, -51.500000) ', points: '62 45 79 45 70 58 53 58', }, null, -1 ) function _sfc_render$X(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock('svg', _hoisted_1$6w, [ createElementVNode('defs', null, [ createElementVNode( 'linearGradient', { id: `linearGradient-1-${_ctx.id}`, x1: '38.8503086%', y1: '0%', x2: '61.1496914%', y2: '100%', }, _hoisted_5$3C, 8, _hoisted_2$5g ), createElementVNode( 'linearGradient', { id: `linearGradient-2-${_ctx.id}`, x1: '0%', y1: '9.5%', x2: '100%', y2: '90.5%', }, _hoisted_9$2j, 8, _hoisted_6$3b ), createElementVNode( 'rect', { id: `path-3-${_ctx.id}`, x: '0', y: '0', width: '17', height: '36', }, null, 8, _hoisted_10$25 ), ]), createElementVNode('g', _hoisted_11$1W, [ createElementVNode('g', _hoisted_12$1Q, [ createElementVNode('g', _hoisted_13$1E, [ _hoisted_14$1r, _hoisted_15$1m, createElementVNode('g', _hoisted_16$1k, [ _hoisted_17$1c, _hoisted_18$14, createElementVNode( 'rect', { id: 'Rectangle-Copy-12', fill: `url(#linearGradient-1-${_ctx.id})`, transform: 'translate(46.500000, 25.000000) scale(-1, 1) translate(-46.500000, -25.000000) ', x: '38', y: '7', width: '17', height: '36', }, null, 8, _hoisted_19$$ ), _hoisted_20$V, ]), createElementVNode( 'rect', { id: 'Rectangle-Copy-15', fill: `url(#linearGradient-2-${_ctx.id})`, x: '13', y: '45', width: '40', height: '36', }, null, 8, _hoisted_21$L ), createElementVNode('g', _hoisted_22$J, [ createElementVNode( 'mask', { id: `mask-4-${_ctx.id}`, fill: 'var(--el-empty-fill-color-0)', }, [ createElementVNode( 'use', { 'xlink:href': `#path-3-${_ctx.id}`, }, null, 8, _hoisted_24$D ), ], 8, _hoisted_23$F ), createElementVNode( 'use', { id: 'Mask', fill: 'var(--el-empty-fill-color-8)', transform: 'translate(8.500000, 18.000000) scale(-1, 1) translate(-8.500000, -18.000000) ', 'xlink:href': `#path-3-${_ctx.id}`, }, null, 8, _hoisted_25$x ), createElementVNode( 'polygon', { id: 'Rectangle-Copy', fill: 'var(--el-empty-fill-color-9)', mask: `url(#mask-4-${_ctx.id})`, transform: 'translate(12.000000, 9.000000) scale(-1, 1) translate(-12.000000, -9.000000) ', points: '7 0 24 0 20 18 -1.70530257e-13 16', }, null, 8, _hoisted_26$u ), ]), _hoisted_27$t, ]), ]), ]), ]) ) } var ImgEmpty = /* @__PURE__ */ _export_sfc$1(_sfc_main$87, [ ['render', _sfc_render$X], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/empty/src/img-empty.vue', ], ]) const emptyProps = { image: { type: String, default: '', }, imageSize: Number, description: { type: String, default: '', }, } const _hoisted_1$6v = ['src'] const _hoisted_2$5f = { key: 1 } const __default__$n = { name: 'ElEmpty', } const _sfc_main$86 = /* @__PURE__ */ defineComponent({ ...__default__$n, props: emptyProps, setup(__props2) { const props2 = __props2 const { t: t3 } = useLocale() const ns = useNamespace('empty') const emptyDescription = computed( () => props2.description || t3('el.table.emptyText') ) const imageStyle = computed(() => ({ width: props2.imageSize ? `${props2.imageSize}px` : '', })) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { class: normalizeClass(unref(ns).b()), }, [ createElementVNode( 'div', { class: normalizeClass(unref(ns).e('image')), style: normalizeStyle$1(unref(imageStyle)), }, [ _ctx.image ? (openBlock(), createElementBlock( 'img', { key: 0, src: _ctx.image, ondragstart: 'return false', }, null, 8, _hoisted_1$6v )) : renderSlot(_ctx.$slots, 'image', { key: 1 }, () => [ createVNode$1(ImgEmpty), ]), ], 6 ), createElementVNode( 'div', { class: normalizeClass(unref(ns).e('description')), }, [ _ctx.$slots.description ? renderSlot(_ctx.$slots, 'description', { key: 0 }) : (openBlock(), createElementBlock( 'p', _hoisted_2$5f, toDisplayString$1(unref(emptyDescription)), 1 )), ], 2 ), _ctx.$slots.default ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass(unref(ns).e('bottom')), }, [renderSlot(_ctx.$slots, 'default')], 2 )) : createCommentVNode('v-if', true), ], 2 ) ) } }, }) var Empty$2 = /* @__PURE__ */ _export_sfc$1(_sfc_main$86, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/empty/src/empty.vue', ], ]) const ElEmpty = withInstall(Empty$2) const formProps = buildProps({ model: Object, rules: { type: definePropType(Object), }, labelPosition: String, labelWidth: { type: [String, Number], default: '', }, labelSuffix: { type: String, default: '', }, inline: Boolean, inlineMessage: Boolean, statusIcon: Boolean, showMessage: { type: Boolean, default: true, }, size: { type: String, values: componentSizes, }, disabled: Boolean, validateOnRuleChange: { type: Boolean, default: true, }, hideRequiredAsterisk: { type: Boolean, default: false, }, scrollToError: Boolean, }) const formEmits = { validate: (prop, isValid, message2) => (isArray$D(prop) || isString$f(prop)) && isBoolean$5(isValid) && isString$f(message2), } function useFormLabelWidth() { const potentialLabelWidthArr = ref([]) const autoLabelWidth = computed(() => { if (!potentialLabelWidthArr.value.length) return '0' const max3 = Math.max(...potentialLabelWidthArr.value) return max3 ? `${max3}px` : '' }) function getLabelWidthIndex(width) { const index2 = potentialLabelWidthArr.value.indexOf(width) return index2 } function registerLabelWidth(val2, oldVal) { if (val2 && oldVal) { const index2 = getLabelWidthIndex(oldVal) potentialLabelWidthArr.value.splice(index2, 1, val2) } else if (val2) { potentialLabelWidthArr.value.push(val2) } } function deregisterLabelWidth(val2) { const index2 = getLabelWidthIndex(val2) if (index2 > -1) { potentialLabelWidthArr.value.splice(index2, 1) } } return { autoLabelWidth, registerLabelWidth, deregisterLabelWidth, } } const filterFields = (fields, props2) => { const normalized = castArray$1(props2) return normalized.length > 0 ? fields.filter((field2) => field2.prop && normalized.includes(field2.prop)) : fields } const __default__$m = { name: 'ElForm', } const _sfc_main$85 = /* @__PURE__ */ defineComponent({ ...__default__$m, props: formProps, emits: formEmits, setup(__props2, { expose, emit: emit2 }) { const props2 = __props2 const fields = [] const formSize = useSize$1() const ns = useNamespace('form') const formClasses = computed(() => { const { labelPosition, inline } = props2 return [ ns.b(), ns.m(formSize.value || 'default'), { [ns.m(`label-${labelPosition}`)]: labelPosition, [ns.m('inline')]: inline, }, ] }) const addField = (field2) => { fields.push(field2) } const removeField = (field2) => { if (field2.prop) { fields.splice(fields.indexOf(field2), 1) } } const resetFields = (properties = []) => { if (!props2.model) { return } filterFields(fields, properties).forEach((field2) => field2.resetField()) } const clearValidate = (props22 = []) => { filterFields(fields, props22).forEach((field2) => field2.clearValidate()) } const isValidatable = computed(() => { const hasModel = !!props2.model return hasModel }) const obtainValidateFields = (props22) => { if (fields.length === 0) return [] const filteredFields = filterFields(fields, props22) if (!filteredFields.length) { return [] } return filteredFields } const validate = async (callback) => validateField(void 0, callback) const doValidateField = async (props22 = []) => { if (!isValidatable.value) return false const fields2 = obtainValidateFields(props22) if (fields2.length === 0) return true let validationErrors = {} for (const field2 of fields2) { try { await field2.validate('') } catch (fields3) { validationErrors = { ...validationErrors, ...fields3, } } } if (Object.keys(validationErrors).length === 0) return true return Promise.reject(validationErrors) } const validateField = async (modelProps = [], callback) => { const shouldThrow = !isFunction$l(callback) try { const result = await doValidateField(modelProps) if (result === true) { callback == null ? void 0 : callback(result) } return result } catch (e2) { const invalidFields = e2 if (props2.scrollToError) { scrollToField(Object.keys(invalidFields)[0]) } callback == null ? void 0 : callback(false, invalidFields) return shouldThrow && Promise.reject(invalidFields) } } const scrollToField = (prop) => { var _a2 const field2 = filterFields(fields, prop)[0] if (field2) { ;(_a2 = field2.$el) == null ? void 0 : _a2.scrollIntoView() } } watch$1( () => props2.rules, () => { if (props2.validateOnRuleChange) validate() }, { deep: true } ) provide( formContextKey, reactive({ ...toRefs$2(props2), emit: emit2, resetFields, clearValidate, validateField, addField, removeField, ...useFormLabelWidth(), }) ) expose({ validate, validateField, resetFields, clearValidate, scrollToField, }) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'form', { class: normalizeClass(unref(formClasses)), }, [renderSlot(_ctx.$slots, 'default')], 2 ) ) } }, }) var Form = /* @__PURE__ */ _export_sfc$1(_sfc_main$85, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/form/src/form.vue', ], ]) function _extends$1() { _extends$1 = Object.assign ? Object.assign.bind() : function (target2) { for (var i2 = 1; i2 < arguments.length; i2++) { var source2 = arguments[i2] for (var key2 in source2) { if (Object.prototype.hasOwnProperty.call(source2, key2)) { target2[key2] = source2[key2] } } } return target2 } return _extends$1.apply(this, arguments) } function _inheritsLoose(subClass, superClass) { subClass.prototype = Object.create(superClass.prototype) subClass.prototype.constructor = subClass _setPrototypeOf$1(subClass, superClass) } function _getPrototypeOf(o2) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf2(o3) { return o3.__proto__ || Object.getPrototypeOf(o3) } return _getPrototypeOf(o2) } function _setPrototypeOf$1(o2, p2) { _setPrototypeOf$1 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf2(o3, p3) { o3.__proto__ = p3 return o3 } return _setPrototypeOf$1(o2, p2) } function _isNativeReflectConstruct$1() { if (typeof Reflect === 'undefined' || !Reflect.construct) return false if (Reflect.construct.sham) return false if (typeof Proxy === 'function') return true try { Boolean.prototype.valueOf.call( Reflect.construct(Boolean, [], function () {}) ) return true } catch (e2) { return false } } function _construct$1(Parent, args, Class) { if (_isNativeReflectConstruct$1()) { _construct$1 = Reflect.construct.bind() } else { _construct$1 = function _construct2(Parent2, args2, Class2) { var a2 = [null] a2.push.apply(a2, args2) var Constructor = Function.bind.apply(Parent2, a2) var instance = new Constructor() if (Class2) _setPrototypeOf$1(instance, Class2.prototype) return instance } } return _construct$1.apply(null, arguments) } function _isNativeFunction(fn2) { return Function.toString.call(fn2).indexOf('[native code]') !== -1 } function _wrapNativeSuper(Class) { var _cache = typeof Map === 'function' ? /* @__PURE__ */ new Map() : void 0 _wrapNativeSuper = function _wrapNativeSuper2(Class2) { if (Class2 === null || !_isNativeFunction(Class2)) return Class2 if (typeof Class2 !== 'function') { throw new TypeError('Super expression must either be null or a function') } if (typeof _cache !== 'undefined') { if (_cache.has(Class2)) return _cache.get(Class2) _cache.set(Class2, Wrapper) } function Wrapper() { return _construct$1(Class2, arguments, _getPrototypeOf(this).constructor) } Wrapper.prototype = Object.create(Class2.prototype, { constructor: { value: Wrapper, enumerable: false, writable: true, configurable: true, }, }) return _setPrototypeOf$1(Wrapper, Class2) } return _wrapNativeSuper(Class) } var formatRegExp = /%[sdj%]/g var warning = function warning2() {} if (typeof process !== 'undefined' && process.env && false) { warning = function warning3(type4, errors) { if ( typeof console !== 'undefined' && console.warn && typeof ASYNC_VALIDATOR_NO_WARNING === 'undefined' ) { if ( errors.every(function (e2) { return typeof e2 === 'string' }) ) { console.warn(type4, errors) } } } } function convertFieldsError(errors) { if (!errors || !errors.length) return null var fields = {} errors.forEach(function (error2) { var field2 = error2.field fields[field2] = fields[field2] || [] fields[field2].push(error2) }) return fields } function format$4(template2) { for ( var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++ ) { args[_key - 1] = arguments[_key] } var i2 = 0 var len2 = args.length if (typeof template2 === 'function') { return template2.apply(null, args) } if (typeof template2 === 'string') { var str = template2.replace(formatRegExp, function (x2) { if (x2 === '%%') { return '%' } if (i2 >= len2) { return x2 } switch (x2) { case '%s': return String(args[i2++]) case '%d': return Number(args[i2++]) case '%j': try { return JSON.stringify(args[i2++]) } catch (_2) { return '[Circular]' } break default: return x2 } }) return str } return template2 } function isNativeStringType(type4) { return ( type4 === 'string' || type4 === 'url' || type4 === 'hex' || type4 === 'email' || type4 === 'date' || type4 === 'pattern' ) } function isEmptyValue$2(value2, type4) { if (value2 === void 0 || value2 === null) { return true } if (type4 === 'array' && Array.isArray(value2) && !value2.length) { return true } if (isNativeStringType(type4) && typeof value2 === 'string' && !value2) { return true } return false } function asyncParallelArray(arr, func, callback) { var results = [] var total2 = 0 var arrLength = arr.length function count2(errors) { results.push.apply(results, errors || []) total2++ if (total2 === arrLength) { callback(results) } } arr.forEach(function (a2) { func(a2, count2) }) } function asyncSerialArray(arr, func, callback) { var index2 = 0 var arrLength = arr.length function next(errors) { if (errors && errors.length) { callback(errors) return } var original = index2 index2 = index2 + 1 if (original < arrLength) { func(arr[original], next) } else { callback([]) } } next([]) } function flattenObjArr(objArr) { var ret = [] Object.keys(objArr).forEach(function (k2) { ret.push.apply(ret, objArr[k2] || []) }) return ret } var AsyncValidationError = /* @__PURE__ */ (function (_Error) { _inheritsLoose(AsyncValidationError2, _Error) function AsyncValidationError2(errors, fields) { var _this _this = _Error.call(this, 'Async Validation Error') || this _this.errors = errors _this.fields = fields return _this } return AsyncValidationError2 })(/* @__PURE__ */ _wrapNativeSuper(Error)) function asyncMap(objArr, option2, func, callback, source2) { if (option2.first) { var _pending = new Promise(function (resolve2, reject2) { var next = function next2(errors) { callback(errors) return errors.length ? reject2( new AsyncValidationError(errors, convertFieldsError(errors)) ) : resolve2(source2) } var flattenArr = flattenObjArr(objArr) asyncSerialArray(flattenArr, func, next) }) _pending['catch'](function (e2) { return e2 }) return _pending } var firstFields = option2.firstFields === true ? Object.keys(objArr) : option2.firstFields || [] var objArrKeys = Object.keys(objArr) var objArrLength = objArrKeys.length var total2 = 0 var results = [] var pending = new Promise(function (resolve2, reject2) { var next = function next2(errors) { results.push.apply(results, errors) total2++ if (total2 === objArrLength) { callback(results) return results.length ? reject2( new AsyncValidationError(results, convertFieldsError(results)) ) : resolve2(source2) } } if (!objArrKeys.length) { callback(results) resolve2(source2) } objArrKeys.forEach(function (key2) { var arr = objArr[key2] if (firstFields.indexOf(key2) !== -1) { asyncSerialArray(arr, func, next) } else { asyncParallelArray(arr, func, next) } }) }) pending['catch'](function (e2) { return e2 }) return pending } function isErrorObj(obj) { return !!(obj && obj.message !== void 0) } function getValue$3(value2, path) { var v4 = value2 for (var i2 = 0; i2 < path.length; i2++) { if (v4 == void 0) { return v4 } v4 = v4[path[i2]] } return v4 } function complementError(rule2, source2) { return function (oe2) { var fieldValue if (rule2.fullFields) { fieldValue = getValue$3(source2, rule2.fullFields) } else { fieldValue = source2[oe2.field || rule2.fullField] } if (isErrorObj(oe2)) { oe2.field = oe2.field || rule2.fullField oe2.fieldValue = fieldValue return oe2 } return { message: typeof oe2 === 'function' ? oe2() : oe2, fieldValue, field: oe2.field || rule2.fullField, } } } function deepMerge(target2, source2) { if (source2) { for (var s2 in source2) { if (source2.hasOwnProperty(s2)) { var value2 = source2[s2] if (typeof value2 === 'object' && typeof target2[s2] === 'object') { target2[s2] = _extends$1({}, target2[s2], value2) } else { target2[s2] = value2 } } } } return target2 } var required$1 = function required2( rule2, value2, source2, errors, options2, type4 ) { if ( rule2.required && (!source2.hasOwnProperty(rule2.field) || isEmptyValue$2(value2, type4 || rule2.type)) ) { errors.push(format$4(options2.messages.required, rule2.fullField)) } } var whitespace = function whitespace2( rule2, value2, source2, errors, options2 ) { if (/^\s+$/.test(value2) || value2 === '') { errors.push(format$4(options2.messages.whitespace, rule2.fullField)) } } var urlReg var getUrlRegex = function () { if (urlReg) { return urlReg } var word = '[a-fA-F\\d:]' var b2 = function b3(options2) { return options2 && options2.includeBoundaries ? '(?:(?<=\\s|^)(?=' + word + ')|(?<=' + word + ')(?=\\s|$))' : '' } 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}' var v6seg = '[a-fA-F\\d]{1,4}' 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() var v46Exact = new RegExp('(?:^' + v4 + '$)|(?:^' + v6 + '$)') var v4exact = new RegExp('^' + v4 + '$') var v6exact = new RegExp('^' + v6 + '$') var ip = function ip2(options2) { return options2 && options2.exact ? v46Exact : new RegExp( '(?:' + b2(options2) + v4 + b2(options2) + ')|(?:' + b2(options2) + v6 + b2(options2) + ')', 'g' ) } ip.v4 = function (options2) { return options2 && options2.exact ? v4exact : new RegExp('' + b2(options2) + v4 + b2(options2), 'g') } ip.v6 = function (options2) { return options2 && options2.exact ? v6exact : new RegExp('' + b2(options2) + v6 + b2(options2), 'g') } var protocol = '(?:(?:[a-z]+:)?//)' var auth = '(?:\\S+(?::\\S*)?@)?' var ipv4 = ip.v4().source var ipv6 = ip.v6().source var host = '(?:(?:[a-z\\u00a1-\\uffff0-9][-_]*)*[a-z\\u00a1-\\uffff0-9]+)' var domain = '(?:\\.(?:[a-z\\u00a1-\\uffff0-9]-*)*[a-z\\u00a1-\\uffff0-9]+)*' var tld = '(?:\\.(?:[a-z\\u00a1-\\uffff]{2,}))' var port2 = '(?::\\d{2,5})?' var path = '(?:[/?#][^\\s"]*)?' var regex3 = '(?:' + protocol + '|www\\.)' + auth + '(?:localhost|' + ipv4 + '|' + ipv6 + '|' + host + domain + tld + ')' + port2 + path urlReg = new RegExp('(?:^' + regex3 + '$)', 'i') return urlReg } var pattern$2 = { 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,}))$/, hex: /^#?([a-f0-9]{6}|[a-f0-9]{3})$/i, } var types = { integer: function integer2(value2) { return types.number(value2) && parseInt(value2, 10) === value2 }, float: function float2(value2) { return types.number(value2) && !types.integer(value2) }, array: function array2(value2) { return Array.isArray(value2) }, regexp: function regexp2(value2) { if (value2 instanceof RegExp) { return true } try { return !!new RegExp(value2) } catch (e2) { return false } }, date: function date2(value2) { return ( typeof value2.getTime === 'function' && typeof value2.getMonth === 'function' && typeof value2.getYear === 'function' && !isNaN(value2.getTime()) ) }, number: function number2(value2) { if (isNaN(value2)) { return false } return typeof value2 === 'number' }, object: function object2(value2) { return typeof value2 === 'object' && !types.array(value2) }, method: function method2(value2) { return typeof value2 === 'function' }, email: function email(value2) { return ( typeof value2 === 'string' && value2.length <= 320 && !!value2.match(pattern$2.email) ) }, url: function url(value2) { return ( typeof value2 === 'string' && value2.length <= 2048 && !!value2.match(getUrlRegex()) ) }, hex: function hex(value2) { return typeof value2 === 'string' && !!value2.match(pattern$2.hex) }, } var type$1 = function type2(rule2, value2, source2, errors, options2) { if (rule2.required && value2 === void 0) { required$1(rule2, value2, source2, errors, options2) return } var custom = [ 'integer', 'float', 'array', 'regexp', 'object', 'method', 'email', 'number', 'date', 'url', 'hex', ] var ruleType = rule2.type if (custom.indexOf(ruleType) > -1) { if (!types[ruleType](value2)) { errors.push( format$4(options2.messages.types[ruleType], rule2.fullField, rule2.type) ) } } else if (ruleType && typeof value2 !== rule2.type) { errors.push( format$4(options2.messages.types[ruleType], rule2.fullField, rule2.type) ) } } var range$2 = function range2(rule2, value2, source2, errors, options2) { var len2 = typeof rule2.len === 'number' var min3 = typeof rule2.min === 'number' var max3 = typeof rule2.max === 'number' var spRegexp = /[\uD800-\uDBFF][\uDC00-\uDFFF]/g var val2 = value2 var key2 = null var num2 = typeof value2 === 'number' var str = typeof value2 === 'string' var arr = Array.isArray(value2) if (num2) { key2 = 'number' } else if (str) { key2 = 'string' } else if (arr) { key2 = 'array' } if (!key2) { return false } if (arr) { val2 = value2.length } if (str) { val2 = value2.replace(spRegexp, '_').length } if (len2) { if (val2 !== rule2.len) { errors.push( format$4(options2.messages[key2].len, rule2.fullField, rule2.len) ) } } else if (min3 && !max3 && val2 < rule2.min) { errors.push( format$4(options2.messages[key2].min, rule2.fullField, rule2.min) ) } else if (max3 && !min3 && val2 > rule2.max) { errors.push( format$4(options2.messages[key2].max, rule2.fullField, rule2.max) ) } else if (min3 && max3 && (val2 < rule2.min || val2 > rule2.max)) { errors.push( format$4( options2.messages[key2].range, rule2.fullField, rule2.min, rule2.max ) ) } } var ENUM$1 = 'enum' var enumerable$1 = function enumerable2( rule2, value2, source2, errors, options2 ) { rule2[ENUM$1] = Array.isArray(rule2[ENUM$1]) ? rule2[ENUM$1] : [] if (rule2[ENUM$1].indexOf(value2) === -1) { errors.push( format$4( options2.messages[ENUM$1], rule2.fullField, rule2[ENUM$1].join(', ') ) ) } } var pattern$1 = function pattern2(rule2, value2, source2, errors, options2) { if (rule2.pattern) { if (rule2.pattern instanceof RegExp) { rule2.pattern.lastIndex = 0 if (!rule2.pattern.test(value2)) { errors.push( format$4( options2.messages.pattern.mismatch, rule2.fullField, value2, rule2.pattern ) ) } } else if (typeof rule2.pattern === 'string') { var _pattern = new RegExp(rule2.pattern) if (!_pattern.test(value2)) { errors.push( format$4( options2.messages.pattern.mismatch, rule2.fullField, value2, rule2.pattern ) ) } } } } var rules = { required: required$1, whitespace, type: type$1, range: range$2, enum: enumerable$1, pattern: pattern$1, } var string = function string2(rule2, value2, callback, source2, options2) { var errors = [] var validate = rule2.required || (!rule2.required && source2.hasOwnProperty(rule2.field)) if (validate) { if (isEmptyValue$2(value2, 'string') && !rule2.required) { return callback() } rules.required(rule2, value2, source2, errors, options2, 'string') if (!isEmptyValue$2(value2, 'string')) { rules.type(rule2, value2, source2, errors, options2) rules.range(rule2, value2, source2, errors, options2) rules.pattern(rule2, value2, source2, errors, options2) if (rule2.whitespace === true) { rules.whitespace(rule2, value2, source2, errors, options2) } } } callback(errors) } var method$1 = function method3(rule2, value2, callback, source2, options2) { var errors = [] var validate = rule2.required || (!rule2.required && source2.hasOwnProperty(rule2.field)) if (validate) { if (isEmptyValue$2(value2) && !rule2.required) { return callback() } rules.required(rule2, value2, source2, errors, options2) if (value2 !== void 0) { rules.type(rule2, value2, source2, errors, options2) } } callback(errors) } var number$3 = function number3(rule2, value2, callback, source2, options2) { var errors = [] var validate = rule2.required || (!rule2.required && source2.hasOwnProperty(rule2.field)) if (validate) { if (value2 === '') { value2 = void 0 } if (isEmptyValue$2(value2) && !rule2.required) { return callback() } rules.required(rule2, value2, source2, errors, options2) if (value2 !== void 0) { rules.type(rule2, value2, source2, errors, options2) rules.range(rule2, value2, source2, errors, options2) } } callback(errors) } var _boolean = function _boolean2(rule2, value2, callback, source2, options2) { var errors = [] var validate = rule2.required || (!rule2.required && source2.hasOwnProperty(rule2.field)) if (validate) { if (isEmptyValue$2(value2) && !rule2.required) { return callback() } rules.required(rule2, value2, source2, errors, options2) if (value2 !== void 0) { rules.type(rule2, value2, source2, errors, options2) } } callback(errors) } var regexp$1 = function regexp3(rule2, value2, callback, source2, options2) { var errors = [] var validate = rule2.required || (!rule2.required && source2.hasOwnProperty(rule2.field)) if (validate) { if (isEmptyValue$2(value2) && !rule2.required) { return callback() } rules.required(rule2, value2, source2, errors, options2) if (!isEmptyValue$2(value2)) { rules.type(rule2, value2, source2, errors, options2) } } callback(errors) } var integer = function integer3(rule2, value2, callback, source2, options2) { var errors = [] var validate = rule2.required || (!rule2.required && source2.hasOwnProperty(rule2.field)) if (validate) { if (isEmptyValue$2(value2) && !rule2.required) { return callback() } rules.required(rule2, value2, source2, errors, options2) if (value2 !== void 0) { rules.type(rule2, value2, source2, errors, options2) rules.range(rule2, value2, source2, errors, options2) } } callback(errors) } var floatFn = function floatFn2(rule2, value2, callback, source2, options2) { var errors = [] var validate = rule2.required || (!rule2.required && source2.hasOwnProperty(rule2.field)) if (validate) { if (isEmptyValue$2(value2) && !rule2.required) { return callback() } rules.required(rule2, value2, source2, errors, options2) if (value2 !== void 0) { rules.type(rule2, value2, source2, errors, options2) rules.range(rule2, value2, source2, errors, options2) } } callback(errors) } var array = function array3(rule2, value2, callback, source2, options2) { var errors = [] var validate = rule2.required || (!rule2.required && source2.hasOwnProperty(rule2.field)) if (validate) { if ((value2 === void 0 || value2 === null) && !rule2.required) { return callback() } rules.required(rule2, value2, source2, errors, options2, 'array') if (value2 !== void 0 && value2 !== null) { rules.type(rule2, value2, source2, errors, options2) rules.range(rule2, value2, source2, errors, options2) } } callback(errors) } var object = function object3(rule2, value2, callback, source2, options2) { var errors = [] var validate = rule2.required || (!rule2.required && source2.hasOwnProperty(rule2.field)) if (validate) { if (isEmptyValue$2(value2) && !rule2.required) { return callback() } rules.required(rule2, value2, source2, errors, options2) if (value2 !== void 0) { rules.type(rule2, value2, source2, errors, options2) } } callback(errors) } var ENUM = 'enum' var enumerable = function enumerable3( rule2, value2, callback, source2, options2 ) { var errors = [] var validate = rule2.required || (!rule2.required && source2.hasOwnProperty(rule2.field)) if (validate) { if (isEmptyValue$2(value2) && !rule2.required) { return callback() } rules.required(rule2, value2, source2, errors, options2) if (value2 !== void 0) { rules[ENUM](rule2, value2, source2, errors, options2) } } callback(errors) } var pattern = function pattern3(rule2, value2, callback, source2, options2) { var errors = [] var validate = rule2.required || (!rule2.required && source2.hasOwnProperty(rule2.field)) if (validate) { if (isEmptyValue$2(value2, 'string') && !rule2.required) { return callback() } rules.required(rule2, value2, source2, errors, options2) if (!isEmptyValue$2(value2, 'string')) { rules.pattern(rule2, value2, source2, errors, options2) } } callback(errors) } var date$1 = function date3(rule2, value2, callback, source2, options2) { var errors = [] var validate = rule2.required || (!rule2.required && source2.hasOwnProperty(rule2.field)) if (validate) { if (isEmptyValue$2(value2, 'date') && !rule2.required) { return callback() } rules.required(rule2, value2, source2, errors, options2) if (!isEmptyValue$2(value2, 'date')) { var dateObject if (value2 instanceof Date) { dateObject = value2 } else { dateObject = new Date(value2) } rules.type(rule2, dateObject, source2, errors, options2) if (dateObject) { rules.range(rule2, dateObject.getTime(), source2, errors, options2) } } } callback(errors) } var required = function required3(rule2, value2, callback, source2, options2) { var errors = [] var type4 = Array.isArray(value2) ? 'array' : typeof value2 rules.required(rule2, value2, source2, errors, options2, type4) callback(errors) } var type$2 = function type3(rule2, value2, callback, source2, options2) { var ruleType = rule2.type var errors = [] var validate = rule2.required || (!rule2.required && source2.hasOwnProperty(rule2.field)) if (validate) { if (isEmptyValue$2(value2, ruleType) && !rule2.required) { return callback() } rules.required(rule2, value2, source2, errors, options2, ruleType) if (!isEmptyValue$2(value2, ruleType)) { rules.type(rule2, value2, source2, errors, options2) } } callback(errors) } var any = function any2(rule2, value2, callback, source2, options2) { var errors = [] var validate = rule2.required || (!rule2.required && source2.hasOwnProperty(rule2.field)) if (validate) { if (isEmptyValue$2(value2) && !rule2.required) { return callback() } rules.required(rule2, value2, source2, errors, options2) } callback(errors) } var validators$3 = { string, method: method$1, number: number$3, boolean: _boolean, regexp: regexp$1, integer, float: floatFn, array, object, enum: enumerable, pattern, date: date$1, url: type$2, hex: type$2, email: type$2, required, any, } function newMessages() { return { default: 'Validation error on field %s', required: '%s is required', enum: '%s must be one of %s', whitespace: '%s cannot be empty', date: { format: '%s date %s is invalid for format %s', parse: '%s date could not be parsed, %s is invalid ', invalid: '%s date %s is invalid', }, types: { string: '%s is not a %s', method: '%s is not a %s (function)', array: '%s is not an %s', object: '%s is not an %s', number: '%s is not a %s', date: '%s is not a %s', boolean: '%s is not a %s', integer: '%s is not an %s', float: '%s is not a %s', regexp: '%s is not a valid %s', email: '%s is not a valid %s', url: '%s is not a valid %s', hex: '%s is not a valid %s', }, string: { len: '%s must be exactly %s characters', min: '%s must be at least %s characters', max: '%s cannot be longer than %s characters', range: '%s must be between %s and %s characters', }, number: { len: '%s must equal %s', min: '%s cannot be less than %s', max: '%s cannot be greater than %s', range: '%s must be between %s and %s', }, array: { len: '%s must be exactly %s in length', min: '%s cannot be less than %s in length', max: '%s cannot be greater than %s in length', range: '%s must be between %s and %s in length', }, pattern: { mismatch: '%s value %s does not match pattern %s', }, clone: function clone2() { var cloned = JSON.parse(JSON.stringify(this)) cloned.clone = this.clone return cloned }, } } var messages = newMessages() var Schema = /* @__PURE__ */ (function () { function Schema2(descriptor) { this.rules = null this._messages = messages this.define(descriptor) } var _proto = Schema2.prototype _proto.define = function define(rules2) { var _this = this if (!rules2) { throw new Error('Cannot configure a schema with no rules') } if (typeof rules2 !== 'object' || Array.isArray(rules2)) { throw new Error('Rules must be an object') } this.rules = {} Object.keys(rules2).forEach(function (name2) { var item2 = rules2[name2] _this.rules[name2] = Array.isArray(item2) ? item2 : [item2] }) } _proto.messages = function messages2(_messages) { if (_messages) { this._messages = deepMerge(newMessages(), _messages) } return this._messages } _proto.validate = function validate(source_, o2, oc) { var _this2 = this if (o2 === void 0) { o2 = {} } if (oc === void 0) { oc = function oc2() {} } var source2 = source_ var options2 = o2 var callback = oc if (typeof options2 === 'function') { callback = options2 options2 = {} } if (!this.rules || Object.keys(this.rules).length === 0) { if (callback) { callback(null, source2) } return Promise.resolve(source2) } function complete(results) { var errors = [] var fields = {} function add2(e2) { if (Array.isArray(e2)) { var _errors errors = (_errors = errors).concat.apply(_errors, e2) } else { errors.push(e2) } } for (var i2 = 0; i2 < results.length; i2++) { add2(results[i2]) } if (!errors.length) { callback(null, source2) } else { fields = convertFieldsError(errors) callback(errors, fields) } } if (options2.messages) { var messages$1 = this.messages() if (messages$1 === messages) { messages$1 = newMessages() } deepMerge(messages$1, options2.messages) options2.messages = messages$1 } else { options2.messages = this.messages() } var series = {} var keys3 = options2.keys || Object.keys(this.rules) keys3.forEach(function (z2) { var arr = _this2.rules[z2] var value2 = source2[z2] arr.forEach(function (r2) { var rule2 = r2 if (typeof rule2.transform === 'function') { if (source2 === source_) { source2 = _extends$1({}, source2) } value2 = source2[z2] = rule2.transform(value2) } if (typeof rule2 === 'function') { rule2 = { validator: rule2, } } else { rule2 = _extends$1({}, rule2) } rule2.validator = _this2.getValidationMethod(rule2) if (!rule2.validator) { return } rule2.field = z2 rule2.fullField = rule2.fullField || z2 rule2.type = _this2.getType(rule2) series[z2] = series[z2] || [] series[z2].push({ rule: rule2, value: value2, source: source2, field: z2, }) }) }) var errorFields = {} return asyncMap( series, options2, function (data2, doIt) { var rule2 = data2.rule var deep = (rule2.type === 'object' || rule2.type === 'array') && (typeof rule2.fields === 'object' || typeof rule2.defaultField === 'object') deep = deep && (rule2.required || (!rule2.required && data2.value)) rule2.field = data2.field function addFullField(key2, schema) { return _extends$1({}, schema, { fullField: rule2.fullField + '.' + key2, fullFields: rule2.fullFields ? [].concat(rule2.fullFields, [key2]) : [key2], }) } function cb(e2) { if (e2 === void 0) { e2 = [] } var errorList = Array.isArray(e2) ? e2 : [e2] if (!options2.suppressWarning && errorList.length) { Schema2.warning('async-validator:', errorList) } if (errorList.length && rule2.message !== void 0) { errorList = [].concat(rule2.message) } var filledErrors = errorList.map(complementError(rule2, source2)) if (options2.first && filledErrors.length) { errorFields[rule2.field] = 1 return doIt(filledErrors) } if (!deep) { doIt(filledErrors) } else { if (rule2.required && !data2.value) { if (rule2.message !== void 0) { filledErrors = [] .concat(rule2.message) .map(complementError(rule2, source2)) } else if (options2.error) { filledErrors = [ options2.error( rule2, format$4(options2.messages.required, rule2.field) ), ] } return doIt(filledErrors) } var fieldsSchema = {} if (rule2.defaultField) { Object.keys(data2.value).map(function (key2) { fieldsSchema[key2] = rule2.defaultField }) } fieldsSchema = _extends$1({}, fieldsSchema, data2.rule.fields) var paredFieldsSchema = {} Object.keys(fieldsSchema).forEach(function (field2) { var fieldSchema = fieldsSchema[field2] var fieldSchemaList = Array.isArray(fieldSchema) ? fieldSchema : [fieldSchema] paredFieldsSchema[field2] = fieldSchemaList.map( addFullField.bind(null, field2) ) }) var schema = new Schema2(paredFieldsSchema) schema.messages(options2.messages) if (data2.rule.options) { data2.rule.options.messages = options2.messages data2.rule.options.error = options2.error } schema.validate( data2.value, data2.rule.options || options2, function (errs) { var finalErrors = [] if (filledErrors && filledErrors.length) { finalErrors.push.apply(finalErrors, filledErrors) } if (errs && errs.length) { finalErrors.push.apply(finalErrors, errs) } doIt(finalErrors.length ? finalErrors : null) } ) } } var res if (rule2.asyncValidator) { res = rule2.asyncValidator( rule2, data2.value, cb, data2.source, options2 ) } else if (rule2.validator) { try { res = rule2.validator( rule2, data2.value, cb, data2.source, options2 ) } catch (error2) { console.error == null ? void 0 : console.error(error2) if (!options2.suppressValidatorError) { setTimeout(function () { throw error2 }, 0) } cb(error2.message) } if (res === true) { cb() } else if (res === false) { cb( typeof rule2.message === 'function' ? rule2.message(rule2.fullField || rule2.field) : rule2.message || (rule2.fullField || rule2.field) + ' fails' ) } else if (res instanceof Array) { cb(res) } else if (res instanceof Error) { cb(res.message) } } if (res && res.then) { res.then( function () { return cb() }, function (e2) { return cb(e2) } ) } }, function (results) { complete(results) }, source2 ) } _proto.getType = function getType2(rule2) { if (rule2.type === void 0 && rule2.pattern instanceof RegExp) { rule2.type = 'pattern' } if ( typeof rule2.validator !== 'function' && rule2.type && !validators$3.hasOwnProperty(rule2.type) ) { throw new Error(format$4('Unknown rule type %s', rule2.type)) } return rule2.type || 'string' } _proto.getValidationMethod = function getValidationMethod(rule2) { if (typeof rule2.validator === 'function') { return rule2.validator } var keys3 = Object.keys(rule2) var messageIndex = keys3.indexOf('message') if (messageIndex !== -1) { keys3.splice(messageIndex, 1) } if (keys3.length === 1 && keys3[0] === 'required') { return validators$3.required } return validators$3[this.getType(rule2)] || void 0 } return Schema2 })() Schema.register = function register2(type4, validator2) { if (typeof validator2 !== 'function') { throw new Error( 'Cannot register a validator by type, validator is not a function' ) } validators$3[type4] = validator2 } Schema.warning = warning Schema.messages = messages Schema.validators = validators$3 const formItemValidateStates = ['', 'error', 'validating', 'success'] const formItemProps$1 = buildProps({ label: String, labelWidth: { type: [String, Number], default: '', }, prop: { type: definePropType([String, Array]), }, required: { type: Boolean, default: void 0, }, rules: { type: definePropType([Object, Array]), }, error: String, validateStatus: { type: String, values: formItemValidateStates, }, for: String, inlineMessage: { type: [String, Boolean], default: '', }, showMessage: { type: Boolean, default: true, }, size: { type: String, values: componentSizes, }, }) const COMPONENT_NAME$a = 'ElLabelWrap' var FormLabelWrap = defineComponent({ name: COMPONENT_NAME$a, props: { isAutoWidth: Boolean, updateAll: Boolean, }, setup(props2, { slots }) { const formContext = inject(formContextKey) const formItemContext = inject(formItemContextKey) if (!formContext || !formItemContext) throwError$1( COMPONENT_NAME$a, 'usage: ' ) const ns = useNamespace('form') const el2 = ref() const computedWidth = ref(0) const getLabelWidth = () => { var _a2 if ((_a2 = el2.value) == null ? void 0 : _a2.firstElementChild) { const width = window.getComputedStyle(el2.value.firstElementChild).width return Math.ceil(Number.parseFloat(width)) } else { return 0 } } const updateLabelWidth = (action = 'update') => { nextTick(() => { if (slots.default && props2.isAutoWidth) { if (action === 'update') { computedWidth.value = getLabelWidth() } else if (action === 'remove') { formContext.deregisterLabelWidth(computedWidth.value) } } }) } const updateLabelWidthFn = () => updateLabelWidth('update') onMounted(() => { updateLabelWidthFn() }) onBeforeUnmount(() => { updateLabelWidth('remove') }) onUpdated(() => updateLabelWidthFn()) watch$1(computedWidth, (val2, oldVal) => { if (props2.updateAll) { formContext.registerLabelWidth(val2, oldVal) } }) useResizeObserver$1( computed(() => { var _a2, _b2 return (_b2 = (_a2 = el2.value) == null ? void 0 : _a2.firstElementChild) != null ? _b2 : null }), updateLabelWidthFn ) return () => { var _a2, _b2 if (!slots) return null const { isAutoWidth } = props2 if (isAutoWidth) { const autoLabelWidth = formContext.autoLabelWidth const style2 = {} if (autoLabelWidth && autoLabelWidth !== 'auto') { const marginWidth = Math.max( 0, Number.parseInt(autoLabelWidth, 10) - computedWidth.value ) const marginPosition = formContext.labelPosition === 'left' ? 'marginRight' : 'marginLeft' if (marginWidth) { style2[marginPosition] = `${marginWidth}px` } } return createVNode$1( 'div', { ref: el2, class: [ns.be('item', 'label-wrap')], style: style2, }, [(_a2 = slots.default) == null ? void 0 : _a2.call(slots)] ) } else { return createVNode$1( Fragment, { ref: el2, }, [(_b2 = slots.default) == null ? void 0 : _b2.call(slots)] ) } } }, }) const _hoisted_1$6u = ['for'] const __default__$l = { name: 'ElFormItem', } const _sfc_main$84 = /* @__PURE__ */ defineComponent({ ...__default__$l, props: formItemProps$1, setup(__props2, { expose }) { const props2 = __props2 const COMPONENT_NAME2 = 'ElFormItem' const slots = useSlots() const formContext = inject(formContextKey) if (!formContext) throwError$1( COMPONENT_NAME2, 'usage: ' ) const parentFormItemContext = inject(formItemContextKey, void 0) const _size = useSize$1(void 0, { formItem: false }) const ns = useNamespace('form-item') const validateState = ref('') const validateStateDebounced = refDebounced$1(validateState, 100) const validateMessage = ref('') const formItemRef = ref() let initialValue = void 0 let isResettingField = false const labelStyle = computed(() => { if (formContext.labelPosition === 'top') { return {} } const labelWidth = addUnit( props2.labelWidth || formContext.labelWidth || '' ) if (labelWidth) return { width: labelWidth } return {} }) const contentStyle = computed(() => { if (formContext.labelPosition === 'top' || formContext.inline) { return {} } if (!props2.label && !props2.labelWidth && isNested) { return {} } const labelWidth = addUnit( props2.labelWidth || formContext.labelWidth || '' ) if (!props2.label && !slots.label) { return { marginLeft: labelWidth } } return {} }) const formItemClasses = computed(() => [ ns.b(), ns.m(_size.value), ns.is('error', validateState.value === 'error'), ns.is('validating', validateState.value === 'validating'), ns.is('success', validateState.value === 'success'), ns.is('required', isRequired.value || props2.required), ns.is('no-asterisk', formContext.hideRequiredAsterisk), { [ns.m('feedback')]: formContext.statusIcon }, ]) const _inlineMessage = computed(() => isBoolean$5(props2.inlineMessage) ? props2.inlineMessage : formContext.inlineMessage || false ) const validateClasses = computed(() => [ ns.e('error'), { [ns.em('error', 'inline')]: _inlineMessage.value }, ]) const propString = computed(() => { if (!props2.prop) return '' return isString$f(props2.prop) ? props2.prop : props2.prop.join('.') }) const labelFor = computed(() => props2.for || propString.value) const isNested = !!parentFormItemContext const fieldValue = computed(() => { const model = formContext.model if (!model || !props2.prop) { return } return getProp(model, props2.prop).value }) const _rules = computed(() => { const rules2 = props2.rules ? castArray$1(props2.rules) : [] const formRules = formContext.rules if (formRules && props2.prop) { const _rules2 = getProp(formRules, props2.prop).value if (_rules2) { rules2.push(...castArray$1(_rules2)) } } if (props2.required !== void 0) { rules2.push({ required: !!props2.required }) } return rules2 }) const validateEnabled = computed(() => _rules.value.length > 0) const getFilteredRule = (trigger2) => { const rules2 = _rules.value return rules2 .filter((rule2) => { if (!rule2.trigger || !trigger2) return true if (Array.isArray(rule2.trigger)) { return rule2.trigger.includes(trigger2) } else { return rule2.trigger === trigger2 } }) .map(({ trigger: trigger22, ...rule2 }) => rule2) } const isRequired = computed(() => _rules.value.some((rule2) => rule2.required === true) ) const shouldShowError = computed( () => validateStateDebounced.value === 'error' && props2.showMessage && formContext.showMessage ) const currentLabel = computed( () => `${props2.label || ''}${formContext.labelSuffix || ''}` ) const setValidationState = (state2) => { validateState.value = state2 } const onValidationFailed = (error2) => { var _a2, _b2 const { errors, fields } = error2 if (!errors || !fields) { console.error(error2) } setValidationState('error') validateMessage.value = errors ? (_b2 = (_a2 = errors == null ? void 0 : errors[0]) == null ? void 0 : _a2.message) != null ? _b2 : `${props2.prop} is required` : '' formContext.emit('validate', props2.prop, false, validateMessage.value) } const onValidationSucceeded = () => { setValidationState('success') formContext.emit('validate', props2.prop, true, '') } const doValidate = async (rules2) => { const modelName = propString.value const validator2 = new Schema({ [modelName]: rules2, }) return validator2 .validate({ [modelName]: fieldValue.value }, { firstFields: true }) .then(() => { onValidationSucceeded() return true }) .catch((err) => { onValidationFailed(err) return Promise.reject(err) }) } const validate = async (trigger2, callback) => { if (isResettingField) { isResettingField = false return false } const hasCallback = isFunction$l(callback) if (!validateEnabled.value) { callback == null ? void 0 : callback(false) return false } const rules2 = getFilteredRule(trigger2) if (rules2.length === 0) { callback == null ? void 0 : callback(true) return true } setValidationState('validating') return doValidate(rules2) .then(() => { callback == null ? void 0 : callback(true) return true }) .catch((err) => { const { fields } = err callback == null ? void 0 : callback(false, fields) return hasCallback ? false : Promise.reject(fields) }) } const clearValidate = () => { setValidationState('') validateMessage.value = '' } const resetField = async () => { const model = formContext.model if (!model || !props2.prop) return const computedValue = getProp(model, props2.prop) if (!isEqual$4(computedValue.value, initialValue)) { isResettingField = true } computedValue.value = initialValue await nextTick() clearValidate() } watch$1( () => props2.error, (val2) => { validateMessage.value = val2 || '' setValidationState(val2 ? 'error' : '') }, { immediate: true } ) watch$1( () => props2.validateStatus, (val2) => setValidationState(val2 || '') ) const context2 = reactive({ ...toRefs$2(props2), $el: formItemRef, size: _size, validateState, resetField, clearValidate, validate, }) provide(formItemContextKey, context2) onMounted(() => { if (props2.prop) { formContext.addField(context2) initialValue = clone$b(fieldValue.value) } }) onBeforeUnmount(() => { formContext.removeField(context2) }) expose({ size: _size, validateMessage, validateState, validate, clearValidate, resetField, }) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { ref_key: 'formItemRef', ref: formItemRef, class: normalizeClass(unref(formItemClasses)), }, [ createVNode$1( unref(FormLabelWrap), { 'is-auto-width': unref(labelStyle).width === 'auto', 'update-all': unref(formContext).labelWidth === 'auto', }, { default: withCtx(() => [ _ctx.label || _ctx.$slots.label ? (openBlock(), createElementBlock( 'label', { key: 0, for: unref(labelFor), class: normalizeClass(unref(ns).e('label')), style: normalizeStyle$1(unref(labelStyle)), }, [ renderSlot( _ctx.$slots, 'label', { label: unref(currentLabel) }, () => [ createTextVNode( toDisplayString$1(unref(currentLabel)), 1 ), ] ), ], 14, _hoisted_1$6u )) : createCommentVNode('v-if', true), ]), _: 3, }, 8, ['is-auto-width', 'update-all'] ), createElementVNode( 'div', { class: normalizeClass(unref(ns).e('content')), style: normalizeStyle$1(unref(contentStyle)), }, [ renderSlot(_ctx.$slots, 'default'), createVNode$1( Transition, { name: `${unref(ns).namespace.value}-zoom-in-top`, }, { default: withCtx(() => [ unref(shouldShowError) ? renderSlot( _ctx.$slots, 'error', { key: 0, error: validateMessage.value, }, () => [ createElementVNode( 'div', { class: normalizeClass(unref(validateClasses)), }, toDisplayString$1(validateMessage.value), 3 ), ] ) : createCommentVNode('v-if', true), ]), _: 3, }, 8, ['name'] ), ], 6 ), ], 2 ) ) } }, }) var FormItem = /* @__PURE__ */ _export_sfc$1(_sfc_main$84, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/form/src/form-item.vue', ], ]) const ElForm = withInstall(Form, { FormItem, }) const ElFormItem = withNoopInstall(FormItem) const imageViewerProps = buildProps({ urlList: { type: definePropType(Array), default: () => mutable([]), }, zIndex: { type: Number, }, initialIndex: { type: Number, default: 0, }, infinite: { type: Boolean, default: true, }, hideOnClickModal: { type: Boolean, default: false, }, teleported: { type: Boolean, default: false, }, }) const imageViewerEmits = { close: () => true, switch: (index2) => typeof index2 === 'number', } const _hoisted_1$6t = ['src'] const __default__$k = { name: 'ElImageViewer', } const _sfc_main$83 = /* @__PURE__ */ defineComponent({ ...__default__$k, props: imageViewerProps, emits: imageViewerEmits, setup(__props2, { emit: emit2 }) { const props2 = __props2 const Mode = { CONTAIN: { name: 'contain', icon: markRaw(fullScreen), }, ORIGINAL: { name: 'original', icon: markRaw(scaleToOriginal), }, } const mousewheelEventName = isFirefox() ? 'DOMMouseScroll' : 'mousewheel' const { t: t3 } = useLocale() const ns = useNamespace('image-viewer') const { nextZIndex: nextZIndex2 } = useZIndex() const wrapper = ref() const imgRefs = ref([]) const scopeEventListener = effectScope() const loading2 = ref(true) const index2 = ref(props2.initialIndex) const mode2 = ref(Mode.CONTAIN) const transform3 = ref({ scale: 1, deg: 0, offsetX: 0, offsetY: 0, enableTransition: false, }) const isSingle = computed(() => { const { urlList } = props2 return urlList.length <= 1 }) const isFirst = computed(() => { return index2.value === 0 }) const isLast = computed(() => { return index2.value === props2.urlList.length - 1 }) const currentImg = computed(() => { return props2.urlList[index2.value] }) const imgStyle = computed(() => { const { scale: scale2, deg: deg2, offsetX, offsetY, enableTransition, } = transform3.value let translateX = offsetX / scale2 let translateY = offsetY / scale2 switch (deg2 % 360) { case 90: case -270: ;[translateX, translateY] = [translateY, -translateX] break case 180: case -180: ;[translateX, translateY] = [-translateX, -translateY] break case 270: case -90: ;[translateX, translateY] = [-translateY, translateX] break } const style2 = { transform: `scale(${scale2}) rotate(${deg2}deg) translate(${translateX}px, ${translateY}px)`, transition: enableTransition ? 'transform .3s' : '', } if (mode2.value.name === Mode.CONTAIN.name) { style2.maxWidth = style2.maxHeight = '100%' } return style2 }) const computedZIndex = computed(() => { return isNumber$h(props2.zIndex) ? props2.zIndex : nextZIndex2() }) function hide2() { unregisterEventListener() emit2('close') } function registerEventListener() { const keydownHandler = throttle$4((e2) => { switch (e2.code) { case EVENT_CODE.esc: hide2() break case EVENT_CODE.space: toggleMode() break case EVENT_CODE.left: prev() break case EVENT_CODE.up: handleActions('zoomIn') break case EVENT_CODE.right: next() break case EVENT_CODE.down: handleActions('zoomOut') break } }) const mousewheelHandler = throttle$4((e2) => { const delta = e2.wheelDelta ? e2.wheelDelta : -e2.detail if (delta > 0) { handleActions('zoomIn', { zoomRate: 1.2, enableTransition: false, }) } else { handleActions('zoomOut', { zoomRate: 1.2, enableTransition: false, }) } }) scopeEventListener.run(() => { useEventListener$1(document, 'keydown', keydownHandler) useEventListener$1(document, mousewheelEventName, mousewheelHandler) }) } function unregisterEventListener() { scopeEventListener.stop() } function handleImgLoad() { loading2.value = false } function handleImgError(e2) { loading2.value = false e2.target.alt = t3('el.image.error') } function handleMouseDown(e2) { if (loading2.value || e2.button !== 0 || !wrapper.value) return transform3.value.enableTransition = false const { offsetX, offsetY } = transform3.value const startX = e2.pageX const startY = e2.pageY const dragHandler = throttle$4((ev) => { transform3.value = { ...transform3.value, offsetX: offsetX + ev.pageX - startX, offsetY: offsetY + ev.pageY - startY, } }) const removeMousemove = useEventListener$1( document, 'mousemove', dragHandler ) useEventListener$1(document, 'mouseup', () => { removeMousemove() }) e2.preventDefault() } function reset2() { transform3.value = { scale: 1, deg: 0, offsetX: 0, offsetY: 0, enableTransition: false, } } function toggleMode() { if (loading2.value) return const modeNames = Object.keys(Mode) const modeValues = Object.values(Mode) const currentMode = mode2.value.name const index22 = modeValues.findIndex((i2) => i2.name === currentMode) const nextIndex = (index22 + 1) % modeNames.length mode2.value = Mode[modeNames[nextIndex]] reset2() } function prev() { if (isFirst.value && !props2.infinite) return const len2 = props2.urlList.length index2.value = (index2.value - 1 + len2) % len2 } function next() { if (isLast.value && !props2.infinite) return const len2 = props2.urlList.length index2.value = (index2.value + 1) % len2 } function handleActions(action, options2 = {}) { if (loading2.value) return const { zoomRate, rotateDeg, enableTransition } = { zoomRate: 1.4, rotateDeg: 90, enableTransition: true, ...options2, } switch (action) { case 'zoomOut': if (transform3.value.scale > 0.2) { transform3.value.scale = Number.parseFloat( (transform3.value.scale / zoomRate).toFixed(3) ) } break case 'zoomIn': if (transform3.value.scale < 7) { transform3.value.scale = Number.parseFloat( (transform3.value.scale * zoomRate).toFixed(3) ) } break case 'clockwise': transform3.value.deg += rotateDeg break case 'anticlockwise': transform3.value.deg -= rotateDeg break } transform3.value.enableTransition = enableTransition } watch$1(currentImg, () => { nextTick(() => { const $img = imgRefs.value[0] if (!($img == null ? void 0 : $img.complete)) { loading2.value = true } }) }) watch$1(index2, (val2) => { reset2() emit2('switch', val2) }) onMounted(() => { var _a2, _b2 registerEventListener() ;(_b2 = (_a2 = wrapper.value) == null ? void 0 : _a2.focus) == null ? void 0 : _b2.call(_a2) }) return (_ctx, _cache) => { return ( openBlock(), createBlock( Teleport, { to: 'body', disabled: !_ctx.teleported, }, [ createVNode$1( Transition, { name: 'viewer-fade', appear: '', }, { default: withCtx(() => [ createElementVNode( 'div', { ref_key: 'wrapper', ref: wrapper, tabindex: -1, class: normalizeClass(unref(ns).e('wrapper')), style: normalizeStyle$1({ zIndex: unref(computedZIndex), }), }, [ createElementVNode( 'div', { class: normalizeClass(unref(ns).e('mask')), onClick: _cache[0] || (_cache[0] = withModifiers( ($event) => _ctx.hideOnClickModal && hide2(), ['self'] )), }, null, 2 ), createCommentVNode(' CLOSE '), createElementVNode( 'span', { class: normalizeClass([ unref(ns).e('btn'), unref(ns).e('close'), ]), onClick: hide2, }, [ createVNode$1(unref(ElIcon), null, { default: withCtx(() => [ createVNode$1(unref(close$2)), ]), _: 1, }), ], 2 ), createCommentVNode(' ARROW '), !unref(isSingle) ? (openBlock(), createElementBlock( Fragment, { key: 0 }, [ createElementVNode( 'span', { class: normalizeClass([ unref(ns).e('btn'), unref(ns).e('prev'), unref(ns).is( 'disabled', !_ctx.infinite && unref(isFirst) ), ]), onClick: prev, }, [ createVNode$1(unref(ElIcon), null, { default: withCtx(() => [ createVNode$1(unref(arrowLeft)), ]), _: 1, }), ], 2 ), createElementVNode( 'span', { class: normalizeClass([ unref(ns).e('btn'), unref(ns).e('next'), unref(ns).is( 'disabled', !_ctx.infinite && unref(isLast) ), ]), onClick: next, }, [ createVNode$1(unref(ElIcon), null, { default: withCtx(() => [ createVNode$1(unref(arrowRight)), ]), _: 1, }), ], 2 ), ], 64 )) : createCommentVNode('v-if', true), createCommentVNode(' ACTIONS '), createElementVNode( 'div', { class: normalizeClass([ unref(ns).e('btn'), unref(ns).e('actions'), ]), }, [ createElementVNode( 'div', { class: normalizeClass( unref(ns).e('actions__inner') ), }, [ createVNode$1( unref(ElIcon), { onClick: _cache[1] || (_cache[1] = ($event) => handleActions('zoomOut')), }, { default: withCtx(() => [ createVNode$1(unref(zoomOut)), ]), _: 1, } ), createVNode$1( unref(ElIcon), { onClick: _cache[2] || (_cache[2] = ($event) => handleActions('zoomIn')), }, { default: withCtx(() => [ createVNode$1(unref(zoomIn)), ]), _: 1, } ), createElementVNode( 'i', { class: normalizeClass( unref(ns).e('actions__divider') ), }, null, 2 ), createVNode$1( unref(ElIcon), { onClick: toggleMode }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent(mode2.value.icon) )), ]), _: 1, } ), createElementVNode( 'i', { class: normalizeClass( unref(ns).e('actions__divider') ), }, null, 2 ), createVNode$1( unref(ElIcon), { onClick: _cache[3] || (_cache[3] = ($event) => handleActions('anticlockwise')), }, { default: withCtx(() => [ createVNode$1(unref(refreshLeft)), ]), _: 1, } ), createVNode$1( unref(ElIcon), { onClick: _cache[4] || (_cache[4] = ($event) => handleActions('clockwise')), }, { default: withCtx(() => [ createVNode$1(unref(refreshRight)), ]), _: 1, } ), ], 2 ), ], 2 ), createCommentVNode(' CANVAS '), createElementVNode( 'div', { class: normalizeClass(unref(ns).e('canvas')), }, [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.urlList, (url2, i2) => { return withDirectives( (openBlock(), createElementBlock( 'img', { ref_for: true, ref: (el2) => (imgRefs.value[i2] = el2), key: url2, src: url2, style: normalizeStyle$1(unref(imgStyle)), class: normalizeClass(unref(ns).e('img')), onLoad: handleImgLoad, onError: handleImgError, onMousedown: handleMouseDown, }, null, 46, _hoisted_1$6t )), [[vShow, i2 === index2.value]] ) }), 128 )), ], 2 ), renderSlot(_ctx.$slots, 'default'), ], 6 ), ]), _: 3, } ), ], 8, ['disabled'] ) ) } }, }) var ImageViewer = /* @__PURE__ */ _export_sfc$1(_sfc_main$83, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/image-viewer/src/image-viewer.vue', ], ]) const ElImageViewer = withInstall(ImageViewer) const imageProps = buildProps({ appendToBody: { type: Boolean, default: void 0, }, hideOnClickModal: { type: Boolean, default: false, }, src: { type: String, default: '', }, fit: { type: String, values: ['', 'contain', 'cover', 'fill', 'none', 'scale-down'], default: '', }, lazy: { type: Boolean, default: false, }, scrollContainer: { type: definePropType([String, Object]), }, previewSrcList: { type: definePropType(Array), default: () => mutable([]), }, previewTeleported: { type: Boolean, default: false, }, zIndex: { type: Number, }, initialIndex: { type: Number, default: 0, }, }) const imageEmits = { error: (evt) => evt instanceof Event, switch: (val2) => isNumber$h(val2), close: () => true, } const _hoisted_1$6s = ['src'] const _hoisted_2$5e = { key: 0 } const __default__$j = { name: 'ElImage', } const _sfc_main$82 = /* @__PURE__ */ defineComponent({ ...__default__$j, props: imageProps, emits: imageEmits, setup(__props2, { emit: emit2 }) { const props2 = __props2 let prevOverflow = '' useDeprecated( { scope: 'el-image', from: 'append-to-body', replacement: 'preview-teleported', version: '2.2.0', ref: 'https://element-plus.org/en-US/component/image.html#image-attributess', }, computed(() => isBoolean$5(props2.appendToBody)) ) const { t: t3 } = useLocale() const ns = useNamespace('image') const attrs = useAttrs() const hasLoadError = ref(false) const loading2 = ref(true) const imgWidth = ref(0) const imgHeight = ref(0) const showViewer = ref(false) const container = ref() const _scrollContainer = ref() let stopScrollListener let stopWheelListener const containerStyle = computed(() => attrs.value.style) const imageStyle = computed(() => { const { fit } = props2 if (isClient$1 && fit) { return { objectFit: fit } } return {} }) const preview2 = computed(() => { const { previewSrcList } = props2 return Array.isArray(previewSrcList) && previewSrcList.length > 0 }) const teleported = computed(() => { return props2.appendToBody || props2.previewTeleported }) const imageIndex = computed(() => { const { previewSrcList, initialIndex } = props2 let previewIndex = initialIndex if (initialIndex > previewSrcList.length - 1) { previewIndex = 0 } return previewIndex }) const loadImage2 = () => { if (!isClient$1) return loading2.value = true hasLoadError.value = false const img = new Image() const currentImageSrc = props2.src img.addEventListener('load', (e2) => { if (currentImageSrc !== props2.src) { return } handleLoad(e2, img) }) img.addEventListener('error', (e2) => { if (currentImageSrc !== props2.src) { return } handleError(e2) }) Object.entries(attrs.value).forEach(([key2, value2]) => { if (key2.toLowerCase() === 'onload') return img.setAttribute(key2, value2) }) img.src = currentImageSrc } function handleLoad(e2, img) { imgWidth.value = img.width imgHeight.value = img.height loading2.value = false hasLoadError.value = false } function handleError(event) { loading2.value = false hasLoadError.value = true emit2('error', event) } function handleLazyLoad() { if (isInContainer(container.value, _scrollContainer.value)) { loadImage2() removeLazyLoadListener() } } const lazyLoadHandler = useThrottleFn$1(handleLazyLoad, 200) async function addLazyLoadListener() { var _a2 if (!isClient$1) return await nextTick() const { scrollContainer } = props2 if (isElement$3(scrollContainer)) { _scrollContainer.value = scrollContainer } else if (isString$f(scrollContainer) && scrollContainer !== '') { _scrollContainer.value = (_a2 = document.querySelector(scrollContainer)) != null ? _a2 : void 0 } else if (container.value) { _scrollContainer.value = getScrollContainer(container.value) } if (_scrollContainer.value) { stopScrollListener = useEventListener$1( _scrollContainer, 'scroll', lazyLoadHandler ) setTimeout(() => handleLazyLoad(), 100) } } function removeLazyLoadListener() { if (!isClient$1 || !_scrollContainer.value || !lazyLoadHandler) return stopScrollListener() _scrollContainer.value = void 0 } function wheelHandler(e2) { if (!e2.ctrlKey) return if (e2.deltaY < 0) { e2.preventDefault() return false } else if (e2.deltaY > 0) { e2.preventDefault() return false } } function clickHandler() { if (!preview2.value) return stopWheelListener = useEventListener$1('wheel', wheelHandler, { passive: false, }) prevOverflow = document.body.style.overflow document.body.style.overflow = 'hidden' showViewer.value = true } function closeViewer() { stopWheelListener == null ? void 0 : stopWheelListener() document.body.style.overflow = prevOverflow showViewer.value = false emit2('close') } function switchViewer(val2) { emit2('switch', val2) } watch$1( () => props2.src, () => { if (props2.lazy) { loading2.value = true hasLoadError.value = false removeLazyLoadListener() addLazyLoadListener() } else { loadImage2() } } ) onMounted(() => { if (props2.lazy) { addLazyLoadListener() } else { loadImage2() } }) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { ref_key: 'container', ref: container, class: normalizeClass([unref(ns).b(), _ctx.$attrs.class]), style: normalizeStyle$1(unref(containerStyle)), }, [ loading2.value ? renderSlot(_ctx.$slots, 'placeholder', { key: 0 }, () => [ createElementVNode( 'div', { class: normalizeClass(unref(ns).e('placeholder')), }, null, 2 ), ]) : hasLoadError.value ? renderSlot(_ctx.$slots, 'error', { key: 1 }, () => [ createElementVNode( 'div', { class: normalizeClass(unref(ns).e('error')), }, toDisplayString$1(unref(t3)('el.image.error')), 3 ), ]) : (openBlock(), createElementBlock( 'img', mergeProps({ key: 2 }, unref(attrs), { src: _ctx.src, style: unref(imageStyle), class: [ unref(ns).e('inner'), unref(preview2) ? unref(ns).e('preview') : '', ], onClick: clickHandler, }), null, 16, _hoisted_1$6s )), unref(preview2) ? (openBlock(), createElementBlock( Fragment, { key: 3 }, [ showViewer.value ? (openBlock(), createBlock( unref(ElImageViewer), { key: 0, 'z-index': _ctx.zIndex, 'initial-index': unref(imageIndex), 'url-list': _ctx.previewSrcList, 'hide-on-click-modal': _ctx.hideOnClickModal, teleported: unref(teleported), onClose: closeViewer, onSwitch: switchViewer, }, { default: withCtx(() => [ _ctx.$slots.viewer ? (openBlock(), createElementBlock('div', _hoisted_2$5e, [ renderSlot(_ctx.$slots, 'viewer'), ])) : createCommentVNode('v-if', true), ]), _: 3, }, 8, [ 'z-index', 'initial-index', 'url-list', 'hide-on-click-modal', 'teleported', ] )) : createCommentVNode('v-if', true), ], 2112 )) : createCommentVNode('v-if', true), ], 6 ) ) } }, }) var Image$1 = /* @__PURE__ */ _export_sfc$1(_sfc_main$82, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/image/src/image.vue', ], ]) const ElImage = withInstall(Image$1) const inputNumberProps = buildProps({ step: { type: Number, default: 1, }, stepStrictly: { type: Boolean, default: false, }, max: { type: Number, default: Number.POSITIVE_INFINITY, }, min: { type: Number, default: Number.NEGATIVE_INFINITY, }, modelValue: { type: Number, }, disabled: { type: Boolean, default: false, }, size: { type: String, values: componentSizes, }, controls: { type: Boolean, default: true, }, controlsPosition: { type: String, default: '', values: ['', 'right'], }, name: String, label: String, placeholder: String, precision: { type: Number, validator: (val2) => val2 >= 0 && val2 === Number.parseInt(`${val2}`, 10), }, }) const inputNumberEmits = { change: (prev, cur) => prev !== cur, blur: (e2) => e2 instanceof FocusEvent, focus: (e2) => e2 instanceof FocusEvent, input: (val2) => isNumber$h(val2), 'update:modelValue': (val2) => isNumber$h(val2) || val2 === void 0, } const _sfc_main$81 = defineComponent({ name: 'ElInputNumber', components: { ElInput, ElIcon, ArrowUp: arrowUp, ArrowDown: arrowDown, Plus: plus, Minus: minus, }, directives: { RepeatClick, }, props: inputNumberProps, emits: inputNumberEmits, setup(props2, { emit: emit2 }) { const input = ref() const data2 = reactive({ currentValue: props2.modelValue, userInput: null, }) const { formItem } = useFormItem() const ns = useNamespace('input-number') const minDisabled = computed( () => ensurePrecision(props2.modelValue, -1) < props2.min ) const maxDisabled = computed( () => ensurePrecision(props2.modelValue) > props2.max ) const numPrecision = computed(() => { const stepPrecision = getPrecision2(props2.step) if (!isUndefined$c(props2.precision)) { if (stepPrecision > props2.precision); return props2.precision } else { return Math.max(getPrecision2(props2.modelValue), stepPrecision) } }) const controlsAtRight = computed(() => { return props2.controls && props2.controlsPosition === 'right' }) const inputNumberSize = useSize$1() const inputNumberDisabled = useDisabled$1() const displayValue = computed(() => { if (data2.userInput !== null) { return data2.userInput } let currentValue = data2.currentValue if (isNumber$h(currentValue)) { if (Number.isNaN(currentValue)) return '' if (!isUndefined$c(props2.precision)) { currentValue = currentValue.toFixed(props2.precision) } } return currentValue }) const toPrecision = (num2, pre) => { if (isUndefined$c(pre)) pre = numPrecision.value return Number.parseFloat(`${Math.round(num2 * 10 ** pre) / 10 ** pre}`) } const getPrecision2 = (value2) => { if (isUndefined$c(value2)) return 0 const valueString = value2.toString() const dotPosition = valueString.indexOf('.') let precision = 0 if (dotPosition !== -1) { precision = valueString.length - dotPosition - 1 } return precision } const ensurePrecision = (val2, coefficient = 1) => { if (!isNumber$h(val2)) return data2.currentValue val2 = isNumber$h(val2) ? val2 : Number.NaN return toPrecision(val2 + props2.step * coefficient) } const increase = () => { if (inputNumberDisabled.value || maxDisabled.value) return const value2 = props2.modelValue || 0 const newVal = ensurePrecision(value2) setCurrentValue(newVal) } const decrease = () => { if (inputNumberDisabled.value || minDisabled.value) return const value2 = props2.modelValue || 0 const newVal = ensurePrecision(value2, -1) setCurrentValue(newVal) } const verifyValue = (value2, update3) => { const { max: max3, min: min3, step, precision, stepStrictly } = props2 let newVal = Number(value2) if (value2 === null) { newVal = Number.NaN } if (!Number.isNaN(newVal)) { if (stepStrictly) { newVal = Math.round(newVal / step) * step } if (!isUndefined$c(precision)) { newVal = toPrecision(newVal, precision) } if (newVal > max3 || newVal < min3) { newVal = newVal > max3 ? max3 : min3 update3 && emit2('update:modelValue', newVal) } } return newVal } const setCurrentValue = (value2) => { var _a2 const oldVal = data2.currentValue let newVal = verifyValue(value2) if (oldVal === newVal) return if (Number.isNaN(newVal)) { newVal = void 0 } data2.userInput = null emit2('update:modelValue', newVal) emit2('input', newVal) emit2('change', newVal, oldVal) ;(_a2 = formItem == null ? void 0 : formItem.validate) == null ? void 0 : _a2.call(formItem, 'change').catch((err) => debugWarn()) data2.currentValue = newVal } const handleInput = (value2) => { return (data2.userInput = value2) } const handleInputChange = (value2) => { const newVal = value2 !== '' ? Number(value2) : '' if ((isNumber$h(newVal) && !Number.isNaN(newVal)) || value2 === '') { setCurrentValue(newVal) } data2.userInput = null } const focus2 = () => { var _a2, _b2 ;(_b2 = (_a2 = input.value) == null ? void 0 : _a2.focus) == null ? void 0 : _b2.call(_a2) } const blur = () => { var _a2, _b2 ;(_b2 = (_a2 = input.value) == null ? void 0 : _a2.blur) == null ? void 0 : _b2.call(_a2) } const handleFocus = (event) => { emit2('focus', event) } const handleBlur = (event) => { var _a2 emit2('blur', event) ;(_a2 = formItem == null ? void 0 : formItem.validate) == null ? void 0 : _a2.call(formItem, 'blur').catch((err) => debugWarn()) } watch$1( () => props2.modelValue, (value2) => { const newVal = verifyValue(value2, true) data2.currentValue = newVal data2.userInput = null }, { immediate: true } ) onMounted(() => { var _a2 const innerInput = (_a2 = input.value) == null ? void 0 : _a2.input innerInput.setAttribute('role', 'spinbutton') innerInput.setAttribute('aria-valuemax', String(props2.max)) innerInput.setAttribute('aria-valuemin', String(props2.min)) innerInput.setAttribute('aria-valuenow', String(data2.currentValue)) innerInput.setAttribute( 'aria-disabled', String(inputNumberDisabled.value) ) if (!isNumber$h(props2.modelValue)) { let val2 = Number(props2.modelValue) if (Number.isNaN(val2)) { val2 = void 0 } emit2('update:modelValue', val2) } }) onUpdated(() => { var _a2 const innerInput = (_a2 = input.value) == null ? void 0 : _a2.input innerInput == null ? void 0 : innerInput.setAttribute('aria-valuenow', data2.currentValue) }) return { input, displayValue, handleInput, handleInputChange, controlsAtRight, decrease, increase, inputNumberSize, inputNumberDisabled, maxDisabled, minDisabled, focus: focus2, blur, handleFocus, handleBlur, ns, } }, }) function _sfc_render$W(_ctx, _cache, $props2, $setup, $data, $options) { const _component_arrow_down = resolveComponent('arrow-down') const _component_minus = resolveComponent('minus') const _component_el_icon = resolveComponent('el-icon') const _component_arrow_up = resolveComponent('arrow-up') const _component_plus = resolveComponent('plus') const _component_el_input = resolveComponent('el-input') const _directive_repeat_click = resolveDirective('repeat-click') return ( openBlock(), createElementBlock( 'div', { class: normalizeClass([ _ctx.ns.b(), _ctx.ns.m(_ctx.inputNumberSize), _ctx.ns.is('disabled', _ctx.inputNumberDisabled), _ctx.ns.is('without-controls', !_ctx.controls), _ctx.ns.is('controls-right', _ctx.controlsAtRight), ]), onDragstart: _cache[2] || (_cache[2] = withModifiers(() => {}, ['prevent'])), }, [ _ctx.controls ? withDirectives( (openBlock(), createElementBlock( 'span', { key: 0, role: 'button', class: normalizeClass([ _ctx.ns.e('decrease'), _ctx.ns.is('disabled', _ctx.minDisabled), ]), onKeydown: _cache[0] || (_cache[0] = withKeys( (...args) => _ctx.decrease && _ctx.decrease(...args), ['enter'] )), }, [ createVNode$1(_component_el_icon, null, { default: withCtx(() => [ _ctx.controlsAtRight ? (openBlock(), createBlock(_component_arrow_down, { key: 0 })) : (openBlock(), createBlock(_component_minus, { key: 1 })), ]), _: 1, }), ], 34 )), [[_directive_repeat_click, _ctx.decrease]] ) : createCommentVNode('v-if', true), _ctx.controls ? withDirectives( (openBlock(), createElementBlock( 'span', { key: 1, role: 'button', class: normalizeClass([ _ctx.ns.e('increase'), _ctx.ns.is('disabled', _ctx.maxDisabled), ]), onKeydown: _cache[1] || (_cache[1] = withKeys( (...args) => _ctx.increase && _ctx.increase(...args), ['enter'] )), }, [ createVNode$1(_component_el_icon, null, { default: withCtx(() => [ _ctx.controlsAtRight ? (openBlock(), createBlock(_component_arrow_up, { key: 0 })) : (openBlock(), createBlock(_component_plus, { key: 1 })), ]), _: 1, }), ], 34 )), [[_directive_repeat_click, _ctx.increase]] ) : createCommentVNode('v-if', true), createVNode$1( _component_el_input, { ref: 'input', type: 'number', step: _ctx.step, 'model-value': _ctx.displayValue, placeholder: _ctx.placeholder, disabled: _ctx.inputNumberDisabled, size: _ctx.inputNumberSize, max: _ctx.max, min: _ctx.min, name: _ctx.name, label: _ctx.label, 'validate-event': false, onKeydown: [ withKeys(withModifiers(_ctx.increase, ['prevent']), ['up']), withKeys(withModifiers(_ctx.decrease, ['prevent']), ['down']), ], onBlur: _ctx.handleBlur, onFocus: _ctx.handleFocus, onInput: _ctx.handleInput, onChange: _ctx.handleInputChange, }, null, 8, [ 'step', 'model-value', 'placeholder', 'disabled', 'size', 'max', 'min', 'name', 'label', 'onKeydown', 'onBlur', 'onFocus', 'onInput', 'onChange', ] ), ], 34 ) ) } var InputNumber = /* @__PURE__ */ _export_sfc$1(_sfc_main$81, [ ['render', _sfc_render$W], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/input-number/src/input-number.vue', ], ]) const ElInputNumber = withInstall(InputNumber) const linkProps = buildProps({ type: { type: String, values: ['primary', 'success', 'warning', 'info', 'danger', 'default'], default: 'default', }, underline: { type: Boolean, default: true, }, disabled: { type: Boolean, default: false }, href: { type: String, default: '' }, icon: { type: iconPropType, default: '', }, }) const linkEmits = { click: (evt) => evt instanceof MouseEvent, } const _hoisted_1$6r = ['href'] const __default__$i = { name: 'ElLink', } const _sfc_main$80 = /* @__PURE__ */ defineComponent({ ...__default__$i, props: linkProps, emits: linkEmits, setup(__props2, { emit: emit2 }) { const props2 = __props2 const ns = useNamespace('link') function handleClick2(event) { if (!props2.disabled) emit2('click', event) } return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'a', { class: normalizeClass([ unref(ns).b(), unref(ns).m(_ctx.type), unref(ns).is('disabled', _ctx.disabled), unref(ns).is('underline', _ctx.underline && !_ctx.disabled), ]), href: _ctx.disabled || !_ctx.href ? void 0 : _ctx.href, onClick: handleClick2, }, [ _ctx.icon ? (openBlock(), createBlock( unref(ElIcon), { key: 0 }, { default: withCtx(() => [ (openBlock(), createBlock(resolveDynamicComponent(_ctx.icon))), ]), _: 1, } )) : createCommentVNode('v-if', true), _ctx.$slots.default ? (openBlock(), createElementBlock( 'span', { key: 1, class: normalizeClass(unref(ns).e('inner')), }, [renderSlot(_ctx.$slots, 'default')], 2 )) : createCommentVNode('v-if', true), _ctx.$slots.icon ? renderSlot(_ctx.$slots, 'icon', { key: 2 }) : createCommentVNode('v-if', true), ], 10, _hoisted_1$6r ) ) } }, }) var Link = /* @__PURE__ */ _export_sfc$1(_sfc_main$80, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/link/src/link.vue', ], ]) const ElLink = withInstall(Link) class SubMenu$1 { constructor(parent2, domNode) { this.parent = parent2 this.domNode = domNode this.subIndex = 0 this.subIndex = 0 this.init() } init() { this.subMenuItems = this.domNode.querySelectorAll('li') this.addListeners() } gotoSubIndex(idx) { if (idx === this.subMenuItems.length) { idx = 0 } else if (idx < 0) { idx = this.subMenuItems.length - 1 } this.subMenuItems[idx].focus() this.subIndex = idx } addListeners() { const parentNode2 = this.parent.domNode Array.prototype.forEach.call(this.subMenuItems, (el2) => { el2.addEventListener('keydown', (event) => { let prevDef = false switch (event.code) { case EVENT_CODE.down: { this.gotoSubIndex(this.subIndex + 1) prevDef = true break } case EVENT_CODE.up: { this.gotoSubIndex(this.subIndex - 1) prevDef = true break } case EVENT_CODE.tab: { triggerEvent$1(parentNode2, 'mouseleave') break } case EVENT_CODE.enter: case EVENT_CODE.space: { prevDef = true event.currentTarget.click() break } } if (prevDef) { event.preventDefault() event.stopPropagation() } return false }) }) } } class MenuItem$1 { constructor(domNode) { this.domNode = domNode this.submenu = null this.submenu = null this.init() } init() { this.domNode.setAttribute('tabindex', '0') const menuChild = this.domNode.querySelector('.el-menu') if (menuChild) { this.submenu = new SubMenu$1(this, menuChild) } this.addListeners() } addListeners() { this.domNode.addEventListener('keydown', (event) => { let prevDef = false switch (event.code) { case EVENT_CODE.down: { triggerEvent$1(event.currentTarget, 'mouseenter') this.submenu && this.submenu.gotoSubIndex(0) prevDef = true break } case EVENT_CODE.up: { triggerEvent$1(event.currentTarget, 'mouseenter') this.submenu && this.submenu.gotoSubIndex(this.submenu.subMenuItems.length - 1) prevDef = true break } case EVENT_CODE.tab: { triggerEvent$1(event.currentTarget, 'mouseleave') break } case EVENT_CODE.enter: case EVENT_CODE.space: { prevDef = true event.currentTarget.click() break } } if (prevDef) { event.preventDefault() } }) } } class Menu$3 { constructor(domNode) { this.domNode = domNode this.init() } init() { const menuChildren = this.domNode.childNodes Array.from(menuChildren).forEach((child) => { if (child.nodeType === 1) { new MenuItem$1(child) } }) } } const _sfc_main$7$ = defineComponent({ name: 'ElMenuCollapseTransition', setup() { const listeners = { onBeforeEnter: (el2) => (el2.style.opacity = '0.2'), onEnter(el2, done) { addClass$1(el2, 'el-opacity-transition') el2.style.opacity = '1' done() }, onAfterEnter(el2) { removeClass$1(el2, 'el-opacity-transition') el2.style.opacity = '' }, onBeforeLeave(el2) { if (!el2.dataset) { el2.dataset = {} } if (hasClass$1(el2, 'el-menu--collapse')) { removeClass$1(el2, 'el-menu--collapse') el2.dataset.oldOverflow = el2.style.overflow el2.dataset.scrollWidth = el2.clientWidth.toString() addClass$1(el2, 'el-menu--collapse') } else { addClass$1(el2, 'el-menu--collapse') el2.dataset.oldOverflow = el2.style.overflow el2.dataset.scrollWidth = el2.clientWidth.toString() removeClass$1(el2, 'el-menu--collapse') } el2.style.width = `${el2.scrollWidth}px` el2.style.overflow = 'hidden' }, onLeave(el2) { addClass$1(el2, 'horizontal-collapse-transition') el2.style.width = `${el2.dataset.scrollWidth}px` }, } return { listeners, } }, }) function _sfc_render$V(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createBlock( Transition, mergeProps({ mode: 'out-in' }, _ctx.listeners), { default: withCtx(() => [renderSlot(_ctx.$slots, 'default')]), _: 3, }, 16 ) ) } var ElMenuCollapseTransition = /* @__PURE__ */ _export_sfc$1(_sfc_main$7$, [ ['render', _sfc_render$V], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/menu/src/menu-collapse-transition.vue', ], ]) function useMenu(instance, currentIndex) { const rootMenu = inject('rootMenu') if (!rootMenu) throwError$1('useMenu', 'can not inject root menu') const indexPath = computed(() => { let parent2 = instance.parent const path = [currentIndex.value] while (parent2.type.name !== 'ElMenu') { if (parent2.props.index) { path.unshift(parent2.props.index) } parent2 = parent2.parent } return path }) const parentMenu = computed(() => { let parent2 = instance.parent while (parent2 && !['ElMenu', 'ElSubMenu'].includes(parent2.type.name)) { parent2 = parent2.parent } return parent2 }) const paddingStyle = computed(() => { let parent2 = instance.parent if (rootMenu.props.mode !== 'vertical') return {} let padding = 20 if (rootMenu.props.collapse) { padding = 20 } else { while (parent2 && parent2.type.name !== 'ElMenu') { if (parent2.type.name === 'ElSubMenu') { padding += 20 } parent2 = parent2.parent } } return { paddingLeft: `${padding}px` } }) return { parentMenu, paddingStyle, indexPath, } } function useMenuColor(props2) { const menuBarColor = computed(() => { const color2 = props2.backgroundColor if (!color2) { return '' } else { return new TinyColor(color2).shade(20).toString() } }) return menuBarColor } const useMenuCssVar = (props2) => { return computed(() => { return { '--el-menu-text-color': props2.textColor || '', '--el-menu-hover-text-color': props2.textColor || '', '--el-menu-bg-color': props2.backgroundColor || '', '--el-menu-hover-bg-color': useMenuColor(props2).value || '', '--el-menu-active-color': props2.activeTextColor || '', } }) } const subMenuProps = buildProps({ index: { type: String, required: true, }, showTimeout: { type: Number, default: 300, }, hideTimeout: { type: Number, default: 300, }, popperClass: String, disabled: Boolean, popperAppendToBody: { type: Boolean, default: void 0, }, popperOffset: { type: Number, default: 6, }, }) const COMPONENT_NAME$9 = 'ElSubMenu' var SubMenu = defineComponent({ name: COMPONENT_NAME$9, props: subMenuProps, setup(props2, { slots, expose }) { const instance = getCurrentInstance() const { paddingStyle, indexPath, parentMenu } = useMenu( instance, computed(() => props2.index) ) const rootMenu = inject('rootMenu') if (!rootMenu) throwError$1(COMPONENT_NAME$9, 'can not inject root menu') const subMenu = inject(`subMenu:${parentMenu.value.uid}`) if (!subMenu) throwError$1(COMPONENT_NAME$9, 'can not inject sub menu') const items = ref({}) const subMenus = ref({}) let timeout const mouseInChild = ref(false) const verticalTitleRef = ref() const vPopper = ref(null) const currentPlacement = computed(() => mode2.value === 'horizontal' && isFirstLevel.value ? 'bottom-start' : 'right-start' ) const subMenuTitleIcon = computed(() => { return (mode2.value === 'horizontal' && isFirstLevel.value) || (mode2.value === 'vertical' && !rootMenu.props.collapse) ? arrowDown : arrowRight }) const isFirstLevel = computed(() => { let isFirstLevel2 = true let parent2 = instance.parent while (parent2 && parent2.type.name !== 'ElMenu') { if (['ElSubMenu', 'ElMenuItemGroup'].includes(parent2.type.name)) { isFirstLevel2 = false break } else { parent2 = parent2.parent } } return isFirstLevel2 }) const appendToBody = computed(() => { return props2.popperAppendToBody === void 0 ? isFirstLevel.value : Boolean(props2.popperAppendToBody) }) const menuTransitionName = computed(() => rootMenu.props.collapse ? 'el-zoom-in-left' : 'el-zoom-in-top' ) const fallbackPlacements = computed(() => mode2.value === 'horizontal' && isFirstLevel.value ? [ 'bottom-start', 'bottom-end', 'top-start', 'top-end', 'right-start', 'left-start', ] : [ 'right-start', 'left-start', 'bottom-start', 'bottom-end', 'top-start', 'top-end', ] ) const opened = computed(() => rootMenu.openedMenus.includes(props2.index)) const active = computed(() => { let isActive = false Object.values(items.value).forEach((item22) => { if (item22.active) { isActive = true } }) Object.values(subMenus.value).forEach((subItem) => { if (subItem.active) { isActive = true } }) return isActive }) const backgroundColor2 = computed( () => rootMenu.props.backgroundColor || '' ) const activeTextColor = computed(() => rootMenu.props.activeTextColor || '') const textColor = computed(() => rootMenu.props.textColor || '') const mode2 = computed(() => rootMenu.props.mode) const item2 = reactive({ index: props2.index, indexPath, active, }) const titleStyle = computed(() => { if (mode2.value !== 'horizontal') { return { color: textColor.value, } } return { borderBottomColor: active.value ? rootMenu.props.activeTextColor ? activeTextColor.value : '' : 'transparent', color: active.value ? activeTextColor.value : textColor.value, } }) const doDestroy = () => { var _a2, _b2, _c2 return (_c2 = (_b2 = (_a2 = vPopper.value) == null ? void 0 : _a2.popperRef) == null ? void 0 : _b2.popperInstanceRef) == null ? void 0 : _c2.destroy() } const handleCollapseToggle = (value2) => { if (!value2) { doDestroy() } } const handleClick2 = () => { if ( (rootMenu.props.menuTrigger === 'hover' && rootMenu.props.mode === 'horizontal') || (rootMenu.props.collapse && rootMenu.props.mode === 'vertical') || props2.disabled ) return rootMenu.handleSubMenuClick({ index: props2.index, indexPath: indexPath.value, active: active.value, }) } const handleMouseenter = (event, showTimeout = props2.showTimeout) => { var _a2 if (event.type === 'focus' && !event.relatedTarget) { return } if ( (rootMenu.props.menuTrigger === 'click' && rootMenu.props.mode === 'horizontal') || (!rootMenu.props.collapse && rootMenu.props.mode === 'vertical') || props2.disabled ) { return } subMenu.mouseInChild.value = true timeout == null ? void 0 : timeout() ;({ stop: timeout } = useTimeoutFn$1(() => { rootMenu.openMenu(props2.index, indexPath.value) }, showTimeout)) if (appendToBody.value) { ;(_a2 = parentMenu.value.vnode.el) == null ? void 0 : _a2.dispatchEvent(new MouseEvent('mouseenter')) } } const handleMouseleave = (deepDispatch = false) => { var _a2, _b2 if ( (rootMenu.props.menuTrigger === 'click' && rootMenu.props.mode === 'horizontal') || (!rootMenu.props.collapse && rootMenu.props.mode === 'vertical') ) { return } timeout == null ? void 0 : timeout() subMenu.mouseInChild.value = false ;({ stop: timeout } = useTimeoutFn$1( () => !mouseInChild.value && rootMenu.closeMenu(props2.index, indexPath.value), props2.hideTimeout )) if (appendToBody.value && deepDispatch) { if ( ((_a2 = instance.parent) == null ? void 0 : _a2.type.name) === 'ElSubMenu' ) { ;(_b2 = subMenu.handleMouseleave) == null ? void 0 : _b2.call(subMenu, true) } } } watch$1( () => rootMenu.props.collapse, (value2) => handleCollapseToggle(Boolean(value2)) ) { const addSubMenu = (item22) => { subMenus.value[item22.index] = item22 } const removeSubMenu = (item22) => { delete subMenus.value[item22.index] } provide(`subMenu:${instance.uid}`, { addSubMenu, removeSubMenu, handleMouseleave, mouseInChild, }) } expose({ opened, }) onMounted(() => { rootMenu.addSubMenu(item2) subMenu.addSubMenu(item2) }) onBeforeUnmount(() => { subMenu.removeSubMenu(item2) rootMenu.removeSubMenu(item2) }) return () => { var _a2 const titleTag = [ (_a2 = slots.title) == null ? void 0 : _a2.call(slots), h$4( ElIcon, { class: ['el-sub-menu__icon-arrow'], }, { default: () => h$4(subMenuTitleIcon.value) } ), ] const ulStyle = useMenuCssVar(rootMenu.props) const child = rootMenu.isMenuPopup ? h$4( ElTooltip, { ref: vPopper, visible: opened.value, effect: 'light', pure: true, offset: props2.popperOffset, showArrow: false, persistent: true, popperClass: props2.popperClass, placement: currentPlacement.value, teleported: appendToBody.value, fallbackPlacements: fallbackPlacements.value, transition: menuTransitionName.value, gpuAcceleration: false, }, { content: () => { var _a22 return h$4( 'div', { class: [`el-menu--${mode2.value}`, props2.popperClass], onMouseenter: (evt) => handleMouseenter(evt, 100), onMouseleave: () => handleMouseleave(true), onFocus: (evt) => handleMouseenter(evt, 100), }, [ h$4( 'ul', { class: [ 'el-menu el-menu--popup', `el-menu--popup-${currentPlacement.value}`, ], style: ulStyle.value, }, [ (_a22 = slots.default) == null ? void 0 : _a22.call(slots), ] ), ] ) }, default: () => h$4( 'div', { class: 'el-sub-menu__title', style: [ paddingStyle.value, titleStyle.value, { backgroundColor: backgroundColor2.value }, ], onClick: handleClick2, }, titleTag ), } ) : h$4(Fragment, {}, [ h$4( 'div', { class: 'el-sub-menu__title', style: [ paddingStyle.value, titleStyle.value, { backgroundColor: backgroundColor2.value }, ], ref: verticalTitleRef, onClick: handleClick2, }, titleTag ), h$4( _CollapseTransition, {}, { default: () => { var _a22 return withDirectives( h$4( 'ul', { role: 'menu', class: 'el-menu el-menu--inline', style: ulStyle.value, }, [ (_a22 = slots.default) == null ? void 0 : _a22.call(slots), ] ), [[vShow, opened.value]] ) }, } ), ]) return h$4( 'li', { class: [ 'el-sub-menu', { 'is-active': active.value, 'is-opened': opened.value, 'is-disabled': props2.disabled, }, ], role: 'menuitem', ariaHaspopup: true, ariaExpanded: opened.value, onMouseenter: handleMouseenter, onMouseleave: () => handleMouseleave(true), onFocus: handleMouseenter, }, [child] ) } }, }) const menuProps = buildProps({ mode: { type: String, values: ['horizontal', 'vertical'], default: 'vertical', }, defaultActive: { type: String, default: '', }, defaultOpeneds: { type: definePropType(Array), default: () => mutable([]), }, uniqueOpened: Boolean, router: Boolean, menuTrigger: { type: String, values: ['hover', 'click'], default: 'hover', }, collapse: Boolean, backgroundColor: String, textColor: String, activeTextColor: String, collapseTransition: { type: Boolean, default: true, }, ellipsis: { type: Boolean, default: true, }, }) const checkIndexPath = (indexPath) => Array.isArray(indexPath) && indexPath.every((path) => isString$f(path)) const menuEmits = { close: (index2, indexPath) => isString$f(index2) && checkIndexPath(indexPath), open: (index2, indexPath) => isString$f(index2) && checkIndexPath(indexPath), select: (index2, indexPath, item2, routerResult) => isString$f(index2) && checkIndexPath(indexPath) && isObject$v(item2) && (routerResult === void 0 || routerResult instanceof Promise), } var Menu$2 = defineComponent({ name: 'ElMenu', props: menuProps, emits: menuEmits, setup(props2, { emit: emit2, slots, expose }) { const instance = getCurrentInstance() const router2 = instance.appContext.config.globalProperties.$router const menu2 = ref() const openedMenus = ref( props2.defaultOpeneds && !props2.collapse ? props2.defaultOpeneds.slice(0) : [] ) const activeIndex = ref(props2.defaultActive) const items = ref({}) const subMenus = ref({}) const isMenuPopup = computed(() => { return ( props2.mode === 'horizontal' || (props2.mode === 'vertical' && props2.collapse) ) }) const initMenu2 = () => { const activeItem = activeIndex.value && items.value[activeIndex.value] if (!activeItem || props2.mode === 'horizontal' || props2.collapse) return const indexPath = activeItem.indexPath indexPath.forEach((index2) => { const subMenu = subMenus.value[index2] subMenu && openMenu(index2, subMenu.indexPath) }) } const openMenu = (index2, indexPath) => { if (openedMenus.value.includes(index2)) return if (props2.uniqueOpened) { openedMenus.value = openedMenus.value.filter((index22) => indexPath.includes(index22) ) } openedMenus.value.push(index2) emit2('open', index2, indexPath) } const closeMenu = (index2, indexPath) => { const i2 = openedMenus.value.indexOf(index2) if (i2 !== -1) { openedMenus.value.splice(i2, 1) } emit2('close', index2, indexPath) } const handleSubMenuClick = ({ index: index2, indexPath }) => { const isOpened = openedMenus.value.includes(index2) if (isOpened) { closeMenu(index2, indexPath) } else { openMenu(index2, indexPath) } } const handleMenuItemClick = (menuItem) => { if (props2.mode === 'horizontal' || props2.collapse) { openedMenus.value = [] } const { index: index2, indexPath } = menuItem if (index2 === void 0 || indexPath === void 0) return if (props2.router && router2) { const route = menuItem.route || index2 const routerResult = router2.push(route).then((res) => { if (!res) activeIndex.value = index2 return res }) emit2( 'select', index2, indexPath, { index: index2, indexPath, route }, routerResult ) } else { activeIndex.value = index2 emit2('select', index2, indexPath, { index: index2, indexPath }) } } const updateActiveIndex = (val2) => { const itemsInData = items.value const item2 = itemsInData[val2] || (activeIndex.value && itemsInData[activeIndex.value]) || itemsInData[props2.defaultActive] if (item2) { activeIndex.value = item2.index initMenu2() } else { activeIndex.value = val2 } } const handleResize = () => { nextTick(() => instance.proxy.$forceUpdate()) } watch$1( () => props2.defaultActive, (currentActive) => { if (!items.value[currentActive]) { activeIndex.value = '' } updateActiveIndex(currentActive) } ) watch$1(items.value, () => initMenu2()) watch$1( () => props2.collapse, (value2) => { if (value2) openedMenus.value = [] } ) { const addSubMenu = (item2) => { subMenus.value[item2.index] = item2 } const removeSubMenu = (item2) => { delete subMenus.value[item2.index] } const addMenuItem = (item2) => { items.value[item2.index] = item2 } const removeMenuItem = (item2) => { delete items.value[item2.index] } provide( 'rootMenu', reactive({ props: props2, openedMenus, items, subMenus, activeIndex, isMenuPopup, addMenuItem, removeMenuItem, addSubMenu, removeSubMenu, openMenu, closeMenu, handleMenuItemClick, handleSubMenuClick, }) ) provide(`subMenu:${instance.uid}`, { addSubMenu, removeSubMenu, mouseInChild: ref(false), }) } onMounted(() => { initMenu2() if (props2.mode === 'horizontal') { new Menu$3(instance.vnode.el) } }) { const open2 = (index2) => { const { indexPath } = subMenus.value[index2] indexPath.forEach((i2) => openMenu(i2, indexPath)) } expose({ open: open2, close: closeMenu, handleResize, }) } const flattedChildren = (children) => { const vnodes = Array.isArray(children) ? children : [children] const result = [] vnodes.forEach((child) => { if (Array.isArray(child.children)) { result.push(...flattedChildren(child.children)) } else { result.push(child) } }) return result } const useVNodeResize = (vnode) => props2.mode === 'horizontal' ? withDirectives(vnode, [[Resize, handleResize]]) : vnode return () => { var _a2, _b2, _c2, _d let slot = (_b2 = (_a2 = slots.default) == null ? void 0 : _a2.call(slots)) != null ? _b2 : [] const vShowMore = [] if (props2.mode === 'horizontal' && menu2.value) { const items2 = Array.from( (_d = (_c2 = menu2.value) == null ? void 0 : _c2.childNodes) != null ? _d : [] ).filter((item2) => item2.nodeName !== '#text' || item2.nodeValue) const originalSlot = flattedChildren(slot) const moreItemWidth = 64 const paddingLeft2 = Number.parseInt( getComputedStyle(menu2.value).paddingLeft, 10 ) const paddingRight2 = Number.parseInt( getComputedStyle(menu2.value).paddingRight, 10 ) const menuWidth = menu2.value.clientWidth - paddingLeft2 - paddingRight2 let calcWidth = 0 let sliceIndex = 0 items2.forEach((item2, index2) => { calcWidth += item2.offsetWidth || 0 if (calcWidth <= menuWidth - moreItemWidth) { sliceIndex = index2 + 1 } }) const slotDefault = originalSlot.slice(0, sliceIndex) const slotMore = originalSlot.slice(sliceIndex) if ((slotMore == null ? void 0 : slotMore.length) && props2.ellipsis) { slot = slotDefault vShowMore.push( h$4( SubMenu, { index: 'sub-menu-more', class: 'el-sub-menu__hide-arrow', }, { title: () => h$4( ElIcon, { class: ['el-sub-menu__icon-more'], }, { default: () => h$4(more) } ), default: () => slotMore, } ) ) } } const ulStyle = useMenuCssVar(props2) const resizeMenu = (vNode) => props2.ellipsis ? useVNodeResize(vNode) : vNode const vMenu = resizeMenu( h$4( 'ul', { key: String(props2.collapse), role: 'menubar', ref: menu2, style: ulStyle.value, class: { 'el-menu': true, 'el-menu--horizontal': props2.mode === 'horizontal', 'el-menu--collapse': props2.collapse, }, }, [...slot, ...vShowMore] ) ) if (props2.collapseTransition && props2.mode === 'vertical') { return h$4(ElMenuCollapseTransition, () => vMenu) } return vMenu } }, }) const menuItemProps = buildProps({ index: { type: definePropType([String, null]), default: null, }, route: { type: definePropType([String, Object]), }, disabled: Boolean, }) const menuItemEmits = { click: (item2) => isString$f(item2.index) && Array.isArray(item2.indexPath), } const COMPONENT_NAME$8 = 'ElMenuItem' const _sfc_main$7_ = defineComponent({ name: COMPONENT_NAME$8, components: { ElTooltip, }, props: menuItemProps, emits: menuItemEmits, setup(props2, { emit: emit2 }) { const instance = getCurrentInstance() const rootMenu = inject('rootMenu') if (!rootMenu) throwError$1(COMPONENT_NAME$8, 'can not inject root menu') const { parentMenu, paddingStyle, indexPath } = useMenu( instance, toRef(props2, 'index') ) const subMenu = inject(`subMenu:${parentMenu.value.uid}`) if (!subMenu) throwError$1(COMPONENT_NAME$8, 'can not inject sub menu') const active = computed(() => props2.index === rootMenu.activeIndex) const item2 = reactive({ index: props2.index, indexPath, active, }) const handleClick2 = () => { if (!props2.disabled) { rootMenu.handleMenuItemClick({ index: props2.index, indexPath: indexPath.value, route: props2.route, }) emit2('click', item2) } } onMounted(() => { subMenu.addSubMenu(item2) rootMenu.addMenuItem(item2) }) onBeforeUnmount(() => { subMenu.removeSubMenu(item2) rootMenu.removeMenuItem(item2) }) return { Effect, parentMenu, rootMenu, paddingStyle, active, handleClick: handleClick2, } }, }) const _hoisted_1$6q = { class: 'el-menu-tooltip__trigger' } function _sfc_render$U(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_tooltip = resolveComponent('el-tooltip') return ( openBlock(), createElementBlock( 'li', { class: normalizeClass([ 'el-menu-item', { 'is-active': _ctx.active, 'is-disabled': _ctx.disabled, }, ]), role: 'menuitem', tabindex: '-1', style: normalizeStyle$1(_ctx.paddingStyle), onClick: _cache[0] || (_cache[0] = (...args) => _ctx.handleClick && _ctx.handleClick(...args)), }, [ _ctx.parentMenu.type.name === 'ElMenu' && _ctx.rootMenu.props.collapse && _ctx.$slots.title ? (openBlock(), createBlock( _component_el_tooltip, { key: 0, effect: _ctx.Effect.DARK, placement: 'right', 'fallback-placements': ['left'], persistent: '', }, { content: withCtx(() => [renderSlot(_ctx.$slots, 'title')]), default: withCtx(() => [ createElementVNode('div', _hoisted_1$6q, [ renderSlot(_ctx.$slots, 'default'), ]), ]), _: 3, }, 8, ['effect'] )) : (openBlock(), createElementBlock( Fragment, { key: 1 }, [ renderSlot(_ctx.$slots, 'default'), renderSlot(_ctx.$slots, 'title'), ], 64 )), ], 6 ) ) } var MenuItem = /* @__PURE__ */ _export_sfc$1(_sfc_main$7_, [ ['render', _sfc_render$U], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/menu/src/menu-item.vue', ], ]) const menuItemGroupProps = { title: String, } const COMPONENT_NAME$7 = 'ElMenuItemGroup' const _sfc_main$7Z = defineComponent({ name: COMPONENT_NAME$7, props: menuItemGroupProps, setup() { const instance = getCurrentInstance() const menu2 = inject('rootMenu') if (!menu2) throwError$1(COMPONENT_NAME$7, 'can not inject root menu') const levelPadding = computed(() => { if (menu2.props.collapse) return 20 let padding = 20 let parent2 = instance.parent while (parent2 && parent2.type.name !== 'ElMenu') { if (parent2.type.name === 'ElSubMenu') { padding += 20 } parent2 = parent2.parent } return padding }) return { levelPadding, } }, }) const _hoisted_1$6p = { class: 'el-menu-item-group' } function _sfc_render$T(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock('li', _hoisted_1$6p, [ createElementVNode( 'div', { class: 'el-menu-item-group__title', style: normalizeStyle$1({ paddingLeft: `${_ctx.levelPadding}px` }), }, [ !_ctx.$slots.title ? (openBlock(), createElementBlock( Fragment, { key: 0 }, [createTextVNode(toDisplayString$1(_ctx.title), 1)], 2112 )) : renderSlot(_ctx.$slots, 'title', { key: 1 }), ], 4 ), createElementVNode('ul', null, [renderSlot(_ctx.$slots, 'default')]), ]) ) } var MenuItemGroup = /* @__PURE__ */ _export_sfc$1(_sfc_main$7Z, [ ['render', _sfc_render$T], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/menu/src/menu-item-group.vue', ], ]) const ElMenu = withInstall(Menu$2, { MenuItem, MenuItemGroup, SubMenu, }) const ElMenuItem = withNoopInstall(MenuItem) const ElMenuItemGroup = withNoopInstall(MenuItemGroup) const ElSubMenu = withNoopInstall(SubMenu) const pageHeaderProps = buildProps({ icon: { type: iconPropType, default: () => back$1, }, title: String, content: { type: String, default: '', }, }) const pageHeaderEmits = { back: () => true, } const __default__$h = { name: 'ElPageHeader', } const _sfc_main$7Y = /* @__PURE__ */ defineComponent({ ...__default__$h, props: pageHeaderProps, emits: pageHeaderEmits, setup(__props2, { emit: emit2 }) { const { t: t3 } = useLocale() const ns = useNamespace('page-header') function handleClick2() { emit2('back') } return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { class: normalizeClass(unref(ns).b()), }, [ createElementVNode( 'div', { class: normalizeClass(unref(ns).e('left')), onClick: handleClick2, }, [ _ctx.icon || _ctx.$slots.icon ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass(unref(ns).e('icon')), }, [ renderSlot(_ctx.$slots, 'icon', {}, () => [ _ctx.icon ? (openBlock(), createBlock( unref(ElIcon), { key: 0 }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent(_ctx.icon) )), ]), _: 1, } )) : createCommentVNode('v-if', true), ]), ], 2 )) : createCommentVNode('v-if', true), createElementVNode( 'div', { class: normalizeClass(unref(ns).e('title')), }, [ renderSlot(_ctx.$slots, 'title', {}, () => [ createTextVNode( toDisplayString$1( _ctx.title || unref(t3)('el.pageHeader.title') ), 1 ), ]), ], 2 ), ], 2 ), createElementVNode( 'div', { class: normalizeClass(unref(ns).e('content')), }, [ renderSlot(_ctx.$slots, 'content', {}, () => [ createTextVNode(toDisplayString$1(_ctx.content), 1), ]), ], 2 ), ], 2 ) ) } }, }) var PageHeader = /* @__PURE__ */ _export_sfc$1(_sfc_main$7Y, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/page-header/src/page-header.vue', ], ]) const ElPageHeader = withInstall(PageHeader) const paginationPrevProps = { disabled: Boolean, currentPage: { type: Number, default: 1, }, prevText: { type: String, default: '', }, } const _sfc_main$7X = defineComponent({ name: 'ElPaginationPrev', components: { ElIcon, ArrowLeft: arrowLeft, }, props: paginationPrevProps, emits: ['click'], setup(props2) { const internalDisabled = computed( () => props2.disabled || props2.currentPage <= 1 ) return { internalDisabled, } }, }) const _hoisted_1$6o = ['disabled', 'aria-disabled'] const _hoisted_2$5d = { key: 0 } function _sfc_render$S(_ctx, _cache, $props2, $setup, $data, $options) { const _component_arrow_left = resolveComponent('arrow-left') const _component_el_icon = resolveComponent('el-icon') return ( openBlock(), createElementBlock( 'button', { type: 'button', class: 'btn-prev', disabled: _ctx.internalDisabled, 'aria-disabled': _ctx.internalDisabled, onClick: _cache[0] || (_cache[0] = ($event) => _ctx.$emit('click', $event)), }, [ _ctx.prevText ? (openBlock(), createElementBlock( 'span', _hoisted_2$5d, toDisplayString$1(_ctx.prevText), 1 )) : (openBlock(), createBlock( _component_el_icon, { key: 1 }, { default: withCtx(() => [createVNode$1(_component_arrow_left)]), _: 1, } )), ], 8, _hoisted_1$6o ) ) } var Prev = /* @__PURE__ */ _export_sfc$1(_sfc_main$7X, [ ['render', _sfc_render$S], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/pagination/src/components/prev.vue', ], ]) const paginationNextProps = { disabled: Boolean, currentPage: { type: Number, default: 1, }, pageCount: { type: Number, default: 50, }, nextText: { type: String, default: '', }, } const _sfc_main$7W = defineComponent({ name: 'ElPaginationNext', components: { ElIcon, ArrowRight: arrowRight, }, props: paginationNextProps, emits: ['click'], setup(props2) { const internalDisabled = computed( () => props2.disabled || props2.currentPage === props2.pageCount || props2.pageCount === 0 ) return { internalDisabled, } }, }) const _hoisted_1$6n = ['disabled', 'aria-disabled'] const _hoisted_2$5c = { key: 0 } function _sfc_render$R(_ctx, _cache, $props2, $setup, $data, $options) { const _component_arrow_right = resolveComponent('arrow-right') const _component_el_icon = resolveComponent('el-icon') return ( openBlock(), createElementBlock( 'button', { type: 'button', class: 'btn-next', disabled: _ctx.internalDisabled, 'aria-disabled': _ctx.internalDisabled, onClick: _cache[0] || (_cache[0] = ($event) => _ctx.$emit('click', $event)), }, [ _ctx.nextText ? (openBlock(), createElementBlock( 'span', _hoisted_2$5c, toDisplayString$1(_ctx.nextText), 1 )) : (openBlock(), createBlock( _component_el_icon, { key: 1 }, { default: withCtx(() => [createVNode$1(_component_arrow_right)]), _: 1, } )), ], 8, _hoisted_1$6n ) ) } var Next = /* @__PURE__ */ _export_sfc$1(_sfc_main$7W, [ ['render', _sfc_render$R], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/pagination/src/components/next.vue', ], ]) const selectGroupKey = 'ElSelectGroup' const selectKey = 'ElSelect' function useOption$1(props2, states) { const select2 = inject(selectKey) const selectGroup = inject(selectGroupKey, { disabled: false }) const isObject2 = computed(() => { return ( Object.prototype.toString.call(props2.value).toLowerCase() === '[object object]' ) }) const itemSelected = computed(() => { if (!select2.props.multiple) { return isEqual2(props2.value, select2.props.modelValue) } else { return contains2(select2.props.modelValue, props2.value) } }) const limitReached = computed(() => { if (select2.props.multiple) { const modelValue = select2.props.modelValue || [] return ( !itemSelected.value && modelValue.length >= select2.props.multipleLimit && select2.props.multipleLimit > 0 ) } else { return false } }) const currentLabel = computed(() => { return props2.label || (isObject2.value ? '' : props2.value) }) const currentValue = computed(() => { return props2.value || props2.label || '' }) const isDisabled = computed(() => { return props2.disabled || states.groupDisabled || limitReached.value }) const instance = getCurrentInstance() const contains2 = (arr = [], target2) => { if (!isObject2.value) { return arr && arr.includes(target2) } else { const valueKey = select2.props.valueKey return ( arr && arr.some((item2) => { return get$a(item2, valueKey) === get$a(target2, valueKey) }) ) } } const isEqual2 = (a2, b2) => { if (!isObject2.value) { return a2 === b2 } else { const { valueKey } = select2.props return get$a(a2, valueKey) === get$a(b2, valueKey) } } const hoverItem = () => { if (!props2.disabled && !selectGroup.disabled) { select2.hoverIndex = select2.optionsArray.indexOf(instance.proxy) } } watch$1( () => currentLabel.value, () => { if (!props2.created && !select2.props.remote) select2.setSelected() } ) watch$1( () => props2.value, (val2, oldVal) => { const { remote, valueKey } = select2.props if (!props2.created && !remote) { if ( valueKey && typeof val2 === 'object' && typeof oldVal === 'object' && val2[valueKey] === oldVal[valueKey] ) { return } select2.setSelected() } } ) watch$1( () => selectGroup.disabled, () => { states.groupDisabled = selectGroup.disabled }, { immediate: true } ) const { queryChange } = toRaw(select2) watch$1(queryChange, (changes) => { const { query } = unref(changes) const regexp4 = new RegExp(escapeStringRegexp(query), 'i') states.visible = regexp4.test(currentLabel.value) || props2.created if (!states.visible) { select2.filteredOptionsCount-- } }) return { select: select2, currentLabel, currentValue, itemSelected, isDisabled, hoverItem, } } const _sfc_main$7V = defineComponent({ name: 'ElOption', componentName: 'ElOption', props: { value: { required: true, type: [String, Number, Boolean, Object], }, label: [String, Number], created: Boolean, disabled: { type: Boolean, default: false, }, }, setup(props2) { const ns = useNamespace('select') const states = reactive({ index: -1, groupDisabled: false, visible: true, hitState: false, hover: false, }) const { currentLabel, itemSelected, isDisabled, select: select2, hoverItem, } = useOption$1(props2, states) const { visible, hover } = toRefs$2(states) const vm = getCurrentInstance().proxy const key2 = vm.value select2.onOptionCreate(vm) onBeforeUnmount(() => { const { selected } = select2 const selectedOptions = select2.props.multiple ? selected : [selected] const doesSelected = selectedOptions.some((item2) => { return item2.value === vm.value }) if (select2.cachedOptions.get(key2) === vm && !doesSelected) { nextTick(() => { select2.cachedOptions.delete(key2) }) } select2.onOptionDestroy(key2, vm) }) function selectOptionClick() { if (props2.disabled !== true && states.groupDisabled !== true) { select2.handleOptionSelect(vm, true) } } return { ns, currentLabel, itemSelected, isDisabled, select: select2, hoverItem, visible, hover, selectOptionClick, states, } }, }) function _sfc_render$Q(_ctx, _cache, $props2, $setup, $data, $options) { return withDirectives( (openBlock(), createElementBlock( 'li', { class: normalizeClass([ _ctx.ns.be('dropdown', 'item'), _ctx.ns.is('disabled', _ctx.isDisabled), { selected: _ctx.itemSelected, hover: _ctx.hover, }, ]), onMouseenter: _cache[0] || (_cache[0] = (...args) => _ctx.hoverItem && _ctx.hoverItem(...args)), onClick: _cache[1] || (_cache[1] = withModifiers( (...args) => _ctx.selectOptionClick && _ctx.selectOptionClick(...args), ['stop'] )), }, [ renderSlot(_ctx.$slots, 'default', {}, () => [ createElementVNode( 'span', null, toDisplayString$1(_ctx.currentLabel), 1 ), ]), ], 34 )), [[vShow, _ctx.visible]] ) } var Option$1 = /* @__PURE__ */ _export_sfc$1(_sfc_main$7V, [ ['render', _sfc_render$Q], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/select/src/option.vue', ], ]) const _sfc_main$7U = defineComponent({ name: 'ElSelectDropdown', componentName: 'ElSelectDropdown', setup() { const select2 = inject(selectKey) const ns = useNamespace('select') const popperClass = computed(() => select2.props.popperClass) const isMultiple2 = computed(() => select2.props.multiple) const isFitInputWidth = computed(() => select2.props.fitInputWidth) const minWidth = ref('') function updateMinWidth() { var _a2 minWidth.value = `${ (_a2 = select2.selectWrapper) == null ? void 0 : _a2.getBoundingClientRect().width }px` } onMounted(() => { updateMinWidth() addResizeListener(select2.selectWrapper, updateMinWidth) }) onBeforeUnmount(() => { removeResizeListener(select2.selectWrapper, updateMinWidth) }) return { ns, minWidth, popperClass, isMultiple: isMultiple2, isFitInputWidth, } }, }) function _sfc_render$P(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock( 'div', { class: normalizeClass([ _ctx.ns.b('dropdown'), _ctx.ns.is('multiple', _ctx.isMultiple), _ctx.popperClass, ]), style: normalizeStyle$1({ [_ctx.isFitInputWidth ? 'width' : 'minWidth']: _ctx.minWidth, }), }, [renderSlot(_ctx.$slots, 'default')], 6 ) ) } var ElSelectMenu$1 = /* @__PURE__ */ _export_sfc$1(_sfc_main$7U, [ ['render', _sfc_render$P], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/select/src/select-dropdown.vue', ], ]) function useSelectStates(props2) { const { t: t3 } = useLocale() return reactive({ options: /* @__PURE__ */ new Map(), cachedOptions: /* @__PURE__ */ new Map(), createdLabel: null, createdSelected: false, selected: props2.multiple ? [] : {}, inputLength: 20, inputWidth: 0, initialInputHeight: 0, optionsCount: 0, filteredOptionsCount: 0, visible: false, softFocus: false, selectedLabel: '', hoverIndex: -1, query: '', previousQuery: null, inputHovering: false, cachedPlaceHolder: '', currentPlaceholder: t3('el.select.placeholder'), menuVisibleOnFocus: false, isOnComposition: false, isSilentBlur: false, prefixWidth: 11, tagInMultiLine: false, }) } const useSelect$2 = (props2, states, ctx) => { const { t: t3 } = useLocale() const ns = useNamespace('select') const reference2 = ref(null) const input = ref(null) const tooltipRef = ref(null) const tags = ref(null) const selectWrapper = ref(null) const scrollbar = ref(null) const hoverOption = ref(-1) const queryChange = shallowRef({ query: '' }) const groupQueryChange = shallowRef('') const elForm = inject(formContextKey, {}) const elFormItem = inject(formItemContextKey, {}) const readonly2 = computed( () => !props2.filterable || props2.multiple || !states.visible ) const selectDisabled = computed(() => props2.disabled || elForm.disabled) const showClose = computed(() => { const hasValue = props2.multiple ? Array.isArray(props2.modelValue) && props2.modelValue.length > 0 : props2.modelValue !== void 0 && props2.modelValue !== null && props2.modelValue !== '' const criteria = props2.clearable && !selectDisabled.value && states.inputHovering && hasValue return criteria }) const iconComponent = computed(() => props2.remote && props2.filterable ? '' : props2.suffixIcon ) const iconReverse = computed(() => ns.is('reverse', iconComponent.value && states.visible) ) const debounce$12 = computed(() => (props2.remote ? 300 : 0)) const emptyText = computed(() => { if (props2.loading) { return props2.loadingText || t3('el.select.loading') } else { if (props2.remote && states.query === '' && states.options.size === 0) return false if ( props2.filterable && states.query && states.options.size > 0 && states.filteredOptionsCount === 0 ) { return props2.noMatchText || t3('el.select.noMatch') } if (states.options.size === 0) { return props2.noDataText || t3('el.select.noData') } } return null }) const optionsArray = computed(() => Array.from(states.options.values())) const cachedOptionsArray = computed(() => Array.from(states.cachedOptions.values()) ) const showNewOption = computed(() => { const hasExistingOption = optionsArray.value .filter((option2) => { return !option2.created }) .some((option2) => { return option2.currentLabel === states.query }) return ( props2.filterable && props2.allowCreate && states.query !== '' && !hasExistingOption ) }) const selectSize = useSize$1() const collapseTagSize = computed(() => ['small'].includes(selectSize.value) ? 'small' : 'default' ) const dropMenuVisible = computed({ get() { return states.visible && emptyText.value !== false }, set(val2) { states.visible = val2 }, }) watch$1( () => selectDisabled.value, () => { nextTick(() => { resetInputHeight() }) } ) watch$1( () => props2.placeholder, (val2) => { states.cachedPlaceHolder = states.currentPlaceholder = val2 } ) watch$1( () => props2.modelValue, (val2, oldVal) => { var _a2 if (props2.multiple) { resetInputHeight() if ((val2 && val2.length > 0) || (input.value && states.query !== '')) { states.currentPlaceholder = '' } else { states.currentPlaceholder = states.cachedPlaceHolder } if (props2.filterable && !props2.reserveKeyword) { states.query = '' handleQueryChange(states.query) } } setSelected() if (props2.filterable && !props2.multiple) { states.inputLength = 20 } if (!isEqual$4(val2, oldVal)) { ;(_a2 = elFormItem.validate) == null ? void 0 : _a2.call(elFormItem, 'change').catch((err) => debugWarn()) } }, { flush: 'post', deep: true, } ) watch$1( () => states.visible, (val2) => { var _a2, _b2, _c2 if (!val2) { input.value && input.value.blur() states.query = '' states.previousQuery = null states.selectedLabel = '' states.inputLength = 20 states.menuVisibleOnFocus = false resetHoverIndex() nextTick(() => { if ( input.value && input.value.value === '' && states.selected.length === 0 ) { states.currentPlaceholder = states.cachedPlaceHolder } }) if (!props2.multiple) { if (states.selected) { if ( props2.filterable && props2.allowCreate && states.createdSelected && states.createdLabel ) { states.selectedLabel = states.createdLabel } else { states.selectedLabel = states.selected.currentLabel } if (props2.filterable) states.query = states.selectedLabel } if (props2.filterable) { states.currentPlaceholder = states.cachedPlaceHolder } } } else { ;(_b2 = (_a2 = tooltipRef.value) == null ? void 0 : _a2.updatePopper) == null ? void 0 : _b2.call(_a2) if (props2.filterable) { states.filteredOptionsCount = states.optionsCount states.query = props2.remote ? '' : states.selectedLabel if (props2.multiple) { ;(_c2 = input.value) == null ? void 0 : _c2.focus() } else { if (states.selectedLabel) { states.currentPlaceholder = `${states.selectedLabel}` states.selectedLabel = '' } } handleQueryChange(states.query) if (!props2.multiple && !props2.remote) { queryChange.value.query = '' triggerRef(queryChange) triggerRef(groupQueryChange) } } } ctx.emit('visible-change', val2) } ) watch$1( () => states.options.entries(), () => { var _a2, _b2, _c2 if (!isClient$1) return ;(_b2 = (_a2 = tooltipRef.value) == null ? void 0 : _a2.updatePopper) == null ? void 0 : _b2.call(_a2) if (props2.multiple) { resetInputHeight() } const inputs = ((_c2 = selectWrapper.value) == null ? void 0 : _c2.querySelectorAll('input')) || [] if (!Array.from(inputs).includes(document.activeElement)) { setSelected() } if ( props2.defaultFirstOption && (props2.filterable || props2.remote) && states.filteredOptionsCount ) { checkDefaultFirstOption() } }, { flush: 'post', } ) watch$1( () => states.hoverIndex, (val2) => { if (typeof val2 === 'number' && val2 > -1) { hoverOption.value = optionsArray.value[val2] || {} } optionsArray.value.forEach((option2) => { option2.hover = hoverOption.value === option2 }) } ) const resetInputHeight = () => { if (props2.collapseTags && !props2.filterable) return nextTick(() => { var _a2, _b2 if (!reference2.value) return const inputChildNodes = reference2.value.$el.childNodes const input2 = Array.from(inputChildNodes).find( (item2) => item2.tagName === 'INPUT' ) const _tags = tags.value const sizeInMap = states.initialInputHeight || 40 input2.style.height = states.selected.length === 0 ? `${sizeInMap}px` : `${Math.max( _tags ? _tags.clientHeight + (_tags.clientHeight > sizeInMap ? 6 : 0) : 0, sizeInMap )}px` states.tagInMultiLine = Number.parseFloat(input2.style.height) >= sizeInMap if (states.visible && emptyText.value !== false) { ;(_b2 = (_a2 = tooltipRef.value) == null ? void 0 : _a2.updatePopper) == null ? void 0 : _b2.call(_a2) } }) } const handleQueryChange = (val2) => { if (states.previousQuery === val2 || states.isOnComposition) return if ( states.previousQuery === null && (typeof props2.filterMethod === 'function' || typeof props2.remoteMethod === 'function') ) { states.previousQuery = val2 return } states.previousQuery = val2 nextTick(() => { var _a2, _b2 if (states.visible) (_b2 = (_a2 = tooltipRef.value) == null ? void 0 : _a2.updatePopper) == null ? void 0 : _b2.call(_a2) }) states.hoverIndex = -1 if (props2.multiple && props2.filterable) { nextTick(() => { const length2 = input.value.value.length * 15 + 20 states.inputLength = props2.collapseTags ? Math.min(50, length2) : length2 managePlaceholder() resetInputHeight() }) } if (props2.remote && typeof props2.remoteMethod === 'function') { states.hoverIndex = -1 props2.remoteMethod(val2) } else if (typeof props2.filterMethod === 'function') { props2.filterMethod(val2) triggerRef(groupQueryChange) } else { states.filteredOptionsCount = states.optionsCount queryChange.value.query = val2 triggerRef(queryChange) triggerRef(groupQueryChange) } if ( props2.defaultFirstOption && (props2.filterable || props2.remote) && states.filteredOptionsCount ) { checkDefaultFirstOption() } } const managePlaceholder = () => { if (states.currentPlaceholder !== '') { states.currentPlaceholder = input.value.value ? '' : states.cachedPlaceHolder } } const checkDefaultFirstOption = () => { const optionsInDropdown = optionsArray.value.filter( (n2) => n2.visible && !n2.disabled && !n2.states.groupDisabled ) const userCreatedOption = optionsInDropdown.find((n2) => n2.created) const firstOriginOption = optionsInDropdown[0] states.hoverIndex = getValueIndex( optionsArray.value, userCreatedOption || firstOriginOption ) } const setSelected = () => { var _a2 if (!props2.multiple) { const option2 = getOption(props2.modelValue) if ((_a2 = option2.props) == null ? void 0 : _a2.created) { states.createdLabel = option2.props.value states.createdSelected = true } else { states.createdSelected = false } states.selectedLabel = option2.currentLabel states.selected = option2 if (props2.filterable) states.query = states.selectedLabel return } else { states.selectedLabel = '' } const result = [] if (Array.isArray(props2.modelValue)) { props2.modelValue.forEach((value2) => { result.push(getOption(value2)) }) } states.selected = result nextTick(() => { resetInputHeight() }) } const getOption = (value2) => { let option2 const isObjectValue = toRawType(value2).toLowerCase() === 'object' const isNull2 = toRawType(value2).toLowerCase() === 'null' const isUndefined2 = toRawType(value2).toLowerCase() === 'undefined' for (let i2 = states.cachedOptions.size - 1; i2 >= 0; i2--) { const cachedOption = cachedOptionsArray.value[i2] const isEqualValue = isObjectValue ? get$a(cachedOption, props2.valueKey) === get$a(value2, props2.valueKey) : cachedOption.value === value2 if (isEqualValue) { option2 = { value: value2, currentLabel: cachedOption.currentLabel, isDisabled: cachedOption.isDisabled, } break } } if (option2) return option2 const label = isObjectValue ? value2.label : !isNull2 && !isUndefined2 ? value2 : '' const newOption = { value: value2, currentLabel: label, } if (props2.multiple) { newOption.hitState = false } return newOption } const resetHoverIndex = () => { setTimeout(() => { const valueKey = props2.valueKey if (!props2.multiple) { states.hoverIndex = optionsArray.value.findIndex((item2) => { return getValueKey(item2) === getValueKey(states.selected) }) } else { if (states.selected.length > 0) { states.hoverIndex = Math.min.apply( null, states.selected.map((selected) => { return optionsArray.value.findIndex((item2) => { return get$a(item2, valueKey) === get$a(selected, valueKey) }) }) ) } else { states.hoverIndex = -1 } } }, 300) } const handleResize = () => { var _a2, _b2 resetInputWidth() ;(_b2 = (_a2 = tooltipRef.value) == null ? void 0 : _a2.updatePopper) == null ? void 0 : _b2.call(_a2) if (props2.multiple && !props2.filterable) resetInputHeight() } const resetInputWidth = () => { var _a2 states.inputWidth = (_a2 = reference2.value) == null ? void 0 : _a2.$el.getBoundingClientRect().width } const onInputChange = () => { if (props2.filterable && states.query !== states.selectedLabel) { states.query = states.selectedLabel handleQueryChange(states.query) } } const debouncedOnInputChange = debounce$3(() => { onInputChange() }, debounce$12.value) const debouncedQueryChange = debounce$3((e2) => { handleQueryChange(e2.target.value) }, debounce$12.value) const emitChange = (val2) => { if (!isEqual$4(props2.modelValue, val2)) { ctx.emit(CHANGE_EVENT, val2) } } const deletePrevTag = (e2) => { if (e2.target.value.length <= 0 && !toggleLastOptionHitState()) { const value2 = props2.modelValue.slice() value2.pop() ctx.emit(UPDATE_MODEL_EVENT, value2) emitChange(value2) } if (e2.target.value.length === 1 && props2.modelValue.length === 0) { states.currentPlaceholder = states.cachedPlaceHolder } } const deleteTag = (event, tag) => { const index2 = states.selected.indexOf(tag) if (index2 > -1 && !selectDisabled.value) { const value2 = props2.modelValue.slice() value2.splice(index2, 1) ctx.emit(UPDATE_MODEL_EVENT, value2) emitChange(value2) ctx.emit('remove-tag', tag.value) } event.stopPropagation() } const deleteSelected = (event) => { event.stopPropagation() const value2 = props2.multiple ? [] : '' if (typeof value2 !== 'string') { for (const item2 of states.selected) { if (item2.isDisabled) value2.push(item2.value) } } ctx.emit(UPDATE_MODEL_EVENT, value2) emitChange(value2) states.visible = false ctx.emit('clear') } const handleOptionSelect = (option2, byClick) => { var _a2 if (props2.multiple) { const value2 = (props2.modelValue || []).slice() const optionIndex = getValueIndex(value2, option2.value) if (optionIndex > -1) { value2.splice(optionIndex, 1) } else if ( props2.multipleLimit <= 0 || value2.length < props2.multipleLimit ) { value2.push(option2.value) } ctx.emit(UPDATE_MODEL_EVENT, value2) emitChange(value2) if (option2.created) { states.query = '' handleQueryChange('') states.inputLength = 20 } if (props2.filterable) (_a2 = input.value) == null ? void 0 : _a2.focus() } else { ctx.emit(UPDATE_MODEL_EVENT, option2.value) emitChange(option2.value) states.visible = false } states.isSilentBlur = byClick setSoftFocus() if (states.visible) return nextTick(() => { scrollToOption(option2) }) } const getValueIndex = (arr = [], value2) => { if (!isObject$v(value2)) return arr.indexOf(value2) const valueKey = props2.valueKey let index2 = -1 arr.some((item2, i2) => { if (get$a(item2, valueKey) === get$a(value2, valueKey)) { index2 = i2 return true } return false }) return index2 } const setSoftFocus = () => { states.softFocus = true const _input = input.value || reference2.value if (_input) { _input == null ? void 0 : _input.focus() } } const scrollToOption = (option2) => { var _a2, _b2, _c2, _d, _e const targetOption = Array.isArray(option2) ? option2[0] : option2 let target2 = null if (targetOption == null ? void 0 : targetOption.value) { const options2 = optionsArray.value.filter( (item2) => item2.value === targetOption.value ) if (options2.length > 0) { target2 = options2[0].$el } } if (tooltipRef.value && target2) { const menu2 = (_d = (_c2 = (_b2 = (_a2 = tooltipRef.value) == null ? void 0 : _a2.popperRef) == null ? void 0 : _b2.contentRef) == null ? void 0 : _c2.querySelector) == null ? void 0 : _d.call(_c2, `.${ns.be('dropdown', 'wrap')}`) if (menu2) { scrollIntoView$1(menu2, target2) } } ;(_e = scrollbar.value) == null ? void 0 : _e.handleScroll() } const onOptionCreate = (vm) => { states.optionsCount++ states.filteredOptionsCount++ states.options.set(vm.value, vm) states.cachedOptions.set(vm.value, vm) } const onOptionDestroy = (key2, vm) => { if (states.options.get(key2) === vm) { states.optionsCount-- states.filteredOptionsCount-- states.options.delete(key2) } } const resetInputState = (e2) => { if (e2.code !== EVENT_CODE.backspace) toggleLastOptionHitState(false) states.inputLength = input.value.value.length * 15 + 20 resetInputHeight() } const toggleLastOptionHitState = (hit) => { if (!Array.isArray(states.selected)) return const option2 = states.selected[states.selected.length - 1] if (!option2) return if (hit === true || hit === false) { option2.hitState = hit return hit } option2.hitState = !option2.hitState return option2.hitState } const handleComposition = (event) => { const text2 = event.target.value if (event.type === 'compositionend') { states.isOnComposition = false nextTick(() => handleQueryChange(text2)) } else { const lastCharacter = text2[text2.length - 1] || '' states.isOnComposition = !isKorean(lastCharacter) } } const handleMenuEnter = () => { nextTick(() => scrollToOption(states.selected)) } const handleFocus = (event) => { if (!states.softFocus) { if (props2.automaticDropdown || props2.filterable) { if (props2.filterable && !states.visible) { states.menuVisibleOnFocus = true } states.visible = true } ctx.emit('focus', event) } else { states.softFocus = false } } const blur = () => { var _a2 states.visible = false ;(_a2 = reference2.value) == null ? void 0 : _a2.blur() } const handleBlur = (event) => { nextTick(() => { if (states.isSilentBlur) { states.isSilentBlur = false } else { ctx.emit('blur', event) } }) states.softFocus = false } const handleClearClick = (event) => { deleteSelected(event) } const handleClose = () => { states.visible = false } const toggleMenu = () => { var _a2 if (props2.automaticDropdown) return if (!selectDisabled.value) { if (states.menuVisibleOnFocus) { states.menuVisibleOnFocus = false } else { states.visible = !states.visible } if (states.visible) { ;(_a2 = input.value || reference2.value) == null ? void 0 : _a2.focus() } } } const selectOption = () => { if (!states.visible) { toggleMenu() } else { if (optionsArray.value[states.hoverIndex]) { handleOptionSelect(optionsArray.value[states.hoverIndex], void 0) } } } const getValueKey = (item2) => { return isObject$v(item2.value) ? get$a(item2.value, props2.valueKey) : item2.value } const optionsAllDisabled = computed(() => optionsArray.value .filter((option2) => option2.visible) .every((option2) => option2.disabled) ) const navigateOptions = (direction2) => { if (!states.visible) { states.visible = true return } if (states.options.size === 0 || states.filteredOptionsCount === 0) return if (states.isOnComposition) return if (!optionsAllDisabled.value) { if (direction2 === 'next') { states.hoverIndex++ if (states.hoverIndex === states.options.size) { states.hoverIndex = 0 } } else if (direction2 === 'prev') { states.hoverIndex-- if (states.hoverIndex < 0) { states.hoverIndex = states.options.size - 1 } } const option2 = optionsArray.value[states.hoverIndex] if ( option2.disabled === true || option2.states.groupDisabled === true || !option2.visible ) { navigateOptions(direction2) } nextTick(() => scrollToOption(hoverOption.value)) } } return { optionsArray, selectSize, handleResize, debouncedOnInputChange, debouncedQueryChange, deletePrevTag, deleteTag, deleteSelected, handleOptionSelect, scrollToOption, readonly: readonly2, resetInputHeight, showClose, iconComponent, iconReverse, showNewOption, collapseTagSize, setSelected, managePlaceholder, selectDisabled, emptyText, toggleLastOptionHitState, resetInputState, handleComposition, onOptionCreate, onOptionDestroy, handleMenuEnter, handleFocus, blur, handleBlur, handleClearClick, handleClose, toggleMenu, selectOption, getValueKey, navigateOptions, dropMenuVisible, queryChange, groupQueryChange, reference: reference2, input, tooltipRef, tags, selectWrapper, scrollbar, } } const COMPONENT_NAME$6 = 'ElSelect' const _sfc_main$7T = defineComponent({ name: COMPONENT_NAME$6, componentName: COMPONENT_NAME$6, components: { ElInput, ElSelectMenu: ElSelectMenu$1, ElOption: Option$1, ElTag, ElScrollbar, ElTooltip, ElIcon, }, directives: { ClickOutside }, props: { name: String, id: String, modelValue: { type: [Array, String, Number, Boolean, Object], default: void 0, }, autocomplete: { type: String, default: 'off', }, automaticDropdown: Boolean, size: { type: String, validator: isValidComponentSize, }, effect: { type: String, default: 'light', }, disabled: Boolean, clearable: Boolean, filterable: Boolean, allowCreate: Boolean, loading: Boolean, popperClass: { type: String, default: '', }, remote: Boolean, loadingText: String, noMatchText: String, noDataText: String, remoteMethod: Function, filterMethod: Function, multiple: Boolean, multipleLimit: { type: Number, default: 0, }, placeholder: { type: String, }, defaultFirstOption: Boolean, reserveKeyword: { type: Boolean, default: true, }, valueKey: { type: String, default: 'value', }, collapseTags: Boolean, collapseTagsTooltip: { type: Boolean, default: false, }, popperAppendToBody: { type: Boolean, default: void 0, }, teleported: useTooltipContentProps.teleported, persistent: { type: Boolean, default: true, }, clearIcon: { type: [String, Object], default: circleClose, }, fitInputWidth: { type: Boolean, default: false, }, suffixIcon: { type: [String, Object], default: arrowUp, }, tagType: { ...tagProps.type, default: 'info' }, }, emits: [ UPDATE_MODEL_EVENT, CHANGE_EVENT, 'remove-tag', 'clear', 'visible-change', 'focus', 'blur', ], setup(props2, ctx) { const nsSelect = useNamespace('select') const nsInput = useNamespace('input') const { t: t3 } = useLocale() const states = useSelectStates(props2) const { optionsArray, selectSize, readonly: readonly2, handleResize, collapseTagSize, debouncedOnInputChange, debouncedQueryChange, deletePrevTag, deleteTag, deleteSelected, handleOptionSelect, scrollToOption, setSelected, resetInputHeight, managePlaceholder, showClose, selectDisabled, iconComponent, iconReverse, showNewOption, emptyText, toggleLastOptionHitState, resetInputState, handleComposition, onOptionCreate, onOptionDestroy, handleMenuEnter, handleFocus, blur, handleBlur, handleClearClick, handleClose, toggleMenu, selectOption, getValueKey, navigateOptions, dropMenuVisible, reference: reference2, input, tooltipRef, tags, selectWrapper, scrollbar, queryChange, groupQueryChange, } = useSelect$2(props2, states, ctx) const { focus: focus2 } = useFocus$1(reference2) const { inputWidth, selected, inputLength, filteredOptionsCount, visible, softFocus, selectedLabel, hoverIndex, query, inputHovering, currentPlaceholder, menuVisibleOnFocus, isOnComposition, isSilentBlur, options: options2, cachedOptions, optionsCount, prefixWidth, tagInMultiLine, } = toRefs$2(states) const wrapperKls = computed(() => { const classList2 = [nsSelect.b()] const _selectSize = unref(selectSize) if (_selectSize) { classList2.push(nsSelect.m(_selectSize)) } if (props2.disabled) { classList2.push(nsSelect.m('disabled')) } return classList2 }) const selectTagsStyle = computed(() => ({ maxWidth: `${unref(inputWidth) - 32}px`, width: '100%', })) provide( selectKey, reactive({ props: props2, options: options2, optionsArray, cachedOptions, optionsCount, filteredOptionsCount, hoverIndex, handleOptionSelect, onOptionCreate, onOptionDestroy, selectWrapper, selected, setSelected, queryChange, groupQueryChange, }) ) onMounted(() => { states.cachedPlaceHolder = currentPlaceholder.value = props2.placeholder || t3('el.select.placeholder') if ( props2.multiple && Array.isArray(props2.modelValue) && props2.modelValue.length > 0 ) { currentPlaceholder.value = '' } addResizeListener(selectWrapper.value, handleResize) if (reference2.value && reference2.value.$el) { const sizeMap = { large: 36, default: 32, small: 28, } const input2 = reference2.value.input states.initialInputHeight = input2.getBoundingClientRect().height || sizeMap[selectSize.value] } if (props2.remote && props2.multiple) { resetInputHeight() } nextTick(() => { if (!reference2.value) return if (reference2.value.$el) { inputWidth.value = reference2.value.$el.getBoundingClientRect().width } if (ctx.slots.prefix) { const inputChildNodes = reference2.value.$el.childNodes const input2 = Array.from(inputChildNodes).find( (item2) => item2.tagName === 'INPUT' ) const prefix = reference2.value.$el.querySelector( `.${nsInput.e('prefix')}` ) prefixWidth.value = Math.max( prefix.getBoundingClientRect().width + 5, 30 ) if (states.prefixWidth) { input2.style.paddingLeft = `${Math.max(states.prefixWidth, 30)}px` } } }) setSelected() }) onBeforeUnmount(() => { removeResizeListener(selectWrapper.value, handleResize) }) if (props2.multiple && !Array.isArray(props2.modelValue)) { ctx.emit(UPDATE_MODEL_EVENT, []) } if (!props2.multiple && Array.isArray(props2.modelValue)) { ctx.emit(UPDATE_MODEL_EVENT, '') } const popperPaneRef = computed(() => { var _a2, _b2 return (_b2 = (_a2 = tooltipRef.value) == null ? void 0 : _a2.popperRef) == null ? void 0 : _b2.contentRef }) const { compatTeleported } = useDeprecateAppendToBody( COMPONENT_NAME$6, 'popperAppendToBody' ) return { tagInMultiLine, prefixWidth, selectSize, readonly: readonly2, handleResize, collapseTagSize, debouncedOnInputChange, debouncedQueryChange, deletePrevTag, deleteTag, deleteSelected, handleOptionSelect, scrollToOption, inputWidth, selected, inputLength, filteredOptionsCount, visible, softFocus, selectedLabel, hoverIndex, query, inputHovering, currentPlaceholder, menuVisibleOnFocus, isOnComposition, isSilentBlur, options: options2, resetInputHeight, managePlaceholder, showClose, selectDisabled, iconComponent, iconReverse, showNewOption, emptyText, toggleLastOptionHitState, resetInputState, handleComposition, handleMenuEnter, handleFocus, blur, handleBlur, handleClearClick, handleClose, toggleMenu, selectOption, getValueKey, navigateOptions, dropMenuVisible, focus: focus2, reference: reference2, input, tooltipRef, popperPaneRef, tags, selectWrapper, scrollbar, wrapperKls, selectTagsStyle, compatTeleported, nsSelect, } }, }) const _hoisted_1$6m = { class: 'select-trigger' } const _hoisted_2$5b = ['disabled', 'autocomplete'] const _hoisted_3$4D = { style: { height: '100%', display: 'flex', 'justify-content': 'center', 'align-items': 'center', }, } function _sfc_render$O(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_tag = resolveComponent('el-tag') const _component_el_tooltip = resolveComponent('el-tooltip') const _component_el_icon = resolveComponent('el-icon') const _component_el_input = resolveComponent('el-input') const _component_el_option = resolveComponent('el-option') const _component_el_scrollbar = resolveComponent('el-scrollbar') const _component_el_select_menu = resolveComponent('el-select-menu') const _directive_click_outside = resolveDirective('click-outside') return withDirectives( (openBlock(), createElementBlock( 'div', { ref: 'selectWrapper', class: normalizeClass(_ctx.wrapperKls), onClick: _cache[24] || (_cache[24] = withModifiers( (...args) => _ctx.toggleMenu && _ctx.toggleMenu(...args), ['stop'] )), }, [ createVNode$1( _component_el_tooltip, { ref: 'tooltipRef', visible: _ctx.dropMenuVisible, 'onUpdate:visible': _cache[23] || (_cache[23] = ($event) => (_ctx.dropMenuVisible = $event)), placement: 'bottom-start', teleported: _ctx.compatTeleported, 'popper-class': [_ctx.nsSelect.e('popper'), _ctx.popperClass], 'fallback-placements': [ 'bottom-start', 'top-start', 'right', 'left', ], effect: _ctx.effect, pure: '', trigger: 'click', transition: `${_ctx.nsSelect.namespace.value}-zoom-in-top`, 'stop-popper-mouse-event': false, 'gpu-acceleration': false, persistent: _ctx.persistent, onShow: _ctx.handleMenuEnter, }, { default: withCtx(() => [ createElementVNode('div', _hoisted_1$6m, [ _ctx.multiple ? (openBlock(), createElementBlock( 'div', { key: 0, ref: 'tags', class: normalizeClass(_ctx.nsSelect.e('tags')), style: normalizeStyle$1(_ctx.selectTagsStyle), }, [ _ctx.collapseTags && _ctx.selected.length ? (openBlock(), createElementBlock( 'span', { key: 0, class: normalizeClass([ _ctx.nsSelect.b('tags-wrapper'), { 'has-prefix': _ctx.prefixWidth && _ctx.selected.length, }, ]), }, [ createVNode$1( _component_el_tag, { closable: !_ctx.selectDisabled && !_ctx.selected[0].isDisabled, size: _ctx.collapseTagSize, hit: _ctx.selected[0].hitState, type: _ctx.tagType, 'disable-transitions': '', onClose: _cache[0] || (_cache[0] = ($event) => _ctx.deleteTag( $event, _ctx.selected[0] )), }, { default: withCtx(() => [ createElementVNode( 'span', { class: normalizeClass( _ctx.nsSelect.e('tags-text') ), style: normalizeStyle$1({ maxWidth: _ctx.inputWidth - 123 + 'px', }), }, toDisplayString$1( _ctx.selected[0].currentLabel ), 7 ), ]), _: 1, }, 8, ['closable', 'size', 'hit', 'type'] ), _ctx.selected.length > 1 ? (openBlock(), createBlock( _component_el_tag, { key: 0, closable: false, size: _ctx.collapseTagSize, type: _ctx.tagType, 'disable-transitions': '', }, { default: withCtx(() => [ _ctx.collapseTagsTooltip ? (openBlock(), createBlock( _component_el_tooltip, { key: 0, disabled: _ctx.dropMenuVisible, 'fallback-placements': [ 'bottom', 'top', 'right', 'left', ], effect: _ctx.effect, placement: 'bottom', teleported: false, }, { default: withCtx(() => [ createElementVNode( 'span', { class: normalizeClass( _ctx.nsSelect.e( 'tags-text' ) ), }, '+ ' + toDisplayString$1( _ctx.selected.length - 1 ), 3 ), ]), content: withCtx(() => [ createElementVNode( 'div', { class: normalizeClass( _ctx.nsSelect.e( 'collapse-tags' ) ), }, [ (openBlock(true), createElementBlock( Fragment, null, renderList( _ctx.selected, (item2, idx) => { return ( openBlock(), createElementBlock( 'div', { key: idx, class: normalizeClass( _ctx.nsSelect.e( 'collapse-tag' ) ), }, [ (openBlock(), createBlock( _component_el_tag, { key: _ctx.getValueKey( item2 ), class: 'in-tooltip', closable: !_ctx.selectDisabled && !item2.isDisabled, size: _ctx.collapseTagSize, hit: item2.hitState, type: _ctx.tagType, 'disable-transitions': '', style: { margin: '2px', }, onClose: ( $event ) => _ctx.deleteTag( $event, item2 ), }, { default: withCtx( () => [ createElementVNode( 'span', { class: normalizeClass( _ctx.nsSelect.e( 'tags-text' ) ), style: normalizeStyle$1( { maxWidth: _ctx.inputWidth - 75 + 'px', } ), }, toDisplayString$1( item2.currentLabel ), 7 ), ] ), _: 2, }, 1032, [ 'closable', 'size', 'hit', 'type', 'onClose', ] )), ], 2 ) ) } ), 128 )), ], 2 ), ]), _: 1, }, 8, ['disabled', 'effect'] )) : (openBlock(), createElementBlock( 'span', { key: 1, class: normalizeClass( _ctx.nsSelect.e('tags-text') ), }, '+ ' + toDisplayString$1( _ctx.selected.length - 1 ), 3 )), ]), _: 1, }, 8, ['size', 'type'] )) : createCommentVNode('v-if', true), ], 2 )) : createCommentVNode('v-if', true), createCommentVNode('
'), !_ctx.collapseTags ? (openBlock(), createBlock( Transition, { key: 1, onAfterLeave: _ctx.resetInputHeight, }, { default: withCtx(() => [ createElementVNode( 'span', { class: normalizeClass([ _ctx.nsSelect.b('tags-wrapper'), { 'has-prefix': _ctx.prefixWidth && _ctx.selected.length, }, ]), }, [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.selected, (item2) => { return ( openBlock(), createBlock( _component_el_tag, { key: _ctx.getValueKey(item2), closable: !_ctx.selectDisabled && !item2.isDisabled, size: _ctx.collapseTagSize, hit: item2.hitState, type: _ctx.tagType, 'disable-transitions': '', onClose: ($event) => _ctx.deleteTag($event, item2), }, { default: withCtx(() => [ createElementVNode( 'span', { class: normalizeClass( _ctx.nsSelect.e( 'tags-text' ) ), style: normalizeStyle$1({ maxWidth: _ctx.inputWidth - 75 + 'px', }), }, toDisplayString$1( item2.currentLabel ), 7 ), ]), _: 2, }, 1032, [ 'closable', 'size', 'hit', 'type', 'onClose', ] ) ) }), 128 )), ], 2 ), ]), _: 1, }, 8, ['onAfterLeave'] )) : createCommentVNode('v-if', true), createCommentVNode('
'), _ctx.filterable ? withDirectives( (openBlock(), createElementBlock( 'input', { key: 2, ref: 'input', 'onUpdate:modelValue': _cache[1] || (_cache[1] = ($event) => (_ctx.query = $event)), type: 'text', class: normalizeClass([ _ctx.nsSelect.e('input'), _ctx.nsSelect.is(_ctx.selectSize), ]), disabled: _ctx.selectDisabled, autocomplete: _ctx.autocomplete, style: normalizeStyle$1({ marginLeft: (_ctx.prefixWidth && !_ctx.selected.length) || _ctx.tagInMultiLine ? `${_ctx.prefixWidth}px` : '', flexGrow: 1, width: `${ _ctx.inputLength / (_ctx.inputWidth - 32) }%`, maxWidth: `${_ctx.inputWidth - 42}px`, }), onFocus: _cache[2] || (_cache[2] = (...args) => _ctx.handleFocus && _ctx.handleFocus(...args)), onBlur: _cache[3] || (_cache[3] = (...args) => _ctx.handleBlur && _ctx.handleBlur(...args)), onKeyup: _cache[4] || (_cache[4] = (...args) => _ctx.managePlaceholder && _ctx.managePlaceholder(...args)), onKeydown: [ _cache[5] || (_cache[5] = (...args) => _ctx.resetInputState && _ctx.resetInputState(...args)), _cache[6] || (_cache[6] = withKeys( withModifiers( ($event) => _ctx.navigateOptions('next'), ['prevent'] ), ['down'] )), _cache[7] || (_cache[7] = withKeys( withModifiers( ($event) => _ctx.navigateOptions('prev'), ['prevent'] ), ['up'] )), _cache[8] || (_cache[8] = withKeys( withModifiers( ($event) => (_ctx.visible = false), ['stop', 'prevent'] ), ['esc'] )), _cache[9] || (_cache[9] = withKeys( withModifiers( (...args) => _ctx.selectOption && _ctx.selectOption(...args), ['stop', 'prevent'] ), ['enter'] )), _cache[10] || (_cache[10] = withKeys( (...args) => _ctx.deletePrevTag && _ctx.deletePrevTag(...args), ['delete'] )), _cache[11] || (_cache[11] = withKeys( ($event) => (_ctx.visible = false), ['tab'] )), ], onCompositionstart: _cache[12] || (_cache[12] = (...args) => _ctx.handleComposition && _ctx.handleComposition(...args)), onCompositionupdate: _cache[13] || (_cache[13] = (...args) => _ctx.handleComposition && _ctx.handleComposition(...args)), onCompositionend: _cache[14] || (_cache[14] = (...args) => _ctx.handleComposition && _ctx.handleComposition(...args)), onInput: _cache[15] || (_cache[15] = (...args) => _ctx.debouncedQueryChange && _ctx.debouncedQueryChange(...args)), }, null, 46, _hoisted_2$5b )), [[vModelText, _ctx.query]] ) : createCommentVNode('v-if', true), ], 6 )) : createCommentVNode('v-if', true), createVNode$1( _component_el_input, { id: _ctx.id, ref: 'reference', modelValue: _ctx.selectedLabel, 'onUpdate:modelValue': _cache[16] || (_cache[16] = ($event) => (_ctx.selectedLabel = $event)), type: 'text', placeholder: _ctx.currentPlaceholder, name: _ctx.name, autocomplete: _ctx.autocomplete, size: _ctx.selectSize, disabled: _ctx.selectDisabled, readonly: _ctx.readonly, 'validate-event': false, class: normalizeClass([ _ctx.nsSelect.is('focus', _ctx.visible), ]), tabindex: _ctx.multiple && _ctx.filterable ? -1 : void 0, onFocus: _ctx.handleFocus, onBlur: _ctx.handleBlur, onInput: _ctx.debouncedOnInputChange, onPaste: _ctx.debouncedOnInputChange, onCompositionstart: _ctx.handleComposition, onCompositionupdate: _ctx.handleComposition, onCompositionend: _ctx.handleComposition, onKeydown: [ _cache[17] || (_cache[17] = withKeys( withModifiers( ($event) => _ctx.navigateOptions('next'), ['stop', 'prevent'] ), ['down'] )), _cache[18] || (_cache[18] = withKeys( withModifiers( ($event) => _ctx.navigateOptions('prev'), ['stop', 'prevent'] ), ['up'] )), withKeys( withModifiers(_ctx.selectOption, ['stop', 'prevent']), ['enter'] ), _cache[19] || (_cache[19] = withKeys( withModifiers( ($event) => (_ctx.visible = false), ['stop', 'prevent'] ), ['esc'] )), _cache[20] || (_cache[20] = withKeys( ($event) => (_ctx.visible = false), ['tab'] )), ], onMouseenter: _cache[21] || (_cache[21] = ($event) => (_ctx.inputHovering = true)), onMouseleave: _cache[22] || (_cache[22] = ($event) => (_ctx.inputHovering = false)), }, createSlots( { suffix: withCtx(() => [ _ctx.iconComponent ? withDirectives( (openBlock(), createBlock( _component_el_icon, { key: 0, class: normalizeClass([ _ctx.nsSelect.e('caret'), _ctx.nsSelect.e('icon'), _ctx.iconReverse, ]), }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent( _ctx.iconComponent ) )), ]), _: 1, }, 8, ['class'] )), [[vShow, !_ctx.showClose]] ) : createCommentVNode('v-if', true), _ctx.showClose && _ctx.clearIcon ? (openBlock(), createBlock( _component_el_icon, { key: 1, class: normalizeClass([ _ctx.nsSelect.e('caret'), _ctx.nsSelect.e('icon'), ]), onClick: _ctx.handleClearClick, }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent(_ctx.clearIcon) )), ]), _: 1, }, 8, ['class', 'onClick'] )) : createCommentVNode('v-if', true), ]), _: 2, }, [ _ctx.$slots.prefix ? { name: 'prefix', fn: withCtx(() => [ createElementVNode('div', _hoisted_3$4D, [ renderSlot(_ctx.$slots, 'prefix'), ]), ]), } : void 0, ] ), 1032, [ 'id', 'modelValue', 'placeholder', 'name', 'autocomplete', 'size', 'disabled', 'readonly', 'class', 'tabindex', 'onFocus', 'onBlur', 'onInput', 'onPaste', 'onCompositionstart', 'onCompositionupdate', 'onCompositionend', 'onKeydown', ] ), ]), ]), content: withCtx(() => [ createVNode$1(_component_el_select_menu, null, { default: withCtx(() => [ withDirectives( createVNode$1( _component_el_scrollbar, { ref: 'scrollbar', tag: 'ul', 'wrap-class': _ctx.nsSelect.be('dropdown', 'wrap'), 'view-class': _ctx.nsSelect.be('dropdown', 'list'), class: normalizeClass([ _ctx.nsSelect.is( 'empty', !_ctx.allowCreate && Boolean(_ctx.query) && _ctx.filteredOptionsCount === 0 ), ]), }, { default: withCtx(() => [ _ctx.showNewOption ? (openBlock(), createBlock( _component_el_option, { key: 0, value: _ctx.query, created: true, }, null, 8, ['value'] )) : createCommentVNode('v-if', true), renderSlot(_ctx.$slots, 'default'), ]), _: 3, }, 8, ['wrap-class', 'view-class', 'class'] ), [[vShow, _ctx.options.size > 0 && !_ctx.loading]] ), _ctx.emptyText && (!_ctx.allowCreate || _ctx.loading || (_ctx.allowCreate && _ctx.options.size === 0)) ? (openBlock(), createElementBlock( Fragment, { key: 0 }, [ _ctx.$slots.empty ? renderSlot(_ctx.$slots, 'empty', { key: 0 }) : (openBlock(), createElementBlock( 'p', { key: 1, class: normalizeClass( _ctx.nsSelect.be('dropdown', 'empty') ), }, toDisplayString$1(_ctx.emptyText), 3 )), ], 2112 )) : createCommentVNode('v-if', true), ]), _: 3, }), ]), _: 3, }, 8, [ 'visible', 'teleported', 'popper-class', 'effect', 'transition', 'persistent', 'onShow', ] ), ], 2 )), [[_directive_click_outside, _ctx.handleClose, _ctx.popperPaneRef]] ) } var Select$3 = /* @__PURE__ */ _export_sfc$1(_sfc_main$7T, [ ['render', _sfc_render$O], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/select/src/select.vue', ], ]) const _sfc_main$7S = defineComponent({ name: 'ElOptionGroup', componentName: 'ElOptionGroup', props: { label: String, disabled: { type: Boolean, default: false, }, }, setup(props2) { const ns = useNamespace('select') const visible = ref(true) const instance = getCurrentInstance() const children = ref([]) provide( selectGroupKey, reactive({ ...toRefs$2(props2), }) ) const select2 = inject(selectKey) onMounted(() => { children.value = flattedChildren(instance.subTree) }) const flattedChildren = (node2) => { const children2 = [] if (Array.isArray(node2.children)) { node2.children.forEach((child) => { var _a2 if ( child.type && child.type.name === 'ElOption' && child.component && child.component.proxy ) { children2.push(child.component.proxy) } else if ((_a2 = child.children) == null ? void 0 : _a2.length) { children2.push(...flattedChildren(child)) } }) } return children2 } const { groupQueryChange } = toRaw(select2) watch$1(groupQueryChange, () => { visible.value = children.value.some((option2) => option2.visible === true) }) return { visible, ns, } }, }) function _sfc_render$N(_ctx, _cache, $props2, $setup, $data, $options) { return withDirectives( (openBlock(), createElementBlock( 'ul', { class: normalizeClass(_ctx.ns.be('group', 'wrap')), }, [ createElementVNode( 'li', { class: normalizeClass(_ctx.ns.be('group', 'title')), }, toDisplayString$1(_ctx.label), 3 ), createElementVNode('li', null, [ createElementVNode( 'ul', { class: normalizeClass(_ctx.ns.b('group')), }, [renderSlot(_ctx.$slots, 'default')], 2 ), ]), ], 2 )), [[vShow, _ctx.visible]] ) } var OptionGroup = /* @__PURE__ */ _export_sfc$1(_sfc_main$7S, [ ['render', _sfc_render$N], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/select/src/option-group.vue', ], ]) const ElSelect = withInstall(Select$3, { Option: Option$1, OptionGroup, }) const ElOption$1 = withNoopInstall(Option$1) const ElOptionGroup = withNoopInstall(OptionGroup) const usePagination = () => inject(elPaginationKey, {}) const paginationSizesProps = buildProps({ pageSize: { type: Number, required: true, }, pageSizes: { type: definePropType(Array), default: () => mutable([10, 20, 30, 40, 50, 100]), }, popperClass: { type: String, default: '', }, disabled: Boolean, size: { type: String, default: 'default', }, }) const _sfc_main$7R = defineComponent({ name: 'ElPaginationSizes', components: { ElSelect, ElOption: ElOption$1, }, props: paginationSizesProps, emits: ['page-size-change'], setup(props2, { emit: emit2 }) { const { t: t3 } = useLocale() const ns = useNamespace('pagination') const pagination = usePagination() const innerPageSize = ref(props2.pageSize) watch$1( () => props2.pageSizes, (newVal, oldVal) => { if (isEqual$4(newVal, oldVal)) return if (Array.isArray(newVal)) { const pageSize = newVal.includes(props2.pageSize) ? props2.pageSize : props2.pageSizes[0] emit2('page-size-change', pageSize) } } ) watch$1( () => props2.pageSize, (newVal) => { innerPageSize.value = newVal } ) const innerPagesizes = computed(() => props2.pageSizes) function handleChange(val2) { var _a2 if (val2 !== innerPageSize.value) { innerPageSize.value = val2 ;(_a2 = pagination.handleSizeChange) == null ? void 0 : _a2.call(pagination, Number(val2)) } } return { ns, innerPagesizes, innerPageSize, t: t3, handleChange, } }, }) function _sfc_render$M(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_option = resolveComponent('el-option') const _component_el_select = resolveComponent('el-select') return ( openBlock(), createElementBlock( 'span', { class: normalizeClass(_ctx.ns.e('sizes')), }, [ createVNode$1( _component_el_select, { 'model-value': _ctx.innerPageSize, disabled: _ctx.disabled, 'popper-class': _ctx.popperClass, size: _ctx.size, onChange: _ctx.handleChange, }, { default: withCtx(() => [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.innerPagesizes, (item2) => { return ( openBlock(), createBlock( _component_el_option, { key: item2, value: item2, label: item2 + _ctx.t('el.pagination.pagesize'), }, null, 8, ['value', 'label'] ) ) }), 128 )), ]), _: 1, }, 8, ['model-value', 'disabled', 'popper-class', 'size', 'onChange'] ), ], 2 ) ) } var Sizes = /* @__PURE__ */ _export_sfc$1(_sfc_main$7R, [ ['render', _sfc_render$M], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/pagination/src/components/sizes.vue', ], ]) const _sfc_main$7Q = defineComponent({ name: 'ElPaginationJumper', components: { ElInput, }, setup() { const { t: t3 } = useLocale() const ns = useNamespace('pagination') const { pageCount, disabled, currentPage: currentPage2, changeEvent, } = usePagination() const userInput = ref() const innerValue = computed(() => { var _a2 return (_a2 = userInput.value) != null ? _a2 : currentPage2 == null ? void 0 : currentPage2.value }) function handleInput(val2) { userInput.value = +val2 } function handleChange(val2) { val2 = Math.trunc(+val2) changeEvent == null ? void 0 : changeEvent(+val2) userInput.value = void 0 } return { ns, pageCount, disabled, innerValue, t: t3, handleInput, handleChange, } }, }) const _hoisted_1$6l = ['disabled'] function _sfc_render$L(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_input = resolveComponent('el-input') return ( openBlock(), createElementBlock( 'span', { class: normalizeClass(_ctx.ns.e('jump')), disabled: _ctx.disabled, }, [ createTextVNode( toDisplayString$1(_ctx.t('el.pagination.goto')) + ' ', 1 ), createVNode$1( _component_el_input, { size: 'small', class: normalizeClass([ _ctx.ns.e('editor'), _ctx.ns.is('in-pagination'), ]), min: 1, max: _ctx.pageCount, disabled: _ctx.disabled, 'model-value': _ctx.innerValue, type: 'number', 'onUpdate:modelValue': _ctx.handleInput, onChange: _ctx.handleChange, }, null, 8, [ 'class', 'max', 'disabled', 'model-value', 'onUpdate:modelValue', 'onChange', ] ), createTextVNode( ' ' + toDisplayString$1(_ctx.t('el.pagination.pageClassifier')), 1 ), ], 10, _hoisted_1$6l ) ) } var Jumper = /* @__PURE__ */ _export_sfc$1(_sfc_main$7Q, [ ['render', _sfc_render$L], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/pagination/src/components/jumper.vue', ], ]) const paginationTotalProps = { total: { type: Number, default: 1e3, }, } const _sfc_main$7P = defineComponent({ name: 'ElPaginationTotal', props: paginationTotalProps, setup() { const { t: t3 } = useLocale() const ns = useNamespace('pagination') const { disabled } = usePagination() return { t: t3, ns, disabled, } }, }) const _hoisted_1$6k = ['disabled'] function _sfc_render$K(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock( 'span', { class: normalizeClass(_ctx.ns.e('total')), disabled: _ctx.disabled, }, toDisplayString$1( _ctx.t('el.pagination.total', { total: _ctx.total, }) ), 11, _hoisted_1$6k ) ) } var Total = /* @__PURE__ */ _export_sfc$1(_sfc_main$7P, [ ['render', _sfc_render$K], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/pagination/src/components/total.vue', ], ]) const paginationPagerProps = { currentPage: { type: Number, default: 1, }, pageCount: { type: Number, required: true, }, pagerCount: { type: Number, default: 7, }, disabled: Boolean, } const _sfc_main$7O = defineComponent({ name: 'ElPaginationPager', components: { DArrowLeft: dArrowLeft, DArrowRight: dArrowRight, MoreFilled: moreFilled, }, props: paginationPagerProps, emits: ['change'], setup(props2, { emit: emit2 }) { const nsPager = useNamespace('pager') const nsIcon = useNamespace('icon') const showPrevMore = ref(false) const showNextMore = ref(false) const quickPrevHover = ref(false) const quickNextHover = ref(false) const pagers = computed(() => { const pagerCount = props2.pagerCount const halfPagerCount = (pagerCount - 1) / 2 const currentPage2 = Number(props2.currentPage) const pageCount = Number(props2.pageCount) let showPrevMore2 = false let showNextMore2 = false if (pageCount > pagerCount) { if (currentPage2 > pagerCount - halfPagerCount) { showPrevMore2 = true } if (currentPage2 < pageCount - halfPagerCount) { showNextMore2 = true } } const array4 = [] if (showPrevMore2 && !showNextMore2) { const startPage = pageCount - (pagerCount - 2) for (let i2 = startPage; i2 < pageCount; i2++) { array4.push(i2) } } else if (!showPrevMore2 && showNextMore2) { for (let i2 = 2; i2 < pagerCount; i2++) { array4.push(i2) } } else if (showPrevMore2 && showNextMore2) { const offset2 = Math.floor(pagerCount / 2) - 1 for ( let i2 = currentPage2 - offset2; i2 <= currentPage2 + offset2; i2++ ) { array4.push(i2) } } else { for (let i2 = 2; i2 < pageCount; i2++) { array4.push(i2) } } return array4 }) watchEffect(() => { const halfPagerCount = (props2.pagerCount - 1) / 2 showPrevMore.value = false showNextMore.value = false if (props2.pageCount > props2.pagerCount) { if (props2.currentPage > props2.pagerCount - halfPagerCount) { showPrevMore.value = true } if (props2.currentPage < props2.pageCount - halfPagerCount) { showNextMore.value = true } } }) function onMouseenter(direction2) { if (props2.disabled) return if (direction2 === 'left') { quickPrevHover.value = true } else { quickNextHover.value = true } } function onEnter(e2) { const target2 = e2.target if ( target2.tagName.toLowerCase() === 'li' && Array.from(target2.classList).includes('number') ) { const newPage = Number(target2.textContent) if (newPage !== props2.currentPage) { emit2('change', newPage) } } } function onPagerClick(event) { const target2 = event.target if (target2.tagName.toLowerCase() === 'ul' || props2.disabled) { return } let newPage = Number(target2.textContent) const pageCount = props2.pageCount const currentPage2 = props2.currentPage const pagerCountOffset = props2.pagerCount - 2 if (target2.className.includes('more')) { if (target2.className.includes('quickprev')) { newPage = currentPage2 - pagerCountOffset } else if (target2.className.includes('quicknext')) { newPage = currentPage2 + pagerCountOffset } } if (!Number.isNaN(+newPage)) { if (newPage < 1) { newPage = 1 } if (newPage > pageCount) { newPage = pageCount } } if (newPage !== currentPage2) { emit2('change', newPage) } } return { showPrevMore, showNextMore, quickPrevHover, quickNextHover, pagers, nsPager, nsIcon, onMouseenter, onPagerClick, onEnter, } }, }) const _hoisted_1$6j = ['aria-current'] const _hoisted_2$5a = ['aria-current'] const _hoisted_3$4C = ['aria-current'] function _sfc_render$J(_ctx, _cache, $props2, $setup, $data, $options) { const _component_d_arrow_left = resolveComponent('d-arrow-left') const _component_more_filled = resolveComponent('more-filled') const _component_d_arrow_right = resolveComponent('d-arrow-right') return ( openBlock(), createElementBlock( 'ul', { class: normalizeClass(_ctx.nsPager.b()), onClick: _cache[4] || (_cache[4] = (...args) => _ctx.onPagerClick && _ctx.onPagerClick(...args)), onKeyup: _cache[5] || (_cache[5] = withKeys( (...args) => _ctx.onEnter && _ctx.onEnter(...args), ['enter'] )), }, [ _ctx.pageCount > 0 ? (openBlock(), createElementBlock( 'li', { key: 0, class: normalizeClass([ [ _ctx.nsPager.is('active', _ctx.currentPage === 1), _ctx.nsPager.is('disabled', _ctx.disabled), ], 'number', ]), 'aria-current': _ctx.currentPage === 1, tabindex: '0', }, ' 1 ', 10, _hoisted_1$6j )) : createCommentVNode('v-if', true), _ctx.showPrevMore ? (openBlock(), createElementBlock( 'li', { key: 1, class: normalizeClass([ 'more', 'btn-quickprev', _ctx.nsIcon.b(), _ctx.nsPager.is('disabled', _ctx.disabled), ]), onMouseenter: _cache[0] || (_cache[0] = ($event) => _ctx.onMouseenter('left')), onMouseleave: _cache[1] || (_cache[1] = ($event) => (_ctx.quickPrevHover = false)), }, [ _ctx.quickPrevHover ? (openBlock(), createBlock(_component_d_arrow_left, { key: 0 })) : (openBlock(), createBlock(_component_more_filled, { key: 1 })), ], 34 )) : createCommentVNode('v-if', true), (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.pagers, (pager) => { return ( openBlock(), createElementBlock( 'li', { key: pager, class: normalizeClass([ [ _ctx.nsPager.is('active', _ctx.currentPage === pager), _ctx.nsPager.is('disabled', _ctx.disabled), ], 'number', ]), 'aria-current': _ctx.currentPage === pager, tabindex: '0', }, toDisplayString$1(pager), 11, _hoisted_2$5a ) ) }), 128 )), _ctx.showNextMore ? (openBlock(), createElementBlock( 'li', { key: 2, class: normalizeClass([ 'more', 'btn-quicknext', _ctx.nsIcon.b(), _ctx.nsPager.is('disabled', _ctx.disabled), ]), onMouseenter: _cache[2] || (_cache[2] = ($event) => _ctx.onMouseenter('right')), onMouseleave: _cache[3] || (_cache[3] = ($event) => (_ctx.quickNextHover = false)), }, [ _ctx.quickNextHover ? (openBlock(), createBlock(_component_d_arrow_right, { key: 0 })) : (openBlock(), createBlock(_component_more_filled, { key: 1 })), ], 34 )) : createCommentVNode('v-if', true), _ctx.pageCount > 1 ? (openBlock(), createElementBlock( 'li', { key: 3, class: normalizeClass([ [ _ctx.nsPager.is( 'active', _ctx.currentPage === _ctx.pageCount ), _ctx.nsPager.is('disabled', _ctx.disabled), ], 'number', ]), 'aria-current': _ctx.currentPage === _ctx.pageCount, tabindex: '0', }, toDisplayString$1(_ctx.pageCount), 11, _hoisted_3$4C )) : createCommentVNode('v-if', true), ], 34 ) ) } var Pager = /* @__PURE__ */ _export_sfc$1(_sfc_main$7O, [ ['render', _sfc_render$J], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/pagination/src/components/pager.vue', ], ]) const isAbsent = (v4) => typeof v4 !== 'number' const paginationProps = buildProps({ total: Number, pageSize: Number, defaultPageSize: Number, currentPage: Number, defaultCurrentPage: Number, pageCount: Number, pagerCount: { type: Number, validator: (value2) => { return ( typeof value2 === 'number' && Math.trunc(value2) === value2 && value2 > 4 && value2 < 22 && value2 % 2 === 1 ) }, default: 7, }, layout: { type: String, default: ['prev', 'pager', 'next', 'jumper', '->', 'total'].join(', '), }, pageSizes: { type: definePropType(Array), default: () => mutable([10, 20, 30, 40, 50, 100]), }, popperClass: { type: String, default: '', }, prevText: { type: String, default: '', }, nextText: { type: String, default: '', }, small: Boolean, background: Boolean, disabled: Boolean, hideOnSinglePage: Boolean, }) const paginationEmits = { 'update:current-page': (val2) => typeof val2 === 'number', 'update:page-size': (val2) => typeof val2 === 'number', 'size-change': (val2) => typeof val2 === 'number', 'current-change': (val2) => typeof val2 === 'number', 'prev-click': (val2) => typeof val2 === 'number', 'next-click': (val2) => typeof val2 === 'number', } const componentName = 'ElPagination' var Pagination = defineComponent({ name: componentName, props: paginationProps, emits: paginationEmits, setup(props2, { emit: emit2, slots }) { const { t: t3 } = useLocale() const ns = useNamespace('pagination') const vnodeProps = getCurrentInstance().vnode.props || {} const hasCurrentPageListener = 'onUpdate:currentPage' in vnodeProps || 'onUpdate:current-page' in vnodeProps || 'onCurrentChange' in vnodeProps const hasPageSizeListener = 'onUpdate:pageSize' in vnodeProps || 'onUpdate:page-size' in vnodeProps || 'onSizeChange' in vnodeProps const assertValidUsage = computed(() => { if (isAbsent(props2.total) && isAbsent(props2.pageCount)) return false if (!isAbsent(props2.currentPage) && !hasCurrentPageListener) return false if (props2.layout.includes('sizes')) { if (!isAbsent(props2.pageCount)) { if (!hasPageSizeListener) return false } else if (!isAbsent(props2.total)) { if (!isAbsent(props2.pageSize)) { if (!hasPageSizeListener) { return false } } } } return true }) const innerPageSize = ref( isAbsent(props2.defaultPageSize) ? 10 : props2.defaultPageSize ) const innerCurrentPage = ref( isAbsent(props2.defaultCurrentPage) ? 1 : props2.defaultCurrentPage ) const pageSizeBridge = computed({ get() { return isAbsent(props2.pageSize) ? innerPageSize.value : props2.pageSize }, set(v4) { if (isAbsent(props2.pageSize)) { innerPageSize.value = v4 } if (hasPageSizeListener) { emit2('update:page-size', v4) emit2('size-change', v4) } }, }) const pageCountBridge = computed(() => { let pageCount = 0 if (!isAbsent(props2.pageCount)) { pageCount = props2.pageCount } else if (!isAbsent(props2.total)) { pageCount = Math.max(1, Math.ceil(props2.total / pageSizeBridge.value)) } return pageCount }) const currentPageBridge = computed({ get() { return isAbsent(props2.currentPage) ? innerCurrentPage.value : props2.currentPage }, set(v4) { let newCurrentPage = v4 if (v4 < 1) { newCurrentPage = 1 } else if (v4 > pageCountBridge.value) { newCurrentPage = pageCountBridge.value } if (isAbsent(props2.currentPage)) { innerCurrentPage.value = newCurrentPage } if (hasCurrentPageListener) { emit2('update:current-page', newCurrentPage) emit2('current-change', newCurrentPage) } }, }) watch$1(pageCountBridge, (val2) => { if (currentPageBridge.value > val2) currentPageBridge.value = val2 }) function handleCurrentChange(val2) { currentPageBridge.value = val2 } function handleSizeChange(val2) { pageSizeBridge.value = val2 const newPageCount = pageCountBridge.value if (currentPageBridge.value > newPageCount) { currentPageBridge.value = newPageCount } } function prev() { if (props2.disabled) return currentPageBridge.value -= 1 emit2('prev-click', currentPageBridge.value) } function next() { if (props2.disabled) return currentPageBridge.value += 1 emit2('next-click', currentPageBridge.value) } function addClass2(element, cls) { if (element) { if (!element.props) { element.props = {} } element.props.class = [element.props.class, cls].join(' ') } } provide(elPaginationKey, { pageCount: pageCountBridge, disabled: computed(() => props2.disabled), currentPage: currentPageBridge, changeEvent: handleCurrentChange, handleSizeChange, }) return () => { var _a2, _b2 if (!assertValidUsage.value) { debugWarn(componentName, t3('el.pagination.deprecationWarning')) return null } if (!props2.layout) return null if (props2.hideOnSinglePage && pageCountBridge.value <= 1) return null const rootChildren = [] const rightWrapperChildren = [] const rightWrapperRoot = h$4( 'div', { class: ns.e('rightwrapper') }, rightWrapperChildren ) const TEMPLATE_MAP = { prev: h$4(Prev, { disabled: props2.disabled, currentPage: currentPageBridge.value, prevText: props2.prevText, onClick: prev, }), jumper: h$4(Jumper), pager: h$4(Pager, { currentPage: currentPageBridge.value, pageCount: pageCountBridge.value, pagerCount: props2.pagerCount, onChange: handleCurrentChange, disabled: props2.disabled, }), next: h$4(Next, { disabled: props2.disabled, currentPage: currentPageBridge.value, pageCount: pageCountBridge.value, nextText: props2.nextText, onClick: next, }), sizes: h$4(Sizes, { pageSize: pageSizeBridge.value, pageSizes: props2.pageSizes, popperClass: props2.popperClass, disabled: props2.disabled, size: props2.small ? 'small' : 'default', }), slot: (_b2 = (_a2 = slots == null ? void 0 : slots.default) == null ? void 0 : _a2.call(slots)) != null ? _b2 : null, total: h$4(Total, { total: isAbsent(props2.total) ? 0 : props2.total }), } const components = props2.layout.split(',').map((item2) => item2.trim()) let haveRightWrapper = false components.forEach((c2) => { if (c2 === '->') { haveRightWrapper = true return } if (!haveRightWrapper) { rootChildren.push(TEMPLATE_MAP[c2]) } else { rightWrapperChildren.push(TEMPLATE_MAP[c2]) } }) addClass2(rootChildren[0], ns.is('first')) addClass2(rootChildren[rootChildren.length - 1], ns.is('last')) if (haveRightWrapper && rightWrapperChildren.length > 0) { addClass2(rightWrapperChildren[0], ns.is('first')) addClass2( rightWrapperChildren[rightWrapperChildren.length - 1], ns.is('last') ) rootChildren.push(rightWrapperRoot) } return h$4( 'div', { role: 'pagination', 'aria-label': 'pagination', class: [ ns.b(), ns.is('background', props2.background), { [ns.m('small')]: props2.small, }, ], }, rootChildren ) } }, }) const ElPagination = withInstall(Pagination) const popconfirmProps = buildProps({ title: { type: String, }, confirmButtonText: { type: String, }, cancelButtonText: { type: String, }, confirmButtonType: { type: String, values: buttonTypes, default: 'primary', }, cancelButtonType: { type: String, values: buttonTypes, default: 'text', }, icon: { type: iconPropType, default: questionFilled, }, iconColor: { type: String, default: '#f90', }, hideIcon: { type: Boolean, default: false, }, hideAfter: { type: Number, default: 200, }, onConfirm: { type: definePropType(Function), }, onCancel: { type: definePropType(Function), }, teleported: useTooltipContentProps.teleported, persistent: useTooltipContentProps.persistent, }) const COMPONENT_NAME$5 = 'ElPopconfirm' const _sfc_main$7N = defineComponent({ name: COMPONENT_NAME$5, components: { ElButton, ElTooltip, ElIcon, }, props: popconfirmProps, setup(props2) { const { compatTeleported } = useDeprecateAppendToBody( COMPONENT_NAME$5, 'appendToBody' ) const { t: t3 } = useLocale() const ns = useNamespace('popconfirm') const tooltipRef = ref() const hidePopper = () => { var _a2, _b2 ;(_b2 = (_a2 = unref(tooltipRef)) == null ? void 0 : _a2.onClose) == null ? void 0 : _b2.call(_a2) } const handleCallback = () => { hidePopper() } const confirm2 = (e2) => { var _a2 ;(_a2 = props2.onConfirm) == null ? void 0 : _a2.call(props2, e2) handleCallback() } const cancel2 = (e2) => { var _a2 ;(_a2 = props2.onCancel) == null ? void 0 : _a2.call(props2, e2) handleCallback() } const finalConfirmButtonText = computed( () => props2.confirmButtonText || t3('el.popconfirm.confirmButtonText') ) const finalCancelButtonText = computed( () => props2.cancelButtonText || t3('el.popconfirm.cancelButtonText') ) return { finalConfirmButtonText, finalCancelButtonText, tooltipRef, ns, compatTeleported, confirm: confirm2, cancel: cancel2, } }, }) function _sfc_render$I(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_icon = resolveComponent('el-icon') const _component_el_button = resolveComponent('el-button') const _component_el_tooltip = resolveComponent('el-tooltip') return ( openBlock(), createBlock( _component_el_tooltip, mergeProps({ ref: 'tooltipRef' }, _ctx.$attrs, { trigger: 'click', effect: 'light', 'popper-class': `${_ctx.ns.namespace.value}-popover`, teleported: _ctx.compatTeleported, 'fallback-placements': ['bottom', 'top', 'right', 'left'], 'hide-after': _ctx.hideAfter, persistent: _ctx.persistent, }), { content: withCtx(() => [ createElementVNode( 'div', { class: normalizeClass(_ctx.ns.b()), }, [ createElementVNode( 'div', { class: normalizeClass(_ctx.ns.e('main')), }, [ !_ctx.hideIcon && _ctx.icon ? (openBlock(), createBlock( _component_el_icon, { key: 0, class: normalizeClass(_ctx.ns.e('icon')), style: normalizeStyle$1({ color: _ctx.iconColor }), }, { default: withCtx(() => [ (openBlock(), createBlock(resolveDynamicComponent(_ctx.icon))), ]), _: 1, }, 8, ['class', 'style'] )) : createCommentVNode('v-if', true), createTextVNode(' ' + toDisplayString$1(_ctx.title), 1), ], 2 ), createElementVNode( 'div', { class: normalizeClass(_ctx.ns.e('action')), }, [ createVNode$1( _component_el_button, { size: 'small', type: _ctx.cancelButtonType, onClick: _ctx.cancel, }, { default: withCtx(() => [ createTextVNode( toDisplayString$1(_ctx.finalCancelButtonText), 1 ), ]), _: 1, }, 8, ['type', 'onClick'] ), createVNode$1( _component_el_button, { size: 'small', type: _ctx.confirmButtonType, onClick: _ctx.confirm, }, { default: withCtx(() => [ createTextVNode( toDisplayString$1(_ctx.finalConfirmButtonText), 1 ), ]), _: 1, }, 8, ['type', 'onClick'] ), ], 2 ), ], 2 ), ]), default: withCtx(() => [ _ctx.$slots.reference ? renderSlot(_ctx.$slots, 'reference', { key: 0 }) : createCommentVNode('v-if', true), ]), _: 3, }, 16, ['popper-class', 'teleported', 'hide-after', 'persistent'] ) ) } var Popconfirm = /* @__PURE__ */ _export_sfc$1(_sfc_main$7N, [ ['render', _sfc_render$I], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/popconfirm/src/popconfirm.vue', ], ]) const ElPopconfirm = withInstall(Popconfirm) const usePopoverProps = buildProps({ trigger: useTooltipTriggerProps.trigger, placement: dropdownProps.placement, disabled: useTooltipTriggerProps.disabled, visible: useTooltipContentProps.visible, transition: useTooltipContentProps.transition, popperOptions: dropdownProps.popperOptions, tabindex: dropdownProps.tabindex, appendToBody: { type: Boolean, default: void 0 }, content: useTooltipContentProps.content, popperStyle: useTooltipContentProps.popperStyle, popperClass: useTooltipContentProps.popperClass, enterable: { ...useTooltipContentProps.enterable, default: true, }, effect: { ...useTooltipContentProps.effect, default: 'light', }, teleported: useTooltipContentProps.teleported, title: String, width: { type: [String, Number], default: 150, }, offset: { type: Number, default: void 0, }, showAfter: { type: Number, default: 0, }, hideAfter: { type: Number, default: 200, }, autoClose: { type: Number, default: 0, }, showArrow: { type: Boolean, default: true, }, persistent: { type: Boolean, default: true, }, }) const emits = [ 'update:visible', 'before-enter', 'before-leave', 'after-enter', 'after-leave', ] const COMPONENT_NAME$4 = 'ElPopover' const _sfc_main$7M = defineComponent({ name: COMPONENT_NAME$4, components: { ElTooltip, }, props: usePopoverProps, emits, setup(props2, { emit: emit2 }) { const ns = useNamespace('popover') const tooltipRef = ref(null) const popperRef = computed(() => { var _a2 return (_a2 = unref(tooltipRef)) == null ? void 0 : _a2.popperRef }) const width = computed(() => { if (isString$f(props2.width)) { return props2.width } return `${props2.width}px` }) const style2 = computed(() => { return [ { width: width.value, }, props2.popperStyle, ] }) const kls = computed(() => { return [ns.b(), props2.popperClass, { [ns.m('plain')]: !!props2.content }] }) const gpuAcceleration = computed(() => { return props2.transition === 'el-fade-in-linear' }) const { compatTeleported } = useDeprecateAppendToBody( COMPONENT_NAME$4, 'appendToBody' ) const hide2 = () => { var _a2 ;(_a2 = tooltipRef.value) == null ? void 0 : _a2.hide() } const beforeEnter = () => { emit2('before-enter') } const beforeLeave = () => { emit2('before-leave') } const afterEnter = () => { emit2('after-enter') } const afterLeave = () => { emit2('after-leave') } return { compatTeleported, ns, kls, gpuAcceleration, style: style2, tooltipRef, popperRef, hide: hide2, beforeEnter, beforeLeave, afterEnter, afterLeave, } }, }) function _sfc_render$H(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_tooltip = resolveComponent('el-tooltip') return ( openBlock(), createBlock( _component_el_tooltip, mergeProps({ ref: 'tooltipRef' }, _ctx.$attrs, { trigger: _ctx.trigger, placement: _ctx.placement, disabled: _ctx.disabled, visible: _ctx.visible, transition: _ctx.transition, 'popper-options': _ctx.popperOptions, tabindex: _ctx.tabindex, 'append-to-body': _ctx.appendToBody, content: _ctx.content, offset: _ctx.offset, 'show-after': _ctx.showAfter, 'hide-after': _ctx.hideAfter, 'auto-close': _ctx.autoClose, 'show-arrow': _ctx.showArrow, 'aria-label': _ctx.title, effect: _ctx.effect, enterable: _ctx.enterable, 'popper-class': _ctx.kls, 'popper-style': _ctx.style, teleported: _ctx.compatTeleported, persistent: _ctx.persistent, 'gpu-acceleration': _ctx.gpuAcceleration, onBeforeShow: _ctx.beforeEnter, onBeforeHide: _ctx.beforeLeave, onShow: _ctx.afterEnter, onHide: _ctx.afterLeave, }), { content: withCtx(() => [ _ctx.title ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass(_ctx.ns.e('title')), role: 'title', }, toDisplayString$1(_ctx.title), 3 )) : createCommentVNode('v-if', true), renderSlot(_ctx.$slots, 'default', {}, () => [ createTextVNode(toDisplayString$1(_ctx.content), 1), ]), ]), default: withCtx(() => [ _ctx.$slots.reference ? renderSlot(_ctx.$slots, 'reference', { key: 0 }) : createCommentVNode('v-if', true), ]), _: 3, }, 16, [ 'trigger', 'placement', 'disabled', 'visible', 'transition', 'popper-options', 'tabindex', 'append-to-body', 'content', 'offset', 'show-after', 'hide-after', 'auto-close', 'show-arrow', 'aria-label', 'effect', 'enterable', 'popper-class', 'popper-style', 'teleported', 'persistent', 'gpu-acceleration', 'onBeforeShow', 'onBeforeHide', 'onShow', 'onHide', ] ) ) } var Popover$2 = /* @__PURE__ */ _export_sfc$1(_sfc_main$7M, [ ['render', _sfc_render$H], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/popover/src/index.vue', ], ]) const attachEvents = (el2, binding) => { const popperComponent = binding.arg || binding.value const popover = popperComponent == null ? void 0 : popperComponent.popperRef if (popover) { popover.triggerRef = el2 } } var PopoverDirective = { mounted(el2, binding) { attachEvents(el2, binding) }, updated(el2, binding) { attachEvents(el2, binding) }, } const VPopover = 'popover' Popover$2.install = (app2) => { app2.component(Popover$2.name, Popover$2) } PopoverDirective.install = (app2) => { app2.directive(VPopover, PopoverDirective) } const _PopoverDirective = PopoverDirective Popover$2.directive = _PopoverDirective const _Popover = Popover$2 const ElPopover = _Popover const ElPopoverDirective = _PopoverDirective const progressProps = buildProps({ type: { type: String, default: 'line', values: ['line', 'circle', 'dashboard'], }, percentage: { type: Number, default: 0, validator: (val2) => val2 >= 0 && val2 <= 100, }, status: { type: String, default: '', values: ['', 'success', 'exception', 'warning'], }, indeterminate: { type: Boolean, default: false, }, duration: { type: Number, default: 3, }, strokeWidth: { type: Number, default: 6, }, strokeLinecap: { type: definePropType(String), default: 'round', }, textInside: { type: Boolean, default: false, }, width: { type: Number, default: 126, }, showText: { type: Boolean, default: true, }, color: { type: definePropType([String, Array, Function]), default: '', }, format: { type: definePropType(Function), default: (percentage) => `${percentage}%`, }, }) const _sfc_main$7L = defineComponent({ name: 'ElProgress', components: { ElIcon, CircleCheck: circleCheck, CircleClose: circleClose, Check: check$1, Close: close$2, WarningFilled: warningFilled, }, props: progressProps, setup(props2) { const ns = useNamespace('progress') const barStyle = computed(() => ({ width: `${props2.percentage}%`, animationDuration: `${props2.duration}s`, backgroundColor: getCurrentColor(props2.percentage), })) const relativeStrokeWidth = computed(() => ((props2.strokeWidth / props2.width) * 100).toFixed(1) ) const radius = computed(() => { if (props2.type === 'circle' || props2.type === 'dashboard') { return Number.parseInt( `${50 - Number.parseFloat(relativeStrokeWidth.value) / 2}`, 10 ) } else { return 0 } }) const trackPath = computed(() => { const r2 = radius.value const isDashboard = props2.type === 'dashboard' return ` M 50 50 m 0 ${isDashboard ? '' : '-'}${r2} a ${r2} ${r2} 0 1 1 0 ${isDashboard ? '-' : ''}${r2 * 2} a ${r2} ${r2} 0 1 1 0 ${isDashboard ? '' : '-'}${r2 * 2} ` }) const perimeter = computed(() => 2 * Math.PI * radius.value) const rate = computed(() => (props2.type === 'dashboard' ? 0.75 : 1)) const strokeDashoffset = computed(() => { const offset2 = (-1 * perimeter.value * (1 - rate.value)) / 2 return `${offset2}px` }) const trailPathStyle = computed(() => ({ strokeDasharray: `${perimeter.value * rate.value}px, ${ perimeter.value }px`, strokeDashoffset: strokeDashoffset.value, })) const circlePathStyle = computed(() => ({ strokeDasharray: `${ perimeter.value * rate.value * (props2.percentage / 100) }px, ${perimeter.value}px`, strokeDashoffset: strokeDashoffset.value, transition: 'stroke-dasharray 0.6s ease 0s, stroke 0.6s ease', })) const stroke = computed(() => { let ret if (props2.color) { ret = getCurrentColor(props2.percentage) } else { switch (props2.status) { case 'success': ret = '#13ce66' break case 'exception': ret = '#ff4949' break case 'warning': ret = '#e6a23c' break default: ret = '#20a0ff' } } return ret }) const statusIcon = computed(() => { if (props2.status === 'warning') { return warningFilled } if (props2.type === 'line') { return props2.status === 'success' ? circleCheck : circleClose } else { return props2.status === 'success' ? check$1 : close$2 } }) const progressTextSize = computed(() => { return props2.type === 'line' ? 12 + props2.strokeWidth * 0.4 : props2.width * 0.111111 + 2 }) const content2 = computed(() => props2.format(props2.percentage)) const getCurrentColor = (percentage) => { var _a2 const { color: color2 } = props2 if (typeof color2 === 'function') { return color2(percentage) } else if (typeof color2 === 'string') { return color2 } else { const span = 100 / color2.length const seriesColors = color2.map((seriesColor, index2) => { if (typeof seriesColor === 'string') { return { color: seriesColor, percentage: (index2 + 1) * span, } } return seriesColor }) const colors = seriesColors.sort( (a2, b2) => a2.percentage - b2.percentage ) for (const color22 of colors) { if (color22.percentage > percentage) return color22.color } return (_a2 = colors[colors.length - 1]) == null ? void 0 : _a2.color } } const slotData = computed(() => { return { percentage: props2.percentage, } }) return { ns, barStyle, relativeStrokeWidth, radius, trackPath, perimeter, rate, strokeDashoffset, trailPathStyle, circlePathStyle, stroke, statusIcon, progressTextSize, content: content2, slotData, } }, }) const _hoisted_1$6i = ['aria-valuenow'] const _hoisted_2$59 = { viewBox: '0 0 100 100' } const _hoisted_3$4B = ['d', 'stroke-width'] const _hoisted_4$3$ = ['d', 'stroke', 'stroke-linecap', 'stroke-width'] const _hoisted_5$3B = { key: 0 } function _sfc_render$G(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_icon = resolveComponent('el-icon') return ( openBlock(), createElementBlock( 'div', { class: normalizeClass([ _ctx.ns.b(), _ctx.ns.m(_ctx.type), _ctx.ns.is(_ctx.status), { [_ctx.ns.m('without-text')]: !_ctx.showText, [_ctx.ns.m('text-inside')]: _ctx.textInside, }, ]), role: 'progressbar', 'aria-valuenow': _ctx.percentage, 'aria-valuemin': '0', 'aria-valuemax': '100', }, [ _ctx.type === 'line' ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass(_ctx.ns.b('bar')), }, [ createElementVNode( 'div', { class: normalizeClass(_ctx.ns.be('bar', 'outer')), style: normalizeStyle$1({ height: `${_ctx.strokeWidth}px`, }), }, [ createElementVNode( 'div', { class: normalizeClass([ _ctx.ns.be('bar', 'inner'), { [_ctx.ns.bem('bar', 'inner', 'indeterminate')]: _ctx.indeterminate, }, ]), style: normalizeStyle$1(_ctx.barStyle), }, [ (_ctx.showText || _ctx.$slots.default) && _ctx.textInside ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass( _ctx.ns.be('bar', 'innerText') ), }, [ renderSlot( _ctx.$slots, 'default', normalizeProps( guardReactiveProps(_ctx.slotData) ), () => [ createElementVNode( 'span', null, toDisplayString$1(_ctx.content), 1 ), ] ), ], 2 )) : createCommentVNode('v-if', true), ], 6 ), ], 6 ), ], 2 )) : (openBlock(), createElementBlock( 'div', { key: 1, class: normalizeClass(_ctx.ns.b('circle')), style: normalizeStyle$1({ height: `${_ctx.width}px`, width: `${_ctx.width}px`, }), }, [ (openBlock(), createElementBlock('svg', _hoisted_2$59, [ createElementVNode( 'path', { class: normalizeClass(_ctx.ns.be('circle', 'track')), d: _ctx.trackPath, stroke: '#e5e9f2', 'stroke-width': _ctx.relativeStrokeWidth, fill: 'none', style: normalizeStyle$1(_ctx.trailPathStyle), }, null, 14, _hoisted_3$4B ), createElementVNode( 'path', { class: normalizeClass(_ctx.ns.be('circle', 'path')), d: _ctx.trackPath, stroke: _ctx.stroke, fill: 'none', 'stroke-linecap': _ctx.strokeLinecap, 'stroke-width': _ctx.percentage ? _ctx.relativeStrokeWidth : 0, style: normalizeStyle$1(_ctx.circlePathStyle), }, null, 14, _hoisted_4$3$ ), ])), ], 6 )), (_ctx.showText || _ctx.$slots.default) && !_ctx.textInside ? (openBlock(), createElementBlock( 'div', { key: 2, class: normalizeClass(_ctx.ns.e('text')), style: normalizeStyle$1({ fontSize: `${_ctx.progressTextSize}px`, }), }, [ renderSlot( _ctx.$slots, 'default', normalizeProps(guardReactiveProps(_ctx.slotData)), () => [ !_ctx.status ? (openBlock(), createElementBlock( 'span', _hoisted_5$3B, toDisplayString$1(_ctx.content), 1 )) : (openBlock(), createBlock( _component_el_icon, { key: 1 }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent(_ctx.statusIcon) )), ]), _: 1, } )), ] ), ], 6 )) : createCommentVNode('v-if', true), ], 10, _hoisted_1$6i ) ) } var Progress$1 = /* @__PURE__ */ _export_sfc$1(_sfc_main$7L, [ ['render', _sfc_render$G], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/progress/src/progress.vue', ], ]) const ElProgress = withInstall(Progress$1) const rateProps = buildProps({ modelValue: { type: Number, default: 0, }, lowThreshold: { type: Number, default: 2, }, highThreshold: { type: Number, default: 4, }, max: { type: Number, default: 5, }, colors: { type: definePropType([Array, Object]), default: () => mutable(['', '', '']), }, voidColor: { type: String, default: '', }, disabledVoidColor: { type: String, default: '', }, icons: { type: definePropType([Array, Object]), default: () => [starFilled, starFilled, starFilled], }, voidIcon: { type: iconPropType, default: () => star, }, disabledVoidIcon: { type: iconPropType, default: () => starFilled, }, disabled: { type: Boolean, default: false, }, allowHalf: { type: Boolean, default: false, }, showText: { type: Boolean, default: false, }, showScore: { type: Boolean, default: false, }, textColor: { type: String, default: '', }, texts: { type: definePropType(Array), default: () => mutable([ 'Extremely bad', 'Disappointed', 'Fair', 'Satisfied', 'Surprise', ]), }, scoreTemplate: { type: String, default: '{value}', }, size: { type: String, validator: isValidComponentSize, }, }) const rateEmits = { change: (value2) => typeof value2 === 'number', [UPDATE_MODEL_EVENT]: (value2) => typeof value2 === 'number', } const _hoisted_1$6h = ['aria-valuenow', 'aria-valuetext', 'aria-valuemax'] const _hoisted_2$58 = ['onMousemove', 'onClick'] const __default__$g = { name: 'ElRate', } const _sfc_main$7K = /* @__PURE__ */ defineComponent({ ...__default__$g, props: rateProps, emits: rateEmits, setup(__props2, { expose, emit: emit2 }) { const props2 = __props2 function getValueFromMap(value2, map2) { const isExcludedObject = (val2) => isObject$v(val2) const matchedKeys = Object.keys(map2) .map((key2) => +key2) .filter((key2) => { const val2 = map2[key2] const excluded = isExcludedObject(val2) ? val2.excluded : false return excluded ? value2 < key2 : value2 <= key2 }) .sort((a2, b2) => a2 - b2) const matchedValue = map2[matchedKeys[0]] return ( (isExcludedObject(matchedValue) && matchedValue.value) || matchedValue ) } const formContext = inject(formContextKey, void 0) const rateSize = useSize$1() const ns = useNamespace('rate') const currentValue = ref(props2.modelValue) const hoverIndex = ref(-1) const pointerAtLeftHalf = ref(true) const rateClasses = computed(() => [ns.b(), ns.m(rateSize.value)]) const rateDisabled = computed( () => props2.disabled || (formContext == null ? void 0 : formContext.disabled) ) const rateStyles = computed(() => { return { '--el-rate-void-color': props2.voidColor, '--el-rate-disabled-void-color': props2.disabledVoidColor, '--el-rate-fill-color': activeColor.value, } }) const text2 = computed(() => { let result = '' if (props2.showScore) { result = props2.scoreTemplate.replace( /\{\s*value\s*\}/, rateDisabled.value ? `${props2.modelValue}` : `${currentValue.value}` ) } else if (props2.showText) { result = props2.texts[Math.ceil(currentValue.value) - 1] } return result }) const valueDecimal = computed( () => props2.modelValue * 100 - Math.floor(props2.modelValue) * 100 ) const colorMap = computed(() => isArray$D(props2.colors) ? { [props2.lowThreshold]: props2.colors[0], [props2.highThreshold]: { value: props2.colors[1], excluded: true }, [props2.max]: props2.colors[2], } : props2.colors ) const activeColor = computed(() => { const color2 = getValueFromMap(currentValue.value, colorMap.value) return isObject$v(color2) ? '' : color2 }) const decimalStyle = computed(() => { let width = '' if (rateDisabled.value) { width = `${valueDecimal.value}%` } else if (props2.allowHalf) { width = '50%' } return { color: activeColor.value, width, } }) const componentMap = computed(() => isArray$D(props2.icons) ? { [props2.lowThreshold]: props2.icons[0], [props2.highThreshold]: { value: props2.icons[1], excluded: true, }, [props2.max]: props2.icons[2], } : props2.icons ) const decimalIconComponent = computed(() => getValueFromMap(props2.modelValue, componentMap.value) ) const voidComponent = computed(() => rateDisabled.value ? props2.disabledVoidIcon : props2.voidIcon ) const activeComponent = computed(() => getValueFromMap(currentValue.value, componentMap.value) ) const iconComponents = computed(() => { const result = Array.from({ length: props2.max }) const threshold = currentValue.value result.fill(activeComponent.value, 0, threshold) result.fill(voidComponent.value, threshold, props2.max) return result }) function showDecimalIcon(item2) { const showWhenDisabled = rateDisabled.value && valueDecimal.value > 0 && item2 - 1 < props2.modelValue && item2 > props2.modelValue const showWhenAllowHalf = props2.allowHalf && pointerAtLeftHalf.value && item2 - 0.5 <= currentValue.value && item2 > currentValue.value return showWhenDisabled || showWhenAllowHalf } function selectValue(value2) { if (rateDisabled.value) { return } if (props2.allowHalf && pointerAtLeftHalf.value) { emit2(UPDATE_MODEL_EVENT, currentValue.value) if (props2.modelValue !== currentValue.value) { emit2('change', currentValue.value) } } else { emit2(UPDATE_MODEL_EVENT, value2) if (props2.modelValue !== value2) { emit2('change', value2) } } } function handleKey(e2) { if (rateDisabled.value) { return } let _currentValue = currentValue.value const code2 = e2.code if (code2 === EVENT_CODE.up || code2 === EVENT_CODE.right) { if (props2.allowHalf) { _currentValue += 0.5 } else { _currentValue += 1 } e2.stopPropagation() e2.preventDefault() } else if (code2 === EVENT_CODE.left || code2 === EVENT_CODE.down) { if (props2.allowHalf) { _currentValue -= 0.5 } else { _currentValue -= 1 } e2.stopPropagation() e2.preventDefault() } _currentValue = _currentValue < 0 ? 0 : _currentValue _currentValue = _currentValue > props2.max ? props2.max : _currentValue emit2(UPDATE_MODEL_EVENT, _currentValue) emit2('change', _currentValue) return _currentValue } function setCurrentValue(value2, event) { if (rateDisabled.value) { return } if (props2.allowHalf) { let target2 = event.target if (hasClass$1(target2, ns.e('item'))) { target2 = target2.querySelector(`.${ns.e('icon')}`) } if (target2.clientWidth === 0 || hasClass$1(target2, ns.e('decimal'))) { target2 = target2.parentNode } pointerAtLeftHalf.value = event.offsetX * 2 <= target2.clientWidth currentValue.value = pointerAtLeftHalf.value ? value2 - 0.5 : value2 } else { currentValue.value = value2 } hoverIndex.value = value2 } function resetCurrentValue() { if (rateDisabled.value) { return } if (props2.allowHalf) { pointerAtLeftHalf.value = props2.modelValue !== Math.floor(props2.modelValue) } currentValue.value = props2.modelValue hoverIndex.value = -1 } watch$1( () => props2.modelValue, (val2) => { currentValue.value = val2 pointerAtLeftHalf.value = props2.modelValue !== Math.floor(props2.modelValue) } ) if (!props2.modelValue) { emit2(UPDATE_MODEL_EVENT, 0) } expose({ setCurrentValue, resetCurrentValue, }) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { class: normalizeClass([ unref(rateClasses), unref(ns).is('disabled', unref(rateDisabled)), ]), role: 'slider', 'aria-valuenow': currentValue.value, 'aria-valuetext': unref(text2), 'aria-valuemin': '0', 'aria-valuemax': _ctx.max, tabindex: '0', style: normalizeStyle$1(unref(rateStyles)), onKeydown: handleKey, }, [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.max, (item2, key2) => { return ( openBlock(), createElementBlock( 'span', { key: key2, class: normalizeClass(unref(ns).e('item')), onMousemove: ($event) => setCurrentValue(item2, $event), onMouseleave: resetCurrentValue, onClick: ($event) => selectValue(item2), }, [ createVNode$1( unref(ElIcon), { class: normalizeClass([ unref(ns).e('icon'), { hover: hoverIndex.value === item2 }, unref(ns).is('active', item2 <= currentValue.value), ]), }, { default: withCtx(() => [ !showDecimalIcon(item2) ? (openBlock(), createBlock( resolveDynamicComponent( unref(iconComponents)[item2 - 1] ), { key: 0 } )) : createCommentVNode('v-if', true), showDecimalIcon(item2) ? (openBlock(), createBlock( unref(ElIcon), { key: 1, style: normalizeStyle$1( unref(decimalStyle) ), class: normalizeClass([ unref(ns).e('icon'), unref(ns).e('decimal'), ]), }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent( unref(decimalIconComponent) ) )), ]), _: 1, }, 8, ['style', 'class'] )) : createCommentVNode('v-if', true), ]), _: 2, }, 1032, ['class'] ), ], 42, _hoisted_2$58 ) ) }), 128 )), _ctx.showText || _ctx.showScore ? (openBlock(), createElementBlock( 'span', { key: 0, class: normalizeClass(unref(ns).e('text')), }, toDisplayString$1(unref(text2)), 3 )) : createCommentVNode('v-if', true), ], 46, _hoisted_1$6h ) ) } }, }) var Rate = /* @__PURE__ */ _export_sfc$1(_sfc_main$7K, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/rate/src/rate.vue', ], ]) const ElRate = withInstall(Rate) const IconMap = { success: 'icon-success', warning: 'icon-warning', error: 'icon-error', info: 'icon-info', } const IconComponentMap = { [IconMap.success]: circleCheckFilled, [IconMap.warning]: warningFilled, [IconMap.error]: circleCloseFilled, [IconMap.info]: infoFilled, } const resultProps = buildProps({ title: { type: String, default: '', }, subTitle: { type: String, default: '', }, icon: { values: ['success', 'warning', 'info', 'error'], default: 'info', }, }) const COMPONENT_NAME$3 = 'ElResult' const _sfc_main$7J = defineComponent({ name: COMPONENT_NAME$3, props: resultProps, setup(props2, { slots }) { const ns = useNamespace('result') useDeprecated( { scope: COMPONENT_NAME$3, type: 'Slot', from: 'subTitle', replacement: 'sub-title', version: '2.1.3', ref: 'https://github.com/element-plus/element-plus/pull/6636/', }, computed(() => !!slots.subTitle) ) const resultIcon = computed(() => { const icon = props2.icon const iconClass = icon && IconMap[icon] ? IconMap[icon] : 'icon-info' const iconComponent = IconComponentMap[iconClass] || IconComponentMap['icon-info'] return { class: iconClass, component: iconComponent, } }) return { ns, resultIcon, } }, }) function _sfc_render$F(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock( 'div', { class: normalizeClass(_ctx.ns.b()), }, [ createElementVNode( 'div', { class: normalizeClass(_ctx.ns.e('icon')), }, [ renderSlot(_ctx.$slots, 'icon', {}, () => [ _ctx.resultIcon.component ? (openBlock(), createBlock( resolveDynamicComponent(_ctx.resultIcon.component), { key: 0, class: normalizeClass(_ctx.resultIcon.class), }, null, 8, ['class'] )) : createCommentVNode('v-if', true), ]), ], 2 ), _ctx.title || _ctx.$slots.title ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass(_ctx.ns.e('title')), }, [ renderSlot(_ctx.$slots, 'title', {}, () => [ createElementVNode( 'p', null, toDisplayString$1(_ctx.title), 1 ), ]), ], 2 )) : createCommentVNode('v-if', true), _ctx.subTitle || _ctx.$slots['sub-title'] ? (openBlock(), createElementBlock( 'div', { key: 1, class: normalizeClass(_ctx.ns.e('subtitle')), }, [ renderSlot(_ctx.$slots, 'sub-title', {}, () => [ createElementVNode( 'p', null, toDisplayString$1(_ctx.subTitle), 1 ), ]), ], 2 )) : createCommentVNode('v-if', true), _ctx.$slots.extra ? (openBlock(), createElementBlock( 'div', { key: 2, class: normalizeClass(_ctx.ns.e('extra')), }, [renderSlot(_ctx.$slots, 'extra')], 2 )) : createCommentVNode('v-if', true), ], 2 ) ) } var Result$1 = /* @__PURE__ */ _export_sfc$1(_sfc_main$7J, [ ['render', _sfc_render$F], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/result/src/result.vue', ], ]) const ElResult = withInstall(Result$1) const rowProps = buildProps({ tag: { type: String, default: 'div', }, gutter: { type: Number, default: 0, }, justify: { type: String, values: [ 'start', 'center', 'end', 'space-around', 'space-between', 'space-evenly', ], default: 'start', }, align: { type: String, values: ['top', 'middle', 'bottom'], default: 'top', }, }) const Row = defineComponent({ name: 'ElRow', props: rowProps, setup(props2, { slots }) { const ns = useNamespace('row') const gutter = computed(() => props2.gutter) provide(rowContextKey, { gutter, }) const style2 = computed(() => { const styles = { marginLeft: '', marginRight: '', } if (props2.gutter) { styles.marginLeft = `-${props2.gutter / 2}px` styles.marginRight = styles.marginLeft } return styles }) return () => createVNode$1( props2.tag, { class: [ ns.b(), ns.is(`justify-${props2.justify}`, props2.justify !== 'start'), ns.is(`align-${props2.align}`, props2.align !== 'top'), ], style: style2.value, }, { default: () => { var _a2 return [(_a2 = slots.default) == null ? void 0 : _a2.call(slots)] }, } ) }, }) const ElRow = withInstall(Row) var safeIsNaN = Number.isNaN || function ponyfill(value2) { return typeof value2 === 'number' && value2 !== value2 } function isEqual$3(first2, second) { if (first2 === second) { return true } if (safeIsNaN(first2) && safeIsNaN(second)) { return true } return false } function areInputsEqual(newInputs, lastInputs) { if (newInputs.length !== lastInputs.length) { return false } for (var i2 = 0; i2 < newInputs.length; i2++) { if (!isEqual$3(newInputs[i2], lastInputs[i2])) { return false } } return true } function memoizeOne(resultFn, isEqual2) { if (isEqual2 === void 0) { isEqual2 = areInputsEqual } var cache2 = null function memoized() { var newArgs = [] for (var _i = 0; _i < arguments.length; _i++) { newArgs[_i] = arguments[_i] } if ( cache2 && cache2.lastThis === this && isEqual2(newArgs, cache2.lastArgs) ) { return cache2.lastResult } var lastResult = resultFn.apply(this, newArgs) cache2 = { lastResult, lastArgs: newArgs, lastThis: this, } return lastResult } memoized.clear = function clear2() { cache2 = null } return memoized } const useCache = () => { const vm = getCurrentInstance() const props2 = vm.proxy.$props return computed(() => { const _getItemStyleCache = (_2, __, ___) => ({}) return props2.perfMode ? memoize(_getItemStyleCache) : memoizeOne(_getItemStyleCache) }) } const DEFAULT_DYNAMIC_LIST_ITEM_SIZE = 50 const ITEM_RENDER_EVT = 'item-rendered' const SCROLL_EVT = 'scroll' const FORWARD = 'forward' const BACKWARD = 'backward' const AUTO_ALIGNMENT = 'auto' const SMART_ALIGNMENT = 'smart' const START_ALIGNMENT = 'start' const CENTERED_ALIGNMENT = 'center' const END_ALIGNMENT = 'end' const HORIZONTAL$1 = 'horizontal' const VERTICAL$1 = 'vertical' const LTR = 'ltr' const RTL = 'rtl' const RTL_OFFSET_NAG = 'negative' const RTL_OFFSET_POS_ASC = 'positive-ascending' const RTL_OFFSET_POS_DESC = 'positive-descending' const ScrollbarDirKey = { [HORIZONTAL$1]: 'left', [VERTICAL$1]: 'top', } const SCROLLBAR_MIN_SIZE = 20 const LayoutKeys = { [HORIZONTAL$1]: 'deltaX', [VERTICAL$1]: 'deltaY', } const useWheel = ( { atEndEdge, atStartEdge, layout: layout2 }, onWheelDelta ) => { let frameHandle let offset2 = 0 const hasReachedEdge = (offset22) => { const edgeReached = (offset22 < 0 && atStartEdge.value) || (offset22 > 0 && atEndEdge.value) return edgeReached } const onWheel = (e2) => { cAF(frameHandle) const newOffset = e2[LayoutKeys[layout2.value]] if (hasReachedEdge(offset2) && hasReachedEdge(offset2 + newOffset)) return offset2 += newOffset if (!isFirefox()) { e2.preventDefault() } frameHandle = rAF(() => { onWheelDelta(offset2) offset2 = 0 }) } return { hasReachedEdge, onWheel, } } const itemSize = buildProp({ type: definePropType([Number, Function]), required: true, }) const estimatedItemSize = buildProp({ type: Number, }) const cache$2 = buildProp({ type: Number, default: 2, }) const direction$1 = buildProp({ type: String, values: ['ltr', 'rtl'], default: 'ltr', }) const initScrollOffset = buildProp({ type: Number, default: 0, }) const total = buildProp({ type: Number, required: true, }) const layout$4 = buildProp({ type: String, values: ['horizontal', 'vertical'], default: VERTICAL$1, }) const virtualizedProps = buildProps({ className: { type: String, default: '', }, containerElement: { type: definePropType([String, Object]), default: 'div', }, data: { type: definePropType(Array), default: () => mutable([]), }, direction: direction$1, height: { type: [String, Number], required: true, }, innerElement: { type: [String, Object], default: 'div', }, style: { type: definePropType([Object, String, Array]), }, useIsScrolling: { type: Boolean, default: false, }, width: { type: [Number, String], required: false, }, perfMode: { type: Boolean, default: true, }, scrollbarAlwaysOn: { type: Boolean, default: false, }, }) const virtualizedListProps = buildProps({ cache: cache$2, estimatedItemSize, layout: layout$4, initScrollOffset, total, itemSize, ...virtualizedProps, }) const virtualizedGridProps = buildProps({ columnCache: cache$2, columnWidth: itemSize, estimatedColumnWidth: estimatedItemSize, estimatedRowHeight: estimatedItemSize, initScrollLeft: initScrollOffset, initScrollTop: initScrollOffset, rowCache: cache$2, rowHeight: itemSize, totalColumn: total, totalRow: total, ...virtualizedProps, }) const virtualizedScrollbarProps = buildProps({ layout: layout$4, total, ratio: { type: Number, required: true, }, clientSize: { type: Number, required: true, }, scrollFrom: { type: Number, required: true, }, visible: Boolean, }) const getScrollDir = (prev, cur) => (prev < cur ? FORWARD : BACKWARD) const isHorizontal = (dir3) => dir3 === LTR || dir3 === RTL || dir3 === HORIZONTAL$1 const isRTL = (dir3) => dir3 === RTL let cachedRTLResult = null function getRTLOffsetType(recalculate = false) { if (cachedRTLResult === null || recalculate) { const outerDiv = document.createElement('div') const outerStyle = outerDiv.style outerStyle.width = '50px' outerStyle.height = '50px' outerStyle.overflow = 'scroll' outerStyle.direction = 'rtl' const innerDiv = document.createElement('div') const innerStyle = innerDiv.style innerStyle.width = '100px' innerStyle.height = '100px' outerDiv.appendChild(innerDiv) document.body.appendChild(outerDiv) if (outerDiv.scrollLeft > 0) { cachedRTLResult = RTL_OFFSET_POS_DESC } else { outerDiv.scrollLeft = 1 if (outerDiv.scrollLeft === 0) { cachedRTLResult = RTL_OFFSET_NAG } else { cachedRTLResult = RTL_OFFSET_POS_ASC } } document.body.removeChild(outerDiv) return cachedRTLResult } return cachedRTLResult } function renderThumbStyle({ move, size, bar }, layout2) { const style2 = {} const translate2 = `translate${bar.axis}(${move}px)` style2[bar.size] = size style2.transform = translate2 style2.msTransform = translate2 style2.webkitTransform = translate2 if (layout2 === 'horizontal') { style2.height = '100%' } else { style2.width = '100%' } return style2 } const ScrollBar = defineComponent({ name: 'ElVirtualScrollBar', props: virtualizedScrollbarProps, emits: ['scroll', 'start-move', 'stop-move'], setup(props2, { emit: emit2 }) { const GAP = 4 const trackRef = ref() const thumbRef = ref() let frameHandle = null let onselectstartStore = null const state2 = reactive({ isDragging: false, traveled: 0, }) const bar = computed(() => BAR_MAP[props2.layout]) const trackSize = computed(() => props2.clientSize - GAP) const trackStyle = computed(() => ({ position: 'absolute', width: HORIZONTAL$1 === props2.layout ? `${trackSize.value}px` : '6px', height: HORIZONTAL$1 === props2.layout ? '6px' : `${trackSize.value}px`, [ScrollbarDirKey[props2.layout]]: '2px', right: '2px', bottom: '2px', borderRadius: '4px', })) const thumbSize = computed(() => { const ratio = props2.ratio const clientSize = props2.clientSize if (ratio >= 100) { return Number.POSITIVE_INFINITY } if (ratio >= 50) { return (ratio * clientSize) / 100 } const SCROLLBAR_MAX_SIZE = clientSize / 3 return Math.floor( Math.min( Math.max(ratio * clientSize, SCROLLBAR_MIN_SIZE), SCROLLBAR_MAX_SIZE ) ) }) const thumbStyle = computed(() => { if (!Number.isFinite(thumbSize.value)) { return { display: 'none', } } const thumb = `${thumbSize.value}px` const style2 = renderThumbStyle( { bar: bar.value, size: thumb, move: state2.traveled, }, props2.layout ) return style2 }) const totalSteps = computed(() => Math.floor(props2.clientSize - thumbSize.value - GAP) ) const attachEvents2 = () => { on$2(window, 'mousemove', onMouseMove) on$2(window, 'mouseup', onMouseUp) const thumbEl = unref(thumbRef) if (!thumbEl) return onselectstartStore = document.onselectstart document.onselectstart = () => false on$2(thumbEl, 'touchmove', onMouseMove) on$2(thumbEl, 'touchend', onMouseUp) } const detachEvents = () => { off$1(window, 'mousemove', onMouseMove) off$1(window, 'mouseup', onMouseUp) document.onselectstart = onselectstartStore onselectstartStore = null const thumbEl = unref(thumbRef) if (!thumbEl) return off$1(thumbEl, 'touchmove', onMouseMove) off$1(thumbEl, 'touchend', onMouseUp) } const onThumbMouseDown = (e2) => { e2.stopImmediatePropagation() if (e2.ctrlKey || [1, 2].includes(e2.button)) { return } state2.isDragging = true state2[bar.value.axis] = e2.currentTarget[bar.value.offset] - (e2[bar.value.client] - e2.currentTarget.getBoundingClientRect()[bar.value.direction]) emit2('start-move') attachEvents2() } const onMouseUp = () => { state2.isDragging = false state2[bar.value.axis] = 0 emit2('stop-move') detachEvents() } const onMouseMove = (e2) => { const { isDragging: isDragging2 } = state2 if (!isDragging2) return if (!thumbRef.value || !trackRef.value) return const prevPage2 = state2[bar.value.axis] if (!prevPage2) return cAF(frameHandle) const offset2 = (trackRef.value.getBoundingClientRect()[bar.value.direction] - e2[bar.value.client]) * -1 const thumbClickPosition = thumbRef.value[bar.value.offset] - prevPage2 const distance2 = offset2 - thumbClickPosition frameHandle = rAF(() => { state2.traveled = Math.max(0, Math.min(distance2, totalSteps.value)) emit2('scroll', distance2, totalSteps.value) }) } const clickTrackHandler = (e2) => { const offset2 = Math.abs( e2.target.getBoundingClientRect()[bar.value.direction] - e2[bar.value.client] ) const thumbHalf = thumbRef.value[bar.value.offset] / 2 const distance2 = offset2 - thumbHalf state2.traveled = Math.max(0, Math.min(distance2, totalSteps.value)) emit2('scroll', distance2, totalSteps.value) } const onScrollbarTouchStart = (e2) => e2.preventDefault() watch$1( () => props2.scrollFrom, (v4) => { if (state2.isDragging) return state2.traveled = Math.ceil(v4 * totalSteps.value) } ) onMounted(() => { if (!isClient$1) return on$2(trackRef.value, 'touchstart', onScrollbarTouchStart) on$2(thumbRef.value, 'touchstart', onThumbMouseDown) }) onBeforeUnmount(() => { off$1(trackRef.value, 'touchstart', onScrollbarTouchStart) detachEvents() }) return () => { return h$4( 'div', { role: 'presentation', ref: trackRef, class: 'el-virtual-scrollbar', style: trackStyle.value, onMousedown: withModifiers(clickTrackHandler, ['stop', 'prevent']), }, h$4( 'div', { ref: thumbRef, class: 'el-scrollbar__thumb', style: thumbStyle.value, onMousedown: onThumbMouseDown, }, [] ) ) } }, }) const createList$3 = ({ name: name2, getOffset: getOffset2, getItemSize, getItemOffset, getEstimatedTotalSize: getEstimatedTotalSize2, getStartIndexForOffset, getStopIndexForStartIndex, initCache, clearCache, validateProps, }) => { return defineComponent({ name: name2 != null ? name2 : 'ElVirtualList', props: virtualizedListProps, emits: [ITEM_RENDER_EVT, SCROLL_EVT], setup(props2, { emit: emit2, expose }) { validateProps(props2) const instance = getCurrentInstance() const dynamicSizeCache = ref(initCache(props2, instance)) const getItemStyleCache = useCache() const windowRef = ref() const innerRef = ref() const scrollbarRef = ref() const states = ref({ isScrolling: false, scrollDir: 'forward', scrollOffset: isNumber$h(props2.initScrollOffset) ? props2.initScrollOffset : 0, updateRequested: false, isScrollbarDragging: false, scrollbarAlwaysOn: props2.scrollbarAlwaysOn, }) const itemsToRender = computed(() => { const { total: total2, cache: cache2 } = props2 const { isScrolling, scrollDir, scrollOffset } = unref(states) if (total2 === 0) { return [0, 0, 0, 0] } const startIndex = getStartIndexForOffset( props2, scrollOffset, unref(dynamicSizeCache) ) const stopIndex = getStopIndexForStartIndex( props2, startIndex, scrollOffset, unref(dynamicSizeCache) ) const cacheBackward = !isScrolling || scrollDir === BACKWARD ? Math.max(1, cache2) : 1 const cacheForward = !isScrolling || scrollDir === FORWARD ? Math.max(1, cache2) : 1 return [ Math.max(0, startIndex - cacheBackward), Math.max(0, Math.min(total2 - 1, stopIndex + cacheForward)), startIndex, stopIndex, ] }) const estimatedTotalSize = computed(() => getEstimatedTotalSize2(props2, unref(dynamicSizeCache)) ) const _isHorizontal = computed(() => isHorizontal(props2.layout)) const windowStyle = computed(() => [ { position: 'relative', [`overflow-${_isHorizontal.value ? 'x' : 'y'}`]: 'scroll', WebkitOverflowScrolling: 'touch', willChange: 'transform', }, { direction: props2.direction, height: isNumber$h(props2.height) ? `${props2.height}px` : props2.height, width: isNumber$h(props2.width) ? `${props2.width}px` : props2.width, }, props2.style, ]) const innerStyle = computed(() => { const size = unref(estimatedTotalSize) const horizontal = unref(_isHorizontal) return { height: horizontal ? '100%' : `${size}px`, pointerEvents: unref(states).isScrolling ? 'none' : void 0, width: horizontal ? `${size}px` : '100%', } }) const clientSize = computed(() => _isHorizontal.value ? props2.width : props2.height ) const { onWheel } = useWheel( { atStartEdge: computed(() => states.value.scrollOffset <= 0), atEndEdge: computed( () => states.value.scrollOffset >= estimatedTotalSize.value ), layout: computed(() => props2.layout), }, (offset2) => { var _a2, _b2 ;(_b2 = (_a2 = scrollbarRef.value).onMouseUp) == null ? void 0 : _b2.call(_a2) scrollTo( Math.min( states.value.scrollOffset + offset2, estimatedTotalSize.value - clientSize.value ) ) } ) const emitEvents = () => { const { total: total2 } = props2 if (total2 > 0) { const [cacheStart, cacheEnd, visibleStart, visibleEnd] = unref(itemsToRender) emit2(ITEM_RENDER_EVT, cacheStart, cacheEnd, visibleStart, visibleEnd) } const { scrollDir, scrollOffset, updateRequested } = unref(states) emit2(SCROLL_EVT, scrollDir, scrollOffset, updateRequested) } const scrollVertically = (e2) => { const { clientHeight, scrollHeight, scrollTop } = e2.currentTarget const _states = unref(states) if (_states.scrollOffset === scrollTop) { return } const scrollOffset = Math.max( 0, Math.min(scrollTop, scrollHeight - clientHeight) ) states.value = { ..._states, isScrolling: true, scrollDir: getScrollDir(_states.scrollOffset, scrollOffset), scrollOffset, updateRequested: false, } nextTick(resetIsScrolling) } const scrollHorizontally = (e2) => { const { clientWidth, scrollLeft, scrollWidth } = e2.currentTarget const _states = unref(states) if (_states.scrollOffset === scrollLeft) { return } const { direction: direction2 } = props2 let scrollOffset = scrollLeft if (direction2 === RTL) { switch (getRTLOffsetType()) { case RTL_OFFSET_NAG: { scrollOffset = -scrollLeft break } case RTL_OFFSET_POS_DESC: { scrollOffset = scrollWidth - clientWidth - scrollLeft break } } } scrollOffset = Math.max( 0, Math.min(scrollOffset, scrollWidth - clientWidth) ) states.value = { ..._states, isScrolling: true, scrollDir: getScrollDir(_states.scrollOffset, scrollOffset), scrollOffset, updateRequested: false, } nextTick(resetIsScrolling) } const onScroll = (e2) => { unref(_isHorizontal) ? scrollHorizontally(e2) : scrollVertically(e2) emitEvents() } const onScrollbarScroll = (distanceToGo, totalSteps) => { const offset2 = ((estimatedTotalSize.value - clientSize.value) / totalSteps) * distanceToGo scrollTo(Math.min(estimatedTotalSize.value - clientSize.value, offset2)) } const scrollTo = (offset2) => { offset2 = Math.max(offset2, 0) if (offset2 === unref(states).scrollOffset) { return } states.value = { ...unref(states), scrollOffset: offset2, scrollDir: getScrollDir(unref(states).scrollOffset, offset2), updateRequested: true, } nextTick(resetIsScrolling) } const scrollToItem = (idx, alignment = AUTO_ALIGNMENT) => { const { scrollOffset } = unref(states) idx = Math.max(0, Math.min(idx, props2.total - 1)) scrollTo( getOffset2( props2, idx, alignment, scrollOffset, unref(dynamicSizeCache) ) ) } const getItemStyle2 = (idx) => { const { direction: direction2, itemSize: itemSize2, layout: layout2, } = props2 const itemStyleCache = getItemStyleCache.value( clearCache && itemSize2, clearCache && layout2, clearCache && direction2 ) let style2 if (hasOwn$e(itemStyleCache, String(idx))) { style2 = itemStyleCache[idx] } else { const offset2 = getItemOffset(props2, idx, unref(dynamicSizeCache)) const size = getItemSize(props2, idx, unref(dynamicSizeCache)) const horizontal = unref(_isHorizontal) const isRtl = direction2 === RTL const offsetHorizontal = horizontal ? offset2 : 0 itemStyleCache[idx] = style2 = { position: 'absolute', left: isRtl ? void 0 : `${offsetHorizontal}px`, right: isRtl ? `${offsetHorizontal}px` : void 0, top: !horizontal ? `${offset2}px` : 0, height: !horizontal ? `${size}px` : '100%', width: horizontal ? `${size}px` : '100%', } } return style2 } const resetIsScrolling = () => { states.value.isScrolling = false nextTick(() => { getItemStyleCache.value(-1, null, null) }) } const resetScrollTop = () => { const window2 = windowRef.value if (window2) { window2.scrollTop = 0 } } onMounted(() => { if (!isClient$1) return const { initScrollOffset: initScrollOffset2 } = props2 const windowElement = unref(windowRef) if (isNumber$h(initScrollOffset2) && windowElement) { if (unref(_isHorizontal)) { windowElement.scrollLeft = initScrollOffset2 } else { windowElement.scrollTop = initScrollOffset2 } } emitEvents() }) onUpdated(() => { const { direction: direction2, layout: layout2 } = props2 const { scrollOffset, updateRequested } = unref(states) const windowElement = unref(windowRef) if (updateRequested && windowElement) { if (layout2 === HORIZONTAL$1) { if (direction2 === RTL) { switch (getRTLOffsetType()) { case 'negative': { windowElement.scrollLeft = -scrollOffset break } case 'positive-ascending': { windowElement.scrollLeft = scrollOffset break } default: { const { clientWidth, scrollWidth } = windowElement windowElement.scrollLeft = scrollWidth - clientWidth - scrollOffset break } } } else { windowElement.scrollLeft = scrollOffset } } else { windowElement.scrollTop = scrollOffset } } }) const api = { clientSize, estimatedTotalSize, windowStyle, windowRef, innerRef, innerStyle, itemsToRender, scrollbarRef, states, getItemStyle: getItemStyle2, onScroll, onScrollbarScroll, onWheel, scrollTo, scrollToItem, resetScrollTop, } expose({ windowRef, innerRef, getItemStyleCache, scrollTo, scrollToItem, resetScrollTop, states, }) return api }, render(ctx) { var _a2 const { $slots, className, clientSize, containerElement, data: data2, getItemStyle: getItemStyle2, innerElement, itemsToRender, innerStyle, layout: layout2, total: total2, onScroll, onScrollbarScroll, onWheel, states, useIsScrolling, windowStyle, } = ctx const [start2, end2] = itemsToRender const Container2 = resolveDynamicComponent(containerElement) const Inner = resolveDynamicComponent(innerElement) const children = [] if (total2 > 0) { for (let i2 = start2; i2 <= end2; i2++) { children.push( (_a2 = $slots.default) == null ? void 0 : _a2.call($slots, { data: data2, key: i2, index: i2, isScrolling: useIsScrolling ? states.isScrolling : void 0, style: getItemStyle2(i2), }) ) } } const InnerNode = [ h$4( Inner, { style: innerStyle, ref: 'innerRef', }, !isString$f(Inner) ? { default: () => children, } : children ), ] const scrollbar = h$4(ScrollBar, { ref: 'scrollbarRef', clientSize, layout: layout2, onScroll: onScrollbarScroll, ratio: (clientSize * 100) / this.estimatedTotalSize, scrollFrom: states.scrollOffset / (this.estimatedTotalSize - clientSize), total: total2, }) const listContainer = h$4( Container2, { class: ['el-vl__window', className], style: windowStyle, onScroll, onWheel, ref: 'windowRef', key: 0, }, !isString$f(Container2) ? { default: () => [InnerNode] } : [InnerNode] ) return h$4( 'div', { key: 0, class: [ 'el-vl__wrapper', states.scrollbarAlwaysOn ? 'always-on' : '', ], }, [listContainer, scrollbar] ) }, }) } const FixedSizeList = createList$3({ name: 'ElFixedSizeList', getItemOffset: ({ itemSize: itemSize2 }, index2) => index2 * itemSize2, getItemSize: ({ itemSize: itemSize2 }) => itemSize2, getEstimatedTotalSize: ({ total: total2, itemSize: itemSize2 }) => itemSize2 * total2, getOffset: ( { height, total: total2, itemSize: itemSize2, layout: layout2, width }, index2, alignment, scrollOffset ) => { const size = isHorizontal(layout2) ? width : height const lastItemOffset = Math.max(0, total2 * itemSize2 - size) const maxOffset = Math.min(lastItemOffset, index2 * itemSize2) const minOffset = Math.max(0, (index2 + 1) * itemSize2 - size) if (alignment === SMART_ALIGNMENT) { if ( scrollOffset >= minOffset - size && scrollOffset <= maxOffset + size ) { alignment = AUTO_ALIGNMENT } else { alignment = CENTERED_ALIGNMENT } } switch (alignment) { case START_ALIGNMENT: { return maxOffset } case END_ALIGNMENT: { return minOffset } case CENTERED_ALIGNMENT: { const middleOffset = Math.round(minOffset + (maxOffset - minOffset) / 2) if (middleOffset < Math.ceil(size / 2)) { return 0 } else if (middleOffset > lastItemOffset + Math.floor(size / 2)) { return lastItemOffset } else { return middleOffset } } case AUTO_ALIGNMENT: default: { if (scrollOffset >= minOffset && scrollOffset <= maxOffset) { return scrollOffset } else if (scrollOffset < minOffset) { return minOffset } else { return maxOffset } } } }, getStartIndexForOffset: ({ total: total2, itemSize: itemSize2 }, offset2) => Math.max(0, Math.min(total2 - 1, Math.floor(offset2 / itemSize2))), getStopIndexForStartIndex: ( { height, total: total2, itemSize: itemSize2, layout: layout2, width }, startIndex, scrollOffset ) => { const offset2 = startIndex * itemSize2 const size = isHorizontal(layout2) ? width : height const numVisibleItems = Math.ceil( (size + scrollOffset - offset2) / itemSize2 ) return Math.max(0, Math.min(total2 - 1, startIndex + numVisibleItems - 1)) }, initCache() { return void 0 }, clearCache: true, validateProps() {}, }) const getItemFromCache$1 = (props2, index2, listCache) => { const { itemSize: itemSize2 } = props2 const { items, lastVisitedIndex } = listCache if (index2 > lastVisitedIndex) { let offset2 = 0 if (lastVisitedIndex >= 0) { const item2 = items[lastVisitedIndex] offset2 = item2.offset + item2.size } for (let i2 = lastVisitedIndex + 1; i2 <= index2; i2++) { const size = itemSize2(i2) items[i2] = { offset: offset2, size, } offset2 += size } listCache.lastVisitedIndex = index2 } return items[index2] } const findItem$1 = (props2, listCache, offset2) => { const { items, lastVisitedIndex } = listCache const lastVisitedOffset = lastVisitedIndex > 0 ? items[lastVisitedIndex].offset : 0 if (lastVisitedOffset >= offset2) { return bs$1(props2, listCache, 0, lastVisitedIndex, offset2) } return es$2(props2, listCache, Math.max(0, lastVisitedIndex), offset2) } const bs$1 = (props2, listCache, low, high, offset2) => { while (low <= high) { const mid = low + Math.floor((high - low) / 2) const currentOffset = getItemFromCache$1(props2, mid, listCache).offset if (currentOffset === offset2) { return mid } else if (currentOffset < offset2) { low = mid + 1 } else if (currentOffset > offset2) { high = mid - 1 } } return Math.max(0, low - 1) } const es$2 = (props2, listCache, index2, offset2) => { const { total: total2 } = props2 let exponent = 1 while ( index2 < total2 && getItemFromCache$1(props2, index2, listCache).offset < offset2 ) { index2 += exponent exponent *= 2 } return bs$1( props2, listCache, Math.floor(index2 / 2), Math.min(index2, total2 - 1), offset2 ) } const getEstimatedTotalSize = ( { total: total2 }, { items, estimatedItemSize: estimatedItemSize2, lastVisitedIndex } ) => { let totalSizeOfMeasuredItems = 0 if (lastVisitedIndex >= total2) { lastVisitedIndex = total2 - 1 } if (lastVisitedIndex >= 0) { const item2 = items[lastVisitedIndex] totalSizeOfMeasuredItems = item2.offset + item2.size } const numUnmeasuredItems = total2 - lastVisitedIndex - 1 const totalSizeOfUnmeasuredItems = numUnmeasuredItems * estimatedItemSize2 return totalSizeOfMeasuredItems + totalSizeOfUnmeasuredItems } const DynamicSizeList = createList$3({ name: 'ElDynamicSizeList', getItemOffset: (props2, index2, listCache) => getItemFromCache$1(props2, index2, listCache).offset, getItemSize: (_2, index2, { items }) => items[index2].size, getEstimatedTotalSize, getOffset: (props2, index2, alignment, scrollOffset, listCache) => { const { height, layout: layout2, width } = props2 const size = isHorizontal(layout2) ? width : height const item2 = getItemFromCache$1(props2, index2, listCache) const estimatedTotalSize = getEstimatedTotalSize(props2, listCache) const maxOffset = Math.max( 0, Math.min(estimatedTotalSize - size, item2.offset) ) const minOffset = Math.max(0, item2.offset - size + item2.size) if (alignment === SMART_ALIGNMENT) { if ( scrollOffset >= minOffset - size && scrollOffset <= maxOffset + size ) { alignment = AUTO_ALIGNMENT } else { alignment = CENTERED_ALIGNMENT } } switch (alignment) { case START_ALIGNMENT: { return maxOffset } case END_ALIGNMENT: { return minOffset } case CENTERED_ALIGNMENT: { return Math.round(minOffset + (maxOffset - minOffset) / 2) } case AUTO_ALIGNMENT: default: { if (scrollOffset >= minOffset && scrollOffset <= maxOffset) { return scrollOffset } else if (scrollOffset < minOffset) { return minOffset } else { return maxOffset } } } }, getStartIndexForOffset: (props2, offset2, listCache) => findItem$1(props2, listCache, offset2), getStopIndexForStartIndex: (props2, startIndex, scrollOffset, listCache) => { const { height, total: total2, layout: layout2, width } = props2 const size = isHorizontal(layout2) ? width : height const item2 = getItemFromCache$1(props2, startIndex, listCache) const maxOffset = scrollOffset + size let offset2 = item2.offset + item2.size let stopIndex = startIndex while (stopIndex < total2 - 1 && offset2 < maxOffset) { stopIndex++ offset2 += getItemFromCache$1(props2, stopIndex, listCache).size } return stopIndex }, initCache( { estimatedItemSize: estimatedItemSize2 = DEFAULT_DYNAMIC_LIST_ITEM_SIZE }, instance ) { const cache2 = { items: {}, estimatedItemSize: estimatedItemSize2, lastVisitedIndex: -1, } cache2.clearCacheAfterIndex = (index2, forceUpdate = true) => { var _a2, _b2 cache2.lastVisitedIndex = Math.min(cache2.lastVisitedIndex, index2 - 1) ;(_a2 = instance.exposed) == null ? void 0 : _a2.getItemStyleCache(-1) if (forceUpdate) { ;(_b2 = instance.proxy) == null ? void 0 : _b2.$forceUpdate() } } return cache2 }, clearCache: false, validateProps: ({ itemSize: itemSize2 }) => {}, }) const useGridWheel = ( { atXEndEdge, atXStartEdge, atYEndEdge, atYStartEdge }, onWheelDelta ) => { let frameHandle = null let xOffset = 0 let yOffset = 0 const hasReachedEdge = (x2, y2) => { const xEdgeReached = (x2 < 0 && atXStartEdge.value) || (x2 > 0 && atXEndEdge.value) const yEdgeReached = (y2 < 0 && atYStartEdge.value) || (y2 > 0 && atYEndEdge.value) return xEdgeReached && yEdgeReached } const onWheel = (e2) => { cAF(frameHandle) const x2 = e2.deltaX const y2 = e2.deltaY if ( hasReachedEdge(xOffset, yOffset) && hasReachedEdge(xOffset + x2, yOffset + y2) ) return xOffset += x2 yOffset += y2 if (!isFirefox()) { e2.preventDefault() } frameHandle = rAF(() => { onWheelDelta(xOffset, yOffset) xOffset = 0 yOffset = 0 }) } return { hasReachedEdge, onWheel, } } const createGrid = ({ name: name2, clearCache, getColumnPosition, getColumnStartIndexForOffset, getColumnStopIndexForStartIndex, getEstimatedTotalHeight: getEstimatedTotalHeight2, getEstimatedTotalWidth: getEstimatedTotalWidth2, getColumnOffset, getRowOffset, getRowPosition, getRowStartIndexForOffset, getRowStopIndexForStartIndex, initCache, validateProps, }) => { return defineComponent({ name: name2 != null ? name2 : 'ElVirtualList', props: virtualizedGridProps, emits: [ITEM_RENDER_EVT, SCROLL_EVT], setup(props2, { emit: emit2, expose, slots }) { validateProps(props2) const instance = getCurrentInstance() const cache2 = ref(initCache(props2, instance)) const windowRef = ref() const hScrollbar = ref() const vScrollbar = ref() const innerRef = ref(null) const states = ref({ isScrolling: false, scrollLeft: isNumber$h(props2.initScrollLeft) ? props2.initScrollLeft : 0, scrollTop: isNumber$h(props2.initScrollTop) ? props2.initScrollTop : 0, updateRequested: false, xAxisScrollDir: FORWARD, yAxisScrollDir: FORWARD, }) const getItemStyleCache = useCache() const parsedHeight = computed(() => Number.parseInt(`${props2.height}`, 10) ) const parsedWidth = computed(() => Number.parseInt(`${props2.width}`, 10)) const columnsToRender = computed(() => { const { totalColumn, totalRow, columnCache } = props2 const { isScrolling, xAxisScrollDir, scrollLeft } = unref(states) if (totalColumn === 0 || totalRow === 0) { return [0, 0, 0, 0] } const startIndex = getColumnStartIndexForOffset( props2, scrollLeft, unref(cache2) ) const stopIndex = getColumnStopIndexForStartIndex( props2, startIndex, scrollLeft, unref(cache2) ) const cacheBackward = !isScrolling || xAxisScrollDir === BACKWARD ? Math.max(1, columnCache) : 1 const cacheForward = !isScrolling || xAxisScrollDir === FORWARD ? Math.max(1, columnCache) : 1 return [ Math.max(0, startIndex - cacheBackward), Math.max(0, Math.min(totalColumn - 1, stopIndex + cacheForward)), startIndex, stopIndex, ] }) const rowsToRender = computed(() => { const { totalColumn, totalRow, rowCache } = props2 const { isScrolling, yAxisScrollDir, scrollTop } = unref(states) if (totalColumn === 0 || totalRow === 0) { return [0, 0, 0, 0] } const startIndex = getRowStartIndexForOffset( props2, scrollTop, unref(cache2) ) const stopIndex = getRowStopIndexForStartIndex( props2, startIndex, scrollTop, unref(cache2) ) const cacheBackward = !isScrolling || yAxisScrollDir === BACKWARD ? Math.max(1, rowCache) : 1 const cacheForward = !isScrolling || yAxisScrollDir === FORWARD ? Math.max(1, rowCache) : 1 return [ Math.max(0, startIndex - cacheBackward), Math.max(0, Math.min(totalRow - 1, stopIndex + cacheForward)), startIndex, stopIndex, ] }) const estimatedTotalHeight = computed(() => getEstimatedTotalHeight2(props2, unref(cache2)) ) const estimatedTotalWidth = computed(() => getEstimatedTotalWidth2(props2, unref(cache2)) ) const windowStyle = computed(() => { var _a2 return [ { position: 'relative', overflow: 'hidden', WebkitOverflowScrolling: 'touch', willChange: 'transform', }, { direction: props2.direction, height: isNumber$h(props2.height) ? `${props2.height}px` : props2.height, width: isNumber$h(props2.width) ? `${props2.width}px` : props2.width, }, (_a2 = props2.style) != null ? _a2 : {}, ] }) const innerStyle = computed(() => { const width = `${unref(estimatedTotalWidth)}px` const height = `${unref(estimatedTotalHeight)}px` return { height, pointerEvents: unref(states).isScrolling ? 'none' : void 0, width, } }) const emitEvents = () => { const { totalColumn, totalRow } = props2 if (totalColumn > 0 && totalRow > 0) { const [ columnCacheStart, columnCacheEnd, columnVisibleStart, columnVisibleEnd, ] = unref(columnsToRender) const [rowCacheStart, rowCacheEnd, rowVisibleStart, rowVisibleEnd] = unref(rowsToRender) emit2( ITEM_RENDER_EVT, columnCacheStart, columnCacheEnd, rowCacheStart, rowCacheEnd, columnVisibleStart, columnVisibleEnd, rowVisibleStart, rowVisibleEnd ) } const { scrollLeft, scrollTop, updateRequested, xAxisScrollDir, yAxisScrollDir, } = unref(states) emit2( SCROLL_EVT, xAxisScrollDir, scrollLeft, yAxisScrollDir, scrollTop, updateRequested ) } const onScroll = (e2) => { const { clientHeight, clientWidth, scrollHeight, scrollLeft, scrollTop, scrollWidth, } = e2.currentTarget const _states = unref(states) if ( _states.scrollTop === scrollTop && _states.scrollLeft === scrollLeft ) { return } let _scrollLeft = scrollLeft if (isRTL(props2.direction)) { switch (getRTLOffsetType()) { case RTL_OFFSET_NAG: _scrollLeft = -scrollLeft break case RTL_OFFSET_POS_DESC: _scrollLeft = scrollWidth - clientWidth - scrollLeft break } } states.value = { ..._states, isScrolling: true, scrollLeft: _scrollLeft, scrollTop: Math.max( 0, Math.min(scrollTop, scrollHeight - clientHeight) ), updateRequested: false, xAxisScrollDir: getScrollDir(_states.scrollLeft, _scrollLeft), yAxisScrollDir: getScrollDir(_states.scrollTop, scrollTop), } nextTick(resetIsScrolling) emitEvents() } const onVerticalScroll = (distance2, totalSteps) => { const height = unref(parsedHeight) const offset2 = ((estimatedTotalHeight.value - height) / totalSteps) * distance2 scrollTo({ scrollTop: Math.min(estimatedTotalHeight.value - height, offset2), }) } const onHorizontalScroll = (distance2, totalSteps) => { const width = unref(parsedWidth) const offset2 = ((estimatedTotalWidth.value - width) / totalSteps) * distance2 scrollTo({ scrollLeft: Math.min(estimatedTotalWidth.value - width, offset2), }) } const { onWheel } = useGridWheel( { atXStartEdge: computed(() => states.value.scrollLeft <= 0), atXEndEdge: computed( () => states.value.scrollLeft >= estimatedTotalWidth.value ), atYStartEdge: computed(() => states.value.scrollTop <= 0), atYEndEdge: computed( () => states.value.scrollTop >= estimatedTotalHeight.value ), }, (x2, y2) => { var _a2, _b2, _c2, _d ;(_b2 = (_a2 = hScrollbar.value) == null ? void 0 : _a2.onMouseUp) == null ? void 0 : _b2.call(_a2) ;(_d = (_c2 = hScrollbar.value) == null ? void 0 : _c2.onMouseUp) == null ? void 0 : _d.call(_c2) const width = unref(parsedWidth) const height = unref(parsedHeight) scrollTo({ scrollLeft: Math.min( states.value.scrollLeft + x2, estimatedTotalWidth.value - width ), scrollTop: Math.min( states.value.scrollTop + y2, estimatedTotalHeight.value - height ), }) } ) const scrollTo = ({ scrollLeft = states.value.scrollLeft, scrollTop = states.value.scrollTop, }) => { scrollLeft = Math.max(scrollLeft, 0) scrollTop = Math.max(scrollTop, 0) const _states = unref(states) if ( scrollTop === _states.scrollTop && scrollLeft === _states.scrollLeft ) { return } states.value = { ..._states, xAxisScrollDir: getScrollDir(_states.scrollLeft, scrollLeft), yAxisScrollDir: getScrollDir(_states.scrollTop, scrollTop), scrollLeft, scrollTop, updateRequested: true, } nextTick(resetIsScrolling) } const scrollToItem = ( rowIndex = 0, columnIdx = 0, alignment = AUTO_ALIGNMENT ) => { const _states = unref(states) columnIdx = Math.max(0, Math.min(columnIdx, props2.totalColumn - 1)) rowIndex = Math.max(0, Math.min(rowIndex, props2.totalRow - 1)) const scrollBarWidth2 = getScrollBarWidth() const _cache = unref(cache2) const estimatedHeight = getEstimatedTotalHeight2(props2, _cache) const estimatedWidth = getEstimatedTotalWidth2(props2, _cache) scrollTo({ scrollLeft: getColumnOffset( props2, columnIdx, alignment, _states.scrollLeft, _cache, estimatedWidth > props2.width ? scrollBarWidth2 : 0 ), scrollTop: getRowOffset( props2, rowIndex, alignment, _states.scrollTop, _cache, estimatedHeight > props2.height ? scrollBarWidth2 : 0 ), }) } const getItemStyle2 = (rowIndex, columnIndex) => { const { columnWidth, direction: direction2, rowHeight } = props2 const itemStyleCache = getItemStyleCache.value( clearCache && columnWidth, clearCache && rowHeight, clearCache && direction2 ) const key2 = `${rowIndex},${columnIndex}` if (hasOwn$e(itemStyleCache, key2)) { return itemStyleCache[key2] } else { const [, left2] = getColumnPosition( props2, columnIndex, unref(cache2) ) const _cache = unref(cache2) const rtl = isRTL(direction2) const [height, top2] = getRowPosition(props2, rowIndex, _cache) const [width] = getColumnPosition(props2, columnIndex, _cache) itemStyleCache[key2] = { position: 'absolute', left: rtl ? void 0 : `${left2}px`, right: rtl ? `${left2}px` : void 0, top: `${top2}px`, height: `${height}px`, width: `${width}px`, } return itemStyleCache[key2] } } const resetIsScrolling = () => { states.value.isScrolling = false nextTick(() => { getItemStyleCache.value(-1, null, null) }) } onMounted(() => { if (!isClient$1) return const { initScrollLeft, initScrollTop } = props2 const windowElement = unref(windowRef) if (windowElement) { if (isNumber$h(initScrollLeft)) { windowElement.scrollLeft = initScrollLeft } if (isNumber$h(initScrollTop)) { windowElement.scrollTop = initScrollTop } } emitEvents() }) onUpdated(() => { const { direction: direction2 } = props2 const { scrollLeft, scrollTop, updateRequested } = unref(states) const windowElement = unref(windowRef) if (updateRequested && windowElement) { if (direction2 === RTL) { switch (getRTLOffsetType()) { case RTL_OFFSET_NAG: { windowElement.scrollLeft = -scrollLeft break } case RTL_OFFSET_POS_ASC: { windowElement.scrollLeft = scrollLeft break } default: { const { clientWidth, scrollWidth } = windowElement windowElement.scrollLeft = scrollWidth - clientWidth - scrollLeft break } } } else { windowElement.scrollLeft = Math.max(0, scrollLeft) } windowElement.scrollTop = Math.max(0, scrollTop) } }) expose({ windowRef, innerRef, getItemStyleCache, scrollTo, scrollToItem, states, }) const renderScrollbars = () => { const { totalColumn, totalRow } = props2 const width = unref(parsedWidth) const height = unref(parsedHeight) const estimatedWidth = unref(estimatedTotalWidth) const estimatedHeight = unref(estimatedTotalHeight) const { scrollLeft, scrollTop } = unref(states) const horizontalScrollbar = h$4(ScrollBar, { ref: hScrollbar, clientSize: width, layout: 'horizontal', onScroll: onHorizontalScroll, ratio: (width * 100) / estimatedWidth, scrollFrom: scrollLeft / (estimatedWidth - width), total: totalRow, visible: true, }) const verticalScrollbar = h$4(ScrollBar, { ref: vScrollbar, clientSize: height, layout: 'vertical', onScroll: onVerticalScroll, ratio: (height * 100) / estimatedHeight, scrollFrom: scrollTop / (estimatedHeight - height), total: totalColumn, visible: true, }) return { horizontalScrollbar, verticalScrollbar, } } const renderItems = () => { var _a2 const [columnStart, columnEnd] = unref(columnsToRender) const [rowStart, rowEnd] = unref(rowsToRender) const { data: data2, totalColumn, totalRow, useIsScrolling } = props2 const children = [] if (totalRow > 0 && totalColumn > 0) { for (let row = rowStart; row <= rowEnd; row++) { for (let column = columnStart; column <= columnEnd; column++) { children.push( (_a2 = slots.default) == null ? void 0 : _a2.call(slots, { columnIndex: column, data: data2, key: column, isScrolling: useIsScrolling ? unref(states).isScrolling : void 0, style: getItemStyle2(row, column), rowIndex: row, }) ) } } } return children } const renderInner = () => { const Inner = resolveDynamicComponent(props2.innerElement) const children = renderItems() return [ h$4( Inner, { style: unref(innerStyle), ref: innerRef, }, !isString$f(Inner) ? { default: () => children, } : children ), ] } const renderWindow = () => { const Container2 = resolveDynamicComponent(props2.containerElement) const { horizontalScrollbar, verticalScrollbar } = renderScrollbars() const Inner = renderInner() return h$4( 'div', { key: 0, class: 'el-vg__wrapper', }, [ h$4( Container2, { class: props2.className, style: unref(windowStyle), onScroll, onWheel, ref: windowRef, }, !isString$f(Container2) ? { default: () => Inner } : Inner ), horizontalScrollbar, verticalScrollbar, ] ) } return renderWindow }, }) } const FixedSizeGrid$1 = createGrid({ name: 'ElFixedSizeGrid', getColumnPosition: ({ columnWidth }, index2) => [ columnWidth, index2 * columnWidth, ], getRowPosition: ({ rowHeight }, index2) => [rowHeight, index2 * rowHeight], getEstimatedTotalHeight: ({ totalRow, rowHeight }) => rowHeight * totalRow, getEstimatedTotalWidth: ({ totalColumn, columnWidth }) => columnWidth * totalColumn, getColumnOffset: ( { totalColumn, columnWidth, width }, columnIndex, alignment, scrollLeft, _2, scrollBarWidth2 ) => { width = Number(width) const lastColumnOffset = Math.max(0, totalColumn * columnWidth - width) const maxOffset = Math.min(lastColumnOffset, columnIndex * columnWidth) const minOffset = Math.max( 0, columnIndex * columnWidth - width + scrollBarWidth2 + columnWidth ) if (alignment === 'smart') { if (scrollLeft >= minOffset - width && scrollLeft <= maxOffset + width) { alignment = AUTO_ALIGNMENT } else { alignment = CENTERED_ALIGNMENT } } switch (alignment) { case START_ALIGNMENT: return maxOffset case END_ALIGNMENT: return minOffset case CENTERED_ALIGNMENT: { const middleOffset = Math.round(minOffset + (maxOffset - minOffset) / 2) if (middleOffset < Math.ceil(width / 2)) { return 0 } else if (middleOffset > lastColumnOffset + Math.floor(width / 2)) { return lastColumnOffset } else { return middleOffset } } case AUTO_ALIGNMENT: default: if (scrollLeft >= minOffset && scrollLeft <= maxOffset) { return scrollLeft } else if (minOffset > maxOffset) { return minOffset } else if (scrollLeft < minOffset) { return minOffset } else { return maxOffset } } }, getRowOffset: ( { rowHeight, height, totalRow }, rowIndex, align, scrollTop, _2, scrollBarWidth2 ) => { height = Number(height) const lastRowOffset = Math.max(0, totalRow * rowHeight - height) const maxOffset = Math.min(lastRowOffset, rowIndex * rowHeight) const minOffset = Math.max( 0, rowIndex * rowHeight - height + scrollBarWidth2 + rowHeight ) if (align === SMART_ALIGNMENT) { if (scrollTop >= minOffset - height && scrollTop <= maxOffset + height) { align = AUTO_ALIGNMENT } else { align = CENTERED_ALIGNMENT } } switch (align) { case START_ALIGNMENT: return maxOffset case END_ALIGNMENT: return minOffset case CENTERED_ALIGNMENT: { const middleOffset = Math.round(minOffset + (maxOffset - minOffset) / 2) if (middleOffset < Math.ceil(height / 2)) { return 0 } else if (middleOffset > lastRowOffset + Math.floor(height / 2)) { return lastRowOffset } else { return middleOffset } } case AUTO_ALIGNMENT: default: if (scrollTop >= minOffset && scrollTop <= maxOffset) { return scrollTop } else if (minOffset > maxOffset) { return minOffset } else if (scrollTop < minOffset) { return minOffset } else { return maxOffset } } }, getColumnStartIndexForOffset: ({ columnWidth, totalColumn }, scrollLeft) => Math.max( 0, Math.min(totalColumn - 1, Math.floor(scrollLeft / columnWidth)) ), getColumnStopIndexForStartIndex: ( { columnWidth, totalColumn, width }, startIndex, scrollLeft ) => { const left2 = startIndex * columnWidth const visibleColumnsCount = Math.ceil( (width + scrollLeft - left2) / columnWidth ) return Math.max( 0, Math.min(totalColumn - 1, startIndex + visibleColumnsCount - 1) ) }, getRowStartIndexForOffset: ({ rowHeight, totalRow }, scrollTop) => Math.max(0, Math.min(totalRow - 1, Math.floor(scrollTop / rowHeight))), getRowStopIndexForStartIndex: ( { rowHeight, totalRow, height }, startIndex, scrollTop ) => { const top2 = startIndex * rowHeight const numVisibleRows = Math.ceil((height + scrollTop - top2) / rowHeight) return Math.max(0, Math.min(totalRow - 1, startIndex + numVisibleRows - 1)) }, initCache: () => void 0, clearCache: true, validateProps: ({ columnWidth, rowHeight }) => {}, }) const { max: max$a, min: min$a, floor: floor$5 } = Math const ACCESS_SIZER_KEY_MAP = { column: 'columnWidth', row: 'rowHeight', } const ACCESS_LAST_VISITED_KEY_MAP = { column: 'lastVisitedColumnIndex', row: 'lastVisitedRowIndex', } const getItemFromCache = (props2, index2, gridCache, type4) => { const [cachedItems, sizer, lastVisited] = [ gridCache[type4], props2[ACCESS_SIZER_KEY_MAP[type4]], gridCache[ACCESS_LAST_VISITED_KEY_MAP[type4]], ] if (index2 > lastVisited) { let offset2 = 0 if (lastVisited >= 0) { const item2 = cachedItems[lastVisited] offset2 = item2.offset + item2.size } for (let i2 = lastVisited + 1; i2 <= index2; i2++) { const size = sizer(i2) cachedItems[i2] = { offset: offset2, size, } offset2 += size } gridCache[ACCESS_LAST_VISITED_KEY_MAP[type4]] = index2 } return cachedItems[index2] } const bs = (props2, gridCache, low, high, offset2, type4) => { while (low <= high) { const mid = low + floor$5((high - low) / 2) const currentOffset = getItemFromCache(props2, mid, gridCache, type4).offset if (currentOffset === offset2) { return mid } else if (currentOffset < offset2) { low = mid + 1 } else { high = mid - 1 } } return max$a(0, low - 1) } const es$1 = (props2, gridCache, idx, offset2, type4) => { const total2 = type4 === 'column' ? props2.totalColumn : props2.totalRow let exponent = 1 while ( idx < total2 && getItemFromCache(props2, idx, gridCache, type4).offset < offset2 ) { idx += exponent exponent *= 2 } return bs( props2, gridCache, floor$5(idx / 2), min$a(idx, total2 - 1), offset2, type4 ) } const findItem = (props2, gridCache, offset2, type4) => { const [cache2, lastVisitedIndex] = [ gridCache[type4], gridCache[ACCESS_LAST_VISITED_KEY_MAP[type4]], ] const lastVisitedItemOffset = lastVisitedIndex > 0 ? cache2[lastVisitedIndex].offset : 0 if (lastVisitedItemOffset >= offset2) { return bs(props2, gridCache, 0, lastVisitedIndex, offset2, type4) } return es$1(props2, gridCache, max$a(0, lastVisitedIndex), offset2, type4) } const getEstimatedTotalHeight = ( { totalRow }, { estimatedRowHeight, lastVisitedRowIndex, row } ) => { let sizeOfVisitedRows = 0 if (lastVisitedRowIndex >= totalRow) { lastVisitedRowIndex = totalRow - 1 } if (lastVisitedRowIndex >= 0) { const item2 = row[lastVisitedRowIndex] sizeOfVisitedRows = item2.offset + item2.size } const unvisitedItems = totalRow - lastVisitedRowIndex - 1 const sizeOfUnvisitedItems = unvisitedItems * estimatedRowHeight return sizeOfVisitedRows + sizeOfUnvisitedItems } const getEstimatedTotalWidth = ( { totalColumn }, { column, estimatedColumnWidth, lastVisitedColumnIndex } ) => { let sizeOfVisitedColumns = 0 if (lastVisitedColumnIndex > totalColumn) { lastVisitedColumnIndex = totalColumn - 1 } if (lastVisitedColumnIndex >= 0) { const item2 = column[lastVisitedColumnIndex] sizeOfVisitedColumns = item2.offset + item2.size } const unvisitedItems = totalColumn - lastVisitedColumnIndex - 1 const sizeOfUnvisitedItems = unvisitedItems * estimatedColumnWidth return sizeOfVisitedColumns + sizeOfUnvisitedItems } const ACCESS_ESTIMATED_SIZE_KEY_MAP = { column: getEstimatedTotalWidth, row: getEstimatedTotalHeight, } const getOffset$1 = ( props2, index2, alignment, scrollOffset, cache2, type4, scrollBarWidth2 ) => { const [size, estimatedSizeAssociates] = [ type4 === 'row' ? props2.height : props2.width, ACCESS_ESTIMATED_SIZE_KEY_MAP[type4], ] const item2 = getItemFromCache(props2, index2, cache2, type4) const estimatedSize = estimatedSizeAssociates(props2, cache2) const maxOffset = max$a(0, min$a(estimatedSize - size, item2.offset)) const minOffset = max$a(0, item2.offset - size + scrollBarWidth2 + item2.size) if (alignment === SMART_ALIGNMENT) { if (scrollOffset >= minOffset - size && scrollOffset <= maxOffset + size) { alignment = AUTO_ALIGNMENT } else { alignment = CENTERED_ALIGNMENT } } switch (alignment) { case START_ALIGNMENT: { return maxOffset } case END_ALIGNMENT: { return minOffset } case CENTERED_ALIGNMENT: { return Math.round(minOffset + (maxOffset - minOffset) / 2) } case AUTO_ALIGNMENT: default: { if (scrollOffset >= minOffset && scrollOffset <= maxOffset) { return scrollOffset } else if (minOffset > maxOffset) { return minOffset } else if (scrollOffset < minOffset) { return minOffset } else { return maxOffset } } } } const FixedSizeGrid = createGrid({ name: 'ElDynamicSizeGrid', getColumnPosition: (props2, idx, cache2) => { const item2 = getItemFromCache(props2, idx, cache2, 'column') return [item2.size, item2.offset] }, getRowPosition: (props2, idx, cache2) => { const item2 = getItemFromCache(props2, idx, cache2, 'row') return [item2.size, item2.offset] }, getColumnOffset: ( props2, columnIndex, alignment, scrollLeft, cache2, scrollBarWidth2 ) => getOffset$1( props2, columnIndex, alignment, scrollLeft, cache2, 'column', scrollBarWidth2 ), getRowOffset: ( props2, rowIndex, alignment, scrollTop, cache2, scrollBarWidth2 ) => getOffset$1( props2, rowIndex, alignment, scrollTop, cache2, 'row', scrollBarWidth2 ), getColumnStartIndexForOffset: (props2, scrollLeft, cache2) => findItem(props2, cache2, scrollLeft, 'column'), getColumnStopIndexForStartIndex: (props2, startIndex, scrollLeft, cache2) => { const item2 = getItemFromCache(props2, startIndex, cache2, 'column') const maxOffset = scrollLeft + props2.width let offset2 = item2.offset + item2.size let stopIndex = startIndex while (stopIndex < props2.totalColumn - 1 && offset2 < maxOffset) { stopIndex++ offset2 += getItemFromCache(props2, startIndex, cache2, 'column').size } return stopIndex }, getEstimatedTotalHeight, getEstimatedTotalWidth, getRowStartIndexForOffset: (props2, scrollTop, cache2) => findItem(props2, cache2, scrollTop, 'row'), getRowStopIndexForStartIndex: (props2, startIndex, scrollTop, cache2) => { const { totalRow, height } = props2 const item2 = getItemFromCache(props2, startIndex, cache2, 'row') const maxOffset = scrollTop + height let offset2 = item2.size + item2.offset let stopIndex = startIndex while (stopIndex < totalRow - 1 && offset2 < maxOffset) { stopIndex++ offset2 += getItemFromCache(props2, stopIndex, cache2, 'row').size } return stopIndex }, initCache: ({ estimatedColumnWidth = DEFAULT_DYNAMIC_LIST_ITEM_SIZE, estimatedRowHeight = DEFAULT_DYNAMIC_LIST_ITEM_SIZE, }) => { const cache2 = { column: {}, estimatedColumnWidth, estimatedRowHeight, lastVisitedColumnIndex: -1, lastVisitedRowIndex: -1, row: {}, } return cache2 }, clearCache: true, validateProps: ({ columnWidth, rowHeight }) => {}, }) const _sfc_main$7I = defineComponent({ props: { item: { type: Object, required: true, }, style: Object, height: Number, }, setup() { const ns = useNamespace('select') return { ns, } }, }) function _sfc_render$E(_ctx, _cache, $props2, $setup, $data, $options) { return _ctx.item.isTitle ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass(_ctx.ns.be('group', 'title')), style: normalizeStyle$1([ _ctx.style, { lineHeight: `${_ctx.height}px` }, ]), }, toDisplayString$1(_ctx.item.label), 7 )) : (openBlock(), createElementBlock( 'div', { key: 1, class: normalizeClass(_ctx.ns.be('group', 'split')), style: normalizeStyle$1(_ctx.style), }, [ createElementVNode( 'span', { class: normalizeClass(_ctx.ns.be('group', 'split-dash')), style: normalizeStyle$1({ top: `${_ctx.height / 2}px` }), }, null, 6 ), ], 6 )) } var GroupItem = /* @__PURE__ */ _export_sfc$1(_sfc_main$7I, [ ['render', _sfc_render$E], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/select-v2/src/group-item.vue', ], ]) function useOption(props2, { emit: emit2 }) { return { hoverItem: () => { if (!props2.disabled) { emit2('hover', props2.index) } }, selectOptionClick: () => { if (!props2.disabled) { emit2('select', props2.item, props2.index) } }, } } const SelectProps = { allowCreate: Boolean, autocomplete: { type: String, default: 'none', }, automaticDropdown: Boolean, clearable: Boolean, clearIcon: { type: [String, Object], default: circleClose, }, effect: { type: String, default: 'light', }, collapseTags: Boolean, collapseTagsTooltip: { type: Boolean, default: false, }, defaultFirstOption: Boolean, disabled: Boolean, estimatedOptionHeight: { type: Number, default: void 0, }, filterable: Boolean, filterMethod: Function, height: { type: Number, default: 170, }, itemHeight: { type: Number, default: 34, }, id: String, loading: Boolean, loadingText: String, label: String, modelValue: [Array, String, Number, Boolean, Object], multiple: Boolean, multipleLimit: { type: Number, default: 0, }, name: String, noDataText: String, noMatchText: String, remoteMethod: Function, reserveKeyword: { type: Boolean, default: true, }, options: { type: Array, required: true, }, placeholder: { type: String, }, popperAppendToBody: { type: Boolean, default: void 0, }, teleported: useTooltipContentProps.teleported, persistent: { type: Boolean, default: true, }, popperClass: { type: String, default: '', }, popperOptions: { type: Object, default: () => ({}), }, remote: Boolean, size: { type: String, validator: isValidComponentSize, }, valueKey: { type: String, default: 'value', }, scrollbarAlwaysOn: { type: Boolean, default: false, }, } const OptionProps = { data: Array, disabled: Boolean, hovering: Boolean, item: Object, index: Number, style: Object, selected: Boolean, created: Boolean, } const _sfc_main$7H = defineComponent({ props: OptionProps, emits: ['select', 'hover'], setup(props2, { emit: emit2 }) { const ns = useNamespace('select') const { hoverItem, selectOptionClick } = useOption(props2, { emit: emit2 }) return { ns, hoverItem, selectOptionClick, } }, }) const _hoisted_1$6g = ['aria-selected'] function _sfc_render$D(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock( 'li', { 'aria-selected': _ctx.selected, style: normalizeStyle$1(_ctx.style), class: normalizeClass([ _ctx.ns.be('dropdown', 'option-item'), _ctx.ns.is('selected', _ctx.selected), _ctx.ns.is('disabled', _ctx.disabled), _ctx.ns.is('created', _ctx.created), { hover: _ctx.hovering }, ]), onMouseenter: _cache[0] || (_cache[0] = (...args) => _ctx.hoverItem && _ctx.hoverItem(...args)), onClick: _cache[1] || (_cache[1] = withModifiers( (...args) => _ctx.selectOptionClick && _ctx.selectOptionClick(...args), ['stop'] )), }, [ renderSlot( _ctx.$slots, 'default', { item: _ctx.item, index: _ctx.index, disabled: _ctx.disabled, }, () => [ createElementVNode( 'span', null, toDisplayString$1(_ctx.item.label), 1 ), ] ), ], 46, _hoisted_1$6g ) ) } var OptionItem = /* @__PURE__ */ _export_sfc$1(_sfc_main$7H, [ ['render', _sfc_render$D], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/select-v2/src/option-item.vue', ], ]) const selectV2InjectionKey = 'ElSelectV2Injection' const _sfc_main$7G = defineComponent({ name: 'ElSelectDropdown', props: { data: Array, hoveringIndex: Number, width: Number, }, setup(props2) { const select2 = inject(selectV2InjectionKey) const ns = useNamespace('select') const cachedHeights = ref([]) const listRef = ref(null) const isSized = computed(() => isUndefined$c(select2.props.estimatedOptionHeight) ) const listProps = computed(() => { if (isSized.value) { return { itemSize: select2.props.itemHeight, } } return { estimatedSize: select2.props.estimatedOptionHeight, itemSize: (idx) => cachedHeights.value[idx], } }) const contains2 = (arr = [], target2) => { const { props: { valueKey }, } = select2 if (!isObject$v(target2)) { return arr.includes(target2) } return ( arr && arr.some((item2) => { return get$a(item2, valueKey) === get$a(target2, valueKey) }) ) } const isEqual2 = (selected, target2) => { if (!isObject$v(target2)) { return selected === target2 } else { const { valueKey } = select2.props return get$a(selected, valueKey) === get$a(target2, valueKey) } } const isItemSelected = (modelValue, target2) => { const { valueKey } = select2.props if (select2.props.multiple) { return contains2(modelValue, get$a(target2, valueKey)) } return isEqual2(modelValue, get$a(target2, valueKey)) } const isItemDisabled = (modelValue, selected) => { const { disabled, multiple, multipleLimit } = select2.props return ( disabled || (!selected && (multiple ? multipleLimit > 0 && modelValue.length >= multipleLimit : false)) ) } const isItemHovering = (target2) => props2.hoveringIndex === target2 const scrollToItem = (index2) => { const list2 = listRef.value if (list2) { list2.scrollToItem(index2) } } const resetScrollTop = () => { const list2 = listRef.value if (list2) { list2.resetScrollTop() } } return { ns, select: select2, listProps, listRef, isSized, isItemDisabled, isItemHovering, isItemSelected, scrollToItem, resetScrollTop, } }, render(_ctx, _cache) { var _a2 const { $slots, data: data2, listProps, select: select2, isSized, width, ns, isItemDisabled, isItemHovering, isItemSelected, } = _ctx const Comp = isSized ? FixedSizeList : DynamicSizeList const { props: selectProps, onSelect, onHover, onKeyboardNavigate, onKeyboardSelect, } = select2 const { height, modelValue, multiple } = selectProps if (data2.length === 0) { return h$4( 'div', { class: ns.b('dropdown'), style: { width: `${width}px`, }, }, (_a2 = $slots.empty) == null ? void 0 : _a2.call($slots) ) } const ListItem = withCtx((scoped) => { const { index: index2, data: data22 } = scoped const item2 = data22[index2] if (data22[index2].type === 'Group') { return h$4(GroupItem, { item: item2, style: scoped.style, height: isSized ? listProps.itemSize : listProps.estimatedSize, }) } const selected = isItemSelected(modelValue, item2) const itemDisabled = isItemDisabled(modelValue, selected) return h$4( OptionItem, { ...scoped, selected, disabled: item2.disabled || itemDisabled, created: !!item2.created, hovering: isItemHovering(index2), item: item2, onSelect, onHover, }, { default: withCtx((props2) => { return renderSlot($slots, 'default', props2, () => [ h$4('span', item2.label), ]) }), } ) }) const List2 = h$4( Comp, { ref: 'listRef', className: ns.be('dropdown', 'list'), data: data2, height, width, total: data2.length, scrollbarAlwaysOn: selectProps.scrollbarAlwaysOn, onKeydown: [ _cache[1] || (_cache[1] = withKeys( withModifiers( () => onKeyboardNavigate('forward'), ['stop', 'prevent'] ), ['down'] )), _cache[2] || (_cache[2] = withKeys( withModifiers( () => onKeyboardNavigate('backward'), ['stop', 'prevent'] ), ['up'] )), _cache[3] || (_cache[3] = withKeys( withModifiers(onKeyboardSelect, ['stop', 'prevent']), ['enter'] )), _cache[4] || (_cache[4] = withKeys( withModifiers( () => (select2.expanded = false), ['stop', 'prevent'] ), ['esc'] )), _cache[5] || (_cache[5] = withKeys(() => (select2.expanded = false), ['tab'])), ], ...listProps, }, { default: ListItem, } ) return h$4( 'div', { class: [ns.b('dropdown'), ns.is('multiple', multiple)], }, [List2] ) }, }) var ElSelectMenu = /* @__PURE__ */ _export_sfc$1(_sfc_main$7G, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/select-v2/src/select-dropdown.vue', ], ]) function useAllowCreate(props2, states) { const createOptionCount = ref(0) const cachedSelectedOption = ref(null) const enableAllowCreateMode = computed(() => { return props2.allowCreate && props2.filterable }) function hasExistingOption(query) { const hasValue = (option2) => option2.value === query return ( (props2.options && props2.options.some(hasValue)) || states.createdOptions.some(hasValue) ) } function selectNewOption(option2) { if (!enableAllowCreateMode.value) { return } if (props2.multiple && option2.created) { createOptionCount.value++ } else { cachedSelectedOption.value = option2 } } function createNewOption(query) { if (enableAllowCreateMode.value) { if (query && query.length > 0 && !hasExistingOption(query)) { const newOption = { value: query, label: query, created: true, disabled: false, } if (states.createdOptions.length >= createOptionCount.value) { states.createdOptions[createOptionCount.value] = newOption } else { states.createdOptions.push(newOption) } } else { if (props2.multiple) { states.createdOptions.length = createOptionCount.value } else { const selectedOption = cachedSelectedOption.value states.createdOptions.length = 0 if (selectedOption && selectedOption.created) { states.createdOptions.push(selectedOption) } } } } } function removeNewOption(option2) { if ( !enableAllowCreateMode.value || !option2 || !option2.created || (option2.created && props2.reserveKeyword && states.inputValue === option2.label) ) { return } const idx = states.createdOptions.findIndex( (it2) => it2.value === option2.value ) if (~idx) { states.createdOptions.splice(idx, 1) createOptionCount.value-- } } function clearAllNewOption() { if (enableAllowCreateMode.value) { states.createdOptions.length = 0 createOptionCount.value = 0 } } return { createNewOption, removeNewOption, selectNewOption, clearAllNewOption, } } const flattenOptions = (options2) => { const flattened = [] options2.forEach((option2) => { if (isArray$D(option2.options)) { flattened.push({ label: option2.label, isTitle: true, type: 'Group', }) option2.options.forEach((o2) => { flattened.push(o2) }) flattened.push({ type: 'Group', }) } else { flattened.push(option2) } }) return flattened } function useInput(handleInput) { const isComposing = ref(false) const handleCompositionStart = () => { isComposing.value = true } const handleCompositionUpdate = (event) => { const text2 = event.target.value const lastCharacter = text2[text2.length - 1] || '' isComposing.value = !isKorean(lastCharacter) } const handleCompositionEnd = (event) => { if (isComposing.value) { isComposing.value = false if (isFunction$l(handleInput)) { handleInput(event) } } } return { handleCompositionStart, handleCompositionUpdate, handleCompositionEnd, } } const DEFAULT_INPUT_PLACEHOLDER = '' const MINIMUM_INPUT_WIDTH = 11 const TAG_BASE_WIDTH = { larget: 51, default: 42, small: 33, } const COMPONENT_NAME$2 = 'ElSelectV2' const useSelect$1 = (props2, emit2) => { const { t: t3 } = useLocale() const nsSelectV2 = useNamespace('select-v2') const nsInput = useNamespace('input') const { form: elForm, formItem: elFormItem } = useFormItem() const { compatTeleported } = useDeprecateAppendToBody( COMPONENT_NAME$2, 'popperAppendToBody' ) const states = reactive({ inputValue: DEFAULT_INPUT_PLACEHOLDER, displayInputValue: DEFAULT_INPUT_PLACEHOLDER, calculatedWidth: 0, cachedPlaceholder: '', cachedOptions: [], createdOptions: [], createdLabel: '', createdSelected: false, currentPlaceholder: '', hoveringIndex: -1, comboBoxHovering: false, isOnComposition: false, isSilentBlur: false, isComposing: false, inputLength: 20, selectWidth: 200, initialInputHeight: 0, previousQuery: null, previousValue: '', query: '', selectedLabel: '', softFocus: false, tagInMultiLine: false, }) const selectedIndex = ref(-1) const popperSize = ref(-1) const controlRef = ref(null) const inputRef = ref(null) const menuRef = ref(null) const popper2 = ref(null) const selectRef = ref(null) const selectionRef = ref(null) const calculatorRef = ref(null) const expanded = ref(false) const selectDisabled = computed( () => props2.disabled || (elForm == null ? void 0 : elForm.disabled) ) const popupHeight = computed(() => { const totalHeight = filteredOptions.value.length * 34 return totalHeight > props2.height ? props2.height : totalHeight }) const hasModelValue = computed(() => { return ( props2.modelValue !== void 0 && props2.modelValue !== null && props2.modelValue !== '' ) }) const showClearBtn = computed(() => { const hasValue = props2.multiple ? Array.isArray(props2.modelValue) && props2.modelValue.length > 0 : hasModelValue.value const criteria = props2.clearable && !selectDisabled.value && states.comboBoxHovering && hasValue return criteria }) const iconComponent = computed(() => props2.remote && props2.filterable ? '' : arrowUp ) const iconReverse = computed( () => iconComponent.value && nsSelectV2.is('reverse', expanded.value) ) const validateState = computed( () => (elFormItem == null ? void 0 : elFormItem.validateState) || '' ) const validateIcon = computed( () => ValidateComponentsMap[validateState.value] ) const debounce$12 = computed(() => (props2.remote ? 300 : 0)) const emptyText = computed(() => { const options2 = filteredOptions.value if (props2.loading) { return props2.loadingText || t3('el.select.loading') } else { if (props2.remote && states.inputValue === '' && options2.length === 0) return false if (props2.filterable && states.inputValue && options2.length > 0) { return props2.noMatchText || t3('el.select.noMatch') } if (options2.length === 0) { return props2.noDataText || t3('el.select.noData') } } return null }) const filteredOptions = computed(() => { const isValidOption = (o2) => { const query = states.inputValue const containsQueryString = query ? o2.label.includes(query) : true return containsQueryString } if (props2.loading) { return [] } return flattenOptions( props2.options .concat(states.createdOptions) .map((v4) => { if (isArray$D(v4.options)) { const filtered = v4.options.filter(isValidOption) if (filtered.length > 0) { return { ...v4, options: filtered, } } } else { if (props2.remote || isValidOption(v4)) { return v4 } } return null }) .filter((v4) => v4 !== null) ) }) const optionsAllDisabled = computed(() => filteredOptions.value.every((option2) => option2.disabled) ) const selectSize = useSize$1() const collapseTagSize = computed(() => selectSize.value === 'small' ? 'small' : 'default' ) const tagMaxWidth = computed(() => { const select2 = selectionRef.value const size = collapseTagSize.value || 'default' const paddingLeft2 = select2 ? Number.parseInt(getComputedStyle(select2).paddingLeft) : 0 const paddingRight2 = select2 ? Number.parseInt(getComputedStyle(select2).paddingRight) : 0 return ( states.selectWidth - paddingRight2 - paddingLeft2 - TAG_BASE_WIDTH[size] ) }) const calculatePopperSize = () => { var _a2, _b2, _c2 popperSize.value = ((_c2 = (_b2 = (_a2 = selectRef.value) == null ? void 0 : _a2.getBoundingClientRect) == null ? void 0 : _b2.call(_a2)) == null ? void 0 : _c2.width) || 200 } const inputWrapperStyle = computed(() => { return { width: `${ states.calculatedWidth === 0 ? MINIMUM_INPUT_WIDTH : Math.ceil(states.calculatedWidth) + MINIMUM_INPUT_WIDTH }px`, } }) const shouldShowPlaceholder = computed(() => { if (isArray$D(props2.modelValue)) { return props2.modelValue.length === 0 && !states.displayInputValue } return props2.filterable ? states.displayInputValue.length === 0 : true }) const currentPlaceholder = computed(() => { const _placeholder = props2.placeholder || t3('el.select.placeholder') return props2.multiple ? _placeholder : states.selectedLabel || _placeholder }) const popperRef = computed(() => { var _a2, _b2 return (_b2 = (_a2 = popper2.value) == null ? void 0 : _a2.popperRef) == null ? void 0 : _b2.contentRef }) const indexRef = computed(() => { if (props2.multiple) { const len2 = props2.modelValue.length if (props2.modelValue.length > 0) { return filteredOptions.value.findIndex( (o2) => o2.value === props2.modelValue[len2 - 1] ) } } else { if (props2.modelValue) { return filteredOptions.value.findIndex( (o2) => o2.value === props2.modelValue ) } } return -1 }) const dropdownMenuVisible = computed(() => { return expanded.value && emptyText.value !== false }) const { createNewOption, removeNewOption, selectNewOption, clearAllNewOption, } = useAllowCreate(props2, states) const { handleCompositionStart, handleCompositionUpdate, handleCompositionEnd, } = useInput((e2) => onInput(e2)) const focusAndUpdatePopup = () => { var _a2, _b2, _c2 ;(_b2 = (_a2 = inputRef.value).focus) == null ? void 0 : _b2.call(_a2) ;(_c2 = popper2.value) == null ? void 0 : _c2.updatePopper() } const toggleMenu = () => { if (props2.automaticDropdown) return if (!selectDisabled.value) { if (states.isComposing) states.softFocus = true return nextTick(() => { var _a2, _b2 expanded.value = !expanded.value ;(_b2 = (_a2 = inputRef.value) == null ? void 0 : _a2.focus) == null ? void 0 : _b2.call(_a2) }) } } const onInputChange = () => { if (props2.filterable && states.inputValue !== states.selectedLabel) { states.query = states.selectedLabel } handleQueryChange(states.inputValue) return nextTick(() => { createNewOption(states.inputValue) }) } const debouncedOnInputChange = debounce$3(onInputChange, debounce$12.value) const handleQueryChange = (val2) => { if (states.previousQuery === val2) { return } states.previousQuery = val2 if (props2.filterable && isFunction$l(props2.filterMethod)) { props2.filterMethod(val2) } else if ( props2.filterable && props2.remote && isFunction$l(props2.remoteMethod) ) { props2.remoteMethod(val2) } } const emitChange = (val2) => { if (!isEqual$4(props2.modelValue, val2)) { emit2(CHANGE_EVENT, val2) } } const update3 = (val2) => { emit2(UPDATE_MODEL_EVENT, val2) emitChange(val2) states.previousValue = val2.toString() } const getValueIndex = (arr = [], value2) => { if (!isObject$v(value2)) { return arr.indexOf(value2) } const valueKey = props2.valueKey let index2 = -1 arr.some((item2, i2) => { if (get$a(item2, valueKey) === get$a(value2, valueKey)) { index2 = i2 return true } return false }) return index2 } const getValueKey = (item2) => { return isObject$v(item2) ? get$a(item2, props2.valueKey) : item2 } const getLabel = (item2) => { return isObject$v(item2) ? item2.label : item2 } const resetInputHeight = () => { if (props2.collapseTags && !props2.filterable) { return } return nextTick(() => { var _a2, _b2 if (!inputRef.value) return const selection = selectionRef.value selectRef.value.height = selection.offsetHeight if (expanded.value && emptyText.value !== false) { ;(_b2 = (_a2 = popper2.value) == null ? void 0 : _a2.updatePopper) == null ? void 0 : _b2.call(_a2) } }) } const handleResize = () => { var _a2, _b2 resetInputWidth() calculatePopperSize() ;(_b2 = (_a2 = popper2.value) == null ? void 0 : _a2.updatePopper) == null ? void 0 : _b2.call(_a2) if (props2.multiple) { return resetInputHeight() } } const resetInputWidth = () => { const select2 = selectionRef.value if (select2) { states.selectWidth = select2.getBoundingClientRect().width } } const onSelect = (option2, idx, byClick = true) => { var _a2, _b2 if (props2.multiple) { let selectedOptions = props2.modelValue.slice() const index2 = getValueIndex(selectedOptions, getValueKey(option2)) if (index2 > -1) { selectedOptions = [ ...selectedOptions.slice(0, index2), ...selectedOptions.slice(index2 + 1), ] states.cachedOptions.splice(index2, 1) removeNewOption(option2) } else if ( props2.multipleLimit <= 0 || selectedOptions.length < props2.multipleLimit ) { selectedOptions = [...selectedOptions, getValueKey(option2)] states.cachedOptions.push(option2) selectNewOption(option2) updateHoveringIndex(idx) } update3(selectedOptions) if (option2.created) { states.query = '' handleQueryChange('') states.inputLength = 20 } if (props2.filterable && !props2.reserveKeyword) { ;(_b2 = (_a2 = inputRef.value).focus) == null ? void 0 : _b2.call(_a2) onUpdateInputValue('') } if (props2.filterable) { states.calculatedWidth = calculatorRef.value.getBoundingClientRect().width } resetInputHeight() setSoftFocus() } else { selectedIndex.value = idx states.selectedLabel = option2.label update3(getValueKey(option2)) expanded.value = false states.isComposing = false states.isSilentBlur = byClick selectNewOption(option2) if (!option2.created) { clearAllNewOption() } updateHoveringIndex(idx) } } const deleteTag = (event, tag) => { const { valueKey } = props2 const index2 = props2.modelValue.indexOf(get$a(tag, valueKey)) if (index2 > -1 && !selectDisabled.value) { const value2 = [ ...props2.modelValue.slice(0, index2), ...props2.modelValue.slice(index2 + 1), ] states.cachedOptions.splice(index2, 1) update3(value2) emit2('remove-tag', get$a(tag, valueKey)) states.softFocus = true removeNewOption(tag) return nextTick(focusAndUpdatePopup) } event.stopPropagation() } const handleFocus = (event) => { const focused = states.isComposing states.isComposing = true if (!states.softFocus) { if (!focused) emit2('focus', event) } else { states.softFocus = false } } const handleBlur = () => { states.softFocus = false return nextTick(() => { var _a2, _b2 ;(_b2 = (_a2 = inputRef.value) == null ? void 0 : _a2.blur) == null ? void 0 : _b2.call(_a2) if (calculatorRef.value) { states.calculatedWidth = calculatorRef.value.getBoundingClientRect().width } if (states.isSilentBlur) { states.isSilentBlur = false } else { if (states.isComposing) { emit2('blur') } } states.isComposing = false }) } const handleEsc = () => { if (states.displayInputValue.length > 0) { onUpdateInputValue('') } else { expanded.value = false } } const handleDel = (e2) => { if (states.displayInputValue.length === 0) { e2.preventDefault() const selected = props2.modelValue.slice() selected.pop() removeNewOption(states.cachedOptions.pop()) update3(selected) } } const handleClear = () => { let emptyValue if (isArray$D(props2.modelValue)) { emptyValue = [] } else { emptyValue = '' } states.softFocus = true if (props2.multiple) { states.cachedOptions = [] } else { states.selectedLabel = '' } expanded.value = false update3(emptyValue) emit2('clear') clearAllNewOption() return nextTick(focusAndUpdatePopup) } const onUpdateInputValue = (val2) => { states.displayInputValue = val2 states.inputValue = val2 } const onKeyboardNavigate = (direction2, hoveringIndex = void 0) => { const options2 = filteredOptions.value if ( !['forward', 'backward'].includes(direction2) || selectDisabled.value || options2.length <= 0 || optionsAllDisabled.value ) { return } if (!expanded.value) { return toggleMenu() } if (hoveringIndex === void 0) { hoveringIndex = states.hoveringIndex } let newIndex2 = -1 if (direction2 === 'forward') { newIndex2 = hoveringIndex + 1 if (newIndex2 >= options2.length) { newIndex2 = 0 } } else if (direction2 === 'backward') { newIndex2 = hoveringIndex - 1 if (newIndex2 < 0) { newIndex2 = options2.length - 1 } } const option2 = options2[newIndex2] if (option2.disabled || option2.type === 'Group') { return onKeyboardNavigate(direction2, newIndex2) } else { updateHoveringIndex(newIndex2) scrollToItem(newIndex2) } } const onKeyboardSelect = () => { if (!expanded.value) { return toggleMenu() } else if ( ~states.hoveringIndex && filteredOptions.value[states.hoveringIndex] ) { onSelect( filteredOptions.value[states.hoveringIndex], states.hoveringIndex, false ) } } const updateHoveringIndex = (idx) => { states.hoveringIndex = idx } const resetHoveringIndex = () => { states.hoveringIndex = -1 } const setSoftFocus = () => { var _a2 const _input = inputRef.value if (_input) { ;(_a2 = _input.focus) == null ? void 0 : _a2.call(_input) } } const onInput = (event) => { const value2 = event.target.value onUpdateInputValue(value2) if (states.displayInputValue.length > 0 && !expanded.value) { expanded.value = true } states.calculatedWidth = calculatorRef.value.getBoundingClientRect().width if (props2.multiple) { resetInputHeight() } if (props2.remote) { debouncedOnInputChange() } else { return onInputChange() } } const handleClickOutside = () => { expanded.value = false return handleBlur() } const handleMenuEnter = () => { states.inputValue = states.displayInputValue return nextTick(() => { if (~indexRef.value) { updateHoveringIndex(indexRef.value) scrollToItem(states.hoveringIndex) } }) } const scrollToItem = (index2) => { menuRef.value.scrollToItem(index2) } const initStates = () => { resetHoveringIndex() if (props2.multiple) { if (props2.modelValue.length > 0) { let initHovering = false states.cachedOptions.length = 0 states.previousValue = props2.modelValue.toString() props2.modelValue.forEach((selected) => { const itemIndex = filteredOptions.value.findIndex( (option2) => getValueKey(option2) === selected ) if (~itemIndex) { states.cachedOptions.push(filteredOptions.value[itemIndex]) if (!initHovering) { updateHoveringIndex(itemIndex) } initHovering = true } }) } else { states.cachedOptions = [] states.previousValue = '' } } else { if (hasModelValue.value) { states.previousValue = props2.modelValue const options2 = filteredOptions.value const selectedItemIndex = options2.findIndex( (option2) => getValueKey(option2) === getValueKey(props2.modelValue) ) if (~selectedItemIndex) { states.selectedLabel = options2[selectedItemIndex].label updateHoveringIndex(selectedItemIndex) } else { states.selectedLabel = `${props2.modelValue}` } } else { states.selectedLabel = '' states.previousValue = '' } } calculatePopperSize() } watch$1(expanded, (val2) => { var _a2, _b2 emit2('visible-change', val2) if (val2) { ;(_b2 = (_a2 = popper2.value).update) == null ? void 0 : _b2.call(_a2) } else { states.displayInputValue = '' createNewOption('') } }) watch$1( () => props2.modelValue, (val2, oldVal) => { var _a2 if (!val2 || val2.toString() !== states.previousValue) { initStates() } if (!isEqual$4(val2, oldVal)) { ;(_a2 = elFormItem == null ? void 0 : elFormItem.validate) == null ? void 0 : _a2.call(elFormItem, 'change').catch((err) => debugWarn()) } }, { deep: true, } ) watch$1( () => props2.options, () => { const input = inputRef.value if (!input || (input && document.activeElement !== input)) { initStates() } }, { deep: true, } ) watch$1(filteredOptions, () => { return nextTick(menuRef.value.resetScrollTop) }) onMounted(() => { initStates() addResizeListener(selectRef.value, handleResize) }) onBeforeMount(() => { removeResizeListener(selectRef.value, handleResize) }) return { collapseTagSize, currentPlaceholder, expanded, emptyText, popupHeight, debounce: debounce$12, filteredOptions, iconComponent, iconReverse, inputWrapperStyle, popperSize, dropdownMenuVisible, hasModelValue, shouldShowPlaceholder, selectDisabled, selectSize, showClearBtn, states, tagMaxWidth, nsSelectV2, nsInput, calculatorRef, controlRef, inputRef, menuRef, popper: popper2, selectRef, selectionRef, popperRef, validateState, validateIcon, compatTeleported, debouncedOnInputChange, deleteTag, getLabel, getValueKey, handleBlur, handleClear, handleClickOutside, handleDel, handleEsc, handleFocus, handleMenuEnter, handleResize, toggleMenu, scrollTo: scrollToItem, onInput, onKeyboardNavigate, onKeyboardSelect, onSelect, onHover: updateHoveringIndex, onUpdateInputValue, handleCompositionStart, handleCompositionEnd, handleCompositionUpdate, } } const _sfc_main$7F = defineComponent({ name: 'ElSelectV2', components: { ElSelectMenu, ElTag, ElTooltip, ElIcon, }, directives: { ClickOutside, ModelText: vModelText }, props: SelectProps, emits: [ UPDATE_MODEL_EVENT, CHANGE_EVENT, 'remove-tag', 'clear', 'visible-change', 'focus', 'blur', ], setup(props2, { emit: emit2 }) { const API = useSelect$1(props2, emit2) provide(selectV2InjectionKey, { props: reactive({ ...toRefs$2(props2), height: API.popupHeight, }), onSelect: API.onSelect, onHover: API.onHover, onKeyboardNavigate: API.onKeyboardNavigate, onKeyboardSelect: API.onKeyboardSelect, }) return API }, }) const _hoisted_1$6f = { key: 0 } const _hoisted_2$57 = [ 'id', 'autocomplete', 'aria-expanded', 'aria-labelledby', 'disabled', 'readonly', 'name', 'unselectable', ] const _hoisted_3$4A = ['textContent'] const _hoisted_4$3_ = [ 'id', 'aria-labelledby', 'aria-expanded', 'autocomplete', 'disabled', 'name', 'readonly', 'unselectable', ] const _hoisted_5$3A = ['textContent'] function _sfc_render$C(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_tag = resolveComponent('el-tag') const _component_el_tooltip = resolveComponent('el-tooltip') const _component_el_icon = resolveComponent('el-icon') const _component_el_select_menu = resolveComponent('el-select-menu') const _directive_model_text = resolveDirective('model-text') const _directive_click_outside = resolveDirective('click-outside') return withDirectives( (openBlock(), createElementBlock( 'div', { ref: 'selectRef', class: normalizeClass([ _ctx.nsSelectV2.b(), _ctx.nsSelectV2.m(_ctx.selectSize), ]), onClick: _cache[24] || (_cache[24] = withModifiers( (...args) => _ctx.toggleMenu && _ctx.toggleMenu(...args), ['stop'] )), onMouseenter: _cache[25] || (_cache[25] = ($event) => (_ctx.states.comboBoxHovering = true)), onMouseleave: _cache[26] || (_cache[26] = ($event) => (_ctx.states.comboBoxHovering = false)), }, [ createVNode$1( _component_el_tooltip, { ref: 'popper', visible: _ctx.dropdownMenuVisible, 'onUpdate:visible': _cache[22] || (_cache[22] = ($event) => (_ctx.dropdownMenuVisible = $event)), teleported: _ctx.compatTeleported, 'popper-class': [_ctx.nsSelectV2.e('popper'), _ctx.popperClass], 'gpu-acceleration': false, 'stop-popper-mouse-event': false, 'popper-options': _ctx.popperOptions, 'fallback-placements': [ 'bottom-start', 'top-start', 'right', 'left', ], effect: _ctx.effect, placement: 'bottom-start', pure: '', transition: `${_ctx.nsSelectV2.namespace.value}-zoom-in-top`, trigger: 'click', persistent: _ctx.persistent, onBeforeShow: _ctx.handleMenuEnter, onHide: _cache[23] || (_cache[23] = ($event) => (_ctx.states.inputValue = _ctx.states.displayInputValue)), }, { default: withCtx(() => { var _a2 return [ createElementVNode( 'div', { ref: 'selectionRef', class: normalizeClass([ _ctx.nsSelectV2.e('wrapper'), _ctx.nsSelectV2.is('focused', _ctx.states.isComposing), _ctx.nsSelectV2.is( 'hovering', _ctx.states.comboBoxHovering ), _ctx.nsSelectV2.is('filterable', _ctx.filterable), _ctx.nsSelectV2.is('disabled', _ctx.selectDisabled), ]), }, [ _ctx.$slots.prefix ? (openBlock(), createElementBlock('div', _hoisted_1$6f, [ renderSlot(_ctx.$slots, 'prefix'), ])) : createCommentVNode('v-if', true), _ctx.multiple ? (openBlock(), createElementBlock( 'div', { key: 1, class: normalizeClass( _ctx.nsSelectV2.e('selection') ), }, [ _ctx.collapseTags && _ctx.modelValue.length > 0 ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass( _ctx.nsSelectV2.e('selected-item') ), }, [ createVNode$1( _component_el_tag, { closable: !_ctx.selectDisabled && !((_a2 = _ctx.states.cachedOptions[0]) == null ? void 0 : _a2.disable), size: _ctx.collapseTagSize, type: 'info', 'disable-transitions': '', onClose: _cache[0] || (_cache[0] = ($event) => _ctx.deleteTag( $event, _ctx.states.cachedOptions[0] )), }, { default: withCtx(() => { var _a22 return [ createElementVNode( 'span', { class: normalizeClass( _ctx.nsSelectV2.e('tags-text') ), style: normalizeStyle$1({ maxWidth: `${_ctx.tagMaxWidth}px`, }), }, toDisplayString$1( (_a22 = _ctx.states .cachedOptions[0]) == null ? void 0 : _a22.label ), 7 ), ] }), _: 1, }, 8, ['closable', 'size'] ), _ctx.modelValue.length > 1 ? (openBlock(), createBlock( _component_el_tag, { key: 0, closable: false, size: _ctx.collapseTagSize, type: 'info', 'disable-transitions': '', }, { default: withCtx(() => [ _ctx.collapseTagsTooltip ? (openBlock(), createBlock( _component_el_tooltip, { key: 0, disabled: _ctx.dropdownMenuVisible, 'fallback-placements': [ 'bottom', 'top', 'right', 'left', ], effect: _ctx.effect, placement: 'bottom', teleported: false, }, { default: withCtx(() => [ createElementVNode( 'span', { class: normalizeClass( _ctx.nsSelectV2.e( 'tags-text' ) ), style: normalizeStyle$1({ maxWidth: `${_ctx.tagMaxWidth}px`, }), }, '+ ' + toDisplayString$1( _ctx.modelValue .length - 1 ), 7 ), ]), content: withCtx(() => [ createElementVNode( 'div', { class: normalizeClass( _ctx.nsSelectV2.e( 'selection' ) ), }, [ (openBlock(true), createElementBlock( Fragment, null, renderList( _ctx.states .cachedOptions, ( selected, idx ) => { return ( openBlock(), createElementBlock( 'div', { key: idx, class: normalizeClass( _ctx.nsSelectV2.e( 'selected-item' ) ), }, [ (openBlock(), createBlock( _component_el_tag, { key: _ctx.getValueKey( selected ), closable: !_ctx.selectDisabled && !selected.disabled, size: _ctx.collapseTagSize, class: 'in-tooltip', type: 'info', 'disable-transitions': '', onClose: ( $event ) => _ctx.deleteTag( $event, selected ), }, { default: withCtx( () => [ createElementVNode( 'span', { class: normalizeClass( _ctx.nsSelectV2.e( 'tags-text' ) ), style: normalizeStyle$1( { maxWidth: `${_ctx.tagMaxWidth}px`, } ), }, toDisplayString$1( _ctx.getLabel( selected ) ), 7 ), ] ), _: 2, }, 1032, [ 'closable', 'size', 'onClose', ] )), ], 2 ) ) } ), 128 )), ], 2 ), ]), _: 1, }, 8, ['disabled', 'effect'] )) : (openBlock(), createElementBlock( 'span', { key: 1, class: normalizeClass( _ctx.nsSelectV2.e( 'tags-text' ) ), style: normalizeStyle$1({ maxWidth: `${_ctx.tagMaxWidth}px`, }), }, '+ ' + toDisplayString$1( _ctx.modelValue.length - 1 ), 7 )), ]), _: 1, }, 8, ['size'] )) : createCommentVNode('v-if', true), ], 2 )) : (openBlock(true), createElementBlock( Fragment, { key: 1 }, renderList( _ctx.states.cachedOptions, (selected, idx) => { return ( openBlock(), createElementBlock( 'div', { key: idx, class: normalizeClass( _ctx.nsSelectV2.e('selected-item') ), }, [ (openBlock(), createBlock( _component_el_tag, { key: _ctx.getValueKey(selected), closable: !_ctx.selectDisabled && !selected.disabled, size: _ctx.collapseTagSize, type: 'info', 'disable-transitions': '', onClose: ($event) => _ctx.deleteTag( $event, selected ), }, { default: withCtx(() => [ createElementVNode( 'span', { class: normalizeClass( _ctx.nsSelectV2.e( 'tags-text' ) ), style: normalizeStyle$1({ maxWidth: `${_ctx.tagMaxWidth}px`, }), }, toDisplayString$1( _ctx.getLabel(selected) ), 7 ), ]), _: 2, }, 1032, ['closable', 'size', 'onClose'] )), ], 2 ) ) } ), 128 )), createElementVNode( 'div', { class: normalizeClass([ _ctx.nsSelectV2.e('selected-item'), _ctx.nsSelectV2.e('input-wrapper'), ]), style: normalizeStyle$1(_ctx.inputWrapperStyle), }, [ withDirectives( createElementVNode( 'input', { id: _ctx.id, ref: 'inputRef', autocomplete: _ctx.autocomplete, 'aria-autocomplete': 'list', 'aria-haspopup': 'listbox', autocapitalize: 'off', 'aria-expanded': _ctx.expanded, 'aria-labelledby': _ctx.label, class: normalizeClass([ _ctx.nsSelectV2.is(_ctx.selectSize), _ctx.nsSelectV2.e('combobox-input'), ]), disabled: _ctx.disabled, role: 'combobox', readonly: !_ctx.filterable, spellcheck: 'false', type: 'text', name: _ctx.name, unselectable: _ctx.expanded ? 'on' : void 0, 'onUpdate:modelValue': _cache[1] || (_cache[1] = (...args) => _ctx.onUpdateInputValue && _ctx.onUpdateInputValue(...args)), onFocus: _cache[2] || (_cache[2] = (...args) => _ctx.handleFocus && _ctx.handleFocus(...args)), onInput: _cache[3] || (_cache[3] = (...args) => _ctx.onInput && _ctx.onInput(...args)), onCompositionstart: _cache[4] || (_cache[4] = (...args) => _ctx.handleCompositionStart && _ctx.handleCompositionStart(...args)), onCompositionupdate: _cache[5] || (_cache[5] = (...args) => _ctx.handleCompositionUpdate && _ctx.handleCompositionUpdate( ...args )), onCompositionend: _cache[6] || (_cache[6] = (...args) => _ctx.handleCompositionEnd && _ctx.handleCompositionEnd(...args)), onKeydown: [ _cache[7] || (_cache[7] = withKeys( withModifiers( ($event) => _ctx.onKeyboardNavigate( 'backward' ), ['stop', 'prevent'] ), ['up'] )), _cache[8] || (_cache[8] = withKeys( withModifiers( ($event) => _ctx.onKeyboardNavigate( 'forward' ), ['stop', 'prevent'] ), ['down'] )), _cache[9] || (_cache[9] = withKeys( withModifiers( (...args) => _ctx.onKeyboardSelect && _ctx.onKeyboardSelect(...args), ['stop', 'prevent'] ), ['enter'] )), _cache[10] || (_cache[10] = withKeys( withModifiers( (...args) => _ctx.handleEsc && _ctx.handleEsc(...args), ['stop', 'prevent'] ), ['esc'] )), _cache[11] || (_cache[11] = withKeys( withModifiers( (...args) => _ctx.handleDel && _ctx.handleDel(...args), ['stop'] ), ['delete'] )), ], }, null, 42, _hoisted_2$57 ), [ [ _directive_model_text, _ctx.states.displayInputValue, ], ] ), _ctx.filterable ? (openBlock(), createElementBlock( 'span', { key: 0, ref: 'calculatorRef', 'aria-hidden': 'true', class: normalizeClass( _ctx.nsSelectV2.e('input-calculator') ), textContent: toDisplayString$1( _ctx.states.displayInputValue ), }, null, 10, _hoisted_3$4A )) : createCommentVNode('v-if', true), ], 6 ), ], 2 )) : (openBlock(), createElementBlock( Fragment, { key: 2 }, [ createElementVNode( 'div', { class: normalizeClass([ _ctx.nsSelectV2.e('selected-item'), _ctx.nsSelectV2.e('input-wrapper'), ]), }, [ withDirectives( createElementVNode( 'input', { id: _ctx.id, ref: 'inputRef', 'aria-autocomplete': 'list', 'aria-haspopup': 'listbox', 'aria-labelledby': _ctx.label, 'aria-expanded': _ctx.expanded, autocapitalize: 'off', autocomplete: _ctx.autocomplete, class: normalizeClass( _ctx.nsSelectV2.e('combobox-input') ), disabled: _ctx.disabled, name: _ctx.name, role: 'combobox', readonly: !_ctx.filterable, spellcheck: 'false', type: 'text', unselectable: _ctx.expanded ? 'on' : void 0, onCompositionstart: _cache[12] || (_cache[12] = (...args) => _ctx.handleCompositionStart && _ctx.handleCompositionStart(...args)), onCompositionupdate: _cache[13] || (_cache[13] = (...args) => _ctx.handleCompositionUpdate && _ctx.handleCompositionUpdate( ...args )), onCompositionend: _cache[14] || (_cache[14] = (...args) => _ctx.handleCompositionEnd && _ctx.handleCompositionEnd(...args)), onFocus: _cache[15] || (_cache[15] = (...args) => _ctx.handleFocus && _ctx.handleFocus(...args)), onInput: _cache[16] || (_cache[16] = (...args) => _ctx.onInput && _ctx.onInput(...args)), onKeydown: [ _cache[17] || (_cache[17] = withKeys( withModifiers( ($event) => _ctx.onKeyboardNavigate( 'backward' ), ['stop', 'prevent'] ), ['up'] )), _cache[18] || (_cache[18] = withKeys( withModifiers( ($event) => _ctx.onKeyboardNavigate( 'forward' ), ['stop', 'prevent'] ), ['down'] )), _cache[19] || (_cache[19] = withKeys( withModifiers( (...args) => _ctx.onKeyboardSelect && _ctx.onKeyboardSelect(...args), ['stop', 'prevent'] ), ['enter'] )), _cache[20] || (_cache[20] = withKeys( withModifiers( (...args) => _ctx.handleEsc && _ctx.handleEsc(...args), ['stop', 'prevent'] ), ['esc'] )), ], 'onUpdate:modelValue': _cache[21] || (_cache[21] = (...args) => _ctx.onUpdateInputValue && _ctx.onUpdateInputValue(...args)), }, null, 42, _hoisted_4$3_ ), [ [ _directive_model_text, _ctx.states.displayInputValue, ], ] ), ], 2 ), _ctx.filterable ? (openBlock(), createElementBlock( 'span', { key: 0, ref: 'calculatorRef', 'aria-hidden': 'true', class: normalizeClass([ _ctx.nsSelectV2.e('selected-item'), _ctx.nsSelectV2.e('input-calculator'), ]), textContent: toDisplayString$1( _ctx.states.displayInputValue ), }, null, 10, _hoisted_5$3A )) : createCommentVNode('v-if', true), ], 64 )), _ctx.shouldShowPlaceholder ? (openBlock(), createElementBlock( 'span', { key: 3, class: normalizeClass([ _ctx.nsSelectV2.e('placeholder'), _ctx.nsSelectV2.is( 'transparent', _ctx.states.isComposing || (_ctx.placeholder && _ctx.multiple ? _ctx.modelValue.length === 0 : !_ctx.hasModelValue) ), ]), }, toDisplayString$1(_ctx.currentPlaceholder), 3 )) : createCommentVNode('v-if', true), createElementVNode( 'span', { class: normalizeClass(_ctx.nsSelectV2.e('suffix')), }, [ _ctx.iconComponent ? withDirectives( (openBlock(), createBlock( _component_el_icon, { key: 0, class: normalizeClass([ _ctx.nsSelectV2.e('caret'), _ctx.nsInput.e('icon'), _ctx.iconReverse, ]), }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent( _ctx.iconComponent ) )), ]), _: 1, }, 8, ['class'] )), [[vShow, !_ctx.showClearBtn]] ) : createCommentVNode('v-if', true), _ctx.showClearBtn && _ctx.clearIcon ? (openBlock(), createBlock( _component_el_icon, { key: 1, class: normalizeClass([ _ctx.nsSelectV2.e('caret'), _ctx.nsInput.e('icon'), ]), onClick: withModifiers(_ctx.handleClear, [ 'prevent', 'stop', ]), }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent(_ctx.clearIcon) )), ]), _: 1, }, 8, ['class', 'onClick'] )) : createCommentVNode('v-if', true), _ctx.validateState && _ctx.validateIcon ? (openBlock(), createBlock( _component_el_icon, { key: 2, class: normalizeClass([ _ctx.nsInput.e('icon'), _ctx.nsInput.e('validateIcon'), ]), }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent(_ctx.validateIcon) )), ]), _: 1, }, 8, ['class'] )) : createCommentVNode('v-if', true), ], 2 ), ], 2 ), ] }), content: withCtx(() => [ createVNode$1( _component_el_select_menu, { ref: 'menuRef', data: _ctx.filteredOptions, width: _ctx.popperSize, 'hovering-index': _ctx.states.hoveringIndex, 'scrollbar-always-on': _ctx.scrollbarAlwaysOn, }, { default: withCtx((scope) => [ renderSlot( _ctx.$slots, 'default', normalizeProps(guardReactiveProps(scope)) ), ]), empty: withCtx(() => [ renderSlot(_ctx.$slots, 'empty', {}, () => [ createElementVNode( 'p', { class: normalizeClass(_ctx.nsSelectV2.e('empty')), }, toDisplayString$1(_ctx.emptyText ? _ctx.emptyText : ''), 3 ), ]), ]), _: 3, }, 8, ['data', 'width', 'hovering-index', 'scrollbar-always-on'] ), ]), _: 3, }, 8, [ 'visible', 'teleported', 'popper-class', 'popper-options', 'effect', 'transition', 'persistent', 'onBeforeShow', ] ), ], 34 )), [[_directive_click_outside, _ctx.handleClickOutside, _ctx.popperRef]] ) } var Select$2 = /* @__PURE__ */ _export_sfc$1(_sfc_main$7F, [ ['render', _sfc_render$C], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/select-v2/src/select.vue', ], ]) Select$2.install = (app2) => { app2.component(Select$2.name, Select$2) } const _Select = Select$2 const ElSelectV2 = _Select const skeletonProps = buildProps({ animated: { type: Boolean, default: false, }, count: { type: Number, default: 1, }, rows: { type: Number, default: 3, }, loading: { type: Boolean, default: true, }, throttle: { type: Number, }, }) const skeletonItemProps = buildProps({ variant: { type: String, values: [ 'circle', 'rect', 'h1', 'h3', 'text', 'caption', 'p', 'image', 'button', ], default: 'text', }, }) const __default__$f = { name: 'ElSkeletonItem', } const _sfc_main$7E = /* @__PURE__ */ defineComponent({ ...__default__$f, props: skeletonItemProps, setup(__props2) { const ns = useNamespace('skeleton') return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { class: normalizeClass([ unref(ns).e('item'), unref(ns).e(_ctx.variant), ]), }, [ _ctx.variant === 'image' ? (openBlock(), createBlock(unref(pictureFilled), { key: 0 })) : createCommentVNode('v-if', true), ], 2 ) ) } }, }) var SkeletonItem = /* @__PURE__ */ _export_sfc$1(_sfc_main$7E, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/skeleton/src/skeleton-item.vue', ], ]) const __default__$e = { name: 'ElSkeleton', } const _sfc_main$7D = /* @__PURE__ */ defineComponent({ ...__default__$e, props: skeletonProps, setup(__props2, { expose }) { const props2 = __props2 const ns = useNamespace('skeleton') const uiLoading = useThrottleRender( toRef(props2, 'loading'), props2.throttle ) expose({ uiLoading, }) return (_ctx, _cache) => { return unref(uiLoading) ? (openBlock(), createElementBlock( 'div', mergeProps( { key: 0, class: [unref(ns).b(), unref(ns).is('animated', _ctx.animated)], }, _ctx.$attrs ), [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.count, (i2) => { return ( openBlock(), createElementBlock( Fragment, { key: i2 }, [ _ctx.loading ? renderSlot( _ctx.$slots, 'template', { key: i2 }, () => [ createVNode$1( SkeletonItem, { class: normalizeClass( unref(ns).is('first') ), variant: 'p', }, null, 8, ['class'] ), (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.rows, (item2) => { return ( openBlock(), createBlock( SkeletonItem, { key: item2, class: normalizeClass([ unref(ns).e('paragraph'), unref(ns).is( 'last', item2 === _ctx.rows && _ctx.rows > 1 ), ]), variant: 'p', }, null, 8, ['class'] ) ) }), 128 )), ] ) : createCommentVNode('v-if', true), ], 64 ) ) }), 128 )), ], 16 )) : renderSlot( _ctx.$slots, 'default', normalizeProps(mergeProps({ key: 1 }, _ctx.$attrs)) ) } }, }) var Skeleton = /* @__PURE__ */ _export_sfc$1(_sfc_main$7D, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/skeleton/src/skeleton.vue', ], ]) const ElSkeleton = withInstall(Skeleton, { SkeletonItem, }) const ElSkeletonItem = withNoopInstall(SkeletonItem) const useTooltip = (props2, formatTooltip, showTooltip2) => { const tooltip = ref(null) const tooltipVisible = ref(false) const enableFormat = computed(() => { return formatTooltip.value instanceof Function }) const formatValue = computed(() => { return ( (enableFormat.value && formatTooltip.value(props2.modelValue)) || props2.modelValue ) }) const displayTooltip = debounce$3(() => { showTooltip2.value && (tooltipVisible.value = true) }, 50) const hideTooltip = debounce$3(() => { showTooltip2.value && (tooltipVisible.value = false) }, 50) return { tooltip, tooltipVisible, formatValue, displayTooltip, hideTooltip, } } const useSliderButton = (props2, initData, emit2) => { const { disabled, min: min3, max: max3, step, showTooltip: showTooltip2, precision, sliderSize, formatTooltip, emitChange, resetSize, updateDragging, } = inject('SliderProvider') const { tooltip, tooltipVisible, formatValue, displayTooltip, hideTooltip } = useTooltip(props2, formatTooltip, showTooltip2) const currentPosition = computed(() => { return `${ ((props2.modelValue - min3.value) / (max3.value - min3.value)) * 100 }%` }) const wrapperStyle = computed(() => { return props2.vertical ? { bottom: currentPosition.value } : { left: currentPosition.value } }) const handleMouseEnter = () => { initData.hovering = true displayTooltip() } const handleMouseLeave = () => { initData.hovering = false if (!initData.dragging) { hideTooltip() } } const onButtonDown = (event) => { if (disabled.value) return event.preventDefault() onDragStart(event) on$2(window, 'mousemove', onDragging) on$2(window, 'touchmove', onDragging) on$2(window, 'mouseup', onDragEnd) on$2(window, 'touchend', onDragEnd) on$2(window, 'contextmenu', onDragEnd) } const onLeftKeyDown = () => { if (disabled.value) return initData.newPosition = Number.parseFloat(currentPosition.value) - (step.value / (max3.value - min3.value)) * 100 setPosition(initData.newPosition) emitChange() } const onRightKeyDown = () => { if (disabled.value) return initData.newPosition = Number.parseFloat(currentPosition.value) + (step.value / (max3.value - min3.value)) * 100 setPosition(initData.newPosition) emitChange() } const getClientXY2 = (event) => { let clientX let clientY if (event.type.startsWith('touch')) { clientY = event.touches[0].clientY clientX = event.touches[0].clientX } else { clientY = event.clientY clientX = event.clientX } return { clientX, clientY, } } const onDragStart = (event) => { initData.dragging = true initData.isClick = true const { clientX, clientY } = getClientXY2(event) if (props2.vertical) { initData.startY = clientY } else { initData.startX = clientX } initData.startPosition = Number.parseFloat(currentPosition.value) initData.newPosition = initData.startPosition } const onDragging = (event) => { if (initData.dragging) { initData.isClick = false displayTooltip() resetSize() let diff const { clientX, clientY } = getClientXY2(event) if (props2.vertical) { initData.currentY = clientY diff = ((initData.startY - initData.currentY) / sliderSize.value) * 100 } else { initData.currentX = clientX diff = ((initData.currentX - initData.startX) / sliderSize.value) * 100 } initData.newPosition = initData.startPosition + diff setPosition(initData.newPosition) } } const onDragEnd = () => { if (initData.dragging) { setTimeout(() => { initData.dragging = false if (!initData.hovering) { hideTooltip() } if (!initData.isClick) { setPosition(initData.newPosition) emitChange() } }, 0) off$1(window, 'mousemove', onDragging) off$1(window, 'touchmove', onDragging) off$1(window, 'mouseup', onDragEnd) off$1(window, 'touchend', onDragEnd) off$1(window, 'contextmenu', onDragEnd) } } const setPosition = async (newPosition) => { if (newPosition === null || Number.isNaN(+newPosition)) return if (newPosition < 0) { newPosition = 0 } else if (newPosition > 100) { newPosition = 100 } const lengthPerStep = 100 / ((max3.value - min3.value) / step.value) const steps = Math.round(newPosition / lengthPerStep) let value2 = steps * lengthPerStep * (max3.value - min3.value) * 0.01 + min3.value value2 = Number.parseFloat(value2.toFixed(precision.value)) emit2(UPDATE_MODEL_EVENT, value2) if (!initData.dragging && props2.modelValue !== initData.oldValue) { initData.oldValue = props2.modelValue } await nextTick() initData.dragging && displayTooltip() tooltip.value.updatePopper() } watch$1( () => initData.dragging, (val2) => { updateDragging(val2) } ) return { tooltip, tooltipVisible, showTooltip: showTooltip2, wrapperStyle, formatValue, handleMouseEnter, handleMouseLeave, onButtonDown, onLeftKeyDown, onRightKeyDown, setPosition, } } const _sfc_main$7C = defineComponent({ name: 'ElSliderButton', components: { ElTooltip, }, props: { modelValue: { type: Number, default: 0, }, vertical: { type: Boolean, default: false, }, tooltipClass: { type: String, default: '', }, }, emits: [UPDATE_MODEL_EVENT], setup(props2, { emit: emit2 }) { const ns = useNamespace('slider') const initData = reactive({ hovering: false, dragging: false, isClick: false, startX: 0, currentX: 0, startY: 0, currentY: 0, startPosition: 0, newPosition: 0, oldValue: props2.modelValue, }) const { tooltip, showTooltip: showTooltip2, tooltipVisible, wrapperStyle, formatValue, handleMouseEnter, handleMouseLeave, onButtonDown, onLeftKeyDown, onRightKeyDown, setPosition, } = useSliderButton(props2, initData, emit2) const { hovering, dragging } = toRefs$2(initData) return { ns, tooltip, tooltipVisible, showTooltip: showTooltip2, wrapperStyle, formatValue, handleMouseEnter, handleMouseLeave, onButtonDown, onLeftKeyDown, onRightKeyDown, setPosition, hovering, dragging, } }, }) function _sfc_render$B(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_tooltip = resolveComponent('el-tooltip') return ( openBlock(), createElementBlock( 'div', { ref: 'button', class: normalizeClass([ _ctx.ns.e('button-wrapper'), { hover: _ctx.hovering, dragging: _ctx.dragging }, ]), style: normalizeStyle$1(_ctx.wrapperStyle), tabindex: '0', onMouseenter: _cache[1] || (_cache[1] = (...args) => _ctx.handleMouseEnter && _ctx.handleMouseEnter(...args)), onMouseleave: _cache[2] || (_cache[2] = (...args) => _ctx.handleMouseLeave && _ctx.handleMouseLeave(...args)), onMousedown: _cache[3] || (_cache[3] = (...args) => _ctx.onButtonDown && _ctx.onButtonDown(...args)), onTouchstart: _cache[4] || (_cache[4] = (...args) => _ctx.onButtonDown && _ctx.onButtonDown(...args)), onFocus: _cache[5] || (_cache[5] = (...args) => _ctx.handleMouseEnter && _ctx.handleMouseEnter(...args)), onBlur: _cache[6] || (_cache[6] = (...args) => _ctx.handleMouseLeave && _ctx.handleMouseLeave(...args)), onKeydown: [ _cache[7] || (_cache[7] = withKeys( (...args) => _ctx.onLeftKeyDown && _ctx.onLeftKeyDown(...args), ['left'] )), _cache[8] || (_cache[8] = withKeys( (...args) => _ctx.onRightKeyDown && _ctx.onRightKeyDown(...args), ['right'] )), _cache[9] || (_cache[9] = withKeys( withModifiers( (...args) => _ctx.onLeftKeyDown && _ctx.onLeftKeyDown(...args), ['prevent'] ), ['down'] )), _cache[10] || (_cache[10] = withKeys( withModifiers( (...args) => _ctx.onRightKeyDown && _ctx.onRightKeyDown(...args), ['prevent'] ), ['up'] )), ], }, [ createVNode$1( _component_el_tooltip, { ref: 'tooltip', visible: _ctx.tooltipVisible, 'onUpdate:visible': _cache[0] || (_cache[0] = ($event) => (_ctx.tooltipVisible = $event)), placement: 'top', 'stop-popper-mouse-event': false, 'popper-class': _ctx.tooltipClass, disabled: !_ctx.showTooltip, persistent: '', }, { content: withCtx(() => [ createElementVNode( 'span', null, toDisplayString$1(_ctx.formatValue), 1 ), ]), default: withCtx(() => [ createElementVNode( 'div', { class: normalizeClass([ _ctx.ns.e('button'), { hover: _ctx.hovering, dragging: _ctx.dragging }, ]), }, null, 2 ), ]), _: 1, }, 8, ['visible', 'popper-class', 'disabled'] ), ], 38 ) ) } var SliderButton = /* @__PURE__ */ _export_sfc$1(_sfc_main$7C, [ ['render', _sfc_render$B], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/slider/src/button.vue', ], ]) const _sfc_main$7B = defineComponent({ name: 'ElMarker', props: { mark: { type: [String, Object], default: () => void 0, }, }, setup(props2) { const ns = useNamespace('slider') const label = computed(() => { return typeof props2.mark === 'string' ? props2.mark : props2.mark.label }) return { ns, label, } }, render() { var _a2 return h$4( 'div', { class: this.ns.e('marks-text'), style: (_a2 = this.mark) == null ? void 0 : _a2.style, }, this.label ) }, }) var SliderMarker = /* @__PURE__ */ _export_sfc$1(_sfc_main$7B, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/slider/src/marker.vue', ], ]) const useMarks = (props2) => { return computed(() => { if (!props2.marks) { return [] } const marksKeys = Object.keys(props2.marks) return marksKeys .map(parseFloat) .sort((a2, b2) => a2 - b2) .filter((point) => point <= props2.max && point >= props2.min) .map((point) => ({ point, position: ((point - props2.min) * 100) / (props2.max - props2.min), mark: props2.marks[point], })) }) } const useSlide = (props2, initData, emit2) => { const elForm = inject(formContextKey, {}) const elFormItem = inject(formItemContextKey, {}) const slider = shallowRef(null) const firstButton = ref(null) const secondButton = ref(null) const buttonRefs = { firstButton, secondButton, } const sliderDisabled = computed(() => { return props2.disabled || elForm.disabled || false }) const minValue = computed(() => { return Math.min(initData.firstValue, initData.secondValue) }) const maxValue = computed(() => { return Math.max(initData.firstValue, initData.secondValue) }) const barSize = computed(() => { return props2.range ? `${ (100 * (maxValue.value - minValue.value)) / (props2.max - props2.min) }%` : `${ (100 * (initData.firstValue - props2.min)) / (props2.max - props2.min) }%` }) const barStart = computed(() => { return props2.range ? `${(100 * (minValue.value - props2.min)) / (props2.max - props2.min)}%` : '0%' }) const runwayStyle = computed(() => { return props2.vertical ? { height: props2.height } : {} }) const barStyle = computed(() => { return props2.vertical ? { height: barSize.value, bottom: barStart.value, } : { width: barSize.value, left: barStart.value, } }) const resetSize = () => { if (slider.value) { initData.sliderSize = slider.value[`client${props2.vertical ? 'Height' : 'Width'}`] } } const setPosition = (percent) => { const targetValue = props2.min + (percent * (props2.max - props2.min)) / 100 if (!props2.range) { firstButton.value.setPosition(percent) return } let buttonRefName if ( Math.abs(minValue.value - targetValue) < Math.abs(maxValue.value - targetValue) ) { buttonRefName = initData.firstValue < initData.secondValue ? 'firstButton' : 'secondButton' } else { buttonRefName = initData.firstValue > initData.secondValue ? 'firstButton' : 'secondButton' } buttonRefs[buttonRefName].value.setPosition(percent) } const setFirstValue = (firstValue) => { initData.firstValue = firstValue _emit(props2.range ? [minValue.value, maxValue.value] : firstValue) } const setSecondValue = (secondValue) => { initData.secondValue = secondValue if (props2.range) { _emit([minValue.value, maxValue.value]) } } const _emit = (val2) => { emit2(UPDATE_MODEL_EVENT, val2) emit2(INPUT_EVENT, val2) } const emitChange = async () => { await nextTick() emit2( CHANGE_EVENT, props2.range ? [minValue.value, maxValue.value] : props2.modelValue ) } const onSliderClick = (event) => { if (sliderDisabled.value || initData.dragging) return resetSize() if (props2.vertical) { const sliderOffsetBottom = slider.value.getBoundingClientRect().bottom setPosition( ((sliderOffsetBottom - event.clientY) / initData.sliderSize) * 100 ) } else { const sliderOffsetLeft = slider.value.getBoundingClientRect().left setPosition( ((event.clientX - sliderOffsetLeft) / initData.sliderSize) * 100 ) } emitChange() } return { elFormItem, slider, firstButton, secondButton, sliderDisabled, minValue, maxValue, runwayStyle, barStyle, resetSize, setPosition, emitChange, onSliderClick, setFirstValue, setSecondValue, } } const useStops = (props2, initData, minValue, maxValue) => { const stops = computed(() => { if (!props2.showStops || props2.min > props2.max) return [] if (props2.step === 0) { return [] } const stopCount = (props2.max - props2.min) / props2.step const stepWidth = (100 * props2.step) / (props2.max - props2.min) const result = Array.from({ length: stopCount - 1 }).map( (_2, index2) => (index2 + 1) * stepWidth ) if (props2.range) { return result.filter((step) => { return ( step < (100 * (minValue.value - props2.min)) / (props2.max - props2.min) || step > (100 * (maxValue.value - props2.min)) / (props2.max - props2.min) ) }) } else { return result.filter( (step) => step > (100 * (initData.firstValue - props2.min)) / (props2.max - props2.min) ) } }) const getStopStyle = (position2) => { return props2.vertical ? { bottom: `${position2}%` } : { left: `${position2}%` } } return { stops, getStopStyle, } } const _sfc_main$7A = defineComponent({ name: 'ElSlider', components: { ElInputNumber, SliderButton, SliderMarker, }, props: { modelValue: { type: [Number, Array], default: 0, }, min: { type: Number, default: 0, }, max: { type: Number, default: 100, }, step: { type: Number, default: 1, }, showInput: { type: Boolean, default: false, }, showInputControls: { type: Boolean, default: true, }, size: { type: String, validator: isValidComponentSize, }, inputSize: { type: String, validator: isValidComponentSize, }, showStops: { type: Boolean, default: false, }, showTooltip: { type: Boolean, default: true, }, formatTooltip: { type: Function, default: void 0, }, disabled: { type: Boolean, default: false, }, range: { type: Boolean, default: false, }, vertical: { type: Boolean, default: false, }, height: { type: String, default: '', }, debounce: { type: Number, default: 300, }, label: { type: String, default: void 0, }, tooltipClass: { type: String, default: void 0, }, marks: Object, }, emits: [UPDATE_MODEL_EVENT, CHANGE_EVENT, INPUT_EVENT], setup(props2, { emit: emit2 }) { const ns = useNamespace('slider') const initData = reactive({ firstValue: 0, secondValue: 0, oldValue: 0, dragging: false, sliderSize: 1, }) const { elFormItem, slider, firstButton, secondButton, sliderDisabled, minValue, maxValue, runwayStyle, barStyle, resetSize, emitChange, onSliderClick, setFirstValue, setSecondValue, } = useSlide(props2, initData, emit2) const { stops, getStopStyle } = useStops( props2, initData, minValue, maxValue ) const sliderWrapperSize = useSize$1() const sliderInputSize = computed( () => props2.inputSize || sliderWrapperSize.value ) const sliderKls = computed(() => [ ns.b(), ns.m(sliderWrapperSize.value), ns.is('vertical', props2.vertical), { [ns.m('with-input')]: props2.showInput }, ]) const markList = useMarks(props2) useWatch(props2, initData, minValue, maxValue, emit2, elFormItem) const precision = computed(() => { const precisions = [props2.min, props2.max, props2.step].map((item2) => { const decimal = `${item2}`.split('.')[1] return decimal ? decimal.length : 0 }) return Math.max.apply(null, precisions) }) const { sliderWrapper } = useLifecycle(props2, initData, resetSize) const { firstValue, secondValue, oldValue, dragging, sliderSize } = toRefs$2(initData) const updateDragging = (val2) => { initData.dragging = val2 } provide('SliderProvider', { ...toRefs$2(props2), sliderSize, disabled: sliderDisabled, precision, emitChange, resetSize, updateDragging, }) return { ns, firstValue, secondValue, oldValue, dragging, sliderSize, slider, firstButton, secondButton, sliderDisabled, runwayStyle, barStyle, emitChange, onSliderClick, getStopStyle, setFirstValue, setSecondValue, stops, markList, sliderWrapper, sliderWrapperSize, sliderInputSize, sliderKls, } }, }) const useWatch = (props2, initData, minValue, maxValue, emit2, elFormItem) => { const _emit = (val2) => { emit2(UPDATE_MODEL_EVENT, val2) emit2(INPUT_EVENT, val2) } const valueChanged = () => { if (props2.range) { return ![minValue.value, maxValue.value].every( (item2, index2) => item2 === initData.oldValue[index2] ) } else { return props2.modelValue !== initData.oldValue } } const setValues = () => { var _a2, _b2 if (props2.min > props2.max) { throwError$1('Slider', 'min should not be greater than max.') return } const val2 = props2.modelValue if (props2.range && Array.isArray(val2)) { if (val2[1] < props2.min) { _emit([props2.min, props2.min]) } else if (val2[0] > props2.max) { _emit([props2.max, props2.max]) } else if (val2[0] < props2.min) { _emit([props2.min, val2[1]]) } else if (val2[1] > props2.max) { _emit([val2[0], props2.max]) } else { initData.firstValue = val2[0] initData.secondValue = val2[1] if (valueChanged()) { ;(_a2 = elFormItem.validate) == null ? void 0 : _a2.call(elFormItem, 'change').catch((err) => debugWarn()) initData.oldValue = val2.slice() } } } else if ( !props2.range && typeof val2 === 'number' && !Number.isNaN(val2) ) { if (val2 < props2.min) { _emit(props2.min) } else if (val2 > props2.max) { _emit(props2.max) } else { initData.firstValue = val2 if (valueChanged()) { ;(_b2 = elFormItem.validate) == null ? void 0 : _b2.call(elFormItem, 'change').catch((err) => debugWarn()) initData.oldValue = val2 } } } } setValues() watch$1( () => initData.dragging, (val2) => { if (!val2) { setValues() } } ) watch$1( () => props2.modelValue, (val2, oldVal) => { if ( initData.dragging || (Array.isArray(val2) && Array.isArray(oldVal) && val2.every((item2, index2) => item2 === oldVal[index2]) && initData.firstValue === val2[0] && initData.secondValue === val2[1]) ) { return } setValues() }, { deep: true, } ) watch$1( () => [props2.min, props2.max], () => { setValues() } ) } const useLifecycle = (props2, initData, resetSize) => { const sliderWrapper = ref(null) onMounted(async () => { let valuetext if (props2.range) { if (Array.isArray(props2.modelValue)) { initData.firstValue = Math.max(props2.min, props2.modelValue[0]) initData.secondValue = Math.min(props2.max, props2.modelValue[1]) } else { initData.firstValue = props2.min initData.secondValue = props2.max } initData.oldValue = [initData.firstValue, initData.secondValue] valuetext = `${initData.firstValue}-${initData.secondValue}` } else { if ( typeof props2.modelValue !== 'number' || Number.isNaN(props2.modelValue) ) { initData.firstValue = props2.min } else { initData.firstValue = Math.min( props2.max, Math.max(props2.min, props2.modelValue) ) } initData.oldValue = initData.firstValue valuetext = initData.firstValue } sliderWrapper.value.setAttribute('aria-valuetext', valuetext) sliderWrapper.value.setAttribute( 'aria-label', props2.label ? props2.label : `slider between ${props2.min} and ${props2.max}` ) on$2(window, 'resize', resetSize) await nextTick() resetSize() }) onBeforeUnmount(() => { off$1(window, 'resize', resetSize) }) return { sliderWrapper, } } const _hoisted_1$6e = [ 'aria-valuemin', 'aria-valuemax', 'aria-orientation', 'aria-disabled', ] const _hoisted_2$56 = { key: 1 } function _sfc_render$A(_ctx, _cache, $props2, $setup, $data, $options) { const _component_slider_button = resolveComponent('slider-button') const _component_slider_marker = resolveComponent('slider-marker') const _component_el_input_number = resolveComponent('el-input-number') return ( openBlock(), createElementBlock( 'div', { ref: 'sliderWrapper', class: normalizeClass(_ctx.sliderKls), role: 'slider', 'aria-valuemin': _ctx.min, 'aria-valuemax': _ctx.max, 'aria-orientation': _ctx.vertical ? 'vertical' : 'horizontal', 'aria-disabled': _ctx.sliderDisabled, }, [ createElementVNode( 'div', { ref: 'slider', class: normalizeClass([ _ctx.ns.e('runway'), { 'show-input': _ctx.showInput && !_ctx.range }, _ctx.ns.is('disabled', _ctx.sliderDisabled), ]), style: normalizeStyle$1(_ctx.runwayStyle), onClick: _cache[0] || (_cache[0] = (...args) => _ctx.onSliderClick && _ctx.onSliderClick(...args)), }, [ createElementVNode( 'div', { class: normalizeClass(_ctx.ns.e('bar')), style: normalizeStyle$1(_ctx.barStyle), }, null, 6 ), createVNode$1( _component_slider_button, { ref: 'firstButton', 'model-value': _ctx.firstValue, vertical: _ctx.vertical, 'tooltip-class': _ctx.tooltipClass, 'onUpdate:modelValue': _ctx.setFirstValue, }, null, 8, [ 'model-value', 'vertical', 'tooltip-class', 'onUpdate:modelValue', ] ), _ctx.range ? (openBlock(), createBlock( _component_slider_button, { key: 0, ref: 'secondButton', 'model-value': _ctx.secondValue, vertical: _ctx.vertical, 'tooltip-class': _ctx.tooltipClass, 'onUpdate:modelValue': _ctx.setSecondValue, }, null, 8, [ 'model-value', 'vertical', 'tooltip-class', 'onUpdate:modelValue', ] )) : createCommentVNode('v-if', true), _ctx.showStops ? (openBlock(), createElementBlock('div', _hoisted_2$56, [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.stops, (item2, key2) => { return ( openBlock(), createElementBlock( 'div', { key: key2, class: normalizeClass(_ctx.ns.e('stop')), style: normalizeStyle$1(_ctx.getStopStyle(item2)), }, null, 6 ) ) }), 128 )), ])) : createCommentVNode('v-if', true), _ctx.markList.length > 0 ? (openBlock(), createElementBlock( Fragment, { key: 2 }, [ createElementVNode('div', null, [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.markList, (item2, key2) => { return ( openBlock(), createElementBlock( 'div', { key: key2, style: normalizeStyle$1( _ctx.getStopStyle(item2.position) ), class: normalizeClass([ _ctx.ns.e('stop'), _ctx.ns.e('marks-stop'), ]), }, null, 6 ) ) }), 128 )), ]), createElementVNode( 'div', { class: normalizeClass(_ctx.ns.e('marks')), }, [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.markList, (item2, key2) => { return ( openBlock(), createBlock( _component_slider_marker, { key: key2, mark: item2.mark, style: normalizeStyle$1( _ctx.getStopStyle(item2.position) ), }, null, 8, ['mark', 'style'] ) ) }), 128 )), ], 2 ), ], 64 )) : createCommentVNode('v-if', true), ], 6 ), _ctx.showInput && !_ctx.range ? (openBlock(), createBlock( _component_el_input_number, { key: 0, ref: 'input', 'model-value': _ctx.firstValue, class: normalizeClass(_ctx.ns.e('input')), step: _ctx.step, disabled: _ctx.sliderDisabled, controls: _ctx.showInputControls, min: _ctx.min, max: _ctx.max, debounce: _ctx.debounce, size: _ctx.sliderInputSize, 'onUpdate:modelValue': _ctx.setFirstValue, onChange: _ctx.emitChange, }, null, 8, [ 'model-value', 'class', 'step', 'disabled', 'controls', 'min', 'max', 'debounce', 'size', 'onUpdate:modelValue', 'onChange', ] )) : createCommentVNode('v-if', true), ], 10, _hoisted_1$6e ) ) } var Slider = /* @__PURE__ */ _export_sfc$1(_sfc_main$7A, [ ['render', _sfc_render$A], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/slider/src/index.vue', ], ]) Slider.install = (app2) => { app2.component(Slider.name, Slider) } const _Slider = Slider const ElSlider = _Slider const spaceItem = buildProps({ prefixCls: { type: String, default: '', }, }) const _sfc_main$7z = defineComponent({ props: spaceItem, setup(props2) { const ns = useNamespace('space') const classes = computed(() => `${props2.prefixCls || ns.b()}__item`) return { classes, } }, }) function _sfc_render$z(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock( 'div', { class: normalizeClass(_ctx.classes), }, [renderSlot(_ctx.$slots, 'default')], 2 ) ) } var Item = /* @__PURE__ */ _export_sfc$1(_sfc_main$7z, [ ['render', _sfc_render$z], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/space/src/item.vue', ], ]) const SIZE_MAP = { small: 8, default: 12, large: 16, } function useSpace(props2) { const ns = useNamespace('space') const classes = computed(() => [ns.b(), ns.m(props2.direction), props2.class]) const horizontalSize = ref(0) const verticalSize = ref(0) const containerStyle = computed(() => { const wrapKls = props2.wrap || props2.fill ? { flexWrap: 'wrap', marginBottom: `-${verticalSize.value}px` } : {} const alignment = { alignItems: props2.alignment, } return [wrapKls, alignment, props2.style] }) const itemStyle = computed(() => { const itemBaseStyle = { paddingBottom: `${verticalSize.value}px`, marginRight: `${horizontalSize.value}px`, } const fillStyle = props2.fill ? { flexGrow: 1, minWidth: `${props2.fillRatio}%` } : {} return [itemBaseStyle, fillStyle] }) watchEffect(() => { const { size = 'small', wrap, direction: dir3, fill } = props2 if (Array.isArray(size)) { const [h2 = 0, v4 = 0] = size horizontalSize.value = h2 verticalSize.value = v4 } else { let val2 if (isNumber$h(size)) { val2 = size } else { val2 = SIZE_MAP[size] || SIZE_MAP.small } if ((wrap || fill) && dir3 === 'horizontal') { horizontalSize.value = verticalSize.value = val2 } else { if (dir3 === 'horizontal') { horizontalSize.value = val2 verticalSize.value = 0 } else { verticalSize.value = val2 horizontalSize.value = 0 } } } }) return { classes, containerStyle, itemStyle, } } const spaceProps = buildProps({ direction: { type: String, values: ['horizontal', 'vertical'], default: 'horizontal', }, class: { type: definePropType([String, Object, Array]), default: '', }, style: { type: definePropType([String, Array, Object]), default: '', }, alignment: { type: definePropType(String), default: 'center', }, prefixCls: { type: String, }, spacer: { type: definePropType([Object, String, Number, Array]), default: null, validator: (val2) => isVNode$1(val2) || isNumber$h(val2) || isString$f(val2), }, wrap: { type: Boolean, default: false, }, fill: { type: Boolean, default: false, }, fillRatio: { type: Number, default: 100, }, size: { type: [String, Array, Number], values: componentSizes, validator: (val2) => { return ( isNumber$h(val2) || (isArray$D(val2) && val2.length === 2 && val2.every((i2) => isNumber$h(i2))) ) }, }, }) var Space = defineComponent({ name: 'ElSpace', props: spaceProps, setup(props2, { slots }) { const { classes, containerStyle, itemStyle } = useSpace(props2) return () => { var _a2 const { spacer, prefixCls, direction: direction2 } = props2 const children = renderSlot(slots, 'default', { key: 0 }, () => []) if (((_a2 = children.children) != null ? _a2 : []).length === 0) return null if (isArray$D(children.children)) { let extractedChildren = [] children.children.forEach((child, loopKey) => { if (isFragment(child)) { if (isArray$D(child.children)) { child.children.forEach((nested, key2) => { extractedChildren.push( createVNode$1( Item, { style: itemStyle.value, prefixCls, key: `nested-${key2}`, }, { default: () => [nested], }, PatchFlags.PROPS | PatchFlags.STYLE, ['style', 'prefixCls'] ) ) }) } } else if (isValidElementNode(child)) { extractedChildren.push( createVNode$1( Item, { style: itemStyle.value, prefixCls, key: `LoopKey${loopKey}`, }, { default: () => [child], }, PatchFlags.PROPS | PatchFlags.STYLE, ['style', 'prefixCls'] ) ) } }) if (spacer) { const len2 = extractedChildren.length - 1 extractedChildren = extractedChildren.reduce((acc, child, idx) => { const children2 = [...acc, child] if (idx !== len2) { children2.push( createVNode$1( 'span', { style: [ itemStyle.value, direction2 === 'vertical' ? 'width: 100%' : null, ], key: idx, }, [ isVNode$1(spacer) ? spacer : createTextVNode(spacer, PatchFlags.TEXT), ], PatchFlags.STYLE ) ) } return children2 }, []) } return createVNode$1( 'div', { class: classes.value, style: containerStyle.value, }, extractedChildren, PatchFlags.STYLE | PatchFlags.CLASS ) } return children.children } }, }) const ElSpace = withInstall(Space) const _sfc_main$7y = defineComponent({ name: 'ElSteps', props: { space: { type: [Number, String], default: '', }, active: { type: Number, default: 0, }, direction: { type: String, default: 'horizontal', validator: (val2) => ['horizontal', 'vertical'].includes(val2), }, alignCenter: { type: Boolean, default: false, }, simple: { type: Boolean, default: false, }, finishStatus: { type: String, default: 'finish', validator: (val2) => ['wait', 'process', 'finish', 'error', 'success'].includes(val2), }, processStatus: { type: String, default: 'process', validator: (val2) => ['wait', 'process', 'finish', 'error', 'success'].includes(val2), }, }, emits: [CHANGE_EVENT], setup(props2, { emit: emit2 }) { const ns = useNamespace('steps') const steps = ref([]) watch$1(steps, () => { steps.value.forEach((instance, index2) => { instance.setIndex(index2) }) }) provide('ElSteps', { props: props2, steps }) watch$1( () => props2.active, (newVal, oldVal) => { emit2(CHANGE_EVENT, newVal, oldVal) } ) return { steps, ns, } }, }) function _sfc_render$y(_ctx, _cache, $props2, $setup, $data, $options) { return ( openBlock(), createElementBlock( 'div', { class: normalizeClass([ _ctx.ns.b(), _ctx.ns.m(_ctx.simple ? 'simple' : _ctx.direction), ]), }, [renderSlot(_ctx.$slots, 'default')], 2 ) ) } var Steps = /* @__PURE__ */ _export_sfc$1(_sfc_main$7y, [ ['render', _sfc_render$y], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/steps/src/index.vue', ], ]) const _sfc_main$7x = defineComponent({ name: 'ElStep', components: { ElIcon, Close: close$2, Check: check$1, }, props: { title: { type: String, default: '', }, icon: { type: [String, Object], default: '', }, description: { type: String, default: '', }, status: { type: String, default: '', validator: (val2) => ['', 'wait', 'process', 'finish', 'error', 'success'].includes(val2), }, }, setup(props2) { const ns = useNamespace('step') const index2 = ref(-1) const lineStyle = ref({}) const internalStatus = ref('') const parent2 = inject('ElSteps') const currentInstance = getCurrentInstance() onMounted(() => { watch$1( [ () => parent2.props.active, () => parent2.props.processStatus, () => parent2.props.finishStatus, ], ([active]) => { updateStatus(active) }, { immediate: true } ) }) onBeforeUnmount(() => { parent2.steps.value = parent2.steps.value.filter( (instance) => instance.uid !== currentInstance.uid ) }) const currentStatus = computed(() => { return props2.status || internalStatus.value }) const prevStatus = computed(() => { const prevStep = parent2.steps.value[index2.value - 1] return prevStep ? prevStep.currentStatus : 'wait' }) const isCenter = computed(() => { return parent2.props.alignCenter }) const isVertical = computed(() => { return parent2.props.direction === 'vertical' }) const isSimple = computed(() => { return parent2.props.simple }) const stepsCount = computed(() => { return parent2.steps.value.length }) const isLast = computed(() => { var _a2 return ( ((_a2 = parent2.steps.value[stepsCount.value - 1]) == null ? void 0 : _a2.uid) === currentInstance.uid ) }) const space = computed(() => { return isSimple.value ? '' : parent2.props.space }) const style2 = computed(() => { const style22 = { flexBasis: typeof space.value === 'number' ? `${space.value}px` : space.value ? space.value : `${100 / (stepsCount.value - (isCenter.value ? 0 : 1))}%`, } if (isVertical.value) return style22 if (isLast.value) { style22.maxWidth = `${100 / stepsCount.value}%` } return style22 }) const setIndex = (val2) => { index2.value = val2 } const calcProgress = (status) => { let step = 100 const style22 = {} style22.transitionDelay = `${150 * index2.value}ms` if (status === parent2.props.processStatus) { step = 0 } else if (status === 'wait') { step = 0 style22.transitionDelay = `${-150 * index2.value}ms` } style22.borderWidth = step && !isSimple.value ? '1px' : 0 style22[ parent2.props.direction === 'vertical' ? 'height' : 'width' ] = `${step}%` lineStyle.value = style22 } const updateStatus = (activeIndex) => { if (activeIndex > index2.value) { internalStatus.value = parent2.props.finishStatus } else if (activeIndex === index2.value && prevStatus.value !== 'error') { internalStatus.value = parent2.props.processStatus } else { internalStatus.value = 'wait' } const prevChild = parent2.steps.value[stepsCount.value - 1] if (prevChild) prevChild.calcProgress(internalStatus.value) } const stepItemState = reactive({ uid: computed(() => currentInstance.uid), currentStatus, setIndex, calcProgress, }) parent2.steps.value = [...parent2.steps.value, stepItemState] return { ns, index: index2, lineStyle, currentStatus, isCenter, isVertical, isSimple, isLast, space, style: style2, parent: parent2, setIndex, calcProgress, updateStatus, } }, }) function _sfc_render$x(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_icon = resolveComponent('el-icon') const _component_check = resolveComponent('check') const _component_close = resolveComponent('close') return ( openBlock(), createElementBlock( 'div', { style: normalizeStyle$1(_ctx.style), class: normalizeClass([ _ctx.ns.b(), _ctx.ns.is(_ctx.isSimple ? 'simple' : _ctx.parent.props.direction), _ctx.ns.is('flex', _ctx.isLast && !_ctx.space && !_ctx.isCenter), _ctx.ns.is( 'center', _ctx.isCenter && !_ctx.isVertical && !_ctx.isSimple ), ]), }, [ createCommentVNode(' icon & line '), createElementVNode( 'div', { class: normalizeClass([ _ctx.ns.e('head'), _ctx.ns.is(_ctx.currentStatus), ]), }, [ !_ctx.isSimple ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass(_ctx.ns.e('line')), }, [ createElementVNode( 'i', { class: normalizeClass(_ctx.ns.e('line-inner')), style: normalizeStyle$1(_ctx.lineStyle), }, null, 6 ), ], 2 )) : createCommentVNode('v-if', true), createElementVNode( 'div', { class: normalizeClass([ _ctx.ns.e('icon'), _ctx.ns.is(_ctx.icon ? 'icon' : 'text'), ]), }, [ _ctx.currentStatus !== 'success' && _ctx.currentStatus !== 'error' ? renderSlot(_ctx.$slots, 'icon', { key: 0 }, () => [ _ctx.icon ? (openBlock(), createBlock( _component_el_icon, { key: 0, class: normalizeClass(_ctx.ns.e('icon-inner')), }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent(_ctx.icon) )), ]), _: 1, }, 8, ['class'] )) : createCommentVNode('v-if', true), !_ctx.icon && !_ctx.isSimple ? (openBlock(), createElementBlock( 'div', { key: 1, class: normalizeClass(_ctx.ns.e('icon-inner')), }, toDisplayString$1(_ctx.index + 1), 3 )) : createCommentVNode('v-if', true), ]) : (openBlock(), createBlock( _component_el_icon, { key: 1, class: normalizeClass([ _ctx.ns.e('icon-inner'), _ctx.ns.is('status'), ]), }, { default: withCtx(() => [ _ctx.currentStatus === 'success' ? (openBlock(), createBlock(_component_check, { key: 0 })) : (openBlock(), createBlock(_component_close, { key: 1 })), ]), _: 1, }, 8, ['class'] )), ], 2 ), ], 2 ), createCommentVNode(' title & description '), createElementVNode( 'div', { class: normalizeClass(_ctx.ns.e('main')), }, [ createElementVNode( 'div', { class: normalizeClass([ _ctx.ns.e('title'), _ctx.ns.is(_ctx.currentStatus), ]), }, [ renderSlot(_ctx.$slots, 'title', {}, () => [ createTextVNode(toDisplayString$1(_ctx.title), 1), ]), ], 2 ), _ctx.isSimple ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass(_ctx.ns.e('arrow')), }, null, 2 )) : (openBlock(), createElementBlock( 'div', { key: 1, class: normalizeClass([ _ctx.ns.e('description'), _ctx.ns.is(_ctx.currentStatus), ]), }, [ renderSlot(_ctx.$slots, 'description', {}, () => [ createTextVNode(toDisplayString$1(_ctx.description), 1), ]), ], 2 )), ], 2 ), ], 6 ) ) } var Step = /* @__PURE__ */ _export_sfc$1(_sfc_main$7x, [ ['render', _sfc_render$x], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/steps/src/item.vue', ], ]) const ElSteps = withInstall(Steps, { Step, }) const ElStep = withNoopInstall(Step) const switchProps = buildProps({ modelValue: { type: [Boolean, String, Number], default: false, }, value: { type: [Boolean, String, Number], default: false, }, disabled: { type: Boolean, default: false, }, width: { type: Number, default: 40, }, inlinePrompt: { type: Boolean, default: false, }, activeIcon: { type: iconPropType, default: '', }, inactiveIcon: { type: iconPropType, default: '', }, activeText: { type: String, default: '', }, inactiveText: { type: String, default: '', }, activeColor: { type: String, default: '', }, inactiveColor: { type: String, default: '', }, borderColor: { type: String, default: '', }, activeValue: { type: [Boolean, String, Number], default: true, }, inactiveValue: { type: [Boolean, String, Number], default: false, }, name: { type: String, default: '', }, validateEvent: { type: Boolean, default: true, }, id: String, loading: { type: Boolean, default: false, }, beforeChange: { type: definePropType(Function), }, size: { type: String, validator: isValidComponentSize, }, }) const switchEmits = { [UPDATE_MODEL_EVENT]: (val2) => isBoolean$5(val2) || isString$f(val2) || isNumber$h(val2), [CHANGE_EVENT]: (val2) => isBoolean$5(val2) || isString$f(val2) || isNumber$h(val2), [INPUT_EVENT]: (val2) => isBoolean$5(val2) || isString$f(val2) || isNumber$h(val2), } const COMPONENT_NAME$1 = 'ElSwitch' const _sfc_main$7w = defineComponent({ name: COMPONENT_NAME$1, components: { ElIcon, Loading: loading }, props: switchProps, emits: switchEmits, setup(props2, { emit: emit2 }) { const { formItem } = useFormItem() const switchDisabled = useDisabled$1(computed(() => props2.loading)) const ns = useNamespace('switch') const switchSize = useSize$1() const isModelValue = ref(props2.modelValue !== false) const input = ref() const core2 = ref() const switchKls = computed(() => [ ns.b(), ns.m(switchSize.value), ns.is('disabled', switchDisabled.value), ns.is('checked', checked2.value), ]) watch$1( () => props2.modelValue, () => { isModelValue.value = true } ) watch$1( () => props2.value, () => { isModelValue.value = false } ) const actualValue = computed(() => { return isModelValue.value ? props2.modelValue : props2.value }) const checked2 = computed(() => actualValue.value === props2.activeValue) if ( ![props2.activeValue, props2.inactiveValue].includes(actualValue.value) ) { emit2(UPDATE_MODEL_EVENT, props2.inactiveValue) emit2(CHANGE_EVENT, props2.inactiveValue) emit2(INPUT_EVENT, props2.inactiveValue) } watch$1(checked2, () => { var _a2 input.value.checked = checked2.value if (props2.activeColor || props2.inactiveColor) { setBackgroundColor() } if (props2.validateEvent) { ;(_a2 = formItem == null ? void 0 : formItem.validate) == null ? void 0 : _a2.call(formItem, 'change').catch((err) => debugWarn()) } }) const handleChange = () => { const val2 = checked2.value ? props2.inactiveValue : props2.activeValue emit2(UPDATE_MODEL_EVENT, val2) emit2(CHANGE_EVENT, val2) emit2(INPUT_EVENT, val2) nextTick(() => { input.value.checked = checked2.value }) } const switchValue = () => { if (switchDisabled.value) return const { beforeChange } = props2 if (!beforeChange) { handleChange() return } const shouldChange = beforeChange() const isExpectType = [ isPromise$1(shouldChange), isBoolean$5(shouldChange), ].some((i2) => i2) if (!isExpectType) { throwError$1( COMPONENT_NAME$1, 'beforeChange must return type `Promise` or `boolean`' ) } if (isPromise$1(shouldChange)) { shouldChange .then((result) => { if (result) { handleChange() } }) .catch((e2) => {}) } else if (shouldChange) { handleChange() } } const setBackgroundColor = () => { const newColor = checked2.value ? props2.activeColor : props2.inactiveColor const coreEl = core2.value if (props2.borderColor) coreEl.style.borderColor = props2.borderColor else if (!props2.borderColor) coreEl.style.borderColor = newColor coreEl.style.backgroundColor = newColor coreEl.children[0].style.color = newColor } const focus2 = () => { var _a2, _b2 ;(_b2 = (_a2 = input.value) == null ? void 0 : _a2.focus) == null ? void 0 : _b2.call(_a2) } onMounted(() => { if (props2.activeColor || props2.inactiveColor || props2.borderColor) { setBackgroundColor() } input.value.checked = checked2.value }) return { ns, input, core: core2, switchDisabled, checked: checked2, switchKls, handleChange, switchValue, focus: focus2, } }, }) const _hoisted_1$6d = ['aria-checked', 'aria-disabled'] const _hoisted_2$55 = ['id', 'name', 'true-value', 'false-value', 'disabled'] const _hoisted_3$4z = ['aria-hidden'] const _hoisted_4$3Z = ['aria-hidden'] const _hoisted_5$3z = ['aria-hidden'] const _hoisted_6$3a = ['aria-hidden'] function _sfc_render$w(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_icon = resolveComponent('el-icon') const _component_loading = resolveComponent('loading') return ( openBlock(), createElementBlock( 'div', { class: normalizeClass(_ctx.switchKls), role: 'switch', 'aria-checked': _ctx.checked, 'aria-disabled': _ctx.switchDisabled, onClick: _cache[2] || (_cache[2] = withModifiers( (...args) => _ctx.switchValue && _ctx.switchValue(...args), ['prevent'] )), }, [ createElementVNode( 'input', { id: _ctx.id, ref: 'input', class: normalizeClass(_ctx.ns.e('input')), type: 'checkbox', name: _ctx.name, 'true-value': _ctx.activeValue, 'false-value': _ctx.inactiveValue, disabled: _ctx.switchDisabled, onChange: _cache[0] || (_cache[0] = (...args) => _ctx.handleChange && _ctx.handleChange(...args)), onKeydown: _cache[1] || (_cache[1] = withKeys( (...args) => _ctx.switchValue && _ctx.switchValue(...args), ['enter'] )), }, null, 42, _hoisted_2$55 ), !_ctx.inlinePrompt && (_ctx.inactiveIcon || _ctx.inactiveText) ? (openBlock(), createElementBlock( 'span', { key: 0, class: normalizeClass([ _ctx.ns.e('label'), _ctx.ns.em('label', 'left'), _ctx.ns.is('active', !_ctx.checked), ]), }, [ _ctx.inactiveIcon ? (openBlock(), createBlock( _component_el_icon, { key: 0 }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent(_ctx.inactiveIcon) )), ]), _: 1, } )) : createCommentVNode('v-if', true), !_ctx.inactiveIcon && _ctx.inactiveText ? (openBlock(), createElementBlock( 'span', { key: 1, 'aria-hidden': _ctx.checked, }, toDisplayString$1(_ctx.inactiveText), 9, _hoisted_3$4z )) : createCommentVNode('v-if', true), ], 2 )) : createCommentVNode('v-if', true), createElementVNode( 'span', { ref: 'core', class: normalizeClass(_ctx.ns.e('core')), style: normalizeStyle$1({ width: (_ctx.width || 40) + 'px' }), }, [ _ctx.inlinePrompt ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass(_ctx.ns.e('inner')), }, [ _ctx.activeIcon || _ctx.inactiveIcon ? (openBlock(), createElementBlock( Fragment, { key: 0 }, [ _ctx.activeIcon ? (openBlock(), createBlock( _component_el_icon, { key: 0, class: normalizeClass([ _ctx.ns.is('icon'), _ctx.checked ? _ctx.ns.is('show') : _ctx.ns.is('hide'), ]), }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent(_ctx.activeIcon) )), ]), _: 1, }, 8, ['class'] )) : createCommentVNode('v-if', true), _ctx.inactiveIcon ? (openBlock(), createBlock( _component_el_icon, { key: 1, class: normalizeClass([ _ctx.ns.is('icon'), !_ctx.checked ? _ctx.ns.is('show') : _ctx.ns.is('hide'), ]), }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent( _ctx.inactiveIcon ) )), ]), _: 1, }, 8, ['class'] )) : createCommentVNode('v-if', true), ], 64 )) : _ctx.activeText || _ctx.inactiveIcon ? (openBlock(), createElementBlock( Fragment, { key: 1 }, [ _ctx.activeText ? (openBlock(), createElementBlock( 'span', { key: 0, class: normalizeClass([ _ctx.ns.is('text'), _ctx.checked ? _ctx.ns.is('show') : _ctx.ns.is('hide'), ]), 'aria-hidden': !_ctx.checked, }, toDisplayString$1( _ctx.activeText.substring(0, 3) ), 11, _hoisted_4$3Z )) : createCommentVNode('v-if', true), _ctx.inactiveText ? (openBlock(), createElementBlock( 'span', { key: 1, class: normalizeClass([ _ctx.ns.is('text'), !_ctx.checked ? _ctx.ns.is('show') : _ctx.ns.is('hide'), ]), 'aria-hidden': _ctx.checked, }, toDisplayString$1( _ctx.inactiveText.substring(0, 3) ), 11, _hoisted_5$3z )) : createCommentVNode('v-if', true), ], 64 )) : createCommentVNode('v-if', true), ], 2 )) : createCommentVNode('v-if', true), createElementVNode( 'div', { class: normalizeClass(_ctx.ns.e('action')), }, [ _ctx.loading ? (openBlock(), createBlock( _component_el_icon, { key: 0, class: normalizeClass(_ctx.ns.is('loading')), }, { default: withCtx(() => [ createVNode$1(_component_loading), ]), _: 1, }, 8, ['class'] )) : createCommentVNode('v-if', true), ], 2 ), ], 6 ), !_ctx.inlinePrompt && (_ctx.activeIcon || _ctx.activeText) ? (openBlock(), createElementBlock( 'span', { key: 1, class: normalizeClass([ _ctx.ns.e('label'), _ctx.ns.em('label', 'right'), _ctx.ns.is('active', _ctx.checked), ]), }, [ _ctx.activeIcon ? (openBlock(), createBlock( _component_el_icon, { key: 0 }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent(_ctx.activeIcon) )), ]), _: 1, } )) : createCommentVNode('v-if', true), !_ctx.activeIcon && _ctx.activeText ? (openBlock(), createElementBlock( 'span', { key: 1, 'aria-hidden': !_ctx.checked, }, toDisplayString$1(_ctx.activeText), 9, _hoisted_6$3a )) : createCommentVNode('v-if', true), ], 2 )) : createCommentVNode('v-if', true), ], 10, _hoisted_1$6d ) ) } var Switch$2 = /* @__PURE__ */ _export_sfc$1(_sfc_main$7w, [ ['render', _sfc_render$w], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/switch/src/switch.vue', ], ]) const ElSwitch = withInstall(Switch$2) /*! * escape-html * Copyright(c) 2012-2013 TJ Holowaychuk * Copyright(c) 2015 Andreas Lubbe * Copyright(c) 2015 Tiancheng "Timothy" Gu * MIT Licensed */ var matchHtmlRegExp = /["'&<>]/ var escapeHtml_1 = escapeHtml$1 function escapeHtml$1(string3) { var str = '' + string3 var match2 = matchHtmlRegExp.exec(str) if (!match2) { return str } var escape2 var html2 = '' var index2 = 0 var lastIndex = 0 for (index2 = match2.index; index2 < str.length; index2++) { switch (str.charCodeAt(index2)) { case 34: escape2 = '"' break case 38: escape2 = '&' break case 39: escape2 = ''' break case 60: escape2 = '<' break case 62: escape2 = '>' break default: continue } if (lastIndex !== index2) { html2 += str.substring(lastIndex, index2) } lastIndex = index2 + 1 html2 += escape2 } return lastIndex !== index2 ? html2 + str.substring(lastIndex, index2) : html2 } const getCell = function (event) { let cell = event.target while (cell && cell.tagName.toUpperCase() !== 'HTML') { if (cell.tagName.toUpperCase() === 'TD') { return cell } cell = cell.parentNode } return null } const isObject$u = function (obj) { return obj !== null && typeof obj === 'object' } const orderBy$4 = function (array4, sortKey, reverse3, sortMethod, sortBy2) { if ( !sortKey && !sortMethod && (!sortBy2 || (Array.isArray(sortBy2) && !sortBy2.length)) ) { return array4 } if (typeof reverse3 === 'string') { reverse3 = reverse3 === 'descending' ? -1 : 1 } else { reverse3 = reverse3 && reverse3 < 0 ? -1 : 1 } const getKey2 = sortMethod ? null : function (value2, index2) { if (sortBy2) { if (!Array.isArray(sortBy2)) { sortBy2 = [sortBy2] } return sortBy2.map((by) => { if (typeof by === 'string') { return get$a(value2, by) } else { return by(value2, index2, array4) } }) } if (sortKey !== '$key') { if (isObject$u(value2) && '$value' in value2) value2 = value2.$value } return [isObject$u(value2) ? get$a(value2, sortKey) : value2] } const compare2 = function (a2, b2) { if (sortMethod) { return sortMethod(a2.value, b2.value) } for (let i2 = 0, len2 = a2.key.length; i2 < len2; i2++) { if (a2.key[i2] < b2.key[i2]) { return -1 } if (a2.key[i2] > b2.key[i2]) { return 1 } } return 0 } return array4 .map((value2, index2) => { return { value: value2, index: index2, key: getKey2 ? getKey2(value2, index2) : null, } }) .sort((a2, b2) => { let order2 = compare2(a2, b2) if (!order2) { order2 = a2.index - b2.index } return order2 * +reverse3 }) .map((item2) => item2.value) } const getColumnById = function (table, columnId) { let column = null table.columns.forEach((item2) => { if (item2.id === columnId) { column = item2 } }) return column } const getColumnByKey = function (table, columnKey2) { let column = null for (let i2 = 0; i2 < table.columns.length; i2++) { const item2 = table.columns[i2] if (item2.columnKey === columnKey2) { column = item2 break } } return column } const getColumnByCell = function (table, cell, namespace) { const matches2 = (cell.className || '').match( new RegExp(`${namespace}-table_[^\\s]+`, 'gm') ) if (matches2) { return getColumnById(table, matches2[0]) } return null } const getRowIdentity = (row, rowKey) => { if (!row) throw new Error('Row is required when get row identity') if (typeof rowKey === 'string') { if (!rowKey.includes('.')) { return `${row[rowKey]}` } const key2 = rowKey.split('.') let current2 = row for (const element of key2) { current2 = current2[element] } return `${current2}` } else if (typeof rowKey === 'function') { return rowKey.call(null, row) } } const getKeysMap = function (array4, rowKey) { const arrayMap2 = {} ;(array4 || []).forEach((row, index2) => { arrayMap2[getRowIdentity(row, rowKey)] = { row, index: index2 } }) return arrayMap2 } function mergeOptions$1(defaults2, config2) { const options2 = {} let key2 for (key2 in defaults2) { options2[key2] = defaults2[key2] } for (key2 in config2) { if (hasOwn$e(config2, key2)) { const value2 = config2[key2] if (typeof value2 !== 'undefined') { options2[key2] = value2 } } } return options2 } function parseWidth(width) { if (width === '') return width if (width !== void 0) { width = Number.parseInt(width, 10) if (Number.isNaN(width)) { width = '' } } return width } function parseMinWidth(minWidth) { if (minWidth === '') return minWidth if (minWidth !== void 0) { minWidth = parseWidth(minWidth) if (Number.isNaN(minWidth)) { minWidth = 80 } } return minWidth } function parseHeight(height) { if (typeof height === 'number') { return height } if (typeof height === 'string') { if (/^\d+(?:px)?$/.test(height)) { return Number.parseInt(height, 10) } else { return height } } return null } function compose(...funcs) { if (funcs.length === 0) { return (arg) => arg } if (funcs.length === 1) { return funcs[0] } return funcs.reduce( (a2, b2) => (...args) => a2(b2(...args)) ) } function toggleRowStatus(statusArr, row, newVal) { let changed = false const index2 = statusArr.indexOf(row) const included = index2 !== -1 const addRow = () => { statusArr.push(row) changed = true } const removeRow = () => { statusArr.splice(index2, 1) changed = true } if (typeof newVal === 'boolean') { if (newVal && !included) { addRow() } else if (!newVal && included) { removeRow() } } else { if (included) { removeRow() } else { addRow() } } return changed } function walkTreeNode( root2, cb, childrenKey = 'children', lazyKey = 'hasChildren' ) { const isNil2 = (array4) => !(Array.isArray(array4) && array4.length) function _walker(parent2, children, level) { cb(parent2, children, level) children.forEach((item2) => { if (item2[lazyKey]) { cb(item2, null, level + 1) return } const children2 = item2[childrenKey] if (!isNil2(children2)) { _walker(item2, children2, level + 1) } }) } root2.forEach((item2) => { if (item2[lazyKey]) { cb(item2, null, 0) return } const children = item2[childrenKey] if (!isNil2(children)) { _walker(item2, children, 0) } }) } let removePopper function createTablePopper( trigger2, popperContent, popperOptions2, tooltipEffect ) { const { nextZIndex: nextZIndex2 } = useZIndex() function renderContent() { const isLight = tooltipEffect === 'light' const content22 = document.createElement('div') content22.className = `el-popper ${isLight ? 'is-light' : 'is-dark'}` popperContent = escapeHtml_1(popperContent) content22.innerHTML = popperContent content22.style.zIndex = String(nextZIndex2()) document.body.appendChild(content22) return content22 } function renderArrow() { const arrow22 = document.createElement('div') arrow22.className = 'el-popper__arrow' return arrow22 } function showPopper() { popperInstance && popperInstance.update() } removePopper = function removePopper2() { try { popperInstance && popperInstance.destroy() content2 && document.body.removeChild(content2) off$1(trigger2, 'mouseenter', showPopper) off$1(trigger2, 'mouseleave', removePopper2) } catch (e2) {} } let popperInstance = null const content2 = renderContent() const arrow2 = renderArrow() content2.appendChild(arrow2) popperInstance = createPopper(trigger2, content2, { modifiers: [ { name: 'offset', options: { offset: [0, 8], }, }, { name: 'arrow', options: { element: arrow2, padding: 10, }, }, ], ...popperOptions2, }) on$2(trigger2, 'mouseenter', showPopper) on$2(trigger2, 'mouseleave', removePopper) return popperInstance } const isFixedColumn = (index2, fixed, store2, realColumns) => { let start2 = 0 let after2 = index2 if (realColumns) { if (realColumns[index2].colSpan > 1) { return {} } for (let i2 = 0; i2 < index2; i2++) { start2 += realColumns[i2].colSpan } after2 = start2 + realColumns[index2].colSpan - 1 } else { start2 = index2 } let fixedLayout const columns = store2.states.columns switch (fixed) { case 'left': if (after2 < store2.states.fixedLeafColumnsLength.value) { fixedLayout = 'left' } break case 'right': if ( start2 >= columns.value.length - store2.states.rightFixedLeafColumnsLength.value ) { fixedLayout = 'right' } break default: if (after2 < store2.states.fixedLeafColumnsLength.value) { fixedLayout = 'left' } else if ( start2 >= columns.value.length - store2.states.rightFixedLeafColumnsLength.value ) { fixedLayout = 'right' } } return fixedLayout ? { direction: fixedLayout, start: start2, after: after2, } : {} } const getFixedColumnsClass = ( namespace, index2, fixed, store2, realColumns ) => { const classes = [] const { direction: direction2, start: start2 } = isFixedColumn( index2, fixed, store2, realColumns ) if (direction2) { const isLeft = direction2 === 'left' classes.push(`${namespace}-fixed-column--${direction2}`) if (isLeft && start2 === store2.states.fixedLeafColumnsLength.value - 1) { classes.push('is-last-column') } else if ( !isLeft && start2 === store2.states.columns.value.length - store2.states.rightFixedLeafColumnsLength.value ) { classes.push('is-first-column') } } return classes } function getOffset(offset2, column) { return ( offset2 + (column.realWidth === null || Number.isNaN(column.realWidth) ? Number(column.width) : column.realWidth) ) } const getFixedColumnOffset = (index2, fixed, store2, realColumns) => { const { direction: direction2, start: start2 = 0 } = isFixedColumn( index2, fixed, store2, realColumns ) if (!direction2) { return } const styles = {} const isLeft = direction2 === 'left' const columns = store2.states.columns.value if (isLeft) { styles.left = columns.slice(0, index2).reduce(getOffset, 0) } else { styles.right = columns .slice(start2 + 1) .reverse() .reduce(getOffset, 0) } return styles } const ensurePosition = (style2, key2) => { if (!style2) return if (!Number.isNaN(style2[key2])) { style2[key2] = `${style2[key2]}px` } } function useExpand(watcherData) { const instance = getCurrentInstance() const defaultExpandAll = ref(false) const expandRows = ref([]) const updateExpandRows = () => { const data2 = watcherData.data.value || [] const rowKey = watcherData.rowKey.value if (defaultExpandAll.value) { expandRows.value = data2.slice() } else if (rowKey) { const expandRowsMap = getKeysMap(expandRows.value, rowKey) expandRows.value = data2.reduce((prev, row) => { const rowId = getRowIdentity(row, rowKey) const rowInfo = expandRowsMap[rowId] if (rowInfo) { prev.push(row) } return prev }, []) } else { expandRows.value = [] } } const toggleRowExpansion = (row, expanded) => { const changed = toggleRowStatus(expandRows.value, row, expanded) if (changed) { instance.emit('expand-change', row, expandRows.value.slice()) } } const setExpandRowKeys = (rowKeys) => { instance.store.assertRowKey() const data2 = watcherData.data.value || [] const rowKey = watcherData.rowKey.value const keysMap = getKeysMap(data2, rowKey) expandRows.value = rowKeys.reduce((prev, cur) => { const info = keysMap[cur] if (info) { prev.push(info.row) } return prev }, []) } const isRowExpanded = (row) => { const rowKey = watcherData.rowKey.value if (rowKey) { const expandMap = getKeysMap(expandRows.value, rowKey) return !!expandMap[getRowIdentity(row, rowKey)] } return expandRows.value.includes(row) } return { updateExpandRows, toggleRowExpansion, setExpandRowKeys, isRowExpanded, states: { expandRows, defaultExpandAll, }, } } function useCurrent(watcherData) { const instance = getCurrentInstance() const _currentRowKey = ref(null) const currentRow = ref(null) const setCurrentRowKey = (key2) => { instance.store.assertRowKey() _currentRowKey.value = key2 setCurrentRowByKey(key2) } const restoreCurrentRowKey = () => { _currentRowKey.value = null } const setCurrentRowByKey = (key2) => { const { data: data2, rowKey } = watcherData let _currentRow = null if (rowKey.value) { _currentRow = (unref(data2) || []).find( (item2) => getRowIdentity(item2, rowKey.value) === key2 ) } currentRow.value = _currentRow } const updateCurrentRow = (_currentRow) => { const oldCurrentRow = currentRow.value if (_currentRow && _currentRow !== oldCurrentRow) { currentRow.value = _currentRow instance.emit('current-change', currentRow.value, oldCurrentRow) return } if (!_currentRow && oldCurrentRow) { currentRow.value = null instance.emit('current-change', null, oldCurrentRow) } } const updateCurrentRowData = () => { const rowKey = watcherData.rowKey.value const data2 = watcherData.data.value || [] const oldCurrentRow = currentRow.value if (!data2.includes(oldCurrentRow) && oldCurrentRow) { if (rowKey) { const currentRowKey = getRowIdentity(oldCurrentRow, rowKey) setCurrentRowByKey(currentRowKey) } else { currentRow.value = null } if (currentRow.value === null) { instance.emit('current-change', null, oldCurrentRow) } } else if (_currentRowKey.value) { setCurrentRowByKey(_currentRowKey.value) restoreCurrentRowKey() } } return { setCurrentRowKey, restoreCurrentRowKey, setCurrentRowByKey, updateCurrentRow, updateCurrentRowData, states: { _currentRowKey, currentRow, }, } } function useTree$2(watcherData) { const expandRowKeys = ref([]) const treeData = ref({}) const indent = ref(16) const lazy = ref(false) const lazyTreeNodeMap = ref({}) const lazyColumnIdentifier = ref('hasChildren') const childrenColumnName = ref('children') const instance = getCurrentInstance() const normalizedData = computed(() => { if (!watcherData.rowKey.value) return {} const data2 = watcherData.data.value || [] return normalize2(data2) }) const normalizedLazyNode = computed(() => { const rowKey = watcherData.rowKey.value const keys3 = Object.keys(lazyTreeNodeMap.value) const res = {} if (!keys3.length) return res keys3.forEach((key2) => { if (lazyTreeNodeMap.value[key2].length) { const item2 = { children: [] } lazyTreeNodeMap.value[key2].forEach((row) => { const currentRowKey = getRowIdentity(row, rowKey) item2.children.push(currentRowKey) if (row[lazyColumnIdentifier.value] && !res[currentRowKey]) { res[currentRowKey] = { children: [] } } }) res[key2] = item2 } }) return res }) const normalize2 = (data2) => { const rowKey = watcherData.rowKey.value const res = {} walkTreeNode( data2, (parent2, children, level) => { const parentId = getRowIdentity(parent2, rowKey) if (Array.isArray(children)) { res[parentId] = { children: children.map((row) => getRowIdentity(row, rowKey)), level, } } else if (lazy.value) { res[parentId] = { children: [], lazy: true, level, } } }, childrenColumnName.value, lazyColumnIdentifier.value ) return res } const updateTreeData = ( ifChangeExpandRowKeys = false, ifExpandAll = ((_a2) => (_a2 = instance.store) == null ? void 0 : _a2.states.defaultExpandAll.value)() ) => { var _a2 const nested = normalizedData.value const normalizedLazyNode_ = normalizedLazyNode.value const keys3 = Object.keys(nested) const newTreeData = {} if (keys3.length) { const oldTreeData = unref(treeData) const rootLazyRowKeys = [] const getExpanded = (oldValue, key2) => { if (ifChangeExpandRowKeys) { if (expandRowKeys.value) { return ifExpandAll || expandRowKeys.value.includes(key2) } else { return !!( ifExpandAll || (oldValue == null ? void 0 : oldValue.expanded) ) } } else { const included = ifExpandAll || (expandRowKeys.value && expandRowKeys.value.includes(key2)) return !!((oldValue == null ? void 0 : oldValue.expanded) || included) } } keys3.forEach((key2) => { const oldValue = oldTreeData[key2] const newValue = { ...nested[key2] } newValue.expanded = getExpanded(oldValue, key2) if (newValue.lazy) { const { loaded = false, loading: loading2 = false } = oldValue || {} newValue.loaded = !!loaded newValue.loading = !!loading2 rootLazyRowKeys.push(key2) } newTreeData[key2] = newValue }) const lazyKeys = Object.keys(normalizedLazyNode_) if (lazy.value && lazyKeys.length && rootLazyRowKeys.length) { lazyKeys.forEach((key2) => { const oldValue = oldTreeData[key2] const lazyNodeChildren = normalizedLazyNode_[key2].children if (rootLazyRowKeys.includes(key2)) { if (newTreeData[key2].children.length !== 0) { throw new Error('[ElTable]children must be an empty array.') } newTreeData[key2].children = lazyNodeChildren } else { const { loaded = false, loading: loading2 = false } = oldValue || {} newTreeData[key2] = { lazy: true, loaded: !!loaded, loading: !!loading2, expanded: getExpanded(oldValue, key2), children: lazyNodeChildren, level: '', } } }) } } treeData.value = newTreeData ;(_a2 = instance.store) == null ? void 0 : _a2.updateTableScrollY() } watch$1( () => expandRowKeys.value, () => { updateTreeData(true) } ) watch$1( () => normalizedData.value, () => { updateTreeData() } ) watch$1( () => normalizedLazyNode.value, () => { updateTreeData() } ) const updateTreeExpandKeys = (value2) => { expandRowKeys.value = value2 updateTreeData() } const toggleTreeExpansion = (row, expanded) => { instance.store.assertRowKey() const rowKey = watcherData.rowKey.value const id2 = getRowIdentity(row, rowKey) const data2 = id2 && treeData.value[id2] if (id2 && data2 && 'expanded' in data2) { const oldExpanded = data2.expanded expanded = typeof expanded === 'undefined' ? !data2.expanded : expanded treeData.value[id2].expanded = expanded if (oldExpanded !== expanded) { instance.emit('expand-change', row, expanded) } instance.store.updateTableScrollY() } } const loadOrToggle = (row) => { instance.store.assertRowKey() const rowKey = watcherData.rowKey.value const id2 = getRowIdentity(row, rowKey) const data2 = treeData.value[id2] if (lazy.value && data2 && 'loaded' in data2 && !data2.loaded) { loadData2(row, id2, data2) } else { toggleTreeExpansion(row, void 0) } } const loadData2 = (row, key2, treeNode) => { const { load } = instance.props if (load && !treeData.value[key2].loaded) { treeData.value[key2].loading = true load(row, treeNode, (data2) => { if (!Array.isArray(data2)) { throw new TypeError('[ElTable] data must be an array') } treeData.value[key2].loading = false treeData.value[key2].loaded = true treeData.value[key2].expanded = true if (data2.length) { lazyTreeNodeMap.value[key2] = data2 } instance.emit('expand-change', row, true) }) } } return { loadData: loadData2, loadOrToggle, toggleTreeExpansion, updateTreeExpandKeys, updateTreeData, normalize: normalize2, states: { expandRowKeys, treeData, indent, lazy, lazyTreeNodeMap, lazyColumnIdentifier, childrenColumnName, }, } } const sortData = (data2, states) => { const sortingColumn = states.sortingColumn if (!sortingColumn || typeof sortingColumn.sortable === 'string') { return data2 } return orderBy$4( data2, states.sortProp, states.sortOrder, sortingColumn.sortMethod, sortingColumn.sortBy ) } const doFlattenColumns = (columns) => { const result = [] columns.forEach((column) => { if (column.children) { result.push.apply(result, doFlattenColumns(column.children)) } else { result.push(column) } }) return result } function useWatcher$1() { var _a2 const instance = getCurrentInstance() const { size: tableSize } = toRefs$2( (_a2 = instance.proxy) == null ? void 0 : _a2.$props ) const rowKey = ref(null) const data2 = ref([]) const _data = ref([]) const isComplex = ref(false) const _columns = ref([]) const originColumns = ref([]) const columns = ref([]) const fixedColumns = ref([]) const rightFixedColumns = ref([]) const leafColumns = ref([]) const fixedLeafColumns = ref([]) const rightFixedLeafColumns = ref([]) const leafColumnsLength = ref(0) const fixedLeafColumnsLength = ref(0) const rightFixedLeafColumnsLength = ref(0) const isAllSelected = ref(false) const selection = ref([]) const reserveSelection = ref(false) const selectOnIndeterminate = ref(false) const selectable = ref(null) const filters = ref({}) const filteredData = ref(null) const sortingColumn = ref(null) const sortProp = ref(null) const sortOrder = ref(null) const hoverRow = ref(null) watch$1(data2, () => instance.state && scheduleLayout(false), { deep: true, }) const assertRowKey = () => { if (!rowKey.value) throw new Error('[ElTable] prop row-key is required') } const updateColumns = () => { fixedColumns.value = _columns.value.filter( (column) => column.fixed === true || column.fixed === 'left' ) rightFixedColumns.value = _columns.value.filter( (column) => column.fixed === 'right' ) if ( fixedColumns.value.length > 0 && _columns.value[0] && _columns.value[0].type === 'selection' && !_columns.value[0].fixed ) { _columns.value[0].fixed = true fixedColumns.value.unshift(_columns.value[0]) } const notFixedColumns = _columns.value.filter((column) => !column.fixed) originColumns.value = [] .concat(fixedColumns.value) .concat(notFixedColumns) .concat(rightFixedColumns.value) const leafColumns2 = doFlattenColumns(notFixedColumns) const fixedLeafColumns2 = doFlattenColumns(fixedColumns.value) const rightFixedLeafColumns2 = doFlattenColumns(rightFixedColumns.value) leafColumnsLength.value = leafColumns2.length fixedLeafColumnsLength.value = fixedLeafColumns2.length rightFixedLeafColumnsLength.value = rightFixedLeafColumns2.length columns.value = [] .concat(fixedLeafColumns2) .concat(leafColumns2) .concat(rightFixedLeafColumns2) isComplex.value = fixedColumns.value.length > 0 || rightFixedColumns.value.length > 0 } const scheduleLayout = (needUpdateColumns, immediate = false) => { if (needUpdateColumns) { updateColumns() } if (immediate) { instance.state.doLayout() } else { instance.state.debouncedUpdateLayout() } } const isSelected = (row) => { return selection.value.includes(row) } const clearSelection = () => { isAllSelected.value = false const oldSelection = selection.value if (oldSelection.length) { selection.value = [] instance.emit('selection-change', []) } } const cleanSelection = () => { let deleted if (rowKey.value) { deleted = [] const selectedMap = getKeysMap(selection.value, rowKey.value) const dataMap = getKeysMap(data2.value, rowKey.value) for (const key2 in selectedMap) { if (hasOwn$e(selectedMap, key2) && !dataMap[key2]) { deleted.push(selectedMap[key2].row) } } } else { deleted = selection.value.filter((item2) => !data2.value.includes(item2)) } if (deleted.length) { const newSelection = selection.value.filter( (item2) => !deleted.includes(item2) ) selection.value = newSelection instance.emit('selection-change', newSelection.slice()) } } const getSelectionRows = () => { return (selection.value || []).slice() } const toggleRowSelection = (row, selected = void 0, emitChange = true) => { const changed = toggleRowStatus(selection.value, row, selected) if (changed) { const newSelection = (selection.value || []).slice() if (emitChange) { instance.emit('select', newSelection, row) } instance.emit('selection-change', newSelection) } } const _toggleAllSelection = () => { var _a22, _b2 const value2 = selectOnIndeterminate.value ? !isAllSelected.value : !(isAllSelected.value || selection.value.length) isAllSelected.value = value2 let selectionChanged = false let childrenCount = 0 const rowKey2 = (_b2 = (_a22 = instance == null ? void 0 : instance.store) == null ? void 0 : _a22.states) == null ? void 0 : _b2.rowKey.value data2.value.forEach((row, index2) => { const rowIndex = index2 + childrenCount if (selectable.value) { if ( selectable.value.call(null, row, rowIndex) && toggleRowStatus(selection.value, row, value2) ) { selectionChanged = true } } else { if (toggleRowStatus(selection.value, row, value2)) { selectionChanged = true } } childrenCount += getChildrenCount(getRowIdentity(row, rowKey2)) }) if (selectionChanged) { instance.emit( 'selection-change', selection.value ? selection.value.slice() : [] ) } instance.emit('select-all', selection.value) } const updateSelectionByRowKey = () => { const selectedMap = getKeysMap(selection.value, rowKey.value) data2.value.forEach((row) => { const rowId = getRowIdentity(row, rowKey.value) const rowInfo = selectedMap[rowId] if (rowInfo) { selection.value[rowInfo.index] = row } }) } const updateAllSelected = () => { var _a22, _b2, _c2 if (((_a22 = data2.value) == null ? void 0 : _a22.length) === 0) { isAllSelected.value = false return } let selectedMap if (rowKey.value) { selectedMap = getKeysMap(selection.value, rowKey.value) } const isSelected2 = function (row) { if (selectedMap) { return !!selectedMap[getRowIdentity(row, rowKey.value)] } else { return selection.value.includes(row) } } let isAllSelected_ = true let selectedCount = 0 let childrenCount = 0 for (let i2 = 0, j2 = (data2.value || []).length; i2 < j2; i2++) { const keyProp = (_c2 = (_b2 = instance == null ? void 0 : instance.store) == null ? void 0 : _b2.states) == null ? void 0 : _c2.rowKey.value const rowIndex = i2 + childrenCount const item2 = data2.value[i2] const isRowSelectable = selectable.value && selectable.value.call(null, item2, rowIndex) if (!isSelected2(item2)) { if (!selectable.value || isRowSelectable) { isAllSelected_ = false break } } else { selectedCount++ } childrenCount += getChildrenCount(getRowIdentity(item2, keyProp)) } if (selectedCount === 0) isAllSelected_ = false isAllSelected.value = isAllSelected_ } const getChildrenCount = (rowKey2) => { var _a22 if (!instance || !instance.store) return 0 const { treeData } = instance.store.states let count2 = 0 const children = (_a22 = treeData.value[rowKey2]) == null ? void 0 : _a22.children if (children) { count2 += children.length children.forEach((childKey) => { count2 += getChildrenCount(childKey) }) } return count2 } const updateFilters = (columns2, values2) => { if (!Array.isArray(columns2)) { columns2 = [columns2] } const filters_ = {} columns2.forEach((col) => { filters.value[col.id] = values2 filters_[col.columnKey || col.id] = values2 }) return filters_ } const updateSort = (column, prop, order2) => { if (sortingColumn.value && sortingColumn.value !== column) { sortingColumn.value.order = null } sortingColumn.value = column sortProp.value = prop sortOrder.value = order2 } const execFilter = () => { let sourceData = unref(_data) Object.keys(filters.value).forEach((columnId) => { const values2 = filters.value[columnId] if (!values2 || values2.length === 0) return const column = getColumnById( { columns: columns.value, }, columnId ) if (column && column.filterMethod) { sourceData = sourceData.filter((row) => { return values2.some((value2) => column.filterMethod.call(null, value2, row, column) ) }) } }) filteredData.value = sourceData } const execSort = () => { data2.value = sortData(filteredData.value, { sortingColumn: sortingColumn.value, sortProp: sortProp.value, sortOrder: sortOrder.value, }) } const execQuery = (ignore = void 0) => { if (!(ignore && ignore.filter)) { execFilter() } execSort() } const clearFilter = (columnKeys) => { const { tableHeaderRef } = instance.refs if (!tableHeaderRef) return const panels = Object.assign({}, tableHeaderRef.filterPanels) const keys3 = Object.keys(panels) if (!keys3.length) return if (typeof columnKeys === 'string') { columnKeys = [columnKeys] } if (Array.isArray(columnKeys)) { const columns_ = columnKeys.map((key2) => getColumnByKey( { columns: columns.value, }, key2 ) ) keys3.forEach((key2) => { const column = columns_.find((col) => col.id === key2) if (column) { column.filteredValue = [] } }) instance.store.commit('filterChange', { column: columns_, values: [], silent: true, multi: true, }) } else { keys3.forEach((key2) => { const column = columns.value.find((col) => col.id === key2) if (column) { column.filteredValue = [] } }) filters.value = {} instance.store.commit('filterChange', { column: {}, values: [], silent: true, }) } } const clearSort = () => { if (!sortingColumn.value) return updateSort(null, null, null) instance.store.commit('changeSortCondition', { silent: true, }) } const { setExpandRowKeys, toggleRowExpansion, updateExpandRows, states: expandStates, isRowExpanded, } = useExpand({ data: data2, rowKey, }) const { updateTreeExpandKeys, toggleTreeExpansion, updateTreeData, loadOrToggle, states: treeStates, } = useTree$2({ data: data2, rowKey, }) const { updateCurrentRowData, updateCurrentRow, setCurrentRowKey, states: currentData, } = useCurrent({ data: data2, rowKey, }) const setExpandRowKeysAdapter = (val2) => { setExpandRowKeys(val2) updateTreeExpandKeys(val2) } const toggleRowExpansionAdapter = (row, expanded) => { const hasExpandColumn = columns.value.some( ({ type: type4 }) => type4 === 'expand' ) if (hasExpandColumn) { toggleRowExpansion(row, expanded) } else { toggleTreeExpansion(row, expanded) } } return { assertRowKey, updateColumns, scheduleLayout, isSelected, clearSelection, cleanSelection, getSelectionRows, toggleRowSelection, _toggleAllSelection, toggleAllSelection: null, updateSelectionByRowKey, updateAllSelected, updateFilters, updateCurrentRow, updateSort, execFilter, execSort, execQuery, clearFilter, clearSort, toggleRowExpansion, setExpandRowKeysAdapter, setCurrentRowKey, toggleRowExpansionAdapter, isRowExpanded, updateExpandRows, updateCurrentRowData, loadOrToggle, updateTreeData, states: { tableSize, rowKey, data: data2, _data, isComplex, _columns, originColumns, columns, fixedColumns, rightFixedColumns, leafColumns, fixedLeafColumns, rightFixedLeafColumns, leafColumnsLength, fixedLeafColumnsLength, rightFixedLeafColumnsLength, isAllSelected, selection, reserveSelection, selectOnIndeterminate, selectable, filters, filteredData, sortingColumn, sortProp, sortOrder, hoverRow, ...expandStates, ...treeStates, ...currentData, }, } } function replaceColumn(array4, column) { return array4.map((item2) => { var _a2 if (item2.id === column.id) { return column } else if ((_a2 = item2.children) == null ? void 0 : _a2.length) { item2.children = replaceColumn(item2.children, column) } return item2 }) } function sortColumn(array4) { array4.forEach((item2) => { var _a2, _b2 item2.no = (_a2 = item2.getColumnIndex) == null ? void 0 : _a2.call(item2) if ((_b2 = item2.children) == null ? void 0 : _b2.length) { sortColumn(item2.children) } }) array4.sort((cur, pre) => cur.no - pre.no) } function useStore$1() { const instance = getCurrentInstance() const watcher = useWatcher$1() const ns = useNamespace('table') const mutations = { setData(states, data2) { const dataInstanceChanged = unref(states._data) !== data2 states.data.value = data2 states._data.value = data2 instance.store.execQuery() instance.store.updateCurrentRowData() instance.store.updateExpandRows() instance.store.updateTreeData( instance.store.states.defaultExpandAll.value ) if (unref(states.reserveSelection)) { instance.store.assertRowKey() instance.store.updateSelectionByRowKey() } else { if (dataInstanceChanged) { instance.store.clearSelection() } else { instance.store.cleanSelection() } } instance.store.updateAllSelected() if (instance.$ready) { instance.store.scheduleLayout() } }, insertColumn(states, column, parent2) { const array4 = unref(states._columns) let newColumns = [] if (!parent2) { array4.push(column) newColumns = array4 } else { if (parent2 && !parent2.children) { parent2.children = [] } parent2.children.push(column) newColumns = replaceColumn(array4, parent2) } sortColumn(newColumns) states._columns.value = newColumns if (column.type === 'selection') { states.selectable.value = column.selectable states.reserveSelection.value = column.reserveSelection } if (instance.$ready) { instance.store.updateColumns() instance.store.scheduleLayout() } }, removeColumn(states, column, parent2) { const array4 = unref(states._columns) || [] if (parent2) { parent2.children.splice( parent2.children.findIndex((item2) => item2.id === column.id), 1 ) if (parent2.children.length === 0) { delete parent2.children } states._columns.value = replaceColumn(array4, parent2) } else { const index2 = array4.indexOf(column) if (index2 > -1) { array4.splice(index2, 1) states._columns.value = array4 } } if (instance.$ready) { instance.store.updateColumns() instance.store.scheduleLayout() } }, sort(states, options2) { const { prop, order: order2, init: init2 } = options2 if (prop) { const column = unref(states.columns).find( (column2) => column2.property === prop ) if (column) { column.order = order2 instance.store.updateSort(column, prop, order2) instance.store.commit('changeSortCondition', { init: init2 }) } } }, changeSortCondition(states, options2) { const { sortingColumn: column, sortProp: prop, sortOrder: order2, } = states if (unref(order2) === null) { states.sortingColumn.value = null states.sortProp.value = null } const ingore = { filter: true } instance.store.execQuery(ingore) if (!options2 || !(options2.silent || options2.init)) { instance.emit('sort-change', { column: unref(column), prop: unref(prop), order: unref(order2), }) } instance.store.updateTableScrollY() }, filterChange(_states, options2) { const { column, values: values2, silent } = options2 const newFilters = instance.store.updateFilters(column, values2) instance.store.execQuery() if (!silent) { instance.emit('filter-change', newFilters) } instance.store.updateTableScrollY() }, toggleAllSelection() { instance.store.toggleAllSelection() }, rowSelectedChanged(_states, row) { instance.store.toggleRowSelection(row) instance.store.updateAllSelected() }, setHoverRow(states, row) { states.hoverRow.value = row }, setCurrentRow(_states, row) { instance.store.updateCurrentRow(row) }, } const commit2 = function (name2, ...args) { const mutations2 = instance.store.mutations if (mutations2[name2]) { mutations2[name2].apply(instance, [instance.store.states].concat(args)) } else { throw new Error(`Action not found: ${name2}`) } } const updateTableScrollY = function () { nextTick(() => instance.layout.updateScrollY.apply(instance.layout)) } return { ns, ...watcher, mutations, commit: commit2, updateTableScrollY, } } const InitialStateMap = { rowKey: 'rowKey', defaultExpandAll: 'defaultExpandAll', selectOnIndeterminate: 'selectOnIndeterminate', indent: 'indent', lazy: 'lazy', data: 'data', ['treeProps.hasChildren']: { key: 'lazyColumnIdentifier', default: 'hasChildren', }, ['treeProps.children']: { key: 'childrenColumnName', default: 'children', }, } function createStore$1(table, props2) { if (!table) { throw new Error('Table is required.') } const store2 = useStore$1() store2.toggleAllSelection = debounce$3(store2._toggleAllSelection, 10) Object.keys(InitialStateMap).forEach((key2) => { handleValue(getArrKeysValue(props2, key2), key2, store2) }) proxyTableProps(store2, props2) return store2 } function proxyTableProps(store2, props2) { Object.keys(InitialStateMap).forEach((key2) => { watch$1( () => getArrKeysValue(props2, key2), (value2) => { handleValue(value2, key2, store2) } ) }) } function handleValue(value2, propsKey, store2) { let newVal = value2 let storeKey2 = InitialStateMap[propsKey] if (typeof InitialStateMap[propsKey] === 'object') { storeKey2 = storeKey2.key newVal = newVal || InitialStateMap[propsKey].default } store2.states[storeKey2].value = newVal } function getArrKeysValue(props2, keys3) { if (keys3.includes('.')) { const keyList = keys3.split('.') let value2 = props2 keyList.forEach((key2) => { value2 = value2[key2] }) return value2 } else { return props2[keys3] } } class TableLayout { constructor(options2) { this.observers = [] this.table = null this.store = null this.columns = [] this.fit = true this.showHeader = true this.height = ref(null) this.scrollX = ref(false) this.scrollY = ref(false) this.bodyWidth = ref(null) this.fixedWidth = ref(null) this.rightFixedWidth = ref(null) this.tableHeight = ref(null) this.headerHeight = ref(44) this.appendHeight = ref(0) this.footerHeight = ref(44) this.viewportHeight = ref(null) this.bodyHeight = ref(null) this.bodyScrollHeight = ref(0) this.fixedBodyHeight = ref(null) this.gutterWidth = 0 for (const name2 in options2) { if (hasOwn$e(options2, name2)) { if (isRef(this[name2])) { this[name2].value = options2[name2] } else { this[name2] = options2[name2] } } } if (!this.table) { throw new Error('Table is required for Table Layout') } if (!this.store) { throw new Error('Store is required for Table Layout') } } updateScrollY() { const height = this.height.value if (height === null) return false const bodyWrapper = this.table.refs.bodyWrapper if (this.table.vnode.el && bodyWrapper) { let scrollY = true const prevScrollY = this.scrollY.value if (this.bodyHeight.value === null) { scrollY = false } else { scrollY = bodyWrapper.scrollHeight > this.bodyHeight.value } this.scrollY.value = scrollY return prevScrollY !== scrollY } return false } setHeight(value2, prop = 'height') { if (!isClient$1) return const el2 = this.table.vnode.el value2 = parseHeight(value2) this.height.value = Number(value2) if (!el2 && (value2 || value2 === 0)) return nextTick(() => this.setHeight(value2, prop)) if (typeof value2 === 'number') { el2.style[prop] = `${value2}px` this.updateElsHeight() } else if (typeof value2 === 'string') { el2.style[prop] = value2 this.updateElsHeight() } } setMaxHeight(value2) { this.setHeight(value2, 'max-height') } getFlattenColumns() { const flattenColumns = [] const columns = this.table.store.states.columns.value columns.forEach((column) => { if (column.isColumnGroup) { flattenColumns.push.apply(flattenColumns, column.columns) } else { flattenColumns.push(column) } }) return flattenColumns } updateElsHeight() { var _a2, _b2 if (!this.table.$ready) return nextTick(() => this.updateElsHeight()) const { tableWrapper, headerWrapper, appendWrapper, footerWrapper, tableHeader, tableBody, } = this.table.refs if (tableWrapper && tableWrapper.style.display === 'none') { return } const { tableLayout } = this.table.props this.appendHeight.value = appendWrapper ? appendWrapper.offsetHeight : 0 if (this.showHeader && !headerWrapper && tableLayout === 'fixed') { return } const headerTrElm = tableHeader ? tableHeader : null const noneHeader = this.headerDisplayNone(headerTrElm) const headerWrapperOffsetHeight = (headerWrapper == null ? void 0 : headerWrapper.offsetHeight) || 0 const headerHeight = (this.headerHeight.value = !this.showHeader ? 0 : headerWrapperOffsetHeight) if ( this.showHeader && !noneHeader && headerWrapperOffsetHeight > 0 && (this.table.store.states.columns.value || []).length > 0 && headerHeight < 2 ) { return nextTick(() => this.updateElsHeight()) } const tableHeight = (this.tableHeight.value = (_b2 = (_a2 = this.table) == null ? void 0 : _a2.vnode.el) == null ? void 0 : _b2.clientHeight) const footerHeight = (this.footerHeight.value = footerWrapper ? footerWrapper.offsetHeight : 0) if (this.height.value !== null) { if (this.bodyHeight.value === null) { requestAnimationFrame(() => this.updateElsHeight()) } this.bodyHeight.value = tableHeight - headerHeight - footerHeight + (footerWrapper ? 1 : 0) this.bodyScrollHeight.value = tableBody == null ? void 0 : tableBody.scrollHeight } this.fixedBodyHeight.value = this.scrollX.value ? this.bodyHeight.value - this.gutterWidth : this.bodyHeight.value this.viewportHeight.value = this.scrollX.value ? tableHeight - this.gutterWidth : tableHeight this.updateScrollY() this.notifyObservers('scrollable') } headerDisplayNone(elm) { if (!elm) return true let headerChild = elm while (headerChild.tagName !== 'DIV') { if (getComputedStyle(headerChild).display === 'none') { return true } headerChild = headerChild.parentElement } return false } updateColumnsWidth() { if (!isClient$1) return const fit = this.fit const bodyWidth = this.table.vnode.el.clientWidth let bodyMinWidth = 0 const flattenColumns = this.getFlattenColumns() const flexColumns = flattenColumns.filter( (column) => typeof column.width !== 'number' ) flattenColumns.forEach((column) => { if (typeof column.width === 'number' && column.realWidth) column.realWidth = null }) if (flexColumns.length > 0 && fit) { flattenColumns.forEach((column) => { bodyMinWidth += Number(column.width || column.minWidth || 80) }) if (bodyMinWidth <= bodyWidth) { this.scrollX.value = false const totalFlexWidth = bodyWidth - bodyMinWidth if (flexColumns.length === 1) { flexColumns[0].realWidth = Number(flexColumns[0].minWidth || 80) + totalFlexWidth } else { const allColumnsWidth = flexColumns.reduce( (prev, column) => prev + Number(column.minWidth || 80), 0 ) const flexWidthPerPixel = totalFlexWidth / allColumnsWidth let noneFirstWidth = 0 flexColumns.forEach((column, index2) => { if (index2 === 0) return const flexWidth = Math.floor( Number(column.minWidth || 80) * flexWidthPerPixel ) noneFirstWidth += flexWidth column.realWidth = Number(column.minWidth || 80) + flexWidth }) flexColumns[0].realWidth = Number(flexColumns[0].minWidth || 80) + totalFlexWidth - noneFirstWidth } } else { this.scrollX.value = true flexColumns.forEach((column) => { column.realWidth = Number(column.minWidth) }) } this.bodyWidth.value = Math.max(bodyMinWidth, bodyWidth) this.table.state.resizeState.value.width = this.bodyWidth.value } else { flattenColumns.forEach((column) => { if (!column.width && !column.minWidth) { column.realWidth = 80 } else { column.realWidth = Number(column.width || column.minWidth) } bodyMinWidth += column.realWidth }) this.scrollX.value = bodyMinWidth > bodyWidth this.bodyWidth.value = bodyMinWidth } const fixedColumns = this.store.states.fixedColumns.value if (fixedColumns.length > 0) { let fixedWidth = 0 fixedColumns.forEach((column) => { fixedWidth += Number(column.realWidth || column.width) }) this.fixedWidth.value = fixedWidth } const rightFixedColumns = this.store.states.rightFixedColumns.value if (rightFixedColumns.length > 0) { let rightFixedWidth = 0 rightFixedColumns.forEach((column) => { rightFixedWidth += Number(column.realWidth || column.width) }) this.rightFixedWidth.value = rightFixedWidth } this.notifyObservers('columns') } addObserver(observer) { this.observers.push(observer) } removeObserver(observer) { const index2 = this.observers.indexOf(observer) if (index2 !== -1) { this.observers.splice(index2, 1) } } notifyObservers(event) { const observers = this.observers observers.forEach((observer) => { var _a2, _b2 switch (event) { case 'columns': ;(_a2 = observer.state) == null ? void 0 : _a2.onColumnsChange(this) break case 'scrollable': ;(_b2 = observer.state) == null ? void 0 : _b2.onScrollableChange(this) break default: throw new Error(`Table Layout don't have event ${event}.`) } }) } } const { CheckboxGroup: ElCheckboxGroup } = ElCheckbox const _sfc_main$7v = defineComponent({ name: 'ElTableFilterPanel', components: { ElCheckbox, ElCheckboxGroup, ElScrollbar, ElTooltip, ElIcon, ArrowDown: arrowDown, ArrowUp: arrowUp, }, directives: { ClickOutside }, props: { placement: { type: String, default: 'bottom-start', }, store: { type: Object, }, column: { type: Object, }, upDataColumn: { type: Function, }, }, setup(props2) { const instance = getCurrentInstance() const { t: t3 } = useLocale() const ns = useNamespace('table-filter') const parent2 = instance == null ? void 0 : instance.parent if (!parent2.filterPanels.value[props2.column.id]) { parent2.filterPanels.value[props2.column.id] = instance } const tooltipVisible = ref(false) const tooltip = ref(null) const filters = computed(() => { return props2.column && props2.column.filters }) const filterValue = computed({ get: () => { var _a2 return (((_a2 = props2.column) == null ? void 0 : _a2.filteredValue) || [])[0] }, set: (value2) => { if (filteredValue.value) { if (typeof value2 !== 'undefined' && value2 !== null) { filteredValue.value.splice(0, 1, value2) } else { filteredValue.value.splice(0, 1) } } }, }) const filteredValue = computed({ get() { if (props2.column) { return props2.column.filteredValue || [] } return [] }, set(value2) { if (props2.column) { props2.upDataColumn('filteredValue', value2) } }, }) const multiple = computed(() => { if (props2.column) { return props2.column.filterMultiple } return true }) const isActive = (filter2) => { return filter2.value === filterValue.value } const hidden = () => { tooltipVisible.value = false } const showFilterPanel = (e2) => { e2.stopPropagation() tooltipVisible.value = !tooltipVisible.value } const hideFilterPanel = () => { tooltipVisible.value = false } const handleConfirm = () => { confirmFilter(filteredValue.value) hidden() } const handleReset = () => { filteredValue.value = [] confirmFilter(filteredValue.value) hidden() } const handleSelect = (_filterValue) => { filterValue.value = _filterValue if (typeof _filterValue !== 'undefined' && _filterValue !== null) { confirmFilter(filteredValue.value) } else { confirmFilter([]) } hidden() } const confirmFilter = (filteredValue2) => { props2.store.commit('filterChange', { column: props2.column, values: filteredValue2, }) props2.store.updateAllSelected() } watch$1( tooltipVisible, (value2) => { if (props2.column) { props2.upDataColumn('filterOpened', value2) } }, { immediate: true, } ) const popperPaneRef = computed(() => { var _a2, _b2 return (_b2 = (_a2 = tooltip.value) == null ? void 0 : _a2.popperRef) == null ? void 0 : _b2.contentRef }) return { tooltipVisible, multiple, filteredValue, filterValue, filters, handleConfirm, handleReset, handleSelect, isActive, t: t3, ns, showFilterPanel, hideFilterPanel, popperPaneRef, tooltip, } }, }) const _hoisted_1$6c = { key: 0 } const _hoisted_2$54 = ['disabled'] const _hoisted_3$4y = ['label', 'onClick'] function _sfc_render$v(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_checkbox = resolveComponent('el-checkbox') const _component_el_checkbox_group = resolveComponent('el-checkbox-group') const _component_el_scrollbar = resolveComponent('el-scrollbar') const _component_arrow_up = resolveComponent('arrow-up') const _component_arrow_down = resolveComponent('arrow-down') const _component_el_icon = resolveComponent('el-icon') const _component_el_tooltip = resolveComponent('el-tooltip') const _directive_click_outside = resolveDirective('click-outside') return ( openBlock(), createBlock( _component_el_tooltip, { ref: 'tooltip', visible: _ctx.tooltipVisible, 'onUpdate:visible': _cache[5] || (_cache[5] = ($event) => (_ctx.tooltipVisible = $event)), offset: 0, placement: _ctx.placement, 'show-arrow': false, 'stop-popper-mouse-event': false, 'append-to-body': '', effect: 'light', pure: '', 'popper-class': _ctx.ns.b(), persistent: '', }, { content: withCtx(() => [ _ctx.multiple ? (openBlock(), createElementBlock('div', _hoisted_1$6c, [ createElementVNode( 'div', { class: normalizeClass(_ctx.ns.e('content')), }, [ createVNode$1( _component_el_scrollbar, { 'wrap-class': _ctx.ns.e('wrap'), }, { default: withCtx(() => [ createVNode$1( _component_el_checkbox_group, { modelValue: _ctx.filteredValue, 'onUpdate:modelValue': _cache[0] || (_cache[0] = ($event) => (_ctx.filteredValue = $event)), class: normalizeClass( _ctx.ns.e('checkbox-group') ), }, { default: withCtx(() => [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.filters, (filter2) => { return ( openBlock(), createBlock( _component_el_checkbox, { key: filter2.value, label: filter2.value, }, { default: withCtx(() => [ createTextVNode( toDisplayString$1(filter2.text), 1 ), ]), _: 2, }, 1032, ['label'] ) ) }), 128 )), ]), _: 1, }, 8, ['modelValue', 'class'] ), ]), _: 1, }, 8, ['wrap-class'] ), ], 2 ), createElementVNode( 'div', { class: normalizeClass(_ctx.ns.e('bottom')), }, [ createElementVNode( 'button', { class: normalizeClass({ [_ctx.ns.is('disabled')]: _ctx.filteredValue.length === 0, }), disabled: _ctx.filteredValue.length === 0, type: 'button', onClick: _cache[1] || (_cache[1] = (...args) => _ctx.handleConfirm && _ctx.handleConfirm(...args)), }, toDisplayString$1(_ctx.t('el.table.confirmFilter')), 11, _hoisted_2$54 ), createElementVNode( 'button', { type: 'button', onClick: _cache[2] || (_cache[2] = (...args) => _ctx.handleReset && _ctx.handleReset(...args)), }, toDisplayString$1(_ctx.t('el.table.resetFilter')), 1 ), ], 2 ), ])) : (openBlock(), createElementBlock( 'ul', { key: 1, class: normalizeClass(_ctx.ns.e('list')), }, [ createElementVNode( 'li', { class: normalizeClass([ _ctx.ns.e('list-item'), { [_ctx.ns.is('active')]: _ctx.filterValue === void 0 || _ctx.filterValue === null, }, ]), onClick: _cache[3] || (_cache[3] = ($event) => _ctx.handleSelect(null)), }, toDisplayString$1(_ctx.t('el.table.clearFilter')), 3 ), (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.filters, (filter2) => { return ( openBlock(), createElementBlock( 'li', { key: filter2.value, class: normalizeClass([ _ctx.ns.e('list-item'), _ctx.ns.is('active', _ctx.isActive(filter2)), ]), label: filter2.value, onClick: ($event) => _ctx.handleSelect(filter2.value), }, toDisplayString$1(filter2.text), 11, _hoisted_3$4y ) ) }), 128 )), ], 2 )), ]), default: withCtx(() => [ withDirectives( (openBlock(), createElementBlock( 'span', { class: normalizeClass([ `${_ctx.ns.namespace.value}-table__column-filter-trigger`, `${_ctx.ns.namespace.value}-none-outline`, ]), onClick: _cache[4] || (_cache[4] = (...args) => _ctx.showFilterPanel && _ctx.showFilterPanel(...args)), }, [ createVNode$1(_component_el_icon, null, { default: withCtx(() => [ _ctx.column.filterOpened ? (openBlock(), createBlock(_component_arrow_up, { key: 0 })) : (openBlock(), createBlock(_component_arrow_down, { key: 1 })), ]), _: 1, }), ], 2 )), [ [ _directive_click_outside, _ctx.hideFilterPanel, _ctx.popperPaneRef, ], ] ), ]), _: 1, }, 8, ['visible', 'placement', 'popper-class'] ) ) } var FilterPanel = /* @__PURE__ */ _export_sfc$1(_sfc_main$7v, [ ['render', _sfc_render$v], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/table/src/filter-panel.vue', ], ]) function useLayoutObserver(root2) { const instance = getCurrentInstance() onBeforeMount(() => { tableLayout.value.addObserver(instance) }) onMounted(() => { onColumnsChange(tableLayout.value) onScrollableChange(tableLayout.value) }) onUpdated(() => { onColumnsChange(tableLayout.value) onScrollableChange(tableLayout.value) }) onUnmounted(() => { tableLayout.value.removeObserver(instance) }) const tableLayout = computed(() => { const layout2 = root2.layout if (!layout2) { throw new Error('Can not find table layout.') } return layout2 }) const onColumnsChange = (layout2) => { var _a2 const cols = ((_a2 = root2.vnode.el) == null ? void 0 : _a2.querySelectorAll('colgroup > col')) || [] if (!cols.length) return const flattenColumns = layout2.getFlattenColumns() const columnsMap = {} flattenColumns.forEach((column) => { columnsMap[column.id] = column }) for (let i2 = 0, j2 = cols.length; i2 < j2; i2++) { const col = cols[i2] const name2 = col.getAttribute('name') const column = columnsMap[name2] if (column) { col.setAttribute('width', column.realWidth || column.width) } } } const onScrollableChange = (layout2) => { var _a2, _b2 const cols = ((_a2 = root2.vnode.el) == null ? void 0 : _a2.querySelectorAll('colgroup > col[name=gutter]')) || [] for (let i2 = 0, j2 = cols.length; i2 < j2; i2++) { const col = cols[i2] col.setAttribute( 'width', layout2.scrollY.value ? layout2.gutterWidth : '0' ) } const ths = ((_b2 = root2.vnode.el) == null ? void 0 : _b2.querySelectorAll('th.gutter')) || [] for (let i2 = 0, j2 = ths.length; i2 < j2; i2++) { const th2 = ths[i2] th2.style.width = layout2.scrollY.value ? `${layout2.gutterWidth}px` : '0' th2.style.display = layout2.scrollY.value ? '' : 'none' } } return { tableLayout: tableLayout.value, onColumnsChange, onScrollableChange, } } const TABLE_INJECTION_KEY = Symbol('ElTable') function useEvent(props2, emit2) { const instance = getCurrentInstance() const parent2 = inject(TABLE_INJECTION_KEY) const handleFilterClick = (event) => { event.stopPropagation() return } const handleHeaderClick = (event, column) => { if (!column.filters && column.sortable) { handleSortClick(event, column, false) } else if (column.filterable && !column.sortable) { handleFilterClick(event) } parent2 == null ? void 0 : parent2.emit('header-click', column, event) } const handleHeaderContextMenu = (event, column) => { parent2 == null ? void 0 : parent2.emit('header-contextmenu', column, event) } const draggingColumn = ref(null) const dragging = ref(false) const dragState = ref({}) const handleMouseDown = (event, column) => { if (!isClient$1) return if (column.children && column.children.length > 0) return if (draggingColumn.value && props2.border) { dragging.value = true const table = parent2 emit2('set-drag-visible', true) const tableEl = table == null ? void 0 : table.vnode.el const tableLeft = tableEl.getBoundingClientRect().left const columnEl = instance.vnode.el.querySelector(`th.${column.id}`) const columnRect = columnEl.getBoundingClientRect() const minLeft = columnRect.left - tableLeft + 30 addClass$1(columnEl, 'noclick') dragState.value = { startMouseLeft: event.clientX, startLeft: columnRect.right - tableLeft, startColumnLeft: columnRect.left - tableLeft, tableLeft, } const resizeProxy = table == null ? void 0 : table.refs.resizeProxy resizeProxy.style.left = `${dragState.value.startLeft}px` document.onselectstart = function () { return false } document.ondragstart = function () { return false } const handleMouseMove2 = (event2) => { const deltaLeft = event2.clientX - dragState.value.startMouseLeft const proxyLeft = dragState.value.startLeft + deltaLeft resizeProxy.style.left = `${Math.max(minLeft, proxyLeft)}px` } const handleMouseUp = () => { if (dragging.value) { const { startColumnLeft, startLeft } = dragState.value const finalLeft = Number.parseInt(resizeProxy.style.left, 10) const columnWidth = finalLeft - startColumnLeft column.width = column.realWidth = columnWidth table == null ? void 0 : table.emit( 'header-dragend', column.width, startLeft - startColumnLeft, column, event ) requestAnimationFrame(() => { props2.store.scheduleLayout(false, true) }) document.body.style.cursor = '' dragging.value = false draggingColumn.value = null dragState.value = {} emit2('set-drag-visible', false) } document.removeEventListener('mousemove', handleMouseMove2) document.removeEventListener('mouseup', handleMouseUp) document.onselectstart = null document.ondragstart = null setTimeout(() => { removeClass$1(columnEl, 'noclick') }, 0) } document.addEventListener('mousemove', handleMouseMove2) document.addEventListener('mouseup', handleMouseUp) } } const handleMouseMove = (event, column) => { if (column.children && column.children.length > 0) return let target2 = event.target while (target2 && target2.tagName !== 'TH') { target2 = target2.parentNode } if (!column || !column.resizable) return if (!dragging.value && props2.border) { const rect = target2.getBoundingClientRect() const bodyStyle = document.body.style if (rect.width > 12 && rect.right - event.pageX < 8) { bodyStyle.cursor = 'col-resize' if (hasClass$1(target2, 'is-sortable')) { target2.style.cursor = 'col-resize' } draggingColumn.value = column } else if (!dragging.value) { bodyStyle.cursor = '' if (hasClass$1(target2, 'is-sortable')) { target2.style.cursor = 'pointer' } draggingColumn.value = null } } } const handleMouseOut = () => { if (!isClient$1) return document.body.style.cursor = '' } const toggleOrder = ({ order: order2, sortOrders }) => { if (order2 === '') return sortOrders[0] const index2 = sortOrders.indexOf(order2 || null) return sortOrders[index2 > sortOrders.length - 2 ? 0 : index2 + 1] } const handleSortClick = (event, column, givenOrder) => { event.stopPropagation() const order2 = column.order === givenOrder ? null : givenOrder || toggleOrder(column) let target2 = event.target while (target2 && target2.tagName !== 'TH') { target2 = target2.parentNode } if (target2 && target2.tagName === 'TH') { if (hasClass$1(target2, 'noclick')) { removeClass$1(target2, 'noclick') return } } if (!column.sortable) return const states = props2.store.states let sortProp = states.sortProp.value let sortOrder const sortingColumn = states.sortingColumn.value if ( sortingColumn !== column || (sortingColumn === column && sortingColumn.order === null) ) { if (sortingColumn) { sortingColumn.order = null } states.sortingColumn.value = column sortProp = column.property } if (!order2) { sortOrder = column.order = null } else { sortOrder = column.order = order2 } states.sortProp.value = sortProp states.sortOrder.value = sortOrder parent2 == null ? void 0 : parent2.store.commit('changeSortCondition') } return { handleHeaderClick, handleHeaderContextMenu, handleMouseDown, handleMouseMove, handleMouseOut, handleSortClick, handleFilterClick, } } function useStyle$2(props2) { const parent2 = inject(TABLE_INJECTION_KEY) const ns = useNamespace('table') const getHeaderRowStyle = (rowIndex) => { const headerRowStyle2 = parent2 == null ? void 0 : parent2.props.headerRowStyle if (typeof headerRowStyle2 === 'function') { return headerRowStyle2.call(null, { rowIndex }) } return headerRowStyle2 } const getHeaderRowClass = (rowIndex) => { const classes = [] const headerRowClassName = parent2 == null ? void 0 : parent2.props.headerRowClassName if (typeof headerRowClassName === 'string') { classes.push(headerRowClassName) } else if (typeof headerRowClassName === 'function') { classes.push(headerRowClassName.call(null, { rowIndex })) } return classes.join(' ') } const getHeaderCellStyle = (rowIndex, columnIndex, row, column) => { var _a2 let headerCellStyles = (_a2 = parent2 == null ? void 0 : parent2.props.headerCellStyle) != null ? _a2 : {} if (typeof headerCellStyles === 'function') { headerCellStyles = headerCellStyles.call(null, { rowIndex, columnIndex, row, column, }) } const fixedStyle = column.isSubColumn ? null : getFixedColumnOffset(columnIndex, column.fixed, props2.store, row) ensurePosition(fixedStyle, 'left') ensurePosition(fixedStyle, 'right') return Object.assign({}, headerCellStyles, fixedStyle) } const getHeaderCellClass = (rowIndex, columnIndex, row, column) => { const fixedClasses = column.isSubColumn ? [] : getFixedColumnsClass( ns.b(), columnIndex, column.fixed, props2.store, row ) const classes = [ column.id, column.order, column.headerAlign, column.className, column.labelClassName, ...fixedClasses, ] if (!column.children) { classes.push('is-leaf') } if (column.sortable) { classes.push('is-sortable') } const headerCellClassName = parent2 == null ? void 0 : parent2.props.headerCellClassName if (typeof headerCellClassName === 'string') { classes.push(headerCellClassName) } else if (typeof headerCellClassName === 'function') { classes.push( headerCellClassName.call(null, { rowIndex, columnIndex, row, column, }) ) } classes.push(ns.e('cell')) return classes.filter((className) => Boolean(className)).join(' ') } return { getHeaderRowStyle, getHeaderRowClass, getHeaderCellStyle, getHeaderCellClass, } } const getAllColumns$1 = (columns) => { const result = [] columns.forEach((column) => { if (column.children) { result.push(column) result.push.apply(result, getAllColumns$1(column.children)) } else { result.push(column) } }) return result } const convertToRows$1 = (originColumns) => { let maxLevel = 1 const traverse = (column, parent2) => { if (parent2) { column.level = parent2.level + 1 if (maxLevel < column.level) { maxLevel = column.level } } if (column.children) { let colSpan = 0 column.children.forEach((subColumn) => { traverse(subColumn, column) colSpan += subColumn.colSpan }) column.colSpan = colSpan } else { column.colSpan = 1 } } originColumns.forEach((column) => { column.level = 1 traverse(column, void 0) }) const rows = [] for (let i2 = 0; i2 < maxLevel; i2++) { rows.push([]) } const allColumns = getAllColumns$1(originColumns) allColumns.forEach((column) => { if (!column.children) { column.rowSpan = maxLevel - column.level + 1 } else { column.rowSpan = 1 column.children.forEach((col) => (col.isSubColumn = true)) } rows[column.level - 1].push(column) }) return rows } function useUtils$1(props2) { const parent2 = inject(TABLE_INJECTION_KEY) const columnRows = computed(() => { return convertToRows$1(props2.store.states.originColumns.value) }) const isGroup2 = computed(() => { const result = columnRows.value.length > 1 if (result && parent2) { parent2.state.isGroup.value = true } return result }) const toggleAllSelection = (event) => { event.stopPropagation() parent2 == null ? void 0 : parent2.store.commit('toggleAllSelection') } return { isGroup: isGroup2, toggleAllSelection, columnRows, } } var TableHeader = defineComponent({ name: 'ElTableHeader', components: { ElCheckbox, }, props: { fixed: { type: String, default: '', }, store: { required: true, type: Object, }, border: Boolean, defaultSort: { type: Object, default: () => { return { prop: '', order: '', } }, }, }, setup(props2, { emit: emit2 }) { const instance = getCurrentInstance() const parent2 = inject(TABLE_INJECTION_KEY) const ns = useNamespace('table') const filterPanels = ref({}) const { onColumnsChange, onScrollableChange } = useLayoutObserver(parent2) onMounted(async () => { await nextTick() await nextTick() const { prop, order: order2 } = props2.defaultSort parent2 == null ? void 0 : parent2.store.commit('sort', { prop, order: order2, init: true }) }) const { handleHeaderClick, handleHeaderContextMenu, handleMouseDown, handleMouseMove, handleMouseOut, handleSortClick, handleFilterClick, } = useEvent(props2, emit2) const { getHeaderRowStyle, getHeaderRowClass, getHeaderCellStyle, getHeaderCellClass, } = useStyle$2(props2) const { isGroup: isGroup2, toggleAllSelection, columnRows, } = useUtils$1(props2) instance.state = { onColumnsChange, onScrollableChange, } instance.filterPanels = filterPanels return { ns, filterPanels, onColumnsChange, onScrollableChange, columnRows, getHeaderRowClass, getHeaderRowStyle, getHeaderCellClass, getHeaderCellStyle, handleHeaderClick, handleHeaderContextMenu, handleMouseDown, handleMouseMove, handleMouseOut, handleSortClick, handleFilterClick, isGroup: isGroup2, toggleAllSelection, } }, render() { const { ns, isGroup: isGroup2, columnRows, getHeaderCellStyle, getHeaderCellClass, getHeaderRowClass, getHeaderRowStyle, handleHeaderClick, handleHeaderContextMenu, handleMouseDown, handleMouseMove, handleSortClick, handleMouseOut, store: store2, $parent, } = this let rowSpan = 1 return h$4( 'thead', { class: { [ns.is('group')]: isGroup2 }, }, columnRows.map((subColumns, rowIndex) => h$4( 'tr', { class: getHeaderRowClass(rowIndex), key: rowIndex, style: getHeaderRowStyle(rowIndex), }, subColumns.map((column, cellIndex) => { if (column.rowSpan > rowSpan) { rowSpan = column.rowSpan } return h$4( 'th', { class: getHeaderCellClass( rowIndex, cellIndex, subColumns, column ), colspan: column.colSpan, key: `${column.id}-thead`, rowspan: column.rowSpan, style: getHeaderCellStyle( rowIndex, cellIndex, subColumns, column ), onClick: ($event) => handleHeaderClick($event, column), onContextmenu: ($event) => handleHeaderContextMenu($event, column), onMousedown: ($event) => handleMouseDown($event, column), onMousemove: ($event) => handleMouseMove($event, column), onMouseout: handleMouseOut, }, [ h$4( 'div', { class: [ 'cell', column.filteredValue && column.filteredValue.length > 0 ? 'highlight' : '', column.labelClassName, ], }, [ column.renderHeader ? column.renderHeader({ column, $index: cellIndex, store: store2, _self: $parent, }) : column.label, column.sortable && h$4( 'span', { onClick: ($event) => handleSortClick($event, column), class: 'caret-wrapper', }, [ h$4('i', { onClick: ($event) => handleSortClick($event, column, 'ascending'), class: 'sort-caret ascending', }), h$4('i', { onClick: ($event) => handleSortClick($event, column, 'descending'), class: 'sort-caret descending', }), ] ), column.filterable && h$4(FilterPanel, { store: store2, placement: column.filterPlacement || 'bottom-start', column, upDataColumn: (key2, value2) => { column[key2] = value2 }, }), ] ), ] ) }) ) ) ) }, }) function useEvents(props2) { const parent2 = inject(TABLE_INJECTION_KEY) const tooltipContent = ref('') const tooltipTrigger = ref(h$4('div')) const handleEvent2 = (event, row, name2) => { var _a2 const table = parent2 const cell = getCell(event) let column const namespace = (_a2 = table == null ? void 0 : table.vnode.el) == null ? void 0 : _a2.dataset.prefix if (cell) { column = getColumnByCell( { columns: props2.store.states.columns.value, }, cell, namespace ) if (column) { table == null ? void 0 : table.emit(`cell-${name2}`, row, column, cell, event) } } table == null ? void 0 : table.emit(`row-${name2}`, row, column, event) } const handleDoubleClick = (event, row) => { handleEvent2(event, row, 'dblclick') } const handleClick2 = (event, row) => { props2.store.commit('setCurrentRow', row) handleEvent2(event, row, 'click') } const handleContextMenu = (event, row) => { handleEvent2(event, row, 'contextmenu') } const handleMouseEnter = debounce$3((index2) => { props2.store.commit('setHoverRow', index2) }, 30) const handleMouseLeave = debounce$3(() => { props2.store.commit('setHoverRow', null) }, 30) const handleCellMouseEnter = (event, row) => { var _a2 const table = parent2 const cell = getCell(event) const namespace = (_a2 = table == null ? void 0 : table.vnode.el) == null ? void 0 : _a2.dataset.prefix if (cell) { const column = getColumnByCell( { columns: props2.store.states.columns.value, }, cell, namespace ) const hoverState = (table.hoverState = { cell, column, row }) table == null ? void 0 : table.emit( 'cell-mouse-enter', hoverState.row, hoverState.column, hoverState.cell, event ) } const cellChild = event.target.querySelector('.cell') if ( !( hasClass$1(cellChild, `${namespace}-tooltip`) && cellChild.childNodes.length ) ) { return } const range3 = document.createRange() range3.setStart(cellChild, 0) range3.setEnd(cellChild, cellChild.childNodes.length) const rangeWidth = range3.getBoundingClientRect().width const padding = (Number.parseInt(getStyle$1(cellChild, 'paddingLeft'), 10) || 0) + (Number.parseInt(getStyle$1(cellChild, 'paddingRight'), 10) || 0) if ( rangeWidth + padding > cellChild.offsetWidth || cellChild.scrollWidth > cellChild.offsetWidth ) { createTablePopper( cell, cell.innerText || cell.textContent, { placement: 'top', strategy: 'fixed', }, row.tooltipEffect ) } } const handleCellMouseLeave = (event) => { const cell = getCell(event) if (!cell) return const oldHoverState = parent2 == null ? void 0 : parent2.hoverState parent2 == null ? void 0 : parent2.emit( 'cell-mouse-leave', oldHoverState == null ? void 0 : oldHoverState.row, oldHoverState == null ? void 0 : oldHoverState.column, oldHoverState == null ? void 0 : oldHoverState.cell, event ) } return { handleDoubleClick, handleClick: handleClick2, handleContextMenu, handleMouseEnter, handleMouseLeave, handleCellMouseEnter, handleCellMouseLeave, tooltipContent, tooltipTrigger, } } function useStyles(props2) { const parent2 = inject(TABLE_INJECTION_KEY) const ns = useNamespace('table') const getRowStyle = (row, rowIndex) => { const rowStyle = parent2 == null ? void 0 : parent2.props.rowStyle if (typeof rowStyle === 'function') { return rowStyle.call(null, { row, rowIndex, }) } return rowStyle || null } const getRowClass = (row, rowIndex) => { const classes = [ns.e('row')] if ( (parent2 == null ? void 0 : parent2.props.highlightCurrentRow) && row === props2.store.states.currentRow.value ) { classes.push('current-row') } if (props2.stripe && rowIndex % 2 === 1) { classes.push(ns.em('row', 'striped')) } const rowClassName = parent2 == null ? void 0 : parent2.props.rowClassName if (typeof rowClassName === 'string') { classes.push(rowClassName) } else if (typeof rowClassName === 'function') { classes.push( rowClassName.call(null, { row, rowIndex, }) ) } return classes } const getCellStyle = (rowIndex, columnIndex, row, column) => { const cellStyle = parent2 == null ? void 0 : parent2.props.cellStyle let cellStyles = cellStyle != null ? cellStyle : {} if (typeof cellStyle === 'function') { cellStyles = cellStyle.call(null, { rowIndex, columnIndex, row, column, }) } const fixedStyle = column.isSubColumn ? null : getFixedColumnOffset( columnIndex, props2 == null ? void 0 : props2.fixed, props2.store ) ensurePosition(fixedStyle, 'left') ensurePosition(fixedStyle, 'right') return Object.assign({}, cellStyles, fixedStyle) } const getCellClass = (rowIndex, columnIndex, row, column) => { const fixedClasses = column.isSubColumn ? [] : getFixedColumnsClass( ns.b(), columnIndex, props2 == null ? void 0 : props2.fixed, props2.store ) const classes = [column.id, column.align, column.className, ...fixedClasses] const cellClassName = parent2 == null ? void 0 : parent2.props.cellClassName if (typeof cellClassName === 'string') { classes.push(cellClassName) } else if (typeof cellClassName === 'function') { classes.push( cellClassName.call(null, { rowIndex, columnIndex, row, column, }) ) } classes.push(ns.e('cell')) return classes.filter((className) => Boolean(className)).join(' ') } const getSpan = (row, column, rowIndex, columnIndex) => { let rowspan = 1 let colspan = 1 const fn2 = parent2 == null ? void 0 : parent2.props.spanMethod if (typeof fn2 === 'function') { const result = fn2({ row, column, rowIndex, columnIndex, }) if (Array.isArray(result)) { rowspan = result[0] colspan = result[1] } else if (typeof result === 'object') { rowspan = result.rowspan colspan = result.colspan } } return { rowspan, colspan } } const getColspanRealWidth = (columns, colspan, index2) => { if (colspan < 1) { return columns[index2].realWidth } const widthArr = columns .map(({ realWidth, width }) => realWidth || width) .slice(index2, index2 + colspan) return Number( widthArr.reduce((acc, width) => Number(acc) + Number(width), -1) ) } return { getRowStyle, getRowClass, getCellStyle, getCellClass, getSpan, getColspanRealWidth, } } function useRender$1(props2) { const parent2 = inject(TABLE_INJECTION_KEY) const { handleDoubleClick, handleClick: handleClick2, handleContextMenu, handleMouseEnter, handleMouseLeave, handleCellMouseEnter, handleCellMouseLeave, tooltipContent, tooltipTrigger, } = useEvents(props2) const { getRowStyle, getRowClass, getCellStyle, getCellClass, getSpan, getColspanRealWidth, } = useStyles(props2) const firstDefaultColumnIndex = computed(() => { return props2.store.states.columns.value.findIndex( ({ type: type4 }) => type4 === 'default' ) }) const getKeyOfRow = (row, index2) => { const rowKey = parent2.props.rowKey if (rowKey) { return getRowIdentity(row, rowKey) } return index2 } const rowRender = (row, $index, treeRowData, expanded = false) => { const { tooltipEffect, store: store2 } = props2 const { indent, columns } = store2.states const rowClasses = getRowClass(row, $index) let display2 = true if (treeRowData) { rowClasses.push(`el-table__row--level-${treeRowData.level}`) display2 = treeRowData.display } const displayStyle = display2 ? null : { display: 'none', } return h$4( 'tr', { style: [displayStyle, getRowStyle(row, $index)], class: rowClasses, key: getKeyOfRow(row, $index), onDblclick: ($event) => handleDoubleClick($event, row), onClick: ($event) => handleClick2($event, row), onContextmenu: ($event) => handleContextMenu($event, row), onMouseenter: () => handleMouseEnter($index), onMouseleave: handleMouseLeave, }, columns.value.map((column, cellIndex) => { const { rowspan, colspan } = getSpan(row, column, $index, cellIndex) if (!rowspan || !colspan) { return null } const columnData = { ...column } columnData.realWidth = getColspanRealWidth( columns.value, colspan, cellIndex ) const data2 = { store: props2.store, _self: props2.context || parent2, column: columnData, row, $index, cellIndex, expanded, } if (cellIndex === firstDefaultColumnIndex.value && treeRowData) { data2.treeNode = { indent: treeRowData.level * indent.value, level: treeRowData.level, } if (typeof treeRowData.expanded === 'boolean') { data2.treeNode.expanded = treeRowData.expanded if ('loading' in treeRowData) { data2.treeNode.loading = treeRowData.loading } if ('noLazyChildren' in treeRowData) { data2.treeNode.noLazyChildren = treeRowData.noLazyChildren } } } const baseKey = `${$index},${cellIndex}` const patchKey = columnData.columnKey || columnData.rawColumnKey || '' const tdChildren = cellChildren(cellIndex, column, data2) return h$4( 'td', { style: getCellStyle($index, cellIndex, row, column), class: getCellClass($index, cellIndex, row, column), key: `${patchKey}${baseKey}`, rowspan, colspan, onMouseenter: ($event) => handleCellMouseEnter($event, { ...row, tooltipEffect }), onMouseleave: handleCellMouseLeave, }, [tdChildren] ) }) ) } const cellChildren = (cellIndex, column, data2) => { return column.renderCell(data2) } const wrappedRowRender = (row, $index) => { const store2 = props2.store const { isRowExpanded, assertRowKey } = store2 const { treeData, lazyTreeNodeMap, childrenColumnName, rowKey } = store2.states const columns = store2.states.columns.value const hasExpandColumn = columns.some( ({ type: type4 }) => type4 === 'expand' ) if (hasExpandColumn) { const expanded = isRowExpanded(row) const tr2 = rowRender(row, $index, void 0, expanded) const renderExpanded = parent2.renderExpanded if (expanded) { if (!renderExpanded) { console.error('[Element Error]renderExpanded is required.') return tr2 } return [ [ tr2, h$4( 'tr', { key: `expanded-row__${tr2.key}`, }, [ h$4( 'td', { colspan: columns.length, class: 'el-table__cell el-table__expanded-cell', }, [renderExpanded({ row, $index, store: store2, expanded })] ), ] ), ], ] } else { return [[tr2]] } } else if (Object.keys(treeData.value).length) { assertRowKey() const key2 = getRowIdentity(row, rowKey.value) let cur = treeData.value[key2] let treeRowData = null if (cur) { treeRowData = { expanded: cur.expanded, level: cur.level, display: true, } if (typeof cur.lazy === 'boolean') { if (typeof cur.loaded === 'boolean' && cur.loaded) { treeRowData.noLazyChildren = !(cur.children && cur.children.length) } treeRowData.loading = cur.loading } } const tmp = [rowRender(row, $index, treeRowData)] if (cur) { let i2 = 0 const traverse = (children, parent22) => { if (!(children && children.length && parent22)) return children.forEach((node2) => { const innerTreeRowData = { display: parent22.display && parent22.expanded, level: parent22.level + 1, expanded: false, noLazyChildren: false, loading: false, } const childKey = getRowIdentity(node2, rowKey.value) if (childKey === void 0 || childKey === null) { throw new Error('For nested data item, row-key is required.') } cur = { ...treeData.value[childKey] } if (cur) { innerTreeRowData.expanded = cur.expanded cur.level = cur.level || innerTreeRowData.level cur.display = !!(cur.expanded && innerTreeRowData.display) if (typeof cur.lazy === 'boolean') { if (typeof cur.loaded === 'boolean' && cur.loaded) { innerTreeRowData.noLazyChildren = !( cur.children && cur.children.length ) } innerTreeRowData.loading = cur.loading } } i2++ tmp.push(rowRender(node2, $index + i2, innerTreeRowData)) if (cur) { const nodes2 = lazyTreeNodeMap.value[childKey] || node2[childrenColumnName.value] traverse(nodes2, cur) } }) } cur.display = true const nodes = lazyTreeNodeMap.value[key2] || row[childrenColumnName.value] traverse(nodes, cur) } return tmp } else { return rowRender(row, $index, void 0) } } return { wrappedRowRender, tooltipContent, tooltipTrigger, } } const defaultProps$b = { store: { required: true, type: Object, }, stripe: Boolean, tooltipEffect: String, context: { default: () => ({}), type: Object, }, rowClassName: [String, Function], rowStyle: [Object, Function], fixed: { type: String, default: '', }, highlight: Boolean, } var TableBody = defineComponent({ name: 'ElTableBody', props: defaultProps$b, setup(props2) { const instance = getCurrentInstance() const parent2 = inject(TABLE_INJECTION_KEY) const ns = useNamespace('table') const { wrappedRowRender, tooltipContent, tooltipTrigger } = useRender$1(props2) const { onColumnsChange, onScrollableChange } = useLayoutObserver(parent2) watch$1(props2.store.states.hoverRow, (newVal, oldVal) => { if (!props2.store.states.isComplex.value || !isClient$1) return let raf2 = window.requestAnimationFrame if (!raf2) { raf2 = (fn2) => window.setTimeout(fn2, 16) } raf2(() => { var _a2 const rows = (_a2 = instance == null ? void 0 : instance.vnode.el) == null ? void 0 : _a2.querySelectorAll(`.${ns.e('row')}`) const oldRow = rows[oldVal] const newRow = rows[newVal] if (oldRow) { removeClass$1(oldRow, 'hover-row') } if (newRow) { addClass$1(newRow, 'hover-row') } }) }) onUnmounted(() => { var _a2 ;(_a2 = removePopper) == null ? void 0 : _a2() }) onUpdated(() => { var _a2 ;(_a2 = removePopper) == null ? void 0 : _a2() }) return { ns, onColumnsChange, onScrollableChange, wrappedRowRender, tooltipContent, tooltipTrigger, } }, render() { const { wrappedRowRender, store: store2 } = this const data2 = store2.states.data.value || [] return h$4('tbody', {}, [ data2.reduce((acc, row) => { return acc.concat(wrappedRowRender(row, acc.length)) }, []), ]) }, }) function hColgroup(props2) { const isAuto2 = props2.tableLayout === 'auto' let columns = props2.columns || [] if (isAuto2) { if (columns.every((column) => column.width === void 0)) { columns = [] } } const getPropsData = (column) => { const propsData = { key: `${props2.tableLayout}_${column.id}`, style: {}, name: void 0, } if (isAuto2) { propsData.style = { width: `${column.width}px`, } } else { propsData.name = column.id } return propsData } return h$4( 'colgroup', {}, columns.map((column) => h$4('col', getPropsData(column))) ) } hColgroup.props = ['columns', 'tableLayout'] function useMapState() { const table = inject(TABLE_INJECTION_KEY) const store2 = table == null ? void 0 : table.store const leftFixedLeafCount = computed(() => { return store2.states.fixedLeafColumnsLength.value }) const rightFixedLeafCount = computed(() => { return store2.states.rightFixedColumns.value.length }) const columnsCount = computed(() => { return store2.states.columns.value.length }) const leftFixedCount = computed(() => { return store2.states.fixedColumns.value.length }) const rightFixedCount = computed(() => { return store2.states.rightFixedColumns.value.length }) return { leftFixedLeafCount, rightFixedLeafCount, columnsCount, leftFixedCount, rightFixedCount, columns: store2.states.columns, } } function useStyle$1(props2) { const { columns } = useMapState() const ns = useNamespace('table') const getCellClasses = (columns2, cellIndex) => { const column = columns2[cellIndex] const classes = [ ns.e('cell'), column.id, column.align, column.labelClassName, ...getFixedColumnsClass(ns.b(), cellIndex, column.fixed, props2.store), ] if (column.className) { classes.push(column.className) } if (!column.children) { classes.push(ns.is('leaf')) } return classes } const getCellStyles = (column, cellIndex) => { const fixedStyle = getFixedColumnOffset( cellIndex, column.fixed, props2.store ) ensurePosition(fixedStyle, 'left') ensurePosition(fixedStyle, 'right') return fixedStyle } return { getCellClasses, getCellStyles, columns, } } var TableFooter = defineComponent({ name: 'ElTableFooter', props: { fixed: { type: String, default: '', }, store: { required: true, type: Object, }, summaryMethod: Function, sumText: String, border: Boolean, defaultSort: { type: Object, default: () => { return { prop: '', order: '', } }, }, }, setup(props2) { const { getCellClasses, getCellStyles, columns } = useStyle$1(props2) const ns = useNamespace('table') return { ns, getCellClasses, getCellStyles, columns, } }, render() { const { columns, getCellStyles, getCellClasses, summaryMethod, sumText, ns, } = this const data2 = this.store.states.data.value let sums = [] if (summaryMethod) { sums = summaryMethod({ columns, data: data2, }) } else { columns.forEach((column, index2) => { if (index2 === 0) { sums[index2] = sumText return } const values2 = data2.map((item2) => Number(item2[column.property])) const precisions = [] let notNumber = true values2.forEach((value2) => { if (!Number.isNaN(+value2)) { notNumber = false const decimal = `${value2}`.split('.')[1] precisions.push(decimal ? decimal.length : 0) } }) const precision = Math.max.apply(null, precisions) if (!notNumber) { sums[index2] = values2.reduce((prev, curr) => { const value2 = Number(curr) if (!Number.isNaN(+value2)) { return Number.parseFloat( (prev + curr).toFixed(Math.min(precision, 20)) ) } else { return prev } }, 0) } else { sums[index2] = '' } }) } return h$4( 'table', { class: ns.e('footer'), cellspacing: '0', cellpadding: '0', border: '0', }, [ hColgroup({ columns, }), h$4('tbody', [ h$4('tr', {}, [ ...columns.map((column, cellIndex) => h$4( 'td', { key: cellIndex, colspan: column.colSpan, rowspan: column.rowSpan, class: getCellClasses(columns, cellIndex), style: getCellStyles(column, cellIndex), }, [ h$4( 'div', { class: ['cell', column.labelClassName], }, [sums[cellIndex]] ), ] ) ), ]), ]), ] ) }, }) function useUtils(store2) { const setCurrentRow = (row) => { store2.commit('setCurrentRow', row) } const getSelectionRows = () => { return store2.getSelectionRows() } const toggleRowSelection = (row, selected) => { store2.toggleRowSelection(row, selected, false) store2.updateAllSelected() } const clearSelection = () => { store2.clearSelection() } const clearFilter = (columnKeys) => { store2.clearFilter(columnKeys) } const toggleAllSelection = () => { store2.commit('toggleAllSelection') } const toggleRowExpansion = (row, expanded) => { store2.toggleRowExpansionAdapter(row, expanded) } const clearSort = () => { store2.clearSort() } const sort3 = (prop, order2) => { store2.commit('sort', { prop, order: order2 }) } return { setCurrentRow, getSelectionRows, toggleRowSelection, clearSelection, clearFilter, toggleAllSelection, toggleRowExpansion, clearSort, sort: sort3, } } function useStyle(props2, layout2, store2, table) { const isHidden2 = ref(false) const renderExpanded = ref(null) const resizeProxyVisible = ref(false) const setDragVisible = (visible) => { resizeProxyVisible.value = visible } const resizeState = ref({ width: null, height: null, }) const isGroup2 = ref(false) const scrollbarViewStyle = { display: 'inline-block', verticalAlign: 'middle', } const tableWidth = ref() watchEffect(() => { layout2.setHeight(props2.height) }) watchEffect(() => { layout2.setMaxHeight(props2.maxHeight) }) watch$1( () => [props2.currentRowKey, store2.states.rowKey], ([currentRowKey, rowKey]) => { if (!unref(rowKey)) return store2.setCurrentRowKey(`${currentRowKey}`) }, { immediate: true, } ) watch$1( () => props2.data, (data2) => { table.store.commit('setData', data2) }, { immediate: true, deep: true, } ) watchEffect(() => { if (props2.expandRowKeys) { store2.setExpandRowKeysAdapter(props2.expandRowKeys) } }) const handleMouseLeave = () => { table.store.commit('setHoverRow', null) if (table.hoverState) table.hoverState = null } const handleHeaderFooterMousewheel = (event, data2) => { const { pixelX, pixelY } = data2 if (Math.abs(pixelX) >= Math.abs(pixelY)) { table.refs.bodyWrapper.scrollLeft += data2.pixelX / 5 } } const shouldUpdateHeight = computed(() => { return ( props2.height || props2.maxHeight || store2.states.fixedColumns.value.length > 0 || store2.states.rightFixedColumns.value.length > 0 ) }) const tableBodyStyles = computed(() => { return { width: layout2.bodyWidth.value ? `${layout2.bodyWidth.value}px` : '', } }) const doLayout = () => { if (shouldUpdateHeight.value) { layout2.updateElsHeight() } layout2.updateColumnsWidth() requestAnimationFrame(syncPostion) } onMounted(async () => { await nextTick() store2.updateColumns() bindEvents() requestAnimationFrame(doLayout) resizeState.value = { width: (tableWidth.value = table.vnode.el.offsetWidth), height: table.vnode.el.offsetHeight, } store2.states.columns.value.forEach((column) => { if (column.filteredValue && column.filteredValue.length) { table.store.commit('filterChange', { column, values: column.filteredValue, silent: true, }) } }) table.$ready = true }) const setScrollClassByEl = (el2, className) => { if (!el2) return const classList2 = Array.from(el2.classList).filter( (item2) => !item2.startsWith('is-scrolling-') ) classList2.push(layout2.scrollX.value ? className : 'is-scrolling-none') el2.className = classList2.join(' ') } const setScrollClass = (className) => { const { tableWrapper } = table.refs setScrollClassByEl(tableWrapper, className) } const hasScrollClass = (className) => { const { tableWrapper } = table.refs if (tableWrapper && tableWrapper.classList.contains(className)) { return true } return false } const syncPostion = function () { if (!table.refs.scrollBarRef) return if (!layout2.scrollX.value) { const scrollingNoneClass = 'is-scrolling-none' if (!hasScrollClass(scrollingNoneClass)) { setScrollClass(scrollingNoneClass) } return } const scrollContainer = table.refs.scrollBarRef.wrap$ if (!scrollContainer) return const { scrollLeft, offsetWidth, scrollWidth } = scrollContainer const { headerWrapper, footerWrapper } = table.refs if (headerWrapper) headerWrapper.scrollLeft = scrollLeft if (footerWrapper) footerWrapper.scrollLeft = scrollLeft const maxScrollLeftPosition = scrollWidth - offsetWidth - 1 if (scrollLeft >= maxScrollLeftPosition) { setScrollClass('is-scrolling-right') } else if (scrollLeft === 0) { setScrollClass('is-scrolling-left') } else { setScrollClass('is-scrolling-middle') } } const bindEvents = () => { var _a2 if (!table.refs.scrollBarRef) return ;(_a2 = table.refs.scrollBarRef.wrap$) == null ? void 0 : _a2.addEventListener('scroll', syncPostion, { passive: true, }) if (props2.fit) { addResizeListener(table.vnode.el, resizeListener) } else { on$2(window, 'resize', doLayout) } } onBeforeUnmount(() => { unbindEvents() }) const unbindEvents = () => { var _a2 ;(_a2 = table.refs.scrollBarRef.wrap$) == null ? void 0 : _a2.removeEventListener('scroll', syncPostion, true) if (props2.fit) { removeResizeListener(table.vnode.el, resizeListener) } else { off$1(window, 'resize', doLayout) } } const resizeListener = () => { if (!table.$ready) return let shouldUpdateLayout = false const el2 = table.vnode.el const { width: oldWidth, height: oldHeight } = resizeState.value const width = (tableWidth.value = el2.offsetWidth) if (oldWidth !== width) { shouldUpdateLayout = true } const height2 = el2.offsetHeight if ((props2.height || shouldUpdateHeight.value) && oldHeight !== height2) { shouldUpdateLayout = true } if (shouldUpdateLayout) { resizeState.value = { width, height: height2, } doLayout() } } const tableSize = useSize$1() const bodyWidth = computed(() => { const { bodyWidth: bodyWidth_, scrollY, gutterWidth } = layout2 return bodyWidth_.value ? `${bodyWidth_.value - (scrollY.value ? gutterWidth : 0)}px` : '' }) const tableLayout = computed(() => { if (props2.maxHeight) return 'fixed' return props2.tableLayout }) function calcMaxHeight(maxHeight, footerHeight, headerHeight) { const parsedMaxHeight = parseHeight(maxHeight) const tableHeaderHeight = props2.showHeader ? headerHeight : 0 if (parsedMaxHeight === null) return if (isString$f(parsedMaxHeight)) { return `calc(${parsedMaxHeight} - ${footerHeight}px - ${tableHeaderHeight}px)` } return parsedMaxHeight - footerHeight - tableHeaderHeight } const height = computed(() => { const headerHeight = layout2.headerHeight.value || 0 const bodyHeight2 = layout2.bodyHeight.value const footerHeight = layout2.footerHeight.value || 0 if (props2.height) { return bodyHeight2 ? bodyHeight2 : void 0 } else if (props2.maxHeight) { return calcMaxHeight(props2.maxHeight, footerHeight, headerHeight) } return void 0 }) const bodyHeight = computed(() => { const headerHeight = layout2.headerHeight.value || 0 const bodyHeight2 = layout2.bodyHeight.value const footerHeight = layout2.footerHeight.value || 0 if (props2.height) { return { height: bodyHeight2 ? `${bodyHeight2}px` : '', } } else if (props2.maxHeight) { const maxHeight = calcMaxHeight( props2.maxHeight, footerHeight, headerHeight ) if (maxHeight !== null) { return { 'max-height': `${maxHeight}${isNumber$h(maxHeight) ? 'px' : ''}`, } } } return {} }) const emptyBlockStyle = computed(() => { if (props2.data && props2.data.length) return null let height2 = '100%' if (layout2.appendHeight.value) { height2 = `calc(100% - ${layout2.appendHeight.value}px)` } return { width: tableWidth.value ? `${tableWidth.value}px` : '', height: height2, } }) const handleFixedMousewheel = (event, data2) => { const bodyWrapper = table.refs.bodyWrapper if (Math.abs(data2.spinY) > 0) { const currentScrollTop = bodyWrapper.scrollTop if (data2.pixelY < 0 && currentScrollTop !== 0) { event.preventDefault() } if ( data2.pixelY > 0 && bodyWrapper.scrollHeight - bodyWrapper.clientHeight > currentScrollTop ) { event.preventDefault() } bodyWrapper.scrollTop += Math.ceil(data2.pixelY / 5) } else { bodyWrapper.scrollLeft += Math.ceil(data2.pixelX / 5) } } const fixedHeight = computed(() => { if (props2.maxHeight) { if (props2.showSummary) { return { bottom: 0, } } return { bottom: layout2.scrollX.value && props2.data.length ? `${layout2.gutterWidth}px` : '', } } else { if (props2.showSummary) { return { height: layout2.tableHeight.value ? `${layout2.tableHeight.value}px` : '', } } return { height: layout2.viewportHeight.value ? `${layout2.viewportHeight.value}px` : '', } } }) const fixedBodyHeight = computed(() => { if (props2.height) { return { height: layout2.fixedBodyHeight.value ? `${layout2.fixedBodyHeight.value}px` : '', } } else if (props2.maxHeight) { let maxHeight = parseHeight(props2.maxHeight) if (typeof maxHeight === 'number') { maxHeight = layout2.scrollX.value ? maxHeight - layout2.gutterWidth : maxHeight if (props2.showHeader) { maxHeight -= layout2.headerHeight.value } maxHeight -= layout2.footerHeight.value return { 'max-height': `${maxHeight}px`, } } } return {} }) return { isHidden: isHidden2, renderExpanded, setDragVisible, isGroup: isGroup2, handleMouseLeave, handleHeaderFooterMousewheel, tableSize, bodyHeight, height, emptyBlockStyle, handleFixedMousewheel, fixedHeight, fixedBodyHeight, resizeProxyVisible, bodyWidth, resizeState, doLayout, tableBodyStyles, tableLayout, scrollbarViewStyle, } } var defaultProps$a = { data: { type: Array, default: () => { return [] }, }, size: String, width: [String, Number], height: [String, Number], maxHeight: [String, Number], fit: { type: Boolean, default: true, }, stripe: Boolean, border: Boolean, rowKey: [String, Function], showHeader: { type: Boolean, default: true, }, showSummary: Boolean, sumText: String, summaryMethod: Function, rowClassName: [String, Function], rowStyle: [Object, Function], cellClassName: [String, Function], cellStyle: [Object, Function], headerRowClassName: [String, Function], headerRowStyle: [Object, Function], headerCellClassName: [String, Function], headerCellStyle: [Object, Function], highlightCurrentRow: Boolean, currentRowKey: [String, Number], emptyText: String, expandRowKeys: Array, defaultExpandAll: Boolean, defaultSort: Object, tooltipEffect: String, spanMethod: Function, selectOnIndeterminate: { type: Boolean, default: true, }, indent: { type: Number, default: 16, }, treeProps: { type: Object, default: () => { return { hasChildren: 'hasChildren', children: 'children', } }, }, lazy: Boolean, load: Function, style: { type: Object, default: () => ({}), }, className: { type: String, default: '', }, tableLayout: { type: String, default: 'fixed', }, scrollbarAlwaysOn: { type: Boolean, default: false, }, } const useScrollbar = () => { const scrollBarRef = ref() const scrollTo = (options2, yCoord) => { const scrollbar = scrollBarRef.value if (scrollbar) { scrollbar.scrollTo(options2, yCoord) } } const setScrollPosition = (position2, offset2) => { const scrollbar = scrollBarRef.value if ( scrollbar && isNumber$h(offset2) && ['Top', 'Left'].includes(position2) ) { scrollbar[`setScroll${position2}`](offset2) } } const setScrollTop2 = (top2) => setScrollPosition('Top', top2) const setScrollLeft2 = (left2) => setScrollPosition('Left', left2) return { scrollBarRef, scrollTo, setScrollTop: setScrollTop2, setScrollLeft: setScrollLeft2, } } let tableIdSeed = 1 const _sfc_main$7u = defineComponent({ name: 'ElTable', directives: { Mousewheel, }, components: { TableHeader, TableBody, TableFooter, ElScrollbar, hColgroup, }, props: defaultProps$a, emits: [ 'select', 'select-all', 'selection-change', 'cell-mouse-enter', 'cell-mouse-leave', 'cell-contextmenu', 'cell-click', 'cell-dblclick', 'row-click', 'row-contextmenu', 'row-dblclick', 'header-click', 'header-contextmenu', 'sort-change', 'filter-change', 'current-change', 'header-dragend', 'expand-change', ], setup(props2) { const { t: t3 } = useLocale() const ns = useNamespace('table') const table = getCurrentInstance() provide(TABLE_INJECTION_KEY, table) const store2 = createStore$1(table, props2) table.store = store2 const layout2 = new TableLayout({ store: table.store, table, fit: props2.fit, showHeader: props2.showHeader, }) table.layout = layout2 const isEmpty2 = computed( () => (store2.states.data.value || []).length === 0 ) const { setCurrentRow, getSelectionRows, toggleRowSelection, clearSelection, clearFilter, toggleAllSelection, toggleRowExpansion, clearSort, sort: sort3, } = useUtils(store2) const { isHidden: isHidden2, renderExpanded, setDragVisible, isGroup: isGroup2, handleMouseLeave, handleHeaderFooterMousewheel, tableSize, bodyHeight, height, emptyBlockStyle, handleFixedMousewheel, fixedHeight, fixedBodyHeight, resizeProxyVisible, bodyWidth, resizeState, doLayout, tableBodyStyles, tableLayout, scrollbarViewStyle, } = useStyle(props2, layout2, store2, table) const { scrollBarRef, scrollTo, setScrollLeft: setScrollLeft2, setScrollTop: setScrollTop2, } = useScrollbar() const debouncedUpdateLayout = debounce$3(doLayout, 50) const tableId = `el-table_${tableIdSeed++}` table.tableId = tableId table.state = { isGroup: isGroup2, resizeState, doLayout, debouncedUpdateLayout, } const computedSumText = computed( () => props2.sumText || t3('el.table.sumText') ) const computedEmptyText = computed(() => { return props2.emptyText || t3('el.table.emptyText') }) return { ns, layout: layout2, store: store2, handleHeaderFooterMousewheel, handleMouseLeave, tableId, tableSize, isHidden: isHidden2, isEmpty: isEmpty2, renderExpanded, resizeProxyVisible, resizeState, isGroup: isGroup2, bodyWidth, bodyHeight, height, tableBodyStyles, emptyBlockStyle, debouncedUpdateLayout, handleFixedMousewheel, fixedHeight, fixedBodyHeight, setCurrentRow, getSelectionRows, toggleRowSelection, clearSelection, clearFilter, toggleAllSelection, toggleRowExpansion, clearSort, doLayout, sort: sort3, t: t3, setDragVisible, context: table, computedSumText, computedEmptyText, tableLayout, scrollbarViewStyle, scrollBarRef, scrollTo, setScrollLeft: setScrollLeft2, setScrollTop: setScrollTop2, } }, }) const _hoisted_1$6b = ['data-prefix'] const _hoisted_2$53 = { ref: 'hiddenColumns', class: 'hidden-columns', } function _sfc_render$u(_ctx, _cache, $props2, $setup, $data, $options) { const _component_hColgroup = resolveComponent('hColgroup') const _component_table_header = resolveComponent('table-header') const _component_table_body = resolveComponent('table-body') const _component_el_scrollbar = resolveComponent('el-scrollbar') const _component_table_footer = resolveComponent('table-footer') const _directive_mousewheel = resolveDirective('mousewheel') return ( openBlock(), createElementBlock( 'div', { ref: 'tableWrapper', class: normalizeClass([ { [_ctx.ns.m('fit')]: _ctx.fit, [_ctx.ns.m('striped')]: _ctx.stripe, [_ctx.ns.m('border')]: _ctx.border || _ctx.isGroup, [_ctx.ns.m('hidden')]: _ctx.isHidden, [_ctx.ns.m('group')]: _ctx.isGroup, [_ctx.ns.m('fluid-height')]: _ctx.maxHeight, [_ctx.ns.m('scrollable-x')]: _ctx.layout.scrollX.value, [_ctx.ns.m('scrollable-y')]: _ctx.layout.scrollY.value, [_ctx.ns.m('enable-row-hover')]: !_ctx.store.states.isComplex.value, [_ctx.ns.m('enable-row-transition')]: (_ctx.store.states.data.value || []).length !== 0 && (_ctx.store.states.data.value || []).length < 100, 'has-footer': _ctx.showSummary, }, _ctx.ns.m(_ctx.tableSize), _ctx.className, _ctx.ns.b(), _ctx.ns.m(`layout-${_ctx.tableLayout}`), ]), style: normalizeStyle$1(_ctx.style), 'data-prefix': _ctx.ns.namespace.value, onMouseleave: _cache[0] || (_cache[0] = ($event) => _ctx.handleMouseLeave()), }, [ createElementVNode( 'div', { class: normalizeClass(_ctx.ns.e('inner-wrapper')), }, [ createElementVNode( 'div', _hoisted_2$53, [renderSlot(_ctx.$slots, 'default')], 512 ), _ctx.showHeader && _ctx.tableLayout === 'fixed' ? withDirectives( (openBlock(), createElementBlock( 'div', { key: 0, ref: 'headerWrapper', class: normalizeClass(_ctx.ns.e('header-wrapper')), }, [ createElementVNode( 'table', { ref: 'tableHeader', class: normalizeClass(_ctx.ns.e('header')), style: normalizeStyle$1(_ctx.tableBodyStyles), border: '0', cellpadding: '0', cellspacing: '0', }, [ createVNode$1( _component_hColgroup, { columns: _ctx.store.states.columns.value, 'table-layout': _ctx.tableLayout, }, null, 8, ['columns', 'table-layout'] ), createVNode$1( _component_table_header, { ref: 'tableHeaderRef', border: _ctx.border, 'default-sort': _ctx.defaultSort, store: _ctx.store, onSetDragVisible: _ctx.setDragVisible, }, null, 8, [ 'border', 'default-sort', 'store', 'onSetDragVisible', ] ), ], 6 ), ], 2 )), [[_directive_mousewheel, _ctx.handleHeaderFooterMousewheel]] ) : createCommentVNode('v-if', true), createElementVNode( 'div', { ref: 'bodyWrapper', style: normalizeStyle$1(_ctx.bodyHeight), class: normalizeClass(_ctx.ns.e('body-wrapper')), }, [ createVNode$1( _component_el_scrollbar, { ref: 'scrollBarRef', height: _ctx.maxHeight ? void 0 : _ctx.height, 'max-height': _ctx.maxHeight ? _ctx.height : void 0, 'view-style': _ctx.scrollbarViewStyle, always: _ctx.scrollbarAlwaysOn, }, { default: withCtx(() => [ createElementVNode( 'table', { ref: 'tableBody', class: normalizeClass(_ctx.ns.e('body')), cellspacing: '0', cellpadding: '0', border: '0', style: normalizeStyle$1({ width: _ctx.bodyWidth, tableLayout: _ctx.tableLayout, }), }, [ createVNode$1( _component_hColgroup, { columns: _ctx.store.states.columns.value, 'table-layout': _ctx.tableLayout, }, null, 8, ['columns', 'table-layout'] ), _ctx.showHeader && _ctx.tableLayout === 'auto' ? (openBlock(), createBlock( _component_table_header, { key: 0, border: _ctx.border, 'default-sort': _ctx.defaultSort, store: _ctx.store, onSetDragVisible: _ctx.setDragVisible, }, null, 8, [ 'border', 'default-sort', 'store', 'onSetDragVisible', ] )) : createCommentVNode('v-if', true), createVNode$1( _component_table_body, { context: _ctx.context, highlight: _ctx.highlightCurrentRow, 'row-class-name': _ctx.rowClassName, 'tooltip-effect': _ctx.tooltipEffect, 'row-style': _ctx.rowStyle, store: _ctx.store, stripe: _ctx.stripe, }, null, 8, [ 'context', 'highlight', 'row-class-name', 'tooltip-effect', 'row-style', 'store', 'stripe', ] ), ], 6 ), _ctx.isEmpty ? (openBlock(), createElementBlock( 'div', { key: 0, ref: 'emptyBlock', style: normalizeStyle$1(_ctx.emptyBlockStyle), class: normalizeClass(_ctx.ns.e('empty-block')), }, [ createElementVNode( 'span', { class: normalizeClass( _ctx.ns.e('empty-text') ), }, [ renderSlot(_ctx.$slots, 'empty', {}, () => [ createTextVNode( toDisplayString$1(_ctx.computedEmptyText), 1 ), ]), ], 2 ), ], 6 )) : createCommentVNode('v-if', true), _ctx.$slots.append ? (openBlock(), createElementBlock( 'div', { key: 1, ref: 'appendWrapper', class: normalizeClass( _ctx.ns.e('append-wrapper') ), }, [renderSlot(_ctx.$slots, 'append')], 2 )) : createCommentVNode('v-if', true), ]), _: 3, }, 8, ['height', 'max-height', 'view-style', 'always'] ), ], 6 ), _ctx.border || _ctx.isGroup ? (openBlock(), createElementBlock( 'div', { key: 1, class: normalizeClass(_ctx.ns.e('border-left-patch')), }, null, 2 )) : createCommentVNode('v-if', true), ], 2 ), _ctx.showSummary ? withDirectives( (openBlock(), createElementBlock( 'div', { key: 0, ref: 'footerWrapper', class: normalizeClass(_ctx.ns.e('footer-wrapper')), }, [ createVNode$1( _component_table_footer, { border: _ctx.border, 'default-sort': _ctx.defaultSort, store: _ctx.store, style: normalizeStyle$1(_ctx.tableBodyStyles), 'sum-text': _ctx.computedSumText, 'summary-method': _ctx.summaryMethod, }, null, 8, [ 'border', 'default-sort', 'store', 'style', 'sum-text', 'summary-method', ] ), ], 2 )), [ [vShow, !_ctx.isEmpty], [_directive_mousewheel, _ctx.handleHeaderFooterMousewheel], ] ) : createCommentVNode('v-if', true), withDirectives( createElementVNode( 'div', { ref: 'resizeProxy', class: normalizeClass(_ctx.ns.e('column-resize-proxy')), }, null, 2 ), [[vShow, _ctx.resizeProxyVisible]] ), ], 46, _hoisted_1$6b ) ) } var Table$5 = /* @__PURE__ */ _export_sfc$1(_sfc_main$7u, [ ['render', _sfc_render$u], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/table/src/table.vue', ], ]) const defaultClassNames = { selection: 'table-column--selection', expand: 'table__expand-column', } const cellStarts = { default: { order: '', }, selection: { width: 48, minWidth: 48, realWidth: 48, order: '', }, expand: { width: 48, minWidth: 48, realWidth: 48, order: '', }, index: { width: 48, minWidth: 48, realWidth: 48, order: '', }, } const getDefaultClassName = (type4) => { return defaultClassNames[type4] || '' } const cellForced = { selection: { renderHeader({ store: store2 }) { function isDisabled() { return store2.states.data.value && store2.states.data.value.length === 0 } return h$4(ElCheckbox, { disabled: isDisabled(), size: store2.states.tableSize.value, indeterminate: store2.states.selection.value.length > 0 && !store2.states.isAllSelected.value, 'onUpdate:modelValue': store2.toggleAllSelection, modelValue: store2.states.isAllSelected.value, }) }, renderCell({ row, column, store: store2, $index }) { return h$4(ElCheckbox, { disabled: column.selectable ? !column.selectable.call(null, row, $index) : false, size: store2.states.tableSize.value, onChange: () => { store2.commit('rowSelectedChanged', row) }, onClick: (event) => event.stopPropagation(), modelValue: store2.isSelected(row), }) }, sortable: false, resizable: false, }, index: { renderHeader({ column }) { return column.label || '#' }, renderCell({ column, $index }) { let i2 = $index + 1 const index2 = column.index if (typeof index2 === 'number') { i2 = $index + index2 } else if (typeof index2 === 'function') { i2 = index2($index) } return h$4('div', {}, [i2]) }, sortable: false, }, expand: { renderHeader({ column }) { return column.label || '' }, renderCell({ row, store: store2, expanded }) { const { ns } = store2 const classes = [ns.e('expand-icon')] if (expanded) { classes.push(ns.em('expand-icon', 'expanded')) } const callback = function (e2) { e2.stopPropagation() store2.toggleRowExpansion(row) } return h$4( 'div', { class: classes, onClick: callback, }, { default: () => { return [ h$4(ElIcon, null, { default: () => { return [h$4(arrowRight)] }, }), ] }, } ) }, sortable: false, resizable: false, }, } function defaultRenderCell({ row, column, $index }) { var _a2 const property2 = column.property const value2 = property2 && getProp(row, property2).value if (column && column.formatter) { return column.formatter(row, column, value2, $index) } return ( ((_a2 = value2 == null ? void 0 : value2.toString) == null ? void 0 : _a2.call(value2)) || '' ) } function treeCellPrefix( { row, treeNode, store: store2 }, createPlacehoder = false ) { const { ns } = store2 if (!treeNode) { if (createPlacehoder) { return [ h$4('span', { class: ns.e('placeholder'), }), ] } return null } const ele = [] const callback = function (e2) { e2.stopPropagation() store2.loadOrToggle(row) } if (treeNode.indent) { ele.push( h$4('span', { class: ns.e('indent'), style: { 'padding-left': `${treeNode.indent}px` }, }) ) } if (typeof treeNode.expanded === 'boolean' && !treeNode.noLazyChildren) { const expandClasses = [ ns.e('expand-icon'), treeNode.expanded ? ns.em('expand-icon', 'expanded') : '', ] let icon = arrowRight if (treeNode.loading) { icon = loading } ele.push( h$4( 'div', { class: expandClasses, onClick: callback, }, { default: () => { return [ h$4( ElIcon, { class: { [ns.is('loading')]: treeNode.loading } }, { default: () => [h$4(icon)], } ), ] }, } ) ) } else { ele.push( h$4('span', { class: ns.e('placeholder'), }) ) } return ele } function useWatcher(owner, props_2) { const instance = getCurrentInstance() const registerComplexWatchers = () => { const props2 = ['fixed'] const aliases = { realWidth: 'width', realMinWidth: 'minWidth', } const allAliases = props2.reduce((prev, cur) => { prev[cur] = cur return prev }, aliases) Object.keys(allAliases).forEach((key2) => { const columnKey2 = aliases[key2] if (hasOwn$e(props_2, columnKey2)) { watch$1( () => props_2[columnKey2], (newVal) => { let value2 = newVal if (columnKey2 === 'width' && key2 === 'realWidth') { value2 = parseWidth(newVal) } if (columnKey2 === 'minWidth' && key2 === 'realMinWidth') { value2 = parseMinWidth(newVal) } instance.columnConfig.value[columnKey2] = value2 instance.columnConfig.value[key2] = value2 const updateColumns = columnKey2 === 'fixed' owner.value.store.scheduleLayout(updateColumns) } ) } }) } const registerNormalWatchers = () => { const props2 = [ 'label', 'filters', 'filterMultiple', 'sortable', 'index', 'formatter', 'className', 'labelClassName', 'showOverflowTooltip', ] const aliases = { property: 'prop', align: 'realAlign', headerAlign: 'realHeaderAlign', } const allAliases = props2.reduce((prev, cur) => { prev[cur] = cur return prev }, aliases) Object.keys(allAliases).forEach((key2) => { const columnKey2 = aliases[key2] if (hasOwn$e(props_2, columnKey2)) { watch$1( () => props_2[columnKey2], (newVal) => { instance.columnConfig.value[key2] = newVal } ) } }) } return { registerComplexWatchers, registerNormalWatchers, } } function useRender(props2, slots, owner) { const instance = getCurrentInstance() const columnId = ref('') const isSubColumn = ref(false) const realAlign = ref() const realHeaderAlign = ref() const ns = useNamespace('table') watchEffect(() => { realAlign.value = props2.align ? `is-${props2.align}` : null realAlign.value }) watchEffect(() => { realHeaderAlign.value = props2.headerAlign ? `is-${props2.headerAlign}` : realAlign.value realHeaderAlign.value }) const columnOrTableParent = computed(() => { let parent2 = instance.vnode.vParent || instance.parent while (parent2 && !parent2.tableId && !parent2.columnId) { parent2 = parent2.vnode.vParent || parent2.parent } return parent2 }) const hasTreeColumn = computed(() => { const { store: store2 } = instance.parent if (!store2) return false const { treeData } = store2.states const treeDataValue = treeData.value return treeDataValue && Object.keys(treeDataValue).length > 0 }) const realWidth = ref(parseWidth(props2.width)) const realMinWidth = ref(parseMinWidth(props2.minWidth)) const setColumnWidth = (column) => { if (realWidth.value) column.width = realWidth.value if (realMinWidth.value) { column.minWidth = realMinWidth.value } if (!column.minWidth) { column.minWidth = 80 } column.realWidth = Number( column.width === void 0 ? column.minWidth : column.width ) return column } const setColumnForcedProps = (column) => { const type4 = column.type const source2 = cellForced[type4] || {} Object.keys(source2).forEach((prop) => { const value2 = source2[prop] if (prop !== 'className' && value2 !== void 0) { column[prop] = value2 } }) const className = getDefaultClassName(type4) if (className) { const forceClass = `${unref(ns.namespace)}-${className}` column.className = column.className ? `${column.className} ${forceClass}` : forceClass } return column } const checkSubColumn = (children) => { if (Array.isArray(children)) { children.forEach((child) => check2(child)) } else { check2(children) } function check2(item2) { var _a2 if ( ((_a2 = item2 == null ? void 0 : item2.type) == null ? void 0 : _a2.name) === 'ElTableColumn' ) { item2.vParent = instance } } } const setColumnRenders = (column) => { if (props2.renderHeader); else if (column.type !== 'selection') { column.renderHeader = (scope) => { instance.columnConfig.value['label'] const renderHeader = slots.header return renderHeader ? renderHeader(scope) : column.label } } let originRenderCell = column.renderCell const hasTreeColumnValue = hasTreeColumn.value if (column.type === 'expand') { column.renderCell = (data2) => h$4( 'div', { class: 'cell', }, [originRenderCell(data2)] ) owner.value.renderExpanded = (data2) => { return slots.default ? slots.default(data2) : slots.default } } else { originRenderCell = originRenderCell || defaultRenderCell column.renderCell = (data2) => { let children = null if (slots.default) { const vnodes = slots.default(data2) children = vnodes.some((v4) => v4.type !== Comment) ? vnodes : originRenderCell(data2) } else { children = originRenderCell(data2) } const shouldCreatePlaceholder = hasTreeColumnValue && data2.cellIndex === 0 const prefix = treeCellPrefix(data2, shouldCreatePlaceholder) const props22 = { class: 'cell', style: {}, } if (column.showOverflowTooltip) { props22.class = `${props22.class} ${unref(ns.namespace)}-tooltip` props22.style = { width: `${ (data2.column.realWidth || Number(data2.column.width)) - 1 }px`, } } checkSubColumn(children) return h$4('div', props22, [prefix, children]) } } return column } const getPropsData = (...propsKey) => { return propsKey.reduce((prev, cur) => { if (Array.isArray(cur)) { cur.forEach((key2) => { prev[key2] = props2[key2] }) } return prev }, {}) } const getColumnElIndex = (children, child) => { return Array.prototype.indexOf.call(children, child) } return { columnId, realAlign, isSubColumn, realHeaderAlign, columnOrTableParent, setColumnWidth, setColumnForcedProps, setColumnRenders, getPropsData, getColumnElIndex, } } var defaultProps$9 = { type: { type: String, default: 'default', }, label: String, className: String, labelClassName: String, property: String, prop: String, width: { type: [String, Number], default: '', }, minWidth: { type: [String, Number], default: '', }, renderHeader: Function, sortable: { type: [Boolean, String], default: false, }, sortMethod: Function, sortBy: [String, Function, Array], resizable: { type: Boolean, default: true, }, columnKey: String, align: String, headerAlign: String, showTooltipWhenOverflow: Boolean, showOverflowTooltip: Boolean, fixed: [Boolean, String], formatter: Function, selectable: Function, reserveSelection: Boolean, filterMethod: Function, filteredValue: Array, filters: Array, filterPlacement: String, filterMultiple: { type: Boolean, default: true, }, index: [Number, Function], sortOrders: { type: Array, default: () => { return ['ascending', 'descending', null] }, validator: (val2) => { return val2.every((order2) => ['ascending', 'descending', null].includes(order2) ) }, }, } let columnIdSeed = 1 var ElTableColumn$1 = defineComponent({ name: 'ElTableColumn', components: { ElCheckbox, }, props: defaultProps$9, setup(props2, { slots }) { const instance = getCurrentInstance() const columnConfig = ref({}) const owner = computed(() => { let parent22 = instance.parent while (parent22 && !parent22.tableId) { parent22 = parent22.parent } return parent22 }) const { registerNormalWatchers, registerComplexWatchers } = useWatcher( owner, props2 ) const { columnId, isSubColumn, realHeaderAlign, columnOrTableParent, setColumnWidth, setColumnForcedProps, setColumnRenders, getPropsData, getColumnElIndex, realAlign, } = useRender(props2, slots, owner) const parent2 = columnOrTableParent.value columnId.value = `${ parent2.tableId || parent2.columnId }_column_${columnIdSeed++}` onBeforeMount(() => { isSubColumn.value = owner.value !== parent2 const type4 = props2.type || 'default' const sortable = props2.sortable === '' ? true : props2.sortable const defaults2 = { ...cellStarts[type4], id: columnId.value, type: type4, property: props2.prop || props2.property, align: realAlign, headerAlign: realHeaderAlign, showOverflowTooltip: props2.showOverflowTooltip || props2.showTooltipWhenOverflow, filterable: props2.filters || props2.filterMethod, filteredValue: [], filterPlacement: '', isColumnGroup: false, isSubColumn: false, filterOpened: false, sortable, index: props2.index, rawColumnKey: instance.vnode.key, } const basicProps = [ 'columnKey', 'label', 'className', 'labelClassName', 'type', 'renderHeader', 'formatter', 'fixed', 'resizable', ] const sortProps = ['sortMethod', 'sortBy', 'sortOrders'] const selectProps = ['selectable', 'reserveSelection'] const filterProps = [ 'filterMethod', 'filters', 'filterMultiple', 'filterOpened', 'filteredValue', 'filterPlacement', ] let column = getPropsData(basicProps, sortProps, selectProps, filterProps) column = mergeOptions$1(defaults2, column) const chains = compose( setColumnRenders, setColumnWidth, setColumnForcedProps ) column = chains(column) columnConfig.value = column registerNormalWatchers() registerComplexWatchers() }) onMounted(() => { var _a2 const parent22 = columnOrTableParent.value const children = isSubColumn.value ? parent22.vnode.el.children : (_a2 = parent22.refs.hiddenColumns) == null ? void 0 : _a2.children const getColumnIndex = () => getColumnElIndex(children || [], instance.vnode.el) columnConfig.value.getColumnIndex = getColumnIndex const columnIndex = getColumnIndex() columnIndex > -1 && owner.value.store.commit( 'insertColumn', columnConfig.value, isSubColumn.value ? parent22.columnConfig.value : null ) }) onBeforeUnmount(() => { owner.value.store.commit( 'removeColumn', columnConfig.value, isSubColumn.value ? parent2.columnConfig.value : null ) }) instance.columnId = columnId.value instance.columnConfig = columnConfig return }, render() { var _a2, _b2, _c2 try { const renderDefault = (_b2 = (_a2 = this.$slots).default) == null ? void 0 : _b2.call(_a2, { row: {}, column: {}, $index: -1, }) const children = [] if (Array.isArray(renderDefault)) { for (const childNode of renderDefault) { if ( ((_c2 = childNode.type) == null ? void 0 : _c2.name) === 'ElTableColumn' || childNode.shapeFlag & 2 ) { children.push(childNode) } else if ( childNode.type === Fragment && Array.isArray(childNode.children) ) { childNode.children.forEach((vnode2) => { if ( (vnode2 == null ? void 0 : vnode2.patchFlag) !== 1024 && !isString$f(vnode2 == null ? void 0 : vnode2.children) ) { children.push(vnode2) } }) } } } const vnode = h$4('div', children) return vnode } catch (e2) { return h$4('div', []) } }, }) const ElTable = withInstall(Table$5, { TableColumn: ElTableColumn$1, }) const ElTableColumn = withNoopInstall(ElTableColumn$1) const tabBarProps = buildProps({ tabs: { type: definePropType(Array), default: () => mutable([]), }, }) const __default__$d = { name: 'ElTabBar', } const _sfc_main$7t = /* @__PURE__ */ defineComponent({ ...__default__$d, props: tabBarProps, setup(__props2, { expose }) { const props2 = __props2 const COMPONENT_NAME2 = 'ElTabBar' const instance = getCurrentInstance() const rootTabs = inject(tabsRootContextKey) if (!rootTabs) throwError$1(COMPONENT_NAME2, '') const ns = useNamespace('tabs') const barRef = ref() const barStyle = ref() const getBarStyle = () => { let offset2 = 0 let tabSize = 0 const sizeName = ['top', 'bottom'].includes(rootTabs.props.tabPosition) ? 'width' : 'height' const sizeDir = sizeName === 'width' ? 'x' : 'y' props2.tabs.every((tab) => { var _a2, _b2, _c2, _d const $el = (_b2 = (_a2 = instance.parent) == null ? void 0 : _a2.refs) == null ? void 0 : _b2[`tab-${tab.paneName}`] if (!$el) return false if (!tab.active) { return true } tabSize = $el[`client${capitalize$2(sizeName)}`] const position2 = sizeDir === 'x' ? 'left' : 'top' offset2 = $el.getBoundingClientRect()[position2] - ((_d = (_c2 = $el.parentElement) == null ? void 0 : _c2.getBoundingClientRect()[position2]) != null ? _d : 0) const tabStyles = window.getComputedStyle($el) if (sizeName === 'width') { if (props2.tabs.length > 1) { tabSize -= Number.parseFloat(tabStyles.paddingLeft) + Number.parseFloat(tabStyles.paddingRight) } offset2 += Number.parseFloat(tabStyles.paddingLeft) } return false }) return { [sizeName]: `${tabSize}px`, transform: `translate${capitalize$2(sizeDir)}(${offset2}px)`, } } const update3 = () => (barStyle.value = getBarStyle()) watch$1( () => props2.tabs, async () => { await nextTick() update3() }, { immediate: true } ) useResizeObserver$1(barRef, () => update3()) expose({ ref: barRef, update: update3, }) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { ref_key: 'barRef', ref: barRef, class: normalizeClass([ unref(ns).e('active-bar'), unref(ns).is(unref(rootTabs).props.tabPosition), ]), style: normalizeStyle$1(barStyle.value), }, null, 6 ) ) } }, }) var TabBar = /* @__PURE__ */ _export_sfc$1(_sfc_main$7t, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/tabs/src/tab-bar.vue', ], ]) const tabNavProps = buildProps({ panes: { type: definePropType(Array), default: () => mutable([]), }, currentName: { type: [String, Number], default: '', }, editable: Boolean, onTabClick: { type: definePropType(Function), default: NOOP, }, onTabRemove: { type: definePropType(Function), default: NOOP, }, type: { type: String, values: ['card', 'border-card', ''], default: '', }, stretch: Boolean, }) const COMPONENT_NAME = 'ElTabNav' const TabNav = defineComponent({ name: COMPONENT_NAME, props: tabNavProps, setup(props2, { expose }) { const rootTabs = inject(tabsRootContextKey) if (!rootTabs) throwError$1(COMPONENT_NAME, ``) const ns = useNamespace('tabs') const visibility2 = useDocumentVisibility$1() const focused = useWindowFocus$1() const navScroll$ = ref() const nav$ = ref() const el$ = ref() const scrollable = ref(false) const navOffset = ref(0) const isFocus = ref(false) const focusable = ref(true) const sizeName = computed(() => ['top', 'bottom'].includes(rootTabs.props.tabPosition) ? 'width' : 'height' ) const navStyle = computed(() => { const dir3 = sizeName.value === 'width' ? 'X' : 'Y' return { transform: `translate${dir3}(-${navOffset.value}px)`, } }) const scrollPrev = () => { if (!navScroll$.value) return const containerSize = navScroll$.value[`offset${capitalize$2(sizeName.value)}`] const currentOffset = navOffset.value if (!currentOffset) return const newOffset = currentOffset > containerSize ? currentOffset - containerSize : 0 navOffset.value = newOffset } const scrollNext = () => { if (!navScroll$.value || !nav$.value) return const navSize = nav$.value[`offset${capitalize$2(sizeName.value)}`] const containerSize = navScroll$.value[`offset${capitalize$2(sizeName.value)}`] const currentOffset = navOffset.value if (navSize - currentOffset <= containerSize) return const newOffset = navSize - currentOffset > containerSize * 2 ? currentOffset + containerSize : navSize - containerSize navOffset.value = newOffset } const scrollToActiveTab = () => { const nav = nav$.value if (!scrollable.value || !el$.value || !navScroll$.value || !nav) return const activeTab2 = el$.value.querySelector('.is-active') if (!activeTab2) return const navScroll = navScroll$.value const isHorizontal2 = ['top', 'bottom'].includes( rootTabs.props.tabPosition ) const activeTabBounding = activeTab2.getBoundingClientRect() const navScrollBounding = navScroll.getBoundingClientRect() const maxOffset = isHorizontal2 ? nav.offsetWidth - navScrollBounding.width : nav.offsetHeight - navScrollBounding.height const currentOffset = navOffset.value let newOffset = currentOffset if (isHorizontal2) { if (activeTabBounding.left < navScrollBounding.left) { newOffset = currentOffset - (navScrollBounding.left - activeTabBounding.left) } if (activeTabBounding.right > navScrollBounding.right) { newOffset = currentOffset + activeTabBounding.right - navScrollBounding.right } } else { if (activeTabBounding.top < navScrollBounding.top) { newOffset = currentOffset - (navScrollBounding.top - activeTabBounding.top) } if (activeTabBounding.bottom > navScrollBounding.bottom) { newOffset = currentOffset + (activeTabBounding.bottom - navScrollBounding.bottom) } } newOffset = Math.max(newOffset, 0) navOffset.value = Math.min(newOffset, maxOffset) } const update3 = () => { if (!nav$.value || !navScroll$.value) return const navSize = nav$.value[`offset${capitalize$2(sizeName.value)}`] const containerSize = navScroll$.value[`offset${capitalize$2(sizeName.value)}`] const currentOffset = navOffset.value if (containerSize < navSize) { const currentOffset2 = navOffset.value scrollable.value = scrollable.value || {} scrollable.value.prev = currentOffset2 scrollable.value.next = currentOffset2 + containerSize < navSize if (navSize - currentOffset2 < containerSize) { navOffset.value = navSize - containerSize } } else { scrollable.value = false if (currentOffset > 0) { navOffset.value = 0 } } } const changeTab = (e2) => { const code2 = e2.code const { up, down, left: left2, right: right2 } = EVENT_CODE if (![up, down, left2, right2].includes(code2)) return const tabList = Array.from( e2.currentTarget.querySelectorAll('[role=tab]') ) const currentIndex = tabList.indexOf(e2.target) let nextIndex if (code2 === left2 || code2 === up) { if (currentIndex === 0) { nextIndex = tabList.length - 1 } else { nextIndex = currentIndex - 1 } } else { if (currentIndex < tabList.length - 1) { nextIndex = currentIndex + 1 } else { nextIndex = 0 } } tabList[nextIndex].focus() tabList[nextIndex].click() setFocus() } const setFocus = () => { if (focusable.value) isFocus.value = true } const removeFocus = () => (isFocus.value = false) watch$1(visibility2, (visibility22) => { if (visibility22 === 'hidden') { focusable.value = false } else if (visibility22 === 'visible') { setTimeout(() => (focusable.value = true), 50) } }) watch$1(focused, (focused2) => { if (focused2) { setTimeout(() => (focusable.value = true), 50) } else { focusable.value = false } }) useResizeObserver$1(el$, update3) onMounted(() => setTimeout(() => scrollToActiveTab(), 0)) onUpdated(() => update3()) expose({ scrollToActiveTab, removeFocus, }) return () => { const scrollBtn = scrollable.value ? [ createVNode$1( 'span', { class: [ ns.e('nav-prev'), ns.is('disabled', !scrollable.value.prev), ], onClick: scrollPrev, }, [ createVNode$1(ElIcon, null, { default: () => [createVNode$1(arrowLeft, null, null)], }), ] ), createVNode$1( 'span', { class: [ ns.e('nav-next'), ns.is('disabled', !scrollable.value.next), ], onClick: scrollNext, }, [ createVNode$1(ElIcon, null, { default: () => [createVNode$1(arrowRight, null, null)], }), ] ), ] : null const tabs2 = props2.panes.map((pane, index2) => { var _a2, _b2 const tabName = pane.props.name || pane.index || `${index2}` const closable = pane.isClosable || props2.editable pane.index = `${index2}` const btnClose = closable ? createVNode$1( ElIcon, { class: 'is-icon-close', onClick: (ev) => props2.onTabRemove(pane, ev), }, { default: () => [createVNode$1(close$2, null, null)], } ) : null const tabLabelContent = ((_b2 = (_a2 = pane.instance.slots).label) == null ? void 0 : _b2.call(_a2)) || pane.props.label const tabindex = pane.active ? 0 : -1 return createVNode$1( 'div', { ref: `tab-${tabName}`, class: [ ns.e('item'), ns.is(rootTabs.props.tabPosition), ns.is('active', pane.active), ns.is('disabled', pane.props.disabled), ns.is('closable', closable), ns.is('focus', isFocus.value), ], id: `tab-${tabName}`, key: `tab-${tabName}`, 'aria-controls': `pane-${tabName}`, role: 'tab', 'aria-selected': pane.active, tabindex: tabindex, onFocus: () => setFocus(), onBlur: () => removeFocus(), onClick: (ev) => { removeFocus() props2.onTabClick(pane, tabName, ev) }, onKeydown: (ev) => { if ( closable && (ev.code === EVENT_CODE.delete || ev.code === EVENT_CODE.backspace) ) { props2.onTabRemove(pane, ev) } }, }, [...[tabLabelContent, btnClose]] ) }) return createVNode$1( 'div', { ref: el$, class: [ ns.e('nav-wrap'), ns.is('scrollable', !!scrollable.value), ns.is(rootTabs.props.tabPosition), ], }, [ scrollBtn, createVNode$1( 'div', { class: ns.e('nav-scroll'), ref: navScroll$, }, [ createVNode$1( 'div', { class: [ ns.e('nav'), ns.is(rootTabs.props.tabPosition), ns.is( 'stretch', props2.stretch && ['top', 'bottom'].includes(rootTabs.props.tabPosition) ), ], ref: nav$, style: navStyle.value, role: 'tablist', onKeydown: changeTab, }, [ ...[ !props2.type ? createVNode$1( TabBar, { tabs: [...props2.panes], }, null ) : null, tabs2, ], ] ), ] ), ] ) } }, }) const tabsProps = buildProps({ type: { type: String, values: ['card', 'border-card', ''], default: '', }, activeName: { type: [String, Number], default: '', }, closable: Boolean, addable: Boolean, modelValue: { type: [String, Number], default: '', }, editable: Boolean, tabPosition: { type: String, values: ['top', 'right', 'bottom', 'left'], default: 'top', }, beforeLeave: { type: definePropType(Function), default: () => true, }, stretch: Boolean, }) const isPanelName = (value2) => isString$f(value2) || isNumber$h(value2) const tabsEmits = { [UPDATE_MODEL_EVENT]: (name2) => isPanelName(name2), [INPUT_EVENT]: (name2) => isPanelName(name2), 'tab-click': (pane, ev) => ev instanceof Event, 'tab-change': (name2) => isPanelName(name2), edit: (paneName, action) => ['remove', 'add'].includes(action), 'tab-remove': (name2) => isPanelName(name2), 'tab-add': () => true, } const getPaneInstanceFromSlot = (vnode, paneInstanceList = []) => { const children = vnode.children || [] Array.from(children).forEach((node2) => { let type4 = node2.type type4 = type4.name || type4 if (type4 === 'ElTabPane' && node2.component) { paneInstanceList.push(node2.component) } else if (type4 === Fragment || type4 === 'template') { getPaneInstanceFromSlot(node2, paneInstanceList) } }) return paneInstanceList } var Tabs = defineComponent({ name: 'ElTabs', props: tabsProps, emits: tabsEmits, setup(props2, { emit: emit2, slots, expose }) { const instance = getCurrentInstance() useDeprecated( { scope: 'el-tabs', type: 'Event', from: 'input', replacement: 'tab-change', version: '2.5.0', ref: 'https://element-plus.org/en-US/component/tabs.html#tabs-events', }, computed(() => { var _a2 return isFunction$l( (_a2 = instance.vnode.props) == null ? void 0 : _a2.onInput ) }) ) const ns = useNamespace('tabs') const nav$ = ref() const panes = ref([]) const currentName = ref(props2.modelValue || props2.activeName || '0') const paneStatesMap = {} const updatePaneInstances = (isForceUpdate = false) => { if (slots.default) { const children = instance.subTree.children const content2 = Array.from(children).find( ({ props: props22 }) => (props22 == null ? void 0 : props22.class) === ns.e('content') ) if (!content2) return const paneInstanceList = getPaneInstanceFromSlot(content2).map( (paneComponent) => paneStatesMap[paneComponent.uid] ) const panesChanged = !( paneInstanceList.length === panes.value.length && paneInstanceList.every( (pane, index2) => pane.uid === panes.value[index2].uid ) ) if (isForceUpdate || panesChanged) { panes.value = paneInstanceList } } else if (panes.value.length !== 0) { panes.value = [] } } const changeCurrentName = (value2) => { currentName.value = value2 emit2(INPUT_EVENT, value2) emit2(UPDATE_MODEL_EVENT, value2) emit2('tab-change', value2) } const setCurrentName = (value2) => { var _a2 if (currentName.value === value2) return const canLeave = (_a2 = props2.beforeLeave) == null ? void 0 : _a2.call(props2, value2, currentName.value) if (isPromise$1(canLeave)) { canLeave.then(() => { var _a22, _b2 changeCurrentName(value2) ;(_b2 = (_a22 = nav$.value) == null ? void 0 : _a22.removeFocus) == null ? void 0 : _b2.call(_a22) }, NOOP) } else if (canLeave !== false) { changeCurrentName(value2) } } const handleTabClick = (tab, tabName, event) => { if (tab.props.disabled) return setCurrentName(tabName) emit2('tab-click', tab, event) } const handleTabRemove = (pane, ev) => { if (pane.props.disabled) return ev.stopPropagation() emit2('edit', pane.props.name, 'remove') emit2('tab-remove', pane.props.name) } const handleTabAdd = () => { emit2('edit', void 0, 'add') emit2('tab-add') } onUpdated(() => updatePaneInstances()) onMounted(() => updatePaneInstances()) watch$1( () => props2.activeName, (modelValue) => setCurrentName(modelValue) ) watch$1( () => props2.modelValue, (modelValue) => setCurrentName(modelValue) ) watch$1(currentName, async () => { var _a2, _b2 updatePaneInstances(true) await nextTick() await ((_a2 = nav$.value) == null ? void 0 : _a2.$nextTick()) ;(_b2 = nav$.value) == null ? void 0 : _b2.scrollToActiveTab() }) provide(tabsRootContextKey, { props: props2, currentName, updatePaneState: (pane) => (paneStatesMap[pane.uid] = pane), }) expose({ currentName, }) return () => { const newButton = props2.editable || props2.addable ? createVNode$1( 'span', { class: ns.e('new-tab'), tabindex: '0', onClick: handleTabAdd, onKeydown: (ev) => { if (ev.code === EVENT_CODE.enter) handleTabAdd() }, }, [ createVNode$1( ElIcon, { class: ns.is('icon-plus'), }, { default: () => [createVNode$1(plus, null, null)], } ), ] ) : null const header = createVNode$1( 'div', { class: [ns.e('header'), ns.is(props2.tabPosition)], }, [ newButton, createVNode$1( TabNav, { ref: nav$, currentName: currentName.value, editable: props2.editable, type: props2.type, panes: panes.value, stretch: props2.stretch, onTabClick: handleTabClick, onTabRemove: handleTabRemove, }, null ), ] ) const panels = createVNode$1( 'div', { class: ns.e('content'), }, [renderSlot(slots, 'default')] ) return createVNode$1( 'div', { class: [ ns.b(), ns.m(props2.tabPosition), { [ns.m('card')]: props2.type === 'card', [ns.m('border-card')]: props2.type === 'border-card', }, ], }, [ ...(props2.tabPosition !== 'bottom' ? [header, panels] : [panels, header]), ] ) } }, }) const tabPaneProps = buildProps({ label: { type: String, default: '', }, name: { type: [String, Number], default: '', }, closable: Boolean, disabled: Boolean, lazy: Boolean, }) const _hoisted_1$6a = ['id', 'aria-hidden', 'aria-labelledby'] const __default__$c = { name: 'ElTabPane', } const _sfc_main$7s = /* @__PURE__ */ defineComponent({ ...__default__$c, props: tabPaneProps, setup(__props2) { const props2 = __props2 const COMPONENT_NAME2 = 'ElTabPane' const instance = getCurrentInstance() const tabsRoot = inject(tabsRootContextKey) if (!tabsRoot) throwError$1( COMPONENT_NAME2, 'usage: ' ) const ns = useNamespace('tab-pane') const index2 = ref() const isClosable = computed( () => props2.closable || tabsRoot.props.closable ) const active = computedEager$1( () => tabsRoot.currentName.value === (props2.name || index2.value) ) const loaded = ref(active.value) const paneName = computed(() => props2.name || index2.value) const shouldBeRender = computedEager$1( () => !props2.lazy || loaded.value || active.value ) watch$1(active, (val2) => { if (val2) loaded.value = true }) tabsRoot.updatePaneState( reactive({ uid: instance.uid, instance: markRaw(instance), props: props2, paneName, active, index: index2, isClosable, }) ) return (_ctx, _cache) => { return unref(shouldBeRender) ? withDirectives( (openBlock(), createElementBlock( 'div', { key: 0, id: `pane-${unref(paneName)}`, class: normalizeClass(unref(ns).b()), role: 'tabpanel', 'aria-hidden': !unref(active), 'aria-labelledby': `tab-${unref(paneName)}`, }, [renderSlot(_ctx.$slots, 'default')], 10, _hoisted_1$6a )), [[vShow, unref(active)]] ) : createCommentVNode('v-if', true) } }, }) var TabPane = /* @__PURE__ */ _export_sfc$1(_sfc_main$7s, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/tabs/src/tab-pane.vue', ], ]) const ElTabs = withInstall(Tabs, { TabPane, }) const ElTabPane = withNoopInstall(TabPane) dayjs.extend(customParseFormat) const { Option: ElOption } = ElSelect const parseTime = (time2) => { const values2 = (time2 || '').split(':') if (values2.length >= 2) { let hours = Number.parseInt(values2[0], 10) const minutes = Number.parseInt(values2[1], 10) const timeUpper = time2.toUpperCase() if (timeUpper.includes('AM') && hours === 12) { hours = 0 } else if (timeUpper.includes('PM') && hours !== 12) { hours += 12 } return { hours, minutes, } } return null } const compareTime = (time1, time2) => { const value1 = parseTime(time1) const value2 = parseTime(time2) const minutes1 = value1.minutes + value1.hours * 60 const minutes2 = value2.minutes + value2.hours * 60 if (minutes1 === minutes2) { return 0 } return minutes1 > minutes2 ? 1 : -1 } const padTime = (time2) => { return `${time2}`.padStart(2, '0') } const formatTime$1 = (time2) => { return `${padTime(time2.hours)}:${padTime(time2.minutes)}` } const nextTime = (time2, step) => { const timeValue = parseTime(time2) const stepValue = parseTime(step) const next = { hours: timeValue.hours, minutes: timeValue.minutes, } next.minutes += stepValue.minutes next.hours += stepValue.hours next.hours += Math.floor(next.minutes / 60) next.minutes = next.minutes % 60 return formatTime$1(next) } const _sfc_main$7r = defineComponent({ name: 'ElTimeSelect', components: { ElSelect, ElOption, ElIcon }, model: { prop: 'value', event: 'change', }, props: { format: { type: String, default: 'HH:mm', }, modelValue: String, disabled: { type: Boolean, default: false, }, editable: { type: Boolean, default: true, }, effect: { type: String, default: 'light', }, clearable: { type: Boolean, default: true, }, size: { type: String, values: componentSizes, default: '', }, placeholder: { type: String, default: '', }, start: { type: String, default: '09:00', }, end: { type: String, default: '18:00', }, step: { type: String, default: '00:30', }, minTime: { type: String, default: '', }, maxTime: { type: String, default: '', }, name: { type: String, default: '', }, prefixIcon: { type: [String, Object], default: clock, }, clearIcon: { type: [String, Object], default: circleClose, }, }, emits: ['change', 'blur', 'focus', 'update:modelValue'], setup(props2) { const select2 = ref(null) const value2 = computed(() => props2.modelValue) const start2 = computed(() => { const time2 = parseTime(props2.start) return formatTime$1(time2) }) const end2 = computed(() => { const time2 = parseTime(props2.end) return formatTime$1(time2) }) const step = computed(() => { const time2 = parseTime(props2.step) return formatTime$1(time2) }) const minTime = computed(() => { const time2 = parseTime(props2.minTime) return time2 ? formatTime$1(time2) : null }) const maxTime = computed(() => { const time2 = parseTime(props2.maxTime) return time2 ? formatTime$1(time2) : null }) const items = computed(() => { const result = [] if (props2.start && props2.end && props2.step) { let current2 = start2.value let currentTime while (compareTime(current2, end2.value) <= 0) { currentTime = dayjs(current2, 'HH:mm').format(props2.format) result.push({ value: currentTime, disabled: compareTime(current2, minTime.value || '-1:-1') <= 0 || compareTime(current2, maxTime.value || '100:100') >= 0, }) current2 = nextTime(current2, step.value) } } return result }) const blur = () => { var _a2, _b2 ;(_b2 = (_a2 = select2.value) == null ? void 0 : _a2.blur) == null ? void 0 : _b2.call(_a2) } const focus2 = () => { var _a2, _b2 ;(_b2 = (_a2 = select2.value) == null ? void 0 : _a2.focus) == null ? void 0 : _b2.call(_a2) } return { select: select2, value: value2, items, blur, focus: focus2, } }, }) function _sfc_render$t(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_option = resolveComponent('el-option') const _component_el_icon = resolveComponent('el-icon') const _component_el_select = resolveComponent('el-select') return ( openBlock(), createBlock( _component_el_select, { ref: 'select', 'model-value': _ctx.value, disabled: _ctx.disabled, clearable: _ctx.clearable, 'clear-icon': _ctx.clearIcon, size: _ctx.size, effect: _ctx.effect, placeholder: _ctx.placeholder, 'default-first-option': '', filterable: _ctx.editable, 'onUpdate:modelValue': _cache[0] || (_cache[0] = (event) => _ctx.$emit('update:modelValue', event)), onChange: _cache[1] || (_cache[1] = (event) => _ctx.$emit('change', event)), onBlur: _cache[2] || (_cache[2] = (event) => _ctx.$emit('blur', event)), onFocus: _cache[3] || (_cache[3] = (event) => _ctx.$emit('focus', event)), }, { prefix: withCtx(() => [ _ctx.prefixIcon ? (openBlock(), createBlock( _component_el_icon, { key: 0, class: 'el-input__prefix-icon', }, { default: withCtx(() => [ (openBlock(), createBlock(resolveDynamicComponent(_ctx.prefixIcon))), ]), _: 1, } )) : createCommentVNode('v-if', true), ]), default: withCtx(() => [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.items, (item2) => { return ( openBlock(), createBlock( _component_el_option, { key: item2.value, label: item2.value, value: item2.value, disabled: item2.disabled, }, null, 8, ['label', 'value', 'disabled'] ) ) }), 128 )), ]), _: 1, }, 8, [ 'model-value', 'disabled', 'clearable', 'clear-icon', 'size', 'effect', 'placeholder', 'filterable', ] ) ) } var TimeSelect = /* @__PURE__ */ _export_sfc$1(_sfc_main$7r, [ ['render', _sfc_render$t], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/time-select/src/time-select.vue', ], ]) TimeSelect.install = (app2) => { app2.component(TimeSelect.name, TimeSelect) } const _TimeSelect = TimeSelect const ElTimeSelect = _TimeSelect const Timeline = defineComponent({ name: 'ElTimeline', setup(_2, { slots }) { const ns = useNamespace('timeline') provide('timeline', slots) return () => { return h$4('ul', { class: [ns.b()] }, [renderSlot(slots, 'default')]) } }, }) const timelineItemProps = buildProps({ timestamp: { type: String, default: '', }, hideTimestamp: { type: Boolean, default: false, }, center: { type: Boolean, default: false, }, placement: { type: String, default: 'bottom', }, type: { type: String, default: '', }, color: { type: String, default: '', }, size: { type: String, default: 'normal', }, icon: { type: iconPropType, default: '', }, hollow: { type: Boolean, default: false, }, }) const _sfc_main$7q = defineComponent({ name: 'ElTimelineItem', components: { ElIcon, }, props: timelineItemProps, setup() { const ns = useNamespace('timeline-item') return { ns, } }, }) function _sfc_render$s(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_icon = resolveComponent('el-icon') return ( openBlock(), createElementBlock( 'li', { class: normalizeClass([ _ctx.ns.b(), { [_ctx.ns.e('center')]: _ctx.center }, ]), }, [ createElementVNode( 'div', { class: normalizeClass(_ctx.ns.e('tail')), }, null, 2 ), !_ctx.$slots.dot ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass([ _ctx.ns.e('node'), _ctx.ns.em('node', _ctx.size || ''), _ctx.ns.em('node', _ctx.type || ''), _ctx.ns.is('hollow', _ctx.hollow), ]), style: normalizeStyle$1({ backgroundColor: _ctx.color, }), }, [ _ctx.icon ? (openBlock(), createBlock( _component_el_icon, { key: 0, class: normalizeClass(_ctx.ns.e('icon')), }, { default: withCtx(() => [ (openBlock(), createBlock(resolveDynamicComponent(_ctx.icon))), ]), _: 1, }, 8, ['class'] )) : createCommentVNode('v-if', true), ], 6 )) : createCommentVNode('v-if', true), _ctx.$slots.dot ? (openBlock(), createElementBlock( 'div', { key: 1, class: normalizeClass(_ctx.ns.e('dot')), }, [renderSlot(_ctx.$slots, 'dot')], 2 )) : createCommentVNode('v-if', true), createElementVNode( 'div', { class: normalizeClass(_ctx.ns.e('wrapper')), }, [ !_ctx.hideTimestamp && _ctx.placement === 'top' ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass([ _ctx.ns.e('timestamp'), _ctx.ns.is('top'), ]), }, toDisplayString$1(_ctx.timestamp), 3 )) : createCommentVNode('v-if', true), createElementVNode( 'div', { class: normalizeClass(_ctx.ns.e('content')), }, [renderSlot(_ctx.$slots, 'default')], 2 ), !_ctx.hideTimestamp && _ctx.placement === 'bottom' ? (openBlock(), createElementBlock( 'div', { key: 1, class: normalizeClass([ _ctx.ns.e('timestamp'), _ctx.ns.is('bottom'), ]), }, toDisplayString$1(_ctx.timestamp), 3 )) : createCommentVNode('v-if', true), ], 2 ), ], 2 ) ) } var TimelineItem = /* @__PURE__ */ _export_sfc$1(_sfc_main$7q, [ ['render', _sfc_render$s], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/timeline/src/timeline-item.vue', ], ]) const ElTimeline = withInstall(Timeline, { TimelineItem, }) const ElTimelineItem = withNoopInstall(TimelineItem) const tooltipV2CommonProps = buildProps({ nowrap: Boolean, }) var TooltipV2Sides = /* @__PURE__ */ ((TooltipV2Sides2) => { TooltipV2Sides2['top'] = 'top' TooltipV2Sides2['bottom'] = 'bottom' TooltipV2Sides2['left'] = 'left' TooltipV2Sides2['right'] = 'right' return TooltipV2Sides2 })(TooltipV2Sides || {}) const tooltipV2Sides = Object.values(TooltipV2Sides) const tooltipV2ArrowProps = buildProps({ width: { type: Number, default: 10, }, height: { type: Number, default: 10, }, style: { type: definePropType(Object), default: null, }, }) const tooltipV2ArrowSpecialProps = buildProps({ side: { type: definePropType(String), values: tooltipV2Sides, required: true, }, }) const tooltipV2Strategies = ['absolute', 'fixed'] const tooltipV2Placements = [ 'top-start', 'top-end', 'top', 'bottom-start', 'bottom-end', 'bottom', 'left-start', 'left-end', 'left', 'right-start', 'right-end', 'right', ] const tooltipV2ContentProps = buildProps({ ariaLabel: String, arrowPadding: { type: definePropType(Number), default: 5, }, effect: { type: String, default: '', }, contentClass: String, placement: { type: definePropType(String), values: tooltipV2Placements, default: 'bottom', }, reference: { type: definePropType(Object), default: null, }, offset: { type: Number, default: 8, }, strategy: { type: definePropType(String), values: tooltipV2Strategies, default: 'absolute', }, showArrow: { type: Boolean, default: false, }, }) const tooltipV2RootProps = buildProps({ delayDuration: { type: Number, default: 300, }, defaultOpen: Boolean, open: { type: Boolean, default: void 0, }, onOpenChange: { type: definePropType(Function), }, 'onUpdate:open': { type: definePropType(Function), }, }) const EventHandler = { type: definePropType(Function), } const tooltipV2TriggerProps = buildProps({ onBlur: EventHandler, onClick: EventHandler, onFocus: EventHandler, onMouseDown: EventHandler, onMouseEnter: EventHandler, onMouseLeave: EventHandler, }) const tooltipV2Props = buildProps({ ...tooltipV2RootProps, ...tooltipV2ArrowProps, ...tooltipV2TriggerProps, ...tooltipV2ContentProps, alwaysOn: Boolean, fullTransition: Boolean, transitionProps: { type: definePropType(Object), default: null, }, teleported: Boolean, to: { type: definePropType(String), default: 'body', }, }) const __default__$b = { name: 'ElTooltipV2Root', } const _sfc_main$7p = /* @__PURE__ */ defineComponent({ ...__default__$b, props: tooltipV2RootProps, setup(__props2, { expose }) { const props2 = __props2 const _open = ref(props2.defaultOpen) const triggerRef2 = ref(null) const open2 = computed({ get: () => (isPropAbsent(props2.open) ? _open.value : props2.open), set: (open22) => { var _a2 _open.value = open22 ;(_a2 = props2['onUpdate:open']) == null ? void 0 : _a2.call(props2, open22) }, }) const isOpenDelayed = computed( () => isNumber$h(props2.delayDuration) && props2.delayDuration > 0 ) const { start: onDelayedOpen, stop: clearTimer2 } = useTimeoutFn$1( () => { open2.value = true }, computed(() => props2.delayDuration), { immediate: false, } ) const ns = useNamespace('tooltip-v2') const contentId = useId() const onNormalOpen = () => { clearTimer2() open2.value = true } const onDelayOpen = () => { unref(isOpenDelayed) ? onDelayedOpen() : onNormalOpen() } const onOpen = onNormalOpen const onClose = () => { clearTimer2() open2.value = false } const onChange = (open22) => { var _a2 if (open22) { document.dispatchEvent(new CustomEvent(TOOLTIP_V2_OPEN)) onOpen() } ;(_a2 = props2.onOpenChange) == null ? void 0 : _a2.call(props2, open22) } watch$1(open2, onChange) onMounted(() => { document.addEventListener(TOOLTIP_V2_OPEN, onClose) }) onBeforeUnmount(() => { clearTimer2() document.removeEventListener(TOOLTIP_V2_OPEN, onClose) }) provide(tooltipV2RootKey, { contentId, triggerRef: triggerRef2, ns, onClose, onDelayOpen, onOpen, }) expose({ onOpen, onClose, }) return (_ctx, _cache) => { return renderSlot(_ctx.$slots, 'default', { open: unref(open2) }) } }, }) var TooltipV2Root = /* @__PURE__ */ _export_sfc$1(_sfc_main$7p, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/tooltip-v2/src/root.vue', ], ]) const __default__$a = { name: 'ElTooltipV2Arrow', } const _sfc_main$7o = /* @__PURE__ */ defineComponent({ ...__default__$a, props: { ...tooltipV2ArrowProps, ...tooltipV2ArrowSpecialProps, }, setup(__props2) { const props2 = __props2 const { ns } = inject(tooltipV2RootKey) const { arrowRef } = inject(tooltipV2ContentKey) const arrowStyle = computed(() => { const { style: style2, width, height } = props2 const namespace = ns.namespace.value return { [`--${namespace}-tooltip-v2-arrow-width`]: `${width}px`, [`--${namespace}-tooltip-v2-arrow-height`]: `${height}px`, [`--${namespace}-tooltip-v2-arrow-border-width`]: `${width / 2}px`, [`--${namespace}-tooltip-v2-arrow-cover-width`]: width / 2 - 1, ...(style2 || {}), } }) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'span', { ref_key: 'arrowRef', ref: arrowRef, style: normalizeStyle$1(unref(arrowStyle)), class: normalizeClass(unref(ns).e('arrow')), }, null, 6 ) ) } }, }) var TooltipV2Arrow = /* @__PURE__ */ _export_sfc$1(_sfc_main$7o, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/tooltip-v2/src/arrow.vue', ], ]) const _hoisted_1$69 = ['data-side'] const __default__$9 = { name: 'ElTooltipV2Content', } const _sfc_main$7n = /* @__PURE__ */ defineComponent({ ...__default__$9, props: { ...tooltipV2ContentProps, ...tooltipV2CommonProps }, setup(__props2) { const props2 = __props2 const { triggerRef: triggerRef2, contentId } = inject(tooltipV2RootKey) const placement = ref(props2.placement) const strategy = ref(props2.strategy) const arrowRef = ref(null) const { referenceRef, contentRef, middlewareData, x: x2, y: y2, update: update3, } = useFloating({ placement, strategy, middleware: computed(() => { const middleware = [T$5(props2.offset)] if (props2.showArrow) { middleware.push( arrowMiddleware({ arrowRef, }) ) } return middleware }), }) const zIndex2 = useZIndex().nextZIndex() const ns = useNamespace('tooltip-v2') const side = computed(() => { return placement.value.split('-')[0] }) const contentStyle = computed(() => { return { position: unref(strategy), top: `${unref(y2) || 0}px`, left: `${unref(x2) || 0}px`, zIndex: zIndex2, } }) const arrowStyle = computed(() => { if (!props2.showArrow) return {} const { arrow: arrow2 } = unref(middlewareData) return { [`--${ns.namespace.value}-tooltip-v2-arrow-x`]: `${arrow2 == null ? void 0 : arrow2.x}px` || '', [`--${ns.namespace.value}-tooltip-v2-arrow-y`]: `${arrow2 == null ? void 0 : arrow2.y}px` || '', } }) const contentClass = computed(() => [ ns.e('content'), ns.is('dark', props2.effect === 'dark'), ns.is(unref(strategy)), props2.contentClass, ]) watch$1(arrowRef, () => update3()) watch$1( () => props2.placement, (val2) => (placement.value = val2) ) onMounted(() => { watch$1( () => props2.reference || triggerRef2.value, (el2) => { referenceRef.value = el2 || void 0 }, { immediate: true, } ) }) provide(tooltipV2ContentKey, { arrowRef }) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { ref_key: 'contentRef', ref: contentRef, style: normalizeStyle$1(unref(contentStyle)), 'data-tooltip-v2-root': '', }, [ !_ctx.nowrap ? (openBlock(), createElementBlock( 'div', { key: 0, 'data-side': unref(side), class: normalizeClass(unref(contentClass)), }, [ renderSlot(_ctx.$slots, 'default', { contentStyle: unref(contentStyle), contentClass: unref(contentClass), }), createVNode$1( unref(ElVisuallyHidden), { id: unref(contentId), role: 'tooltip', }, { default: withCtx(() => [ _ctx.ariaLabel ? (openBlock(), createElementBlock( Fragment, { key: 0 }, [ createTextVNode( toDisplayString$1(_ctx.ariaLabel), 1 ), ], 2112 )) : renderSlot(_ctx.$slots, 'default', { key: 1 }), ]), _: 3, }, 8, ['id'] ), renderSlot(_ctx.$slots, 'arrow', { style: normalizeStyle$1(unref(arrowStyle)), side: unref(side), }), ], 10, _hoisted_1$69 )) : createCommentVNode('v-if', true), ], 4 ) ) } }, }) var TooltipV2Content = /* @__PURE__ */ _export_sfc$1(_sfc_main$7n, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/tooltip-v2/src/content.vue', ], ]) const forwardRefProps = buildProps({ setRef: { type: definePropType(Function), required: true, }, onlyChild: Boolean, }) var ForwardRef = defineComponent({ props: forwardRefProps, setup(props2, { slots }) { const fragmentRef = ref() const setRef = composeRefs(fragmentRef, (el2) => { if (el2) { props2.setRef(el2.nextElementSibling) } else { props2.setRef(null) } }) return () => { var _a2 const [firstChild] = ((_a2 = slots.default) == null ? void 0 : _a2.call(slots)) || [] const child = props2.onlyChild ? ensureOnlyChild(firstChild.children) : firstChild.children return createVNode$1( Fragment, { ref: setRef, }, [child] ) } }, }) const __default__$8 = { name: 'ElTooltipV2Trigger', } const _sfc_main$7m = /* @__PURE__ */ defineComponent({ ...__default__$8, props: { ...tooltipV2CommonProps, ...tooltipV2TriggerProps, }, setup(__props2) { const props2 = __props2 const { onClose, onOpen, onDelayOpen, triggerRef: triggerRef2, contentId, } = inject(tooltipV2RootKey) let isMousedown = false const setTriggerRef = (el2) => { triggerRef2.value = el2 } const onMouseup = () => { isMousedown = false } const onMouseenter = composeEventHandlers(props2.onMouseEnter, onDelayOpen) const onMouseleave = composeEventHandlers(props2.onMouseLeave, onClose) const onMousedown = composeEventHandlers(props2.onMouseDown, () => { onClose() isMousedown = true document.addEventListener('mouseup', onMouseup, { once: true }) }) const onFocus = composeEventHandlers(props2.onFocus, () => { if (!isMousedown) onOpen() }) const onBlur = composeEventHandlers(props2.onBlur, onClose) const onClick = composeEventHandlers(props2.onClick, (e2) => { if (e2.detail === 0) onClose() }) const events2 = { blur: onBlur, click: onClick, focus: onFocus, mousedown: onMousedown, mouseenter: onMouseenter, mouseleave: onMouseleave, } const setEvents = (el2, events22, type4) => { if (el2) { Object.entries(events22).forEach(([name2, handler]) => { el2[type4](name2, handler) }) } } watch$1(triggerRef2, (triggerEl, previousTriggerEl) => { setEvents(triggerEl, events2, 'addEventListener') setEvents(previousTriggerEl, events2, 'removeEventListener') if (triggerEl) { triggerEl.setAttribute('aria-describedby', contentId.value) } }) onBeforeUnmount(() => { setEvents(triggerRef2.value, events2, 'removeEventListener') document.removeEventListener('mouseup', onMouseup) }) return (_ctx, _cache) => { return _ctx.nowrap ? (openBlock(), createBlock( unref(ForwardRef), { key: 0, 'set-ref': setTriggerRef, 'only-child': '', }, { default: withCtx(() => [renderSlot(_ctx.$slots, 'default')]), _: 3, } )) : (openBlock(), createElementBlock( 'button', mergeProps( { key: 1, ref_key: 'triggerRef', ref: triggerRef2, }, _ctx.$attrs ), [renderSlot(_ctx.$slots, 'default')], 16 )) } }, }) var TooltipV2Trigger = /* @__PURE__ */ _export_sfc$1(_sfc_main$7m, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/tooltip-v2/src/trigger.vue', ], ]) const __default__$7 = { name: 'ElTooltipV2', } const _sfc_main$7l = /* @__PURE__ */ defineComponent({ ...__default__$7, props: tooltipV2Props, setup(__props2) { const props2 = __props2 const refedProps = toRefs$2(props2) const arrowProps = reactive( pick$3(refedProps, Object.keys(tooltipV2ArrowProps)) ) const contentProps = reactive( pick$3(refedProps, Object.keys(tooltipV2ContentProps)) ) const rootProps = reactive( pick$3(refedProps, Object.keys(tooltipV2RootProps)) ) const triggerProps = reactive( pick$3(refedProps, Object.keys(tooltipV2TriggerProps)) ) return (_ctx, _cache) => { return ( openBlock(), createBlock( TooltipV2Root, normalizeProps(guardReactiveProps(unref(rootProps))), { default: withCtx(({ open: open2 }) => [ createVNode$1( TooltipV2Trigger, mergeProps(unref(triggerProps), { nowrap: '' }), { default: withCtx(() => [renderSlot(_ctx.$slots, 'trigger')]), _: 3, }, 16 ), (openBlock(), createBlock( Teleport, { to: _ctx.to, disabled: !_ctx.teleported, }, [ _ctx.fullTransition ? (openBlock(), createBlock( Transition, normalizeProps( mergeProps({ key: 0 }, _ctx.transitionProps) ), { default: withCtx(() => [ _ctx.alwaysOn || open2 ? (openBlock(), createBlock( TooltipV2Content, normalizeProps( mergeProps({ key: 0 }, unref(contentProps)) ), { arrow: withCtx( ({ style: style2, side }) => [ _ctx.showArrow ? (openBlock(), createBlock( TooltipV2Arrow, mergeProps( { key: 0 }, unref(arrowProps), { style: style2, side, } ), null, 16, ['style', 'side'] )) : createCommentVNode('v-if', true), ] ), default: withCtx(() => [ renderSlot(_ctx.$slots, 'default'), ]), _: 3, }, 16 )) : createCommentVNode('v-if', true), ]), _: 2, }, 1040 )) : (openBlock(), createElementBlock( Fragment, { key: 1 }, [ _ctx.alwaysOn || open2 ? (openBlock(), createBlock( TooltipV2Content, normalizeProps( mergeProps({ key: 0 }, unref(contentProps)) ), { arrow: withCtx(({ style: style2, side }) => [ _ctx.showArrow ? (openBlock(), createBlock( TooltipV2Arrow, mergeProps( { key: 0 }, unref(arrowProps), { style: style2, side, } ), null, 16, ['style', 'side'] )) : createCommentVNode('v-if', true), ]), default: withCtx(() => [ renderSlot(_ctx.$slots, 'default'), ]), _: 3, }, 16 )) : createCommentVNode('v-if', true), ], 2112 )), ], 8, ['to', 'disabled'] )), ]), _: 3, }, 16 ) ) } }, }) var TooltipV2 = /* @__PURE__ */ _export_sfc$1(_sfc_main$7l, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/tooltip-v2/src/tooltip.vue', ], ]) const ElTooltipV2 = withInstall(TooltipV2) const CHECKED_CHANGE_EVENT = 'checked-change' const useCheckProps = { data: { type: Array, default() { return [] }, }, optionRender: Function, placeholder: String, title: String, filterable: Boolean, format: Object, filterMethod: Function, defaultChecked: Array, props: Object, } const useCheck$1 = (props2, panelState) => { const { emit: emit2 } = getCurrentInstance() const labelProp = computed(() => props2.props.label || 'label') const keyProp = computed(() => props2.props.key || 'key') const disabledProp = computed(() => props2.props.disabled || 'disabled') const filteredData = computed(() => { return props2.data.filter((item2) => { if (typeof props2.filterMethod === 'function') { return props2.filterMethod(panelState.query, item2) } else { const label = item2[labelProp.value] || item2[keyProp.value].toString() return label.toLowerCase().includes(panelState.query.toLowerCase()) } }) }) const checkableData = computed(() => { return filteredData.value.filter((item2) => !item2[disabledProp.value]) }) const checkedSummary = computed(() => { const checkedLength = panelState.checked.length const dataLength = props2.data.length const { noChecked, hasChecked } = props2.format if (noChecked && hasChecked) { return checkedLength > 0 ? hasChecked .replace(/\${checked}/g, checkedLength.toString()) .replace(/\${total}/g, dataLength.toString()) : noChecked.replace(/\${total}/g, dataLength.toString()) } else { return `${checkedLength}/${dataLength}` } }) const isIndeterminate = computed(() => { const checkedLength = panelState.checked.length return checkedLength > 0 && checkedLength < checkableData.value.length }) const updateAllChecked = () => { const checkableDataKeys = checkableData.value.map( (item2) => item2[keyProp.value] ) panelState.allChecked = checkableDataKeys.length > 0 && checkableDataKeys.every((item2) => panelState.checked.includes(item2)) } const handleAllCheckedChange = (value2) => { panelState.checked = value2 ? checkableData.value.map((item2) => item2[keyProp.value]) : [] } watch$1( () => panelState.checked, (val2, oldVal) => { updateAllChecked() if (panelState.checkChangeByUser) { const movedKeys = val2 .concat(oldVal) .filter((v4) => !val2.includes(v4) || !oldVal.includes(v4)) emit2(CHECKED_CHANGE_EVENT, val2, movedKeys) } else { emit2(CHECKED_CHANGE_EVENT, val2) panelState.checkChangeByUser = true } } ) watch$1(checkableData, () => { updateAllChecked() }) watch$1( () => props2.data, () => { const checked2 = [] const filteredDataKeys = filteredData.value.map( (item2) => item2[keyProp.value] ) panelState.checked.forEach((item2) => { if (filteredDataKeys.includes(item2)) { checked2.push(item2) } }) panelState.checkChangeByUser = false panelState.checked = checked2 } ) watch$1( () => props2.defaultChecked, (val2, oldVal) => { if ( oldVal && val2.length === oldVal.length && val2.every((item2) => oldVal.includes(item2)) ) return const checked2 = [] const checkableDataKeys = checkableData.value.map( (item2) => item2[keyProp.value] ) val2.forEach((item2) => { if (checkableDataKeys.includes(item2)) { checked2.push(item2) } }) panelState.checkChangeByUser = false panelState.checked = checked2 }, { immediate: true, } ) return { labelProp, keyProp, disabledProp, filteredData, checkableData, checkedSummary, isIndeterminate, updateAllChecked, handleAllCheckedChange, } } const _sfc_main$7k = defineComponent({ name: 'ElTransferPanel', components: { ElCheckboxGroup: ElCheckboxGroup$1, ElCheckbox, ElInput, OptionContent: ({ option: option2 }) => option2, }, props: useCheckProps, emits: [CHECKED_CHANGE_EVENT], setup(props2, { slots }) { const { t: t3 } = useLocale() const ns = useNamespace('transfer') const panelState = reactive({ checked: [], allChecked: false, query: '', inputHover: false, checkChangeByUser: true, }) const { labelProp, keyProp, disabledProp, filteredData, checkedSummary, isIndeterminate, handleAllCheckedChange, } = useCheck$1(props2, panelState) const hasNoMatch = computed(() => { return panelState.query.length > 0 && filteredData.value.length === 0 }) const hasFooter = computed(() => !!slots.default()[0].children.length) const { checked: checked2, allChecked, query, inputHover, checkChangeByUser, } = toRefs$2(panelState) return { ns, labelProp, keyProp, disabledProp, filteredData, checkedSummary, isIndeterminate, handleAllCheckedChange, checked: checked2, allChecked, query, inputHover, checkChangeByUser, hasNoMatch, SearchIcon: search, hasFooter, t: t3, } }, }) function _sfc_render$r(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_checkbox = resolveComponent('el-checkbox') const _component_el_input = resolveComponent('el-input') const _component_option_content = resolveComponent('option-content') const _component_el_checkbox_group = resolveComponent('el-checkbox-group') return ( openBlock(), createElementBlock( 'div', { class: normalizeClass(_ctx.ns.b('panel')), }, [ createElementVNode( 'p', { class: normalizeClass(_ctx.ns.be('panel', 'header')), }, [ createVNode$1( _component_el_checkbox, { modelValue: _ctx.allChecked, 'onUpdate:modelValue': _cache[0] || (_cache[0] = ($event) => (_ctx.allChecked = $event)), indeterminate: _ctx.isIndeterminate, onChange: _ctx.handleAllCheckedChange, }, { default: withCtx(() => [ createTextVNode(toDisplayString$1(_ctx.title) + ' ', 1), createElementVNode( 'span', null, toDisplayString$1(_ctx.checkedSummary), 1 ), ]), _: 1, }, 8, ['modelValue', 'indeterminate', 'onChange'] ), ], 2 ), createElementVNode( 'div', { class: normalizeClass([ _ctx.ns.be('panel', 'body'), _ctx.ns.is('with-footer', _ctx.hasFooter), ]), }, [ _ctx.filterable ? (openBlock(), createBlock( _component_el_input, { key: 0, modelValue: _ctx.query, 'onUpdate:modelValue': _cache[1] || (_cache[1] = ($event) => (_ctx.query = $event)), class: normalizeClass(_ctx.ns.be('panel', 'filter')), size: 'default', placeholder: _ctx.placeholder, 'prefix-icon': _ctx.SearchIcon, clearable: '', onMouseenter: _cache[2] || (_cache[2] = ($event) => (_ctx.inputHover = true)), onMouseleave: _cache[3] || (_cache[3] = ($event) => (_ctx.inputHover = false)), }, null, 8, ['modelValue', 'class', 'placeholder', 'prefix-icon'] )) : createCommentVNode('v-if', true), withDirectives( createVNode$1( _component_el_checkbox_group, { modelValue: _ctx.checked, 'onUpdate:modelValue': _cache[4] || (_cache[4] = ($event) => (_ctx.checked = $event)), class: normalizeClass([ _ctx.ns.is('filterable', _ctx.filterable), _ctx.ns.be('panel', 'list'), ]), }, { default: withCtx(() => [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.filteredData, (item2) => { return ( openBlock(), createBlock( _component_el_checkbox, { key: item2[_ctx.keyProp], class: normalizeClass( _ctx.ns.be('panel', 'item') ), label: item2[_ctx.keyProp], disabled: item2[_ctx.disabledProp], }, { default: withCtx(() => [ createVNode$1( _component_option_content, { option: _ctx.optionRender(item2), }, null, 8, ['option'] ), ]), _: 2, }, 1032, ['class', 'label', 'disabled'] ) ) }), 128 )), ]), _: 1, }, 8, ['modelValue', 'class'] ), [[vShow, !_ctx.hasNoMatch && _ctx.data.length > 0]] ), withDirectives( createElementVNode( 'p', { class: normalizeClass(_ctx.ns.be('panel', 'empty')), }, toDisplayString$1( _ctx.hasNoMatch ? _ctx.t('el.transfer.noMatch') : _ctx.t('el.transfer.noData') ), 3 ), [[vShow, _ctx.hasNoMatch || _ctx.data.length === 0]] ), ], 2 ), _ctx.hasFooter ? (openBlock(), createElementBlock( 'p', { key: 0, class: normalizeClass(_ctx.ns.be('panel', 'footer')), }, [renderSlot(_ctx.$slots, 'default')], 2 )) : createCommentVNode('v-if', true), ], 2 ) ) } var TransferPanel = /* @__PURE__ */ _export_sfc$1(_sfc_main$7k, [ ['render', _sfc_render$r], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/transfer/src/transfer-panel.vue', ], ]) const useComputedData = (props2) => { const propsKey = computed(() => props2.props.key) const dataObj = computed(() => { return props2.data.reduce( (o2, cur) => (o2[cur[propsKey.value]] = cur) && o2, {} ) }) const sourceData = computed(() => { return props2.data.filter( (item2) => !props2.modelValue.includes(item2[propsKey.value]) ) }) const targetData = computed(() => { if (props2.targetOrder === 'original') { return props2.data.filter((item2) => props2.modelValue.includes(item2[propsKey.value]) ) } else { return props2.modelValue.reduce((arr, cur) => { const val2 = dataObj.value[cur] if (val2) { arr.push(val2) } return arr }, []) } }) return { propsKey, sourceData, targetData, } } const LEFT_CHECK_CHANGE_EVENT = 'left-check-change' const RIGHT_CHECK_CHANGE_EVENT = 'right-check-change' const useCheckedChange = (checkedState, emit2) => { const onSourceCheckedChange = (val2, movedKeys) => { checkedState.leftChecked = val2 if (movedKeys === void 0) return emit2(LEFT_CHECK_CHANGE_EVENT, val2, movedKeys) } const onTargetCheckedChange = (val2, movedKeys) => { checkedState.rightChecked = val2 if (movedKeys === void 0) return emit2(RIGHT_CHECK_CHANGE_EVENT, val2, movedKeys) } return { onSourceCheckedChange, onTargetCheckedChange, } } const useMove = (props2, checkedState, propsKey, emit2) => { const _emit = (value2, type4, checked2) => { emit2(UPDATE_MODEL_EVENT, value2) emit2(CHANGE_EVENT, value2, type4, checked2) } const addToLeft = () => { const currentValue = props2.modelValue.slice() checkedState.rightChecked.forEach((item2) => { const index2 = currentValue.indexOf(item2) if (index2 > -1) { currentValue.splice(index2, 1) } }) _emit(currentValue, 'left', checkedState.rightChecked) } const addToRight = () => { let currentValue = props2.modelValue.slice() const itemsToBeMoved = props2.data .filter((item2) => { const itemKey = item2[propsKey.value] return ( checkedState.leftChecked.includes(itemKey) && !props2.modelValue.includes(itemKey) ) }) .map((item2) => item2[propsKey.value]) currentValue = props2.targetOrder === 'unshift' ? itemsToBeMoved.concat(currentValue) : currentValue.concat(itemsToBeMoved) if (props2.targetOrder === 'original') { currentValue = props2.data .filter((item2) => currentValue.includes(item2[propsKey.value])) .map((item2) => item2[propsKey.value]) } _emit(currentValue, 'right', checkedState.leftChecked) } return { addToLeft, addToRight, } } const _sfc_main$7j = defineComponent({ name: 'ElTransfer', components: { TransferPanel, ElButton, ElIcon, ArrowLeft: arrowLeft, ArrowRight: arrowRight, }, props: { data: { type: Array, default: () => [], }, titles: { type: Array, default: () => [], }, buttonTexts: { type: Array, default: () => [], }, filterPlaceholder: { type: String, default: '', }, filterMethod: Function, leftDefaultChecked: { type: Array, default: () => [], }, rightDefaultChecked: { type: Array, default: () => [], }, renderContent: Function, modelValue: { type: Array, default: () => [], }, format: { type: Object, default: () => ({}), }, filterable: { type: Boolean, default: false, }, props: { type: Object, default: () => ({ label: 'label', key: 'key', disabled: 'disabled', }), }, targetOrder: { type: String, default: 'original', validator: (val2) => { return ['original', 'push', 'unshift'].includes(val2) }, }, }, emits: [ UPDATE_MODEL_EVENT, CHANGE_EVENT, LEFT_CHECK_CHANGE_EVENT, RIGHT_CHECK_CHANGE_EVENT, ], setup(props2, { emit: emit2, slots }) { const { t: t3 } = useLocale() const ns = useNamespace('transfer') const elFormItem = inject(formItemContextKey, {}) const checkedState = reactive({ leftChecked: [], rightChecked: [], }) const { propsKey, sourceData, targetData } = useComputedData(props2) const { onSourceCheckedChange, onTargetCheckedChange } = useCheckedChange( checkedState, emit2 ) const { addToLeft, addToRight } = useMove( props2, checkedState, propsKey, emit2 ) const leftPanel = ref() const rightPanel = ref() const clearQuery = (which) => { switch (which) { case 'left': leftPanel.value.query = '' break case 'right': rightPanel.value.query = '' break } } const hasButtonTexts = computed(() => props2.buttonTexts.length === 2) const leftPanelTitle = computed( () => props2.titles[0] || t3('el.transfer.titles.0') ) const rightPanelTitle = computed( () => props2.titles[1] || t3('el.transfer.titles.1') ) const panelFilterPlaceholder = computed( () => props2.filterPlaceholder || t3('el.transfer.filterPlaceholder') ) watch$1( () => props2.modelValue, () => { var _a2 ;(_a2 = elFormItem.validate) == null ? void 0 : _a2.call(elFormItem, 'change').catch((err) => debugWarn()) } ) const optionRender = computed(() => (option2) => { if (props2.renderContent) return props2.renderContent(h$4, option2) if (slots.default) return slots.default({ option: option2 }) return h$4( 'span', option2[props2.props.label] || option2[props2.props.key] ) }) return { ns, sourceData, targetData, onSourceCheckedChange, onTargetCheckedChange, addToLeft, addToRight, ...toRefs$2(checkedState), hasButtonTexts, leftPanelTitle, rightPanelTitle, panelFilterPlaceholder, clearQuery, leftPanel, rightPanel, optionRender, } }, }) const _hoisted_1$68 = { key: 0 } const _hoisted_2$52 = { key: 0 } function _sfc_render$q(_ctx, _cache, $props2, $setup, $data, $options) { const _component_transfer_panel = resolveComponent('transfer-panel') const _component_arrow_left = resolveComponent('arrow-left') const _component_el_icon = resolveComponent('el-icon') const _component_el_button = resolveComponent('el-button') const _component_arrow_right = resolveComponent('arrow-right') return ( openBlock(), createElementBlock( 'div', { class: normalizeClass(_ctx.ns.b()), }, [ createVNode$1( _component_transfer_panel, { ref: 'leftPanel', data: _ctx.sourceData, 'option-render': _ctx.optionRender, placeholder: _ctx.panelFilterPlaceholder, title: _ctx.leftPanelTitle, filterable: _ctx.filterable, format: _ctx.format, 'filter-method': _ctx.filterMethod, 'default-checked': _ctx.leftDefaultChecked, props: _ctx.props, onCheckedChange: _ctx.onSourceCheckedChange, }, { default: withCtx(() => [renderSlot(_ctx.$slots, 'left-footer')]), _: 3, }, 8, [ 'data', 'option-render', 'placeholder', 'title', 'filterable', 'format', 'filter-method', 'default-checked', 'props', 'onCheckedChange', ] ), createElementVNode( 'div', { class: normalizeClass(_ctx.ns.e('buttons')), }, [ createVNode$1( _component_el_button, { type: 'primary', class: normalizeClass([ _ctx.ns.e('button'), _ctx.ns.is('with-texts', _ctx.hasButtonTexts), ]), disabled: _ctx.rightChecked.length === 0, onClick: _ctx.addToLeft, }, { default: withCtx(() => [ createVNode$1(_component_el_icon, null, { default: withCtx(() => [ createVNode$1(_component_arrow_left), ]), _: 1, }), _ctx.buttonTexts[0] !== void 0 ? (openBlock(), createElementBlock( 'span', _hoisted_1$68, toDisplayString$1(_ctx.buttonTexts[0]), 1 )) : createCommentVNode('v-if', true), ]), _: 1, }, 8, ['class', 'disabled', 'onClick'] ), createVNode$1( _component_el_button, { type: 'primary', class: normalizeClass([ _ctx.ns.e('button'), _ctx.ns.is('with-texts', _ctx.hasButtonTexts), ]), disabled: _ctx.leftChecked.length === 0, onClick: _ctx.addToRight, }, { default: withCtx(() => [ _ctx.buttonTexts[1] !== void 0 ? (openBlock(), createElementBlock( 'span', _hoisted_2$52, toDisplayString$1(_ctx.buttonTexts[1]), 1 )) : createCommentVNode('v-if', true), createVNode$1(_component_el_icon, null, { default: withCtx(() => [ createVNode$1(_component_arrow_right), ]), _: 1, }), ]), _: 1, }, 8, ['class', 'disabled', 'onClick'] ), ], 2 ), createVNode$1( _component_transfer_panel, { ref: 'rightPanel', data: _ctx.targetData, 'option-render': _ctx.optionRender, placeholder: _ctx.panelFilterPlaceholder, filterable: _ctx.filterable, format: _ctx.format, 'filter-method': _ctx.filterMethod, title: _ctx.rightPanelTitle, 'default-checked': _ctx.rightDefaultChecked, props: _ctx.props, onCheckedChange: _ctx.onTargetCheckedChange, }, { default: withCtx(() => [renderSlot(_ctx.$slots, 'right-footer')]), _: 3, }, 8, [ 'data', 'option-render', 'placeholder', 'filterable', 'format', 'filter-method', 'title', 'default-checked', 'props', 'onCheckedChange', ] ), ], 2 ) ) } var Transfer = /* @__PURE__ */ _export_sfc$1(_sfc_main$7j, [ ['render', _sfc_render$q], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/transfer/src/index.vue', ], ]) Transfer.install = (app2) => { app2.component(Transfer.name, Transfer) } const _Transfer = Transfer const ElTransfer = _Transfer const NODE_KEY = '$treeNodeId' const markNodeData = function (node2, data2) { if (!data2 || data2[NODE_KEY]) return Object.defineProperty(data2, NODE_KEY, { value: node2.id, enumerable: false, configurable: false, writable: false, }) } const getNodeKey = function (key2, data2) { if (!key2) return data2[NODE_KEY] return data2[key2] } const getChildState = (node2) => { let all3 = true let none = true let allWithoutDisable = true for (let i2 = 0, j2 = node2.length; i2 < j2; i2++) { const n2 = node2[i2] if (n2.checked !== true || n2.indeterminate) { all3 = false if (!n2.disabled) { allWithoutDisable = false } } if (n2.checked !== false || n2.indeterminate) { none = false } } return { all: all3, none, allWithoutDisable, half: !all3 && !none } } const reInitChecked = function (node2) { if (node2.childNodes.length === 0) return const { all: all3, none, half } = getChildState(node2.childNodes) if (all3) { node2.checked = true node2.indeterminate = false } else if (half) { node2.checked = false node2.indeterminate = true } else if (none) { node2.checked = false node2.indeterminate = false } const parent2 = node2.parent if (!parent2 || parent2.level === 0) return if (!node2.store.checkStrictly) { reInitChecked(parent2) } } const getPropertyFromData = function (node2, prop) { const props2 = node2.store.props const data2 = node2.data || {} const config2 = props2[prop] if (typeof config2 === 'function') { return config2(data2, node2) } else if (typeof config2 === 'string') { return data2[config2] } else if (typeof config2 === 'undefined') { const dataProp = data2[prop] return dataProp === void 0 ? '' : dataProp } } let nodeIdSeed = 0 class Node$2 { constructor(options2) { this.id = nodeIdSeed++ this.text = null this.checked = false this.indeterminate = false this.data = null this.expanded = false this.parent = null this.visible = true this.isCurrent = false this.canFocus = false for (const name2 in options2) { if (hasOwn$e(options2, name2)) { this[name2] = options2[name2] } } this.level = 0 this.loaded = false this.childNodes = [] this.loading = false if (this.parent) { this.level = this.parent.level + 1 } } initialize() { const store2 = this.store if (!store2) { throw new Error('[Node]store is required!') } store2.registerNode(this) const props2 = store2.props if (props2 && typeof props2.isLeaf !== 'undefined') { const isLeaf2 = getPropertyFromData(this, 'isLeaf') if (typeof isLeaf2 === 'boolean') { this.isLeafByUser = isLeaf2 } } if (store2.lazy !== true && this.data) { this.setData(this.data) if (store2.defaultExpandAll) { this.expanded = true this.canFocus = true } } else if (this.level > 0 && store2.lazy && store2.defaultExpandAll) { this.expand() } if (!Array.isArray(this.data)) { markNodeData(this, this.data) } if (!this.data) return const defaultExpandedKeys = store2.defaultExpandedKeys const key2 = store2.key if (key2 && defaultExpandedKeys && defaultExpandedKeys.includes(this.key)) { this.expand(null, store2.autoExpandParent) } if ( key2 && store2.currentNodeKey !== void 0 && this.key === store2.currentNodeKey ) { store2.currentNode = this store2.currentNode.isCurrent = true } if (store2.lazy) { store2._initDefaultCheckedNode(this) } this.updateLeafState() if (this.parent && (this.level === 1 || this.parent.expanded === true)) this.canFocus = true } setData(data2) { if (!Array.isArray(data2)) { markNodeData(this, data2) } this.data = data2 this.childNodes = [] let children if (this.level === 0 && Array.isArray(this.data)) { children = this.data } else { children = getPropertyFromData(this, 'children') || [] } for (let i2 = 0, j2 = children.length; i2 < j2; i2++) { this.insertChild({ data: children[i2] }) } } get label() { return getPropertyFromData(this, 'label') } get key() { const nodeKey = this.store.key if (this.data) return this.data[nodeKey] return null } get disabled() { return getPropertyFromData(this, 'disabled') } get nextSibling() { const parent2 = this.parent if (parent2) { const index2 = parent2.childNodes.indexOf(this) if (index2 > -1) { return parent2.childNodes[index2 + 1] } } return null } get previousSibling() { const parent2 = this.parent if (parent2) { const index2 = parent2.childNodes.indexOf(this) if (index2 > -1) { return index2 > 0 ? parent2.childNodes[index2 - 1] : null } } return null } contains(target2, deep = true) { return (this.childNodes || []).some( (child) => child === target2 || (deep && child.contains(target2)) ) } remove() { const parent2 = this.parent if (parent2) { parent2.removeChild(this) } } insertChild(child, index2, batch) { if (!child) throw new Error('InsertChild error: child is required.') if (!(child instanceof Node$2)) { if (!batch) { const children = this.getChildren(true) if (!children.includes(child.data)) { if (typeof index2 === 'undefined' || index2 < 0) { children.push(child.data) } else { children.splice(index2, 0, child.data) } } } Object.assign(child, { parent: this, store: this.store, }) child = reactive(new Node$2(child)) if (child instanceof Node$2) { child.initialize() } } child.level = this.level + 1 if (typeof index2 === 'undefined' || index2 < 0) { this.childNodes.push(child) } else { this.childNodes.splice(index2, 0, child) } this.updateLeafState() } insertBefore(child, ref2) { let index2 if (ref2) { index2 = this.childNodes.indexOf(ref2) } this.insertChild(child, index2) } insertAfter(child, ref2) { let index2 if (ref2) { index2 = this.childNodes.indexOf(ref2) if (index2 !== -1) index2 += 1 } this.insertChild(child, index2) } removeChild(child) { const children = this.getChildren() || [] const dataIndex = children.indexOf(child.data) if (dataIndex > -1) { children.splice(dataIndex, 1) } const index2 = this.childNodes.indexOf(child) if (index2 > -1) { this.store && this.store.deregisterNode(child) child.parent = null this.childNodes.splice(index2, 1) } this.updateLeafState() } removeChildByData(data2) { let targetNode = null for (let i2 = 0; i2 < this.childNodes.length; i2++) { if (this.childNodes[i2].data === data2) { targetNode = this.childNodes[i2] break } } if (targetNode) { this.removeChild(targetNode) } } expand(callback, expandParent) { const done = () => { if (expandParent) { let parent2 = this.parent while (parent2.level > 0) { parent2.expanded = true parent2 = parent2.parent } } this.expanded = true if (callback) callback() this.childNodes.forEach((item2) => { item2.canFocus = true }) } if (this.shouldLoadData()) { this.loadData((data2) => { if (Array.isArray(data2)) { if (this.checked) { this.setChecked(true, true) } else if (!this.store.checkStrictly) { reInitChecked(this) } done() } }) } else { done() } } doCreateChildren(array4, defaultProps2 = {}) { array4.forEach((item2) => { this.insertChild( Object.assign({ data: item2 }, defaultProps2), void 0, true ) }) } collapse() { this.expanded = false this.childNodes.forEach((item2) => { item2.canFocus = false }) } shouldLoadData() { return this.store.lazy === true && this.store.load && !this.loaded } updateLeafState() { if ( this.store.lazy === true && this.loaded !== true && typeof this.isLeafByUser !== 'undefined' ) { this.isLeaf = this.isLeafByUser return } const childNodes = this.childNodes if ( !this.store.lazy || (this.store.lazy === true && this.loaded === true) ) { this.isLeaf = !childNodes || childNodes.length === 0 return } this.isLeaf = false } setChecked(value2, deep, recursion, passValue) { this.indeterminate = value2 === 'half' this.checked = value2 === true if (this.store.checkStrictly) return if (!(this.shouldLoadData() && !this.store.checkDescendants)) { const { all: all3, allWithoutDisable } = getChildState(this.childNodes) if (!this.isLeaf && !all3 && allWithoutDisable) { this.checked = false value2 = false } const handleDescendants = () => { if (deep) { const childNodes = this.childNodes for (let i2 = 0, j2 = childNodes.length; i2 < j2; i2++) { const child = childNodes[i2] passValue = passValue || value2 !== false const isCheck = child.disabled ? child.checked : passValue child.setChecked(isCheck, deep, true, passValue) } const { half, all: all22 } = getChildState(childNodes) if (!all22) { this.checked = all22 this.indeterminate = half } } } if (this.shouldLoadData()) { this.loadData( () => { handleDescendants() reInitChecked(this) }, { checked: value2 !== false, } ) return } else { handleDescendants() } } const parent2 = this.parent if (!parent2 || parent2.level === 0) return if (!recursion) { reInitChecked(parent2) } } getChildren(forceInit = false) { if (this.level === 0) return this.data const data2 = this.data if (!data2) return null const props2 = this.store.props let children = 'children' if (props2) { children = props2.children || 'children' } if (data2[children] === void 0) { data2[children] = null } if (forceInit && !data2[children]) { data2[children] = [] } return data2[children] } updateChildren() { const newData = this.getChildren() || [] const oldData = this.childNodes.map((node2) => node2.data) const newDataMap = {} const newNodes = [] newData.forEach((item2, index2) => { const key2 = item2[NODE_KEY] const isNodeExists = !!key2 && oldData.findIndex((data2) => data2[NODE_KEY] === key2) >= 0 if (isNodeExists) { newDataMap[key2] = { index: index2, data: item2 } } else { newNodes.push({ index: index2, data: item2 }) } }) if (!this.store.lazy) { oldData.forEach((item2) => { if (!newDataMap[item2[NODE_KEY]]) this.removeChildByData(item2) }) } newNodes.forEach(({ index: index2, data: data2 }) => { this.insertChild({ data: data2 }, index2) }) this.updateLeafState() } loadData(callback, defaultProps2 = {}) { if ( this.store.lazy === true && this.store.load && !this.loaded && (!this.loading || Object.keys(defaultProps2).length) ) { this.loading = true const resolve2 = (children) => { this.loaded = true this.loading = false this.childNodes = [] this.doCreateChildren(children, defaultProps2) this.updateLeafState() if (callback) { callback.call(this, children) } } this.store.load(this, resolve2) } else { if (callback) { callback.call(this) } } } } class TreeStore { constructor(options2) { this.currentNode = null this.currentNodeKey = null for (const option2 in options2) { if (hasOwn$e(options2, option2)) { this[option2] = options2[option2] } } this.nodesMap = {} } initialize() { this.root = new Node$2({ data: this.data, store: this, }) this.root.initialize() if (this.lazy && this.load) { const loadFn = this.load loadFn(this.root, (data2) => { this.root.doCreateChildren(data2) this._initDefaultCheckedNodes() }) } else { this._initDefaultCheckedNodes() } } filter(value2) { const filterNodeMethod = this.filterNodeMethod const lazy = this.lazy const traverse = function (node2) { const childNodes = node2.root ? node2.root.childNodes : node2.childNodes childNodes.forEach((child) => { child.visible = filterNodeMethod.call(child, value2, child.data, child) traverse(child) }) if (!node2.visible && childNodes.length) { let allHidden = true allHidden = !childNodes.some((child) => child.visible) if (node2.root) { node2.root.visible = allHidden === false } else { node2.visible = allHidden === false } } if (!value2) return if (node2.visible && !node2.isLeaf && !lazy) node2.expand() } traverse(this) } setData(newVal) { const instanceChanged = newVal !== this.root.data if (instanceChanged) { this.root.setData(newVal) this._initDefaultCheckedNodes() } else { this.root.updateChildren() } } getNode(data2) { if (data2 instanceof Node$2) return data2 const key2 = typeof data2 !== 'object' ? data2 : getNodeKey(this.key, data2) return this.nodesMap[key2] || null } insertBefore(data2, refData) { const refNode = this.getNode(refData) refNode.parent.insertBefore({ data: data2 }, refNode) } insertAfter(data2, refData) { const refNode = this.getNode(refData) refNode.parent.insertAfter({ data: data2 }, refNode) } remove(data2) { const node2 = this.getNode(data2) if (node2 && node2.parent) { if (node2 === this.currentNode) { this.currentNode = null } node2.parent.removeChild(node2) } } append(data2, parentData) { const parentNode2 = parentData ? this.getNode(parentData) : this.root if (parentNode2) { parentNode2.insertChild({ data: data2 }) } } _initDefaultCheckedNodes() { const defaultCheckedKeys = this.defaultCheckedKeys || [] const nodesMap = this.nodesMap defaultCheckedKeys.forEach((checkedKey) => { const node2 = nodesMap[checkedKey] if (node2) { node2.setChecked(true, !this.checkStrictly) } }) } _initDefaultCheckedNode(node2) { const defaultCheckedKeys = this.defaultCheckedKeys || [] if (defaultCheckedKeys.includes(node2.key)) { node2.setChecked(true, !this.checkStrictly) } } setDefaultCheckedKey(newVal) { if (newVal !== this.defaultCheckedKeys) { this.defaultCheckedKeys = newVal this._initDefaultCheckedNodes() } } registerNode(node2) { const key2 = this.key if (!node2 || !node2.data) return if (!key2) { this.nodesMap[node2.id] = node2 } else { const nodeKey = node2.key if (nodeKey !== void 0) this.nodesMap[node2.key] = node2 } } deregisterNode(node2) { const key2 = this.key if (!key2 || !node2 || !node2.data) return node2.childNodes.forEach((child) => { this.deregisterNode(child) }) delete this.nodesMap[node2.key] } getCheckedNodes(leafOnly = false, includeHalfChecked = false) { const checkedNodes = [] const traverse = function (node2) { const childNodes = node2.root ? node2.root.childNodes : node2.childNodes childNodes.forEach((child) => { if ( (child.checked || (includeHalfChecked && child.indeterminate)) && (!leafOnly || (leafOnly && child.isLeaf)) ) { checkedNodes.push(child.data) } traverse(child) }) } traverse(this) return checkedNodes } getCheckedKeys(leafOnly = false) { return this.getCheckedNodes(leafOnly).map( (data2) => (data2 || {})[this.key] ) } getHalfCheckedNodes() { const nodes = [] const traverse = function (node2) { const childNodes = node2.root ? node2.root.childNodes : node2.childNodes childNodes.forEach((child) => { if (child.indeterminate) { nodes.push(child.data) } traverse(child) }) } traverse(this) return nodes } getHalfCheckedKeys() { return this.getHalfCheckedNodes().map((data2) => (data2 || {})[this.key]) } _getAllNodes() { const allNodes = [] const nodesMap = this.nodesMap for (const nodeKey in nodesMap) { if (hasOwn$e(nodesMap, nodeKey)) { allNodes.push(nodesMap[nodeKey]) } } return allNodes } updateChildren(key2, data2) { const node2 = this.nodesMap[key2] if (!node2) return const childNodes = node2.childNodes for (let i2 = childNodes.length - 1; i2 >= 0; i2--) { const child = childNodes[i2] this.remove(child.data) } for (let i2 = 0, j2 = data2.length; i2 < j2; i2++) { const child = data2[i2] this.append(child, node2.data) } } _setCheckedKeys(key2, leafOnly = false, checkedKeys) { const allNodes = this._getAllNodes().sort((a2, b2) => b2.level - a2.level) const cache2 = /* @__PURE__ */ Object.create(null) const keys3 = Object.keys(checkedKeys) allNodes.forEach((node2) => node2.setChecked(false, false)) for (let i2 = 0, j2 = allNodes.length; i2 < j2; i2++) { const node2 = allNodes[i2] const nodeKey = node2.data[key2].toString() const checked2 = keys3.includes(nodeKey) if (!checked2) { if (node2.checked && !cache2[nodeKey]) { node2.setChecked(false, false) } continue } let parent2 = node2.parent while (parent2 && parent2.level > 0) { cache2[parent2.data[key2]] = true parent2 = parent2.parent } if (node2.isLeaf || this.checkStrictly) { node2.setChecked(true, false) continue } node2.setChecked(true, true) if (leafOnly) { node2.setChecked(false, false) const traverse = function (node22) { const childNodes = node22.childNodes childNodes.forEach((child) => { if (!child.isLeaf) { child.setChecked(false, false) } traverse(child) }) } traverse(node2) } } } setCheckedNodes(array4, leafOnly = false) { const key2 = this.key const checkedKeys = {} array4.forEach((item2) => { checkedKeys[(item2 || {})[key2]] = true }) this._setCheckedKeys(key2, leafOnly, checkedKeys) } setCheckedKeys(keys3, leafOnly = false) { this.defaultCheckedKeys = keys3 const key2 = this.key const checkedKeys = {} keys3.forEach((key22) => { checkedKeys[key22] = true }) this._setCheckedKeys(key2, leafOnly, checkedKeys) } setDefaultExpandedKeys(keys3) { keys3 = keys3 || [] this.defaultExpandedKeys = keys3 keys3.forEach((key2) => { const node2 = this.getNode(key2) if (node2) node2.expand(null, this.autoExpandParent) }) } setChecked(data2, checked2, deep) { const node2 = this.getNode(data2) if (node2) { node2.setChecked(!!checked2, deep) } } getCurrentNode() { return this.currentNode } setCurrentNode(currentNode) { const prevCurrentNode = this.currentNode if (prevCurrentNode) { prevCurrentNode.isCurrent = false } this.currentNode = currentNode this.currentNode.isCurrent = true } setUserCurrentNode(node2, shouldAutoExpandParent = true) { const key2 = node2[this.key] const currNode = this.nodesMap[key2] this.setCurrentNode(currNode) if (shouldAutoExpandParent && this.currentNode.level > 1) { this.currentNode.parent.expand(null, true) } } setCurrentNodeKey(key2, shouldAutoExpandParent = true) { if (key2 === null || key2 === void 0) { this.currentNode && (this.currentNode.isCurrent = false) this.currentNode = null return } const node2 = this.getNode(key2) if (node2) { this.setCurrentNode(node2) if (shouldAutoExpandParent && this.currentNode.level > 1) { this.currentNode.parent.expand(null, true) } } } } const _sfc_main$7i = defineComponent({ name: 'ElTreeNodeContent', props: { node: { type: Object, required: true, }, renderContent: Function, }, setup(props2) { const ns = useNamespace('tree') const nodeInstance = inject('NodeInstance') const tree = inject('RootTree') return () => { const node2 = props2.node const { data: data2, store: store2 } = node2 return props2.renderContent ? props2.renderContent(h$4, { _self: nodeInstance, node: node2, data: data2, store: store2, }) : tree.ctx.slots.default ? tree.ctx.slots.default({ node: node2, data: data2 }) : h$4('span', { class: ns.be('node', 'label') }, [node2.label]) } }, }) var NodeContent = /* @__PURE__ */ _export_sfc$1(_sfc_main$7i, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/tree/src/tree-node-content.vue', ], ]) function useNodeExpandEventBroadcast(props2) { const parentNodeMap = inject('TreeNodeMap', null) const currentNodeMap = { treeNodeExpand: (node2) => { if (props2.node !== node2) { props2.node.collapse() } }, children: [], } if (parentNodeMap) { parentNodeMap.children.push(currentNodeMap) } provide('TreeNodeMap', currentNodeMap) return { broadcastExpanded: (node2) => { if (!props2.accordion) return for (const childNode of currentNodeMap.children) { childNode.treeNodeExpand(node2) } }, } } const dragEventsKey = Symbol('dragEvents') function useDragNodeHandler({ props: props2, ctx, el$, dropIndicator$, store: store2, }) { const ns = useNamespace('tree') const dragState = ref({ showDropIndicator: false, draggingNode: null, dropNode: null, allowDrop: true, dropType: null, }) const treeNodeDragStart = ({ event, treeNode }) => { if ( typeof props2.allowDrag === 'function' && !props2.allowDrag(treeNode.node) ) { event.preventDefault() return false } event.dataTransfer.effectAllowed = 'move' try { event.dataTransfer.setData('text/plain', '') } catch (e2) {} dragState.value.draggingNode = treeNode ctx.emit('node-drag-start', treeNode.node, event) } const treeNodeDragOver = ({ event, treeNode }) => { const dropNode = treeNode const oldDropNode = dragState.value.dropNode if (oldDropNode && oldDropNode !== dropNode) { removeClass$1(oldDropNode.$el, ns.is('drop-inner')) } const draggingNode = dragState.value.draggingNode if (!draggingNode || !dropNode) return let dropPrev = true let dropInner = true let dropNext = true let userAllowDropInner = true if (typeof props2.allowDrop === 'function') { dropPrev = props2.allowDrop(draggingNode.node, dropNode.node, 'prev') userAllowDropInner = dropInner = props2.allowDrop( draggingNode.node, dropNode.node, 'inner' ) dropNext = props2.allowDrop(draggingNode.node, dropNode.node, 'next') } event.dataTransfer.dropEffect = dropInner || dropPrev || dropNext ? 'move' : 'none' if ((dropPrev || dropInner || dropNext) && oldDropNode !== dropNode) { if (oldDropNode) { ctx.emit('node-drag-leave', draggingNode.node, oldDropNode.node, event) } ctx.emit('node-drag-enter', draggingNode.node, dropNode.node, event) } if (dropPrev || dropInner || dropNext) { dragState.value.dropNode = dropNode } if (dropNode.node.nextSibling === draggingNode.node) { dropNext = false } if (dropNode.node.previousSibling === draggingNode.node) { dropPrev = false } if (dropNode.node.contains(draggingNode.node, false)) { dropInner = false } if ( draggingNode.node === dropNode.node || draggingNode.node.contains(dropNode.node) ) { dropPrev = false dropInner = false dropNext = false } const targetPosition = dropNode.$el.getBoundingClientRect() const treePosition = el$.value.getBoundingClientRect() let dropType const prevPercent = dropPrev ? (dropInner ? 0.25 : dropNext ? 0.45 : 1) : -1 const nextPercent = dropNext ? (dropInner ? 0.75 : dropPrev ? 0.55 : 0) : 1 let indicatorTop = -9999 const distance2 = event.clientY - targetPosition.top if (distance2 < targetPosition.height * prevPercent) { dropType = 'before' } else if (distance2 > targetPosition.height * nextPercent) { dropType = 'after' } else if (dropInner) { dropType = 'inner' } else { dropType = 'none' } const iconPosition = dropNode.$el .querySelector(`.${ns.be('node', 'expand-icon')}`) .getBoundingClientRect() const dropIndicator = dropIndicator$.value if (dropType === 'before') { indicatorTop = iconPosition.top - treePosition.top } else if (dropType === 'after') { indicatorTop = iconPosition.bottom - treePosition.top } dropIndicator.style.top = `${indicatorTop}px` dropIndicator.style.left = `${iconPosition.right - treePosition.left}px` if (dropType === 'inner') { addClass$1(dropNode.$el, ns.is('drop-inner')) } else { removeClass$1(dropNode.$el, ns.is('drop-inner')) } dragState.value.showDropIndicator = dropType === 'before' || dropType === 'after' dragState.value.allowDrop = dragState.value.showDropIndicator || userAllowDropInner dragState.value.dropType = dropType ctx.emit('node-drag-over', draggingNode.node, dropNode.node, event) } const treeNodeDragEnd = (event) => { const { draggingNode, dropType, dropNode } = dragState.value event.preventDefault() event.dataTransfer.dropEffect = 'move' if (draggingNode && dropNode) { const draggingNodeCopy = { data: draggingNode.node.data } if (dropType !== 'none') { draggingNode.node.remove() } if (dropType === 'before') { dropNode.node.parent.insertBefore(draggingNodeCopy, dropNode.node) } else if (dropType === 'after') { dropNode.node.parent.insertAfter(draggingNodeCopy, dropNode.node) } else if (dropType === 'inner') { dropNode.node.insertChild(draggingNodeCopy) } if (dropType !== 'none') { store2.value.registerNode(draggingNodeCopy) } removeClass$1(dropNode.$el, ns.is('drop-inner')) ctx.emit( 'node-drag-end', draggingNode.node, dropNode.node, dropType, event ) if (dropType !== 'none') { ctx.emit('node-drop', draggingNode.node, dropNode.node, dropType, event) } } if (draggingNode && !dropNode) { ctx.emit('node-drag-end', draggingNode.node, null, dropType, event) } dragState.value.showDropIndicator = false dragState.value.draggingNode = null dragState.value.dropNode = null dragState.value.allowDrop = true } provide(dragEventsKey, { treeNodeDragStart, treeNodeDragOver, treeNodeDragEnd, }) return { dragState, } } const _sfc_main$7h = defineComponent({ name: 'ElTreeNode', components: { ElCollapseTransition: _CollapseTransition, ElCheckbox, NodeContent, ElIcon, Loading: loading, }, props: { node: { type: Node$2, default: () => ({}), }, props: { type: Object, default: () => ({}), }, accordion: Boolean, renderContent: Function, renderAfterExpand: Boolean, showCheckbox: { type: Boolean, default: false, }, }, emits: ['node-expand'], setup(props2, ctx) { const ns = useNamespace('tree') const { broadcastExpanded } = useNodeExpandEventBroadcast(props2) const tree = inject('RootTree') const expanded = ref(false) const childNodeRendered = ref(false) const oldChecked = ref(null) const oldIndeterminate = ref(null) const node$ = ref(null) const dragEvents = inject(dragEventsKey) const instance = getCurrentInstance() provide('NodeInstance', instance) if (props2.node.expanded) { expanded.value = true childNodeRendered.value = true } const childrenKey = tree.props['children'] || 'children' watch$1( () => { const children = props2.node.data[childrenKey] return children && [...children] }, () => { props2.node.updateChildren() } ) watch$1( () => props2.node.indeterminate, (val2) => { handleSelectChange(props2.node.checked, val2) } ) watch$1( () => props2.node.checked, (val2) => { handleSelectChange(val2, props2.node.indeterminate) } ) watch$1( () => props2.node.expanded, (val2) => { nextTick(() => (expanded.value = val2)) if (val2) { childNodeRendered.value = true } } ) const getNodeKey$1 = (node2) => { return getNodeKey(tree.props.nodeKey, node2.data) } const getNodeClass = (node2) => { const nodeClassFunc = props2.props.class if (!nodeClassFunc) { return {} } let className if (isFunction$l(nodeClassFunc)) { const { data: data2 } = node2 className = nodeClassFunc(data2, node2) } else { className = nodeClassFunc } if (isString$f(className)) { return { [className]: true } } else { return className } } const handleSelectChange = (checked2, indeterminate) => { if ( oldChecked.value !== checked2 || oldIndeterminate.value !== indeterminate ) { tree.ctx.emit('check-change', props2.node.data, checked2, indeterminate) } oldChecked.value = checked2 oldIndeterminate.value = indeterminate } const handleClick2 = (e2) => { const store2 = tree.store.value store2.setCurrentNode(props2.node) tree.ctx.emit( 'current-change', store2.currentNode ? store2.currentNode.data : null, store2.currentNode ) tree.currentNode.value = props2.node if (tree.props.expandOnClickNode) { handleExpandIconClick() } if (tree.props.checkOnClickNode && !props2.node.disabled) { handleCheckChange(null, { target: { checked: !props2.node.checked }, }) } tree.ctx.emit('node-click', props2.node.data, props2.node, instance, e2) } const handleContextMenu = (event) => { if (tree.instance.vnode.props['onNodeContextmenu']) { event.stopPropagation() event.preventDefault() } tree.ctx.emit( 'node-contextmenu', event, props2.node.data, props2.node, instance ) } const handleExpandIconClick = () => { if (props2.node.isLeaf) return if (expanded.value) { tree.ctx.emit('node-collapse', props2.node.data, props2.node, instance) props2.node.collapse() } else { props2.node.expand() ctx.emit('node-expand', props2.node.data, props2.node, instance) } } const handleCheckChange = (value2, ev) => { props2.node.setChecked(ev.target.checked, !tree.props.checkStrictly) nextTick(() => { const store2 = tree.store.value tree.ctx.emit('check', props2.node.data, { checkedNodes: store2.getCheckedNodes(), checkedKeys: store2.getCheckedKeys(), halfCheckedNodes: store2.getHalfCheckedNodes(), halfCheckedKeys: store2.getHalfCheckedKeys(), }) }) } const handleChildNodeExpand = (nodeData, node2, instance2) => { broadcastExpanded(node2) tree.ctx.emit('node-expand', nodeData, node2, instance2) } const handleDragStart = (event) => { if (!tree.props.draggable) return dragEvents.treeNodeDragStart({ event, treeNode: props2 }) } const handleDragOver = (event) => { event.preventDefault() if (!tree.props.draggable) return dragEvents.treeNodeDragOver({ event, treeNode: { $el: node$.value, node: props2.node }, }) } const handleDrop = (event) => { event.preventDefault() } const handleDragEnd2 = (event) => { if (!tree.props.draggable) return dragEvents.treeNodeDragEnd(event) } return { ns, node$, tree, expanded, childNodeRendered, oldChecked, oldIndeterminate, getNodeKey: getNodeKey$1, getNodeClass, handleSelectChange, handleClick: handleClick2, handleContextMenu, handleExpandIconClick, handleCheckChange, handleChildNodeExpand, handleDragStart, handleDragOver, handleDrop, handleDragEnd: handleDragEnd2, CaretRight: caretRight, } }, }) const _hoisted_1$67 = [ 'aria-expanded', 'aria-disabled', 'aria-checked', 'draggable', 'data-key', ] const _hoisted_2$51 = ['aria-expanded'] function _sfc_render$p(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_icon = resolveComponent('el-icon') const _component_el_checkbox = resolveComponent('el-checkbox') const _component_loading = resolveComponent('loading') const _component_node_content = resolveComponent('node-content') const _component_el_tree_node = resolveComponent('el-tree-node') const _component_el_collapse_transition = resolveComponent( 'el-collapse-transition' ) return withDirectives( (openBlock(), createElementBlock( 'div', { ref: 'node$', class: normalizeClass([ _ctx.ns.b('node'), _ctx.ns.is('expanded', _ctx.expanded), _ctx.ns.is('current', _ctx.node.isCurrent), _ctx.ns.is('hidden', !_ctx.node.visible), _ctx.ns.is('focusable', !_ctx.node.disabled), _ctx.ns.is('checked', !_ctx.node.disabled && _ctx.node.checked), _ctx.getNodeClass(_ctx.node), ]), role: 'treeitem', tabindex: '-1', 'aria-expanded': _ctx.expanded, 'aria-disabled': _ctx.node.disabled, 'aria-checked': _ctx.node.checked, draggable: _ctx.tree.props.draggable, 'data-key': _ctx.getNodeKey(_ctx.node), onClick: _cache[1] || (_cache[1] = withModifiers( (...args) => _ctx.handleClick && _ctx.handleClick(...args), ['stop'] )), onContextmenu: _cache[2] || (_cache[2] = (...args) => _ctx.handleContextMenu && _ctx.handleContextMenu(...args)), onDragstart: _cache[3] || (_cache[3] = withModifiers( (...args) => _ctx.handleDragStart && _ctx.handleDragStart(...args), ['stop'] )), onDragover: _cache[4] || (_cache[4] = withModifiers( (...args) => _ctx.handleDragOver && _ctx.handleDragOver(...args), ['stop'] )), onDragend: _cache[5] || (_cache[5] = withModifiers( (...args) => _ctx.handleDragEnd && _ctx.handleDragEnd(...args), ['stop'] )), onDrop: _cache[6] || (_cache[6] = withModifiers( (...args) => _ctx.handleDrop && _ctx.handleDrop(...args), ['stop'] )), }, [ createElementVNode( 'div', { class: normalizeClass(_ctx.ns.be('node', 'content')), style: normalizeStyle$1({ paddingLeft: (_ctx.node.level - 1) * _ctx.tree.props.indent + 'px', }), }, [ _ctx.tree.props.icon || _ctx.CaretRight ? (openBlock(), createBlock( _component_el_icon, { key: 0, class: normalizeClass([ _ctx.ns.be('node', 'expand-icon'), _ctx.ns.is('leaf', _ctx.node.isLeaf), { expanded: !_ctx.node.isLeaf && _ctx.expanded, }, ]), onClick: withModifiers(_ctx.handleExpandIconClick, [ 'stop', ]), }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent( _ctx.tree.props.icon || _ctx.CaretRight ) )), ]), _: 1, }, 8, ['class', 'onClick'] )) : createCommentVNode('v-if', true), _ctx.showCheckbox ? (openBlock(), createBlock( _component_el_checkbox, { key: 1, 'model-value': _ctx.node.checked, indeterminate: _ctx.node.indeterminate, disabled: !!_ctx.node.disabled, onClick: _cache[0] || (_cache[0] = withModifiers(() => {}, ['stop'])), onChange: _ctx.handleCheckChange, }, null, 8, ['model-value', 'indeterminate', 'disabled', 'onChange'] )) : createCommentVNode('v-if', true), _ctx.node.loading ? (openBlock(), createBlock( _component_el_icon, { key: 2, class: normalizeClass([ _ctx.ns.be('node', 'loading-icon'), _ctx.ns.is('loading'), ]), }, { default: withCtx(() => [createVNode$1(_component_loading)]), _: 1, }, 8, ['class'] )) : createCommentVNode('v-if', true), createVNode$1( _component_node_content, { node: _ctx.node, 'render-content': _ctx.renderContent, }, null, 8, ['node', 'render-content'] ), ], 6 ), createVNode$1(_component_el_collapse_transition, null, { default: withCtx(() => [ !_ctx.renderAfterExpand || _ctx.childNodeRendered ? withDirectives( (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass(_ctx.ns.be('node', 'children')), role: 'group', 'aria-expanded': _ctx.expanded, }, [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.node.childNodes, (child) => { return ( openBlock(), createBlock( _component_el_tree_node, { key: _ctx.getNodeKey(child), 'render-content': _ctx.renderContent, 'render-after-expand': _ctx.renderAfterExpand, 'show-checkbox': _ctx.showCheckbox, node: child, accordion: _ctx.accordion, props: _ctx.props, onNodeExpand: _ctx.handleChildNodeExpand, }, null, 8, [ 'render-content', 'render-after-expand', 'show-checkbox', 'node', 'accordion', 'props', 'onNodeExpand', ] ) ) }), 128 )), ], 10, _hoisted_2$51 )), [[vShow, _ctx.expanded]] ) : createCommentVNode('v-if', true), ]), _: 1, }), ], 42, _hoisted_1$67 )), [[vShow, _ctx.node.visible]] ) } var ElTreeNode$1 = /* @__PURE__ */ _export_sfc$1(_sfc_main$7h, [ ['render', _sfc_render$p], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/tree/src/tree-node.vue', ], ]) function useKeydown({ el$ }, store2) { const ns = useNamespace('tree') const treeItems = shallowRef([]) const checkboxItems = shallowRef([]) onMounted(() => { initTabIndex() on$2(el$.value, 'keydown', handleKeydown) }) onBeforeUnmount(() => { off$1(el$.value, 'keydown', handleKeydown) }) onUpdated(() => { treeItems.value = Array.from(el$.value.querySelectorAll('[role=treeitem]')) checkboxItems.value = Array.from( el$.value.querySelectorAll('input[type=checkbox]') ) }) watch$1(checkboxItems, (val2) => { val2.forEach((checkbox2) => { checkbox2.setAttribute('tabindex', '-1') }) }) const handleKeydown = (ev) => { const currentItem = ev.target if (!currentItem.className.includes(ns.b('node'))) return const code2 = ev.code treeItems.value = Array.from( el$.value.querySelectorAll(`.${ns.is('focusable')}[role=treeitem]`) ) const currentIndex = treeItems.value.indexOf(currentItem) let nextIndex if ([EVENT_CODE.up, EVENT_CODE.down].includes(code2)) { ev.preventDefault() if (code2 === EVENT_CODE.up) { nextIndex = currentIndex === -1 ? 0 : currentIndex !== 0 ? currentIndex - 1 : treeItems.value.length - 1 const startIndex = nextIndex while (true) { if ( store2.value.getNode(treeItems.value[nextIndex].dataset.key) .canFocus ) break nextIndex-- if (nextIndex === startIndex) { nextIndex = -1 break } if (nextIndex < 0) { nextIndex = treeItems.value.length - 1 } } } else { nextIndex = currentIndex === -1 ? 0 : currentIndex < treeItems.value.length - 1 ? currentIndex + 1 : 0 const startIndex = nextIndex while (true) { if ( store2.value.getNode(treeItems.value[nextIndex].dataset.key) .canFocus ) break nextIndex++ if (nextIndex === startIndex) { nextIndex = -1 break } if (nextIndex >= treeItems.value.length) { nextIndex = 0 } } } nextIndex !== -1 && treeItems.value[nextIndex].focus() } if ([EVENT_CODE.left, EVENT_CODE.right].includes(code2)) { ev.preventDefault() currentItem.click() } const hasInput = currentItem.querySelector('[type="checkbox"]') if ([EVENT_CODE.enter, EVENT_CODE.space].includes(code2) && hasInput) { ev.preventDefault() hasInput.click() } } const initTabIndex = () => { var _a2 treeItems.value = Array.from( el$.value.querySelectorAll(`.${ns.is('focusable')}[role=treeitem]`) ) checkboxItems.value = Array.from( el$.value.querySelectorAll('input[type=checkbox]') ) const checkedItem = el$.value.querySelectorAll( `.${ns.is('checked')}[role=treeitem]` ) if (checkedItem.length) { checkedItem[0].setAttribute('tabindex', '0') return } ;(_a2 = treeItems.value[0]) == null ? void 0 : _a2.setAttribute('tabindex', '0') } } const _sfc_main$7g = defineComponent({ name: 'ElTree', components: { ElTreeNode: ElTreeNode$1 }, props: { data: { type: Array, default: () => [], }, emptyText: { type: String, }, renderAfterExpand: { type: Boolean, default: true, }, nodeKey: String, checkStrictly: Boolean, defaultExpandAll: Boolean, expandOnClickNode: { type: Boolean, default: true, }, checkOnClickNode: Boolean, checkDescendants: { type: Boolean, default: false, }, autoExpandParent: { type: Boolean, default: true, }, defaultCheckedKeys: Array, defaultExpandedKeys: Array, currentNodeKey: [String, Number], renderContent: Function, showCheckbox: { type: Boolean, default: false, }, draggable: { type: Boolean, default: false, }, allowDrag: Function, allowDrop: Function, props: { type: Object, default: () => ({ children: 'children', label: 'label', disabled: 'disabled', }), }, lazy: { type: Boolean, default: false, }, highlightCurrent: Boolean, load: Function, filterNodeMethod: Function, accordion: Boolean, indent: { type: Number, default: 18, }, icon: [String, Object], }, emits: [ 'check-change', 'current-change', 'node-click', 'node-contextmenu', 'node-collapse', 'node-expand', 'check', 'node-drag-start', 'node-drag-end', 'node-drop', 'node-drag-leave', 'node-drag-enter', 'node-drag-over', ], setup(props2, ctx) { const { t: t3 } = useLocale() const ns = useNamespace('tree') const store2 = ref( new TreeStore({ key: props2.nodeKey, data: props2.data, lazy: props2.lazy, props: props2.props, load: props2.load, currentNodeKey: props2.currentNodeKey, checkStrictly: props2.checkStrictly, checkDescendants: props2.checkDescendants, defaultCheckedKeys: props2.defaultCheckedKeys, defaultExpandedKeys: props2.defaultExpandedKeys, autoExpandParent: props2.autoExpandParent, defaultExpandAll: props2.defaultExpandAll, filterNodeMethod: props2.filterNodeMethod, }) ) store2.value.initialize() const root2 = ref(store2.value.root) const currentNode = ref(null) const el$ = ref(null) const dropIndicator$ = ref(null) const { broadcastExpanded } = useNodeExpandEventBroadcast(props2) const { dragState } = useDragNodeHandler({ props: props2, ctx, el$, dropIndicator$, store: store2, }) useKeydown({ el$ }, store2) const isEmpty2 = computed(() => { const { childNodes } = root2.value return ( !childNodes || childNodes.length === 0 || childNodes.every(({ visible }) => !visible) ) }) watch$1( () => props2.defaultCheckedKeys, (newVal) => { store2.value.setDefaultCheckedKey(newVal) } ) watch$1( () => props2.defaultExpandedKeys, (newVal) => { store2.value.setDefaultExpandedKeys(newVal) } ) watch$1( () => props2.data, (newVal) => { store2.value.setData(newVal) }, { deep: true } ) watch$1( () => props2.checkStrictly, (newVal) => { store2.value.checkStrictly = newVal } ) const filter2 = (value2) => { if (!props2.filterNodeMethod) throw new Error('[Tree] filterNodeMethod is required when filter') store2.value.filter(value2) } const getNodeKey$1 = (node2) => { return getNodeKey(props2.nodeKey, node2.data) } const getNodePath = (data2) => { if (!props2.nodeKey) throw new Error('[Tree] nodeKey is required in getNodePath') const node2 = store2.value.getNode(data2) if (!node2) return [] const path = [node2.data] let parent2 = node2.parent while (parent2 && parent2 !== root2.value) { path.push(parent2.data) parent2 = parent2.parent } return path.reverse() } const getCheckedNodes = (leafOnly, includeHalfChecked) => { return store2.value.getCheckedNodes(leafOnly, includeHalfChecked) } const getCheckedKeys = (leafOnly) => { return store2.value.getCheckedKeys(leafOnly) } const getCurrentNode = () => { const currentNode2 = store2.value.getCurrentNode() return currentNode2 ? currentNode2.data : null } const getCurrentKey = () => { if (!props2.nodeKey) throw new Error('[Tree] nodeKey is required in getCurrentKey') const currentNode2 = getCurrentNode() return currentNode2 ? currentNode2[props2.nodeKey] : null } const setCheckedNodes = (nodes, leafOnly) => { if (!props2.nodeKey) throw new Error('[Tree] nodeKey is required in setCheckedNodes') store2.value.setCheckedNodes(nodes, leafOnly) } const setCheckedKeys = (keys3, leafOnly) => { if (!props2.nodeKey) throw new Error('[Tree] nodeKey is required in setCheckedKeys') store2.value.setCheckedKeys(keys3, leafOnly) } const setChecked = (data2, checked2, deep) => { store2.value.setChecked(data2, checked2, deep) } const getHalfCheckedNodes = () => { return store2.value.getHalfCheckedNodes() } const getHalfCheckedKeys = () => { return store2.value.getHalfCheckedKeys() } const setCurrentNode = (node2, shouldAutoExpandParent = true) => { if (!props2.nodeKey) throw new Error('[Tree] nodeKey is required in setCurrentNode') store2.value.setUserCurrentNode(node2, shouldAutoExpandParent) } const setCurrentKey = (key2, shouldAutoExpandParent = true) => { if (!props2.nodeKey) throw new Error('[Tree] nodeKey is required in setCurrentKey') store2.value.setCurrentNodeKey(key2, shouldAutoExpandParent) } const getNode = (data2) => { return store2.value.getNode(data2) } const remove2 = (data2) => { store2.value.remove(data2) } const append = (data2, parentNode2) => { store2.value.append(data2, parentNode2) } const insertBefore2 = (data2, refNode) => { store2.value.insertBefore(data2, refNode) } const insertAfter = (data2, refNode) => { store2.value.insertAfter(data2, refNode) } const handleNodeExpand = (nodeData, node2, instance) => { broadcastExpanded(node2) ctx.emit('node-expand', nodeData, node2, instance) } const updateKeyChildren = (key2, data2) => { if (!props2.nodeKey) throw new Error('[Tree] nodeKey is required in updateKeyChild') store2.value.updateChildren(key2, data2) } provide('RootTree', { ctx, props: props2, store: store2, root: root2, currentNode, instance: getCurrentInstance(), }) return { ns, store: store2, root: root2, currentNode, dragState, el$, dropIndicator$, isEmpty: isEmpty2, filter: filter2, getNodeKey: getNodeKey$1, getNodePath, getCheckedNodes, getCheckedKeys, getCurrentNode, getCurrentKey, setCheckedNodes, setCheckedKeys, setChecked, getHalfCheckedNodes, getHalfCheckedKeys, setCurrentNode, setCurrentKey, t: t3, getNode, remove: remove2, append, insertBefore: insertBefore2, insertAfter, handleNodeExpand, updateKeyChildren, } }, }) function _sfc_render$o(_ctx, _cache, $props2, $setup, $data, $options) { var _a2 const _component_el_tree_node = resolveComponent('el-tree-node') return ( openBlock(), createElementBlock( 'div', { ref: 'el$', class: normalizeClass([ _ctx.ns.b(), _ctx.ns.is('dragging', !!_ctx.dragState.draggingNode), _ctx.ns.is('drop-not-allow', !_ctx.dragState.allowDrop), _ctx.ns.is('drop-inner', _ctx.dragState.dropType === 'inner'), { [_ctx.ns.m('highlight-current')]: _ctx.highlightCurrent }, ]), role: 'tree', }, [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.root.childNodes, (child) => { return ( openBlock(), createBlock( _component_el_tree_node, { key: _ctx.getNodeKey(child), node: child, props: _ctx.props, accordion: _ctx.accordion, 'render-after-expand': _ctx.renderAfterExpand, 'show-checkbox': _ctx.showCheckbox, 'render-content': _ctx.renderContent, onNodeExpand: _ctx.handleNodeExpand, }, null, 8, [ 'node', 'props', 'accordion', 'render-after-expand', 'show-checkbox', 'render-content', 'onNodeExpand', ] ) ) }), 128 )), _ctx.isEmpty ? (openBlock(), createElementBlock( 'div', { key: 0, class: normalizeClass(_ctx.ns.e('empty-block')), }, [ createElementVNode( 'span', { class: normalizeClass(_ctx.ns.e('empty-text')), }, toDisplayString$1( (_a2 = _ctx.emptyText) != null ? _a2 : _ctx.t('el.tree.emptyText') ), 3 ), ], 2 )) : createCommentVNode('v-if', true), withDirectives( createElementVNode( 'div', { ref: 'dropIndicator$', class: normalizeClass(_ctx.ns.e('drop-indicator')), }, null, 2 ), [[vShow, _ctx.dragState.showDropIndicator]] ), ], 2 ) ) } var Tree$2 = /* @__PURE__ */ _export_sfc$1(_sfc_main$7g, [ ['render', _sfc_render$o], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/tree/src/tree.vue', ], ]) Tree$2.install = (app2) => { app2.component(Tree$2.name, Tree$2) } const _Tree = Tree$2 const ElTree = _Tree const useSelect = (props2, { attrs }, { tree, key: key2 }) => { const ns = useNamespace('tree-select') const result = { ...pick$3(toRefs$2(props2), Object.keys(ElSelect.props)), ...attrs, valueKey: key2, popperClass: computed(() => { const classes = [ns.e('popper')] if (props2.popperClass) classes.push(props2.popperClass) return classes.join(' ') }), filterMethod: (keyword = '') => { if (props2.filterMethod) props2.filterMethod(keyword) nextTick(() => { var _a2 ;(_a2 = tree.value) == null ? void 0 : _a2.filter(keyword) }) }, onVisibleChange: (visible) => { var _a2 ;(_a2 = attrs.onVisibleChange) == null ? void 0 : _a2.call(attrs, visible) if (props2.filterable && visible) { result.filterMethod() } }, } return result } const component = defineComponent({ extends: ElOption$1, setup(props2, ctx) { const result = ElOption$1.setup(props2, ctx) delete result.selectOptionClick return result }, methods: { selectOptionClick() { this.$el.parentElement.click() }, }, }) const useTree$1 = ( props2, { attrs, slots, emit: emit2 }, { select: select2, tree, key: key2 } ) => { watch$1( () => props2.modelValue, () => { if (props2.showCheckbox) { nextTick(() => { const treeInstance = tree.value if ( treeInstance && !isEqual$4( treeInstance.getCheckedKeys(), toValidArray(props2.modelValue) ) ) { treeInstance.setCheckedKeys(toValidArray(props2.modelValue)) } }) } }, { immediate: true, deep: true, } ) const propsMap = computed(() => ({ value: key2.value, ...props2.props, })) const getNodeValByProp = (prop, data2) => { var _a2 const propVal = propsMap.value[prop] if (isFunction$l(propVal)) { return propVal( data2, (_a2 = tree.value) == null ? void 0 : _a2.getNode(getNodeValByProp('value', data2)) ) } else { return data2[propVal] } } return { ...pick$3(toRefs$2(props2), Object.keys(_Tree.props)), ...attrs, nodeKey: key2, defaultExpandedKeys: computed(() => props2.defaultExpandedKeys ? props2.defaultExpandedKeys.concat(props2.modelValue) : toValidArray(props2.modelValue) ), renderContent: (h2, { node: node2, data: data2, store: store2 }) => { return h2( component, { value: getNodeValByProp('value', data2), label: getNodeValByProp('label', data2), disabled: getNodeValByProp('disabled', data2), }, props2.renderContent ? () => props2.renderContent(h2, { node: node2, data: data2, store: store2, }) : slots.default ? () => slots.default({ node: node2, data: data2, store: store2 }) : void 0 ) }, filterNodeMethod: (value2, data2, node2) => { var _a2 if (props2.filterNodeMethod) return props2.filterNodeMethod(value2, data2, node2) if (!value2) return true return (_a2 = getNodeValByProp('label', data2)) == null ? void 0 : _a2.includes(value2) }, onNodeClick: (data2, node2, e2) => { var _a2, _b2, _c2 ;(_a2 = attrs.onNodeClick) == null ? void 0 : _a2.call(attrs, data2, node2, e2) if (props2.checkStrictly || node2.isLeaf) { if (!getNodeValByProp('disabled', data2)) { const option2 = (_b2 = select2.value) == null ? void 0 : _b2.options.get(getNodeValByProp('value', data2)) ;(_c2 = select2.value) == null ? void 0 : _c2.handleOptionSelect(option2, true) } } else { e2.ctx.handleExpandIconClick() } }, onCheck: (data2, params2) => { var _a2, _b2 ;(_a2 = attrs.onCheck) == null ? void 0 : _a2.call(attrs, data2, params2) const checkedKeys = !props2.checkStrictly ? (_b2 = tree.value) == null ? void 0 : _b2.getCheckedKeys(true) : params2.checkedKeys const value2 = getNodeValByProp('value', data2) emit2( UPDATE_MODEL_EVENT, props2.multiple ? checkedKeys : checkedKeys.includes(value2) ? value2 : void 0 ) }, } } function toValidArray(val2) { return Array.isArray(val2) ? val2 : val2 || val2 === 0 ? [val2] : [] } const _sfc_main$7f = defineComponent({ name: 'ElTreeSelect', props: { ...ElSelect.props, ..._Tree.props, }, setup(props2, context2) { const { slots, expose } = context2 const select2 = ref() const tree = ref() const key2 = computed(() => props2.valueKey || props2.nodeKey || 'value') const selectProps = useSelect(props2, context2, { select: select2, tree, key: key2, }) const treeProps2 = useTree$1(props2, context2, { select: select2, tree, key: key2, }) const methods = reactive({}) expose(methods) onMounted(() => { Object.assign(methods, { ...pick$3(tree.value, [ 'filter', 'updateKeyChildren', 'getCheckedNodes', 'setCheckedNodes', 'getCheckedKeys', 'setCheckedKeys', 'setChecked', 'getHalfCheckedNodes', 'getHalfCheckedKeys', 'getCurrentKey', 'getCurrentNode', 'setCurrentKey', 'setCurrentNode', 'getNode', 'remove', 'append', 'insertBefore', 'insertAfter', ]), ...pick$3(select2.value, ['focus', 'blur']), }) }) return () => h$4( ElSelect, reactive({ ...selectProps, ref: (ref2) => (select2.value = ref2), }), { ...slots, default: () => h$4( _Tree, reactive({ ...treeProps2, ref: (ref2) => (tree.value = ref2), }) ), } ) }, }) var TreeSelect = /* @__PURE__ */ _export_sfc$1(_sfc_main$7f, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/tree-select/src/tree-select.vue', ], ]) TreeSelect.install = (app2) => { app2.component(TreeSelect.name, TreeSelect) } const _TreeSelect = TreeSelect const ElTreeSelect = _TreeSelect const ROOT_TREE_INJECTION_KEY = Symbol() const EMPTY_NODE = { key: -1, level: -1, data: {}, } var TreeOptionsEnum = /* @__PURE__ */ ((TreeOptionsEnum2) => { TreeOptionsEnum2['KEY'] = 'id' TreeOptionsEnum2['LABEL'] = 'label' TreeOptionsEnum2['CHILDREN'] = 'children' TreeOptionsEnum2['DISABLED'] = 'disabled' return TreeOptionsEnum2 })(TreeOptionsEnum || {}) var SetOperationEnum = /* @__PURE__ */ ((SetOperationEnum2) => { SetOperationEnum2['ADD'] = 'add' SetOperationEnum2['DELETE'] = 'delete' return SetOperationEnum2 })(SetOperationEnum || {}) const treeProps = buildProps({ data: { type: definePropType(Array), default: () => mutable([]), }, emptyText: { type: String, }, height: { type: Number, default: 200, }, props: { type: definePropType(Object), default: () => mutable({ children: 'children', label: 'label', disabled: 'disabled', value: 'id', }), }, highlightCurrent: { type: Boolean, default: false, }, showCheckbox: { type: Boolean, default: false, }, defaultCheckedKeys: { type: definePropType(Array), default: () => mutable([]), }, checkStrictly: { type: Boolean, default: false, }, defaultExpandedKeys: { type: definePropType(Array), default: () => mutable([]), }, indent: { type: Number, default: 16, }, icon: { type: String, }, expandOnClickNode: { type: Boolean, default: true, }, checkOnClickNode: { type: Boolean, default: false, }, currentNodeKey: { type: definePropType([String, Number]), }, accordion: { type: Boolean, default: false, }, filterMethod: { type: definePropType(Function), }, perfMode: { type: Boolean, default: true, }, }) const treeNodeProps = buildProps({ node: { type: definePropType(Object), default: () => mutable(EMPTY_NODE), }, expanded: { type: Boolean, default: false, }, checked: { type: Boolean, default: false, }, indeterminate: { type: Boolean, default: false, }, showCheckbox: { type: Boolean, default: false, }, disabled: { type: Boolean, default: false, }, current: { type: Boolean, default: false, }, hiddenExpandIcon: { type: Boolean, default: false, }, }) const treeNodeContentProps = buildProps({ node: { type: definePropType(Object), required: true, }, }) const NODE_CLICK = 'node-click' const NODE_EXPAND = 'node-expand' const NODE_COLLAPSE = 'node-collapse' const CURRENT_CHANGE = 'current-change' const NODE_CHECK = 'check' const NODE_CHECK_CHANGE = 'check-change' const NODE_CONTEXTMENU = 'node-contextmenu' const treeEmits = { [NODE_CLICK]: (data2, node2, e2) => data2 && node2 && e2, [NODE_EXPAND]: (data2, node2) => data2 && node2, [NODE_COLLAPSE]: (data2, node2) => data2 && node2, [CURRENT_CHANGE]: (data2, node2) => data2 && node2, [NODE_CHECK]: (data2, checkedInfo) => data2 && checkedInfo, [NODE_CHECK_CHANGE]: (data2, checked2) => data2 && typeof checked2 === 'boolean', [NODE_CONTEXTMENU]: (event, data2, node2) => event && data2 && node2, } const treeNodeEmits = { click: (node2, e2) => !!(node2 && e2), toggle: (node2) => !!node2, check: (node2, checked2) => node2 && typeof checked2 === 'boolean', } function useCheck(props2, tree) { const checkedKeys = ref(/* @__PURE__ */ new Set()) const indeterminateKeys = ref(/* @__PURE__ */ new Set()) const { emit: emit2 } = getCurrentInstance() watch$1( () => tree.value, () => { return nextTick(() => { _setCheckedKeys(props2.defaultCheckedKeys) }) }, { immediate: true, } ) const updateCheckedKeys = () => { if (!tree.value || !props2.showCheckbox || props2.checkStrictly) { return } const { levelTreeNodeMap, maxLevel } = tree.value const checkedKeySet = checkedKeys.value const indeterminateKeySet = /* @__PURE__ */ new Set() for (let level = maxLevel - 1; level >= 1; --level) { const nodes = levelTreeNodeMap.get(level) if (!nodes) continue nodes.forEach((node2) => { const children = node2.children if (children) { let allChecked = true let hasChecked = false for (const childNode of children) { const key2 = childNode.key if (checkedKeySet.has(key2)) { hasChecked = true } else if (indeterminateKeySet.has(key2)) { allChecked = false hasChecked = true break } else { allChecked = false } } if (allChecked) { checkedKeySet.add(node2.key) } else if (hasChecked) { indeterminateKeySet.add(node2.key) checkedKeySet.delete(node2.key) } else { checkedKeySet.delete(node2.key) indeterminateKeySet.delete(node2.key) } } }) } indeterminateKeys.value = indeterminateKeySet } const isChecked = (node2) => checkedKeys.value.has(node2.key) const isIndeterminate = (node2) => indeterminateKeys.value.has(node2.key) const toggleCheckbox = (node2, isChecked2, nodeClick = true) => { const checkedKeySet = checkedKeys.value const toggle2 = (node22, checked2) => { checkedKeySet[checked2 ? SetOperationEnum.ADD : SetOperationEnum.DELETE]( node22.key ) const children = node22.children if (!props2.checkStrictly && children) { children.forEach((childNode) => { if (!childNode.disabled) { toggle2(childNode, checked2) } }) } } toggle2(node2, isChecked2) updateCheckedKeys() if (nodeClick) { afterNodeCheck(node2, isChecked2) } } const afterNodeCheck = (node2, checked2) => { const { checkedNodes, checkedKeys: checkedKeys2 } = getChecked() const { halfCheckedNodes, halfCheckedKeys } = getHalfChecked() emit2(NODE_CHECK, node2.data, { checkedKeys: checkedKeys2, checkedNodes, halfCheckedKeys, halfCheckedNodes, }) emit2(NODE_CHECK_CHANGE, node2.data, checked2) } function getCheckedKeys(leafOnly = false) { return getChecked(leafOnly).checkedKeys } function getCheckedNodes(leafOnly = false) { return getChecked(leafOnly).checkedNodes } function getHalfCheckedKeys() { return getHalfChecked().halfCheckedKeys } function getHalfCheckedNodes() { return getHalfChecked().halfCheckedNodes } function getChecked(leafOnly = false) { const checkedNodes = [] const keys3 = [] if ((tree == null ? void 0 : tree.value) && props2.showCheckbox) { const { treeNodeMap } = tree.value checkedKeys.value.forEach((key2) => { const node2 = treeNodeMap.get(key2) if (node2 && (!leafOnly || (leafOnly && node2.isLeaf))) { keys3.push(key2) checkedNodes.push(node2.data) } }) } return { checkedKeys: keys3, checkedNodes, } } function getHalfChecked() { const halfCheckedNodes = [] const halfCheckedKeys = [] if ((tree == null ? void 0 : tree.value) && props2.showCheckbox) { const { treeNodeMap } = tree.value indeterminateKeys.value.forEach((key2) => { const node2 = treeNodeMap.get(key2) if (node2) { halfCheckedKeys.push(key2) halfCheckedNodes.push(node2.data) } }) } return { halfCheckedNodes, halfCheckedKeys, } } function setCheckedKeys(keys3) { checkedKeys.value.clear() indeterminateKeys.value.clear() _setCheckedKeys(keys3) } function setChecked(key2, isChecked2) { if ((tree == null ? void 0 : tree.value) && props2.showCheckbox) { const node2 = tree.value.treeNodeMap.get(key2) if (node2) { toggleCheckbox(node2, isChecked2, false) } } } function _setCheckedKeys(keys3) { if (tree == null ? void 0 : tree.value) { const { treeNodeMap } = tree.value if (props2.showCheckbox && treeNodeMap && keys3) { for (const key2 of keys3) { const node2 = treeNodeMap.get(key2) if (node2 && !isChecked(node2)) { toggleCheckbox(node2, true, false) } } } } } return { updateCheckedKeys, toggleCheckbox, isChecked, isIndeterminate, getCheckedKeys, getCheckedNodes, getHalfCheckedKeys, getHalfCheckedNodes, setChecked, setCheckedKeys, } } function useFilter(props2, tree) { const hiddenNodeKeySet = ref(/* @__PURE__ */ new Set([])) const hiddenExpandIconKeySet = ref(/* @__PURE__ */ new Set([])) const filterable = computed(() => { return isFunction$l(props2.filterMethod) }) function doFilter(query) { var _a2 if (!filterable.value) { return } const expandKeySet = /* @__PURE__ */ new Set() const hiddenExpandIconKeys = hiddenExpandIconKeySet.value const hiddenKeys2 = hiddenNodeKeySet.value const family = [] const nodes = ((_a2 = tree.value) == null ? void 0 : _a2.treeNodes) || [] const filter2 = props2.filterMethod hiddenKeys2.clear() function traverse(nodes2) { nodes2.forEach((node2) => { family.push(node2) if (filter2 == null ? void 0 : filter2(query, node2.data)) { family.forEach((member) => { expandKeySet.add(member.key) }) } else if (node2.isLeaf) { hiddenKeys2.add(node2.key) } const children = node2.children if (children) { traverse(children) } if (!node2.isLeaf) { if (!expandKeySet.has(node2.key)) { hiddenKeys2.add(node2.key) } else if (children) { let allHidden = true for (const childNode of children) { if (!hiddenKeys2.has(childNode.key)) { allHidden = false break } } if (allHidden) { hiddenExpandIconKeys.add(node2.key) } else { hiddenExpandIconKeys.delete(node2.key) } } } family.pop() }) } traverse(nodes) return expandKeySet } function isForceHiddenExpandIcon(node2) { return hiddenExpandIconKeySet.value.has(node2.key) } return { hiddenExpandIconKeySet, hiddenNodeKeySet, doFilter, isForceHiddenExpandIcon, } } function useTree(props2, emit2) { const expandedKeySet = ref(new Set(props2.defaultExpandedKeys)) const currentKey = ref() const tree = shallowRef() watch$1( () => props2.currentNodeKey, (key2) => { currentKey.value = key2 }, { immediate: true, } ) watch$1( () => props2.data, (data2) => { setData(data2) }, { immediate: true, } ) const { isIndeterminate, isChecked, toggleCheckbox, getCheckedKeys, getCheckedNodes, getHalfCheckedKeys, getHalfCheckedNodes, setChecked, setCheckedKeys, } = useCheck(props2, tree) const { doFilter, hiddenNodeKeySet, isForceHiddenExpandIcon } = useFilter( props2, tree ) const valueKey = computed(() => { var _a2 return ( ((_a2 = props2.props) == null ? void 0 : _a2.value) || TreeOptionsEnum.KEY ) }) const childrenKey = computed(() => { var _a2 return ( ((_a2 = props2.props) == null ? void 0 : _a2.children) || TreeOptionsEnum.CHILDREN ) }) const disabledKey = computed(() => { var _a2 return ( ((_a2 = props2.props) == null ? void 0 : _a2.disabled) || TreeOptionsEnum.DISABLED ) }) const labelKey = computed(() => { var _a2 return ( ((_a2 = props2.props) == null ? void 0 : _a2.label) || TreeOptionsEnum.LABEL ) }) const flattenTree = computed(() => { const expandedKeys = expandedKeySet.value const hiddenKeys2 = hiddenNodeKeySet.value const flattenNodes = [] const nodes = (tree.value && tree.value.treeNodes) || [] function traverse() { const stack = [] for (let i2 = nodes.length - 1; i2 >= 0; --i2) { stack.push(nodes[i2]) } while (stack.length) { const node2 = stack.pop() if (!node2) continue if (!hiddenKeys2.has(node2.key)) { flattenNodes.push(node2) } if (expandedKeys.has(node2.key)) { const children = node2.children if (children) { const length2 = children.length for (let i2 = length2 - 1; i2 >= 0; --i2) { stack.push(children[i2]) } } } } } traverse() return flattenNodes }) const isNotEmpty = computed(() => { return flattenTree.value.length > 0 }) function createTree(data2) { const treeNodeMap = /* @__PURE__ */ new Map() const levelTreeNodeMap = /* @__PURE__ */ new Map() let maxLevel = 1 function traverse(nodes, level = 1, parent2 = void 0) { var _a2 const siblings = [] for (const rawNode of nodes) { const value2 = getKey2(rawNode) const node2 = { level, key: value2, data: rawNode, } node2.label = getLabel(rawNode) node2.parent = parent2 const children = getChildren(rawNode) node2.disabled = getDisabled(rawNode) node2.isLeaf = !children || children.length === 0 if (children && children.length) { node2.children = traverse(children, level + 1, node2) } siblings.push(node2) treeNodeMap.set(value2, node2) if (!levelTreeNodeMap.has(level)) { levelTreeNodeMap.set(level, []) } ;(_a2 = levelTreeNodeMap.get(level)) == null ? void 0 : _a2.push(node2) } if (level > maxLevel) { maxLevel = level } return siblings } const treeNodes = traverse(data2) return { treeNodeMap, levelTreeNodeMap, maxLevel, treeNodes, } } function filter2(query) { const keys3 = doFilter(query) if (keys3) { expandedKeySet.value = keys3 } } function getChildren(node2) { return node2[childrenKey.value] } function getKey2(node2) { if (!node2) { return '' } return node2[valueKey.value] } function getDisabled(node2) { return node2[disabledKey.value] } function getLabel(node2) { return node2[labelKey.value] } function toggleExpand(node2) { const expandedKeys = expandedKeySet.value if (expandedKeys.has(node2.key)) { collapse2(node2) } else { expand2(node2) } } function handleNodeClick(node2, e2) { emit2(NODE_CLICK, node2.data, node2, e2) handleCurrentChange(node2) if (props2.expandOnClickNode) { toggleExpand(node2) } if (props2.showCheckbox && props2.checkOnClickNode && !node2.disabled) { toggleCheckbox(node2, !isChecked(node2), true) } } function handleCurrentChange(node2) { if (!isCurrent(node2)) { currentKey.value = node2.key emit2(CURRENT_CHANGE, node2.data, node2) } } function handleNodeCheck(node2, checked2) { toggleCheckbox(node2, checked2) } function expand2(node2) { const keySet = expandedKeySet.value if ((tree == null ? void 0 : tree.value) && props2.accordion) { const { treeNodeMap } = tree.value keySet.forEach((key2) => { const node22 = treeNodeMap.get(key2) if (node22 && node22.level === node22.level) { keySet.delete(key2) } }) } keySet.add(node2.key) emit2(NODE_EXPAND, node2.data, node2) } function collapse2(node2) { expandedKeySet.value.delete(node2.key) emit2(NODE_COLLAPSE, node2.data, node2) } function isExpanded(node2) { return expandedKeySet.value.has(node2.key) } function isDisabled(node2) { return !!node2.disabled } function isCurrent(node2) { const current2 = currentKey.value return !!current2 && current2 === node2.key } function getCurrentNode() { var _a2, _b2 if (!currentKey.value) return void 0 return (_b2 = (_a2 = tree == null ? void 0 : tree.value) == null ? void 0 : _a2.treeNodeMap.get(currentKey.value)) == null ? void 0 : _b2.data } function getCurrentKey() { return currentKey.value } function setCurrentKey(key2) { currentKey.value = key2 } function setData(data2) { nextTick(() => (tree.value = createTree(data2))) } return { tree, flattenTree, isNotEmpty, getKey: getKey2, getChildren, toggleExpand, toggleCheckbox, isExpanded, isChecked, isIndeterminate, isDisabled, isCurrent, isForceHiddenExpandIcon, handleNodeClick, handleNodeCheck, getCurrentNode, getCurrentKey, setCurrentKey, getCheckedKeys, getCheckedNodes, getHalfCheckedKeys, getHalfCheckedNodes, setChecked, setCheckedKeys, filter: filter2, setData, } } var ElNodeContent = defineComponent({ name: 'ElTreeNodeContent', props: treeNodeContentProps, setup(props2) { const tree = inject(ROOT_TREE_INJECTION_KEY) const ns = useNamespace('tree') return () => { const node2 = props2.node const { data: data2 } = node2 return (tree == null ? void 0 : tree.ctx.slots.default) ? tree.ctx.slots.default({ node: node2, data: data2 }) : h$4('span', { class: ns.be('node', 'label') }, [ node2 == null ? void 0 : node2.label, ]) } }, }) const DEFAULT_ICON = 'caret-right' const _sfc_main$7e = defineComponent({ name: 'ElTreeNode', components: { ElIcon, CaretRight: caretRight, ElCheckbox, ElNodeContent, }, props: treeNodeProps, emits: treeNodeEmits, setup(props2, { emit: emit2 }) { const tree = inject(ROOT_TREE_INJECTION_KEY) const ns = useNamespace('tree') const indent = computed(() => { var _a2 return (_a2 = tree == null ? void 0 : tree.props.indent) != null ? _a2 : 16 }) const icon = computed(() => { var _a2 return (_a2 = tree == null ? void 0 : tree.props.icon) != null ? _a2 : DEFAULT_ICON }) const handleClick2 = (e2) => { emit2('click', props2.node, e2) } const handleExpandIconClick = () => { emit2('toggle', props2.node) } const handleCheckChange = (value2) => { emit2('check', props2.node, value2) } const handleContextMenu = (event) => { var _a2, _b2, _c2, _d if ( (_c2 = (_b2 = (_a2 = tree == null ? void 0 : tree.instance) == null ? void 0 : _a2.vnode) == null ? void 0 : _b2.props) == null ? void 0 : _c2['onNodeContextmenu'] ) { event.stopPropagation() event.preventDefault() } tree == null ? void 0 : tree.ctx.emit( NODE_CONTEXTMENU, event, (_d = props2.node) == null ? void 0 : _d.data, props2.node ) } return { ns, indent, icon, handleClick: handleClick2, handleExpandIconClick, handleCheckChange, handleContextMenu, } }, }) const _hoisted_1$66 = [ 'aria-expanded', 'aria-disabled', 'aria-checked', 'data-key', ] function _sfc_render$n(_ctx, _cache, $props2, $setup, $data, $options) { var _a2, _b2, _c2 const _component_el_icon = resolveComponent('el-icon') const _component_el_checkbox = resolveComponent('el-checkbox') const _component_el_node_content = resolveComponent('el-node-content') return ( openBlock(), createElementBlock( 'div', { ref: 'node$', class: normalizeClass([ _ctx.ns.b('node'), _ctx.ns.is('expanded', _ctx.expanded), _ctx.ns.is('current', _ctx.current), _ctx.ns.is('focusable', !_ctx.disabled), _ctx.ns.is('checked', !_ctx.disabled && _ctx.checked), ]), role: 'treeitem', tabindex: '-1', 'aria-expanded': _ctx.expanded, 'aria-disabled': _ctx.disabled, 'aria-checked': _ctx.checked, 'data-key': (_a2 = _ctx.node) == null ? void 0 : _a2.key, onClick: _cache[1] || (_cache[1] = withModifiers( (...args) => _ctx.handleClick && _ctx.handleClick(...args), ['stop'] )), onContextmenu: _cache[2] || (_cache[2] = (...args) => _ctx.handleContextMenu && _ctx.handleContextMenu(...args)), }, [ createElementVNode( 'div', { class: normalizeClass(_ctx.ns.be('node', 'content')), style: normalizeStyle$1({ paddingLeft: `${(_ctx.node.level - 1) * _ctx.indent}px`, }), }, [ _ctx.icon ? (openBlock(), createBlock( _component_el_icon, { key: 0, class: normalizeClass([ _ctx.ns.is( 'leaf', !!((_b2 = _ctx.node) == null ? void 0 : _b2.isLeaf) ), _ctx.ns.is('hidden', _ctx.hiddenExpandIcon), { expanded: !((_c2 = _ctx.node) == null ? void 0 : _c2.isLeaf) && _ctx.expanded, }, _ctx.ns.be('node', 'expand-icon'), ]), onClick: withModifiers(_ctx.handleExpandIconClick, [ 'stop', ]), }, { default: withCtx(() => [ (openBlock(), createBlock(resolveDynamicComponent(_ctx.icon))), ]), _: 1, }, 8, ['class', 'onClick'] )) : createCommentVNode('v-if', true), _ctx.showCheckbox ? (openBlock(), createBlock( _component_el_checkbox, { key: 1, 'model-value': _ctx.checked, indeterminate: _ctx.indeterminate, disabled: _ctx.disabled, onChange: _ctx.handleCheckChange, onClick: _cache[0] || (_cache[0] = withModifiers(() => {}, ['stop'])), }, null, 8, ['model-value', 'indeterminate', 'disabled', 'onChange'] )) : createCommentVNode('v-if', true), createVNode$1( _component_el_node_content, { node: _ctx.node }, null, 8, ['node'] ), ], 6 ), ], 42, _hoisted_1$66 ) ) } var ElTreeNode = /* @__PURE__ */ _export_sfc$1(_sfc_main$7e, [ ['render', _sfc_render$n], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/tree-v2/src/tree-node.vue', ], ]) const _sfc_main$7d = defineComponent({ name: 'ElTreeV2', components: { ElTreeNode, FixedSizeList, }, props: treeProps, emits: treeEmits, setup(props2, ctx) { provide(ROOT_TREE_INJECTION_KEY, { ctx, props: props2, instance: getCurrentInstance(), }) const { t: t3 } = useLocale() const ns = useNamespace('tree') const { flattenTree, isNotEmpty, toggleExpand, isExpanded, isIndeterminate, isChecked, isDisabled, isCurrent, isForceHiddenExpandIcon, toggleCheckbox, handleNodeClick, handleNodeCheck, getCurrentNode, getCurrentKey, setCurrentKey, getCheckedKeys, getCheckedNodes, getHalfCheckedKeys, getHalfCheckedNodes, setChecked, setCheckedKeys, filter: filter2, setData, } = useTree(props2, ctx.emit) ctx.expose({ getCurrentNode, getCurrentKey, setCurrentKey, getCheckedKeys, getCheckedNodes, getHalfCheckedKeys, getHalfCheckedNodes, setChecked, setCheckedKeys, filter: filter2, setData, }) return { t: t3, ns, flattenTree, itemSize: 26, isNotEmpty, toggleExpand, toggleCheckbox, isExpanded, isIndeterminate, isChecked, isDisabled, isCurrent, isForceHiddenExpandIcon, handleNodeClick, handleNodeCheck, } }, }) function _sfc_render$m(_ctx, _cache, $props2, $setup, $data, $options) { var _a2 const _component_el_tree_node = resolveComponent('el-tree-node') const _component_fixed_size_list = resolveComponent('fixed-size-list') return ( openBlock(), createElementBlock( 'div', { class: normalizeClass([ _ctx.ns.b(), { [_ctx.ns.m('highlight-current')]: _ctx.highlightCurrent }, ]), role: 'tree', }, [ _ctx.isNotEmpty ? (openBlock(), createBlock( _component_fixed_size_list, { key: 0, 'class-name': _ctx.ns.b('virtual-list'), data: _ctx.flattenTree, total: _ctx.flattenTree.length, height: _ctx.height, 'item-size': _ctx.itemSize, 'perf-mode': _ctx.perfMode, }, { default: withCtx( ({ data: data2, index: index2, style: style2 }) => [ (openBlock(), createBlock( _component_el_tree_node, { key: data2[index2].key, style: normalizeStyle$1(style2), node: data2[index2], expanded: _ctx.isExpanded(data2[index2]), 'show-checkbox': _ctx.showCheckbox, checked: _ctx.isChecked(data2[index2]), indeterminate: _ctx.isIndeterminate(data2[index2]), disabled: _ctx.isDisabled(data2[index2]), current: _ctx.isCurrent(data2[index2]), 'hidden-expand-icon': _ctx.isForceHiddenExpandIcon( data2[index2] ), onClick: _ctx.handleNodeClick, onToggle: _ctx.toggleExpand, onCheck: _ctx.handleNodeCheck, }, null, 8, [ 'style', 'node', 'expanded', 'show-checkbox', 'checked', 'indeterminate', 'disabled', 'current', 'hidden-expand-icon', 'onClick', 'onToggle', 'onCheck', ] )), ] ), _: 1, }, 8, [ 'class-name', 'data', 'total', 'height', 'item-size', 'perf-mode', ] )) : (openBlock(), createElementBlock( 'div', { key: 1, class: normalizeClass(_ctx.ns.e('empty-block')), }, [ createElementVNode( 'span', { class: normalizeClass(_ctx.ns.e('empty-text')), }, toDisplayString$1( (_a2 = _ctx.emptyText) != null ? _a2 : _ctx.t('el.tree.emptyText') ), 3 ), ], 2 )), ], 2 ) ) } var TreeV2 = /* @__PURE__ */ _export_sfc$1(_sfc_main$7d, [ ['render', _sfc_render$m], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/tree-v2/src/tree.vue', ], ]) const ElTreeV2 = withInstall(TreeV2) const SCOPE$2 = 'ElUpload' class UploadAjaxError extends Error { constructor(message2, status, method4, url2) { super(message2) this.name = 'UploadAjaxError' this.status = status this.method = method4 this.url = url2 } } function getError(action, option2, xhr2) { let msg if (xhr2.response) { msg = `${xhr2.response.error || xhr2.response}` } else if (xhr2.responseText) { msg = `${xhr2.responseText}` } else { msg = `fail to ${option2.method} ${action} ${xhr2.status}` } return new UploadAjaxError(msg, xhr2.status, option2.method, action) } function getBody(xhr2) { const text2 = xhr2.responseText || xhr2.response if (!text2) { return text2 } try { return JSON.parse(text2) } catch (e2) { return text2 } } const ajaxUpload = (option2) => { if (typeof XMLHttpRequest === 'undefined') throwError$1(SCOPE$2, 'XMLHttpRequest is undefined') const xhr2 = new XMLHttpRequest() const action = option2.action if (xhr2.upload) { xhr2.upload.addEventListener('progress', (evt) => { const progressEvt = evt progressEvt.percent = evt.total > 0 ? (evt.loaded / evt.total) * 100 : 0 option2.onProgress(progressEvt) }) } const formData = new FormData() if (option2.data) { for (const [key2, value2] of Object.entries(option2.data)) { if (Array.isArray(value2)) formData.append(key2, ...value2) else formData.append(key2, value2) } } formData.append(option2.filename, option2.file, option2.file.name) xhr2.addEventListener('error', () => { option2.onError(getError(action, option2, xhr2)) }) xhr2.addEventListener('load', () => { if (xhr2.status < 200 || xhr2.status >= 300) { return option2.onError(getError(action, option2, xhr2)) } option2.onSuccess(getBody(xhr2)) }) xhr2.open(option2.method, action, true) if (option2.withCredentials && 'withCredentials' in xhr2) { xhr2.withCredentials = true } const headers = option2.headers || {} if (headers instanceof Headers) { headers.forEach((value2, key2) => xhr2.setRequestHeader(key2, value2)) } else { for (const [key2, value2] of Object.entries(headers)) { if (isNil$1(value2)) continue xhr2.setRequestHeader(key2, String(value2)) } } xhr2.send(formData) return xhr2 } const uploadListTypes = ['text', 'picture', 'picture-card'] let fileId = 1 const genFileId = () => Date.now() + fileId++ const uploadBaseProps = buildProps({ action: { type: String, required: true, }, headers: { type: definePropType(Object), }, method: { type: String, default: 'post', }, data: { type: Object, default: () => mutable({}), }, multiple: { type: Boolean, default: false, }, name: { type: String, default: 'file', }, drag: { type: Boolean, default: false, }, withCredentials: Boolean, showFileList: { type: Boolean, default: true, }, accept: { type: String, default: '', }, type: { type: String, default: 'select', }, fileList: { type: definePropType(Array), default: () => mutable([]), }, autoUpload: { type: Boolean, default: true, }, listType: { type: String, values: uploadListTypes, default: 'text', }, httpRequest: { type: definePropType(Function), default: ajaxUpload, }, disabled: Boolean, limit: Number, }) const uploadProps = buildProps({ ...uploadBaseProps, beforeUpload: { type: definePropType(Function), default: NOOP, }, beforeRemove: { type: definePropType(Function), }, onRemove: { type: definePropType(Function), default: NOOP, }, onChange: { type: definePropType(Function), default: NOOP, }, onPreview: { type: definePropType(Function), default: NOOP, }, onSuccess: { type: definePropType(Function), default: NOOP, }, onProgress: { type: definePropType(Function), default: NOOP, }, onError: { type: definePropType(Function), default: NOOP, }, onExceed: { type: definePropType(Function), default: NOOP, }, }) const uploadListProps = buildProps({ files: { type: definePropType(Array), default: () => mutable([]), }, disabled: { type: Boolean, default: false, }, handlePreview: { type: definePropType(Function), default: NOOP, }, listType: { type: String, values: uploadListTypes, default: 'text', }, }) const uploadListEmits = { remove: (file2) => !!file2, } const _hoisted_1$65 = ['onKeydown'] const _hoisted_2$50 = ['src'] const _hoisted_3$4x = ['onClick'] const _hoisted_4$3Y = ['onClick'] const _hoisted_5$3y = ['onClick'] const __default__$6 = { name: 'ElUploadList', } const _sfc_main$7c = /* @__PURE__ */ defineComponent({ ...__default__$6, props: uploadListProps, emits: uploadListEmits, setup(__props2, { emit: emit2 }) { const props2 = __props2 const { t: t3 } = useLocale() const nsUpload = useNamespace('upload') const nsIcon = useNamespace('icon') const nsList = useNamespace('list') const focusing = ref(false) const handleClick2 = (file2) => { props2.handlePreview(file2) } const onFileClicked = (e2) => { e2.target.focus() } const handleRemove = (file2) => { emit2('remove', file2) } return (_ctx, _cache) => { return ( openBlock(), createBlock( TransitionGroup, { tag: 'ul', class: normalizeClass([ unref(nsUpload).b('list'), unref(nsUpload).bm('list', _ctx.listType), unref(nsUpload).is('disabled', _ctx.disabled), ]), name: unref(nsList).b(), }, { default: withCtx(() => [ (openBlock(true), createElementBlock( Fragment, null, renderList(_ctx.files, (file2) => { return ( openBlock(), createElementBlock( 'li', { key: file2.uid || file2.name, class: normalizeClass([ unref(nsUpload).be('list', 'item'), unref(nsUpload).is(file2.status), { focusing: focusing.value }, ]), tabindex: '0', onKeydown: withKeys( ($event) => !_ctx.disabled && handleRemove(file2), ['delete'] ), onFocus: _cache[0] || (_cache[0] = ($event) => (focusing.value = true)), onBlur: _cache[1] || (_cache[1] = ($event) => (focusing.value = false)), onClick: onFileClicked, }, [ renderSlot( _ctx.$slots, 'default', { file: file2 }, () => [ _ctx.listType === 'picture' || (file2.status !== 'uploading' && _ctx.listType === 'picture-card') ? (openBlock(), createElementBlock( 'img', { key: 0, class: normalizeClass( unref(nsUpload).be( 'list', 'item-thumbnail' ) ), src: file2.url, alt: '', }, null, 10, _hoisted_2$50 )) : createCommentVNode('v-if', true), _ctx.listType !== 'picture' && (file2.status === 'uploading' || _ctx.listType !== 'picture-card') ? (openBlock(), createElementBlock( 'div', { key: 1, class: normalizeClass( unref(nsUpload).be('list', 'item-info') ), }, [ createElementVNode( 'a', { class: normalizeClass( unref(nsUpload).be( 'list', 'item-name' ) ), onClick: ($event) => handleClick2(file2), }, [ createVNode$1( unref(ElIcon), { class: normalizeClass( unref(nsIcon).m('document') ), }, { default: withCtx(() => [ createVNode$1(unref(document$4)), ]), _: 1, }, 8, ['class'] ), createTextVNode( ' ' + toDisplayString$1(file2.name), 1 ), ], 10, _hoisted_3$4x ), file2.status === 'uploading' ? (openBlock(), createBlock( unref(ElProgress), { key: 0, type: _ctx.listType === 'picture-card' ? 'circle' : 'line', 'stroke-width': _ctx.listType === 'picture-card' ? 6 : 2, percentage: Number( file2.percentage ), style: normalizeStyle$1( _ctx.listType === 'picture-card' ? '' : 'margin-top: 0.5rem' ), }, null, 8, [ 'type', 'stroke-width', 'percentage', 'style', ] )) : createCommentVNode('v-if', true), ], 2 )) : createCommentVNode('v-if', true), createElementVNode( 'label', { class: normalizeClass( unref(nsUpload).be( 'list', 'item-status-label' ) ), }, [ _ctx.listType === 'text' ? (openBlock(), createBlock( unref(ElIcon), { key: 0, class: normalizeClass([ unref(nsIcon).m('upload-success'), unref(nsIcon).m('circle-check'), ]), }, { default: withCtx(() => [ createVNode$1(unref(circleCheck)), ]), _: 1, }, 8, ['class'] )) : ['picture-card', 'picture'].includes( _ctx.listType ) ? (openBlock(), createBlock( unref(ElIcon), { key: 1, class: normalizeClass([ unref(nsIcon).m('upload-success'), unref(nsIcon).m('check'), ]), }, { default: withCtx(() => [ createVNode$1(unref(check$1)), ]), _: 1, }, 8, ['class'] )) : createCommentVNode('v-if', true), ], 2 ), !_ctx.disabled ? (openBlock(), createBlock( unref(ElIcon), { key: 2, class: normalizeClass( unref(nsIcon).m('close') ), onClick: ($event) => handleRemove(file2), }, { default: withCtx(() => [ createVNode$1(unref(close$2)), ]), _: 2, }, 1032, ['class', 'onClick'] )) : createCommentVNode('v-if', true), createCommentVNode( ' Due to close btn only appears when li gets focused disappears after li gets blurred, thus keyboard navigation can never reach close btn' ), createCommentVNode( ' This is a bug which needs to be fixed ' ), createCommentVNode( ' TODO: Fix the incorrect navigation interaction ' ), !_ctx.disabled ? (openBlock(), createElementBlock( 'i', { key: 3, class: normalizeClass( unref(nsIcon).m('close-tip') ), }, toDisplayString$1( unref(t3)('el.upload.deleteTip') ), 3 )) : createCommentVNode('v-if', true), _ctx.listType === 'picture-card' ? (openBlock(), createElementBlock( 'span', { key: 4, class: normalizeClass( unref(nsUpload).be('list', 'item-actions') ), }, [ createElementVNode( 'span', { class: normalizeClass( unref(nsUpload).be( 'list', 'item-preview' ) ), onClick: ($event) => _ctx.handlePreview(file2), }, [ createVNode$1( unref(ElIcon), { class: normalizeClass( unref(nsIcon).m('zoom-in') ), }, { default: withCtx(() => [ createVNode$1(unref(zoomIn)), ]), _: 1, }, 8, ['class'] ), ], 10, _hoisted_4$3Y ), !_ctx.disabled ? (openBlock(), createElementBlock( 'span', { key: 0, class: normalizeClass( unref(nsUpload).be( 'list', 'item-delete' ) ), onClick: ($event) => handleRemove(file2), }, [ createVNode$1( unref(ElIcon), { class: normalizeClass( unref(nsIcon).m('delete') ), }, { default: withCtx(() => [ createVNode$1(unref(_delete)), ]), _: 1, }, 8, ['class'] ), ], 10, _hoisted_5$3y )) : createCommentVNode('v-if', true), ], 2 )) : createCommentVNode('v-if', true), ] ), ], 42, _hoisted_1$65 ) ) }), 128 )), renderSlot(_ctx.$slots, 'append'), ]), _: 3, }, 8, ['class', 'name'] ) ) } }, }) var UploadList = /* @__PURE__ */ _export_sfc$1(_sfc_main$7c, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/upload/src/upload-list.vue', ], ]) const uploadDraggerProps = buildProps({ disabled: { type: Boolean, default: false, }, }) const uploadDraggerEmits = { file: (file2) => isArray$D(file2), } const _hoisted_1$64 = ['onDrop', 'onDragover'] const __default__$5 = { name: 'ElUploadDrag', } const _sfc_main$7b = /* @__PURE__ */ defineComponent({ ...__default__$5, props: uploadDraggerProps, emits: uploadDraggerEmits, setup(__props2, { emit: emit2 }) { const props2 = __props2 const COMPONENT_NAME2 = 'ElUploadDrag' const uploaderContext = inject(uploadContextKey) if (!uploaderContext) { throwError$1( COMPONENT_NAME2, 'usage: ' ) } const ns = useNamespace('upload') const dragover = ref(false) const onDrop = (e2) => { if (props2.disabled) return dragover.value = false const files2 = Array.from(e2.dataTransfer.files) const accept = uploaderContext.accept.value if (!accept) { emit2('file', files2) return } const filesFiltered = files2.filter((file2) => { const { type: type4, name: name2 } = file2 const extension = name2.includes('.') ? `.${name2.split('.').pop()}` : '' const baseType = type4.replace(/\/.*$/, '') return accept .split(',') .map((type22) => type22.trim()) .filter((type22) => type22) .some((acceptedType) => { if (acceptedType.startsWith('.')) { return extension === acceptedType } if (/\/\*$/.test(acceptedType)) { return baseType === acceptedType.replace(/\/\*$/, '') } if (/^[^/]+\/[^/]+$/.test(acceptedType)) { return type4 === acceptedType } return false }) }) emit2('file', filesFiltered) } const onDragover = () => { if (!props2.disabled) dragover.value = true } return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { class: normalizeClass([ unref(ns).b('dragger'), unref(ns).is('dragover', dragover.value), ]), onDrop: withModifiers(onDrop, ['prevent']), onDragover: withModifiers(onDragover, ['prevent']), onDragleave: _cache[0] || (_cache[0] = withModifiers( ($event) => (dragover.value = false), ['prevent'] )), }, [renderSlot(_ctx.$slots, 'default')], 42, _hoisted_1$64 ) ) } }, }) var UploadDragger = /* @__PURE__ */ _export_sfc$1(_sfc_main$7b, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/upload/src/upload-dragger.vue', ], ]) const uploadContentProps = buildProps({ ...uploadBaseProps, fileList: { type: definePropType(Array), default: () => mutable([]), }, beforeUpload: { type: definePropType(Function), default: NOOP, }, onRemove: { type: definePropType(Function), default: NOOP, }, onStart: { type: definePropType(Function), default: NOOP, }, onSuccess: { type: definePropType(Function), default: NOOP, }, onProgress: { type: definePropType(Function), default: NOOP, }, onError: { type: definePropType(Function), default: NOOP, }, onExceed: { type: definePropType(Function), default: NOOP, }, }) const _hoisted_1$63 = ['onKeydown'] const _hoisted_2$4$ = ['name', 'multiple', 'accept'] const __default__$4 = { name: 'ElUploadContent', inheritAttrs: false, } const _sfc_main$7a = /* @__PURE__ */ defineComponent({ ...__default__$4, props: uploadContentProps, setup(__props2, { expose }) { const props2 = __props2 const ns = useNamespace('upload') const requests = shallowRef({}) const inputRef = shallowRef() const uploadFiles = (files2) => { if (files2.length === 0) return const { autoUpload, limit: limit2, fileList, multiple, onStart, onExceed, } = props2 if (limit2 && fileList.length + files2.length > limit2) { onExceed(files2, fileList) return } if (!multiple) { files2 = files2.slice(0, 1) } for (const file2 of files2) { const rawFile = file2 rawFile.uid = genFileId() onStart(rawFile) if (autoUpload) upload2(rawFile) } } const upload2 = async (rawFile) => { inputRef.value.value = '' if (!props2.beforeUpload) { return doUpload(rawFile) } let hookResult try { hookResult = await props2.beforeUpload(rawFile) } catch (e2) { hookResult = false } if (hookResult === false) { props2.onRemove(rawFile) return } let file2 = rawFile if (hookResult instanceof Blob) { if (hookResult instanceof File) { file2 = hookResult } else { file2 = new File([hookResult], rawFile.name, { type: rawFile.type, }) } for (const key2 of Object.keys(rawFile)) { file2[key2] = rawFile[key2] } } doUpload(rawFile) } const doUpload = (rawFile) => { const { headers, data: data2, method: method4, withCredentials, name: filename, action, onProgress, onSuccess, onError, httpRequest, } = props2 const { uid: uid2 } = rawFile const options2 = { headers: headers || {}, withCredentials, file: rawFile, data: data2, method: method4, filename, action, onProgress: (evt) => { onProgress(evt, rawFile) }, onSuccess: (res) => { onSuccess(res, rawFile) delete requests.value[uid2] }, onError: (err) => { onError(err, rawFile) delete requests.value[uid2] }, } const request3 = httpRequest(options2) requests.value[uid2] = request3 if (request3 instanceof Promise) { request3.then(options2.onSuccess, options2.onError) } } const handleChange = (e2) => { const files2 = e2.target.files if (!files2) return uploadFiles(Array.from(files2)) } const handleClick2 = () => { if (!props2.disabled) { inputRef.value.value = '' inputRef.value.click() } } const handleKeydown = () => { handleClick2() } const abort = (file2) => { const _reqs = entriesOf(requests.value).filter( file2 ? ([uid2]) => String(file2.uid) === uid2 : () => true ) _reqs.forEach(([uid2, req]) => { if (req instanceof XMLHttpRequest) req.abort() delete requests.value[uid2] }) } expose({ abort, upload: upload2, }) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { class: normalizeClass([unref(ns).b(), unref(ns).m(_ctx.listType)]), tabindex: '0', onClick: handleClick2, onKeydown: withKeys(withModifiers(handleKeydown, ['self']), [ 'enter', 'space', ]), }, [ _ctx.drag ? (openBlock(), createBlock( UploadDragger, { key: 0, disabled: _ctx.disabled, onFile: uploadFiles, }, { default: withCtx(() => [ renderSlot(_ctx.$slots, 'default'), ]), _: 3, }, 8, ['disabled'] )) : renderSlot(_ctx.$slots, 'default', { key: 1 }), createElementVNode( 'input', { ref_key: 'inputRef', ref: inputRef, class: normalizeClass(unref(ns).e('input')), name: _ctx.name, multiple: _ctx.multiple, accept: _ctx.accept, type: 'file', onChange: handleChange, }, null, 42, _hoisted_2$4$ ), ], 42, _hoisted_1$63 ) ) } }, }) var UploadContent = /* @__PURE__ */ _export_sfc$1(_sfc_main$7a, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/upload/src/upload-content.vue', ], ]) const SCOPE$1 = 'ElUpload' const revokeObjectURL = (file2) => { var _a2 if ((_a2 = file2.url) == null ? void 0 : _a2.startsWith('blob:')) { URL.revokeObjectURL(file2.url) } } const useHandlers = (props2, uploadRef) => { const uploadFiles = ref([]) const getFile = (rawFile) => uploadFiles.value.find((file2) => file2.uid === rawFile.uid) function abort(file2) { var _a2 ;(_a2 = uploadRef.value) == null ? void 0 : _a2.abort(file2) } function clearFiles(states = ['ready', 'uploading', 'success', 'fail']) { uploadFiles.value = uploadFiles.value.filter( (row) => !states.includes(row.status) ) } const handleError = (err, rawFile) => { const file2 = getFile(rawFile) if (!file2) return file2.status = 'fail' uploadFiles.value.splice(uploadFiles.value.indexOf(file2), 1) props2.onError(err, file2, uploadFiles.value) props2.onChange(file2, uploadFiles.value) } const handleProgress = (evt, rawFile) => { const file2 = getFile(rawFile) if (!file2) return props2.onProgress(evt, file2, uploadFiles.value) file2.status = 'uploading' file2.percentage = Math.round(evt.percent) } const handleSuccess = (response, rawFile) => { const file2 = getFile(rawFile) if (!file2) return file2.status = 'success' file2.response = response props2.onSuccess(response, file2, uploadFiles.value) props2.onChange(file2, uploadFiles.value) } const handleStart = (file2) => { const uploadFile = { name: file2.name, percentage: 0, status: 'ready', size: file2.size, raw: file2, uid: file2.uid, } if (props2.listType === 'picture-card' || props2.listType === 'picture') { try { uploadFile.url = URL.createObjectURL(file2) } catch (err) { debugWarn(SCOPE$1, err.message) props2.onError(err, uploadFile, uploadFiles.value) } } uploadFiles.value.push(uploadFile) props2.onChange(uploadFile, uploadFiles.value) } const handleRemove = async (file2, rawFile) => { if (rawFile) { useDeprecated( { scope: SCOPE$1, from: 'handleRemove second argument', version: '2.2', replacement: 'first argument `file`', ref: 'https://element-plus.org/en-US/component/upload.html#methods', }, true ) } const _file = rawFile || file2 const uploadFile = _file instanceof File ? getFile(_file) : _file if (!uploadFile) throwError$1(SCOPE$1, 'file to be removed not found') const doRemove = (file22) => { abort(file22) const fileList = uploadFiles.value fileList.splice(fileList.indexOf(file22), 1) props2.onRemove(file22, fileList) revokeObjectURL(file22) } if (props2.beforeRemove) { const before2 = await props2.beforeRemove(uploadFile, uploadFiles.value) if (before2 !== false) doRemove(uploadFile) } else { doRemove(uploadFile) } } function submit() { uploadFiles.value .filter(({ status }) => status === 'ready') .forEach(({ raw }) => { var _a2 return ( raw && ((_a2 = uploadRef.value) == null ? void 0 : _a2.upload(raw)) ) }) } watch$1( () => props2.listType, (val2) => { if (val2 !== 'picture-card' && val2 !== 'picture') { return } uploadFiles.value = uploadFiles.value.map((file2) => { const { raw, url: url2 } = file2 if (!url2 && raw) { try { file2.url = URL.createObjectURL(raw) } catch (err) { props2.onError(err, file2, uploadFiles.value) } } return file2 }) } ) watch$1( () => props2.fileList, (fileList) => { for (const file2 of fileList) { file2.uid || (file2.uid = genFileId()) file2.status || (file2.status = 'success') } uploadFiles.value = fileList }, { immediate: true, deep: true } ) return { abort, clearFiles, handleError, handleProgress, handleStart, handleSuccess, handleRemove, submit, uploadFiles, } } const __default__$3 = { name: 'ElUpload', } const _sfc_main$79 = /* @__PURE__ */ defineComponent({ ...__default__$3, props: uploadProps, setup(__props2, { expose }) { const props2 = __props2 const slots = useSlots() const disabled = useDisabled$1() const uploadRef = shallowRef() const { abort, submit, clearFiles, uploadFiles, handleStart, handleError, handleRemove, handleSuccess, handleProgress, } = useHandlers(props2, uploadRef) const isPictureCard = computed(() => props2.listType === 'picture-card') const uploadContentProps2 = computed(() => ({ ...props2, onStart: handleStart, onProgress: handleProgress, onSuccess: handleSuccess, onError: handleError, onRemove: handleRemove, })) onBeforeUnmount(() => { uploadFiles.value.forEach(({ url: url2 }) => { if (url2 == null ? void 0 : url2.startsWith('blob:')) URL.revokeObjectURL(url2) }) }) provide(uploadContextKey, { accept: toRef(props2, 'accept'), }) expose({ abort, submit, clearFiles, handleStart, handleRemove, }) return (_ctx, _cache) => { return ( openBlock(), createElementBlock('div', null, [ unref(isPictureCard) && _ctx.showFileList ? (openBlock(), createBlock( UploadList, { key: 0, disabled: unref(disabled), 'list-type': _ctx.listType, files: unref(uploadFiles), 'handle-preview': _ctx.onPreview, onRemove: unref(handleRemove), }, createSlots( { append: withCtx(() => [ _ctx.listType === 'picture-card' ? (openBlock(), createBlock( UploadContent, mergeProps( { key: 0, ref_key: 'uploadRef', ref: uploadRef, }, unref(uploadContentProps2) ), { default: withCtx(() => [ unref(slots).trigger ? renderSlot(_ctx.$slots, 'trigger', { key: 0, }) : createCommentVNode('v-if', true), !unref(slots).trigger && unref(slots).default ? renderSlot(_ctx.$slots, 'default', { key: 1, }) : createCommentVNode('v-if', true), ]), _: 3, }, 16 )) : createCommentVNode('v-if', true), ]), _: 2, }, [ _ctx.$slots.file ? { name: 'default', fn: withCtx(({ file: file2 }) => [ renderSlot(_ctx.$slots, 'file', { file: file2 }), ]), } : void 0, ] ), 1032, ['disabled', 'list-type', 'files', 'handle-preview', 'onRemove'] )) : createCommentVNode('v-if', true), _ctx.listType !== 'picture-card' ? (openBlock(), createBlock( UploadContent, mergeProps( { key: 1, ref_key: 'uploadRef', ref: uploadRef, }, unref(uploadContentProps2) ), { default: withCtx(() => [ unref(slots).trigger ? renderSlot(_ctx.$slots, 'trigger', { key: 0 }) : createCommentVNode('v-if', true), !unref(slots).trigger && unref(slots).default ? renderSlot(_ctx.$slots, 'default', { key: 1 }) : createCommentVNode('v-if', true), ]), _: 3, }, 16 )) : createCommentVNode('v-if', true), _ctx.$slots.trigger ? renderSlot(_ctx.$slots, 'default', { key: 2 }) : createCommentVNode('v-if', true), renderSlot(_ctx.$slots, 'tip'), !unref(isPictureCard) && _ctx.showFileList ? (openBlock(), createBlock( UploadList, { key: 3, disabled: unref(disabled), 'list-type': _ctx.listType, files: unref(uploadFiles), 'handle-preview': _ctx.onPreview, onRemove: unref(handleRemove), }, createSlots({ _: 2 }, [ _ctx.$slots.file ? { name: 'default', fn: withCtx(({ file: file2 }) => [ renderSlot(_ctx.$slots, 'file', { file: file2 }), ]), } : void 0, ]), 1032, ['disabled', 'list-type', 'files', 'handle-preview', 'onRemove'] )) : createCommentVNode('v-if', true), ]) ) } }, }) var Upload = /* @__PURE__ */ _export_sfc$1(_sfc_main$79, [ [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/upload/src/upload.vue', ], ]) const ElUpload = withInstall(Upload) var Components = [ ElAffix, ElAlert, ElAutocomplete, ElAvatar, ElBacktop, ElBadge, ElBreadcrumb, ElBreadcrumbItem, ElButton, ElButtonGroup$1, ElCalendar, ElCard, ElCarousel, ElCarouselItem, ElCascader, ElCascaderPanel, ElCheckTag, ElCheckbox, ElCheckboxButton, ElCheckboxGroup$1, ElCol, ElCollapse, ElCollapseItem, ElCollapseTransition, ElColorPicker, ElConfigProvider, ElContainer, ElAside, ElFooter, ElHeader, ElMain, ElDatePicker, ElDescriptions, ElDescriptionsItem, ElDialog, ElDivider, ElDrawer, ElDropdown, ElDropdownItem, ElDropdownMenu, ElEmpty, ElForm, ElFormItem, ElIcon, ElImage, ElImageViewer, ElInput, ElInputNumber, ElLink, ElMenu, ElMenuItem, ElMenuItemGroup, ElPageHeader, ElPagination, ElPopconfirm, ElPopover, ElPopper, ElProgress, ElRadio, ElRadioButton, ElRadioGroup, ElRate, ElResult, ElRow, ElScrollbar, ElSelect, ElOption$1, ElOptionGroup, ElSelectV2, ElSkeleton, ElSkeletonItem, ElSlider, ElSpace, ElSteps, ElStep, ElSwitch, ElTable, ElTableColumn, ElTabs, ElTabPane, ElTag, ElTimePicker, ElTimeSelect, ElTimeline, ElTimelineItem, ElTooltip, ElTooltipV2, ElTransfer, ElTree, ElTreeSelect, ElTreeV2, ElUpload, ] const SCOPE = 'ElInfiniteScroll' const CHECK_INTERVAL = 50 const DEFAULT_DELAY$1 = 200 const DEFAULT_DISTANCE = 0 const attributes = { delay: { type: Number, default: DEFAULT_DELAY$1, }, distance: { type: Number, default: DEFAULT_DISTANCE, }, disabled: { type: Boolean, default: false, }, immediate: { type: Boolean, default: true, }, } const getScrollOptions = (el2, instance) => { return Object.entries(attributes).reduce((acm, [name2, option2]) => { var _a2, _b2 const { type: type4, default: defaultValue } = option2 const attrVal = el2.getAttribute(`infinite-scroll-${name2}`) let value2 = (_b2 = (_a2 = instance[attrVal]) != null ? _a2 : attrVal) != null ? _b2 : defaultValue value2 = value2 === 'false' ? false : value2 value2 = type4(value2) acm[name2] = Number.isNaN(value2) ? defaultValue : value2 return acm }, {}) } const destroyObserver = (el2) => { const { observer } = el2[SCOPE] if (observer) { observer.disconnect() delete el2[SCOPE].observer } } const handleScroll = (el2, cb) => { const { container, containerEl, instance, observer, lastScrollTop } = el2[SCOPE] const { disabled, distance: distance2 } = getScrollOptions(el2, instance) const { clientHeight, scrollHeight, scrollTop } = containerEl const delta = scrollTop - lastScrollTop el2[SCOPE].lastScrollTop = scrollTop if (observer || disabled || delta < 0) return let shouldTrigger = false if (container === el2) { shouldTrigger = scrollHeight - (clientHeight + scrollTop) <= distance2 } else { const { clientTop, scrollHeight: height } = el2 const offsetTop = getOffsetTopDistance(el2, containerEl) shouldTrigger = scrollTop + clientHeight >= offsetTop + clientTop + height - distance2 } if (shouldTrigger) { cb.call(instance) } } function checkFull(el2, cb) { const { containerEl, instance } = el2[SCOPE] const { disabled } = getScrollOptions(el2, instance) if (disabled || containerEl.clientHeight === 0) return if (containerEl.scrollHeight <= containerEl.clientHeight) { cb.call(instance) } else { destroyObserver(el2) } } const InfiniteScroll = { async mounted(el2, binding) { const { instance, value: cb } = binding if (!isFunction$l(cb)) { throwError$1( SCOPE, "'v-infinite-scroll' binding value must be a function" ) } await nextTick() const { delay: delay2, immediate } = getScrollOptions(el2, instance) const container = getScrollContainer(el2, true) const containerEl = container === window ? document.documentElement : container const onScroll = throttle$4(handleScroll.bind(null, el2, cb), delay2) if (!container) return el2[SCOPE] = { instance, container, containerEl, delay: delay2, cb, onScroll, lastScrollTop: containerEl.scrollTop, } if (immediate) { const observer = new MutationObserver( throttle$4(checkFull.bind(null, el2, cb), CHECK_INTERVAL) ) el2[SCOPE].observer = observer observer.observe(el2, { childList: true, subtree: true }) checkFull(el2, cb) } container.addEventListener('scroll', onScroll) }, unmounted(el2) { const { container, onScroll } = el2[SCOPE] container == null ? void 0 : container.removeEventListener('scroll', onScroll) destroyObserver(el2) }, async updated(el2) { if (!el2[SCOPE]) { await nextTick() } const { containerEl, cb, observer } = el2[SCOPE] if (containerEl.clientHeight && observer) { checkFull(el2, cb) } }, } const _InfiniteScroll = InfiniteScroll _InfiniteScroll.install = (app2) => { app2.directive('InfiniteScroll', _InfiniteScroll) } const ElInfiniteScroll = _InfiniteScroll function createLoadingComponent(options2) { let afterLeaveTimer const afterLeaveFlag = ref(false) const data2 = reactive({ ...options2, originalPosition: '', originalOverflow: '', visible: false, }) function setText(text2) { data2.text = text2 } function destroySelf() { const target2 = data2.parent if (!target2.vLoadingAddClassList) { let loadingNumber = target2.getAttribute('loading-number') loadingNumber = Number.parseInt(loadingNumber) - 1 if (!loadingNumber) { removeClass$1(target2, 'el-loading-parent--relative') target2.removeAttribute('loading-number') } else { target2.setAttribute('loading-number', loadingNumber.toString()) } removeClass$1(target2, 'el-loading-parent--hidden') } remvoeElLoadingChild() } function remvoeElLoadingChild() { var _a2, _b2 ;(_b2 = (_a2 = vm.$el) == null ? void 0 : _a2.parentNode) == null ? void 0 : _b2.removeChild(vm.$el) } function close2() { var _a2 if (options2.beforeClose && !options2.beforeClose()) return const target2 = data2.parent target2.vLoadingAddClassList = void 0 afterLeaveFlag.value = true clearTimeout(afterLeaveTimer) afterLeaveTimer = window.setTimeout(() => { if (afterLeaveFlag.value) { afterLeaveFlag.value = false destroySelf() } }, 400) data2.visible = false ;(_a2 = options2.closed) == null ? void 0 : _a2.call(options2) } function handleAfterLeave() { if (!afterLeaveFlag.value) return afterLeaveFlag.value = false destroySelf() } const elLoadingComponent = { name: 'ElLoading', setup() { return () => { const svg2 = data2.spinner || data2.svg const spinner = h$4( 'svg', { class: 'circular', viewBox: data2.svgViewBox ? data2.svgViewBox : '25 25 50 50', ...(svg2 ? { innerHTML: svg2 } : {}), }, [ h$4('circle', { class: 'path', cx: '50', cy: '50', r: '20', fill: 'none', }), ] ) const spinnerText = data2.text ? h$4('p', { class: 'el-loading-text' }, [data2.text]) : void 0 return h$4( Transition, { name: 'el-loading-fade', onAfterLeave: handleAfterLeave, }, { default: withCtx(() => [ withDirectives( createVNode$1( 'div', { style: { backgroundColor: data2.background || '', }, class: [ 'el-loading-mask', data2.customClass, data2.fullscreen ? 'is-fullscreen' : '', ], }, [ h$4( 'div', { class: 'el-loading-spinner', }, [spinner, spinnerText] ), ] ), [[vShow, data2.visible]] ), ]), } ) } }, } const vm = createApp$1(elLoadingComponent).mount( document.createElement('div') ) return { ...toRefs$2(data2), setText, remvoeElLoadingChild, close: close2, handleAfterLeave, vm, get $el() { return vm.$el }, } } let fullscreenInstance = void 0 const Loading = function (options2 = {}) { if (!isClient$1) return void 0 const resolved = resolveOptions(options2) if (resolved.fullscreen && fullscreenInstance) { fullscreenInstance.remvoeElLoadingChild() fullscreenInstance.close() } const instance = createLoadingComponent({ ...resolved, closed: () => { var _a2 ;(_a2 = resolved.closed) == null ? void 0 : _a2.call(resolved) if (resolved.fullscreen) fullscreenInstance = void 0 }, }) addStyle(resolved, resolved.parent, instance) addClassList(resolved, resolved.parent, instance) resolved.parent.vLoadingAddClassList = () => addClassList(resolved, resolved.parent, instance) let loadingNumber = resolved.parent.getAttribute('loading-number') if (!loadingNumber) { loadingNumber = '1' } else { loadingNumber = `${Number.parseInt(loadingNumber) + 1}` } resolved.parent.setAttribute('loading-number', loadingNumber) resolved.parent.appendChild(instance.$el) nextTick(() => (instance.visible.value = resolved.visible)) if (resolved.fullscreen) { fullscreenInstance = instance } return instance } const resolveOptions = (options2) => { var _a2, _b2, _c2, _d let target2 if (isString$f(options2.target)) { target2 = (_a2 = document.querySelector(options2.target)) != null ? _a2 : document.body } else { target2 = options2.target || document.body } return { parent: target2 === document.body || options2.body ? document.body : target2, background: options2.background || '', svg: options2.svg || '', svgViewBox: options2.svgViewBox || '', spinner: options2.spinner || false, text: options2.text || '', fullscreen: target2 === document.body && ((_b2 = options2.fullscreen) != null ? _b2 : true), lock: (_c2 = options2.lock) != null ? _c2 : false, customClass: options2.customClass || '', visible: (_d = options2.visible) != null ? _d : true, target: target2, } } const addStyle = async (options2, parent2, instance) => { const { nextZIndex: nextZIndex2 } = useZIndex() const maskStyle = {} if (options2.fullscreen) { instance.originalPosition.value = getStyle$1(document.body, 'position') instance.originalOverflow.value = getStyle$1(document.body, 'overflow') maskStyle.zIndex = nextZIndex2() } else if (options2.parent === document.body) { instance.originalPosition.value = getStyle$1(document.body, 'position') await nextTick() for (const property2 of ['top', 'left']) { const scroll = property2 === 'top' ? 'scrollTop' : 'scrollLeft' maskStyle[property2] = `${ options2.target.getBoundingClientRect()[property2] + document.body[scroll] + document.documentElement[scroll] - Number.parseInt(getStyle$1(document.body, `margin-${property2}`), 10) }px` } for (const property2 of ['height', 'width']) { maskStyle[property2] = `${ options2.target.getBoundingClientRect()[property2] }px` } } else { instance.originalPosition.value = getStyle$1(parent2, 'position') } for (const [key2, value2] of Object.entries(maskStyle)) { instance.$el.style[key2] = value2 } } const addClassList = (options2, parent2, instance) => { if ( instance.originalPosition.value !== 'absolute' && instance.originalPosition.value !== 'fixed' ) { addClass$1(parent2, 'el-loading-parent--relative') } else { removeClass$1(parent2, 'el-loading-parent--relative') } if (options2.fullscreen && options2.lock) { addClass$1(parent2, 'el-loading-parent--hidden') } else { removeClass$1(parent2, 'el-loading-parent--hidden') } } const INSTANCE_KEY = Symbol('ElLoading') const createInstance$1 = (el2, binding) => { var _a2, _b2, _c2, _d const vm = binding.instance const getBindingProp = (key2) => isObject$v(binding.value) ? binding.value[key2] : void 0 const resolveExpression = (key2) => { const data2 = (isString$f(key2) && (vm == null ? void 0 : vm[key2])) || key2 if (data2) return ref(data2) else return data2 } const getProp2 = (name2) => resolveExpression( getBindingProp(name2) || el2.getAttribute(`element-loading-${hyphenate(name2)}`) ) const fullscreen = (_a2 = getBindingProp('fullscreen')) != null ? _a2 : binding.modifiers.fullscreen const options2 = { text: getProp2('text'), svg: getProp2('svg'), svgViewBox: getProp2('svgViewBox'), spinner: getProp2('spinner'), background: getProp2('background'), customClass: getProp2('customClass'), fullscreen, target: (_b2 = getBindingProp('target')) != null ? _b2 : fullscreen ? void 0 : el2, body: (_c2 = getBindingProp('body')) != null ? _c2 : binding.modifiers.body, lock: (_d = getBindingProp('lock')) != null ? _d : binding.modifiers.lock, } el2[INSTANCE_KEY] = { options: options2, instance: Loading(options2), } } const updateOptions = (newOptions, originalOptions) => { for (const key2 of Object.keys(originalOptions)) { if (isRef(originalOptions[key2])) originalOptions[key2].value = newOptions[key2] } } const vLoading = { mounted(el2, binding) { if (binding.value) { createInstance$1(el2, binding) } }, updated(el2, binding) { const instance = el2[INSTANCE_KEY] if (binding.oldValue !== binding.value) { if (binding.value && !binding.oldValue) { createInstance$1(el2, binding) } else if (binding.value && binding.oldValue) { if (isObject$v(binding.value)) updateOptions(binding.value, instance.options) } else { instance == null ? void 0 : instance.instance.close() } } }, unmounted(el2) { var _a2 ;(_a2 = el2[INSTANCE_KEY]) == null ? void 0 : _a2.instance.close() }, } const ElLoading = { install(app2) { app2.directive('loading', vLoading) app2.config.globalProperties.$loading = Loading }, directive: vLoading, service: Loading, } const messageTypes = ['success', 'info', 'warning', 'error'] const messageProps = buildProps({ customClass: { type: String, default: '', }, center: { type: Boolean, default: false, }, dangerouslyUseHTMLString: { type: Boolean, default: false, }, duration: { type: Number, default: 3e3, }, icon: { type: iconPropType, default: '', }, id: { type: String, default: '', }, message: { type: definePropType([String, Object, Function]), default: '', }, onClose: { type: definePropType(Function), required: false, }, showClose: { type: Boolean, default: false, }, type: { type: String, values: messageTypes, default: 'info', }, offset: { type: Number, default: 20, }, zIndex: { type: Number, default: 0, }, grouping: { type: Boolean, default: false, }, repeatNum: { type: Number, default: 1, }, }) const messageEmits = { destroy: () => true, } const _sfc_main$78 = defineComponent({ name: 'ElMessage', components: { ElBadge, ElIcon, ...TypeComponents, }, props: messageProps, emits: messageEmits, setup(props2) { const ns = useNamespace('message') const visible = ref(false) const badgeType = ref( props2.type ? (props2.type === 'error' ? 'danger' : props2.type) : 'info' ) let stopTimer = void 0 const typeClass = computed(() => { const type4 = props2.type return { [ns.bm('icon', type4)]: type4 && TypeComponentsMap[type4] } }) const iconComponent = computed(() => { return props2.icon || TypeComponentsMap[props2.type] || '' }) const customStyle = computed(() => ({ top: `${props2.offset}px`, zIndex: props2.zIndex, })) function startTimer2() { if (props2.duration > 0) { ;({ stop: stopTimer } = useTimeoutFn$1(() => { if (visible.value) close2() }, props2.duration)) } } function clearTimer2() { stopTimer == null ? void 0 : stopTimer() } function close2() { visible.value = false } function keydown({ code: code2 }) { if (code2 === EVENT_CODE.esc) { if (visible.value) { close2() } } else { startTimer2() } } onMounted(() => { startTimer2() visible.value = true }) watch$1( () => props2.repeatNum, () => { clearTimer2() startTimer2() } ) useEventListener$1(document, 'keydown', keydown) return { ns, typeClass, iconComponent, customStyle, visible, badgeType, close: close2, clearTimer: clearTimer2, startTimer: startTimer2, } }, }) const _hoisted_1$62 = ['id'] const _hoisted_2$4_ = ['innerHTML'] function _sfc_render$l(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_badge = resolveComponent('el-badge') const _component_el_icon = resolveComponent('el-icon') const _component_close = resolveComponent('close') return ( openBlock(), createBlock( Transition, { name: _ctx.ns.b('fade'), onBeforeLeave: _ctx.onClose, onAfterLeave: _cache[2] || (_cache[2] = ($event) => _ctx.$emit('destroy')), }, { default: withCtx(() => [ withDirectives( createElementVNode( 'div', { id: _ctx.id, class: normalizeClass([ _ctx.ns.b(), { [_ctx.ns.m(_ctx.type)]: _ctx.type && !_ctx.icon }, _ctx.ns.is('center', _ctx.center), _ctx.ns.is('closable', _ctx.showClose), _ctx.customClass, ]), style: normalizeStyle$1(_ctx.customStyle), role: 'alert', onMouseenter: _cache[0] || (_cache[0] = (...args) => _ctx.clearTimer && _ctx.clearTimer(...args)), onMouseleave: _cache[1] || (_cache[1] = (...args) => _ctx.startTimer && _ctx.startTimer(...args)), }, [ _ctx.repeatNum > 1 ? (openBlock(), createBlock( _component_el_badge, { key: 0, value: _ctx.repeatNum, type: _ctx.badgeType, class: normalizeClass(_ctx.ns.e('badge')), }, null, 8, ['value', 'type', 'class'] )) : createCommentVNode('v-if', true), _ctx.iconComponent ? (openBlock(), createBlock( _component_el_icon, { key: 1, class: normalizeClass([ _ctx.ns.e('icon'), _ctx.typeClass, ]), }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent(_ctx.iconComponent) )), ]), _: 1, }, 8, ['class'] )) : createCommentVNode('v-if', true), renderSlot(_ctx.$slots, 'default', {}, () => [ !_ctx.dangerouslyUseHTMLString ? (openBlock(), createElementBlock( 'p', { key: 0, class: normalizeClass(_ctx.ns.e('content')), }, toDisplayString$1(_ctx.message), 3 )) : (openBlock(), createElementBlock( Fragment, { key: 1 }, [ createCommentVNode( " Caution here, message could've been compromised, never use user's input as message " ), createElementVNode( 'p', { class: normalizeClass(_ctx.ns.e('content')), innerHTML: _ctx.message, }, null, 10, _hoisted_2$4_ ), ], 2112 )), ]), _ctx.showClose ? (openBlock(), createBlock( _component_el_icon, { key: 2, class: normalizeClass(_ctx.ns.e('closeBtn')), onClick: withModifiers(_ctx.close, ['stop']), }, { default: withCtx(() => [ createVNode$1(_component_close), ]), _: 1, }, 8, ['class', 'onClick'] )) : createCommentVNode('v-if', true), ], 46, _hoisted_1$62 ), [[vShow, _ctx.visible]] ), ]), _: 3, }, 8, ['name', 'onBeforeLeave'] ) ) } var MessageConstructor = /* @__PURE__ */ _export_sfc$1(_sfc_main$78, [ ['render', _sfc_render$l], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/message/src/message.vue', ], ]) const instances$2 = [] let seed$1 = 1 const message = function (options2 = {}, context2) { if (!isClient$1) return { close: () => void 0 } if ( isNumber$h(messageConfig.max) && instances$2.length >= messageConfig.max ) { return { close: () => void 0 } } if ( !isVNode$1(options2) && isObject$v(options2) && options2.grouping && !isVNode$1(options2.message) && instances$2.length ) { const tempVm = instances$2.find((item2) => { var _a2, _b2, _c2 return ( `${ (_b2 = (_a2 = item2.vm.props) == null ? void 0 : _a2.message) != null ? _b2 : '' }` === `${(_c2 = options2.message) != null ? _c2 : ''}` ) }) if (tempVm) { tempVm.vm.component.props.repeatNum += 1 tempVm.vm.component.props.type = (options2 == null ? void 0 : options2.type) || 'info' return { close: () => (vm.component.proxy.visible = false), } } } if (isString$f(options2) || isVNode$1(options2)) { options2 = { message: options2 } } let verticalOffset = options2.offset || 20 instances$2.forEach(({ vm: vm2 }) => { var _a2 verticalOffset += (((_a2 = vm2.el) == null ? void 0 : _a2.offsetHeight) || 0) + 16 }) verticalOffset += 16 const { nextZIndex: nextZIndex2 } = useZIndex() const id2 = `message_${seed$1++}` const userOnClose = options2.onClose const props2 = { zIndex: nextZIndex2(), ...options2, offset: verticalOffset, id: id2, onClose: () => { close$1(id2, userOnClose) }, } let appendTo = document.body if (isElement$3(options2.appendTo)) { appendTo = options2.appendTo } else if (isString$f(options2.appendTo)) { appendTo = document.querySelector(options2.appendTo) } if (!isElement$3(appendTo)) { appendTo = document.body } const container = document.createElement('div') container.className = `container_${id2}` const messageContent = props2.message const vm = createVNode$1( MessageConstructor, props2, isFunction$l(messageContent) ? { default: messageContent } : isVNode$1(messageContent) ? { default: () => messageContent } : null ) vm.appContext = context2 || message._context vm.props.onDestroy = () => { render$1(null, container) } render$1(vm, container) instances$2.push({ vm }) appendTo.appendChild(container.firstElementChild) return { close: () => (vm.component.proxy.visible = false), } } messageTypes.forEach((type4) => { message[type4] = (options2 = {}, appContext) => { if (isString$f(options2) || isVNode$1(options2)) { options2 = { message: options2, } } return message( { ...options2, type: type4, }, appContext ) } }) function close$1(id2, userOnClose) { const idx = instances$2.findIndex( ({ vm: vm2 }) => id2 === vm2.component.props.id ) if (idx === -1) return const { vm } = instances$2[idx] if (!vm) return userOnClose == null ? void 0 : userOnClose(vm) const removedHeight = vm.el.offsetHeight instances$2.splice(idx, 1) const len2 = instances$2.length if (len2 < 1) return for (let i2 = idx; i2 < len2; i2++) { const pos = Number.parseInt(instances$2[i2].vm.el.style['top'], 10) - removedHeight - 16 instances$2[i2].vm.component.props.offset = pos } } function closeAll$1() { var _a2 for (let i2 = instances$2.length - 1; i2 >= 0; i2--) { const instance = instances$2[i2].vm.component ;(_a2 = instance == null ? void 0 : instance.proxy) == null ? void 0 : _a2.close() } } message.closeAll = closeAll$1 message._context = null const ElMessage = withInstallFunction(message, '$message') const _sfc_main$77 = defineComponent({ name: 'ElMessageBox', directives: { TrapFocus, }, components: { ElButton, ElInput, ElOverlay, ElIcon, ...TypeComponents, }, inheritAttrs: false, props: { buttonSize: { type: String, validator: isValidComponentSize, }, modal: { type: Boolean, default: true, }, lockScroll: { type: Boolean, default: true, }, showClose: { type: Boolean, default: true, }, closeOnClickModal: { type: Boolean, default: true, }, closeOnPressEscape: { type: Boolean, default: true, }, closeOnHashChange: { type: Boolean, default: true, }, center: Boolean, draggable: Boolean, roundButton: { default: false, type: Boolean, }, container: { type: String, default: 'body', }, boxType: { type: String, default: '', }, }, emits: ['vanish', 'action'], setup(props2, { emit: emit2 }) { const { t: t3 } = useLocale() const visible = ref(false) const { nextZIndex: nextZIndex2 } = useZIndex() const state2 = reactive({ beforeClose: null, callback: null, cancelButtonText: '', cancelButtonClass: '', confirmButtonText: '', confirmButtonClass: '', customClass: '', customStyle: {}, dangerouslyUseHTMLString: false, distinguishCancelAndClose: false, icon: '', inputPattern: null, inputPlaceholder: '', inputType: 'text', inputValue: null, inputValidator: null, inputErrorMessage: '', message: null, modalFade: true, modalClass: '', showCancelButton: false, showConfirmButton: true, type: '', title: void 0, showInput: false, action: '', confirmButtonLoading: false, cancelButtonLoading: false, confirmButtonDisabled: false, editorErrorMessage: '', validateError: false, zIndex: nextZIndex2(), }) const typeClass = computed(() => { const type4 = state2.type return type4 && TypeComponentsMap[type4] ? `el-message-box-icon--${type4}` : '' }) const btnSize = useSize$1( computed(() => props2.buttonSize), { prop: true, form: true, formItem: true } ) const iconComponent = computed( () => state2.icon || TypeComponentsMap[state2.type] || '' ) const hasMessage = computed(() => !!state2.message) const rootRef = ref() const headerRef = ref() const inputRef = ref() const confirmRef = ref() const confirmButtonClasses = computed(() => state2.confirmButtonClass) watch$1( () => state2.inputValue, async (val2) => { await nextTick() if (props2.boxType === 'prompt' && val2 !== null) { validate() } }, { immediate: true } ) watch$1( () => visible.value, (val2) => { if (val2) { if (props2.boxType === 'alert' || props2.boxType === 'confirm') { nextTick().then(() => { var _a2, _b2, _c2 ;(_c2 = (_b2 = (_a2 = confirmRef.value) == null ? void 0 : _a2.$el) == null ? void 0 : _b2.focus) == null ? void 0 : _c2.call(_b2) }) } state2.zIndex = nextZIndex2() } if (props2.boxType !== 'prompt') return if (val2) { nextTick().then(() => { if (inputRef.value && inputRef.value.$el) { getInputElement().focus() } }) } else { state2.editorErrorMessage = '' state2.validateError = false } } ) const draggable2 = computed(() => props2.draggable) useDraggable$1(rootRef, headerRef, draggable2) onMounted(async () => { await nextTick() if (props2.closeOnHashChange) { on$2(window, 'hashchange', doClose) } }) onBeforeUnmount(() => { if (props2.closeOnHashChange) { off$1(window, 'hashchange', doClose) } }) function doClose() { if (!visible.value) return visible.value = false nextTick(() => { if (state2.action) emit2('action', state2.action) }) } const handleWrapperClick = () => { if (props2.closeOnClickModal) { handleAction(state2.distinguishCancelAndClose ? 'close' : 'cancel') } } const overlayEvent = useSameTarget(handleWrapperClick) const handleInputEnter = (e2) => { if (state2.inputType !== 'textarea') { e2.preventDefault() return handleAction('confirm') } } const handleAction = (action) => { var _a2 if (props2.boxType === 'prompt' && action === 'confirm' && !validate()) { return } state2.action = action if (state2.beforeClose) { ;(_a2 = state2.beforeClose) == null ? void 0 : _a2.call(state2, action, state2, doClose) } else { doClose() } } const validate = () => { if (props2.boxType === 'prompt') { const inputPattern = state2.inputPattern if (inputPattern && !inputPattern.test(state2.inputValue || '')) { state2.editorErrorMessage = state2.inputErrorMessage || t3('el.messagebox.error') state2.validateError = true return false } const inputValidator = state2.inputValidator if (typeof inputValidator === 'function') { const validateResult = inputValidator(state2.inputValue) if (validateResult === false) { state2.editorErrorMessage = state2.inputErrorMessage || t3('el.messagebox.error') state2.validateError = true return false } if (typeof validateResult === 'string') { state2.editorErrorMessage = validateResult state2.validateError = true return false } } } state2.editorErrorMessage = '' state2.validateError = false return true } const getInputElement = () => { const inputRefs = inputRef.value.$refs return inputRefs.input || inputRefs.textarea } const handleClose = () => { handleAction('close') } if (props2.closeOnPressEscape) { useModal( { handleClose, }, visible ) } else { usePreventGlobal(visible, 'keydown', (e2) => e2.code === EVENT_CODE.esc) } if (props2.lockScroll) { useLockscreen(visible) } useRestoreActive(visible) return { ...toRefs$2(state2), overlayEvent, visible, hasMessage, typeClass, btnSize, iconComponent, confirmButtonClasses, rootRef, headerRef, inputRef, confirmRef, doClose, handleClose, handleWrapperClick, handleInputEnter, handleAction, t: t3, } }, }) const _hoisted_1$61 = ['aria-label'] const _hoisted_2$4Z = { key: 0, ref: 'headerRef', class: 'el-message-box__header', } const _hoisted_3$4w = { class: 'el-message-box__title' } const _hoisted_4$3X = { class: 'el-message-box__content' } const _hoisted_5$3x = { class: 'el-message-box__container' } const _hoisted_6$39 = { key: 1, class: 'el-message-box__message', } const _hoisted_7$2O = { key: 0 } const _hoisted_8$2u = ['innerHTML'] const _hoisted_9$2i = { class: 'el-message-box__input' } const _hoisted_10$24 = { class: 'el-message-box__btns' } function _sfc_render$k(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_icon = resolveComponent('el-icon') const _component_close = resolveComponent('close') const _component_el_input = resolveComponent('el-input') const _component_el_button = resolveComponent('el-button') const _component_el_overlay = resolveComponent('el-overlay') const _directive_trap_focus = resolveDirective('trap-focus') return ( openBlock(), createBlock( Transition, { name: 'fade-in-linear', onAfterLeave: _cache[11] || (_cache[11] = ($event) => _ctx.$emit('vanish')), }, { default: withCtx(() => [ withDirectives( createVNode$1( _component_el_overlay, { 'z-index': _ctx.zIndex, 'overlay-class': ['is-message-box', _ctx.modalClass], mask: _ctx.modal, }, { default: withCtx(() => [ createElementVNode( 'div', { class: 'el-overlay-message-box', onClick: _cache[8] || (_cache[8] = (...args) => _ctx.overlayEvent.onClick && _ctx.overlayEvent.onClick(...args)), onMousedown: _cache[9] || (_cache[9] = (...args) => _ctx.overlayEvent.onMousedown && _ctx.overlayEvent.onMousedown(...args)), onMouseup: _cache[10] || (_cache[10] = (...args) => _ctx.overlayEvent.onMouseup && _ctx.overlayEvent.onMouseup(...args)), }, [ withDirectives( (openBlock(), createElementBlock( 'div', { ref: 'rootRef', role: 'dialog', 'aria-label': _ctx.title || 'dialog', 'aria-modal': 'true', class: normalizeClass([ 'el-message-box', _ctx.customClass, { 'el-message-box--center': _ctx.center, 'is-draggable': _ctx.draggable, }, ]), style: normalizeStyle$1(_ctx.customStyle), onClick: _cache[7] || (_cache[7] = withModifiers(() => {}, ['stop'])), }, [ _ctx.title !== null && _ctx.title !== void 0 ? (openBlock(), createElementBlock( 'div', _hoisted_2$4Z, [ createElementVNode('div', _hoisted_3$4w, [ _ctx.iconComponent && _ctx.center ? (openBlock(), createBlock( _component_el_icon, { key: 0, class: normalizeClass([ 'el-message-box__status', _ctx.typeClass, ]), }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent( _ctx.iconComponent ) )), ]), _: 1, }, 8, ['class'] )) : createCommentVNode('v-if', true), createElementVNode( 'span', null, toDisplayString$1(_ctx.title), 1 ), ]), _ctx.showClose ? (openBlock(), createElementBlock( 'button', { key: 0, type: 'button', class: 'el-message-box__headerbtn', 'aria-label': 'Close', onClick: _cache[0] || (_cache[0] = ($event) => _ctx.handleAction( _ctx.distinguishCancelAndClose ? 'close' : 'cancel' )), onKeydown: _cache[1] || (_cache[1] = withKeys( withModifiers( ($event) => _ctx.handleAction( _ctx.distinguishCancelAndClose ? 'close' : 'cancel' ), ['prevent'] ), ['enter'] )), }, [ createVNode$1( _component_el_icon, { class: 'el-message-box__close', }, { default: withCtx(() => [ createVNode$1( _component_close ), ]), _: 1, } ), ], 32 )) : createCommentVNode('v-if', true), ], 512 )) : createCommentVNode('v-if', true), createElementVNode('div', _hoisted_4$3X, [ createElementVNode('div', _hoisted_5$3x, [ _ctx.iconComponent && !_ctx.center && _ctx.hasMessage ? (openBlock(), createBlock( _component_el_icon, { key: 0, class: normalizeClass([ 'el-message-box__status', _ctx.typeClass, ]), }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent( _ctx.iconComponent ) )), ]), _: 1, }, 8, ['class'] )) : createCommentVNode('v-if', true), _ctx.hasMessage ? (openBlock(), createElementBlock('div', _hoisted_6$39, [ renderSlot( _ctx.$slots, 'default', {}, () => [ !_ctx.dangerouslyUseHTMLString ? (openBlock(), createElementBlock( 'p', _hoisted_7$2O, toDisplayString$1(_ctx.message), 1 )) : (openBlock(), createElementBlock( 'p', { key: 1, innerHTML: _ctx.message, }, null, 8, _hoisted_8$2u )), ] ), ])) : createCommentVNode('v-if', true), ]), withDirectives( createElementVNode( 'div', _hoisted_9$2i, [ createVNode$1( _component_el_input, { ref: 'inputRef', modelValue: _ctx.inputValue, 'onUpdate:modelValue': _cache[2] || (_cache[2] = ($event) => (_ctx.inputValue = $event)), type: _ctx.inputType, placeholder: _ctx.inputPlaceholder, class: normalizeClass({ invalid: _ctx.validateError, }), onKeydown: withKeys( _ctx.handleInputEnter, ['enter'] ), }, null, 8, [ 'modelValue', 'type', 'placeholder', 'class', 'onKeydown', ] ), createElementVNode( 'div', { class: 'el-message-box__errormsg', style: normalizeStyle$1({ visibility: !!_ctx.editorErrorMessage ? 'visible' : 'hidden', }), }, toDisplayString$1( _ctx.editorErrorMessage ), 5 ), ], 512 ), [[vShow, _ctx.showInput]] ), ]), createElementVNode('div', _hoisted_10$24, [ _ctx.showCancelButton ? (openBlock(), createBlock( _component_el_button, { key: 0, loading: _ctx.cancelButtonLoading, class: normalizeClass([ _ctx.cancelButtonClass, ]), round: _ctx.roundButton, size: _ctx.btnSize, onClick: _cache[3] || (_cache[3] = ($event) => _ctx.handleAction('cancel')), onKeydown: _cache[4] || (_cache[4] = withKeys( withModifiers( ($event) => _ctx.handleAction('cancel'), ['prevent'] ), ['enter'] )), }, { default: withCtx(() => [ createTextVNode( toDisplayString$1( _ctx.cancelButtonText || _ctx.t('el.messagebox.cancel') ), 1 ), ]), _: 1, }, 8, ['loading', 'class', 'round', 'size'] )) : createCommentVNode('v-if', true), withDirectives( createVNode$1( _component_el_button, { ref: 'confirmRef', type: 'primary', loading: _ctx.confirmButtonLoading, class: normalizeClass([ _ctx.confirmButtonClasses, ]), round: _ctx.roundButton, disabled: _ctx.confirmButtonDisabled, size: _ctx.btnSize, onClick: _cache[5] || (_cache[5] = ($event) => _ctx.handleAction('confirm')), onKeydown: _cache[6] || (_cache[6] = withKeys( withModifiers( ($event) => _ctx.handleAction('confirm'), ['prevent'] ), ['enter'] )), }, { default: withCtx(() => [ createTextVNode( toDisplayString$1( _ctx.confirmButtonText || _ctx.t('el.messagebox.confirm') ), 1 ), ]), _: 1, }, 8, [ 'loading', 'class', 'round', 'disabled', 'size', ] ), [[vShow, _ctx.showConfirmButton]] ), ]), ], 14, _hoisted_1$61 )), [[_directive_trap_focus]] ), ], 32 ), ]), _: 3, }, 8, ['z-index', 'overlay-class', 'mask'] ), [[vShow, _ctx.visible]] ), ]), _: 3, } ) ) } var MessageBoxConstructor = /* @__PURE__ */ _export_sfc$1(_sfc_main$77, [ ['render', _sfc_render$k], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/message-box/src/index.vue', ], ]) const messageInstance = /* @__PURE__ */ new Map() const initInstance = (props2, container, appContext = null) => { const vnode = h$4(MessageBoxConstructor, props2) vnode.appContext = appContext render$1(vnode, container) document.body.appendChild(container.firstElementChild) return vnode.component } const genContainer = () => { return document.createElement('div') } const showMessage = (options2, appContext) => { const container = genContainer() options2.onVanish = () => { render$1(null, container) messageInstance.delete(vm) } options2.onAction = (action) => { const currentMsg = messageInstance.get(vm) let resolve2 if (options2.showInput) { resolve2 = { value: vm.inputValue, action } } else { resolve2 = action } if (options2.callback) { options2.callback(resolve2, instance.proxy) } else { if (action === 'cancel' || action === 'close') { if (options2.distinguishCancelAndClose && action !== 'cancel') { currentMsg.reject('close') } else { currentMsg.reject('cancel') } } else { currentMsg.resolve(resolve2) } } } const instance = initInstance(options2, container, appContext) const vm = instance.proxy for (const prop in options2) { if (hasOwn$e(options2, prop) && !hasOwn$e(vm.$props, prop)) { vm[prop] = options2[prop] } } watch$1( () => vm.message, (newVal, oldVal) => { if (isVNode$1(newVal)) { instance.slots.default = () => [newVal] } else if (isVNode$1(oldVal) && !isVNode$1(newVal)) { delete instance.slots.default } }, { immediate: true, } ) vm.visible = true return vm } function MessageBox(options2, appContext = null) { if (!isClient$1) return Promise.reject() let callback if (isString$f(options2) || isVNode$1(options2)) { options2 = { message: options2, } } else { callback = options2.callback } return new Promise((resolve2, reject2) => { const vm = showMessage( options2, appContext != null ? appContext : MessageBox._context ) messageInstance.set(vm, { options: options2, callback, resolve: resolve2, reject: reject2, }) }) } const MESSAGE_BOX_VARIANTS = ['alert', 'confirm', 'prompt'] const MESSAGE_BOX_DEFAULT_OPTS = { alert: { closeOnPressEscape: false, closeOnClickModal: false }, confirm: { showCancelButton: true }, prompt: { showCancelButton: true, showInput: true }, } MESSAGE_BOX_VARIANTS.forEach((boxType) => { MessageBox[boxType] = messageBoxFactory(boxType) }) function messageBoxFactory(boxType) { return (message2, titleOrOpts, options2, appContext) => { let title if (isObject$v(titleOrOpts)) { options2 = titleOrOpts title = '' } else if (isUndefined$c(titleOrOpts)) { title = '' } else { title = titleOrOpts } return MessageBox( Object.assign( { title, message: message2, type: '', ...MESSAGE_BOX_DEFAULT_OPTS[boxType], }, options2, { boxType, } ), appContext ) } } MessageBox.close = () => { messageInstance.forEach((_2, vm) => { vm.doClose() }) messageInstance.clear() } MessageBox._context = null const _MessageBox = MessageBox _MessageBox.install = (app2) => { _MessageBox._context = app2._context app2.config.globalProperties.$msgbox = _MessageBox app2.config.globalProperties.$messageBox = _MessageBox app2.config.globalProperties.$alert = _MessageBox.alert app2.config.globalProperties.$confirm = _MessageBox.confirm app2.config.globalProperties.$prompt = _MessageBox.prompt } const ElMessageBox = _MessageBox const notificationTypes = ['success', 'info', 'warning', 'error'] const notificationProps = buildProps({ customClass: { type: String, default: '', }, dangerouslyUseHTMLString: { type: Boolean, default: false, }, duration: { type: Number, default: 4500, }, icon: { type: definePropType([String, Object]), default: '', }, id: { type: String, default: '', }, message: { type: definePropType([String, Object]), default: '', }, offset: { type: Number, default: 0, }, onClick: { type: definePropType(Function), default: () => void 0, }, onClose: { type: definePropType(Function), required: true, }, position: { type: String, values: ['top-right', 'top-left', 'bottom-right', 'bottom-left'], default: 'top-right', }, showClose: { type: Boolean, default: true, }, title: { type: String, default: '', }, type: { type: String, values: [...notificationTypes, ''], default: '', }, zIndex: { type: Number, default: 0, }, }) const notificationEmits = { destroy: () => true, } const _sfc_main$76 = defineComponent({ name: 'ElNotification', components: { ElIcon, ...TypeComponents, }, props: notificationProps, emits: notificationEmits, setup(props2) { const ns = useNamespace('notification') const visible = ref(false) let timer2 = void 0 const typeClass = computed(() => { const type4 = props2.type return type4 && TypeComponentsMap[props2.type] ? ns.m(type4) : '' }) const iconComponent = computed(() => { return TypeComponentsMap[props2.type] || props2.icon || '' }) const horizontalClass = computed(() => props2.position.endsWith('right') ? 'right' : 'left' ) const verticalProperty = computed(() => props2.position.startsWith('top') ? 'top' : 'bottom' ) const positionStyle = computed(() => { return { [verticalProperty.value]: `${props2.offset}px`, zIndex: props2.zIndex, } }) function startTimer2() { if (props2.duration > 0) { ;({ stop: timer2 } = useTimeoutFn$1(() => { if (visible.value) close2() }, props2.duration)) } } function clearTimer2() { timer2 == null ? void 0 : timer2() } function close2() { visible.value = false } function onKeydown({ code: code2 }) { if (code2 === EVENT_CODE.delete || code2 === EVENT_CODE.backspace) { clearTimer2() } else if (code2 === EVENT_CODE.esc) { if (visible.value) { close2() } } else { startTimer2() } } onMounted(() => { startTimer2() visible.value = true }) useEventListener$1(document, 'keydown', onKeydown) return { ns, horizontalClass, typeClass, iconComponent, positionStyle, visible, close: close2, clearTimer: clearTimer2, startTimer: startTimer2, } }, }) const _hoisted_1$60 = ['id'] const _hoisted_2$4Y = ['textContent'] const _hoisted_3$4v = { key: 0 } const _hoisted_4$3W = ['innerHTML'] function _sfc_render$j(_ctx, _cache, $props2, $setup, $data, $options) { const _component_el_icon = resolveComponent('el-icon') const _component_close = resolveComponent('close') return ( openBlock(), createBlock( Transition, { name: _ctx.ns.b('fade'), onBeforeLeave: _ctx.onClose, onAfterLeave: _cache[3] || (_cache[3] = ($event) => _ctx.$emit('destroy')), }, { default: withCtx(() => [ withDirectives( createElementVNode( 'div', { id: _ctx.id, class: normalizeClass([ _ctx.ns.b(), _ctx.customClass, _ctx.horizontalClass, ]), style: normalizeStyle$1(_ctx.positionStyle), role: 'alert', onMouseenter: _cache[0] || (_cache[0] = (...args) => _ctx.clearTimer && _ctx.clearTimer(...args)), onMouseleave: _cache[1] || (_cache[1] = (...args) => _ctx.startTimer && _ctx.startTimer(...args)), onClick: _cache[2] || (_cache[2] = (...args) => _ctx.onClick && _ctx.onClick(...args)), }, [ _ctx.iconComponent ? (openBlock(), createBlock( _component_el_icon, { key: 0, class: normalizeClass([ _ctx.ns.e('icon'), _ctx.typeClass, ]), }, { default: withCtx(() => [ (openBlock(), createBlock( resolveDynamicComponent(_ctx.iconComponent) )), ]), _: 1, }, 8, ['class'] )) : createCommentVNode('v-if', true), createElementVNode( 'div', { class: normalizeClass(_ctx.ns.e('group')), }, [ createElementVNode( 'h2', { class: normalizeClass(_ctx.ns.e('title')), textContent: toDisplayString$1(_ctx.title), }, null, 10, _hoisted_2$4Y ), withDirectives( createElementVNode( 'div', { class: normalizeClass(_ctx.ns.e('content')), style: normalizeStyle$1( !!_ctx.title ? void 0 : { margin: 0 } ), }, [ renderSlot(_ctx.$slots, 'default', {}, () => [ !_ctx.dangerouslyUseHTMLString ? (openBlock(), createElementBlock( 'p', _hoisted_3$4v, toDisplayString$1(_ctx.message), 1 )) : (openBlock(), createElementBlock( Fragment, { key: 1 }, [ createCommentVNode( " Caution here, message could've been compromized, nerver use user's input as message " ), createCommentVNode( ' eslint-disable-next-line ' ), createElementVNode( 'p', { innerHTML: _ctx.message }, null, 8, _hoisted_4$3W ), ], 2112 )), ]), ], 6 ), [[vShow, _ctx.message]] ), _ctx.showClose ? (openBlock(), createBlock( _component_el_icon, { key: 0, class: normalizeClass(_ctx.ns.e('closeBtn')), onClick: withModifiers(_ctx.close, ['stop']), }, { default: withCtx(() => [ createVNode$1(_component_close), ]), _: 1, }, 8, ['class', 'onClick'] )) : createCommentVNode('v-if', true), ], 2 ), ], 46, _hoisted_1$60 ), [[vShow, _ctx.visible]] ), ]), _: 3, }, 8, ['name', 'onBeforeLeave'] ) ) } var NotificationConstructor = /* @__PURE__ */ _export_sfc$1(_sfc_main$76, [ ['render', _sfc_render$j], [ '__file', '/home/runner/work/element-plus/element-plus/packages/components/notification/src/notification.vue', ], ]) const notifications = { 'top-left': [], 'top-right': [], 'bottom-left': [], 'bottom-right': [], } const GAP_SIZE = 16 let seed = 1 const notify$2 = function (options2 = {}, context2 = null) { if (!isClient$1) return { close: () => void 0 } if (typeof options2 === 'string' || isVNode$1(options2)) { options2 = { message: options2 } } const position2 = options2.position || 'top-right' let verticalOffset = options2.offset || 0 notifications[position2].forEach(({ vm: vm2 }) => { var _a2 verticalOffset += (((_a2 = vm2.el) == null ? void 0 : _a2.offsetHeight) || 0) + GAP_SIZE }) verticalOffset += GAP_SIZE const { nextZIndex: nextZIndex2 } = useZIndex() const id2 = `notification_${seed++}` const userOnClose = options2.onClose const props2 = { zIndex: nextZIndex2(), offset: verticalOffset, ...options2, id: id2, onClose: () => { close(id2, position2, userOnClose) }, } let appendTo = document.body if (isElement$3(options2.appendTo)) { appendTo = options2.appendTo } else if (isString$f(options2.appendTo)) { appendTo = document.querySelector(options2.appendTo) } if (!isElement$3(appendTo)) { appendTo = document.body } const container = document.createElement('div') const vm = createVNode$1( NotificationConstructor, props2, isVNode$1(props2.message) ? { default: () => props2.message, } : null ) vm.appContext = context2 != null ? context2 : notify$2._context vm.props.onDestroy = () => { render$1(null, container) } render$1(vm, container) notifications[position2].push({ vm }) appendTo.appendChild(container.firstElementChild) return { close: () => { vm.component.proxy.visible = false }, } } notificationTypes.forEach((type4) => { notify$2[type4] = (options2 = {}) => { if (typeof options2 === 'string' || isVNode$1(options2)) { options2 = { message: options2, } } return notify$2({ ...options2, type: type4, }) } }) function close(id2, position2, userOnClose) { const orientedNotifications = notifications[position2] const idx = orientedNotifications.findIndex(({ vm: vm2 }) => { var _a2 return ((_a2 = vm2.component) == null ? void 0 : _a2.props.id) === id2 }) if (idx === -1) return const { vm } = orientedNotifications[idx] if (!vm) return userOnClose == null ? void 0 : userOnClose(vm) const removedHeight = vm.el.offsetHeight const verticalPos = position2.split('-')[0] orientedNotifications.splice(idx, 1) const len2 = orientedNotifications.length if (len2 < 1) return for (let i2 = idx; i2 < len2; i2++) { const { el: el2, component: component2 } = orientedNotifications[i2].vm const pos = Number.parseInt(el2.style[verticalPos], 10) - removedHeight - GAP_SIZE component2.props.offset = pos } } function closeAll() { for (const orientedNotifications of Object.values(notifications)) { orientedNotifications.forEach(({ vm }) => { vm.component.proxy.visible = false }) } } notify$2.closeAll = closeAll notify$2._context = null const ElNotification = withInstallFunction(notify$2, '$notify') var Plugins = [ ElInfiniteScroll, ElLoading, ElMessage, ElMessageBox, ElNotification, ElPopoverDirective, ] var installer = makeInstaller([...Components, ...Plugins]) const install$T = installer.install const version$6 = installer.version var ElementPlus = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, install: install$T, version: version$6, default: installer, makeInstaller, dayjs, affixEmits, affixProps, ElAffix, alertEffects, alertEmits, alertProps, ElAlert, autocompleteEmits, autocompleteProps, ElAutocomplete, avatarEmits, avatarProps, ElAvatar, backtopEmits, backtopProps, ElBacktop, badgeProps, ElBadge, breadcrumbProps, breadcrumbItemProps, ElBreadcrumb, ElBreadcrumbItem, buttonEmits, buttonNativeTypes, buttonProps, buttonTypes, ElButton, ElButtonGroup: ElButtonGroup$1, calendarEmits, calendarProps, ElCalendar, cardProps, ElCard, carouselEmits, carouselProps, carouselItemProps, ElCarousel, ElCarouselItem, ElCascader, CASCADER_PANEL_INJECTION_KEY, ExpandTrigger: ExpandTrigger$1, CommonProps, DefaultProps, useCascaderConfig, ElCascaderPanel, checkTagEmits, checkTagProps, ElCheckTag, ElCheckbox, ElCheckboxButton, ElCheckboxGroup: ElCheckboxGroup$1, colProps, ElCol, collapseEmits, collapseProps, emitChangeFn, collapseItemProps, ElCollapse, ElCollapseItem, ElCollapseTransition, ElColorPicker, configProviderProps, messageConfig, ElConfigProvider, ElAside, ElContainer, ElFooter, ElHeader, ElMain, ElDatePicker, ElDescriptions, ElDescriptionsItem, useDialog, dialogEmits, dialogProps, ElDialog, dividerProps, ElDivider, drawerEmits, drawerProps, ElDrawer, DROPDOWN_COLLECTION_INJECTION_KEY: COLLECTION_INJECTION_KEY, DROPDOWN_COLLECTION_ITEM_INJECTION_KEY: COLLECTION_ITEM_INJECTION_KEY, ElCollection, ElCollectionItem, FIRST_KEYS, FIRST_LAST_KEYS, LAST_KEYS, dropdownItemProps, dropdownMenuProps, dropdownProps, DROPDOWN_INJECTION_KEY, ElDropdown, ElDropdownItem, ElDropdownMenu, emptyProps, ElEmpty, formEmits, formProps, formItemProps: formItemProps$1, formItemValidateStates, ElForm, ElFormItem, iconProps, ElIcon, imageEmits, imageProps, ElImage, imageViewerEmits, imageViewerProps, ElImageViewer, inputEmits, inputProps, ElInput, inputNumberEmits, inputNumberProps, ElInputNumber, linkEmits, linkProps, ElLink, menuEmits, menuProps, menuItemEmits, menuItemProps, menuItemGroupProps, subMenuProps, ElMenu, ElMenuItem, ElMenuItemGroup, ElSubMenu, overlayEmits, overlayProps, ElOverlay, pageHeaderEmits, pageHeaderProps, ElPageHeader, paginationEmits, paginationProps, ElPagination, popconfirmProps, ElPopconfirm, useDeprecateAppendToBody, Effect, usePopperProps, usePopperTriggerProps, usePopperContentProps, usePopperCoreConfigProps, usePopperArrowProps, ElPopperArrow, ElPopperTrigger, ElPopperContent, ElPopper, progressProps, ElProgress, radioEmits, radioProps, radioPropsBase, useRadio, radioGroupEmits, radioGroupProps, radioButtonProps, ElRadio, ElRadioButton, ElRadioGroup, rateEmits, rateProps, ElRate, IconComponentMap, IconMap, resultProps, ElResult, rowProps, ElRow, BAR_MAP, renderThumbStyle: renderThumbStyle$1, scrollbarEmits, scrollbarProps, thumbProps, ElScrollbar, selectGroupKey, selectKey, ElOption: ElOption$1, ElOptionGroup, ElSelect, selectV2InjectionKey, ElSelectV2, skeletonProps, skeletonItemProps, ElSkeleton, ElSkeletonItem, ElSlider, spaceProps, useSpace, ElSpace, ElStep, ElSteps, switchEmits, switchProps, ElSwitch, ElTable, ElTableColumn, tabsEmits, tabsProps, tabBarProps, tabNavProps, tabPaneProps, ElTabPane, ElTabs, tagEmits, tagProps, ElTag, extractDateFormat, extractTimeFormat, rangeArr, DEFAULT_FORMATS_DATE, DEFAULT_FORMATS_DATEPICKER, DEFAULT_FORMATS_TIME, timePickerDefaultProps, CommonPicker, TimePickPanel, ElTimePicker, ElTimeSelect, timelineItemProps, ElTimeline, ElTimelineItem, useTooltipContentProps, useTooltipProps, useTooltipTriggerProps, TOOLTIP_INJECTION_KEY, ElTooltip, CHANGE_EVENT, INPUT_EVENT, UPDATE_MODEL_EVENT, ElTransfer, ElTree, ElTreeSelect, ElTreeV2, genFileId, uploadBaseProps, uploadListTypes, uploadProps, uploadContentProps, uploadListEmits, uploadListProps, uploadDraggerEmits, uploadDraggerProps, ElUpload, FixedSizeList, DynamicSizeList, FixedSizeGrid: FixedSizeGrid$1, DynamicSizeGrid: FixedSizeGrid, virtualizedGridProps, virtualizedListProps, virtualizedProps, virtualizedScrollbarProps, ElInfiniteScroll, ElLoading, ElLoadingDirective: vLoading, vLoading, ElLoadingService: Loading, messageEmits, messageProps, messageTypes, ElMessage, ElMessageBox, notificationEmits, notificationProps, notificationTypes, ElNotification, ElPopover, ElPopoverDirective, EVENT_CODE, WEEK_DAYS, datePickTypes, componentSizes, ClickOutside, RepeatClick, TrapFocus, Mousewheel, Resize, useAttrs, useDisabled: useDisabled$1, useSize: useSize$1, useSizeProp, useDeprecated, useDraggable: useDraggable$1, useFocus: useFocus$1, useFormItem, provideGlobalConfig, useGlobalConfig, buildLocaleContext, buildTranslator, translate: translate$2, useLocale, useLockscreen, useModal, createModelToggleComposable, useModelToggle: useModelToggle$1, useModelToggleEmits: useModelToggleEmits$1, useModelToggleProps: useModelToggleProps$1, usePreventGlobal, useProp, useRestoreActive, useSameTarget, useTeleport, useThrottleRender, useTimeout: useTimeout$1, useTransitionFallthrough, useTransitionFallthroughEmits, ID_INJECTION_KEY, useId, useEscapeKeydown, POPPER_CONTAINER_ID, POPPER_CONTAINER_SELECTOR, usePopperContainer, useDelayedRender, useDelayedToggle, useDelayedToggleProps, FORWARD_REF_INJECTION_KEY, useForwardRef, useForwardRefDirective, useNamespace, useZIndex, arrowMiddleware, getPositionDataWithUnit, useFloating, useFloatingProps, breadcrumbKey, buttonGroupContextKey, carouselContextKey, collapseContextKey, configProviderContextKey, dialogInjectionKey, formContextKey, formItemContextKey, elPaginationKey, radioGroupKey, rowContextKey, scrollbarContextKey, tabsRootContextKey, uploadContextKey, POPPER_CONTENT_INJECTION_KEY, POPPER_INJECTION_KEY, TOOLTIP_V2_OPEN, tooltipV2ContentKey, tooltipV2RootKey, }, Symbol.toStringTag, { value: 'Module' } ) ) var index$r = '' var __defProp$9$1 = Object.defineProperty var __defProps$6$1 = Object.defineProperties var __getOwnPropDescs$6$1 = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$b$1 = Object.getOwnPropertySymbols var __hasOwnProp$b$1 = Object.prototype.hasOwnProperty var __propIsEnum$b$1 = Object.prototype.propertyIsEnumerable var __defNormalProp$9$1 = (obj, key2, value2) => key2 in obj ? __defProp$9$1(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$9$1 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$b$1.call(b2, prop)) __defNormalProp$9$1(a2, prop, b2[prop]) if (__getOwnPropSymbols$b$1) for (var prop of __getOwnPropSymbols$b$1(b2)) { if (__propIsEnum$b$1.call(b2, prop)) __defNormalProp$9$1(a2, prop, b2[prop]) } return a2 } var __spreadProps$6$1 = (a2, b2) => __defProps$6$1(a2, __getOwnPropDescs$6$1(b2)) function computedEager(fn2, options2) { var _a2 const result = shallowRef() watchEffect( () => { result.value = fn2() }, __spreadProps$6$1(__spreadValues$9$1({}, options2), { flush: (_a2 = options2 == null ? void 0 : options2.flush) != null ? _a2 : 'sync', }) ) return readonly(result) } var _a$3 const isClient = typeof window !== 'undefined' const isDef$1 = (val2) => typeof val2 !== 'undefined' const assert$1 = (condition2, ...infos) => { if (!condition2) console.warn(...infos) } const toString$d = Object.prototype.toString const isBoolean$4 = (val2) => typeof val2 === 'boolean' const isFunction$k = (val2) => typeof val2 === 'function' const isNumber$g = (val2) => typeof val2 === 'number' const isString$e = (val2) => typeof val2 === 'string' const isObject$t = (val2) => toString$d.call(val2) === '[object Object]' const isWindow$2 = (val2) => typeof window !== 'undefined' && toString$d.call(val2) === '[object Window]' const now$5 = () => Date.now() const timestamp$2 = () => +Date.now() const clamp$1 = (n2, min3, max3) => Math.min(max3, Math.max(min3, n2)) const noop$6 = () => {} const rand = (min3, max3) => { min3 = Math.ceil(min3) max3 = Math.floor(max3) return Math.floor(Math.random() * (max3 - min3 + 1)) + min3 } const isIOS = isClient && ((_a$3 = window == null ? void 0 : window.navigator) == null ? void 0 : _a$3.userAgent) && /iP(ad|hone|od)/.test(window.navigator.userAgent) const hasOwn$d = (val2, key2) => Object.prototype.hasOwnProperty.call(val2, key2) function resolveUnref(r2) { return typeof r2 === 'function' ? r2() : unref(r2) } function createFilterWrapper(filter2, fn2) { function wrapper(...args) { return new Promise((resolve2, reject2) => { Promise.resolve( filter2(() => fn2.apply(this, args), { fn: fn2, thisArg: this, args }) ) .then(resolve2) .catch(reject2) }) } return wrapper } const bypassFilter = (invoke2) => { return invoke2() } function debounceFilter(ms, options2 = {}) { let timer2 let maxTimer let lastRejector = noop$6 const _clearTimeout = (timer22) => { clearTimeout(timer22) lastRejector() lastRejector = noop$6 } const filter2 = (invoke2) => { const duration2 = resolveUnref(ms) const maxDuration = resolveUnref(options2.maxWait) if (timer2) _clearTimeout(timer2) if (duration2 <= 0 || (maxDuration !== void 0 && maxDuration <= 0)) { if (maxTimer) { _clearTimeout(maxTimer) maxTimer = null } return Promise.resolve(invoke2()) } return new Promise((resolve2, reject2) => { lastRejector = options2.rejectOnCancel ? reject2 : resolve2 if (maxDuration && !maxTimer) { maxTimer = setTimeout(() => { if (timer2) _clearTimeout(timer2) maxTimer = null resolve2(invoke2()) }, maxDuration) } timer2 = setTimeout(() => { if (maxTimer) _clearTimeout(maxTimer) maxTimer = null resolve2(invoke2()) }, duration2) }) } return filter2 } function throttleFilter( ms, trailing = true, leading = true, rejectOnCancel = false ) { let lastExec = 0 let timer2 let isLeading = true let lastRejector = noop$6 let lastValue const clear2 = () => { if (timer2) { clearTimeout(timer2) timer2 = void 0 lastRejector() lastRejector = noop$6 } } const filter2 = (_invoke) => { const duration2 = resolveUnref(ms) const elapsed = Date.now() - lastExec const invoke2 = () => { return (lastValue = _invoke()) } clear2() if (duration2 <= 0) { lastExec = Date.now() return invoke2() } if (elapsed > duration2 && (leading || !isLeading)) { lastExec = Date.now() invoke2() } else if (trailing) { lastValue = new Promise((resolve2, reject2) => { lastRejector = rejectOnCancel ? reject2 : resolve2 timer2 = setTimeout(() => { lastExec = Date.now() isLeading = true resolve2(invoke2()) clear2() }, Math.max(0, duration2 - elapsed)) }) } if (!leading && !timer2) timer2 = setTimeout(() => (isLeading = true), duration2) isLeading = false return lastValue } return filter2 } function pausableFilter(extendFilter = bypassFilter) { const isActive = ref(true) function pause() { isActive.value = false } function resume() { isActive.value = true } const eventFilter = (...args) => { if (isActive.value) extendFilter(...args) } return { isActive: readonly(isActive), pause, resume, eventFilter } } function __onlyVue3(name2 = 'this function') { return } function __onlyVue27Plus(name2 = 'this function') { return } const directiveHooks = { mounted: 'mounted', updated: 'updated', unmounted: 'unmounted', } function promiseTimeout(ms, throwOnTimeout = false, reason = 'Timeout') { return new Promise((resolve2, reject2) => { if (throwOnTimeout) setTimeout(() => reject2(reason), ms) else setTimeout(resolve2, ms) }) } function identity$1(arg) { return arg } function createSingletonPromise(fn2) { let _promise function wrapper() { if (!_promise) _promise = fn2() return _promise } wrapper.reset = async () => { const _prev = _promise _promise = void 0 if (_prev) await _prev } return wrapper } function invoke$2(fn2) { return fn2() } function containsProp(obj, ...props2) { return props2.some((k2) => k2 in obj) } function increaseWithUnit(target2, delta) { var _a2 if (typeof target2 === 'number') return target2 + delta const value2 = ((_a2 = target2.match(/^-?[0-9]+\.?[0-9]*/)) == null ? void 0 : _a2[0]) || '' const unit = target2.slice(value2.length) const result = parseFloat(value2) + delta if (Number.isNaN(result)) return target2 return result + unit } function objectPick(obj, keys3, omitUndefined = false) { return keys3.reduce((n2, k2) => { if (k2 in obj) { if (!omitUndefined || obj[k2] !== void 0) n2[k2] = obj[k2] } return n2 }, {}) } function computedWithControl(source2, fn2) { let v4 = void 0 let track2 let trigger2 const dirty = ref(true) const update3 = () => { dirty.value = true trigger2() } watch$1(source2, update3, { flush: 'sync' }) const get3 = isFunction$k(fn2) ? fn2 : fn2.get const set2 = isFunction$k(fn2) ? void 0 : fn2.set const result = customRef((_track, _trigger) => { track2 = _track trigger2 = _trigger return { get() { if (dirty.value) { v4 = get3() dirty.value = false } track2() return v4 }, set(v22) { set2 == null ? void 0 : set2(v22) }, } }) if (Object.isExtensible(result)) result.trigger = update3 return result } function tryOnScopeDispose(fn2) { if (getCurrentScope()) { onScopeDispose(fn2) return true } return false } function createEventHook() { const fns = [] const off2 = (fn2) => { const index2 = fns.indexOf(fn2) if (index2 !== -1) fns.splice(index2, 1) } const on2 = (fn2) => { fns.push(fn2) const offFn = () => off2(fn2) tryOnScopeDispose(offFn) return { off: offFn, } } const trigger2 = (param) => { fns.forEach((fn2) => fn2(param)) } return { on: on2, off: off2, trigger: trigger2, } } function createGlobalState(stateFactory) { let initialized = false let state2 const scope = effectScope(true) return () => { if (!initialized) { state2 = scope.run(stateFactory) initialized = true } return state2 } } function createInjectionState(composable) { const key2 = Symbol('InjectionState') const useProvidingState = (...args) => { const state2 = composable(...args) provide(key2, state2) return state2 } const useInjectedState = () => inject(key2) return [useProvidingState, useInjectedState] } function createSharedComposable(composable) { let subscribers = 0 let state2 let scope const dispose2 = () => { subscribers -= 1 if (scope && subscribers <= 0) { scope.stop() state2 = void 0 scope = void 0 } } return (...args) => { subscribers += 1 if (!state2) { scope = effectScope(true) state2 = scope.run(() => composable(...args)) } tryOnScopeDispose(dispose2) return state2 } } function extendRef( ref2, extend2, { enumerable: enumerable4 = false, unwrap = true } = {} ) { for (const [key2, value2] of Object.entries(extend2)) { if (key2 === 'value') continue if (isRef(value2) && unwrap) { Object.defineProperty(ref2, key2, { get() { return value2.value }, set(v4) { value2.value = v4 }, enumerable: enumerable4, }) } else { Object.defineProperty(ref2, key2, { value: value2, enumerable: enumerable4, }) } } return ref2 } function get$8(obj, key2) { if (key2 == null) return unref(obj) return unref(obj)[key2] } function isDefined(v4) { return unref(v4) != null } var __defProp$8$1 = Object.defineProperty var __getOwnPropSymbols$a$1 = Object.getOwnPropertySymbols var __hasOwnProp$a$1 = Object.prototype.hasOwnProperty var __propIsEnum$a$1 = Object.prototype.propertyIsEnumerable var __defNormalProp$8$1 = (obj, key2, value2) => key2 in obj ? __defProp$8$1(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$8$1 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$a$1.call(b2, prop)) __defNormalProp$8$1(a2, prop, b2[prop]) if (__getOwnPropSymbols$a$1) for (var prop of __getOwnPropSymbols$a$1(b2)) { if (__propIsEnum$a$1.call(b2, prop)) __defNormalProp$8$1(a2, prop, b2[prop]) } return a2 } function makeDestructurable(obj, arr) { if (typeof Symbol !== 'undefined') { const clone2 = __spreadValues$8$1({}, obj) Object.defineProperty(clone2, Symbol.iterator, { enumerable: false, value() { let index2 = 0 return { next: () => ({ value: arr[index2++], done: index2 > arr.length, }), } }, }) return clone2 } else { return Object.assign([...arr], obj) } } function reactify(fn2, options2) { const unrefFn = (options2 == null ? void 0 : options2.computedGetter) === false ? unref : resolveUnref return function (...args) { return computed(() => fn2.apply( this, args.map((i2) => unrefFn(i2)) ) ) } } function reactifyObject(obj, optionsOrKeys = {}) { let keys3 = [] let options2 if (Array.isArray(optionsOrKeys)) { keys3 = optionsOrKeys } else { options2 = optionsOrKeys const { includeOwnProperties = true } = optionsOrKeys keys3.push(...Object.keys(obj)) if (includeOwnProperties) keys3.push(...Object.getOwnPropertyNames(obj)) } return Object.fromEntries( keys3.map((key2) => { const value2 = obj[key2] return [ key2, typeof value2 === 'function' ? reactify(value2.bind(obj), options2) : value2, ] }) ) } function toReactive(objectRef) { if (!isRef(objectRef)) return reactive(objectRef) const proxy = new Proxy( {}, { get(_2, p2, receiver) { return unref(Reflect.get(objectRef.value, p2, receiver)) }, set(_2, p2, value2) { if (isRef(objectRef.value[p2]) && !isRef(value2)) objectRef.value[p2].value = value2 else objectRef.value[p2] = value2 return true }, deleteProperty(_2, p2) { return Reflect.deleteProperty(objectRef.value, p2) }, has(_2, p2) { return Reflect.has(objectRef.value, p2) }, ownKeys() { return Object.keys(objectRef.value) }, getOwnPropertyDescriptor() { return { enumerable: true, configurable: true, } }, } ) return reactive(proxy) } function reactiveComputed(fn2) { return toReactive(computed(fn2)) } function reactiveOmit(obj, ...keys3) { const flatKeys = keys3.flat() return reactiveComputed(() => Object.fromEntries( Object.entries(toRefs$2(obj)).filter((e2) => !flatKeys.includes(e2[0])) ) ) } function reactivePick(obj, ...keys3) { const flatKeys = keys3.flat() return reactive( Object.fromEntries(flatKeys.map((k2) => [k2, toRef(obj, k2)])) ) } function refAutoReset(defaultValue, afterMs = 1e4) { return customRef((track2, trigger2) => { let value2 = defaultValue let timer2 const resetAfter = () => setTimeout(() => { value2 = defaultValue trigger2() }, resolveUnref(afterMs)) tryOnScopeDispose(() => { clearTimeout(timer2) }) return { get() { track2() return value2 }, set(newValue) { value2 = newValue trigger2() clearTimeout(timer2) timer2 = resetAfter() }, } }) } function useDebounceFn(fn2, ms = 200, options2 = {}) { return createFilterWrapper(debounceFilter(ms, options2), fn2) } function refDebounced(value2, ms = 200, options2 = {}) { const debounced = ref(value2.value) const updater = useDebounceFn( () => { debounced.value = value2.value }, ms, options2 ) watch$1(value2, () => updater()) return debounced } function refDefault(source2, defaultValue) { return computed({ get() { var _a2 return (_a2 = source2.value) != null ? _a2 : defaultValue }, set(value2) { source2.value = value2 }, }) } function useThrottleFn( fn2, ms = 200, trailing = false, leading = true, rejectOnCancel = false ) { return createFilterWrapper( throttleFilter(ms, trailing, leading, rejectOnCancel), fn2 ) } function refThrottled(value2, delay2 = 200, trailing = true, leading = true) { if (delay2 <= 0) return value2 const throttled = ref(value2.value) const updater = useThrottleFn( () => { throttled.value = value2.value }, delay2, trailing, leading ) watch$1(value2, () => updater()) return throttled } function refWithControl(initial, options2 = {}) { let source2 = initial let track2 let trigger2 const ref2 = customRef((_track, _trigger) => { track2 = _track trigger2 = _trigger return { get() { return get3() }, set(v4) { set2(v4) }, } }) function get3(tracking = true) { if (tracking) track2() return source2 } function set2(value2, triggering = true) { var _a2, _b2 if (value2 === source2) return const old = source2 if ( ((_a2 = options2.onBeforeChange) == null ? void 0 : _a2.call(options2, value2, old)) === false ) return source2 = value2 ;(_b2 = options2.onChanged) == null ? void 0 : _b2.call(options2, value2, old) if (triggering) trigger2() } const untrackedGet = () => get3(false) const silentSet = (v4) => set2(v4, false) const peek = () => get3(false) const lay = (v4) => set2(v4, false) return extendRef( ref2, { get: get3, set: set2, untrackedGet, silentSet, peek, lay, }, { enumerable: true } ) } const controlledRef = refWithControl function resolveRef(r2) { return typeof r2 === 'function' ? computed(r2) : ref(r2) } function set$6(...args) { if (args.length === 2) { const [ref2, value2] = args ref2.value = value2 } if (args.length === 3) { { const [target2, key2, value2] = args target2[key2] = value2 } } } function syncRef(left2, right2, options2 = {}) { var _a2, _b2 const { flush: flush2 = 'sync', deep = false, immediate = true, direction: direction2 = 'both', transform: transform3 = {}, } = options2 let watchLeft let watchRight const transformLTR = (_a2 = transform3.ltr) != null ? _a2 : (v4) => v4 const transformRTL = (_b2 = transform3.rtl) != null ? _b2 : (v4) => v4 if (direction2 === 'both' || direction2 === 'ltr') { watchLeft = watch$1( left2, (newValue) => (right2.value = transformLTR(newValue)), { flush: flush2, deep, immediate } ) } if (direction2 === 'both' || direction2 === 'rtl') { watchRight = watch$1( right2, (newValue) => (left2.value = transformRTL(newValue)), { flush: flush2, deep, immediate } ) } return () => { watchLeft == null ? void 0 : watchLeft() watchRight == null ? void 0 : watchRight() } } function syncRefs(source2, targets, options2 = {}) { const { flush: flush2 = 'sync', deep = false, immediate = true } = options2 if (!Array.isArray(targets)) targets = [targets] return watch$1( source2, (newValue) => targets.forEach((target2) => (target2.value = newValue)), { flush: flush2, deep, immediate } ) } var __defProp$7$1 = Object.defineProperty var __defProps$5$1 = Object.defineProperties var __getOwnPropDescs$5$1 = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$9$1 = Object.getOwnPropertySymbols var __hasOwnProp$9$1 = Object.prototype.hasOwnProperty var __propIsEnum$9$1 = Object.prototype.propertyIsEnumerable var __defNormalProp$7$1 = (obj, key2, value2) => key2 in obj ? __defProp$7$1(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$7$1 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$9$1.call(b2, prop)) __defNormalProp$7$1(a2, prop, b2[prop]) if (__getOwnPropSymbols$9$1) for (var prop of __getOwnPropSymbols$9$1(b2)) { if (__propIsEnum$9$1.call(b2, prop)) __defNormalProp$7$1(a2, prop, b2[prop]) } return a2 } var __spreadProps$5$1 = (a2, b2) => __defProps$5$1(a2, __getOwnPropDescs$5$1(b2)) function toRefs(objectRef) { if (!isRef(objectRef)) return toRefs$2(objectRef) const result = Array.isArray(objectRef.value) ? new Array(objectRef.value.length) : {} for (const key2 in objectRef.value) { result[key2] = customRef(() => ({ get() { return objectRef.value[key2] }, set(v4) { if (Array.isArray(objectRef.value)) { const copy2 = [...objectRef.value] copy2[key2] = v4 objectRef.value = copy2 } else { const newObject = __spreadProps$5$1( __spreadValues$7$1({}, objectRef.value), { [key2]: v4 } ) Object.setPrototypeOf(newObject, objectRef.value) objectRef.value = newObject } }, })) } return result } function tryOnBeforeMount(fn2, sync = true) { if (getCurrentInstance()) onBeforeMount(fn2) else if (sync) fn2() else nextTick(fn2) } function tryOnBeforeUnmount(fn2) { if (getCurrentInstance()) onBeforeUnmount(fn2) } function tryOnMounted(fn2, sync = true) { if (getCurrentInstance()) onMounted(fn2) else if (sync) fn2() else nextTick(fn2) } function tryOnUnmounted(fn2) { if (getCurrentInstance()) onUnmounted(fn2) } function createUntil(r2, isNot = false) { function toMatch( condition2, { flush: flush2 = 'sync', deep = false, timeout, throwOnTimeout } = {} ) { let stop2 = null const watcher = new Promise((resolve2) => { stop2 = watch$1( r2, (v4) => { if (condition2(v4) !== isNot) { stop2 == null ? void 0 : stop2() resolve2(v4) } }, { flush: flush2, deep, immediate: true, } ) }) const promises = [watcher] if (timeout != null) { promises.push( promiseTimeout(timeout, throwOnTimeout) .then(() => resolveUnref(r2)) .finally(() => (stop2 == null ? void 0 : stop2())) ) } return Promise.race(promises) } function toBe(value2, options2) { if (!isRef(value2)) return toMatch((v4) => v4 === value2, options2) const { flush: flush2 = 'sync', deep = false, timeout, throwOnTimeout, } = options2 != null ? options2 : {} let stop2 = null const watcher = new Promise((resolve2) => { stop2 = watch$1( [r2, value2], ([v12, v22]) => { if (isNot !== (v12 === v22)) { stop2 == null ? void 0 : stop2() resolve2(v12) } }, { flush: flush2, deep, immediate: true, } ) }) const promises = [watcher] if (timeout != null) { promises.push( promiseTimeout(timeout, throwOnTimeout) .then(() => resolveUnref(r2)) .finally(() => { stop2 == null ? void 0 : stop2() return resolveUnref(r2) }) ) } return Promise.race(promises) } function toBeTruthy(options2) { return toMatch((v4) => Boolean(v4), options2) } function toBeNull(options2) { return toBe(null, options2) } function toBeUndefined(options2) { return toBe(void 0, options2) } function toBeNaN(options2) { return toMatch(Number.isNaN, options2) } function toContains(value2, options2) { return toMatch((v4) => { const array4 = Array.from(v4) return array4.includes(value2) || array4.includes(resolveUnref(value2)) }, options2) } function changed(options2) { return changedTimes(1, options2) } function changedTimes(n2 = 1, options2) { let count2 = -1 return toMatch(() => { count2 += 1 return count2 >= n2 }, options2) } if (Array.isArray(resolveUnref(r2))) { const instance = { toMatch, toContains, changed, changedTimes, get not() { return createUntil(r2, !isNot) }, } return instance } else { const instance = { toMatch, toBe, toBeTruthy, toBeNull, toBeNaN, toBeUndefined, changed, changedTimes, get not() { return createUntil(r2, !isNot) }, } return instance } } function until(r2) { return createUntil(r2) } function useArrayEvery(list2, fn2) { return computed(() => resolveUnref(list2).every((element, index2, array4) => fn2(resolveUnref(element), index2, array4) ) ) } function useArrayFilter(list2, fn2) { return computed(() => resolveUnref(list2) .map((i2) => resolveUnref(i2)) .filter(fn2) ) } function useArrayFind(list2, fn2) { return computed(() => resolveUnref( resolveUnref(list2).find((element, index2, array4) => fn2(resolveUnref(element), index2, array4) ) ) ) } function useArrayFindIndex(list2, fn2) { return computed(() => resolveUnref(list2).findIndex((element, index2, array4) => fn2(resolveUnref(element), index2, array4) ) ) } function findLast$2(arr, cb) { let index2 = arr.length while (index2-- > 0) { if (cb(arr[index2], index2, arr)) return arr[index2] } return void 0 } function useArrayFindLast(list2, fn2) { return computed(() => resolveUnref( !Array.prototype.findLast ? findLast$2(resolveUnref(list2), (element, index2, array4) => fn2(resolveUnref(element), index2, array4) ) : resolveUnref(list2).findLast((element, index2, array4) => fn2(resolveUnref(element), index2, array4) ) ) ) } function useArrayJoin(list2, separator) { return computed(() => resolveUnref(list2) .map((i2) => resolveUnref(i2)) .join(resolveUnref(separator)) ) } function useArrayMap(list2, fn2) { return computed(() => resolveUnref(list2) .map((i2) => resolveUnref(i2)) .map(fn2) ) } function useArrayReduce(list2, reducer, ...args) { const reduceCallback = (sum2, value2, index2) => reducer(resolveUnref(sum2), resolveUnref(value2), index2) return computed(() => { const resolved = resolveUnref(list2) return args.length ? resolved.reduce(reduceCallback, resolveUnref(args[0])) : resolved.reduce(reduceCallback) }) } function useArraySome(list2, fn2) { return computed(() => resolveUnref(list2).some((element, index2, array4) => fn2(resolveUnref(element), index2, array4) ) ) } function useArrayUnique(list2) { return computed(() => [ ...new Set(resolveUnref(list2).map((element) => resolveUnref(element))), ]) } function useCounter(initialValue = 0, options2 = {}) { const count2 = ref(initialValue) const { max: max3 = Infinity, min: min3 = -Infinity } = options2 const inc2 = (delta = 1) => (count2.value = Math.min(max3, count2.value + delta)) const dec = (delta = 1) => (count2.value = Math.max(min3, count2.value - delta)) const get3 = () => count2.value const set2 = (val2) => (count2.value = Math.max(min3, Math.min(max3, val2))) const reset2 = (val2 = initialValue) => { initialValue = val2 return set2(val2) } return { count: count2, inc: inc2, dec, get: get3, set: set2, reset: reset2 } } const REGEX_PARSE = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/ const REGEX_FORMAT = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a{1,2}|A{1,2}|m{1,2}|s{1,2}|Z{1,2}|SSS/g const defaultMeridiem = (hours, minutes, isLowercase, hasPeriod) => { let m2 = hours < 12 ? 'AM' : 'PM' if (hasPeriod) m2 = m2.split('').reduce((acc, curr) => (acc += `${curr}.`), '') return isLowercase ? m2.toLowerCase() : m2 } const formatDate$1 = (date4, formatStr, options2 = {}) => { var _a2 const years = date4.getFullYear() const month = date4.getMonth() const days = date4.getDate() const hours = date4.getHours() const minutes = date4.getMinutes() const seconds = date4.getSeconds() const milliseconds = date4.getMilliseconds() const day = date4.getDay() const meridiem = (_a2 = options2.customMeridiem) != null ? _a2 : defaultMeridiem const matches2 = { YY: () => String(years).slice(-2), YYYY: () => years, M: () => month + 1, MM: () => `${month + 1}`.padStart(2, '0'), MMM: () => date4.toLocaleDateString(options2.locales, { month: 'short' }), MMMM: () => date4.toLocaleDateString(options2.locales, { month: 'long' }), D: () => String(days), DD: () => `${days}`.padStart(2, '0'), H: () => String(hours), HH: () => `${hours}`.padStart(2, '0'), h: () => `${hours % 12 || 12}`.padStart(1, '0'), hh: () => `${hours % 12 || 12}`.padStart(2, '0'), m: () => String(minutes), mm: () => `${minutes}`.padStart(2, '0'), s: () => String(seconds), ss: () => `${seconds}`.padStart(2, '0'), SSS: () => `${milliseconds}`.padStart(3, '0'), d: () => day, dd: () => date4.toLocaleDateString(options2.locales, { weekday: 'narrow' }), ddd: () => date4.toLocaleDateString(options2.locales, { weekday: 'short' }), dddd: () => date4.toLocaleDateString(options2.locales, { weekday: 'long' }), A: () => meridiem(hours, minutes), AA: () => meridiem(hours, minutes, false, true), a: () => meridiem(hours, minutes, true), aa: () => meridiem(hours, minutes, true, true), } return formatStr.replace( REGEX_FORMAT, (match2, $1) => $1 || matches2[match2]() ) } const normalizeDate = (date4) => { if (date4 === null) return new Date(NaN) if (date4 === void 0) return new Date() if (date4 instanceof Date) return new Date(date4) if (typeof date4 === 'string' && !/Z$/i.test(date4)) { const d3 = date4.match(REGEX_PARSE) if (d3) { const m2 = d3[2] - 1 || 0 const ms = (d3[7] || '0').substring(0, 3) return new Date( d3[1], m2, d3[3] || 1, d3[4] || 0, d3[5] || 0, d3[6] || 0, ms ) } } return new Date(date4) } function useDateFormat(date4, formatStr = 'HH:mm:ss', options2 = {}) { return computed(() => formatDate$1( normalizeDate(resolveUnref(date4)), resolveUnref(formatStr), options2 ) ) } function useIntervalFn(cb, interval = 1e3, options2 = {}) { const { immediate = true, immediateCallback = false } = options2 let timer2 = null const isActive = ref(false) function clean() { if (timer2) { clearInterval(timer2) timer2 = null } } function pause() { isActive.value = false clean() } function resume() { const intervalValue = resolveUnref(interval) if (intervalValue <= 0) return isActive.value = true if (immediateCallback) cb() clean() timer2 = setInterval(cb, intervalValue) } if (immediate && isClient) resume() if (isRef(interval) || isFunction$k(interval)) { const stopWatch = watch$1(interval, () => { if (isActive.value && isClient) resume() }) tryOnScopeDispose(stopWatch) } tryOnScopeDispose(pause) return { isActive, pause, resume, } } var __defProp$6$1 = Object.defineProperty var __getOwnPropSymbols$8$1 = Object.getOwnPropertySymbols var __hasOwnProp$8$1 = Object.prototype.hasOwnProperty var __propIsEnum$8$1 = Object.prototype.propertyIsEnumerable var __defNormalProp$6$1 = (obj, key2, value2) => key2 in obj ? __defProp$6$1(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$6$1 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$8$1.call(b2, prop)) __defNormalProp$6$1(a2, prop, b2[prop]) if (__getOwnPropSymbols$8$1) for (var prop of __getOwnPropSymbols$8$1(b2)) { if (__propIsEnum$8$1.call(b2, prop)) __defNormalProp$6$1(a2, prop, b2[prop]) } return a2 } function useInterval(interval = 1e3, options2 = {}) { const { controls: exposeControls = false, immediate = true, callback, } = options2 const counter2 = ref(0) const update3 = () => (counter2.value += 1) const reset2 = () => { counter2.value = 0 } const controls = useIntervalFn( callback ? () => { update3() callback(counter2.value) } : update3, interval, { immediate } ) if (exposeControls) { return __spreadValues$6$1( { counter: counter2, reset: reset2, }, controls ) } else { return counter2 } } function useLastChanged(source2, options2 = {}) { var _a2 const ms = ref((_a2 = options2.initialValue) != null ? _a2 : null) watch$1(source2, () => (ms.value = timestamp$2()), options2) return ms } function useTimeoutFn(cb, interval, options2 = {}) { const { immediate = true } = options2 const isPending = ref(false) let timer2 = null function clear2() { if (timer2) { clearTimeout(timer2) timer2 = null } } function stop2() { isPending.value = false clear2() } function start2(...args) { clear2() isPending.value = true timer2 = setTimeout(() => { isPending.value = false timer2 = null cb(...args) }, resolveUnref(interval)) } if (immediate) { isPending.value = true if (isClient) start2() } tryOnScopeDispose(stop2) return { isPending: readonly(isPending), start: start2, stop: stop2, } } var __defProp$5$1 = Object.defineProperty var __getOwnPropSymbols$7$1 = Object.getOwnPropertySymbols var __hasOwnProp$7$1 = Object.prototype.hasOwnProperty var __propIsEnum$7$1 = Object.prototype.propertyIsEnumerable var __defNormalProp$5$1 = (obj, key2, value2) => key2 in obj ? __defProp$5$1(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$5$1 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$7$1.call(b2, prop)) __defNormalProp$5$1(a2, prop, b2[prop]) if (__getOwnPropSymbols$7$1) for (var prop of __getOwnPropSymbols$7$1(b2)) { if (__propIsEnum$7$1.call(b2, prop)) __defNormalProp$5$1(a2, prop, b2[prop]) } return a2 } function useTimeout(interval = 1e3, options2 = {}) { const { controls: exposeControls = false, callback } = options2 const controls = useTimeoutFn( callback != null ? callback : noop$6, interval, options2 ) const ready = computed(() => !controls.isPending.value) if (exposeControls) { return __spreadValues$5$1( { ready, }, controls ) } else { return ready } } function useToNumber(value2, options2 = {}) { const { method: method4 = 'parseFloat', radix, nanToZero } = options2 return computed(() => { let resolved = resolveUnref(value2) if (typeof resolved === 'string') resolved = Number[method4](resolved, radix) if (nanToZero && isNaN(resolved)) resolved = 0 return resolved }) } function useToString(value2) { return computed(() => `${resolveUnref(value2)}`) } function useToggle(initialValue = false, options2 = {}) { const { truthyValue = true, falsyValue = false } = options2 const valueIsRef = isRef(initialValue) const _value = ref(initialValue) function toggle2(value2) { if (arguments.length) { _value.value = value2 return _value.value } else { const truthy = resolveUnref(truthyValue) _value.value = _value.value === truthy ? resolveUnref(falsyValue) : truthy return _value.value } } if (valueIsRef) return toggle2 else return [_value, toggle2] } function watchArray(source2, cb, options2) { let oldList = (options2 == null ? void 0 : options2.immediate) ? [] : [ ...(source2 instanceof Function ? source2() : Array.isArray(source2) ? source2 : unref(source2)), ] return watch$1( source2, (newList, _2, onCleanup) => { const oldListRemains = new Array(oldList.length) const added = [] for (const obj of newList) { let found = false for (let i2 = 0; i2 < oldList.length; i2++) { if (!oldListRemains[i2] && obj === oldList[i2]) { oldListRemains[i2] = true found = true break } } if (!found) added.push(obj) } const removed = oldList.filter((_22, i2) => !oldListRemains[i2]) cb(newList, oldList, added, removed, onCleanup) oldList = [...newList] }, options2 ) } var __getOwnPropSymbols$6$1 = Object.getOwnPropertySymbols var __hasOwnProp$6$1 = Object.prototype.hasOwnProperty var __propIsEnum$6$1 = Object.prototype.propertyIsEnumerable var __objRest$5 = (source2, exclude) => { var target2 = {} for (var prop in source2) if (__hasOwnProp$6$1.call(source2, prop) && exclude.indexOf(prop) < 0) target2[prop] = source2[prop] if (source2 != null && __getOwnPropSymbols$6$1) for (var prop of __getOwnPropSymbols$6$1(source2)) { if (exclude.indexOf(prop) < 0 && __propIsEnum$6$1.call(source2, prop)) target2[prop] = source2[prop] } return target2 } function watchWithFilter(source2, cb, options2 = {}) { const _a2 = options2, { eventFilter = bypassFilter } = _a2, watchOptions = __objRest$5(_a2, ['eventFilter']) return watch$1(source2, createFilterWrapper(eventFilter, cb), watchOptions) } var __getOwnPropSymbols$5$1 = Object.getOwnPropertySymbols var __hasOwnProp$5$1 = Object.prototype.hasOwnProperty var __propIsEnum$5$1 = Object.prototype.propertyIsEnumerable var __objRest$4 = (source2, exclude) => { var target2 = {} for (var prop in source2) if (__hasOwnProp$5$1.call(source2, prop) && exclude.indexOf(prop) < 0) target2[prop] = source2[prop] if (source2 != null && __getOwnPropSymbols$5$1) for (var prop of __getOwnPropSymbols$5$1(source2)) { if (exclude.indexOf(prop) < 0 && __propIsEnum$5$1.call(source2, prop)) target2[prop] = source2[prop] } return target2 } function watchAtMost(source2, cb, options2) { const _a2 = options2, { count: count2 } = _a2, watchOptions = __objRest$4(_a2, ['count']) const current2 = ref(0) const stop2 = watchWithFilter( source2, (...args) => { current2.value += 1 if (current2.value >= resolveUnref(count2)) nextTick(() => stop2()) cb(...args) }, watchOptions ) return { count: current2, stop: stop2 } } var __defProp$4$1 = Object.defineProperty var __defProps$4$1 = Object.defineProperties var __getOwnPropDescs$4$1 = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$4$1 = Object.getOwnPropertySymbols var __hasOwnProp$4$1 = Object.prototype.hasOwnProperty var __propIsEnum$4$1 = Object.prototype.propertyIsEnumerable var __defNormalProp$4$1 = (obj, key2, value2) => key2 in obj ? __defProp$4$1(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$4$1 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$4$1.call(b2, prop)) __defNormalProp$4$1(a2, prop, b2[prop]) if (__getOwnPropSymbols$4$1) for (var prop of __getOwnPropSymbols$4$1(b2)) { if (__propIsEnum$4$1.call(b2, prop)) __defNormalProp$4$1(a2, prop, b2[prop]) } return a2 } var __spreadProps$4$1 = (a2, b2) => __defProps$4$1(a2, __getOwnPropDescs$4$1(b2)) var __objRest$3 = (source2, exclude) => { var target2 = {} for (var prop in source2) if (__hasOwnProp$4$1.call(source2, prop) && exclude.indexOf(prop) < 0) target2[prop] = source2[prop] if (source2 != null && __getOwnPropSymbols$4$1) for (var prop of __getOwnPropSymbols$4$1(source2)) { if (exclude.indexOf(prop) < 0 && __propIsEnum$4$1.call(source2, prop)) target2[prop] = source2[prop] } return target2 } function watchDebounced(source2, cb, options2 = {}) { const _a2 = options2, { debounce: debounce2 = 0, maxWait = void 0 } = _a2, watchOptions = __objRest$3(_a2, ['debounce', 'maxWait']) return watchWithFilter( source2, cb, __spreadProps$4$1(__spreadValues$4$1({}, watchOptions), { eventFilter: debounceFilter(debounce2, { maxWait }), }) ) } var __defProp$3$1 = Object.defineProperty var __defProps$3$1 = Object.defineProperties var __getOwnPropDescs$3$1 = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$3$1 = Object.getOwnPropertySymbols var __hasOwnProp$3$1 = Object.prototype.hasOwnProperty var __propIsEnum$3$1 = Object.prototype.propertyIsEnumerable var __defNormalProp$3$1 = (obj, key2, value2) => key2 in obj ? __defProp$3$1(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$3$1 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$3$1.call(b2, prop)) __defNormalProp$3$1(a2, prop, b2[prop]) if (__getOwnPropSymbols$3$1) for (var prop of __getOwnPropSymbols$3$1(b2)) { if (__propIsEnum$3$1.call(b2, prop)) __defNormalProp$3$1(a2, prop, b2[prop]) } return a2 } var __spreadProps$3$1 = (a2, b2) => __defProps$3$1(a2, __getOwnPropDescs$3$1(b2)) var __objRest$2$1 = (source2, exclude) => { var target2 = {} for (var prop in source2) if (__hasOwnProp$3$1.call(source2, prop) && exclude.indexOf(prop) < 0) target2[prop] = source2[prop] if (source2 != null && __getOwnPropSymbols$3$1) for (var prop of __getOwnPropSymbols$3$1(source2)) { if (exclude.indexOf(prop) < 0 && __propIsEnum$3$1.call(source2, prop)) target2[prop] = source2[prop] } return target2 } function watchIgnorable(source2, cb, options2 = {}) { const _a2 = options2, { eventFilter = bypassFilter } = _a2, watchOptions = __objRest$2$1(_a2, ['eventFilter']) const filteredCb = createFilterWrapper(eventFilter, cb) let ignoreUpdates let ignorePrevAsyncUpdates let stop2 if (watchOptions.flush === 'sync') { const ignore = ref(false) ignorePrevAsyncUpdates = () => {} ignoreUpdates = (updater) => { ignore.value = true updater() ignore.value = false } stop2 = watch$1( source2, (...args) => { if (!ignore.value) filteredCb(...args) }, watchOptions ) } else { const disposables = [] const ignoreCounter = ref(0) const syncCounter = ref(0) ignorePrevAsyncUpdates = () => { ignoreCounter.value = syncCounter.value } disposables.push( watch$1( source2, () => { syncCounter.value++ }, __spreadProps$3$1(__spreadValues$3$1({}, watchOptions), { flush: 'sync', }) ) ) ignoreUpdates = (updater) => { const syncCounterPrev = syncCounter.value updater() ignoreCounter.value += syncCounter.value - syncCounterPrev } disposables.push( watch$1( source2, (...args) => { const ignore = ignoreCounter.value > 0 && ignoreCounter.value === syncCounter.value ignoreCounter.value = 0 syncCounter.value = 0 if (ignore) return filteredCb(...args) }, watchOptions ) ) stop2 = () => { disposables.forEach((fn2) => fn2()) } } return { stop: stop2, ignoreUpdates, ignorePrevAsyncUpdates } } function watchOnce(source2, cb, options2) { const stop2 = watch$1( source2, (...args) => { nextTick(() => stop2()) return cb(...args) }, options2 ) } var __defProp$2$1 = Object.defineProperty var __defProps$2$1 = Object.defineProperties var __getOwnPropDescs$2$1 = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$2$1 = Object.getOwnPropertySymbols var __hasOwnProp$2$1 = Object.prototype.hasOwnProperty var __propIsEnum$2$1 = Object.prototype.propertyIsEnumerable var __defNormalProp$2$1 = (obj, key2, value2) => key2 in obj ? __defProp$2$1(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$2$1 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$2$1.call(b2, prop)) __defNormalProp$2$1(a2, prop, b2[prop]) if (__getOwnPropSymbols$2$1) for (var prop of __getOwnPropSymbols$2$1(b2)) { if (__propIsEnum$2$1.call(b2, prop)) __defNormalProp$2$1(a2, prop, b2[prop]) } return a2 } var __spreadProps$2$1 = (a2, b2) => __defProps$2$1(a2, __getOwnPropDescs$2$1(b2)) var __objRest$1$1 = (source2, exclude) => { var target2 = {} for (var prop in source2) if (__hasOwnProp$2$1.call(source2, prop) && exclude.indexOf(prop) < 0) target2[prop] = source2[prop] if (source2 != null && __getOwnPropSymbols$2$1) for (var prop of __getOwnPropSymbols$2$1(source2)) { if (exclude.indexOf(prop) < 0 && __propIsEnum$2$1.call(source2, prop)) target2[prop] = source2[prop] } return target2 } function watchPausable(source2, cb, options2 = {}) { const _a2 = options2, { eventFilter: filter2 } = _a2, watchOptions = __objRest$1$1(_a2, ['eventFilter']) const { eventFilter, pause, resume, isActive } = pausableFilter(filter2) const stop2 = watchWithFilter( source2, cb, __spreadProps$2$1(__spreadValues$2$1({}, watchOptions), { eventFilter, }) ) return { stop: stop2, pause, resume, isActive } } var __defProp$1$1 = Object.defineProperty var __defProps$1$1 = Object.defineProperties var __getOwnPropDescs$1$1 = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$1$1 = Object.getOwnPropertySymbols var __hasOwnProp$1$1 = Object.prototype.hasOwnProperty var __propIsEnum$1$1 = Object.prototype.propertyIsEnumerable var __defNormalProp$1$1 = (obj, key2, value2) => key2 in obj ? __defProp$1$1(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$1$1 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$1$1.call(b2, prop)) __defNormalProp$1$1(a2, prop, b2[prop]) if (__getOwnPropSymbols$1$1) for (var prop of __getOwnPropSymbols$1$1(b2)) { if (__propIsEnum$1$1.call(b2, prop)) __defNormalProp$1$1(a2, prop, b2[prop]) } return a2 } var __spreadProps$1$1 = (a2, b2) => __defProps$1$1(a2, __getOwnPropDescs$1$1(b2)) var __objRest$6 = (source2, exclude) => { var target2 = {} for (var prop in source2) if (__hasOwnProp$1$1.call(source2, prop) && exclude.indexOf(prop) < 0) target2[prop] = source2[prop] if (source2 != null && __getOwnPropSymbols$1$1) for (var prop of __getOwnPropSymbols$1$1(source2)) { if (exclude.indexOf(prop) < 0 && __propIsEnum$1$1.call(source2, prop)) target2[prop] = source2[prop] } return target2 } function watchThrottled(source2, cb, options2 = {}) { const _a2 = options2, { throttle: throttle2 = 0, trailing = true, leading = true } = _a2, watchOptions = __objRest$6(_a2, ['throttle', 'trailing', 'leading']) return watchWithFilter( source2, cb, __spreadProps$1$1(__spreadValues$1$1({}, watchOptions), { eventFilter: throttleFilter(throttle2, trailing, leading), }) ) } var __defProp$o = Object.defineProperty var __defProps$a = Object.defineProperties var __getOwnPropDescs$a = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$q = Object.getOwnPropertySymbols var __hasOwnProp$q = Object.prototype.hasOwnProperty var __propIsEnum$q = Object.prototype.propertyIsEnumerable var __defNormalProp$o = (obj, key2, value2) => key2 in obj ? __defProp$o(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$o = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$q.call(b2, prop)) __defNormalProp$o(a2, prop, b2[prop]) if (__getOwnPropSymbols$q) for (var prop of __getOwnPropSymbols$q(b2)) { if (__propIsEnum$q.call(b2, prop)) __defNormalProp$o(a2, prop, b2[prop]) } return a2 } var __spreadProps$a = (a2, b2) => __defProps$a(a2, __getOwnPropDescs$a(b2)) function watchTriggerable(source2, cb, options2 = {}) { let cleanupFn function onEffect() { if (!cleanupFn) return const fn2 = cleanupFn cleanupFn = void 0 fn2() } function onCleanup(callback) { cleanupFn = callback } const _cb = (value2, oldValue) => { onEffect() return cb(value2, oldValue, onCleanup) } const res = watchIgnorable(source2, _cb, options2) const { ignoreUpdates } = res const trigger2 = () => { let res2 ignoreUpdates(() => { res2 = _cb(getWatchSources(source2), getOldValue(source2)) }) return res2 } return __spreadProps$a(__spreadValues$o({}, res), { trigger: trigger2, }) } function getWatchSources(sources) { if (isReactive(sources)) return sources if (Array.isArray(sources)) return sources.map((item2) => getOneWatchSource(item2)) return getOneWatchSource(sources) } function getOneWatchSource(source2) { return typeof source2 === 'function' ? source2() : unref(source2) } function getOldValue(source2) { return Array.isArray(source2) ? source2.map(() => void 0) : void 0 } function whenever(source2, cb, options2) { return watch$1( source2, (v4, ov, onInvalidate) => { if (v4) cb(v4, ov, onInvalidate) }, options2 ) } function computedAsync(evaluationCallback, initialState, optionsOrRef) { let options2 if (isRef(optionsOrRef)) { options2 = { evaluating: optionsOrRef, } } else { options2 = optionsOrRef || {} } const { lazy = false, evaluating = void 0, shallow = false, onError = noop$6, } = options2 const started = ref(!lazy) const current2 = shallow ? shallowRef(initialState) : ref(initialState) let counter2 = 0 watchEffect(async (onInvalidate) => { if (!started.value) return counter2++ const counterAtBeginning = counter2 let hasFinished = false if (evaluating) { Promise.resolve().then(() => { evaluating.value = true }) } try { const result = await evaluationCallback((cancelCallback) => { onInvalidate(() => { if (evaluating) evaluating.value = false if (!hasFinished) cancelCallback() }) }) if (counterAtBeginning === counter2) current2.value = result } catch (e2) { onError(e2) } finally { if (evaluating && counterAtBeginning === counter2) evaluating.value = false hasFinished = true } }) if (lazy) { return computed(() => { started.value = true return current2.value }) } else { return current2 } } function computedInject(key2, options2, defaultSource, treatDefaultAsFactory) { let source2 = inject(key2) if (defaultSource) source2 = inject(key2, defaultSource) if (treatDefaultAsFactory) source2 = inject(key2, defaultSource, treatDefaultAsFactory) if (typeof options2 === 'function') { return computed((ctx) => options2(source2, ctx)) } else { return computed({ get: (ctx) => options2.get(source2, ctx), set: options2.set, }) } } const createUnrefFn = (fn2) => { return function (...args) { return fn2.apply( this, args.map((i2) => unref(i2)) ) } } function unrefElement(elRef) { var _a2 const plain = resolveUnref(elRef) return (_a2 = plain == null ? void 0 : plain.$el) != null ? _a2 : plain } const defaultWindow$1 = isClient ? window : void 0 const defaultDocument = isClient ? window.document : void 0 const defaultNavigator = isClient ? window.navigator : void 0 const defaultLocation = isClient ? window.location : void 0 function useEventListener(...args) { let target2 let events2 let listeners let options2 if (isString$e(args[0]) || Array.isArray(args[0])) { ;[events2, listeners, options2] = args target2 = defaultWindow$1 } else { ;[target2, events2, listeners, options2] = args } if (!target2) return noop$6 if (!Array.isArray(events2)) events2 = [events2] if (!Array.isArray(listeners)) listeners = [listeners] const cleanups = [] const cleanup = () => { cleanups.forEach((fn2) => fn2()) cleanups.length = 0 } const register4 = (el2, event, listener, options22) => { el2.addEventListener(event, listener, options22) return () => el2.removeEventListener(event, listener, options22) } const stopWatch = watch$1( () => [unrefElement(target2), resolveUnref(options2)], ([el2, options22]) => { cleanup() if (!el2) return cleanups.push( ...events2.flatMap((event) => { return listeners.map((listener) => register4(el2, event, listener, options22) ) }) ) }, { immediate: true, flush: 'post' } ) const stop2 = () => { stopWatch() cleanup() } tryOnScopeDispose(stop2) return stop2 } let _iOSWorkaround = false function onClickOutside(target2, handler, options2 = {}) { const { window: window2 = defaultWindow$1, ignore = [], capture = true, detectIframe = false, } = options2 if (!window2) return if (isIOS && !_iOSWorkaround) { _iOSWorkaround = true Array.from(window2.document.body.children).forEach((el2) => el2.addEventListener('click', noop$6) ) } let shouldListen = true const shouldIgnore = (event) => { return ignore.some((target22) => { if (typeof target22 === 'string') { return Array.from(window2.document.querySelectorAll(target22)).some( (el2) => el2 === event.target || event.composedPath().includes(el2) ) } else { const el2 = unrefElement(target22) return ( el2 && (event.target === el2 || event.composedPath().includes(el2)) ) } }) } const listener = (event) => { const el2 = unrefElement(target2) if (!el2 || el2 === event.target || event.composedPath().includes(el2)) return if (event.detail === 0) shouldListen = !shouldIgnore(event) if (!shouldListen) { shouldListen = true return } handler(event) } const cleanup = [ useEventListener(window2, 'click', listener, { passive: true, capture }), useEventListener( window2, 'pointerdown', (e2) => { const el2 = unrefElement(target2) if (el2) shouldListen = !e2.composedPath().includes(el2) && !shouldIgnore(e2) }, { passive: true } ), detectIframe && useEventListener(window2, 'blur', (event) => { var _a2 const el2 = unrefElement(target2) if ( ((_a2 = window2.document.activeElement) == null ? void 0 : _a2.tagName) === 'IFRAME' && !(el2 == null ? void 0 : el2.contains(window2.document.activeElement)) ) handler(event) }), ].filter(Boolean) const stop2 = () => cleanup.forEach((fn2) => fn2()) return stop2 } var __defProp$n = Object.defineProperty var __defProps$9 = Object.defineProperties var __getOwnPropDescs$9 = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$p = Object.getOwnPropertySymbols var __hasOwnProp$p = Object.prototype.hasOwnProperty var __propIsEnum$p = Object.prototype.propertyIsEnumerable var __defNormalProp$n = (obj, key2, value2) => key2 in obj ? __defProp$n(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$n = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$p.call(b2, prop)) __defNormalProp$n(a2, prop, b2[prop]) if (__getOwnPropSymbols$p) for (var prop of __getOwnPropSymbols$p(b2)) { if (__propIsEnum$p.call(b2, prop)) __defNormalProp$n(a2, prop, b2[prop]) } return a2 } var __spreadProps$9 = (a2, b2) => __defProps$9(a2, __getOwnPropDescs$9(b2)) const createKeyPredicate = (keyFilter) => { if (typeof keyFilter === 'function') return keyFilter else if (typeof keyFilter === 'string') return (event) => event.key === keyFilter else if (Array.isArray(keyFilter)) return (event) => keyFilter.includes(event.key) return () => true } function onKeyStroke(...args) { let key2 let handler let options2 = {} if (args.length === 3) { key2 = args[0] handler = args[1] options2 = args[2] } else if (args.length === 2) { if (typeof args[1] === 'object') { key2 = true handler = args[0] options2 = args[1] } else { key2 = args[0] handler = args[1] } } else { key2 = true handler = args[0] } const { target: target2 = defaultWindow$1, eventName = 'keydown', passive: passive2 = false, } = options2 const predicate = createKeyPredicate(key2) const listener = (e2) => { if (predicate(e2)) handler(e2) } return useEventListener(target2, eventName, listener, passive2) } function onKeyDown(key2, handler, options2 = {}) { return onKeyStroke( key2, handler, __spreadProps$9(__spreadValues$n({}, options2), { eventName: 'keydown' }) ) } function onKeyPressed(key2, handler, options2 = {}) { return onKeyStroke( key2, handler, __spreadProps$9(__spreadValues$n({}, options2), { eventName: 'keypress' }) ) } function onKeyUp(key2, handler, options2 = {}) { return onKeyStroke( key2, handler, __spreadProps$9(__spreadValues$n({}, options2), { eventName: 'keyup' }) ) } const DEFAULT_DELAY = 500 function onLongPress(target2, handler, options2) { var _a2, _b2 const elementRef = computed(() => unrefElement(target2)) let timeout function clear2() { if (timeout) { clearTimeout(timeout) timeout = void 0 } } function onDown(ev) { var _a22, _b22, _c2, _d if ( ((_a22 = options2 == null ? void 0 : options2.modifiers) == null ? void 0 : _a22.self) && ev.target !== elementRef.value ) return clear2() if ( (_b22 = options2 == null ? void 0 : options2.modifiers) == null ? void 0 : _b22.prevent ) ev.preventDefault() if ( (_c2 = options2 == null ? void 0 : options2.modifiers) == null ? void 0 : _c2.stop ) ev.stopPropagation() timeout = setTimeout( () => handler(ev), (_d = options2 == null ? void 0 : options2.delay) != null ? _d : DEFAULT_DELAY ) } const listenerOptions = { capture: (_a2 = options2 == null ? void 0 : options2.modifiers) == null ? void 0 : _a2.capture, once: (_b2 = options2 == null ? void 0 : options2.modifiers) == null ? void 0 : _b2.once, } useEventListener(elementRef, 'pointerdown', onDown, listenerOptions) useEventListener(elementRef, 'pointerup', clear2, listenerOptions) useEventListener(elementRef, 'pointerleave', clear2, listenerOptions) } const isFocusedElementEditable = () => { const { activeElement, body } = document if (!activeElement) return false if (activeElement === body) return false switch (activeElement.tagName) { case 'INPUT': case 'TEXTAREA': return true } return activeElement.hasAttribute('contenteditable') } const isTypedCharValid = ({ keyCode, metaKey, ctrlKey, altKey }) => { if (metaKey || ctrlKey || altKey) return false if ((keyCode >= 48 && keyCode <= 57) || (keyCode >= 96 && keyCode <= 105)) return true if (keyCode >= 65 && keyCode <= 90) return true return false } function onStartTyping(callback, options2 = {}) { const { document: document2 = defaultDocument } = options2 const keydown = (event) => { !isFocusedElementEditable() && isTypedCharValid(event) && callback(event) } if (document2) useEventListener(document2, 'keydown', keydown, { passive: true }) } function templateRef(key2, initialValue = null) { const instance = getCurrentInstance() let _trigger = () => {} const element = customRef((track2, trigger2) => { _trigger = trigger2 return { get() { var _a2, _b2 track2() return (_b2 = (_a2 = instance == null ? void 0 : instance.proxy) == null ? void 0 : _a2.$refs[key2]) != null ? _b2 : initialValue }, set() {}, } }) tryOnMounted(_trigger) onUpdated(_trigger) return element } function useActiveElement(options2 = {}) { var _a2 const { window: window2 = defaultWindow$1 } = options2 const document2 = (_a2 = options2.document) != null ? _a2 : window2 == null ? void 0 : window2.document const activeElement = computedWithControl( () => null, () => (document2 == null ? void 0 : document2.activeElement) ) if (window2) { useEventListener( window2, 'blur', (event) => { if (event.relatedTarget !== null) return activeElement.trigger() }, true ) useEventListener(window2, 'focus', activeElement.trigger, true) } return activeElement } function useAsyncQueue(tasks, options2 = {}) { const { interrupt = true, onError = noop$6, onFinished = noop$6 } = options2 const promiseState = { pending: 'pending', rejected: 'rejected', fulfilled: 'fulfilled', } const initialResult = Array.from(new Array(tasks.length), () => ({ state: promiseState.pending, data: null, })) const result = reactive(initialResult) const activeIndex = ref(-1) if (!tasks || tasks.length === 0) { onFinished() return { activeIndex, result, } } function updateResult(state2, res) { activeIndex.value++ result[activeIndex.value].data = res result[activeIndex.value].state = state2 } tasks.reduce((prev, curr) => { return prev .then((prevRes) => { var _a2 if ( ((_a2 = result[activeIndex.value]) == null ? void 0 : _a2.state) === promiseState.rejected && interrupt ) { onFinished() return } return curr(prevRes).then((currentRes) => { updateResult(promiseState.fulfilled, currentRes) activeIndex.value === tasks.length - 1 && onFinished() return currentRes }) }) .catch((e2) => { updateResult(promiseState.rejected, e2) onError() return e2 }) }, Promise.resolve()) return { activeIndex, result, } } function useAsyncState(promise2, initialState, options2) { const { immediate = true, delay: delay2 = 0, onError = noop$6, onSuccess = noop$6, resetOnExecute = true, shallow = true, throwError: throwError2, } = options2 != null ? options2 : {} const state2 = shallow ? shallowRef(initialState) : ref(initialState) const isReady = ref(false) const isLoading = ref(false) const error2 = ref(void 0) async function execute(delay22 = 0, ...args) { if (resetOnExecute) state2.value = initialState error2.value = void 0 isReady.value = false isLoading.value = true if (delay22 > 0) await promiseTimeout(delay22) const _promise = typeof promise2 === 'function' ? promise2(...args) : promise2 try { const data2 = await _promise state2.value = data2 isReady.value = true onSuccess(data2) } catch (e2) { error2.value = e2 onError(e2) if (throwError2) throw error2 } finally { isLoading.value = false } return state2.value } if (immediate) execute(delay2) return { state: state2, isReady, isLoading, error: error2, execute, } } const defaults$7 = { array: (v4) => JSON.stringify(v4), object: (v4) => JSON.stringify(v4), set: (v4) => JSON.stringify(Array.from(v4)), map: (v4) => JSON.stringify(Object.fromEntries(v4)), null: () => '', } function getDefaultSerialization(target2) { if (!target2) return defaults$7.null if (target2 instanceof Map) return defaults$7.map else if (target2 instanceof Set) return defaults$7.set else if (Array.isArray(target2)) return defaults$7.array else return defaults$7.object } function useBase64(target2, options2) { const base642 = ref('') const promise2 = ref() function execute() { if (!isClient) return promise2.value = new Promise((resolve2, reject2) => { try { const _target = resolveUnref(target2) if (_target == null) { resolve2('') } else if (typeof _target === 'string') { resolve2(blobToBase64(new Blob([_target], { type: 'text/plain' }))) } else if (_target instanceof Blob) { resolve2(blobToBase64(_target)) } else if (_target instanceof ArrayBuffer) { resolve2(window.btoa(String.fromCharCode(...new Uint8Array(_target)))) } else if (_target instanceof HTMLCanvasElement) { resolve2( _target.toDataURL( options2 == null ? void 0 : options2.type, options2 == null ? void 0 : options2.quality ) ) } else if (_target instanceof HTMLImageElement) { const img = _target.cloneNode(false) img.crossOrigin = 'Anonymous' imgLoaded(img) .then(() => { const canvas = document.createElement('canvas') const ctx = canvas.getContext('2d') canvas.width = img.width canvas.height = img.height ctx.drawImage(img, 0, 0, canvas.width, canvas.height) resolve2( canvas.toDataURL( options2 == null ? void 0 : options2.type, options2 == null ? void 0 : options2.quality ) ) }) .catch(reject2) } else if (typeof _target === 'object') { const _serializeFn = (options2 == null ? void 0 : options2.serializer) || getDefaultSerialization(_target) const serialized = _serializeFn(_target) return resolve2( blobToBase64(new Blob([serialized], { type: 'application/json' })) ) } else { reject2(new Error('target is unsupported types')) } } catch (error2) { reject2(error2) } }) promise2.value.then((res) => (base642.value = res)) return promise2.value } if (isRef(target2) || isFunction$k(target2)) watch$1(target2, execute, { immediate: true }) else execute() return { base64: base642, promise: promise2, execute, } } function imgLoaded(img) { return new Promise((resolve2, reject2) => { if (!img.complete) { img.onload = () => { resolve2() } img.onerror = reject2 } else { resolve2() } }) } function blobToBase64(blob) { return new Promise((resolve2, reject2) => { const fr2 = new FileReader() fr2.onload = (e2) => { resolve2(e2.target.result) } fr2.onerror = reject2 fr2.readAsDataURL(blob) }) } function useSupported(callback, sync = false) { const isSupported = ref() const update3 = () => (isSupported.value = Boolean(callback())) update3() tryOnMounted(update3, sync) return isSupported } function useBattery({ navigator: navigator2 = defaultNavigator } = {}) { const events2 = [ 'chargingchange', 'chargingtimechange', 'dischargingtimechange', 'levelchange', ] const isSupported = useSupported( () => navigator2 && 'getBattery' in navigator2 ) const charging = ref(false) const chargingTime = ref(0) const dischargingTime = ref(0) const level = ref(1) let battery function updateBatteryInfo() { charging.value = this.charging chargingTime.value = this.chargingTime || 0 dischargingTime.value = this.dischargingTime || 0 level.value = this.level } if (isSupported.value) { navigator2.getBattery().then((_battery) => { battery = _battery updateBatteryInfo.call(battery) for (const event of events2) useEventListener(battery, event, updateBatteryInfo, { passive: true }) }) } return { isSupported, charging, chargingTime, dischargingTime, level, } } function useBluetooth(options2) { let { acceptAllDevices = false } = options2 || {} const { filters = void 0, optionalServices = void 0, navigator: navigator2 = defaultNavigator, } = options2 || {} const isSupported = useSupported( () => navigator2 && 'bluetooth' in navigator2 ) const device = shallowRef(void 0) const error2 = shallowRef(null) watch$1(device, () => { connectToBluetoothGATTServer() }) async function requestDevice() { if (!isSupported.value) return error2.value = null if (filters && filters.length > 0) acceptAllDevices = false try { device.value = await (navigator2 == null ? void 0 : navigator2.bluetooth.requestDevice({ acceptAllDevices, filters, optionalServices, })) } catch (err) { error2.value = err } } const server = ref() const isConnected = computed(() => { var _a2 return ((_a2 = server.value) == null ? void 0 : _a2.connected) || false }) async function connectToBluetoothGATTServer() { error2.value = null if (device.value && device.value.gatt) { device.value.addEventListener('gattserverdisconnected', () => {}) try { server.value = await device.value.gatt.connect() } catch (err) { error2.value = err } } } tryOnMounted(() => { var _a2 if (device.value) (_a2 = device.value.gatt) == null ? void 0 : _a2.connect() }) tryOnScopeDispose(() => { var _a2 if (device.value) (_a2 = device.value.gatt) == null ? void 0 : _a2.disconnect() }) return { isSupported, isConnected, device, requestDevice, server, error: error2, } } function useMediaQuery(query, options2 = {}) { const { window: window2 = defaultWindow$1 } = options2 const isSupported = useSupported( () => window2 && 'matchMedia' in window2 && typeof window2.matchMedia === 'function' ) let mediaQuery const matches2 = ref(false) const cleanup = () => { if (!mediaQuery) return if ('removeEventListener' in mediaQuery) mediaQuery.removeEventListener('change', update3) else mediaQuery.removeListener(update3) } const update3 = () => { if (!isSupported.value) return cleanup() mediaQuery = window2.matchMedia(resolveRef(query).value) matches2.value = mediaQuery.matches if ('addEventListener' in mediaQuery) mediaQuery.addEventListener('change', update3) else mediaQuery.addListener(update3) } watchEffect(update3) tryOnScopeDispose(() => cleanup()) return matches2 } const breakpointsTailwind = { sm: 640, md: 768, lg: 1024, xl: 1280, '2xl': 1536, } const breakpointsBootstrapV5 = { sm: 576, md: 768, lg: 992, xl: 1200, xxl: 1400, } const breakpointsVuetify = { xs: 600, sm: 960, md: 1264, lg: 1904, } const breakpointsAntDesign = { xs: 480, sm: 576, md: 768, lg: 992, xl: 1200, xxl: 1600, } const breakpointsQuasar = { xs: 600, sm: 1024, md: 1440, lg: 1920, } const breakpointsSematic = { mobileS: 320, mobileM: 375, mobileL: 425, tablet: 768, laptop: 1024, laptopL: 1440, desktop4K: 2560, } const breakpointsMasterCss = { '3xs': 360, '2xs': 480, xs: 600, sm: 768, md: 1024, lg: 1280, xl: 1440, '2xl': 1600, '3xl': 1920, '4xl': 2560, } var __defProp$m = Object.defineProperty var __getOwnPropSymbols$o = Object.getOwnPropertySymbols var __hasOwnProp$o = Object.prototype.hasOwnProperty var __propIsEnum$o = Object.prototype.propertyIsEnumerable var __defNormalProp$m = (obj, key2, value2) => key2 in obj ? __defProp$m(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$m = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$o.call(b2, prop)) __defNormalProp$m(a2, prop, b2[prop]) if (__getOwnPropSymbols$o) for (var prop of __getOwnPropSymbols$o(b2)) { if (__propIsEnum$o.call(b2, prop)) __defNormalProp$m(a2, prop, b2[prop]) } return a2 } function useBreakpoints(breakpoints, options2 = {}) { function getValue2(k2, delta) { let v4 = breakpoints[k2] if (delta != null) v4 = increaseWithUnit(v4, delta) if (typeof v4 === 'number') v4 = `${v4}px` return v4 } const { window: window2 = defaultWindow$1 } = options2 function match2(query) { if (!window2) return false return window2.matchMedia(query).matches } const greaterOrEqual = (k2) => { return useMediaQuery(`(min-width: ${getValue2(k2)})`, options2) } const shortcutMethods = Object.keys(breakpoints).reduce((shortcuts, k2) => { Object.defineProperty(shortcuts, k2, { get: () => greaterOrEqual(k2), enumerable: true, configurable: true, }) return shortcuts }, {}) return __spreadValues$m( { greater(k2) { return useMediaQuery(`(min-width: ${getValue2(k2, 0.1)})`, options2) }, greaterOrEqual, smaller(k2) { return useMediaQuery(`(max-width: ${getValue2(k2, -0.1)})`, options2) }, smallerOrEqual(k2) { return useMediaQuery(`(max-width: ${getValue2(k2)})`, options2) }, between(a2, b2) { return useMediaQuery( `(min-width: ${getValue2(a2)}) and (max-width: ${getValue2( b2, -0.1 )})`, options2 ) }, isGreater(k2) { return match2(`(min-width: ${getValue2(k2, 0.1)})`) }, isGreaterOrEqual(k2) { return match2(`(min-width: ${getValue2(k2)})`) }, isSmaller(k2) { return match2(`(max-width: ${getValue2(k2, -0.1)})`) }, isSmallerOrEqual(k2) { return match2(`(max-width: ${getValue2(k2)})`) }, isInBetween(a2, b2) { return match2( `(min-width: ${getValue2(a2)}) and (max-width: ${getValue2( b2, -0.1 )})` ) }, }, shortcutMethods ) } const useBroadcastChannel = (options2) => { const { name: name2, window: window2 = defaultWindow$1 } = options2 const isSupported = useSupported( () => window2 && 'BroadcastChannel' in window2 ) const isClosed = ref(false) const channel2 = ref() const data2 = ref() const error2 = ref(null) const post = (data22) => { if (channel2.value) channel2.value.postMessage(data22) } const close2 = () => { if (channel2.value) channel2.value.close() isClosed.value = true } if (isSupported.value) { tryOnMounted(() => { error2.value = null channel2.value = new BroadcastChannel(name2) channel2.value.addEventListener( 'message', (e2) => { data2.value = e2.data }, { passive: true } ) channel2.value.addEventListener( 'messageerror', (e2) => { error2.value = e2 }, { passive: true } ) channel2.value.addEventListener('close', () => { isClosed.value = true }) }) } tryOnScopeDispose(() => { close2() }) return { isSupported, channel: channel2, data: data2, post, close: close2, error: error2, isClosed, } } function useBrowserLocation({ window: window2 = defaultWindow$1 } = {}) { const buildState2 = (trigger2) => { const { state: state22, length: length2 } = (window2 == null ? void 0 : window2.history) || {} const { hash: hash2, host, hostname, href, origin, pathname, port: port2, protocol, search: search2, } = (window2 == null ? void 0 : window2.location) || {} return { trigger: trigger2, state: state22, length: length2, hash: hash2, host, hostname, href, origin, pathname, port: port2, protocol, search: search2, } } const state2 = ref(buildState2('load')) if (window2) { useEventListener( window2, 'popstate', () => (state2.value = buildState2('popstate')), { passive: true } ) useEventListener( window2, 'hashchange', () => (state2.value = buildState2('hashchange')), { passive: true } ) } return state2 } function useCached(refValue, comparator = (a2, b2) => a2 === b2, watchOptions) { const cachedValue = ref(refValue.value) watch$1( () => refValue.value, (value2) => { if (!comparator(value2, cachedValue.value)) cachedValue.value = value2 }, watchOptions ) return cachedValue } function useClipboard(options2 = {}) { const { navigator: navigator2 = defaultNavigator, read: read2 = false, source: source2, copiedDuring = 1500, legacy = false, } = options2 const events2 = ['copy', 'cut'] const isClipboardApiSupported = useSupported( () => navigator2 && 'clipboard' in navigator2 ) const isSupported = computed(() => isClipboardApiSupported.value || legacy) const text2 = ref('') const copied = ref(false) const timeout = useTimeoutFn(() => (copied.value = false), copiedDuring) function updateText() { if (isClipboardApiSupported.value) { navigator2.clipboard.readText().then((value2) => { text2.value = value2 }) } else { text2.value = legacyRead() } } if (isSupported.value && read2) { for (const event of events2) useEventListener(event, updateText) } async function copy2(value2 = resolveUnref(source2)) { if (isSupported.value && value2 != null) { if (isClipboardApiSupported.value) await navigator2.clipboard.writeText(value2) else legacyCopy(value2) text2.value = value2 copied.value = true timeout.start() } } function legacyCopy(value2) { const ta2 = document.createElement('textarea') ta2.value = value2 != null ? value2 : '' ta2.style.position = 'absolute' ta2.style.opacity = '0' document.body.appendChild(ta2) ta2.select() document.execCommand('copy') ta2.remove() } function legacyRead() { var _a2, _b2, _c2 return (_c2 = (_b2 = (_a2 = document == null ? void 0 : document.getSelection) == null ? void 0 : _a2.call(document)) == null ? void 0 : _b2.toString()) != null ? _c2 : '' } return { isSupported, text: text2, copied, copy: copy2, } } var __defProp$l = Object.defineProperty var __defProps$8 = Object.defineProperties var __getOwnPropDescs$8 = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$n = Object.getOwnPropertySymbols var __hasOwnProp$n = Object.prototype.hasOwnProperty var __propIsEnum$n = Object.prototype.propertyIsEnumerable var __defNormalProp$l = (obj, key2, value2) => key2 in obj ? __defProp$l(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$l = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$n.call(b2, prop)) __defNormalProp$l(a2, prop, b2[prop]) if (__getOwnPropSymbols$n) for (var prop of __getOwnPropSymbols$n(b2)) { if (__propIsEnum$n.call(b2, prop)) __defNormalProp$l(a2, prop, b2[prop]) } return a2 } var __spreadProps$8 = (a2, b2) => __defProps$8(a2, __getOwnPropDescs$8(b2)) function cloneFnJSON(source2) { return JSON.parse(JSON.stringify(source2)) } function useCloned(source2, options2 = {}) { const cloned = ref({}) const { manual, clone: clone2 = cloneFnJSON, deep = true, immediate = true, } = options2 function sync() { cloned.value = clone2(unref(source2)) } if (!manual && isRef(source2)) { watch$1( source2, sync, __spreadProps$8(__spreadValues$l({}, options2), { deep, immediate, }) ) } else { sync() } return { cloned, sync } } const _global = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {} const globalKey = '__vueuse_ssr_handlers__' _global[globalKey] = _global[globalKey] || {} const handlers$2 = _global[globalKey] function getSSRHandler(key2, fallback) { return handlers$2[key2] || fallback } function setSSRHandler(key2, fn2) { handlers$2[key2] = fn2 } function guessSerializerType(rawInit) { return rawInit == null ? 'any' : rawInit instanceof Set ? 'set' : rawInit instanceof Map ? 'map' : rawInit instanceof Date ? 'date' : typeof rawInit === 'boolean' ? 'boolean' : typeof rawInit === 'string' ? 'string' : typeof rawInit === 'object' ? 'object' : !Number.isNaN(rawInit) ? 'number' : 'any' } var __defProp$k = Object.defineProperty var __getOwnPropSymbols$m = Object.getOwnPropertySymbols var __hasOwnProp$m = Object.prototype.hasOwnProperty var __propIsEnum$m = Object.prototype.propertyIsEnumerable var __defNormalProp$k = (obj, key2, value2) => key2 in obj ? __defProp$k(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$k = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$m.call(b2, prop)) __defNormalProp$k(a2, prop, b2[prop]) if (__getOwnPropSymbols$m) for (var prop of __getOwnPropSymbols$m(b2)) { if (__propIsEnum$m.call(b2, prop)) __defNormalProp$k(a2, prop, b2[prop]) } return a2 } const StorageSerializers = { boolean: { read: (v4) => v4 === 'true', write: (v4) => String(v4), }, object: { read: (v4) => JSON.parse(v4), write: (v4) => JSON.stringify(v4), }, number: { read: (v4) => Number.parseFloat(v4), write: (v4) => String(v4), }, any: { read: (v4) => v4, write: (v4) => String(v4), }, string: { read: (v4) => v4, write: (v4) => String(v4), }, map: { read: (v4) => new Map(JSON.parse(v4)), write: (v4) => JSON.stringify(Array.from(v4.entries())), }, set: { read: (v4) => new Set(JSON.parse(v4)), write: (v4) => JSON.stringify(Array.from(v4)), }, date: { read: (v4) => new Date(v4), write: (v4) => v4.toISOString(), }, } const customStorageEventName = 'vueuse-storage' function useStorage(key2, defaults2, storage2, options2 = {}) { var _a2 const { flush: flush2 = 'pre', deep = true, listenToStorageChanges = true, writeDefaults = true, mergeDefaults = false, shallow, window: window2 = defaultWindow$1, eventFilter, onError = (e2) => { console.error(e2) }, } = options2 const data2 = (shallow ? shallowRef : ref)(defaults2) if (!storage2) { try { storage2 = getSSRHandler('getDefaultStorage', () => { var _a22 return (_a22 = defaultWindow$1) == null ? void 0 : _a22.localStorage })() } catch (e2) { onError(e2) } } if (!storage2) return data2 const rawInit = resolveUnref(defaults2) const type4 = guessSerializerType(rawInit) const serializer = (_a2 = options2.serializer) != null ? _a2 : StorageSerializers[type4] const { pause: pauseWatch, resume: resumeWatch } = watchPausable( data2, () => write2(data2.value), { flush: flush2, deep, eventFilter } ) if (window2 && listenToStorageChanges) { useEventListener(window2, 'storage', update3) useEventListener(window2, customStorageEventName, updateFromCustomEvent) } update3() return data2 function write2(v4) { try { if (v4 == null) { storage2.removeItem(key2) } else { const serialized = serializer.write(v4) const oldValue = storage2.getItem(key2) if (oldValue !== serialized) { storage2.setItem(key2, serialized) if (window2) { window2.dispatchEvent( new CustomEvent(customStorageEventName, { detail: { key: key2, oldValue, newValue: serialized, storageArea: storage2, }, }) ) } } } } catch (e2) { onError(e2) } } function read2(event) { const rawValue = event ? event.newValue : storage2.getItem(key2) if (rawValue == null) { if (writeDefaults && rawInit !== null) storage2.setItem(key2, serializer.write(rawInit)) return rawInit } else if (!event && mergeDefaults) { const value2 = serializer.read(rawValue) if (isFunction$k(mergeDefaults)) return mergeDefaults(value2, rawInit) else if (type4 === 'object' && !Array.isArray(value2)) return __spreadValues$k(__spreadValues$k({}, rawInit), value2) return value2 } else if (typeof rawValue !== 'string') { return rawValue } else { return serializer.read(rawValue) } } function updateFromCustomEvent(event) { update3(event.detail) } function update3(event) { if (event && event.storageArea !== storage2) return if (event && event.key == null) { data2.value = rawInit return } if (event && event.key !== key2) return pauseWatch() try { data2.value = read2(event) } catch (e2) { onError(e2) } finally { if (event) nextTick(resumeWatch) else resumeWatch() } } } function usePreferredDark(options2) { return useMediaQuery('(prefers-color-scheme: dark)', options2) } var __defProp$j = Object.defineProperty var __getOwnPropSymbols$l = Object.getOwnPropertySymbols var __hasOwnProp$l = Object.prototype.hasOwnProperty var __propIsEnum$l = Object.prototype.propertyIsEnumerable var __defNormalProp$j = (obj, key2, value2) => key2 in obj ? __defProp$j(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$j = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$l.call(b2, prop)) __defNormalProp$j(a2, prop, b2[prop]) if (__getOwnPropSymbols$l) for (var prop of __getOwnPropSymbols$l(b2)) { if (__propIsEnum$l.call(b2, prop)) __defNormalProp$j(a2, prop, b2[prop]) } return a2 } function useColorMode(options2 = {}) { const { selector: selector2 = 'html', attribute = 'class', initialValue = 'auto', window: window2 = defaultWindow$1, storage: storage2, storageKey = 'vueuse-color-scheme', listenToStorageChanges = true, storageRef, emitAuto, } = options2 const modes = __spreadValues$j( { auto: '', light: 'light', dark: 'dark', }, options2.modes || {} ) const preferredDark = usePreferredDark({ window: window2 }) const preferredMode = computed(() => (preferredDark.value ? 'dark' : 'light')) const store2 = storageRef || (storageKey == null ? ref(initialValue) : useStorage(storageKey, initialValue, storage2, { window: window2, listenToStorageChanges, })) const state2 = computed({ get() { return store2.value === 'auto' && !emitAuto ? preferredMode.value : store2.value }, set(v4) { store2.value = v4 }, }) const updateHTMLAttrs = getSSRHandler( 'updateHTMLAttrs', (selector22, attribute2, value2) => { const el2 = window2 == null ? void 0 : window2.document.querySelector(selector22) if (!el2) return if (attribute2 === 'class') { const current2 = value2.split(/\s/g) Object.values(modes) .flatMap((i2) => (i2 || '').split(/\s/g)) .filter(Boolean) .forEach((v4) => { if (current2.includes(v4)) el2.classList.add(v4) else el2.classList.remove(v4) }) } else { el2.setAttribute(attribute2, value2) } } ) function defaultOnChanged(mode2) { var _a2 const resolvedMode = mode2 === 'auto' ? preferredMode.value : mode2 updateHTMLAttrs( selector2, attribute, (_a2 = modes[resolvedMode]) != null ? _a2 : resolvedMode ) } function onChanged(mode2) { if (options2.onChanged) options2.onChanged(mode2, defaultOnChanged) else defaultOnChanged(mode2) } watch$1(state2, onChanged, { flush: 'post', immediate: true }) if (emitAuto) watch$1(preferredMode, () => onChanged(state2.value), { flush: 'post' }) tryOnMounted(() => onChanged(state2.value)) return state2 } function useConfirmDialog(revealed = ref(false)) { const confirmHook = createEventHook() const cancelHook = createEventHook() const revealHook = createEventHook() let _resolve = noop$6 const reveal = (data2) => { revealHook.trigger(data2) revealed.value = true return new Promise((resolve2) => { _resolve = resolve2 }) } const confirm2 = (data2) => { revealed.value = false confirmHook.trigger(data2) _resolve({ data: data2, isCanceled: false }) } const cancel2 = (data2) => { revealed.value = false cancelHook.trigger(data2) _resolve({ data: data2, isCanceled: true }) } return { isRevealed: computed(() => revealed.value), reveal, confirm: confirm2, cancel: cancel2, onReveal: revealHook.on, onConfirm: confirmHook.on, onCancel: cancelHook.on, } } function useCssVar( prop, target2, { window: window2 = defaultWindow$1, initialValue = '' } = {} ) { const variable = ref(initialValue) const elRef = computed(() => { var _a2 return ( unrefElement(target2) || ((_a2 = window2 == null ? void 0 : window2.document) == null ? void 0 : _a2.documentElement) ) }) watch$1( [elRef, () => resolveUnref(prop)], ([el2, prop2]) => { var _a2 if (el2 && window2) { const value2 = (_a2 = window2.getComputedStyle(el2).getPropertyValue(prop2)) == null ? void 0 : _a2.trim() variable.value = value2 || initialValue } }, { immediate: true } ) watch$1(variable, (val2) => { var _a2 if ((_a2 = elRef.value) == null ? void 0 : _a2.style) elRef.value.style.setProperty(resolveUnref(prop), val2) }) return variable } function useCurrentElement() { const vm = getCurrentInstance() const currentElement = computedWithControl( () => null, () => vm.proxy.$el ) onUpdated(currentElement.trigger) onMounted(currentElement.trigger) return currentElement } function useCycleList(list2, options2) { var _a2 const state2 = shallowRef( (_a2 = options2 == null ? void 0 : options2.initialValue) != null ? _a2 : list2[0] ) const index2 = computed({ get() { var _a22 let index22 = (options2 == null ? void 0 : options2.getIndexOf) ? options2.getIndexOf(state2.value, list2) : list2.indexOf(state2.value) if (index22 < 0) index22 = (_a22 = options2 == null ? void 0 : options2.fallbackIndex) != null ? _a22 : 0 return index22 }, set(v4) { set2(v4) }, }) function set2(i2) { const length2 = list2.length const index22 = ((i2 % length2) + length2) % length2 const value2 = list2[index22] state2.value = value2 return value2 } function shift(delta = 1) { return set2(index2.value + delta) } function next(n2 = 1) { return shift(n2) } function prev(n2 = 1) { return shift(-n2) } return { state: state2, index: index2, next, prev, } } var __defProp$i = Object.defineProperty var __defProps$7 = Object.defineProperties var __getOwnPropDescs$7 = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$k = Object.getOwnPropertySymbols var __hasOwnProp$k = Object.prototype.hasOwnProperty var __propIsEnum$k = Object.prototype.propertyIsEnumerable var __defNormalProp$i = (obj, key2, value2) => key2 in obj ? __defProp$i(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$i = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$k.call(b2, prop)) __defNormalProp$i(a2, prop, b2[prop]) if (__getOwnPropSymbols$k) for (var prop of __getOwnPropSymbols$k(b2)) { if (__propIsEnum$k.call(b2, prop)) __defNormalProp$i(a2, prop, b2[prop]) } return a2 } var __spreadProps$7 = (a2, b2) => __defProps$7(a2, __getOwnPropDescs$7(b2)) function useDark(options2 = {}) { const { valueDark = 'dark', valueLight = '', window: window2 = defaultWindow$1, } = options2 const mode2 = useColorMode( __spreadProps$7(__spreadValues$i({}, options2), { onChanged: (mode22, defaultHandler) => { var _a2 if (options2.onChanged) (_a2 = options2.onChanged) == null ? void 0 : _a2.call(options2, mode22 === 'dark') else defaultHandler(mode22) }, modes: { dark: valueDark, light: valueLight, }, }) ) const preferredDark = usePreferredDark({ window: window2 }) const isDark = computed({ get() { return mode2.value === 'dark' }, set(v4) { if (v4 === preferredDark.value) mode2.value = 'auto' else mode2.value = v4 ? 'dark' : 'light' }, }) return isDark } const fnBypass = (v4) => v4 const fnSetSource = (source2, value2) => (source2.value = value2) function defaultDump(clone2) { return clone2 ? (isFunction$k(clone2) ? clone2 : cloneFnJSON) : fnBypass } function defaultParse(clone2) { return clone2 ? (isFunction$k(clone2) ? clone2 : cloneFnJSON) : fnBypass } function useManualRefHistory(source2, options2 = {}) { const { clone: clone2 = false, dump = defaultDump(clone2), parse: parse2 = defaultParse(clone2), setSource = fnSetSource, } = options2 function _createHistoryRecord() { return markRaw({ snapshot: dump(source2.value), timestamp: timestamp$2(), }) } const last2 = ref(_createHistoryRecord()) const undoStack = ref([]) const redoStack = ref([]) const _setSource = (record) => { setSource(source2, parse2(record.snapshot)) last2.value = record } const commit2 = () => { undoStack.value.unshift(last2.value) last2.value = _createHistoryRecord() if (options2.capacity && undoStack.value.length > options2.capacity) undoStack.value.splice(options2.capacity, Infinity) if (redoStack.value.length) redoStack.value.splice(0, redoStack.value.length) } const clear2 = () => { undoStack.value.splice(0, undoStack.value.length) redoStack.value.splice(0, redoStack.value.length) } const undo2 = () => { const state2 = undoStack.value.shift() if (state2) { redoStack.value.unshift(last2.value) _setSource(state2) } } const redo2 = () => { const state2 = redoStack.value.shift() if (state2) { undoStack.value.unshift(last2.value) _setSource(state2) } } const reset2 = () => { _setSource(last2.value) } const history2 = computed(() => [last2.value, ...undoStack.value]) const canUndo2 = computed(() => undoStack.value.length > 0) const canRedo2 = computed(() => redoStack.value.length > 0) return { source: source2, undoStack, redoStack, last: last2, history: history2, canUndo: canUndo2, canRedo: canRedo2, clear: clear2, commit: commit2, reset: reset2, undo: undo2, redo: redo2, } } var __defProp$h = Object.defineProperty var __defProps$6 = Object.defineProperties var __getOwnPropDescs$6 = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$j = Object.getOwnPropertySymbols var __hasOwnProp$j = Object.prototype.hasOwnProperty var __propIsEnum$j = Object.prototype.propertyIsEnumerable var __defNormalProp$h = (obj, key2, value2) => key2 in obj ? __defProp$h(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$h = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$j.call(b2, prop)) __defNormalProp$h(a2, prop, b2[prop]) if (__getOwnPropSymbols$j) for (var prop of __getOwnPropSymbols$j(b2)) { if (__propIsEnum$j.call(b2, prop)) __defNormalProp$h(a2, prop, b2[prop]) } return a2 } var __spreadProps$6 = (a2, b2) => __defProps$6(a2, __getOwnPropDescs$6(b2)) function useRefHistory(source2, options2 = {}) { const { deep = false, flush: flush2 = 'pre', eventFilter } = options2 const { eventFilter: composedFilter, pause, resume: resumeTracking, isActive: isTracking, } = pausableFilter(eventFilter) const { ignoreUpdates, ignorePrevAsyncUpdates, stop: stop2, } = watchIgnorable(source2, commit2, { deep, flush: flush2, eventFilter: composedFilter, }) function setSource(source22, value2) { ignorePrevAsyncUpdates() ignoreUpdates(() => { source22.value = value2 }) } const manualHistory = useManualRefHistory( source2, __spreadProps$6(__spreadValues$h({}, options2), { clone: options2.clone || deep, setSource, }) ) const { clear: clear2, commit: manualCommit } = manualHistory function commit2() { ignorePrevAsyncUpdates() manualCommit() } function resume(commitNow) { resumeTracking() if (commitNow) commit2() } function batch(fn2) { let canceled = false const cancel2 = () => (canceled = true) ignoreUpdates(() => { fn2(cancel2) }) if (!canceled) commit2() } function dispose2() { stop2() clear2() } return __spreadProps$6(__spreadValues$h({}, manualHistory), { isTracking, pause, resume, commit: commit2, batch, dispose: dispose2, }) } var __defProp$g = Object.defineProperty var __defProps$5 = Object.defineProperties var __getOwnPropDescs$5 = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$i = Object.getOwnPropertySymbols var __hasOwnProp$i = Object.prototype.hasOwnProperty var __propIsEnum$i = Object.prototype.propertyIsEnumerable var __defNormalProp$g = (obj, key2, value2) => key2 in obj ? __defProp$g(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$g = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$i.call(b2, prop)) __defNormalProp$g(a2, prop, b2[prop]) if (__getOwnPropSymbols$i) for (var prop of __getOwnPropSymbols$i(b2)) { if (__propIsEnum$i.call(b2, prop)) __defNormalProp$g(a2, prop, b2[prop]) } return a2 } var __spreadProps$5 = (a2, b2) => __defProps$5(a2, __getOwnPropDescs$5(b2)) function useDebouncedRefHistory(source2, options2 = {}) { const filter2 = options2.debounce ? debounceFilter(options2.debounce) : void 0 const history2 = useRefHistory( source2, __spreadProps$5(__spreadValues$g({}, options2), { eventFilter: filter2 }) ) return __spreadValues$g({}, history2) } function useDeviceMotion(options2 = {}) { const { window: window2 = defaultWindow$1, eventFilter = bypassFilter } = options2 const acceleration = ref({ x: null, y: null, z: null }) const rotationRate = ref({ alpha: null, beta: null, gamma: null }) const interval = ref(0) const accelerationIncludingGravity = ref({ x: null, y: null, z: null, }) if (window2) { const onDeviceMotion = createFilterWrapper(eventFilter, (event) => { acceleration.value = event.acceleration accelerationIncludingGravity.value = event.accelerationIncludingGravity rotationRate.value = event.rotationRate interval.value = event.interval }) useEventListener(window2, 'devicemotion', onDeviceMotion) } return { acceleration, accelerationIncludingGravity, rotationRate, interval, } } function useDeviceOrientation(options2 = {}) { const { window: window2 = defaultWindow$1 } = options2 const isSupported = useSupported( () => window2 && 'DeviceOrientationEvent' in window2 ) const isAbsolute = ref(false) const alpha = ref(null) const beta = ref(null) const gamma = ref(null) if (window2 && isSupported.value) { useEventListener(window2, 'deviceorientation', (event) => { isAbsolute.value = event.absolute alpha.value = event.alpha beta.value = event.beta gamma.value = event.gamma }) } return { isSupported, isAbsolute, alpha, beta, gamma, } } function useDevicePixelRatio({ window: window2 = defaultWindow$1 } = {}) { const pixelRatio = ref(1) if (window2) { let observe = function () { pixelRatio.value = window2.devicePixelRatio cleanup() media = window2.matchMedia(`(resolution: ${pixelRatio.value}dppx)`) media.addEventListener('change', observe, { once: true }) }, cleanup = function () { media == null ? void 0 : media.removeEventListener('change', observe) } let media observe() tryOnScopeDispose(cleanup) } return { pixelRatio } } function usePermission(permissionDesc, options2 = {}) { const { controls = false, navigator: navigator2 = defaultNavigator } = options2 const isSupported = useSupported( () => navigator2 && 'permissions' in navigator2 ) let permissionStatus const desc = typeof permissionDesc === 'string' ? { name: permissionDesc } : permissionDesc const state2 = ref() const onChange = () => { if (permissionStatus) state2.value = permissionStatus.state } const query = createSingletonPromise(async () => { if (!isSupported.value) return if (!permissionStatus) { try { permissionStatus = await navigator2.permissions.query(desc) useEventListener(permissionStatus, 'change', onChange) onChange() } catch (e2) { state2.value = 'prompt' } } return permissionStatus }) query() if (controls) { return { state: state2, isSupported, query, } } else { return state2 } } function useDevicesList(options2 = {}) { const { navigator: navigator2 = defaultNavigator, requestPermissions = false, constraints = { audio: true, video: true }, onUpdated: onUpdated2, } = options2 const devices = ref([]) const videoInputs = computed(() => devices.value.filter((i2) => i2.kind === 'videoinput') ) const audioInputs = computed(() => devices.value.filter((i2) => i2.kind === 'audioinput') ) const audioOutputs = computed(() => devices.value.filter((i2) => i2.kind === 'audiooutput') ) const isSupported = useSupported( () => navigator2 && navigator2.mediaDevices && navigator2.mediaDevices.enumerateDevices ) const permissionGranted = ref(false) async function update3() { if (!isSupported.value) return devices.value = await navigator2.mediaDevices.enumerateDevices() onUpdated2 == null ? void 0 : onUpdated2(devices.value) } async function ensurePermissions() { if (!isSupported.value) return false if (permissionGranted.value) return true const { state: state2, query } = usePermission('camera', { controls: true }) await query() if (state2.value !== 'granted') { const stream = await navigator2.mediaDevices.getUserMedia(constraints) stream.getTracks().forEach((t3) => t3.stop()) update3() permissionGranted.value = true } else { permissionGranted.value = true } return permissionGranted.value } if (isSupported.value) { if (requestPermissions) ensurePermissions() useEventListener(navigator2.mediaDevices, 'devicechange', update3) update3() } return { devices, ensurePermissions, permissionGranted, videoInputs, audioInputs, audioOutputs, isSupported, } } function useDisplayMedia(options2 = {}) { var _a2 const enabled = ref((_a2 = options2.enabled) != null ? _a2 : false) const video = options2.video const audio2 = options2.audio const { navigator: navigator2 = defaultNavigator } = options2 const isSupported = useSupported(() => { var _a22 return (_a22 = navigator2 == null ? void 0 : navigator2.mediaDevices) == null ? void 0 : _a22.getDisplayMedia }) const constraint = { audio: audio2, video } const stream = shallowRef() async function _start() { if (!isSupported.value || stream.value) return stream.value = await navigator2.mediaDevices.getDisplayMedia(constraint) return stream.value } async function _stop() { var _a22 ;(_a22 = stream.value) == null ? void 0 : _a22.getTracks().forEach((t3) => t3.stop()) stream.value = void 0 } function stop2() { _stop() enabled.value = false } async function start2() { await _start() if (stream.value) enabled.value = true return stream.value } watch$1( enabled, (v4) => { if (v4) _start() else _stop() }, { immediate: true } ) return { isSupported, stream, start: start2, stop: stop2, enabled, } } function useDocumentVisibility({ document: document2 = defaultDocument } = {}) { if (!document2) return ref('visible') const visibility2 = ref(document2.visibilityState) useEventListener(document2, 'visibilitychange', () => { visibility2.value = document2.visibilityState }) return visibility2 } var __defProp$f = Object.defineProperty var __defProps$4 = Object.defineProperties var __getOwnPropDescs$4 = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$h = Object.getOwnPropertySymbols var __hasOwnProp$h = Object.prototype.hasOwnProperty var __propIsEnum$h = Object.prototype.propertyIsEnumerable var __defNormalProp$f = (obj, key2, value2) => key2 in obj ? __defProp$f(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$f = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$h.call(b2, prop)) __defNormalProp$f(a2, prop, b2[prop]) if (__getOwnPropSymbols$h) for (var prop of __getOwnPropSymbols$h(b2)) { if (__propIsEnum$h.call(b2, prop)) __defNormalProp$f(a2, prop, b2[prop]) } return a2 } var __spreadProps$4 = (a2, b2) => __defProps$4(a2, __getOwnPropDescs$4(b2)) function useDraggable(target2, options2 = {}) { var _a2, _b2, _c2 const draggingElement = (_a2 = options2.draggingElement) != null ? _a2 : defaultWindow$1 const draggingHandle = (_b2 = options2.handle) != null ? _b2 : target2 const position2 = ref( (_c2 = resolveUnref(options2.initialValue)) != null ? _c2 : { x: 0, y: 0 } ) const pressedDelta = ref() const filterEvent = (e2) => { if (options2.pointerTypes) return options2.pointerTypes.includes(e2.pointerType) return true } const handleEvent2 = (e2) => { if (resolveUnref(options2.preventDefault)) e2.preventDefault() if (resolveUnref(options2.stopPropagation)) e2.stopPropagation() } const start2 = (e2) => { var _a22 if (!filterEvent(e2)) return if (resolveUnref(options2.exact) && e2.target !== resolveUnref(target2)) return const rect = resolveUnref(target2).getBoundingClientRect() const pos = { x: e2.clientX - rect.left, y: e2.clientY - rect.top, } if ( ((_a22 = options2.onStart) == null ? void 0 : _a22.call(options2, pos, e2)) === false ) return pressedDelta.value = pos handleEvent2(e2) } const move = (e2) => { var _a22 if (!filterEvent(e2)) return if (!pressedDelta.value) return position2.value = { x: e2.clientX - pressedDelta.value.x, y: e2.clientY - pressedDelta.value.y, } ;(_a22 = options2.onMove) == null ? void 0 : _a22.call(options2, position2.value, e2) handleEvent2(e2) } const end2 = (e2) => { var _a22 if (!filterEvent(e2)) return if (!pressedDelta.value) return pressedDelta.value = void 0 ;(_a22 = options2.onEnd) == null ? void 0 : _a22.call(options2, position2.value, e2) handleEvent2(e2) } if (isClient) { useEventListener(draggingHandle, 'pointerdown', start2, true) useEventListener(draggingElement, 'pointermove', move, true) useEventListener(draggingElement, 'pointerup', end2, true) } return __spreadProps$4(__spreadValues$f({}, toRefs(position2)), { position: position2, isDragging: computed(() => !!pressedDelta.value), style: computed( () => `left:${position2.value.x}px;top:${position2.value.y}px;` ), }) } function useDropZone(target2, onDrop) { const isOverDropZone = ref(false) let counter2 = 0 if (isClient) { useEventListener(target2, 'dragenter', (event) => { event.preventDefault() counter2 += 1 isOverDropZone.value = true }) useEventListener(target2, 'dragover', (event) => { event.preventDefault() }) useEventListener(target2, 'dragleave', (event) => { event.preventDefault() counter2 -= 1 if (counter2 === 0) isOverDropZone.value = false }) useEventListener(target2, 'drop', (event) => { var _a2, _b2 event.preventDefault() counter2 = 0 isOverDropZone.value = false const files2 = Array.from( (_b2 = (_a2 = event.dataTransfer) == null ? void 0 : _a2.files) != null ? _b2 : [] ) onDrop == null ? void 0 : onDrop(files2.length === 0 ? null : files2) }) } return { isOverDropZone, } } var __getOwnPropSymbols$g = Object.getOwnPropertySymbols var __hasOwnProp$g = Object.prototype.hasOwnProperty var __propIsEnum$g = Object.prototype.propertyIsEnumerable var __objRest$2 = (source2, exclude) => { var target2 = {} for (var prop in source2) if (__hasOwnProp$g.call(source2, prop) && exclude.indexOf(prop) < 0) target2[prop] = source2[prop] if (source2 != null && __getOwnPropSymbols$g) for (var prop of __getOwnPropSymbols$g(source2)) { if (exclude.indexOf(prop) < 0 && __propIsEnum$g.call(source2, prop)) target2[prop] = source2[prop] } return target2 } function useResizeObserver(target2, callback, options2 = {}) { const _a2 = options2, { window: window2 = defaultWindow$1 } = _a2, observerOptions = __objRest$2(_a2, ['window']) let observer const isSupported = useSupported(() => window2 && 'ResizeObserver' in window2) const cleanup = () => { if (observer) { observer.disconnect() observer = void 0 } } const stopWatch = watch$1( () => unrefElement(target2), (el2) => { cleanup() if (isSupported.value && window2 && el2) { observer = new ResizeObserver(callback) observer.observe(el2, observerOptions) } }, { immediate: true, flush: 'post' } ) const stop2 = () => { cleanup() stopWatch() } tryOnScopeDispose(stop2) return { isSupported, stop: stop2, } } function useElementBounding(target2, options2 = {}) { const { reset: reset2 = true, windowResize = true, windowScroll = true, immediate = true, } = options2 const height = ref(0) const bottom2 = ref(0) const left2 = ref(0) const right2 = ref(0) const top2 = ref(0) const width = ref(0) const x2 = ref(0) const y2 = ref(0) function update3() { const el2 = unrefElement(target2) if (!el2) { if (reset2) { height.value = 0 bottom2.value = 0 left2.value = 0 right2.value = 0 top2.value = 0 width.value = 0 x2.value = 0 y2.value = 0 } return } const rect = el2.getBoundingClientRect() height.value = rect.height bottom2.value = rect.bottom left2.value = rect.left right2.value = rect.right top2.value = rect.top width.value = rect.width x2.value = rect.x y2.value = rect.y } useResizeObserver(target2, update3) watch$1( () => unrefElement(target2), (ele) => !ele && update3() ) if (windowScroll) useEventListener('scroll', update3, { capture: true, passive: true }) if (windowResize) useEventListener('resize', update3, { passive: true }) tryOnMounted(() => { if (immediate) update3() }) return { height, bottom: bottom2, left: left2, right: right2, top: top2, width, x: x2, y: y2, update: update3, } } function useRafFn(fn2, options2 = {}) { const { immediate = true, window: window2 = defaultWindow$1 } = options2 const isActive = ref(false) let previousFrameTimestamp = 0 let rafId = null function loop(timestamp2) { if (!isActive.value || !window2) return const delta = timestamp2 - previousFrameTimestamp fn2({ delta, timestamp: timestamp2 }) previousFrameTimestamp = timestamp2 rafId = window2.requestAnimationFrame(loop) } function resume() { if (!isActive.value && window2) { isActive.value = true rafId = window2.requestAnimationFrame(loop) } } function pause() { isActive.value = false if (rafId != null && window2) { window2.cancelAnimationFrame(rafId) rafId = null } } if (immediate) resume() tryOnScopeDispose(pause) return { isActive: readonly(isActive), pause, resume, } } var __defProp$e = Object.defineProperty var __getOwnPropSymbols$f = Object.getOwnPropertySymbols var __hasOwnProp$f = Object.prototype.hasOwnProperty var __propIsEnum$f = Object.prototype.propertyIsEnumerable var __defNormalProp$e = (obj, key2, value2) => key2 in obj ? __defProp$e(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$e = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$f.call(b2, prop)) __defNormalProp$e(a2, prop, b2[prop]) if (__getOwnPropSymbols$f) for (var prop of __getOwnPropSymbols$f(b2)) { if (__propIsEnum$f.call(b2, prop)) __defNormalProp$e(a2, prop, b2[prop]) } return a2 } function useElementByPoint(options2) { const element = ref(null) const { x: x2, y: y2, document: document2 = defaultDocument } = options2 const controls = useRafFn(() => { element.value = (document2 == null ? void 0 : document2.elementFromPoint(resolveUnref(x2), resolveUnref(y2))) || null }) return __spreadValues$e( { element, }, controls ) } function useElementHover(el2, options2 = {}) { const delayEnter = options2 ? options2.delayEnter : 0 const delayLeave = options2 ? options2.delayLeave : 0 const isHovered = ref(false) let timer2 const toggle2 = (entering) => { const delay2 = entering ? delayEnter : delayLeave if (timer2) { clearTimeout(timer2) timer2 = void 0 } if (delay2) timer2 = setTimeout(() => (isHovered.value = entering), delay2) else isHovered.value = entering } if (!window) return isHovered useEventListener(el2, 'mouseenter', () => toggle2(true), { passive: true }) useEventListener(el2, 'mouseleave', () => toggle2(false), { passive: true }) return isHovered } function useElementSize( target2, initialSize = { width: 0, height: 0 }, options2 = {} ) { const { window: window2 = defaultWindow$1, box: box2 = 'content-box' } = options2 const isSVG2 = computed(() => { var _a2, _b2 return (_b2 = (_a2 = unrefElement(target2)) == null ? void 0 : _a2.namespaceURI) == null ? void 0 : _b2.includes('svg') }) const width = ref(initialSize.width) const height = ref(initialSize.height) useResizeObserver( target2, ([entry]) => { const boxSize = box2 === 'border-box' ? entry.borderBoxSize : box2 === 'content-box' ? entry.contentBoxSize : entry.devicePixelContentBoxSize if (window2 && isSVG2.value) { const $elem = unrefElement(target2) if ($elem) { const styles = window2.getComputedStyle($elem) width.value = parseFloat(styles.width) height.value = parseFloat(styles.height) } } else { if (boxSize) { const formatBoxSize = Array.isArray(boxSize) ? boxSize : [boxSize] width.value = formatBoxSize.reduce( (acc, { inlineSize }) => acc + inlineSize, 0 ) height.value = formatBoxSize.reduce( (acc, { blockSize }) => acc + blockSize, 0 ) } else { width.value = entry.contentRect.width height.value = entry.contentRect.height } } }, options2 ) watch$1( () => unrefElement(target2), (ele) => { width.value = ele ? initialSize.width : 0 height.value = ele ? initialSize.height : 0 } ) return { width, height, } } function useElementVisibility( element, { window: window2 = defaultWindow$1, scrollTarget } = {} ) { const elementIsVisible = ref(false) const testBounding = () => { if (!window2) return const document2 = window2.document const el2 = unrefElement(element) if (!el2) { elementIsVisible.value = false } else { const rect = el2.getBoundingClientRect() elementIsVisible.value = rect.top <= (window2.innerHeight || document2.documentElement.clientHeight) && rect.left <= (window2.innerWidth || document2.documentElement.clientWidth) && rect.bottom >= 0 && rect.right >= 0 } } watch$1( () => unrefElement(element), () => testBounding(), { immediate: true, flush: 'post' } ) if (window2) { useEventListener(scrollTarget || window2, 'scroll', testBounding, { capture: false, passive: true, }) } return elementIsVisible } const events = /* @__PURE__ */ new Map() function useEventBus(key2) { const scope = getCurrentScope() function on2(listener) { var _a2 const listeners = events.get(key2) || [] listeners.push(listener) events.set(key2, listeners) const _off = () => off2(listener) ;(_a2 = scope == null ? void 0 : scope.cleanups) == null ? void 0 : _a2.push(_off) return _off } function once2(listener) { function _listener(...args) { off2(_listener) listener(...args) } return on2(_listener) } function off2(listener) { const listeners = events.get(key2) if (!listeners) return const index2 = listeners.indexOf(listener) if (index2 > -1) listeners.splice(index2, 1) if (!listeners.length) events.delete(key2) } function reset2() { events.delete(key2) } function emit2(event, payload) { var _a2 ;(_a2 = events.get(key2)) == null ? void 0 : _a2.forEach((v4) => v4(event, payload)) } return { on: on2, once: once2, off: off2, emit: emit2, reset: reset2 } } function useEventSource(url2, events2 = [], options2 = {}) { const event = ref(null) const data2 = ref(null) const status = ref('CONNECTING') const eventSource = ref(null) const error2 = ref(null) const { withCredentials = false } = options2 const close2 = () => { if (eventSource.value) { eventSource.value.close() eventSource.value = null status.value = 'CLOSED' } } const es2 = new EventSource(url2, { withCredentials }) eventSource.value = es2 es2.onopen = () => { status.value = 'OPEN' error2.value = null } es2.onerror = (e2) => { status.value = 'CLOSED' error2.value = e2 } es2.onmessage = (e2) => { event.value = null data2.value = e2.data } for (const event_name of events2) { useEventListener(es2, event_name, (e2) => { event.value = event_name data2.value = e2.data || null }) } tryOnScopeDispose(() => { close2() }) return { eventSource, event, data: data2, status, error: error2, close: close2, } } function useEyeDropper(options2 = {}) { const { initialValue = '' } = options2 const isSupported = useSupported( () => typeof window !== 'undefined' && 'EyeDropper' in window ) const sRGBHex = ref(initialValue) async function open2(openOptions) { if (!isSupported.value) return const eyeDropper = new window.EyeDropper() const result = await eyeDropper.open(openOptions) sRGBHex.value = result.sRGBHex return result } return { isSupported, sRGBHex, open: open2 } } function useFavicon(newIcon = null, options2 = {}) { const { baseUrl = '', rel = 'icon', document: document2 = defaultDocument, } = options2 const favicon = resolveRef(newIcon) const applyIcon = (icon) => { document2 == null ? void 0 : document2.head .querySelectorAll(`link[rel*="${rel}"]`) .forEach((el2) => (el2.href = `${baseUrl}${icon}`)) } watch$1( favicon, (i2, o2) => { if (isString$e(i2) && i2 !== o2) applyIcon(i2) }, { immediate: true } ) return favicon } var __defProp$d = Object.defineProperty var __defProps$3 = Object.defineProperties var __getOwnPropDescs$3 = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$e = Object.getOwnPropertySymbols var __hasOwnProp$e = Object.prototype.hasOwnProperty var __propIsEnum$e = Object.prototype.propertyIsEnumerable var __defNormalProp$d = (obj, key2, value2) => key2 in obj ? __defProp$d(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$d = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$e.call(b2, prop)) __defNormalProp$d(a2, prop, b2[prop]) if (__getOwnPropSymbols$e) for (var prop of __getOwnPropSymbols$e(b2)) { if (__propIsEnum$e.call(b2, prop)) __defNormalProp$d(a2, prop, b2[prop]) } return a2 } var __spreadProps$3 = (a2, b2) => __defProps$3(a2, __getOwnPropDescs$3(b2)) const payloadMapping = { json: 'application/json', text: 'text/plain', } function isFetchOptions(obj) { return ( obj && containsProp( obj, 'immediate', 'refetch', 'initialData', 'timeout', 'beforeFetch', 'afterFetch', 'onFetchError', 'fetch' ) ) } function isAbsoluteURL$2(url2) { return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(url2) } function headersToObject(headers) { if (typeof Headers !== 'undefined' && headers instanceof Headers) return Object.fromEntries([...headers.entries()]) return headers } function combineCallbacks(combination2, ...callbacks) { if (combination2 === 'overwrite') { return async (ctx) => { const callback = callbacks[callbacks.length - 1] if (callback !== void 0) await callback(ctx) return ctx } } else { return async (ctx) => { await callbacks.reduce( (prevCallback, callback) => prevCallback.then(async () => { if (callback) ctx = __spreadValues$d( __spreadValues$d({}, ctx), await callback(ctx) ) }), Promise.resolve() ) return ctx } } } function createFetch(config2 = {}) { const _combination = config2.combination || 'chain' const _options = config2.options || {} const _fetchOptions = config2.fetchOptions || {} function useFactoryFetch(url2, ...args) { const computedUrl = computed(() => { const baseUrl = resolveUnref(config2.baseUrl) const targetUrl = resolveUnref(url2) return baseUrl && !isAbsoluteURL$2(targetUrl) ? joinPaths(baseUrl, targetUrl) : targetUrl }) let options2 = _options let fetchOptions = _fetchOptions if (args.length > 0) { if (isFetchOptions(args[0])) { options2 = __spreadProps$3( __spreadValues$d(__spreadValues$d({}, options2), args[0]), { beforeFetch: combineCallbacks( _combination, _options.beforeFetch, args[0].beforeFetch ), afterFetch: combineCallbacks( _combination, _options.afterFetch, args[0].afterFetch ), onFetchError: combineCallbacks( _combination, _options.onFetchError, args[0].onFetchError ), } ) } else { fetchOptions = __spreadProps$3( __spreadValues$d(__spreadValues$d({}, fetchOptions), args[0]), { headers: __spreadValues$d( __spreadValues$d({}, headersToObject(fetchOptions.headers) || {}), headersToObject(args[0].headers) || {} ), } ) } } if (args.length > 1 && isFetchOptions(args[1])) { options2 = __spreadProps$3( __spreadValues$d(__spreadValues$d({}, options2), args[1]), { beforeFetch: combineCallbacks( _combination, _options.beforeFetch, args[1].beforeFetch ), afterFetch: combineCallbacks( _combination, _options.afterFetch, args[1].afterFetch ), onFetchError: combineCallbacks( _combination, _options.onFetchError, args[1].onFetchError ), } ) } return useFetch(computedUrl, fetchOptions, options2) } return useFactoryFetch } function useFetch(url2, ...args) { var _a2 const supportsAbort = typeof AbortController === 'function' let fetchOptions = {} let options2 = { immediate: true, refetch: false, timeout: 0 } const config2 = { method: 'GET', type: 'text', payload: void 0, } if (args.length > 0) { if (isFetchOptions(args[0])) options2 = __spreadValues$d(__spreadValues$d({}, options2), args[0]) else fetchOptions = args[0] } if (args.length > 1) { if (isFetchOptions(args[1])) options2 = __spreadValues$d(__spreadValues$d({}, options2), args[1]) } const { fetch: fetch2 = (_a2 = defaultWindow$1) == null ? void 0 : _a2.fetch, initialData, timeout, } = options2 const responseEvent = createEventHook() const errorEvent = createEventHook() const finallyEvent = createEventHook() const isFinished = ref(false) const isFetching = ref(false) const aborted = ref(false) const statusCode = ref(null) const response = shallowRef(null) const error2 = shallowRef(null) const data2 = shallowRef(initialData) const canAbort = computed(() => supportsAbort && isFetching.value) let controller let timer2 const abort = () => { if (supportsAbort && controller) { controller.abort() controller = void 0 } } const loading2 = (isLoading) => { isFetching.value = isLoading isFinished.value = !isLoading } if (timeout) timer2 = useTimeoutFn(abort, timeout, { immediate: false }) const execute = async (throwOnFailed = false) => { var _a22 loading2(true) error2.value = null statusCode.value = null aborted.value = false if (supportsAbort) { abort() controller = new AbortController() controller.signal.onabort = () => (aborted.value = true) fetchOptions = __spreadProps$3(__spreadValues$d({}, fetchOptions), { signal: controller.signal, }) } const defaultFetchOptions = { method: config2.method, headers: {}, } if (config2.payload) { const headers = headersToObject(defaultFetchOptions.headers) if (config2.payloadType) headers['Content-Type'] = (_a22 = payloadMapping[config2.payloadType]) != null ? _a22 : config2.payloadType const payload = resolveUnref(config2.payload) defaultFetchOptions.body = config2.payloadType === 'json' ? JSON.stringify(payload) : payload } let isCanceled = false const context2 = { url: resolveUnref(url2), options: __spreadValues$d( __spreadValues$d({}, defaultFetchOptions), fetchOptions ), cancel: () => { isCanceled = true }, } if (options2.beforeFetch) Object.assign(context2, await options2.beforeFetch(context2)) if (isCanceled || !fetch2) { loading2(false) return Promise.resolve(null) } let responseData = null if (timer2) timer2.start() return new Promise((resolve2, reject2) => { var _a3 fetch2( context2.url, __spreadProps$3( __spreadValues$d( __spreadValues$d({}, defaultFetchOptions), context2.options ), { headers: __spreadValues$d( __spreadValues$d( {}, headersToObject(defaultFetchOptions.headers) ), headersToObject( (_a3 = context2.options) == null ? void 0 : _a3.headers ) ), } ) ) .then(async (fetchResponse) => { response.value = fetchResponse statusCode.value = fetchResponse.status responseData = await fetchResponse[config2.type]() if ( options2.afterFetch && statusCode.value >= 200 && statusCode.value < 300 ) ({ data: responseData } = await options2.afterFetch({ data: responseData, response: fetchResponse, })) data2.value = responseData if (!fetchResponse.ok) throw new Error(fetchResponse.statusText) responseEvent.trigger(fetchResponse) return resolve2(fetchResponse) }) .catch(async (fetchError) => { let errorData = fetchError.message || fetchError.name if (options2.onFetchError) ({ data: responseData, error: errorData } = await options2.onFetchError({ data: responseData, error: fetchError, response: response.value, })) data2.value = responseData error2.value = errorData errorEvent.trigger(fetchError) if (throwOnFailed) return reject2(fetchError) return resolve2(null) }) .finally(() => { loading2(false) if (timer2) timer2.stop() finallyEvent.trigger(null) }) }) } const refetch = resolveRef(options2.refetch) watch$1([refetch, resolveRef(url2)], ([refetch2]) => refetch2 && execute(), { deep: true, }) const shell = { isFinished, statusCode, response, error: error2, data: data2, isFetching, canAbort, aborted, abort, execute, onFetchResponse: responseEvent.on, onFetchError: errorEvent.on, onFetchFinally: finallyEvent.on, get: setMethod('GET'), put: setMethod('PUT'), post: setMethod('POST'), delete: setMethod('DELETE'), patch: setMethod('PATCH'), head: setMethod('HEAD'), options: setMethod('OPTIONS'), json: setType('json'), text: setType('text'), blob: setType('blob'), arrayBuffer: setType('arrayBuffer'), formData: setType('formData'), } function setMethod(method4) { return (payload, payloadType) => { if (!isFetching.value) { config2.method = method4 config2.payload = payload config2.payloadType = payloadType if (isRef(config2.payload)) { watch$1( [refetch, resolveRef(config2.payload)], ([refetch2]) => refetch2 && execute(), { deep: true } ) } const rawPayload = resolveUnref(config2.payload) if ( !payloadType && rawPayload && Object.getPrototypeOf(rawPayload) === Object.prototype && !(rawPayload instanceof FormData) ) config2.payloadType = 'json' return __spreadProps$3(__spreadValues$d({}, shell), { then(onFulfilled, onRejected) { return waitUntilFinished().then(onFulfilled, onRejected) }, }) } return void 0 } } function waitUntilFinished() { return new Promise((resolve2, reject2) => { until(isFinished) .toBe(true) .then(() => resolve2(shell)) .catch((error22) => reject2(error22)) }) } function setType(type4) { return () => { if (!isFetching.value) { config2.type = type4 return __spreadProps$3(__spreadValues$d({}, shell), { then(onFulfilled, onRejected) { return waitUntilFinished().then(onFulfilled, onRejected) }, }) } return void 0 } } if (options2.immediate) setTimeout(execute, 0) return __spreadProps$3(__spreadValues$d({}, shell), { then(onFulfilled, onRejected) { return waitUntilFinished().then(onFulfilled, onRejected) }, }) } function joinPaths(start2, end2) { if (!start2.endsWith('/') && !end2.startsWith('/')) return `${start2}/${end2}` return `${start2}${end2}` } var __defProp$c = Object.defineProperty var __getOwnPropSymbols$d = Object.getOwnPropertySymbols var __hasOwnProp$d = Object.prototype.hasOwnProperty var __propIsEnum$d = Object.prototype.propertyIsEnumerable var __defNormalProp$c = (obj, key2, value2) => key2 in obj ? __defProp$c(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$c = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$d.call(b2, prop)) __defNormalProp$c(a2, prop, b2[prop]) if (__getOwnPropSymbols$d) for (var prop of __getOwnPropSymbols$d(b2)) { if (__propIsEnum$d.call(b2, prop)) __defNormalProp$c(a2, prop, b2[prop]) } return a2 } const DEFAULT_OPTIONS = { multiple: true, accept: '*', } function useFileDialog(options2 = {}) { const { document: document2 = defaultDocument } = options2 const files2 = ref(null) let input if (document2) { input = document2.createElement('input') input.type = 'file' input.onchange = (event) => { const result = event.target files2.value = result.files } } const open2 = (localOptions) => { if (!input) return const _options = __spreadValues$c( __spreadValues$c(__spreadValues$c({}, DEFAULT_OPTIONS), options2), localOptions ) input.multiple = _options.multiple input.accept = _options.accept if (hasOwn$d(_options, 'capture')) input.capture = _options.capture input.click() } const reset2 = () => { files2.value = null if (input) input.value = '' } return { files: readonly(files2), open: open2, reset: reset2, } } var __defProp$b = Object.defineProperty var __getOwnPropSymbols$c = Object.getOwnPropertySymbols var __hasOwnProp$c = Object.prototype.hasOwnProperty var __propIsEnum$c = Object.prototype.propertyIsEnumerable var __defNormalProp$b = (obj, key2, value2) => key2 in obj ? __defProp$b(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$b = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$c.call(b2, prop)) __defNormalProp$b(a2, prop, b2[prop]) if (__getOwnPropSymbols$c) for (var prop of __getOwnPropSymbols$c(b2)) { if (__propIsEnum$c.call(b2, prop)) __defNormalProp$b(a2, prop, b2[prop]) } return a2 } function useFileSystemAccess(options2 = {}) { const { window: _window = defaultWindow$1, dataType: dataType2 = 'Text' } = unref(options2) const window2 = _window const isSupported = useSupported( () => window2 && 'showSaveFilePicker' in window2 && 'showOpenFilePicker' in window2 ) const fileHandle = ref() const data2 = ref() const file2 = ref() const fileName = computed(() => { var _a2, _b2 return (_b2 = (_a2 = file2.value) == null ? void 0 : _a2.name) != null ? _b2 : '' }) const fileMIME = computed(() => { var _a2, _b2 return (_b2 = (_a2 = file2.value) == null ? void 0 : _a2.type) != null ? _b2 : '' }) const fileSize = computed(() => { var _a2, _b2 return (_b2 = (_a2 = file2.value) == null ? void 0 : _a2.size) != null ? _b2 : 0 }) const fileLastModified = computed(() => { var _a2, _b2 return (_b2 = (_a2 = file2.value) == null ? void 0 : _a2.lastModified) != null ? _b2 : 0 }) async function open2(_options = {}) { if (!isSupported.value) return const [handle] = await window2.showOpenFilePicker( __spreadValues$b(__spreadValues$b({}, unref(options2)), _options) ) fileHandle.value = handle await updateFile() await updateData() } async function create3(_options = {}) { if (!isSupported.value) return fileHandle.value = await window2.showSaveFilePicker( __spreadValues$b(__spreadValues$b({}, unref(options2)), _options) ) data2.value = void 0 await updateFile() await updateData() } async function save3(_options = {}) { if (!isSupported.value) return if (!fileHandle.value) return saveAs(_options) if (data2.value) { const writableStream = await fileHandle.value.createWritable() await writableStream.write(data2.value) await writableStream.close() } await updateFile() } async function saveAs(_options = {}) { if (!isSupported.value) return fileHandle.value = await window2.showSaveFilePicker( __spreadValues$b(__spreadValues$b({}, unref(options2)), _options) ) if (data2.value) { const writableStream = await fileHandle.value.createWritable() await writableStream.write(data2.value) await writableStream.close() } await updateFile() } async function updateFile() { var _a2 file2.value = await ((_a2 = fileHandle.value) == null ? void 0 : _a2.getFile()) } async function updateData() { var _a2, _b2 if (unref(dataType2) === 'Text') data2.value = await ((_a2 = file2.value) == null ? void 0 : _a2.text()) if (unref(dataType2) === 'ArrayBuffer') data2.value = await ((_b2 = file2.value) == null ? void 0 : _b2.arrayBuffer()) if (unref(dataType2) === 'Blob') data2.value = file2.value } watch$1(() => unref(dataType2), updateData) return { isSupported, data: data2, file: file2, fileName, fileMIME, fileSize, fileLastModified, open: open2, create: create3, save: save3, saveAs, updateData, } } function useFocus(target2, options2 = {}) { const { initialValue = false } = options2 const innerFocused = ref(false) const targetElement = computed(() => unrefElement(target2)) useEventListener(targetElement, 'focus', () => (innerFocused.value = true)) useEventListener(targetElement, 'blur', () => (innerFocused.value = false)) const focused = computed({ get: () => innerFocused.value, set(value2) { var _a2, _b2 if (!value2 && innerFocused.value) (_a2 = targetElement.value) == null ? void 0 : _a2.blur() else if (value2 && !innerFocused.value) (_b2 = targetElement.value) == null ? void 0 : _b2.focus() }, }) watch$1( targetElement, () => { focused.value = initialValue }, { immediate: true, flush: 'post' } ) return { focused } } function useFocusWithin(target2, options2 = {}) { const activeElement = useActiveElement(options2) const targetElement = computed(() => unrefElement(target2)) const focused = computed(() => targetElement.value && activeElement.value ? targetElement.value.contains(activeElement.value) : false ) return { focused } } function useFps(options2) { var _a2 const fps = ref(0) if (typeof performance === 'undefined') return fps const every2 = (_a2 = options2 == null ? void 0 : options2.every) != null ? _a2 : 10 let last2 = performance.now() let ticks = 0 useRafFn(() => { ticks += 1 if (ticks >= every2) { const now2 = performance.now() const diff = now2 - last2 fps.value = Math.round(1e3 / (diff / ticks)) last2 = now2 ticks = 0 } }) return fps } const functionsMap = [ [ 'requestFullscreen', 'exitFullscreen', 'fullscreenElement', 'fullscreenEnabled', 'fullscreenchange', 'fullscreenerror', ], [ 'webkitRequestFullscreen', 'webkitExitFullscreen', 'webkitFullscreenElement', 'webkitFullscreenEnabled', 'webkitfullscreenchange', 'webkitfullscreenerror', ], [ 'webkitRequestFullScreen', 'webkitCancelFullScreen', 'webkitCurrentFullScreenElement', 'webkitCancelFullScreen', 'webkitfullscreenchange', 'webkitfullscreenerror', ], [ 'mozRequestFullScreen', 'mozCancelFullScreen', 'mozFullScreenElement', 'mozFullScreenEnabled', 'mozfullscreenchange', 'mozfullscreenerror', ], [ 'msRequestFullscreen', 'msExitFullscreen', 'msFullscreenElement', 'msFullscreenEnabled', 'MSFullscreenChange', 'MSFullscreenError', ], ] function useFullscreen(target2, options2 = {}) { const { document: document2 = defaultDocument, autoExit = false } = options2 const targetRef = target2 || (document2 == null ? void 0 : document2.querySelector('html')) const isFullscreen = ref(false) let map2 = functionsMap[0] const isSupported = useSupported(() => { if (!document2) { return false } else { for (const m2 of functionsMap) { if (m2[1] in document2) { map2 = m2 return true } } } return false }) const [REQUEST, EXIT, ELEMENT, , EVENT] = map2 async function exit() { if (!isSupported.value) return if (document2 == null ? void 0 : document2[ELEMENT]) await document2[EXIT]() isFullscreen.value = false } async function enter() { if (!isSupported.value) return await exit() const target22 = unrefElement(targetRef) if (target22) { await target22[REQUEST]() isFullscreen.value = true } } async function toggle2() { if (isFullscreen.value) await exit() else await enter() } if (document2) { useEventListener( document2, EVENT, () => { isFullscreen.value = !!(document2 == null ? void 0 : document2[ELEMENT]) }, false ) } if (autoExit) tryOnScopeDispose(exit) return { isSupported, isFullscreen, enter, exit, toggle: toggle2, } } function mapGamepadToXbox360Controller(gamepad) { return computed(() => { if (gamepad.value) { return { buttons: { a: gamepad.value.buttons[0], b: gamepad.value.buttons[1], x: gamepad.value.buttons[2], y: gamepad.value.buttons[3], }, bumper: { left: gamepad.value.buttons[4], right: gamepad.value.buttons[5], }, triggers: { left: gamepad.value.buttons[6], right: gamepad.value.buttons[7], }, stick: { left: { horizontal: gamepad.value.axes[0], vertical: gamepad.value.axes[1], button: gamepad.value.buttons[10], }, right: { horizontal: gamepad.value.axes[2], vertical: gamepad.value.axes[3], button: gamepad.value.buttons[11], }, }, dpad: { up: gamepad.value.buttons[12], down: gamepad.value.buttons[13], left: gamepad.value.buttons[14], right: gamepad.value.buttons[15], }, back: gamepad.value.buttons[8], start: gamepad.value.buttons[9], } } return null }) } function useGamepad(options2 = {}) { const { navigator: navigator2 = defaultNavigator } = options2 const isSupported = useSupported( () => navigator2 && 'getGamepads' in navigator2 ) const gamepads = ref([]) const onConnectedHook = createEventHook() const onDisconnectedHook = createEventHook() const stateFromGamepad = (gamepad) => { const hapticActuators = [] const vibrationActuator = 'vibrationActuator' in gamepad ? gamepad.vibrationActuator : null if (vibrationActuator) hapticActuators.push(vibrationActuator) if (gamepad.hapticActuators) hapticActuators.push(...gamepad.hapticActuators) return { id: gamepad.id, hapticActuators, index: gamepad.index, mapping: gamepad.mapping, connected: gamepad.connected, timestamp: gamepad.timestamp, axes: gamepad.axes.map((axes) => axes), buttons: gamepad.buttons.map((button) => ({ pressed: button.pressed, touched: button.touched, value: button.value, })), } } const updateGamepadState = () => { const _gamepads = (navigator2 == null ? void 0 : navigator2.getGamepads()) || [] for (let i2 = 0; i2 < _gamepads.length; ++i2) { const gamepad = _gamepads[i2] if (gamepad) { const index2 = gamepads.value.findIndex( ({ index: index22 }) => index22 === gamepad.index ) if (index2 > -1) gamepads.value[index2] = stateFromGamepad(gamepad) } } } const { isActive, pause, resume } = useRafFn(updateGamepadState) const onGamepadConnected = (gamepad) => { if (!gamepads.value.some(({ index: index2 }) => index2 === gamepad.index)) { gamepads.value.push(stateFromGamepad(gamepad)) onConnectedHook.trigger(gamepad.index) } resume() } const onGamepadDisconnected = (gamepad) => { gamepads.value = gamepads.value.filter((x2) => x2.index !== gamepad.index) onDisconnectedHook.trigger(gamepad.index) } useEventListener('gamepadconnected', (e2) => onGamepadConnected(e2.gamepad)) useEventListener('gamepaddisconnected', (e2) => onGamepadDisconnected(e2.gamepad) ) tryOnMounted(() => { const _gamepads = (navigator2 == null ? void 0 : navigator2.getGamepads()) || [] if (_gamepads) { for (let i2 = 0; i2 < _gamepads.length; ++i2) { const gamepad = _gamepads[i2] if (gamepad) onGamepadConnected(gamepad) } } }) pause() return { isSupported, onConnected: onConnectedHook.on, onDisconnected: onDisconnectedHook.on, gamepads, pause, resume, isActive, } } function useGeolocation(options2 = {}) { const { enableHighAccuracy = true, maximumAge = 3e4, timeout = 27e3, navigator: navigator2 = defaultNavigator, immediate = true, } = options2 const isSupported = useSupported( () => navigator2 && 'geolocation' in navigator2 ) const locatedAt = ref(null) const error2 = ref(null) const coords = ref({ accuracy: 0, latitude: Infinity, longitude: Infinity, altitude: null, altitudeAccuracy: null, heading: null, speed: null, }) function updatePosition(position2) { locatedAt.value = position2.timestamp coords.value = position2.coords error2.value = null } let watcher function resume() { if (isSupported.value) { watcher = navigator2.geolocation.watchPosition( updatePosition, (err) => (error2.value = err), { enableHighAccuracy, maximumAge, timeout, } ) } } if (immediate) resume() function pause() { if (watcher && navigator2) navigator2.geolocation.clearWatch(watcher) } tryOnScopeDispose(() => { pause() }) return { isSupported, coords, locatedAt, error: error2, resume, pause, } } const defaultEvents$1 = [ 'mousemove', 'mousedown', 'resize', 'keydown', 'touchstart', 'wheel', ] const oneMinute = 6e4 function useIdle(timeout = oneMinute, options2 = {}) { const { initialState = false, listenForVisibilityChange = true, events: events2 = defaultEvents$1, window: window2 = defaultWindow$1, eventFilter = throttleFilter(50), } = options2 const idle = ref(initialState) const lastActive = ref(timestamp$2()) let timer2 const onEvent = createFilterWrapper(eventFilter, () => { idle.value = false lastActive.value = timestamp$2() clearTimeout(timer2) timer2 = setTimeout(() => (idle.value = true), timeout) }) if (window2) { const document2 = window2.document for (const event of events2) useEventListener(window2, event, onEvent, { passive: true }) if (listenForVisibilityChange) { useEventListener(document2, 'visibilitychange', () => { if (!document2.hidden) onEvent() }) } } timer2 = setTimeout(() => (idle.value = true), timeout) return { idle, lastActive } } var __defProp$a = Object.defineProperty var __getOwnPropSymbols$b = Object.getOwnPropertySymbols var __hasOwnProp$b = Object.prototype.hasOwnProperty var __propIsEnum$b = Object.prototype.propertyIsEnumerable var __defNormalProp$a = (obj, key2, value2) => key2 in obj ? __defProp$a(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$a = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$b.call(b2, prop)) __defNormalProp$a(a2, prop, b2[prop]) if (__getOwnPropSymbols$b) for (var prop of __getOwnPropSymbols$b(b2)) { if (__propIsEnum$b.call(b2, prop)) __defNormalProp$a(a2, prop, b2[prop]) } return a2 } async function loadImage(options2) { return new Promise((resolve2, reject2) => { const img = new Image() const { src, srcset, sizes: sizes2 } = options2 img.src = src if (srcset) img.srcset = srcset if (sizes2) img.sizes = sizes2 img.onload = () => resolve2(img) img.onerror = reject2 }) } const useImage = (options2, asyncStateOptions = {}) => { const state2 = useAsyncState( () => loadImage(resolveUnref(options2)), void 0, __spreadValues$a( { resetOnExecute: true, }, asyncStateOptions ) ) watch$1( () => resolveUnref(options2), () => state2.execute(asyncStateOptions.delay), { deep: true } ) return state2 } const ARRIVED_STATE_THRESHOLD_PIXELS = 1 function useScroll(element, options2 = {}) { const { throttle: throttle2 = 0, idle = 200, onStop = noop$6, onScroll = noop$6, offset: offset2 = { left: 0, right: 0, top: 0, bottom: 0, }, eventListenerOptions = { capture: false, passive: true, }, behavior = 'auto', } = options2 const internalX = ref(0) const internalY = ref(0) const x2 = computed({ get() { return internalX.value }, set(x22) { scrollTo(x22, void 0) }, }) const y2 = computed({ get() { return internalY.value }, set(y22) { scrollTo(void 0, y22) }, }) function scrollTo(_x, _y) { var _a2, _b2, _c2 const _element = resolveUnref(element) if (!_element) return ;(_c2 = _element instanceof Document ? document.body : _element) == null ? void 0 : _c2.scrollTo({ top: (_a2 = resolveUnref(_y)) != null ? _a2 : y2.value, left: (_b2 = resolveUnref(_x)) != null ? _b2 : x2.value, behavior: resolveUnref(behavior), }) } const isScrolling = ref(false) const arrivedState = reactive({ left: true, right: false, top: true, bottom: false, }) const directions = reactive({ left: false, right: false, top: false, bottom: false, }) const onScrollEnd = (e2) => { if (!isScrolling.value) return isScrolling.value = false directions.left = false directions.right = false directions.top = false directions.bottom = false onStop(e2) } const onScrollEndDebounced = useDebounceFn(onScrollEnd, throttle2 + idle) const onScrollHandler = (e2) => { const eventTarget = e2.target === document ? e2.target.documentElement : e2.target const scrollLeft = eventTarget.scrollLeft directions.left = scrollLeft < internalX.value directions.right = scrollLeft > internalY.value arrivedState.left = scrollLeft <= 0 + (offset2.left || 0) arrivedState.right = scrollLeft + eventTarget.clientWidth >= eventTarget.scrollWidth - (offset2.right || 0) - ARRIVED_STATE_THRESHOLD_PIXELS internalX.value = scrollLeft let scrollTop = eventTarget.scrollTop if (e2.target === document && !scrollTop) scrollTop = document.body.scrollTop directions.top = scrollTop < internalY.value directions.bottom = scrollTop > internalY.value arrivedState.top = scrollTop <= 0 + (offset2.top || 0) arrivedState.bottom = scrollTop + eventTarget.clientHeight >= eventTarget.scrollHeight - (offset2.bottom || 0) - ARRIVED_STATE_THRESHOLD_PIXELS internalY.value = scrollTop isScrolling.value = true onScrollEndDebounced(e2) onScroll(e2) } useEventListener( element, 'scroll', throttle2 ? useThrottleFn(onScrollHandler, throttle2, true, false) : onScrollHandler, eventListenerOptions ) useEventListener(element, 'scrollend', onScrollEnd, eventListenerOptions) return { x: x2, y: y2, isScrolling, arrivedState, directions, } } var __defProp$9 = Object.defineProperty var __defProps$2 = Object.defineProperties var __getOwnPropDescs$2 = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$a = Object.getOwnPropertySymbols var __hasOwnProp$a = Object.prototype.hasOwnProperty var __propIsEnum$a = Object.prototype.propertyIsEnumerable var __defNormalProp$9 = (obj, key2, value2) => key2 in obj ? __defProp$9(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$9 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$a.call(b2, prop)) __defNormalProp$9(a2, prop, b2[prop]) if (__getOwnPropSymbols$a) for (var prop of __getOwnPropSymbols$a(b2)) { if (__propIsEnum$a.call(b2, prop)) __defNormalProp$9(a2, prop, b2[prop]) } return a2 } var __spreadProps$2 = (a2, b2) => __defProps$2(a2, __getOwnPropDescs$2(b2)) function useInfiniteScroll(element, onLoadMore, options2 = {}) { var _a2, _b2 const direction2 = (_a2 = options2.direction) != null ? _a2 : 'bottom' const state2 = reactive( useScroll( element, __spreadProps$2(__spreadValues$9({}, options2), { offset: __spreadValues$9( { [direction2]: (_b2 = options2.distance) != null ? _b2 : 0, }, options2.offset ), }) ) ) watch$1( () => state2.arrivedState[direction2], async (v4) => { var _a22, _b22 if (v4) { const elem = resolveUnref(element) const previous = { height: (_a22 = elem == null ? void 0 : elem.scrollHeight) != null ? _a22 : 0, width: (_b22 = elem == null ? void 0 : elem.scrollWidth) != null ? _b22 : 0, } await onLoadMore(state2) if (options2.preserveScrollPosition && elem) { nextTick(() => { elem.scrollTo({ top: elem.scrollHeight - previous.height, left: elem.scrollWidth - previous.width, }) }) } } } ) } function useIntersectionObserver(target2, callback, options2 = {}) { const { root: root2, rootMargin = '0px', threshold = 0.1, window: window2 = defaultWindow$1, } = options2 const isSupported = useSupported( () => window2 && 'IntersectionObserver' in window2 ) let cleanup = noop$6 const stopWatch = isSupported.value ? watch$1( () => ({ el: unrefElement(target2), root: unrefElement(root2), }), ({ el: el2, root: root22 }) => { cleanup() if (!el2) return const observer = new IntersectionObserver(callback, { root: root22, rootMargin, threshold, }) observer.observe(el2) cleanup = () => { observer.disconnect() cleanup = noop$6 } }, { immediate: true, flush: 'post' } ) : noop$6 const stop2 = () => { cleanup() stopWatch() } tryOnScopeDispose(stop2) return { isSupported, stop: stop2, } } const defaultEvents = ['mousedown', 'mouseup', 'keydown', 'keyup'] function useKeyModifier(modifier, options2 = {}) { const { events: events2 = defaultEvents, document: document2 = defaultDocument, initial = null, } = options2 const state2 = ref(initial) if (document2) { events2.forEach((listenerEvent) => { useEventListener(document2, listenerEvent, (evt) => { if (typeof evt.getModifierState === 'function') state2.value = evt.getModifierState(modifier) }) }) } return state2 } function useLocalStorage(key2, initialValue, options2 = {}) { const { window: window2 = defaultWindow$1 } = options2 return useStorage( key2, initialValue, window2 == null ? void 0 : window2.localStorage, options2 ) } const DefaultMagicKeysAliasMap = { ctrl: 'control', command: 'meta', cmd: 'meta', option: 'alt', up: 'arrowup', down: 'arrowdown', left: 'arrowleft', right: 'arrowright', } function useMagicKeys(options2 = {}) { const { reactive: useReactive = false, target: target2 = defaultWindow$1, aliasMap = DefaultMagicKeysAliasMap, passive: passive2 = true, onEventFired = noop$6, } = options2 const current2 = reactive(/* @__PURE__ */ new Set()) const obj = { toJSON() { return {} }, current: current2, } const refs = useReactive ? reactive(obj) : obj const metaDeps = /* @__PURE__ */ new Set() const usedKeys = /* @__PURE__ */ new Set() function setRefs(key2, value2) { if (key2 in refs) { if (useReactive) refs[key2] = value2 else refs[key2].value = value2 } } function reset2() { current2.clear() for (const key2 of usedKeys) setRefs(key2, false) } function updateRefs(e2, value2) { var _a2, _b2 const key2 = (_a2 = e2.key) == null ? void 0 : _a2.toLowerCase() const code2 = (_b2 = e2.code) == null ? void 0 : _b2.toLowerCase() const values2 = [code2, key2].filter(Boolean) if (key2) { if (value2) current2.add(key2) else current2.delete(key2) } for (const key22 of values2) { usedKeys.add(key22) setRefs(key22, value2) } if (key2 === 'meta' && !value2) { metaDeps.forEach((key22) => { current2.delete(key22) setRefs(key22, false) }) metaDeps.clear() } else if ( typeof e2.getModifierState === 'function' && e2.getModifierState('Meta') && value2 ) { ;[...current2, ...values2].forEach((key22) => metaDeps.add(key22)) } } useEventListener( target2, 'keydown', (e2) => { updateRefs(e2, true) return onEventFired(e2) }, { passive: passive2 } ) useEventListener( target2, 'keyup', (e2) => { updateRefs(e2, false) return onEventFired(e2) }, { passive: passive2 } ) useEventListener('blur', reset2, { passive: true }) useEventListener('focus', reset2, { passive: true }) const proxy = new Proxy(refs, { get(target22, prop, rec) { if (typeof prop !== 'string') return Reflect.get(target22, prop, rec) prop = prop.toLowerCase() if (prop in aliasMap) prop = aliasMap[prop] if (!(prop in refs)) { if (/[+_-]/.test(prop)) { const keys3 = prop.split(/[+_-]/g).map((i2) => i2.trim()) refs[prop] = computed(() => keys3.every((key2) => unref(proxy[key2]))) } else { refs[prop] = ref(false) } } const r2 = Reflect.get(target22, prop, rec) return useReactive ? unref(r2) : r2 }, }) return proxy } var __defProp$8 = Object.defineProperty var __getOwnPropSymbols$9 = Object.getOwnPropertySymbols var __hasOwnProp$9 = Object.prototype.hasOwnProperty var __propIsEnum$9 = Object.prototype.propertyIsEnumerable var __defNormalProp$8 = (obj, key2, value2) => key2 in obj ? __defProp$8(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$8 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$9.call(b2, prop)) __defNormalProp$8(a2, prop, b2[prop]) if (__getOwnPropSymbols$9) for (var prop of __getOwnPropSymbols$9(b2)) { if (__propIsEnum$9.call(b2, prop)) __defNormalProp$8(a2, prop, b2[prop]) } return a2 } function usingElRef(source2, cb) { if (resolveUnref(source2)) cb(resolveUnref(source2)) } function timeRangeToArray(timeRanges) { let ranges = [] for (let i2 = 0; i2 < timeRanges.length; ++i2) ranges = [...ranges, [timeRanges.start(i2), timeRanges.end(i2)]] return ranges } function tracksToArray(tracks) { return Array.from(tracks).map( ( { label, kind, language, mode: mode2, activeCues, cues, inBandMetadataTrackDispatchType, }, id2 ) => ({ id: id2, label, kind, language, mode: mode2, activeCues, cues, inBandMetadataTrackDispatchType, }) ) } const defaultOptions = { src: '', tracks: [], } function useMediaControls(target2, options2 = {}) { options2 = __spreadValues$8(__spreadValues$8({}, defaultOptions), options2) const { document: document2 = defaultDocument } = options2 const currentTime = ref(0) const duration2 = ref(0) const seeking = ref(false) const volume = ref(1) const waiting = ref(false) const ended = ref(false) const playing = ref(false) const rate = ref(1) const stalled = ref(false) const buffered = ref([]) const tracks = ref([]) const selectedTrack = ref(-1) const isPictureInPicture = ref(false) const muted = ref(false) const supportsPictureInPicture = document2 && 'pictureInPictureEnabled' in document2 const sourceErrorEvent = createEventHook() const disableTrack = (track2) => { usingElRef(target2, (el2) => { if (track2) { const id2 = isNumber$g(track2) ? track2 : track2.id el2.textTracks[id2].mode = 'disabled' } else { for (let i2 = 0; i2 < el2.textTracks.length; ++i2) el2.textTracks[i2].mode = 'disabled' } selectedTrack.value = -1 }) } const enableTrack = (track2, disableTracks = true) => { usingElRef(target2, (el2) => { const id2 = isNumber$g(track2) ? track2 : track2.id if (disableTracks) disableTrack() el2.textTracks[id2].mode = 'showing' selectedTrack.value = id2 }) } const togglePictureInPicture = () => { return new Promise((resolve2, reject2) => { usingElRef(target2, async (el2) => { if (supportsPictureInPicture) { if (!isPictureInPicture.value) { el2.requestPictureInPicture().then(resolve2).catch(reject2) } else { document2.exitPictureInPicture().then(resolve2).catch(reject2) } } }) }) } watchEffect(() => { if (!document2) return const el2 = resolveUnref(target2) if (!el2) return const src = resolveUnref(options2.src) let sources = [] if (!src) return if (isString$e(src)) sources = [{ src }] else if (Array.isArray(src)) sources = src else if (isObject$t(src)) sources = [src] el2.querySelectorAll('source').forEach((e2) => { e2.removeEventListener('error', sourceErrorEvent.trigger) e2.remove() }) sources.forEach(({ src: src2, type: type4 }) => { const source2 = document2.createElement('source') source2.setAttribute('src', src2) source2.setAttribute('type', type4 || '') source2.addEventListener('error', sourceErrorEvent.trigger) el2.appendChild(source2) }) el2.load() }) tryOnScopeDispose(() => { const el2 = resolveUnref(target2) if (!el2) return el2 .querySelectorAll('source') .forEach((e2) => e2.removeEventListener('error', sourceErrorEvent.trigger) ) }) watch$1(volume, (vol) => { const el2 = resolveUnref(target2) if (!el2) return el2.volume = vol }) watch$1(muted, (mute2) => { const el2 = resolveUnref(target2) if (!el2) return el2.muted = mute2 }) watch$1(rate, (rate2) => { const el2 = resolveUnref(target2) if (!el2) return el2.playbackRate = rate2 }) watchEffect(() => { if (!document2) return const textTracks = resolveUnref(options2.tracks) const el2 = resolveUnref(target2) if (!textTracks || !textTracks.length || !el2) return el2.querySelectorAll('track').forEach((e2) => e2.remove()) textTracks.forEach( ({ default: isDefault, kind, label, src, srcLang }, i2) => { const track2 = document2.createElement('track') track2.default = isDefault || false track2.kind = kind track2.label = label track2.src = src track2.srclang = srcLang if (track2.default) selectedTrack.value = i2 el2.appendChild(track2) } ) }) const { ignoreUpdates: ignoreCurrentTimeUpdates } = watchIgnorable( currentTime, (time2) => { const el2 = resolveUnref(target2) if (!el2) return el2.currentTime = time2 } ) const { ignoreUpdates: ignorePlayingUpdates } = watchIgnorable( playing, (isPlaying) => { const el2 = resolveUnref(target2) if (!el2) return isPlaying ? el2.play() : el2.pause() } ) useEventListener(target2, 'timeupdate', () => ignoreCurrentTimeUpdates( () => (currentTime.value = resolveUnref(target2).currentTime) ) ) useEventListener( target2, 'durationchange', () => (duration2.value = resolveUnref(target2).duration) ) useEventListener( target2, 'progress', () => (buffered.value = timeRangeToArray(resolveUnref(target2).buffered)) ) useEventListener(target2, 'seeking', () => (seeking.value = true)) useEventListener(target2, 'seeked', () => (seeking.value = false)) useEventListener(target2, 'waiting', () => (waiting.value = true)) useEventListener(target2, 'playing', () => { waiting.value = false ended.value = false }) useEventListener( target2, 'ratechange', () => (rate.value = resolveUnref(target2).playbackRate) ) useEventListener(target2, 'stalled', () => (stalled.value = true)) useEventListener(target2, 'ended', () => (ended.value = true)) useEventListener(target2, 'pause', () => ignorePlayingUpdates(() => (playing.value = false)) ) useEventListener(target2, 'play', () => ignorePlayingUpdates(() => (playing.value = true)) ) useEventListener( target2, 'enterpictureinpicture', () => (isPictureInPicture.value = true) ) useEventListener( target2, 'leavepictureinpicture', () => (isPictureInPicture.value = false) ) useEventListener(target2, 'volumechange', () => { const el2 = resolveUnref(target2) if (!el2) return volume.value = el2.volume muted.value = el2.muted }) const listeners = [] const stop2 = watch$1([target2], () => { const el2 = resolveUnref(target2) if (!el2) return stop2() listeners[0] = useEventListener( el2.textTracks, 'addtrack', () => (tracks.value = tracksToArray(el2.textTracks)) ) listeners[1] = useEventListener( el2.textTracks, 'removetrack', () => (tracks.value = tracksToArray(el2.textTracks)) ) listeners[2] = useEventListener( el2.textTracks, 'change', () => (tracks.value = tracksToArray(el2.textTracks)) ) }) tryOnScopeDispose(() => listeners.forEach((listener) => listener())) return { currentTime, duration: duration2, waiting, seeking, ended, stalled, buffered, playing, rate, volume, muted, tracks, selectedTrack, enableTrack, disableTrack, supportsPictureInPicture, togglePictureInPicture, isPictureInPicture, onSourceError: sourceErrorEvent.on, } } function useMemoize(resolver, options2) { const initCache = () => { if (options2 == null ? void 0 : options2.cache) return reactive(options2.cache) return reactive(/* @__PURE__ */ new Map()) } const cache2 = initCache() const generateKey = (...args) => (options2 == null ? void 0 : options2.getKey) ? options2.getKey(...args) : JSON.stringify(args) const _loadData = (key2, ...args) => { cache2.set(key2, resolver(...args)) return cache2.get(key2) } const loadData2 = (...args) => _loadData(generateKey(...args), ...args) const deleteData = (...args) => { cache2.delete(generateKey(...args)) } const clearData = () => { cache2.clear() } const memoized = (...args) => { const key2 = generateKey(...args) if (cache2.has(key2)) return cache2.get(key2) return _loadData(key2, ...args) } memoized.load = loadData2 memoized.delete = deleteData memoized.clear = clearData memoized.generateKey = generateKey memoized.cache = cache2 return memoized } function useMemory(options2 = {}) { const memory = ref() const isSupported = useSupported( () => typeof performance !== 'undefined' && 'memory' in performance ) if (isSupported.value) { const { interval = 1e3 } = options2 useIntervalFn( () => { memory.value = performance.memory }, interval, { immediate: options2.immediate, immediateCallback: options2.immediateCallback, } ) } return { isSupported, memory } } function useMounted() { const isMounted = ref(false) onMounted(() => { isMounted.value = true }) return isMounted } function useMouse(options2 = {}) { const { type: type4 = 'page', touch = true, resetOnTouchEnds = false, initialValue = { x: 0, y: 0 }, window: window2 = defaultWindow$1, eventFilter, } = options2 const x2 = ref(initialValue.x) const y2 = ref(initialValue.y) const sourceType = ref(null) const mouseHandler2 = (event) => { if (type4 === 'page') { x2.value = event.pageX y2.value = event.pageY } else if (type4 === 'client') { x2.value = event.clientX y2.value = event.clientY } else if (type4 === 'movement') { x2.value = event.movementX y2.value = event.movementY } sourceType.value = 'mouse' } const reset2 = () => { x2.value = initialValue.x y2.value = initialValue.y } const touchHandler = (event) => { if (event.touches.length > 0) { const touch2 = event.touches[0] if (type4 === 'page') { x2.value = touch2.pageX y2.value = touch2.pageY } else if (type4 === 'client') { x2.value = touch2.clientX y2.value = touch2.clientY } sourceType.value = 'touch' } } const mouseHandlerWrapper = (event) => { return eventFilter === void 0 ? mouseHandler2(event) : eventFilter(() => mouseHandler2(event), {}) } const touchHandlerWrapper = (event) => { return eventFilter === void 0 ? touchHandler(event) : eventFilter(() => touchHandler(event), {}) } if (window2) { useEventListener(window2, 'mousemove', mouseHandlerWrapper, { passive: true, }) useEventListener(window2, 'dragover', mouseHandlerWrapper, { passive: true, }) if (touch && type4 !== 'movement') { useEventListener(window2, 'touchstart', touchHandlerWrapper, { passive: true, }) useEventListener(window2, 'touchmove', touchHandlerWrapper, { passive: true, }) if (resetOnTouchEnds) useEventListener(window2, 'touchend', reset2, { passive: true }) } } return { x: x2, y: y2, sourceType, } } function useMouseInElement(target2, options2 = {}) { const { handleOutside = true, window: window2 = defaultWindow$1 } = options2 const { x: x2, y: y2, sourceType } = useMouse(options2) const targetRef = ref( target2 != null ? target2 : window2 == null ? void 0 : window2.document.body ) const elementX = ref(0) const elementY = ref(0) const elementPositionX = ref(0) const elementPositionY = ref(0) const elementHeight = ref(0) const elementWidth = ref(0) const isOutside = ref(true) let stop2 = () => {} if (window2) { stop2 = watch$1( [targetRef, x2, y2], () => { const el2 = unrefElement(targetRef) if (!el2) return const { left: left2, top: top2, width, height, } = el2.getBoundingClientRect() elementPositionX.value = left2 + window2.pageXOffset elementPositionY.value = top2 + window2.pageYOffset elementHeight.value = height elementWidth.value = width const elX = x2.value - elementPositionX.value const elY = y2.value - elementPositionY.value isOutside.value = width === 0 || height === 0 || elX < 0 || elY < 0 || elX > width || elY > height if (handleOutside || !isOutside.value) { elementX.value = elX elementY.value = elY } }, { immediate: true } ) useEventListener(document, 'mouseleave', () => { isOutside.value = true }) } return { x: x2, y: y2, sourceType, elementX, elementY, elementPositionX, elementPositionY, elementHeight, elementWidth, isOutside, stop: stop2, } } function useMousePressed(options2 = {}) { const { touch = true, drag = true, initialValue = false, window: window2 = defaultWindow$1, } = options2 const pressed = ref(initialValue) const sourceType = ref(null) if (!window2) { return { pressed, sourceType, } } const onPressed = (srcType) => () => { pressed.value = true sourceType.value = srcType } const onReleased = () => { pressed.value = false sourceType.value = null } const target2 = computed(() => unrefElement(options2.target) || window2) useEventListener(target2, 'mousedown', onPressed('mouse'), { passive: true }) useEventListener(window2, 'mouseleave', onReleased, { passive: true }) useEventListener(window2, 'mouseup', onReleased, { passive: true }) if (drag) { useEventListener(target2, 'dragstart', onPressed('mouse'), { passive: true, }) useEventListener(window2, 'drop', onReleased, { passive: true }) useEventListener(window2, 'dragend', onReleased, { passive: true }) } if (touch) { useEventListener(target2, 'touchstart', onPressed('touch'), { passive: true, }) useEventListener(window2, 'touchend', onReleased, { passive: true }) useEventListener(window2, 'touchcancel', onReleased, { passive: true }) } return { pressed, sourceType, } } var __getOwnPropSymbols$8 = Object.getOwnPropertySymbols var __hasOwnProp$8 = Object.prototype.hasOwnProperty var __propIsEnum$8 = Object.prototype.propertyIsEnumerable var __objRest$1 = (source2, exclude) => { var target2 = {} for (var prop in source2) if (__hasOwnProp$8.call(source2, prop) && exclude.indexOf(prop) < 0) target2[prop] = source2[prop] if (source2 != null && __getOwnPropSymbols$8) for (var prop of __getOwnPropSymbols$8(source2)) { if (exclude.indexOf(prop) < 0 && __propIsEnum$8.call(source2, prop)) target2[prop] = source2[prop] } return target2 } function useMutationObserver(target2, callback, options2 = {}) { const _a2 = options2, { window: window2 = defaultWindow$1 } = _a2, mutationOptions = __objRest$1(_a2, ['window']) let observer const isSupported = useSupported( () => window2 && 'MutationObserver' in window2 ) const cleanup = () => { if (observer) { observer.disconnect() observer = void 0 } } const stopWatch = watch$1( () => unrefElement(target2), (el2) => { cleanup() if (isSupported.value && window2 && el2) { observer = new MutationObserver(callback) observer.observe(el2, mutationOptions) } }, { immediate: true } ) const stop2 = () => { cleanup() stopWatch() } tryOnScopeDispose(stop2) return { isSupported, stop: stop2, } } const useNavigatorLanguage = (options2 = {}) => { const { window: window2 = defaultWindow$1 } = options2 const navigator2 = window2 == null ? void 0 : window2.navigator const isSupported = useSupported(() => navigator2 && 'language' in navigator2) const language = ref(navigator2 == null ? void 0 : navigator2.language) useEventListener(window2, 'languagechange', () => { if (navigator2) language.value = navigator2.language }) return { isSupported, language, } } function useNetwork(options2 = {}) { const { window: window2 = defaultWindow$1 } = options2 const navigator2 = window2 == null ? void 0 : window2.navigator const isSupported = useSupported( () => navigator2 && 'connection' in navigator2 ) const isOnline = ref(true) const saveData = ref(false) const offlineAt = ref(void 0) const onlineAt = ref(void 0) const downlink = ref(void 0) const downlinkMax = ref(void 0) const rtt = ref(void 0) const effectiveType = ref(void 0) const type4 = ref('unknown') const connection2 = isSupported.value && navigator2.connection function updateNetworkInformation() { if (!navigator2) return isOnline.value = navigator2.onLine offlineAt.value = isOnline.value ? void 0 : Date.now() onlineAt.value = isOnline.value ? Date.now() : void 0 if (connection2) { downlink.value = connection2.downlink downlinkMax.value = connection2.downlinkMax effectiveType.value = connection2.effectiveType rtt.value = connection2.rtt saveData.value = connection2.saveData type4.value = connection2.type } } if (window2) { useEventListener(window2, 'offline', () => { isOnline.value = false offlineAt.value = Date.now() }) useEventListener(window2, 'online', () => { isOnline.value = true onlineAt.value = Date.now() }) } if (connection2) useEventListener(connection2, 'change', updateNetworkInformation, false) updateNetworkInformation() return { isSupported, isOnline, saveData, offlineAt, onlineAt, downlink, downlinkMax, effectiveType, rtt, type: type4, } } var __defProp$7 = Object.defineProperty var __getOwnPropSymbols$7 = Object.getOwnPropertySymbols var __hasOwnProp$7 = Object.prototype.hasOwnProperty var __propIsEnum$7 = Object.prototype.propertyIsEnumerable var __defNormalProp$7 = (obj, key2, value2) => key2 in obj ? __defProp$7(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$7 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$7.call(b2, prop)) __defNormalProp$7(a2, prop, b2[prop]) if (__getOwnPropSymbols$7) for (var prop of __getOwnPropSymbols$7(b2)) { if (__propIsEnum$7.call(b2, prop)) __defNormalProp$7(a2, prop, b2[prop]) } return a2 } function useNow(options2 = {}) { const { controls: exposeControls = false, interval = 'requestAnimationFrame', } = options2 const now2 = ref(new Date()) const update3 = () => (now2.value = new Date()) const controls = interval === 'requestAnimationFrame' ? useRafFn(update3, { immediate: true }) : useIntervalFn(update3, interval, { immediate: true }) if (exposeControls) { return __spreadValues$7( { now: now2, }, controls ) } else { return now2 } } function useObjectUrl(object4) { const url2 = ref() const release2 = () => { if (url2.value) URL.revokeObjectURL(url2.value) url2.value = void 0 } watch$1( () => unref(object4), (newObject) => { release2() if (newObject) url2.value = URL.createObjectURL(newObject) }, { immediate: true } ) tryOnScopeDispose(release2) return readonly(url2) } function useClamp(value2, min3, max3) { if (isFunction$k(value2) || isReadonly(value2)) return computed(() => clamp$1(resolveUnref(value2), resolveUnref(min3), resolveUnref(max3)) ) const _value = ref(value2) return computed({ get() { return (_value.value = clamp$1( _value.value, resolveUnref(min3), resolveUnref(max3) )) }, set(value22) { _value.value = clamp$1(value22, resolveUnref(min3), resolveUnref(max3)) }, }) } function useOffsetPagination(options2) { const { total: total2 = Infinity, pageSize = 10, page: page2 = 1, onPageChange = noop$6, onPageSizeChange = noop$6, onPageCountChange = noop$6, } = options2 const currentPageSize = useClamp(pageSize, 1, Infinity) const pageCount = computed(() => Math.max(1, Math.ceil(unref(total2) / unref(currentPageSize))) ) const currentPage2 = useClamp(page2, 1, pageCount) const isFirstPage = computed(() => currentPage2.value === 1) const isLastPage = computed(() => currentPage2.value === pageCount.value) if (isRef(page2)) syncRef(page2, currentPage2) if (isRef(pageSize)) syncRef(pageSize, currentPageSize) function prev() { currentPage2.value-- } function next() { currentPage2.value++ } const returnValue = { currentPage: currentPage2, currentPageSize, pageCount, isFirstPage, isLastPage, prev, next, } watch$1(currentPage2, () => { onPageChange(reactive(returnValue)) }) watch$1(currentPageSize, () => { onPageSizeChange(reactive(returnValue)) }) watch$1(pageCount, () => { onPageCountChange(reactive(returnValue)) }) return returnValue } function useOnline(options2 = {}) { const { isOnline } = useNetwork(options2) return isOnline } function usePageLeave(options2 = {}) { const { window: window2 = defaultWindow$1 } = options2 const isLeft = ref(false) const handler = (event) => { if (!window2) return event = event || window2.event const from = event.relatedTarget || event.toElement isLeft.value = !from } if (window2) { useEventListener(window2, 'mouseout', handler, { passive: true }) useEventListener(window2.document, 'mouseleave', handler, { passive: true }) useEventListener(window2.document, 'mouseenter', handler, { passive: true }) } return isLeft } function useParallax(target2, options2 = {}) { const { deviceOrientationTiltAdjust = (i2) => i2, deviceOrientationRollAdjust = (i2) => i2, mouseTiltAdjust = (i2) => i2, mouseRollAdjust = (i2) => i2, window: window2 = defaultWindow$1, } = options2 const orientation = reactive(useDeviceOrientation({ window: window2 })) const { elementX: x2, elementY: y2, elementWidth: width, elementHeight: height, } = useMouseInElement(target2, { handleOutside: false, window: window2 }) const source2 = computed(() => { if ( orientation.isSupported && ((orientation.alpha != null && orientation.alpha !== 0) || (orientation.gamma != null && orientation.gamma !== 0)) ) return 'deviceOrientation' return 'mouse' }) const roll2 = computed(() => { if (source2.value === 'deviceOrientation') { const value2 = -orientation.beta / 90 return deviceOrientationRollAdjust(value2) } else { const value2 = -(y2.value - height.value / 2) / height.value return mouseRollAdjust(value2) } }) const tilt = computed(() => { if (source2.value === 'deviceOrientation') { const value2 = orientation.gamma / 90 return deviceOrientationTiltAdjust(value2) } else { const value2 = (x2.value - width.value / 2) / width.value return mouseTiltAdjust(value2) } }) return { roll: roll2, tilt, source: source2 } } var __defProp$6 = Object.defineProperty var __defProps$1 = Object.defineProperties var __getOwnPropDescs$1 = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$6 = Object.getOwnPropertySymbols var __hasOwnProp$6 = Object.prototype.hasOwnProperty var __propIsEnum$6 = Object.prototype.propertyIsEnumerable var __defNormalProp$6 = (obj, key2, value2) => key2 in obj ? __defProp$6(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$6 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$6.call(b2, prop)) __defNormalProp$6(a2, prop, b2[prop]) if (__getOwnPropSymbols$6) for (var prop of __getOwnPropSymbols$6(b2)) { if (__propIsEnum$6.call(b2, prop)) __defNormalProp$6(a2, prop, b2[prop]) } return a2 } var __spreadProps$1 = (a2, b2) => __defProps$1(a2, __getOwnPropDescs$1(b2)) const defaultState = { x: 0, y: 0, pointerId: 0, pressure: 0, tiltX: 0, tiltY: 0, width: 0, height: 0, twist: 0, pointerType: null, } const keys$h = /* @__PURE__ */ Object.keys(defaultState) function usePointer(options2 = {}) { const { target: target2 = defaultWindow$1 } = options2 const isInside = ref(false) const state2 = ref(options2.initialValue || {}) Object.assign(state2.value, defaultState, state2.value) const handler = (event) => { isInside.value = true if ( options2.pointerTypes && !options2.pointerTypes.includes(event.pointerType) ) return state2.value = objectPick(event, keys$h, false) } if (target2) { useEventListener(target2, 'pointerdown', handler, { passive: true }) useEventListener(target2, 'pointermove', handler, { passive: true }) useEventListener(target2, 'pointerleave', () => (isInside.value = false), { passive: true, }) } return __spreadProps$1(__spreadValues$6({}, toRefs(state2)), { isInside, }) } function usePointerLock(target2, options2 = {}) { const { document: document2 = defaultDocument, pointerLockOptions } = options2 const isSupported = useSupported( () => document2 && 'pointerLockElement' in document2 ) const element = ref() const triggerElement = ref() let targetElement if (isSupported.value) { useEventListener(document2, 'pointerlockchange', () => { var _a2 const currentElement = (_a2 = document2.pointerLockElement) != null ? _a2 : element.value if (targetElement && currentElement === targetElement) { element.value = document2.pointerLockElement if (!element.value) targetElement = triggerElement.value = null } }) useEventListener(document2, 'pointerlockerror', () => { var _a2 const currentElement = (_a2 = document2.pointerLockElement) != null ? _a2 : element.value if (targetElement && currentElement === targetElement) { const action = document2.pointerLockElement ? 'release' : 'acquire' throw new Error(`Failed to ${action} pointer lock.`) } }) } async function lock2(e2, options22) { var _a2 if (!isSupported.value) throw new Error('Pointer Lock API is not supported by your browser.') triggerElement.value = e2 instanceof Event ? e2.currentTarget : null targetElement = e2 instanceof Event ? (_a2 = unrefElement(target2)) != null ? _a2 : triggerElement.value : unrefElement(e2) if (!targetElement) throw new Error('Target element undefined.') targetElement.requestPointerLock( options22 != null ? options22 : pointerLockOptions ) return await until(element).toBe(targetElement) } async function unlock2() { if (!element.value) return false document2.exitPointerLock() await until(element).toBeNull() return true } return { isSupported, element, triggerElement, lock: lock2, unlock: unlock2, } } var SwipeDirection ;(function (SwipeDirection2) { SwipeDirection2['UP'] = 'UP' SwipeDirection2['RIGHT'] = 'RIGHT' SwipeDirection2['DOWN'] = 'DOWN' SwipeDirection2['LEFT'] = 'LEFT' SwipeDirection2['NONE'] = 'NONE' })(SwipeDirection || (SwipeDirection = {})) function useSwipe(target2, options2 = {}) { const { threshold = 50, onSwipe, onSwipeEnd, onSwipeStart, passive: passive2 = true, window: window2 = defaultWindow$1, } = options2 const coordsStart = reactive({ x: 0, y: 0 }) const coordsEnd = reactive({ x: 0, y: 0 }) const diffX = computed(() => coordsStart.x - coordsEnd.x) const diffY = computed(() => coordsStart.y - coordsEnd.y) const { max: max3, abs: abs2 } = Math const isThresholdExceeded = computed( () => max3(abs2(diffX.value), abs2(diffY.value)) >= threshold ) const isSwiping = ref(false) const direction2 = computed(() => { if (!isThresholdExceeded.value) return SwipeDirection.NONE if (abs2(diffX.value) > abs2(diffY.value)) { return diffX.value > 0 ? SwipeDirection.LEFT : SwipeDirection.RIGHT } else { return diffY.value > 0 ? SwipeDirection.UP : SwipeDirection.DOWN } }) const getTouchEventCoords = (e2) => [ e2.touches[0].clientX, e2.touches[0].clientY, ] const updateCoordsStart = (x2, y2) => { coordsStart.x = x2 coordsStart.y = y2 } const updateCoordsEnd = (x2, y2) => { coordsEnd.x = x2 coordsEnd.y = y2 } let listenerOptions const isPassiveEventSupported = checkPassiveEventSupport( window2 == null ? void 0 : window2.document ) if (!passive2) listenerOptions = isPassiveEventSupported ? { passive: false, capture: true } : { capture: true } else listenerOptions = isPassiveEventSupported ? { passive: true } : { capture: false } const onTouchEnd = (e2) => { if (isSwiping.value) onSwipeEnd == null ? void 0 : onSwipeEnd(e2, direction2.value) isSwiping.value = false } const stops = [ useEventListener( target2, 'touchstart', (e2) => { if (listenerOptions.capture && !listenerOptions.passive) e2.preventDefault() const [x2, y2] = getTouchEventCoords(e2) updateCoordsStart(x2, y2) updateCoordsEnd(x2, y2) onSwipeStart == null ? void 0 : onSwipeStart(e2) }, listenerOptions ), useEventListener( target2, 'touchmove', (e2) => { const [x2, y2] = getTouchEventCoords(e2) updateCoordsEnd(x2, y2) if (!isSwiping.value && isThresholdExceeded.value) isSwiping.value = true if (isSwiping.value) onSwipe == null ? void 0 : onSwipe(e2) }, listenerOptions ), useEventListener(target2, 'touchend', onTouchEnd, listenerOptions), useEventListener(target2, 'touchcancel', onTouchEnd, listenerOptions), ] const stop2 = () => stops.forEach((s2) => s2()) return { isPassiveEventSupported, isSwiping, direction: direction2, coordsStart, coordsEnd, lengthX: diffX, lengthY: diffY, stop: stop2, } } function checkPassiveEventSupport(document2) { if (!document2) return false let supportsPassive = false const optionsBlock = { get passive() { supportsPassive = true return false }, } document2.addEventListener('x', noop$6, optionsBlock) document2.removeEventListener('x', noop$6) return supportsPassive } function usePointerSwipe(target2, options2 = {}) { const targetRef = resolveRef(target2) const { threshold = 50, onSwipe, onSwipeEnd, onSwipeStart } = options2 const posStart = reactive({ x: 0, y: 0 }) const updatePosStart = (x2, y2) => { posStart.x = x2 posStart.y = y2 } const posEnd = reactive({ x: 0, y: 0 }) const updatePosEnd = (x2, y2) => { posEnd.x = x2 posEnd.y = y2 } const distanceX = computed(() => posStart.x - posEnd.x) const distanceY = computed(() => posStart.y - posEnd.y) const { max: max3, abs: abs2 } = Math const isThresholdExceeded = computed( () => max3(abs2(distanceX.value), abs2(distanceY.value)) >= threshold ) const isSwiping = ref(false) const isPointerDown = ref(false) const direction2 = computed(() => { if (!isThresholdExceeded.value) return SwipeDirection.NONE if (abs2(distanceX.value) > abs2(distanceY.value)) { return distanceX.value > 0 ? SwipeDirection.LEFT : SwipeDirection.RIGHT } else { return distanceY.value > 0 ? SwipeDirection.UP : SwipeDirection.DOWN } }) const eventIsAllowed = (e2) => { var _a2, _b2, _c2 const isReleasingButton = e2.buttons === 0 const isPrimaryButton = e2.buttons === 1 return (_c2 = (_b2 = (_a2 = options2.pointerTypes) == null ? void 0 : _a2.includes(e2.pointerType)) != null ? _b2 : isReleasingButton || isPrimaryButton) != null ? _c2 : true } const stops = [ useEventListener(target2, 'pointerdown', (e2) => { var _a2, _b2 if (!eventIsAllowed(e2)) return isPointerDown.value = true ;(_b2 = (_a2 = targetRef.value) == null ? void 0 : _a2.style) == null ? void 0 : _b2.setProperty('touch-action', 'none') const eventTarget = e2.target eventTarget == null ? void 0 : eventTarget.setPointerCapture(e2.pointerId) const { clientX: x2, clientY: y2 } = e2 updatePosStart(x2, y2) updatePosEnd(x2, y2) onSwipeStart == null ? void 0 : onSwipeStart(e2) }), useEventListener(target2, 'pointermove', (e2) => { if (!eventIsAllowed(e2)) return if (!isPointerDown.value) return const { clientX: x2, clientY: y2 } = e2 updatePosEnd(x2, y2) if (!isSwiping.value && isThresholdExceeded.value) isSwiping.value = true if (isSwiping.value) onSwipe == null ? void 0 : onSwipe(e2) }), useEventListener(target2, 'pointerup', (e2) => { var _a2, _b2 if (!eventIsAllowed(e2)) return if (isSwiping.value) onSwipeEnd == null ? void 0 : onSwipeEnd(e2, direction2.value) isPointerDown.value = false isSwiping.value = false ;(_b2 = (_a2 = targetRef.value) == null ? void 0 : _a2.style) == null ? void 0 : _b2.setProperty('touch-action', 'initial') }), ] const stop2 = () => stops.forEach((s2) => s2()) return { isSwiping: readonly(isSwiping), direction: readonly(direction2), posStart: readonly(posStart), posEnd: readonly(posEnd), distanceX, distanceY, stop: stop2, } } function usePreferredColorScheme(options2) { const isLight = useMediaQuery('(prefers-color-scheme: light)', options2) const isDark = useMediaQuery('(prefers-color-scheme: dark)', options2) return computed(() => { if (isDark.value) return 'dark' if (isLight.value) return 'light' return 'no-preference' }) } function usePreferredContrast(options2) { const isMore = useMediaQuery('(prefers-contrast: more)', options2) const isLess = useMediaQuery('(prefers-contrast: less)', options2) const isCustom = useMediaQuery('(prefers-contrast: custom)', options2) return computed(() => { if (isMore.value) return 'more' if (isLess.value) return 'less' if (isCustom.value) return 'custom' return 'no-preference' }) } function usePreferredLanguages(options2 = {}) { const { window: window2 = defaultWindow$1 } = options2 if (!window2) return ref(['en']) const navigator2 = window2.navigator const value2 = ref(navigator2.languages) useEventListener(window2, 'languagechange', () => { value2.value = navigator2.languages }) return value2 } function usePreferredReducedMotion(options2) { const isReduced = useMediaQuery('(prefers-reduced-motion: reduce)', options2) return computed(() => { if (isReduced.value) return 'reduce' return 'no-preference' }) } function usePrevious(value2, initialValue) { const previous = shallowRef(initialValue) watch$1( resolveRef(value2), (_2, oldValue) => { previous.value = oldValue }, { flush: 'sync' } ) return readonly(previous) } const useScreenOrientation = (options2 = {}) => { const { window: window2 = defaultWindow$1 } = options2 const isSupported = useSupported( () => window2 && 'screen' in window2 && 'orientation' in window2.screen ) const screenOrientation = isSupported.value ? window2.screen.orientation : {} const orientation = ref(screenOrientation.type) const angle2 = ref(screenOrientation.angle || 0) if (isSupported.value) { useEventListener(window2, 'orientationchange', () => { orientation.value = screenOrientation.type angle2.value = screenOrientation.angle }) } const lockOrientation = (type4) => { if (!isSupported.value) return Promise.reject(new Error('Not supported')) return screenOrientation.lock(type4) } const unlockOrientation = () => { if (isSupported.value) screenOrientation.unlock() } return { isSupported, orientation, angle: angle2, lockOrientation, unlockOrientation, } } const topVarName = '--vueuse-safe-area-top' const rightVarName = '--vueuse-safe-area-right' const bottomVarName = '--vueuse-safe-area-bottom' const leftVarName = '--vueuse-safe-area-left' function useScreenSafeArea() { const top2 = ref('') const right2 = ref('') const bottom2 = ref('') const left2 = ref('') if (isClient) { const topCssVar = useCssVar(topVarName) const rightCssVar = useCssVar(rightVarName) const bottomCssVar = useCssVar(bottomVarName) const leftCssVar = useCssVar(leftVarName) topCssVar.value = 'env(safe-area-inset-top, 0px)' rightCssVar.value = 'env(safe-area-inset-right, 0px)' bottomCssVar.value = 'env(safe-area-inset-bottom, 0px)' leftCssVar.value = 'env(safe-area-inset-left, 0px)' update3() useEventListener('resize', useDebounceFn(update3)) } function update3() { top2.value = getValue$2(topVarName) right2.value = getValue$2(rightVarName) bottom2.value = getValue$2(bottomVarName) left2.value = getValue$2(leftVarName) } return { top: top2, right: right2, bottom: bottom2, left: left2, update: update3, } } function getValue$2(position2) { return getComputedStyle(document.documentElement).getPropertyValue(position2) } function useScriptTag(src, onLoaded = noop$6, options2 = {}) { const { immediate = true, manual = false, type: type4 = 'text/javascript', async = true, crossOrigin, referrerPolicy, noModule, defer: defer2, document: document2 = defaultDocument, attrs = {}, } = options2 const scriptTag2 = ref(null) let _promise = null const loadScript = (waitForScriptLoad) => new Promise((resolve2, reject2) => { const resolveWithElement = (el22) => { scriptTag2.value = el22 resolve2(el22) return el22 } if (!document2) { resolve2(false) return } let shouldAppend = false let el2 = document2.querySelector(`script[src="${resolveUnref(src)}"]`) if (!el2) { el2 = document2.createElement('script') el2.type = type4 el2.async = async el2.src = resolveUnref(src) if (defer2) el2.defer = defer2 if (crossOrigin) el2.crossOrigin = crossOrigin if (noModule) el2.noModule = noModule if (referrerPolicy) el2.referrerPolicy = referrerPolicy Object.entries(attrs).forEach(([name2, value2]) => el2 == null ? void 0 : el2.setAttribute(name2, value2) ) shouldAppend = true } else if (el2.hasAttribute('data-loaded')) { resolveWithElement(el2) } el2.addEventListener('error', (event) => reject2(event)) el2.addEventListener('abort', (event) => reject2(event)) el2.addEventListener('load', () => { el2.setAttribute('data-loaded', 'true') onLoaded(el2) resolveWithElement(el2) }) if (shouldAppend) el2 = document2.head.appendChild(el2) if (!waitForScriptLoad) resolveWithElement(el2) }) const load = (waitForScriptLoad = true) => { if (!_promise) _promise = loadScript(waitForScriptLoad) return _promise } const unload = () => { if (!document2) return _promise = null if (scriptTag2.value) scriptTag2.value = null const el2 = document2.querySelector(`script[src="${resolveUnref(src)}"]`) if (el2) document2.head.removeChild(el2) } if (immediate && !manual) tryOnMounted(load) if (!manual) tryOnUnmounted(unload) return { scriptTag: scriptTag2, load, unload } } function checkOverflowScroll(ele) { const style2 = window.getComputedStyle(ele) if ( style2.overflowX === 'scroll' || style2.overflowY === 'scroll' || (style2.overflowX === 'auto' && ele.clientHeight < ele.scrollHeight) || (style2.overflowY === 'auto' && ele.clientWidth < ele.scrollWidth) ) { return true } else { const parent2 = ele.parentNode if (!parent2 || parent2.tagName === 'BODY') return false return checkOverflowScroll(parent2) } } function preventDefault$1(rawEvent) { const e2 = rawEvent || window.event const _target = e2.target if (checkOverflowScroll(_target)) return false if (e2.touches.length > 1) return true if (e2.preventDefault) e2.preventDefault() return false } function useScrollLock(element, initialState = false) { const isLocked = ref(initialState) let stopTouchMoveListener = null let initialOverflow watch$1( resolveRef(element), (el2) => { if (el2) { const ele = el2 initialOverflow = ele.style.overflow if (isLocked.value) ele.style.overflow = 'hidden' } }, { immediate: true, } ) const lock2 = () => { const ele = resolveUnref(element) if (!ele || isLocked.value) return if (isIOS) { stopTouchMoveListener = useEventListener( ele, 'touchmove', (e2) => { preventDefault$1(e2) }, { passive: false } ) } ele.style.overflow = 'hidden' isLocked.value = true } const unlock2 = () => { const ele = resolveUnref(element) if (!ele || !isLocked.value) return isIOS && (stopTouchMoveListener == null ? void 0 : stopTouchMoveListener()) ele.style.overflow = initialOverflow isLocked.value = false } tryOnScopeDispose(unlock2) return computed({ get() { return isLocked.value }, set(v4) { if (v4) lock2() else unlock2() }, }) } function useSessionStorage(key2, initialValue, options2 = {}) { const { window: window2 = defaultWindow$1 } = options2 return useStorage( key2, initialValue, window2 == null ? void 0 : window2.sessionStorage, options2 ) } var __defProp$5 = Object.defineProperty var __getOwnPropSymbols$5 = Object.getOwnPropertySymbols var __hasOwnProp$5 = Object.prototype.hasOwnProperty var __propIsEnum$5 = Object.prototype.propertyIsEnumerable var __defNormalProp$5 = (obj, key2, value2) => key2 in obj ? __defProp$5(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$5 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$5.call(b2, prop)) __defNormalProp$5(a2, prop, b2[prop]) if (__getOwnPropSymbols$5) for (var prop of __getOwnPropSymbols$5(b2)) { if (__propIsEnum$5.call(b2, prop)) __defNormalProp$5(a2, prop, b2[prop]) } return a2 } function useShare(shareOptions = {}, options2 = {}) { const { navigator: navigator2 = defaultNavigator } = options2 const _navigator = navigator2 const isSupported = useSupported(() => _navigator && 'canShare' in _navigator) const share2 = async (overrideOptions = {}) => { if (isSupported.value) { const data2 = __spreadValues$5( __spreadValues$5({}, resolveUnref(shareOptions)), resolveUnref(overrideOptions) ) let granted = true if (data2.files && _navigator.canShare) granted = _navigator.canShare({ files: data2.files }) if (granted) return _navigator.share(data2) } } return { isSupported, share: share2, } } const defaultSortFn = (source2, compareFn) => source2.sort(compareFn) const defaultCompare = (a2, b2) => a2 - b2 function useSorted(...args) { var _a2, _b2, _c2, _d const [source2] = args let compareFn = defaultCompare let options2 = {} if (args.length === 2) { if (typeof args[1] === 'object') { options2 = args[1] compareFn = (_a2 = options2.compareFn) != null ? _a2 : defaultCompare } else { compareFn = (_b2 = args[1]) != null ? _b2 : defaultCompare } } else if (args.length > 2) { compareFn = (_c2 = args[1]) != null ? _c2 : defaultCompare options2 = (_d = args[2]) != null ? _d : {} } const { dirty = false, sortFn = defaultSortFn } = options2 if (!dirty) return computed(() => sortFn([...unref(source2)], compareFn)) watchEffect(() => { const result = sortFn(unref(source2), compareFn) if (isRef(source2)) source2.value = result else source2.splice(0, source2.length, ...result) }) return source2 } function useSpeechRecognition(options2 = {}) { const { interimResults = true, continuous = true, window: window2 = defaultWindow$1, } = options2 const lang = resolveRef(options2.lang || 'en-US') const isListening = ref(false) const isFinal = ref(false) const result = ref('') const error2 = shallowRef(void 0) const toggle2 = (value2 = !isListening.value) => { isListening.value = value2 } const start2 = () => { isListening.value = true } const stop2 = () => { isListening.value = false } const SpeechRecognition = window2 && (window2.SpeechRecognition || window2.webkitSpeechRecognition) const isSupported = useSupported(() => SpeechRecognition) let recognition if (isSupported.value) { recognition = new SpeechRecognition() recognition.continuous = continuous recognition.interimResults = interimResults recognition.lang = unref(lang) recognition.onstart = () => { isFinal.value = false } watch$1(lang, (lang2) => { if (recognition && !isListening.value) recognition.lang = lang2 }) recognition.onresult = (event) => { const transcript = Array.from(event.results) .map((result2) => { isFinal.value = result2.isFinal return result2[0] }) .map((result2) => result2.transcript) .join('') result.value = transcript error2.value = void 0 } recognition.onerror = (event) => { error2.value = event } recognition.onend = () => { isListening.value = false recognition.lang = unref(lang) } watch$1(isListening, () => { if (isListening.value) recognition.start() else recognition.stop() }) } tryOnScopeDispose(() => { isListening.value = false }) return { isSupported, isListening, isFinal, recognition, result, error: error2, toggle: toggle2, start: start2, stop: stop2, } } function useSpeechSynthesis(text2, options2 = {}) { const { pitch = 1, rate = 1, volume = 1, window: window2 = defaultWindow$1, } = options2 const synth = window2 && window2.speechSynthesis const isSupported = useSupported(() => synth) const isPlaying = ref(false) const status = ref('init') const spokenText = resolveRef(text2 || '') const lang = resolveRef(options2.lang || 'en-US') const error2 = shallowRef(void 0) const toggle2 = (value2 = !isPlaying.value) => { isPlaying.value = value2 } const bindEventsForUtterance = (utterance2) => { utterance2.lang = unref(lang) utterance2.voice = unref(options2.voice) || null utterance2.pitch = pitch utterance2.rate = rate utterance2.volume = volume utterance2.onstart = () => { isPlaying.value = true status.value = 'play' } utterance2.onpause = () => { isPlaying.value = false status.value = 'pause' } utterance2.onresume = () => { isPlaying.value = true status.value = 'play' } utterance2.onend = () => { isPlaying.value = false status.value = 'end' } utterance2.onerror = (event) => { error2.value = event } } const utterance = computed(() => { isPlaying.value = false status.value = 'init' const newUtterance = new SpeechSynthesisUtterance(spokenText.value) bindEventsForUtterance(newUtterance) return newUtterance }) const speak = () => { synth.cancel() utterance && synth.speak(utterance.value) } const stop2 = () => { synth.cancel() isPlaying.value = false } if (isSupported.value) { bindEventsForUtterance(utterance.value) watch$1(lang, (lang2) => { if (utterance.value && !isPlaying.value) utterance.value.lang = lang2 }) if (options2.voice) { watch$1(options2.voice, () => { synth.cancel() }) } watch$1(isPlaying, () => { if (isPlaying.value) synth.resume() else synth.pause() }) } tryOnScopeDispose(() => { isPlaying.value = false }) return { isSupported, isPlaying, status, utterance, error: error2, stop: stop2, toggle: toggle2, speak, } } function useStepper(steps, initialStep) { const stepsRef = ref(steps) const stepNames = computed(() => Array.isArray(stepsRef.value) ? stepsRef.value : Object.keys(stepsRef.value) ) const index2 = ref( stepNames.value.indexOf( initialStep != null ? initialStep : stepNames.value[0] ) ) const current2 = computed(() => at2(index2.value)) const isFirst = computed(() => index2.value === 0) const isLast = computed(() => index2.value === stepNames.value.length - 1) const next = computed(() => stepNames.value[index2.value + 1]) const previous = computed(() => stepNames.value[index2.value - 1]) function at2(index22) { if (Array.isArray(stepsRef.value)) return stepsRef.value[index22] return stepsRef.value[stepNames.value[index22]] } function get3(step) { if (!stepNames.value.includes(step)) return return at2(stepNames.value.indexOf(step)) } function goTo(step) { if (stepNames.value.includes(step)) index2.value = stepNames.value.indexOf(step) } function goToNext() { if (isLast.value) return index2.value++ } function goToPrevious() { if (isFirst.value) return index2.value-- } function goBackTo(step) { if (isAfter(step)) goTo(step) } function isNext(step) { return stepNames.value.indexOf(step) === index2.value + 1 } function isPrevious(step) { return stepNames.value.indexOf(step) === index2.value - 1 } function isCurrent(step) { return stepNames.value.indexOf(step) === index2.value } function isBefore(step) { return index2.value < stepNames.value.indexOf(step) } function isAfter(step) { return index2.value > stepNames.value.indexOf(step) } return { steps: stepsRef, stepNames, index: index2, current: current2, next, previous, isFirst, isLast, at: at2, get: get3, goTo, goToNext, goToPrevious, goBackTo, isNext, isPrevious, isCurrent, isBefore, isAfter, } } var __defProp$4 = Object.defineProperty var __getOwnPropSymbols$4 = Object.getOwnPropertySymbols var __hasOwnProp$4 = Object.prototype.hasOwnProperty var __propIsEnum$4 = Object.prototype.propertyIsEnumerable var __defNormalProp$4 = (obj, key2, value2) => key2 in obj ? __defProp$4(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$4 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$4.call(b2, prop)) __defNormalProp$4(a2, prop, b2[prop]) if (__getOwnPropSymbols$4) for (var prop of __getOwnPropSymbols$4(b2)) { if (__propIsEnum$4.call(b2, prop)) __defNormalProp$4(a2, prop, b2[prop]) } return a2 } function useStorageAsync(key2, initialValue, storage2, options2 = {}) { var _a2 const { flush: flush2 = 'pre', deep = true, listenToStorageChanges = true, writeDefaults = true, mergeDefaults = false, shallow, window: window2 = defaultWindow$1, eventFilter, onError = (e2) => { console.error(e2) }, } = options2 const rawInit = resolveUnref(initialValue) const type4 = guessSerializerType(rawInit) const data2 = (shallow ? shallowRef : ref)(initialValue) const serializer = (_a2 = options2.serializer) != null ? _a2 : StorageSerializers[type4] if (!storage2) { try { storage2 = getSSRHandler('getDefaultStorage', () => { var _a22 return (_a22 = defaultWindow$1) == null ? void 0 : _a22.localStorage })() } catch (e2) { onError(e2) } } async function read2(event) { if (!storage2 || (event && event.key !== key2)) return try { const rawValue = event ? event.newValue : await storage2.getItem(key2) if (rawValue == null) { data2.value = rawInit if (writeDefaults && rawInit !== null) await storage2.setItem(key2, await serializer.write(rawInit)) } else if (mergeDefaults) { const value2 = await serializer.read(rawValue) if (isFunction$k(mergeDefaults)) data2.value = mergeDefaults(value2, rawInit) else if (type4 === 'object' && !Array.isArray(value2)) data2.value = __spreadValues$4(__spreadValues$4({}, rawInit), value2) else data2.value = value2 } else { data2.value = await serializer.read(rawValue) } } catch (e2) { onError(e2) } } read2() if (window2 && listenToStorageChanges) useEventListener(window2, 'storage', (e2) => setTimeout(() => read2(e2), 0)) if (storage2) { watchWithFilter( data2, async () => { try { if (data2.value == null) await storage2.removeItem(key2) else await storage2.setItem(key2, await serializer.write(data2.value)) } catch (e2) { onError(e2) } }, { flush: flush2, deep, eventFilter, } ) } return data2 } let _id = 0 function useStyleTag(css2, options2 = {}) { const isLoaded = ref(false) const { document: document2 = defaultDocument, immediate = true, manual = false, id: id2 = `vueuse_styletag_${++_id}`, } = options2 const cssRef = ref(css2) let stop2 = () => {} const load = () => { if (!document2) return const el2 = document2.getElementById(id2) || document2.createElement('style') if (!el2.isConnected) { el2.type = 'text/css' el2.id = id2 if (options2.media) el2.media = options2.media document2.head.appendChild(el2) } if (isLoaded.value) return stop2 = watch$1( cssRef, (value2) => { el2.textContent = value2 }, { immediate: true } ) isLoaded.value = true } const unload = () => { if (!document2 || !isLoaded.value) return stop2() document2.head.removeChild(document2.getElementById(id2)) isLoaded.value = false } if (immediate && !manual) tryOnMounted(load) if (!manual) tryOnScopeDispose(unload) return { id: id2, css: cssRef, unload, load, isLoaded: readonly(isLoaded), } } function useTemplateRefsList() { const refs = ref([]) refs.value.set = (el2) => { if (el2) refs.value.push(el2) } onBeforeUpdate(() => { refs.value.length = 0 }) return refs } function useTextDirection(options2 = {}) { const { document: document2 = defaultDocument, selector: selector2 = 'html', observe = false, initialValue = 'ltr', } = options2 function getValue2() { var _a2, _b2 return (_b2 = (_a2 = document2 == null ? void 0 : document2.querySelector(selector2)) == null ? void 0 : _a2.getAttribute('dir')) != null ? _b2 : initialValue } const dir3 = ref(getValue2()) tryOnMounted(() => (dir3.value = getValue2())) if (observe && document2) { useMutationObserver( document2.querySelector(selector2), () => (dir3.value = getValue2()), { attributes: true } ) } return computed({ get() { return dir3.value }, set(v4) { var _a2, _b2 dir3.value = v4 if (!document2) return if (dir3.value) (_a2 = document2.querySelector(selector2)) == null ? void 0 : _a2.setAttribute('dir', dir3.value) else (_b2 = document2.querySelector(selector2)) == null ? void 0 : _b2.removeAttribute('dir') }, }) } function getRangesFromSelection(selection) { var _a2 const rangeCount = (_a2 = selection.rangeCount) != null ? _a2 : 0 const ranges = new Array(rangeCount) for (let i2 = 0; i2 < rangeCount; i2++) { const range3 = selection.getRangeAt(i2) ranges[i2] = range3 } return ranges } function useTextSelection(options2 = {}) { const { window: window2 = defaultWindow$1 } = options2 const selection = ref(null) const text2 = computed(() => { var _a2, _b2 return (_b2 = (_a2 = selection.value) == null ? void 0 : _a2.toString()) != null ? _b2 : '' }) const ranges = computed(() => selection.value ? getRangesFromSelection(selection.value) : [] ) const rects = computed(() => ranges.value.map((range3) => range3.getBoundingClientRect()) ) function onSelectionChange() { selection.value = null if (window2) selection.value = window2.getSelection() } if (window2) useEventListener(window2.document, 'selectionchange', onSelectionChange) return { text: text2, rects, ranges, selection, } } function useTextareaAutosize(options2) { const textarea = ref(options2 == null ? void 0 : options2.element) const input = ref(options2 == null ? void 0 : options2.input) function triggerResize() { var _a2, _b2 if (!textarea.value) return textarea.value.style.height = '1px' textarea.value.style.height = `${ (_a2 = textarea.value) == null ? void 0 : _a2.scrollHeight }px` ;(_b2 = options2 == null ? void 0 : options2.onResize) == null ? void 0 : _b2.call(options2) } watch$1([input, textarea], triggerResize, { immediate: true }) useResizeObserver(textarea, () => triggerResize()) if (options2 == null ? void 0 : options2.watch) watch$1(options2.watch, triggerResize, { immediate: true, deep: true }) return { textarea, input, triggerResize, } } var __defProp$3 = Object.defineProperty var __defProps = Object.defineProperties var __getOwnPropDescs = Object.getOwnPropertyDescriptors var __getOwnPropSymbols$3 = Object.getOwnPropertySymbols var __hasOwnProp$3 = Object.prototype.hasOwnProperty var __propIsEnum$3 = Object.prototype.propertyIsEnumerable var __defNormalProp$3 = (obj, key2, value2) => key2 in obj ? __defProp$3(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$3 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$3.call(b2, prop)) __defNormalProp$3(a2, prop, b2[prop]) if (__getOwnPropSymbols$3) for (var prop of __getOwnPropSymbols$3(b2)) { if (__propIsEnum$3.call(b2, prop)) __defNormalProp$3(a2, prop, b2[prop]) } return a2 } var __spreadProps = (a2, b2) => __defProps(a2, __getOwnPropDescs(b2)) function useThrottledRefHistory(source2, options2 = {}) { const { throttle: throttle2 = 200, trailing = true } = options2 const filter2 = throttleFilter(throttle2, trailing) const history2 = useRefHistory( source2, __spreadProps(__spreadValues$3({}, options2), { eventFilter: filter2 }) ) return __spreadValues$3({}, history2) } var __defProp$2 = Object.defineProperty var __getOwnPropSymbols$2 = Object.getOwnPropertySymbols var __hasOwnProp$2 = Object.prototype.hasOwnProperty var __propIsEnum$2 = Object.prototype.propertyIsEnumerable var __defNormalProp$2 = (obj, key2, value2) => key2 in obj ? __defProp$2(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$2 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$2.call(b2, prop)) __defNormalProp$2(a2, prop, b2[prop]) if (__getOwnPropSymbols$2) for (var prop of __getOwnPropSymbols$2(b2)) { if (__propIsEnum$2.call(b2, prop)) __defNormalProp$2(a2, prop, b2[prop]) } return a2 } var __objRest = (source2, exclude) => { var target2 = {} for (var prop in source2) if (__hasOwnProp$2.call(source2, prop) && exclude.indexOf(prop) < 0) target2[prop] = source2[prop] if (source2 != null && __getOwnPropSymbols$2) for (var prop of __getOwnPropSymbols$2(source2)) { if (exclude.indexOf(prop) < 0 && __propIsEnum$2.call(source2, prop)) target2[prop] = source2[prop] } return target2 } const DEFAULT_UNITS = [ { max: 6e4, value: 1e3, name: 'second' }, { max: 276e4, value: 6e4, name: 'minute' }, { max: 72e6, value: 36e5, name: 'hour' }, { max: 5184e5, value: 864e5, name: 'day' }, { max: 24192e5, value: 6048e5, name: 'week' }, { max: 28512e6, value: 2592e6, name: 'month' }, { max: Infinity, value: 31536e6, name: 'year' }, ] const DEFAULT_MESSAGES = { justNow: 'just now', past: (n2) => (n2.match(/\d/) ? `${n2} ago` : n2), future: (n2) => (n2.match(/\d/) ? `in ${n2}` : n2), month: (n2, past) => n2 === 1 ? past ? 'last month' : 'next month' : `${n2} month${n2 > 1 ? 's' : ''}`, year: (n2, past) => n2 === 1 ? past ? 'last year' : 'next year' : `${n2} year${n2 > 1 ? 's' : ''}`, day: (n2, past) => n2 === 1 ? past ? 'yesterday' : 'tomorrow' : `${n2} day${n2 > 1 ? 's' : ''}`, week: (n2, past) => n2 === 1 ? past ? 'last week' : 'next week' : `${n2} week${n2 > 1 ? 's' : ''}`, hour: (n2) => `${n2} hour${n2 > 1 ? 's' : ''}`, minute: (n2) => `${n2} minute${n2 > 1 ? 's' : ''}`, second: (n2) => `${n2} second${n2 > 1 ? 's' : ''}`, invalid: '', } const DEFAULT_FORMATTER = (date4) => date4.toISOString().slice(0, 10) function useTimeAgo(time2, options2 = {}) { const { controls: exposeControls = false, updateInterval = 3e4 } = options2 const _a2 = useNow({ interval: updateInterval, controls: true }), { now: now2 } = _a2, controls = __objRest(_a2, ['now']) const timeAgo = computed(() => formatTimeAgo(new Date(resolveUnref(time2)), options2, unref(now2.value)) ) if (exposeControls) { return __spreadValues$2( { timeAgo, }, controls ) } else { return timeAgo } } function formatTimeAgo(from, options2 = {}, now2 = Date.now()) { var _a2 const { max: max3, messages: messages2 = DEFAULT_MESSAGES, fullDateFormatter = DEFAULT_FORMATTER, units = DEFAULT_UNITS, showSecond = false, rounding = 'round', } = options2 const roundFn = typeof rounding === 'number' ? (n2) => +n2.toFixed(rounding) : Math[rounding] const diff = +now2 - +from const absDiff = Math.abs(diff) function getValue2(diff2, unit) { return roundFn(Math.abs(diff2) / unit.value) } function format2(diff2, unit) { const val2 = getValue2(diff2, unit) const past = diff2 > 0 const str = applyFormat(unit.name, val2, past) return applyFormat(past ? 'past' : 'future', str, past) } function applyFormat(name2, val2, isPast) { const formatter2 = messages2[name2] if (typeof formatter2 === 'function') return formatter2(val2, isPast) return formatter2.replace('{0}', val2.toString()) } if (absDiff < 6e4 && !showSecond) return messages2.justNow if (typeof max3 === 'number' && absDiff > max3) return fullDateFormatter(new Date(from)) if (typeof max3 === 'string') { const unitMax = (_a2 = units.find((i2) => i2.name === max3)) == null ? void 0 : _a2.max if (unitMax && absDiff > unitMax) return fullDateFormatter(new Date(from)) } for (const [idx, unit] of units.entries()) { const val2 = getValue2(diff, unit) if (val2 <= 0 && units[idx - 1]) return format2(diff, units[idx - 1]) if (absDiff < unit.max) return format2(diff, unit) } return messages2.invalid } function useTimeoutPoll(fn2, interval, timeoutPollOptions) { const { start: start2 } = useTimeoutFn(loop, interval) const isActive = ref(false) async function loop() { if (!isActive.value) return await fn2() start2() } function resume() { if (!isActive.value) { isActive.value = true loop() } } function pause() { isActive.value = false } if (timeoutPollOptions == null ? void 0 : timeoutPollOptions.immediate) resume() tryOnScopeDispose(pause) return { isActive, pause, resume, } } var __defProp$1 = Object.defineProperty var __getOwnPropSymbols$1 = Object.getOwnPropertySymbols var __hasOwnProp$1 = Object.prototype.hasOwnProperty var __propIsEnum$1 = Object.prototype.propertyIsEnumerable var __defNormalProp$1 = (obj, key2, value2) => key2 in obj ? __defProp$1(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues$1 = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp$1.call(b2, prop)) __defNormalProp$1(a2, prop, b2[prop]) if (__getOwnPropSymbols$1) for (var prop of __getOwnPropSymbols$1(b2)) { if (__propIsEnum$1.call(b2, prop)) __defNormalProp$1(a2, prop, b2[prop]) } return a2 } function useTimestamp(options2 = {}) { const { controls: exposeControls = false, offset: offset2 = 0, immediate = true, interval = 'requestAnimationFrame', callback, } = options2 const ts = ref(timestamp$2() + offset2) const update3 = () => (ts.value = timestamp$2() + offset2) const cb = callback ? () => { update3() callback(ts.value) } : update3 const controls = interval === 'requestAnimationFrame' ? useRafFn(cb, { immediate }) : useIntervalFn(cb, interval, { immediate }) if (exposeControls) { return __spreadValues$1( { timestamp: ts, }, controls ) } else { return ts } } function useTitle$1(newTitle = null, options2 = {}) { var _a2, _b2 const { document: document2 = defaultDocument } = options2 const title = resolveRef( (_a2 = newTitle != null ? newTitle : document2 == null ? void 0 : document2.title) != null ? _a2 : null ) const isReadonly2 = newTitle && isFunction$k(newTitle) function format2(t3) { if (!('titleTemplate' in options2)) return t3 const template2 = options2.titleTemplate || '%s' return isFunction$k(template2) ? template2(t3) : unref(template2).replace(/%s/g, t3) } watch$1( title, (t3, o2) => { if (t3 !== o2 && document2) document2.title = format2(isString$e(t3) ? t3 : '') }, { immediate: true } ) if ( options2.observe && !options2.titleTemplate && document2 && !isReadonly2 ) { useMutationObserver( (_b2 = document2.head) == null ? void 0 : _b2.querySelector('title'), () => { if (document2 && document2.title !== title.value) title.value = format2(document2.title) }, { childList: true } ) } return title } var __defProp = Object.defineProperty var __getOwnPropSymbols = Object.getOwnPropertySymbols var __hasOwnProp = Object.prototype.hasOwnProperty var __propIsEnum = Object.prototype.propertyIsEnumerable var __defNormalProp = (obj, key2, value2) => key2 in obj ? __defProp(obj, key2, { enumerable: true, configurable: true, writable: true, value: value2, }) : (obj[key2] = value2) var __spreadValues = (a2, b2) => { for (var prop in b2 || (b2 = {})) if (__hasOwnProp.call(b2, prop)) __defNormalProp(a2, prop, b2[prop]) if (__getOwnPropSymbols) for (var prop of __getOwnPropSymbols(b2)) { if (__propIsEnum.call(b2, prop)) __defNormalProp(a2, prop, b2[prop]) } return a2 } const _TransitionPresets = { easeInSine: [0.12, 0, 0.39, 0], easeOutSine: [0.61, 1, 0.88, 1], easeInOutSine: [0.37, 0, 0.63, 1], easeInQuad: [0.11, 0, 0.5, 0], easeOutQuad: [0.5, 1, 0.89, 1], easeInOutQuad: [0.45, 0, 0.55, 1], easeInCubic: [0.32, 0, 0.67, 0], easeOutCubic: [0.33, 1, 0.68, 1], easeInOutCubic: [0.65, 0, 0.35, 1], easeInQuart: [0.5, 0, 0.75, 0], easeOutQuart: [0.25, 1, 0.5, 1], easeInOutQuart: [0.76, 0, 0.24, 1], easeInQuint: [0.64, 0, 0.78, 0], easeOutQuint: [0.22, 1, 0.36, 1], easeInOutQuint: [0.83, 0, 0.17, 1], easeInExpo: [0.7, 0, 0.84, 0], easeOutExpo: [0.16, 1, 0.3, 1], easeInOutExpo: [0.87, 0, 0.13, 1], easeInCirc: [0.55, 0, 1, 0.45], easeOutCirc: [0, 0.55, 0.45, 1], easeInOutCirc: [0.85, 0, 0.15, 1], easeInBack: [0.36, 0, 0.66, -0.56], easeOutBack: [0.34, 1.56, 0.64, 1], easeInOutBack: [0.68, -0.6, 0.32, 1.6], } const TransitionPresets = __spreadValues( { linear: identity$1, }, _TransitionPresets ) function createEasingFunction([p0, p1, p2, p3]) { const a2 = (a1, a22) => 1 - 3 * a22 + 3 * a1 const b2 = (a1, a22) => 3 * a22 - 6 * a1 const c2 = (a1) => 3 * a1 const calcBezier = (t3, a1, a22) => ((a2(a1, a22) * t3 + b2(a1, a22)) * t3 + c2(a1)) * t3 const getSlope = (t3, a1, a22) => 3 * a2(a1, a22) * t3 * t3 + 2 * b2(a1, a22) * t3 + c2(a1) const getTforX = (x2) => { let aGuessT = x2 for (let i2 = 0; i2 < 4; ++i2) { const currentSlope = getSlope(aGuessT, p0, p2) if (currentSlope === 0) return aGuessT const currentX = calcBezier(aGuessT, p0, p2) - x2 aGuessT -= currentX / currentSlope } return aGuessT } return (x2) => p0 === p1 && p2 === p3 ? x2 : calcBezier(getTforX(x2), p1, p3) } function useTransition(source2, options2 = {}) { const { delay: delay2 = 0, disabled = false, duration: duration2 = 1e3, onFinished = noop$6, onStarted = noop$6, transition = identity$1, } = options2 const currentTransition = computed(() => { const t3 = unref(transition) return isFunction$k(t3) ? t3 : createEasingFunction(t3) }) const sourceValue = computed(() => { const s2 = unref(source2) return isNumber$g(s2) ? s2 : s2.map(unref) }) const sourceVector = computed(() => isNumber$g(sourceValue.value) ? [sourceValue.value] : sourceValue.value ) const outputVector = ref(sourceVector.value.slice(0)) let currentDuration let diffVector let endAt let startAt let startVector const { resume, pause } = useRafFn( () => { const now2 = Date.now() const progress = clamp$1(1 - (endAt - now2) / currentDuration, 0, 1) outputVector.value = startVector.map((val2, i2) => { var _a2 return ( val2 + ((_a2 = diffVector[i2]) != null ? _a2 : 0) * currentTransition.value(progress) ) }) if (progress >= 1) { pause() onFinished() } }, { immediate: false } ) const start2 = () => { pause() currentDuration = unref(duration2) diffVector = outputVector.value.map((n2, i2) => { var _a2, _b2 return ( ((_a2 = sourceVector.value[i2]) != null ? _a2 : 0) - ((_b2 = outputVector.value[i2]) != null ? _b2 : 0) ) }) startVector = outputVector.value.slice(0) startAt = Date.now() endAt = startAt + currentDuration resume() onStarted() } const timeout = useTimeoutFn(start2, delay2, { immediate: false }) watch$1( sourceVector, () => { if (unref(disabled)) return if (unref(delay2) <= 0) start2() else timeout.start() }, { deep: true } ) watch$1( () => unref(disabled), (v4) => { if (v4) { outputVector.value = sourceVector.value.slice(0) pause() } } ) return computed(() => { const targetVector = unref(disabled) ? sourceVector : outputVector return isNumber$g(sourceValue.value) ? targetVector.value[0] : targetVector.value }) } function useUrlSearchParams(mode2 = 'history', options2 = {}) { const { initialValue = {}, removeNullishValues = true, removeFalsyValues = false, write: enableWrite = true, window: window2 = defaultWindow$1, } = options2 if (!window2) return reactive(initialValue) const state2 = reactive({}) function getRawParams() { if (mode2 === 'history') { return window2.location.search || '' } else if (mode2 === 'hash') { const hash2 = window2.location.hash || '' const index2 = hash2.indexOf('?') return index2 > 0 ? hash2.slice(index2) : '' } else { return (window2.location.hash || '').replace(/^#/, '') } } function constructQuery(params2) { const stringified = params2.toString() if (mode2 === 'history') return `${stringified ? `?${stringified}` : ''}${ window2.location.hash || '' }` if (mode2 === 'hash-params') return `${window2.location.search || ''}${ stringified ? `#${stringified}` : '' }` const hash2 = window2.location.hash || '#' const index2 = hash2.indexOf('?') if (index2 > 0) return `${hash2.slice(0, index2)}${stringified ? `?${stringified}` : ''}` return `${hash2}${stringified ? `?${stringified}` : ''}` } function read2() { return new URLSearchParams(getRawParams()) } function updateState(params2) { const unusedKeys = new Set(Object.keys(state2)) for (const key2 of params2.keys()) { const paramsForKey = params2.getAll(key2) state2[key2] = paramsForKey.length > 1 ? paramsForKey : params2.get(key2) || '' unusedKeys.delete(key2) } Array.from(unusedKeys).forEach((key2) => delete state2[key2]) } const { pause, resume } = watchPausable( state2, () => { const params2 = new URLSearchParams('') Object.keys(state2).forEach((key2) => { const mapEntry = state2[key2] if (Array.isArray(mapEntry)) mapEntry.forEach((value2) => params2.append(key2, value2)) else if (removeNullishValues && mapEntry == null) params2.delete(key2) else if (removeFalsyValues && !mapEntry) params2.delete(key2) else params2.set(key2, mapEntry) }) write2(params2) }, { deep: true } ) function write2(params2, shouldUpdate) { pause() if (shouldUpdate) updateState(params2) window2.history.replaceState( window2.history.state, window2.document.title, window2.location.pathname + constructQuery(params2) ) resume() } function onChanged() { if (!enableWrite) return write2(read2(), true) } useEventListener(window2, 'popstate', onChanged, false) if (mode2 !== 'history') useEventListener(window2, 'hashchange', onChanged, false) const initial = read2() if (initial.keys().next().value) updateState(initial) else Object.assign(state2, initialValue) return state2 } function useUserMedia(options2 = {}) { var _a2, _b2 const enabled = ref((_a2 = options2.enabled) != null ? _a2 : false) const autoSwitch = ref((_b2 = options2.autoSwitch) != null ? _b2 : true) const videoDeviceId = ref(options2.videoDeviceId) const audioDeviceId = ref(options2.audioDeviceId) const { navigator: navigator2 = defaultNavigator } = options2 const isSupported = useSupported(() => { var _a22 return (_a22 = navigator2 == null ? void 0 : navigator2.mediaDevices) == null ? void 0 : _a22.getUserMedia }) const stream = shallowRef() function getDeviceOptions(device) { if (device.value === 'none' || device.value === false) return false if (device.value == null) return true return { deviceId: device.value, } } async function _start() { if (!isSupported.value || stream.value) return stream.value = await navigator2.mediaDevices.getUserMedia({ video: getDeviceOptions(videoDeviceId), audio: getDeviceOptions(audioDeviceId), }) return stream.value } async function _stop() { var _a22 ;(_a22 = stream.value) == null ? void 0 : _a22.getTracks().forEach((t3) => t3.stop()) stream.value = void 0 } function stop2() { _stop() enabled.value = false } async function start2() { await _start() if (stream.value) enabled.value = true return stream.value } async function restart() { _stop() return await start2() } watch$1( enabled, (v4) => { if (v4) _start() else _stop() }, { immediate: true } ) watch$1( [videoDeviceId, audioDeviceId], () => { if (autoSwitch.value && stream.value) restart() }, { immediate: true } ) return { isSupported, stream, start: start2, stop: stop2, restart, videoDeviceId, audioDeviceId, enabled, autoSwitch, } } function useVModel(props2, key2, emit2, options2 = {}) { var _a2, _b2, _c2 const { clone: clone2 = false, passive: passive2 = false, eventName, deep = false, defaultValue, } = options2 const vm = getCurrentInstance() const _emit = emit2 || (vm == null ? void 0 : vm.emit) || ((_a2 = vm == null ? void 0 : vm.$emit) == null ? void 0 : _a2.bind(vm)) || ((_c2 = (_b2 = vm == null ? void 0 : vm.proxy) == null ? void 0 : _b2.$emit) == null ? void 0 : _c2.bind(vm == null ? void 0 : vm.proxy)) let event = eventName if (!key2) { { key2 = 'modelValue' } } event = eventName || event || `update:${key2.toString()}` const cloneFn = (val2) => !clone2 ? val2 : isFunction$k(clone2) ? clone2(val2) : cloneFnJSON(val2) const getValue2 = () => isDef$1(props2[key2]) ? cloneFn(props2[key2]) : defaultValue if (passive2) { const initialValue = getValue2() const proxy = ref(initialValue) watch$1( () => props2[key2], (v4) => (proxy.value = cloneFn(v4)) ) watch$1( proxy, (v4) => { if (v4 !== props2[key2] || deep) _emit(event, v4) }, { deep } ) return proxy } else { return computed({ get() { return getValue2() }, set(value2) { _emit(event, value2) }, }) } } function useVModels(props2, emit2, options2 = {}) { const ret = {} for (const key2 in props2) ret[key2] = useVModel(props2, key2, emit2, options2) return ret } function useVibrate(options2) { const { pattern: pattern4 = [], interval = 0, navigator: navigator2 = defaultNavigator, } = options2 || {} const isSupported = useSupported( () => typeof navigator2 !== 'undefined' && 'vibrate' in navigator2 ) const patternRef = resolveRef(pattern4) let intervalControls const vibrate = (pattern22 = patternRef.value) => { if (isSupported.value) navigator2.vibrate(pattern22) } const stop2 = () => { if (isSupported.value) navigator2.vibrate(0) intervalControls == null ? void 0 : intervalControls.pause() } if (interval > 0) { intervalControls = useIntervalFn(vibrate, interval, { immediate: false, immediateCallback: false, }) } return { isSupported, pattern: pattern4, intervalControls, vibrate, stop: stop2, } } function useVirtualList(list2, options2) { const { containerStyle, wrapperProps, scrollTo, calculateRange, currentList, containerRef, } = 'itemHeight' in options2 ? useVerticalVirtualList(options2, list2) : useHorizontalVirtualList(options2, list2) return { list: currentList, scrollTo, containerProps: { ref: containerRef, onScroll: () => { calculateRange() }, style: containerStyle, }, wrapperProps, } } function useVirtualListResources(list2) { const containerRef = ref(null) const size = useElementSize(containerRef) const currentList = ref([]) const source2 = shallowRef(list2) const state2 = ref({ start: 0, end: 10 }) return { state: state2, source: source2, currentList, size, containerRef } } function createGetViewCapacity(state2, source2, itemSize2) { return (containerSize) => { if (typeof itemSize2 === 'number') return Math.ceil(containerSize / itemSize2) const { start: start2 = 0 } = state2.value let sum2 = 0 let capacity = 0 for (let i2 = start2; i2 < source2.value.length; i2++) { const size = itemSize2(i2) sum2 += size capacity = i2 if (sum2 > containerSize) break } return capacity - start2 } } function createGetOffset(source2, itemSize2) { return (scrollDirection) => { if (typeof itemSize2 === 'number') return Math.floor(scrollDirection / itemSize2) + 1 let sum2 = 0 let offset2 = 0 for (let i2 = 0; i2 < source2.value.length; i2++) { const size = itemSize2(i2) sum2 += size if (sum2 >= scrollDirection) { offset2 = i2 break } } return offset2 + 1 } } function createCalculateRange( type4, overscan, getOffset2, getViewCapacity, { containerRef, state: state2, currentList, source: source2 } ) { return () => { const element = containerRef.value if (element) { const offset2 = getOffset2( type4 === 'vertical' ? element.scrollTop : element.scrollLeft ) const viewCapacity = getViewCapacity( type4 === 'vertical' ? element.clientHeight : element.clientWidth ) const from = offset2 - overscan const to = offset2 + viewCapacity + overscan state2.value = { start: from < 0 ? 0 : from, end: to > source2.value.length ? source2.value.length : to, } currentList.value = source2.value .slice(state2.value.start, state2.value.end) .map((ele, index2) => ({ data: ele, index: index2 + state2.value.start, })) } } } function createGetDistance(itemSize2, source2) { return (index2) => { if (typeof itemSize2 === 'number') { const size2 = index2 * itemSize2 return size2 } const size = source2.value .slice(0, index2) .reduce((sum2, _2, i2) => sum2 + itemSize2(i2), 0) return size } } function useWatchForSizes(size, list2, calculateRange) { watch$1([size.width, size.height, list2], () => { calculateRange() }) } function createComputedTotalSize(itemSize2, source2) { return computed(() => { if (typeof itemSize2 === 'number') return source2.value.length * itemSize2 return source2.value.reduce( (sum2, _2, index2) => sum2 + itemSize2(index2), 0 ) }) } const scrollToDictionaryForElementScrollKey = { horizontal: 'scrollLeft', vertical: 'scrollTop', } function createScrollTo(type4, calculateRange, getDistance, containerRef) { return (index2) => { if (containerRef.value) { containerRef.value[scrollToDictionaryForElementScrollKey[type4]] = getDistance(index2) calculateRange() } } } function useHorizontalVirtualList(options2, list2) { const resources = useVirtualListResources(list2) const { state: state2, source: source2, currentList, size, containerRef, } = resources const containerStyle = { overflowX: 'auto' } const { itemWidth, overscan = 5 } = options2 const getViewCapacity = createGetViewCapacity(state2, source2, itemWidth) const getOffset2 = createGetOffset(source2, itemWidth) const calculateRange = createCalculateRange( 'horizontal', overscan, getOffset2, getViewCapacity, resources ) const getDistanceLeft = createGetDistance(itemWidth, source2) const offsetLeft = computed(() => getDistanceLeft(state2.value.start)) const totalWidth = createComputedTotalSize(itemWidth, source2) useWatchForSizes(size, list2, calculateRange) const scrollTo = createScrollTo( 'horizontal', calculateRange, getDistanceLeft, containerRef ) const wrapperProps = computed(() => { return { style: { height: '100%', width: `${totalWidth.value - offsetLeft.value}px`, marginLeft: `${offsetLeft.value}px`, display: 'flex', }, } }) return { scrollTo, calculateRange, wrapperProps, containerStyle, currentList, containerRef, } } function useVerticalVirtualList(options2, list2) { const resources = useVirtualListResources(list2) const { state: state2, source: source2, currentList, size, containerRef, } = resources const containerStyle = { overflowY: 'auto' } const { itemHeight, overscan = 5 } = options2 const getViewCapacity = createGetViewCapacity(state2, source2, itemHeight) const getOffset2 = createGetOffset(source2, itemHeight) const calculateRange = createCalculateRange( 'vertical', overscan, getOffset2, getViewCapacity, resources ) const getDistanceTop = createGetDistance(itemHeight, source2) const offsetTop = computed(() => getDistanceTop(state2.value.start)) const totalHeight = createComputedTotalSize(itemHeight, source2) useWatchForSizes(size, list2, calculateRange) const scrollTo = createScrollTo( 'vertical', calculateRange, getDistanceTop, containerRef ) const wrapperProps = computed(() => { return { style: { width: '100%', height: `${totalHeight.value - offsetTop.value}px`, marginTop: `${offsetTop.value}px`, }, } }) return { calculateRange, scrollTo, containerStyle, wrapperProps, currentList, containerRef, } } const useWakeLock = (options2 = {}) => { const { navigator: navigator2 = defaultNavigator, document: document2 = defaultDocument, } = options2 let wakeLock const isSupported = useSupported(() => navigator2 && 'wakeLock' in navigator2) const isActive = ref(false) async function onVisibilityChange() { if (!isSupported.value || !wakeLock) return if (document2 && document2.visibilityState === 'visible') wakeLock = await navigator2.wakeLock.request('screen') isActive.value = !wakeLock.released } if (document2) useEventListener(document2, 'visibilitychange', onVisibilityChange, { passive: true, }) async function request3(type4) { if (!isSupported.value) return wakeLock = await navigator2.wakeLock.request(type4) isActive.value = !wakeLock.released } async function release2() { if (!isSupported.value || !wakeLock) return await wakeLock.release() isActive.value = !wakeLock.released wakeLock = null } return { isSupported, isActive, request: request3, release: release2, } } const useWebNotification = (defaultOptions2 = {}) => { const { window: window2 = defaultWindow$1 } = defaultOptions2 const isSupported = useSupported(() => !!window2 && 'Notification' in window2) const notification2 = ref(null) const requestPermission = async () => { if (!isSupported.value) return if ('permission' in Notification && Notification.permission !== 'denied') await Notification.requestPermission() } const onClick = createEventHook() const onShow = createEventHook() const onError = createEventHook() const onClose = createEventHook() const show = async (overrides) => { if (!isSupported.value) return await requestPermission() const options2 = Object.assign({}, defaultOptions2, overrides) notification2.value = new Notification(options2.title || '', options2) notification2.value.onclick = (event) => onClick.trigger(event) notification2.value.onshow = (event) => onShow.trigger(event) notification2.value.onerror = (event) => onError.trigger(event) notification2.value.onclose = (event) => onClose.trigger(event) return notification2.value } const close2 = () => { if (notification2.value) notification2.value.close() notification2.value = null } tryOnMounted(async () => { if (isSupported.value) await requestPermission() }) tryOnScopeDispose(close2) if (isSupported.value && window2) { const document2 = window2.document useEventListener(document2, 'visibilitychange', (e2) => { e2.preventDefault() if (document2.visibilityState === 'visible') { close2() } }) } return { isSupported, notification: notification2, show, close: close2, onClick, onShow, onError, onClose, } } const DEFAULT_PING_MESSAGE = 'ping' function resolveNestedOptions(options2) { if (options2 === true) return {} return options2 } function useWebSocket(url2, options2 = {}) { const { onConnected, onDisconnected, onError, onMessage, immediate = true, autoClose = true, protocols = [], } = options2 const data2 = ref(null) const status = ref('CLOSED') const wsRef = ref() const urlRef = resolveRef(url2) let heartbeatPause let heartbeatResume let explicitlyClosed = false let retried = 0 let bufferedData = [] let pongTimeoutWait const close2 = (code2 = 1e3, reason) => { if (!wsRef.value) return explicitlyClosed = true heartbeatPause == null ? void 0 : heartbeatPause() wsRef.value.close(code2, reason) } const _sendBuffer = () => { if (bufferedData.length && wsRef.value && status.value === 'OPEN') { for (const buffer of bufferedData) wsRef.value.send(buffer) bufferedData = [] } } const resetHeartbeat = () => { clearTimeout(pongTimeoutWait) pongTimeoutWait = void 0 } const send = (data22, useBuffer = true) => { if (!wsRef.value || status.value !== 'OPEN') { if (useBuffer) bufferedData.push(data22) return false } _sendBuffer() wsRef.value.send(data22) return true } const _init = () => { if (explicitlyClosed || typeof urlRef.value === 'undefined') return const ws = new WebSocket(urlRef.value, protocols) wsRef.value = ws status.value = 'CONNECTING' ws.onopen = () => { status.value = 'OPEN' onConnected == null ? void 0 : onConnected(ws) heartbeatResume == null ? void 0 : heartbeatResume() _sendBuffer() } ws.onclose = (ev) => { status.value = 'CLOSED' wsRef.value = void 0 onDisconnected == null ? void 0 : onDisconnected(ws, ev) if (!explicitlyClosed && options2.autoReconnect) { const { retries = -1, delay: delay2 = 1e3, onFailed, } = resolveNestedOptions(options2.autoReconnect) retried += 1 if (typeof retries === 'number' && (retries < 0 || retried < retries)) setTimeout(_init, delay2) else if (typeof retries === 'function' && retries()) setTimeout(_init, delay2) else onFailed == null ? void 0 : onFailed() } } ws.onerror = (e2) => { onError == null ? void 0 : onError(ws, e2) } ws.onmessage = (e2) => { if (options2.heartbeat) { resetHeartbeat() const { message: message2 = DEFAULT_PING_MESSAGE } = resolveNestedOptions(options2.heartbeat) if (e2.data === message2) return } data2.value = e2.data onMessage == null ? void 0 : onMessage(ws, e2) } } if (options2.heartbeat) { const { message: message2 = DEFAULT_PING_MESSAGE, interval = 1e3, pongTimeout = 1e3, } = resolveNestedOptions(options2.heartbeat) const { pause, resume } = useIntervalFn( () => { send(message2, false) if (pongTimeoutWait != null) return pongTimeoutWait = setTimeout(() => { close2() }, pongTimeout) }, interval, { immediate: false } ) heartbeatPause = pause heartbeatResume = resume } if (autoClose) { useEventListener(window, 'beforeunload', () => close2()) tryOnScopeDispose(close2) } const open2 = () => { close2() explicitlyClosed = false retried = 0 _init() } if (immediate) watch$1(urlRef, open2, { immediate: true }) return { data: data2, status, close: close2, send, open: open2, ws: wsRef, } } function useWebWorker(arg0, workerOptions, options2) { const { window: window2 = defaultWindow$1 } = options2 != null ? options2 : {} const data2 = ref(null) const worker = shallowRef() const post = function post2(val2) { if (!worker.value) return worker.value.postMessage(val2) } const terminate = function terminate2() { if (!worker.value) return worker.value.terminate() } if (window2) { if (isString$e(arg0)) worker.value = new Worker(arg0, workerOptions) else if (isFunction$k(arg0)) worker.value = arg0() else worker.value = arg0 worker.value.onmessage = (e2) => { data2.value = e2.data } tryOnScopeDispose(() => { if (worker.value) worker.value.terminate() }) } return { data: data2, post, terminate, worker, } } const jobRunner = (userFunc) => (e2) => { const userFuncArgs = e2.data[0] return Promise.resolve(userFunc.apply(void 0, userFuncArgs)) .then((result) => { postMessage(['SUCCESS', result]) }) .catch((error2) => { postMessage(['ERROR', error2]) }) } const depsParser = (deps) => { if (deps.length === 0) return '' const depsString = deps.map((dep) => `'${dep}'`).toString() return `importScripts(${depsString})` } const createWorkerBlobUrl = (fn2, deps) => { const blobCode = `${depsParser(deps)}; onmessage=(${jobRunner})(${fn2})` const blob = new Blob([blobCode], { type: 'text/javascript' }) const url2 = URL.createObjectURL(blob) return url2 } const useWebWorkerFn = (fn2, options2 = {}) => { const { dependencies: dependencies2 = [], timeout, window: window2 = defaultWindow$1, } = options2 const worker = ref() const workerStatus = ref('PENDING') const promise2 = ref({}) const timeoutId = ref() const workerTerminate = (status = 'PENDING') => { if (worker.value && worker.value._url && window2) { worker.value.terminate() URL.revokeObjectURL(worker.value._url) promise2.value = {} worker.value = void 0 window2.clearTimeout(timeoutId.value) workerStatus.value = status } } workerTerminate() tryOnScopeDispose(workerTerminate) const generateWorker = () => { const blobUrl = createWorkerBlobUrl(fn2, dependencies2) const newWorker = new Worker(blobUrl) newWorker._url = blobUrl newWorker.onmessage = (e2) => { const { resolve: resolve2 = () => {}, reject: reject2 = () => {} } = promise2.value const [status, result] = e2.data switch (status) { case 'SUCCESS': resolve2(result) workerTerminate(status) break default: reject2(result) workerTerminate('ERROR') break } } newWorker.onerror = (e2) => { const { reject: reject2 = () => {} } = promise2.value reject2(e2) workerTerminate('ERROR') } if (timeout) { timeoutId.value = setTimeout( () => workerTerminate('TIMEOUT_EXPIRED'), timeout ) } return newWorker } const callWorker = (...fnArgs) => new Promise((resolve2, reject2) => { promise2.value = { resolve: resolve2, reject: reject2, } worker.value && worker.value.postMessage([[...fnArgs]]) workerStatus.value = 'RUNNING' }) const workerFn = (...fnArgs) => { if (workerStatus.value === 'RUNNING') { console.error( '[useWebWorkerFn] You can only run one instance of the worker at a time.' ) return Promise.reject() } worker.value = generateWorker() return callWorker(...fnArgs) } return { workerFn, workerStatus, workerTerminate, } } function useWindowFocus({ window: window2 = defaultWindow$1 } = {}) { if (!window2) return ref(false) const focused = ref(window2.document.hasFocus()) useEventListener(window2, 'blur', () => { focused.value = false }) useEventListener(window2, 'focus', () => { focused.value = true }) return focused } function useWindowScroll({ window: window2 = defaultWindow$1 } = {}) { if (!window2) { return { x: ref(0), y: ref(0), } } const x2 = ref(window2.scrollX) const y2 = ref(window2.scrollY) useEventListener( window2, 'scroll', () => { x2.value = window2.scrollX y2.value = window2.scrollY }, { capture: false, passive: true, } ) return { x: x2, y: y2 } } function useWindowSize(options2 = {}) { const { window: window2 = defaultWindow$1, initialWidth = Infinity, initialHeight = Infinity, listenOrientation = true, includeScrollbar = true, } = options2 const width = ref(initialWidth) const height = ref(initialHeight) const update3 = () => { if (window2) { if (includeScrollbar) { width.value = window2.innerWidth height.value = window2.innerHeight } else { width.value = window2.document.documentElement.clientWidth height.value = window2.document.documentElement.clientHeight } } } update3() tryOnMounted(update3) useEventListener('resize', update3, { passive: true }) if (listenOrientation) useEventListener('orientationchange', update3, { passive: true }) return { width, height } } var index$q = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, DefaultMagicKeysAliasMap, StorageSerializers, get SwipeDirection() { return SwipeDirection }, TransitionPresets, asyncComputed: computedAsync, breakpointsAntDesign, breakpointsBootstrapV5, breakpointsMasterCss, breakpointsQuasar, breakpointsSematic, breakpointsTailwind, breakpointsVuetify, cloneFnJSON, computedAsync, computedInject, createFetch, createUnrefFn, customStorageEventName, defaultDocument, defaultLocation, defaultNavigator, defaultWindow: defaultWindow$1, formatTimeAgo, getSSRHandler, mapGamepadToXbox360Controller, onClickOutside, onKeyDown, onKeyPressed, onKeyStroke, onKeyUp, onLongPress, onStartTyping, setSSRHandler, templateRef, unrefElement, useActiveElement, useAsyncQueue, useAsyncState, useBase64, useBattery, useBluetooth, useBreakpoints, useBroadcastChannel, useBrowserLocation, useCached, useClipboard, useCloned, useColorMode, useConfirmDialog, useCssVar, useCurrentElement, useCycleList, useDark, useDebouncedRefHistory, useDeviceMotion, useDeviceOrientation, useDevicePixelRatio, useDevicesList, useDisplayMedia, useDocumentVisibility, useDraggable, useDropZone, useElementBounding, useElementByPoint, useElementHover, useElementSize, useElementVisibility, useEventBus, useEventListener, useEventSource, useEyeDropper, useFavicon, useFetch, useFileDialog, useFileSystemAccess, useFocus, useFocusWithin, useFps, useFullscreen, useGamepad, useGeolocation, useIdle, useImage, useInfiniteScroll, useIntersectionObserver, useKeyModifier, useLocalStorage, useMagicKeys, useManualRefHistory, useMediaControls, useMediaQuery, useMemoize, useMemory, useMounted, useMouse, useMouseInElement, useMousePressed, useMutationObserver, useNavigatorLanguage, useNetwork, useNow, useObjectUrl, useOffsetPagination, useOnline, usePageLeave, useParallax, usePermission, usePointer, usePointerLock, usePointerSwipe, usePreferredColorScheme, usePreferredContrast, usePreferredDark, usePreferredLanguages, usePreferredReducedMotion, usePrevious, useRafFn, useRefHistory, useResizeObserver, useScreenOrientation, useScreenSafeArea, useScriptTag, useScroll, useScrollLock, useSessionStorage, useShare, useSorted, useSpeechRecognition, useSpeechSynthesis, useStepper, useStorage, useStorageAsync, useStyleTag, useSupported, useSwipe, useTemplateRefsList, useTextDirection, useTextSelection, useTextareaAutosize, useThrottledRefHistory, useTimeAgo, useTimeoutPoll, useTimestamp, useTitle: useTitle$1, useTransition, useUrlSearchParams, useUserMedia, useVModel, useVModels, useVibrate, useVirtualList, useWakeLock, useWebNotification, useWebSocket, useWebWorker, useWebWorkerFn, useWindowFocus, useWindowScroll, useWindowSize, __onlyVue27Plus, __onlyVue3, assert: assert$1, autoResetRef: refAutoReset, bypassFilter, clamp: clamp$1, computedEager, computedWithControl, containsProp, controlledComputed: computedWithControl, controlledRef, createEventHook, createFilterWrapper, createGlobalState, createInjectionState, createReactiveFn: reactify, createSharedComposable, createSingletonPromise, debounceFilter, debouncedRef: refDebounced, debouncedWatch: watchDebounced, directiveHooks, eagerComputed: computedEager, extendRef, formatDate: formatDate$1, get: get$8, hasOwn: hasOwn$d, identity: identity$1, ignorableWatch: watchIgnorable, increaseWithUnit, invoke: invoke$2, isBoolean: isBoolean$4, isClient, isDef: isDef$1, isDefined, isFunction: isFunction$k, isIOS, isNumber: isNumber$g, isObject: isObject$t, isString: isString$e, isWindow: isWindow$2, makeDestructurable, noop: noop$6, normalizeDate, now: now$5, objectPick, pausableFilter, pausableWatch: watchPausable, promiseTimeout, rand, reactify, reactifyObject, reactiveComputed, reactiveOmit, reactivePick, refAutoReset, refDebounced, refDefault, refThrottled, refWithControl, resolveRef, resolveUnref, set: set$6, syncRef, syncRefs, throttleFilter, throttledRef: refThrottled, throttledWatch: watchThrottled, timestamp: timestamp$2, toReactive, toRefs, tryOnBeforeMount, tryOnBeforeUnmount, tryOnMounted, tryOnScopeDispose, tryOnUnmounted, until, useArrayEvery, useArrayFilter, useArrayFind, useArrayFindIndex, useArrayFindLast, useArrayJoin, useArrayMap, useArrayReduce, useArraySome, useArrayUnique, useCounter, useDateFormat, useDebounce: refDebounced, useDebounceFn, useInterval, useIntervalFn, useLastChanged, useThrottle: refThrottled, useThrottleFn, useTimeout, useTimeoutFn, useToNumber, useToString, useToggle, watchArray, watchAtMost, watchDebounced, watchIgnorable, watchOnce, watchPausable, watchThrottled, watchTriggerable, watchWithFilter, whenever, }, Symbol.toStringTag, { value: 'Module' } ) ) function getDevtoolsGlobalHook() { return getTarget().__VUE_DEVTOOLS_GLOBAL_HOOK__ } function getTarget() { return typeof navigator !== 'undefined' && typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : {} } const isProxyAvailable = typeof Proxy === 'function' const HOOK_SETUP = 'devtools-plugin:setup' const HOOK_PLUGIN_SETTINGS_SET = 'plugin:settings:set' let supported let perf function isPerformanceSupported() { var _a2 if (supported !== void 0) { return supported } if (typeof window !== 'undefined' && window.performance) { supported = true perf = window.performance } else if ( typeof global !== 'undefined' && ((_a2 = global.perf_hooks) === null || _a2 === void 0 ? void 0 : _a2.performance) ) { supported = true perf = global.perf_hooks.performance } else { supported = false } return supported } function now$4() { return isPerformanceSupported() ? perf.now() : Date.now() } class ApiProxy { constructor(plugin, hook) { this.target = null this.targetQueue = [] this.onQueue = [] this.plugin = plugin this.hook = hook const defaultSettings = {} if (plugin.settings) { for (const id2 in plugin.settings) { const item2 = plugin.settings[id2] defaultSettings[id2] = item2.defaultValue } } const localSettingsSaveId = `__vue-devtools-plugin-settings__${plugin.id}` let currentSettings = Object.assign({}, defaultSettings) try { const raw = localStorage.getItem(localSettingsSaveId) const data2 = JSON.parse(raw) Object.assign(currentSettings, data2) } catch (e2) {} this.fallbacks = { getSettings() { return currentSettings }, setSettings(value2) { try { localStorage.setItem(localSettingsSaveId, JSON.stringify(value2)) } catch (e2) {} currentSettings = value2 }, now() { return now$4() }, } if (hook) { hook.on(HOOK_PLUGIN_SETTINGS_SET, (pluginId, value2) => { if (pluginId === this.plugin.id) { this.fallbacks.setSettings(value2) } }) } this.proxiedOn = new Proxy( {}, { get: (_target, prop) => { if (this.target) { return this.target.on[prop] } else { return (...args) => { this.onQueue.push({ method: prop, args, }) } } }, } ) this.proxiedTarget = new Proxy( {}, { get: (_target, prop) => { if (this.target) { return this.target[prop] } else if (prop === 'on') { return this.proxiedOn } else if (Object.keys(this.fallbacks).includes(prop)) { return (...args) => { this.targetQueue.push({ method: prop, args, resolve: () => {}, }) return this.fallbacks[prop](...args) } } else { return (...args) => { return new Promise((resolve2) => { this.targetQueue.push({ method: prop, args, resolve: resolve2, }) }) } } }, } ) } async setRealTarget(target2) { this.target = target2 for (const item2 of this.onQueue) { this.target.on[item2.method](...item2.args) } for (const item2 of this.targetQueue) { item2.resolve(await this.target[item2.method](...item2.args)) } } } function setupDevtoolsPlugin(pluginDescriptor, setupFn) { const descriptor = pluginDescriptor const target2 = getTarget() const hook = getDevtoolsGlobalHook() const enableProxy = isProxyAvailable && descriptor.enableEarlyProxy if (hook && (target2.__VUE_DEVTOOLS_PLUGIN_API_AVAILABLE__ || !enableProxy)) { hook.emit(HOOK_SETUP, pluginDescriptor, setupFn) } else { const proxy = enableProxy ? new ApiProxy(descriptor, hook) : null const list2 = (target2.__VUE_DEVTOOLS_PLUGINS__ = target2.__VUE_DEVTOOLS_PLUGINS__ || []) list2.push({ pluginDescriptor: descriptor, setupFn, proxy, }) if (proxy) setupFn(proxy.proxiedTarget) } } /*! * vue-router v4.2.5 * (c) 2023 Eduardo San Martin Morote * @license MIT */ const isBrowser = typeof window !== 'undefined' function isESModule(obj) { return obj.__esModule || obj[Symbol.toStringTag] === 'Module' } const assign$e = Object.assign function applyToParams(fn2, params2) { const newParams = {} for (const key2 in params2) { const value2 = params2[key2] newParams[key2] = isArray$C(value2) ? value2.map(fn2) : fn2(value2) } return newParams } const noop$5 = () => {} const isArray$C = Array.isArray const TRAILING_SLASH_RE = /\/$/ const removeTrailingSlash = (path) => path.replace(TRAILING_SLASH_RE, '') function parseURL(parseQuery2, location2, currentLocation = '/') { let path, query = {}, searchString = '', hash2 = '' const hashPos = location2.indexOf('#') let searchPos = location2.indexOf('?') if (hashPos < searchPos && hashPos >= 0) { searchPos = -1 } if (searchPos > -1) { path = location2.slice(0, searchPos) searchString = location2.slice( searchPos + 1, hashPos > -1 ? hashPos : location2.length ) query = parseQuery2(searchString) } if (hashPos > -1) { path = path || location2.slice(0, hashPos) hash2 = location2.slice(hashPos, location2.length) } path = resolveRelativePath(path != null ? path : location2, currentLocation) return { fullPath: path + (searchString && '?') + searchString + hash2, path, query, hash: hash2, } } function stringifyURL(stringifyQuery2, location2) { const query = location2.query ? stringifyQuery2(location2.query) : '' return location2.path + (query && '?') + query + (location2.hash || '') } function stripBase(pathname, base2) { if (!base2 || !pathname.toLowerCase().startsWith(base2.toLowerCase())) return pathname return pathname.slice(base2.length) || '/' } function isSameRouteLocation(stringifyQuery2, a2, b2) { const aLastIndex = a2.matched.length - 1 const bLastIndex = b2.matched.length - 1 return ( aLastIndex > -1 && aLastIndex === bLastIndex && isSameRouteRecord(a2.matched[aLastIndex], b2.matched[bLastIndex]) && isSameRouteLocationParams(a2.params, b2.params) && stringifyQuery2(a2.query) === stringifyQuery2(b2.query) && a2.hash === b2.hash ) } function isSameRouteRecord(a2, b2) { return (a2.aliasOf || a2) === (b2.aliasOf || b2) } function isSameRouteLocationParams(a2, b2) { if (Object.keys(a2).length !== Object.keys(b2).length) return false for (const key2 in a2) { if (!isSameRouteLocationParamsValue(a2[key2], b2[key2])) return false } return true } function isSameRouteLocationParamsValue(a2, b2) { return isArray$C(a2) ? isEquivalentArray(a2, b2) : isArray$C(b2) ? isEquivalentArray(b2, a2) : a2 === b2 } function isEquivalentArray(a2, b2) { return isArray$C(b2) ? a2.length === b2.length && a2.every((value2, i2) => value2 === b2[i2]) : a2.length === 1 && a2[0] === b2 } function resolveRelativePath(to, from) { if (to.startsWith('/')) return to if (!to) return from const fromSegments = from.split('/') const toSegments = to.split('/') const lastToSegment = toSegments[toSegments.length - 1] if (lastToSegment === '..' || lastToSegment === '.') { toSegments.push('') } let position2 = fromSegments.length - 1 let toPosition let segment for (toPosition = 0; toPosition < toSegments.length; toPosition++) { segment = toSegments[toPosition] if (segment === '.') continue if (segment === '..') { if (position2 > 1) position2-- } else break } return ( fromSegments.slice(0, position2).join('/') + '/' + toSegments .slice(toPosition - (toPosition === toSegments.length ? 1 : 0)) .join('/') ) } var NavigationType ;(function (NavigationType2) { NavigationType2['pop'] = 'pop' NavigationType2['push'] = 'push' })(NavigationType || (NavigationType = {})) var NavigationDirection ;(function (NavigationDirection2) { NavigationDirection2['back'] = 'back' NavigationDirection2['forward'] = 'forward' NavigationDirection2['unknown'] = '' })(NavigationDirection || (NavigationDirection = {})) const START = '' function normalizeBase(base2) { if (!base2) { if (isBrowser) { const baseEl = document.querySelector('base') base2 = (baseEl && baseEl.getAttribute('href')) || '/' base2 = base2.replace(/^\w+:\/\/[^\/]+/, '') } else { base2 = '/' } } if (base2[0] !== '/' && base2[0] !== '#') base2 = '/' + base2 return removeTrailingSlash(base2) } const BEFORE_HASH_RE = /^[^#]+#/ function createHref(base2, location2) { return base2.replace(BEFORE_HASH_RE, '#') + location2 } function getElementPosition(el2, offset2) { const docRect = document.documentElement.getBoundingClientRect() const elRect = el2.getBoundingClientRect() return { behavior: offset2.behavior, left: elRect.left - docRect.left - (offset2.left || 0), top: elRect.top - docRect.top - (offset2.top || 0), } } const computeScrollPosition = () => ({ left: window.pageXOffset, top: window.pageYOffset, }) function scrollToPosition(position2) { let scrollToOptions if ('el' in position2) { const positionEl = position2.el const isIdSelector = typeof positionEl === 'string' && positionEl.startsWith('#') const el2 = typeof positionEl === 'string' ? isIdSelector ? document.getElementById(positionEl.slice(1)) : document.querySelector(positionEl) : positionEl if (!el2) { return } scrollToOptions = getElementPosition(el2, position2) } else { scrollToOptions = position2 } if ('scrollBehavior' in document.documentElement.style) window.scrollTo(scrollToOptions) else { window.scrollTo( scrollToOptions.left != null ? scrollToOptions.left : window.pageXOffset, scrollToOptions.top != null ? scrollToOptions.top : window.pageYOffset ) } } function getScrollKey(path, delta) { const position2 = history.state ? history.state.position - delta : -1 return position2 + path } const scrollPositions = /* @__PURE__ */ new Map() function saveScrollPosition(key2, scrollPosition) { scrollPositions.set(key2, scrollPosition) } function getSavedScrollPosition(key2) { const scroll = scrollPositions.get(key2) scrollPositions.delete(key2) return scroll } let createBaseLocation = () => location.protocol + '//' + location.host function createCurrentLocation(base2, location2) { const { pathname, search: search2, hash: hash2 } = location2 const hashPos = base2.indexOf('#') if (hashPos > -1) { let slicePos = hash2.includes(base2.slice(hashPos)) ? base2.slice(hashPos).length : 1 let pathFromHash = hash2.slice(slicePos) if (pathFromHash[0] !== '/') pathFromHash = '/' + pathFromHash return stripBase(pathFromHash, '') } const path = stripBase(pathname, base2) return path + search2 + hash2 } function useHistoryListeners(base2, historyState, currentLocation, replace2) { let listeners = [] let teardowns = [] let pauseState = null const popStateHandler = ({ state: state2 }) => { const to = createCurrentLocation(base2, location) const from = currentLocation.value const fromState = historyState.value let delta = 0 if (state2) { currentLocation.value = to historyState.value = state2 if (pauseState && pauseState === from) { pauseState = null return } delta = fromState ? state2.position - fromState.position : 0 } else { replace2(to) } listeners.forEach((listener) => { listener(currentLocation.value, from, { delta, type: NavigationType.pop, direction: delta ? delta > 0 ? NavigationDirection.forward : NavigationDirection.back : NavigationDirection.unknown, }) }) } function pauseListeners() { pauseState = currentLocation.value } function listen(callback) { listeners.push(callback) const teardown = () => { const index2 = listeners.indexOf(callback) if (index2 > -1) listeners.splice(index2, 1) } teardowns.push(teardown) return teardown } function beforeUnloadListener() { const { history: history2 } = window if (!history2.state) return history2.replaceState( assign$e({}, history2.state, { scroll: computeScrollPosition() }), '' ) } function destroy2() { for (const teardown of teardowns) teardown() teardowns = [] window.removeEventListener('popstate', popStateHandler) window.removeEventListener('beforeunload', beforeUnloadListener) } window.addEventListener('popstate', popStateHandler) window.addEventListener('beforeunload', beforeUnloadListener, { passive: true, }) return { pauseListeners, listen, destroy: destroy2, } } function buildState( back2, current2, forward, replaced = false, computeScroll = false ) { return { back: back2, current: current2, forward, replaced, position: window.history.length, scroll: computeScroll ? computeScrollPosition() : null, } } function useHistoryStateNavigation(base2) { const { history: history2, location: location2 } = window const currentLocation = { value: createCurrentLocation(base2, location2), } const historyState = { value: history2.state } if (!historyState.value) { changeLocation( currentLocation.value, { back: null, current: currentLocation.value, forward: null, position: history2.length - 1, replaced: true, scroll: null, }, true ) } function changeLocation(to, state2, replace3) { const hashIndex = base2.indexOf('#') const url2 = hashIndex > -1 ? (location2.host && document.querySelector('base') ? base2 : base2.slice(hashIndex)) + to : createBaseLocation() + base2 + to try { history2[replace3 ? 'replaceState' : 'pushState'](state2, '', url2) historyState.value = state2 } catch (err) { { console.error(err) } location2[replace3 ? 'replace' : 'assign'](url2) } } function replace2(to, data2) { const state2 = assign$e( {}, history2.state, buildState(historyState.value.back, to, historyState.value.forward, true), data2, { position: historyState.value.position } ) changeLocation(to, state2, true) currentLocation.value = to } function push2(to, data2) { const currentState = assign$e({}, historyState.value, history2.state, { forward: to, scroll: computeScrollPosition(), }) changeLocation(currentState.current, currentState, true) const state2 = assign$e( {}, buildState(currentLocation.value, to, null), { position: currentState.position + 1 }, data2 ) changeLocation(to, state2, false) currentLocation.value = to } return { location: currentLocation, state: historyState, push: push2, replace: replace2, } } function createWebHistory(base2) { base2 = normalizeBase(base2) const historyNavigation = useHistoryStateNavigation(base2) const historyListeners = useHistoryListeners( base2, historyNavigation.state, historyNavigation.location, historyNavigation.replace ) function go2(delta, triggerListeners = true) { if (!triggerListeners) historyListeners.pauseListeners() history.go(delta) } const routerHistory = assign$e( { location: '', base: base2, go: go2, createHref: createHref.bind(null, base2), }, historyNavigation, historyListeners ) Object.defineProperty(routerHistory, 'location', { enumerable: true, get: () => historyNavigation.location.value, }) Object.defineProperty(routerHistory, 'state', { enumerable: true, get: () => historyNavigation.state.value, }) return routerHistory } function createMemoryHistory(base2 = '') { let listeners = [] let queue2 = [START] let position2 = 0 base2 = normalizeBase(base2) function setLocation(location2) { position2++ if (position2 !== queue2.length) { queue2.splice(position2) } queue2.push(location2) } function triggerListeners(to, from, { direction: direction2, delta }) { const info = { direction: direction2, delta, type: NavigationType.pop, } for (const callback of listeners) { callback(to, from, info) } } const routerHistory = { location: START, state: {}, base: base2, createHref: createHref.bind(null, base2), replace(to) { queue2.splice(position2--, 1) setLocation(to) }, push(to, data2) { setLocation(to) }, listen(callback) { listeners.push(callback) return () => { const index2 = listeners.indexOf(callback) if (index2 > -1) listeners.splice(index2, 1) } }, destroy() { listeners = [] queue2 = [START] position2 = 0 }, go(delta, shouldTrigger = true) { const from = this.location const direction2 = delta < 0 ? NavigationDirection.back : NavigationDirection.forward position2 = Math.max(0, Math.min(position2 + delta, queue2.length - 1)) if (shouldTrigger) { triggerListeners(this.location, from, { direction: direction2, delta, }) } }, } Object.defineProperty(routerHistory, 'location', { enumerable: true, get: () => queue2[position2], }) return routerHistory } function createWebHashHistory(base2) { base2 = location.host ? base2 || location.pathname + location.search : '' if (!base2.includes('#')) base2 += '#' return createWebHistory(base2) } function isRouteLocation(route) { return typeof route === 'string' || (route && typeof route === 'object') } function isRouteName(name2) { return typeof name2 === 'string' || typeof name2 === 'symbol' } const START_LOCATION_NORMALIZED = { path: '/', name: void 0, params: {}, query: {}, hash: '', fullPath: '/', matched: [], meta: {}, redirectedFrom: void 0, } const NavigationFailureSymbol = Symbol('') var NavigationFailureType ;(function (NavigationFailureType2) { NavigationFailureType2[(NavigationFailureType2['aborted'] = 4)] = 'aborted' NavigationFailureType2[(NavigationFailureType2['cancelled'] = 8)] = 'cancelled' NavigationFailureType2[(NavigationFailureType2['duplicated'] = 16)] = 'duplicated' })(NavigationFailureType || (NavigationFailureType = {})) function createRouterError(type4, params2) { { return assign$e( new Error(), { type: type4, [NavigationFailureSymbol]: true, }, params2 ) } } function isNavigationFailure(error2, type4) { return ( error2 instanceof Error && NavigationFailureSymbol in error2 && (type4 == null || !!(error2.type & type4)) ) } const BASE_PARAM_PATTERN = '[^/]+?' const BASE_PATH_PARSER_OPTIONS = { sensitive: false, strict: false, start: true, end: true, } const REGEX_CHARS_RE = /[.+*?^${}()[\]/\\]/g function tokensToParser(segments, extraOptions) { const options2 = assign$e({}, BASE_PATH_PARSER_OPTIONS, extraOptions) const score = [] let pattern4 = options2.start ? '^' : '' const keys3 = [] for (const segment of segments) { const segmentScores = segment.length ? [] : [90] if (options2.strict && !segment.length) pattern4 += '/' for (let tokenIndex = 0; tokenIndex < segment.length; tokenIndex++) { const token = segment[tokenIndex] let subSegmentScore = 40 + (options2.sensitive ? 0.25 : 0) if (token.type === 0) { if (!tokenIndex) pattern4 += '/' pattern4 += token.value.replace(REGEX_CHARS_RE, '\\$&') subSegmentScore += 40 } else if (token.type === 1) { const { value: value2, repeatable, optional, regexp: regexp4 } = token keys3.push({ name: value2, repeatable, optional, }) const re3 = regexp4 ? regexp4 : BASE_PARAM_PATTERN if (re3 !== BASE_PARAM_PATTERN) { subSegmentScore += 10 try { new RegExp(`(${re3})`) } catch (err) { throw new Error( `Invalid custom RegExp for param "${value2}" (${re3}): ` + err.message ) } } let subPattern = repeatable ? `((?:${re3})(?:/(?:${re3}))*)` : `(${re3})` if (!tokenIndex) subPattern = optional && segment.length < 2 ? `(?:/${subPattern})` : '/' + subPattern if (optional) subPattern += '?' pattern4 += subPattern subSegmentScore += 20 if (optional) subSegmentScore += -8 if (repeatable) subSegmentScore += -20 if (re3 === '.*') subSegmentScore += -50 } segmentScores.push(subSegmentScore) } score.push(segmentScores) } if (options2.strict && options2.end) { const i2 = score.length - 1 score[i2][score[i2].length - 1] += 0.7000000000000001 } if (!options2.strict) pattern4 += '/?' if (options2.end) pattern4 += '$' else if (options2.strict) pattern4 += '(?:/|$)' const re2 = new RegExp(pattern4, options2.sensitive ? '' : 'i') function parse2(path) { const match2 = path.match(re2) const params2 = {} if (!match2) return null for (let i2 = 1; i2 < match2.length; i2++) { const value2 = match2[i2] || '' const key2 = keys3[i2 - 1] params2[key2.name] = value2 && key2.repeatable ? value2.split('/') : value2 } return params2 } function stringify2(params2) { let path = '' let avoidDuplicatedSlash = false for (const segment of segments) { if (!avoidDuplicatedSlash || !path.endsWith('/')) path += '/' avoidDuplicatedSlash = false for (const token of segment) { if (token.type === 0) { path += token.value } else if (token.type === 1) { const { value: value2, repeatable, optional } = token const param = value2 in params2 ? params2[value2] : '' if (isArray$C(param) && !repeatable) { throw new Error( `Provided param "${value2}" is an array but it is not repeatable (* or + modifiers)` ) } const text2 = isArray$C(param) ? param.join('/') : param if (!text2) { if (optional) { if (segment.length < 2) { if (path.endsWith('/')) path = path.slice(0, -1) else avoidDuplicatedSlash = true } } else throw new Error(`Missing required param "${value2}"`) } path += text2 } } } return path || '/' } return { re: re2, score, keys: keys3, parse: parse2, stringify: stringify2, } } function compareScoreArray(a2, b2) { let i2 = 0 while (i2 < a2.length && i2 < b2.length) { const diff = b2[i2] - a2[i2] if (diff) return diff i2++ } if (a2.length < b2.length) { return a2.length === 1 && a2[0] === 40 + 40 ? -1 : 1 } else if (a2.length > b2.length) { return b2.length === 1 && b2[0] === 40 + 40 ? 1 : -1 } return 0 } function comparePathParserScore(a2, b2) { let i2 = 0 const aScore = a2.score const bScore = b2.score while (i2 < aScore.length && i2 < bScore.length) { const comp = compareScoreArray(aScore[i2], bScore[i2]) if (comp) return comp i2++ } if (Math.abs(bScore.length - aScore.length) === 1) { if (isLastScoreNegative(aScore)) return 1 if (isLastScoreNegative(bScore)) return -1 } return bScore.length - aScore.length } function isLastScoreNegative(score) { const last2 = score[score.length - 1] return score.length > 0 && last2[last2.length - 1] < 0 } const ROOT_TOKEN = { type: 0, value: '', } const VALID_PARAM_RE = /[a-zA-Z0-9_]/ function tokenizePath(path) { if (!path) return [[]] if (path === '/') return [[ROOT_TOKEN]] if (!path.startsWith('/')) { throw new Error(`Invalid path "${path}"`) } function crash(message2) { throw new Error(`ERR (${state2})/"${buffer}": ${message2}`) } let state2 = 0 let previousState = state2 const tokens = [] let segment function finalizeSegment() { if (segment) tokens.push(segment) segment = [] } let i2 = 0 let char let buffer = '' let customRe = '' function consumeBuffer() { if (!buffer) return if (state2 === 0) { segment.push({ type: 0, value: buffer, }) } else if (state2 === 1 || state2 === 2 || state2 === 3) { if (segment.length > 1 && (char === '*' || char === '+')) crash( `A repeatable param (${buffer}) must be alone in its segment. eg: '/:ids+.` ) segment.push({ type: 1, value: buffer, regexp: customRe, repeatable: char === '*' || char === '+', optional: char === '*' || char === '?', }) } else { crash('Invalid state to consume buffer') } buffer = '' } function addCharToBuffer() { buffer += char } while (i2 < path.length) { char = path[i2++] if (char === '\\' && state2 !== 2) { previousState = state2 state2 = 4 continue } switch (state2) { case 0: if (char === '/') { if (buffer) { consumeBuffer() } finalizeSegment() } else if (char === ':') { consumeBuffer() state2 = 1 } else { addCharToBuffer() } break case 4: addCharToBuffer() state2 = previousState break case 1: if (char === '(') { state2 = 2 } else if (VALID_PARAM_RE.test(char)) { addCharToBuffer() } else { consumeBuffer() state2 = 0 if (char !== '*' && char !== '?' && char !== '+') i2-- } break case 2: if (char === ')') { if (customRe[customRe.length - 1] == '\\') customRe = customRe.slice(0, -1) + char else state2 = 3 } else { customRe += char } break case 3: consumeBuffer() state2 = 0 if (char !== '*' && char !== '?' && char !== '+') i2-- customRe = '' break default: crash('Unknown state') break } } if (state2 === 2) crash(`Unfinished custom RegExp for param "${buffer}"`) consumeBuffer() finalizeSegment() return tokens } function createRouteRecordMatcher(record, parent2, options2) { const parser2 = tokensToParser(tokenizePath(record.path), options2) const matcher = assign$e(parser2, { record, parent: parent2, children: [], alias: [], }) if (parent2) { if (!matcher.record.aliasOf === !parent2.record.aliasOf) parent2.children.push(matcher) } return matcher } function createRouterMatcher(routes2, globalOptions) { const matchers2 = [] const matcherMap = /* @__PURE__ */ new Map() globalOptions = mergeOptions( { strict: false, end: true, sensitive: false }, globalOptions ) function getRecordMatcher(name2) { return matcherMap.get(name2) } function addRoute(record, parent2, originalRecord) { const isRootAdd = !originalRecord const mainNormalizedRecord = normalizeRouteRecord(record) mainNormalizedRecord.aliasOf = originalRecord && originalRecord.record const options2 = mergeOptions(globalOptions, record) const normalizedRecords = [mainNormalizedRecord] if ('alias' in record) { const aliases = typeof record.alias === 'string' ? [record.alias] : record.alias for (const alias of aliases) { normalizedRecords.push( assign$e({}, mainNormalizedRecord, { components: originalRecord ? originalRecord.record.components : mainNormalizedRecord.components, path: alias, aliasOf: originalRecord ? originalRecord.record : mainNormalizedRecord, }) ) } } let matcher let originalMatcher for (const normalizedRecord of normalizedRecords) { const { path } = normalizedRecord if (parent2 && path[0] !== '/') { const parentPath = parent2.record.path const connectingSlash = parentPath[parentPath.length - 1] === '/' ? '' : '/' normalizedRecord.path = parent2.record.path + (path && connectingSlash + path) } matcher = createRouteRecordMatcher(normalizedRecord, parent2, options2) if (originalRecord) { originalRecord.alias.push(matcher) } else { originalMatcher = originalMatcher || matcher if (originalMatcher !== matcher) originalMatcher.alias.push(matcher) if (isRootAdd && record.name && !isAliasRecord(matcher)) removeRoute(record.name) } if (mainNormalizedRecord.children) { const children = mainNormalizedRecord.children for (let i2 = 0; i2 < children.length; i2++) { addRoute( children[i2], matcher, originalRecord && originalRecord.children[i2] ) } } originalRecord = originalRecord || matcher if ( (matcher.record.components && Object.keys(matcher.record.components).length) || matcher.record.name || matcher.record.redirect ) { insertMatcher(matcher) } } return originalMatcher ? () => { removeRoute(originalMatcher) } : noop$5 } function removeRoute(matcherRef) { if (isRouteName(matcherRef)) { const matcher = matcherMap.get(matcherRef) if (matcher) { matcherMap.delete(matcherRef) matchers2.splice(matchers2.indexOf(matcher), 1) matcher.children.forEach(removeRoute) matcher.alias.forEach(removeRoute) } } else { const index2 = matchers2.indexOf(matcherRef) if (index2 > -1) { matchers2.splice(index2, 1) if (matcherRef.record.name) matcherMap.delete(matcherRef.record.name) matcherRef.children.forEach(removeRoute) matcherRef.alias.forEach(removeRoute) } } } function getRoutes() { return matchers2 } function insertMatcher(matcher) { let i2 = 0 while ( i2 < matchers2.length && comparePathParserScore(matcher, matchers2[i2]) >= 0 && (matcher.record.path !== matchers2[i2].record.path || !isRecordChildOf(matcher, matchers2[i2])) ) i2++ matchers2.splice(i2, 0, matcher) if (matcher.record.name && !isAliasRecord(matcher)) matcherMap.set(matcher.record.name, matcher) } function resolve2(location2, currentLocation) { let matcher let params2 = {} let path let name2 if ('name' in location2 && location2.name) { matcher = matcherMap.get(location2.name) if (!matcher) throw createRouterError(1, { location: location2, }) name2 = matcher.record.name params2 = assign$e( paramsFromLocation( currentLocation.params, matcher.keys.filter((k2) => !k2.optional).map((k2) => k2.name) ), location2.params && paramsFromLocation( location2.params, matcher.keys.map((k2) => k2.name) ) ) path = matcher.stringify(params2) } else if ('path' in location2) { path = location2.path matcher = matchers2.find((m2) => m2.re.test(path)) if (matcher) { params2 = matcher.parse(path) name2 = matcher.record.name } } else { matcher = currentLocation.name ? matcherMap.get(currentLocation.name) : matchers2.find((m2) => m2.re.test(currentLocation.path)) if (!matcher) throw createRouterError(1, { location: location2, currentLocation, }) name2 = matcher.record.name params2 = assign$e({}, currentLocation.params, location2.params) path = matcher.stringify(params2) } const matched = [] let parentMatcher = matcher while (parentMatcher) { matched.unshift(parentMatcher.record) parentMatcher = parentMatcher.parent } return { name: name2, path, params: params2, matched, meta: mergeMetaFields(matched), } } routes2.forEach((route) => addRoute(route)) return { addRoute, resolve: resolve2, removeRoute, getRoutes, getRecordMatcher, } } function paramsFromLocation(params2, keys3) { const newParams = {} for (const key2 of keys3) { if (key2 in params2) newParams[key2] = params2[key2] } return newParams } function normalizeRouteRecord(record) { return { path: record.path, redirect: record.redirect, name: record.name, meta: record.meta || {}, aliasOf: void 0, beforeEnter: record.beforeEnter, props: normalizeRecordProps(record), children: record.children || [], instances: {}, leaveGuards: /* @__PURE__ */ new Set(), updateGuards: /* @__PURE__ */ new Set(), enterCallbacks: {}, components: 'components' in record ? record.components || null : record.component && { default: record.component }, } } function normalizeRecordProps(record) { const propsObject = {} const props2 = record.props || false if ('component' in record) { propsObject.default = props2 } else { for (const name2 in record.components) propsObject[name2] = typeof props2 === 'object' ? props2[name2] : props2 } return propsObject } function isAliasRecord(record) { while (record) { if (record.record.aliasOf) return true record = record.parent } return false } function mergeMetaFields(matched) { return matched.reduce((meta, record) => assign$e(meta, record.meta), {}) } function mergeOptions(defaults2, partialOptions) { const options2 = {} for (const key2 in defaults2) { options2[key2] = key2 in partialOptions ? partialOptions[key2] : defaults2[key2] } return options2 } function isRecordChildOf(record, parent2) { return parent2.children.some( (child) => child === record || isRecordChildOf(record, child) ) } const HASH_RE = /#/g const AMPERSAND_RE = /&/g const SLASH_RE = /\//g const EQUAL_RE = /=/g const IM_RE = /\?/g const PLUS_RE = /\+/g const ENC_BRACKET_OPEN_RE = /%5B/g const ENC_BRACKET_CLOSE_RE = /%5D/g const ENC_CARET_RE = /%5E/g const ENC_BACKTICK_RE = /%60/g const ENC_CURLY_OPEN_RE = /%7B/g const ENC_PIPE_RE = /%7C/g const ENC_CURLY_CLOSE_RE = /%7D/g const ENC_SPACE_RE = /%20/g function commonEncode(text2) { return encodeURI('' + text2) .replace(ENC_PIPE_RE, '|') .replace(ENC_BRACKET_OPEN_RE, '[') .replace(ENC_BRACKET_CLOSE_RE, ']') } function encodeHash(text2) { return commonEncode(text2) .replace(ENC_CURLY_OPEN_RE, '{') .replace(ENC_CURLY_CLOSE_RE, '}') .replace(ENC_CARET_RE, '^') } function encodeQueryValue(text2) { return commonEncode(text2) .replace(PLUS_RE, '%2B') .replace(ENC_SPACE_RE, '+') .replace(HASH_RE, '%23') .replace(AMPERSAND_RE, '%26') .replace(ENC_BACKTICK_RE, '`') .replace(ENC_CURLY_OPEN_RE, '{') .replace(ENC_CURLY_CLOSE_RE, '}') .replace(ENC_CARET_RE, '^') } function encodeQueryKey(text2) { return encodeQueryValue(text2).replace(EQUAL_RE, '%3D') } function encodePath(text2) { return commonEncode(text2).replace(HASH_RE, '%23').replace(IM_RE, '%3F') } function encodeParam(text2) { return text2 == null ? '' : encodePath(text2).replace(SLASH_RE, '%2F') } function decode$3(text2) { try { return decodeURIComponent('' + text2) } catch (err) {} return '' + text2 } function parseQuery(search2) { const query = {} if (search2 === '' || search2 === '?') return query const hasLeadingIM = search2[0] === '?' const searchParams = (hasLeadingIM ? search2.slice(1) : search2).split('&') for (let i2 = 0; i2 < searchParams.length; ++i2) { const searchParam = searchParams[i2].replace(PLUS_RE, ' ') const eqPos = searchParam.indexOf('=') const key2 = decode$3(eqPos < 0 ? searchParam : searchParam.slice(0, eqPos)) const value2 = eqPos < 0 ? null : decode$3(searchParam.slice(eqPos + 1)) if (key2 in query) { let currentValue = query[key2] if (!isArray$C(currentValue)) { currentValue = query[key2] = [currentValue] } currentValue.push(value2) } else { query[key2] = value2 } } return query } function stringifyQuery(query) { let search2 = '' for (let key2 in query) { const value2 = query[key2] key2 = encodeQueryKey(key2) if (value2 == null) { if (value2 !== void 0) { search2 += (search2.length ? '&' : '') + key2 } continue } const values2 = isArray$C(value2) ? value2.map((v4) => v4 && encodeQueryValue(v4)) : [value2 && encodeQueryValue(value2)] values2.forEach((value3) => { if (value3 !== void 0) { search2 += (search2.length ? '&' : '') + key2 if (value3 != null) search2 += '=' + value3 } }) } return search2 } function normalizeQuery(query) { const normalizedQuery = {} for (const key2 in query) { const value2 = query[key2] if (value2 !== void 0) { normalizedQuery[key2] = isArray$C(value2) ? value2.map((v4) => (v4 == null ? null : '' + v4)) : value2 == null ? value2 : '' + value2 } } return normalizedQuery } const matchedRouteKey = Symbol('') const viewDepthKey = Symbol('') const routerKey = Symbol('') const routeLocationKey = Symbol('') const routerViewLocationKey = Symbol('') function useCallbacks() { let handlers2 = [] function add2(handler) { handlers2.push(handler) return () => { const i2 = handlers2.indexOf(handler) if (i2 > -1) handlers2.splice(i2, 1) } } function reset2() { handlers2 = [] } return { add: add2, list: () => handlers2.slice(), reset: reset2, } } function registerGuard(record, name2, guard) { const removeFromList = () => { record[name2].delete(guard) } onUnmounted(removeFromList) onDeactivated(removeFromList) onActivated(() => { record[name2].add(guard) }) record[name2].add(guard) } function onBeforeRouteLeave(leaveGuard) { const activeRecord = inject(matchedRouteKey, {}).value if (!activeRecord) { return } registerGuard(activeRecord, 'leaveGuards', leaveGuard) } function onBeforeRouteUpdate(updateGuard) { const activeRecord = inject(matchedRouteKey, {}).value if (!activeRecord) { return } registerGuard(activeRecord, 'updateGuards', updateGuard) } function guardToPromiseFn(guard, to, from, record, name2) { const enterCallbackArray = record && (record.enterCallbacks[name2] = record.enterCallbacks[name2] || []) return () => new Promise((resolve2, reject2) => { const next = (valid) => { if (valid === false) { reject2( createRouterError(4, { from, to, }) ) } else if (valid instanceof Error) { reject2(valid) } else if (isRouteLocation(valid)) { reject2( createRouterError(2, { from: to, to: valid, }) ) } else { if ( enterCallbackArray && record.enterCallbacks[name2] === enterCallbackArray && typeof valid === 'function' ) { enterCallbackArray.push(valid) } resolve2() } } const guardReturn = guard.call( record && record.instances[name2], to, from, next ) let guardCall = Promise.resolve(guardReturn) if (guard.length < 3) guardCall = guardCall.then(next) guardCall.catch((err) => reject2(err)) }) } function extractComponentsGuards(matched, guardType, to, from) { const guards = [] for (const record of matched) { for (const name2 in record.components) { let rawComponent = record.components[name2] if (guardType !== 'beforeRouteEnter' && !record.instances[name2]) continue if (isRouteComponent(rawComponent)) { const options2 = rawComponent.__vccOpts || rawComponent const guard = options2[guardType] guard && guards.push(guardToPromiseFn(guard, to, from, record, name2)) } else { let componentPromise = rawComponent() guards.push(() => componentPromise.then((resolved) => { if (!resolved) return Promise.reject( new Error( `Couldn't resolve component "${name2}" at "${record.path}"` ) ) const resolvedComponent = isESModule(resolved) ? resolved.default : resolved record.components[name2] = resolvedComponent const options2 = resolvedComponent.__vccOpts || resolvedComponent const guard = options2[guardType] return guard && guardToPromiseFn(guard, to, from, record, name2)() }) ) } } } return guards } function isRouteComponent(component2) { return ( typeof component2 === 'object' || 'displayName' in component2 || 'props' in component2 || '__vccOpts' in component2 ) } function loadRouteLocation(route) { return route.matched.every((record) => record.redirect) ? Promise.reject(new Error('Cannot load a route that redirects.')) : Promise.all( route.matched.map( (record) => record.components && Promise.all( Object.keys(record.components).reduce((promises, name2) => { const rawComponent = record.components[name2] if ( typeof rawComponent === 'function' && !('displayName' in rawComponent) ) { promises.push( rawComponent().then((resolved) => { if (!resolved) return Promise.reject( new Error( `Couldn't resolve component "${name2}" at "${record.path}". Ensure you passed a function that returns a promise.` ) ) const resolvedComponent = isESModule(resolved) ? resolved.default : resolved record.components[name2] = resolvedComponent return }) ) } return promises }, []) ) ) ).then(() => route) } function useLink(props2) { const router2 = inject(routerKey) const currentRoute = inject(routeLocationKey) const route = computed(() => router2.resolve(unref(props2.to))) const activeRecordIndex = computed(() => { const { matched } = route.value const { length: length2 } = matched const routeMatched = matched[length2 - 1] const currentMatched = currentRoute.matched if (!routeMatched || !currentMatched.length) return -1 const index2 = currentMatched.findIndex( isSameRouteRecord.bind(null, routeMatched) ) if (index2 > -1) return index2 const parentRecordPath = getOriginalPath(matched[length2 - 2]) return length2 > 1 && getOriginalPath(routeMatched) === parentRecordPath && currentMatched[currentMatched.length - 1].path !== parentRecordPath ? currentMatched.findIndex( isSameRouteRecord.bind(null, matched[length2 - 2]) ) : index2 }) const isActive = computed( () => activeRecordIndex.value > -1 && includesParams(currentRoute.params, route.value.params) ) const isExactActive = computed( () => activeRecordIndex.value > -1 && activeRecordIndex.value === currentRoute.matched.length - 1 && isSameRouteLocationParams(currentRoute.params, route.value.params) ) function navigate(e2 = {}) { if (guardEvent(e2)) { return router2[unref(props2.replace) ? 'replace' : 'push']( unref(props2.to) ).catch(noop$5) } return Promise.resolve() } return { route, href: computed(() => route.value.href), isActive, isExactActive, navigate, } } const RouterLinkImpl = /* @__PURE__ */ defineComponent({ name: 'RouterLink', compatConfig: { MODE: 3 }, props: { to: { type: [String, Object], required: true, }, replace: Boolean, activeClass: String, exactActiveClass: String, custom: Boolean, ariaCurrentValue: { type: String, default: 'page', }, }, useLink, setup(props2, { slots }) { const link2 = reactive(useLink(props2)) const { options: options2 } = inject(routerKey) const elClass = computed(() => ({ [getLinkClass( props2.activeClass, options2.linkActiveClass, 'router-link-active' )]: link2.isActive, [getLinkClass( props2.exactActiveClass, options2.linkExactActiveClass, 'router-link-exact-active' )]: link2.isExactActive, })) return () => { const children = slots.default && slots.default(link2) return props2.custom ? children : h$4( 'a', { 'aria-current': link2.isExactActive ? props2.ariaCurrentValue : null, href: link2.href, onClick: link2.navigate, class: elClass.value, }, children ) } }, }) const RouterLink$1 = RouterLinkImpl function guardEvent(e2) { if (e2.metaKey || e2.altKey || e2.ctrlKey || e2.shiftKey) return if (e2.defaultPrevented) return if (e2.button !== void 0 && e2.button !== 0) return if (e2.currentTarget && e2.currentTarget.getAttribute) { const target2 = e2.currentTarget.getAttribute('target') if (/\b_blank\b/i.test(target2)) return } if (e2.preventDefault) e2.preventDefault() return true } function includesParams(outer, inner2) { for (const key2 in inner2) { const innerValue = inner2[key2] const outerValue = outer[key2] if (typeof innerValue === 'string') { if (innerValue !== outerValue) return false } else { if ( !isArray$C(outerValue) || outerValue.length !== innerValue.length || innerValue.some((value2, i2) => value2 !== outerValue[i2]) ) return false } } return true } function getOriginalPath(record) { return record ? (record.aliasOf ? record.aliasOf.path : record.path) : '' } const getLinkClass = (propClass, globalClass, defaultClass) => propClass != null ? propClass : globalClass != null ? globalClass : defaultClass const RouterViewImpl = /* @__PURE__ */ defineComponent({ name: 'RouterView', inheritAttrs: false, props: { name: { type: String, default: 'default', }, route: Object, }, compatConfig: { MODE: 3 }, setup(props2, { attrs, slots }) { const injectedRoute = inject(routerViewLocationKey) const routeToDisplay = computed(() => props2.route || injectedRoute.value) const injectedDepth = inject(viewDepthKey, 0) const depth = computed(() => { let initialDepth = unref(injectedDepth) const { matched } = routeToDisplay.value let matchedRoute while ( (matchedRoute = matched[initialDepth]) && !matchedRoute.components ) { initialDepth++ } return initialDepth }) const matchedRouteRef = computed( () => routeToDisplay.value.matched[depth.value] ) provide( viewDepthKey, computed(() => depth.value + 1) ) provide(matchedRouteKey, matchedRouteRef) provide(routerViewLocationKey, routeToDisplay) const viewRef = ref() watch$1( () => [viewRef.value, matchedRouteRef.value, props2.name], ([instance, to, name2], [oldInstance, from, oldName]) => { if (to) { to.instances[name2] = instance if (from && from !== to && instance && instance === oldInstance) { if (!to.leaveGuards.size) { to.leaveGuards = from.leaveGuards } if (!to.updateGuards.size) { to.updateGuards = from.updateGuards } } } if ( instance && to && (!from || !isSameRouteRecord(to, from) || !oldInstance) ) { ;(to.enterCallbacks[name2] || []).forEach((callback) => callback(instance) ) } }, { flush: 'post' } ) return () => { const route = routeToDisplay.value const currentName = props2.name const matchedRoute = matchedRouteRef.value const ViewComponent = matchedRoute && matchedRoute.components[currentName] if (!ViewComponent) { return normalizeSlot(slots.default, { Component: ViewComponent, route }) } const routePropsOption = matchedRoute.props[currentName] const routeProps = routePropsOption ? routePropsOption === true ? route.params : typeof routePropsOption === 'function' ? routePropsOption(route) : routePropsOption : null const onVnodeUnmounted = (vnode) => { if (vnode.component.isUnmounted) { matchedRoute.instances[currentName] = null } } const component2 = h$4( ViewComponent, assign$e({}, routeProps, attrs, { onVnodeUnmounted, ref: viewRef, }) ) return ( normalizeSlot(slots.default, { Component: component2, route }) || component2 ) } }, }) function normalizeSlot(slot, data2) { if (!slot) return null const slotContent = slot(data2) return slotContent.length === 1 ? slotContent[0] : slotContent } const RouterView = RouterViewImpl function createRouter(options2) { const matcher = createRouterMatcher(options2.routes, options2) const parseQuery$1 = options2.parseQuery || parseQuery const stringifyQuery$1 = options2.stringifyQuery || stringifyQuery const routerHistory = options2.history const beforeGuards = useCallbacks() const beforeResolveGuards = useCallbacks() const afterGuards = useCallbacks() const currentRoute = shallowRef(START_LOCATION_NORMALIZED) let pendingLocation = START_LOCATION_NORMALIZED if (isBrowser && options2.scrollBehavior && 'scrollRestoration' in history) { history.scrollRestoration = 'manual' } const normalizeParams = applyToParams.bind( null, (paramValue) => '' + paramValue ) const encodeParams = applyToParams.bind(null, encodeParam) const decodeParams = applyToParams.bind(null, decode$3) function addRoute(parentOrRoute, route) { let parent2 let record if (isRouteName(parentOrRoute)) { parent2 = matcher.getRecordMatcher(parentOrRoute) record = route } else { record = parentOrRoute } return matcher.addRoute(record, parent2) } function removeRoute(name2) { const recordMatcher = matcher.getRecordMatcher(name2) if (recordMatcher) { matcher.removeRoute(recordMatcher) } } function getRoutes() { return matcher.getRoutes().map((routeMatcher) => routeMatcher.record) } function hasRoute(name2) { return !!matcher.getRecordMatcher(name2) } function resolve2(rawLocation, currentLocation) { currentLocation = assign$e({}, currentLocation || currentRoute.value) if (typeof rawLocation === 'string') { const locationNormalized = parseURL( parseQuery$1, rawLocation, currentLocation.path ) const matchedRoute2 = matcher.resolve( { path: locationNormalized.path }, currentLocation ) const href2 = routerHistory.createHref(locationNormalized.fullPath) return assign$e(locationNormalized, matchedRoute2, { params: decodeParams(matchedRoute2.params), hash: decode$3(locationNormalized.hash), redirectedFrom: void 0, href: href2, }) } let matcherLocation if ('path' in rawLocation) { matcherLocation = assign$e({}, rawLocation, { path: parseURL(parseQuery$1, rawLocation.path, currentLocation.path) .path, }) } else { const targetParams = assign$e({}, rawLocation.params) for (const key2 in targetParams) { if (targetParams[key2] == null) { delete targetParams[key2] } } matcherLocation = assign$e({}, rawLocation, { params: encodeParams(targetParams), }) currentLocation.params = encodeParams(currentLocation.params) } const matchedRoute = matcher.resolve(matcherLocation, currentLocation) const hash2 = rawLocation.hash || '' matchedRoute.params = normalizeParams(decodeParams(matchedRoute.params)) const fullPath = stringifyURL( stringifyQuery$1, assign$e({}, rawLocation, { hash: encodeHash(hash2), path: matchedRoute.path, }) ) const href = routerHistory.createHref(fullPath) return assign$e( { fullPath, hash: hash2, query: stringifyQuery$1 === stringifyQuery ? normalizeQuery(rawLocation.query) : rawLocation.query || {}, }, matchedRoute, { redirectedFrom: void 0, href, } ) } function locationAsObject(to) { return typeof to === 'string' ? parseURL(parseQuery$1, to, currentRoute.value.path) : assign$e({}, to) } function checkCanceledNavigation(to, from) { if (pendingLocation !== to) { return createRouterError(8, { from, to, }) } } function push2(to) { return pushWithRedirect(to) } function replace2(to) { return push2(assign$e(locationAsObject(to), { replace: true })) } function handleRedirectRecord(to) { const lastMatched = to.matched[to.matched.length - 1] if (lastMatched && lastMatched.redirect) { const { redirect } = lastMatched let newTargetLocation = typeof redirect === 'function' ? redirect(to) : redirect if (typeof newTargetLocation === 'string') { newTargetLocation = newTargetLocation.includes('?') || newTargetLocation.includes('#') ? (newTargetLocation = locationAsObject(newTargetLocation)) : { path: newTargetLocation } newTargetLocation.params = {} } return assign$e( { query: to.query, hash: to.hash, params: 'path' in newTargetLocation ? {} : to.params, }, newTargetLocation ) } } function pushWithRedirect(to, redirectedFrom) { const targetLocation = (pendingLocation = resolve2(to)) const from = currentRoute.value const data2 = to.state const force = to.force const replace3 = to.replace === true const shouldRedirect = handleRedirectRecord(targetLocation) if (shouldRedirect) return pushWithRedirect( assign$e(locationAsObject(shouldRedirect), { state: typeof shouldRedirect === 'object' ? assign$e({}, data2, shouldRedirect.state) : data2, force, replace: replace3, }), redirectedFrom || targetLocation ) const toLocation = targetLocation toLocation.redirectedFrom = redirectedFrom let failure if (!force && isSameRouteLocation(stringifyQuery$1, from, targetLocation)) { failure = createRouterError(16, { to: toLocation, from }) handleScroll2(from, from, true, false) } return (failure ? Promise.resolve(failure) : navigate(toLocation, from)) .catch((error2) => isNavigationFailure(error2) ? isNavigationFailure(error2, 2) ? error2 : markAsReady(error2) : triggerError(error2, toLocation, from) ) .then((failure2) => { if (failure2) { if (isNavigationFailure(failure2, 2)) { return pushWithRedirect( assign$e( { replace: replace3, }, locationAsObject(failure2.to), { state: typeof failure2.to === 'object' ? assign$e({}, data2, failure2.to.state) : data2, force, } ), redirectedFrom || toLocation ) } } else { failure2 = finalizeNavigation(toLocation, from, true, replace3, data2) } triggerAfterEach(toLocation, from, failure2) return failure2 }) } function checkCanceledNavigationAndReject(to, from) { const error2 = checkCanceledNavigation(to, from) return error2 ? Promise.reject(error2) : Promise.resolve() } function runWithContext(fn2) { const app2 = installedApps.values().next().value return app2 && typeof app2.runWithContext === 'function' ? app2.runWithContext(fn2) : fn2() } function navigate(to, from) { let guards const [leavingRecords, updatingRecords, enteringRecords] = extractChangingRecords(to, from) guards = extractComponentsGuards( leavingRecords.reverse(), 'beforeRouteLeave', to, from ) for (const record of leavingRecords) { record.leaveGuards.forEach((guard) => { guards.push(guardToPromiseFn(guard, to, from)) }) } const canceledNavigationCheck = checkCanceledNavigationAndReject.bind( null, to, from ) guards.push(canceledNavigationCheck) return runGuardQueue(guards) .then(() => { guards = [] for (const guard of beforeGuards.list()) { guards.push(guardToPromiseFn(guard, to, from)) } guards.push(canceledNavigationCheck) return runGuardQueue(guards) }) .then(() => { guards = extractComponentsGuards( updatingRecords, 'beforeRouteUpdate', to, from ) for (const record of updatingRecords) { record.updateGuards.forEach((guard) => { guards.push(guardToPromiseFn(guard, to, from)) }) } guards.push(canceledNavigationCheck) return runGuardQueue(guards) }) .then(() => { guards = [] for (const record of enteringRecords) { if (record.beforeEnter) { if (isArray$C(record.beforeEnter)) { for (const beforeEnter of record.beforeEnter) guards.push(guardToPromiseFn(beforeEnter, to, from)) } else { guards.push(guardToPromiseFn(record.beforeEnter, to, from)) } } } guards.push(canceledNavigationCheck) return runGuardQueue(guards) }) .then(() => { to.matched.forEach((record) => (record.enterCallbacks = {})) guards = extractComponentsGuards( enteringRecords, 'beforeRouteEnter', to, from ) guards.push(canceledNavigationCheck) return runGuardQueue(guards) }) .then(() => { guards = [] for (const guard of beforeResolveGuards.list()) { guards.push(guardToPromiseFn(guard, to, from)) } guards.push(canceledNavigationCheck) return runGuardQueue(guards) }) .catch((err) => (isNavigationFailure(err, 8) ? err : Promise.reject(err))) } function triggerAfterEach(to, from, failure) { afterGuards .list() .forEach((guard) => runWithContext(() => guard(to, from, failure))) } function finalizeNavigation(toLocation, from, isPush, replace3, data2) { const error2 = checkCanceledNavigation(toLocation, from) if (error2) return error2 const isFirstNavigation = from === START_LOCATION_NORMALIZED const state2 = !isBrowser ? {} : history.state if (isPush) { if (replace3 || isFirstNavigation) routerHistory.replace( toLocation.fullPath, assign$e( { scroll: isFirstNavigation && state2 && state2.scroll, }, data2 ) ) else routerHistory.push(toLocation.fullPath, data2) } currentRoute.value = toLocation handleScroll2(toLocation, from, isPush, isFirstNavigation) markAsReady() } let removeHistoryListener function setupListeners() { if (removeHistoryListener) return removeHistoryListener = routerHistory.listen((to, _from, info) => { if (!router2.listening) return const toLocation = resolve2(to) const shouldRedirect = handleRedirectRecord(toLocation) if (shouldRedirect) { pushWithRedirect( assign$e(shouldRedirect, { replace: true }), toLocation ).catch(noop$5) return } pendingLocation = toLocation const from = currentRoute.value if (isBrowser) { saveScrollPosition( getScrollKey(from.fullPath, info.delta), computeScrollPosition() ) } navigate(toLocation, from) .catch((error2) => { if (isNavigationFailure(error2, 4 | 8)) { return error2 } if (isNavigationFailure(error2, 2)) { pushWithRedirect(error2.to, toLocation) .then((failure) => { if ( isNavigationFailure(failure, 4 | 16) && !info.delta && info.type === NavigationType.pop ) { routerHistory.go(-1, false) } }) .catch(noop$5) return Promise.reject() } if (info.delta) { routerHistory.go(-info.delta, false) } return triggerError(error2, toLocation, from) }) .then((failure) => { failure = failure || finalizeNavigation(toLocation, from, false) if (failure) { if (info.delta && !isNavigationFailure(failure, 8)) { routerHistory.go(-info.delta, false) } else if ( info.type === NavigationType.pop && isNavigationFailure(failure, 4 | 16) ) { routerHistory.go(-1, false) } } triggerAfterEach(toLocation, from, failure) }) .catch(noop$5) }) } let readyHandlers = useCallbacks() let errorListeners = useCallbacks() let ready function triggerError(error2, to, from) { markAsReady(error2) const list2 = errorListeners.list() if (list2.length) { list2.forEach((handler) => handler(error2, to, from)) } else { console.error(error2) } return Promise.reject(error2) } function isReady() { if (ready && currentRoute.value !== START_LOCATION_NORMALIZED) return Promise.resolve() return new Promise((resolve3, reject2) => { readyHandlers.add([resolve3, reject2]) }) } function markAsReady(err) { if (!ready) { ready = !err setupListeners() readyHandlers .list() .forEach(([resolve3, reject2]) => (err ? reject2(err) : resolve3())) readyHandlers.reset() } return err } function handleScroll2(to, from, isPush, isFirstNavigation) { const { scrollBehavior } = options2 if (!isBrowser || !scrollBehavior) return Promise.resolve() const scrollPosition = (!isPush && getSavedScrollPosition(getScrollKey(to.fullPath, 0))) || ((isFirstNavigation || !isPush) && history.state && history.state.scroll) || null return nextTick() .then(() => scrollBehavior(to, from, scrollPosition)) .then((position2) => position2 && scrollToPosition(position2)) .catch((err) => triggerError(err, to, from)) } const go2 = (delta) => routerHistory.go(delta) let started const installedApps = /* @__PURE__ */ new Set() const router2 = { currentRoute, listening: true, addRoute, removeRoute, hasRoute, getRoutes, resolve: resolve2, options: options2, push: push2, replace: replace2, go: go2, back: () => go2(-1), forward: () => go2(1), beforeEach: beforeGuards.add, beforeResolve: beforeResolveGuards.add, afterEach: afterGuards.add, onError: errorListeners.add, isReady, install(app2) { const router3 = this app2.component('RouterLink', RouterLink$1) app2.component('RouterView', RouterView) app2.config.globalProperties.$router = router3 Object.defineProperty(app2.config.globalProperties, '$route', { enumerable: true, get: () => unref(currentRoute), }) if ( isBrowser && !started && currentRoute.value === START_LOCATION_NORMALIZED ) { started = true push2(routerHistory.location).catch((err) => {}) } const reactiveRoute = {} for (const key2 in START_LOCATION_NORMALIZED) { Object.defineProperty(reactiveRoute, key2, { get: () => currentRoute.value[key2], enumerable: true, }) } app2.provide(routerKey, router3) app2.provide(routeLocationKey, shallowReactive(reactiveRoute)) app2.provide(routerViewLocationKey, currentRoute) const unmountApp = app2.unmount installedApps.add(app2) app2.unmount = function () { installedApps.delete(app2) if (installedApps.size < 1) { pendingLocation = START_LOCATION_NORMALIZED removeHistoryListener && removeHistoryListener() removeHistoryListener = null currentRoute.value = START_LOCATION_NORMALIZED started = false ready = false } unmountApp() } }, } function runGuardQueue(guards) { return guards.reduce( (promise2, guard) => promise2.then(() => runWithContext(guard)), Promise.resolve() ) } return router2 } function extractChangingRecords(to, from) { const leavingRecords = [] const updatingRecords = [] const enteringRecords = [] const len2 = Math.max(from.matched.length, to.matched.length) for (let i2 = 0; i2 < len2; i2++) { const recordFrom = from.matched[i2] if (recordFrom) { if (to.matched.find((record) => isSameRouteRecord(record, recordFrom))) updatingRecords.push(recordFrom) else leavingRecords.push(recordFrom) } const recordTo = to.matched[i2] if (recordTo) { if (!from.matched.find((record) => isSameRouteRecord(record, recordTo))) { enteringRecords.push(recordTo) } } } return [leavingRecords, updatingRecords, enteringRecords] } function useRouter() { return inject(routerKey) } function useRoute() { return inject(routeLocationKey) } var vueRouter = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, get NavigationFailureType() { return NavigationFailureType }, RouterLink: RouterLink$1, RouterView, START_LOCATION: START_LOCATION_NORMALIZED, createMemoryHistory, createRouter, createRouterMatcher, createWebHashHistory, createWebHistory, isNavigationFailure, loadRouteLocation, matchedRouteKey, onBeforeRouteLeave, onBeforeRouteUpdate, parseQuery, routeLocationKey, routerKey, routerViewLocationKey, stringifyQuery, useLink, useRoute, useRouter, viewDepthKey, }, Symbol.toStringTag, { value: 'Module' } ) ) function useTitle() { const title = 'CMS' const { currentRoute } = useRouter() const pageTitle = useTitle$1() watch$1( [() => currentRoute.value.path], () => { const route = unref(currentRoute) pageTitle.value = route.meta.title ? `${title} - ${title}` : `${title}` }, { immediate: true, } ) } const _sfc_main$75 = /* @__PURE__ */ defineComponent({ setup(__props2) { const triggerRef2 = ref({ getBoundingClientRect() { return position2.value }, }) const position2 = ref({ top: 0, left: 0, bottom: 0, right: 0, }) const defaultOptions2 = { content: '', disabled: false, rawContent: false, placement: 'bottom', effect: 'dark', offset: null, popperClass: 'cms-el-tooltip', showAfter: 20, } const currentOptions = reactive({ ...defaultOptions2, }) function updateCurrentOptions(options2) { Object.assign(currentOptions, defaultOptions2, options2) } function getOptions(el2) { let options2 = {} const dataset = el2.dataset options2.content = el2.title const disabled = dataset['tooltipDisabled'] options2.disabled = disabled == 'true' || disabled === '' ? true : defaultOptions2.disabled const rawContent = dataset['tooltipRawContent'] options2.rawContent = rawContent == 'true' || rawContent === '' ? true : defaultOptions2.rawContent const placement = dataset['tooltipPlacement'] const placements2 = [ 'top', 'top-start', 'top-end', 'bottom', 'bottom-start', 'bottom-end', 'left', 'left-start', 'left-end', 'right', 'right-start', 'right-end', ] options2.placement = placement && placements2.includes(placement) ? placement : defaultOptions2.placement const effect2 = dataset['tooltipEffect'] const effects = ['dark', 'light'] options2.effect = effect2 && effects.includes(effect2) ? effect2 : defaultOptions2.effect const offset2 = dataset['tooltipOffset'] options2.offset = offset2 ? Number(offset2) : null const popperClass = dataset['tooltipPopperClass'] options2.popperClass = popperClass || defaultOptions2.popperClass const showAfter = parseInt(el2.dataset['tooltipShowAfter'] || '') options2.showAfter = showAfter || defaultOptions2.showAfter return options2 } let currentTitleEl let visible = ref(false) function show(el2) { visible.value = true position2.value = el2.getBoundingClientRect() } function hide2() { visible.value = false } function backupTitle(titleEl) { titleEl.dataset.title = titleEl.title titleEl.title = '' } function revertTitle(titleEl) { if (!titleEl) return titleEl.title = titleEl.dataset.title || '' titleEl.dataset.title = '' } function findClosestTileEl(target2, level = 5) { level -= 1 if (!target2) return if (!level) return if ( target2 instanceof HTMLElement && (target2.title || target2.dataset.title) ) return target2 return findClosestTileEl(target2.parentElement, level) } let showTimer function mouseoverHandler(e2) { if (!(e2.target instanceof Element)) return const titleEl = findClosestTileEl(e2.target) if (titleEl !== currentTitleEl) { revertTitle(currentTitleEl) } if (!titleEl) { currentTitleEl = void 0 hide2() return } if (titleEl && titleEl !== currentTitleEl) { currentTitleEl = titleEl const options2 = getOptions(titleEl) backupTitle(titleEl) clearTimeout(showTimer) showTimer = setTimeout(() => { updateCurrentOptions(options2) show(titleEl) }, options2.showAfter) } } const mouseoverHandler_ = useDebounceFn(mouseoverHandler, 10) useEventListener(document, 'mouseover', mouseoverHandler_, true) return (_ctx, _cache) => { const _component_el_tooltip = resolveComponent('el-tooltip') return ( openBlock(), createElementBlock('div', null, [ createVNode$1( _component_el_tooltip, { visible: visible.value, 'onUpdate:visible': _cache[0] || (_cache[0] = ($event) => (visible.value = $event)), content: unref(currentOptions).content, disabled: unref(currentOptions)?.disabled, 'raw-content': unref(currentOptions)?.rawContent, placement: unref(currentOptions)?.placement, effect: unref(currentOptions)?.effect, offset: unref(currentOptions)?.offset, 'popper-class': unref(currentOptions)?.popperClass, enterable: false, trigger: 'hover', 'virtual-triggering': '', 'virtual-ref': triggerRef2.value, persistent: '', }, null, 8, [ 'visible', 'content', 'disabled', 'raw-content', 'placement', 'effect', 'offset', 'popper-class', 'virtual-ref', ] ), ]) ) } }, }) var TitleTooltip = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: _sfc_main$75, }, Symbol.toStringTag, { value: 'Module' } ) ) var App_vue_vue_type_style_index_0_scoped_true_lang = '' var _export_sfc = (sfc, props2) => { const target2 = sfc.__vccOpts || sfc for (const [key2, val2] of props2) { target2[key2] = val2 } return target2 } const _hoisted_1$5$ = { class: 'app' } const _sfc_main$74 = /* @__PURE__ */ defineComponent({ setup(__props2) { useTitle() onMounted(() => {}) return (_ctx, _cache) => { const _component_router_view = resolveComponent('router-view') return ( openBlock(), createElementBlock('div', _hoisted_1$5$, [ createVNode$1(_component_router_view), createVNode$1(_sfc_main$75), ]) ) } }, }) var AppView = /* @__PURE__ */ _export_sfc(_sfc_main$74, [ ['__scopeId', 'data-v-6d210531'], ]) var App$1 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: AppView, }, Symbol.toStringTag, { value: 'Module' } ) ) var axios$2 = { exports: {} } var bind$b = function bind2(fn2, thisArg) { return function wrap() { var args = new Array(arguments.length) for (var i2 = 0; i2 < args.length; i2++) { args[i2] = arguments[i2] } return fn2.apply(thisArg, args) } } var bind$a = bind$b var toString$c = Object.prototype.toString function isArray$B(val2) { return toString$c.call(val2) === '[object Array]' } function isUndefined$b(val2) { return typeof val2 === 'undefined' } function isBuffer$3(val2) { return ( val2 !== null && !isUndefined$b(val2) && val2.constructor !== null && !isUndefined$b(val2.constructor) && typeof val2.constructor.isBuffer === 'function' && val2.constructor.isBuffer(val2) ) } function isArrayBuffer$1(val2) { return toString$c.call(val2) === '[object ArrayBuffer]' } function isFormData$2(val2) { return typeof FormData !== 'undefined' && val2 instanceof FormData } function isArrayBufferView(val2) { var result if (typeof ArrayBuffer !== 'undefined' && ArrayBuffer.isView) { result = ArrayBuffer.isView(val2) } else { result = val2 && val2.buffer && val2.buffer instanceof ArrayBuffer } return result } function isString$d(val2) { return typeof val2 === 'string' } function isNumber$f(val2) { return typeof val2 === 'number' } function isObject$s(val2) { return val2 !== null && typeof val2 === 'object' } function isPlainObject$8(val2) { if (toString$c.call(val2) !== '[object Object]') { return false } var prototype = Object.getPrototypeOf(val2) return prototype === null || prototype === Object.prototype } function isDate$a(val2) { return toString$c.call(val2) === '[object Date]' } function isFile(val2) { return toString$c.call(val2) === '[object File]' } function isBlob(val2) { return toString$c.call(val2) === '[object Blob]' } function isFunction$j(val2) { return toString$c.call(val2) === '[object Function]' } function isStream(val2) { return isObject$s(val2) && isFunction$j(val2.pipe) } function isURLSearchParams(val2) { return ( typeof URLSearchParams !== 'undefined' && val2 instanceof URLSearchParams ) } function trim$5(str) { return str.trim ? str.trim() : str.replace(/^\s+|\s+$/g, '') } function isStandardBrowserEnv() { if ( typeof navigator !== 'undefined' && (navigator.product === 'ReactNative' || navigator.product === 'NativeScript' || navigator.product === 'NS') ) { return false } return typeof window !== 'undefined' && typeof document !== 'undefined' } function forEach(obj, fn2) { if (obj === null || typeof obj === 'undefined') { return } if (typeof obj !== 'object') { obj = [obj] } if (isArray$B(obj)) { for (var i2 = 0, l2 = obj.length; i2 < l2; i2++) { fn2.call(null, obj[i2], i2, obj) } } else { for (var key2 in obj) { if (Object.prototype.hasOwnProperty.call(obj, key2)) { fn2.call(null, obj[key2], key2, obj) } } } } function merge$3() { var result = {} function assignValue2(val2, key2) { if (isPlainObject$8(result[key2]) && isPlainObject$8(val2)) { result[key2] = merge$3(result[key2], val2) } else if (isPlainObject$8(val2)) { result[key2] = merge$3({}, val2) } else if (isArray$B(val2)) { result[key2] = val2.slice() } else { result[key2] = val2 } } for (var i2 = 0, l2 = arguments.length; i2 < l2; i2++) { forEach(arguments[i2], assignValue2) } return result } function extend$2(a2, b2, thisArg) { forEach(b2, function assignValue2(val2, key2) { if (thisArg && typeof val2 === 'function') { a2[key2] = bind$a(val2, thisArg) } else { a2[key2] = val2 } }) return a2 } function stripBOM(content2) { if (content2.charCodeAt(0) === 65279) { content2 = content2.slice(1) } return content2 } var utils$e = { isArray: isArray$B, isArrayBuffer: isArrayBuffer$1, isBuffer: isBuffer$3, isFormData: isFormData$2, isArrayBufferView, isString: isString$d, isNumber: isNumber$f, isObject: isObject$s, isPlainObject: isPlainObject$8, isUndefined: isUndefined$b, isDate: isDate$a, isFile, isBlob, isFunction: isFunction$j, isStream, isURLSearchParams, isStandardBrowserEnv, forEach, merge: merge$3, extend: extend$2, trim: trim$5, stripBOM, } var utils$d = utils$e function encode(val2) { return encodeURIComponent(val2) .replace(/%3A/gi, ':') .replace(/%24/g, '$') .replace(/%2C/gi, ',') .replace(/%20/g, '+') .replace(/%5B/gi, '[') .replace(/%5D/gi, ']') } var buildURL$2 = function buildURL2(url2, params2, paramsSerializer) { if (!params2) { return url2 } var serializedParams if (paramsSerializer) { serializedParams = paramsSerializer(params2) } else if (utils$d.isURLSearchParams(params2)) { serializedParams = params2.toString() } else { var parts = [] utils$d.forEach(params2, function serialize2(val2, key2) { if (val2 === null || typeof val2 === 'undefined') { return } if (utils$d.isArray(val2)) { key2 = key2 + '[]' } else { val2 = [val2] } utils$d.forEach(val2, function parseValue2(v4) { if (utils$d.isDate(v4)) { v4 = v4.toISOString() } else if (utils$d.isObject(v4)) { v4 = JSON.stringify(v4) } parts.push(encode(key2) + '=' + encode(v4)) }) }) serializedParams = parts.join('&') } if (serializedParams) { var hashmarkIndex = url2.indexOf('#') if (hashmarkIndex !== -1) { url2 = url2.slice(0, hashmarkIndex) } url2 += (url2.indexOf('?') === -1 ? '?' : '&') + serializedParams } return url2 } var utils$c = utils$e function InterceptorManager$1() { this.handlers = [] } InterceptorManager$1.prototype.use = function use2( fulfilled, rejected, options2 ) { this.handlers.push({ fulfilled, rejected, synchronous: options2 ? options2.synchronous : false, runWhen: options2 ? options2.runWhen : null, }) return this.handlers.length - 1 } InterceptorManager$1.prototype.eject = function eject(id2) { if (this.handlers[id2]) { this.handlers[id2] = null } } InterceptorManager$1.prototype.forEach = function forEach2(fn2) { utils$c.forEach(this.handlers, function forEachHandler(h2) { if (h2 !== null) { fn2(h2) } }) } var InterceptorManager_1 = InterceptorManager$1 var utils$b = utils$e var normalizeHeaderName$1 = function normalizeHeaderName2( headers, normalizedName ) { utils$b.forEach(headers, function processHeader(value2, name2) { if ( name2 !== normalizedName && name2.toUpperCase() === normalizedName.toUpperCase() ) { headers[normalizedName] = value2 delete headers[name2] } }) } var enhanceError$2 = function enhanceError2( error2, config2, code2, request3, response ) { error2.config = config2 if (code2) { error2.code = code2 } error2.request = request3 error2.response = response error2.isAxiosError = true error2.toJSON = function toJSON() { return { message: this.message, name: this.name, description: this.description, number: this.number, fileName: this.fileName, lineNumber: this.lineNumber, columnNumber: this.columnNumber, stack: this.stack, config: this.config, code: this.code, status: this.response && this.response.status ? this.response.status : null, } } return error2 } var enhanceError$1 = enhanceError$2 var createError$2 = function createError2( message2, config2, code2, request3, response ) { var error2 = new Error(message2) return enhanceError$1(error2, config2, code2, request3, response) } var createError$1 = createError$2 var settle$1 = function settle2(resolve2, reject2, response) { var validateStatus2 = response.config.validateStatus if ( !response.status || !validateStatus2 || validateStatus2(response.status) ) { resolve2(response) } else { reject2( createError$1( 'Request failed with status code ' + response.status, response.config, null, response.request, response ) ) } } var utils$a = utils$e var cookies$1 = utils$a.isStandardBrowserEnv() ? (function standardBrowserEnv() { return { write: function write2(name2, value2, expires, path, domain, secure) { var cookie2 = [] cookie2.push(name2 + '=' + encodeURIComponent(value2)) if (utils$a.isNumber(expires)) { cookie2.push('expires=' + new Date(expires).toGMTString()) } if (utils$a.isString(path)) { cookie2.push('path=' + path) } if (utils$a.isString(domain)) { cookie2.push('domain=' + domain) } if (secure === true) { cookie2.push('secure') } document.cookie = cookie2.join('; ') }, read: function read2(name2) { var match2 = document.cookie.match( new RegExp('(^|;\\s*)(' + name2 + ')=([^;]*)') ) return match2 ? decodeURIComponent(match2[3]) : null }, remove: function remove2(name2) { this.write(name2, '', Date.now() - 864e5) }, } })() : (function nonStandardBrowserEnv() { return { write: function write2() {}, read: function read2() { return null }, remove: function remove2() {}, } })() var isAbsoluteURL$1 = function isAbsoluteURL2(url2) { return /^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(url2) } var combineURLs$1 = function combineURLs2(baseURL2, relativeURL) { return relativeURL ? baseURL2.replace(/\/+$/, '') + '/' + relativeURL.replace(/^\/+/, '') : baseURL2 } var isAbsoluteURL = isAbsoluteURL$1 var combineURLs = combineURLs$1 var buildFullPath$1 = function buildFullPath2(baseURL2, requestedURL) { if (baseURL2 && !isAbsoluteURL(requestedURL)) { return combineURLs(baseURL2, requestedURL) } return requestedURL } var utils$9 = utils$e var ignoreDuplicateOf = [ 'age', 'authorization', 'content-length', 'content-type', 'etag', 'expires', 'from', 'host', 'if-modified-since', 'if-unmodified-since', 'last-modified', 'location', 'max-forwards', 'proxy-authorization', 'referer', 'retry-after', 'user-agent', ] var parseHeaders$1 = function parseHeaders2(headers) { var parsed = {} var key2 var val2 var i2 if (!headers) { return parsed } utils$9.forEach(headers.split('\n'), function parser2(line) { i2 = line.indexOf(':') key2 = utils$9.trim(line.substr(0, i2)).toLowerCase() val2 = utils$9.trim(line.substr(i2 + 1)) if (key2) { if (parsed[key2] && ignoreDuplicateOf.indexOf(key2) >= 0) { return } if (key2 === 'set-cookie') { parsed[key2] = (parsed[key2] ? parsed[key2] : []).concat([val2]) } else { parsed[key2] = parsed[key2] ? parsed[key2] + ', ' + val2 : val2 } } }) return parsed } var utils$8 = utils$e var isURLSameOrigin$1 = utils$8.isStandardBrowserEnv() ? (function standardBrowserEnv2() { var msie = /(msie|trident)/i.test(navigator.userAgent) var urlParsingNode = document.createElement('a') var originURL function resolveURL(url2) { var href = url2 if (msie) { urlParsingNode.setAttribute('href', href) href = urlParsingNode.href } urlParsingNode.setAttribute('href', href) return { href: urlParsingNode.href, protocol: urlParsingNode.protocol ? urlParsingNode.protocol.replace(/:$/, '') : '', host: urlParsingNode.host, search: urlParsingNode.search ? urlParsingNode.search.replace(/^\?/, '') : '', hash: urlParsingNode.hash ? urlParsingNode.hash.replace(/^#/, '') : '', hostname: urlParsingNode.hostname, port: urlParsingNode.port, pathname: urlParsingNode.pathname.charAt(0) === '/' ? urlParsingNode.pathname : '/' + urlParsingNode.pathname, } } originURL = resolveURL(window.location.href) return function isURLSameOrigin2(requestURL) { var parsed = utils$8.isString(requestURL) ? resolveURL(requestURL) : requestURL return ( parsed.protocol === originURL.protocol && parsed.host === originURL.host ) } })() : (function nonStandardBrowserEnv2() { return function isURLSameOrigin2() { return true } })() function Cancel$3(message2) { this.message = message2 } Cancel$3.prototype.toString = function toString2() { return 'Cancel' + (this.message ? ': ' + this.message : '') } Cancel$3.prototype.__CANCEL__ = true var Cancel_1 = Cancel$3 var utils$7 = utils$e var settle = settle$1 var cookies = cookies$1 var buildURL$1 = buildURL$2 var buildFullPath = buildFullPath$1 var parseHeaders = parseHeaders$1 var isURLSameOrigin = isURLSameOrigin$1 var createError = createError$2 var defaults$6 = defaults_1 var Cancel$2 = Cancel_1 var xhr = function xhrAdapter(config2) { return new Promise(function dispatchXhrRequest(resolve2, reject2) { var requestData = config2.data var requestHeaders = config2.headers var responseType = config2.responseType var onCanceled function done() { if (config2.cancelToken) { config2.cancelToken.unsubscribe(onCanceled) } if (config2.signal) { config2.signal.removeEventListener('abort', onCanceled) } } if (utils$7.isFormData(requestData)) { delete requestHeaders['Content-Type'] } var request3 = new XMLHttpRequest() if (config2.auth) { var username = config2.auth.username || '' var password = config2.auth.password ? unescape(encodeURIComponent(config2.auth.password)) : '' requestHeaders.Authorization = 'Basic ' + btoa(username + ':' + password) } var fullPath = buildFullPath(config2.baseURL, config2.url) request3.open( config2.method.toUpperCase(), buildURL$1(fullPath, config2.params, config2.paramsSerializer), true ) request3.timeout = config2.timeout function onloadend() { if (!request3) { return } var responseHeaders = 'getAllResponseHeaders' in request3 ? parseHeaders(request3.getAllResponseHeaders()) : null var responseData = !responseType || responseType === 'text' || responseType === 'json' ? request3.responseText : request3.response var response = { data: responseData, status: request3.status, statusText: request3.statusText, headers: responseHeaders, config: config2, request: request3, } settle( function _resolve(value2) { resolve2(value2) done() }, function _reject(err) { reject2(err) done() }, response ) request3 = null } if ('onloadend' in request3) { request3.onloadend = onloadend } else { request3.onreadystatechange = function handleLoad() { if (!request3 || request3.readyState !== 4) { return } if ( request3.status === 0 && !(request3.responseURL && request3.responseURL.indexOf('file:') === 0) ) { return } setTimeout(onloadend) } } request3.onabort = function handleAbort() { if (!request3) { return } reject2(createError('Request aborted', config2, 'ECONNABORTED', request3)) request3 = null } request3.onerror = function handleError() { reject2(createError('Network Error', config2, null, request3)) request3 = null } request3.ontimeout = function handleTimeout() { var timeoutErrorMessage = config2.timeout ? 'timeout of ' + config2.timeout + 'ms exceeded' : 'timeout exceeded' var transitional2 = config2.transitional || defaults$6.transitional if (config2.timeoutErrorMessage) { timeoutErrorMessage = config2.timeoutErrorMessage } reject2( createError( timeoutErrorMessage, config2, transitional2.clarifyTimeoutError ? 'ETIMEDOUT' : 'ECONNABORTED', request3 ) ) request3 = null } if (utils$7.isStandardBrowserEnv()) { var xsrfValue = (config2.withCredentials || isURLSameOrigin(fullPath)) && config2.xsrfCookieName ? cookies.read(config2.xsrfCookieName) : void 0 if (xsrfValue) { requestHeaders[config2.xsrfHeaderName] = xsrfValue } } if ('setRequestHeader' in request3) { utils$7.forEach(requestHeaders, function setRequestHeader(val2, key2) { if ( typeof requestData === 'undefined' && key2.toLowerCase() === 'content-type' ) { delete requestHeaders[key2] } else { request3.setRequestHeader(key2, val2) } }) } if (!utils$7.isUndefined(config2.withCredentials)) { request3.withCredentials = !!config2.withCredentials } if (responseType && responseType !== 'json') { request3.responseType = config2.responseType } if (typeof config2.onDownloadProgress === 'function') { request3.addEventListener('progress', config2.onDownloadProgress) } if (typeof config2.onUploadProgress === 'function' && request3.upload) { request3.upload.addEventListener('progress', config2.onUploadProgress) } if (config2.cancelToken || config2.signal) { onCanceled = function (cancel2) { if (!request3) { return } reject2( !cancel2 || (cancel2 && cancel2.type) ? new Cancel$2('canceled') : cancel2 ) request3.abort() request3 = null } config2.cancelToken && config2.cancelToken.subscribe(onCanceled) if (config2.signal) { config2.signal.aborted ? onCanceled() : config2.signal.addEventListener('abort', onCanceled) } } if (!requestData) { requestData = null } request3.send(requestData) }) } var utils$6 = utils$e var normalizeHeaderName = normalizeHeaderName$1 var enhanceError = enhanceError$2 var DEFAULT_CONTENT_TYPE = { 'Content-Type': 'application/x-www-form-urlencoded', } function setContentTypeIfUnset(headers, value2) { if ( !utils$6.isUndefined(headers) && utils$6.isUndefined(headers['Content-Type']) ) { headers['Content-Type'] = value2 } } function getDefaultAdapter() { var adapter if (typeof XMLHttpRequest !== 'undefined') { adapter = xhr } else if ( typeof process !== 'undefined' && Object.prototype.toString.call(process) === '[object process]' ) { adapter = xhr } return adapter } function stringifySafely(rawValue, parser2, encoder) { if (utils$6.isString(rawValue)) { try { ;(parser2 || JSON.parse)(rawValue) return utils$6.trim(rawValue) } catch (e2) { if (e2.name !== 'SyntaxError') { throw e2 } } } return (encoder || JSON.stringify)(rawValue) } var defaults$5 = { transitional: { silentJSONParsing: true, forcedJSONParsing: true, clarifyTimeoutError: false, }, adapter: getDefaultAdapter(), transformRequest: [ function transformRequest(data2, headers) { normalizeHeaderName(headers, 'Accept') normalizeHeaderName(headers, 'Content-Type') if ( utils$6.isFormData(data2) || utils$6.isArrayBuffer(data2) || utils$6.isBuffer(data2) || utils$6.isStream(data2) || utils$6.isFile(data2) || utils$6.isBlob(data2) ) { return data2 } if (utils$6.isArrayBufferView(data2)) { return data2.buffer } if (utils$6.isURLSearchParams(data2)) { setContentTypeIfUnset( headers, 'application/x-www-form-urlencoded;charset=utf-8' ) return data2.toString() } if ( utils$6.isObject(data2) || (headers && headers['Content-Type'] === 'application/json') ) { setContentTypeIfUnset(headers, 'application/json') return stringifySafely(data2) } return data2 }, ], transformResponse: [ function transformResponse(data2) { var transitional2 = this.transitional || defaults$5.transitional var silentJSONParsing = transitional2 && transitional2.silentJSONParsing var forcedJSONParsing = transitional2 && transitional2.forcedJSONParsing var strictJSONParsing = !silentJSONParsing && this.responseType === 'json' if ( strictJSONParsing || (forcedJSONParsing && utils$6.isString(data2) && data2.length) ) { try { return JSON.parse(data2) } catch (e2) { if (strictJSONParsing) { if (e2.name === 'SyntaxError') { throw enhanceError(e2, this, 'E_JSON_PARSE') } throw e2 } } } return data2 }, ], timeout: 0, xsrfCookieName: 'XSRF-TOKEN', xsrfHeaderName: 'X-XSRF-TOKEN', maxContentLength: -1, maxBodyLength: -1, validateStatus: function validateStatus(status) { return status >= 200 && status < 300 }, headers: { common: { Accept: 'application/json, text/plain, */*', }, }, } utils$6.forEach( ['delete', 'get', 'head'], function forEachMethodNoData(method4) { defaults$5.headers[method4] = {} } ) utils$6.forEach( ['post', 'put', 'patch'], function forEachMethodWithData(method4) { defaults$5.headers[method4] = utils$6.merge(DEFAULT_CONTENT_TYPE) } ) var defaults_1 = defaults$5 var utils$5 = utils$e var defaults$4 = defaults_1 var transformData$1 = function transformData2(data2, headers, fns) { var context2 = this || defaults$4 utils$5.forEach(fns, function transform3(fn2) { data2 = fn2.call(context2, data2, headers) }) return data2 } var isCancel$1 = function isCancel2(value2) { return !!(value2 && value2.__CANCEL__) } var utils$4 = utils$e var transformData = transformData$1 var isCancel = isCancel$1 var defaults$3 = defaults_1 var Cancel$1 = Cancel_1 function throwIfCancellationRequested(config2) { if (config2.cancelToken) { config2.cancelToken.throwIfRequested() } if (config2.signal && config2.signal.aborted) { throw new Cancel$1('canceled') } } var dispatchRequest$1 = function dispatchRequest2(config2) { throwIfCancellationRequested(config2) config2.headers = config2.headers || {} config2.data = transformData.call( config2, config2.data, config2.headers, config2.transformRequest ) config2.headers = utils$4.merge( config2.headers.common || {}, config2.headers[config2.method] || {}, config2.headers ) utils$4.forEach( ['delete', 'get', 'head', 'post', 'put', 'patch', 'common'], function cleanHeaderConfig(method4) { delete config2.headers[method4] } ) var adapter = config2.adapter || defaults$3.adapter return adapter(config2).then( function onAdapterResolution(response) { throwIfCancellationRequested(config2) response.data = transformData.call( config2, response.data, response.headers, config2.transformResponse ) return response }, function onAdapterRejection(reason) { if (!isCancel(reason)) { throwIfCancellationRequested(config2) if (reason && reason.response) { reason.response.data = transformData.call( config2, reason.response.data, reason.response.headers, config2.transformResponse ) } } return Promise.reject(reason) } ) } var utils$3 = utils$e var mergeConfig$2 = function mergeConfig2(config1, config2) { config2 = config2 || {} var config3 = {} function getMergedValue(target2, source2) { if (utils$3.isPlainObject(target2) && utils$3.isPlainObject(source2)) { return utils$3.merge(target2, source2) } else if (utils$3.isPlainObject(source2)) { return utils$3.merge({}, source2) } else if (utils$3.isArray(source2)) { return source2.slice() } return source2 } function mergeDeepProperties(prop) { if (!utils$3.isUndefined(config2[prop])) { return getMergedValue(config1[prop], config2[prop]) } else if (!utils$3.isUndefined(config1[prop])) { return getMergedValue(void 0, config1[prop]) } } function valueFromConfig2(prop) { if (!utils$3.isUndefined(config2[prop])) { return getMergedValue(void 0, config2[prop]) } } function defaultToConfig2(prop) { if (!utils$3.isUndefined(config2[prop])) { return getMergedValue(void 0, config2[prop]) } else if (!utils$3.isUndefined(config1[prop])) { return getMergedValue(void 0, config1[prop]) } } function mergeDirectKeys(prop) { if (prop in config2) { return getMergedValue(config1[prop], config2[prop]) } else if (prop in config1) { return getMergedValue(void 0, config1[prop]) } } var mergeMap = { url: valueFromConfig2, method: valueFromConfig2, data: valueFromConfig2, baseURL: defaultToConfig2, transformRequest: defaultToConfig2, transformResponse: defaultToConfig2, paramsSerializer: defaultToConfig2, timeout: defaultToConfig2, timeoutMessage: defaultToConfig2, withCredentials: defaultToConfig2, adapter: defaultToConfig2, responseType: defaultToConfig2, xsrfCookieName: defaultToConfig2, xsrfHeaderName: defaultToConfig2, onUploadProgress: defaultToConfig2, onDownloadProgress: defaultToConfig2, decompress: defaultToConfig2, maxContentLength: defaultToConfig2, maxBodyLength: defaultToConfig2, transport: defaultToConfig2, httpAgent: defaultToConfig2, httpsAgent: defaultToConfig2, cancelToken: defaultToConfig2, socketPath: defaultToConfig2, responseEncoding: defaultToConfig2, validateStatus: mergeDirectKeys, } utils$3.forEach( Object.keys(config1).concat(Object.keys(config2)), function computeConfigValue(prop) { var merge2 = mergeMap[prop] || mergeDeepProperties var configValue = merge2(prop) ;(utils$3.isUndefined(configValue) && merge2 !== mergeDirectKeys) || (config3[prop] = configValue) } ) return config3 } var data$1 = { version: '0.24.0', } var VERSION$3 = data$1.version var validators$2 = {} ;['object', 'boolean', 'number', 'function', 'string', 'symbol'].forEach( function (type4, i2) { validators$2[type4] = function validator2(thing) { return typeof thing === type4 || 'a' + (i2 < 1 ? 'n ' : ' ') + type4 } } ) var deprecatedWarnings = {} validators$2.transitional = function transitional( validator2, version2, message2 ) { function formatMessage(opt, desc) { return ( '[Axios v' + VERSION$3 + "] Transitional option '" + opt + "'" + desc + (message2 ? '. ' + message2 : '') ) } return function (value2, opt, opts) { if (validator2 === false) { throw new Error( formatMessage( opt, ' has been removed' + (version2 ? ' in ' + version2 : '') ) ) } if (version2 && !deprecatedWarnings[opt]) { deprecatedWarnings[opt] = true console.warn( formatMessage( opt, ' has been deprecated since v' + version2 + ' and will be removed in the near future' ) ) } return validator2 ? validator2(value2, opt, opts) : true } } function assertOptions(options2, schema, allowUnknown) { if (typeof options2 !== 'object') { throw new TypeError('options must be an object') } var keys3 = Object.keys(options2) var i2 = keys3.length while (i2-- > 0) { var opt = keys3[i2] var validator2 = schema[opt] if (validator2) { var value2 = options2[opt] var result = value2 === void 0 || validator2(value2, opt, options2) if (result !== true) { throw new TypeError('option ' + opt + ' must be ' + result) } continue } if (allowUnknown !== true) { throw Error('Unknown option ' + opt) } } } var validator$1 = { assertOptions, validators: validators$2, } var utils$2 = utils$e var buildURL = buildURL$2 var InterceptorManager = InterceptorManager_1 var dispatchRequest = dispatchRequest$1 var mergeConfig$1 = mergeConfig$2 var validator = validator$1 var validators$1 = validator.validators function Axios$1(instanceConfig) { this.defaults = instanceConfig this.interceptors = { request: new InterceptorManager(), response: new InterceptorManager(), } } Axios$1.prototype.request = function request2(config2) { if (typeof config2 === 'string') { config2 = arguments[1] || {} config2.url = arguments[0] } else { config2 = config2 || {} } config2 = mergeConfig$1(this.defaults, config2) if (config2.method) { config2.method = config2.method.toLowerCase() } else if (this.defaults.method) { config2.method = this.defaults.method.toLowerCase() } else { config2.method = 'get' } var transitional2 = config2.transitional if (transitional2 !== void 0) { validator.assertOptions( transitional2, { silentJSONParsing: validators$1.transitional(validators$1.boolean), forcedJSONParsing: validators$1.transitional(validators$1.boolean), clarifyTimeoutError: validators$1.transitional(validators$1.boolean), }, false ) } var requestInterceptorChain = [] var synchronousRequestInterceptors = true this.interceptors.request.forEach(function unshiftRequestInterceptors( interceptor2 ) { if ( typeof interceptor2.runWhen === 'function' && interceptor2.runWhen(config2) === false ) { return } synchronousRequestInterceptors = synchronousRequestInterceptors && interceptor2.synchronous requestInterceptorChain.unshift( interceptor2.fulfilled, interceptor2.rejected ) }) var responseInterceptorChain = [] this.interceptors.response.forEach(function pushResponseInterceptors( interceptor2 ) { responseInterceptorChain.push(interceptor2.fulfilled, interceptor2.rejected) }) var promise2 if (!synchronousRequestInterceptors) { var chain = [dispatchRequest, void 0] Array.prototype.unshift.apply(chain, requestInterceptorChain) chain = chain.concat(responseInterceptorChain) promise2 = Promise.resolve(config2) while (chain.length) { promise2 = promise2.then(chain.shift(), chain.shift()) } return promise2 } var newConfig = config2 while (requestInterceptorChain.length) { var onFulfilled = requestInterceptorChain.shift() var onRejected = requestInterceptorChain.shift() try { newConfig = onFulfilled(newConfig) } catch (error2) { onRejected(error2) break } } try { promise2 = dispatchRequest(newConfig) } catch (error2) { return Promise.reject(error2) } while (responseInterceptorChain.length) { promise2 = promise2.then( responseInterceptorChain.shift(), responseInterceptorChain.shift() ) } return promise2 } Axios$1.prototype.getUri = function getUri(config2) { config2 = mergeConfig$1(this.defaults, config2) return buildURL( config2.url, config2.params, config2.paramsSerializer ).replace(/^\?/, '') } utils$2.forEach( ['delete', 'get', 'head', 'options'], function forEachMethodNoData2(method4) { Axios$1.prototype[method4] = function (url2, config2) { return this.request( mergeConfig$1(config2 || {}, { method: method4, url: url2, data: (config2 || {}).data, }) ) } } ) utils$2.forEach( ['post', 'put', 'patch'], function forEachMethodWithData2(method4) { Axios$1.prototype[method4] = function (url2, data2, config2) { return this.request( mergeConfig$1(config2 || {}, { method: method4, url: url2, data: data2, }) ) } } ) var Axios_1 = Axios$1 var Cancel = Cancel_1 function CancelToken(executor) { if (typeof executor !== 'function') { throw new TypeError('executor must be a function.') } var resolvePromise this.promise = new Promise(function promiseExecutor(resolve2) { resolvePromise = resolve2 }) var token = this this.promise.then(function (cancel2) { if (!token._listeners) return var i2 var l2 = token._listeners.length for (i2 = 0; i2 < l2; i2++) { token._listeners[i2](cancel2) } token._listeners = null }) this.promise.then = function (onfulfilled) { var _resolve var promise2 = new Promise(function (resolve2) { token.subscribe(resolve2) _resolve = resolve2 }).then(onfulfilled) promise2.cancel = function reject2() { token.unsubscribe(_resolve) } return promise2 } executor(function cancel2(message2) { if (token.reason) { return } token.reason = new Cancel(message2) resolvePromise(token.reason) }) } CancelToken.prototype.throwIfRequested = function throwIfRequested() { if (this.reason) { throw this.reason } } CancelToken.prototype.subscribe = function subscribe(listener) { if (this.reason) { listener(this.reason) return } if (this._listeners) { this._listeners.push(listener) } else { this._listeners = [listener] } } CancelToken.prototype.unsubscribe = function unsubscribe(listener) { if (!this._listeners) { return } var index2 = this._listeners.indexOf(listener) if (index2 !== -1) { this._listeners.splice(index2, 1) } } CancelToken.source = function source() { var cancel2 var token = new CancelToken(function executor(c2) { cancel2 = c2 }) return { token, cancel: cancel2, } } var CancelToken_1 = CancelToken var spread = function spread2(callback) { return function wrap(arr) { return callback.apply(null, arr) } } var isAxiosError = function isAxiosError2(payload) { return typeof payload === 'object' && payload.isAxiosError === true } var utils$1 = utils$e var bind$9 = bind$b var Axios = Axios_1 var mergeConfig = mergeConfig$2 var defaults$2 = defaults_1 function createInstance(defaultConfig) { var context2 = new Axios(defaultConfig) var instance = bind$9(Axios.prototype.request, context2) utils$1.extend(instance, Axios.prototype, context2) utils$1.extend(instance, context2) instance.create = function create3(instanceConfig) { return createInstance(mergeConfig(defaultConfig, instanceConfig)) } return instance } var axios$1 = createInstance(defaults$2) axios$1.Axios = Axios axios$1.Cancel = Cancel_1 axios$1.CancelToken = CancelToken_1 axios$1.isCancel = isCancel$1 axios$1.VERSION = data$1.version axios$1.all = function all(promises) { return Promise.all(promises) } axios$1.spread = spread axios$1.isAxiosError = isAxiosError axios$2.exports = axios$1 axios$2.exports.default = axios$1 var axios = axios$2.exports var index$p = /* @__PURE__ */ _mergeNamespaces( { __proto__: null, default: axios, }, [axios] ) const Local = { set(key2, val2) { let stringify2 = val2 if (typeof val2 === 'object') { stringify2 = JSON.stringify(val2) } window.localStorage.setItem(key2, stringify2) }, get(key2) { let json = window.localStorage.getItem(key2) if (json === 'undefined') { return void 0 } try { return JSON.parse(json) } catch (error2) { return json } }, remove(key2) { window.localStorage.removeItem(key2) }, clear() { window.localStorage.clear() }, } const Session = { set(key2, val2) { let json = val2 if (typeof val2 === 'object') { json = JSON.stringify(val2) } window.sessionStorage.setItem(key2, json) }, get(key2) { let json = window.sessionStorage.getItem(key2) if (json === 'undefined') { return void 0 } try { return JSON.parse(json) } catch (error2) { return json } }, remove(key2) { window.sessionStorage.removeItem(key2) }, clear() { window.sessionStorage.clear() }, } window.Local = Local window.Session = Session function toast(messageOrOptions, type4, duration2) { let elMessage setTimeout(() => { elMessage = ElMessage({ message: String(messageOrOptions), type: type4, duration: duration2, grouping: true, showClose: true, ...Object(typeof messageOrOptions === 'object' ? messageOrOptions : {}), }) }) return { close() { setTimeout(() => { elMessage?.close() }) }, } } function createSingleToast() { let single return function singleToast2(...args) { single?.close() single = toast(...args) } } window.toast = toast var af = { name: 'af', el: { colorpicker: { confirm: 'Bevestig', clear: 'Maak skoon', }, datepicker: { now: 'Nou', today: 'Vandag', cancel: 'Kanselleer', clear: 'Maak skoon', confirm: 'Bevestig', selectDate: 'Kies datum', selectTime: 'Kies tyd', startDate: 'Begindatum', startTime: 'Begintyd', endDate: 'Einddatum', endTime: 'Eindtyd', prevYear: 'Previous Year', nextYear: 'Next Year', prevMonth: 'Previous Month', nextMonth: 'Next Month', year: 'Jaar', month1: 'Jan', month2: 'Feb', month3: 'Mrt', month4: 'Apr', month5: 'Mei', month6: 'Jun', month7: 'Jul', month8: 'Aug', month9: 'Sep', month10: 'Okt', month11: 'Nov', month12: 'Des', weeks: { sun: 'So', mon: 'Ma', tue: 'Di', wed: 'Wo', thu: 'Do', fri: 'Vr', sat: 'Sa', }, months: { jan: 'Jan', feb: 'Feb', mar: 'Mrt', apr: 'Apr', may: 'Mei', jun: 'Jun', jul: 'Jul', aug: 'Aug', sep: 'Sep', oct: 'Okt', nov: 'Nov', dec: 'Des', }, }, select: { loading: 'Laai', noMatch: 'Geen toepaslike data', noData: 'Geen data', placeholder: 'Kies', }, cascader: { noMatch: 'Geen toepaslike data', loading: 'Laai', placeholder: 'Kies', noData: 'Geen data', }, pagination: { goto: 'Gaan na', pagesize: '/page', total: 'Totaal {total}', pageClassifier: '', }, messagebox: { title: 'Boodskap', confirm: 'Bevestig', cancel: 'Kanselleer', error: 'Ongeldige invoer', }, upload: { deleteTip: 'press delete to remove', delete: 'Verwyder', preview: 'Voorskou', continue: 'Gaan voort', }, table: { emptyText: 'Geen Data', confirmFilter: 'Bevestig', resetFilter: 'Herstel', clearFilter: 'Alles', sumText: 'Som', }, tree: { emptyText: 'Geen Data', }, transfer: { noMatch: 'Geen toepaslike data', noData: 'Geen data', titles: ['Lys 1', 'Lys 2'], filterPlaceholder: 'Voer sleutelwoord in', noCheckedFormat: '{total} items', hasCheckedFormat: '{checked}/{total} gekies', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_0 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: af, }, Symbol.toStringTag, { value: 'Module' } ) ) var ar = { name: 'ar', el: { colorpicker: { confirm: '\u0645\u0648\u0627\u0641\u0642', clear: '\u0625\u0632\u0627\u0644\u0629', }, datepicker: { now: '\u0627\u0644\u0622\u0646', today: '\u0627\u0644\u064A\u0648\u0645', cancel: '\u0625\u0644\u063A\u0627\u0621', clear: '\u0625\u0632\u0627\u0644\u0629', confirm: '\u0645\u0648\u0627\u0641\u0642', selectDate: '\u0625\u062E\u062A\u0631 \u0627\u0644\u062A\u0627\u0631\u064A\u062E', selectTime: '\u0625\u062E\u062A\u0631 \u0627\u0644\u0648\u0642\u062A', startDate: '\u062A\u0627\u0631\u064A\u062E \u0627\u0644\u0628\u062F\u0621', startTime: '\u0648\u0642\u062A \u0627\u0644\u0628\u062F\u0621', endDate: '\u062A\u0627\u0631\u064A\u062E \u0627\u0644\u0625\u0646\u062A\u0647\u0627\u0621', endTime: '\u0648\u0642\u062A \u0627\u0644\u0625\u0646\u062A\u0647\u0627\u0621', prevYear: '\u0627\u0644\u0633\u0646\u0629 \u0627\u0644\u0633\u0627\u0628\u0642\u0629', nextYear: '\u0627\u0644\u0633\u0646\u0629 \u0627\u0644\u062A\u0627\u0644\u064A\u0629', prevMonth: '\u0627\u0644\u0634\u0647\u0631 \u0627\u0644\u0633\u0627\u0628\u0642', nextMonth: '\u0627\u0644\u0634\u0647\u0631 \u0627\u0644\u062A\u0627\u0644\u064A', year: '\u0633\u0646\u0629', month1: '\u064A\u0646\u0627\u064A\u0631', month2: '\u0641\u0628\u0631\u0627\u064A\u0631', month3: '\u0645\u0627\u0631\u0633', month4: '\u0627\u0628\u0631\u064A\u0644', month5: '\u0645\u0627\u064A\u0648', month6: '\u064A\u0648\u0646\u064A\u0648', month7: '\u064A\u0648\u0644\u064A\u0648', month8: '\u0623\u063A\u0633\u0637\u0633', month9: '\u0633\u0628\u062A\u0645\u0628\u0631', month10: '\u0623\u0643\u062A\u0648\u0628\u0631', month11: '\u0646\u0648\u0641\u0645\u0628\u0631', month12: '\u062F\u064A\u0633\u0645\u0628\u0631', week: '\u0623\u0633\u0628\u0648\u0639', weeks: { sun: '\u0627\u0644\u0623\u062D\u062F', mon: '\u0627\u0644\u0623\u062B\u0646\u064A\u0646', tue: '\u0627\u0644\u062B\u0644\u0627\u062B\u0627\u0621', wed: '\u0627\u0644\u0623\u0631\u0628\u0639\u0627\u0621', thu: '\u0627\u0644\u062E\u0645\u064A\u0633', fri: '\u0627\u0644\u062C\u0645\u0639\u0629', sat: '\u0627\u0644\u0633\u0628\u062A', }, months: { jan: '\u064A\u0646\u0627\u064A\u0631', feb: '\u0641\u0628\u0631\u0627\u064A\u0631', mar: '\u0645\u0627\u0631\u0633', apr: '\u0623\u0628\u0631\u064A\u0644', may: '\u0645\u0627\u064A\u0648', jun: '\u064A\u0648\u0646\u064A\u0648', jul: '\u064A\u0648\u0644\u064A\u0648', aug: '\u0623\u063A\u0633\u0637\u0633', sep: '\u0633\u0628\u062A\u0645\u0628\u0631', oct: '\u0623\u0643\u062A\u0648\u0628\u0631', nov: '\u0646\u0648\u0641\u0645\u0628\u0631', dec: '\u062F\u064A\u0633\u0645\u0628\u0631', }, }, select: { loading: '\u062C\u0627\u0631 \u0627\u0644\u062A\u062D\u0645\u064A\u0644', noMatch: '\u0644\u0627\u064A\u0648\u062C\u062F \u0628\u064A\u0627\u0646\u0627\u062A \u0645\u0637\u0627\u0628\u0642\u0629', noData: '\u0644\u0627\u064A\u0648\u062C\u062F \u0628\u064A\u0627\u0646\u0627\u062A', placeholder: '\u0625\u062E\u062A\u0631', }, cascader: { noMatch: '\u0644\u0627\u064A\u0648\u062C\u062F \u0628\u064A\u0627\u0646\u0627\u062A \u0645\u0637\u0627\u0628\u0642\u0629', loading: '\u062C\u0627\u0631 \u0627\u0644\u062A\u062D\u0645\u064A\u0644', placeholder: '\u0625\u062E\u062A\u0631', noData: '\u0644\u0627\u064A\u0648\u062C\u062F \u0628\u064A\u0627\u0646\u0627\u062A', }, pagination: { goto: '\u0623\u0630\u0647\u0628 \u0625\u0644\u0649', pagesize: '/\u0635\u0641\u062D\u0629', total: '\u0627\u0644\u0643\u0644 {total}', pageClassifier: '', }, messagebox: { title: '\u0627\u0644\u0639\u0646\u0648\u0627\u0646', confirm: '\u0645\u0648\u0627\u0641\u0642', cancel: '\u0625\u0644\u063A\u0627\u0621', error: '\u0645\u062F\u062E\u0644 \u063A\u064A\u0631 \u0635\u062D\u064A\u062D', }, upload: { delete: '\u062D\u0630\u0641', preview: '\u0639\u0631\u0636', continue: '\u0625\u0633\u062A\u0645\u0631\u0627\u0631', }, table: { emptyText: '\u0644\u0627\u064A\u0648\u062C\u062F \u0628\u064A\u0627\u0646\u0627\u062A', confirmFilter: '\u062A\u0623\u0643\u064A\u062F', resetFilter: '\u062D\u0630\u0641', clearFilter: '\u0627\u0644\u0643\u0644', sumText: '\u0627\u0644\u0645\u062C\u0645\u0648\u0639', }, tree: { emptyText: '\u0644\u0627\u064A\u0648\u062C\u062F \u0628\u064A\u0627\u0646\u0627\u062A', }, transfer: { noMatch: '\u0644\u0627\u064A\u0648\u062C\u062F \u0628\u064A\u0627\u0646\u0627\u062A \u0645\u0637\u0627\u0628\u0642\u0629', noData: '\u0644\u0627\u064A\u0648\u062C\u062F \u0628\u064A\u0627\u0646\u0627\u062A', titles: [ '\u0642\u0627\u0626\u0645\u0629 1', '\u0642\u0627\u0626\u0645\u0629 2', ], filterPlaceholder: '\u0627\u062F\u062E\u0644 \u0643\u0644\u0645\u0629', noCheckedFormat: '{total} \u0639\u0646\u0627\u0635\u0631', hasCheckedFormat: '{checked}/{total} \u0645\u062E\u062A\u0627\u0631', }, image: { error: '\u0641\u0634\u0644', }, pageHeader: { title: '\u0639\u0648\u062F\u0629', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_1 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: ar, }, Symbol.toStringTag, { value: 'Module' } ) ) var az = { name: 'az', el: { colorpicker: { confirm: 'T\u0259sdiql\u0259', clear: 'T\u0259mizl\u0259', }, datepicker: { now: '\u0130ndi', today: 'Bug\xFCn', cancel: '\u0130mtina', clear: 'T\u0259mizl\u0259', confirm: 'T\u0259sdiql\u0259', selectDate: 'Tarix se\xE7', selectTime: 'Saat se\xE7', startDate: 'Ba\u015Flan\u011F\u0131c Tarixi', startTime: 'Ba\u015Flan\u011F\u0131c Saat\u0131', endDate: 'Bitm\u0259 Tarixi', endTime: 'Bitm\u0259 Saat\u0131', prevYear: '\xD6nc\u0259ki il', nextYear: 'Sonrak\u0131 il', prevMonth: '\xD6nc\u0259ki ay', nextMonth: 'Sonrak\u0131 ay', year: '', month1: 'Yanvar', month2: 'Fevral', month3: 'Mart', month4: 'Aprel', month5: 'May', month6: '\u0130yun', month7: '\u0130yul', month8: 'Avqust', month9: 'Sentyabr', month10: 'Oktyabr', month11: 'Noyabr', month12: 'Dekabr', week: 'h\u0259ft\u0259', weeks: { sun: 'Baz', mon: 'B.e', tue: '\xC7.a', wed: '\xC7\u0259r', thu: 'C.a', fri: 'C\xFCm', sat: '\u015E\u0259n', }, months: { jan: 'Yan', feb: 'Fev', mar: 'Mar', apr: 'Apr', may: 'May', jun: '\u0130yn', jul: '\u0130yl', aug: 'Avq', sep: 'Sen', oct: 'Okt', nov: 'Noy', dec: 'Dek', }, }, select: { loading: 'Y\xFCkl\u0259nir', noMatch: 'N\u0259tic\u0259 tap\u0131lmad\u0131', noData: 'M\u0259lumat yoxdur', placeholder: 'Se\xE7', }, cascader: { noMatch: 'N\u0259tic\u0259 tap\u0131lmad\u0131', loading: 'Y\xFCkl\u0259nir', placeholder: 'Se\xE7', noData: 'M\u0259lumat yoxdur', }, pagination: { goto: 'Get', pagesize: '/s\u0259hif\u0259', total: 'Toplam {total}', pageClassifier: '', }, messagebox: { title: 'Mesaj', confirm: 'T\u0259sdiql\u0259', cancel: '\u0130mtina', error: 'S\u0259hv', }, upload: { deleteTip: 'S\xFCr\xFC\u015Fd\xFCrm\u0259d\u0259n sonra sil', delete: 'Sil', preview: '\xD6n izl\u0259', continue: 'Davam et', }, table: { emptyText: 'M\u0259lumat yoxdur', confirmFilter: 'T\u0259sdiql\u0259', resetFilter: 'S\u0131f\u0131rla', clearFilter: 'B\xFCt\xFCn', sumText: 'C\u0259mi', }, tree: { emptyText: 'M\u0259lumat yoxdur', }, transfer: { noMatch: 'N\u0259tic\u0259 tap\u0131lmad\u0131', noData: 'M\u0259lumat yoxdur', titles: ['Siyah\u0131 1', 'Siyah\u0131 2'], filterPlaceholder: 'K\u0259lim\u0259l\u0259ri daxil et', noCheckedFormat: '{total} \u0259d\u0259d', hasCheckedFormat: '{checked}/{total} se\xE7ildi', }, image: { error: 'S\u018FHV', }, pageHeader: { title: 'Geri', }, popconfirm: { confirmButtonText: 'B\u0259li', cancelButtonText: 'Xeyr', }, empty: { description: 'M\u0259lumat yoxdur', }, }, } var __glob_8_2 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: az, }, Symbol.toStringTag, { value: 'Module' } ) ) var bg = { name: 'bg', el: { colorpicker: { confirm: 'OK', clear: '\u0418\u0437\u0447\u0438\u0441\u0442\u0438', }, datepicker: { now: '\u0421\u0435\u0433\u0430', today: '\u0414\u043D\u0435\u0441', cancel: '\u041E\u0442\u043A\u0430\u0436\u0438', clear: '\u0418\u0437\u0447\u0438\u0441\u0442\u0438', confirm: '\u041E\u041A', selectDate: '\u0418\u0437\u0431\u0435\u0440\u0438 \u0434\u0430\u0442\u0430', selectTime: '\u0418\u0437\u0431\u0435\u0440\u0438 \u0447\u0430\u0441', startDate: '\u041D\u0430\u0447\u0430\u043B\u043D\u0430 \u0434\u0430\u0442\u0430', startTime: '\u041D\u0430\u0447\u0430\u043B\u0435\u043D \u0447\u0430\u0441', endDate: '\u041A\u0440\u0430\u0439\u043D\u0430 \u0434\u0430\u0442\u0430', endTime: '\u041A\u0440\u0430\u0435\u043D \u0447\u0430\u0441', prevYear: 'Previous Year', nextYear: 'Next Year', prevMonth: 'Previous Month', nextMonth: 'Next Month', year: '', month1: '\u042F\u043D\u0443\u0430\u0440\u0438', month2: '\u0424\u0435\u0432\u0440\u0443\u0430\u0440\u0438', month3: '\u041C\u0430\u0440\u0442', month4: '\u0410\u043F\u0440\u0438\u043B', month5: '\u041C\u0430\u0439', month6: '\u042E\u043D\u0438', month7: '\u042E\u043B\u0438', month8: '\u0410\u0432\u0433\u0443\u0441\u0442', month9: '\u0421\u0435\u043F\u0442\u0435\u043C\u0432\u0440\u0438', month10: '\u041E\u043A\u0442\u043E\u043C\u0432\u0440\u0438', month11: '\u041D\u043E\u0435\u043C\u0432\u0440\u0438', month12: '\u0414\u0435\u043A\u0435\u043C\u0432\u0440\u0438', weeks: { sun: '\u041D\u0435\u0434', mon: '\u041F\u043E\u043D', tue: '\u0412\u0442\u043E', wed: '\u0421\u0440\u044F', thu: '\u0427\u0435\u0442', fri: '\u041F\u0435\u0442', sat: '\u0421\u044A\u0431', }, months: { jan: '\u042F\u043D\u0443', feb: '\u0424\u0435\u0432', mar: '\u041C\u0430\u0440', apr: '\u0410\u043F\u0440', may: '\u041C\u0430\u0439', jun: '\u042E\u043D\u0438', jul: '\u042E\u043B\u0438', aug: '\u0410\u0432\u0433', sep: '\u0421\u0435\u043F', oct: '\u041E\u043A\u0442', nov: '\u041D\u043E\u0435', dec: '\u0414\u0435\u043A', }, }, select: { loading: '\u0417\u0430\u0440\u0435\u0436\u0434\u0430\u043D\u0435', noMatch: '\u041D\u044F\u043C\u0430 \u043D\u0430\u043C\u0435\u0440\u0435\u043D\u0438', noData: '\u041D\u044F\u043C\u0430 \u0434\u0430\u043D\u043D\u0438', placeholder: '\u0418\u0437\u0431\u0435\u0440\u0438', }, cascader: { noMatch: '\u041D\u044F\u043C\u0430 \u043D\u0430\u043C\u0435\u0440\u0435\u043D\u0438', loading: '\u0417\u0430\u0440\u0435\u0436\u0434\u0430\u043D\u0435', placeholder: '\u0418\u0437\u0431\u0435\u0440\u0438', noData: '\u041D\u044F\u043C\u0430 \u0434\u0430\u043D\u043D\u0438', }, pagination: { goto: '\u0418\u0434\u0438 \u043D\u0430', pagesize: '/\u0441\u0442\u0440\u0430\u043D\u0438\u0446\u0430', total: '\u041E\u0431\u0449\u043E {total}', pageClassifier: '', }, messagebox: { title: '\u0421\u044A\u043E\u0431\u0449\u0435\u043D\u0438\u0435', confirm: '\u041E\u041A', cancel: '\u041E\u0442\u043A\u0430\u0436\u0438', error: '\u041D\u0435\u0432\u0430\u043B\u0438\u0434\u043D\u0438 \u0434\u0430\u043D\u043D\u0438', }, upload: { deleteTip: 'press delete to remove', delete: '\u0418\u0437\u0442\u0440\u0438\u0439', preview: '\u041F\u0440\u0435\u0433\u043B\u0435\u0434\u0430\u0439', continue: '\u041F\u0440\u043E\u0434\u044A\u043B\u0436\u0438', }, table: { emptyText: '\u041D\u044F\u043C\u0430 \u0434\u0430\u043D\u043D\u0438', confirmFilter: '\u041F\u043E\u0442\u0432\u044A\u0440\u0434\u0438', resetFilter: '\u0418\u0437\u0447\u0438\u0441\u0442\u0438', clearFilter: '\u0412\u0441\u0438\u0447\u043A\u0438', sumText: 'Sum', }, tree: { emptyText: '\u041D\u044F\u043C\u0430 \u0434\u0430\u043D\u043D\u0438', }, transfer: { noMatch: '\u041D\u044F\u043C\u0430 \u043D\u0430\u043C\u0435\u0440\u0435\u043D\u0438', noData: '\u041D\u044F\u043C\u0430 \u0434\u0430\u043D\u043D\u0438', titles: ['List 1', 'List 2'], filterPlaceholder: 'Enter keyword', noCheckedFormat: '{total} items', hasCheckedFormat: '{checked}/{total} checked', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_3 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: bg, }, Symbol.toStringTag, { value: 'Module' } ) ) var bn = { name: 'bn', el: { colorpicker: { confirm: '\u09A0\u09BF\u0995 \u0986\u099B\u09C7', clear: '\u0995\u09CD\u09B2\u09BF\u09DF\u09BE\u09B0', }, datepicker: { now: '\u098F\u0996\u09A8', today: '\u0986\u099C', cancel: '\u09AC\u09BE\u09A4\u09BF\u09B2', clear: '\u0995\u09CD\u09B2\u09BF\u09DF\u09BE\u09B0', confirm: '\u09A0\u09BF\u0995 \u0986\u099B\u09C7', selectDate: '\u09A4\u09BE\u09B0\u09BF\u0996 \u09A8\u09BF\u09B0\u09CD\u09AC\u09BE\u099A\u09A8 \u0995\u09B0\u09C1\u09A8', selectTime: '\u09B8\u09AE\u09DF \u09A8\u09BF\u09B0\u09CD\u09AC\u09BE\u099A\u09A8 \u0995\u09B0\u09C1\u09A8', startDate: '\u09AF\u09C7 \u09A4\u09BE\u09B0\u09BF\u0996 \u09A5\u09C7\u0995\u09C7', startTime: '\u09AF\u09C7 \u09B8\u09AE\u09DF \u09A5\u09C7\u0995\u09C7', endDate: '\u09AF\u09C7 \u09A4\u09BE\u09B0\u09BF\u0996 \u09AA\u09B0\u09CD\u09AF\u09A8\u09CD\u09A4', endTime: '\u09AF\u09C7 \u09B8\u09AE\u09DF \u09AA\u09B0\u09CD\u09AF\u09A8\u09CD\u09A4', prevYear: '\u09AA\u09C2\u09B0\u09CD\u09AC\u09AC\u09B0\u09CD\u09A4\u09C0 \u09AC\u099B\u09B0', nextYear: '\u09AA\u09B0\u09AC\u09B0\u09CD\u09A4\u09C0 \u09AC\u099B\u09B0', prevMonth: '\u09AA\u09C2\u09B0\u09CD\u09AC\u09AC\u09B0\u09CD\u09A4\u09C0 \u09AE\u09BE\u09B8', nextMonth: '\u09AA\u09B0\u09AC\u09B0\u09CD\u09A4\u09C0 \u09AE\u09BE\u09B8', year: '\u09B8\u09BE\u09B2', month1: '\u099C\u09BE\u09A8\u09C1\u09DF\u09BE\u09B0\u09BF', month2: '\u09AB\u09C7\u09AC\u09CD\u09B0\u09C1\u09DF\u09BE\u09B0\u09C0', month3: '\u09AE\u09BE\u09B0\u09CD\u099A', month4: '\u098F\u09AA\u09CD\u09B0\u09BF\u09B2', month5: '\u09AE\u09C7', month6: '\u099C\u09C1\u09A8', month7: '\u099C\u09C1\u09B2\u09BE\u0987', month8: '\u0986\u0997\u09B7\u09CD\u099F', month9: '\u09B8\u09C7\u09AA\u09CD\u099F\u09C7\u09AE\u09CD\u09AC\u09B0', month10: '\u0985\u0995\u09CD\u099F\u09CB\u09AC\u09B0', month11: '\u09A8\u09AD\u09C7\u09AE\u09CD\u09AC\u09B0', month12: '\u09A1\u09BF\u09B8\u09C7\u09AE\u09CD\u09AC\u09B0', week: '\u09B8\u09BE\u09AA\u09CD\u09A4\u09BE\u09B9', weeks: { sun: '\u09B0\u09AC\u09BF', mon: '\u09B8\u09CB\u09AE', tue: '\u09AE\u0999\u09CD\u0997\u09B2', wed: '\u09AC\u09C1\u09A7', thu: '\u09AC\u09C3\u09B9\u0983', fri: '\u09B6\u09C1\u0995\u09CD\u09B0', sat: '\u09B6\u09A8\u09BF', }, months: { jan: '\u099C\u09BE\u09A8\u09C1', feb: '\u09AB\u09C7\u09AC\u09CD\u09B0\u09C1', mar: '\u09AE\u09BE\u09B0\u09CD\u099A', apr: '\u098F\u09AA\u09CD\u09B0\u09BF', may: '\u09AE\u09C7', jun: '\u099C\u09C1\u09A8', jul: '\u099C\u09C1\u09B2\u09BE', aug: '\u0986\u0997', sep: '\u09B8\u09C7\u09AA\u09CD\u099F\u09C7', oct: '\u0986\u0995\u09CD\u099F\u09CB', nov: '\u09A8\u09AD\u09C7', dec: '\u09A1\u09BF\u09B8\u09C7', }, }, select: { loading: '\u09B2\u09CB\u09A1 \u09B9\u099A\u09CD\u099B\u09C7', noMatch: '\u0995\u09CB\u09A8 \u09AE\u09BF\u09B2 \u09AA\u0993\u09DF\u09BE \u09AF\u09BE\u09DF\u09A8\u09BF', noData: '\u0995\u09CB\u09A8 \u09A1\u09BE\u099F\u09BE \u09A8\u09C7\u0987', placeholder: '\u09A8\u09BF\u09B0\u09CD\u09AC\u09BE\u099A\u09A8 \u0995\u09B0\u09C1\u09A8', }, cascader: { noMatch: '\u0995\u09CB\u09A8 \u09AE\u09BF\u09B2 \u09AA\u0993\u09DF\u09BE \u09AF\u09BE\u09DF\u09A8\u09BF', loading: '\u09B2\u09CB\u09A1 \u09B9\u099A\u09CD\u099B\u09C7', placeholder: '\u09A8\u09BF\u09B0\u09CD\u09AC\u09BE\u099A\u09A8 \u0995\u09B0\u09C1\u09A8', noData: '\u0995\u09CB\u09A8 \u09A1\u09BE\u099F\u09BE \u09A8\u09C7\u0987', }, pagination: { goto: '\u09AF\u09BE\u09A8', pagesize: '/\u09AA\u09C7\u099C', total: '\u09AE\u09CB\u099F {total}', pageClassifier: '', deprecationWarning: '\u0985\u09AA\u09CD\u09B0\u099A\u09B2\u09BF\u09A4 (Deprecated) \u09AC\u09CD\u09AF\u09BE\u09AC\u09B9\u09BE\u09B0 \u09AA\u0993\u09DF\u09BE \u0997\u09C7\u099B\u09C7, \u0986\u09B0\u0993 \u099C\u09BE\u09A8\u09A4\u09C7 \u099A\u09BE\u0987\u09B2\u09C7, \u09A6\u09DF\u09BE \u0995\u09B0\u09C7 el-pagination \u098F\u09B0 \u09A1\u0995\u09C1\u09AE\u09C7\u09A8\u09CD\u099F\u09C7\u09B6\u09A8 \u09A6\u09C7\u0996\u09C1\u09A8', }, messagebox: { title: '\u09AC\u09BE\u09B0\u09CD\u09A4\u09BE', confirm: '\u09A0\u09BF\u0995 \u0986\u099B\u09C7', cancel: '\u09AC\u09BE\u09A4\u09BF\u09B2', error: '\u0987\u09A8\u09AA\u09C1\u099F \u09A1\u09BE\u099F\u09BE \u0997\u09CD\u09B0\u09B9\u09A8\u09AF\u09CB\u0997\u09CD\u09AF \u09A8\u09DF', }, upload: { deleteTip: '\u0985\u09AA\u09B8\u09BE\u09B0\u09A3 \u0995\u09B0\u09A4\u09C7 "\u09A1\u09BF\u09B2\u09BF\u099F" \u098F \u0995\u09CD\u09B2\u09BF\u0995 \u0995\u09B0\u09C1\u09A8', delete: '\u09A1\u09BF\u09B2\u09BF\u099F', preview: '\u09AA\u09CD\u09B0\u09BF\u09AD\u09BF\u0989', continue: '\u099A\u09BE\u09B2\u09BF\u09DF\u09C7 \u09AF\u09BE\u09A8', }, table: { emptyText: '\u0995\u09CB\u09A8 \u09A1\u09BE\u099F\u09BE \u09A8\u09C7\u0987', confirmFilter: '\u09A8\u09BF\u09B6\u09CD\u099A\u09BF\u09A4 \u0995\u09B0\u09C1\u09A8', resetFilter: '\u09B0\u09BF\u09B8\u09C7\u099F', clearFilter: '\u09B8\u09AC', sumText: '\u09B8\u09BE\u09B0\u09BE\u0982\u09B6', }, tree: { emptyText: '\u0995\u09CB\u09A8 \u09A1\u09BE\u099F\u09BE \u09A8\u09C7\u0987', }, transfer: { noMatch: '\u0995\u09CB\u09A8 \u09AE\u09BF\u09B2 \u09AA\u0993\u09DF\u09BE \u09AF\u09BE\u09DF\u09A8\u09BF', noData: '\u0995\u09CB\u09A8 \u09A1\u09BE\u099F\u09BE \u09A8\u09C7\u0987', titles: [ '\u09B2\u09BF\u09B8\u09CD\u099F \u09E7', '\u09B2\u09BF\u09B8\u09CD\u099F \u09E8', ], filterPlaceholder: '\u09B8\u09BE\u09B0\u09CD\u099A \u0995\u09B0\u09C1\u09A8', noCheckedFormat: '{total} \u0986\u0987\u099F\u09C7\u09AE', hasCheckedFormat: '{checked}/{total} \u099F\u09BF\u0995 \u0995\u09B0\u09BE \u09B9\u09DF\u09C7\u099B\u09C7', }, image: { error: '\u09AC\u09CD\u09AF\u09B0\u09CD\u09A5 \u09B9\u09DF\u09C7\u099B\u09C7', }, pageHeader: { title: '\u09AA\u09BF\u099B\u09A8\u09C7', }, popconfirm: { confirmButtonText: '\u09B9\u09CD\u09AF\u09BE', cancelButtonText: '\u09A8\u09BE', }, }, } var __glob_8_4 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: bn, }, Symbol.toStringTag, { value: 'Module' } ) ) var ca = { name: 'ca', el: { colorpicker: { confirm: 'Confirmar', clear: 'Netejar', }, datepicker: { now: 'Ara', today: 'Avui', cancel: 'Cancel\xB7lar', clear: 'Netejar', confirm: 'Confirmar', selectDate: 'Seleccionar data', selectTime: 'Seleccionar hora', startDate: 'Data Inici', startTime: 'Hora Inici', endDate: 'Data Final', endTime: 'Hora Final', prevYear: 'Any anterior', nextYear: 'Pr\xF2xim Any', prevMonth: 'Mes anterior', nextMonth: 'Pr\xF2xim Mes', year: '', month1: 'Gener', month2: 'Febrer', month3: 'Mar\xE7', month4: 'Abril', month5: 'Maig', month6: 'Juny', month7: 'Juliol', month8: 'Agost', month9: 'Setembre', month10: 'Octubre', month11: 'Novembre', month12: 'Desembre', weeks: { sun: 'Dg', mon: 'Dl', tue: 'Dt', wed: 'Dc', thu: 'Dj', fri: 'Dv', sat: 'Ds', }, months: { jan: 'Gen', feb: 'Febr', mar: 'Mar\xE7', apr: 'Abr', may: 'Maig', jun: 'Juny', jul: 'Jul', aug: 'Ag', sep: 'Set', oct: 'Oct', nov: 'Nov', dec: 'Des', }, }, select: { loading: 'Carregant', noMatch: 'No hi ha dades que coincideixin', noData: 'Sense Dades', placeholder: 'Seleccionar', }, cascader: { noMatch: 'No hi ha dades que coincideixin', loading: 'Carregant', placeholder: 'Seleccionar', noData: 'Sense Dades', }, pagination: { goto: 'Anar a', pagesize: '/p\xE0gina', total: 'Total {total}', pageClassifier: '', }, messagebox: { confirm: 'Acceptar', cancel: 'Cancel\xB7lar', error: 'Entrada inv\xE0lida', }, upload: { deleteTip: 'premi eliminar per descartar', delete: 'Eliminar', preview: 'Vista Pr\xE8via', continue: 'Continuar', }, table: { emptyText: 'Sense Dades', confirmFilter: 'Confirmar', resetFilter: 'Netejar', clearFilter: 'Tot', sumText: 'Tot', }, tree: { emptyText: 'Sense Dades', }, transfer: { noMatch: 'No hi ha dades que coincideixin', noData: 'Sense Dades', titles: ['Llista 1', 'Llista 2'], filterPlaceholder: 'Introdueix la paraula clau', noCheckedFormat: '{total} \xEDtems', hasCheckedFormat: '{checked}/{total} seleccionats', }, image: { error: 'HA FALLAT', }, pageHeader: { title: 'Tornar', }, popconfirm: { confirmButtonText: 'S\xED', cancelButtonText: 'No', }, }, } var __glob_8_5 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: ca, }, Symbol.toStringTag, { value: 'Module' } ) ) var cs = { name: 'cs', el: { colorpicker: { confirm: 'OK', clear: 'Vymazat', }, datepicker: { now: 'Te\u010F', today: 'Dnes', cancel: 'Zru\u0161it', clear: 'Vymazat', confirm: 'OK', selectDate: 'Vybrat datum', selectTime: 'Vybrat \u010Das', startDate: 'Datum za\u010D\xE1tku', startTime: '\u010Cas za\u010D\xE1tku', endDate: 'Datum konce', endTime: '\u010Cas konce', prevYear: 'P\u0159edchoz\xED rok', nextYear: 'P\u0159\xED\u0161t\xED rok', prevMonth: 'P\u0159edchoz\xED m\u011Bs\xEDc', nextMonth: 'P\u0159\xED\u0161t\xED m\u011Bs\xEDc', day: 'Den', week: 'T\xFDden', month: 'M\u011Bs\xEDc', year: 'Rok', month1: 'Leden', month2: '\xDAnor', month3: 'B\u0159ezen', month4: 'Duben', month5: 'Kv\u011Bten', month6: '\u010Cerven', month7: '\u010Cervenec', month8: 'Srpen', month9: 'Z\xE1\u0159\xED', month10: '\u0158\xEDjen', month11: 'Listopad', month12: 'Prosinec', weeks: { sun: 'Ne', mon: 'Po', tue: '\xDAt', wed: 'St', thu: '\u010Ct', fri: 'P\xE1', sat: 'So', }, months: { jan: 'Led', feb: '\xDAno', mar: 'B\u0159e', apr: 'Dub', may: 'Kv\u011B', jun: '\u010Cer', jul: '\u010Cvc', aug: 'Srp', sep: 'Z\xE1\u0159', oct: '\u0158\xEDj', nov: 'Lis', dec: 'Pro', }, }, select: { loading: 'Na\u010D\xEDt\xE1n\xED', noMatch: '\u017D\xE1dn\xE1 shoda', noData: '\u017D\xE1dn\xE1 data', placeholder: 'Vybrat', }, cascader: { noMatch: '\u017D\xE1dn\xE1 shoda', loading: 'Na\u010D\xEDt\xE1n\xED', placeholder: 'Vybrat', noData: '\u017D\xE1dn\xE1 data', }, pagination: { goto: 'J\xEDt na', pagesize: 'na stranu', total: 'Celkem {total}', pageClassifier: '', }, messagebox: { title: 'Zpr\xE1va', confirm: 'OK', cancel: 'Zru\u0161it', error: 'Neplatn\xFD vstup', }, upload: { deleteTip: 'Stisknout pro smaz\xE1n\xED', delete: 'Vymazat', preview: 'N\xE1hled', continue: 'Pokra\u010Dovat', }, table: { emptyText: '\u017D\xE1dn\xE1 data', confirmFilter: 'Potvrdit', resetFilter: 'Resetovat', clearFilter: 'V\u0161e', sumText: 'Celkem', }, tree: { emptyText: '\u017D\xE1dn\xE1 data', }, transfer: { noMatch: '\u017D\xE1dn\xE1 shoda', noData: '\u017D\xE1dn\xE1 data', titles: ['Seznam 1', 'Seznam 2'], filterPlaceholder: 'Kl\xED\u010Dov\xE9 slovo', noCheckedFormat: '{total} polo\u017Eek', hasCheckedFormat: '{checked}/{total} vybr\xE1no', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_6 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: cs, }, Symbol.toStringTag, { value: 'Module' } ) ) var da = { name: 'da', el: { colorpicker: { confirm: 'OK', clear: 'Ryd', }, datepicker: { now: 'Nu', today: 'I dag', cancel: 'Annuller', clear: 'Ryd', confirm: 'OK', selectDate: 'V\xE6lg dato', selectTime: 'V\xE6lg tidspunkt', startDate: 'Startdato', startTime: 'Starttidspunkt', endDate: 'Slutdato', endTime: 'Sluttidspunkt', prevYear: 'Forrige \xE5r', nextYear: 'N\xE6ste \xE5r', prevMonth: 'Forrige m\xE5ned', nextMonth: 'N\xE6ste m\xE5ned', year: '', month1: 'Januar', month2: 'Februar', month3: 'Marts', month4: 'April', month5: 'Maj', month6: 'Juni', month7: 'Juli', month8: 'August', month9: 'September', month10: 'Oktober', month11: 'November', month12: 'December', week: 'uge', weeks: { sun: 'S\xF8n', mon: 'Man', tue: 'Tir', wed: 'Ons', thu: 'Tor', fri: 'Fre', sat: 'L\xF8r', }, months: { jan: 'Jan', feb: 'Feb', mar: 'Mar', apr: 'Apr', may: 'Maj', jun: 'Jun', jul: 'Jul', aug: 'Aug', sep: 'Sep', oct: 'Okt', nov: 'Nov', dec: 'Dec', }, }, select: { loading: 'Henter', noMatch: 'Ingen matchende data', noData: 'Ingen data', placeholder: 'V\xE6lg', }, cascader: { noMatch: 'Ingen matchende data', loading: 'Henter', placeholder: 'V\xE6lg', noData: 'Ingen data', }, pagination: { goto: 'G\xE5 til', pagesize: '/side', total: 'Total {total}', pageClassifier: '', }, messagebox: { confirm: 'OK', cancel: 'Annuller', error: 'Ugyldig input', }, upload: { deleteTip: 'tryk slet for at fjerne', delete: 'Slet', preview: 'Forh\xE5ndsvisning', continue: 'Forts\xE6t', }, table: { emptyText: 'Ingen data', confirmFilter: 'Bekr\xE6ft', resetFilter: 'Nulstil', clearFilter: 'Alle', sumText: 'Sum', }, tree: { emptyText: 'Ingen data', }, transfer: { noMatch: 'Ingen matchende data', noData: 'Ingen data', titles: ['Liste 1', 'Liste 2'], filterPlaceholder: 'Indtast s\xF8geord', noCheckedFormat: '{total} emner', hasCheckedFormat: '{checked}/{total} valgt', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_7 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: da, }, Symbol.toStringTag, { value: 'Module' } ) ) var de$1 = { name: 'de', el: { colorpicker: { confirm: 'OK', clear: 'Leeren', }, datepicker: { now: 'Jetzt', today: 'Heute', cancel: 'Abbrechen', clear: 'Leeren', confirm: 'OK', selectDate: 'Datum w\xE4hlen', selectTime: 'Uhrzeit w\xE4hlen', startDate: 'Startdatum', startTime: 'Startzeit', endDate: 'Enddatum', endTime: 'Endzeit', prevYear: 'Letztes Jahr', nextYear: 'N\xE4chtes Jahr', prevMonth: 'Letzter Monat', nextMonth: 'N\xE4chster Monat', day: 'Tag', week: 'Woche', month: 'Monat', year: '', month1: 'Januar', month2: 'Februar', month3: 'M\xE4rz', month4: 'April', month5: 'Mai', month6: 'Juni', month7: 'Juli', month8: 'August', month9: 'September', month10: 'Oktober', month11: 'November', month12: 'Dezember', weeks: { sun: 'So', mon: 'Mo', tue: 'Di', wed: 'Mi', thu: 'Do', fri: 'Fr', sat: 'Sa', }, months: { jan: 'Jan', feb: 'Feb', mar: 'M\xE4r', apr: 'Apr', may: 'Mai', jun: 'Jun', jul: 'Jul', aug: 'Aug', sep: 'Sep', oct: 'Okt', nov: 'Nov', dec: 'Dez', }, }, select: { loading: 'L\xE4dt.', noMatch: 'Nichts gefunden.', noData: 'Keine Daten', placeholder: 'Daten w\xE4hlen', }, cascader: { noMatch: 'Nichts gefunden.', loading: 'L\xE4dt.', placeholder: 'Daten w\xE4hlen', noData: 'Keine Daten', }, pagination: { goto: 'Gehe zu', pagesize: ' pro Seite', total: 'Gesamt {total}', pageClassifier: '', }, messagebox: { confirm: 'OK', cancel: 'Abbrechen', error: 'Fehler', }, upload: { deleteTip: 'Klicke l\xF6schen zum entfernen', delete: 'L\xF6schen', preview: 'Vorschau', continue: 'Fortsetzen', }, table: { emptyText: 'Keine Daten', confirmFilter: 'Anwenden', resetFilter: 'Zur\xFCcksetzen', clearFilter: 'Alles ', sumText: 'Summe', }, tree: { emptyText: 'Keine Eintr\xE4ge', }, transfer: { noMatch: 'Nichts gefunden.', noData: 'Keine Eintr\xE4ge', titles: ['Liste 1', 'Liste 2'], filterPlaceholder: 'Eintr\xE4ge filtern', noCheckedFormat: '{total} Eintr\xE4ge', hasCheckedFormat: '{checked}/{total} ausgew\xE4hlt', }, image: { error: 'FEHLGESCHLAGEN', }, pageHeader: { title: 'Zur\xFCck', }, popconfirm: { confirmButtonText: 'Ja', cancelButtonText: 'Nein', }, }, } var __glob_8_8 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: de$1, }, Symbol.toStringTag, { value: 'Module' } ) ) var el = { name: 'el', el: { colorpicker: { confirm: '\u0395\u03BD\u03C4\u03AC\u03BE\u03B5\u03B9', clear: '\u039A\u03B1\u03B8\u03B1\u03C1\u03B9\u03C3\u03BC\u03CC\u03C2', }, datepicker: { now: '\u03A4\u03CE\u03C1\u03B1', today: '\u03A3\u03AE\u03BC\u03B5\u03C1\u03B1', cancel: '\u0391\u03BA\u03CD\u03C1\u03C9\u03C3\u03B7', clear: '\u039A\u03B1\u03B8\u03B1\u03C1\u03B9\u03C3\u03BC\u03CC\u03C2', confirm: '\u0395\u03BD\u03C4\u03AC\u03BE\u03B5\u03B9', selectDate: '\u0395\u03C0\u03B9\u03BB\u03AD\u03BE\u03C4\u03B5 \u03B7\u03BC\u03AD\u03C1\u03B1', selectTime: '\u0395\u03C0\u03B9\u03BB\u03AD\u03BE\u03C4\u03B5 \u03CE\u03C1\u03B1', startDate: '\u0397\u03BC\u03B5\u03C1\u03BF\u03BC\u03B7\u03BD\u03AF\u03B1 \u0388\u03BD\u03B1\u03C1\u03BE\u03B7\u03C2', startTime: '\u03A9\u03C1\u03B1 \u0388\u03BD\u03B1\u03C1\u03BE\u03B7\u03C2', endDate: '\u0397\u03BC\u03B5\u03C1\u03BF\u03BC\u03B7\u03BD\u03AF\u03B1 \u039B\u03AE\u03BE\u03B7\u03C2', endTime: '\u03A9\u03C1\u03B1 \u039B\u03AE\u03BE\u03B7\u03C2', prevYear: '\u03A0\u03C1\u03BF\u03B7\u03B3\u03BF\u03CD\u03BC\u03B5\u03BD\u03BF \u0388\u03C4\u03BF\u03C2', nextYear: '\u0395\u03C0\u03CC\u03BC\u03B5\u03BD\u03BF \u0388\u03C4\u03BF\u03C2', prevMonth: '\u03A0\u03C1\u03BF\u03B7\u03B3\u03BF\u03CD\u03BC\u03B5\u03BD\u03BF\u03C2 \u039C\u03AE\u03BD\u03B1\u03C2', nextMonth: '\u0395\u03C0\u03CC\u03BC\u03B5\u03BD\u03BF\u03C2 \u039C\u03AE\u03BD\u03B1\u03C2', year: '\u0388\u03C4\u03BF\u03C2', month1: '\u0399\u03B1\u03BD\u03BF\u03C5\u03AC\u03C1\u03B9\u03BF\u03C2', month2: '\u03A6\u03B5\u03B2\u03C1\u03BF\u03C5\u03AC\u03C1\u03B9\u03BF\u03C2', month3: '\u039C\u03AC\u03C1\u03C4\u03B9\u03BF\u03C2', month4: '\u0391\u03C0\u03C1\u03AF\u03BB\u03B9\u03BF\u03C2', month5: '\u039C\u03AC\u03B9\u03BF\u03C2', month6: '\u0399\u03BF\u03CD\u03BD\u03B9\u03BF\u03C2', month7: '\u0399\u03BF\u03CD\u03BB\u03B9\u03BF\u03C2', month8: '\u0391\u03CD\u03B3\u03BF\u03C5\u03C3\u03C4\u03BF\u03C2', month9: '\u03A3\u03B5\u03C0\u03C4\u03AD\u03BC\u03B2\u03C1\u03B9\u03BF\u03C2', month10: '\u039F\u03BA\u03C4\u03CE\u03B2\u03C1\u03B9\u03BF\u03C2', month11: '\u039D\u03BF\u03AD\u03BC\u03B2\u03C1\u03B9\u03BF\u03C2', month12: '\u0394\u03B5\u03BA\u03AD\u03BC\u03B2\u03C1\u03B9\u03BF\u03C2', weeks: { sun: '\u039A\u03C5\u03C1', mon: '\u0394\u03B5\u03C5', tue: '\u03A4\u03C1\u03B9', wed: '\u03A4\u03B5\u03C4', thu: '\u03A0\u03B5\u03BC', fri: '\u03A0\u03B1\u03C1', sat: '\u03A3\u03B1\u03B2', }, months: { jan: '\u0399\u03B1\u03BD', feb: '\u03A6\u03B5\u03B2', mar: '\u039C\u03B1\u03C1', apr: '\u0391\u03C0\u03C1', may: '\u039C\u03B1\u03CA', jun: '\u0399\u03BF\u03C5\u03BD', jul: '\u0399\u03BF\u03C5\u03BB', aug: '\u0391\u03C5\u03B3', sep: '\u03A3\u03B5\u03C0', oct: '\u039F\u03BA\u03C4', nov: '\u039D\u03BF\u03B5', dec: '\u0394\u03B5\u03BA', }, }, select: { loading: '\u03A6\u03CC\u03C1\u03C4\u03C9\u03C3\u03B7', noMatch: '\u0394\u03B5\u03BD \u03B2\u03C1\u03AD\u03B8\u03B7\u03BA\u03B1\u03BD \u03B1\u03C0\u03BF\u03C4\u03B5\u03BB\u03AD\u03C3\u03BC\u03B1\u03C4\u03B1', noData: '\u03A7\u03C9\u03C1\u03AF\u03C2 \u03B4\u03B5\u03B4\u03BF\u03BC\u03AD\u03BD\u03B1', placeholder: '\u0395\u03C0\u03B9\u03BB\u03BF\u03B3\u03AE', }, cascader: { noMatch: '\u0394\u03B5\u03BD \u03B2\u03C1\u03AD\u03B8\u03B7\u03BA\u03B1\u03BD \u03B1\u03C0\u03BF\u03C4\u03B5\u03BB\u03AD\u03C3\u03BC\u03B1\u03C4\u03B1', loading: '\u03A6\u03CC\u03C1\u03C4\u03C9\u03C3\u03B7', placeholder: '\u0395\u03C0\u03B9\u03BB\u03BF\u03B3\u03AE', noData: '\u03A7\u03C9\u03C1\u03AF\u03C2 \u03B4\u03B5\u03B4\u03BF\u03BC\u03AD\u03BD\u03B1', }, pagination: { goto: '\u039C\u03B5\u03C4\u03AC\u03B2\u03B1\u03C3\u03B7 \u03C3\u03B5', pagesize: '/\u03C3\u03B5\u03BB\u03AF\u03B4\u03B1', total: '\u03A3\u03CD\u03BD\u03BF\u03BB\u03BF {total}', pageClassifier: '', }, messagebox: { title: '\u039C\u03AE\u03BD\u03C5\u03BC\u03B1', confirm: '\u0395\u03BD\u03C4\u03AC\u03BE\u03B5\u03B9', cancel: '\u0391\u03BA\u03CD\u03C1\u03C9\u03C3\u03B7', error: '\u0386\u03BA\u03C5\u03C1\u03B7 \u03B5\u03B9\u03C3\u03B1\u03B3\u03C9\u03B3\u03AE', }, upload: { deleteTip: '\u03A0\u03AC\u03C4\u03B7\u03C3\u03B5 \u0394\u03B9\u03B1\u03B3\u03C1\u03B1\u03C6\u03AE \u03B3\u03B9\u03B1 \u03B1\u03C6\u03B1\u03AF\u03C1\u03B5\u03C3\u03B7', delete: '\u0394\u03B9\u03B1\u03B3\u03C1\u03B1\u03C6\u03AE', preview: '\u03A0\u03C1\u03BF\u03B5\u03C0\u03B9\u03C3\u03BA\u03CC\u03C0\u03B7\u03C3\u03B7', continue: '\u03A3\u03C5\u03BD\u03AD\u03C7\u03B5\u03B9\u03B1', }, table: { emptyText: '\u03A7\u03C9\u03C1\u03AF\u03C2 \u0394\u03B5\u03B4\u03BF\u03BC\u03AD\u03BD\u03B1', confirmFilter: '\u0395\u03C0\u03B9\u03B2\u03B5\u03B2\u03B1\u03AF\u03C9\u03C3\u03B7', resetFilter: '\u0395\u03C0\u03B1\u03BD\u03B1\u03C6\u03BF\u03C1\u03AC', clearFilter: '\u038C\u03BB\u03B1', sumText: '\u03A3\u03CD\u03BD\u03BF\u03BB\u03BF', }, tree: { emptyText: '\u03A7\u03C9\u03C1\u03AF\u03C2 \u0394\u03B5\u03B4\u03BF\u03BC\u03AD\u03BD\u03B1', }, transfer: { noMatch: '\u0394\u03B5\u03BD \u03B2\u03C1\u03AD\u03B8\u03B7\u03BA\u03B1\u03BD \u03B1\u03C0\u03BF\u03C4\u03B5\u03BB\u03AD\u03C3\u03BC\u03B1\u03C4\u03B1', noData: '\u03A7\u03C9\u03C1\u03AF\u03C2 \u03B4\u03B5\u03B4\u03BF\u03BC\u03AD\u03BD\u03B1', titles: [ '\u039B\u03AF\u03C3\u03C4\u03B1 1', '\u039B\u03AF\u03C3\u03C4\u03B1 2', ], filterPlaceholder: '\u0391\u03BD\u03B1\u03B6\u03AE\u03C4\u03B7\u03C3\u03B7', noCheckedFormat: '{total} \u0391\u03BD\u03C4\u03B9\u03BA\u03B5\u03AF\u03BC\u03B5\u03BD\u03B1', hasCheckedFormat: '{checked}/{total} \u03B5\u03C0\u03B9\u03BB\u03B5\u03B3\u03BC\u03AD\u03BD\u03B1', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_9 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: el, }, Symbol.toStringTag, { value: 'Module' } ) ) var eo = { name: 'eo', el: { colorpicker: { confirm: 'Bone', clear: 'Malplenigi', }, datepicker: { now: 'Nun', today: 'Hodia\u016D', cancel: 'Nuligi', clear: 'Malplenigi', confirm: 'Bone', selectDate: 'Elektu daton', selectTime: 'Elektu horon', startDate: 'Komenca Dato', startTime: 'Komenca Horo', endDate: 'Fina Dato', endTime: 'Fina Horo', prevYear: 'Anta\u016Da Jaro', nextYear: 'Sekva Jaro', prevMonth: 'Anta\u016Da Monato', nextMonth: 'Sekva Monato', year: 'Jaro', month1: 'Januaro', month2: 'Februaro', month3: 'Marto', month4: 'Aprilo', month5: 'Majo', month6: 'Junio', month7: 'Julio', month8: 'A\u016Dgusto', month9: 'Septembro', month10: 'Oktobro', month11: 'Novembro', month12: 'Decembro', week: 'Semajno', weeks: { sun: 'Dim', mon: 'Lun', tue: 'Mar', wed: 'Mer', thu: '\u0134a\u016D', fri: 'Ven', sat: 'Sab', }, months: { jan: 'Jan', feb: 'Feb', mar: 'Mar', apr: 'Apr', may: 'Maj', jun: 'Jun', jul: 'Jul', aug: 'A\u016Dg', sep: 'Sep', oct: 'Okt', nov: 'Nov', dec: 'Dec', }, }, select: { loading: '\u015Car\u011Dante', noMatch: 'Neniuj kongruaj datumoj', noData: 'Neniuj datumoj', placeholder: 'Bonvolu elekti', }, cascader: { noMatch: 'Neniuj kongruaj datumoj', loading: '\u015Car\u011Dante', placeholder: 'Bonvolu elekti', noData: 'Neniuj datumoj', }, pagination: { goto: 'Iru al', pagesize: '/ pa\u011Do', total: 'Entute {total}', pageClassifier: '', }, messagebox: { title: 'Mesa\u011Do', confirm: 'Bone', cancel: 'Nuligi', error: 'Nevalida Enigo!', }, upload: { deleteTip: 'Premu "Delete" por forigi', delete: 'Forigi', preview: 'Anta\u016Drigardi', continue: 'Da\u016Drigi', }, table: { emptyText: 'Neniuj datumoj', confirmFilter: 'Konfirmi', resetFilter: 'Restarigi', clearFilter: '\u0108iuj', sumText: 'Sumo', }, tree: { emptyText: 'Neniuj datumoj', }, transfer: { noMatch: 'Neniuj kongruaj datumoj', noData: 'Neniuj datumoj', titles: ['Listo 1', 'Listo 2'], filterPlaceholder: 'Enigu \u015Dlosilvorton', noCheckedFormat: '{total} elementoj', hasCheckedFormat: '{checked}/{total} elektitaj', }, image: { error: 'MALSUKCESIS', }, pageHeader: { title: 'Reen', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_11 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: eo, }, Symbol.toStringTag, { value: 'Module' } ) ) var es = { name: 'es', el: { colorpicker: { confirm: 'Confirmar', clear: 'Despejar', }, datepicker: { now: 'Ahora', today: 'Hoy', cancel: 'Cancelar', clear: 'Despejar', confirm: 'Confirmar', selectDate: 'Seleccionar fecha', selectTime: 'Seleccionar hora', startDate: 'Fecha Incial', startTime: 'Hora Inicial', endDate: 'Fecha Final', endTime: 'Hora Final', prevYear: 'A\xF1o Anterior', nextYear: 'Pr\xF3ximo A\xF1o', prevMonth: 'Mes Anterior', nextMonth: 'Pr\xF3ximo Mes', year: '', month1: 'enero', month2: 'febrero', month3: 'marzo', month4: 'abril', month5: 'mayo', month6: 'junio', month7: 'julio', month8: 'agosto', month9: 'septiembre', month10: 'octubre', month11: 'noviembre', month12: 'diciembre', weeks: { sun: 'dom', mon: 'lun', tue: 'mar', wed: 'mi\xE9', thu: 'jue', fri: 'vie', sat: 's\xE1b', }, months: { jan: 'ene', feb: 'feb', mar: 'mar', apr: 'abr', may: 'may', jun: 'jun', jul: 'jul', aug: 'ago', sep: 'sep', oct: 'oct', nov: 'nov', dec: 'dic', }, }, select: { loading: 'Cargando', noMatch: 'No hay datos que coincidan', noData: 'Sin datos', placeholder: 'Seleccionar', }, cascader: { noMatch: 'No hay datos que coincidan', loading: 'Cargando', placeholder: 'Seleccionar', noData: 'Sin datos', }, pagination: { goto: 'Ir a', pagesize: '/p\xE1gina', total: 'Total {total}', pageClassifier: '', }, messagebox: { confirm: 'Aceptar', cancel: 'Cancelar', error: 'Entrada inv\xE1lida', }, upload: { deleteTip: 'Pulse Eliminar para retirar', delete: 'Eliminar', preview: 'Vista Previa', continue: 'Continuar', }, table: { emptyText: 'Sin Datos', confirmFilter: 'Confirmar', resetFilter: 'Reiniciar', clearFilter: 'Despejar', sumText: 'Suma', }, tree: { emptyText: 'Sin Datos', }, transfer: { noMatch: 'No hay datos que coincidan', noData: 'Sin datos', titles: ['Lista 1', 'Lista 2'], filterPlaceholder: 'Ingresar palabra clave', noCheckedFormat: '{total} art\xEDculos', hasCheckedFormat: '{checked}/{total} revisados', }, image: { error: 'HA FALLADO', }, pageHeader: { title: 'Volver', }, popconfirm: { confirmButtonText: 'Si', cancelButtonText: 'No', }, }, } var __glob_8_12 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: es, }, Symbol.toStringTag, { value: 'Module' } ) ) var et$2 = { name: 'et', el: { colorpicker: { confirm: 'OK', clear: 'T\xFChjenda', }, datepicker: { now: 'Praegu', today: 'T\xE4na', cancel: 'T\xFChista', clear: 'T\xFChjenda', confirm: 'OK', selectDate: 'Vali kuup\xE4ev', selectTime: 'Vali kellaaeg', startDate: 'Alguskuup\xE4ev', startTime: 'Algusaeg', endDate: 'L\xF5pukuup\xE4ev', endTime: 'L\xF5puaeg', prevYear: 'Eelmine aasta', nextYear: 'J\xE4rgmine aasta', prevMonth: 'Eelmine kuu', nextMonth: 'J\xE4rgmine kuu', year: '', month1: 'Jaanuar', month2: 'Veebruar', month3: 'M\xE4rts', month4: 'Aprill', month5: 'Mai', month6: 'Juuni', month7: 'Juuli', month8: 'August', month9: 'September', month10: 'Oktoober', month11: 'November', month12: 'Detsember', weeks: { sun: 'P', mon: 'E', tue: 'T', wed: 'K', thu: 'N', fri: 'R', sat: 'L', }, months: { jan: 'Jaan', feb: 'Veeb', mar: 'M\xE4r', apr: 'Apr', may: 'Mai', jun: 'Juun', jul: 'Juul', aug: 'Aug', sep: 'Sept', oct: 'Okt', nov: 'Nov', dec: 'Dets', }, }, select: { loading: 'Laadimine', noMatch: 'Sobivad andmed puuduvad', noData: 'Andmed puuduvad', placeholder: 'Vali', }, cascader: { noMatch: 'Sobivad andmed puuduvad', loading: 'Laadimine', placeholder: 'Vali', noData: 'Andmed puuduvad', }, pagination: { goto: 'Mine lehele', pagesize: '/page', total: 'Kokku {total}', pageClassifier: '', }, messagebox: { title: 'Teade', confirm: 'OK', cancel: 'T\xFChista', error: 'Vigane sisend', }, upload: { deleteTip: 'Vajuta "Kustuta", et eemaldada', delete: 'Kustuta', preview: 'Eelvaate', continue: 'J\xE4tka', }, table: { emptyText: 'Andmed puuduvad', confirmFilter: 'Kinnita', resetFilter: 'Taasta', clearFilter: 'K\xF5ik', sumText: 'Summa', }, tree: { emptyText: 'Andmed puuduvad', }, transfer: { noMatch: 'Sobivad andmed puuduvad', noData: 'Andmed puuduvad', titles: ['Loend 1', 'Loend 2'], filterPlaceholder: 'Sisesta m\xE4rks\xF5na', noCheckedFormat: '{total} objekti', hasCheckedFormat: '{checked}/{total} valitud', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_13 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: et$2, }, Symbol.toStringTag, { value: 'Module' } ) ) var eu = { name: 'eu', el: { colorpicker: { confirm: 'Ados', clear: 'Garbitu', }, datepicker: { now: 'Orain', today: 'Gaur', cancel: 'Utzi', clear: 'Garbitu', confirm: 'Ados', selectDate: 'Hautatu data', selectTime: 'Hautatu ordua', startDate: 'Hasierako data', startTime: 'Hasierako ordua', endDate: 'Amaierako data', endTime: 'Amaierako ordua', prevYear: 'Aurreko urtea', nextYear: 'Hurrengo urtea', prevMonth: 'Aurreko hilabetea', nextMonth: 'Hurrengo hilabetea', year: '', month1: 'Urtarrila', month2: 'Otsaila', month3: 'Martxoa', month4: 'Apirila', month5: 'Maiatza', month6: 'Ekaina', month7: 'Uztaila', month8: 'Abuztua', month9: 'Iraila', month10: 'Urria', month11: 'Azaroa', month12: 'Abendua', weeks: { sun: 'ig.', mon: 'al.', tue: 'ar.', wed: 'az.', thu: 'og.', fri: 'ol.', sat: 'lr.', }, months: { jan: 'urt', feb: 'ots', mar: 'mar', apr: 'api', may: 'mai', jun: 'eka', jul: 'uzt', aug: 'abu', sep: 'ira', oct: 'urr', nov: 'aza', dec: 'abe', }, }, select: { loading: 'Kargatzen', noMatch: 'Bat datorren daturik ez', noData: 'Daturik ez', placeholder: 'Hautatu', }, cascader: { noMatch: 'Bat datorren daturik ez', loading: 'Kargatzen', placeholder: 'Hautatu', noData: 'Daturik ez', }, pagination: { goto: 'Joan', pagesize: '/orria', total: 'Guztira {total}', pageClassifier: '', }, messagebox: { title: 'Mezua', confirm: 'Ados', cancel: 'Utzi', error: 'Sarrera baliogabea', }, upload: { deleteTip: 'sakatu Ezabatu kentzeko', delete: 'Ezabatu', preview: 'Aurrebista', continue: 'Jarraitu', }, table: { emptyText: 'Daturik ez', confirmFilter: 'Baieztatu', resetFilter: 'Berrezarri', clearFilter: 'Guztia', sumText: 'Batura', }, tree: { emptyText: 'Daturik ez', }, transfer: { noMatch: 'Bat datorren daturik ez', noData: 'Daturik ez', titles: ['Zerrenda 1', 'Zerrenda 2'], filterPlaceholder: 'Sartu gako-hitza', noCheckedFormat: '{total} elementu', hasCheckedFormat: '{checked}/{total} hautatuta', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_14 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: eu, }, Symbol.toStringTag, { value: 'Module' } ) ) var fa = { name: 'fa', el: { colorpicker: { confirm: '\u0628\u0627\u0634\u062F', clear: '\u062D\u0630\u0641', }, datepicker: { now: '\u0627\u06A9\u0646\u0648\u0646', today: '\u0627\u0645\u0631\u0648\u0632', cancel: '\u0644\u063A\u0648', clear: '\u062D\u0630\u0641', confirm: '\u0628\u0627\u0634\u0647', selectDate: '\u0627\u0646\u062A\u062E\u0627\u0628 \u062A\u0627\u0631\u06CC\u062E', selectTime: '\u0627\u0646\u062A\u062E\u0627\u0628 \u0632\u0645\u0627\u0646', startDate: '\u062A\u0627\u0631\u06CC\u062E \u0634\u0631\u0648\u0639', startTime: '\u0632\u0645\u0627\u0646 \u0634\u0631\u0648\u0639', endDate: '\u062A\u0627\u0631\u06CC\u062E \u067E\u0627\u06CC\u0627\u0646', endTime: '\u0632\u0645\u0627\u0646 \u067E\u0627\u06CC\u0627\u0646', prevYear: '\u0633\u0627\u0644 \u0642\u0628\u0644', nextYear: '\u0633\u0627\u0644 \u0628\u0639\u062F', prevMonth: '\u0645\u0627\u0647 \u0642\u0628\u0644', nextMonth: '\u0645\u0627\u0647 \u0628\u0639\u062F', year: '\u0633\u0627\u0644', month1: '\u0698\u0627\u0646\u0648\u06CC\u0647', month2: '\u0641\u0648\u0631\u06CC\u0647', month3: '\u0645\u0627\u0631\u0633', month4: '\u0622\u0648\u0631\u06CC\u0644', month5: '\u0645\u0647', month6: '\u0698\u0648\u0626\u0646', month7: '\u062C\u0648\u0644\u0627\u06CC', month8: '\u0627\u0648\u062A', month9: '\u0633\u067E\u062A\u0627\u0645\u0628\u0631', month10: '\u0627\u06A9\u062A\u0628\u0631', month11: '\u0646\u0648\u0627\u0645\u0628\u0631', month12: '\u062F\u0633\u0627\u0645\u0628\u0631', weeks: { sun: '\u06CC\u06A9\u0634\u0646\u0628\u0647', mon: '\u062F\u0648\u0634\u0646\u0628\u0647', tue: '\u0633\u0647\u200B\u0634\u0646\u0628\u0647', wed: '\u0686\u0647\u0627\u0631\u0634\u0646\u0628\u0647', thu: '\u067E\u0646\u062C\u200B\u0634\u0646\u0628\u0647', fri: '\u062C\u0645\u0639\u0647', sat: '\u0634\u0646\u0628\u0647', }, months: { jan: '\u0698\u0627\u0646\u0648\u06CC\u0647', feb: '\u0641\u0648\u0631\u06CC\u0647', mar: '\u0645\u0627\u0631\u0633', apr: '\u0622\u0648\u0631\u06CC\u0644', may: '\u0645\u0647', jun: '\u0698\u0648\u0626\u0646', jul: '\u062C\u0648\u0644\u0627\u06CC', aug: '\u0627\u0648\u062A', sep: '\u0633\u067E\u062A\u0627\u0645\u0628\u0631', oct: '\u0627\u06A9\u062A\u0628\u0631', nov: '\u0646\u0648\u0627\u0645\u0628\u0631', dec: '\u062F\u0633\u0627\u0645\u0628\u0631', }, }, select: { loading: '\u0628\u0627\u0631\u06AF\u06CC\u0631\u06CC', noMatch: '\u0647\u06CC\u0686 \u062F\u0627\u062F\u0647\u200C\u0627\u06CC \u067E\u06CC\u062F\u0627 \u0646\u0634\u062F', noData: '\u0627\u0637\u0644\u0627\u0639\u0627\u062A\u06CC \u0648\u062C\u0648\u062F \u0646\u062F\u0627\u0631\u062F', placeholder: '\u0627\u0646\u062A\u062E\u0627\u0628 \u06A9\u0646\u06CC\u062F', }, cascader: { noMatch: '\u0647\u06CC\u0686 \u062F\u0627\u062F\u0647\u200C\u0627\u06CC \u067E\u06CC\u062F\u0627 \u0646\u0634\u062F', loading: '\u0628\u0627\u0631\u06AF\u06CC\u0631\u06CC', placeholder: '\u0627\u0646\u062A\u062E\u0627\u0628 \u06A9\u0646\u06CC\u062F', noData: '\u0627\u0637\u0644\u0627\u0639\u0627\u062A\u06CC \u0648\u062C\u0648\u062F \u0646\u062F\u0627\u0631\u062F', }, pagination: { goto: '\u0628\u0631\u0648 \u0628\u0647', pagesize: '/\u0635\u0641\u062D\u0647', total: '\u0645\u062C\u0645\u0648\u0639 {total}', pageClassifier: '', }, messagebox: { title: '\u067E\u06CC\u0627\u0645', confirm: '\u0628\u0627\u0634\u0647', cancel: '\u0644\u063A\u0648', error: '\u0648\u0631\u0648\u062F\u06CC \u063A\u06CC\u0631 \u0645\u062C\u0627\u0632', }, upload: { deleteTip: '\u0628\u0631\u0627\u06CC \u067E\u0627\u06A9 \u06A9\u0631\u062F\u0646 \u062D\u0630\u0641 \u0631\u0627 \u0641\u0634\u0627\u0631 \u062F\u0647\u06CC\u062F', delete: '\u062D\u0630\u0641', preview: '\u067E\u06CC\u0634\u200C\u0646\u0645\u0627\u06CC\u0634', continue: '\u0627\u062F\u0627\u0645\u0647', }, table: { emptyText: '\u0627\u0637\u0644\u0627\u0639\u0627\u062A\u06CC \u0648\u062C\u0648\u062F \u0646\u062F\u0627\u0631\u062F', confirmFilter: '\u062A\u0627\u06CC\u06CC\u062F', resetFilter: '\u062D\u0630\u0641', clearFilter: '\u0647\u0645\u0647', sumText: '\u062C\u0645\u0639', }, tree: { emptyText: '\u0627\u0637\u0644\u0627\u0639\u0627\u062A\u06CC \u0648\u062C\u0648\u062F \u0646\u062F\u0627\u0631\u062F', }, transfer: { noMatch: '\u0647\u06CC\u0686 \u062F\u0627\u062F\u0647\u200C\u0627\u06CC \u067E\u06CC\u062F\u0627 \u0646\u0634\u062F', noData: '\u0627\u0637\u0644\u0627\u0639\u0627\u062A\u06CC \u0648\u062C\u0648\u062F \u0646\u062F\u0627\u0631\u062F', titles: ['\u0644\u06CC\u0633\u062A 1', '\u0644\u06CC\u0633\u062A 2'], filterPlaceholder: '\u06A9\u0644\u06CC\u062F \u0648\u0627\u0698\u0647 \u0647\u0627\u0631\u0648 \u0648\u0627\u0631\u062F \u06A9\u0646', noCheckedFormat: '{total} \u0645\u0648\u0631\u062F', hasCheckedFormat: '{checked} \u0645\u0648\u0631\u062F \u0627\u0632 {total} \u0645\u0648\u0631\u062F \u0627\u0646\u062A\u062E\u0627\u0628 \u0634\u062F\u0647 \u0627\u0633\u062A', }, image: { error: '\u062E\u0637\u0627 \u062F\u0631 \u0628\u0627\u0631\u06AF\u06CC\u0631\u06CC \u062A\u0635\u0648\u06CC\u0631', }, pageHeader: { title: '\u0628\u0627\u0632\u06AF\u0634\u062A', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_15 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: fa, }, Symbol.toStringTag, { value: 'Module' } ) ) var fi = { name: 'fi', el: { colorpicker: { confirm: 'OK', clear: 'Tyhjenn\xE4', }, datepicker: { now: 'Nyt', today: 'T\xE4n\xE4\xE4n', cancel: 'Peruuta', clear: 'Tyhjenn\xE4', confirm: 'OK', selectDate: 'Valitse p\xE4iv\xE4', selectTime: 'Valitse aika', startDate: 'Aloitusp\xE4iv\xE4', startTime: 'Aloitusaika', endDate: 'Lopetusp\xE4iv\xE4', endTime: 'Lopetusaika', prevYear: 'Edellinen vuosi', nextYear: 'Seuraava vuosi', prevMonth: 'Edellinen kuukausi', nextMonth: 'Seuraava kuukausi', year: '', month1: 'tammikuu', month2: 'helmikuu', month3: 'maaliskuu', month4: 'huhtikuu', month5: 'toukokuu', month6: 'kes\xE4kuu', month7: 'hein\xE4kuu', month8: 'elokuu', month9: 'syyskuu', month10: 'lokakuu', month11: 'marraskuu', month12: 'joulukuu', weeks: { sun: 'su', mon: 'ma', tue: 'ti', wed: 'ke', thu: 'to', fri: 'pe', sat: 'la', }, months: { jan: 'tammi', feb: 'helmi', mar: 'maalis', apr: 'huhti', may: 'touko', jun: 'kes\xE4', jul: 'hein\xE4', aug: 'elo', sep: 'syys', oct: 'loka', nov: 'marras', dec: 'joulu', }, }, select: { loading: 'Lataa', noMatch: 'Ei vastaavia tietoja', noData: 'Ei tietoja', placeholder: 'Valitse', }, cascader: { noMatch: 'Ei vastaavia tietoja', loading: 'Lataa', placeholder: 'Valitse', noData: 'Ei tietoja', }, pagination: { goto: 'Mene', pagesize: '/sivu', total: 'Yhteens\xE4 {total}', pageClassifier: '', }, messagebox: { title: 'Viesti', confirm: 'OK', cancel: 'Peruuta', error: 'Virheellinen sy\xF6te', }, upload: { deleteTip: 'Poista Delete-n\xE4pp\xE4imell\xE4', delete: 'Poista', preview: 'Esikatsele', continue: 'Jatka', }, table: { emptyText: 'Ei tietoja', confirmFilter: 'Vahvista', resetFilter: 'Tyhjenn\xE4', clearFilter: 'Kaikki', sumText: 'Summa', }, tree: { emptyText: 'Ei tietoja', }, transfer: { noMatch: 'Ei vastaavia tietoja', noData: 'Ei tietoja', titles: ['Luettelo 1', 'Luettelo 2'], filterPlaceholder: 'Sy\xF6t\xE4 hakusana', noCheckedFormat: '{total} kohdetta', hasCheckedFormat: '{checked}/{total} valittu', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_16 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: fi, }, Symbol.toStringTag, { value: 'Module' } ) ) var fr = { name: 'fr', el: { colorpicker: { confirm: 'OK', clear: 'Effacer', }, datepicker: { now: 'Maintenant', today: 'Auj.', cancel: 'Annuler', clear: 'Effacer', confirm: 'OK', selectDate: 'Choisir date', selectTime: 'Choisir horaire', startDate: 'Date d\xE9but', startTime: 'Horaire d\xE9but', endDate: 'Date fin', endTime: 'Horaire fin', prevYear: 'Ann\xE9e pr\xE9c\xE9dente', nextYear: 'Ann\xE9e suivante', prevMonth: 'Mois pr\xE9c\xE9dent', nextMonth: 'Mois suivant', year: '', month1: 'Janvier', month2: 'F\xE9vrier', month3: 'Mars', month4: 'Avril', month5: 'Mai', month6: 'Juin', month7: 'Juillet', month8: 'Ao\xFBt', month9: 'Septembre', month10: 'Octobre', month11: 'Novembre', month12: 'D\xE9cembre', weeks: { sun: 'Dim', mon: 'Lun', tue: 'Mar', wed: 'Mer', thu: 'Jeu', fri: 'Ven', sat: 'Sam', }, months: { jan: 'Jan', feb: 'F\xE9v', mar: 'Mar', apr: 'Avr', may: 'Mai', jun: 'Jun', jul: 'Jul', aug: 'Ao\xFB', sep: 'Sep', oct: 'Oct', nov: 'Nov', dec: 'D\xE9c', }, }, select: { loading: 'Chargement', noMatch: 'Aucune correspondance', noData: 'Aucune donn\xE9e', placeholder: 'Choisir', }, cascader: { noMatch: 'Aucune correspondance', loading: 'Chargement', placeholder: 'Choisir', noData: 'Aucune donn\xE9e', }, pagination: { goto: 'Aller \xE0', pagesize: '/page', total: 'Total {total}', pageClassifier: '', }, messagebox: { confirm: 'Confirmer', cancel: 'Annuler', error: 'Erreur', }, upload: { deleteTip: 'Cliquer sur supprimer pour retirer le fichier', delete: 'Supprimer', preview: 'Aper\xE7u', continue: 'Continuer', }, table: { emptyText: 'Aucune donn\xE9e', confirmFilter: 'Confirmer', resetFilter: 'R\xE9initialiser', clearFilter: 'Tous', sumText: 'Somme', }, tree: { emptyText: 'Aucune donn\xE9e', }, transfer: { noMatch: 'Aucune correspondance', noData: 'Aucune donn\xE9e', titles: ['Liste 1', 'Liste 2'], filterPlaceholder: 'Entrer un mot clef', noCheckedFormat: '{total} elements', hasCheckedFormat: '{checked}/{total} coch\xE9(s)', }, image: { error: 'ECHEC', }, pageHeader: { title: 'Retour', }, popconfirm: { confirmButtonText: 'Oui', cancelButtonText: 'Non', }, }, } var __glob_8_17 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: fr, }, Symbol.toStringTag, { value: 'Module' } ) ) var he$1 = { name: 'he', el: { colorpicker: { confirm: '\u05D0\u05D9\u05E9\u05D5\u05E8', clear: '\u05E0\u05E7\u05D4', }, datepicker: { now: '\u05DB\u05E2\u05EA', today: '\u05D4\u05D9\u05D5\u05DD', cancel: '\u05D1\u05D8\u05DC', clear: '\u05E0\u05E7\u05D4', confirm: '\u05D0\u05D9\u05E9\u05D5\u05E8', selectDate: '\u05D1\u05D7\u05E8 \u05EA\u05D0\u05E8\u05D9\u05DA', selectTime: '\u05D1\u05D7\u05E8 \u05D6\u05DE\u05DF', startDate: '\u05EA\u05D0\u05E8\u05D9\u05DA \u05D4\u05EA\u05D7\u05DC\u05D4', startTime: '\u05D6\u05DE\u05DF \u05D4\u05EA\u05D7\u05DC\u05D4', endDate: '\u05EA\u05D0\u05E8\u05D9\u05DA \u05E1\u05D9\u05D5\u05DD', endTime: '\u05D6\u05DE\u05DF \u05E1\u05D9\u05D5\u05DD', prevYear: 'Previous Year', nextYear: 'Next Year', prevMonth: 'Previous Month', nextMonth: 'Next Month', year: '', month1: '\u05D9\u05E0\u05D5\u05D0\u05E8', month2: '\u05E4\u05D1\u05E8\u05D5\u05D0\u05E8', month3: '\u05DE\u05E8\u05E5', month4: '\u05D0\u05E4\u05E8\u05D9\u05DC', month5: '\u05DE\u05D0\u05D9', month6: '\u05D9\u05D5\u05E0\u05D9', month7: '\u05D9\u05D5\u05DC\u05D9', month8: '\u05D0\u05D5\u05D2\u05D5\u05E1\u05D8', month9: '\u05E1\u05E4\u05D8\u05DE\u05D1\u05E8', month10: '\u05D0\u05D5\u05E7\u05D8\u05D5\u05D1\u05E8', month11: '\u05E0\u05D5\u05D1\u05DE\u05D1\u05E8', month12: '\u05D3\u05E6\u05DE\u05D1\u05E8', weeks: { sun: '\u05D0\u05F3', mon: '\u05D1\u05F3', tue: '\u05D2\u05F3', wed: '\u05D3\u05F3', thu: '\u05D4\u05F3', fri: '\u05D5\u05F3', sat: '\u05E9\u05D1\u05EA', }, months: { jan: '\u05D9\u05E0\u05D5\u05D0\u05E8', feb: '\u05E4\u05D1\u05E8\u05D5\u05D0\u05E8', mar: '\u05DE\u05E8\u05E5', apr: '\u05D0\u05E4\u05E8\u05D9\u05DC', may: '\u05DE\u05D0\u05D9', jun: '\u05D9\u05D5\u05E0\u05D9', jul: '\u05D9\u05D5\u05DC\u05D9', aug: '\u05D0\u05D5\u05D2\u05D5\u05E1\u05D8', sep: '\u05E1\u05E4\u05D8\u05DE\u05D1\u05E8', oct: '\u05D0\u05D5\u05E7\u05D8\u05D5\u05D1\u05E8', nov: '\u05E0\u05D5\u05D1\u05DE\u05D1\u05E8', dec: '\u05D3\u05E6\u05DE\u05D1\u05E8', }, }, select: { loading: '\u05D8\u05D5\u05E2\u05DF', noMatch: '\u05DC\u05D0 \u05E0\u05DE\u05E6\u05D0\u05D5 \u05E0\u05EA\u05D5\u05E0\u05D9\u05DD', noData: '\u05DC\u05DC\u05D0 \u05E0\u05EA\u05D5\u05E0\u05D9\u05DD', placeholder: '\u05D1\u05D7\u05E8', }, cascader: { noMatch: '\u05DC\u05DC\u05D0 \u05E0\u05EA\u05D5\u05E0\u05D9\u05DD \u05DE\u05EA\u05D0\u05D9\u05DE\u05D9\u05DD', loading: '\u05D8\u05D5\u05E2\u05DF', placeholder: '\u05D1\u05D7\u05E8', noData: '\u05DC\u05DC\u05D0 \u05E0\u05EA\u05D5\u05E0\u05D9\u05DD', }, pagination: { goto: '\u05E2\u05D1\u05D5\u05E8 \u05DC', pagesize: '/page', total: '\u05DB\u05D5\u05DC\u05DC {total}', pageClassifier: '', }, messagebox: { title: '\u05D4\u05D5\u05D3\u05E2\u05D4', confirm: '\u05D0\u05D9\u05E9\u05D5\u05E8', cancel: '\u05D1\u05D8\u05DC', error: '\u05E7\u05DC\u05D8 \u05DC\u05D0 \u05EA\u05E7\u05D9\u05DF', }, upload: { deleteTip: 'press delete to remove', delete: '\u05DE\u05D7\u05E7', preview: '\u05EA\u05E6\u05D5\u05D2\u05D4 \u05DE\u05E7\u05D3\u05D9\u05DE\u05D4', continue: '\u05D4\u05DE\u05E9\u05DA', }, table: { emptyText: '\u05D0\u05D9\u05DF \u05E0\u05EA\u05D5\u05E0\u05D9\u05DD', confirmFilter: '\u05D0\u05D9\u05E9\u05D5\u05E8', resetFilter: '\u05E0\u05E7\u05D4', clearFilter: '\u05D4\u05DB\u05DC', sumText: '\u05E1\u05DA', }, tree: { emptyText: '\u05D0\u05D9\u05DF \u05E0\u05EA\u05D5\u05E0\u05D9\u05DD', }, transfer: { noMatch: '\u05D0\u05D9\u05DF \u05E0\u05EA\u05D5\u05E0\u05D9\u05DD \u05DE\u05EA\u05D0\u05D9\u05DE\u05D9\u05DD', noData: '\u05DC\u05DC\u05D0 \u05E0\u05EA\u05D5\u05E0\u05D9\u05DD', titles: [ '\u05E8\u05E9\u05D9\u05DE\u05D4 1', '\u05E8\u05E9\u05D9\u05DE\u05D4 2', ], filterPlaceholder: '\u05D4\u05E7\u05DC\u05D3', noCheckedFormat: '\u05E4\u05E8\u05D9\u05D8\u05D9\u05DD {total}', hasCheckedFormat: ' \u05D0\u05D9\u05E9\u05D5\u05E8 {checked}/{total}', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_18 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: he$1, }, Symbol.toStringTag, { value: 'Module' } ) ) var hr = { name: 'hr', el: { colorpicker: { confirm: 'OK', clear: 'O\u010Disti', }, datepicker: { now: 'Sada', today: 'Danas', cancel: 'Otka\u017Ei', clear: 'O\u010Disti', confirm: 'OK', selectDate: 'Odaberi datum', selectTime: 'Odaberi vrijeme', startDate: 'Datum po\u010Detka', startTime: 'Vrijeme po\u010Detka', endDate: 'Datum zavr\u0161etka', endTime: 'Vrijeme zavr\u0161etka', prevYear: 'Prethodna godina', nextYear: 'Sljede\u0107a godina', prevMonth: 'Prethodni mjesec', nextMonth: 'Sljede\u0107i mjesec', year: '', month1: 'Sije\u010Danj', month2: 'Velja\u010Da', month3: 'O\u017Eujak', month4: 'Travanj', month5: 'Svibanj', month6: 'Lipanj', month7: 'Srpanj', month8: 'Kolovoz', month9: 'Rujan', month10: 'Listopad', month11: 'Studeni', month12: 'Prosinac', week: 'tjedan', weeks: { sun: 'Ned', mon: 'Pon', tue: 'Uto', wed: 'Sri', thu: '\u010Cet', fri: 'Pet', sat: 'Sub', }, months: { jan: 'Jan', feb: 'Feb', mar: 'Mar', apr: 'Apr', may: 'May', jun: 'Jun', jul: 'Jul', aug: 'Aug', sep: 'Sep', oct: 'Oct', nov: 'Nov', dec: 'Dec', }, }, select: { loading: 'U\u010Ditavanje', noMatch: 'Nema prona\u0111enih podataka', noData: 'Nema podataka', placeholder: 'Izaberi', }, cascader: { noMatch: 'Nema prona\u0111enih podataka', loading: 'U\u010Ditavanje', placeholder: 'Izaberi', noData: 'Nema podataka', }, pagination: { goto: 'Idi na', pagesize: '/stranica', total: 'Ukupno {total}', pageClassifier: '', }, messagebox: { title: 'Poruka', confirm: 'OK', cancel: 'Otka\u017Ei', error: 'Pogre\u0161an unos', }, upload: { deleteTip: 'pritisnite izbri\u0161i za brisanje', delete: 'Izbri\u0161i', preview: 'Pregled', continue: 'Nastavak', }, table: { emptyText: 'Nema podataka', confirmFilter: 'Potvrdi', resetFilter: 'Resetiraj', clearFilter: 'Sve', sumText: 'Suma', }, tree: { emptyText: 'Nema podataka', }, transfer: { noMatch: 'Nema prona\u0111enih podataka', noData: 'Nema podataka', titles: ['Lista 1', 'Lista 2'], filterPlaceholder: 'Unesite klju\u010Dnu rije\u010D', noCheckedFormat: '{total} stavki', hasCheckedFormat: '{checked}/{total} checked', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_19 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: hr, }, Symbol.toStringTag, { value: 'Module' } ) ) var hu = { name: 'hu', el: { colorpicker: { confirm: 'OK', clear: 'T\xF6rl\xE9s', }, datepicker: { now: 'Most', today: 'Ma', cancel: 'M\xE9gse', clear: 'T\xF6rl\xE9s', confirm: 'OK', selectDate: 'D\xE1tum', selectTime: 'Id\u0151pont', startDate: 'D\xE1tum-t\xF3l', startTime: 'Id\u0151pont-t\xF3l', endDate: 'D\xE1tum-ig', endTime: 'Id\u0151pont-ig', prevYear: 'El\u0151z\u0151 \xE9v', nextYear: 'K\xF6vetkez\u0151 \xE9v', prevMonth: 'El\u0151z\u0151 h\xF3nap', nextMonth: 'K\xF6vetkez\u0151 h\xF3nap', year: '', month1: 'Janu\xE1r', month2: 'Febru\xE1r', month3: 'M\xE1rcius', month4: '\xC1prilis', month5: 'M\xE1jus', month6: 'J\xFAnius', month7: 'J\xFAlius', month8: 'Augusztus', month9: 'Szeptember', month10: 'Okt\xF3ber', month11: 'November', month12: 'December', weeks: { sun: 'Vas', mon: 'H\xE9t', tue: 'Ked', wed: 'Sze', thu: 'Cs\xFC', fri: 'P\xE9n', sat: 'Szo', }, months: { jan: 'Jan', feb: 'Feb', mar: 'M\xE1r', apr: '\xC1pr', may: 'M\xE1j', jun: 'J\xFAn', jul: 'J\xFAl', aug: 'Aug', sep: 'Szep', oct: 'Okt', nov: 'Nov', dec: 'Dec', }, }, select: { loading: 'Bet\xF6lt\xE9s', noMatch: 'Nincs tal\xE1lat', noData: 'Nincs adat', placeholder: 'V\xE1lassz', }, cascader: { noMatch: 'Nincs tal\xE1lat', loading: 'Bet\xF6lt\xE9s', placeholder: 'V\xE1lassz', noData: 'Nincs adat', }, pagination: { goto: 'Ugr\xE1s', pagesize: '/oldal', total: '\xD6ssz {total}', pageClassifier: '', }, messagebox: { title: '\xDCzenet', confirm: 'OK', cancel: 'M\xE9gse', error: 'Hib\xE1s adat', }, upload: { deleteTip: 'kattints a t\xF6rl\xE9shez', delete: 'T\xF6rl\xE9s', preview: 'El\u0151n\xE9zet', continue: 'Tov\xE1bb', }, table: { emptyText: 'Nincs adat', confirmFilter: 'Meger\u0151s\xEDt', resetFilter: 'Alaphelyet', clearFilter: 'Mind', sumText: '\xD6sszeg', }, tree: { emptyText: 'Nincs adat', }, transfer: { noMatch: 'Nincs tal\xE1lat', noData: 'Nincs adat', titles: ['Lista 1', 'Lista 2'], filterPlaceholder: 'Kulcssz\xF3', noCheckedFormat: '{total} elem', hasCheckedFormat: '{checked}/{total} kiv\xE1lasztva', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_20 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: hu, }, Symbol.toStringTag, { value: 'Module' } ) ) var hyAm = { name: 'hy-am', el: { colorpicker: { confirm: '\u053C\u0561\u0582', clear: '\u0544\u0561\u0584\u0580\u0565\u056C', }, datepicker: { now: '\u0540\u056B\u0574\u0561', today: '\u0531\u0575\u057D\u0585\u0580', cancel: '\u0549\u0565\u0572\u0561\u0580\u056F\u0565\u056C', clear: '\u0544\u0561\u0584\u0580\u0565\u056C', confirm: '\u053C\u0561\u0582', selectDate: '\u0538\u0576\u057F\u0580\u0565\u0584 \u0561\u0574\u057D\u0561\u0569\u056B\u0582\u0568', selectTime: '\u0538\u0576\u057F\u0580\u0565\u0584 \u056A\u0561\u0574\u0561\u0576\u0561\u056F\u0568', startDate: '\u054D\u056F\u0566\u0562. \u0561\u0574\u057D\u0561\u0569\u056B\u0582\u0568', startTime: '\u054D\u056F\u0566\u0562. \u056A\u0561\u0574\u0561\u0576\u0561\u056F\u0568', endDate: '\u054E\u0565\u0580\u057B. \u0561\u0574\u057D\u0561\u0569\u056B\u057E\u0568', endTime: '\u054E\u0565\u0580\u057B. \u056A\u0561\u0574\u0561\u0576\u0561\u056F\u0568', prevYear: '\u0546\u0561\u056D\u0578\u0580\u0564 \u057F\u0561\u0580\u056B', nextYear: '\u0545\u0561\u057B\u0578\u0580\u0564 \u057F\u0561\u0580\u056B', prevMonth: '\u0546\u0561\u056D\u0578\u0580\u0564 \u0561\u0574\u056B\u057D', nextMonth: '\u0545\u0561\u057B\u0578\u0580\u0564 \u0561\u0574\u056B\u057D', year: '\u054F\u0561\u0580\u056B', month1: '\u0545\u0578\u0582\u0576\u0578\u0582\u0561\u0580', month2: '\u0553\u0565\u057F\u0580\u0578\u0582\u0561\u0580', month3: '\u0544\u0561\u0580\u057F', month4: '\u0531\u057A\u0580\u056B\u056C', month5: '\u0544\u0561\u0575\u056B\u057D', month6: '\u0545\u0578\u0582\u0576\u056B\u057D', month7: '\u0545\u0578\u0582\u056C\u056B\u057D', month8: '\u0555\u0563\u0578\u057D\u057F\u0578\u057D', month9: '\u054D\u0565\u057A\u057F\u0565\u0574\u0562\u0565\u0580', month10: '\u0545\u0578\u056F\u057F\u0565\u0574\u0562\u0565\u0580', month11: '\u0546\u0578\u0575\u0565\u0574\u0562\u0565\u0580', month12: '\u0534\u0565\u056F\u057F\u0565\u0574\u0562\u0565\u0580', week: '\u0547\u0561\u0562\u0561\u0569', weeks: { sun: '\u053F\u056B\u0580', mon: '\u0535\u0580\u056F', tue: '\u0535\u0580', wed: '\u0549\u0578\u0580', thu: '\u0540\u056B\u0576\u0563', fri: '\u0548\u0582\u0580\u0562', sat: '\u0547\u0561\u0562', }, months: { jan: '\u0545\u0578\u0582\u0576\u057E', feb: '\u0553\u0565\u057F', mar: '\u0544\u0561\u0580', apr: '\u0531\u057A\u0580', may: '\u0544\u0561\u0575', jun: '\u0545\u0578\u0582\u0576', jul: '\u0545\u0578\u0582\u056C', aug: '\u0555\u0563', sep: '\u054D\u0565\u057A\u057F', oct: '\u0545\u0578\u056F', nov: '\u0546\u0578\u0575', dec: '\u0534\u0565\u056F', }, }, select: { loading: '\u0532\u0565\u057C\u0576\u0578\u0582\u0574', noMatch: '\u0540\u0561\u0574\u0561\u057A\u0561\u057F\u0561\u057D\u056D\u0561\u0576 \u057F\u0578\u0582\u0565\u0561\u056C\u0576\u0565\u0580 \u0579\u056F\u0561\u0576', noData: '\u054F\u057E\u0575\u0561\u056C\u0576\u0565\u0580 \u0579\u056F\u0561\u0576', placeholder: '\u0538\u0576\u057F\u0580\u0565\u056C', }, cascader: { noMatch: '\u0540\u0561\u0574\u0561\u057A\u0561\u057F\u0561\u057D\u056D\u0561\u0576 \u057F\u0578\u0582\u0565\u0561\u056C\u0576\u0565\u0580 \u0579\u056F\u0561\u0576', loading: '\u0532\u0565\u057C\u0576\u0578\u0582\u0574', placeholder: '\u0538\u0576\u057F\u0580\u0565\u056C', noData: '\u054F\u057E\u0575\u0561\u056C\u0576\u0565\u0580 \u0579\u056F\u0561\u0576', }, pagination: { goto: '\u0531\u0576\u0581\u0576\u0565\u056C', pagesize: ' \u0567\u057B\u0578\u0582\u0574', total: '\u0538\u0576\u0564\u0561\u0574\u0565\u0576\u0568 {total}', pageClassifier: '', }, messagebox: { title: '\u0540\u0561\u0572\u0578\u0580\u0564\u0561\u0563\u0580\u0578\u0582\u0569\u056B\u0582\u0576', confirm: '\u053C\u0561\u0582', cancel: '\u0549\u0565\u0572\u0561\u0580\u056F\u0565\u056C', error: '\u0531\u0576\u057E\u0561\u0582\u0565\u0580 \u057F\u0578\u0582\u0565\u0561\u056C\u0576\u0565\u0580\u056B \u0574\u0578\u0582\u057F\u0584', }, upload: { deleteTip: '\u054D\u0565\u0572\u0574\u0565\u0584 [\u054B\u0576\u057B\u0565\u056C] \u057B\u0576\u057B\u0565\u056C\u0578\u0582 \u0570\u0561\u0574\u0561\u0580', delete: '\u054B\u0576\u057B\u0565\u056C', preview: '\u0546\u0561\u056D\u0561\u0564\u056B\u057F\u0578\u0582\u0574', continue: '\u0547\u0561\u0580\u0578\u0582\u0576\u0561\u056F\u0565\u056C', }, table: { emptyText: '\u054F\u0578\u0582\u0565\u0561\u056C\u0576\u0565\u0580 \u0579\u056F\u0561\u0576', confirmFilter: '\u0545\u0561\u057D\u057F\u0561\u057F\u0565\u056C', resetFilter: '\u054E\u0565\u0580\u0561\u0563\u0578\u0580\u056E\u0561\u0580\u056F\u0565\u056C', clearFilter: '\u0532\u0578\u056C\u0578\u0580\u0568', sumText: '\u0533\u0578\u0582\u0574\u0561\u0580\u0568', }, tree: { emptyText: '\u054F\u0578\u0582\u0565\u0561\u056C\u0576\u0565\u0580 \u0579\u056F\u0561\u0576', }, transfer: { noMatch: '\u0540\u0561\u0574\u0561\u057A\u0561\u057F\u0561\u057D\u056D\u0561\u0576 \u057F\u0578\u0582\u0565\u0561\u056C\u0576\u0565\u0580 \u0579\u056F\u0561\u0576', noData: '\u054F\u0578\u0582\u0565\u0561\u056C\u0576\u0565\u0580 \u0579\u056F\u0561\u0576', titles: [ '\u0551\u0578\u0582\u0581\u0561\u056F 1', '\u0551\u0578\u0582\u0581\u0561\u056F 2', ], filterPlaceholder: '\u0544\u0578\u0582\u057F\u0584\u0561\u0563\u0580\u0565\u0584 \u0562\u0561\u0576\u0561\u056C\u056B \u0562\u0561\u057C', noCheckedFormat: '{total} \u0574\u056B\u0561\u0582\u0578\u0580', hasCheckedFormat: '{checked}/{total} \u0568\u0576\u057F\u0580\u0578\u0582\u0561\u056E \u0567', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_21 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: hyAm, }, Symbol.toStringTag, { value: 'Module' } ) ) var id$2 = { name: 'id', el: { colorpicker: { confirm: 'Pilih', clear: 'Kosongkan', }, datepicker: { now: 'Sekarang', today: 'Hari ini', cancel: 'Batal', clear: 'Kosongkan', confirm: 'Ya', selectDate: 'Pilih tanggal', selectTime: 'Pilih waktu', startDate: 'Tanggal Mulai', startTime: 'Waktu Mulai', endDate: 'Tanggal Selesai', endTime: 'Waktu Selesai', prevYear: 'Tahun Sebelumnya', nextYear: 'Tahun Selanjutnya', prevMonth: 'Bulan Sebelumnya', nextMonth: 'Bulan Selanjutnya', year: 'Tahun', month1: 'Januari', month2: 'Februari', month3: 'Maret', month4: 'April', month5: 'Mei', month6: 'Juni', month7: 'Juli', month8: 'Agustus', month9: 'September', month10: 'Oktober', month11: 'November', month12: 'Desember', week: 'Minggu', weeks: { sun: 'Min', mon: 'Sen', tue: 'Sel', wed: 'Rab', thu: 'Kam', fri: 'Jum', sat: 'Sab', }, months: { jan: 'Jan', feb: 'Feb', mar: 'Mar', apr: 'Apr', may: 'Mei', jun: 'Jun', jul: 'Jul', aug: 'Agu', sep: 'Sep', oct: 'Okt', nov: 'Nov', dec: 'Des', }, }, select: { loading: 'Memuat', noMatch: 'Tidak ada data yg cocok', noData: 'Tidak ada data', placeholder: 'Pilih', }, cascader: { noMatch: 'Tidak ada data yg cocok', loading: 'Memuat', placeholder: 'Pilih', noData: 'Tidak ada data', }, pagination: { goto: 'Pergi ke', pagesize: '/halaman', total: 'Total {total}', pageClassifier: '', deprecationWarning: 'Penggunaan yang tidak akan digunakan lagi terdeteksi, silakan lihat dokumentasi el-pagination untuk lebih jelasnya', }, messagebox: { title: 'Pesan', confirm: 'Ya', cancel: 'Batal', error: 'Masukan ilegal', }, upload: { deleteTip: 'Tekan hapus untuk melanjutkan', delete: 'Hapus', preview: 'Pratinjau', continue: 'Lanjutkan', }, table: { emptyText: 'Tidak ada data', confirmFilter: 'Konfirmasi', resetFilter: 'Atur ulang', clearFilter: 'Semua', sumText: 'Jumlah', }, tree: { emptyText: 'Tidak ada data', }, transfer: { noMatch: 'Tidak ada data yg cocok', noData: 'Tidak ada data', titles: ['Daftar 1', 'Daftar 2'], filterPlaceholder: 'Masukan kata kunci', noCheckedFormat: '{total} item', hasCheckedFormat: '{checked}/{total} terpilih', }, image: { error: 'GAGAL', }, pageHeader: { title: 'Kembali', }, popconfirm: { confirmButtonText: 'Ya', cancelButtonText: 'Tidak', }, }, } var __glob_8_22 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: id$2, }, Symbol.toStringTag, { value: 'Module' } ) ) var it$1 = { name: 'it', el: { colorpicker: { confirm: 'OK', clear: 'Pulisci', }, datepicker: { now: 'Ora', today: 'Oggi', cancel: 'Cancella', clear: 'Pulisci', confirm: 'OK', selectDate: 'Seleziona data', selectTime: 'Seleziona ora', startDate: 'Data inizio', startTime: 'Ora inizio', endDate: 'Data fine', endTime: 'Ora fine', prevYear: 'Anno precedente', nextYear: 'Anno successivo', prevMonth: 'Mese precedente', nextMonth: 'Mese successivo', year: '', month1: 'Gennaio', month2: 'Febbraio', month3: 'Marzo', month4: 'Aprile', month5: 'Maggio', month6: 'Giugno', month7: 'Luglio', month8: 'Agosto', month9: 'Settembre', month10: 'Ottobre', month11: 'Novembre', month12: 'Dicembre', weeks: { sun: 'Dom', mon: 'Lun', tue: 'Mar', wed: 'Mer', thu: 'Gio', fri: 'Ven', sat: 'Sab', }, months: { jan: 'Gen', feb: 'Feb', mar: 'Mar', apr: 'Apr', may: 'Mag', jun: 'Giu', jul: 'Lug', aug: 'Ago', sep: 'Set', oct: 'Ott', nov: 'Nov', dec: 'Dic', }, }, select: { loading: 'Caricamento', noMatch: 'Nessuna corrispondenza', noData: 'Nessun dato', placeholder: 'Seleziona', }, cascader: { noMatch: 'Nessuna corrispondenza', loading: 'Caricamento', placeholder: 'Seleziona', noData: 'Nessun dato', }, pagination: { goto: 'Vai a', pagesize: '/page', total: 'Totale {total}', pageClassifier: '', }, messagebox: { confirm: 'OK', cancel: 'Cancella', error: 'Input non valido', }, upload: { deleteTip: 'Premi cancella per rimuovere', delete: 'Cancella', preview: 'Anteprima', continue: 'Continua', }, table: { emptyText: 'Nessun dato', confirmFilter: 'Conferma', resetFilter: 'Reset', clearFilter: 'Tutti', sumText: 'Somma', }, tree: { emptyText: 'Nessun dato', }, transfer: { noMatch: 'Nessuna corrispondenza', noData: 'Nessun dato', titles: ['Lista 1', 'Lista 2'], filterPlaceholder: 'Inserisci filtro', noCheckedFormat: '{total} elementi', hasCheckedFormat: '{checked}/{total} selezionati', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_23 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: it$1, }, Symbol.toStringTag, { value: 'Module' } ) ) var ja$2 = { name: 'ja', el: { colorpicker: { confirm: 'OK', clear: '\u30AF\u30EA\u30A2', }, datepicker: { now: '\u73FE\u5728', today: '\u4ECA\u65E5', cancel: '\u30AD\u30E3\u30F3\u30BB\u30EB', clear: '\u30AF\u30EA\u30A2', confirm: 'OK', selectDate: '\u65E5\u4ED8\u3092\u9078\u629E', selectTime: '\u6642\u9593\u3092\u9078\u629E', startDate: '\u958B\u59CB\u65E5', startTime: '\u958B\u59CB\u6642\u9593', endDate: '\u7D42\u4E86\u65E5', endTime: '\u7D42\u4E86\u6642\u9593', prevYear: '\u524D\u5E74', nextYear: '\u7FCC\u5E74', prevMonth: '\u524D\u6708', nextMonth: '\u7FCC\u6708', year: '\u5E74', month1: '1\u6708', month2: '2\u6708', month3: '3\u6708', month4: '4\u6708', month5: '5\u6708', month6: '6\u6708', month7: '7\u6708', month8: '8\u6708', month9: '9\u6708', month10: '10\u6708', month11: '11\u6708', month12: '12\u6708', weeks: { sun: '\u65E5', mon: '\u6708', tue: '\u706B', wed: '\u6C34', thu: '\u6728', fri: '\u91D1', sat: '\u571F', }, months: { jan: '1\u6708', feb: '2\u6708', mar: '3\u6708', apr: '4\u6708', may: '5\u6708', jun: '6\u6708', jul: '7\u6708', aug: '8\u6708', sep: '9\u6708', oct: '10\u6708', nov: '11\u6708', dec: '12\u6708', }, }, select: { loading: '\u30ED\u30FC\u30C9\u4E2D', noMatch: '\u30C7\u30FC\u30BF\u306A\u3057', noData: '\u30C7\u30FC\u30BF\u306A\u3057', placeholder: '\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044', }, cascader: { noMatch: '\u30C7\u30FC\u30BF\u306A\u3057', loading: '\u30ED\u30FC\u30C9\u4E2D', placeholder: '\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044', noData: '\u30C7\u30FC\u30BF\u306A\u3057', }, pagination: { goto: '', pagesize: '\u4EF6/\u30DA\u30FC\u30B8', total: '\u7DCF\u8A08 {total} \u4EF6', pageClassifier: '\u30DA\u30FC\u30B8\u76EE\u3078', }, messagebox: { title: '\u30E1\u30C3\u30BB\u30FC\u30B8', confirm: 'OK', cancel: '\u30AD\u30E3\u30F3\u30BB\u30EB', error: '\u6B63\u3057\u304F\u306A\u3044\u5165\u529B', }, upload: { deleteTip: 'Del\u30AD\u30FC\u3092\u62BC\u3057\u3066\u524A\u9664\u3059\u308B', delete: '\u524A\u9664\u3059\u308B', preview: '\u30D7\u30EC\u30D3\u30E5\u30FC', continue: '\u7D9A\u884C\u3059\u308B', }, table: { emptyText: '\u30C7\u30FC\u30BF\u306A\u3057', confirmFilter: '\u78BA\u8A8D', resetFilter: '\u521D\u671F\u5316', clearFilter: '\u3059\u3079\u3066', sumText: '\u5408\u8A08', }, tree: { emptyText: '\u30C7\u30FC\u30BF\u306A\u3057', }, transfer: { noMatch: '\u30C7\u30FC\u30BF\u306A\u3057', noData: '\u30C7\u30FC\u30BF\u306A\u3057', titles: ['\u30EA\u30B9\u30C8 1', '\u30EA\u30B9\u30C8 2'], filterPlaceholder: '\u30AD\u30FC\u30EF\u30FC\u30C9\u3092\u5165\u529B', noCheckedFormat: '\u7DCF\u8A08 {total} \u4EF6', hasCheckedFormat: '{checked}/{total} \u3092\u9078\u629E\u3057\u305F', }, image: { error: '\u5931\u6557', }, pageHeader: { title: '\u623B\u308B', }, popconfirm: { confirmButtonText: '\u306F\u3044', cancelButtonText: '\u3044\u3044\u3048', }, }, } var __glob_8_24 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: ja$2, }, Symbol.toStringTag, { value: 'Module' } ) ) var kk = { name: 'kk', el: { colorpicker: { confirm: '\u049A\u0430\u0431\u044B\u043B\u0434\u0430\u0443', clear: '\u0422\u0430\u0437\u0430\u043B\u0430\u0443', }, datepicker: { now: '\u049A\u0430\u0437\u0456\u0440', today: '\u0411\u04AF\u0433\u0456\u043D', cancel: '\u0411\u043E\u043B\u0434\u044B\u0440\u043C\u0430\u0443', clear: '\u0422\u0430\u0437\u0430\u043B\u0430\u0443', confirm: '\u049A\u0430\u0431\u044B\u043B\u0434\u0430\u0443', selectDate: '\u041A\u04AF\u043D\u0434\u0456 \u0442\u0430\u04A3\u0434\u0430\u04A3\u044B\u0437', selectTime: '\u0421\u0430\u0493\u0430\u0442\u0442\u044B \u0442\u0430\u04A3\u0434\u0430\u04A3\u044B\u0437', startDate: '\u0411\u0430\u0441\u0442\u0430\u043B\u0443 \u043A\u04AF\u043D\u0456', startTime: '\u0411\u0430\u0441\u0442\u0430\u043B\u0443 \u0441\u0430\u0493\u0430\u0442\u044B', endDate: '\u0410\u044F\u049B\u0442\u0430\u043B\u0443 \u043A\u04AF\u043D\u0456', endTime: '\u0410\u044F\u049B\u0442\u0430\u043B\u0443 \u0441\u0430\u0493\u0430\u0442\u044B', prevYear: '\u0410\u043B\u0434\u044B\u04A3\u0493\u044B \u0436\u044B\u043B', nextYear: '\u041A\u0435\u043B\u0435\u0441\u0456 \u0436\u044B\u043B', prevMonth: '\u0410\u043B\u0434\u044B\u04A3\u0493\u044B \u0430\u0439', nextMonth: '\u041A\u0435\u043B\u0435\u0441\u0456 \u0430\u0439', year: '\u0416\u044B\u043B', month1: '\u049A\u0430\u04A3\u0442\u0430\u0440', month2: '\u0410\u049B\u043F\u0430\u043D', month3: '\u041D\u0430\u0443\u0440\u044B\u0437', month4: '\u0421\u04D9\u0443\u0456\u0440', month5: '\u041C\u0430\u043C\u044B\u0440', month6: '\u041C\u0430\u0443\u0441\u044B\u043C', month7: '\u0428\u0456\u043B\u0434\u0435', month8: '\u0422\u0430\u043C\u044B\u0437', month9: '\u049A\u044B\u0440\u043A\u04AF\u0439\u0435\u043A', month10: '\u049A\u0430\u0437\u0430\u043D', month11: '\u049A\u0430\u0440\u0430\u0448\u0430', month12: '\u0416\u0435\u043B\u0442\u043E\u049B\u0441\u0430\u043D', week: '\u0410\u043F\u0442\u0430', weeks: { sun: '\u0416\u0435\u043A', mon: '\u0414\u04AF\u0439', tue: '\u0421\u0435\u0439', wed: '\u0421\u04D9\u0440', thu: '\u0411\u0435\u0439', fri: '\u0416\u04B1\u043C', sat: '\u0421\u0435\u043D', }, months: { jan: '\u049A\u0430\u04A3', feb: '\u0410\u049B\u043F', mar: '\u041D\u0430\u0443', apr: '\u0421\u04D9\u0443', may: '\u041C\u0430\u043C', jun: '\u041C\u0430\u0443', jul: '\u0428\u0456\u043B', aug: '\u0422\u0430\u043C', sep: '\u049A\u044B\u0440', oct: '\u049A\u0430\u0437', nov: '\u049A\u0430\u0440', dec: '\u0416\u0435\u043B', }, }, select: { loading: '\u0416\u04AF\u043A\u0442\u0435\u043B\u0443\u0434\u0435', noMatch: '\u0421\u04D9\u0439\u043A\u0435\u0441 \u0434\u0435\u0440\u0435\u043A\u0442\u0435\u0440 \u0436\u043E\u049B', noData: '\u0414\u0435\u0440\u0435\u043A\u0442\u0435\u0440 \u0436\u043E\u049B', placeholder: '\u0422\u0430\u04A3\u0434\u0430\u04A3\u044B\u0437', }, cascader: { noMatch: '\u0421\u04D9\u0439\u043A\u0435\u0441 \u0434\u0435\u0440\u0435\u043A\u0442\u0435\u0440 \u0436\u043E\u049B', loading: '\u0416\u04AF\u043A\u0442\u0435\u043B\u0443\u0434\u0435', placeholder: '\u0422\u0430\u04A3\u0434\u0430\u04A3\u044B\u0437', noData: '\u0414\u0435\u0440\u0435\u043A\u0442\u0435\u0440 \u0436\u043E\u049B', }, pagination: { goto: '\u0411\u0430\u0440\u0443', pagesize: '/page', total: '\u0411\u0430\u0440\u043B\u044B\u0493\u044B {total}', pageClassifier: '', }, messagebox: { title: '\u0425\u0430\u0431\u0430\u0440', confirm: '\u049A\u0430\u0431\u044B\u043B\u0434\u0430\u0443', cancel: '\u0411\u043E\u043B\u0434\u044B\u0440\u043C\u0430\u0443', error: '\u0416\u0430\u0440\u0430\u043C\u0441\u044B\u0437 \u0435\u043D\u0433\u0456\u0437\u0443\u043B\u0435\u0440', }, upload: { deleteTip: '\u04E8\u0448\u0456\u0440\u0443\u0434\u0456 \u0431\u0430\u0441\u044B\u043F \u04E9\u0448\u0456\u0440\u0456\u04A3\u0456\u0437', delete: '\u04E8\u0448\u0456\u0440\u0443', preview: '\u0410\u043B\u0434\u044B\u043D \u0430\u043B\u0430 \u049B\u0430\u0440\u0430\u0443', continue: '\u0416\u0430\u043B\u0493\u0430\u0441\u0442\u044B\u0440\u0443', }, table: { emptyText: '\u0414\u0435\u0440\u0435\u043A\u0442\u0435\u0440 \u0436\u043E\u049B', confirmFilter: '\u049A\u0430\u0431\u044B\u043B\u0434\u0430\u0443', resetFilter: '\u049A\u0430\u043B\u043F\u044B\u043D\u0430 \u043A\u0435\u043B\u0442\u0456\u0440\u0443', clearFilter: '\u0411\u0430\u0440\u043B\u044B\u0493\u044B', sumText: '\u0421\u043E\u043C\u0430\u0441\u044B', }, tree: { emptyText: '\u0414\u0435\u0440\u0435\u043A\u0442\u0435\u0440 \u0436\u043E\u049B', }, transfer: { noMatch: '\u0421\u04D9\u0439\u043A\u0435\u0441 \u0434\u0435\u0440\u0435\u043A\u0442\u0435\u0440 \u0436\u043E\u049B', noData: '\u0414\u0435\u0440\u0435\u043A\u0442\u0435\u0440 \u0436\u043E\u049B', titles: ['List 1', 'List 2'], filterPlaceholder: '\u041A\u0456\u043B\u0442 \u0441\u04E9\u0437\u0434\u0456 \u0435\u043D\u0433\u0456\u0437\u0456\u04A3\u0456\u0437', noCheckedFormat: '{total} \u044D\u043B\u044D\u043C\u044D\u043D\u0442', hasCheckedFormat: '{checked}/{total} \u049B\u04B1\u0441\u0431\u0435\u043B\u0433\u0456\u0441\u0456 \u049B\u043E\u0439\u044B\u043B\u0434\u044B', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_25 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: kk, }, Symbol.toStringTag, { value: 'Module' } ) ) var km = { name: 'km', el: { colorpicker: { confirm: '\u1799\u179B\u17CB\u1796\u17D2\u179A\u1798', clear: '\u179B\u17BB\u1794', }, datepicker: { now: '\u17A5\u17A1\u17BC\u179C\u200B\u1793\u17C1\u17C7', today: '\u1790\u17D2\u1784\u17C3\u1793\u17C1\u17C7', cancel: '\u1794\u17C4\u17C7\u1794\u1784\u17CB', clear: '\u179B\u17BB\u1794', confirm: '\u1799\u179B\u17CB\u1796\u17D2\u179A\u1798', selectDate: '\u1787\u17D2\u179A\u17BE\u179F\u179A\u17BE\u179F\u1790\u17D2\u1784\u17C3', selectTime: '\u1787\u17D2\u179A\u17BE\u179F\u179A\u17BE\u179F\u1798\u17C9\u17C4\u1784', startDate: '\u1790\u17D2\u1784\u17C3\u1785\u17B6\u1794\u17CB\u1795\u17D2\u178F\u17BE\u1798', startTime: '\u1798\u17C9\u17C4\u1784\u1785\u17B6\u1794\u17CB\u1795\u17D2\u178F\u17BE\u1798', endDate: '\u1790\u17D2\u1784\u17C3\u1794\u1789\u17D2\u1785\u1794\u17CB', endTime: '\u1798\u17C9\u17C4\u1784\u1794\u1789\u17D2\u1785\u1794\u17CB', prevYear: '\u1786\u17D2\u1793\u17B6\u17C6\u1798\u17BB\u1793', nextYear: '\u1786\u17D2\u1793\u17B6\u17C6\u1780\u17D2\u179A\u17C4\u1799', prevMonth: '\u1781\u17C2\u1798\u17BB\u1793', nextMonth: '\u1781\u17C2\u1780\u17D2\u179A\u17C4\u1799', year: '\u1786\u17D2\u1793\u17B6\u17C6', month1: '\u1798\u1780\u179A\u17B6', month2: '\u1780\u17BB\u1798\u17D2\u1797\u17C8', month3: '\u1798\u17B8\u1793\u17B6', month4: '\u1798\u17C1\u179F\u17B6', month5: '\u17A7\u179F\u1797\u17B6', month6: '\u1798\u17B7\u1790\u17BB\u1793\u17B6', month7: '\u1780\u1780\u17D2\u1780\u178A\u17B6', month8: '\u179F\u17B8\u17A0\u17B6', month9: '\u1780\u1789\u17D2\u1789\u17B6', month10: '\u178F\u17BB\u179B\u17B6', month11: '\u179C\u17B7\u1785\u17D2\u1786\u17B7\u1780\u17B6', month12: '\u1792\u17D2\u1793\u17BC', weeks: { sun: '\u17A2\u17B6\u1791\u17B7\u178F\u17D2\u1799', mon: '\u1785\u1793\u17D2\u1791', tue: '\u17A2\u1784\u17D2\u1782\u17B6\u179A', wed: '\u1796\u17BB\u1792', thu: '\u1796\u17D2\u179A\u17A0', fri: '\u179F\u17BB\u1780\u17D2\u179A', sat: '\u179F\u17C5\u179A\u17CD', }, months: { jan: '\u1798\u1780\u179A\u17B6', feb: '\u1780\u17BB\u1798\u17D2\u1797\u17C8', mar: '\u1798\u17B8\u1793\u17B6', apr: '\u1798\u17C1\u179F\u17B6', may: '\u17A7\u179F\u1797\u17B6', jun: '\u1798\u17B7\u1790\u17BB\u1793\u17B6', jul: '\u1780\u1780\u17D2\u1780\u178A\u17B6', aug: '\u179F\u17B8\u17A0\u17B6', sep: '\u1780\u1789\u17D2\u1789\u17B6', oct: '\u178F\u17BB\u179B\u17B6', nov: '\u179C\u17B7\u1785\u17D2\u1786\u17B7\u1780\u17B6', dec: '\u1792\u17D2\u1793\u17BC', }, }, select: { loading: '\u1780\u17C6\u1796\u17BB\u1784\u1795\u17D2\u1791\u17BB\u1780', noMatch: '\u1782\u17D2\u1798\u17B6\u1793\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u178A\u17BC\u1785', noData: '\u1782\u17D2\u1798\u17B6\u1793\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799', placeholder: '\u1787\u17D2\u179A\u17BE\u179F\u179A\u17BE\u179F', }, cascader: { noMatch: '\u1782\u17D2\u1798\u17B6\u1793\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u178A\u17BC\u1785', loading: '\u1780\u17C6\u1796\u17BB\u1784\u1795\u17D2\u1791\u17BB\u1780', placeholder: '\u1787\u17D2\u179A\u17BE\u179F\u179A\u17BE\u179F', noData: '\u1782\u17D2\u1798\u17B6\u1793\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799', }, pagination: { goto: '\u1791\u17C5\u1780\u17B6\u1793\u17CB', pagesize: '/\u1791\u17C6\u1796\u17D0\u179A', total: '\u179F\u179A\u17BB\u1794 {total}', pageClassifier: '', }, messagebox: { title: '\u179F\u17B6\u179A', confirm: '\u1799\u179B\u17CB\u1796\u17D2\u179A\u1798', cancel: '\u1794\u17C4\u17C7\u1794\u1784\u17CB', error: '\u1780\u17B6\u179A\u1794\u1789\u17D2\u1785\u17BC\u179B\u1798\u17B7\u1793\u178F\u17D2\u179A\u17BC\u179C\u1794\u17B6\u1793\u17A2\u1793\u17BB\u1789\u17D2\u1789\u17B6\u178F', }, upload: { deleteTip: '\u1785\u17BB\u1785\u179B\u17BB\u1794\u178A\u17BE\u1798\u17D2\u1794\u17B8\u178A\u1780\u1785\u17C1\u1789', delete: '\u179B\u17BB\u1794', preview: '\u1798\u17BE\u179B', continue: '\u1794\u1793\u17D2\u178F', }, table: { emptyText: '\u1782\u17D2\u1798\u17B6\u1793\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799', confirmFilter: '\u1799\u179B\u17CB\u1796\u17D2\u179A\u1798', resetFilter: '\u1780\u17C6\u178E\u178F\u17CB\u17A1\u17BE\u1784\u179C\u17B7\u1789', clearFilter: '\u1791\u17B6\u17C6\u1784\u17A2\u179F\u17CB', sumText: '\u1794\u17BC\u1780', }, tree: { emptyText: '\u1782\u17D2\u1798\u17B6\u1793\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799', }, transfer: { noMatch: '\u1782\u17D2\u1798\u17B6\u1793\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799\u178A\u17BC\u1785', noData: '\u1782\u17D2\u1798\u17B6\u1793\u1791\u17B7\u1793\u17D2\u1793\u1793\u17D0\u1799', titles: [ '\u1794\u1789\u17D2\u1787\u17B8 \u17E1', '\u1794\u1789\u17D2\u1787\u17B8 \u17E2', ], filterPlaceholder: '\u1794\u1789\u17D2\u1785\u17BC\u179B\u1796\u17B6\u1780\u17D2\u1799', noCheckedFormat: '{total} \u1792\u17B6\u178F\u17BB', hasCheckedFormat: '{checked}/{total} \u1794\u17B6\u1793\u1787\u17D2\u179A\u17BE\u179F\u1799\u1780', }, image: { error: '\u1798\u17B7\u1793\u1794\u17B6\u1793\u1787\u17C4\u1782\u1787\u17D0\u1799', }, pageHeader: { title: '\u178F\u17D2\u179A\u179B\u1794\u17CB\u1780\u17D2\u179A\u17C4\u1799', }, popconfirm: { confirmButtonText: '\u1799\u179B\u17CB\u1796\u17D2\u179A\u1798', cancelButtonText: '\u1798\u17B7\u1793\u1796\u17D2\u179A\u1798', }, }, } var __glob_8_26 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: km, }, Symbol.toStringTag, { value: 'Module' } ) ) var ko = { name: 'ko', el: { colorpicker: { confirm: '\uD655\uC778', clear: '\uCD08\uAE30\uD654', }, datepicker: { now: '\uC9C0\uAE08', today: '\uC624\uB298', cancel: '\uCDE8\uC18C', clear: '\uCD08\uAE30\uD654', confirm: '\uD655\uC778', selectDate: '\uB0A0\uC9DC \uC120\uD0DD', selectTime: '\uC2DC\uAC04 \uC120\uD0DD', startDate: '\uC2DC\uC791 \uB0A0\uC9DC', startTime: '\uC2DC\uC791 \uC2DC\uAC04', endDate: '\uC885\uB8CC \uB0A0\uC9DC', endTime: '\uC885\uB8CC \uC2DC\uAC04', prevYear: '\uC9C0\uB09C\uD574', nextYear: '\uB2E4\uC74C\uD574', prevMonth: '\uC9C0\uB09C\uB2EC', nextMonth: '\uB2E4\uC74C\uB2EC', year: '\uB144', month1: '1\uC6D4', month2: '2\uC6D4', month3: '3\uC6D4', month4: '4\uC6D4', month5: '5\uC6D4', month6: '6\uC6D4', month7: '7\uC6D4', month8: '8\uC6D4', month9: '9\uC6D4', month10: '10\uC6D4', month11: '11\uC6D4', month12: '12\uC6D4', weeks: { sun: '\uC77C', mon: '\uC6D4', tue: '\uD654', wed: '\uC218', thu: '\uBAA9', fri: '\uAE08', sat: '\uD1A0', }, months: { jan: '1\uC6D4', feb: '2\uC6D4', mar: '3\uC6D4', apr: '4\uC6D4', may: '5\uC6D4', jun: '6\uC6D4', jul: '7\uC6D4', aug: '8\uC6D4', sep: '9\uC6D4', oct: '10\uC6D4', nov: '11\uC6D4', dec: '12\uC6D4', }, }, select: { loading: '\uBD88\uB7EC\uC624\uB294 \uC911', noMatch: '\uAC80\uC0C9\uB41C \uB370\uC774\uD130 \uC5C6\uC74C', noData: '\uB370\uC774\uD130 \uC5C6\uC74C', placeholder: '\uC120\uD0DD', }, cascader: { noMatch: '\uAC80\uC0C9\uB41C \uB370\uC774\uD130 \uC5C6\uC74C', loading: '\uBD88\uB7EC\uC624\uB294 \uC911', placeholder: '\uC120\uD0DD', noData: '\uB370\uC774\uD130 \uC5C6\uC74C', }, pagination: { goto: '', pagesize: '\uAC74/\uD398\uC774\uC9C0', total: '\uCD1D {total} \uAC74', pageClassifier: '\uD398\uC774\uC9C0\uB85C', }, messagebox: { title: '\uBA54\uC2DC\uC9C0', confirm: '\uD655\uC778', cancel: '\uCDE8\uC18C', error: '\uC62C\uBC14\uB974\uC9C0 \uC54A\uC740 \uC785\uB825', }, upload: { deleteTip: 'Delete \uD0A4\uB97C \uB20C\uB7EC \uC0AD\uC81C', delete: '\uC0AD\uC81C', preview: '\uBBF8\uB9AC\uBCF4\uAE30', continue: '\uACC4\uC18D\uD558\uAE30', }, table: { emptyText: '\uB370\uC774\uD130 \uC5C6\uC74C', confirmFilter: '\uD655\uC778', resetFilter: '\uCD08\uAE30\uD654', clearFilter: '\uC804\uCCB4', sumText: '\uD569\uACC4', }, tree: { emptyText: '\uB370\uC774\uD130 \uC5C6\uC74C', }, transfer: { noMatch: '\uAC80\uC0C9\uB41C \uB370\uC774\uD130 \uC5C6\uC74C', noData: '\uB370\uC774\uD130 \uC5C6\uC74C', titles: ['\uB9AC\uC2A4\uD2B8 1', '\uB9AC\uC2A4\uD2B8 2'], filterPlaceholder: '\uAC80\uC0C9\uC5B4\uB97C \uC785\uB825\uD558\uC138\uC694', noCheckedFormat: '\uCD1D {total} \uAC74', hasCheckedFormat: '{checked}/{total} \uC120\uD0DD\uB428', }, image: { error: '\uBD88\uB7EC\uC624\uAE30 \uC2E4\uD328', }, pageHeader: { title: '\uB4A4\uB85C', }, popconfirm: { confirmButtonText: '\uC608', cancelButtonText: '\uC544\uB2C8\uC624', }, }, } var __glob_8_27 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: ko, }, Symbol.toStringTag, { value: 'Module' } ) ) var ku = { name: 'ku', el: { colorpicker: { confirm: 'Temam', clear: 'Paqij bike', }, datepicker: { now: 'Niha', today: '\xCEro', cancel: 'Betal bike', clear: 'Paqij bike', confirm: 'Temam', selectDate: 'D\xEErok\xEA bibij\xEAre', selectTime: 'Dem\xEA bibij\xEAre', startDate: 'D\xEEroka Destp\xEAk\xEA', startTime: 'Dema Destp\xEAk\xEA', endDate: 'D\xEEroka Daw\xEE', endTime: 'Dema Daw\xEE', prevYear: 'Sala P\xEA\u015F', nextYear: 'Sala Pa\u015F', prevMonth: 'Meha P\xEA\u015F', nextMonth: 'Meha Pa\u015F', year: 'Sal', month1: 'R\xEAbendan', month2: 'Re\u015Femeh', month3: 'Adar', month4: 'Avr\xEAl', month5: 'Gulan', month6: 'P\xFB\u015Fber', month7: 'T\xEErmeh', month8: 'Gilav\xEAj', month9: 'Rezber', month10: 'Kew\xE7\xEAr', month11: 'Sarmawaz', month12: 'Berfanbar', weeks: { sun: 'Yek', mon: 'Du\u015F', tue: 'S\xEA\u015F', wed: '\xC7ar', thu: 'P\xEAn', fri: '\xCEn', sat: '\u015Eem', }, months: { jan: 'R\xEAb', feb: 'Re\u015F', mar: 'Ada', apr: 'Avr', may: 'Gul', jun: 'P\xFB\u015F', jul: 'T\xEEr', aug: 'Gil', sep: 'Rez', oct: 'Kew', nov: 'Sar', dec: 'Ber', }, }, select: { loading: 'Bardibe', noMatch: 'Li hembere ve agah\xEE tune', noData: 'Agah\xEE tune', placeholder: 'Bibij\xEAre', }, cascader: { noMatch: 'Li hembere ve agah\xEE tune', loading: 'Bardibe', placeholder: 'Bibij\xEAre', noData: 'Agah\xEE tune', }, pagination: { goto: 'Bi\xE7e', pagesize: '/rupel', total: 'Tevah\xEE {total}', pageClassifier: '', }, messagebox: { title: 'Peyam', confirm: 'Temam', cancel: 'Betal bike', error: 'Beyana \xE7ewt', }, upload: { deleteTip: 'ji bo rake p\xEAl "delete" bike', delete: 'Rake', preview: 'P\xEA\u015Fd\xEEtin', continue: 'Berdewam', }, table: { emptyText: 'Agah\xEE tune', confirmFilter: 'Pi\u015Ftrast bike', resetFilter: 'J\xEA bibe', clearFilter: 'Hem\xFB', sumText: 'Kom', }, tree: { emptyText: 'Agah\xEE tune', }, transfer: { noMatch: 'Li hembere ve agah\xEE tune', noData: 'Agah\xEE tune', titles: ['L\xEEste 1', 'L\xEEste 2'], filterPlaceholder: 'Biniv\xEEse', noCheckedFormat: '{total} lib', hasCheckedFormat: '{checked}/{total} bijartin', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_28 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: ku, }, Symbol.toStringTag, { value: 'Module' } ) ) var ky = { name: 'ky', el: { colorpicker: { confirm: '\u041C\u0443\u0440\u0443\u043D\u043A\u0443', clear: '\u0430\u0447\u044B\u043A', }, datepicker: { now: '\u0430\u0437\u044B\u0440', today: '\u0431\u04AF\u0433\u04AF\u043D', cancel: '\u0436\u043E\u043A\u043A\u043E \u0447\u044B\u0433\u0430\u0440\u044B\u043B\u0434\u044B', clear: '\u0430\u0447\u044B\u043A', confirm: '\u0431\u0435\u043B\u0433\u0438\u043B\u04E9\u04E9', selectDate: '\u0434\u0430\u0442\u0430', selectTime: '\u0442\u0430\u043D\u0434\u043E\u043E \u0443\u0431\u0430\u043A\u0442\u044B\u0441\u044B', startDate: '\u0411\u0430\u0448\u0442\u0430\u043B\u0433\u0430\u043D \u0434\u0430\u0442\u0430\u0441\u044B', startTime: 'Start \u0443\u0431\u0430\u043A\u044B\u0442', endDate: '\u0411\u04AF\u0442\u043A\u04E9\u043D \u0434\u0430\u0442\u0430\u0441\u044B', endTime: 'End \u0443\u0431\u0430\u043A\u044B\u0442', prevYear: '\u04E9\u0442\u043A\u04E9\u043D \u0436\u044B\u043B\u044B', nextYear: '\u0431\u0438\u0440 \u0436\u044B\u043B\u0434\u0430\u043D \u043A\u0438\u0439\u0438\u043D', prevMonth: '\u04E8\u0442\u043A\u04E9\u043D \u0430\u0439\u0434\u0430', nextMonth: '\u041A\u0438\u0439\u0438\u043D\u043A\u0438 \u0430\u0439', year: '\u0436\u044B\u043B', month1: '\u0431\u0438\u0440\u0438\u043D\u0447\u0438 \u0430\u0439', month2: '\u042D\u043A\u0438\u043D\u0447\u0438 \u0430\u0439\u0434\u0430', month3: '\u04AE\u0447\u04AF\u043D\u0447\u04AF \u0430\u0439\u0434\u0430', month4: '\u0422\u04E9\u0440\u0442\u04AF\u043D\u0447\u04AF \u0430\u0439\u0434\u0430', month5: '\u0431\u0435\u0448\u0438\u043D\u0447\u0438 \u0430\u0439\u0434\u0430', month6: '\u0410\u043B\u0433\u0430\u0447\u043A\u044B \u0430\u043B\u0442\u044B \u0430\u0439', month7: '\u0436\u0435\u0442\u0438\u043D\u0447\u0438 \u0430\u0439\u0434\u0430', month8: '\u0441\u0435\u0433\u0438\u0437\u0438\u043D\u0447\u0438 \u0430\u0439', month9: '\u0410\u043B\u0433\u0430\u0447\u043A\u044B \u0442\u043E\u0433\u0443\u0437 \u0430\u0439', month10: '\u043E\u043D\u0443\u043D\u0447\u0443 \u0430\u0439\u0434\u0430', month11: '\u043E\u043D \u0431\u0438\u0440\u0438\u043D\u0447\u0438 \u0430\u0439', month12: '\u043E\u043D \u044D\u043A\u0438\u043D\u0447\u0438 \u0430\u0439\u0434\u0430', weeks: { sun: '\u0436\u0435\u0442\u0438 \u0436\u0443\u043C\u0430', mon: '\u0434\u04AF\u0439\u0448\u04E9\u043C\u0431\u04AF', tue: '\u0448\u0435\u0439\u0448\u0435\u043C\u0431\u0438', wed: '\u0448\u0430\u0440\u0448\u0435\u043C\u0431\u0438', thu: '\u0431\u0435\u0439\u0448\u0435\u043C\u0431\u0438', fri: '\u0436\u0443\u043C\u0430', sat: '\u0438\u0448\u0435\u043C\u0431\u0438', }, months: { jan: '\u0431\u0438\u0440\u0438\u043D\u0447\u0438 \u0430\u0439', feb: '\u042D\u043A\u0438\u043D\u0447\u0438 \u0430\u0439\u0434\u0430', mar: '\u04AE\u0447\u04AF\u043D\u0447\u04AF \u0430\u0439\u0434\u0430', apr: '\u0422\u04E9\u0440\u0442\u04AF\u043D\u0447\u04AF \u0430\u0439\u0434\u0430', may: '\u0431\u0435\u0448\u0438\u043D\u0447\u0438 \u0430\u0439\u0434\u0430', jun: '\u0410\u043B\u0433\u0430\u0447\u043A\u044B \u0430\u043B\u0442\u044B \u0430\u0439', jul: '\u0436\u0435\u0442\u0438\u043D\u0447\u0438 \u0430\u0439\u0434\u0430', aug: '\u0441\u0435\u0433\u0438\u0437\u0438\u043D\u0447\u0438 \u0430\u0439', sep: '\u0410\u043B\u0433\u0430\u0447\u043A\u044B \u0442\u043E\u0433\u0443\u0437 \u0430\u0439', oct: '\u043E\u043D\u0443\u043D\u0447\u0443 \u0430\u0439\u0434\u0430', nov: '\u043E\u043D \u0431\u0438\u0440\u0438\u043D\u0447\u0438 \u0430\u0439', dec: '\u043E\u043D \u044D\u043A\u0438\u043D\u0447\u0438 \u0430\u0439\u0434\u0430', }, }, select: { loading: '\u0416\u04AF\u043A\u0442\u04E9\u043B\u04AF\u04AF\u0434\u04E9', noMatch: '\u0414\u0430\u043B \u043A\u0435\u043B\u0433\u0435\u043D \u043C\u0430\u0430\u043B\u044B\u043C\u0430\u0442\u0442\u0430\u0440', noData: '\u043C\u0430\u0430\u043B\u044B\u043C\u0430\u0442 \u0436\u043E\u043A', placeholder: '\u0442\u0430\u043D\u0434\u043E\u043E', }, cascader: { noMatch: '\u0414\u0430\u043B \u043A\u0435\u043B\u0433\u0435\u043D \u043C\u0430\u0430\u043B\u044B\u043C\u0430\u0442\u0442\u0430\u0440', loading: '\u0416\u04AF\u043A\u0442\u04E9\u043B\u04AF\u04AF\u0434\u04E9', placeholder: '\u0442\u0430\u043D\u0434\u043E\u043E', noData: '\u043C\u0430\u0430\u043B\u044B\u043C\u0430\u0442 \u0436\u043E\u043A', }, pagination: { goto: '\u041C\u0443\u0440\u0443\u043D\u043A\u0443', pagesize: '\u0431\u0438\u0440', total: '\u0431\u04AF\u0442\u04AF\u043D\u0434\u04E9\u0439 {total} \u0441\u0430\u043D ', pageClassifier: '\u0431\u0435\u0442', }, messagebox: { title: '\u0442\u0435\u0437', confirm: '\u0431\u0435\u043B\u0433\u0438\u043B\u04E9\u04E9', cancel: '\u0436\u043E\u043A\u043A\u043E \u0447\u044B\u0433\u0430\u0440\u044B\u043B\u0434\u044B', error: '\u041C\u0430\u0430\u043B\u044B\u043C\u0430\u0442\u0442\u0430\u0440\u0434\u044B \u043A\u0438\u0440\u0433\u0438\u0437\u04AF\u04AF \u043C\u044B\u0439\u0437\u0430\u043C\u0434\u0443\u0443 \u044D\u043C\u0435\u0441!', }, upload: { deleteTip: '\u0416\u043E\u043A \u043A\u044B\u043B\u0443\u0443 \u0431\u0430\u0441\u043A\u044B\u0447\u044B\u043D \u0431\u0430\u0441\u0443\u0443 \u0436\u043E\u043A', delete: '\u0436\u043E\u043A \u043A\u044B\u043B\u0443\u0443', preview: '\u0416\u041C\u041A\u043D\u044B\u043D \u043A\u0430\u0440\u0442\u0438\u043D\u043A\u0438', continue: '\u0436\u04AF\u043A\u0442\u04E9\u043F \u0431\u0435\u0440', }, table: { emptyText: '\u043C\u0430\u0430\u043B\u044B\u043C\u0430\u0442 \u0436\u043E\u043A', confirmFilter: '\u0447\u044B\u043F\u043A\u0430', resetFilter: '\u043A\u0430\u0439\u0440\u0430 \u043E\u0440\u043D\u043E\u0442\u0443\u0443', clearFilter: '\u0431\u04AF\u0442\u043A\u04E9\u043D', sumText: '\u0411\u0430\u0440\u0434\u044B\u0433\u044B \u0431\u043E\u043B\u0443\u043F', }, tree: { emptyText: '\u043C\u0430\u0430\u043B\u044B\u043C\u0430\u0442 \u0436\u043E\u043A', }, transfer: { noMatch: '\u0414\u0430\u043B \u043A\u0435\u043B\u0433\u0435\u043D \u043C\u0430\u0430\u043B\u044B\u043C\u0430\u0442\u0442\u0430\u0440', noData: '\u043C\u0430\u0430\u043B\u044B\u043C\u0430\u0442 \u0436\u043E\u043A', titles: [ '1 \u0442\u0438\u0437\u043C\u0435\u0441\u0438', '2 \u0442\u0438\u0437\u043C\u0435\u0441\u0438', ], filterPlaceholder: '\u0421\u0443\u0440\u0430\u043D\u044B\u0447, \u0438\u0437\u0434\u04E9\u04E9 \u043A\u0438\u0440\u0435\u0442', noCheckedFormat: '\u0431\u04AF\u0442\u04AF\u043D\u0434\u04E9\u0439 {total} \u0441\u0430\u043D', hasCheckedFormat: '\u0422\u0430\u043D\u0434\u0430\u043B\u0433\u0430\u043D {checked}/{total} \u0441\u0430\u043D', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_29 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: ky, }, Symbol.toStringTag, { value: 'Module' } ) ) var lt$2 = { name: 'lt', el: { colorpicker: { confirm: 'OK', clear: 'Valyti', }, datepicker: { now: 'Dabar', today: '\u0160iandien', cancel: 'At\u0161aukti', clear: 'Valyti', confirm: 'OK', selectDate: 'Pasirink dat\u0105', selectTime: 'Pasirink laik\u0105', startDate: 'Data nuo', startTime: 'Laikas nuo', endDate: 'Data iki', endTime: 'Laikas iki', prevYear: 'Metai atgal', nextYear: 'Metai \u012F priek\u012F', prevMonth: 'M\u0117n. atgal', nextMonth: 'M\u0117n. \u012F priek\u012F', year: '', month1: 'Sausis', month2: 'Vasaris', month3: 'Kovas', month4: 'Balandis', month5: 'Gegu\u017E\u0117', month6: 'Bir\u017Eelis', month7: 'Liepa', month8: 'Rugpj\u016Btis', month9: 'Rugs\u0117jis', month10: 'Spalis', month11: 'Lapkritis', month12: 'Gruodis', weeks: { sun: 'S.', mon: 'Pr.', tue: 'A.', wed: 'T.', thu: 'K.', fri: 'Pn.', sat: '\u0160.', }, months: { jan: 'Sau', feb: 'Vas', mar: 'Kov', apr: 'Bal', may: 'Geg', jun: 'Bir', jul: 'Lie', aug: 'Rugp', sep: 'Rugs', oct: 'Spa', nov: 'Lap', dec: 'Gruo', }, }, select: { loading: 'Kraunasi', noMatch: 'Duomen\u0173 nerasta', noData: 'N\u0117ra duomen\u0173', placeholder: 'Pasirink', }, cascader: { noMatch: 'Duomen\u0173 nerasta', loading: 'Kraunasi', placeholder: 'Pasirink', noData: 'N\u0117ra duomen\u0173', }, pagination: { goto: 'Eiti \u012F', pagesize: '/p', total: 'Viso {total}', pageClassifier: '', }, messagebox: { title: '\u017Dinut\u0117', confirm: 'OK', cancel: 'At\u0161aukti', error: 'Klaida \u012Fvestuose duomenyse', }, upload: { deleteTip: 'spauskite "Trinti" nor\u0117dami pa\u0161alinti', delete: 'Trinti', preview: 'Per\u017Ei\u016Br\u0117ti', continue: 'Toliau', }, table: { emptyText: 'Duomen\u0173 nerasta', confirmFilter: 'Patvirtinti', resetFilter: 'Atstatyti', clearFilter: 'I\u0161valyti', sumText: 'Suma', }, tree: { emptyText: 'N\u0117ra duomen\u0173', }, transfer: { noMatch: 'Duomen\u0173 nerasta', noData: 'N\u0117ra duomen\u0173', titles: ['S\u0105ra\u0161as 1', 'S\u0105ra\u0161as 2'], filterPlaceholder: '\u012Evesk rakta\u017Eod\u012F', noCheckedFormat: 'Viso: {total}', hasCheckedFormat: 'Pa\u017Eym\u0117ta {checked} i\u0161 {total}', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_30 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: lt$2, }, Symbol.toStringTag, { value: 'Module' } ) ) var lv = { name: 'lv', el: { colorpicker: { confirm: 'Labi', clear: 'Not\u012Br\u012Bt', }, datepicker: { now: 'Tagad', today: '\u0160odien', cancel: 'Atcelt', clear: 'Not\u012Br\u012Bt', confirm: 'Labi', selectDate: 'Izv\u0113l\u0113ties datumu', selectTime: 'Izv\u0113l\u0113ties laiku', startDate: 'S\u0101kuma datums', startTime: 'S\u0101kuma laiks', endDate: 'Beigu datums', endTime: 'Beigu laiks', prevYear: 'Iepriek\u0161\u0113jais gads', nextYear: 'N\u0101kamais gads', prevMonth: 'Iepriek\u0161\u0113jais m\u0113nesis', nextMonth: 'N\u0101kamais m\u0113nesis', year: '', month1: 'Janv\u0101ris', month2: 'Febru\u0101ris', month3: 'Marts', month4: 'Apr\u012Blis', month5: 'Maijs', month6: 'J\u016Bnijs', month7: 'J\u016Blijs', month8: 'Augusts', month9: 'Septembris', month10: 'Oktobris', month11: 'Novembris', month12: 'Decembris', weeks: { sun: 'Sv', mon: 'Pr', tue: 'Ot', wed: 'Tr', thu: 'Ce', fri: 'Pk', sat: 'Se', }, months: { jan: 'Jan', feb: 'Feb', mar: 'Mar', apr: 'Apr', may: 'Mai', jun: 'J\u016Bn', jul: 'J\u016Bl', aug: 'Aug', sep: 'Sep', oct: 'Okt', nov: 'Nov', dec: 'Dec', }, }, select: { loading: 'Iel\u0101d\u0113', noMatch: 'Nav atbilsto\u0161u datu', noData: 'Nav datu', placeholder: 'Izv\u0113l\u0113ties', }, cascader: { noMatch: 'Nav atbilsto\u0161u datu', loading: 'Iel\u0101d\u0113', placeholder: 'Izv\u0113l\u0113ties', noData: 'Nav datu', }, pagination: { goto: 'Iet uz', pagesize: '/lapa', total: 'Kop\u0101 {total}', pageClassifier: '', }, messagebox: { title: 'Pazi\u0146ojums', confirm: 'Labi', cancel: 'Atcelt', error: 'Neder\u012Bga ievade', }, upload: { deleteTip: 'Nospiediet dz\u0113st lai iz\u0146emtu', delete: 'Dz\u0113st', preview: 'Priek\u0161skat\u012Bt', continue: 'Turpin\u0101t', }, table: { emptyText: 'Nav datu', confirmFilter: 'Apstiprin\u0101t', resetFilter: 'Atiestat\u012Bt', clearFilter: 'Visi', sumText: 'Summa', }, tree: { emptyText: 'Nav datu', }, transfer: { noMatch: 'Nav atbilsto\u0161u datu', noData: 'Nav datu', titles: ['Saraksts 1', 'Saraksts 2'], filterPlaceholder: 'Ievad\u012Bt atsl\u0113gv\u0101rdu', noCheckedFormat: '{total} vien\u012Bbas', hasCheckedFormat: '{checked}/{total} atz\u012Bm\u0113ti', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_31 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: lv, }, Symbol.toStringTag, { value: 'Module' } ) ) var mg = { name: 'mg', el: { colorpicker: { confirm: 'ENY', clear: 'Fafana', }, datepicker: { now: 'Zao', today: 'Androany', cancel: 'Hanafoana', clear: 'Fafana', confirm: 'ENY', selectDate: 'Misafidy daty', selectTime: 'Misafidy ora', startDate: 'Daty fanombohana', startTime: 'Ora fanombohana', endDate: 'Daty farany', endTime: 'Ora farany', prevYear: 'Taona teo aloha', nextYear: 'Taona manaraka', prevMonth: 'Volana teo aloha', nextMonth: 'Volana manaraka', year: '', month1: 'Janoary', month2: 'Febroary', month3: 'Martsa', month4: 'Aprily', month5: 'May', month6: 'Jona', month7: 'Jolay', month8: 'Aogositra', month9: 'Septambra', month10: 'Oktobra', month11: 'Novambra', month12: 'Desambra', week: 'herinandro', weeks: { sun: 'Lad', mon: 'Ala', tue: 'Tal', wed: 'Lar', thu: 'Lak', fri: 'Zom', sat: 'Sab', }, months: { jan: 'Jan', feb: 'Feb', mar: 'Mar', apr: 'Apr', may: 'May', jun: 'Jon', jul: 'Jol', aug: 'Aog', sep: 'Sep', oct: 'Okt', nov: 'Nov', dec: 'Des', }, }, select: { loading: 'Eo ampiandrasana', noMatch: 'Tsy misy angona mifanentana', noData: 'Tsy misy angona', placeholder: 'Safidy', }, cascader: { noMatch: 'Tsy misy angona mifanentana', loading: 'Eo ampiandrasana', placeholder: 'Safidy', noData: 'Tsy misy angona', }, pagination: { goto: 'Mandeha any', pagesize: '/page', total: 'Totaly {total}', pageClassifier: '', deprecationWarning: 'Fampiasana tsy ampiasaina intsony no hita, azafady mba jereo ny tahirin-kevitra el-pagination raha mila fanazavana fanampiny', }, messagebox: { title: 'Hafatra', confirm: 'ENY', cancel: 'Hanafoana', error: 'Fampidirana tsy ara-dal\xE0na', }, upload: { deleteTip: 'tsindrio fafana raha hanala', delete: 'Fafana', preview: 'Topi-maso', continue: 'Hanoy', }, table: { emptyText: 'Tsy misy angona', confirmFilter: 'Manamarina', resetFilter: 'Averina', clearFilter: 'Rehetra', sumText: 'Atambatra', }, tree: { emptyText: 'Tsy misy angona', }, transfer: { noMatch: 'Tsy misy angona mifanentana', noData: 'Tsy misy angona', titles: ['Lisitra 1', 'Lisitra 2'], filterPlaceholder: 'Ampidiro teny fanalahidy', noCheckedFormat: '{total} zavatra', hasCheckedFormat: '{checked}/{total} voamarina', }, image: { error: 'TSY NAHOMBY', }, pageHeader: { title: 'Miverina', }, popconfirm: { confirmButtonText: 'Eny', cancelButtonText: 'Tsy', }, }, } var __glob_8_32 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: mg, }, Symbol.toStringTag, { value: 'Module' } ) ) var mn = { name: 'mn', el: { colorpicker: { confirm: '\u0422\u0438\u0439\u043C', clear: '\u0426\u044D\u0432\u044D\u0440\u043B\u044D\u0445', }, datepicker: { now: '\u041E\u0434\u043E\u043E', today: '\u04E8\u043D\u04E9\u04E9\u0434\u04E9\u0440', cancel: '\u0411\u043E\u043B\u0438\u0445', clear: '\u0426\u044D\u0432\u044D\u0440\u043B\u044D\u0445', confirm: '\u0422\u0438\u0439\u043C', selectDate: '\u041E\u0433\u043D\u043E\u043E\u0433 \u0441\u043E\u043D\u0433\u043E', selectTime: '\u0426\u0430\u0433\u0438\u0439\u0433 \u0441\u043E\u043D\u0433\u043E', startDate: '\u042D\u0445\u043B\u044D\u0445 \u043E\u0433\u043D\u043E\u043E', startTime: '\u042D\u0445\u043B\u044D\u0445 \u0446\u0430\u0433', endDate: '\u0414\u0443\u0443\u0441\u0430\u0445 \u043E\u0433\u043D\u043E\u043E', endTime: '\u0414\u0443\u0443\u0441\u0430\u0445 \u0446\u0430\u0433', prevYear: '\u04E8\u043C\u043D\u04E9\u0445 \u0436\u0438\u043B', nextYear: '\u0414\u0430\u0440\u0430\u0430 \u0436\u0438\u043B', prevMonth: '\u04E8\u043C\u043D\u04E9\u0445 \u0441\u0430\u0440', nextMonth: '\u0414\u0430\u0440\u0430\u0430 \u0441\u0430\u0440', year: '\u043E\u043D', month1: '1 \u0441\u0430\u0440', month2: '2 \u0441\u0430\u0440', month3: '3 \u0441\u0430\u0440', month4: '4 \u0441\u0430\u0440', month5: '5 \u0441\u0430\u0440', month6: '6 \u0441\u0430\u0440', month7: '7 \u0441\u0430\u0440', month8: '8 \u0441\u0430\u0440', month9: '9 \u0441\u0430\u0440', month10: '10 \u0441\u0430\u0440', month11: '11 \u0441\u0430\u0440', month12: '12 \u0441\u0430\u0440', week: '\u0414\u043E\u043B\u043E\u043E \u0445\u043E\u043D\u043E\u0433', weeks: { sun: '\u041D\u044F\u043C', mon: '\u0414\u0430\u0432', tue: '\u041C\u044F\u0433', wed: '\u041B\u0445\u0430', thu: '\u041F\u04AF\u0440', fri: '\u0411\u0430\u0430', sat: '\u0411\u044F\u043C', }, months: { jan: '1 \u0441\u0430\u0440', feb: '2 \u0441\u0430\u0440', mar: '3 \u0441\u0430\u0440', apr: '4 \u0441\u0430\u0440', may: '5 \u0441\u0430\u0440', jun: '6 \u0441\u0430\u0440', jul: '7 \u0441\u0430\u0440', aug: '8 \u0441\u0430\u0440', sep: '9 \u0441\u0430\u0440', oct: '10 \u0441\u0430\u0440', nov: '11 \u0441\u0430\u0440', dec: '12 \u0441\u0430\u0440', }, }, select: { loading: '\u0410\u0447\u0430\u0430\u043B\u0436 \u0431\u0430\u0439\u043D\u0430', noMatch: '\u0422\u043E\u0445\u0438\u0440\u043E\u0445 \u04E9\u0433\u04E9\u0433\u0434\u04E9\u043B \u0431\u0430\u0439\u0445\u0433\u04AF\u0439', noData: '\u04E8\u0433\u04E9\u0433\u0434\u04E9\u043B \u0431\u0430\u0439\u0445\u0433\u04AF\u0439', placeholder: '\u0421\u043E\u043D\u0433\u043E\u0445', }, cascader: { noMatch: '\u0422\u043E\u0445\u0438\u0440\u043E\u0445 \u04E9\u0433\u04E9\u0433\u0434\u04E9\u043B \u0431\u0430\u0439\u0445\u0433\u04AF\u0439', loading: '\u0410\u0447\u0430\u0430\u043B\u0436 \u0431\u0430\u0439\u043D\u0430', placeholder: '\u0421\u043E\u043D\u0433\u043E\u0445', noData: '\u04E8\u0433\u04E9\u0433\u0434\u04E9\u043B \u0431\u0430\u0439\u0445\u0433\u04AF\u0439', }, pagination: { goto: '\u041E\u0447\u0438\u0445', pagesize: '/\u0445\u0443\u0443\u0434\u0430\u0441', total: '\u041D\u0438\u0439\u0442 {total}', pageClassifier: '', }, messagebox: { title: '\u0417\u0443\u0440\u0432\u0430\u0441', confirm: '\u0422\u0438\u0439\u043C', cancel: '\u0411\u043E\u043B\u0438\u0445', error: '\u0411\u0443\u0440\u0443\u0443 \u0443\u0442\u0433\u0430', }, upload: { deleteTip: '\u0423\u0441\u0442\u0433\u0430\u0445\u044B\u043D \u0434\u0430\u0440\u0436 \u0430\u0440\u0438\u043B\u0433\u0430', delete: '\u0423\u0441\u0442\u0433\u0430\u0445', preview: '\u04E8\u043C\u043D\u04E9\u0445', continue: '\u04AE\u0440\u0433\u044D\u043B\u0436\u043B\u04AF\u04AF\u043B\u044D\u0445', }, table: { emptyText: '\u04E8\u0433\u04E9\u0433\u0434\u04E9\u043B \u0431\u0430\u0439\u0445\u0433\u04AF\u0439', confirmFilter: '\u0417\u04E9\u0432\u0448\u04E9\u04E9\u0440\u04E9\u0445', resetFilter: '\u0426\u044D\u0432\u044D\u0440\u043B\u044D\u0445', clearFilter: '\u0411\u04AF\u0433\u0434', sumText: '\u041D\u0438\u0439\u0442', }, tree: { emptyText: '\u04E8\u0433\u04E9\u0433\u0434\u04E9\u043B \u0431\u0430\u0439\u0445\u0433\u04AF\u0439', }, transfer: { noMatch: '\u0422\u043E\u0445\u0438\u0440\u043E\u0445 \u04E9\u0433\u04E9\u0433\u0434\u04E9\u043B \u0431\u0430\u0439\u0445\u0433\u04AF\u0439', noData: '\u04E8\u0433\u04E9\u0433\u0434\u04E9\u043B \u0431\u0430\u0439\u0445\u0433\u04AF\u0439', titles: [ '\u0416\u0430\u0433\u0441\u0430\u0430\u043B\u0442 1', '\u0416\u0430\u0433\u0441\u0430\u0430\u043B\u0442 2', ], filterPlaceholder: '\u0423\u0442\u0433\u0430 \u043E\u0440\u0443\u0443\u043B', noCheckedFormat: '{total} \u04E9\u0433\u04E9\u0433\u0434\u04E9\u043B', hasCheckedFormat: '{checked}/{total} \u0441\u043E\u043D\u0433\u043E\u0441\u043E\u043D', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_33 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: mn, }, Symbol.toStringTag, { value: 'Module' } ) ) var nbNo = { name: 'nb-no', el: { colorpicker: { confirm: 'OK', clear: 'T\xF8m', }, datepicker: { now: 'N\xE5', today: 'I dag', cancel: 'Avbryt', clear: 'T\xF8m', confirm: 'OK', selectDate: 'Velg dato', selectTime: 'Velg tidspunkt', startDate: 'Startdato', startTime: 'Starttidspunkt', endDate: 'Sluttdato', endTime: 'Sluttidspunkt', prevYear: 'I fjor', nextYear: 'Neste \xE5r', prevMonth: 'Forrige M\xE5ned', nextMonth: 'Neste M\xE5ned', year: '', month1: 'Januar', month2: 'Februar', month3: 'Mars', month4: 'April', month5: 'Mai', month6: 'Juni', month7: 'Juli', month8: 'August', month9: 'September', month10: 'Oktober', month11: 'November', month12: 'Desember', week: 'uke', weeks: { sun: 'S\xF8n', mon: 'Man', tue: 'Tir', wed: 'Ons', thu: 'Tor', fri: 'Fre', sat: 'L\xF8r', }, months: { jan: 'Jan', feb: 'Feb', mar: 'Mar', apr: 'Apr', may: 'Mai', jun: 'Jun', jul: 'Jul', aug: 'Aug', sep: 'Sep', oct: 'Okt', nov: 'Nov', dec: 'Des', }, }, select: { loading: 'Laster', noMatch: 'Ingen samsvarende resulater', noData: 'Ingen resulater', placeholder: 'Velg', }, cascader: { noMatch: 'Ingen samsvarende resultater', loading: 'Laster', placeholder: 'Velg', noData: 'Ingen resultater', }, pagination: { goto: 'G\xE5 til', pagesize: '/side', total: 'Total {total}', pageClassifier: '', }, messagebox: { confirm: 'OK', cancel: 'Avbryt', error: 'Ugyldig input', }, upload: { deleteTip: 'trykk p\xE5 x for \xE5 slette', delete: 'Slett', preview: 'Forh\xE5ndsvisning', continue: 'Fortsett', }, table: { emptyText: 'Ingen Data', confirmFilter: 'Bekreft', resetFilter: 'Tilbakestill', clearFilter: 'Alle', sumText: 'Sum', }, tree: { emptyText: 'Ingen Data', }, transfer: { noMatch: 'Ingen samsvarende data', noData: 'Ingen data', titles: ['Liste 1', 'Liste 2'], filterPlaceholder: 'Skriv inn n\xF8kkelord', noCheckedFormat: '{total} gjenstander', hasCheckedFormat: '{checked}/{total} valgt', }, image: { error: 'FEILET', }, pageHeader: { title: 'Tilbake', }, popconfirm: { confirmButtonText: 'Ja', cancelButtonText: 'Nei', }, }, } var __glob_8_34 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: nbNo, }, Symbol.toStringTag, { value: 'Module' } ) ) var nl = { name: 'nl', el: { colorpicker: { confirm: 'Bevestig', clear: 'Wissen', }, datepicker: { now: 'Nu', today: 'Vandaag', cancel: 'Annuleren', clear: 'Legen', confirm: 'Bevestig', selectDate: 'Selecteer datum', selectTime: 'Selecteer tijd', startDate: 'Startdatum', startTime: 'Starttijd', endDate: 'Einddatum', endTime: 'Eindtijd', prevYear: 'Vorig jaar', nextYear: 'Volgend jaar', prevMonth: 'Vorige maand', nextMonth: 'Volgende maand', year: '', month1: 'januari', month2: 'februari', month3: 'maart', month4: 'april', month5: 'mei', month6: 'juni', month7: 'juli', month8: 'augustus', month9: 'september', month10: 'oktober', month11: 'november', month12: 'december', weeks: { sun: 'Zo', mon: 'Ma', tue: 'Di', wed: 'Wo', thu: 'Do', fri: 'Vr', sat: 'Za', }, months: { jan: 'jan', feb: 'feb', mar: 'maa', apr: 'apr', may: 'mei', jun: 'jun', jul: 'jul', aug: 'aug', sep: 'sep', oct: 'okt', nov: 'nov', dec: 'dec', }, }, select: { loading: 'Laden', noMatch: 'Geen overeenkomende resultaten', noData: 'Geen data', placeholder: 'Selecteer', }, cascader: { noMatch: 'Geen overeenkomende resultaten', loading: 'Laden', placeholder: 'Selecteer', noData: 'Geen data', }, pagination: { goto: 'Ga naar', pagesize: '/pagina', total: 'Totaal {total}', pageClassifier: '', }, messagebox: { title: 'Bericht', confirm: 'Bevestig', cancel: 'Annuleren', error: 'Ongeldige invoer', }, upload: { deleteTip: 'Kies verwijder om te wissen', delete: 'Verwijder', preview: 'Voorbeeld', continue: 'Doorgaan', }, table: { emptyText: 'Geen data', confirmFilter: 'Bevestigen', resetFilter: 'Reset', clearFilter: 'Alles', sumText: 'Som', }, tree: { emptyText: 'Geen data', }, transfer: { noMatch: 'Geen overeenkomende resultaten', noData: 'Geen data', titles: ['Lijst 1', 'Lijst 2'], filterPlaceholder: 'Geef zoekwoerd', noCheckedFormat: '{total} items', hasCheckedFormat: '{checked}/{total} geselecteerd', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_35 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: nl, }, Symbol.toStringTag, { value: 'Module' } ) ) var pa = { name: 'pa', el: { colorpicker: { confirm: '\u062A\u0627\u06CC\u06CC\u062F', clear: '\u067E\u0627\u06A9\u0648\u0644', }, datepicker: { now: '\u0627\u0648\u0633', today: '\u0646\u0646', cancel: '\u0631\u062F\u0648\u0644', clear: '\u067E\u0627\u06A9\u0648\u0644', confirm: '\u062A\u0627\u06CC\u06CC\u062F', selectDate: '\u0646\u06CC\u067C\u0647 \u0648\u067C\u0627\u06A9\u0626', selectTime: '\u0648\u062E\u062A \u0648\u067C\u0627\u06A9\u0626', startDate: '\u067E\u06CC\u0644 \u0646\u06CC\u067C\u0647', startTime: '\u062F \u067E\u064A\u0644 \u0648\u062E\u062A', endDate: '\u062F \u067E\u0627\u06CC \u0646\u06CC\u067C\u0647', endTime: '\u062F \u067E\u0627\u06CC \u0648\u062E\u062A', prevYear: '\u062A\u06CC\u0631 \u06A9\u0627\u0644', nextYear: '\u0631\u0627\u062A\u0644\u0648\u0646\u06A9\u06CC \u06A9\u0627\u0644', prevMonth: '\u062A\u06CC\u0631\u0647 \u0645\u06CC\u0627\u0634\u062A', nextMonth: '\u0631\u0627\u062A\u0644\u0648\u0646\u06A9\u06D0 \u0645\u06CC\u0627\u0634\u062A', year: '\u06A9\u0627\u0644', month1: '\u062C\u0646\u0648\u0631\u064A', month2: '\u0641\u0628\u0631\u0648\u0631\u064A', month3: '\u0645\u0627\u0631\u0686', month4: '\u0627\u067E\u0631\u06CC\u0644', month5: '\u0645\u06CC', month6: '\u062C\u0648\u0646', month7: '\u062C\u0648\u0644\u0627\u06CC', month8: '\u0627\u06AB\u0633\u062A', month9: '\u0633\u067E\u062A\u0645\u0628\u0631', month10: '\u0627\u06A9\u062A\u0648\u0628\u0631', month11: '\u0646\u0648\u0645\u0628\u0631', month12: '\u062F\u0633\u0645\u0628\u0631', weeks: { sun: '\u06CC\u06A9\u0634\u0646\u0628\u0647', mon: '\u062F\u0648\u0634\u0646\u0628\u0647', tue: '\u0633\u0647\u200B \u0634\u0646\u0628\u0647', wed: '\u0686\u0647\u0627\u0631\u0634\u0646\u0628\u0647', thu: '\u067E\u0646\u062C\u200B\u0634\u0646\u0628\u0647', fri: '\u062C\u0645\u0639\u0647', sat: '\u0634\u0646\u0628\u0647', }, months: { jan: '\u062C\u0646\u0648\u0631\u064A', feb: '\u0641\u0628\u0631\u0648\u0631\u064A', mar: '\u0645\u0627\u0631\u0686', apr: '\u0627\u067E\u0631\u06CC\u0644', may: '\u0645\u06CC', jun: '\u062C\u0648\u0646', jul: '\u062C\u0648\u0644\u0627\u06CC', aug: '\u0627\u06AB\u0633\u062A', sep: '\u0633\u067E\u062A\u0645\u0628\u0631', oct: '\u0627\u06A9\u062A\u0648\u0628\u0631', nov: '\u0646\u0648\u0645\u0628\u0631', dec: '\u062F\u0633\u0645\u0628\u0631', }, }, select: { loading: '\u0628\u0627\u0631 \u06A9\u0648\u0644', noMatch: '\u0647\u06CC\u0685\u0647 \u0648\u0646\u0647 \u0645\u0648\u0646\u062F\u0644 \u0634\u0648\u0644', noData: '\u0647\u06CC\u0685 \u0645\u0639\u0644\u0648\u0645\u0627\u062A \u0646\u0634\u062A\u0647', placeholder: '\u0681\u0627\u06CC \u0644\u0631\u0648\u0646\u06A9\u06CC', }, cascader: { noMatch: '\u0647\u06CC\u0685\u0647 \u0648\u0646\u0647 \u0645\u0648\u0646\u062F\u0644 \u0634\u0648\u0644', loading: '\u0628\u0627\u0631 \u06A9\u0648\u0644', placeholder: '\u0681\u0627\u06CC \u0644\u0631\u0648\u0646\u06A9\u06CC', noData: '\u0647\u06CC\u0685 \u0645\u0639\u0644\u0648\u0645\u0627\u062A \u0646\u0634\u062A\u0647', }, pagination: { goto: '\u0648\u0631\u062A\u06AB', pagesize: '/\u062F \u067E\u0627\u06BC\u06D0 \u0627\u0646\u062F\u0627\u0632\u0647', total: '\u0645\u062C\u0645\u0648\u0639\u0647 {total}', pageClassifier: '', }, messagebox: { title: '\u0639\u0646\u0648\u0627\u0646', confirm: '\u062A\u0627\u06CC\u06CC\u062F', cancel: '\u0644\u063A\u0648\u0647 \u06A9\u0648\u0644', error: '\u062A\u064A\u0631\u0648\u062A\u0646\u0647', }, upload: { deleteTip: '\u062F \u062D\u0630\u0641 \u06A9\u0648\u0644\u0648 \u0644\u067E\u0627\u0631\u0647 \u067E\u0627\u06A9\u0647 \u062A\u06BC\u06CD \u0641\u0634\u0627\u0631 \u06A9\u0693\u0626', delete: '\u0693\u0646\u06AB\u0648\u0644', preview: '\u0645\u062E\u06A9\u062A\u0646\u0647', continue: '\u0627\u062F\u0627\u0645\u0647', }, table: { emptyText: '\u0647\u06CC\u0685 \u0645\u0639\u0644\u0648\u0645\u0627\u062A \u0648\u0646\u0647 \u0645\u0648\u0646\u062F\u0644 \u0634\u0648\u0644', confirmFilter: '\u062A\u0627\u06CC\u06CC\u062F', resetFilter: '\u067E\u0627\u06A9\u0648\u0644', clearFilter: '\u067C\u0648\u0644', sumText: '\u0645\u062C\u0645\u0648\u0639\u0647', }, tree: { emptyText: '\u0647\u06CC\u0685 \u0645\u0639\u0644\u0648\u0645\u0627\u062A \u0648\u0646\u0647 \u0645\u0648\u0646\u062F\u0644 \u0634\u0648\u0644', }, transfer: { noMatch: '\u0647\u06CC\u0685\u0647 \u0648\u0646\u0647 \u0645\u0648\u0646\u062F\u0644 \u0634\u0648\u0644', noData: '\u0647\u06CC\u0685 \u0645\u0639\u0644\u0648\u0645\u0627\u062A \u0646\u0634\u062A\u0647', titles: ['\u0644\u06CC\u0633\u067C 1', '\u0644\u06CC\u0633\u067C 2'], filterPlaceholder: '\u062F \u0645\u062A\u0646 \u06A9\u0644\u06CC\u0645\u06D0 \u062F\u0646\u0646\u0647 \u06A9\u0693\u0626', noCheckedFormat: '{total} \u062A\u0648\u06A9\u064A', hasCheckedFormat: '{checked} \u062A\u0648\u06A9\u064A \u0627\u0632 {total} \u062A\u0648\u06A9\u064A \u067C\u0627\u06A9\u0644 \u0634\u0648\u06CC \u062F\u064A', }, image: { error: '\u062F \u0627\u0646\u0681\u0648\u0631 \u067E\u0648\u0631\u062A\u0647 \u06A9\u0648\u0644\u0648 \u06A9\u06D0 \u0633\u062A\u0648\u0646\u0632\u0647', }, pageHeader: { title: '\u0628\u06CC\u0631\u062A\u0647 \u0631\u0627\u062A\u06AB', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_36 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: pa, }, Symbol.toStringTag, { value: 'Module' } ) ) var pl = { name: 'pl', el: { colorpicker: { confirm: 'OK', clear: 'Wyczy\u015B\u0107', }, datepicker: { now: 'Teraz', today: 'Dzisiaj', cancel: 'Anuluj', clear: 'Wyczy\u015B\u0107', confirm: 'OK', selectDate: 'Wybierz dat\u0119', selectTime: 'Wybierz godzin\u0119', startDate: 'Data pocz\u0105tkowa', startTime: 'Godzina pocz\u0105tkowa', endDate: 'Data ko\u0144cowa', endTime: 'Czas ko\u0144cowa', prevYear: 'Poprzedni rok', nextYear: 'Nast\u0119pny rok', prevMonth: 'Poprzedni miesi\u0105c', nextMonth: 'Nast\u0119pny miesi\u0105c', year: 'rok', month1: 'stycze\u0144', month2: 'luty', month3: 'marzec', month4: 'kwiecie\u0144', month5: 'maj', month6: 'czerwiec', month7: 'lipiec', month8: 'sierpie\u0144', month9: 'wrzesie\u0144', month10: 'pa\u017Adziernik', month11: 'listopad', month12: 'grudzie\u0144', week: 'tydzie\u0144', weeks: { sun: 'niedz.', mon: 'pon.', tue: 'wt.', wed: '\u015Br.', thu: 'czw.', fri: 'pt.', sat: 'sob.', }, months: { jan: 'STY', feb: 'LUT', mar: 'MAR', apr: 'KWI', may: 'MAJ', jun: 'CZE', jul: 'LIP', aug: 'SIE', sep: 'WRZ', oct: 'PA\u0179', nov: 'LIS', dec: 'GRU', }, }, select: { loading: '\u0141adowanie', noMatch: 'Brak dopasowa\u0144', noData: 'Brak danych', placeholder: 'Wybierz', }, cascader: { noMatch: 'Brak dopasowa\u0144', loading: '\u0141adowanie', placeholder: 'Wybierz', noData: 'Brak danych', }, pagination: { goto: 'Id\u017A do', pagesize: '/stron\u0119', total: 'Wszystkich {total}', pageClassifier: '', }, messagebox: { title: 'Wiadomo\u015B\u0107', confirm: 'OK', cancel: 'Anuluj', error: 'Wiadomo\u015B\u0107 zawiera niedozwolone znaki', }, upload: { deleteTip: 'kliknij kasuj aby usun\u0105\u0107', delete: 'Kasuj', preview: 'Podgl\u0105d', continue: 'Kontynuuj', }, table: { emptyText: 'Brak danych', confirmFilter: 'Potwierd\u017A', resetFilter: 'Resetuj', clearFilter: 'Wszystko', sumText: 'Razem', }, tree: { emptyText: 'Brak danych', }, transfer: { noMatch: 'Brak dopasowa\u0144', noData: 'Brak danych', titles: ['Lista 1', 'Lista 2'], filterPlaceholder: 'Wpisz szukan\u0105 fraz\u0119', noCheckedFormat: 'razem: {total}', hasCheckedFormat: 'wybranych: {checked}/{total}', }, image: { error: 'B\u0141\u0104D', }, pageHeader: { title: 'Wstecz', }, popconfirm: { confirmButtonText: 'Tak', cancelButtonText: 'Nie', }, }, } var __glob_8_37 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: pl, }, Symbol.toStringTag, { value: 'Module' } ) ) var ptBr = { name: 'pt-br', el: { colorpicker: { confirm: 'Confirmar', clear: 'Limpar', }, datepicker: { now: 'Agora', today: 'Hoje', cancel: 'Cancelar', clear: 'Limpar', confirm: 'Confirmar', selectDate: 'Selecione a data', selectTime: 'Selecione a hora', startDate: 'Data inicial', startTime: 'Hora inicial', endDate: 'Data final', endTime: 'Hora final', prevYear: 'Ano anterior', nextYear: 'Pr\xF3ximo ano', prevMonth: 'M\xEAs anterior', nextMonth: 'Pr\xF3ximo m\xEAs', year: '', month1: 'Janeiro', month2: 'Fevereiro', month3: 'Mar\xE7o', month4: 'Abril', month5: 'Maio', month6: 'Junho', month7: 'Julho', month8: 'Agosto', month9: 'Setembro', month10: 'Outubro', month11: 'Novembro', month12: 'Dezembro', weeks: { sun: 'Dom', mon: 'Seg', tue: 'Ter', wed: 'Qua', thu: 'Qui', fri: 'Sex', sat: 'Sab', }, months: { jan: 'Jan', feb: 'Fev', mar: 'Mar', apr: 'Abr', may: 'Mai', jun: 'Jun', jul: 'Jul', aug: 'Ago', sep: 'Set', oct: 'Out', nov: 'Nov', dec: 'Dez', }, }, select: { loading: 'Carregando', noMatch: 'Sem resultados', noData: 'Sem dados', placeholder: 'Selecione', }, cascader: { noMatch: 'Sem resultados', loading: 'Carregando', placeholder: 'Selecione', noData: 'Sem dados', }, pagination: { goto: 'Ir para', pagesize: '/p\xE1gina', total: 'Total {total}', pageClassifier: '', }, messagebox: { title: 'Mensagem', confirm: 'Confirmar', cancel: 'Cancelar', error: 'Erro!', }, upload: { deleteTip: 'aperte delete para apagar', delete: 'Apagar', preview: 'Pr\xE9-visualizar', continue: 'Continuar', }, table: { emptyText: 'Sem dados', confirmFilter: 'Confirmar', resetFilter: 'Limpar', clearFilter: 'Todos', sumText: 'Total', }, tree: { emptyText: 'Sem dados', }, transfer: { noMatch: 'Sem resultados', noData: 'Sem dados', titles: ['Lista 1', 'Lista 2'], filterPlaceholder: 'Digite uma palavra-chave', noCheckedFormat: '{total} itens', hasCheckedFormat: '{checked}/{total} selecionados', }, image: { error: 'Erro ao carregar imagem', }, pageHeader: { title: 'Voltar', }, popconfirm: { confirmButtonText: 'Sim', cancelButtonText: 'N\xE3o', }, }, } var __glob_8_38 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: ptBr, }, Symbol.toStringTag, { value: 'Module' } ) ) var pt$1 = { name: 'pt', el: { colorpicker: { confirm: 'Confirmar', clear: 'Limpar', }, datepicker: { now: 'Agora', today: 'Hoje', cancel: 'Cancelar', clear: 'Limpar', confirm: 'Confirmar', selectDate: 'Selecione a data', selectTime: 'Selecione a hora', startDate: 'Data de inicio', startTime: 'Hora de inicio', endDate: 'Data de fim', endTime: 'Hora de fim', prevYear: 'Previous Year', nextYear: 'Next Year', prevMonth: 'Previous Month', nextMonth: 'Next Month', year: '', month1: 'Janeiro', month2: 'Fevereiro', month3: 'Mar\xE7o', month4: 'Abril', month5: 'Maio', month6: 'Junho', month7: 'Julho', month8: 'Agosto', month9: 'Setembro', month10: 'Outubro', month11: 'Novembro', month12: 'Dezembro', weeks: { sun: 'Dom', mon: 'Seg', tue: 'Ter', wed: 'Qua', thu: 'Qui', fri: 'Sex', sat: 'Sab', }, months: { jan: 'Jan', feb: 'Fev', mar: 'Mar', apr: 'Abr', may: 'Mai', jun: 'Jun', jul: 'Jul', aug: 'Ago', sep: 'Set', oct: 'Out', nov: 'Nov', dec: 'Dez', }, }, select: { loading: 'A carregar', noMatch: 'Sem correspond\xEAncia', noData: 'Sem dados', placeholder: 'Selecione', }, cascader: { noMatch: 'Sem correspond\xEAncia', loading: 'A carregar', placeholder: 'Selecione', noData: 'Sem dados', }, pagination: { goto: 'Ir para', pagesize: '/pagina', total: 'Total {total}', pageClassifier: '', }, messagebox: { title: 'Mensagem', confirm: 'Confirmar', cancel: 'Cancelar', error: 'Erro!', }, upload: { deleteTip: 'press delete to remove', delete: 'Apagar', preview: 'Previsualizar', continue: 'Continuar', }, table: { emptyText: 'Sem dados', confirmFilter: 'Confirmar', resetFilter: 'Limpar', clearFilter: 'Todos', sumText: 'Sum', }, tree: { emptyText: 'Sem dados', }, transfer: { noMatch: 'Sem correspond\xEAncia', noData: 'Sem dados', titles: ['List 1', 'List 2'], filterPlaceholder: 'Enter keyword', noCheckedFormat: '{total} items', hasCheckedFormat: '{checked}/{total} checked', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_39 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: pt$1, }, Symbol.toStringTag, { value: 'Module' } ) ) var ro = { name: 'ro', el: { colorpicker: { confirm: 'OK', clear: '\u0218terge', }, datepicker: { now: 'Acum', today: 'Azi', cancel: 'Anuleaz\u0103', clear: '\u0218terge', confirm: 'OK', selectDate: 'Selecteaz\u0103 data', selectTime: 'Selecteaz\u0103 ora', startDate: 'Data de \xEEnceput', startTime: 'Ora de \xEEnceput', endDate: 'Data de sf\xE2r\u0219it', endTime: 'Ora de sf\xE2r\u0219it', prevYear: 'Anul trecut', nextYear: 'Anul urm\u0103tor', prevMonth: 'Luna trecut\u0103', nextMonth: 'Luna urm\u0103toare', year: '', month1: 'Ianuarie', month2: 'Februarie', month3: 'Martie', month4: 'Aprilie', month5: 'Mai', month6: 'Iunie', month7: 'Iulie', month8: 'August', month9: 'Septembrie', month10: 'Octombrie', month11: 'Noiembrie', month12: 'Decembrie', weeks: { sun: 'Du', mon: 'Lu', tue: 'Ma', wed: 'Mi', thu: 'Jo', fri: 'Vi', sat: 'S\xE2', }, months: { jan: 'Ian', feb: 'Feb', mar: 'Mar', apr: 'Apr', may: 'Mai', jun: 'Iun', jul: 'Iul', aug: 'Aug', sep: 'Sep', oct: 'Oct', nov: 'Noi', dec: 'Dec', }, }, select: { loading: 'Se \xEEncarc\u0103', noMatch: 'Nu exist\u0103 date potrivite', noData: 'Nu exist\u0103 date', placeholder: 'Selecteaz\u0103', }, cascader: { noMatch: 'Nu exist\u0103 date potrivite', loading: 'Se \xEEncarc\u0103', placeholder: 'Selecteaz\u0103', noData: 'Nu exist\u0103 date', }, pagination: { goto: 'Go to', pagesize: '/pagina', total: 'Total {total}', pageClassifier: '', }, messagebox: { title: 'Mesaj', confirm: 'OK', cancel: 'Anuleaz\u0103', error: 'Date introduse eronate', }, upload: { deleteTip: 'ap\u0103sa\u021Bi pe \u0219terge\u021Bi pentru a elimina', delete: '\u0219terge', preview: 'previzualizare', continue: 'continu\u0103', }, table: { emptyText: 'Nu exist\u0103 date', confirmFilter: 'Confirm\u0103', resetFilter: 'Reseteaz\u0103', clearFilter: 'Tot', sumText: 'Suma', }, tree: { emptyText: 'Nu exist\u0103 date', }, transfer: { noMatch: 'Nu exist\u0103 date potrivite', noData: 'Nu exist\u0103 date', titles: ['Lista 1', 'Lista 2'], filterPlaceholder: 'Introduce\u021Bi cuv\xE2ntul cheie', noCheckedFormat: '{total} elemente', hasCheckedFormat: '{checked}/{total} verificate', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_40 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: ro, }, Symbol.toStringTag, { value: 'Module' } ) ) var ru = { name: 'ru', el: { colorpicker: { confirm: 'OK', clear: '\u041E\u0447\u0438\u0441\u0442\u0438\u0442\u044C', }, datepicker: { now: '\u0421\u0435\u0439\u0447\u0430\u0441', today: '\u0421\u0435\u0433\u043E\u0434\u043D\u044F', cancel: '\u041E\u0442\u043C\u0435\u043D\u0430', clear: '\u041E\u0447\u0438\u0441\u0442\u0438\u0442\u044C', confirm: 'OK', selectDate: '\u0412\u044B\u0431\u0440\u0430\u0442\u044C \u0434\u0430\u0442\u0443', selectTime: '\u0412\u044B\u0431\u0440\u0430\u0442\u044C \u0432\u0440\u0435\u043C\u044F', startDate: '\u0414\u0430\u0442\u0430 \u043D\u0430\u0447\u0430\u043B\u0430', startTime: '\u0412\u0440\u0435\u043C\u044F \u043D\u0430\u0447\u0430\u043B\u0430', endDate: '\u0414\u0430\u0442\u0430 \u043E\u043A\u043E\u043D\u0447\u0430\u043D\u0438\u044F', endTime: '\u0412\u0440\u0435\u043C\u044F \u043E\u043A\u043E\u043D\u0447\u0430\u043D\u0438\u044F', prevYear: '\u041F\u0440\u0435\u0434\u044B\u0434\u0443\u0449\u0438\u0439 \u0433\u043E\u0434', nextYear: '\u0421\u043B\u0435\u0434\u0443\u044E\u0449\u0438\u0439 \u0433\u043E\u0434', prevMonth: '\u041F\u0440\u0435\u0434\u044B\u0434\u0443\u0449\u0438\u0439 \u043C\u0435\u0441\u044F\u0446', nextMonth: '\u0421\u043B\u0435\u0434\u0443\u044E\u0449\u0438\u0439 \u043C\u0435\u0441\u044F\u0446', year: '', month1: '\u042F\u043D\u0432\u0430\u0440\u044C', month2: '\u0424\u0435\u0432\u0440\u0430\u043B\u044C', month3: '\u041C\u0430\u0440\u0442', month4: '\u0410\u043F\u0440\u0435\u043B\u044C', month5: '\u041C\u0430\u0439', month6: '\u0418\u044E\u043D\u044C', month7: '\u0418\u044E\u043B\u044C', month8: '\u0410\u0432\u0433\u0443\u0441\u0442', month9: '\u0421\u0435\u043D\u0442\u044F\u0431\u0440\u044C', month10: '\u041E\u043A\u0442\u044F\u0431\u0440\u044C', month11: '\u041D\u043E\u044F\u0431\u0440\u044C', month12: '\u0414\u0435\u043A\u0430\u0431\u0440\u044C', week: '\u043D\u0435\u0434\u0435\u043B\u044F', weeks: { sun: '\u0412\u0441', mon: '\u041F\u043D', tue: '\u0412\u0442', wed: '\u0421\u0440', thu: '\u0427\u0442', fri: '\u041F\u0442', sat: '\u0421\u0431', }, months: { jan: '\u042F\u043D\u0432', feb: '\u0424\u0435\u0432', mar: '\u041C\u0430\u0440', apr: '\u0410\u043F\u0440', may: '\u041C\u0430\u0439', jun: '\u0418\u044E\u043D', jul: '\u0418\u044E\u043B', aug: '\u0410\u0432\u0433', sep: '\u0421\u0435\u043D', oct: '\u041E\u043A\u0442', nov: '\u041D\u043E\u044F', dec: '\u0414\u0435\u043A', }, }, select: { loading: '\u0417\u0430\u0433\u0440\u0443\u0437\u043A\u0430', noMatch: '\u0421\u043E\u0432\u043F\u0430\u0434\u0435\u043D\u0438\u0439 \u043D\u0435 \u043D\u0430\u0439\u0434\u0435\u043D\u043E', noData: '\u041D\u0435\u0442 \u0434\u0430\u043D\u043D\u044B\u0445', placeholder: '\u0412\u044B\u0431\u0440\u0430\u0442\u044C', }, cascader: { noMatch: '\u0421\u043E\u0432\u043F\u0430\u0434\u0435\u043D\u0438\u0439 \u043D\u0435 \u043D\u0430\u0439\u0434\u0435\u043D\u043E', loading: '\u0417\u0430\u0433\u0440\u0443\u0437\u043A\u0430', placeholder: '\u0412\u044B\u0431\u0440\u0430\u0442\u044C', noData: '\u041D\u0435\u0442 \u0434\u0430\u043D\u043D\u044B\u0445', }, pagination: { goto: '\u041F\u0435\u0440\u0435\u0439\u0442\u0438', pagesize: ' \u043D\u0430 \u0441\u0442\u0440\u0430\u043D\u0438\u0446\u0435', total: '\u0412\u0441\u0435\u0433\u043E {total}', pageClassifier: '', }, messagebox: { title: '\u0421\u043E\u043E\u0431\u0449\u0435\u043D\u0438\u0435', confirm: 'OK', cancel: '\u041E\u0442\u043C\u0435\u043D\u0430', error: '\u041D\u0435\u0434\u043E\u043F\u0443\u0441\u0442\u0438\u043C\u044B\u0439 \u0432\u0432\u043E\u0434 \u0434\u0430\u043D\u043D\u044B\u0445', }, upload: { deleteTip: '\u041D\u0430\u0436\u043C\u0438\u0442\u0435 [\u0423\u0434\u0430\u043B\u0438\u0442\u044C] \u0434\u043B\u044F \u0443\u0434\u0430\u043B\u0435\u043D\u0438\u044F', delete: '\u0423\u0434\u0430\u043B\u0438\u0442\u044C', preview: '\u041F\u0440\u0435\u0432\u044C\u044E', continue: '\u041F\u0440\u043E\u0434\u043E\u043B\u0436\u0438\u0442\u044C', }, table: { emptyText: '\u041D\u0435\u0442 \u0434\u0430\u043D\u043D\u044B\u0445', confirmFilter: '\u041F\u043E\u0434\u0442\u0432\u0435\u0440\u0434\u0438\u0442\u044C', resetFilter: '\u0421\u0431\u0440\u043E\u0441\u0438\u0442\u044C', clearFilter: '\u0412\u0441\u0435', sumText: '\u0421\u0443\u043C\u043C\u0430', }, tree: { emptyText: '\u041D\u0435\u0442 \u0434\u0430\u043D\u043D\u044B\u0445', }, transfer: { noMatch: '\u0421\u043E\u0432\u043F\u0430\u0434\u0435\u043D\u0438\u0439 \u043D\u0435 \u043D\u0430\u0439\u0434\u0435\u043D\u043E', noData: '\u041D\u0435\u0442 \u0434\u0430\u043D\u043D\u044B\u0445', titles: [ '\u0421\u043F\u0438\u0441\u043E\u043A 1', '\u0421\u043F\u0438\u0441\u043E\u043A 2', ], filterPlaceholder: '\u0412\u0432\u0435\u0434\u0438\u0442\u0435 \u043A\u043B\u044E\u0447\u0435\u0432\u043E\u0435 \u0441\u043B\u043E\u0432\u043E', noCheckedFormat: '{total} \u043F\u0443\u043D\u043A\u0442\u043E\u0432', hasCheckedFormat: '{checked}/{total} \u0432\u044B\u0431\u0440\u0430\u043D\u043E', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'OK', cancelButtonText: '\u041E\u0442\u043C\u0435\u043D\u0430', }, }, } var __glob_8_41 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: ru, }, Symbol.toStringTag, { value: 'Module' } ) ) var sk = { name: 'sk', el: { colorpicker: { confirm: 'OK', clear: 'Zmaza\u0165', }, datepicker: { now: 'Teraz', today: 'Dnes', cancel: 'Zru\u0161i\u0165', clear: 'Zmaza\u0165', confirm: 'OK', selectDate: 'Vybra\u0165 d\xE1tum', selectTime: 'Vybra\u0165 \u010Das', startDate: 'D\xE1tum za\u010Diatku', startTime: '\u010Cas za\u010Diatku', endDate: 'D\xE1tum konca', endTime: '\u010Cas konca', prevYear: 'Predo\u0161l\xFD rok', nextYear: '\u010Eal\u0161\xED rok', prevMonth: 'Predo\u0161l\xFD mesiac', nextMonth: '\u010Eal\u0161\xED mesiac', day: 'De\u0148', week: 'T\xFD\u017Ede\u0148', month: 'Mesiac', year: 'Rok', month1: 'Janu\xE1r', month2: 'Febru\xE1r', month3: 'Marec', month4: 'Apr\xEDl', month5: 'M\xE1j', month6: 'J\xFAn', month7: 'J\xFAl', month8: 'August', month9: 'September', month10: 'Okt\xF3ber', month11: 'November', month12: 'December', weeks: { sun: 'Ne', mon: 'Po', tue: 'Ut', wed: 'St', thu: '\u0160t', fri: 'Pi', sat: 'So', }, months: { jan: 'Jan', feb: 'Feb', mar: 'Mar', apr: 'Apr', may: 'M\xE1j', jun: 'J\xFAn', jul: 'J\xFAl', aug: 'Aug', sep: 'Sep', oct: 'Okt', nov: 'Nov', dec: 'Dec', }, }, select: { loading: 'Na\u010D\xEDtavanie', noMatch: '\u017Diadna zhoda', noData: '\u017Diadne d\xE1ta', placeholder: 'Vybra\u0165', }, cascader: { noMatch: '\u017Diadna zhoda', loading: 'Na\u010D\xEDtavanie', placeholder: 'Vybra\u0165', noData: '\u017Diadne d\xE1ta', }, pagination: { goto: 'Cho\u010F na', pagesize: 'na stranu', total: 'V\u0161etko {total}', pageClassifier: '', }, messagebox: { title: 'Spr\xE1va', confirm: 'OK', cancel: 'Zru\u0161i\u0165', error: 'Neplatn\xFD vstup', }, upload: { deleteTip: 'pre odstr\xE1nenie stisni kl\xE1vesu Delete', delete: 'Vymaza\u0165', preview: 'Prehliada\u0165', continue: 'Pokra\u010Dova\u0165', }, table: { emptyText: '\u017Diadne d\xE1ta', confirmFilter: 'Potvrdi\u0165', resetFilter: 'Zresetova\u0165', clearFilter: 'V\u0161etko', sumText: 'Spolu', }, tree: { emptyText: '\u017Diadne d\xE1ta', }, transfer: { noMatch: '\u017Diadna zhoda', noData: '\u017Diadne d\xE1ta', titles: ['Zoznam 1', 'Zoznam 2'], filterPlaceholder: 'Filtrova\u0165 pod\u013Ea', noCheckedFormat: '{total} polo\u017Eiek', hasCheckedFormat: '{checked}/{total} ozna\u010Den\xFDch', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_42 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: sk, }, Symbol.toStringTag, { value: 'Module' } ) ) var sl = { name: 'sl', el: { colorpicker: { confirm: 'V redu', clear: 'Po\u010Disti', }, datepicker: { now: 'Zdaj', today: 'Danes', cancel: 'Prekli\u010Di', clear: 'Po\u010Disti', confirm: 'Potrdi', selectDate: 'Izberi datum', selectTime: 'Izberi \u010Das', startDate: 'Za\u010Detni datum', startTime: 'Za\u010Detni \u010Das', endDate: 'Kon\u010Dni datum', endTime: 'Kon\u010Dni \u010Das', prevYear: 'Prej\u0161nje leto', nextYear: 'Naslednje leto', prevMonth: 'Prej\u0161nji mesec', nextMonth: 'Naslednji mesec', year: '', month1: 'Jan', month2: 'Feb', month3: 'Mar', month4: 'Apr', month5: 'Maj', month6: 'Jun', month7: 'Jul', month8: 'Avg', month9: 'Sep', month10: 'Okt', month11: 'Nov', month12: 'Dec', week: 'teden', weeks: { sun: 'Ned', mon: 'Pon', tue: 'Tor', wed: 'Sre', thu: '\u010Cet', fri: 'Pet', sat: 'Sob', }, months: { jan: 'Jan', feb: 'Feb', mar: 'Mar', apr: 'Apr', may: 'Maj', jun: 'Jun', jul: 'Jul', aug: 'Avg', sep: 'Sep', oct: 'Okt', nov: 'Nov', dec: 'Dec', }, }, select: { loading: 'Nalaganje', noMatch: 'Ni ustreznih podatkov', noData: 'Ni podatkov', placeholder: 'Izberi', }, cascader: { noMatch: 'Ni ustreznih podatkov', loading: 'Nalaganje', placeholder: 'Izberi', noData: 'Ni podatkov', }, pagination: { goto: 'Pojdi na', pagesize: '/stran', total: 'Skupno {total}', pageClassifier: '', }, messagebox: { title: 'Sporo\u010Dilo', confirm: 'V redu', cancel: 'Prekli\u010Di', error: 'Nedovoljen vnos', }, upload: { deleteTip: 'press delete to remove', delete: 'Izbri\u0161i', preview: 'Predogled', continue: 'Nadaljuj', }, table: { emptyText: 'Ni podatkov', confirmFilter: 'Potrdi', resetFilter: 'Ponastavi', clearFilter: 'Vse', sumText: 'Skupno', }, tree: { emptyText: 'Ni podatkov', }, transfer: { noMatch: 'Ni ustreznih podatkov', noData: 'Ni podatkov', titles: ['Seznam 1', 'Seznam 2'], filterPlaceholder: 'Vnesi klju\u010Dno besedo', noCheckedFormat: '{total} elementov', hasCheckedFormat: '{checked}/{total} izbranih', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_43 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: sl, }, Symbol.toStringTag, { value: 'Module' } ) ) var sr = { name: 'sr', el: { colorpicker: { confirm: 'OK', clear: '\u041F\u043E\u043D\u0438\u0448\u0442\u0438', }, datepicker: { now: '\u0421\u0430\u0434', today: '\u0414\u0430\u043D\u0430\u0441', cancel: '\u041E\u0442\u043A\u0430\u0436\u0438', clear: '\u0411\u0440\u0438\u0448\u0438', confirm: 'OK', selectDate: '\u0418\u0437\u0430\u0431\u0435\u0440\u0438 \u0434\u0430\u0442\u0443\u043C', selectTime: '\u0418\u0437\u0430\u0431\u0435\u0440\u0438 \u0432\u0440\u0435\u043C\u0435', startDate: '\u0414\u0430\u0442\u0443\u043C \u043F\u043E\u0447\u0435\u0442\u043A\u0430', startTime: '\u0412\u0440\u0435\u043C\u0435 \u043F\u043E\u0447\u0435\u0442\u043A\u0430', endDate: '\u0414\u0430\u0442\u0443\u043C \u0437\u0430\u0432\u0440\u0448\u0435\u0442\u043A\u0430', endTime: '\u0412\u0440\u0435\u043C\u0435 \u0437\u0430\u0432\u0440\u0448\u0435\u0442\u043A\u0430', prevYear: '\u041F\u0440\u0435\u0442\u0445\u043E\u0434\u043D\u0430 \u0433\u043E\u0434\u0438\u043D\u0430', nextYear: '\u0421\u043B\u0435\u0434\u0435\u045B\u0430 \u0433\u043E\u0434\u0438\u043D\u0430', prevMonth: '\u041F\u0440\u0435\u0442\u0445\u043E\u0434\u043D\u0438 \u043C\u0435\u0441\u0435\u0446', nextMonth: '\u0421\u043B\u0435\u0434\u0435\u045B\u0438 \u043C\u0435\u0441\u0435\u0446', year: '\u0433\u043E\u0434\u0438\u043D\u0430', month1: '\u0458\u0430\u043D\u0443\u0430\u0440', month2: '\u0444\u0435\u0431\u0440\u0443\u0430\u0440', month3: '\u043C\u0430\u0440\u0442', month4: '\u0430\u043F\u0440\u0438\u043B', month5: '\u043C\u0430\u0458', month6: '\u0458\u0443\u043D', month7: '\u0458\u0443\u043B', month8: '\u0430\u0432\u0433\u0443\u0441\u0442', month9: '\u0441\u0435\u043F\u0442\u0435\u043C\u0431\u0430\u0440', month10: '\u043E\u043A\u0442\u043E\u0431\u0430\u0440', month11: '\u043D\u043E\u0432\u0435\u043C\u0431\u0430\u0440', month12: '\u0434\u0435\u0446\u0435\u043C\u0431\u0430\u0440', week: '\u0441\u0435\u0434\u043C\u0438\u0446\u0430', weeks: { sun: '\u041D\u0435\u0434', mon: '\u041F\u043E\u043D', tue: '\u0423\u0442\u043E', wed: '\u0421\u0440\u0435', thu: '\u0427\u0435\u0442', fri: '\u041F\u0435\u0442', sat: '\u0421\u0443\u0431', }, months: { jan: '\u0458\u0430\u043D', feb: '\u0444\u0435\u0431', mar: '\u043C\u0430\u0440', apr: '\u0430\u043F\u0440', may: '\u043C\u0430\u0458', jun: '\u0458\u0443\u043D', jul: '\u0458\u0443\u043B', aug: '\u0430\u0432\u0433', sep: '\u0441\u0435\u043F', oct: '\u043E\u043A\u0442', nov: '\u043D\u043E\u0432', dec: '\u0434\u0435\u0446', }, }, select: { loading: '\u0423\u0447\u0438\u0442\u0430\u0432\u0430\u045A\u0435', noMatch: '\u041D\u0435\u043C\u0430 \u0440\u0435\u0437\u0443\u043B\u0442\u0430\u0442\u0430', noData: '\u041D\u0435\u043C\u0430 \u043F\u043E\u0434\u0430\u0442\u0430\u043A\u0430', placeholder: '\u0418\u0437\u0430\u0431\u0435\u0440\u0438', }, cascader: { noMatch: '\u041D\u0435\u043C\u0430 \u0440\u0435\u0437\u0443\u043B\u0442\u0430\u0442\u0430', loading: '\u0423\u0447\u0438\u0442\u0430\u0432\u0430\u045A\u0435', placeholder: '\u0418\u0437\u0430\u0431\u0435\u0440\u0438', noData: '\u041D\u0435\u043C\u0430 \u043F\u043E\u0434\u0430\u0442\u0430\u043A\u0430', }, pagination: { goto: '\u0418\u0434\u0438 \u043D\u0430', pagesize: '/\u0441\u0442\u0440\u0430\u043D\u0438', total: '\u0423\u043A\u0443\u043F\u043D\u043E {total}', pageClassifier: '', }, messagebox: { title: '\u041F\u043E\u0440\u0443\u043A\u0430', confirm: 'OK', cancel: '\u041E\u0442\u043A\u0430\u0436\u0438', error: '\u041D\u0435\u0438\u0441\u043F\u0440\u0430\u0432\u0430\u043D \u0443\u043D\u043E\u0441', }, upload: { deleteTip: '\u043F\u0440\u0438\u0442\u0438\u0441\u043D\u0438 \u0411\u0420\u0418\u0428\u0418 \u0434\u0430 \u043E\u0431\u0440\u0438\u0448\u0435\u0448', delete: '\u0411\u0440\u0438\u0448\u0438', preview: '\u0412\u0438\u0434\u0438', continue: '\u041D\u0430\u0441\u0442\u0430\u0432\u0438', }, table: { emptyText: '\u041D\u0435\u043C\u0430 \u043F\u043E\u0434\u0430\u0442\u0430\u043A\u0430', confirmFilter: '\u041F\u043E\u0442\u0432\u0440\u0434\u0438', resetFilter: '\u0420\u0435\u0441\u0435\u0442\u0443\u0458', clearFilter: '\u0421\u0432\u0435', sumText: '\u0417\u0431\u0438\u0440', }, tree: { emptyText: '\u041D\u0435\u043C\u0430 \u043F\u043E\u0434\u0430\u0442\u0430\u043A\u0430', }, transfer: { noMatch: '\u041D\u0435\u043C\u0430 \u0440\u0435\u0437\u0443\u043B\u0442\u0430\u0442\u0430', noData: '\u041D\u0435\u043C\u0430 \u043F\u043E\u0434\u0430\u0442\u0430\u043A\u0430', titles: [ '\u041B\u0438\u0441\u0442\u0430 1', '\u041B\u0438\u0441\u0442\u0430 2', ], filterPlaceholder: '\u0423\u043D\u0435\u0441\u0438 \u043A\u0459\u0443\u0447\u043D\u0443 \u0440\u0435\u0447', noCheckedFormat: '{total} \u0441\u0442\u0430\u0432\u043A\u0438', hasCheckedFormat: '{checked}/{total} \u043E\u0431\u0435\u043B\u0435\u0436\u0435\u043D\u0438\u0445', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_44 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: sr, }, Symbol.toStringTag, { value: 'Module' } ) ) var sv = { name: 'sv', el: { colorpicker: { confirm: 'OK', clear: 'T\xF6m', }, datepicker: { now: 'Nu', today: 'Idag', cancel: 'Avbryt', clear: 'T\xF6m', confirm: 'OK', selectDate: 'V\xE4lj datum', selectTime: 'V\xE4lj tid', startDate: 'Startdatum', startTime: 'Starttid', endDate: 'Slutdatum', endTime: 'Sluttid', prevYear: 'F\xF6reg\xE5ende \xE5r', nextYear: 'N\xE4sta \xE5r', prevMonth: 'F\xF6reg\xE5ende m\xE5nad', nextMonth: 'N\xE4sta m\xE5nad', year: '', month1: 'Januari', month2: 'Februari', month3: 'Mars', month4: 'April', month5: 'Maj', month6: 'Juni', month7: 'Juli', month8: 'Augusti', month9: 'September', month10: 'Oktober', month11: 'November', month12: 'December', weeks: { sun: 'S\xF6n', mon: 'M\xE5n', tue: 'Tis', wed: 'Ons', thu: 'Tor', fri: 'Fre', sat: 'L\xF6r', }, months: { jan: 'Jan', feb: 'Feb', mar: 'Mar', apr: 'Apr', may: 'Maj', jun: 'Jun', jul: 'Jul', aug: 'Aug', sep: 'Sep', oct: 'Okt', nov: 'Nov', dec: 'Dec', }, }, select: { loading: 'Laddar', noMatch: 'Hittade inget', noData: 'Ingen data', placeholder: 'V\xE4lj', }, cascader: { noMatch: 'Hittade inget', loading: 'Laddar', placeholder: 'V\xE4lj', noData: 'Ingen data', }, pagination: { goto: 'G\xE5 till', pagesize: '/sida', total: 'Totalt {total}', pageClassifier: '', }, messagebox: { title: 'Meddelande', confirm: 'OK', cancel: 'Avbryt', error: 'Felaktig inmatning', }, upload: { deleteTip: 'press delete to remove', delete: 'Radera', preview: 'F\xF6rhandsvisa', continue: 'Forts\xE4tt', }, table: { emptyText: 'Inga Data', confirmFilter: 'Bekr\xE4fta', resetFilter: '\xC5terst\xE4ll', clearFilter: 'Alla', sumText: 'Summa', }, tree: { emptyText: 'Ingen data', }, transfer: { noMatch: 'Hittade inget', noData: 'Ingen data', titles: ['List 1', 'List 2'], filterPlaceholder: 'Enter keyword', noCheckedFormat: '{total} items', hasCheckedFormat: '{checked}/{total} checked', }, image: { error: 'FAILED', }, pageHeader: { title: 'Bak\xE5t', }, popconfirm: { confirmButtonText: 'Ja', cancelButtonText: 'Nej', }, }, } var __glob_8_45 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: sv, }, Symbol.toStringTag, { value: 'Module' } ) ) var ta = { name: 'ta', el: { colorpicker: { confirm: '\u0B89\u0BB1\u0BC1\u0BA4\u0BBF \u0B9A\u0BC6\u0BAF\u0BCD', clear: '\u0BA4\u0BC6\u0BB3\u0BBF\u0BB5\u0BBE\u0B95\u0BCD\u0B95\u0BC1', }, datepicker: { now: '\u0BA4\u0BB1\u0BCD\u0BAA\u0BCB\u0BA4\u0BC1', today: '\u0B87\u0BA9\u0BCD\u0BB1\u0BC1', cancel: '\u0BB0\u0BA4\u0BCD\u0BA4\u0BC1 \u0B9A\u0BC6\u0BAF\u0BCD', clear: '\u0B9A\u0BB0\u0BBF', confirm: '\u0B89\u0BB1\u0BC1\u0BA4\u0BBF \u0B9A\u0BC6\u0BAF\u0BCD', selectDate: '\u0BA4\u0BC7\u0BA4\u0BBF\u0BAF\u0BC8 \u0BA4\u0BC7\u0BB0\u0BCD\u0BB5\u0BC1 \u0B9A\u0BC6\u0BAF\u0BCD', selectTime: '\u0BA8\u0BC7\u0BB0\u0BA4\u0BCD\u0BA4\u0BC8 \u0BA4\u0BC7\u0BB0\u0BCD\u0BB5\u0BC1 \u0B9A\u0BC6\u0BAF\u0BCD', startDate: '\u0BA4\u0BCA\u0B9F\u0B99\u0BCD\u0B95\u0BC1\u0BAE\u0BCD \u0BA8\u0BBE\u0BB3\u0BCD', startTime: '\u0BA4\u0BCA\u0B9F\u0B99\u0BCD\u0B95\u0BC1\u0BAE\u0BCD \u0BA8\u0BC7\u0BB0\u0BAE\u0BCD', endDate: '\u0BAE\u0BC1\u0B9F\u0BBF\u0BAF\u0BC1\u0BAE\u0BCD \u0BA4\u0BC7\u0BA4\u0BBF', endTime: '\u0BAE\u0BC1\u0B9F\u0BBF\u0BAF\u0BC1\u0BAE\u0BCD \u0BA8\u0BC7\u0BB0\u0BAE\u0BCD', prevYear: 'Previous Year', nextYear: 'Next Year', prevMonth: 'Previous Month', nextMonth: 'Next Month', year: '\u0BB5\u0BB0\u0BC1\u0B9F\u0BAE\u0BCD', month1: '\u0B9C\u0BA9\u0BB5\u0BB0\u0BBF', month2: '\u0BAA\u0BBF\u0BAA\u0BCD\u0BB0\u0BB5\u0BB0\u0BBF', month3: '\u0BAE\u0BBE\u0BB0\u0BCD\u0B9A\u0BCD', month4: '\u0B8F\u0BAA\u0BCD\u0BB0\u0BB2\u0BCD', month5: '\u0BAE\u0BC7', month6: '\u0B9C\u0BC2\u0BA9\u0BCD', month7: '\u0B9C\u0BC2\u0BB2\u0BC8', month8: '\u0B86\u0B95\u0BB8\u0BCD\u0B9F\u0BCD', month9: '\u0B9A\u0BC6\u0BAA\u0BCD\u0B9F\u0BAE\u0BCD\u0BAA\u0BB0\u0BCD', month10: '\u0B85\u0B95\u0BCD\u0B9F\u0BCB\u0BAA\u0BB0\u0BCD', month11: '\u0BA8\u0BB5\u0BAE\u0BCD\u0BAA\u0BB0\u0BCD', month12: '\u0B9F\u0BBF\u0B9A\u0BAE\u0BCD\u0BAA\u0BB0\u0BCD', weeks: { sun: '\u0B9E\u0BBE\u0BAF\u0BBF\u0BB1\u0BC1', mon: '\u0BA4\u0BBF\u0B99\u0BCD\u0B95\u0BB3\u0BCD', tue: '\u0B9A\u0BC6\u0BB5\u0BCD\u0BB5\u0BBE\u0BAF\u0BCD', wed: '\u0BAA\u0BC1\u0BA4\u0BA9\u0BCD', thu: '\u0BB5\u0BBF\u0BAF\u0BBE\u0BB4\u0BA9\u0BCD', fri: '\u0BB5\u0BC6\u0BB3\u0BCD\u0BB3\u0BBF', sat: '\u0B9A\u0BA9\u0BBF', }, months: { jan: '\u0B9C\u0BA9\u0BB5\u0BB0\u0BBF', feb: '\u0BAA\u0BBF\u0BAA\u0BCD\u0BB0\u0BB5\u0BB0\u0BBF', mar: '\u0BAE\u0BBE\u0BB0\u0BCD\u0B9A\u0BCD', apr: '\u0B8F\u0BAA\u0BCD\u0BB0\u0BB2\u0BCD', may: '\u0BAE\u0BC7', jun: '\u0B9C\u0BC2\u0BA9\u0BCD', jul: '\u0B9C\u0BC2\u0BB2\u0BC8', aug: '\u0B86\u0B95\u0BB8\u0BCD\u0B9F\u0BCD', sep: '\u0B9A\u0BC6\u0BAA\u0BCD\u0B9F\u0BAE\u0BCD\u0BAA\u0BB0\u0BCD', oct: '\u0B85\u0B95\u0BCD\u0B9F\u0BCB\u0BAA\u0BB0\u0BCD', nov: '\u0BA8\u0BB5\u0BAE\u0BCD\u0BAA\u0BB0\u0BCD', dec: '\u0B9F\u0BBF\u0B9A\u0BAE\u0BCD\u0BAA\u0BB0\u0BCD', }, }, select: { loading: '\u0BA4\u0BAF\u0BBE\u0BB0\u0BBE\u0B95\u0BBF\u0B95\u0BCD\u0B95\u0BCA\u0BA3\u0BCD\u0B9F\u0BBF\u0BB0\u0BC1\u0B95\u0BCD\u0B95\u0BBF\u0BB1\u0BA4\u0BC1', noMatch: '\u0BAA\u0BCA\u0BB0\u0BC1\u0BA4\u0BCD\u0BA4\u0BAE\u0BBE\u0BA9 \u0BA4\u0BB0\u0BB5\u0BC1 \u0B95\u0BBF\u0B9F\u0BC8\u0B95\u0BCD\u0B95\u0BB5\u0BBF\u0BB2\u0BCD\u0BB2\u0BC8', noData: '\u0BA4\u0BB0\u0BB5\u0BC1 \u0B87\u0BB2\u0BCD\u0BB2\u0BC8', placeholder: '\u0BA4\u0BC7\u0BB0\u0BCD\u0BB5\u0BC1 \u0B9A\u0BC6\u0BAF\u0BCD', }, cascader: { noMatch: '\u0BAA\u0BCA\u0BB0\u0BC1\u0BA4\u0BCD\u0BA4\u0BAE\u0BBE\u0BA9 \u0BA4\u0BB0\u0BB5\u0BC1 \u0B95\u0BBF\u0B9F\u0BC8\u0B95\u0BCD\u0B95\u0BB5\u0BBF\u0BB2\u0BCD\u0BB2\u0BC8', loading: '\u0BA4\u0BAF\u0BBE\u0BB0\u0BBE\u0B95\u0BBF\u0B95\u0BCD\u0B95\u0BCA\u0BA3\u0BCD\u0B9F\u0BBF\u0BB0\u0BC1\u0B95\u0BCD\u0B95\u0BBF\u0BB1\u0BA4\u0BC1', placeholder: '\u0BA4\u0BC7\u0BB0\u0BCD\u0BB5\u0BC1 \u0B9A\u0BC6\u0BAF\u0BCD', noData: '\u0BA4\u0BB0\u0BB5\u0BC1 \u0B87\u0BB2\u0BCD\u0BB2\u0BC8', }, pagination: { goto: '\u0BA4\u0BC7\u0BB5\u0BC8\u0BAF\u0BBE\u0BA9\u0BCD \u0BAA\u0B95\u0BC1\u0BA4\u0BBF\u0B95\u0BCD\u0B95\u0BC1 \u0B9A\u0BC6\u0BB2\u0BCD', pagesize: '/page', total: '\u0BAE\u0BCA\u0BA4\u0BCD\u0BA4\u0BAE\u0BCD {total}', pageClassifier: '', }, messagebox: { title: '\u0B9A\u0BC6\u0BAF\u0BCD\u0BA4\u0BBF', confirm: '\u0B89\u0BB1\u0BC1\u0BA4\u0BBF \u0B9A\u0BC6\u0BAF\u0BCD', cancel: '\u0BB0\u0BA4\u0BCD\u0BA4\u0BC1 \u0B9A\u0BC6\u0BAF\u0BCD', error: '\u0BAA\u0BCA\u0BB0\u0BC1\u0BA4\u0BCD\u0BA4\u0BBE\u0BAE\u0BBF\u0BB2\u0BCD\u0BB2\u0BBE\u0BA4 \u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1', }, upload: { deleteTip: 'press delete to remove', delete: '\u0BA8\u0BC0\u0B95\u0BCD\u0B95\u0BC1', preview: '\u0BAE\u0BC1\u0BA9\u0BCD\u0BA9\u0BCB\u0B9F\u0BCD\u0B9F\u0BAE\u0BCD \u0BAA\u0BBE\u0BB0\u0BCD', continue: '\u0BA4\u0BCA\u0B9F\u0BB0\u0BC1', }, table: { emptyText: '\u0BA4\u0BB0\u0BB5\u0BC1 \u0B87\u0BB2\u0BCD\u0BB2\u0BC8', confirmFilter: '\u0B89\u0BB1\u0BC1\u0BA4\u0BBF \u0B9A\u0BC6\u0BAF\u0BCD', resetFilter: '\u0BAA\u0BC1\u0BA4\u0BC1\u0BAE\u0BBE\u0BB1\u0BCD\u0BB1\u0BAE\u0BCD \u0B9A\u0BC6\u0BAF\u0BCD', clearFilter: '\u0B85\u0BA9\u0BC8\u0BA4\u0BCD\u0BA4\u0BC1\u0BAE\u0BCD', sumText: '\u0B95\u0BC2\u0B9F\u0BCD\u0B9F\u0BC1', }, tree: { emptyText: '\u0BA4\u0BB0\u0BB5\u0BC1 \u0B87\u0BB2\u0BCD\u0BB2\u0BC8', }, transfer: { noMatch: '\u0BAA\u0BCA\u0BB0\u0BC1\u0BA4\u0BCD\u0BA4\u0BAE\u0BBE\u0BA9 \u0BA4\u0BB0\u0BB5\u0BC1 \u0B95\u0BBF\u0B9F\u0BC8\u0B95\u0BCD\u0B95\u0BB5\u0BBF\u0BB2\u0BCD\u0BB2\u0BC8', noData: '\u0BA4\u0BB0\u0BB5\u0BC1 \u0B87\u0BB2\u0BCD\u0BB2\u0BC8', titles: [ '\u0BAA\u0B9F\u0BCD\u0B9F\u0BBF\u0BAF\u0BB2\u0BCD 1', '\u0BAA\u0B9F\u0BCD\u0B9F\u0BBF\u0BAF\u0BB2\u0BCD 2', ], filterPlaceholder: '\u0B9A\u0BCA\u0BB2\u0BCD\u0BB2\u0BC8 \u0B89\u0BB3\u0BCD\u0BB3\u0BC0\u0B9F\u0BC1 \u0B9A\u0BC6\u0BAF\u0BCD', noCheckedFormat: '{total} items', hasCheckedFormat: '{checked}/{total} \u0BA4\u0BC7\u0BB0\u0BCD\u0BB5\u0BC1 \u0B9A\u0BC6\u0BAF\u0BCD\u0BAF\u0BAA\u0BCD\u0BAA\u0B9F\u0BCD\u0B9F\u0BB5\u0BC8\u0B95\u0BB3\u0BCD', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_46 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: ta, }, Symbol.toStringTag, { value: 'Module' } ) ) var th$2 = { name: 'th', el: { colorpicker: { confirm: '\u0E15\u0E01\u0E25\u0E07', clear: '\u0E25\u0E49\u0E32\u0E07\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25', }, datepicker: { now: '\u0E15\u0E2D\u0E19\u0E19\u0E35\u0E49', today: '\u0E27\u0E31\u0E19\u0E19\u0E35\u0E49', cancel: '\u0E22\u0E01\u0E40\u0E25\u0E34\u0E01', clear: '\u0E25\u0E49\u0E32\u0E07\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25', confirm: '\u0E15\u0E01\u0E25\u0E07', selectDate: '\u0E40\u0E25\u0E37\u0E2D\u0E01\u0E27\u0E31\u0E19\u0E17\u0E35\u0E48', selectTime: '\u0E40\u0E25\u0E37\u0E2D\u0E01\u0E40\u0E27\u0E25\u0E32', startDate: '\u0E27\u0E31\u0E19\u0E17\u0E35\u0E48\u0E40\u0E23\u0E34\u0E48\u0E21\u0E15\u0E49\u0E19', startTime: '\u0E40\u0E27\u0E25\u0E32\u0E40\u0E23\u0E34\u0E48\u0E21\u0E15\u0E49\u0E19', endDate: '\u0E27\u0E31\u0E19\u0E17\u0E35\u0E48\u0E2A\u0E34\u0E49\u0E19\u0E2A\u0E38\u0E14', endTime: '\u0E40\u0E27\u0E25\u0E32\u0E2A\u0E34\u0E49\u0E19\u0E2A\u0E38\u0E14', prevYear: '\u0E1B\u0E35\u0E01\u0E48\u0E2D\u0E19\u0E2B\u0E19\u0E49\u0E32', nextYear: '\u0E1B\u0E35\u0E16\u0E31\u0E14\u0E44\u0E1B', prevMonth: '\u0E40\u0E14\u0E37\u0E2D\u0E19\u0E01\u0E48\u0E2D\u0E19\u0E2B\u0E19\u0E49\u0E32', nextMonth: '\u0E40\u0E14\u0E37\u0E2D\u0E19\u0E16\u0E31\u0E14\u0E44\u0E1B', year: '\u0E1B\u0E35', month1: '\u0E21\u0E01\u0E23\u0E32\u0E04\u0E21', month2: '\u0E01\u0E38\u0E21\u0E20\u0E32\u0E1E\u0E31\u0E19\u0E18\u0E4C', month3: '\u0E21\u0E35\u0E19\u0E32\u0E04\u0E21', month4: '\u0E40\u0E21\u0E29\u0E32\u0E22\u0E19', month5: '\u0E1E\u0E24\u0E29\u0E20\u0E32\u0E04\u0E21', month6: '\u0E21\u0E34\u0E16\u0E38\u0E19\u0E32\u0E22\u0E19', month7: '\u0E01\u0E23\u0E01\u0E0E\u0E32\u0E04\u0E21', month8: '\u0E2A\u0E34\u0E07\u0E2B\u0E32\u0E04\u0E21', month9: '\u0E01\u0E31\u0E19\u0E22\u0E32\u0E22\u0E19', month10: '\u0E15\u0E38\u0E25\u0E32\u0E04\u0E21', month11: '\u0E1E\u0E24\u0E28\u0E08\u0E34\u0E01\u0E32\u0E22\u0E19', month12: '\u0E18\u0E31\u0E19\u0E27\u0E32\u0E04\u0E21', weeks: { sun: '\u0E2D\u0E32', mon: '\u0E08', tue: '\u0E2D', wed: '\u0E1E', thu: '\u0E1E\u0E24', fri: '\u0E28', sat: '\u0E2A', }, months: { jan: '\u0E21\u0E01\u0E23\u0E32', feb: '\u0E01\u0E38\u0E21\u0E20\u0E32', mar: '\u0E21\u0E35\u0E19\u0E32', apr: '\u0E40\u0E21\u0E29\u0E32', may: '\u0E1E\u0E24\u0E29\u0E20\u0E32', jun: '\u0E21\u0E34\u0E16\u0E38\u0E19\u0E32', jul: '\u0E01\u0E23\u0E01\u0E0E\u0E32', aug: '\u0E2A\u0E34\u0E07\u0E2B\u0E32', sep: '\u0E01\u0E31\u0E19\u0E22\u0E32', oct: '\u0E15\u0E38\u0E25\u0E32', nov: '\u0E1E\u0E24\u0E28\u0E08\u0E34\u0E01\u0E32', dec: '\u0E18\u0E31\u0E19\u0E27\u0E32', }, }, select: { loading: '\u0E01\u0E33\u0E25\u0E31\u0E07\u0E42\u0E2B\u0E25\u0E14', noMatch: '\u0E44\u0E21\u0E48\u0E1E\u0E1A\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E17\u0E35\u0E48\u0E15\u0E23\u0E07\u0E01\u0E31\u0E19', noData: '\u0E44\u0E21\u0E48\u0E1E\u0E1A\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25', placeholder: '\u0E40\u0E25\u0E37\u0E2D\u0E01', }, cascader: { noMatch: '\u0E44\u0E21\u0E48\u0E1E\u0E1A\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E17\u0E35\u0E48\u0E15\u0E23\u0E07\u0E01\u0E31\u0E19', loading: '\u0E01\u0E33\u0E25\u0E31\u0E07\u0E42\u0E2B\u0E25\u0E14', placeholder: '\u0E40\u0E25\u0E37\u0E2D\u0E01', noData: '\u0E44\u0E21\u0E48\u0E1E\u0E1A\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25', }, pagination: { goto: '\u0E44\u0E1B\u0E17\u0E35\u0E48', pagesize: '/\u0E2B\u0E19\u0E49\u0E32', total: '\u0E17\u0E31\u0E49\u0E07\u0E2B\u0E21\u0E14 {total}', pageClassifier: '', }, messagebox: { title: '\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21', confirm: '\u0E15\u0E01\u0E25\u0E07', cancel: '\u0E22\u0E01\u0E40\u0E25\u0E34\u0E01', error: '\u0E04\u0E38\u0E13\u0E1B\u0E49\u0E2D\u0E19\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07', }, upload: { deleteTip: '\u0E01\u0E14\u0E1B\u0E38\u0E48\u0E21 "\u0E25\u0E1A" \u0E40\u0E1E\u0E37\u0E48\u0E2D\u0E25\u0E1A\u0E2D\u0E2D\u0E01', delete: '\u0E25\u0E1A', preview: '\u0E15\u0E31\u0E27\u0E2D\u0E22\u0E48\u0E32\u0E07', continue: '\u0E17\u0E33\u0E15\u0E48\u0E2D', }, table: { emptyText: '\u0E44\u0E21\u0E48\u0E1E\u0E1A\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25', confirmFilter: '\u0E22\u0E37\u0E19\u0E22\u0E31\u0E19', resetFilter: '\u0E23\u0E35\u0E40\u0E0B\u0E47\u0E15', clearFilter: '\u0E17\u0E31\u0E49\u0E07\u0E2B\u0E21\u0E14', sumText: '\u0E23\u0E27\u0E21', }, tree: { emptyText: '\u0E44\u0E21\u0E48\u0E1E\u0E1A\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25', }, transfer: { noMatch: '\u0E44\u0E21\u0E48\u0E1E\u0E1A\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E17\u0E35\u0E48\u0E15\u0E23\u0E07\u0E01\u0E31\u0E19', noData: '\u0E44\u0E21\u0E48\u0E1E\u0E1A\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25', titles: ['List 1', 'List 2'], filterPlaceholder: '\u0E01\u0E23\u0E2D\u0E01\u0E04\u0E35\u0E22\u0E4C\u0E40\u0E27\u0E34\u0E23\u0E4C\u0E14', noCheckedFormat: '{total} items', hasCheckedFormat: '{checked}/{total} checked', }, image: { error: 'FAILED', }, pageHeader: { title: '\u0E22\u0E49\u0E2D\u0E19\u0E01\u0E25\u0E31\u0E1A', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_47 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: th$2, }, Symbol.toStringTag, { value: 'Module' } ) ) var tk = { name: 'tk', el: { colorpicker: { confirm: 'OK', clear: 'Arassala', }, datepicker: { now: '\u015Euwagt', today: '\u015E\xFCg\xFCn', cancel: 'Bes et', clear: 'Arassala', confirm: 'OK', selectDate: 'G\xFCni sa\xFDla\u0148', selectTime: 'Wagty sa\xFDla\u0148', startDate: 'Ba\u015Fla\xFDan g\xFCni', startTime: 'Ba\u015Fla\xFDan wagty', endDate: 'Gutar\xFDan g\xFCni', endTime: 'Gutar\xFDan wagty', prevYear: 'Previous Year', nextYear: 'Next Year', prevMonth: 'Previous Month', nextMonth: 'Next Month', year: '', month1: '\xDDan', month2: 'Few', month3: 'Mar', month4: 'Apr', month5: 'Ma\xFD', month6: 'I\xFDn', month7: 'I\xFDl', month8: 'Awg', month9: 'Sen', month10: 'Okt', month11: 'No\xFD', month12: 'Dek', weeks: { sun: '\xDDek', mon: 'Du\u015F', tue: 'Si\u015F', wed: '\xC7ar', thu: 'Pen', fri: 'Ann', sat: '\u015Een', }, months: { jan: '\xDDan', feb: 'Few', mar: 'Mar', apr: 'Apr', may: 'Ma\xFD', jun: 'I\xFDn', jul: 'I\xFDl', aug: 'Awg', sep: 'Sep', oct: 'Okt', nov: 'No\xFD', dec: 'Dek', }, }, select: { loading: 'Indiril\xFD\xE4r', noMatch: 'Hi\xE7zat tapylmady', noData: 'Hi\xE7zat \xFDok', placeholder: 'Sa\xFDla', }, cascader: { noMatch: 'Hi\xE7zat tapylmady', loading: 'Indiril\xFD\xE4r', placeholder: 'Sa\xFDla\u0148', noData: 'Hi\xE7zat \xFDok', }, pagination: { goto: 'Git', pagesize: '/sahypa', total: 'Umumy {total}', pageClassifier: '', }, messagebox: { title: 'Hat', confirm: 'OK', cancel: 'Bes et', error: '\xDDal\u0148y\u015F girizme', }, upload: { deleteTip: 'Pozmak \xFC\xE7in "poz" d\xFCwm\xE4 basy\u0148', delete: 'Poz', preview: 'G\xF6r', continue: 'Dowam et', }, table: { emptyText: 'Maglumat \xFDok', confirmFilter: 'Tassykla', resetFilter: 'Arassala', clearFilter: 'Hemmesi', sumText: 'Jemi', }, tree: { emptyText: 'Maglumat \xFDok', }, transfer: { noMatch: 'Hi\xE7zat tapylmady', noData: 'Hi\xE7zat \xFDok', titles: ['Sanaw 1', 'Sanaw 2'], filterPlaceholder: 'G\xF6zleg s\xF6zlerini girizi\u0148', noCheckedFormat: '{total} sany', hasCheckedFormat: '{checked}/{total} sa\xFDlanan', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_48 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: tk, }, Symbol.toStringTag, { value: 'Module' } ) ) var tr = { name: 'tr', el: { colorpicker: { confirm: 'Onayla', clear: 'Temizle', }, datepicker: { now: '\u015Eimdi', today: 'Bug\xFCn', cancel: '\u0130ptal', clear: 'Temizle', confirm: 'Onayla', selectDate: 'Tarih se\xE7', selectTime: 'Saat se\xE7', startDate: 'Ba\u015Flang\u0131\xE7 Tarihi', startTime: 'Ba\u015Flang\u0131\xE7 Saati', endDate: 'Biti\u015F Tarihi', endTime: 'Biti\u015F Saati', prevYear: '\xD6nceki Y\u0131l', nextYear: 'Sonraki Y\u0131l', prevMonth: '\xD6nceki Ay', nextMonth: 'Sonraki Ay', year: '', month1: 'Ocak', month2: '\u015Eubat', month3: 'Mart', month4: 'Nisan', month5: 'May\u0131s', month6: 'Haziran', month7: 'Temmuz', month8: 'A\u011Fustos', month9: 'Eyl\xFCl', month10: 'Ekim', month11: 'Kas\u0131m', month12: 'Aral\u0131k', weeks: { sun: 'Paz', mon: 'Pzt', tue: 'Sal', wed: '\xC7ar', thu: 'Per', fri: 'Cum', sat: 'Cmt', }, months: { jan: 'Oca', feb: '\u015Eub', mar: 'Mar', apr: 'Nis', may: 'May', jun: 'Haz', jul: 'Tem', aug: 'A\u011Fu', sep: 'Eyl', oct: 'Eki', nov: 'Kas', dec: 'Ara', }, }, select: { loading: 'Y\xFCkleniyor', noMatch: 'E\u015Fle\u015Fen veri bulunamad\u0131', noData: 'Veri yok', placeholder: 'Se\xE7', }, cascader: { noMatch: 'E\u015Fle\u015Fen veri bulunamad\u0131', loading: 'Y\xFCkleniyor', placeholder: 'Se\xE7', noData: 'Veri yok', }, pagination: { goto: 'Git', pagesize: '/sayfa', total: 'Toplam {total}', pageClassifier: '', }, messagebox: { title: 'Mesaj', confirm: 'Onayla', cancel: '\u0130ptal', error: '\u0130llegal giri\u015F', }, upload: { deleteTip: 'kald\u0131rmak i\xE7in delete tu\u015Funa bas', delete: 'Sil', preview: 'G\xF6r\xFCnt\xFCle', continue: 'Devam', }, table: { emptyText: 'Veri yok', confirmFilter: 'Onayla', resetFilter: 'S\u0131f\u0131rla', clearFilter: 'Hepsi', sumText: 'Sum', }, tree: { emptyText: 'Veri yok', }, transfer: { noMatch: 'E\u015Fle\u015Fen veri bulunamad\u0131', noData: 'Veri yok', titles: ['Liste 1', 'Liste 2'], filterPlaceholder: 'Anahtar kelimeleri gir', noCheckedFormat: '{total} adet', hasCheckedFormat: '{checked}/{total} se\xE7ildi', }, image: { error: 'BA\u015EARISIZ OLDU', }, pageHeader: { title: 'Geri', }, popconfirm: { confirmButtonText: 'Evet', cancelButtonText: 'Hay\u0131r', }, }, } var __glob_8_49 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: tr, }, Symbol.toStringTag, { value: 'Module' } ) ) var ugCn = { name: 'ug-cn', el: { colorpicker: { confirm: '\u062C\u06D5\u0632\u0645\u0644\u06D5\u0634', clear: '\u0642\u06C7\u0631\u06C7\u0642\u062F\u0627\u0634', }, datepicker: { now: '\u06BE\u0627\u0632\u0649\u0631\u0642\u0649 \u06CB\u0627\u0642\u0649\u062A', today: '\u0628\u06C8\u06AF\u06C8\u0646', cancel: '\u0628\u0649\u0643\u0627\u0631 \u0642\u0649\u0644\u0649\u0634', clear: '\u0642\u06C7\u0631\u06C7\u0642\u062F\u0627\u0634', confirm: '\u062C\u06D5\u0632\u0645\u0644\u06D5\u0634', selectDate: '\u0686\u0649\u0633\u0644\u0627 \u062A\u0627\u0644\u0644\u0627\u06AD', selectTime: '\u06CB\u0627\u0642\u0649\u062A \u062A\u0627\u0644\u0644\u0627\u06AD', startDate: '\u0628\u0627\u0634\u0644\u0627\u0646\u063A\u0627\u0646 \u0686\u0649\u0633\u0644\u0627', startTime: '\u0628\u0627\u0634\u0644\u0627\u0646\u063A\u0627\u0646 \u06CB\u0627\u0642\u0649\u062A', endDate: '\u0626\u0627\u062E\u0649\u0631\u0644\u0627\u0634\u0642\u0627\u0646 \u0686\u0649\u0633\u0644\u0627', endTime: '\u0626\u0627\u062E\u0649\u0631\u0644\u0627\u0634\u0642\u0627\u0646 \u06CB\u0627\u0642\u0649\u062A', prevYear: '\u0626\u0627\u0644\u062F\u0649\u0646\u0642\u0649 \u064A\u0649\u0644', nextYear: '\u0643\u0649\u064A\u0649\u0646\u0643\u0649 \u064A\u0649\u0644', prevMonth: '\u0626\u0627\u0644\u062F\u0649\u0646\u0642\u0649 \u0626\u0627\u064A', nextMonth: '\u0643\u0649\u064A\u0649\u0646\u0643\u0649 \u0626\u0627\u064A', year: '- \u064A\u0649\u0644', month1: '1-\u0626\u0627\u064A', month2: '2-\u0626\u0627\u064A', month3: '3-\u0626\u0627\u064A', month4: '4-\u0626\u0627\u064A', month5: '5-\u0626\u0627\u064A', month6: '6-\u0626\u0627\u064A', month7: '7-\u0626\u0627\u064A', month8: '8-\u0626\u0627\u064A', month9: '9-\u0626\u0627\u064A', month10: '10-\u0626\u0627\u064A', month11: '11-\u0626\u0627\u064A', month12: '12-\u0626\u0627\u064A', weeks: { sun: '\u064A\u06D5\u0643\u0634\u06D5\u0646\u0628\u06D5', mon: '\u062F\u06C8\u0634\u06D5\u0646\u0628\u06D5', tue: '\u0633\u06D5\u064A\u0634\u06D5\u0646\u0628\u06D5', wed: '\u0686\u0627\u0631\u0634\u06D5\u0646\u0628\u06D5', thu: '\u067E\u06D5\u064A\u0634\u06D5\u0646\u0628\u06D5', fri: '\u062C\u06C8\u0645\u06D5', sat: '\u0634\u06D5\u0646\u0628\u06D5', }, months: { jan: '1-\u0626\u0627\u064A', feb: '2-\u0626\u0627\u064A', mar: '3-\u0626\u0627\u064A', apr: '4-\u0626\u0627\u064A', may: '5-\u0626\u0627\u064A', jun: '6-\u0626\u0627\u064A', jul: '7-\u0626\u0627\u064A', aug: '8-\u0626\u0627\u064A', sep: '9-\u0626\u0627\u064A', oct: '10-\u0626\u0627\u064A', nov: '11-\u0626\u0627\u064A', dec: '12-\u0626\u0627\u064A', }, }, select: { loading: '\u064A\u06C8\u0643\u0644\u0649\u0646\u0649\u06CB\u0627\u062A\u0649\u062F\u06C7', noMatch: '\u0626\u06C7\u0686\u06C7\u0631 \u062A\u06D0\u067E\u0649\u0644\u0645\u0649\u062F\u0649', noData: '\u0626\u06C7\u0686\u06C7\u0631 \u064A\u0648\u0642', placeholder: '\u062A\u0627\u0644\u0644\u0627\u06AD', }, cascader: { noMatch: '\u0626\u06C7\u0686\u06C7\u0631 \u062A\u06D0\u067E\u0649\u0644\u0645\u0649\u062F\u0649', loading: '\u064A\u06C8\u0643\u0644\u0649\u0646\u0649\u06CB\u0627\u062A\u0649\u062F\u06C7', placeholder: '\u062A\u0627\u0644\u0644\u0627\u06AD', noData: '\u0626\u06C7\u0686\u06C7\u0631 \u064A\u0648\u0642', }, pagination: { goto: '\u0643\u0649\u064A\u0649\u0646\u0643\u0649 \u0628\u06D5\u062A', pagesize: '\u062A\u0627\u0644/\u0628\u06D5\u062A', total: '\u062C\u06D5\u0645\u0626\u0649\u064A {total} \u062A\u0627\u0644', pageClassifier: '\u0628\u06D5\u062A', }, messagebox: { title: '\u0626\u06D5\u0633\u0643\u06D5\u0631\u062A\u0649\u0634', confirm: '\u062C\u06D5\u0632\u0645\u0644\u06D5\u0634', cancel: '\u0628\u0649\u0643\u0627\u0631 \u0642\u0649\u0644\u0649\u0634', error: '\u0643\u0649\u0631\u06AF\u06C8\u0632\u06AF\u06D5\u0646 \u0626\u06C7\u0686\u06C7\u0631\u0649\u06AD\u0649\u0632\u062F\u0627 \u062E\u0627\u062A\u0627\u0644\u0649\u0642 \u0628\u0627\u0631!', }, upload: { deleteTip: 'delete \u0643\u06C7\u0646\u067E\u0643\u0649\u0633\u0649\u0646\u0649 \u0628\u06D0\u0633\u0649\u067E \u0626\u06C6\u0686\u06C8\u0631\u06D5\u0644\u06D5\u064A\u0633\u0649\u0632', delete: '\u0626\u06C6\u0686\u06C8\u0631\u06C8\u0634', preview: '\u0631\u06D5\u0633\u0649\u0645\u0646\u0649 \u0643\u06C6\u0631\u06C8\u0634', continue: '\u0631\u06D5\u0633\u0649\u0645 \u064A\u0648\u0644\u0644\u0627\u0634', }, table: { emptyText: '\u0626\u06C7\u0686\u06C7\u0631 \u064A\u0648\u0642', confirmFilter: '\u0633\u06C8\u0632\u06AF\u06C8\u0686', resetFilter: '\u0642\u0627\u064A\u062A\u0627 \u062A\u0648\u0644\u062F\u06C7\u0631\u06C7\u0634', clearFilter: '\u06BE\u06D5\u0645\u0645\u06D5', sumText: '\u062C\u06D5\u0645\u0626\u0649\u064A', }, tree: { emptyText: '\u0626\u06C7\u0686\u06C7\u0631 \u064A\u0648\u0642', }, transfer: { noMatch: '\u0626\u06C7\u0686\u06C7\u0631 \u062A\u06D0\u067E\u0649\u0644\u0645\u0649\u062F\u0649', noData: '\u0626\u06C7\u0686\u06C7\u0631 \u064A\u0648\u0642', titles: [ '\u062C\u06D5\u062F\u06CB\u06D5\u0644 1', '\u062C\u06D5\u062F\u06CB\u06D5\u0644 2', ], filterPlaceholder: '\u0626\u0649\u0632\u062F\u0649\u0645\u06D5\u0643\u0686\u0649 \u0628\u0648\u0644\u063A\u0627\u0646 \u0645\u06D5\u0632\u0645\u06C7\u0646\u0646\u0649 \u0643\u0649\u0631\u06AF\u06C8\u0632\u06C8\u06AD', noCheckedFormat: '\u062C\u06D5\u0645\u0626\u0649\u064A {total} \u062A\u06C8\u0631', hasCheckedFormat: '\u062A\u0627\u0644\u0644\u0627\u0646\u063A\u0649\u0646\u0649 {checked}/{total} \u062A\u06C8\u0631', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_50 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: ugCn, }, Symbol.toStringTag, { value: 'Module' } ) ) var uk = { name: 'uk', el: { colorpicker: { confirm: 'OK', clear: '\u041E\u0447\u0438\u0441\u0442\u0438\u0442\u0438', }, datepicker: { now: '\u0417\u0430\u0440\u0430\u0437', today: '\u0421\u044C\u043E\u0433\u043E\u0434\u043D\u0456', cancel: '\u0412\u0456\u0434\u043C\u0456\u043D\u0430', clear: '\u041E\u0447\u0438\u0441\u0442\u0438\u0442\u0438', confirm: 'OK', selectDate: '\u0412\u0438\u0431\u0440\u0430\u0442\u0438 \u0434\u0430\u0442\u0443', selectTime: '\u0412\u0438\u0431\u0440\u0430\u0442\u0438 \u0447\u0430\u0441', startDate: '\u0414\u0430\u0442\u0430 \u043F\u043E\u0447\u0430\u0442\u043A\u0443', startTime: '\u0427\u0430\u0441 \u043F\u043E\u0447\u0430\u0442\u043A\u0443', endDate: '\u0414\u0430\u0442\u0430 \u0437\u0430\u0432\u0435\u0440\u0448\u0435\u043D\u043D\u044F', endTime: '\u0427\u0430\u0441 \u0437\u0430\u0432\u0435\u0440\u0448\u0435\u043D\u043D\u044F', prevYear: '\u041F\u043E\u043F\u0435\u0440\u0435\u0434\u043D\u0456\u0439 \u0420\u0456\u043A', nextYear: '\u041D\u0430\u0441\u0442\u0443\u043F\u043D\u0438\u0439 \u0420\u0456\u043A', prevMonth: '\u041F\u043E\u043F\u0435\u0440\u0435\u0434\u043D\u0456\u0439 \u041C\u0456\u0441\u044F\u0446\u044C', nextMonth: '\u041D\u0430\u0441\u0442\u0443\u043F\u043D\u0438\u0439 \u041C\u0456\u0441\u044F\u0446\u044C', year: '', month1: '\u0421\u0456\u0447\u0435\u043D\u044C', month2: '\u041B\u044E\u0442\u0438\u0439', month3: '\u0411\u0435\u0440\u0435\u0437\u0435\u043D\u044C', month4: '\u041A\u0432\u0456\u0442\u0435\u043D\u044C', month5: '\u0422\u0440\u0430\u0432\u0435\u043D\u044C', month6: '\u0427\u0435\u0440\u0432\u0435\u043D\u044C', month7: '\u041B\u0438\u043F\u0435\u043D\u044C', month8: '\u0421\u0435\u0440\u043F\u0435\u043D\u044C', month9: '\u0412\u0435\u0440\u0435\u0441\u0435\u043D\u044C', month10: '\u0416\u043E\u0432\u0442\u0435\u043D\u044C', month11: '\u041B\u0438\u0441\u0442\u043E\u043F\u0430\u0434', month12: '\u0413\u0440\u0443\u0434\u0435\u043D\u044C', week: '\u0442\u0438\u0436\u0434\u0435\u043D\u044C', weeks: { sun: '\u041D\u0434', mon: '\u041F\u043D', tue: '\u0412\u0442', wed: '\u0421\u0440', thu: '\u0427\u0442', fri: '\u041F\u0442', sat: '\u0421\u0431', }, months: { jan: '\u0421\u0456\u0447', feb: '\u041B\u044E\u0442', mar: '\u0411\u0435\u0440', apr: '\u041A\u0432\u0456', may: '\u0422\u0440\u0430', jun: '\u0427\u0435\u0440', jul: '\u041B\u0438\u043F', aug: '\u0421\u0435\u0440', sep: '\u0412\u0435\u0440', oct: '\u0416\u043E\u0432', nov: '\u041B\u0438\u0441', dec: '\u0413\u0440\u0443', }, }, select: { loading: '\u0417\u0430\u0432\u0430\u043D\u0442\u0430\u0436\u0435\u043D\u043D\u044F', noMatch: '\u0421\u043F\u0456\u0432\u043F\u0430\u0434\u0456\u043D\u044C \u043D\u0435 \u0437\u043D\u0430\u0439\u0434\u0435\u043D\u043E', noData: '\u041D\u0435\u043C\u0430\u0454 \u0434\u0430\u043D\u0438\u0445', placeholder: '\u041E\u0431\u0440\u0430\u0442\u0438', }, cascader: { noMatch: '\u0421\u043F\u0456\u0432\u043F\u0430\u0434\u0456\u043D\u044C \u043D\u0435 \u0437\u043D\u0430\u0439\u0434\u0435\u043D\u043E', loading: '\u0417\u0430\u0432\u0430\u043D\u0442\u0430\u0436\u0435\u043D\u043D\u044F', placeholder: '\u041E\u0431\u0440\u0430\u0442\u0438', noData: '\u041D\u0435\u043C\u0430\u0454 \u0434\u0430\u043D\u0438\u0445', }, pagination: { goto: '\u041F\u0435\u0440\u0435\u0439\u0442\u0438', pagesize: '\u043D\u0430 \u0441\u0442\u043E\u0440\u0456\u043D\u0446\u0456', total: '\u0412\u0441\u044C\u043E\u0433\u043E {total}', pageClassifier: '', }, messagebox: { title: '\u041F\u043E\u0432\u0456\u0434\u043E\u043C\u043B\u0435\u043D\u043D\u044F', confirm: 'OK', cancel: '\u0412\u0456\u0434\u043C\u0456\u043D\u0430', error: '\u041D\u0435\u043F\u0440\u0438\u043F\u0443\u0441\u0442\u0438\u043C\u0438\u0439 \u0432\u0432\u0456\u0434 \u0434\u0430\u043D\u0438\u0445', }, upload: { deleteTip: '\u043D\u0430\u0442\u0438\u0441\u043D\u0456\u0442\u044C \u043A\u043D\u043E\u043F\u043A\u0443 \u0449\u043E\u0431 \u0432\u0438\u0434\u0430\u043B\u0438\u0442\u0438', delete: '\u0412\u0438\u0434\u0430\u043B\u0438\u0442\u0438', preview: '\u041F\u0435\u0440\u0435\u0433\u043B\u044F\u0434', continue: '\u041F\u0440\u043E\u0434\u043E\u0432\u0436\u0438\u0442\u0438', }, table: { emptyText: '\u041D\u0435\u043C\u0430\u0454 \u0434\u0430\u043D\u0438\u0445', confirmFilter: '\u041F\u0456\u0434\u0442\u0432\u0435\u0440\u0434\u0438\u0442\u0438', resetFilter: '\u0421\u043A\u0438\u043D\u0443\u0442\u0438', clearFilter: '\u0412\u0441\u0435', sumText: '\u0421\u0443\u043C\u0430', }, tree: { emptyText: '\u041D\u0435\u043C\u0430\u0454 \u0434\u0430\u043D\u0438\u0445', }, transfer: { noMatch: '\u0421\u043F\u0456\u0432\u043F\u0430\u0434\u0456\u043D\u044C \u043D\u0435 \u0437\u043D\u0430\u0439\u0434\u0435\u043D\u043E', noData: '\u041E\u0431\u0440\u0430\u0442\u0438', titles: [ '\u0421\u043F\u0438\u0441\u043E\u043A 1', '\u0421\u043F\u0438\u0441\u043E\u043A 2', ], filterPlaceholder: '\u0412\u0432\u0435\u0434\u0456\u0442\u044C \u043A\u043B\u044E\u0447\u043E\u0432\u0435 \u0441\u043B\u043E\u0432\u043E', noCheckedFormat: '{total} \u043F\u0443\u043D\u043A\u0442\u0456\u0432', hasCheckedFormat: '{checked}/{total} \u0432\u0438\u0431\u0440\u0430\u043D\u043E', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_51 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: uk, }, Symbol.toStringTag, { value: 'Module' } ) ) var uzUz = { name: 'uz-uz', el: { colorpicker: { confirm: 'Qabul qilish', clear: 'Tozalash', }, datepicker: { now: 'Hozir', today: 'Bugun', cancel: 'Bekor qilish', clear: 'Tozalash', confirm: 'Qabul qilish', selectDate: 'Kunni tanlash', selectTime: 'Soatni tanlash', startDate: 'Boshlanish sanasi', startTime: 'Boshlanish vaqti', endDate: 'Tugash sanasi', endTime: 'Tugash vaqti', prevYear: 'O\u02BBtgan yil', nextYear: 'Kelgusi yil', prevMonth: 'O\u02BBtgan oy', nextMonth: 'Kelgusi oy', year: 'Yil', month1: 'Yanvar', month2: 'Fevral', month3: 'Mart', month4: 'Aprel', month5: 'May', month6: 'Iyun', month7: 'Iyul', month8: 'Avgust', month9: 'Sentabr', month10: 'Oktabr', month11: 'Noyabr', month12: 'Dekabr', week: 'Hafta', weeks: { sun: 'Yak', mon: 'Dush', tue: 'Sesh', wed: 'Chor', thu: 'Pay', fri: 'Jum', sat: 'Shan', }, months: { jan: 'Yan', feb: 'Fev', mar: 'Mar', apr: 'Apr', may: 'May', jun: 'Iyun', jul: 'Iyul', aug: 'Avg', sep: 'Sen', oct: 'Okt', nov: 'Noy', dec: 'Dek', }, }, select: { loading: 'Yuklanmoqda', noMatch: 'Mos ma\u02BClumot yo\u02BBq', noData: 'Ma\u02BClumot yo\u02BBq', placeholder: 'Tanladizngiz', }, cascader: { noMatch: 'Mos ma\u02BClumot topilmadi', loading: 'Yuklanmoqda', placeholder: 'Tanlash', noData: 'Ma\u02BClumot yo\u02BBq', }, pagination: { goto: 'O\u02BBtish', pagesize: '/sahifa', total: 'Barchasi {total} ta', pageClassifier: '', }, messagebox: { title: 'Xabar', confirm: 'Qabul qilish', cancel: 'Bekor qilish', error: 'Xatolik', }, upload: { deleteTip: 'O\u02BBchirish tugmasini bosib o\u02BBchiring', delete: 'O\u02BBchirish', preview: 'Oldin ko\u02BBrish', continue: 'Davom qilish', }, table: { emptyText: 'Bo\u02BBsh', confirmFilter: 'Qabul qilish', resetFilter: 'Oldingi holatga qaytarish', clearFilter: 'Jami', sumText: 'Summasi', }, tree: { emptyText: 'Ma\u02BClumot yo\u02BBq', }, transfer: { noMatch: 'Mos ma\u02BClumot topilmadi', noData: 'Ma\u02BClumot yo\u02BBq', titles: ['1-jadval', '2-jadval'], filterPlaceholder: 'Kalit so\u02BBzni kiriting', noCheckedFormat: '{total} ta element', hasCheckedFormat: '{checked}/{total} ta belgilandi', }, image: { error: 'Xatolik', }, pageHeader: { title: 'Orqaga', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } var __glob_8_52 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: uzUz, }, Symbol.toStringTag, { value: 'Module' } ) ) var vi = { name: 'vi', el: { colorpicker: { confirm: 'OK', clear: 'X\xF3a', }, datepicker: { now: 'Hi\u1EC7n t\u1EA1i', today: 'H\xF4m nay', cancel: 'H\u1EE7y', clear: 'X\xF3a', confirm: 'OK', selectDate: 'Ch\u1ECDn ng\xE0y', selectTime: 'Ch\u1ECDn gi\u1EDD', startDate: 'Ng\xE0y b\u1EAFt \u0111\u1EA7u', startTime: 'Th\u1EDDi gian b\u1EAFt \u0111\u1EA7u', endDate: 'Ng\xE0y k\u1EBFt th\xFAc', endTime: 'Th\u1EDDi gian k\u1EBFt th\xFAc', prevYear: 'N\u0103m tr\u01B0\u1EDBc', nextYear: 'N\u0103m t\u1EDBi', prevMonth: 'Th\xE1ng tr\u01B0\u1EDBc', nextMonth: 'Th\xE1ng t\u1EDBi', year: 'N\u0103m', month1: 'Th\xE1ng 1', month2: 'Th\xE1ng 2', month3: 'Th\xE1ng 3', month4: 'Th\xE1ng 4', month5: 'Th\xE1ng 5', month6: 'Th\xE1ng 6', month7: 'Th\xE1ng 7', month8: 'Th\xE1ng 8', month9: 'Th\xE1ng 9', month10: 'Th\xE1ng 10', month11: 'Th\xE1ng 11', month12: 'Th\xE1ng 12', weeks: { sun: 'CN', mon: 'T2', tue: 'T3', wed: 'T4', thu: 'T5', fri: 'T6', sat: 'T7', }, months: { jan: 'Th.1', feb: 'Th.2', mar: 'Th.3', apr: 'Th.4', may: 'Th.5', jun: 'Th.6', jul: 'Th.7', aug: 'Th.8', sep: 'Th.9', oct: 'Th.10', nov: 'Th.11', dec: 'Th.12', }, }, select: { loading: '\u0110ang t\u1EA3i', noMatch: 'D\u1EEF li\u1EC7u kh\xF4ng ph\xF9 h\u1EE3p', noData: 'Kh\xF4ng t\xECm th\u1EA5y d\u1EEF li\u1EC7u', placeholder: 'Ch\u1ECDn', }, cascader: { noMatch: 'D\u1EEF li\u1EC7u kh\xF4ng ph\xF9 h\u1EE3p', loading: '\u0110ang t\u1EA3i', placeholder: 'Ch\u1ECDn', noData: 'Kh\xF4ng t\xECm th\u1EA5y d\u1EEF li\u1EC7u', }, pagination: { goto: 'Nh\u1EA3y t\u1EDBi', pagesize: '/trang', total: 'T\u1ED5ng {total}', pageClassifier: '', }, messagebox: { title: 'Th\xF4ng b\xE1o', confirm: 'OK', cancel: 'H\u1EE7y', error: 'D\u1EEF li\u1EC7u kh\xF4ng h\u1EE3p l\u1EC7', }, upload: { deleteTip: 'Nh\u1EA5n xo\xE1 \u0111\u1EC3 xo\xE1', delete: 'X\xF3a', preview: 'Xem tr\u01B0\u1EDBc', continue: 'Ti\u1EBFp t\u1EE5c', }, table: { emptyText: 'Kh\xF4ng c\xF3 d\u1EEF li\u1EC7u', confirmFilter: 'X\xE1c nh\u1EADn', resetFilter: 'L\xE0m m\u1EDBi', clearFilter: 'X\xF3a h\u1EBFt', sumText: 'T\u1ED5ng', }, tree: { emptyText: 'Kh\xF4ng c\xF3 d\u1EEF li\u1EC7u', }, transfer: { noMatch: 'D\u1EEF li\u1EC7u kh\xF4ng ph\xF9 h\u1EE3p', noData: 'Kh\xF4ng t\xECm th\u1EA5y d\u1EEF li\u1EC7u', titles: ['Danh s\xE1ch 1', 'Danh s\xE1ch 2'], filterPlaceholder: 'Nh\u1EADp t\u1EEB kh\xF3a', noCheckedFormat: '{total} m\u1EE5c', hasCheckedFormat: '{checked}/{total} \u0111\xE3 ch\u1ECDn ', }, image: { error: 'L\u1ED6I', }, pageHeader: { title: 'Quay l\u1EA1i', }, popconfirm: { confirmButtonText: 'Ok', cancelButtonText: 'Hu\u1EF7', }, }, } var __glob_8_53 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: vi, }, Symbol.toStringTag, { value: 'Module' } ) ) var zhCn$2 = { name: 'zh-cn', el: { colorpicker: { confirm: '\u786E\u5B9A', clear: '\u6E05\u7A7A', }, datepicker: { now: '\u6B64\u523B', today: '\u4ECA\u5929', cancel: '\u53D6\u6D88', clear: '\u6E05\u7A7A', confirm: '\u786E\u5B9A', selectDate: '\u9009\u62E9\u65E5\u671F', selectTime: '\u9009\u62E9\u65F6\u95F4', startDate: '\u5F00\u59CB\u65E5\u671F', startTime: '\u5F00\u59CB\u65F6\u95F4', endDate: '\u7ED3\u675F\u65E5\u671F', endTime: '\u7ED3\u675F\u65F6\u95F4', prevYear: '\u524D\u4E00\u5E74', nextYear: '\u540E\u4E00\u5E74', prevMonth: '\u4E0A\u4E2A\u6708', nextMonth: '\u4E0B\u4E2A\u6708', year: '\u5E74', month1: '1 \u6708', month2: '2 \u6708', month3: '3 \u6708', month4: '4 \u6708', month5: '5 \u6708', month6: '6 \u6708', month7: '7 \u6708', month8: '8 \u6708', month9: '9 \u6708', month10: '10 \u6708', month11: '11 \u6708', month12: '12 \u6708', weeks: { sun: '\u65E5', mon: '\u4E00', tue: '\u4E8C', wed: '\u4E09', thu: '\u56DB', fri: '\u4E94', sat: '\u516D', }, months: { jan: '\u4E00\u6708', feb: '\u4E8C\u6708', mar: '\u4E09\u6708', apr: '\u56DB\u6708', may: '\u4E94\u6708', jun: '\u516D\u6708', jul: '\u4E03\u6708', aug: '\u516B\u6708', sep: '\u4E5D\u6708', oct: '\u5341\u6708', nov: '\u5341\u4E00\u6708', dec: '\u5341\u4E8C\u6708', }, }, select: { loading: '\u52A0\u8F7D\u4E2D', noMatch: '\u65E0\u5339\u914D\u6570\u636E', noData: '\u65E0\u6570\u636E', placeholder: '\u8BF7\u9009\u62E9', }, cascader: { noMatch: '\u65E0\u5339\u914D\u6570\u636E', loading: '\u52A0\u8F7D\u4E2D', placeholder: '\u8BF7\u9009\u62E9', noData: '\u6682\u65E0\u6570\u636E', }, pagination: { goto: '\u524D\u5F80', pagesize: '\u6761/\u9875', total: '\u5171 {total} \u6761', pageClassifier: '\u9875', deprecationWarning: '\u4F60\u4F7F\u7528\u4E86\u4E00\u4E9B\u5DF2\u88AB\u5E9F\u5F03\u7684\u7528\u6CD5\uFF0C\u8BF7\u53C2\u8003 el-pagination \u7684\u5B98\u65B9\u6587\u6863', }, messagebox: { title: '\u63D0\u793A', confirm: '\u786E\u5B9A', cancel: '\u53D6\u6D88', error: '\u8F93\u5165\u7684\u6570\u636E\u4E0D\u5408\u6CD5!', }, upload: { deleteTip: '\u6309 delete \u952E\u53EF\u5220\u9664', delete: '\u5220\u9664', preview: '\u67E5\u770B\u56FE\u7247', continue: '\u7EE7\u7EED\u4E0A\u4F20', }, table: { emptyText: '\u6682\u65E0\u6570\u636E', confirmFilter: '\u7B5B\u9009', resetFilter: '\u91CD\u7F6E', clearFilter: '\u5168\u90E8', sumText: '\u5408\u8BA1', }, tree: { emptyText: '\u6682\u65E0\u6570\u636E', }, transfer: { noMatch: '\u65E0\u5339\u914D\u6570\u636E', noData: '\u65E0\u6570\u636E', titles: ['\u5217\u8868 1', '\u5217\u8868 2'], filterPlaceholder: '\u8BF7\u8F93\u5165\u641C\u7D22\u5185\u5BB9', noCheckedFormat: '\u5171 {total} \u9879', hasCheckedFormat: '\u5DF2\u9009 {checked}/{total} \u9879', }, image: { error: '\u52A0\u8F7D\u5931\u8D25', }, pageHeader: { title: '\u8FD4\u56DE', }, popconfirm: { confirmButtonText: '\u786E\u5B9A', cancelButtonText: '\u53D6\u6D88', }, }, } var __glob_8_54 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: zhCn$2, }, Symbol.toStringTag, { value: 'Module' } ) ) var zhTw = { name: 'zh-tw', el: { colorpicker: { confirm: '\u78BA\u8A8D', clear: '\u6E05\u7A7A', }, datepicker: { now: '\u73FE\u5728', today: '\u4ECA\u5929', cancel: '\u53D6\u6D88', clear: '\u6E05\u7A7A', confirm: '\u78BA\u8A8D', selectDate: '\u9078\u64C7\u65E5\u671F', selectTime: '\u9078\u64C7\u6642\u9593', startDate: '\u958B\u59CB\u65E5\u671F', startTime: '\u958B\u59CB\u6642\u9593', endDate: '\u7D50\u675F\u65E5\u671F', endTime: '\u7D50\u675F\u6642\u9593', prevYear: '\u524D\u4E00\u5E74', nextYear: '\u5F8C\u4E00\u5E74', prevMonth: '\u4E0A\u500B\u6708', nextMonth: '\u4E0B\u500B\u6708', year: '\u5E74', month1: '1 \u6708', month2: '2 \u6708', month3: '3 \u6708', month4: '4 \u6708', month5: '5 \u6708', month6: '6 \u6708', month7: '7 \u6708', month8: '8 \u6708', month9: '9 \u6708', month10: '10 \u6708', month11: '11 \u6708', month12: '12 \u6708', weeks: { sun: '\u65E5', mon: '\u4E00', tue: '\u4E8C', wed: '\u4E09', thu: '\u56DB', fri: '\u4E94', sat: '\u516D', }, months: { jan: '\u4E00\u6708', feb: '\u4E8C\u6708', mar: '\u4E09\u6708', apr: '\u56DB\u6708', may: '\u4E94\u6708', jun: '\u516D\u6708', jul: '\u4E03\u6708', aug: '\u516B\u6708', sep: '\u4E5D\u6708', oct: '\u5341\u6708', nov: '\u5341\u4E00\u6708', dec: '\u5341\u4E8C\u6708', }, }, select: { loading: '\u52A0\u8F09\u4E2D', noMatch: '\u7121\u5339\u914D\u8CC7\u6599', noData: '\u7121\u8CC7\u6599', placeholder: '\u8ACB\u9078\u64C7', }, cascader: { noMatch: '\u7121\u5339\u914D\u8CC7\u6599', loading: '\u52A0\u8F09\u4E2D', placeholder: '\u8ACB\u9078\u64C7', noData: '\u7121\u8CC7\u6599', }, pagination: { goto: '\u524D\u5F80', pagesize: '\u9805/\u9801', total: '\u5171 {total} \u9805', pageClassifier: '\u9801', }, messagebox: { title: '\u63D0\u793A', confirm: '\u78BA\u5B9A', cancel: '\u53D6\u6D88', error: '\u8F38\u5165\u7684\u8CC7\u6599\u4E0D\u7B26\u898F\u5B9A!', }, upload: { deleteTip: '\u6309 delete \u9375\u53EF\u522A\u9664', delete: '\u522A\u9664', preview: '\u67E5\u770B\u5716\u7247', continue: '\u7E7C\u7E8C\u4E0A\u50B3', }, table: { emptyText: '\u66AB\u7121\u8CC7\u6599', confirmFilter: '\u7BE9\u9078', resetFilter: '\u91CD\u7F6E', clearFilter: '\u5168\u90E8', sumText: '\u5408\u8A08', }, tree: { emptyText: '\u66AB\u7121\u8CC7\u6599', }, transfer: { noMatch: '\u7121\u5339\u914D\u8CC7\u6599', noData: '\u7121\u8CC7\u6599', titles: ['\u5217\u8868 1', '\u5217\u8868 2'], filterPlaceholder: '\u8ACB\u8F38\u5165\u641C\u7D22\u5167\u5BB9', noCheckedFormat: '\u5171 {total} \u9805', hasCheckedFormat: '\u5DF2\u9078 {checked}/{total} \u9805', }, image: { error: '\u52A0\u8F09\u5931\u6557', }, pageHeader: { title: '\u8FD4\u56DE', }, popconfirm: { confirmButtonText: '\u78BA\u8A8D', cancelButtonText: '\u53D6\u6D88', }, }, } var __glob_8_55 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: zhTw, }, Symbol.toStringTag, { value: 'Module' } ) ) class Base { vueKey = Math.random() constructor() { Object.defineProperty(this, 'vueKey', { enumerable: false, }) return reactive(this) } } var __glob_0_1 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, Base, }, Symbol.toStringTag, { value: 'Module' } ) ) const EDITING = 'editing' const RUNNING = 'running' const MODE = { EDITING, RUNNING, } const mode = /running/.test(location.href) ? MODE.RUNNING : MODE.EDITING const editing = mode === MODE.EDITING const running = mode === MODE.RUNNING class Client { constructor() {} static windowArea = {} beforeSize = { x: 150, y: 100, width: 1600, height: 800, } fullScreenBeforeSize = { x: 150, y: 100, width: 1600, height: 800, } isClient() { return !!window.bridge?.electron } async invoke(...args) { if (!window.bridge) { throw new Error('!bridge') } return await window.bridge.invoke(...args) } async openDirectory(option2 = {}) { if (!window.bridge) return '' option2 = Object.assign( { title: '\u8BF7\u9009\u62E9\u6587\u4EF6\u4F4D\u7F6E', buttonLabel: '\u786E\u5B9A', properties: ['openDirectory'], filters: [{ name: 'FileType', extensions: ['cmspkg'] }], }, option2 ) return new Promise((rs2) => { client .invoke(async ({ electron: electron2 }, option22) => { const { dialog, BrowserWindow } = electron2 const win = BrowserWindow.getFocusedWindow() const res = await dialog.showOpenDialog(win, option22) if (res !== void 0) { return res } }, option2) .then((res) => { !res.canceled && rs2(res.filePaths[0]) }) }) } async getFilePath(option2 = {}) { if (!window.bridge) return [] option2 = Object.assign( { title: '\u8BF7\u9009\u62E9\u6587\u4EF6', filters: [{ name: 'SQLite File Type', extensions: ['db'] }], }, option2 ) return new Promise((rs2) => { client .invoke(async ({ electron: electron2 }, option22) => { const { dialog, BrowserWindow } = electron2 const win = BrowserWindow.getFocusedWindow() const res = await dialog.showOpenDialog(win, option22) if (res !== void 0) { return res } }, option2) .then((res) => { !res.canceled && rs2(res.filePaths) }) }) } async saveFile(dir3, fileName, url2) { if (!window.bridge) return '' let arraybuffer = await request.get(url2, { responseType: 'arraybuffer' }) return new Promise((rs2) => { client .invoke( ( { electron: electron2, require: require2 }, dir22, fileName2, arrayBuffer ) => { const fs = require2('fs') const path = require2('path') const { shell } = electron2 let isExist = fs.existsSync(dir22) if (!isExist) { fs.mkdirSync(dir22, { recursive: true, }) } const filePath = path.join(dir22, '/' + fileName2) const ui32 = new Uint8Array(arrayBuffer) fs.writeFileSync(filePath, ui32) shell.showItemInFolder(filePath) }, dir3, fileName, arraybuffer ) .then(() => { rs2(true) }) }) } async isExists(path) { return new Promise((rs2) => { client .invoke(({ require: require2 }, path2) => { const fs = require2('fs') let isExists = fs.existsSync(path2) return isExists }, path) .then((res) => { rs2(res) }) }) } async getProjectDefaultFile() { return new Promise((rs2) => { client .invoke(({ electron: electron2, require: require2 }) => { let { app: app2 } = electron2 const path = require2('path') return path.join(app2.getAppPath(), '../../../../host/data/projects') }) .then((path) => { rs2(path) }) }) } async getWindowArea() { return new Promise(async (rs2) => { await client .invoke(({ electron: electron2 }) => { let windowArea = {} const { screen } = electron2 const primaryDisplay = screen.getAllDisplays() let xList = [], yList = [], boundsList = [] let currentDisplay = screen.getPrimaryDisplay() let singleWorkArea = currentDisplay.workArea primaryDisplay.forEach((disWin) => { xList.push(disWin.bounds.x) yList.push(disWin.bounds.y) boundsList.push(disWin.bounds) }) let fullWorkSizeWidth = primaryDisplay[ xList.findIndex((item2) => item2 === Math.max(...xList)) ].workArea.width + Math.max(...xList) let fullBoundsWidth = primaryDisplay[ xList.findIndex((item2) => item2 === Math.max(...xList)) ].bounds.width + Math.max(...xList) let fullWorkSizeHeight = primaryDisplay[ yList.findIndex((item2) => item2 === Math.max(...yList)) ].workArea.height + Math.max(...yList) let fullBoundsHeight = primaryDisplay[ yList.findIndex((item2) => item2 === Math.max(...yList)) ].bounds.height + Math.max(...yList) windowArea.fullArea = { full: { width: fullBoundsWidth, height: fullBoundsHeight, }, normal: { width: fullWorkSizeWidth, height: fullWorkSizeHeight, }, } windowArea.isValidFullArea = boundsList.every( (item2) => item2.x % singleWorkArea.width === 0 && item2.y % singleWorkArea.height === 0 ) return windowArea }) .then((res) => { rs2(res) }) }) } requestFullscreen(isFullAllWindow = app.config.isFullAllWindow) { return new Promise((rs2) => { client .invoke( ({ electron: electron2 }, isFullAllWindow2, windowArea) => { const { BrowserWindow } = electron2 const win = BrowserWindow.getFocusedWindow() if (!win) return let fullScreenBeforeSize = win.getBounds() if (!isFullAllWindow2 || !windowArea.isValidFullArea) { win.setFullScreen(true) } else { win.webContents.executeJavaScript( `(${function (beforeSize) { models.client.fullScreenBeforeSize = beforeSize }})(${JSON.stringify(fullScreenBeforeSize)})` ) win.setBounds({ x: 0, y: 0, width: windowArea.fullArea.full.width, height: windowArea.fullArea.full.height, }) } }, isFullAllWindow, Client.windowArea, mode ) .then(() => { rs2(true) }) }) } exitFullScreen() { return new Promise((rs2) => { client .invoke(({ electron: electron2 }, beforeSize) => { const { BrowserWindow } = electron2 const win = BrowserWindow.getFocusedWindow() if (!win) return win.isFullScreen() ? win.setFullScreen(false) : win.setBounds(beforeSize) }, client.fullScreenBeforeSize) .then(() => { rs2(true) }) }) } static isMaximized() { return new Promise((rs2) => { client .invoke(({ electron: electron2 }, windowArea) => { const { BrowserWindow } = electron2 const win = BrowserWindow.getFocusedWindow() if (!win) return let size = win.getBounds() return ( size.width === windowArea.fullArea.normal.width && size.height === windowArea.fullArea.normal.height ) }, Client.windowArea) .then((res) => { rs2(res) }) }) } setMaxSize() { return new Promise((rs2) => { client .invoke( async ({ electron: electron2 }, isFullAllWindow, windowArea) => { const { BrowserWindow } = electron2 const win = BrowserWindow.getFocusedWindow() if (!win) return if (isFullAllWindow) { win.setBounds({ width: windowArea.fullArea.normal.width, height: windowArea.fullArea.normal.height, x: 0, y: 0, }) } else { win.maximize() } return }, app.config.isFullAllWindow, Client.windowArea ) .then((res) => { rs2(res) }) }) } maximize() { return new Promise((rs2) => { client .invoke( async ( { electron: electron2 }, mode2, isFullAllWindow, windowArea, beforeSize ) => { const { BrowserWindow } = electron2 const win = BrowserWindow.getFocusedWindow() if (!win) return if ( isFullAllWindow && windowArea.isValidFullArea && mode2 === 'running' ) { let size = win.getBounds() let isMaximized = size.width === windowArea.fullArea.normal.width && size.height === windowArea.fullArea.normal.height if (isMaximized) { win.setBounds(beforeSize) } else { win.webContents.executeJavaScript( `(${function (beforeSize2) { models.client.beforeSize = beforeSize2 }})(${JSON.stringify(size)})` ) win.setBounds({ width: windowArea.fullArea.normal.width, height: windowArea.fullArea.normal.height, x: 0, y: 0, }) } return } if (win.isMaximized()) { win.restore() } else { win.maximize() } }, mode, app.config.isFullAllWindow, Client.windowArea, client.beforeSize ) .then((res) => { rs2(res) }) }) } } const client = new Client() if (client.isClient()) { Client.windowArea = await client.getWindowArea() } window.cmstype = window.electron || 'Web' var __glob_0_4 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, Client, client, }, Symbol.toStringTag, { value: 'Module' } ) ) var lodash$2 = { exports: {} } /** * @license * Lodash * Copyright OpenJS Foundation and other contributors * Released under MIT license * Based on Underscore.js 1.8.3 * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors */ ;(function (module2, exports2) { ;(function () { var undefined$1 var VERSION2 = '4.17.21' var LARGE_ARRAY_SIZE2 = 200 var CORE_ERROR_TEXT = 'Unsupported core-js use. Try https://npms.io/search?q=ponyfill.', FUNC_ERROR_TEXT2 = 'Expected a function', INVALID_TEMPL_VAR_ERROR_TEXT = 'Invalid `variable` option passed into `_.template`' var HASH_UNDEFINED2 = '__lodash_hash_undefined__' var MAX_MEMOIZE_SIZE2 = 500 var PLACEHOLDER = '__lodash_placeholder__' var CLONE_DEEP_FLAG2 = 1, CLONE_FLAT_FLAG2 = 2, CLONE_SYMBOLS_FLAG2 = 4 var COMPARE_PARTIAL_FLAG2 = 1, COMPARE_UNORDERED_FLAG2 = 2 var WRAP_BIND_FLAG = 1, WRAP_BIND_KEY_FLAG = 2, WRAP_CURRY_BOUND_FLAG = 4, WRAP_CURRY_FLAG = 8, WRAP_CURRY_RIGHT_FLAG = 16, WRAP_PARTIAL_FLAG = 32, WRAP_PARTIAL_RIGHT_FLAG = 64, WRAP_ARY_FLAG = 128, WRAP_REARG_FLAG = 256, WRAP_FLIP_FLAG = 512 var DEFAULT_TRUNC_LENGTH = 30, DEFAULT_TRUNC_OMISSION = '...' var HOT_COUNT2 = 800, HOT_SPAN2 = 16 var LAZY_FILTER_FLAG = 1, LAZY_MAP_FLAG = 2, LAZY_WHILE_FLAG = 3 var INFINITY2 = 1 / 0, MAX_SAFE_INTEGER2 = 9007199254740991, MAX_INTEGER = 17976931348623157e292, NAN2 = 0 / 0 var MAX_ARRAY_LENGTH = 4294967295, MAX_ARRAY_INDEX = MAX_ARRAY_LENGTH - 1, HALF_MAX_ARRAY_LENGTH = MAX_ARRAY_LENGTH >>> 1 var wrapFlags = [ ['ary', WRAP_ARY_FLAG], ['bind', WRAP_BIND_FLAG], ['bindKey', WRAP_BIND_KEY_FLAG], ['curry', WRAP_CURRY_FLAG], ['curryRight', WRAP_CURRY_RIGHT_FLAG], ['flip', WRAP_FLIP_FLAG], ['partial', WRAP_PARTIAL_FLAG], ['partialRight', WRAP_PARTIAL_RIGHT_FLAG], ['rearg', WRAP_REARG_FLAG], ] var argsTag2 = '[object Arguments]', arrayTag2 = '[object Array]', asyncTag2 = '[object AsyncFunction]', boolTag2 = '[object Boolean]', dateTag2 = '[object Date]', domExcTag = '[object DOMException]', errorTag2 = '[object Error]', funcTag2 = '[object Function]', genTag2 = '[object GeneratorFunction]', mapTag2 = '[object Map]', numberTag2 = '[object Number]', nullTag2 = '[object Null]', objectTag2 = '[object Object]', promiseTag2 = '[object Promise]', proxyTag2 = '[object Proxy]', regexpTag2 = '[object RegExp]', setTag2 = '[object Set]', stringTag2 = '[object String]', symbolTag2 = '[object Symbol]', undefinedTag2 = '[object Undefined]', weakMapTag2 = '[object WeakMap]', weakSetTag = '[object WeakSet]' var arrayBufferTag2 = '[object ArrayBuffer]', dataViewTag2 = '[object DataView]', float32Tag2 = '[object Float32Array]', float64Tag2 = '[object Float64Array]', int8Tag2 = '[object Int8Array]', int16Tag2 = '[object Int16Array]', int32Tag2 = '[object Int32Array]', uint8Tag2 = '[object Uint8Array]', uint8ClampedTag2 = '[object Uint8ClampedArray]', uint16Tag2 = '[object Uint16Array]', uint32Tag2 = '[object Uint32Array]' var reEmptyStringLeading = /\b__p \+= '';/g, reEmptyStringMiddle = /\b(__p \+=) '' \+/g, reEmptyStringTrailing = /(__e\(.*?\)|\b__t\)) \+\n'';/g var reEscapedHtml = /&(?:amp|lt|gt|quot|#39);/g, reUnescapedHtml = /[&<>"']/g, reHasEscapedHtml = RegExp(reEscapedHtml.source), reHasUnescapedHtml = RegExp(reUnescapedHtml.source) var reEscape = /<%-([\s\S]+?)%>/g, reEvaluate = /<%([\s\S]+?)%>/g, reInterpolate = /<%=([\s\S]+?)%>/g var reIsDeepProp2 = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, reIsPlainProp2 = /^\w*$/, rePropName2 = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g var reRegExpChar2 = /[\\^$.*+?()[\]{}|]/g, reHasRegExpChar = RegExp(reRegExpChar2.source) var reTrimStart2 = /^\s+/ var reWhitespace2 = /\s/ var reWrapComment = /\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/, reWrapDetails = /\{\n\/\* \[wrapped with (.+)\] \*/, reSplitDetails = /,? & / var reAsciiWord = /[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g var reForbiddenIdentifierChars = /[()=,{}\[\]\/\s]/ var reEscapeChar2 = /\\(\\)?/g var reEsTemplate = /\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g var reFlags2 = /\w*$/ var reIsBadHex2 = /^[-+]0x[0-9a-f]+$/i var reIsBinary2 = /^0b[01]+$/i var reIsHostCtor2 = /^\[object .+?Constructor\]$/ var reIsOctal2 = /^0o[0-7]+$/i var reIsUint2 = /^(?:0|[1-9]\d*)$/ var reLatin = /[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g var reNoMatch = /($^)/ var reUnescapedString = /['\n\r\u2028\u2029\\]/g var rsAstralRange = '\\ud800-\\udfff', rsComboMarksRange = '\\u0300-\\u036f', reComboHalfMarksRange = '\\ufe20-\\ufe2f', rsComboSymbolsRange = '\\u20d0-\\u20ff', rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange, rsDingbatRange = '\\u2700-\\u27bf', rsLowerRange = 'a-z\\xdf-\\xf6\\xf8-\\xff', rsMathOpRange = '\\xac\\xb1\\xd7\\xf7', rsNonCharRange = '\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf', rsPunctuationRange = '\\u2000-\\u206f', rsSpaceRange = ' \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000', rsUpperRange = 'A-Z\\xc0-\\xd6\\xd8-\\xde', rsVarRange = '\\ufe0e\\ufe0f', rsBreakRange = rsMathOpRange + rsNonCharRange + rsPunctuationRange + rsSpaceRange var rsApos = "['\u2019]", rsAstral = '[' + rsAstralRange + ']', rsBreak = '[' + rsBreakRange + ']', rsCombo = '[' + rsComboRange + ']', rsDigits = '\\d+', rsDingbat = '[' + rsDingbatRange + ']', rsLower = '[' + rsLowerRange + ']', rsMisc = '[^' + rsAstralRange + rsBreakRange + rsDigits + rsDingbatRange + rsLowerRange + rsUpperRange + ']', rsFitz = '\\ud83c[\\udffb-\\udfff]', rsModifier = '(?:' + rsCombo + '|' + rsFitz + ')', rsNonAstral = '[^' + rsAstralRange + ']', rsRegional = '(?:\\ud83c[\\udde6-\\uddff]){2}', rsSurrPair = '[\\ud800-\\udbff][\\udc00-\\udfff]', rsUpper = '[' + rsUpperRange + ']', rsZWJ = '\\u200d' var rsMiscLower = '(?:' + rsLower + '|' + rsMisc + ')', rsMiscUpper = '(?:' + rsUpper + '|' + rsMisc + ')', rsOptContrLower = '(?:' + rsApos + '(?:d|ll|m|re|s|t|ve))?', rsOptContrUpper = '(?:' + rsApos + '(?:D|LL|M|RE|S|T|VE))?', reOptMod = rsModifier + '?', rsOptVar = '[' + rsVarRange + ']?', rsOptJoin = '(?:' + rsZWJ + '(?:' + [rsNonAstral, rsRegional, rsSurrPair].join('|') + ')' + rsOptVar + reOptMod + ')*', rsOrdLower = '\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])', rsOrdUpper = '\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])', rsSeq = rsOptVar + reOptMod + rsOptJoin, rsEmoji = '(?:' + [rsDingbat, rsRegional, rsSurrPair].join('|') + ')' + rsSeq, rsSymbol = '(?:' + [ rsNonAstral + rsCombo + '?', rsCombo, rsRegional, rsSurrPair, rsAstral, ].join('|') + ')' var reApos = RegExp(rsApos, 'g') var reComboMark = RegExp(rsCombo, 'g') var reUnicode = RegExp( rsFitz + '(?=' + rsFitz + ')|' + rsSymbol + rsSeq, 'g' ) var reUnicodeWord = RegExp( [ rsUpper + '?' + rsLower + '+' + rsOptContrLower + '(?=' + [rsBreak, rsUpper, '$'].join('|') + ')', rsMiscUpper + '+' + rsOptContrUpper + '(?=' + [rsBreak, rsUpper + rsMiscLower, '$'].join('|') + ')', rsUpper + '?' + rsMiscLower + '+' + rsOptContrLower, rsUpper + '+' + rsOptContrUpper, rsOrdUpper, rsOrdLower, rsDigits, rsEmoji, ].join('|'), 'g' ) var reHasUnicode = RegExp( '[' + rsZWJ + rsAstralRange + rsComboRange + rsVarRange + ']' ) var reHasUnicodeWord = /[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/ var contextProps = [ 'Array', 'Buffer', 'DataView', 'Date', 'Error', 'Float32Array', 'Float64Array', 'Function', 'Int8Array', 'Int16Array', 'Int32Array', 'Map', 'Math', 'Object', 'Promise', 'RegExp', 'Set', 'String', 'Symbol', 'TypeError', 'Uint8Array', 'Uint8ClampedArray', 'Uint16Array', 'Uint32Array', 'WeakMap', '_', 'clearTimeout', 'isFinite', 'parseInt', 'setTimeout', ] var templateCounter = -1 var typedArrayTags2 = {} typedArrayTags2[float32Tag2] = typedArrayTags2[float64Tag2] = typedArrayTags2[int8Tag2] = typedArrayTags2[int16Tag2] = typedArrayTags2[int32Tag2] = typedArrayTags2[uint8Tag2] = typedArrayTags2[uint8ClampedTag2] = typedArrayTags2[uint16Tag2] = typedArrayTags2[uint32Tag2] = true typedArrayTags2[argsTag2] = typedArrayTags2[arrayTag2] = typedArrayTags2[arrayBufferTag2] = typedArrayTags2[boolTag2] = typedArrayTags2[dataViewTag2] = typedArrayTags2[dateTag2] = typedArrayTags2[errorTag2] = typedArrayTags2[funcTag2] = typedArrayTags2[mapTag2] = typedArrayTags2[numberTag2] = typedArrayTags2[objectTag2] = typedArrayTags2[regexpTag2] = typedArrayTags2[setTag2] = typedArrayTags2[stringTag2] = typedArrayTags2[weakMapTag2] = false var cloneableTags2 = {} cloneableTags2[argsTag2] = cloneableTags2[arrayTag2] = cloneableTags2[arrayBufferTag2] = cloneableTags2[dataViewTag2] = cloneableTags2[boolTag2] = cloneableTags2[dateTag2] = cloneableTags2[float32Tag2] = cloneableTags2[float64Tag2] = cloneableTags2[int8Tag2] = cloneableTags2[int16Tag2] = cloneableTags2[int32Tag2] = cloneableTags2[mapTag2] = cloneableTags2[numberTag2] = cloneableTags2[objectTag2] = cloneableTags2[regexpTag2] = cloneableTags2[setTag2] = cloneableTags2[stringTag2] = cloneableTags2[symbolTag2] = cloneableTags2[uint8Tag2] = cloneableTags2[uint8ClampedTag2] = cloneableTags2[uint16Tag2] = cloneableTags2[uint32Tag2] = true cloneableTags2[errorTag2] = cloneableTags2[funcTag2] = cloneableTags2[weakMapTag2] = false var deburredLetters = { '\xC0': 'A', '\xC1': 'A', '\xC2': 'A', '\xC3': 'A', '\xC4': 'A', '\xC5': 'A', '\xE0': 'a', '\xE1': 'a', '\xE2': 'a', '\xE3': 'a', '\xE4': 'a', '\xE5': 'a', '\xC7': 'C', '\xE7': 'c', '\xD0': 'D', '\xF0': 'd', '\xC8': 'E', '\xC9': 'E', '\xCA': 'E', '\xCB': 'E', '\xE8': 'e', '\xE9': 'e', '\xEA': 'e', '\xEB': 'e', '\xCC': 'I', '\xCD': 'I', '\xCE': 'I', '\xCF': 'I', '\xEC': 'i', '\xED': 'i', '\xEE': 'i', '\xEF': 'i', '\xD1': 'N', '\xF1': 'n', '\xD2': 'O', '\xD3': 'O', '\xD4': 'O', '\xD5': 'O', '\xD6': 'O', '\xD8': 'O', '\xF2': 'o', '\xF3': 'o', '\xF4': 'o', '\xF5': 'o', '\xF6': 'o', '\xF8': 'o', '\xD9': 'U', '\xDA': 'U', '\xDB': 'U', '\xDC': 'U', '\xF9': 'u', '\xFA': 'u', '\xFB': 'u', '\xFC': 'u', '\xDD': 'Y', '\xFD': 'y', '\xFF': 'y', '\xC6': 'Ae', '\xE6': 'ae', '\xDE': 'Th', '\xFE': 'th', '\xDF': 'ss', '\u0100': 'A', '\u0102': 'A', '\u0104': 'A', '\u0101': 'a', '\u0103': 'a', '\u0105': 'a', '\u0106': 'C', '\u0108': 'C', '\u010A': 'C', '\u010C': 'C', '\u0107': 'c', '\u0109': 'c', '\u010B': 'c', '\u010D': 'c', '\u010E': 'D', '\u0110': 'D', '\u010F': 'd', '\u0111': 'd', '\u0112': 'E', '\u0114': 'E', '\u0116': 'E', '\u0118': 'E', '\u011A': 'E', '\u0113': 'e', '\u0115': 'e', '\u0117': 'e', '\u0119': 'e', '\u011B': 'e', '\u011C': 'G', '\u011E': 'G', '\u0120': 'G', '\u0122': 'G', '\u011D': 'g', '\u011F': 'g', '\u0121': 'g', '\u0123': 'g', '\u0124': 'H', '\u0126': 'H', '\u0125': 'h', '\u0127': 'h', '\u0128': 'I', '\u012A': 'I', '\u012C': 'I', '\u012E': 'I', '\u0130': 'I', '\u0129': 'i', '\u012B': 'i', '\u012D': 'i', '\u012F': 'i', '\u0131': 'i', '\u0134': 'J', '\u0135': 'j', '\u0136': 'K', '\u0137': 'k', '\u0138': 'k', '\u0139': 'L', '\u013B': 'L', '\u013D': 'L', '\u013F': 'L', '\u0141': 'L', '\u013A': 'l', '\u013C': 'l', '\u013E': 'l', '\u0140': 'l', '\u0142': 'l', '\u0143': 'N', '\u0145': 'N', '\u0147': 'N', '\u014A': 'N', '\u0144': 'n', '\u0146': 'n', '\u0148': 'n', '\u014B': 'n', '\u014C': 'O', '\u014E': 'O', '\u0150': 'O', '\u014D': 'o', '\u014F': 'o', '\u0151': 'o', '\u0154': 'R', '\u0156': 'R', '\u0158': 'R', '\u0155': 'r', '\u0157': 'r', '\u0159': 'r', '\u015A': 'S', '\u015C': 'S', '\u015E': 'S', '\u0160': 'S', '\u015B': 's', '\u015D': 's', '\u015F': 's', '\u0161': 's', '\u0162': 'T', '\u0164': 'T', '\u0166': 'T', '\u0163': 't', '\u0165': 't', '\u0167': 't', '\u0168': 'U', '\u016A': 'U', '\u016C': 'U', '\u016E': 'U', '\u0170': 'U', '\u0172': 'U', '\u0169': 'u', '\u016B': 'u', '\u016D': 'u', '\u016F': 'u', '\u0171': 'u', '\u0173': 'u', '\u0174': 'W', '\u0175': 'w', '\u0176': 'Y', '\u0177': 'y', '\u0178': 'Y', '\u0179': 'Z', '\u017B': 'Z', '\u017D': 'Z', '\u017A': 'z', '\u017C': 'z', '\u017E': 'z', '\u0132': 'IJ', '\u0133': 'ij', '\u0152': 'Oe', '\u0153': 'oe', '\u0149': "'n", '\u017F': 's', } var htmlEscapes = { '&': '&', '<': '<', '>': '>', '"': '"', "'": ''', } var htmlUnescapes = { '&': '&', '<': '<', '>': '>', '"': '"', ''': "'", } var stringEscapes = { '\\': '\\', "'": "'", '\n': 'n', '\r': 'r', '\u2028': 'u2028', '\u2029': 'u2029', } var freeParseFloat = parseFloat, freeParseInt2 = parseInt var freeGlobal2 = typeof commonjsGlobal == 'object' && commonjsGlobal && commonjsGlobal.Object === Object && commonjsGlobal var freeSelf2 = typeof self == 'object' && self && self.Object === Object && self var root2 = freeGlobal2 || freeSelf2 || Function('return this')() var freeExports2 = exports2 && !exports2.nodeType && exports2 var freeModule2 = freeExports2 && true && module2 && !module2.nodeType && module2 var moduleExports2 = freeModule2 && freeModule2.exports === freeExports2 var freeProcess2 = moduleExports2 && freeGlobal2.process var nodeUtil2 = (function () { try { var types2 = freeModule2 && freeModule2.require && freeModule2.require('util').types if (types2) { return types2 } return ( freeProcess2 && freeProcess2.binding && freeProcess2.binding('util') ) } catch (e2) {} })() var nodeIsArrayBuffer = nodeUtil2 && nodeUtil2.isArrayBuffer, nodeIsDate = nodeUtil2 && nodeUtil2.isDate, nodeIsMap2 = nodeUtil2 && nodeUtil2.isMap, nodeIsRegExp = nodeUtil2 && nodeUtil2.isRegExp, nodeIsSet2 = nodeUtil2 && nodeUtil2.isSet, nodeIsTypedArray2 = nodeUtil2 && nodeUtil2.isTypedArray function apply2(func, thisArg, args) { switch (args.length) { case 0: return func.call(thisArg) case 1: return func.call(thisArg, args[0]) case 2: return func.call(thisArg, args[0], args[1]) case 3: return func.call(thisArg, args[0], args[1], args[2]) } return func.apply(thisArg, args) } function arrayAggregator(array4, setter, iteratee, accumulator) { var index2 = -1, length2 = array4 == null ? 0 : array4.length while (++index2 < length2) { var value2 = array4[index2] setter(accumulator, value2, iteratee(value2), array4) } return accumulator } function arrayEach2(array4, iteratee) { var index2 = -1, length2 = array4 == null ? 0 : array4.length while (++index2 < length2) { if (iteratee(array4[index2], index2, array4) === false) { break } } return array4 } function arrayEachRight(array4, iteratee) { var length2 = array4 == null ? 0 : array4.length while (length2--) { if (iteratee(array4[length2], length2, array4) === false) { break } } return array4 } function arrayEvery(array4, predicate) { var index2 = -1, length2 = array4 == null ? 0 : array4.length while (++index2 < length2) { if (!predicate(array4[index2], index2, array4)) { return false } } return true } function arrayFilter2(array4, predicate) { var index2 = -1, length2 = array4 == null ? 0 : array4.length, resIndex = 0, result = [] while (++index2 < length2) { var value2 = array4[index2] if (predicate(value2, index2, array4)) { result[resIndex++] = value2 } } return result } function arrayIncludes2(array4, value2) { var length2 = array4 == null ? 0 : array4.length return !!length2 && baseIndexOf2(array4, value2, 0) > -1 } function arrayIncludesWith2(array4, value2, comparator) { var index2 = -1, length2 = array4 == null ? 0 : array4.length while (++index2 < length2) { if (comparator(value2, array4[index2])) { return true } } return false } function arrayMap2(array4, iteratee) { var index2 = -1, length2 = array4 == null ? 0 : array4.length, result = Array(length2) while (++index2 < length2) { result[index2] = iteratee(array4[index2], index2, array4) } return result } function arrayPush2(array4, values2) { var index2 = -1, length2 = values2.length, offset2 = array4.length while (++index2 < length2) { array4[offset2 + index2] = values2[index2] } return array4 } function arrayReduce2(array4, iteratee, accumulator, initAccum) { var index2 = -1, length2 = array4 == null ? 0 : array4.length if (initAccum && length2) { accumulator = array4[++index2] } while (++index2 < length2) { accumulator = iteratee(accumulator, array4[index2], index2, array4) } return accumulator } function arrayReduceRight(array4, iteratee, accumulator, initAccum) { var length2 = array4 == null ? 0 : array4.length if (initAccum && length2) { accumulator = array4[--length2] } while (length2--) { accumulator = iteratee(accumulator, array4[length2], length2, array4) } return accumulator } function arraySome2(array4, predicate) { var index2 = -1, length2 = array4 == null ? 0 : array4.length while (++index2 < length2) { if (predicate(array4[index2], index2, array4)) { return true } } return false } var asciiSize = baseProperty('length') function asciiToArray(string3) { return string3.split('') } function asciiWords(string3) { return string3.match(reAsciiWord) || [] } function baseFindKey(collection2, predicate, eachFunc) { var result eachFunc(collection2, function (value2, key2, collection3) { if (predicate(value2, key2, collection3)) { result = key2 return false } }) return result } function baseFindIndex2(array4, predicate, fromIndex, fromRight) { var length2 = array4.length, index2 = fromIndex + (fromRight ? 1 : -1) while (fromRight ? index2-- : ++index2 < length2) { if (predicate(array4[index2], index2, array4)) { return index2 } } return -1 } function baseIndexOf2(array4, value2, fromIndex) { return value2 === value2 ? strictIndexOf2(array4, value2, fromIndex) : baseFindIndex2(array4, baseIsNaN2, fromIndex) } function baseIndexOfWith(array4, value2, fromIndex, comparator) { var index2 = fromIndex - 1, length2 = array4.length while (++index2 < length2) { if (comparator(array4[index2], value2)) { return index2 } } return -1 } function baseIsNaN2(value2) { return value2 !== value2 } function baseMean(array4, iteratee) { var length2 = array4 == null ? 0 : array4.length return length2 ? baseSum(array4, iteratee) / length2 : NAN2 } function baseProperty(key2) { return function (object4) { return object4 == null ? undefined$1 : object4[key2] } } function basePropertyOf(object4) { return function (key2) { return object4 == null ? undefined$1 : object4[key2] } } function baseReduce( collection2, iteratee, accumulator, initAccum, eachFunc ) { eachFunc(collection2, function (value2, index2, collection3) { accumulator = initAccum ? ((initAccum = false), value2) : iteratee(accumulator, value2, index2, collection3) }) return accumulator } function baseSortBy(array4, comparer) { var length2 = array4.length array4.sort(comparer) while (length2--) { array4[length2] = array4[length2].value } return array4 } function baseSum(array4, iteratee) { var result, index2 = -1, length2 = array4.length while (++index2 < length2) { var current2 = iteratee(array4[index2]) if (current2 !== undefined$1) { result = result === undefined$1 ? current2 : result + current2 } } return result } function baseTimes2(n2, iteratee) { var index2 = -1, result = Array(n2) while (++index2 < n2) { result[index2] = iteratee(index2) } return result } function baseToPairs(object4, props2) { return arrayMap2(props2, function (key2) { return [key2, object4[key2]] }) } function baseTrim2(string3) { return string3 ? string3 .slice(0, trimmedEndIndex2(string3) + 1) .replace(reTrimStart2, '') : string3 } function baseUnary2(func) { return function (value2) { return func(value2) } } function baseValues(object4, props2) { return arrayMap2(props2, function (key2) { return object4[key2] }) } function cacheHas2(cache2, key2) { return cache2.has(key2) } function charsStartIndex(strSymbols, chrSymbols) { var index2 = -1, length2 = strSymbols.length while ( ++index2 < length2 && baseIndexOf2(chrSymbols, strSymbols[index2], 0) > -1 ) {} return index2 } function charsEndIndex(strSymbols, chrSymbols) { var index2 = strSymbols.length while ( index2-- && baseIndexOf2(chrSymbols, strSymbols[index2], 0) > -1 ) {} return index2 } function countHolders(array4, placeholder) { var length2 = array4.length, result = 0 while (length2--) { if (array4[length2] === placeholder) { ++result } } return result } var deburrLetter = basePropertyOf(deburredLetters) var escapeHtmlChar = basePropertyOf(htmlEscapes) function escapeStringChar(chr) { return '\\' + stringEscapes[chr] } function getValue2(object4, key2) { return object4 == null ? undefined$1 : object4[key2] } function hasUnicode(string3) { return reHasUnicode.test(string3) } function hasUnicodeWord(string3) { return reHasUnicodeWord.test(string3) } function iteratorToArray(iterator2) { var data2, result = [] while (!(data2 = iterator2.next()).done) { result.push(data2.value) } return result } function mapToArray2(map2) { var index2 = -1, result = Array(map2.size) map2.forEach(function (value2, key2) { result[++index2] = [key2, value2] }) return result } function overArg2(func, transform3) { return function (arg) { return func(transform3(arg)) } } function replaceHolders(array4, placeholder) { var index2 = -1, length2 = array4.length, resIndex = 0, result = [] while (++index2 < length2) { var value2 = array4[index2] if (value2 === placeholder || value2 === PLACEHOLDER) { array4[index2] = PLACEHOLDER result[resIndex++] = index2 } } return result } function setToArray2(set2) { var index2 = -1, result = Array(set2.size) set2.forEach(function (value2) { result[++index2] = value2 }) return result } function setToPairs(set2) { var index2 = -1, result = Array(set2.size) set2.forEach(function (value2) { result[++index2] = [value2, value2] }) return result } function strictIndexOf2(array4, value2, fromIndex) { var index2 = fromIndex - 1, length2 = array4.length while (++index2 < length2) { if (array4[index2] === value2) { return index2 } } return -1 } function strictLastIndexOf(array4, value2, fromIndex) { var index2 = fromIndex + 1 while (index2--) { if (array4[index2] === value2) { return index2 } } return index2 } function stringSize(string3) { return hasUnicode(string3) ? unicodeSize(string3) : asciiSize(string3) } function stringToArray(string3) { return hasUnicode(string3) ? unicodeToArray(string3) : asciiToArray(string3) } function trimmedEndIndex2(string3) { var index2 = string3.length while (index2-- && reWhitespace2.test(string3.charAt(index2))) {} return index2 } var unescapeHtmlChar = basePropertyOf(htmlUnescapes) function unicodeSize(string3) { var result = (reUnicode.lastIndex = 0) while (reUnicode.test(string3)) { ++result } return result } function unicodeToArray(string3) { return string3.match(reUnicode) || [] } function unicodeWords(string3) { return string3.match(reUnicodeWord) || [] } var runInContext = function runInContext2(context2) { context2 = context2 == null ? root2 : _2.defaults(root2.Object(), context2, _2.pick(root2, contextProps)) var Array2 = context2.Array, Date2 = context2.Date, Error2 = context2.Error, Function2 = context2.Function, Math2 = context2.Math, Object2 = context2.Object, RegExp2 = context2.RegExp, String2 = context2.String, TypeError2 = context2.TypeError var arrayProto2 = Array2.prototype, funcProto2 = Function2.prototype, objectProto2 = Object2.prototype var coreJsData2 = context2['__core-js_shared__'] var funcToString2 = funcProto2.toString var hasOwnProperty2 = objectProto2.hasOwnProperty var idCounter = 0 var maskSrcKey2 = (function () { var uid2 = /[^.]+$/.exec( (coreJsData2 && coreJsData2.keys && coreJsData2.keys.IE_PROTO) || '' ) return uid2 ? 'Symbol(src)_1.' + uid2 : '' })() var nativeObjectToString2 = objectProto2.toString var objectCtorString = funcToString2.call(Object2) var oldDash = root2._ var reIsNative2 = RegExp2( '^' + funcToString2 .call(hasOwnProperty2) .replace(reRegExpChar2, '\\$&') .replace( /hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, '$1.*?' ) + '$' ) var Buffer2 = moduleExports2 ? context2.Buffer : undefined$1, Symbol2 = context2.Symbol, Uint8Array2 = context2.Uint8Array, allocUnsafe2 = Buffer2 ? Buffer2.allocUnsafe : undefined$1, getPrototype2 = overArg2(Object2.getPrototypeOf, Object2), objectCreate2 = Object2.create, propertyIsEnumerable3 = objectProto2.propertyIsEnumerable, splice2 = arrayProto2.splice, spreadableSymbol2 = Symbol2 ? Symbol2.isConcatSpreadable : undefined$1, symIterator = Symbol2 ? Symbol2.iterator : undefined$1, symToStringTag2 = Symbol2 ? Symbol2.toStringTag : undefined$1 var defineProperty4 = (function () { try { var func = getNative2(Object2, 'defineProperty') func({}, '', {}) return func } catch (e2) {} })() var ctxClearTimeout = context2.clearTimeout !== root2.clearTimeout && context2.clearTimeout, ctxNow = Date2 && Date2.now !== root2.Date.now && Date2.now, ctxSetTimeout = context2.setTimeout !== root2.setTimeout && context2.setTimeout var nativeCeil = Math2.ceil, nativeFloor = Math2.floor, nativeGetSymbols2 = Object2.getOwnPropertySymbols, nativeIsBuffer2 = Buffer2 ? Buffer2.isBuffer : undefined$1, nativeIsFinite = context2.isFinite, nativeJoin = arrayProto2.join, nativeKeys2 = overArg2(Object2.keys, Object2), nativeMax2 = Math2.max, nativeMin2 = Math2.min, nativeNow2 = Date2.now, nativeParseInt = context2.parseInt, nativeRandom = Math2.random, nativeReverse2 = arrayProto2.reverse var DataView2 = getNative2(context2, 'DataView'), Map2 = getNative2(context2, 'Map'), Promise2 = getNative2(context2, 'Promise'), Set2 = getNative2(context2, 'Set'), WeakMap2 = getNative2(context2, 'WeakMap'), nativeCreate2 = getNative2(Object2, 'create') var metaMap = WeakMap2 && new WeakMap2() var realNames = {} var dataViewCtorString2 = toSource2(DataView2), mapCtorString2 = toSource2(Map2), promiseCtorString2 = toSource2(Promise2), setCtorString2 = toSource2(Set2), weakMapCtorString2 = toSource2(WeakMap2) var symbolProto2 = Symbol2 ? Symbol2.prototype : undefined$1, symbolValueOf2 = symbolProto2 ? symbolProto2.valueOf : undefined$1, symbolToString2 = symbolProto2 ? symbolProto2.toString : undefined$1 function lodash2(value2) { if ( isObjectLike2(value2) && !isArray3(value2) && !(value2 instanceof LazyWrapper) ) { if (value2 instanceof LodashWrapper) { return value2 } if (hasOwnProperty2.call(value2, '__wrapped__')) { return wrapperClone(value2) } } return new LodashWrapper(value2) } var baseCreate2 = (function () { function object4() {} return function (proto2) { if (!isObject2(proto2)) { return {} } if (objectCreate2) { return objectCreate2(proto2) } object4.prototype = proto2 var result2 = new object4() object4.prototype = undefined$1 return result2 } })() function baseLodash() {} function LodashWrapper(value2, chainAll) { this.__wrapped__ = value2 this.__actions__ = [] this.__chain__ = !!chainAll this.__index__ = 0 this.__values__ = undefined$1 } lodash2.templateSettings = { escape: reEscape, evaluate: reEvaluate, interpolate: reInterpolate, variable: '', imports: { _: lodash2, }, } lodash2.prototype = baseLodash.prototype lodash2.prototype.constructor = lodash2 LodashWrapper.prototype = baseCreate2(baseLodash.prototype) LodashWrapper.prototype.constructor = LodashWrapper function LazyWrapper(value2) { this.__wrapped__ = value2 this.__actions__ = [] this.__dir__ = 1 this.__filtered__ = false this.__iteratees__ = [] this.__takeCount__ = MAX_ARRAY_LENGTH this.__views__ = [] } function lazyClone() { var result2 = new LazyWrapper(this.__wrapped__) result2.__actions__ = copyArray2(this.__actions__) result2.__dir__ = this.__dir__ result2.__filtered__ = this.__filtered__ result2.__iteratees__ = copyArray2(this.__iteratees__) result2.__takeCount__ = this.__takeCount__ result2.__views__ = copyArray2(this.__views__) return result2 } function lazyReverse() { if (this.__filtered__) { var result2 = new LazyWrapper(this) result2.__dir__ = -1 result2.__filtered__ = true } else { result2 = this.clone() result2.__dir__ *= -1 } return result2 } function lazyValue() { var array4 = this.__wrapped__.value(), dir3 = this.__dir__, isArr = isArray3(array4), isRight = dir3 < 0, arrLength = isArr ? array4.length : 0, view2 = getView(0, arrLength, this.__views__), start2 = view2.start, end2 = view2.end, length2 = end2 - start2, index2 = isRight ? end2 : start2 - 1, iteratees = this.__iteratees__, iterLength = iteratees.length, resIndex = 0, takeCount = nativeMin2(length2, this.__takeCount__) if ( !isArr || (!isRight && arrLength == length2 && takeCount == length2) ) { return baseWrapperValue(array4, this.__actions__) } var result2 = [] outer: while (length2-- && resIndex < takeCount) { index2 += dir3 var iterIndex = -1, value2 = array4[index2] while (++iterIndex < iterLength) { var data2 = iteratees[iterIndex], iteratee2 = data2.iteratee, type4 = data2.type, computed2 = iteratee2(value2) if (type4 == LAZY_MAP_FLAG) { value2 = computed2 } else if (!computed2) { if (type4 == LAZY_FILTER_FLAG) { continue outer } else { break outer } } } result2[resIndex++] = value2 } return result2 } LazyWrapper.prototype = baseCreate2(baseLodash.prototype) LazyWrapper.prototype.constructor = LazyWrapper function Hash2(entries2) { var index2 = -1, length2 = entries2 == null ? 0 : entries2.length this.clear() while (++index2 < length2) { var entry = entries2[index2] this.set(entry[0], entry[1]) } } function hashClear2() { this.__data__ = nativeCreate2 ? nativeCreate2(null) : {} this.size = 0 } function hashDelete2(key2) { var result2 = this.has(key2) && delete this.__data__[key2] this.size -= result2 ? 1 : 0 return result2 } function hashGet2(key2) { var data2 = this.__data__ if (nativeCreate2) { var result2 = data2[key2] return result2 === HASH_UNDEFINED2 ? undefined$1 : result2 } return hasOwnProperty2.call(data2, key2) ? data2[key2] : undefined$1 } function hashHas2(key2) { var data2 = this.__data__ return nativeCreate2 ? data2[key2] !== undefined$1 : hasOwnProperty2.call(data2, key2) } function hashSet2(key2, value2) { var data2 = this.__data__ this.size += this.has(key2) ? 0 : 1 data2[key2] = nativeCreate2 && value2 === undefined$1 ? HASH_UNDEFINED2 : value2 return this } Hash2.prototype.clear = hashClear2 Hash2.prototype['delete'] = hashDelete2 Hash2.prototype.get = hashGet2 Hash2.prototype.has = hashHas2 Hash2.prototype.set = hashSet2 function ListCache2(entries2) { var index2 = -1, length2 = entries2 == null ? 0 : entries2.length this.clear() while (++index2 < length2) { var entry = entries2[index2] this.set(entry[0], entry[1]) } } function listCacheClear2() { this.__data__ = [] this.size = 0 } function listCacheDelete2(key2) { var data2 = this.__data__, index2 = assocIndexOf2(data2, key2) if (index2 < 0) { return false } var lastIndex = data2.length - 1 if (index2 == lastIndex) { data2.pop() } else { splice2.call(data2, index2, 1) } --this.size return true } function listCacheGet2(key2) { var data2 = this.__data__, index2 = assocIndexOf2(data2, key2) return index2 < 0 ? undefined$1 : data2[index2][1] } function listCacheHas2(key2) { return assocIndexOf2(this.__data__, key2) > -1 } function listCacheSet2(key2, value2) { var data2 = this.__data__, index2 = assocIndexOf2(data2, key2) if (index2 < 0) { ++this.size data2.push([key2, value2]) } else { data2[index2][1] = value2 } return this } ListCache2.prototype.clear = listCacheClear2 ListCache2.prototype['delete'] = listCacheDelete2 ListCache2.prototype.get = listCacheGet2 ListCache2.prototype.has = listCacheHas2 ListCache2.prototype.set = listCacheSet2 function MapCache2(entries2) { var index2 = -1, length2 = entries2 == null ? 0 : entries2.length this.clear() while (++index2 < length2) { var entry = entries2[index2] this.set(entry[0], entry[1]) } } function mapCacheClear2() { this.size = 0 this.__data__ = { hash: new Hash2(), map: new (Map2 || ListCache2)(), string: new Hash2(), } } function mapCacheDelete2(key2) { var result2 = getMapData2(this, key2)['delete'](key2) this.size -= result2 ? 1 : 0 return result2 } function mapCacheGet2(key2) { return getMapData2(this, key2).get(key2) } function mapCacheHas2(key2) { return getMapData2(this, key2).has(key2) } function mapCacheSet2(key2, value2) { var data2 = getMapData2(this, key2), size2 = data2.size data2.set(key2, value2) this.size += data2.size == size2 ? 0 : 1 return this } MapCache2.prototype.clear = mapCacheClear2 MapCache2.prototype['delete'] = mapCacheDelete2 MapCache2.prototype.get = mapCacheGet2 MapCache2.prototype.has = mapCacheHas2 MapCache2.prototype.set = mapCacheSet2 function SetCache2(values3) { var index2 = -1, length2 = values3 == null ? 0 : values3.length this.__data__ = new MapCache2() while (++index2 < length2) { this.add(values3[index2]) } } function setCacheAdd2(value2) { this.__data__.set(value2, HASH_UNDEFINED2) return this } function setCacheHas2(value2) { return this.__data__.has(value2) } SetCache2.prototype.add = SetCache2.prototype.push = setCacheAdd2 SetCache2.prototype.has = setCacheHas2 function Stack2(entries2) { var data2 = (this.__data__ = new ListCache2(entries2)) this.size = data2.size } function stackClear2() { this.__data__ = new ListCache2() this.size = 0 } function stackDelete2(key2) { var data2 = this.__data__, result2 = data2['delete'](key2) this.size = data2.size return result2 } function stackGet2(key2) { return this.__data__.get(key2) } function stackHas2(key2) { return this.__data__.has(key2) } function stackSet2(key2, value2) { var data2 = this.__data__ if (data2 instanceof ListCache2) { var pairs = data2.__data__ if (!Map2 || pairs.length < LARGE_ARRAY_SIZE2 - 1) { pairs.push([key2, value2]) this.size = ++data2.size return this } data2 = this.__data__ = new MapCache2(pairs) } data2.set(key2, value2) this.size = data2.size return this } Stack2.prototype.clear = stackClear2 Stack2.prototype['delete'] = stackDelete2 Stack2.prototype.get = stackGet2 Stack2.prototype.has = stackHas2 Stack2.prototype.set = stackSet2 function arrayLikeKeys2(value2, inherited) { var isArr = isArray3(value2), isArg = !isArr && isArguments2(value2), isBuff = !isArr && !isArg && isBuffer2(value2), isType = !isArr && !isArg && !isBuff && isTypedArray2(value2), skipIndexes = isArr || isArg || isBuff || isType, result2 = skipIndexes ? baseTimes2(value2.length, String2) : [], length2 = result2.length for (var key2 in value2) { if ( (inherited || hasOwnProperty2.call(value2, key2)) && !( skipIndexes && (key2 == 'length' || (isBuff && (key2 == 'offset' || key2 == 'parent')) || (isType && (key2 == 'buffer' || key2 == 'byteLength' || key2 == 'byteOffset')) || isIndex2(key2, length2)) ) ) { result2.push(key2) } } return result2 } function arraySample(array4) { var length2 = array4.length return length2 ? array4[baseRandom(0, length2 - 1)] : undefined$1 } function arraySampleSize(array4, n2) { return shuffleSelf(copyArray2(array4), baseClamp(n2, 0, array4.length)) } function arrayShuffle(array4) { return shuffleSelf(copyArray2(array4)) } function assignMergeValue(object4, key2, value2) { if ( (value2 !== undefined$1 && !eq2(object4[key2], value2)) || (value2 === undefined$1 && !(key2 in object4)) ) { baseAssignValue2(object4, key2, value2) } } function assignValue2(object4, key2, value2) { var objValue = object4[key2] if ( !(hasOwnProperty2.call(object4, key2) && eq2(objValue, value2)) || (value2 === undefined$1 && !(key2 in object4)) ) { baseAssignValue2(object4, key2, value2) } } function assocIndexOf2(array4, key2) { var length2 = array4.length while (length2--) { if (eq2(array4[length2][0], key2)) { return length2 } } return -1 } function baseAggregator(collection2, setter, iteratee2, accumulator) { baseEach(collection2, function (value2, key2, collection3) { setter(accumulator, value2, iteratee2(value2), collection3) }) return accumulator } function baseAssign2(object4, source2) { return object4 && copyObject2(source2, keys3(source2), object4) } function baseAssignIn2(object4, source2) { return object4 && copyObject2(source2, keysIn2(source2), object4) } function baseAssignValue2(object4, key2, value2) { if (key2 == '__proto__' && defineProperty4) { defineProperty4(object4, key2, { configurable: true, enumerable: true, value: value2, writable: true, }) } else { object4[key2] = value2 } } function baseAt(object4, paths) { var index2 = -1, length2 = paths.length, result2 = Array2(length2), skip = object4 == null while (++index2 < length2) { result2[index2] = skip ? undefined$1 : get3(object4, paths[index2]) } return result2 } function baseClamp(number4, lower, upper) { if (number4 === number4) { if (upper !== undefined$1) { number4 = number4 <= upper ? number4 : upper } if (lower !== undefined$1) { number4 = number4 >= lower ? number4 : lower } } return number4 } function baseClone2(value2, bitmask, customizer, key2, object4, stack) { var result2, isDeep = bitmask & CLONE_DEEP_FLAG2, isFlat = bitmask & CLONE_FLAT_FLAG2, isFull = bitmask & CLONE_SYMBOLS_FLAG2 if (customizer) { result2 = object4 ? customizer(value2, key2, object4, stack) : customizer(value2) } if (result2 !== undefined$1) { return result2 } if (!isObject2(value2)) { return value2 } var isArr = isArray3(value2) if (isArr) { result2 = initCloneArray2(value2) if (!isDeep) { return copyArray2(value2, result2) } } else { var tag = getTag2(value2), isFunc = tag == funcTag2 || tag == genTag2 if (isBuffer2(value2)) { return cloneBuffer2(value2, isDeep) } if (tag == objectTag2 || tag == argsTag2 || (isFunc && !object4)) { result2 = isFlat || isFunc ? {} : initCloneObject2(value2) if (!isDeep) { return isFlat ? copySymbolsIn2(value2, baseAssignIn2(result2, value2)) : copySymbols2(value2, baseAssign2(result2, value2)) } } else { if (!cloneableTags2[tag]) { return object4 ? value2 : {} } result2 = initCloneByTag2(value2, tag, isDeep) } } stack || (stack = new Stack2()) var stacked = stack.get(value2) if (stacked) { return stacked } stack.set(value2, result2) if (isSet2(value2)) { value2.forEach(function (subValue) { result2.add( baseClone2(subValue, bitmask, customizer, subValue, value2, stack) ) }) } else if (isMap2(value2)) { value2.forEach(function (subValue, key3) { result2.set( key3, baseClone2(subValue, bitmask, customizer, key3, value2, stack) ) }) } var keysFunc = isFull ? isFlat ? getAllKeysIn2 : getAllKeys2 : isFlat ? keysIn2 : keys3 var props2 = isArr ? undefined$1 : keysFunc(value2) arrayEach2(props2 || value2, function (subValue, key3) { if (props2) { key3 = subValue subValue = value2[key3] } assignValue2( result2, key3, baseClone2(subValue, bitmask, customizer, key3, value2, stack) ) }) return result2 } function baseConforms(source2) { var props2 = keys3(source2) return function (object4) { return baseConformsTo(object4, source2, props2) } } function baseConformsTo(object4, source2, props2) { var length2 = props2.length if (object4 == null) { return !length2 } object4 = Object2(object4) while (length2--) { var key2 = props2[length2], predicate = source2[key2], value2 = object4[key2] if ( (value2 === undefined$1 && !(key2 in object4)) || !predicate(value2) ) { return false } } return true } function baseDelay(func, wait, args) { if (typeof func != 'function') { throw new TypeError2(FUNC_ERROR_TEXT2) } return setTimeout2(function () { func.apply(undefined$1, args) }, wait) } function baseDifference(array4, values3, iteratee2, comparator) { var index2 = -1, includes4 = arrayIncludes2, isCommon = true, length2 = array4.length, result2 = [], valuesLength = values3.length if (!length2) { return result2 } if (iteratee2) { values3 = arrayMap2(values3, baseUnary2(iteratee2)) } if (comparator) { includes4 = arrayIncludesWith2 isCommon = false } else if (values3.length >= LARGE_ARRAY_SIZE2) { includes4 = cacheHas2 isCommon = false values3 = new SetCache2(values3) } outer: while (++index2 < length2) { var value2 = array4[index2], computed2 = iteratee2 == null ? value2 : iteratee2(value2) value2 = comparator || value2 !== 0 ? value2 : 0 if (isCommon && computed2 === computed2) { var valuesIndex = valuesLength while (valuesIndex--) { if (values3[valuesIndex] === computed2) { continue outer } } result2.push(value2) } else if (!includes4(values3, computed2, comparator)) { result2.push(value2) } } return result2 } var baseEach = createBaseEach(baseForOwn) var baseEachRight = createBaseEach(baseForOwnRight, true) function baseEvery(collection2, predicate) { var result2 = true baseEach(collection2, function (value2, index2, collection3) { result2 = !!predicate(value2, index2, collection3) return result2 }) return result2 } function baseExtremum(array4, iteratee2, comparator) { var index2 = -1, length2 = array4.length while (++index2 < length2) { var value2 = array4[index2], current2 = iteratee2(value2) if ( current2 != null && (computed2 === undefined$1 ? current2 === current2 && !isSymbol2(current2) : comparator(current2, computed2)) ) { var computed2 = current2, result2 = value2 } } return result2 } function baseFill(array4, value2, start2, end2) { var length2 = array4.length start2 = toInteger2(start2) if (start2 < 0) { start2 = -start2 > length2 ? 0 : length2 + start2 } end2 = end2 === undefined$1 || end2 > length2 ? length2 : toInteger2(end2) if (end2 < 0) { end2 += length2 } end2 = start2 > end2 ? 0 : toLength2(end2) while (start2 < end2) { array4[start2++] = value2 } return array4 } function baseFilter(collection2, predicate) { var result2 = [] baseEach(collection2, function (value2, index2, collection3) { if (predicate(value2, index2, collection3)) { result2.push(value2) } }) return result2 } function baseFlatten2(array4, depth, predicate, isStrict, result2) { var index2 = -1, length2 = array4.length predicate || (predicate = isFlattenable2) result2 || (result2 = []) while (++index2 < length2) { var value2 = array4[index2] if (depth > 0 && predicate(value2)) { if (depth > 1) { baseFlatten2(value2, depth - 1, predicate, isStrict, result2) } else { arrayPush2(result2, value2) } } else if (!isStrict) { result2[result2.length] = value2 } } return result2 } var baseFor = createBaseFor() var baseForRight = createBaseFor(true) function baseForOwn(object4, iteratee2) { return object4 && baseFor(object4, iteratee2, keys3) } function baseForOwnRight(object4, iteratee2) { return object4 && baseForRight(object4, iteratee2, keys3) } function baseFunctions(object4, props2) { return arrayFilter2(props2, function (key2) { return isFunction2(object4[key2]) }) } function baseGet2(object4, path) { path = castPath2(path, object4) var index2 = 0, length2 = path.length while (object4 != null && index2 < length2) { object4 = object4[toKey2(path[index2++])] } return index2 && index2 == length2 ? object4 : undefined$1 } function baseGetAllKeys2(object4, keysFunc, symbolsFunc) { var result2 = keysFunc(object4) return isArray3(object4) ? result2 : arrayPush2(result2, symbolsFunc(object4)) } function baseGetTag2(value2) { if (value2 == null) { return value2 === undefined$1 ? undefinedTag2 : nullTag2 } return symToStringTag2 && symToStringTag2 in Object2(value2) ? getRawTag2(value2) : objectToString2(value2) } function baseGt(value2, other) { return value2 > other } function baseHas(object4, key2) { return object4 != null && hasOwnProperty2.call(object4, key2) } function baseHasIn2(object4, key2) { return object4 != null && key2 in Object2(object4) } function baseInRange(number4, start2, end2) { return ( number4 >= nativeMin2(start2, end2) && number4 < nativeMax2(start2, end2) ) } function baseIntersection(arrays, iteratee2, comparator) { var includes4 = comparator ? arrayIncludesWith2 : arrayIncludes2, length2 = arrays[0].length, othLength = arrays.length, othIndex = othLength, caches = Array2(othLength), maxLength = Infinity, result2 = [] while (othIndex--) { var array4 = arrays[othIndex] if (othIndex && iteratee2) { array4 = arrayMap2(array4, baseUnary2(iteratee2)) } maxLength = nativeMin2(array4.length, maxLength) caches[othIndex] = !comparator && (iteratee2 || (length2 >= 120 && array4.length >= 120)) ? new SetCache2(othIndex && array4) : undefined$1 } array4 = arrays[0] var index2 = -1, seen = caches[0] outer: while (++index2 < length2 && result2.length < maxLength) { var value2 = array4[index2], computed2 = iteratee2 ? iteratee2(value2) : value2 value2 = comparator || value2 !== 0 ? value2 : 0 if ( !(seen ? cacheHas2(seen, computed2) : includes4(result2, computed2, comparator)) ) { othIndex = othLength while (--othIndex) { var cache2 = caches[othIndex] if ( !(cache2 ? cacheHas2(cache2, computed2) : includes4(arrays[othIndex], computed2, comparator)) ) { continue outer } } if (seen) { seen.push(computed2) } result2.push(value2) } } return result2 } function baseInverter(object4, setter, iteratee2, accumulator) { baseForOwn(object4, function (value2, key2, object5) { setter(accumulator, iteratee2(value2), key2, object5) }) return accumulator } function baseInvoke(object4, path, args) { path = castPath2(path, object4) object4 = parent2(object4, path) var func = object4 == null ? object4 : object4[toKey2(last2(path))] return func == null ? undefined$1 : apply2(func, object4, args) } function baseIsArguments2(value2) { return isObjectLike2(value2) && baseGetTag2(value2) == argsTag2 } function baseIsArrayBuffer(value2) { return isObjectLike2(value2) && baseGetTag2(value2) == arrayBufferTag2 } function baseIsDate(value2) { return isObjectLike2(value2) && baseGetTag2(value2) == dateTag2 } function baseIsEqual2(value2, other, bitmask, customizer, stack) { if (value2 === other) { return true } if ( value2 == null || other == null || (!isObjectLike2(value2) && !isObjectLike2(other)) ) { return value2 !== value2 && other !== other } return baseIsEqualDeep2( value2, other, bitmask, customizer, baseIsEqual2, stack ) } function baseIsEqualDeep2( object4, other, bitmask, customizer, equalFunc, stack ) { var objIsArr = isArray3(object4), othIsArr = isArray3(other), objTag = objIsArr ? arrayTag2 : getTag2(object4), othTag = othIsArr ? arrayTag2 : getTag2(other) objTag = objTag == argsTag2 ? objectTag2 : objTag othTag = othTag == argsTag2 ? objectTag2 : othTag var objIsObj = objTag == objectTag2, othIsObj = othTag == objectTag2, isSameTag = objTag == othTag if (isSameTag && isBuffer2(object4)) { if (!isBuffer2(other)) { return false } objIsArr = true objIsObj = false } if (isSameTag && !objIsObj) { stack || (stack = new Stack2()) return objIsArr || isTypedArray2(object4) ? equalArrays2( object4, other, bitmask, customizer, equalFunc, stack ) : equalByTag2( object4, other, objTag, bitmask, customizer, equalFunc, stack ) } if (!(bitmask & COMPARE_PARTIAL_FLAG2)) { var objIsWrapped = objIsObj && hasOwnProperty2.call(object4, '__wrapped__'), othIsWrapped = othIsObj && hasOwnProperty2.call(other, '__wrapped__') if (objIsWrapped || othIsWrapped) { var objUnwrapped = objIsWrapped ? object4.value() : object4, othUnwrapped = othIsWrapped ? other.value() : other stack || (stack = new Stack2()) return equalFunc( objUnwrapped, othUnwrapped, bitmask, customizer, stack ) } } if (!isSameTag) { return false } stack || (stack = new Stack2()) return equalObjects2( object4, other, bitmask, customizer, equalFunc, stack ) } function baseIsMap2(value2) { return isObjectLike2(value2) && getTag2(value2) == mapTag2 } function baseIsMatch(object4, source2, matchData, customizer) { var index2 = matchData.length, length2 = index2, noCustomizer = !customizer if (object4 == null) { return !length2 } object4 = Object2(object4) while (index2--) { var data2 = matchData[index2] if ( noCustomizer && data2[2] ? data2[1] !== object4[data2[0]] : !(data2[0] in object4) ) { return false } } while (++index2 < length2) { data2 = matchData[index2] var key2 = data2[0], objValue = object4[key2], srcValue = data2[1] if (noCustomizer && data2[2]) { if (objValue === undefined$1 && !(key2 in object4)) { return false } } else { var stack = new Stack2() if (customizer) { var result2 = customizer( objValue, srcValue, key2, object4, source2, stack ) } if ( !(result2 === undefined$1 ? baseIsEqual2( srcValue, objValue, COMPARE_PARTIAL_FLAG2 | COMPARE_UNORDERED_FLAG2, customizer, stack ) : result2) ) { return false } } } return true } function baseIsNative2(value2) { if (!isObject2(value2) || isMasked2(value2)) { return false } var pattern4 = isFunction2(value2) ? reIsNative2 : reIsHostCtor2 return pattern4.test(toSource2(value2)) } function baseIsRegExp(value2) { return isObjectLike2(value2) && baseGetTag2(value2) == regexpTag2 } function baseIsSet2(value2) { return isObjectLike2(value2) && getTag2(value2) == setTag2 } function baseIsTypedArray2(value2) { return ( isObjectLike2(value2) && isLength2(value2.length) && !!typedArrayTags2[baseGetTag2(value2)] ) } function baseIteratee(value2) { if (typeof value2 == 'function') { return value2 } if (value2 == null) { return identity2 } if (typeof value2 == 'object') { return isArray3(value2) ? baseMatchesProperty(value2[0], value2[1]) : baseMatches(value2) } return property2(value2) } function baseKeys2(object4) { if (!isPrototype2(object4)) { return nativeKeys2(object4) } var result2 = [] for (var key2 in Object2(object4)) { if (hasOwnProperty2.call(object4, key2) && key2 != 'constructor') { result2.push(key2) } } return result2 } function baseKeysIn2(object4) { if (!isObject2(object4)) { return nativeKeysIn2(object4) } var isProto = isPrototype2(object4), result2 = [] for (var key2 in object4) { if ( !( key2 == 'constructor' && (isProto || !hasOwnProperty2.call(object4, key2)) ) ) { result2.push(key2) } } return result2 } function baseLt(value2, other) { return value2 < other } function baseMap(collection2, iteratee2) { var index2 = -1, result2 = isArrayLike2(collection2) ? Array2(collection2.length) : [] baseEach(collection2, function (value2, key2, collection3) { result2[++index2] = iteratee2(value2, key2, collection3) }) return result2 } function baseMatches(source2) { var matchData = getMatchData(source2) if (matchData.length == 1 && matchData[0][2]) { return matchesStrictComparable(matchData[0][0], matchData[0][1]) } return function (object4) { return object4 === source2 || baseIsMatch(object4, source2, matchData) } } function baseMatchesProperty(path, srcValue) { if (isKey2(path) && isStrictComparable(srcValue)) { return matchesStrictComparable(toKey2(path), srcValue) } return function (object4) { var objValue = get3(object4, path) return objValue === undefined$1 && objValue === srcValue ? hasIn2(object4, path) : baseIsEqual2( srcValue, objValue, COMPARE_PARTIAL_FLAG2 | COMPARE_UNORDERED_FLAG2 ) } } function baseMerge(object4, source2, srcIndex, customizer, stack) { if (object4 === source2) { return } baseFor( source2, function (srcValue, key2) { stack || (stack = new Stack2()) if (isObject2(srcValue)) { baseMergeDeep( object4, source2, key2, srcIndex, baseMerge, customizer, stack ) } else { var newValue = customizer ? customizer( safeGet(object4, key2), srcValue, key2 + '', object4, source2, stack ) : undefined$1 if (newValue === undefined$1) { newValue = srcValue } assignMergeValue(object4, key2, newValue) } }, keysIn2 ) } function baseMergeDeep( object4, source2, key2, srcIndex, mergeFunc, customizer, stack ) { var objValue = safeGet(object4, key2), srcValue = safeGet(source2, key2), stacked = stack.get(srcValue) if (stacked) { assignMergeValue(object4, key2, stacked) return } var newValue = customizer ? customizer(objValue, srcValue, key2 + '', object4, source2, stack) : undefined$1 var isCommon = newValue === undefined$1 if (isCommon) { var isArr = isArray3(srcValue), isBuff = !isArr && isBuffer2(srcValue), isTyped = !isArr && !isBuff && isTypedArray2(srcValue) newValue = srcValue if (isArr || isBuff || isTyped) { if (isArray3(objValue)) { newValue = objValue } else if (isArrayLikeObject2(objValue)) { newValue = copyArray2(objValue) } else if (isBuff) { isCommon = false newValue = cloneBuffer2(srcValue, true) } else if (isTyped) { isCommon = false newValue = cloneTypedArray2(srcValue, true) } else { newValue = [] } } else if (isPlainObject2(srcValue) || isArguments2(srcValue)) { newValue = objValue if (isArguments2(objValue)) { newValue = toPlainObject(objValue) } else if (!isObject2(objValue) || isFunction2(objValue)) { newValue = initCloneObject2(srcValue) } } else { isCommon = false } } if (isCommon) { stack.set(srcValue, newValue) mergeFunc(newValue, srcValue, srcIndex, customizer, stack) stack['delete'](srcValue) } assignMergeValue(object4, key2, newValue) } function baseNth(array4, n2) { var length2 = array4.length if (!length2) { return } n2 += n2 < 0 ? length2 : 0 return isIndex2(n2, length2) ? array4[n2] : undefined$1 } function baseOrderBy(collection2, iteratees, orders) { if (iteratees.length) { iteratees = arrayMap2(iteratees, function (iteratee2) { if (isArray3(iteratee2)) { return function (value2) { return baseGet2( value2, iteratee2.length === 1 ? iteratee2[0] : iteratee2 ) } } return iteratee2 }) } else { iteratees = [identity2] } var index2 = -1 iteratees = arrayMap2(iteratees, baseUnary2(getIteratee())) var result2 = baseMap( collection2, function (value2, key2, collection3) { var criteria = arrayMap2(iteratees, function (iteratee2) { return iteratee2(value2) }) return { criteria: criteria, index: ++index2, value: value2 } } ) return baseSortBy(result2, function (object4, other) { return compareMultiple(object4, other, orders) }) } function basePick2(object4, paths) { return basePickBy2(object4, paths, function (value2, path) { return hasIn2(object4, path) }) } function basePickBy2(object4, paths, predicate) { var index2 = -1, length2 = paths.length, result2 = {} while (++index2 < length2) { var path = paths[index2], value2 = baseGet2(object4, path) if (predicate(value2, path)) { baseSet2(result2, castPath2(path, object4), value2) } } return result2 } function basePropertyDeep(path) { return function (object4) { return baseGet2(object4, path) } } function basePullAll(array4, values3, iteratee2, comparator) { var indexOf4 = comparator ? baseIndexOfWith : baseIndexOf2, index2 = -1, length2 = values3.length, seen = array4 if (array4 === values3) { values3 = copyArray2(values3) } if (iteratee2) { seen = arrayMap2(array4, baseUnary2(iteratee2)) } while (++index2 < length2) { var fromIndex = 0, value2 = values3[index2], computed2 = iteratee2 ? iteratee2(value2) : value2 while ( (fromIndex = indexOf4(seen, computed2, fromIndex, comparator)) > -1 ) { if (seen !== array4) { splice2.call(seen, fromIndex, 1) } splice2.call(array4, fromIndex, 1) } } return array4 } function basePullAt(array4, indexes) { var length2 = array4 ? indexes.length : 0, lastIndex = length2 - 1 while (length2--) { var index2 = indexes[length2] if (length2 == lastIndex || index2 !== previous) { var previous = index2 if (isIndex2(index2)) { splice2.call(array4, index2, 1) } else { baseUnset(array4, index2) } } } return array4 } function baseRandom(lower, upper) { return lower + nativeFloor(nativeRandom() * (upper - lower + 1)) } function baseRange(start2, end2, step, fromRight) { var index2 = -1, length2 = nativeMax2(nativeCeil((end2 - start2) / (step || 1)), 0), result2 = Array2(length2) while (length2--) { result2[fromRight ? length2 : ++index2] = start2 start2 += step } return result2 } function baseRepeat(string3, n2) { var result2 = '' if (!string3 || n2 < 1 || n2 > MAX_SAFE_INTEGER2) { return result2 } do { if (n2 % 2) { result2 += string3 } n2 = nativeFloor(n2 / 2) if (n2) { string3 += string3 } } while (n2) return result2 } function baseRest2(func, start2) { return setToString2(overRest2(func, start2, identity2), func + '') } function baseSample(collection2) { return arraySample(values2(collection2)) } function baseSampleSize(collection2, n2) { var array4 = values2(collection2) return shuffleSelf(array4, baseClamp(n2, 0, array4.length)) } function baseSet2(object4, path, value2, customizer) { if (!isObject2(object4)) { return object4 } path = castPath2(path, object4) var index2 = -1, length2 = path.length, lastIndex = length2 - 1, nested = object4 while (nested != null && ++index2 < length2) { var key2 = toKey2(path[index2]), newValue = value2 if ( key2 === '__proto__' || key2 === 'constructor' || key2 === 'prototype' ) { return object4 } if (index2 != lastIndex) { var objValue = nested[key2] newValue = customizer ? customizer(objValue, key2, nested) : undefined$1 if (newValue === undefined$1) { newValue = isObject2(objValue) ? objValue : isIndex2(path[index2 + 1]) ? [] : {} } } assignValue2(nested, key2, newValue) nested = nested[key2] } return object4 } var baseSetData = !metaMap ? identity2 : function (func, data2) { metaMap.set(func, data2) return func } var baseSetToString2 = !defineProperty4 ? identity2 : function (func, string3) { return defineProperty4(func, 'toString', { configurable: true, enumerable: false, value: constant2(string3), writable: true, }) } function baseShuffle(collection2) { return shuffleSelf(values2(collection2)) } function baseSlice(array4, start2, end2) { var index2 = -1, length2 = array4.length if (start2 < 0) { start2 = -start2 > length2 ? 0 : length2 + start2 } end2 = end2 > length2 ? length2 : end2 if (end2 < 0) { end2 += length2 } length2 = start2 > end2 ? 0 : (end2 - start2) >>> 0 start2 >>>= 0 var result2 = Array2(length2) while (++index2 < length2) { result2[index2] = array4[index2 + start2] } return result2 } function baseSome(collection2, predicate) { var result2 baseEach(collection2, function (value2, index2, collection3) { result2 = predicate(value2, index2, collection3) return !result2 }) return !!result2 } function baseSortedIndex(array4, value2, retHighest) { var low = 0, high = array4 == null ? low : array4.length if ( typeof value2 == 'number' && value2 === value2 && high <= HALF_MAX_ARRAY_LENGTH ) { while (low < high) { var mid = (low + high) >>> 1, computed2 = array4[mid] if ( computed2 !== null && !isSymbol2(computed2) && (retHighest ? computed2 <= value2 : computed2 < value2) ) { low = mid + 1 } else { high = mid } } return high } return baseSortedIndexBy(array4, value2, identity2, retHighest) } function baseSortedIndexBy(array4, value2, iteratee2, retHighest) { var low = 0, high = array4 == null ? 0 : array4.length if (high === 0) { return 0 } value2 = iteratee2(value2) var valIsNaN = value2 !== value2, valIsNull = value2 === null, valIsSymbol = isSymbol2(value2), valIsUndefined = value2 === undefined$1 while (low < high) { var mid = nativeFloor((low + high) / 2), computed2 = iteratee2(array4[mid]), othIsDefined = computed2 !== undefined$1, othIsNull = computed2 === null, othIsReflexive = computed2 === computed2, othIsSymbol = isSymbol2(computed2) if (valIsNaN) { var setLow = retHighest || othIsReflexive } else if (valIsUndefined) { setLow = othIsReflexive && (retHighest || othIsDefined) } else if (valIsNull) { setLow = othIsReflexive && othIsDefined && (retHighest || !othIsNull) } else if (valIsSymbol) { setLow = othIsReflexive && othIsDefined && !othIsNull && (retHighest || !othIsSymbol) } else if (othIsNull || othIsSymbol) { setLow = false } else { setLow = retHighest ? computed2 <= value2 : computed2 < value2 } if (setLow) { low = mid + 1 } else { high = mid } } return nativeMin2(high, MAX_ARRAY_INDEX) } function baseSortedUniq(array4, iteratee2) { var index2 = -1, length2 = array4.length, resIndex = 0, result2 = [] while (++index2 < length2) { var value2 = array4[index2], computed2 = iteratee2 ? iteratee2(value2) : value2 if (!index2 || !eq2(computed2, seen)) { var seen = computed2 result2[resIndex++] = value2 === 0 ? 0 : value2 } } return result2 } function baseToNumber(value2) { if (typeof value2 == 'number') { return value2 } if (isSymbol2(value2)) { return NAN2 } return +value2 } function baseToString2(value2) { if (typeof value2 == 'string') { return value2 } if (isArray3(value2)) { return arrayMap2(value2, baseToString2) + '' } if (isSymbol2(value2)) { return symbolToString2 ? symbolToString2.call(value2) : '' } var result2 = value2 + '' return result2 == '0' && 1 / value2 == -INFINITY2 ? '-0' : result2 } function baseUniq2(array4, iteratee2, comparator) { var index2 = -1, includes4 = arrayIncludes2, length2 = array4.length, isCommon = true, result2 = [], seen = result2 if (comparator) { isCommon = false includes4 = arrayIncludesWith2 } else if (length2 >= LARGE_ARRAY_SIZE2) { var set3 = iteratee2 ? null : createSet2(array4) if (set3) { return setToArray2(set3) } isCommon = false includes4 = cacheHas2 seen = new SetCache2() } else { seen = iteratee2 ? [] : result2 } outer: while (++index2 < length2) { var value2 = array4[index2], computed2 = iteratee2 ? iteratee2(value2) : value2 value2 = comparator || value2 !== 0 ? value2 : 0 if (isCommon && computed2 === computed2) { var seenIndex = seen.length while (seenIndex--) { if (seen[seenIndex] === computed2) { continue outer } } if (iteratee2) { seen.push(computed2) } result2.push(value2) } else if (!includes4(seen, computed2, comparator)) { if (seen !== result2) { seen.push(computed2) } result2.push(value2) } } return result2 } function baseUnset(object4, path) { path = castPath2(path, object4) object4 = parent2(object4, path) return object4 == null || delete object4[toKey2(last2(path))] } function baseUpdate(object4, path, updater, customizer) { return baseSet2( object4, path, updater(baseGet2(object4, path)), customizer ) } function baseWhile(array4, predicate, isDrop, fromRight) { var length2 = array4.length, index2 = fromRight ? length2 : -1 while ( (fromRight ? index2-- : ++index2 < length2) && predicate(array4[index2], index2, array4) ) {} return isDrop ? baseSlice( array4, fromRight ? 0 : index2, fromRight ? index2 + 1 : length2 ) : baseSlice( array4, fromRight ? index2 + 1 : 0, fromRight ? length2 : index2 ) } function baseWrapperValue(value2, actions2) { var result2 = value2 if (result2 instanceof LazyWrapper) { result2 = result2.value() } return arrayReduce2( actions2, function (result3, action) { return action.func.apply( action.thisArg, arrayPush2([result3], action.args) ) }, result2 ) } function baseXor(arrays, iteratee2, comparator) { var length2 = arrays.length if (length2 < 2) { return length2 ? baseUniq2(arrays[0]) : [] } var index2 = -1, result2 = Array2(length2) while (++index2 < length2) { var array4 = arrays[index2], othIndex = -1 while (++othIndex < length2) { if (othIndex != index2) { result2[index2] = baseDifference( result2[index2] || array4, arrays[othIndex], iteratee2, comparator ) } } } return baseUniq2(baseFlatten2(result2, 1), iteratee2, comparator) } function baseZipObject(props2, values3, assignFunc) { var index2 = -1, length2 = props2.length, valsLength = values3.length, result2 = {} while (++index2 < length2) { var value2 = index2 < valsLength ? values3[index2] : undefined$1 assignFunc(result2, props2[index2], value2) } return result2 } function castArrayLikeObject(value2) { return isArrayLikeObject2(value2) ? value2 : [] } function castFunction(value2) { return typeof value2 == 'function' ? value2 : identity2 } function castPath2(value2, object4) { if (isArray3(value2)) { return value2 } return isKey2(value2, object4) ? [value2] : stringToPath2(toString4(value2)) } var castRest = baseRest2 function castSlice(array4, start2, end2) { var length2 = array4.length end2 = end2 === undefined$1 ? length2 : end2 return !start2 && end2 >= length2 ? array4 : baseSlice(array4, start2, end2) } var clearTimeout2 = ctxClearTimeout || function (id2) { return root2.clearTimeout(id2) } function cloneBuffer2(buffer, isDeep) { if (isDeep) { return buffer.slice() } var length2 = buffer.length, result2 = allocUnsafe2 ? allocUnsafe2(length2) : new buffer.constructor(length2) buffer.copy(result2) return result2 } function cloneArrayBuffer2(arrayBuffer) { var result2 = new arrayBuffer.constructor(arrayBuffer.byteLength) new Uint8Array2(result2).set(new Uint8Array2(arrayBuffer)) return result2 } function cloneDataView2(dataView, isDeep) { var buffer = isDeep ? cloneArrayBuffer2(dataView.buffer) : dataView.buffer return new dataView.constructor( buffer, dataView.byteOffset, dataView.byteLength ) } function cloneRegExp2(regexp4) { var result2 = new regexp4.constructor( regexp4.source, reFlags2.exec(regexp4) ) result2.lastIndex = regexp4.lastIndex return result2 } function cloneSymbol2(symbol) { return symbolValueOf2 ? Object2(symbolValueOf2.call(symbol)) : {} } function cloneTypedArray2(typedArray, isDeep) { var buffer = isDeep ? cloneArrayBuffer2(typedArray.buffer) : typedArray.buffer return new typedArray.constructor( buffer, typedArray.byteOffset, typedArray.length ) } function compareAscending(value2, other) { if (value2 !== other) { var valIsDefined = value2 !== undefined$1, valIsNull = value2 === null, valIsReflexive = value2 === value2, valIsSymbol = isSymbol2(value2) var othIsDefined = other !== undefined$1, othIsNull = other === null, othIsReflexive = other === other, othIsSymbol = isSymbol2(other) if ( (!othIsNull && !othIsSymbol && !valIsSymbol && value2 > other) || (valIsSymbol && othIsDefined && othIsReflexive && !othIsNull && !othIsSymbol) || (valIsNull && othIsDefined && othIsReflexive) || (!valIsDefined && othIsReflexive) || !valIsReflexive ) { return 1 } if ( (!valIsNull && !valIsSymbol && !othIsSymbol && value2 < other) || (othIsSymbol && valIsDefined && valIsReflexive && !valIsNull && !valIsSymbol) || (othIsNull && valIsDefined && valIsReflexive) || (!othIsDefined && valIsReflexive) || !othIsReflexive ) { return -1 } } return 0 } function compareMultiple(object4, other, orders) { var index2 = -1, objCriteria = object4.criteria, othCriteria = other.criteria, length2 = objCriteria.length, ordersLength = orders.length while (++index2 < length2) { var result2 = compareAscending( objCriteria[index2], othCriteria[index2] ) if (result2) { if (index2 >= ordersLength) { return result2 } var order2 = orders[index2] return result2 * (order2 == 'desc' ? -1 : 1) } } return object4.index - other.index } function composeArgs(args, partials, holders, isCurried) { var argsIndex = -1, argsLength = args.length, holdersLength = holders.length, leftIndex = -1, leftLength = partials.length, rangeLength = nativeMax2(argsLength - holdersLength, 0), result2 = Array2(leftLength + rangeLength), isUncurried = !isCurried while (++leftIndex < leftLength) { result2[leftIndex] = partials[leftIndex] } while (++argsIndex < holdersLength) { if (isUncurried || argsIndex < argsLength) { result2[holders[argsIndex]] = args[argsIndex] } } while (rangeLength--) { result2[leftIndex++] = args[argsIndex++] } return result2 } function composeArgsRight(args, partials, holders, isCurried) { var argsIndex = -1, argsLength = args.length, holdersIndex = -1, holdersLength = holders.length, rightIndex = -1, rightLength = partials.length, rangeLength = nativeMax2(argsLength - holdersLength, 0), result2 = Array2(rangeLength + rightLength), isUncurried = !isCurried while (++argsIndex < rangeLength) { result2[argsIndex] = args[argsIndex] } var offset2 = argsIndex while (++rightIndex < rightLength) { result2[offset2 + rightIndex] = partials[rightIndex] } while (++holdersIndex < holdersLength) { if (isUncurried || argsIndex < argsLength) { result2[offset2 + holders[holdersIndex]] = args[argsIndex++] } } return result2 } function copyArray2(source2, array4) { var index2 = -1, length2 = source2.length array4 || (array4 = Array2(length2)) while (++index2 < length2) { array4[index2] = source2[index2] } return array4 } function copyObject2(source2, props2, object4, customizer) { var isNew = !object4 object4 || (object4 = {}) var index2 = -1, length2 = props2.length while (++index2 < length2) { var key2 = props2[index2] var newValue = customizer ? customizer(object4[key2], source2[key2], key2, object4, source2) : undefined$1 if (newValue === undefined$1) { newValue = source2[key2] } if (isNew) { baseAssignValue2(object4, key2, newValue) } else { assignValue2(object4, key2, newValue) } } return object4 } function copySymbols2(source2, object4) { return copyObject2(source2, getSymbols2(source2), object4) } function copySymbolsIn2(source2, object4) { return copyObject2(source2, getSymbolsIn2(source2), object4) } function createAggregator(setter, initializer) { return function (collection2, iteratee2) { var func = isArray3(collection2) ? arrayAggregator : baseAggregator, accumulator = initializer ? initializer() : {} return func( collection2, setter, getIteratee(iteratee2, 2), accumulator ) } } function createAssigner(assigner) { return baseRest2(function (object4, sources) { var index2 = -1, length2 = sources.length, customizer = length2 > 1 ? sources[length2 - 1] : undefined$1, guard = length2 > 2 ? sources[2] : undefined$1 customizer = assigner.length > 3 && typeof customizer == 'function' ? (length2--, customizer) : undefined$1 if (guard && isIterateeCall(sources[0], sources[1], guard)) { customizer = length2 < 3 ? undefined$1 : customizer length2 = 1 } object4 = Object2(object4) while (++index2 < length2) { var source2 = sources[index2] if (source2) { assigner(object4, source2, index2, customizer) } } return object4 }) } function createBaseEach(eachFunc, fromRight) { return function (collection2, iteratee2) { if (collection2 == null) { return collection2 } if (!isArrayLike2(collection2)) { return eachFunc(collection2, iteratee2) } var length2 = collection2.length, index2 = fromRight ? length2 : -1, iterable = Object2(collection2) while (fromRight ? index2-- : ++index2 < length2) { if (iteratee2(iterable[index2], index2, iterable) === false) { break } } return collection2 } } function createBaseFor(fromRight) { return function (object4, iteratee2, keysFunc) { var index2 = -1, iterable = Object2(object4), props2 = keysFunc(object4), length2 = props2.length while (length2--) { var key2 = props2[fromRight ? length2 : ++index2] if (iteratee2(iterable[key2], key2, iterable) === false) { break } } return object4 } } function createBind(func, bitmask, thisArg) { var isBind = bitmask & WRAP_BIND_FLAG, Ctor = createCtor(func) function wrapper() { var fn2 = this && this !== root2 && this instanceof wrapper ? Ctor : func return fn2.apply(isBind ? thisArg : this, arguments) } return wrapper } function createCaseFirst(methodName) { return function (string3) { string3 = toString4(string3) var strSymbols = hasUnicode(string3) ? stringToArray(string3) : undefined$1 var chr = strSymbols ? strSymbols[0] : string3.charAt(0) var trailing = strSymbols ? castSlice(strSymbols, 1).join('') : string3.slice(1) return chr[methodName]() + trailing } } function createCompounder(callback) { return function (string3) { return arrayReduce2( words(deburr(string3).replace(reApos, '')), callback, '' ) } } function createCtor(Ctor) { return function () { var args = arguments switch (args.length) { case 0: return new Ctor() case 1: return new Ctor(args[0]) case 2: return new Ctor(args[0], args[1]) case 3: return new Ctor(args[0], args[1], args[2]) case 4: return new Ctor(args[0], args[1], args[2], args[3]) case 5: return new Ctor(args[0], args[1], args[2], args[3], args[4]) case 6: return new Ctor( args[0], args[1], args[2], args[3], args[4], args[5] ) case 7: return new Ctor( args[0], args[1], args[2], args[3], args[4], args[5], args[6] ) } var thisBinding = baseCreate2(Ctor.prototype), result2 = Ctor.apply(thisBinding, args) return isObject2(result2) ? result2 : thisBinding } } function createCurry(func, bitmask, arity) { var Ctor = createCtor(func) function wrapper() { var length2 = arguments.length, args = Array2(length2), index2 = length2, placeholder = getHolder(wrapper) while (index2--) { args[index2] = arguments[index2] } var holders = length2 < 3 && args[0] !== placeholder && args[length2 - 1] !== placeholder ? [] : replaceHolders(args, placeholder) length2 -= holders.length if (length2 < arity) { return createRecurry( func, bitmask, createHybrid, wrapper.placeholder, undefined$1, args, holders, undefined$1, undefined$1, arity - length2 ) } var fn2 = this && this !== root2 && this instanceof wrapper ? Ctor : func return apply2(fn2, this, args) } return wrapper } function createFind(findIndexFunc) { return function (collection2, predicate, fromIndex) { var iterable = Object2(collection2) if (!isArrayLike2(collection2)) { var iteratee2 = getIteratee(predicate, 3) collection2 = keys3(collection2) predicate = function (key2) { return iteratee2(iterable[key2], key2, iterable) } } var index2 = findIndexFunc(collection2, predicate, fromIndex) return index2 > -1 ? iterable[iteratee2 ? collection2[index2] : index2] : undefined$1 } } function createFlow(fromRight) { return flatRest2(function (funcs) { var length2 = funcs.length, index2 = length2, prereq = LodashWrapper.prototype.thru if (fromRight) { funcs.reverse() } while (index2--) { var func = funcs[index2] if (typeof func != 'function') { throw new TypeError2(FUNC_ERROR_TEXT2) } if (prereq && !wrapper && getFuncName(func) == 'wrapper') { var wrapper = new LodashWrapper([], true) } } index2 = wrapper ? index2 : length2 while (++index2 < length2) { func = funcs[index2] var funcName = getFuncName(func), data2 = funcName == 'wrapper' ? getData(func) : undefined$1 if ( data2 && isLaziable(data2[0]) && data2[1] == (WRAP_ARY_FLAG | WRAP_CURRY_FLAG | WRAP_PARTIAL_FLAG | WRAP_REARG_FLAG) && !data2[4].length && data2[9] == 1 ) { wrapper = wrapper[getFuncName(data2[0])].apply(wrapper, data2[3]) } else { wrapper = func.length == 1 && isLaziable(func) ? wrapper[funcName]() : wrapper.thru(func) } } return function () { var args = arguments, value2 = args[0] if (wrapper && args.length == 1 && isArray3(value2)) { return wrapper.plant(value2).value() } var index3 = 0, result2 = length2 ? funcs[index3].apply(this, args) : value2 while (++index3 < length2) { result2 = funcs[index3].call(this, result2) } return result2 } }) } function createHybrid( func, bitmask, thisArg, partials, holders, partialsRight, holdersRight, argPos, ary2, arity ) { var isAry = bitmask & WRAP_ARY_FLAG, isBind = bitmask & WRAP_BIND_FLAG, isBindKey = bitmask & WRAP_BIND_KEY_FLAG, isCurried = bitmask & (WRAP_CURRY_FLAG | WRAP_CURRY_RIGHT_FLAG), isFlip = bitmask & WRAP_FLIP_FLAG, Ctor = isBindKey ? undefined$1 : createCtor(func) function wrapper() { var length2 = arguments.length, args = Array2(length2), index2 = length2 while (index2--) { args[index2] = arguments[index2] } if (isCurried) { var placeholder = getHolder(wrapper), holdersCount = countHolders(args, placeholder) } if (partials) { args = composeArgs(args, partials, holders, isCurried) } if (partialsRight) { args = composeArgsRight( args, partialsRight, holdersRight, isCurried ) } length2 -= holdersCount if (isCurried && length2 < arity) { var newHolders = replaceHolders(args, placeholder) return createRecurry( func, bitmask, createHybrid, wrapper.placeholder, thisArg, args, newHolders, argPos, ary2, arity - length2 ) } var thisBinding = isBind ? thisArg : this, fn2 = isBindKey ? thisBinding[func] : func length2 = args.length if (argPos) { args = reorder(args, argPos) } else if (isFlip && length2 > 1) { args.reverse() } if (isAry && ary2 < length2) { args.length = ary2 } if (this && this !== root2 && this instanceof wrapper) { fn2 = Ctor || createCtor(fn2) } return fn2.apply(thisBinding, args) } return wrapper } function createInverter(setter, toIteratee) { return function (object4, iteratee2) { return baseInverter(object4, setter, toIteratee(iteratee2), {}) } } function createMathOperation(operator, defaultValue) { return function (value2, other) { var result2 if (value2 === undefined$1 && other === undefined$1) { return defaultValue } if (value2 !== undefined$1) { result2 = value2 } if (other !== undefined$1) { if (result2 === undefined$1) { return other } if (typeof value2 == 'string' || typeof other == 'string') { value2 = baseToString2(value2) other = baseToString2(other) } else { value2 = baseToNumber(value2) other = baseToNumber(other) } result2 = operator(value2, other) } return result2 } } function createOver(arrayFunc) { return flatRest2(function (iteratees) { iteratees = arrayMap2(iteratees, baseUnary2(getIteratee())) return baseRest2(function (args) { var thisArg = this return arrayFunc(iteratees, function (iteratee2) { return apply2(iteratee2, thisArg, args) }) }) }) } function createPadding(length2, chars2) { chars2 = chars2 === undefined$1 ? ' ' : baseToString2(chars2) var charsLength = chars2.length if (charsLength < 2) { return charsLength ? baseRepeat(chars2, length2) : chars2 } var result2 = baseRepeat( chars2, nativeCeil(length2 / stringSize(chars2)) ) return hasUnicode(chars2) ? castSlice(stringToArray(result2), 0, length2).join('') : result2.slice(0, length2) } function createPartial(func, bitmask, thisArg, partials) { var isBind = bitmask & WRAP_BIND_FLAG, Ctor = createCtor(func) function wrapper() { var argsIndex = -1, argsLength = arguments.length, leftIndex = -1, leftLength = partials.length, args = Array2(leftLength + argsLength), fn2 = this && this !== root2 && this instanceof wrapper ? Ctor : func while (++leftIndex < leftLength) { args[leftIndex] = partials[leftIndex] } while (argsLength--) { args[leftIndex++] = arguments[++argsIndex] } return apply2(fn2, isBind ? thisArg : this, args) } return wrapper } function createRange2(fromRight) { return function (start2, end2, step) { if ( step && typeof step != 'number' && isIterateeCall(start2, end2, step) ) { end2 = step = undefined$1 } start2 = toFinite(start2) if (end2 === undefined$1) { end2 = start2 start2 = 0 } else { end2 = toFinite(end2) } step = step === undefined$1 ? (start2 < end2 ? 1 : -1) : toFinite(step) return baseRange(start2, end2, step, fromRight) } } function createRelationalOperation(operator) { return function (value2, other) { if (!(typeof value2 == 'string' && typeof other == 'string')) { value2 = toNumber2(value2) other = toNumber2(other) } return operator(value2, other) } } function createRecurry( func, bitmask, wrapFunc, placeholder, thisArg, partials, holders, argPos, ary2, arity ) { var isCurry = bitmask & WRAP_CURRY_FLAG, newHolders = isCurry ? holders : undefined$1, newHoldersRight = isCurry ? undefined$1 : holders, newPartials = isCurry ? partials : undefined$1, newPartialsRight = isCurry ? undefined$1 : partials bitmask |= isCurry ? WRAP_PARTIAL_FLAG : WRAP_PARTIAL_RIGHT_FLAG bitmask &= ~(isCurry ? WRAP_PARTIAL_RIGHT_FLAG : WRAP_PARTIAL_FLAG) if (!(bitmask & WRAP_CURRY_BOUND_FLAG)) { bitmask &= ~(WRAP_BIND_FLAG | WRAP_BIND_KEY_FLAG) } var newData = [ func, bitmask, thisArg, newPartials, newHolders, newPartialsRight, newHoldersRight, argPos, ary2, arity, ] var result2 = wrapFunc.apply(undefined$1, newData) if (isLaziable(func)) { setData(result2, newData) } result2.placeholder = placeholder return setWrapToString(result2, func, bitmask) } function createRound(methodName) { var func = Math2[methodName] return function (number4, precision) { number4 = toNumber2(number4) precision = precision == null ? 0 : nativeMin2(toInteger2(precision), 292) if (precision && nativeIsFinite(number4)) { var pair = (toString4(number4) + 'e').split('e'), value2 = func(pair[0] + 'e' + (+pair[1] + precision)) pair = (toString4(value2) + 'e').split('e') return +(pair[0] + 'e' + (+pair[1] - precision)) } return func(number4) } } var createSet2 = !( Set2 && 1 / setToArray2(new Set2([, -0]))[1] == INFINITY2 ) ? noop2 : function (values3) { return new Set2(values3) } function createToPairs(keysFunc) { return function (object4) { var tag = getTag2(object4) if (tag == mapTag2) { return mapToArray2(object4) } if (tag == setTag2) { return setToPairs(object4) } return baseToPairs(object4, keysFunc(object4)) } } function createWrap2( func, bitmask, thisArg, partials, holders, argPos, ary2, arity ) { var isBindKey = bitmask & WRAP_BIND_KEY_FLAG if (!isBindKey && typeof func != 'function') { throw new TypeError2(FUNC_ERROR_TEXT2) } var length2 = partials ? partials.length : 0 if (!length2) { bitmask &= ~(WRAP_PARTIAL_FLAG | WRAP_PARTIAL_RIGHT_FLAG) partials = holders = undefined$1 } ary2 = ary2 === undefined$1 ? ary2 : nativeMax2(toInteger2(ary2), 0) arity = arity === undefined$1 ? arity : toInteger2(arity) length2 -= holders ? holders.length : 0 if (bitmask & WRAP_PARTIAL_RIGHT_FLAG) { var partialsRight = partials, holdersRight = holders partials = holders = undefined$1 } var data2 = isBindKey ? undefined$1 : getData(func) var newData = [ func, bitmask, thisArg, partials, holders, partialsRight, holdersRight, argPos, ary2, arity, ] if (data2) { mergeData(newData, data2) } func = newData[0] bitmask = newData[1] thisArg = newData[2] partials = newData[3] holders = newData[4] arity = newData[9] = newData[9] === undefined$1 ? isBindKey ? 0 : func.length : nativeMax2(newData[9] - length2, 0) if (!arity && bitmask & (WRAP_CURRY_FLAG | WRAP_CURRY_RIGHT_FLAG)) { bitmask &= ~(WRAP_CURRY_FLAG | WRAP_CURRY_RIGHT_FLAG) } if (!bitmask || bitmask == WRAP_BIND_FLAG) { var result2 = createBind(func, bitmask, thisArg) } else if ( bitmask == WRAP_CURRY_FLAG || bitmask == WRAP_CURRY_RIGHT_FLAG ) { result2 = createCurry(func, bitmask, arity) } else if ( (bitmask == WRAP_PARTIAL_FLAG || bitmask == (WRAP_BIND_FLAG | WRAP_PARTIAL_FLAG)) && !holders.length ) { result2 = createPartial(func, bitmask, thisArg, partials) } else { result2 = createHybrid.apply(undefined$1, newData) } var setter = data2 ? baseSetData : setData return setWrapToString(setter(result2, newData), func, bitmask) } function customDefaultsAssignIn(objValue, srcValue, key2, object4) { if ( objValue === undefined$1 || (eq2(objValue, objectProto2[key2]) && !hasOwnProperty2.call(object4, key2)) ) { return srcValue } return objValue } function customDefaultsMerge( objValue, srcValue, key2, object4, source2, stack ) { if (isObject2(objValue) && isObject2(srcValue)) { stack.set(srcValue, objValue) baseMerge(objValue, srcValue, undefined$1, customDefaultsMerge, stack) stack['delete'](srcValue) } return objValue } function customOmitClone(value2) { return isPlainObject2(value2) ? undefined$1 : value2 } function equalArrays2( array4, other, bitmask, customizer, equalFunc, stack ) { var isPartial = bitmask & COMPARE_PARTIAL_FLAG2, arrLength = array4.length, othLength = other.length if (arrLength != othLength && !(isPartial && othLength > arrLength)) { return false } var arrStacked = stack.get(array4) var othStacked = stack.get(other) if (arrStacked && othStacked) { return arrStacked == other && othStacked == array4 } var index2 = -1, result2 = true, seen = bitmask & COMPARE_UNORDERED_FLAG2 ? new SetCache2() : undefined$1 stack.set(array4, other) stack.set(other, array4) while (++index2 < arrLength) { var arrValue = array4[index2], othValue = other[index2] if (customizer) { var compared = isPartial ? customizer(othValue, arrValue, index2, other, array4, stack) : customizer(arrValue, othValue, index2, array4, other, stack) } if (compared !== undefined$1) { if (compared) { continue } result2 = false break } if (seen) { if ( !arraySome2(other, function (othValue2, othIndex) { if ( !cacheHas2(seen, othIndex) && (arrValue === othValue2 || equalFunc(arrValue, othValue2, bitmask, customizer, stack)) ) { return seen.push(othIndex) } }) ) { result2 = false break } } else if ( !( arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack) ) ) { result2 = false break } } stack['delete'](array4) stack['delete'](other) return result2 } function equalByTag2( object4, other, tag, bitmask, customizer, equalFunc, stack ) { switch (tag) { case dataViewTag2: if ( object4.byteLength != other.byteLength || object4.byteOffset != other.byteOffset ) { return false } object4 = object4.buffer other = other.buffer case arrayBufferTag2: if ( object4.byteLength != other.byteLength || !equalFunc(new Uint8Array2(object4), new Uint8Array2(other)) ) { return false } return true case boolTag2: case dateTag2: case numberTag2: return eq2(+object4, +other) case errorTag2: return ( object4.name == other.name && object4.message == other.message ) case regexpTag2: case stringTag2: return object4 == other + '' case mapTag2: var convert = mapToArray2 case setTag2: var isPartial = bitmask & COMPARE_PARTIAL_FLAG2 convert || (convert = setToArray2) if (object4.size != other.size && !isPartial) { return false } var stacked = stack.get(object4) if (stacked) { return stacked == other } bitmask |= COMPARE_UNORDERED_FLAG2 stack.set(object4, other) var result2 = equalArrays2( convert(object4), convert(other), bitmask, customizer, equalFunc, stack ) stack['delete'](object4) return result2 case symbolTag2: if (symbolValueOf2) { return symbolValueOf2.call(object4) == symbolValueOf2.call(other) } } return false } function equalObjects2( object4, other, bitmask, customizer, equalFunc, stack ) { var isPartial = bitmask & COMPARE_PARTIAL_FLAG2, objProps = getAllKeys2(object4), objLength = objProps.length, othProps = getAllKeys2(other), othLength = othProps.length if (objLength != othLength && !isPartial) { return false } var index2 = objLength while (index2--) { var key2 = objProps[index2] if ( !(isPartial ? key2 in other : hasOwnProperty2.call(other, key2)) ) { return false } } var objStacked = stack.get(object4) var othStacked = stack.get(other) if (objStacked && othStacked) { return objStacked == other && othStacked == object4 } var result2 = true stack.set(object4, other) stack.set(other, object4) var skipCtor = isPartial while (++index2 < objLength) { key2 = objProps[index2] var objValue = object4[key2], othValue = other[key2] if (customizer) { var compared = isPartial ? customizer(othValue, objValue, key2, other, object4, stack) : customizer(objValue, othValue, key2, object4, other, stack) } if ( !(compared === undefined$1 ? objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack) : compared) ) { result2 = false break } skipCtor || (skipCtor = key2 == 'constructor') } if (result2 && !skipCtor) { var objCtor = object4.constructor, othCtor = other.constructor if ( objCtor != othCtor && 'constructor' in object4 && 'constructor' in other && !( typeof objCtor == 'function' && objCtor instanceof objCtor && typeof othCtor == 'function' && othCtor instanceof othCtor ) ) { result2 = false } } stack['delete'](object4) stack['delete'](other) return result2 } function flatRest2(func) { return setToString2(overRest2(func, undefined$1, flatten2), func + '') } function getAllKeys2(object4) { return baseGetAllKeys2(object4, keys3, getSymbols2) } function getAllKeysIn2(object4) { return baseGetAllKeys2(object4, keysIn2, getSymbolsIn2) } var getData = !metaMap ? noop2 : function (func) { return metaMap.get(func) } function getFuncName(func) { var result2 = func.name + '', array4 = realNames[result2], length2 = hasOwnProperty2.call(realNames, result2) ? array4.length : 0 while (length2--) { var data2 = array4[length2], otherFunc = data2.func if (otherFunc == null || otherFunc == func) { return data2.name } } return result2 } function getHolder(func) { var object4 = hasOwnProperty2.call(lodash2, 'placeholder') ? lodash2 : func return object4.placeholder } function getIteratee() { var result2 = lodash2.iteratee || iteratee result2 = result2 === iteratee ? baseIteratee : result2 return arguments.length ? result2(arguments[0], arguments[1]) : result2 } function getMapData2(map3, key2) { var data2 = map3.__data__ return isKeyable2(key2) ? data2[typeof key2 == 'string' ? 'string' : 'hash'] : data2.map } function getMatchData(object4) { var result2 = keys3(object4), length2 = result2.length while (length2--) { var key2 = result2[length2], value2 = object4[key2] result2[length2] = [key2, value2, isStrictComparable(value2)] } return result2 } function getNative2(object4, key2) { var value2 = getValue2(object4, key2) return baseIsNative2(value2) ? value2 : undefined$1 } function getRawTag2(value2) { var isOwn = hasOwnProperty2.call(value2, symToStringTag2), tag = value2[symToStringTag2] try { value2[symToStringTag2] = undefined$1 var unmasked = true } catch (e2) {} var result2 = nativeObjectToString2.call(value2) if (unmasked) { if (isOwn) { value2[symToStringTag2] = tag } else { delete value2[symToStringTag2] } } return result2 } var getSymbols2 = !nativeGetSymbols2 ? stubArray2 : function (object4) { if (object4 == null) { return [] } object4 = Object2(object4) return arrayFilter2(nativeGetSymbols2(object4), function (symbol) { return propertyIsEnumerable3.call(object4, symbol) }) } var getSymbolsIn2 = !nativeGetSymbols2 ? stubArray2 : function (object4) { var result2 = [] while (object4) { arrayPush2(result2, getSymbols2(object4)) object4 = getPrototype2(object4) } return result2 } var getTag2 = baseGetTag2 if ( (DataView2 && getTag2(new DataView2(new ArrayBuffer(1))) != dataViewTag2) || (Map2 && getTag2(new Map2()) != mapTag2) || (Promise2 && getTag2(Promise2.resolve()) != promiseTag2) || (Set2 && getTag2(new Set2()) != setTag2) || (WeakMap2 && getTag2(new WeakMap2()) != weakMapTag2) ) { getTag2 = function (value2) { var result2 = baseGetTag2(value2), Ctor = result2 == objectTag2 ? value2.constructor : undefined$1, ctorString = Ctor ? toSource2(Ctor) : '' if (ctorString) { switch (ctorString) { case dataViewCtorString2: return dataViewTag2 case mapCtorString2: return mapTag2 case promiseCtorString2: return promiseTag2 case setCtorString2: return setTag2 case weakMapCtorString2: return weakMapTag2 } } return result2 } } function getView(start2, end2, transforms) { var index2 = -1, length2 = transforms.length while (++index2 < length2) { var data2 = transforms[index2], size2 = data2.size switch (data2.type) { case 'drop': start2 += size2 break case 'dropRight': end2 -= size2 break case 'take': end2 = nativeMin2(end2, start2 + size2) break case 'takeRight': start2 = nativeMax2(start2, end2 - size2) break } } return { start: start2, end: end2 } } function getWrapDetails(source2) { var match2 = source2.match(reWrapDetails) return match2 ? match2[1].split(reSplitDetails) : [] } function hasPath2(object4, path, hasFunc) { path = castPath2(path, object4) var index2 = -1, length2 = path.length, result2 = false while (++index2 < length2) { var key2 = toKey2(path[index2]) if (!(result2 = object4 != null && hasFunc(object4, key2))) { break } object4 = object4[key2] } if (result2 || ++index2 != length2) { return result2 } length2 = object4 == null ? 0 : object4.length return ( !!length2 && isLength2(length2) && isIndex2(key2, length2) && (isArray3(object4) || isArguments2(object4)) ) } function initCloneArray2(array4) { var length2 = array4.length, result2 = new array4.constructor(length2) if ( length2 && typeof array4[0] == 'string' && hasOwnProperty2.call(array4, 'index') ) { result2.index = array4.index result2.input = array4.input } return result2 } function initCloneObject2(object4) { return typeof object4.constructor == 'function' && !isPrototype2(object4) ? baseCreate2(getPrototype2(object4)) : {} } function initCloneByTag2(object4, tag, isDeep) { var Ctor = object4.constructor switch (tag) { case arrayBufferTag2: return cloneArrayBuffer2(object4) case boolTag2: case dateTag2: return new Ctor(+object4) case dataViewTag2: return cloneDataView2(object4, isDeep) case float32Tag2: case float64Tag2: case int8Tag2: case int16Tag2: case int32Tag2: case uint8Tag2: case uint8ClampedTag2: case uint16Tag2: case uint32Tag2: return cloneTypedArray2(object4, isDeep) case mapTag2: return new Ctor() case numberTag2: case stringTag2: return new Ctor(object4) case regexpTag2: return cloneRegExp2(object4) case setTag2: return new Ctor() case symbolTag2: return cloneSymbol2(object4) } } function insertWrapDetails(source2, details) { var length2 = details.length if (!length2) { return source2 } var lastIndex = length2 - 1 details[lastIndex] = (length2 > 1 ? '& ' : '') + details[lastIndex] details = details.join(length2 > 2 ? ', ' : ' ') return source2.replace( reWrapComment, '{\n/* [wrapped with ' + details + '] */\n' ) } function isFlattenable2(value2) { return ( isArray3(value2) || isArguments2(value2) || !!(spreadableSymbol2 && value2 && value2[spreadableSymbol2]) ) } function isIndex2(value2, length2) { var type4 = typeof value2 length2 = length2 == null ? MAX_SAFE_INTEGER2 : length2 return ( !!length2 && (type4 == 'number' || (type4 != 'symbol' && reIsUint2.test(value2))) && value2 > -1 && value2 % 1 == 0 && value2 < length2 ) } function isIterateeCall(value2, index2, object4) { if (!isObject2(object4)) { return false } var type4 = typeof index2 if ( type4 == 'number' ? isArrayLike2(object4) && isIndex2(index2, object4.length) : type4 == 'string' && index2 in object4 ) { return eq2(object4[index2], value2) } return false } function isKey2(value2, object4) { if (isArray3(value2)) { return false } var type4 = typeof value2 if ( type4 == 'number' || type4 == 'symbol' || type4 == 'boolean' || value2 == null || isSymbol2(value2) ) { return true } return ( reIsPlainProp2.test(value2) || !reIsDeepProp2.test(value2) || (object4 != null && value2 in Object2(object4)) ) } function isKeyable2(value2) { var type4 = typeof value2 return type4 == 'string' || type4 == 'number' || type4 == 'symbol' || type4 == 'boolean' ? value2 !== '__proto__' : value2 === null } function isLaziable(func) { var funcName = getFuncName(func), other = lodash2[funcName] if ( typeof other != 'function' || !(funcName in LazyWrapper.prototype) ) { return false } if (func === other) { return true } var data2 = getData(other) return !!data2 && func === data2[0] } function isMasked2(func) { return !!maskSrcKey2 && maskSrcKey2 in func } var isMaskable = coreJsData2 ? isFunction2 : stubFalse2 function isPrototype2(value2) { var Ctor = value2 && value2.constructor, proto2 = (typeof Ctor == 'function' && Ctor.prototype) || objectProto2 return value2 === proto2 } function isStrictComparable(value2) { return value2 === value2 && !isObject2(value2) } function matchesStrictComparable(key2, srcValue) { return function (object4) { if (object4 == null) { return false } return ( object4[key2] === srcValue && (srcValue !== undefined$1 || key2 in Object2(object4)) ) } } function memoizeCapped2(func) { var result2 = memoize2(func, function (key2) { if (cache2.size === MAX_MEMOIZE_SIZE2) { cache2.clear() } return key2 }) var cache2 = result2.cache return result2 } function mergeData(data2, source2) { var bitmask = data2[1], srcBitmask = source2[1], newBitmask = bitmask | srcBitmask, isCommon = newBitmask < (WRAP_BIND_FLAG | WRAP_BIND_KEY_FLAG | WRAP_ARY_FLAG) var isCombo = (srcBitmask == WRAP_ARY_FLAG && bitmask == WRAP_CURRY_FLAG) || (srcBitmask == WRAP_ARY_FLAG && bitmask == WRAP_REARG_FLAG && data2[7].length <= source2[8]) || (srcBitmask == (WRAP_ARY_FLAG | WRAP_REARG_FLAG) && source2[7].length <= source2[8] && bitmask == WRAP_CURRY_FLAG) if (!(isCommon || isCombo)) { return data2 } if (srcBitmask & WRAP_BIND_FLAG) { data2[2] = source2[2] newBitmask |= bitmask & WRAP_BIND_FLAG ? 0 : WRAP_CURRY_BOUND_FLAG } var value2 = source2[3] if (value2) { var partials = data2[3] data2[3] = partials ? composeArgs(partials, value2, source2[4]) : value2 data2[4] = partials ? replaceHolders(data2[3], PLACEHOLDER) : source2[4] } value2 = source2[5] if (value2) { partials = data2[5] data2[5] = partials ? composeArgsRight(partials, value2, source2[6]) : value2 data2[6] = partials ? replaceHolders(data2[5], PLACEHOLDER) : source2[6] } value2 = source2[7] if (value2) { data2[7] = value2 } if (srcBitmask & WRAP_ARY_FLAG) { data2[8] = data2[8] == null ? source2[8] : nativeMin2(data2[8], source2[8]) } if (data2[9] == null) { data2[9] = source2[9] } data2[0] = source2[0] data2[1] = newBitmask return data2 } function nativeKeysIn2(object4) { var result2 = [] if (object4 != null) { for (var key2 in Object2(object4)) { result2.push(key2) } } return result2 } function objectToString2(value2) { return nativeObjectToString2.call(value2) } function overRest2(func, start2, transform4) { start2 = nativeMax2( start2 === undefined$1 ? func.length - 1 : start2, 0 ) return function () { var args = arguments, index2 = -1, length2 = nativeMax2(args.length - start2, 0), array4 = Array2(length2) while (++index2 < length2) { array4[index2] = args[start2 + index2] } index2 = -1 var otherArgs = Array2(start2 + 1) while (++index2 < start2) { otherArgs[index2] = args[index2] } otherArgs[start2] = transform4(array4) return apply2(func, this, otherArgs) } } function parent2(object4, path) { return path.length < 2 ? object4 : baseGet2(object4, baseSlice(path, 0, -1)) } function reorder(array4, indexes) { var arrLength = array4.length, length2 = nativeMin2(indexes.length, arrLength), oldArray = copyArray2(array4) while (length2--) { var index2 = indexes[length2] array4[length2] = isIndex2(index2, arrLength) ? oldArray[index2] : undefined$1 } return array4 } function safeGet(object4, key2) { if (key2 === 'constructor' && typeof object4[key2] === 'function') { return } if (key2 == '__proto__') { return } return object4[key2] } var setData = shortOut2(baseSetData) var setTimeout2 = ctxSetTimeout || function (func, wait) { return root2.setTimeout(func, wait) } var setToString2 = shortOut2(baseSetToString2) function setWrapToString(wrapper, reference2, bitmask) { var source2 = reference2 + '' return setToString2( wrapper, insertWrapDetails( source2, updateWrapDetails(getWrapDetails(source2), bitmask) ) ) } function shortOut2(func) { var count2 = 0, lastCalled = 0 return function () { var stamp2 = nativeNow2(), remaining = HOT_SPAN2 - (stamp2 - lastCalled) lastCalled = stamp2 if (remaining > 0) { if (++count2 >= HOT_COUNT2) { return arguments[0] } } else { count2 = 0 } return func.apply(undefined$1, arguments) } } function shuffleSelf(array4, size2) { var index2 = -1, length2 = array4.length, lastIndex = length2 - 1 size2 = size2 === undefined$1 ? length2 : size2 while (++index2 < size2) { var rand2 = baseRandom(index2, lastIndex), value2 = array4[rand2] array4[rand2] = array4[index2] array4[index2] = value2 } array4.length = size2 return array4 } var stringToPath2 = memoizeCapped2(function (string3) { var result2 = [] if (string3.charCodeAt(0) === 46) { result2.push('') } string3.replace( rePropName2, function (match2, number4, quote, subString) { result2.push( quote ? subString.replace(reEscapeChar2, '$1') : number4 || match2 ) } ) return result2 }) function toKey2(value2) { if (typeof value2 == 'string' || isSymbol2(value2)) { return value2 } var result2 = value2 + '' return result2 == '0' && 1 / value2 == -INFINITY2 ? '-0' : result2 } function toSource2(func) { if (func != null) { try { return funcToString2.call(func) } catch (e2) {} try { return func + '' } catch (e2) {} } return '' } function updateWrapDetails(details, bitmask) { arrayEach2(wrapFlags, function (pair) { var value2 = '_.' + pair[0] if (bitmask & pair[1] && !arrayIncludes2(details, value2)) { details.push(value2) } }) return details.sort() } function wrapperClone(wrapper) { if (wrapper instanceof LazyWrapper) { return wrapper.clone() } var result2 = new LodashWrapper(wrapper.__wrapped__, wrapper.__chain__) result2.__actions__ = copyArray2(wrapper.__actions__) result2.__index__ = wrapper.__index__ result2.__values__ = wrapper.__values__ return result2 } function chunk2(array4, size2, guard) { if ( guard ? isIterateeCall(array4, size2, guard) : size2 === undefined$1 ) { size2 = 1 } else { size2 = nativeMax2(toInteger2(size2), 0) } var length2 = array4 == null ? 0 : array4.length if (!length2 || size2 < 1) { return [] } var index2 = 0, resIndex = 0, result2 = Array2(nativeCeil(length2 / size2)) while (index2 < length2) { result2[resIndex++] = baseSlice(array4, index2, (index2 += size2)) } return result2 } function compact(array4) { var index2 = -1, length2 = array4 == null ? 0 : array4.length, resIndex = 0, result2 = [] while (++index2 < length2) { var value2 = array4[index2] if (value2) { result2[resIndex++] = value2 } } return result2 } function concat2() { var length2 = arguments.length if (!length2) { return [] } var args = Array2(length2 - 1), array4 = arguments[0], index2 = length2 while (index2--) { args[index2 - 1] = arguments[index2] } return arrayPush2( isArray3(array4) ? copyArray2(array4) : [array4], baseFlatten2(args, 1) ) } var difference = baseRest2(function (array4, values3) { return isArrayLikeObject2(array4) ? baseDifference( array4, baseFlatten2(values3, 1, isArrayLikeObject2, true) ) : [] }) var differenceBy = baseRest2(function (array4, values3) { var iteratee2 = last2(values3) if (isArrayLikeObject2(iteratee2)) { iteratee2 = undefined$1 } return isArrayLikeObject2(array4) ? baseDifference( array4, baseFlatten2(values3, 1, isArrayLikeObject2, true), getIteratee(iteratee2, 2) ) : [] }) var differenceWith = baseRest2(function (array4, values3) { var comparator = last2(values3) if (isArrayLikeObject2(comparator)) { comparator = undefined$1 } return isArrayLikeObject2(array4) ? baseDifference( array4, baseFlatten2(values3, 1, isArrayLikeObject2, true), undefined$1, comparator ) : [] }) function drop3(array4, n2, guard) { var length2 = array4 == null ? 0 : array4.length if (!length2) { return [] } n2 = guard || n2 === undefined$1 ? 1 : toInteger2(n2) return baseSlice(array4, n2 < 0 ? 0 : n2, length2) } function dropRight(array4, n2, guard) { var length2 = array4 == null ? 0 : array4.length if (!length2) { return [] } n2 = guard || n2 === undefined$1 ? 1 : toInteger2(n2) n2 = length2 - n2 return baseSlice(array4, 0, n2 < 0 ? 0 : n2) } function dropRightWhile(array4, predicate) { return array4 && array4.length ? baseWhile(array4, getIteratee(predicate, 3), true, true) : [] } function dropWhile(array4, predicate) { return array4 && array4.length ? baseWhile(array4, getIteratee(predicate, 3), true) : [] } function fill(array4, value2, start2, end2) { var length2 = array4 == null ? 0 : array4.length if (!length2) { return [] } if ( start2 && typeof start2 != 'number' && isIterateeCall(array4, value2, start2) ) { start2 = 0 end2 = length2 } return baseFill(array4, value2, start2, end2) } function findIndex(array4, predicate, fromIndex) { var length2 = array4 == null ? 0 : array4.length if (!length2) { return -1 } var index2 = fromIndex == null ? 0 : toInteger2(fromIndex) if (index2 < 0) { index2 = nativeMax2(length2 + index2, 0) } return baseFindIndex2(array4, getIteratee(predicate, 3), index2) } function findLastIndex(array4, predicate, fromIndex) { var length2 = array4 == null ? 0 : array4.length if (!length2) { return -1 } var index2 = length2 - 1 if (fromIndex !== undefined$1) { index2 = toInteger2(fromIndex) index2 = fromIndex < 0 ? nativeMax2(length2 + index2, 0) : nativeMin2(index2, length2 - 1) } return baseFindIndex2(array4, getIteratee(predicate, 3), index2, true) } function flatten2(array4) { var length2 = array4 == null ? 0 : array4.length return length2 ? baseFlatten2(array4, 1) : [] } function flattenDeep2(array4) { var length2 = array4 == null ? 0 : array4.length return length2 ? baseFlatten2(array4, INFINITY2) : [] } function flattenDepth(array4, depth) { var length2 = array4 == null ? 0 : array4.length if (!length2) { return [] } depth = depth === undefined$1 ? 1 : toInteger2(depth) return baseFlatten2(array4, depth) } function fromPairs2(pairs) { var index2 = -1, length2 = pairs == null ? 0 : pairs.length, result2 = {} while (++index2 < length2) { var pair = pairs[index2] result2[pair[0]] = pair[1] } return result2 } function head(array4) { return array4 && array4.length ? array4[0] : undefined$1 } function indexOf3(array4, value2, fromIndex) { var length2 = array4 == null ? 0 : array4.length if (!length2) { return -1 } var index2 = fromIndex == null ? 0 : toInteger2(fromIndex) if (index2 < 0) { index2 = nativeMax2(length2 + index2, 0) } return baseIndexOf2(array4, value2, index2) } function initial(array4) { var length2 = array4 == null ? 0 : array4.length return length2 ? baseSlice(array4, 0, -1) : [] } var intersection = baseRest2(function (arrays) { var mapped = arrayMap2(arrays, castArrayLikeObject) return mapped.length && mapped[0] === arrays[0] ? baseIntersection(mapped) : [] }) var intersectionBy = baseRest2(function (arrays) { var iteratee2 = last2(arrays), mapped = arrayMap2(arrays, castArrayLikeObject) if (iteratee2 === last2(mapped)) { iteratee2 = undefined$1 } else { mapped.pop() } return mapped.length && mapped[0] === arrays[0] ? baseIntersection(mapped, getIteratee(iteratee2, 2)) : [] }) var intersectionWith = baseRest2(function (arrays) { var comparator = last2(arrays), mapped = arrayMap2(arrays, castArrayLikeObject) comparator = typeof comparator == 'function' ? comparator : undefined$1 if (comparator) { mapped.pop() } return mapped.length && mapped[0] === arrays[0] ? baseIntersection(mapped, undefined$1, comparator) : [] }) function join2(array4, separator) { return array4 == null ? '' : nativeJoin.call(array4, separator) } function last2(array4) { var length2 = array4 == null ? 0 : array4.length return length2 ? array4[length2 - 1] : undefined$1 } function lastIndexOf2(array4, value2, fromIndex) { var length2 = array4 == null ? 0 : array4.length if (!length2) { return -1 } var index2 = length2 if (fromIndex !== undefined$1) { index2 = toInteger2(fromIndex) index2 = index2 < 0 ? nativeMax2(length2 + index2, 0) : nativeMin2(index2, length2 - 1) } return value2 === value2 ? strictLastIndexOf(array4, value2, index2) : baseFindIndex2(array4, baseIsNaN2, index2, true) } function nth(array4, n2) { return array4 && array4.length ? baseNth(array4, toInteger2(n2)) : undefined$1 } var pull = baseRest2(pullAll) function pullAll(array4, values3) { return array4 && array4.length && values3 && values3.length ? basePullAll(array4, values3) : array4 } function pullAllBy(array4, values3, iteratee2) { return array4 && array4.length && values3 && values3.length ? basePullAll(array4, values3, getIteratee(iteratee2, 2)) : array4 } function pullAllWith(array4, values3, comparator) { return array4 && array4.length && values3 && values3.length ? basePullAll(array4, values3, undefined$1, comparator) : array4 } var pullAt = flatRest2(function (array4, indexes) { var length2 = array4 == null ? 0 : array4.length, result2 = baseAt(array4, indexes) basePullAt( array4, arrayMap2(indexes, function (index2) { return isIndex2(index2, length2) ? +index2 : index2 }).sort(compareAscending) ) return result2 }) function remove2(array4, predicate) { var result2 = [] if (!(array4 && array4.length)) { return result2 } var index2 = -1, indexes = [], length2 = array4.length predicate = getIteratee(predicate, 3) while (++index2 < length2) { var value2 = array4[index2] if (predicate(value2, index2, array4)) { result2.push(value2) indexes.push(index2) } } basePullAt(array4, indexes) return result2 } function reverse3(array4) { return array4 == null ? array4 : nativeReverse2.call(array4) } function slice2(array4, start2, end2) { var length2 = array4 == null ? 0 : array4.length if (!length2) { return [] } if ( end2 && typeof end2 != 'number' && isIterateeCall(array4, start2, end2) ) { start2 = 0 end2 = length2 } else { start2 = start2 == null ? 0 : toInteger2(start2) end2 = end2 === undefined$1 ? length2 : toInteger2(end2) } return baseSlice(array4, start2, end2) } function sortedIndex(array4, value2) { return baseSortedIndex(array4, value2) } function sortedIndexBy(array4, value2, iteratee2) { return baseSortedIndexBy(array4, value2, getIteratee(iteratee2, 2)) } function sortedIndexOf(array4, value2) { var length2 = array4 == null ? 0 : array4.length if (length2) { var index2 = baseSortedIndex(array4, value2) if (index2 < length2 && eq2(array4[index2], value2)) { return index2 } } return -1 } function sortedLastIndex(array4, value2) { return baseSortedIndex(array4, value2, true) } function sortedLastIndexBy(array4, value2, iteratee2) { return baseSortedIndexBy( array4, value2, getIteratee(iteratee2, 2), true ) } function sortedLastIndexOf(array4, value2) { var length2 = array4 == null ? 0 : array4.length if (length2) { var index2 = baseSortedIndex(array4, value2, true) - 1 if (eq2(array4[index2], value2)) { return index2 } } return -1 } function sortedUniq(array4) { return array4 && array4.length ? baseSortedUniq(array4) : [] } function sortedUniqBy(array4, iteratee2) { return array4 && array4.length ? baseSortedUniq(array4, getIteratee(iteratee2, 2)) : [] } function tail(array4) { var length2 = array4 == null ? 0 : array4.length return length2 ? baseSlice(array4, 1, length2) : [] } function take2(array4, n2, guard) { if (!(array4 && array4.length)) { return [] } n2 = guard || n2 === undefined$1 ? 1 : toInteger2(n2) return baseSlice(array4, 0, n2 < 0 ? 0 : n2) } function takeRight(array4, n2, guard) { var length2 = array4 == null ? 0 : array4.length if (!length2) { return [] } n2 = guard || n2 === undefined$1 ? 1 : toInteger2(n2) n2 = length2 - n2 return baseSlice(array4, n2 < 0 ? 0 : n2, length2) } function takeRightWhile(array4, predicate) { return array4 && array4.length ? baseWhile(array4, getIteratee(predicate, 3), false, true) : [] } function takeWhile(array4, predicate) { return array4 && array4.length ? baseWhile(array4, getIteratee(predicate, 3)) : [] } var union2 = baseRest2(function (arrays) { return baseUniq2(baseFlatten2(arrays, 1, isArrayLikeObject2, true)) }) var unionBy = baseRest2(function (arrays) { var iteratee2 = last2(arrays) if (isArrayLikeObject2(iteratee2)) { iteratee2 = undefined$1 } return baseUniq2( baseFlatten2(arrays, 1, isArrayLikeObject2, true), getIteratee(iteratee2, 2) ) }) var unionWith = baseRest2(function (arrays) { var comparator = last2(arrays) comparator = typeof comparator == 'function' ? comparator : undefined$1 return baseUniq2( baseFlatten2(arrays, 1, isArrayLikeObject2, true), undefined$1, comparator ) }) function uniq2(array4) { return array4 && array4.length ? baseUniq2(array4) : [] } function uniqBy(array4, iteratee2) { return array4 && array4.length ? baseUniq2(array4, getIteratee(iteratee2, 2)) : [] } function uniqWith(array4, comparator) { comparator = typeof comparator == 'function' ? comparator : undefined$1 return array4 && array4.length ? baseUniq2(array4, undefined$1, comparator) : [] } function unzip2(array4) { if (!(array4 && array4.length)) { return [] } var length2 = 0 array4 = arrayFilter2(array4, function (group) { if (isArrayLikeObject2(group)) { length2 = nativeMax2(group.length, length2) return true } }) return baseTimes2(length2, function (index2) { return arrayMap2(array4, baseProperty(index2)) }) } function unzipWith(array4, iteratee2) { if (!(array4 && array4.length)) { return [] } var result2 = unzip2(array4) if (iteratee2 == null) { return result2 } return arrayMap2(result2, function (group) { return apply2(iteratee2, undefined$1, group) }) } var without = baseRest2(function (array4, values3) { return isArrayLikeObject2(array4) ? baseDifference(array4, values3) : [] }) var xor = baseRest2(function (arrays) { return baseXor(arrayFilter2(arrays, isArrayLikeObject2)) }) var xorBy = baseRest2(function (arrays) { var iteratee2 = last2(arrays) if (isArrayLikeObject2(iteratee2)) { iteratee2 = undefined$1 } return baseXor( arrayFilter2(arrays, isArrayLikeObject2), getIteratee(iteratee2, 2) ) }) var xorWith = baseRest2(function (arrays) { var comparator = last2(arrays) comparator = typeof comparator == 'function' ? comparator : undefined$1 return baseXor( arrayFilter2(arrays, isArrayLikeObject2), undefined$1, comparator ) }) var zip2 = baseRest2(unzip2) function zipObject2(props2, values3) { return baseZipObject(props2 || [], values3 || [], assignValue2) } function zipObjectDeep(props2, values3) { return baseZipObject(props2 || [], values3 || [], baseSet2) } var zipWith = baseRest2(function (arrays) { var length2 = arrays.length, iteratee2 = length2 > 1 ? arrays[length2 - 1] : undefined$1 iteratee2 = typeof iteratee2 == 'function' ? (arrays.pop(), iteratee2) : undefined$1 return unzipWith(arrays, iteratee2) }) function chain(value2) { var result2 = lodash2(value2) result2.__chain__ = true return result2 } function tap(value2, interceptor2) { interceptor2(value2) return value2 } function thru(value2, interceptor2) { return interceptor2(value2) } var wrapperAt = flatRest2(function (paths) { var length2 = paths.length, start2 = length2 ? paths[0] : 0, value2 = this.__wrapped__, interceptor2 = function (object4) { return baseAt(object4, paths) } if ( length2 > 1 || this.__actions__.length || !(value2 instanceof LazyWrapper) || !isIndex2(start2) ) { return this.thru(interceptor2) } value2 = value2.slice(start2, +start2 + (length2 ? 1 : 0)) value2.__actions__.push({ func: thru, args: [interceptor2], thisArg: undefined$1, }) return new LodashWrapper(value2, this.__chain__).thru(function ( array4 ) { if (length2 && !array4.length) { array4.push(undefined$1) } return array4 }) }) function wrapperChain() { return chain(this) } function wrapperCommit() { return new LodashWrapper(this.value(), this.__chain__) } function wrapperNext() { if (this.__values__ === undefined$1) { this.__values__ = toArray3(this.value()) } var done = this.__index__ >= this.__values__.length, value2 = done ? undefined$1 : this.__values__[this.__index__++] return { done: done, value: value2 } } function wrapperToIterator() { return this } function wrapperPlant(value2) { var result2, parent3 = this while (parent3 instanceof baseLodash) { var clone3 = wrapperClone(parent3) clone3.__index__ = 0 clone3.__values__ = undefined$1 if (result2) { previous.__wrapped__ = clone3 } else { result2 = clone3 } var previous = clone3 parent3 = parent3.__wrapped__ } previous.__wrapped__ = value2 return result2 } function wrapperReverse() { var value2 = this.__wrapped__ if (value2 instanceof LazyWrapper) { var wrapped = value2 if (this.__actions__.length) { wrapped = new LazyWrapper(this) } wrapped = wrapped.reverse() wrapped.__actions__.push({ func: thru, args: [reverse3], thisArg: undefined$1, }) return new LodashWrapper(wrapped, this.__chain__) } return this.thru(reverse3) } function wrapperValue() { return baseWrapperValue(this.__wrapped__, this.__actions__) } var countBy2 = createAggregator(function (result2, value2, key2) { if (hasOwnProperty2.call(result2, key2)) { ++result2[key2] } else { baseAssignValue2(result2, key2, 1) } }) function every2(collection2, predicate, guard) { var func = isArray3(collection2) ? arrayEvery : baseEvery if (guard && isIterateeCall(collection2, predicate, guard)) { predicate = undefined$1 } return func(collection2, getIteratee(predicate, 3)) } function filter2(collection2, predicate) { var func = isArray3(collection2) ? arrayFilter2 : baseFilter return func(collection2, getIteratee(predicate, 3)) } var find2 = createFind(findIndex) var findLast2 = createFind(findLastIndex) function flatMap(collection2, iteratee2) { return baseFlatten2(map2(collection2, iteratee2), 1) } function flatMapDeep(collection2, iteratee2) { return baseFlatten2(map2(collection2, iteratee2), INFINITY2) } function flatMapDepth(collection2, iteratee2, depth) { depth = depth === undefined$1 ? 1 : toInteger2(depth) return baseFlatten2(map2(collection2, iteratee2), depth) } function forEach3(collection2, iteratee2) { var func = isArray3(collection2) ? arrayEach2 : baseEach return func(collection2, getIteratee(iteratee2, 3)) } function forEachRight(collection2, iteratee2) { var func = isArray3(collection2) ? arrayEachRight : baseEachRight return func(collection2, getIteratee(iteratee2, 3)) } var groupBy2 = createAggregator(function (result2, value2, key2) { if (hasOwnProperty2.call(result2, key2)) { result2[key2].push(value2) } else { baseAssignValue2(result2, key2, [value2]) } }) function includes3(collection2, value2, fromIndex, guard) { collection2 = isArrayLike2(collection2) ? collection2 : values2(collection2) fromIndex = fromIndex && !guard ? toInteger2(fromIndex) : 0 var length2 = collection2.length if (fromIndex < 0) { fromIndex = nativeMax2(length2 + fromIndex, 0) } return isString2(collection2) ? fromIndex <= length2 && collection2.indexOf(value2, fromIndex) > -1 : !!length2 && baseIndexOf2(collection2, value2, fromIndex) > -1 } var invokeMap = baseRest2(function (collection2, path, args) { var index2 = -1, isFunc = typeof path == 'function', result2 = isArrayLike2(collection2) ? Array2(collection2.length) : [] baseEach(collection2, function (value2) { result2[++index2] = isFunc ? apply2(path, value2, args) : baseInvoke(value2, path, args) }) return result2 }) var keyBy = createAggregator(function (result2, value2, key2) { baseAssignValue2(result2, key2, value2) }) function map2(collection2, iteratee2) { var func = isArray3(collection2) ? arrayMap2 : baseMap return func(collection2, getIteratee(iteratee2, 3)) } function orderBy2(collection2, iteratees, orders, guard) { if (collection2 == null) { return [] } if (!isArray3(iteratees)) { iteratees = iteratees == null ? [] : [iteratees] } orders = guard ? undefined$1 : orders if (!isArray3(orders)) { orders = orders == null ? [] : [orders] } return baseOrderBy(collection2, iteratees, orders) } var partition = createAggregator( function (result2, value2, key2) { result2[key2 ? 0 : 1].push(value2) }, function () { return [[], []] } ) function reduce3(collection2, iteratee2, accumulator) { var func = isArray3(collection2) ? arrayReduce2 : baseReduce, initAccum = arguments.length < 3 return func( collection2, getIteratee(iteratee2, 4), accumulator, initAccum, baseEach ) } function reduceRight(collection2, iteratee2, accumulator) { var func = isArray3(collection2) ? arrayReduceRight : baseReduce, initAccum = arguments.length < 3 return func( collection2, getIteratee(iteratee2, 4), accumulator, initAccum, baseEachRight ) } function reject2(collection2, predicate) { var func = isArray3(collection2) ? arrayFilter2 : baseFilter return func(collection2, negate2(getIteratee(predicate, 3))) } function sample2(collection2) { var func = isArray3(collection2) ? arraySample : baseSample return func(collection2) } function sampleSize(collection2, n2, guard) { if ( guard ? isIterateeCall(collection2, n2, guard) : n2 === undefined$1 ) { n2 = 1 } else { n2 = toInteger2(n2) } var func = isArray3(collection2) ? arraySampleSize : baseSampleSize return func(collection2, n2) } function shuffle2(collection2) { var func = isArray3(collection2) ? arrayShuffle : baseShuffle return func(collection2) } function size(collection2) { if (collection2 == null) { return 0 } if (isArrayLike2(collection2)) { return isString2(collection2) ? stringSize(collection2) : collection2.length } var tag = getTag2(collection2) if (tag == mapTag2 || tag == setTag2) { return collection2.size } return baseKeys2(collection2).length } function some2(collection2, predicate, guard) { var func = isArray3(collection2) ? arraySome2 : baseSome if (guard && isIterateeCall(collection2, predicate, guard)) { predicate = undefined$1 } return func(collection2, getIteratee(predicate, 3)) } var sortBy2 = baseRest2(function (collection2, iteratees) { if (collection2 == null) { return [] } var length2 = iteratees.length if ( length2 > 1 && isIterateeCall(collection2, iteratees[0], iteratees[1]) ) { iteratees = [] } else if ( length2 > 2 && isIterateeCall(iteratees[0], iteratees[1], iteratees[2]) ) { iteratees = [iteratees[0]] } return baseOrderBy(collection2, baseFlatten2(iteratees, 1), []) }) var now2 = ctxNow || function () { return root2.Date.now() } function after2(n2, func) { if (typeof func != 'function') { throw new TypeError2(FUNC_ERROR_TEXT2) } n2 = toInteger2(n2) return function () { if (--n2 < 1) { return func.apply(this, arguments) } } } function ary(func, n2, guard) { n2 = guard ? undefined$1 : n2 n2 = func && n2 == null ? func.length : n2 return createWrap2( func, WRAP_ARY_FLAG, undefined$1, undefined$1, undefined$1, undefined$1, n2 ) } function before2(n2, func) { var result2 if (typeof func != 'function') { throw new TypeError2(FUNC_ERROR_TEXT2) } n2 = toInteger2(n2) return function () { if (--n2 > 0) { result2 = func.apply(this, arguments) } if (n2 <= 1) { func = undefined$1 } return result2 } } var bind3 = baseRest2(function (func, thisArg, partials) { var bitmask = WRAP_BIND_FLAG if (partials.length) { var holders = replaceHolders(partials, getHolder(bind3)) bitmask |= WRAP_PARTIAL_FLAG } return createWrap2(func, bitmask, thisArg, partials, holders) }) var bindKey = baseRest2(function (object4, key2, partials) { var bitmask = WRAP_BIND_FLAG | WRAP_BIND_KEY_FLAG if (partials.length) { var holders = replaceHolders(partials, getHolder(bindKey)) bitmask |= WRAP_PARTIAL_FLAG } return createWrap2(key2, bitmask, object4, partials, holders) }) function curry2(func, arity, guard) { arity = guard ? undefined$1 : arity var result2 = createWrap2( func, WRAP_CURRY_FLAG, undefined$1, undefined$1, undefined$1, undefined$1, undefined$1, arity ) result2.placeholder = curry2.placeholder return result2 } function curryRight(func, arity, guard) { arity = guard ? undefined$1 : arity var result2 = createWrap2( func, WRAP_CURRY_RIGHT_FLAG, undefined$1, undefined$1, undefined$1, undefined$1, undefined$1, arity ) result2.placeholder = curryRight.placeholder return result2 } function debounce2(func, wait, options2) { var lastArgs, lastThis, maxWait, result2, timerId, lastCallTime, lastInvokeTime = 0, leading = false, maxing = false, trailing = true if (typeof func != 'function') { throw new TypeError2(FUNC_ERROR_TEXT2) } wait = toNumber2(wait) || 0 if (isObject2(options2)) { leading = !!options2.leading maxing = 'maxWait' in options2 maxWait = maxing ? nativeMax2(toNumber2(options2.maxWait) || 0, wait) : maxWait trailing = 'trailing' in options2 ? !!options2.trailing : trailing } function invokeFunc(time2) { var args = lastArgs, thisArg = lastThis lastArgs = lastThis = undefined$1 lastInvokeTime = time2 result2 = func.apply(thisArg, args) return result2 } function leadingEdge(time2) { lastInvokeTime = time2 timerId = setTimeout2(timerExpired, wait) return leading ? invokeFunc(time2) : result2 } function remainingWait(time2) { var timeSinceLastCall = time2 - lastCallTime, timeSinceLastInvoke = time2 - lastInvokeTime, timeWaiting = wait - timeSinceLastCall return maxing ? nativeMin2(timeWaiting, maxWait - timeSinceLastInvoke) : timeWaiting } function shouldInvoke(time2) { var timeSinceLastCall = time2 - lastCallTime, timeSinceLastInvoke = time2 - lastInvokeTime return ( lastCallTime === undefined$1 || timeSinceLastCall >= wait || timeSinceLastCall < 0 || (maxing && timeSinceLastInvoke >= maxWait) ) } function timerExpired() { var time2 = now2() if (shouldInvoke(time2)) { return trailingEdge(time2) } timerId = setTimeout2(timerExpired, remainingWait(time2)) } function trailingEdge(time2) { timerId = undefined$1 if (trailing && lastArgs) { return invokeFunc(time2) } lastArgs = lastThis = undefined$1 return result2 } function cancel2() { if (timerId !== undefined$1) { clearTimeout2(timerId) } lastInvokeTime = 0 lastArgs = lastCallTime = lastThis = timerId = undefined$1 } function flush2() { return timerId === undefined$1 ? result2 : trailingEdge(now2()) } function debounced() { var time2 = now2(), isInvoking = shouldInvoke(time2) lastArgs = arguments lastThis = this lastCallTime = time2 if (isInvoking) { if (timerId === undefined$1) { return leadingEdge(lastCallTime) } if (maxing) { clearTimeout2(timerId) timerId = setTimeout2(timerExpired, wait) return invokeFunc(lastCallTime) } } if (timerId === undefined$1) { timerId = setTimeout2(timerExpired, wait) } return result2 } debounced.cancel = cancel2 debounced.flush = flush2 return debounced } var defer2 = baseRest2(function (func, args) { return baseDelay(func, 1, args) }) var delay2 = baseRest2(function (func, wait, args) { return baseDelay(func, toNumber2(wait) || 0, args) }) function flip2(func) { return createWrap2(func, WRAP_FLIP_FLAG) } function memoize2(func, resolver) { if ( typeof func != 'function' || (resolver != null && typeof resolver != 'function') ) { throw new TypeError2(FUNC_ERROR_TEXT2) } var memoized = function () { var args = arguments, key2 = resolver ? resolver.apply(this, args) : args[0], cache2 = memoized.cache if (cache2.has(key2)) { return cache2.get(key2) } var result2 = func.apply(this, args) memoized.cache = cache2.set(key2, result2) || cache2 return result2 } memoized.cache = new (memoize2.Cache || MapCache2)() return memoized } memoize2.Cache = MapCache2 function negate2(predicate) { if (typeof predicate != 'function') { throw new TypeError2(FUNC_ERROR_TEXT2) } return function () { var args = arguments switch (args.length) { case 0: return !predicate.call(this) case 1: return !predicate.call(this, args[0]) case 2: return !predicate.call(this, args[0], args[1]) case 3: return !predicate.call(this, args[0], args[1], args[2]) } return !predicate.apply(this, args) } } function once2(func) { return before2(2, func) } var overArgs = castRest(function (func, transforms) { transforms = transforms.length == 1 && isArray3(transforms[0]) ? arrayMap2(transforms[0], baseUnary2(getIteratee())) : arrayMap2(baseFlatten2(transforms, 1), baseUnary2(getIteratee())) var funcsLength = transforms.length return baseRest2(function (args) { var index2 = -1, length2 = nativeMin2(args.length, funcsLength) while (++index2 < length2) { args[index2] = transforms[index2].call(this, args[index2]) } return apply2(func, this, args) }) }) var partial2 = baseRest2(function (func, partials) { var holders = replaceHolders(partials, getHolder(partial2)) return createWrap2( func, WRAP_PARTIAL_FLAG, undefined$1, partials, holders ) }) var partialRight = baseRest2(function (func, partials) { var holders = replaceHolders(partials, getHolder(partialRight)) return createWrap2( func, WRAP_PARTIAL_RIGHT_FLAG, undefined$1, partials, holders ) }) var rearg = flatRest2(function (func, indexes) { return createWrap2( func, WRAP_REARG_FLAG, undefined$1, undefined$1, undefined$1, indexes ) }) function rest(func, start2) { if (typeof func != 'function') { throw new TypeError2(FUNC_ERROR_TEXT2) } start2 = start2 === undefined$1 ? start2 : toInteger2(start2) return baseRest2(func, start2) } function spread3(func, start2) { if (typeof func != 'function') { throw new TypeError2(FUNC_ERROR_TEXT2) } start2 = start2 == null ? 0 : nativeMax2(toInteger2(start2), 0) return baseRest2(function (args) { var array4 = args[start2], otherArgs = castSlice(args, 0, start2) if (array4) { arrayPush2(otherArgs, array4) } return apply2(func, this, otherArgs) }) } function throttle2(func, wait, options2) { var leading = true, trailing = true if (typeof func != 'function') { throw new TypeError2(FUNC_ERROR_TEXT2) } if (isObject2(options2)) { leading = 'leading' in options2 ? !!options2.leading : leading trailing = 'trailing' in options2 ? !!options2.trailing : trailing } return debounce2(func, wait, { leading: leading, maxWait: wait, trailing: trailing, }) } function unary(func) { return ary(func, 1) } function wrap(value2, wrapper) { return partial2(castFunction(wrapper), value2) } function castArray2() { if (!arguments.length) { return [] } var value2 = arguments[0] return isArray3(value2) ? value2 : [value2] } function clone2(value2) { return baseClone2(value2, CLONE_SYMBOLS_FLAG2) } function cloneWith(value2, customizer) { customizer = typeof customizer == 'function' ? customizer : undefined$1 return baseClone2(value2, CLONE_SYMBOLS_FLAG2, customizer) } function cloneDeep2(value2) { return baseClone2(value2, CLONE_DEEP_FLAG2 | CLONE_SYMBOLS_FLAG2) } function cloneDeepWith(value2, customizer) { customizer = typeof customizer == 'function' ? customizer : undefined$1 return baseClone2( value2, CLONE_DEEP_FLAG2 | CLONE_SYMBOLS_FLAG2, customizer ) } function conformsTo(object4, source2) { return ( source2 == null || baseConformsTo(object4, source2, keys3(source2)) ) } function eq2(value2, other) { return value2 === other || (value2 !== value2 && other !== other) } var gt2 = createRelationalOperation(baseGt) var gte = createRelationalOperation(function (value2, other) { return value2 >= other }) var isArguments2 = baseIsArguments2( (function () { return arguments })() ) ? baseIsArguments2 : function (value2) { return ( isObjectLike2(value2) && hasOwnProperty2.call(value2, 'callee') && !propertyIsEnumerable3.call(value2, 'callee') ) } var isArray3 = Array2.isArray var isArrayBuffer2 = nodeIsArrayBuffer ? baseUnary2(nodeIsArrayBuffer) : baseIsArrayBuffer function isArrayLike2(value2) { return ( value2 != null && isLength2(value2.length) && !isFunction2(value2) ) } function isArrayLikeObject2(value2) { return isObjectLike2(value2) && isArrayLike2(value2) } function isBoolean2(value2) { return ( value2 === true || value2 === false || (isObjectLike2(value2) && baseGetTag2(value2) == boolTag2) ) } var isBuffer2 = nativeIsBuffer2 || stubFalse2 var isDate2 = nodeIsDate ? baseUnary2(nodeIsDate) : baseIsDate function isElement2(value2) { return ( isObjectLike2(value2) && value2.nodeType === 1 && !isPlainObject2(value2) ) } function isEmpty2(value2) { if (value2 == null) { return true } if ( isArrayLike2(value2) && (isArray3(value2) || typeof value2 == 'string' || typeof value2.splice == 'function' || isBuffer2(value2) || isTypedArray2(value2) || isArguments2(value2)) ) { return !value2.length } var tag = getTag2(value2) if (tag == mapTag2 || tag == setTag2) { return !value2.size } if (isPrototype2(value2)) { return !baseKeys2(value2).length } for (var key2 in value2) { if (hasOwnProperty2.call(value2, key2)) { return false } } return true } function isEqual2(value2, other) { return baseIsEqual2(value2, other) } function isEqualWith2(value2, other, customizer) { customizer = typeof customizer == 'function' ? customizer : undefined$1 var result2 = customizer ? customizer(value2, other) : undefined$1 return result2 === undefined$1 ? baseIsEqual2(value2, other, undefined$1, customizer) : !!result2 } function isError2(value2) { if (!isObjectLike2(value2)) { return false } var tag = baseGetTag2(value2) return ( tag == errorTag2 || tag == domExcTag || (typeof value2.message == 'string' && typeof value2.name == 'string' && !isPlainObject2(value2)) ) } function isFinite2(value2) { return typeof value2 == 'number' && nativeIsFinite(value2) } function isFunction2(value2) { if (!isObject2(value2)) { return false } var tag = baseGetTag2(value2) return ( tag == funcTag2 || tag == genTag2 || tag == asyncTag2 || tag == proxyTag2 ) } function isInteger2(value2) { return typeof value2 == 'number' && value2 == toInteger2(value2) } function isLength2(value2) { return ( typeof value2 == 'number' && value2 > -1 && value2 % 1 == 0 && value2 <= MAX_SAFE_INTEGER2 ) } function isObject2(value2) { var type4 = typeof value2 return value2 != null && (type4 == 'object' || type4 == 'function') } function isObjectLike2(value2) { return value2 != null && typeof value2 == 'object' } var isMap2 = nodeIsMap2 ? baseUnary2(nodeIsMap2) : baseIsMap2 function isMatch2(object4, source2) { return ( object4 === source2 || baseIsMatch(object4, source2, getMatchData(source2)) ) } function isMatchWith(object4, source2, customizer) { customizer = typeof customizer == 'function' ? customizer : undefined$1 return baseIsMatch(object4, source2, getMatchData(source2), customizer) } function isNaN2(value2) { return isNumber2(value2) && value2 != +value2 } function isNative(value2) { if (isMaskable(value2)) { throw new Error2(CORE_ERROR_TEXT) } return baseIsNative2(value2) } function isNull2(value2) { return value2 === null } function isNil2(value2) { return value2 == null } function isNumber2(value2) { return ( typeof value2 == 'number' || (isObjectLike2(value2) && baseGetTag2(value2) == numberTag2) ) } function isPlainObject2(value2) { if (!isObjectLike2(value2) || baseGetTag2(value2) != objectTag2) { return false } var proto2 = getPrototype2(value2) if (proto2 === null) { return true } var Ctor = hasOwnProperty2.call(proto2, 'constructor') && proto2.constructor return ( typeof Ctor == 'function' && Ctor instanceof Ctor && funcToString2.call(Ctor) == objectCtorString ) } var isRegExp2 = nodeIsRegExp ? baseUnary2(nodeIsRegExp) : baseIsRegExp function isSafeInteger(value2) { return ( isInteger2(value2) && value2 >= -MAX_SAFE_INTEGER2 && value2 <= MAX_SAFE_INTEGER2 ) } var isSet2 = nodeIsSet2 ? baseUnary2(nodeIsSet2) : baseIsSet2 function isString2(value2) { return ( typeof value2 == 'string' || (!isArray3(value2) && isObjectLike2(value2) && baseGetTag2(value2) == stringTag2) ) } function isSymbol2(value2) { return ( typeof value2 == 'symbol' || (isObjectLike2(value2) && baseGetTag2(value2) == symbolTag2) ) } var isTypedArray2 = nodeIsTypedArray2 ? baseUnary2(nodeIsTypedArray2) : baseIsTypedArray2 function isUndefined2(value2) { return value2 === undefined$1 } function isWeakMap2(value2) { return isObjectLike2(value2) && getTag2(value2) == weakMapTag2 } function isWeakSet2(value2) { return isObjectLike2(value2) && baseGetTag2(value2) == weakSetTag } var lt2 = createRelationalOperation(baseLt) var lte = createRelationalOperation(function (value2, other) { return value2 <= other }) function toArray3(value2) { if (!value2) { return [] } if (isArrayLike2(value2)) { return isString2(value2) ? stringToArray(value2) : copyArray2(value2) } if (symIterator && value2[symIterator]) { return iteratorToArray(value2[symIterator]()) } var tag = getTag2(value2), func = tag == mapTag2 ? mapToArray2 : tag == setTag2 ? setToArray2 : values2 return func(value2) } function toFinite(value2) { if (!value2) { return value2 === 0 ? value2 : 0 } value2 = toNumber2(value2) if (value2 === INFINITY2 || value2 === -INFINITY2) { var sign = value2 < 0 ? -1 : 1 return sign * MAX_INTEGER } return value2 === value2 ? value2 : 0 } function toInteger2(value2) { var result2 = toFinite(value2), remainder = result2 % 1 return result2 === result2 ? remainder ? result2 - remainder : result2 : 0 } function toLength2(value2) { return value2 ? baseClamp(toInteger2(value2), 0, MAX_ARRAY_LENGTH) : 0 } function toNumber2(value2) { if (typeof value2 == 'number') { return value2 } if (isSymbol2(value2)) { return NAN2 } if (isObject2(value2)) { var other = typeof value2.valueOf == 'function' ? value2.valueOf() : value2 value2 = isObject2(other) ? other + '' : other } if (typeof value2 != 'string') { return value2 === 0 ? value2 : +value2 } value2 = baseTrim2(value2) var isBinary = reIsBinary2.test(value2) return isBinary || reIsOctal2.test(value2) ? freeParseInt2(value2.slice(2), isBinary ? 2 : 8) : reIsBadHex2.test(value2) ? NAN2 : +value2 } function toPlainObject(value2) { return copyObject2(value2, keysIn2(value2)) } function toSafeInteger(value2) { return value2 ? baseClamp(toInteger2(value2), -MAX_SAFE_INTEGER2, MAX_SAFE_INTEGER2) : value2 === 0 ? value2 : 0 } function toString4(value2) { return value2 == null ? '' : baseToString2(value2) } var assign2 = createAssigner(function (object4, source2) { if (isPrototype2(source2) || isArrayLike2(source2)) { copyObject2(source2, keys3(source2), object4) return } for (var key2 in source2) { if (hasOwnProperty2.call(source2, key2)) { assignValue2(object4, key2, source2[key2]) } } }) var assignIn = createAssigner(function (object4, source2) { copyObject2(source2, keysIn2(source2), object4) }) var assignInWith = createAssigner(function ( object4, source2, srcIndex, customizer ) { copyObject2(source2, keysIn2(source2), object4, customizer) }) var assignWith = createAssigner(function ( object4, source2, srcIndex, customizer ) { copyObject2(source2, keys3(source2), object4, customizer) }) var at2 = flatRest2(baseAt) function create3(prototype, properties) { var result2 = baseCreate2(prototype) return properties == null ? result2 : baseAssign2(result2, properties) } var defaults2 = baseRest2(function (object4, sources) { object4 = Object2(object4) var index2 = -1 var length2 = sources.length var guard = length2 > 2 ? sources[2] : undefined$1 if (guard && isIterateeCall(sources[0], sources[1], guard)) { length2 = 1 } while (++index2 < length2) { var source2 = sources[index2] var props2 = keysIn2(source2) var propsIndex = -1 var propsLength = props2.length while (++propsIndex < propsLength) { var key2 = props2[propsIndex] var value2 = object4[key2] if ( value2 === undefined$1 || (eq2(value2, objectProto2[key2]) && !hasOwnProperty2.call(object4, key2)) ) { object4[key2] = source2[key2] } } } return object4 }) var defaultsDeep = baseRest2(function (args) { args.push(undefined$1, customDefaultsMerge) return apply2(mergeWith, undefined$1, args) }) function findKey2(object4, predicate) { return baseFindKey(object4, getIteratee(predicate, 3), baseForOwn) } function findLastKey(object4, predicate) { return baseFindKey(object4, getIteratee(predicate, 3), baseForOwnRight) } function forIn(object4, iteratee2) { return object4 == null ? object4 : baseFor(object4, getIteratee(iteratee2, 3), keysIn2) } function forInRight(object4, iteratee2) { return object4 == null ? object4 : baseForRight(object4, getIteratee(iteratee2, 3), keysIn2) } function forOwn(object4, iteratee2) { return object4 && baseForOwn(object4, getIteratee(iteratee2, 3)) } function forOwnRight(object4, iteratee2) { return object4 && baseForOwnRight(object4, getIteratee(iteratee2, 3)) } function functions(object4) { return object4 == null ? [] : baseFunctions(object4, keys3(object4)) } function functionsIn(object4) { return object4 == null ? [] : baseFunctions(object4, keysIn2(object4)) } function get3(object4, path, defaultValue) { var result2 = object4 == null ? undefined$1 : baseGet2(object4, path) return result2 === undefined$1 ? defaultValue : result2 } function has2(object4, path) { return object4 != null && hasPath2(object4, path, baseHas) } function hasIn2(object4, path) { return object4 != null && hasPath2(object4, path, baseHasIn2) } var invert2 = createInverter(function (result2, value2, key2) { if (value2 != null && typeof value2.toString != 'function') { value2 = nativeObjectToString2.call(value2) } result2[value2] = key2 }, constant2(identity2)) var invertBy = createInverter(function (result2, value2, key2) { if (value2 != null && typeof value2.toString != 'function') { value2 = nativeObjectToString2.call(value2) } if (hasOwnProperty2.call(result2, value2)) { result2[value2].push(key2) } else { result2[value2] = [key2] } }, getIteratee) var invoke2 = baseRest2(baseInvoke) function keys3(object4) { return isArrayLike2(object4) ? arrayLikeKeys2(object4) : baseKeys2(object4) } function keysIn2(object4) { return isArrayLike2(object4) ? arrayLikeKeys2(object4, true) : baseKeysIn2(object4) } function mapKeys(object4, iteratee2) { var result2 = {} iteratee2 = getIteratee(iteratee2, 3) baseForOwn(object4, function (value2, key2, object5) { baseAssignValue2(result2, iteratee2(value2, key2, object5), value2) }) return result2 } function mapValues(object4, iteratee2) { var result2 = {} iteratee2 = getIteratee(iteratee2, 3) baseForOwn(object4, function (value2, key2, object5) { baseAssignValue2(result2, key2, iteratee2(value2, key2, object5)) }) return result2 } var merge2 = createAssigner(function (object4, source2, srcIndex) { baseMerge(object4, source2, srcIndex) }) var mergeWith = createAssigner(function ( object4, source2, srcIndex, customizer ) { baseMerge(object4, source2, srcIndex, customizer) }) var omit2 = flatRest2(function (object4, paths) { var result2 = {} if (object4 == null) { return result2 } var isDeep = false paths = arrayMap2(paths, function (path) { path = castPath2(path, object4) isDeep || (isDeep = path.length > 1) return path }) copyObject2(object4, getAllKeysIn2(object4), result2) if (isDeep) { result2 = baseClone2( result2, CLONE_DEEP_FLAG2 | CLONE_FLAT_FLAG2 | CLONE_SYMBOLS_FLAG2, customOmitClone ) } var length2 = paths.length while (length2--) { baseUnset(result2, paths[length2]) } return result2 }) function omitBy(object4, predicate) { return pickBy(object4, negate2(getIteratee(predicate))) } var pick2 = flatRest2(function (object4, paths) { return object4 == null ? {} : basePick2(object4, paths) }) function pickBy(object4, predicate) { if (object4 == null) { return {} } var props2 = arrayMap2(getAllKeysIn2(object4), function (prop) { return [prop] }) predicate = getIteratee(predicate) return basePickBy2(object4, props2, function (value2, path) { return predicate(value2, path[0]) }) } function result(object4, path, defaultValue) { path = castPath2(path, object4) var index2 = -1, length2 = path.length if (!length2) { length2 = 1 object4 = undefined$1 } while (++index2 < length2) { var value2 = object4 == null ? undefined$1 : object4[toKey2(path[index2])] if (value2 === undefined$1) { index2 = length2 value2 = defaultValue } object4 = isFunction2(value2) ? value2.call(object4) : value2 } return object4 } function set2(object4, path, value2) { return object4 == null ? object4 : baseSet2(object4, path, value2) } function setWith(object4, path, value2, customizer) { customizer = typeof customizer == 'function' ? customizer : undefined$1 return object4 == null ? object4 : baseSet2(object4, path, value2, customizer) } var toPairs = createToPairs(keys3) var toPairsIn = createToPairs(keysIn2) function transform3(object4, iteratee2, accumulator) { var isArr = isArray3(object4), isArrLike = isArr || isBuffer2(object4) || isTypedArray2(object4) iteratee2 = getIteratee(iteratee2, 4) if (accumulator == null) { var Ctor = object4 && object4.constructor if (isArrLike) { accumulator = isArr ? new Ctor() : [] } else if (isObject2(object4)) { accumulator = isFunction2(Ctor) ? baseCreate2(getPrototype2(object4)) : {} } else { accumulator = {} } } ;(isArrLike ? arrayEach2 : baseForOwn)( object4, function (value2, index2, object5) { return iteratee2(accumulator, value2, index2, object5) } ) return accumulator } function unset(object4, path) { return object4 == null ? true : baseUnset(object4, path) } function update3(object4, path, updater) { return object4 == null ? object4 : baseUpdate(object4, path, castFunction(updater)) } function updateWith(object4, path, updater, customizer) { customizer = typeof customizer == 'function' ? customizer : undefined$1 return object4 == null ? object4 : baseUpdate(object4, path, castFunction(updater), customizer) } function values2(object4) { return object4 == null ? [] : baseValues(object4, keys3(object4)) } function valuesIn(object4) { return object4 == null ? [] : baseValues(object4, keysIn2(object4)) } function clamp2(number4, lower, upper) { if (upper === undefined$1) { upper = lower lower = undefined$1 } if (upper !== undefined$1) { upper = toNumber2(upper) upper = upper === upper ? upper : 0 } if (lower !== undefined$1) { lower = toNumber2(lower) lower = lower === lower ? lower : 0 } return baseClamp(toNumber2(number4), lower, upper) } function inRange(number4, start2, end2) { start2 = toFinite(start2) if (end2 === undefined$1) { end2 = start2 start2 = 0 } else { end2 = toFinite(end2) } number4 = toNumber2(number4) return baseInRange(number4, start2, end2) } function random2(lower, upper, floating) { if ( floating && typeof floating != 'boolean' && isIterateeCall(lower, upper, floating) ) { upper = floating = undefined$1 } if (floating === undefined$1) { if (typeof upper == 'boolean') { floating = upper upper = undefined$1 } else if (typeof lower == 'boolean') { floating = lower lower = undefined$1 } } if (lower === undefined$1 && upper === undefined$1) { lower = 0 upper = 1 } else { lower = toFinite(lower) if (upper === undefined$1) { upper = lower lower = 0 } else { upper = toFinite(upper) } } if (lower > upper) { var temp = lower lower = upper upper = temp } if (floating || lower % 1 || upper % 1) { var rand2 = nativeRandom() return nativeMin2( lower + rand2 * (upper - lower + freeParseFloat('1e-' + ((rand2 + '').length - 1))), upper ) } return baseRandom(lower, upper) } var camelCase2 = createCompounder(function (result2, word, index2) { word = word.toLowerCase() return result2 + (index2 ? capitalize2(word) : word) }) function capitalize2(string3) { return upperFirst(toString4(string3).toLowerCase()) } function deburr(string3) { string3 = toString4(string3) return ( string3 && string3.replace(reLatin, deburrLetter).replace(reComboMark, '') ) } function endsWith3(string3, target2, position2) { string3 = toString4(string3) target2 = baseToString2(target2) var length2 = string3.length position2 = position2 === undefined$1 ? length2 : baseClamp(toInteger2(position2), 0, length2) var end2 = position2 position2 -= target2.length return position2 >= 0 && string3.slice(position2, end2) == target2 } function escape2(string3) { string3 = toString4(string3) return string3 && reHasUnescapedHtml.test(string3) ? string3.replace(reUnescapedHtml, escapeHtmlChar) : string3 } function escapeRegExp(string3) { string3 = toString4(string3) return string3 && reHasRegExpChar.test(string3) ? string3.replace(reRegExpChar2, '\\$&') : string3 } var kebabCase2 = createCompounder(function (result2, word, index2) { return result2 + (index2 ? '-' : '') + word.toLowerCase() }) var lowerCase = createCompounder(function (result2, word, index2) { return result2 + (index2 ? ' ' : '') + word.toLowerCase() }) var lowerFirst = createCaseFirst('toLowerCase') function pad3(string3, length2, chars2) { string3 = toString4(string3) length2 = toInteger2(length2) var strLength = length2 ? stringSize(string3) : 0 if (!length2 || strLength >= length2) { return string3 } var mid = (length2 - strLength) / 2 return ( createPadding(nativeFloor(mid), chars2) + string3 + createPadding(nativeCeil(mid), chars2) ) } function padEnd2(string3, length2, chars2) { string3 = toString4(string3) length2 = toInteger2(length2) var strLength = length2 ? stringSize(string3) : 0 return length2 && strLength < length2 ? string3 + createPadding(length2 - strLength, chars2) : string3 } function padStart2(string3, length2, chars2) { string3 = toString4(string3) length2 = toInteger2(length2) var strLength = length2 ? stringSize(string3) : 0 return length2 && strLength < length2 ? createPadding(length2 - strLength, chars2) + string3 : string3 } function parseInt2(string3, radix, guard) { if (guard || radix == null) { radix = 0 } else if (radix) { radix = +radix } return nativeParseInt( toString4(string3).replace(reTrimStart2, ''), radix || 0 ) } function repeat2(string3, n2, guard) { if (guard ? isIterateeCall(string3, n2, guard) : n2 === undefined$1) { n2 = 1 } else { n2 = toInteger2(n2) } return baseRepeat(toString4(string3), n2) } function replace2() { var args = arguments, string3 = toString4(args[0]) return args.length < 3 ? string3 : string3.replace(args[1], args[2]) } var snakeCase = createCompounder(function (result2, word, index2) { return result2 + (index2 ? '_' : '') + word.toLowerCase() }) function split2(string3, separator, limit2) { if ( limit2 && typeof limit2 != 'number' && isIterateeCall(string3, separator, limit2) ) { separator = limit2 = undefined$1 } limit2 = limit2 === undefined$1 ? MAX_ARRAY_LENGTH : limit2 >>> 0 if (!limit2) { return [] } string3 = toString4(string3) if ( string3 && (typeof separator == 'string' || (separator != null && !isRegExp2(separator))) ) { separator = baseToString2(separator) if (!separator && hasUnicode(string3)) { return castSlice(stringToArray(string3), 0, limit2) } } return string3.split(separator, limit2) } var startCase = createCompounder(function (result2, word, index2) { return result2 + (index2 ? ' ' : '') + upperFirst(word) }) function startsWith3(string3, target2, position2) { string3 = toString4(string3) position2 = position2 == null ? 0 : baseClamp(toInteger2(position2), 0, string3.length) target2 = baseToString2(target2) return string3.slice(position2, position2 + target2.length) == target2 } function template2(string3, options2, guard) { var settings = lodash2.templateSettings if (guard && isIterateeCall(string3, options2, guard)) { options2 = undefined$1 } string3 = toString4(string3) options2 = assignInWith({}, options2, settings, customDefaultsAssignIn) var imports = assignInWith( {}, options2.imports, settings.imports, customDefaultsAssignIn ), importsKeys = keys3(imports), importsValues = baseValues(imports, importsKeys) var isEscaping, isEvaluating, index2 = 0, interpolate = options2.interpolate || reNoMatch, source2 = "__p += '" var reDelimiters = RegExp2( (options2.escape || reNoMatch).source + '|' + interpolate.source + '|' + (interpolate === reInterpolate ? reEsTemplate : reNoMatch).source + '|' + (options2.evaluate || reNoMatch).source + '|$', 'g' ) var sourceURL = '//# sourceURL=' + (hasOwnProperty2.call(options2, 'sourceURL') ? (options2.sourceURL + '').replace(/\s/g, ' ') : 'lodash.templateSources[' + ++templateCounter + ']') + '\n' string3.replace( reDelimiters, function ( match2, escapeValue, interpolateValue, esTemplateValue, evaluateValue, offset2 ) { interpolateValue || (interpolateValue = esTemplateValue) source2 += string3 .slice(index2, offset2) .replace(reUnescapedString, escapeStringChar) if (escapeValue) { isEscaping = true source2 += "' +\n__e(" + escapeValue + ") +\n'" } if (evaluateValue) { isEvaluating = true source2 += "';\n" + evaluateValue + ";\n__p += '" } if (interpolateValue) { source2 += "' +\n((__t = (" + interpolateValue + ")) == null ? '' : __t) +\n'" } index2 = offset2 + match2.length return match2 } ) source2 += "';\n" var variable = hasOwnProperty2.call(options2, 'variable') && options2.variable if (!variable) { source2 = 'with (obj) {\n' + source2 + '\n}\n' } else if (reForbiddenIdentifierChars.test(variable)) { throw new Error2(INVALID_TEMPL_VAR_ERROR_TEXT) } source2 = ( isEvaluating ? source2.replace(reEmptyStringLeading, '') : source2 ) .replace(reEmptyStringMiddle, '$1') .replace(reEmptyStringTrailing, '$1;') source2 = 'function(' + (variable || 'obj') + ') {\n' + (variable ? '' : 'obj || (obj = {});\n') + "var __t, __p = ''" + (isEscaping ? ', __e = _.escape' : '') + (isEvaluating ? ", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n" : ';\n') + source2 + 'return __p\n}' var result2 = attempt(function () { return Function2(importsKeys, sourceURL + 'return ' + source2).apply( undefined$1, importsValues ) }) result2.source = source2 if (isError2(result2)) { throw result2 } return result2 } function toLower(value2) { return toString4(value2).toLowerCase() } function toUpper(value2) { return toString4(value2).toUpperCase() } function trim3(string3, chars2, guard) { string3 = toString4(string3) if (string3 && (guard || chars2 === undefined$1)) { return baseTrim2(string3) } if (!string3 || !(chars2 = baseToString2(chars2))) { return string3 } var strSymbols = stringToArray(string3), chrSymbols = stringToArray(chars2), start2 = charsStartIndex(strSymbols, chrSymbols), end2 = charsEndIndex(strSymbols, chrSymbols) + 1 return castSlice(strSymbols, start2, end2).join('') } function trimEnd(string3, chars2, guard) { string3 = toString4(string3) if (string3 && (guard || chars2 === undefined$1)) { return string3.slice(0, trimmedEndIndex2(string3) + 1) } if (!string3 || !(chars2 = baseToString2(chars2))) { return string3 } var strSymbols = stringToArray(string3), end2 = charsEndIndex(strSymbols, stringToArray(chars2)) + 1 return castSlice(strSymbols, 0, end2).join('') } function trimStart(string3, chars2, guard) { string3 = toString4(string3) if (string3 && (guard || chars2 === undefined$1)) { return string3.replace(reTrimStart2, '') } if (!string3 || !(chars2 = baseToString2(chars2))) { return string3 } var strSymbols = stringToArray(string3), start2 = charsStartIndex(strSymbols, stringToArray(chars2)) return castSlice(strSymbols, start2).join('') } function truncate(string3, options2) { var length2 = DEFAULT_TRUNC_LENGTH, omission = DEFAULT_TRUNC_OMISSION if (isObject2(options2)) { var separator = 'separator' in options2 ? options2.separator : separator length2 = 'length' in options2 ? toInteger2(options2.length) : length2 omission = 'omission' in options2 ? baseToString2(options2.omission) : omission } string3 = toString4(string3) var strLength = string3.length if (hasUnicode(string3)) { var strSymbols = stringToArray(string3) strLength = strSymbols.length } if (length2 >= strLength) { return string3 } var end2 = length2 - stringSize(omission) if (end2 < 1) { return omission } var result2 = strSymbols ? castSlice(strSymbols, 0, end2).join('') : string3.slice(0, end2) if (separator === undefined$1) { return result2 + omission } if (strSymbols) { end2 += result2.length - end2 } if (isRegExp2(separator)) { if (string3.slice(end2).search(separator)) { var match2, substring = result2 if (!separator.global) { separator = RegExp2( separator.source, toString4(reFlags2.exec(separator)) + 'g' ) } separator.lastIndex = 0 while ((match2 = separator.exec(substring))) { var newEnd = match2.index } result2 = result2.slice(0, newEnd === undefined$1 ? end2 : newEnd) } } else if (string3.indexOf(baseToString2(separator), end2) != end2) { var index2 = result2.lastIndexOf(separator) if (index2 > -1) { result2 = result2.slice(0, index2) } } return result2 + omission } function unescape2(string3) { string3 = toString4(string3) return string3 && reHasEscapedHtml.test(string3) ? string3.replace(reEscapedHtml, unescapeHtmlChar) : string3 } var upperCase = createCompounder(function (result2, word, index2) { return result2 + (index2 ? ' ' : '') + word.toUpperCase() }) var upperFirst = createCaseFirst('toUpperCase') function words(string3, pattern4, guard) { string3 = toString4(string3) pattern4 = guard ? undefined$1 : pattern4 if (pattern4 === undefined$1) { return hasUnicodeWord(string3) ? unicodeWords(string3) : asciiWords(string3) } return string3.match(pattern4) || [] } var attempt = baseRest2(function (func, args) { try { return apply2(func, undefined$1, args) } catch (e2) { return isError2(e2) ? e2 : new Error2(e2) } }) var bindAll = flatRest2(function (object4, methodNames) { arrayEach2(methodNames, function (key2) { key2 = toKey2(key2) baseAssignValue2(object4, key2, bind3(object4[key2], object4)) }) return object4 }) function cond(pairs) { var length2 = pairs == null ? 0 : pairs.length, toIteratee = getIteratee() pairs = !length2 ? [] : arrayMap2(pairs, function (pair) { if (typeof pair[1] != 'function') { throw new TypeError2(FUNC_ERROR_TEXT2) } return [toIteratee(pair[0]), pair[1]] }) return baseRest2(function (args) { var index2 = -1 while (++index2 < length2) { var pair = pairs[index2] if (apply2(pair[0], this, args)) { return apply2(pair[1], this, args) } } }) } function conforms(source2) { return baseConforms(baseClone2(source2, CLONE_DEEP_FLAG2)) } function constant2(value2) { return function () { return value2 } } function defaultTo(value2, defaultValue) { return value2 == null || value2 !== value2 ? defaultValue : value2 } var flow = createFlow() var flowRight = createFlow(true) function identity2(value2) { return value2 } function iteratee(func) { return baseIteratee( typeof func == 'function' ? func : baseClone2(func, CLONE_DEEP_FLAG2) ) } function matches2(source2) { return baseMatches(baseClone2(source2, CLONE_DEEP_FLAG2)) } function matchesProperty(path, srcValue) { return baseMatchesProperty(path, baseClone2(srcValue, CLONE_DEEP_FLAG2)) } var method4 = baseRest2(function (path, args) { return function (object4) { return baseInvoke(object4, path, args) } }) var methodOf = baseRest2(function (object4, args) { return function (path) { return baseInvoke(object4, path, args) } }) function mixin2(object4, source2, options2) { var props2 = keys3(source2), methodNames = baseFunctions(source2, props2) if ( options2 == null && !(isObject2(source2) && (methodNames.length || !props2.length)) ) { options2 = source2 source2 = object4 object4 = this methodNames = baseFunctions(source2, keys3(source2)) } var chain2 = !(isObject2(options2) && 'chain' in options2) || !!options2.chain, isFunc = isFunction2(object4) arrayEach2(methodNames, function (methodName) { var func = source2[methodName] object4[methodName] = func if (isFunc) { object4.prototype[methodName] = function () { var chainAll = this.__chain__ if (chain2 || chainAll) { var result2 = object4(this.__wrapped__), actions2 = (result2.__actions__ = copyArray2( this.__actions__ )) actions2.push({ func: func, args: arguments, thisArg: object4 }) result2.__chain__ = chainAll return result2 } return func.apply(object4, arrayPush2([this.value()], arguments)) } } }) return object4 } function noConflict() { if (root2._ === this) { root2._ = oldDash } return this } function noop2() {} function nthArg(n2) { n2 = toInteger2(n2) return baseRest2(function (args) { return baseNth(args, n2) }) } var over = createOver(arrayMap2) var overEvery = createOver(arrayEvery) var overSome = createOver(arraySome2) function property2(path) { return isKey2(path) ? baseProperty(toKey2(path)) : basePropertyDeep(path) } function propertyOf(object4) { return function (path) { return object4 == null ? undefined$1 : baseGet2(object4, path) } } var range3 = createRange2() var rangeRight = createRange2(true) function stubArray2() { return [] } function stubFalse2() { return false } function stubObject() { return {} } function stubString() { return '' } function stubTrue() { return true } function times(n2, iteratee2) { n2 = toInteger2(n2) if (n2 < 1 || n2 > MAX_SAFE_INTEGER2) { return [] } var index2 = MAX_ARRAY_LENGTH, length2 = nativeMin2(n2, MAX_ARRAY_LENGTH) iteratee2 = getIteratee(iteratee2) n2 -= MAX_ARRAY_LENGTH var result2 = baseTimes2(length2, iteratee2) while (++index2 < n2) { iteratee2(index2) } return result2 } function toPath(value2) { if (isArray3(value2)) { return arrayMap2(value2, toKey2) } return isSymbol2(value2) ? [value2] : copyArray2(stringToPath2(toString4(value2))) } function uniqueId2(prefix) { var id2 = ++idCounter return toString4(prefix) + id2 } var add2 = createMathOperation(function (augend, addend) { return augend + addend }, 0) var ceil2 = createRound('ceil') var divide2 = createMathOperation(function (dividend, divisor) { return dividend / divisor }, 1) var floor2 = createRound('floor') function max3(array4) { return array4 && array4.length ? baseExtremum(array4, identity2, baseGt) : undefined$1 } function maxBy(array4, iteratee2) { return array4 && array4.length ? baseExtremum(array4, getIteratee(iteratee2, 2), baseGt) : undefined$1 } function mean2(array4) { return baseMean(array4, identity2) } function meanBy(array4, iteratee2) { return baseMean(array4, getIteratee(iteratee2, 2)) } function min3(array4) { return array4 && array4.length ? baseExtremum(array4, identity2, baseLt) : undefined$1 } function minBy(array4, iteratee2) { return array4 && array4.length ? baseExtremum(array4, getIteratee(iteratee2, 2), baseLt) : undefined$1 } var multiply2 = createMathOperation(function (multiplier, multiplicand) { return multiplier * multiplicand }, 1) var round2 = createRound('round') var subtract2 = createMathOperation(function (minuend, subtrahend) { return minuend - subtrahend }, 0) function sum2(array4) { return array4 && array4.length ? baseSum(array4, identity2) : 0 } function sumBy(array4, iteratee2) { return array4 && array4.length ? baseSum(array4, getIteratee(iteratee2, 2)) : 0 } lodash2.after = after2 lodash2.ary = ary lodash2.assign = assign2 lodash2.assignIn = assignIn lodash2.assignInWith = assignInWith lodash2.assignWith = assignWith lodash2.at = at2 lodash2.before = before2 lodash2.bind = bind3 lodash2.bindAll = bindAll lodash2.bindKey = bindKey lodash2.castArray = castArray2 lodash2.chain = chain lodash2.chunk = chunk2 lodash2.compact = compact lodash2.concat = concat2 lodash2.cond = cond lodash2.conforms = conforms lodash2.constant = constant2 lodash2.countBy = countBy2 lodash2.create = create3 lodash2.curry = curry2 lodash2.curryRight = curryRight lodash2.debounce = debounce2 lodash2.defaults = defaults2 lodash2.defaultsDeep = defaultsDeep lodash2.defer = defer2 lodash2.delay = delay2 lodash2.difference = difference lodash2.differenceBy = differenceBy lodash2.differenceWith = differenceWith lodash2.drop = drop3 lodash2.dropRight = dropRight lodash2.dropRightWhile = dropRightWhile lodash2.dropWhile = dropWhile lodash2.fill = fill lodash2.filter = filter2 lodash2.flatMap = flatMap lodash2.flatMapDeep = flatMapDeep lodash2.flatMapDepth = flatMapDepth lodash2.flatten = flatten2 lodash2.flattenDeep = flattenDeep2 lodash2.flattenDepth = flattenDepth lodash2.flip = flip2 lodash2.flow = flow lodash2.flowRight = flowRight lodash2.fromPairs = fromPairs2 lodash2.functions = functions lodash2.functionsIn = functionsIn lodash2.groupBy = groupBy2 lodash2.initial = initial lodash2.intersection = intersection lodash2.intersectionBy = intersectionBy lodash2.intersectionWith = intersectionWith lodash2.invert = invert2 lodash2.invertBy = invertBy lodash2.invokeMap = invokeMap lodash2.iteratee = iteratee lodash2.keyBy = keyBy lodash2.keys = keys3 lodash2.keysIn = keysIn2 lodash2.map = map2 lodash2.mapKeys = mapKeys lodash2.mapValues = mapValues lodash2.matches = matches2 lodash2.matchesProperty = matchesProperty lodash2.memoize = memoize2 lodash2.merge = merge2 lodash2.mergeWith = mergeWith lodash2.method = method4 lodash2.methodOf = methodOf lodash2.mixin = mixin2 lodash2.negate = negate2 lodash2.nthArg = nthArg lodash2.omit = omit2 lodash2.omitBy = omitBy lodash2.once = once2 lodash2.orderBy = orderBy2 lodash2.over = over lodash2.overArgs = overArgs lodash2.overEvery = overEvery lodash2.overSome = overSome lodash2.partial = partial2 lodash2.partialRight = partialRight lodash2.partition = partition lodash2.pick = pick2 lodash2.pickBy = pickBy lodash2.property = property2 lodash2.propertyOf = propertyOf lodash2.pull = pull lodash2.pullAll = pullAll lodash2.pullAllBy = pullAllBy lodash2.pullAllWith = pullAllWith lodash2.pullAt = pullAt lodash2.range = range3 lodash2.rangeRight = rangeRight lodash2.rearg = rearg lodash2.reject = reject2 lodash2.remove = remove2 lodash2.rest = rest lodash2.reverse = reverse3 lodash2.sampleSize = sampleSize lodash2.set = set2 lodash2.setWith = setWith lodash2.shuffle = shuffle2 lodash2.slice = slice2 lodash2.sortBy = sortBy2 lodash2.sortedUniq = sortedUniq lodash2.sortedUniqBy = sortedUniqBy lodash2.split = split2 lodash2.spread = spread3 lodash2.tail = tail lodash2.take = take2 lodash2.takeRight = takeRight lodash2.takeRightWhile = takeRightWhile lodash2.takeWhile = takeWhile lodash2.tap = tap lodash2.throttle = throttle2 lodash2.thru = thru lodash2.toArray = toArray3 lodash2.toPairs = toPairs lodash2.toPairsIn = toPairsIn lodash2.toPath = toPath lodash2.toPlainObject = toPlainObject lodash2.transform = transform3 lodash2.unary = unary lodash2.union = union2 lodash2.unionBy = unionBy lodash2.unionWith = unionWith lodash2.uniq = uniq2 lodash2.uniqBy = uniqBy lodash2.uniqWith = uniqWith lodash2.unset = unset lodash2.unzip = unzip2 lodash2.unzipWith = unzipWith lodash2.update = update3 lodash2.updateWith = updateWith lodash2.values = values2 lodash2.valuesIn = valuesIn lodash2.without = without lodash2.words = words lodash2.wrap = wrap lodash2.xor = xor lodash2.xorBy = xorBy lodash2.xorWith = xorWith lodash2.zip = zip2 lodash2.zipObject = zipObject2 lodash2.zipObjectDeep = zipObjectDeep lodash2.zipWith = zipWith lodash2.entries = toPairs lodash2.entriesIn = toPairsIn lodash2.extend = assignIn lodash2.extendWith = assignInWith mixin2(lodash2, lodash2) lodash2.add = add2 lodash2.attempt = attempt lodash2.camelCase = camelCase2 lodash2.capitalize = capitalize2 lodash2.ceil = ceil2 lodash2.clamp = clamp2 lodash2.clone = clone2 lodash2.cloneDeep = cloneDeep2 lodash2.cloneDeepWith = cloneDeepWith lodash2.cloneWith = cloneWith lodash2.conformsTo = conformsTo lodash2.deburr = deburr lodash2.defaultTo = defaultTo lodash2.divide = divide2 lodash2.endsWith = endsWith3 lodash2.eq = eq2 lodash2.escape = escape2 lodash2.escapeRegExp = escapeRegExp lodash2.every = every2 lodash2.find = find2 lodash2.findIndex = findIndex lodash2.findKey = findKey2 lodash2.findLast = findLast2 lodash2.findLastIndex = findLastIndex lodash2.findLastKey = findLastKey lodash2.floor = floor2 lodash2.forEach = forEach3 lodash2.forEachRight = forEachRight lodash2.forIn = forIn lodash2.forInRight = forInRight lodash2.forOwn = forOwn lodash2.forOwnRight = forOwnRight lodash2.get = get3 lodash2.gt = gt2 lodash2.gte = gte lodash2.has = has2 lodash2.hasIn = hasIn2 lodash2.head = head lodash2.identity = identity2 lodash2.includes = includes3 lodash2.indexOf = indexOf3 lodash2.inRange = inRange lodash2.invoke = invoke2 lodash2.isArguments = isArguments2 lodash2.isArray = isArray3 lodash2.isArrayBuffer = isArrayBuffer2 lodash2.isArrayLike = isArrayLike2 lodash2.isArrayLikeObject = isArrayLikeObject2 lodash2.isBoolean = isBoolean2 lodash2.isBuffer = isBuffer2 lodash2.isDate = isDate2 lodash2.isElement = isElement2 lodash2.isEmpty = isEmpty2 lodash2.isEqual = isEqual2 lodash2.isEqualWith = isEqualWith2 lodash2.isError = isError2 lodash2.isFinite = isFinite2 lodash2.isFunction = isFunction2 lodash2.isInteger = isInteger2 lodash2.isLength = isLength2 lodash2.isMap = isMap2 lodash2.isMatch = isMatch2 lodash2.isMatchWith = isMatchWith lodash2.isNaN = isNaN2 lodash2.isNative = isNative lodash2.isNil = isNil2 lodash2.isNull = isNull2 lodash2.isNumber = isNumber2 lodash2.isObject = isObject2 lodash2.isObjectLike = isObjectLike2 lodash2.isPlainObject = isPlainObject2 lodash2.isRegExp = isRegExp2 lodash2.isSafeInteger = isSafeInteger lodash2.isSet = isSet2 lodash2.isString = isString2 lodash2.isSymbol = isSymbol2 lodash2.isTypedArray = isTypedArray2 lodash2.isUndefined = isUndefined2 lodash2.isWeakMap = isWeakMap2 lodash2.isWeakSet = isWeakSet2 lodash2.join = join2 lodash2.kebabCase = kebabCase2 lodash2.last = last2 lodash2.lastIndexOf = lastIndexOf2 lodash2.lowerCase = lowerCase lodash2.lowerFirst = lowerFirst lodash2.lt = lt2 lodash2.lte = lte lodash2.max = max3 lodash2.maxBy = maxBy lodash2.mean = mean2 lodash2.meanBy = meanBy lodash2.min = min3 lodash2.minBy = minBy lodash2.stubArray = stubArray2 lodash2.stubFalse = stubFalse2 lodash2.stubObject = stubObject lodash2.stubString = stubString lodash2.stubTrue = stubTrue lodash2.multiply = multiply2 lodash2.nth = nth lodash2.noConflict = noConflict lodash2.noop = noop2 lodash2.now = now2 lodash2.pad = pad3 lodash2.padEnd = padEnd2 lodash2.padStart = padStart2 lodash2.parseInt = parseInt2 lodash2.random = random2 lodash2.reduce = reduce3 lodash2.reduceRight = reduceRight lodash2.repeat = repeat2 lodash2.replace = replace2 lodash2.result = result lodash2.round = round2 lodash2.runInContext = runInContext2 lodash2.sample = sample2 lodash2.size = size lodash2.snakeCase = snakeCase lodash2.some = some2 lodash2.sortedIndex = sortedIndex lodash2.sortedIndexBy = sortedIndexBy lodash2.sortedIndexOf = sortedIndexOf lodash2.sortedLastIndex = sortedLastIndex lodash2.sortedLastIndexBy = sortedLastIndexBy lodash2.sortedLastIndexOf = sortedLastIndexOf lodash2.startCase = startCase lodash2.startsWith = startsWith3 lodash2.subtract = subtract2 lodash2.sum = sum2 lodash2.sumBy = sumBy lodash2.template = template2 lodash2.times = times lodash2.toFinite = toFinite lodash2.toInteger = toInteger2 lodash2.toLength = toLength2 lodash2.toLower = toLower lodash2.toNumber = toNumber2 lodash2.toSafeInteger = toSafeInteger lodash2.toString = toString4 lodash2.toUpper = toUpper lodash2.trim = trim3 lodash2.trimEnd = trimEnd lodash2.trimStart = trimStart lodash2.truncate = truncate lodash2.unescape = unescape2 lodash2.uniqueId = uniqueId2 lodash2.upperCase = upperCase lodash2.upperFirst = upperFirst lodash2.each = forEach3 lodash2.eachRight = forEachRight lodash2.first = head mixin2( lodash2, (function () { var source2 = {} baseForOwn(lodash2, function (func, methodName) { if (!hasOwnProperty2.call(lodash2.prototype, methodName)) { source2[methodName] = func } }) return source2 })(), { chain: false } ) lodash2.VERSION = VERSION2 arrayEach2( ['bind', 'bindKey', 'curry', 'curryRight', 'partial', 'partialRight'], function (methodName) { lodash2[methodName].placeholder = lodash2 } ) arrayEach2(['drop', 'take'], function (methodName, index2) { LazyWrapper.prototype[methodName] = function (n2) { n2 = n2 === undefined$1 ? 1 : nativeMax2(toInteger2(n2), 0) var result2 = this.__filtered__ && !index2 ? new LazyWrapper(this) : this.clone() if (result2.__filtered__) { result2.__takeCount__ = nativeMin2(n2, result2.__takeCount__) } else { result2.__views__.push({ size: nativeMin2(n2, MAX_ARRAY_LENGTH), type: methodName + (result2.__dir__ < 0 ? 'Right' : ''), }) } return result2 } LazyWrapper.prototype[methodName + 'Right'] = function (n2) { return this.reverse()[methodName](n2).reverse() } }) arrayEach2(['filter', 'map', 'takeWhile'], function (methodName, index2) { var type4 = index2 + 1, isFilter = type4 == LAZY_FILTER_FLAG || type4 == LAZY_WHILE_FLAG LazyWrapper.prototype[methodName] = function (iteratee2) { var result2 = this.clone() result2.__iteratees__.push({ iteratee: getIteratee(iteratee2, 3), type: type4, }) result2.__filtered__ = result2.__filtered__ || isFilter return result2 } }) arrayEach2(['head', 'last'], function (methodName, index2) { var takeName = 'take' + (index2 ? 'Right' : '') LazyWrapper.prototype[methodName] = function () { return this[takeName](1).value()[0] } }) arrayEach2(['initial', 'tail'], function (methodName, index2) { var dropName = 'drop' + (index2 ? '' : 'Right') LazyWrapper.prototype[methodName] = function () { return this.__filtered__ ? new LazyWrapper(this) : this[dropName](1) } }) LazyWrapper.prototype.compact = function () { return this.filter(identity2) } LazyWrapper.prototype.find = function (predicate) { return this.filter(predicate).head() } LazyWrapper.prototype.findLast = function (predicate) { return this.reverse().find(predicate) } LazyWrapper.prototype.invokeMap = baseRest2(function (path, args) { if (typeof path == 'function') { return new LazyWrapper(this) } return this.map(function (value2) { return baseInvoke(value2, path, args) }) }) LazyWrapper.prototype.reject = function (predicate) { return this.filter(negate2(getIteratee(predicate))) } LazyWrapper.prototype.slice = function (start2, end2) { start2 = toInteger2(start2) var result2 = this if (result2.__filtered__ && (start2 > 0 || end2 < 0)) { return new LazyWrapper(result2) } if (start2 < 0) { result2 = result2.takeRight(-start2) } else if (start2) { result2 = result2.drop(start2) } if (end2 !== undefined$1) { end2 = toInteger2(end2) result2 = end2 < 0 ? result2.dropRight(-end2) : result2.take(end2 - start2) } return result2 } LazyWrapper.prototype.takeRightWhile = function (predicate) { return this.reverse().takeWhile(predicate).reverse() } LazyWrapper.prototype.toArray = function () { return this.take(MAX_ARRAY_LENGTH) } baseForOwn(LazyWrapper.prototype, function (func, methodName) { var checkIteratee = /^(?:filter|find|map|reject)|While$/.test( methodName ), isTaker = /^(?:head|last)$/.test(methodName), lodashFunc = lodash2[ isTaker ? 'take' + (methodName == 'last' ? 'Right' : '') : methodName ], retUnwrapped = isTaker || /^find/.test(methodName) if (!lodashFunc) { return } lodash2.prototype[methodName] = function () { var value2 = this.__wrapped__, args = isTaker ? [1] : arguments, isLazy = value2 instanceof LazyWrapper, iteratee2 = args[0], useLazy = isLazy || isArray3(value2) var interceptor2 = function (value3) { var result3 = lodashFunc.apply(lodash2, arrayPush2([value3], args)) return isTaker && chainAll ? result3[0] : result3 } if ( useLazy && checkIteratee && typeof iteratee2 == 'function' && iteratee2.length != 1 ) { isLazy = useLazy = false } var chainAll = this.__chain__, isHybrid = !!this.__actions__.length, isUnwrapped = retUnwrapped && !chainAll, onlyLazy = isLazy && !isHybrid if (!retUnwrapped && useLazy) { value2 = onlyLazy ? value2 : new LazyWrapper(this) var result2 = func.apply(value2, args) result2.__actions__.push({ func: thru, args: [interceptor2], thisArg: undefined$1, }) return new LodashWrapper(result2, chainAll) } if (isUnwrapped && onlyLazy) { return func.apply(this, args) } result2 = this.thru(interceptor2) return isUnwrapped ? isTaker ? result2.value()[0] : result2.value() : result2 } }) arrayEach2( ['pop', 'push', 'shift', 'sort', 'splice', 'unshift'], function (methodName) { var func = arrayProto2[methodName], chainName = /^(?:push|sort|unshift)$/.test(methodName) ? 'tap' : 'thru', retUnwrapped = /^(?:pop|shift)$/.test(methodName) lodash2.prototype[methodName] = function () { var args = arguments if (retUnwrapped && !this.__chain__) { var value2 = this.value() return func.apply(isArray3(value2) ? value2 : [], args) } return this[chainName](function (value3) { return func.apply(isArray3(value3) ? value3 : [], args) }) } } ) baseForOwn(LazyWrapper.prototype, function (func, methodName) { var lodashFunc = lodash2[methodName] if (lodashFunc) { var key2 = lodashFunc.name + '' if (!hasOwnProperty2.call(realNames, key2)) { realNames[key2] = [] } realNames[key2].push({ name: methodName, func: lodashFunc }) } }) realNames[createHybrid(undefined$1, WRAP_BIND_KEY_FLAG).name] = [ { name: 'wrapper', func: undefined$1, }, ] LazyWrapper.prototype.clone = lazyClone LazyWrapper.prototype.reverse = lazyReverse LazyWrapper.prototype.value = lazyValue lodash2.prototype.at = wrapperAt lodash2.prototype.chain = wrapperChain lodash2.prototype.commit = wrapperCommit lodash2.prototype.next = wrapperNext lodash2.prototype.plant = wrapperPlant lodash2.prototype.reverse = wrapperReverse lodash2.prototype.toJSON = lodash2.prototype.valueOf = lodash2.prototype.value = wrapperValue lodash2.prototype.first = lodash2.prototype.head if (symIterator) { lodash2.prototype[symIterator] = wrapperToIterator } return lodash2 } var _2 = runInContext() if (freeModule2) { ;(freeModule2.exports = _2)._ = _2 freeExports2._ = _2 } else { root2._ = _2 } }).call(commonjsGlobal) })(lodash$2, lodash$2.exports) var lodash = lodash$2.exports var lodash$1 = /* @__PURE__ */ _mergeNamespaces( { __proto__: null, default: lodash, }, [lodash$2.exports] ) const utils = { setTheme: (theme2) => {}, colorRgb: (theme2) => {}, createRandomId: () => { return `${new Date().toJSON()}|${Math.random().toString(32).slice(6)}` }, copy: (_object, _obj = {}) => { for (let key2 in _object) { if (Object.prototype === Object.getPrototypeOf(_object[key2])) { _obj[key2] = initUtils.copy(_object[key2]) } else { _obj[key2] = _object[key2] } } return _obj }, getImgSrc: (name2) => { const path = `../../images/${name2}.png` const modules2 = {} return modules2[path].default }, getObjectCommonAttribute: (arr) => { var obj = {} arr.forEach((item2) => { for (const i2 in item2) { if (!obj[i2]) obj[i2] = item2[i2] } }) arr.forEach((item2) => { for (const i2 in obj) { if (!item2[i2]) delete obj[i2] } }) return obj }, getsTheChangedField: (obj1, obj2) => { let obj = { key: '', val: void 0, } const validateArrayField = (arr1, arr2) => { if (arr1.length != arr2.length) { return arr2 } for (let i2 = 0, iLen = arr1.length; i2 < iLen; i2++) { const element1 = arr1[i2] const element2 = arr2[i2] if (element1 != element2) { return arr2 } } return '' } for (const key2 in obj1) { const item1 = obj1[key2] const item2 = obj2[key2] if (Object.prototype.toString.call(item1) === '[object Object]'); else if (Object.prototype.toString.call(item1) === '[object Array]') { const val2 = validateArrayField(item1, item2) if (val2) { obj = { key: key2, val: val2 } break } } else { if (item1 != item2) { obj = { key: key2, val: item2, } break } } } return obj }, objRecursion: (object1, object22, object32) => { let _object1 = lodash.cloneDeep(object1) let _object2 = lodash.cloneDeep(object22) let _object3 = lodash.cloneDeep(object32) function showData(key2, value1, value2, value3) { var prototype = Object.prototype.toString.call(value1) if (prototype !== '[object Object]' && prototype !== '[object Array]') { if (value1 !== value2) { value3 = value2 } } return value3 } const handleData = (obj1, obj2, obj3) => { for (const key2 in obj1) { var value1 = obj1[key2] var value2 = obj2[key2] var value3 = obj3[key2] switch (Object.prototype.toString.call(value1)) { case '[object Object]': handleData(value1, value2, value3) break case '[object Array]': if (value1.length !== value2.length) { break } for (let i2 = 0, iLen = value1.length; i2 < iLen; i2++) { const item1 = value1[i2] const item2 = value2[i2] let item3 = value3[i2] item3 = showData(i2, item1, item2, item3) var prototype1 = Object.prototype.toString.call(item1) if ( prototype1 === '[object Object]' || prototype1 === '[object Array]' ) { handleData(item1, item2, item3) } } break default: value3 = showData(key2, value1, value2, value3) break } } } handleData(_object1, _object2, _object3) }, objRecursion1: (object1, object22) => { let _object1 = lodash.cloneDeep(object1) let _object2 = lodash.cloneDeep(object22) const handleData = (obj1, obj2) => { const circulationObj = (_obj1, _obj2) => { for (const key2 in _obj1) { var value1 = _obj1[key2] var value2 = _obj2[key2] var prototype2 = Object.prototype.toString.call(value1) switch (prototype2) { case '[object Object]': handleData(value1, value2) break case '[object Array]': if (value1.length !== value2.length) { break } for (let i2 = 0, iLen = value1.length; i2 < iLen; i2++) { const item1 = value1[i2] const item2 = value2[i2] showData(i2, item1, item2) var prototype1 = Object.prototype.toString.call(item1) if ( prototype1 === '[object Object]' || prototype1 === '[object Array]' ) { handleData(item1, item2) } } break default: showData(key2, value1, value2) break } } } function showData(key2, value1, value2) { var prototype2 = Object.prototype.toString.call(value1) if ( prototype2 !== '[object Object]' && prototype2 !== '[object Array]' ) { if (value1 === value2) delete obj2[key2] } } switch (Object.prototype.toString.call(obj1)) { case '[object Object]': circulationObj(obj1, obj2) break case '[object Array]': for (let i2 = 0, iLen = obj1.length; i2 < iLen; i2++) { const item1 = obj1[i2] const item2 = obj2[i2] showData(i2, item1, item2) var prototype = Object.prototype.toString.call(item1) if ( prototype === '[object Object]' || prototype === '[object Array]' ) { circulationObj(item1, item2) } } break default: showData('Array-element', obj1, obj2) break } } handleData(_object1, _object2) }, prefixInteger: (num2, m2) => { return (Array(m2).join('0') + num2).slice(-m2) }, formateDate: (dateTime, slot = '/') => { let date4 = new Date(dateTime) let yy = date4.getFullYear() let mm = initUtils.prefixInteger(date4.getMonth() + 1, 2) let dd = initUtils.prefixInteger(date4.getDate(), 2) let hh = initUtils.prefixInteger(date4.getHours(), 2) let mf = initUtils.prefixInteger(date4.getMinutes(), 2) let ss = initUtils.prefixInteger(date4.getSeconds(), 2) return yy + slot + mm + slot + dd + ' ' + hh + ':' + mf + ':' + ss }, debouncedFn: useDebounceFn( (callback) => { callback() }, 300, { maxWait: 5e3 } ), downFile: (data2, name2, mediaType) => { if (client.isClient()) { let arr = name2.split('.') let fileType = arr[arr.length - 1] client.invoke(({ electron: electron2 }, fileType2) => { const { BrowserWindow, downloadItem } = electron2 const win = BrowserWindow.getFocusedWindow() win.webContents.session.on('will-download', (event, item2) => { item2.setSaveDialogOptions({ filters: [{ name: `${fileType2} File`, extensions: [fileType2] }], }) }) }, fileType) } const blob = new Blob([data2], { type: mediaType }) const downloadHref = URL.createObjectURL(blob) const downloadLink = document.createElement('a') downloadLink.href = downloadHref downloadLink.download = name2 downloadLink.click() URL.revokeObjectURL(downloadHref) }, getDataFromPropertyPath: (data2, path) => { if (Object.prototype.toString.call(data2) !== '[object Object]') return void 0 if (Object.prototype.toString.call(path) !== '[object Array]') return void 0 if (!data2 || !path || !path.length) return void 0 var _data = JSON.parse(JSON.stringify(data2)) for (let i2 = 0, iLen = path.length; i2 < iLen; i2++) { const item2 = path[i2] if (!_data[item2]) return void 0 _data = _data[item2] } return _data }, getNodeParents: (tree, nodeId, config2) => { const { children = 'children', id: id2 = 'id' } = config2 || {} const toFlatArray = (tree2, parentId) => { return tree2.reduce((t3, _2) => { const child = _2[children] return [ ...t3, parentId ? { ..._2, parentId } : _2, ...(child && child.length ? toFlatArray(child, _2[id2]) : []), ] }, []) } const getIds = (flatArray) => { let ids = [nodeId] let child = flatArray.find((_2) => _2[id2] === nodeId) while (child && child.parentId) { ids = [child.parentId, ...ids] child = flatArray.find((_2) => _2[id2] === child.parentId) } return ids } return getIds(toFlatArray(tree, null)) }, getBase64: (imgUrl) => { window.URL = window.URL || window.webkitURL var xhr2 = new XMLHttpRequest() xhr2.open('get', imgUrl, true) xhr2.responseType = 'blob' return new Promise((reslove, reject2) => { xhr2.onload = function () { if (this.status == 200) { var blob = this.response let oFileReader = new FileReader() oFileReader.onloadend = function (e2) { let base642 = e2.target?.result reslove(base642) } oFileReader.readAsDataURL(blob) } else { reject2('') } } xhr2.send() }) }, isInputActive: (el2 = document.activeElement) => { if (!el2) return false const input = el2 if (input.readOnly || input.disabled) { return false } if ( /^(input)$/i.test(input.tagName) && (/^(text|password|number)$/i.test(input.type) || !input.type) ) { return true } if (/^(textarea)$/i.test(input.tagName)) { return true } if (/^(true|plaintext-only)$/i.test(input.contentEditable)) { return true } return false }, } const initUtils = utils function go(page2, type4 = 'push') { router$1[type4]({ params: { pageId: page2.id, }, }) } function push$4(page2) { go(page2, 'push') } function replace$4(page2) { go(page2, 'replace') } function reload() { window.location.reload() } function back() { window.history.back() } const exportLoading = { open: (text2 = '\u6587\u4EF6\u5BFC\u51FA\u4E2D', target2 = document.body) => { exportLoading.close(target2) let loading2 = document.createElement('div') loading2.className = 'export-loading' loading2.id = 'exportLoadingId' let loadingView = document.createElement('div') loadingView.className = 'loading' loadingView.innerText = Language$1._t(text2) let loadingtips = document.createElement('div') loadingtips.className = 'tips' loadingtips.innerText = Language$1._t('\u540E\u53F0\u52A0\u8F7D') loadingtips.onclick = () => exportLoading.close(target2) loadingView.appendChild(loadingtips) loading2.appendChild(loadingView) target2.appendChild(loading2) }, close: (target2 = document.body) => { let exportLoadingId = document.getElementById('exportLoadingId') if (exportLoadingId) target2.removeChild(exportLoadingId) }, } function _typeof$3(o2) { '@babel/helpers - typeof' return ( (_typeof$3 = 'function' == typeof Symbol && 'symbol' == typeof Symbol.iterator ? function (o3) { return typeof o3 } : function (o3) { return o3 && 'function' == typeof Symbol && o3.constructor === Symbol && o3 !== Symbol.prototype ? 'symbol' : typeof o3 }), _typeof$3(o2) ) } var u8 = Uint8Array, u16 = Uint16Array, u32 = Uint32Array var fleb = new u8([ 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 0, 0, 0, 0, ]) var fdeb = new u8([ 0, 0, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13, 0, 0, ]) var clim = new u8([ 16, 17, 18, 0, 8, 7, 9, 6, 10, 5, 11, 4, 12, 3, 13, 2, 14, 1, 15, ]) var freb = function (eb, start2) { var b2 = new u16(31) for (var i2 = 0; i2 < 31; ++i2) { b2[i2] = start2 += 1 << eb[i2 - 1] } var r2 = new u32(b2[30]) for (var i2 = 1; i2 < 30; ++i2) { for (var j2 = b2[i2]; j2 < b2[i2 + 1]; ++j2) { r2[j2] = ((j2 - b2[i2]) << 5) | i2 } } return [b2, r2] } var _a$2 = freb(fleb, 2), fl = _a$2[0], revfl = _a$2[1] ;(fl[28] = 258), (revfl[258] = 28) var _b$1 = freb(fdeb, 0), fd = _b$1[0], revfd = _b$1[1] var rev = new u16(32768) for (var i$6 = 0; i$6 < 32768; ++i$6) { var x$1 = ((i$6 & 43690) >>> 1) | ((i$6 & 21845) << 1) x$1 = ((x$1 & 52428) >>> 2) | ((x$1 & 13107) << 2) x$1 = ((x$1 & 61680) >>> 4) | ((x$1 & 3855) << 4) rev[i$6] = (((x$1 & 65280) >>> 8) | ((x$1 & 255) << 8)) >>> 1 } var hMap = function (cd, mb, r2) { var s2 = cd.length var i2 = 0 var l2 = new u16(mb) for (; i2 < s2; ++i2) ++l2[cd[i2] - 1] var le2 = new u16(mb) for (i2 = 0; i2 < mb; ++i2) { le2[i2] = (le2[i2 - 1] + l2[i2 - 1]) << 1 } var co if (r2) { co = new u16(1 << mb) var rvb = 15 - mb for (i2 = 0; i2 < s2; ++i2) { if (cd[i2]) { var sv2 = (i2 << 4) | cd[i2] var r_1 = mb - cd[i2] var v4 = le2[cd[i2] - 1]++ << r_1 for (var m2 = v4 | ((1 << r_1) - 1); v4 <= m2; ++v4) { co[rev[v4] >>> rvb] = sv2 } } } } else { co = new u16(s2) for (i2 = 0; i2 < s2; ++i2) co[i2] = rev[le2[cd[i2] - 1]++] >>> (15 - cd[i2]) } return co } var flt = new u8(288) for (var i$6 = 0; i$6 < 144; ++i$6) flt[i$6] = 8 for (var i$6 = 144; i$6 < 256; ++i$6) flt[i$6] = 9 for (var i$6 = 256; i$6 < 280; ++i$6) flt[i$6] = 7 for (var i$6 = 280; i$6 < 288; ++i$6) flt[i$6] = 8 var fdt = new u8(32) for (var i$6 = 0; i$6 < 32; ++i$6) fdt[i$6] = 5 var flm = /* @__PURE__ */ hMap(flt, 9, 0), flrm = /* @__PURE__ */ hMap(flt, 9, 1) var fdm = /* @__PURE__ */ hMap(fdt, 5, 0), fdrm = /* @__PURE__ */ hMap(fdt, 5, 1) var max$9 = function (a2) { var m2 = a2[0] for (var i2 = 1; i2 < a2.length; ++i2) { if (a2[i2] > m2) m2 = a2[i2] } return m2 } var bits = function (d3, p2, m2) { var o2 = (p2 / 8) >> 0 return ((d3[o2] | (d3[o2 + 1] << 8)) >>> (p2 & 7)) & m2 } var bits16 = function (d3, p2) { var o2 = (p2 / 8) >> 0 return (d3[o2] | (d3[o2 + 1] << 8) | (d3[o2 + 2] << 16)) >>> (p2 & 7) } var shft = function (p2) { return ((p2 / 8) >> 0) + (p2 & 7 && 1) } var slc = function (v4, s2, e2) { if (s2 == null || s2 < 0) s2 = 0 if (e2 == null || e2 > v4.length) e2 = v4.length var n2 = new (v4 instanceof u16 ? u16 : v4 instanceof u32 ? u32 : u8)(e2 - s2) n2.set(v4.subarray(s2, e2)) return n2 } var inflt = function (dat, buf, st2) { var sl2 = dat.length var noBuf = !buf || st2 var noSt = !st2 || st2.i if (!st2) st2 = {} if (!buf) buf = new u8(sl2 * 3) var cbuf = function (l3) { var bl = buf.length if (l3 > bl) { var nbuf = new u8(Math.max(bl * 2, l3)) nbuf.set(buf) buf = nbuf } } var final = st2.f || 0, pos = st2.p || 0, bt2 = st2.b || 0, lm = st2.l, dm = st2.d, lbt = st2.m, dbt = st2.n var tbts = sl2 * 8 do { if (!lm) { st2.f = final = bits(dat, pos, 1) var type4 = bits(dat, pos + 1, 3) pos += 3 if (!type4) { var s2 = shft(pos) + 4, l2 = dat[s2 - 4] | (dat[s2 - 3] << 8), t3 = s2 + l2 if (t3 > sl2) { if (noSt) throw 'unexpected EOF' break } if (noBuf) cbuf(bt2 + l2) buf.set(dat.subarray(s2, t3), bt2) ;(st2.b = bt2 += l2), (st2.p = pos = t3 * 8) continue } else if (type4 == 1) (lm = flrm), (dm = fdrm), (lbt = 9), (dbt = 5) else if (type4 == 2) { var hLit = bits(dat, pos, 31) + 257, hcLen = bits(dat, pos + 10, 15) + 4 var tl = hLit + bits(dat, pos + 5, 31) + 1 pos += 14 var ldt = new u8(tl) var clt = new u8(19) for (var i2 = 0; i2 < hcLen; ++i2) { clt[clim[i2]] = bits(dat, pos + i2 * 3, 7) } pos += hcLen * 3 var clb = max$9(clt), clbmsk = (1 << clb) - 1 if (!noSt && pos + tl * (clb + 7) > tbts) break var clm = hMap(clt, clb, 1) for (var i2 = 0; i2 < tl; ) { var r2 = clm[bits(dat, pos, clbmsk)] pos += r2 & 15 var s2 = r2 >>> 4 if (s2 < 16) { ldt[i2++] = s2 } else { var c2 = 0, n2 = 0 if (s2 == 16) (n2 = 3 + bits(dat, pos, 3)), (pos += 2), (c2 = ldt[i2 - 1]) else if (s2 == 17) (n2 = 3 + bits(dat, pos, 7)), (pos += 3) else if (s2 == 18) (n2 = 11 + bits(dat, pos, 127)), (pos += 7) while (n2--) ldt[i2++] = c2 } } var lt2 = ldt.subarray(0, hLit), dt2 = ldt.subarray(hLit) lbt = max$9(lt2) dbt = max$9(dt2) lm = hMap(lt2, lbt, 1) dm = hMap(dt2, dbt, 1) } else throw 'invalid block type' if (pos > tbts) throw 'unexpected EOF' } if (noBuf) cbuf(bt2 + 131072) var lms = (1 << lbt) - 1, dms = (1 << dbt) - 1 var mxa = lbt + dbt + 18 while (noSt || pos + mxa < tbts) { var c2 = lm[bits16(dat, pos) & lms], sym = c2 >>> 4 pos += c2 & 15 if (pos > tbts) throw 'unexpected EOF' if (!c2) throw 'invalid length/literal' if (sym < 256) buf[bt2++] = sym else if (sym == 256) { lm = null break } else { var add2 = sym - 254 if (sym > 264) { var i2 = sym - 257, b2 = fleb[i2] add2 = bits(dat, pos, (1 << b2) - 1) + fl[i2] pos += b2 } var d3 = dm[bits16(dat, pos) & dms], dsym = d3 >>> 4 if (!d3) throw 'invalid distance' pos += d3 & 15 var dt2 = fd[dsym] if (dsym > 3) { var b2 = fdeb[dsym] ;(dt2 += bits16(dat, pos) & ((1 << b2) - 1)), (pos += b2) } if (pos > tbts) throw 'unexpected EOF' if (noBuf) cbuf(bt2 + 131072) var end2 = bt2 + add2 for (; bt2 < end2; bt2 += 4) { buf[bt2] = buf[bt2 - dt2] buf[bt2 + 1] = buf[bt2 + 1 - dt2] buf[bt2 + 2] = buf[bt2 + 2 - dt2] buf[bt2 + 3] = buf[bt2 + 3 - dt2] } bt2 = end2 } } ;(st2.l = lm), (st2.p = pos), (st2.b = bt2) if (lm) (final = 1), (st2.m = lbt), (st2.d = dm), (st2.n = dbt) } while (!final) return bt2 == buf.length ? buf : slc(buf, 0, bt2) } var wbits = function (d3, p2, v4) { v4 <<= p2 & 7 var o2 = (p2 / 8) >> 0 d3[o2] |= v4 d3[o2 + 1] |= v4 >>> 8 } var wbits16 = function (d3, p2, v4) { v4 <<= p2 & 7 var o2 = (p2 / 8) >> 0 d3[o2] |= v4 d3[o2 + 1] |= v4 >>> 8 d3[o2 + 2] |= v4 >>> 16 } var hTree = function (d3, mb) { var t3 = [] for (var i2 = 0; i2 < d3.length; ++i2) { if (d3[i2]) t3.push({ s: i2, f: d3[i2] }) } var s2 = t3.length var t22 = t3.slice() if (!s2) return [new u8(0), 0] if (s2 == 1) { var v4 = new u8(t3[0].s + 1) v4[t3[0].s] = 1 return [v4, 1] } t3.sort(function (a2, b2) { return a2.f - b2.f }) t3.push({ s: -1, f: 25001 }) var l2 = t3[0], r2 = t3[1], i0 = 0, i1 = 1, i22 = 2 t3[0] = { s: -1, f: l2.f + r2.f, l: l2, r: r2 } while (i1 != s2 - 1) { l2 = t3[t3[i0].f < t3[i22].f ? i0++ : i22++] r2 = t3[i0 != i1 && t3[i0].f < t3[i22].f ? i0++ : i22++] t3[i1++] = { s: -1, f: l2.f + r2.f, l: l2, r: r2 } } var maxSym = t22[0].s for (var i2 = 1; i2 < s2; ++i2) { if (t22[i2].s > maxSym) maxSym = t22[i2].s } var tr2 = new u16(maxSym + 1) var mbt = ln(t3[i1 - 1], tr2, 0) if (mbt > mb) { var i2 = 0, dt2 = 0 var lft = mbt - mb, cst = 1 << lft t22.sort(function (a2, b2) { return tr2[b2.s] - tr2[a2.s] || a2.f - b2.f }) for (; i2 < s2; ++i2) { var i2_1 = t22[i2].s if (tr2[i2_1] > mb) { dt2 += cst - (1 << (mbt - tr2[i2_1])) tr2[i2_1] = mb } else break } dt2 >>>= lft while (dt2 > 0) { var i2_2 = t22[i2].s if (tr2[i2_2] < mb) dt2 -= 1 << (mb - tr2[i2_2]++ - 1) else ++i2 } for (; i2 >= 0 && dt2; --i2) { var i2_3 = t22[i2].s if (tr2[i2_3] == mb) { --tr2[i2_3] ++dt2 } } mbt = mb } return [new u8(tr2), mbt] } var ln = function (n2, l2, d3) { return n2.s == -1 ? Math.max(ln(n2.l, l2, d3 + 1), ln(n2.r, l2, d3 + 1)) : (l2[n2.s] = d3) } var lc = function (c2) { var s2 = c2.length while (s2 && !c2[--s2]); var cl = new u16(++s2) var cli = 0, cln = c2[0], cls = 1 var w2 = function (v4) { cl[cli++] = v4 } for (var i2 = 1; i2 <= s2; ++i2) { if (c2[i2] == cln && i2 != s2) ++cls else { if (!cln && cls > 2) { for (; cls > 138; cls -= 138) w2(32754) if (cls > 2) { w2(cls > 10 ? ((cls - 11) << 5) | 28690 : ((cls - 3) << 5) | 12305) cls = 0 } } else if (cls > 3) { w2(cln), --cls for (; cls > 6; cls -= 6) w2(8304) if (cls > 2) w2(((cls - 3) << 5) | 8208), (cls = 0) } while (cls--) w2(cln) cls = 1 cln = c2[i2] } } return [cl.subarray(0, cli), s2] } var clen = function (cf, cl) { var l2 = 0 for (var i2 = 0; i2 < cl.length; ++i2) l2 += cf[i2] * cl[i2] return l2 } var wfblk = function (out2, pos, dat) { var s2 = dat.length var o2 = shft(pos + 2) out2[o2] = s2 & 255 out2[o2 + 1] = s2 >>> 8 out2[o2 + 2] = out2[o2] ^ 255 out2[o2 + 3] = out2[o2 + 1] ^ 255 for (var i2 = 0; i2 < s2; ++i2) out2[o2 + i2 + 4] = dat[i2] return (o2 + 4 + s2) * 8 } var wblk = function (dat, out2, final, syms, lf, df, eb, li, bs2, bl, p2) { wbits(out2, p2++, final) ++lf[256] var _a2 = hTree(lf, 15), dlt = _a2[0], mlb = _a2[1] var _b2 = hTree(df, 15), ddt = _b2[0], mdb = _b2[1] var _c2 = lc(dlt), lclt = _c2[0], nlc = _c2[1] var _d = lc(ddt), lcdt = _d[0], ndc = _d[1] var lcfreq = new u16(19) for (var i2 = 0; i2 < lclt.length; ++i2) lcfreq[lclt[i2] & 31]++ for (var i2 = 0; i2 < lcdt.length; ++i2) lcfreq[lcdt[i2] & 31]++ var _e = hTree(lcfreq, 7), lct = _e[0], mlcb = _e[1] var nlcc = 19 for (; nlcc > 4 && !lct[clim[nlcc - 1]]; --nlcc); var flen = (bl + 5) << 3 var ftlen = clen(lf, flt) + clen(df, fdt) + eb var dtlen = clen(lf, dlt) + clen(df, ddt) + eb + 14 + 3 * nlcc + clen(lcfreq, lct) + (2 * lcfreq[16] + 3 * lcfreq[17] + 7 * lcfreq[18]) if (flen <= ftlen && flen <= dtlen) return wfblk(out2, p2, dat.subarray(bs2, bs2 + bl)) var lm, ll, dm, dl wbits(out2, p2, 1 + (dtlen < ftlen)), (p2 += 2) if (dtlen < ftlen) { ;(lm = hMap(dlt, mlb, 0)), (ll = dlt), (dm = hMap(ddt, mdb, 0)), (dl = ddt) var llm = hMap(lct, mlcb, 0) wbits(out2, p2, nlc - 257) wbits(out2, p2 + 5, ndc - 1) wbits(out2, p2 + 10, nlcc - 4) p2 += 14 for (var i2 = 0; i2 < nlcc; ++i2) wbits(out2, p2 + 3 * i2, lct[clim[i2]]) p2 += 3 * nlcc var lcts = [lclt, lcdt] for (var it2 = 0; it2 < 2; ++it2) { var clct = lcts[it2] for (var i2 = 0; i2 < clct.length; ++i2) { var len2 = clct[i2] & 31 wbits(out2, p2, llm[len2]), (p2 += lct[len2]) if (len2 > 15) wbits(out2, p2, (clct[i2] >>> 5) & 127), (p2 += clct[i2] >>> 12) } } } else { ;(lm = flm), (ll = flt), (dm = fdm), (dl = fdt) } for (var i2 = 0; i2 < li; ++i2) { if (syms[i2] > 255) { var len2 = (syms[i2] >>> 18) & 31 wbits16(out2, p2, lm[len2 + 257]), (p2 += ll[len2 + 257]) if (len2 > 7) wbits(out2, p2, (syms[i2] >>> 23) & 31), (p2 += fleb[len2]) var dst = syms[i2] & 31 wbits16(out2, p2, dm[dst]), (p2 += dl[dst]) if (dst > 3) wbits16(out2, p2, (syms[i2] >>> 5) & 8191), (p2 += fdeb[dst]) } else { wbits16(out2, p2, lm[syms[i2]]), (p2 += ll[syms[i2]]) } } wbits16(out2, p2, lm[256]) return p2 + ll[256] } var deo = /* @__PURE__ */ new u32([ 65540, 131080, 131088, 131104, 262176, 1048704, 1048832, 2114560, 2117632, ]) var et$1 = /* @__PURE__ */ new u8(0) var dflt = function (dat, lvl, plvl, pre, post, lst) { var s2 = dat.length var o2 = new u8(pre + s2 + 5 * (1 + Math.floor(s2 / 7e3)) + post) var w2 = o2.subarray(pre, o2.length - post) var pos = 0 if (!lvl || s2 < 8) { for (var i2 = 0; i2 <= s2; i2 += 65535) { var e2 = i2 + 65535 if (e2 < s2) { pos = wfblk(w2, pos, dat.subarray(i2, e2)) } else { w2[i2] = lst pos = wfblk(w2, pos, dat.subarray(i2, s2)) } } } else { var opt = deo[lvl - 1] var n2 = opt >>> 13, c2 = opt & 8191 var msk_1 = (1 << plvl) - 1 var prev = new u16(32768), head = new u16(msk_1 + 1) var bs1_1 = Math.ceil(plvl / 3), bs2_1 = 2 * bs1_1 var hsh = function (i3) { return (dat[i3] ^ (dat[i3 + 1] << bs1_1) ^ (dat[i3 + 2] << bs2_1)) & msk_1 } var syms = new u32(25e3) var lf = new u16(288), df = new u16(32) var lc_1 = 0, eb = 0, i2 = 0, li = 0, wi = 0, bs2 = 0 for (; i2 < s2; ++i2) { var hv = hsh(i2) var imod = i2 & 32767 var pimod = head[hv] prev[imod] = pimod head[hv] = imod if (wi <= i2) { var rem = s2 - i2 if ((lc_1 > 7e3 || li > 24576) && rem > 423) { pos = wblk(dat, w2, 0, syms, lf, df, eb, li, bs2, i2 - bs2, pos) ;(li = lc_1 = eb = 0), (bs2 = i2) for (var j2 = 0; j2 < 286; ++j2) lf[j2] = 0 for (var j2 = 0; j2 < 30; ++j2) df[j2] = 0 } var l2 = 2, d3 = 0, ch_1 = c2, dif = (imod - pimod) & 32767 if (rem > 2 && hv == hsh(i2 - dif)) { var maxn = Math.min(n2, rem) - 1 var maxd = Math.min(32767, i2) var ml = Math.min(258, rem) while (dif <= maxd && --ch_1 && imod != pimod) { if (dat[i2 + l2] == dat[i2 + l2 - dif]) { var nl2 = 0 for (; nl2 < ml && dat[i2 + nl2] == dat[i2 + nl2 - dif]; ++nl2); if (nl2 > l2) { ;(l2 = nl2), (d3 = dif) if (nl2 > maxn) break var mmd = Math.min(dif, nl2 - 2) var md = 0 for (var j2 = 0; j2 < mmd; ++j2) { var ti = (i2 - dif + j2 + 32768) & 32767 var pti = prev[ti] var cd = (ti - pti + 32768) & 32767 if (cd > md) (md = cd), (pimod = ti) } } } ;(imod = pimod), (pimod = prev[imod]) dif += (imod - pimod + 32768) & 32767 } } if (d3) { syms[li++] = 268435456 | (revfl[l2] << 18) | revfd[d3] var lin = revfl[l2] & 31, din = revfd[d3] & 31 eb += fleb[lin] + fdeb[din] ++lf[257 + lin] ++df[din] wi = i2 + l2 ++lc_1 } else { syms[li++] = dat[i2] ++lf[dat[i2]] } } } pos = wblk(dat, w2, lst, syms, lf, df, eb, li, bs2, i2 - bs2, pos) if (!lst) pos = wfblk(w2, pos, et$1) } return slc(o2, 0, pre + shft(pos) + post) } var adler = function () { var a2 = 1, b2 = 0 return { p: function (d3) { var n2 = a2, m2 = b2 var l2 = d3.length for (var i2 = 0; i2 != l2; ) { var e2 = Math.min(i2 + 5552, l2) for (; i2 < e2; ++i2) (n2 += d3[i2]), (m2 += n2) ;(n2 %= 65521), (m2 %= 65521) } ;(a2 = n2), (b2 = m2) }, d: function () { return ( (((a2 >>> 8) << 16) | ((b2 & 255) << 8) | (b2 >>> 8)) + ((a2 & 255) << 23) * 2 ) }, } } var dopt = function (dat, opt, pre, post, st2) { return dflt( dat, opt.level == null ? 6 : opt.level, opt.mem == null ? Math.ceil(Math.max(8, Math.min(13, Math.log(dat.length))) * 1.5) : 12 + opt.mem, pre, post, !st2 ) } var wbytes = function (d3, b2, v4) { for (; v4; ++b2) (d3[b2] = v4), (v4 >>>= 8) } var zlh = function (c2, o2) { var lv2 = o2.level, fl2 = lv2 == 0 ? 0 : lv2 < 6 ? 1 : lv2 == 9 ? 3 : 2 ;(c2[0] = 120), (c2[1] = (fl2 << 6) | (fl2 ? 32 - 2 * fl2 : 1)) } var zlv = function (d3) { if ((d3[0] & 15) != 8 || d3[0] >>> 4 > 7 || ((d3[0] << 8) | d3[1]) % 31) throw 'invalid zlib data' if (d3[1] & 32) throw 'invalid zlib data: preset dictionaries not supported' } function zlibSync(data2, opts) { if (opts === void 0) { opts = {} } var a2 = adler() a2.p(data2) var d3 = dopt(data2, opts, 2, 4) return zlh(d3, opts), wbytes(d3, d3.length - 4, a2.d()), d3 } function unzlibSync(data2, out2) { return inflt((zlv(data2), data2.subarray(2, -4)), out2) } /** @license * * jsPDF - PDF Document creation from JavaScript * Version 2.5.1 Built on 2022-01-28T15:37:57.791Z * CommitID 00000000 * * Copyright (c) 2010-2021 James Hall , https://github.com/MrRio/jsPDF * 2015-2021 yWorks GmbH, http://www.yworks.com * 2015-2021 Lukas Holländer , https://github.com/HackbrettXXX * 2016-2018 Aras Abbasi * 2010 Aaron Spike, https://github.com/acspike * 2012 Willow Systems Corporation, https://github.com/willowsystems * 2012 Pablo Hess, https://github.com/pablohess * 2012 Florian Jenett, https://github.com/fjenett * 2013 Warren Weckesser, https://github.com/warrenweckesser * 2013 Youssef Beddad, https://github.com/lifof * 2013 Lee Driscoll, https://github.com/lsdriscoll * 2013 Stefan Slonevskiy, https://github.com/stefslon * 2013 Jeremy Morel, https://github.com/jmorel * 2013 Christoph Hartmann, https://github.com/chris-rock * 2014 Juan Pablo Gaviria, https://github.com/juanpgaviria * 2014 James Makes, https://github.com/dollaruw * 2014 Diego Casorran, https://github.com/diegocr * 2014 Steven Spungin, https://github.com/Flamenco * 2014 Kenneth Glassey, https://github.com/Gavvers * * Permission is hereby granted, free of charge, to any person obtaining * a copy of this software and associated documentation files (the * "Software"), to deal in the Software without restriction, including * without limitation the rights to use, copy, modify, merge, publish, * distribute, sublicense, and/or sell copies of the Software, and to * permit persons to whom the Software is furnished to do so, subject to * the following conditions: * * The above copyright notice and this permission notice shall be * included in all copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE * LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION * OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. * * Contributor(s): * siefkenj, ahwolf, rickygu, Midnith, saintclair, eaparango, * kim3er, mfo, alnorth, Flamenco */ var n$1 = (function () { return 'undefined' != typeof window ? window : 'undefined' != typeof global ? global : 'undefined' != typeof self ? self : this })() function i$5() { n$1.console && 'function' == typeof n$1.console.log && n$1.console.log.apply(n$1.console, arguments) } var a$2 = { log: i$5, warn: function (t3) { n$1.console && ('function' == typeof n$1.console.warn ? n$1.console.warn.apply(n$1.console, arguments) : i$5.call(null, arguments)) }, error: function (t3) { n$1.console && ('function' == typeof n$1.console.error ? n$1.console.error.apply(n$1.console, arguments) : i$5(t3)) }, } function o$1(t3, e2, r2) { var n2 = new XMLHttpRequest() n2.open('GET', t3), (n2.responseType = 'blob'), (n2.onload = function () { l$1(n2.response, e2, r2) }), (n2.onerror = function () { a$2.error('could not download file') }), n2.send() } function s$1(t3) { var e2 = new XMLHttpRequest() e2.open('HEAD', t3, false) try { e2.send() } catch (t4) {} return e2.status >= 200 && e2.status <= 299 } function c$2(t3) { try { t3.dispatchEvent(new MouseEvent('click')) } catch (r2) { var e2 = document.createEvent('MouseEvents') e2.initMouseEvent( 'click', true, true, window, 0, 0, 0, 80, 20, false, false, false, false, 0, null ), t3.dispatchEvent(e2) } } var u$2, h$1, l$1 = n$1.saveAs || ('object' !== ('undefined' == typeof window ? 'undefined' : _typeof$3(window)) || window !== n$1 ? function () {} : 'undefined' != typeof HTMLAnchorElement && 'download' in HTMLAnchorElement.prototype ? function (t3, e2, r2) { var i2 = n$1.URL || n$1.webkitURL, a2 = document.createElement('a') ;(e2 = e2 || t3.name || 'download'), (a2.download = e2), (a2.rel = 'noopener'), 'string' == typeof t3 ? ((a2.href = t3), a2.origin !== location.origin ? s$1(a2.href) ? o$1(t3, e2, r2) : c$2(a2, (a2.target = '_blank')) : c$2(a2)) : ((a2.href = i2.createObjectURL(t3)), setTimeout(function () { i2.revokeObjectURL(a2.href) }, 4e4), setTimeout(function () { c$2(a2) }, 0)) } : 'msSaveOrOpenBlob' in navigator ? function (e2, r2, n2) { if (((r2 = r2 || e2.name || 'download'), 'string' == typeof e2)) if (s$1(e2)) o$1(e2, r2, n2) else { var i2 = document.createElement('a') ;(i2.href = e2), (i2.target = '_blank'), setTimeout(function () { c$2(i2) }) } else navigator.msSaveOrOpenBlob( (function (e3, r3) { return ( void 0 === r3 ? (r3 = { autoBom: false }) : 'object' !== _typeof$3(r3) && (a$2.warn( 'Deprecated: Expected third argument to be a object' ), (r3 = { autoBom: !r3 })), r3.autoBom && /^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test( e3.type ) ? new Blob([String.fromCharCode(65279), e3], { type: e3.type, }) : e3 ) })(e2, n2), r2 ) } : function (e2, r2, i2, a2) { if ( ((a2 = a2 || open('', '_blank')) && (a2.document.title = a2.document.body.innerText = 'downloading...'), 'string' == typeof e2) ) return o$1(e2, r2, i2) var s2 = 'application/octet-stream' === e2.type, c2 = /constructor/i.test(n$1.HTMLElement) || n$1.safari, u2 = /CriOS\/[\d]+/.test(navigator.userAgent) if ( (u2 || (s2 && c2)) && 'object' === ('undefined' == typeof FileReader ? 'undefined' : _typeof$3(FileReader)) ) { var h2 = new FileReader() ;(h2.onloadend = function () { var t3 = h2.result ;(t3 = u2 ? t3 : t3.replace(/^data:[^;]*;/, 'data:attachment/file;')), a2 ? (a2.location.href = t3) : (location = t3), (a2 = null) }), h2.readAsDataURL(e2) } else { var l2 = n$1.URL || n$1.webkitURL, f2 = l2.createObjectURL(e2) a2 ? (a2.location = f2) : (location.href = f2), (a2 = null), setTimeout(function () { l2.revokeObjectURL(f2) }, 4e4) } }) /** * A class to parse color values * @author Stoyan Stefanov * {@link http://www.phpied.com/rgb-color-parser-in-javascript/} * @license Use it if you like it */ function f$2(t3) { var e2 ;(t3 = t3 || ''), (this.ok = false), '#' == t3.charAt(0) && (t3 = t3.substr(1, 6)) t3 = { aliceblue: 'f0f8ff', antiquewhite: 'faebd7', aqua: '00ffff', aquamarine: '7fffd4', azure: 'f0ffff', beige: 'f5f5dc', bisque: 'ffe4c4', black: '000000', blanchedalmond: 'ffebcd', blue: '0000ff', blueviolet: '8a2be2', brown: 'a52a2a', burlywood: 'deb887', cadetblue: '5f9ea0', chartreuse: '7fff00', chocolate: 'd2691e', coral: 'ff7f50', cornflowerblue: '6495ed', cornsilk: 'fff8dc', crimson: 'dc143c', cyan: '00ffff', darkblue: '00008b', darkcyan: '008b8b', darkgoldenrod: 'b8860b', darkgray: 'a9a9a9', darkgreen: '006400', darkkhaki: 'bdb76b', darkmagenta: '8b008b', darkolivegreen: '556b2f', darkorange: 'ff8c00', darkorchid: '9932cc', darkred: '8b0000', darksalmon: 'e9967a', darkseagreen: '8fbc8f', darkslateblue: '483d8b', darkslategray: '2f4f4f', darkturquoise: '00ced1', darkviolet: '9400d3', deeppink: 'ff1493', deepskyblue: '00bfff', dimgray: '696969', dodgerblue: '1e90ff', feldspar: 'd19275', firebrick: 'b22222', floralwhite: 'fffaf0', forestgreen: '228b22', fuchsia: 'ff00ff', gainsboro: 'dcdcdc', ghostwhite: 'f8f8ff', gold: 'ffd700', goldenrod: 'daa520', gray: '808080', green: '008000', greenyellow: 'adff2f', honeydew: 'f0fff0', hotpink: 'ff69b4', indianred: 'cd5c5c', indigo: '4b0082', ivory: 'fffff0', khaki: 'f0e68c', lavender: 'e6e6fa', lavenderblush: 'fff0f5', lawngreen: '7cfc00', lemonchiffon: 'fffacd', lightblue: 'add8e6', lightcoral: 'f08080', lightcyan: 'e0ffff', lightgoldenrodyellow: 'fafad2', lightgrey: 'd3d3d3', lightgreen: '90ee90', lightpink: 'ffb6c1', lightsalmon: 'ffa07a', lightseagreen: '20b2aa', lightskyblue: '87cefa', lightslateblue: '8470ff', lightslategray: '778899', lightsteelblue: 'b0c4de', lightyellow: 'ffffe0', lime: '00ff00', limegreen: '32cd32', linen: 'faf0e6', magenta: 'ff00ff', maroon: '800000', mediumaquamarine: '66cdaa', mediumblue: '0000cd', mediumorchid: 'ba55d3', mediumpurple: '9370d8', mediumseagreen: '3cb371', mediumslateblue: '7b68ee', mediumspringgreen: '00fa9a', mediumturquoise: '48d1cc', mediumvioletred: 'c71585', midnightblue: '191970', mintcream: 'f5fffa', mistyrose: 'ffe4e1', moccasin: 'ffe4b5', navajowhite: 'ffdead', navy: '000080', oldlace: 'fdf5e6', olive: '808000', olivedrab: '6b8e23', orange: 'ffa500', orangered: 'ff4500', orchid: 'da70d6', palegoldenrod: 'eee8aa', palegreen: '98fb98', paleturquoise: 'afeeee', palevioletred: 'd87093', papayawhip: 'ffefd5', peachpuff: 'ffdab9', peru: 'cd853f', pink: 'ffc0cb', plum: 'dda0dd', powderblue: 'b0e0e6', purple: '800080', red: 'ff0000', rosybrown: 'bc8f8f', royalblue: '4169e1', saddlebrown: '8b4513', salmon: 'fa8072', sandybrown: 'f4a460', seagreen: '2e8b57', seashell: 'fff5ee', sienna: 'a0522d', silver: 'c0c0c0', skyblue: '87ceeb', slateblue: '6a5acd', slategray: '708090', snow: 'fffafa', springgreen: '00ff7f', steelblue: '4682b4', tan: 'd2b48c', teal: '008080', thistle: 'd8bfd8', tomato: 'ff6347', turquoise: '40e0d0', violet: 'ee82ee', violetred: 'd02090', wheat: 'f5deb3', white: 'ffffff', whitesmoke: 'f5f5f5', yellow: 'ffff00', yellowgreen: '9acd32', }[(t3 = (t3 = t3.replace(/ /g, '')).toLowerCase())] || t3 for ( var r2 = [ { re: /^rgb\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3})\)$/, example: ['rgb(123, 234, 45)', 'rgb(255,234,245)'], process: function (t4) { return [parseInt(t4[1]), parseInt(t4[2]), parseInt(t4[3])] }, }, { re: /^(\w{2})(\w{2})(\w{2})$/, example: ['#00ff00', '336699'], process: function (t4) { return [ parseInt(t4[1], 16), parseInt(t4[2], 16), parseInt(t4[3], 16), ] }, }, { re: /^(\w{1})(\w{1})(\w{1})$/, example: ['#fb0', 'f0f'], process: function (t4) { return [ parseInt(t4[1] + t4[1], 16), parseInt(t4[2] + t4[2], 16), parseInt(t4[3] + t4[3], 16), ] }, }, ], n2 = 0; n2 < r2.length; n2++ ) { var i2 = r2[n2].re, a2 = r2[n2].process, o2 = i2.exec(t3) o2 && ((e2 = a2(o2)), (this.r = e2[0]), (this.g = e2[1]), (this.b = e2[2]), (this.ok = true)) } ;(this.r = this.r < 0 || isNaN(this.r) ? 0 : this.r > 255 ? 255 : this.r), (this.g = this.g < 0 || isNaN(this.g) ? 0 : this.g > 255 ? 255 : this.g), (this.b = this.b < 0 || isNaN(this.b) ? 0 : this.b > 255 ? 255 : this.b), (this.toRGB = function () { return 'rgb(' + this.r + ', ' + this.g + ', ' + this.b + ')' }), (this.toHex = function () { var t4 = this.r.toString(16), e3 = this.g.toString(16), r3 = this.b.toString(16) return ( 1 == t4.length && (t4 = '0' + t4), 1 == e3.length && (e3 = '0' + e3), 1 == r3.length && (r3 = '0' + r3), '#' + t4 + e3 + r3 ) }) } /** * @license * Joseph Myers does not specify a particular license for his work. * * Author: Joseph Myers * Accessed from: http://www.myersdaily.org/joseph/javascript/md5.js * * Modified by: Owen Leong */ function d(t3, e2) { var r2 = t3[0], n2 = t3[1], i2 = t3[2], a2 = t3[3] ;(r2 = g(r2, n2, i2, a2, e2[0], 7, -680876936)), (a2 = g(a2, r2, n2, i2, e2[1], 12, -389564586)), (i2 = g(i2, a2, r2, n2, e2[2], 17, 606105819)), (n2 = g(n2, i2, a2, r2, e2[3], 22, -1044525330)), (r2 = g(r2, n2, i2, a2, e2[4], 7, -176418897)), (a2 = g(a2, r2, n2, i2, e2[5], 12, 1200080426)), (i2 = g(i2, a2, r2, n2, e2[6], 17, -1473231341)), (n2 = g(n2, i2, a2, r2, e2[7], 22, -45705983)), (r2 = g(r2, n2, i2, a2, e2[8], 7, 1770035416)), (a2 = g(a2, r2, n2, i2, e2[9], 12, -1958414417)), (i2 = g(i2, a2, r2, n2, e2[10], 17, -42063)), (n2 = g(n2, i2, a2, r2, e2[11], 22, -1990404162)), (r2 = g(r2, n2, i2, a2, e2[12], 7, 1804603682)), (a2 = g(a2, r2, n2, i2, e2[13], 12, -40341101)), (i2 = g(i2, a2, r2, n2, e2[14], 17, -1502002290)), (r2 = m$3( r2, (n2 = g(n2, i2, a2, r2, e2[15], 22, 1236535329)), i2, a2, e2[1], 5, -165796510 )), (a2 = m$3(a2, r2, n2, i2, e2[6], 9, -1069501632)), (i2 = m$3(i2, a2, r2, n2, e2[11], 14, 643717713)), (n2 = m$3(n2, i2, a2, r2, e2[0], 20, -373897302)), (r2 = m$3(r2, n2, i2, a2, e2[5], 5, -701558691)), (a2 = m$3(a2, r2, n2, i2, e2[10], 9, 38016083)), (i2 = m$3(i2, a2, r2, n2, e2[15], 14, -660478335)), (n2 = m$3(n2, i2, a2, r2, e2[4], 20, -405537848)), (r2 = m$3(r2, n2, i2, a2, e2[9], 5, 568446438)), (a2 = m$3(a2, r2, n2, i2, e2[14], 9, -1019803690)), (i2 = m$3(i2, a2, r2, n2, e2[3], 14, -187363961)), (n2 = m$3(n2, i2, a2, r2, e2[8], 20, 1163531501)), (r2 = m$3(r2, n2, i2, a2, e2[13], 5, -1444681467)), (a2 = m$3(a2, r2, n2, i2, e2[2], 9, -51403784)), (i2 = m$3(i2, a2, r2, n2, e2[7], 14, 1735328473)), (r2 = v$2( r2, (n2 = m$3(n2, i2, a2, r2, e2[12], 20, -1926607734)), i2, a2, e2[5], 4, -378558 )), (a2 = v$2(a2, r2, n2, i2, e2[8], 11, -2022574463)), (i2 = v$2(i2, a2, r2, n2, e2[11], 16, 1839030562)), (n2 = v$2(n2, i2, a2, r2, e2[14], 23, -35309556)), (r2 = v$2(r2, n2, i2, a2, e2[1], 4, -1530992060)), (a2 = v$2(a2, r2, n2, i2, e2[4], 11, 1272893353)), (i2 = v$2(i2, a2, r2, n2, e2[7], 16, -155497632)), (n2 = v$2(n2, i2, a2, r2, e2[10], 23, -1094730640)), (r2 = v$2(r2, n2, i2, a2, e2[13], 4, 681279174)), (a2 = v$2(a2, r2, n2, i2, e2[0], 11, -358537222)), (i2 = v$2(i2, a2, r2, n2, e2[3], 16, -722521979)), (n2 = v$2(n2, i2, a2, r2, e2[6], 23, 76029189)), (r2 = v$2(r2, n2, i2, a2, e2[9], 4, -640364487)), (a2 = v$2(a2, r2, n2, i2, e2[12], 11, -421815835)), (i2 = v$2(i2, a2, r2, n2, e2[15], 16, 530742520)), (r2 = b( r2, (n2 = v$2(n2, i2, a2, r2, e2[2], 23, -995338651)), i2, a2, e2[0], 6, -198630844 )), (a2 = b(a2, r2, n2, i2, e2[7], 10, 1126891415)), (i2 = b(i2, a2, r2, n2, e2[14], 15, -1416354905)), (n2 = b(n2, i2, a2, r2, e2[5], 21, -57434055)), (r2 = b(r2, n2, i2, a2, e2[12], 6, 1700485571)), (a2 = b(a2, r2, n2, i2, e2[3], 10, -1894986606)), (i2 = b(i2, a2, r2, n2, e2[10], 15, -1051523)), (n2 = b(n2, i2, a2, r2, e2[1], 21, -2054922799)), (r2 = b(r2, n2, i2, a2, e2[8], 6, 1873313359)), (a2 = b(a2, r2, n2, i2, e2[15], 10, -30611744)), (i2 = b(i2, a2, r2, n2, e2[6], 15, -1560198380)), (n2 = b(n2, i2, a2, r2, e2[13], 21, 1309151649)), (r2 = b(r2, n2, i2, a2, e2[4], 6, -145523070)), (a2 = b(a2, r2, n2, i2, e2[11], 10, -1120210379)), (i2 = b(i2, a2, r2, n2, e2[2], 15, 718787259)), (n2 = b(n2, i2, a2, r2, e2[9], 21, -343485551)), (t3[0] = _$2(r2, t3[0])), (t3[1] = _$2(n2, t3[1])), (t3[2] = _$2(i2, t3[2])), (t3[3] = _$2(a2, t3[3])) } function p$1(t3, e2, r2, n2, i2, a2) { return ( (e2 = _$2(_$2(e2, t3), _$2(n2, a2))), _$2((e2 << i2) | (e2 >>> (32 - i2)), r2) ) } function g(t3, e2, r2, n2, i2, a2, o2) { return p$1((e2 & r2) | (~e2 & n2), t3, e2, i2, a2, o2) } function m$3(t3, e2, r2, n2, i2, a2, o2) { return p$1((e2 & n2) | (r2 & ~n2), t3, e2, i2, a2, o2) } function v$2(t3, e2, r2, n2, i2, a2, o2) { return p$1(e2 ^ r2 ^ n2, t3, e2, i2, a2, o2) } function b(t3, e2, r2, n2, i2, a2, o2) { return p$1(r2 ^ (e2 | ~n2), t3, e2, i2, a2, o2) } function y$1(t3) { var e2, r2 = t3.length, n2 = [1732584193, -271733879, -1732584194, 271733878] for (e2 = 64; e2 <= t3.length; e2 += 64) d(n2, w(t3.substring(e2 - 64, e2))) t3 = t3.substring(e2 - 64) var i2 = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] for (e2 = 0; e2 < t3.length; e2++) i2[e2 >> 2] |= t3.charCodeAt(e2) << (e2 % 4 << 3) if (((i2[e2 >> 2] |= 128 << (e2 % 4 << 3)), e2 > 55)) for (d(n2, i2), e2 = 0; e2 < 16; e2++) i2[e2] = 0 return (i2[14] = 8 * r2), d(n2, i2), n2 } function w(t3) { var e2, r2 = [] for (e2 = 0; e2 < 64; e2 += 4) r2[e2 >> 2] = t3.charCodeAt(e2) + (t3.charCodeAt(e2 + 1) << 8) + (t3.charCodeAt(e2 + 2) << 16) + (t3.charCodeAt(e2 + 3) << 24) return r2 } ;(u$2 = n$1.atob.bind(n$1)), (h$1 = n$1.btoa.bind(n$1)) var N$1 = '0123456789abcdef'.split('') function L$1(t3) { for (var e2 = '', r2 = 0; r2 < 4; r2++) e2 += N$1[(t3 >> (8 * r2 + 4)) & 15] + N$1[(t3 >> (8 * r2)) & 15] return e2 } function A$1(t3) { return String.fromCharCode( (255 & t3) >> 0, (65280 & t3) >> 8, (16711680 & t3) >> 16, (4278190080 & t3) >> 24 ) } function x(t3) { return y$1(t3).map(A$1).join('') } var S = '5d41402abc4b2a76b9719d911017c592' != (function (t3) { for (var e2 = 0; e2 < t3.length; e2++) t3[e2] = L$1(t3[e2]) return t3.join('') })(y$1('hello')) function _$2(t3, e2) { if (S) { var r2 = (65535 & t3) + (65535 & e2) return (((t3 >> 16) + (e2 >> 16) + (r2 >> 16)) << 16) | (65535 & r2) } return (t3 + e2) & 4294967295 } /** * @license * FPDF is released under a permissive license: there is no usage restriction. * You may embed it freely in your application (commercial or not), with or * without modifications. * * Reference: http://www.fpdf.org/en/script/script37.php */ function P(t3, e2) { var r2, n2, i2, a2 if (t3 !== r2) { for ( var o2 = ((i2 = t3), (a2 = 1 + ((256 / t3.length) >> 0)), new Array(a2 + 1).join(i2)), s2 = [], c2 = 0; c2 < 256; c2++ ) s2[c2] = c2 var u2 = 0 for (c2 = 0; c2 < 256; c2++) { var h2 = s2[c2] ;(u2 = (u2 + h2 + o2.charCodeAt(c2)) % 256), (s2[c2] = s2[u2]), (s2[u2] = h2) } ;(r2 = t3), (n2 = s2) } else s2 = n2 var l2 = e2.length, f2 = 0, d3 = 0, p2 = '' for (c2 = 0; c2 < l2; c2++) (d3 = (d3 + (h2 = s2[(f2 = (f2 + 1) % 256)])) % 256), (s2[f2] = s2[d3]), (s2[d3] = h2), (o2 = s2[(s2[f2] + s2[d3]) % 256]), (p2 += String.fromCharCode(e2.charCodeAt(c2) ^ o2)) return p2 } /** * @license * Licensed under the MIT License. * http://opensource.org/licenses/mit-license * Author: Owen Leong (@owenl131) * Date: 15 Oct 2020 * References: * https://www.cs.cmu.edu/~dst/Adobe/Gallery/anon21jul01-pdf-encryption.txt * https://github.com/foliojs/pdfkit/blob/master/lib/security.js * http://www.fpdf.org/en/script/script37.php */ var k$1 = { print: 4, modify: 8, copy: 16, 'annot-forms': 32 } function I(t3, e2, r2, n2) { ;(this.v = 1), (this.r = 2) var i2 = 192 t3.forEach(function (t4) { if (void 0 !== k$1.perm) throw new Error('Invalid permission: ' + t4) i2 += k$1[t4] }), (this.padding = '(\xBFN^Nu\x8AAd\0NV\xFF\xFA\b..\0\xB6\xD0h>\x80/\f\xA9\xFEdSiz') var a2 = (e2 + this.padding).substr(0, 32), o2 = (r2 + this.padding).substr(0, 32) ;(this.O = this.processOwnerPassword(a2, o2)), (this.P = -(1 + (255 ^ i2))), (this.encryptionKey = x( a2 + this.O + this.lsbFirstWord(this.P) + this.hexToBytes(n2) ).substr(0, 5)), (this.U = P(this.encryptionKey, this.padding)) } function F$1(t3) { if (/[^\u0000-\u00ff]/.test(t3)) throw new Error( 'Invalid PDF Name Object: ' + t3 + ', Only accept ASCII characters.' ) for (var e2 = '', r2 = t3.length, n2 = 0; n2 < r2; n2++) { var i2 = t3.charCodeAt(n2) if ( i2 < 33 || 35 === i2 || 37 === i2 || 40 === i2 || 41 === i2 || 47 === i2 || 60 === i2 || 62 === i2 || 91 === i2 || 93 === i2 || 123 === i2 || 125 === i2 || i2 > 126 ) e2 += '#' + ('0' + i2.toString(16)).slice(-2) else e2 += t3[n2] } return e2 } function C(e2) { if ('object' !== _typeof$3(e2)) throw new Error( 'Invalid Context passed to initialize PubSub (jsPDF-module)' ) var r2 = {} ;(this.subscribe = function (t3, e3, n2) { if ( ((n2 = n2 || false), 'string' != typeof t3 || 'function' != typeof e3 || 'boolean' != typeof n2) ) throw new Error( 'Invalid arguments passed to PubSub.subscribe (jsPDF-module)' ) r2.hasOwnProperty(t3) || (r2[t3] = {}) var i2 = Math.random().toString(35) return (r2[t3][i2] = [e3, !!n2]), i2 }), (this.unsubscribe = function (t3) { for (var e3 in r2) if (r2[e3][t3]) return ( delete r2[e3][t3], 0 === Object.keys(r2[e3]).length && delete r2[e3], true ) return false }), (this.publish = function (t3) { if (r2.hasOwnProperty(t3)) { var i2 = Array.prototype.slice.call(arguments, 1), o2 = [] for (var s2 in r2[t3]) { var c2 = r2[t3][s2] try { c2[0].apply(e2, i2) } catch (t4) { n$1.console && a$2.error('jsPDF PubSub Error', t4.message, t4) } c2[1] && o2.push(s2) } o2.length && o2.forEach(this.unsubscribe) } }), (this.getTopics = function () { return r2 }) } function j(t3) { if (!(this instanceof j)) return new j(t3) var e2 = 'opacity,stroke-opacity'.split(',') for (var r2 in t3) t3.hasOwnProperty(r2) && e2.indexOf(r2) >= 0 && (this[r2] = t3[r2]) ;(this.id = ''), (this.objectNumber = -1) } function O$1(t3, e2) { ;(this.gState = t3), (this.matrix = e2), (this.id = ''), (this.objectNumber = -1) } function B(t3, e2, r2, n2, i2) { if (!(this instanceof B)) return new B(t3, e2, r2, n2, i2) ;(this.type = 'axial' === t3 ? 2 : 3), (this.coords = e2), (this.colors = r2), O$1.call(this, n2, i2) } function M(t3, e2, r2, n2, i2) { if (!(this instanceof M)) return new M(t3, e2, r2, n2, i2) ;(this.boundingBox = t3), (this.xStep = e2), (this.yStep = r2), (this.stream = ''), (this.cloneIndex = 0), O$1.call(this, n2, i2) } function E$1(e2) { var r2, i2 = 'string' == typeof arguments[0] ? arguments[0] : 'p', o2 = arguments[1], s2 = arguments[2], c2 = arguments[3], u2 = [], d3 = 1, p2 = 16, g2 = 'S', m2 = null 'object' === _typeof$3((e2 = e2 || {})) && ((i2 = e2.orientation), (o2 = e2.unit || o2), (s2 = e2.format || s2), (c2 = e2.compress || e2.compressPdf || c2), null !== (m2 = e2.encryption || null) && ((m2.userPassword = m2.userPassword || ''), (m2.ownerPassword = m2.ownerPassword || ''), (m2.userPermissions = m2.userPermissions || [])), (d3 = 'number' == typeof e2.userUnit ? Math.abs(e2.userUnit) : 1), void 0 !== e2.precision && (r2 = e2.precision), void 0 !== e2.floatPrecision && (p2 = e2.floatPrecision), (g2 = e2.defaultPathOperation || 'S')), (u2 = e2.filters || (true === c2 ? ['FlateEncode'] : u2)), (o2 = o2 || 'mm'), (i2 = ('' + (i2 || 'P')).toLowerCase()) var v4 = e2.putOnlyUsedFonts || false, b2 = {}, y2 = { internal: {}, __private__: {} } y2.__private__.PubSub = C var w2 = '1.3', N2 = (y2.__private__.getPdfVersion = function () { return w2 }) y2.__private__.setPdfVersion = function (t3) { w2 = t3 } var L2 = { a0: [2383.94, 3370.39], a1: [1683.78, 2383.94], a2: [1190.55, 1683.78], a3: [841.89, 1190.55], a4: [595.28, 841.89], a5: [419.53, 595.28], a6: [297.64, 419.53], a7: [209.76, 297.64], a8: [147.4, 209.76], a9: [104.88, 147.4], a10: [73.7, 104.88], b0: [2834.65, 4008.19], b1: [2004.09, 2834.65], b2: [1417.32, 2004.09], b3: [1000.63, 1417.32], b4: [708.66, 1000.63], b5: [498.9, 708.66], b6: [354.33, 498.9], b7: [249.45, 354.33], b8: [175.75, 249.45], b9: [124.72, 175.75], b10: [87.87, 124.72], c0: [2599.37, 3676.54], c1: [1836.85, 2599.37], c2: [1298.27, 1836.85], c3: [918.43, 1298.27], c4: [649.13, 918.43], c5: [459.21, 649.13], c6: [323.15, 459.21], c7: [229.61, 323.15], c8: [161.57, 229.61], c9: [113.39, 161.57], c10: [79.37, 113.39], dl: [311.81, 623.62], letter: [612, 792], 'government-letter': [576, 756], legal: [612, 1008], 'junior-legal': [576, 360], ledger: [1224, 792], tabloid: [792, 1224], 'credit-card': [153, 243], } y2.__private__.getPageFormats = function () { return L2 } var A2 = (y2.__private__.getPageFormat = function (t3) { return L2[t3] }) s2 = s2 || 'a4' var x2 = { COMPAT: 'compat', ADVANCED: 'advanced' }, S2 = x2.COMPAT function _2() { this.saveGraphicsState(), lt2(new Vt2(_t2, 0, 0, -_t2, 0, Rr() * _t2).toString() + ' cm'), this.setFontSize(this.getFontSize() / _t2), (g2 = 'n'), (S2 = x2.ADVANCED) } function P2() { this.restoreGraphicsState(), (g2 = 'S'), (S2 = x2.COMPAT) } var k2 = (y2.__private__.combineFontStyleAndFontWeight = function (t3, e3) { if ( ('bold' == t3 && 'normal' == e3) || ('bold' == t3 && 400 == e3) || ('normal' == t3 && 'italic' == e3) || ('bold' == t3 && 'italic' == e3) ) throw new Error('Invalid Combination of fontweight and fontstyle') return ( e3 && (t3 = 400 == e3 || 'normal' === e3 ? 'italic' === t3 ? 'italic' : 'normal' : (700 != e3 && 'bold' !== e3) || 'normal' !== t3 ? (700 == e3 ? 'bold' : e3) + '' + t3 : 'bold'), t3 ) }) ;(y2.advancedAPI = function (t3) { var e3 = S2 === x2.COMPAT return ( e3 && _2.call(this), 'function' != typeof t3 || (t3(this), e3 && P2.call(this)), this ) }), (y2.compatAPI = function (t3) { var e3 = S2 === x2.ADVANCED return ( e3 && P2.call(this), 'function' != typeof t3 || (t3(this), e3 && _2.call(this)), this ) }), (y2.isAdvancedAPI = function () { return S2 === x2.ADVANCED }) var O2, q2 = function (t3) { if (S2 !== x2.ADVANCED) throw new Error( t3 + " is only available in 'advanced' API mode. You need to call advancedAPI() first." ) }, D2 = (y2.roundToPrecision = y2.__private__.roundToPrecision = function (t3, e3) { var n2 = r2 || e3 if (isNaN(t3) || isNaN(n2)) throw new Error('Invalid argument passed to jsPDF.roundToPrecision') return t3.toFixed(n2).replace(/0+$/, '') }) O2 = y2.hpf = y2.__private__.hpf = 'number' == typeof p2 ? function (t3) { if (isNaN(t3)) throw new Error('Invalid argument passed to jsPDF.hpf') return D2(t3, p2) } : 'smart' === p2 ? function (t3) { if (isNaN(t3)) throw new Error('Invalid argument passed to jsPDF.hpf') return D2(t3, t3 > -1 && t3 < 1 ? 16 : 5) } : function (t3) { if (isNaN(t3)) throw new Error('Invalid argument passed to jsPDF.hpf') return D2(t3, 16) } var R2 = (y2.f2 = y2.__private__.f2 = function (t3) { if (isNaN(t3)) throw new Error('Invalid argument passed to jsPDF.f2') return D2(t3, 2) }), T2 = (y2.__private__.f3 = function (t3) { if (isNaN(t3)) throw new Error('Invalid argument passed to jsPDF.f3') return D2(t3, 3) }), U2 = (y2.scale = y2.__private__.scale = function (t3) { if (isNaN(t3)) throw new Error('Invalid argument passed to jsPDF.scale') return S2 === x2.COMPAT ? t3 * _t2 : S2 === x2.ADVANCED ? t3 : void 0 }), z2 = function (t3) { return S2 === x2.COMPAT ? Rr() - t3 : S2 === x2.ADVANCED ? t3 : void 0 }, H4 = function (t3) { return U2(z2(t3)) } y2.__private__.setPrecision = y2.setPrecision = function (t3) { 'number' == typeof parseInt(t3, 10) && (r2 = parseInt(t3, 10)) } var W2, V2 = '00000000000000000000000000000000', G2 = (y2.__private__.getFileId = function () { return V2 }), Y2 = (y2.__private__.setFileId = function (t3) { return ( (V2 = void 0 !== t3 && /^[a-fA-F0-9]{32}$/.test(t3) ? t3.toUpperCase() : V2.split('') .map(function () { return 'ABCDEF0123456789'.charAt( Math.floor(16 * Math.random()) ) }) .join('')), null !== m2 && (Ye = new I( m2.userPermissions, m2.userPassword, m2.ownerPassword, V2 )), V2 ) }) ;(y2.setFileId = function (t3) { return Y2(t3), this }), (y2.getFileId = function () { return G2() }) var J2 = (y2.__private__.convertDateToPDFDate = function (t3) { var e3 = t3.getTimezoneOffset(), r3 = e3 < 0 ? '+' : '-', n2 = Math.floor(Math.abs(e3 / 60)), i3 = Math.abs(e3 % 60), a2 = [r3, Q2(n2), "'", Q2(i3), "'"].join('') return [ 'D:', t3.getFullYear(), Q2(t3.getMonth() + 1), Q2(t3.getDate()), Q2(t3.getHours()), Q2(t3.getMinutes()), Q2(t3.getSeconds()), a2, ].join('') }), X2 = (y2.__private__.convertPDFDateToDate = function (t3) { var e3 = parseInt(t3.substr(2, 4), 10), r3 = parseInt(t3.substr(6, 2), 10) - 1, n2 = parseInt(t3.substr(8, 2), 10), i3 = parseInt(t3.substr(10, 2), 10), a2 = parseInt(t3.substr(12, 2), 10), o3 = parseInt(t3.substr(14, 2), 10) return new Date(e3, r3, n2, i3, a2, o3, 0) }), K2 = (y2.__private__.setCreationDate = function (t3) { var e3 if ((void 0 === t3 && (t3 = new Date()), t3 instanceof Date)) e3 = J2(t3) else { if ( !/^D:(20[0-2][0-9]|203[0-7]|19[7-9][0-9])(0[0-9]|1[0-2])([0-2][0-9]|3[0-1])(0[0-9]|1[0-9]|2[0-3])(0[0-9]|[1-5][0-9])(0[0-9]|[1-5][0-9])(\+0[0-9]|\+1[0-4]|-0[0-9]|-1[0-1])'(0[0-9]|[1-5][0-9])'?$/.test( t3 ) ) throw new Error('Invalid argument passed to jsPDF.setCreationDate') e3 = t3 } return (W2 = e3) }), Z2 = (y2.__private__.getCreationDate = function (t3) { var e3 = W2 return 'jsDate' === t3 && (e3 = X2(W2)), e3 }) ;(y2.setCreationDate = function (t3) { return K2(t3), this }), (y2.getCreationDate = function (t3) { return Z2(t3) }) var $2, Q2 = (y2.__private__.padd2 = function (t3) { return ('0' + parseInt(t3)).slice(-2) }), tt2 = (y2.__private__.padd2Hex = function (t3) { return ('00' + (t3 = t3.toString())).substr(t3.length) }), et2 = 0, rt2 = [], nt2 = [], it2 = 0, at2 = [], ot2 = [], st2 = false, ct2 = nt2, ut2 = function () { ;(et2 = 0), (it2 = 0), (nt2 = []), (rt2 = []), (at2 = []), (Qt2 = Kt2()), (te2 = Kt2()) } y2.__private__.setCustomOutputDestination = function (t3) { ;(st2 = true), (ct2 = t3) } var ht2 = function (t3) { st2 || (ct2 = t3) } y2.__private__.resetCustomOutputDestination = function () { ;(st2 = false), (ct2 = nt2) } var lt2 = (y2.__private__.out = function (t3) { return (t3 = t3.toString()), (it2 += t3.length + 1), ct2.push(t3), ct2 }), ft2 = (y2.__private__.write = function (t3) { return lt2( 1 === arguments.length ? t3.toString() : Array.prototype.join.call(arguments, ' ') ) }), dt2 = (y2.__private__.getArrayBuffer = function (t3) { for ( var e3 = t3.length, r3 = new ArrayBuffer(e3), n2 = new Uint8Array(r3); e3--; ) n2[e3] = t3.charCodeAt(e3) return r3 }), pt3 = [ ['Helvetica', 'helvetica', 'normal', 'WinAnsiEncoding'], ['Helvetica-Bold', 'helvetica', 'bold', 'WinAnsiEncoding'], ['Helvetica-Oblique', 'helvetica', 'italic', 'WinAnsiEncoding'], ['Helvetica-BoldOblique', 'helvetica', 'bolditalic', 'WinAnsiEncoding'], ['Courier', 'courier', 'normal', 'WinAnsiEncoding'], ['Courier-Bold', 'courier', 'bold', 'WinAnsiEncoding'], ['Courier-Oblique', 'courier', 'italic', 'WinAnsiEncoding'], ['Courier-BoldOblique', 'courier', 'bolditalic', 'WinAnsiEncoding'], ['Times-Roman', 'times', 'normal', 'WinAnsiEncoding'], ['Times-Bold', 'times', 'bold', 'WinAnsiEncoding'], ['Times-Italic', 'times', 'italic', 'WinAnsiEncoding'], ['Times-BoldItalic', 'times', 'bolditalic', 'WinAnsiEncoding'], ['ZapfDingbats', 'zapfdingbats', 'normal', null], ['Symbol', 'symbol', 'normal', null], ] y2.__private__.getStandardFonts = function () { return pt3 } var gt2 = e2.fontSize || 16 y2.__private__.setFontSize = y2.setFontSize = function (t3) { return (gt2 = S2 === x2.ADVANCED ? t3 / _t2 : t3), this } var mt2, vt2 = (y2.__private__.getFontSize = y2.getFontSize = function () { return S2 === x2.COMPAT ? gt2 : gt2 * _t2 }), bt2 = e2.R2L || false ;(y2.__private__.setR2L = y2.setR2L = function (t3) { return (bt2 = t3), this }), (y2.__private__.getR2L = y2.getR2L = function () { return bt2 }) var yt2, wt2 = (y2.__private__.setZoomMode = function (t3) { var e3 = [void 0, null, 'fullwidth', 'fullheight', 'fullpage', 'original'] if (/^(?:\d+\.\d*|\d*\.\d+|\d+)%$/.test(t3)) mt2 = t3 else if (isNaN(t3)) { if (-1 === e3.indexOf(t3)) throw new Error( 'zoom must be Integer (e.g. 2), a percentage Value (e.g. 300%) or fullwidth, fullheight, fullpage, original. "' + t3 + '" is not recognized.' ) mt2 = t3 } else mt2 = parseInt(t3, 10) }) y2.__private__.getZoomMode = function () { return mt2 } var Nt2, Lt2 = (y2.__private__.setPageMode = function (t3) { if ( -1 == [ void 0, null, 'UseNone', 'UseOutlines', 'UseThumbs', 'FullScreen', ].indexOf(t3) ) throw new Error( 'Page mode must be one of UseNone, UseOutlines, UseThumbs, or FullScreen. "' + t3 + '" is not recognized.' ) yt2 = t3 }) y2.__private__.getPageMode = function () { return yt2 } var At2 = (y2.__private__.setLayoutMode = function (t3) { if ( -1 == [ void 0, null, 'continuous', 'single', 'twoleft', 'tworight', 'two', ].indexOf(t3) ) throw new Error( 'Layout mode must be one of continuous, single, twoleft, tworight. "' + t3 + '" is not recognized.' ) Nt2 = t3 }) ;(y2.__private__.getLayoutMode = function () { return Nt2 }), (y2.__private__.setDisplayMode = y2.setDisplayMode = function (t3, e3, r3) { return wt2(t3), At2(e3), Lt2(r3), this }) var xt2 = { title: '', subject: '', author: '', keywords: '', creator: '' } ;(y2.__private__.getDocumentProperty = function (t3) { if (-1 === Object.keys(xt2).indexOf(t3)) throw new Error('Invalid argument passed to jsPDF.getDocumentProperty') return xt2[t3] }), (y2.__private__.getDocumentProperties = function () { return xt2 }), (y2.__private__.setDocumentProperties = y2.setProperties = y2.setDocumentProperties = function (t3) { for (var e3 in xt2) xt2.hasOwnProperty(e3) && t3[e3] && (xt2[e3] = t3[e3]) return this }), (y2.__private__.setDocumentProperty = function (t3, e3) { if (-1 === Object.keys(xt2).indexOf(t3)) throw new Error('Invalid arguments passed to jsPDF.setDocumentProperty') return (xt2[t3] = e3) }) var St, _t2, Pt2, kt2, It2, Ft2 = {}, Ct2 = {}, jt2 = [], Ot2 = {}, Bt2 = {}, Mt2 = {}, Et2 = {}, qt2 = null, Dt2 = 0, Rt2 = [], Tt2 = new C(y2), Ut2 = e2.hotfixes || [], zt2 = {}, Ht2 = {}, Wt2 = [], Vt2 = function t3(e3, r3, n2, i3, a2, o3) { if (!(this instanceof t3)) return new t3(e3, r3, n2, i3, a2, o3) isNaN(e3) && (e3 = 1), isNaN(r3) && (r3 = 0), isNaN(n2) && (n2 = 0), isNaN(i3) && (i3 = 1), isNaN(a2) && (a2 = 0), isNaN(o3) && (o3 = 0), (this._matrix = [e3, r3, n2, i3, a2, o3]) } Object.defineProperty(Vt2.prototype, 'sx', { get: function () { return this._matrix[0] }, set: function (t3) { this._matrix[0] = t3 }, }), Object.defineProperty(Vt2.prototype, 'shy', { get: function () { return this._matrix[1] }, set: function (t3) { this._matrix[1] = t3 }, }), Object.defineProperty(Vt2.prototype, 'shx', { get: function () { return this._matrix[2] }, set: function (t3) { this._matrix[2] = t3 }, }), Object.defineProperty(Vt2.prototype, 'sy', { get: function () { return this._matrix[3] }, set: function (t3) { this._matrix[3] = t3 }, }), Object.defineProperty(Vt2.prototype, 'tx', { get: function () { return this._matrix[4] }, set: function (t3) { this._matrix[4] = t3 }, }), Object.defineProperty(Vt2.prototype, 'ty', { get: function () { return this._matrix[5] }, set: function (t3) { this._matrix[5] = t3 }, }), Object.defineProperty(Vt2.prototype, 'a', { get: function () { return this._matrix[0] }, set: function (t3) { this._matrix[0] = t3 }, }), Object.defineProperty(Vt2.prototype, 'b', { get: function () { return this._matrix[1] }, set: function (t3) { this._matrix[1] = t3 }, }), Object.defineProperty(Vt2.prototype, 'c', { get: function () { return this._matrix[2] }, set: function (t3) { this._matrix[2] = t3 }, }), Object.defineProperty(Vt2.prototype, 'd', { get: function () { return this._matrix[3] }, set: function (t3) { this._matrix[3] = t3 }, }), Object.defineProperty(Vt2.prototype, 'e', { get: function () { return this._matrix[4] }, set: function (t3) { this._matrix[4] = t3 }, }), Object.defineProperty(Vt2.prototype, 'f', { get: function () { return this._matrix[5] }, set: function (t3) { this._matrix[5] = t3 }, }), Object.defineProperty(Vt2.prototype, 'rotation', { get: function () { return Math.atan2(this.shx, this.sx) }, }), Object.defineProperty(Vt2.prototype, 'scaleX', { get: function () { return this.decompose().scale.sx }, }), Object.defineProperty(Vt2.prototype, 'scaleY', { get: function () { return this.decompose().scale.sy }, }), Object.defineProperty(Vt2.prototype, 'isIdentity', { get: function () { return ( 1 === this.sx && 0 === this.shy && 0 === this.shx && 1 === this.sy && 0 === this.tx && 0 === this.ty ) }, }), (Vt2.prototype.join = function (t3) { return [this.sx, this.shy, this.shx, this.sy, this.tx, this.ty] .map(O2) .join(t3) }), (Vt2.prototype.multiply = function (t3) { var e3 = t3.sx * this.sx + t3.shy * this.shx, r3 = t3.sx * this.shy + t3.shy * this.sy, n2 = t3.shx * this.sx + t3.sy * this.shx, i3 = t3.shx * this.shy + t3.sy * this.sy, a2 = t3.tx * this.sx + t3.ty * this.shx + this.tx, o3 = t3.tx * this.shy + t3.ty * this.sy + this.ty return new Vt2(e3, r3, n2, i3, a2, o3) }), (Vt2.prototype.decompose = function () { var t3 = this.sx, e3 = this.shy, r3 = this.shx, n2 = this.sy, i3 = this.tx, a2 = this.ty, o3 = Math.sqrt(t3 * t3 + e3 * e3), s3 = (t3 /= o3) * r3 + (e3 /= o3) * n2 ;(r3 -= t3 * s3), (n2 -= e3 * s3) var c3 = Math.sqrt(r3 * r3 + n2 * n2) return ( (s3 /= c3), t3 * (n2 /= c3) < e3 * (r3 /= c3) && ((t3 = -t3), (e3 = -e3), (s3 = -s3), (o3 = -o3)), { scale: new Vt2(o3, 0, 0, c3, 0, 0), translate: new Vt2(1, 0, 0, 1, i3, a2), rotate: new Vt2(t3, e3, -e3, t3, 0, 0), skew: new Vt2(1, 0, s3, 1, 0, 0), } ) }), (Vt2.prototype.toString = function (t3) { return this.join(' ') }), (Vt2.prototype.inversed = function () { var t3 = this.sx, e3 = this.shy, r3 = this.shx, n2 = this.sy, i3 = this.tx, a2 = this.ty, o3 = 1 / (t3 * n2 - e3 * r3), s3 = n2 * o3, c3 = -e3 * o3, u3 = -r3 * o3, h2 = t3 * o3 return new Vt2(s3, c3, u3, h2, -s3 * i3 - u3 * a2, -c3 * i3 - h2 * a2) }), (Vt2.prototype.applyToPoint = function (t3) { var e3 = t3.x * this.sx + t3.y * this.shx + this.tx, r3 = t3.x * this.shy + t3.y * this.sy + this.ty return new Cr(e3, r3) }), (Vt2.prototype.applyToRectangle = function (t3) { var e3 = this.applyToPoint(t3), r3 = this.applyToPoint(new Cr(t3.x + t3.w, t3.y + t3.h)) return new jr(e3.x, e3.y, r3.x - e3.x, r3.y - e3.y) }), (Vt2.prototype.clone = function () { var t3 = this.sx, e3 = this.shy, r3 = this.shx, n2 = this.sy, i3 = this.tx, a2 = this.ty return new Vt2(t3, e3, r3, n2, i3, a2) }), (y2.Matrix = Vt2) var Gt2 = (y2.matrixMult = function (t3, e3) { return e3.multiply(t3) }), Yt2 = new Vt2(1, 0, 0, 1, 0, 0) y2.unitMatrix = y2.identityMatrix = Yt2 var Jt2 = function (t3, e3) { if (!Bt2[t3]) { var r3 = (e3 instanceof B ? 'Sh' : 'P') + (Object.keys(Ot2).length + 1).toString(10) ;(e3.id = r3), (Bt2[t3] = r3), (Ot2[r3] = e3), Tt2.publish('addPattern', e3) } } ;(y2.ShadingPattern = B), (y2.TilingPattern = M), (y2.addShadingPattern = function (t3, e3) { return q2('addShadingPattern()'), Jt2(t3, e3), this }), (y2.beginTilingPattern = function (t3) { q2('beginTilingPattern()'), Br( t3.boundingBox[0], t3.boundingBox[1], t3.boundingBox[2] - t3.boundingBox[0], t3.boundingBox[3] - t3.boundingBox[1], t3.matrix ) }), (y2.endTilingPattern = function (t3, e3) { q2('endTilingPattern()'), (e3.stream = ot2[$2].join('\n')), Jt2(t3, e3), Tt2.publish('endTilingPattern', e3), Wt2.pop().restore() }) var Xt2 = (y2.__private__.newObject = function () { var t3 = Kt2() return Zt2(t3, true), t3 }), Kt2 = (y2.__private__.newObjectDeferred = function () { return ( et2++, (rt2[et2] = function () { return it2 }), et2 ) }), Zt2 = function (t3, e3) { return ( (e3 = 'boolean' == typeof e3 && e3), (rt2[t3] = it2), e3 && lt2(t3 + ' 0 obj'), t3 ) }, $t2 = (y2.__private__.newAdditionalObject = function () { var t3 = { objId: Kt2(), content: '' } return at2.push(t3), t3 }), Qt2 = Kt2(), te2 = Kt2(), ee2 = (y2.__private__.decodeColorString = function (t3) { var e3 = t3.split(' ') if (2 !== e3.length || ('g' !== e3[1] && 'G' !== e3[1])) { if (5 === e3.length && ('k' === e3[4] || 'K' === e3[4])) { e3 = [ (1 - e3[0]) * (1 - e3[3]), (1 - e3[1]) * (1 - e3[3]), (1 - e3[2]) * (1 - e3[3]), 'r', ] } } else { var r3 = parseFloat(e3[0]) e3 = [r3, r3, r3, 'r'] } for (var n2 = '#', i3 = 0; i3 < 3; i3++) n2 += ('0' + Math.floor(255 * parseFloat(e3[i3])).toString(16)).slice( -2 ) return n2 }), re2 = (y2.__private__.encodeColorString = function (e3) { var r3 'string' == typeof e3 && (e3 = { ch1: e3 }) var n2 = e3.ch1, i3 = e3.ch2, a2 = e3.ch3, o3 = e3.ch4, s3 = 'draw' === e3.pdfColorType ? ['G', 'RG', 'K'] : ['g', 'rg', 'k'] if ('string' == typeof n2 && '#' !== n2.charAt(0)) { var c3 = new f$2(n2) if (c3.ok) n2 = c3.toHex() else if (!/^\d*\.?\d*$/.test(n2)) throw new Error( 'Invalid color "' + n2 + '" passed to jsPDF.encodeColorString.' ) } if ( ('string' == typeof n2 && /^#[0-9A-Fa-f]{3}$/.test(n2) && (n2 = '#' + n2[1] + n2[1] + n2[2] + n2[2] + n2[3] + n2[3]), 'string' == typeof n2 && /^#[0-9A-Fa-f]{6}$/.test(n2)) ) { var u3 = parseInt(n2.substr(1), 16) ;(n2 = (u3 >> 16) & 255), (i3 = (u3 >> 8) & 255), (a2 = 255 & u3) } if (void 0 === i3 || (void 0 === o3 && n2 === i3 && i3 === a2)) if ('string' == typeof n2) r3 = n2 + ' ' + s3[0] else switch (e3.precision) { case 2: r3 = R2(n2 / 255) + ' ' + s3[0] break case 3: default: r3 = T2(n2 / 255) + ' ' + s3[0] } else if (void 0 === o3 || 'object' === _typeof$3(o3)) { if (o3 && !isNaN(o3.a) && 0 === o3.a) return (r3 = ['1.', '1.', '1.', s3[1]].join(' ')) if ('string' == typeof n2) r3 = [n2, i3, a2, s3[1]].join(' ') else switch (e3.precision) { case 2: r3 = [R2(n2 / 255), R2(i3 / 255), R2(a2 / 255), s3[1]].join(' ') break default: case 3: r3 = [T2(n2 / 255), T2(i3 / 255), T2(a2 / 255), s3[1]].join(' ') } } else if ('string' == typeof n2) r3 = [n2, i3, a2, o3, s3[2]].join(' ') else switch (e3.precision) { case 2: r3 = [R2(n2), R2(i3), R2(a2), R2(o3), s3[2]].join(' ') break case 3: default: r3 = [T2(n2), T2(i3), T2(a2), T2(o3), s3[2]].join(' ') } return r3 }), ne2 = (y2.__private__.getFilters = function () { return u2 }), ie2 = (y2.__private__.putStream = function (t3) { var e3 = (t3 = t3 || {}).data || '', r3 = t3.filters || ne2(), n2 = t3.alreadyAppliedFilters || [], i3 = t3.addLength1 || false, a2 = e3.length, o3 = t3.objectId, s3 = function (t4) { return t4 } if (null !== m2 && void 0 === o3) throw new Error( 'ObjectId must be passed to putStream for file encryption' ) null !== m2 && (s3 = Ye.encryptor(o3, 0)) var c3 = {} true === r3 && (r3 = ['FlateEncode']) var u3 = t3.additionalKeyValues || [], h2 = (c3 = void 0 !== E$1.API.processDataByFilters ? E$1.API.processDataByFilters(e3, r3) : { data: e3, reverseChain: [] }).reverseChain + (Array.isArray(n2) ? n2.join(' ') : n2.toString()) if ( (0 !== c3.data.length && (u3.push({ key: 'Length', value: c3.data.length }), true === i3 && u3.push({ key: 'Length1', value: a2 })), 0 != h2.length) ) if (h2.split('/').length - 1 == 1) u3.push({ key: 'Filter', value: h2 }) else { u3.push({ key: 'Filter', value: '[' + h2 + ']' }) for (var l2 = 0; l2 < u3.length; l2 += 1) if ('DecodeParms' === u3[l2].key) { for ( var f2 = [], d4 = 0; d4 < c3.reverseChain.split('/').length - 1; d4 += 1 ) f2.push('null') f2.push(u3[l2].value), (u3[l2].value = '[' + f2.join(' ') + ']') } } lt2('<<') for (var p3 = 0; p3 < u3.length; p3++) lt2('/' + u3[p3].key + ' ' + u3[p3].value) lt2('>>'), 0 !== c3.data.length && (lt2('stream'), lt2(s3(c3.data)), lt2('endstream')) }), ae2 = (y2.__private__.putPage = function (t3) { var e3 = t3.number, r3 = t3.data, n2 = t3.objId, i3 = t3.contentsObjId Zt2(n2, true), lt2('<>'), lt2('endobj') var a2 = r3.join('\n') return ( S2 === x2.ADVANCED && (a2 += '\nQ'), Zt2(i3, true), ie2({ data: a2, filters: ne2(), objectId: i3 }), lt2('endobj'), n2 ) }), oe2 = (y2.__private__.putPages = function () { var t3, e3, r3 = [] for (t3 = 1; t3 <= Dt2; t3++) (Rt2[t3].objId = Kt2()), (Rt2[t3].contentsObjId = Kt2()) for (t3 = 1; t3 <= Dt2; t3++) r3.push( ae2({ number: t3, data: ot2[t3], objId: Rt2[t3].objId, contentsObjId: Rt2[t3].contentsObjId, mediaBox: Rt2[t3].mediaBox, cropBox: Rt2[t3].cropBox, bleedBox: Rt2[t3].bleedBox, trimBox: Rt2[t3].trimBox, artBox: Rt2[t3].artBox, userUnit: Rt2[t3].userUnit, rootDictionaryObjId: Qt2, resourceDictionaryObjId: te2, }) ) Zt2(Qt2, true), lt2('<>'), lt2('endobj'), Tt2.publish('postPutPages') }), se2 = function (t3) { Tt2.publish('putFont', { font: t3, out: lt2, newObject: Xt2, putStream: ie2, }), true !== t3.isAlreadyPutted && ((t3.objectNumber = Xt2()), lt2('<<'), lt2('/Type /Font'), lt2('/BaseFont /' + F$1(t3.postScriptName)), lt2('/Subtype /Type1'), 'string' == typeof t3.encoding && lt2('/Encoding /' + t3.encoding), lt2('/FirstChar 32'), lt2('/LastChar 255'), lt2('>>'), lt2('endobj')) }, ce2 = function () { for (var t3 in Ft2) Ft2.hasOwnProperty(t3) && (false === v4 || (true === v4 && b2.hasOwnProperty(t3))) && se2(Ft2[t3]) }, ue2 = function (t3) { t3.objectNumber = Xt2() var e3 = [] e3.push({ key: 'Type', value: '/XObject' }), e3.push({ key: 'Subtype', value: '/Form' }), e3.push({ key: 'BBox', value: '[' + [ O2(t3.x), O2(t3.y), O2(t3.x + t3.width), O2(t3.y + t3.height), ].join(' ') + ']', }), e3.push({ key: 'Matrix', value: '[' + t3.matrix.toString() + ']' }) var r3 = t3.pages[1].join('\n') ie2({ data: r3, additionalKeyValues: e3, objectId: t3.objectNumber }), lt2('endobj') }, he2 = function () { for (var t3 in zt2) zt2.hasOwnProperty(t3) && ue2(zt2[t3]) }, le2 = function (t3, e3) { var r3, n2 = [], i3 = 1 / (e3 - 1) for (r3 = 0; r3 < 1; r3 += i3) n2.push(r3) if ((n2.push(1), 0 != t3[0].offset)) { var a2 = { offset: 0, color: t3[0].color } t3.unshift(a2) } if (1 != t3[t3.length - 1].offset) { var o3 = { offset: 1, color: t3[t3.length - 1].color } t3.push(o3) } for (var s3 = '', c3 = 0, u3 = 0; u3 < n2.length; u3++) { for (r3 = n2[u3]; r3 > t3[c3 + 1].offset; ) c3++ var h2 = t3[c3].offset, l2 = (r3 - h2) / (t3[c3 + 1].offset - h2), f2 = t3[c3].color, d4 = t3[c3 + 1].color s3 += tt2(Math.round((1 - l2) * f2[0] + l2 * d4[0]).toString(16)) + tt2(Math.round((1 - l2) * f2[1] + l2 * d4[1]).toString(16)) + tt2(Math.round((1 - l2) * f2[2] + l2 * d4[2]).toString(16)) } return s3.trim() }, fe2 = function (t3, e3) { e3 || (e3 = 21) var r3 = Xt2(), n2 = le2(t3.colors, e3), i3 = [] i3.push({ key: 'FunctionType', value: '0' }), i3.push({ key: 'Domain', value: '[0.0 1.0]' }), i3.push({ key: 'Size', value: '[' + e3 + ']' }), i3.push({ key: 'BitsPerSample', value: '8' }), i3.push({ key: 'Range', value: '[0.0 1.0 0.0 1.0 0.0 1.0]' }), i3.push({ key: 'Decode', value: '[0.0 1.0 0.0 1.0 0.0 1.0]' }), ie2({ data: n2, additionalKeyValues: i3, alreadyAppliedFilters: ['/ASCIIHexDecode'], objectId: r3, }), lt2('endobj'), (t3.objectNumber = Xt2()), lt2('<< /ShadingType ' + t3.type), lt2('/ColorSpace /DeviceRGB') var a2 = '/Coords [' + O2(parseFloat(t3.coords[0])) + ' ' + O2(parseFloat(t3.coords[1])) + ' ' 2 === t3.type ? (a2 += O2(parseFloat(t3.coords[2])) + ' ' + O2(parseFloat(t3.coords[3]))) : (a2 += O2(parseFloat(t3.coords[2])) + ' ' + O2(parseFloat(t3.coords[3])) + ' ' + O2(parseFloat(t3.coords[4])) + ' ' + O2(parseFloat(t3.coords[5]))), lt2((a2 += ']')), t3.matrix && lt2('/Matrix [' + t3.matrix.toString() + ']'), lt2('/Function ' + r3 + ' 0 R'), lt2('/Extend [true true]'), lt2('>>'), lt2('endobj') }, de2 = function (t3, e3) { var r3 = Kt2(), n2 = Xt2() e3.push({ resourcesOid: r3, objectOid: n2 }), (t3.objectNumber = n2) var i3 = [] i3.push({ key: 'Type', value: '/Pattern' }), i3.push({ key: 'PatternType', value: '1' }), i3.push({ key: 'PaintType', value: '1' }), i3.push({ key: 'TilingType', value: '1' }), i3.push({ key: 'BBox', value: '[' + t3.boundingBox.map(O2).join(' ') + ']', }), i3.push({ key: 'XStep', value: O2(t3.xStep) }), i3.push({ key: 'YStep', value: O2(t3.yStep) }), i3.push({ key: 'Resources', value: r3 + ' 0 R' }), t3.matrix && i3.push({ key: 'Matrix', value: '[' + t3.matrix.toString() + ']' }), ie2({ data: t3.stream, additionalKeyValues: i3, objectId: t3.objectNumber, }), lt2('endobj') }, pe2 = function (t3) { var e3 for (e3 in Ot2) Ot2.hasOwnProperty(e3) && (Ot2[e3] instanceof B ? fe2(Ot2[e3]) : Ot2[e3] instanceof M && de2(Ot2[e3], t3)) }, ge2 = function (t3) { for (var e3 in ((t3.objectNumber = Xt2()), lt2('<<'), t3)) switch (e3) { case 'opacity': lt2('/ca ' + R2(t3[e3])) break case 'stroke-opacity': lt2('/CA ' + R2(t3[e3])) } lt2('>>'), lt2('endobj') }, me2 = function () { var t3 for (t3 in Mt2) Mt2.hasOwnProperty(t3) && ge2(Mt2[t3]) }, ve2 = function () { for (var t3 in (lt2('/XObject <<'), zt2)) zt2.hasOwnProperty(t3) && zt2[t3].objectNumber >= 0 && lt2('/' + t3 + ' ' + zt2[t3].objectNumber + ' 0 R') Tt2.publish('putXobjectDict'), lt2('>>') }, be2 = function () { ;(Ye.oid = Xt2()), lt2('<<'), lt2('/Filter /Standard'), lt2('/V ' + Ye.v), lt2('/R ' + Ye.r), lt2('/U <' + Ye.toHexString(Ye.U) + '>'), lt2('/O <' + Ye.toHexString(Ye.O) + '>'), lt2('/P ' + Ye.P), lt2('>>'), lt2('endobj') }, ye2 = function () { for (var t3 in (lt2('/Font <<'), Ft2)) Ft2.hasOwnProperty(t3) && (false === v4 || (true === v4 && b2.hasOwnProperty(t3))) && lt2('/' + t3 + ' ' + Ft2[t3].objectNumber + ' 0 R') lt2('>>') }, we2 = function () { if (Object.keys(Ot2).length > 0) { for (var t3 in (lt2('/Shading <<'), Ot2)) Ot2.hasOwnProperty(t3) && Ot2[t3] instanceof B && Ot2[t3].objectNumber >= 0 && lt2('/' + t3 + ' ' + Ot2[t3].objectNumber + ' 0 R') Tt2.publish('putShadingPatternDict'), lt2('>>') } }, Ne2 = function (t3) { if (Object.keys(Ot2).length > 0) { for (var e3 in (lt2('/Pattern <<'), Ot2)) Ot2.hasOwnProperty(e3) && Ot2[e3] instanceof y2.TilingPattern && Ot2[e3].objectNumber >= 0 && Ot2[e3].objectNumber < t3 && lt2('/' + e3 + ' ' + Ot2[e3].objectNumber + ' 0 R') Tt2.publish('putTilingPatternDict'), lt2('>>') } }, Le2 = function () { if (Object.keys(Mt2).length > 0) { var t3 for (t3 in (lt2('/ExtGState <<'), Mt2)) Mt2.hasOwnProperty(t3) && Mt2[t3].objectNumber >= 0 && lt2('/' + t3 + ' ' + Mt2[t3].objectNumber + ' 0 R') Tt2.publish('putGStateDict'), lt2('>>') } }, Ae = function (t3) { Zt2(t3.resourcesOid, true), lt2('<<'), lt2('/ProcSet [/PDF /Text /ImageB /ImageC /ImageI]'), ye2(), we2(), Ne2(t3.objectOid), Le2(), ve2(), lt2('>>'), lt2('endobj') }, xe = function () { var t3 = [] ce2(), me2(), he2(), pe2(t3), Tt2.publish('putResources'), t3.forEach(Ae), Ae({ resourcesOid: te2, objectOid: Number.MAX_SAFE_INTEGER }), Tt2.publish('postPutResources') }, Se = function () { Tt2.publish('putAdditionalObjects') for (var t3 = 0; t3 < at2.length; t3++) { var e3 = at2[t3] Zt2(e3.objId, true), lt2(e3.content), lt2('endobj') } Tt2.publish('postPutAdditionalObjects') }, _e = function (t3) { ;(Ct2[t3.fontName] = Ct2[t3.fontName] || {}), (Ct2[t3.fontName][t3.fontStyle] = t3.id) }, Pe = function (t3, e3, r3, n2, i3) { var a2 = { id: 'F' + (Object.keys(Ft2).length + 1).toString(10), postScriptName: t3, fontName: e3, fontStyle: r3, encoding: n2, isStandardFont: i3 || false, metadata: {}, } return ( Tt2.publish('addFont', { font: a2, instance: this }), (Ft2[a2.id] = a2), _e(a2), a2.id ) }, ke = function (t3) { for (var e3 = 0, r3 = pt3.length; e3 < r3; e3++) { var n2 = Pe.call( this, t3[e3][0], t3[e3][1], t3[e3][2], pt3[e3][3], true ) false === v4 && (b2[n2] = true) var i3 = t3[e3][0].split('-') _e({ id: n2, fontName: i3[0], fontStyle: i3[1] || '' }) } Tt2.publish('addFonts', { fonts: Ft2, dictionary: Ct2 }) }, Ie = function (t3) { return ( (t3.foo = function () { try { return t3.apply(this, arguments) } catch (t4) { var e3 = t4.stack || '' ~e3.indexOf(' at ') && (e3 = e3.split(' at ')[1]) var r3 = 'Error in function ' + e3.split('\n')[0].split('<')[0] + ': ' + t4.message if (!n$1.console) throw new Error(r3) n$1.console.error(r3, t4), n$1.alert && alert(r3) } }), (t3.foo.bar = t3), t3.foo ) }, Fe = function (t3, e3) { var r3, n2, i3, a2, o3, s3, c3, u3, h2 if ( ((i3 = (e3 = e3 || {}).sourceEncoding || 'Unicode'), (o3 = e3.outputEncoding), (e3.autoencode || o3) && Ft2[St].metadata && Ft2[St].metadata[i3] && Ft2[St].metadata[i3].encoding && ((a2 = Ft2[St].metadata[i3].encoding), !o3 && Ft2[St].encoding && (o3 = Ft2[St].encoding), !o3 && a2.codePages && (o3 = a2.codePages[0]), 'string' == typeof o3 && (o3 = a2[o3]), o3)) ) { for (c3 = false, s3 = [], r3 = 0, n2 = t3.length; r3 < n2; r3++) (u3 = o3[t3.charCodeAt(r3)]) ? s3.push(String.fromCharCode(u3)) : s3.push(t3[r3]), s3[r3].charCodeAt(0) >> 8 && (c3 = true) t3 = s3.join('') } for (r3 = t3.length; void 0 === c3 && 0 !== r3; ) t3.charCodeAt(r3 - 1) >> 8 && (c3 = true), r3-- if (!c3) return t3 for ( s3 = e3.noBOM ? [] : [254, 255], r3 = 0, n2 = t3.length; r3 < n2; r3++ ) { if ((h2 = (u3 = t3.charCodeAt(r3)) >> 8) >> 8) throw new Error( 'Character at position ' + r3 + " of string '" + t3 + "' exceeds 16bits. Cannot be encoded into UCS-2 BE" ) s3.push(h2), s3.push(u3 - (h2 << 8)) } return String.fromCharCode.apply(void 0, s3) }, Ce = (y2.__private__.pdfEscape = y2.pdfEscape = function (t3, e3) { return Fe(t3, e3) .replace(/\\/g, '\\\\') .replace(/\(/g, '\\(') .replace(/\)/g, '\\)') }), je = (y2.__private__.beginPage = function (t3) { ;(ot2[++Dt2] = []), (Rt2[Dt2] = { objId: 0, contentsObjId: 0, userUnit: Number(d3), artBox: null, bleedBox: null, cropBox: null, trimBox: null, mediaBox: { bottomLeftX: 0, bottomLeftY: 0, topRightX: Number(t3[0]), topRightY: Number(t3[1]), }, }), Me(Dt2), ht2(ot2[$2]) }), Oe = function (t3, e3) { var r3, n2, o3 switch ( ((i2 = e3 || i2), 'string' == typeof t3 && ((r3 = A2(t3.toLowerCase())), Array.isArray(r3) && ((n2 = r3[0]), (o3 = r3[1]))), Array.isArray(t3) && ((n2 = t3[0] * _t2), (o3 = t3[1] * _t2)), isNaN(n2) && ((n2 = s2[0]), (o3 = s2[1])), (n2 > 14400 || o3 > 14400) && (a$2.warn( 'A page in a PDF can not be wider or taller than 14400 userUnit. jsPDF limits the width/height to 14400' ), (n2 = Math.min(14400, n2)), (o3 = Math.min(14400, o3))), (s2 = [n2, o3]), i2.substr(0, 1)) ) { case 'l': o3 > n2 && (s2 = [o3, n2]) break case 'p': n2 > o3 && (s2 = [o3, n2]) } je(s2), pr(fr2), lt2(Lr), 0 !== kr && lt2(kr + ' J'), 0 !== Ir && lt2(Ir + ' j'), Tt2.publish('addPage', { pageNumber: Dt2 }) }, Be = function (t3) { t3 > 0 && t3 <= Dt2 && (ot2.splice(t3, 1), Rt2.splice(t3, 1), Dt2--, $2 > Dt2 && ($2 = Dt2), this.setPage($2)) }, Me = function (t3) { t3 > 0 && t3 <= Dt2 && ($2 = t3) }, Ee = (y2.__private__.getNumberOfPages = y2.getNumberOfPages = function () { return ot2.length - 1 }), qe = function (t3, e3, r3) { var n2, i3 = void 0 return ( (r3 = r3 || {}), (t3 = void 0 !== t3 ? t3 : Ft2[St].fontName), (e3 = void 0 !== e3 ? e3 : Ft2[St].fontStyle), (n2 = t3.toLowerCase()), void 0 !== Ct2[n2] && void 0 !== Ct2[n2][e3] ? (i3 = Ct2[n2][e3]) : void 0 !== Ct2[t3] && void 0 !== Ct2[t3][e3] ? (i3 = Ct2[t3][e3]) : false === r3.disableWarning && a$2.warn( "Unable to look up font label for font '" + t3 + "', '" + e3 + "'. Refer to getFontList() for available fonts." ), i3 || r3.noFallback || (null == (i3 = Ct2.times[e3]) && (i3 = Ct2.times.normal)), i3 ) }, De = (y2.__private__.putInfo = function () { var t3 = Xt2(), e3 = function (t4) { return t4 } for (var r3 in (null !== m2 && (e3 = Ye.encryptor(t3, 0)), lt2('<<'), lt2('/Producer (' + Ce(e3('jsPDF ' + E$1.version)) + ')'), xt2)) xt2.hasOwnProperty(r3) && xt2[r3] && lt2( '/' + r3.substr(0, 1).toUpperCase() + r3.substr(1) + ' (' + Ce(e3(xt2[r3])) + ')' ) lt2('/CreationDate (' + Ce(e3(W2)) + ')'), lt2('>>'), lt2('endobj') }), Re = (y2.__private__.putCatalog = function (t3) { var e3 = (t3 = t3 || {}).rootDictionaryObjId || Qt2 switch ( (Xt2(), lt2('<<'), lt2('/Type /Catalog'), lt2('/Pages ' + e3 + ' 0 R'), mt2 || (mt2 = 'fullwidth'), mt2) ) { case 'fullwidth': lt2('/OpenAction [3 0 R /FitH null]') break case 'fullheight': lt2('/OpenAction [3 0 R /FitV null]') break case 'fullpage': lt2('/OpenAction [3 0 R /Fit]') break case 'original': lt2('/OpenAction [3 0 R /XYZ null null 1]') break default: var r3 = '' + mt2 '%' === r3.substr(r3.length - 1) && (mt2 = parseInt(mt2) / 100), 'number' == typeof mt2 && lt2('/OpenAction [3 0 R /XYZ null null ' + R2(mt2) + ']') } switch ((Nt2 || (Nt2 = 'continuous'), Nt2)) { case 'continuous': lt2('/PageLayout /OneColumn') break case 'single': lt2('/PageLayout /SinglePage') break case 'two': case 'twoleft': lt2('/PageLayout /TwoColumnLeft') break case 'tworight': lt2('/PageLayout /TwoColumnRight') } yt2 && lt2('/PageMode /' + yt2), Tt2.publish('putCatalog'), lt2('>>'), lt2('endobj') }), Te = (y2.__private__.putTrailer = function () { lt2('trailer'), lt2('<<'), lt2('/Size ' + (et2 + 1)), lt2('/Root ' + et2 + ' 0 R'), lt2('/Info ' + (et2 - 1) + ' 0 R'), null !== m2 && lt2('/Encrypt ' + Ye.oid + ' 0 R'), lt2('/ID [ <' + V2 + '> <' + V2 + '> ]'), lt2('>>') }), Ue = (y2.__private__.putHeader = function () { lt2('%PDF-' + w2), lt2('%\xBA\xDF\xAC\xE0') }), ze = (y2.__private__.putXRef = function () { var t3 = '0000000000' lt2('xref'), lt2('0 ' + (et2 + 1)), lt2('0000000000 65535 f ') for (var e3 = 1; e3 <= et2; e3++) { 'function' == typeof rt2[e3] ? lt2((t3 + rt2[e3]()).slice(-10) + ' 00000 n ') : void 0 !== rt2[e3] ? lt2((t3 + rt2[e3]).slice(-10) + ' 00000 n ') : lt2('0000000000 00000 n ') } }), He = (y2.__private__.buildDocument = function () { ut2(), ht2(nt2), Tt2.publish('buildDocument'), Ue(), oe2(), Se(), xe(), null !== m2 && be2(), De(), Re() var t3 = it2 return ( ze(), Te(), lt2('startxref'), lt2('' + t3), lt2('%%EOF'), ht2(ot2[$2]), nt2.join('\n') ) }), We = (y2.__private__.getBlob = function (t3) { return new Blob([dt2(t3)], { type: 'application/pdf' }) }), Ve = (y2.output = y2.__private__.output = Ie(function (t3, e3) { switch ( ('string' == typeof (e3 = e3 || {}) ? (e3 = { filename: e3 }) : (e3.filename = e3.filename || 'generated.pdf'), t3) ) { case void 0: return He() case 'save': y2.save(e3.filename) break case 'arraybuffer': return dt2(He()) case 'blob': return We(He()) case 'bloburi': case 'bloburl': if ( void 0 !== n$1.URL && 'function' == typeof n$1.URL.createObjectURL ) return (n$1.URL && n$1.URL.createObjectURL(We(He()))) || void 0 a$2.warn( 'bloburl is not supported by your system, because URL.createObjectURL is not supported by your browser.' ) break case 'datauristring': case 'dataurlstring': var r3 = '', i3 = He() try { r3 = h$1(i3) } catch (t4) { r3 = h$1(unescape(encodeURIComponent(i3))) } return ( 'data:application/pdf;filename=' + e3.filename + ';base64,' + r3 ) case 'pdfobjectnewwindow': if ('[object Window]' === Object.prototype.toString.call(n$1)) { var o3 = 'https://cdnjs.cloudflare.com/ajax/libs/pdfobject/2.1.1/pdfobject.min.js', s3 = ' integrity="sha512-4ze/a9/4jqu+tX9dfOqJYSvyYd5M6qum/3HpCLr+/Jqf0whc37VUbkpNGHR7/8pSnCFw47T1fmIpwBV7UySh3g==" crossorigin="anonymous"' e3.pdfObjectUrl && ((o3 = e3.pdfObjectUrl), (s3 = '')) var c3 = '', u3 = n$1.open() return null !== u3 && u3.document.write(c3), u3 } throw new Error( 'The option pdfobjectnewwindow just works in a browser-environment.' ) case 'pdfjsnewwindow': if ('[object Window]' === Object.prototype.toString.call(n$1)) { var l2 = '', g3 = n$1.open() if ( (null !== g3 && (g3.document.write(p3), (g3.document.title = e3.filename)), g3 || 'undefined' == typeof safari) ) return g3 break case 'datauri': case 'dataurl': return (n$1.document.location.href = this.output( 'datauristring', e3 )) default: return null } })), Ge = function (t3) { return true === Array.isArray(Ut2) && Ut2.indexOf(t3) > -1 } switch (o2) { case 'pt': _t2 = 1 break case 'mm': _t2 = 72 / 25.4 break case 'cm': _t2 = 72 / 2.54 break case 'in': _t2 = 72 break case 'px': _t2 = 1 == Ge('px_scaling') ? 0.75 : 96 / 72 break case 'pc': case 'em': _t2 = 12 break case 'ex': _t2 = 6 break default: if ('number' != typeof o2) throw new Error('Invalid unit: ' + o2) _t2 = o2 } var Ye = null K2(), Y2() var Je = function (t3) { return null !== m2 ? Ye.encryptor(t3, 0) : function (t4) { return t4 } }, Xe = (y2.__private__.getPageInfo = y2.getPageInfo = function (t3) { if (isNaN(t3) || t3 % 1 != 0) throw new Error('Invalid argument passed to jsPDF.getPageInfo') return { objId: Rt2[t3].objId, pageNumber: t3, pageContext: Rt2[t3] } }), Ke = (y2.__private__.getPageInfoByObjId = function (t3) { if (isNaN(t3) || t3 % 1 != 0) throw new Error('Invalid argument passed to jsPDF.getPageInfoByObjId') for (var e3 in Rt2) if (Rt2[e3].objId === t3) break return Xe(e3) }), Ze = (y2.__private__.getCurrentPageInfo = y2.getCurrentPageInfo = function () { return { objId: Rt2[$2].objId, pageNumber: $2, pageContext: Rt2[$2] } }) ;(y2.addPage = function () { return Oe.apply(this, arguments), this }), (y2.setPage = function () { return Me.apply(this, arguments), ht2.call(this, ot2[$2]), this }), (y2.insertPage = function (t3) { return this.addPage(), this.movePage($2, t3), this }), (y2.movePage = function (t3, e3) { var r3, n2 if (t3 > e3) { ;(r3 = ot2[t3]), (n2 = Rt2[t3]) for (var i3 = t3; i3 > e3; i3--) (ot2[i3] = ot2[i3 - 1]), (Rt2[i3] = Rt2[i3 - 1]) ;(ot2[e3] = r3), (Rt2[e3] = n2), this.setPage(e3) } else if (t3 < e3) { ;(r3 = ot2[t3]), (n2 = Rt2[t3]) for (var a2 = t3; a2 < e3; a2++) (ot2[a2] = ot2[a2 + 1]), (Rt2[a2] = Rt2[a2 + 1]) ;(ot2[e3] = r3), (Rt2[e3] = n2), this.setPage(e3) } return this }), (y2.deletePage = function () { return Be.apply(this, arguments), this }), (y2.__private__.text = y2.text = function (e3, r3, n2, i3, a2) { var o3, s3, c3, u3, h2, l2, f2, d4, p3, g3 = (i3 = i3 || {}).scope || this if ( 'number' == typeof e3 && 'number' == typeof r3 && ('string' == typeof n2 || Array.isArray(n2)) ) { var m3 = n2 ;(n2 = r3), (r3 = e3), (e3 = m3) } if ( (arguments[3] instanceof Vt2 == false ? ((c3 = arguments[4]), (u3 = arguments[5]), ('object' === _typeof$3((f2 = arguments[3])) && null !== f2) || ('string' == typeof c3 && ((u3 = c3), (c3 = null)), 'string' == typeof f2 && ((u3 = f2), (f2 = null)), 'number' == typeof f2 && ((c3 = f2), (f2 = null)), (i3 = { flags: f2, angle: c3, align: u3 }))) : (q2('The transform parameter of text() with a Matrix value'), (p3 = a2)), isNaN(r3) || isNaN(n2) || null == e3) ) throw new Error('Invalid arguments passed to jsPDF.text') if (0 === e3.length) return g3 var v5 = '', y3 = false, w3 = 'number' == typeof i3.lineHeightFactor ? i3.lineHeightFactor : lr, N3 = g3.internal.scaleFactor function L3(t3) { return ( (t3 = t3.split(' ').join(Array(i3.TabLen || 9).join(' '))), Ce(t3, f2) ) } function A3(t3) { for (var e4, r4 = t3.concat(), n3 = [], i4 = r4.length; i4--; ) 'string' == typeof (e4 = r4.shift()) ? n3.push(e4) : Array.isArray(t3) && (1 === e4.length || (void 0 === e4[1] && void 0 === e4[2])) ? n3.push(e4[0]) : n3.push([e4[0], e4[1], e4[2]]) return n3 } function _3(t3, e4) { var r4 if ('string' == typeof t3) r4 = e4(t3)[0] else if (Array.isArray(t3)) { for (var n3, i4, a3 = t3.concat(), o4 = [], s4 = a3.length; s4--; ) 'string' == typeof (n3 = a3.shift()) ? o4.push(e4(n3)[0]) : Array.isArray(n3) && 'string' == typeof n3[0] && ((i4 = e4(n3[0], n3[1], n3[2])), o4.push([i4[0], i4[1], i4[2]])) r4 = o4 } return r4 } var P3 = false, k3 = true if ('string' == typeof e3) P3 = true else if (Array.isArray(e3)) { var I2 = e3.concat() s3 = [] for (var F2, C2 = I2.length; C2--; ) ('string' != typeof (F2 = I2.shift()) || (Array.isArray(F2) && 'string' != typeof F2[0])) && (k3 = false) P3 = k3 } if (false === P3) throw new Error( 'Type of text must be string or Array. "' + e3 + '" is not recognized.' ) 'string' == typeof e3 && (e3 = e3.match(/[\r?\n]/) ? e3.split(/\r\n|\r|\n/g) : [e3]) var j2 = gt2 / g3.internal.scaleFactor, B3 = j2 * (w3 - 1) switch (i3.baseline) { case 'bottom': n2 -= B3 break case 'top': n2 += j2 - B3 break case 'hanging': n2 += j2 - 2 * B3 break case 'middle': n2 += j2 / 2 - B3 } if ( ((l2 = i3.maxWidth || 0) > 0 && ('string' == typeof e3 ? (e3 = g3.splitTextToSize(e3, l2)) : '[object Array]' === Object.prototype.toString.call(e3) && (e3 = e3.reduce(function (t3, e4) { return t3.concat(g3.splitTextToSize(e4, l2)) }, []))), (o3 = { text: e3, x: r3, y: n2, options: i3, mutex: { pdfEscape: Ce, activeFontKey: St, fonts: Ft2, activeFontSize: gt2, }, }), Tt2.publish('preProcessText', o3), (e3 = o3.text), (c3 = (i3 = o3.options).angle), p3 instanceof Vt2 == false && c3 && 'number' == typeof c3) ) { ;(c3 *= Math.PI / 180), 0 === i3.rotationDirection && (c3 = -c3), S2 === x2.ADVANCED && (c3 = -c3) var M2 = Math.cos(c3), E2 = Math.sin(c3) p3 = new Vt2(M2, E2, -E2, M2, 0, 0) } else c3 && c3 instanceof Vt2 && (p3 = c3) S2 !== x2.ADVANCED || p3 || (p3 = Yt2), void 0 !== (h2 = i3.charSpace || _r) && ((v5 += O2(U2(h2)) + ' Tc\n'), this.setCharSpace(this.getCharSpace() || 0)), void 0 !== (d4 = i3.horizontalScale) && (v5 += O2(100 * d4) + ' Tz\n') i3.lang var D3 = -1, R3 = void 0 !== i3.renderingMode ? i3.renderingMode : i3.stroke, T3 = g3.internal.getCurrentPageInfo().pageContext switch (R3) { case 0: case false: case 'fill': D3 = 0 break case 1: case true: case 'stroke': D3 = 1 break case 2: case 'fillThenStroke': D3 = 2 break case 3: case 'invisible': D3 = 3 break case 4: case 'fillAndAddForClipping': D3 = 4 break case 5: case 'strokeAndAddPathForClipping': D3 = 5 break case 6: case 'fillThenStrokeAndAddToPathForClipping': D3 = 6 break case 7: case 'addToPathForClipping': D3 = 7 } var z3 = void 0 !== T3.usedRenderingMode ? T3.usedRenderingMode : -1 ;-1 !== D3 ? (v5 += D3 + ' Tr\n') : -1 !== z3 && (v5 += '0 Tr\n'), -1 !== D3 && (T3.usedRenderingMode = D3), (u3 = i3.align || 'left') var H5, W3 = gt2 * w3, V3 = g3.internal.pageSize.getWidth(), G3 = Ft2[St] ;(h2 = i3.charSpace || _r), (l2 = i3.maxWidth || 0), (f2 = Object.assign({ autoencode: true, noBOM: true }, i3.flags)) var Y3 = [] if ('[object Array]' === Object.prototype.toString.call(e3)) { var J3 ;(s3 = A3(e3)), 'left' !== u3 && (H5 = s3.map(function (t3) { return ( (g3.getStringUnitWidth(t3, { font: G3, charSpace: h2, fontSize: gt2, doKerning: false, }) * gt2) / N3 ) })) var X3, K3 = 0 if ('right' === u3) { ;(r3 -= H5[0]), (e3 = []), (C2 = s3.length) for (var Z3 = 0; Z3 < C2; Z3++) 0 === Z3 ? ((X3 = br(r3)), (J3 = yr(n2))) : ((X3 = U2(K3 - H5[Z3])), (J3 = -W3)), e3.push([s3[Z3], X3, J3]), (K3 = H5[Z3]) } else if ('center' === u3) { ;(r3 -= H5[0] / 2), (e3 = []), (C2 = s3.length) for (var $3 = 0; $3 < C2; $3++) 0 === $3 ? ((X3 = br(r3)), (J3 = yr(n2))) : ((X3 = U2((K3 - H5[$3]) / 2)), (J3 = -W3)), e3.push([s3[$3], X3, J3]), (K3 = H5[$3]) } else if ('left' === u3) { ;(e3 = []), (C2 = s3.length) for (var Q3 = 0; Q3 < C2; Q3++) e3.push(s3[Q3]) } else { if ('justify' !== u3) throw new Error( 'Unrecognized alignment option, use "left", "center", "right" or "justify".' ) ;(e3 = []), (C2 = s3.length), (l2 = 0 !== l2 ? l2 : V3) for (var tt3 = 0; tt3 < C2; tt3++) (J3 = 0 === tt3 ? yr(n2) : -W3), (X3 = 0 === tt3 ? br(r3) : 0), tt3 < C2 - 1 ? Y3.push( O2(U2((l2 - H5[tt3]) / (s3[tt3].split(' ').length - 1))) ) : Y3.push(0), e3.push([s3[tt3], X3, J3]) } } var et3 = 'boolean' == typeof i3.R2L ? i3.R2L : bt2 true === et3 && (e3 = _3(e3, function (t3, e4, r4) { return [t3.split('').reverse().join(''), e4, r4] })), (o3 = { text: e3, x: r3, y: n2, options: i3, mutex: { pdfEscape: Ce, activeFontKey: St, fonts: Ft2, activeFontSize: gt2, }, }), Tt2.publish('postProcessText', o3), (e3 = o3.text), (y3 = o3.mutex.isHex || false) var rt3 = Ft2[St].encoding ;('WinAnsiEncoding' !== rt3 && 'StandardEncoding' !== rt3) || (e3 = _3(e3, function (t3, e4, r4) { return [L3(t3), e4, r4] })), (s3 = A3(e3)), (e3 = []) for ( var nt3, it3, at3, ot3 = 0, st3 = 1, ct3 = Array.isArray(s3[0]) ? st3 : ot3, ut3 = '', ht3 = function (t3, e4, r4) { var n3 = '' return ( r4 instanceof Vt2 ? ((r4 = 'number' == typeof i3.angle ? Gt2(r4, new Vt2(1, 0, 0, 1, t3, e4)) : Gt2(new Vt2(1, 0, 0, 1, t3, e4), r4)), S2 === x2.ADVANCED && (r4 = Gt2(new Vt2(1, 0, 0, -1, 0, 0), r4)), (n3 = r4.join(' ') + ' Tm\n')) : (n3 = O2(t3) + ' ' + O2(e4) + ' Td\n'), n3 ) }, ft3 = 0; ft3 < s3.length; ft3++ ) { switch (((ut3 = ''), ct3)) { case st3: ;(at3 = (y3 ? '<' : '(') + s3[ft3][0] + (y3 ? '>' : ')')), (nt3 = parseFloat(s3[ft3][1])), (it3 = parseFloat(s3[ft3][2])) break case ot3: ;(at3 = (y3 ? '<' : '(') + s3[ft3] + (y3 ? '>' : ')')), (nt3 = br(r3)), (it3 = yr(n2)) } void 0 !== Y3 && void 0 !== Y3[ft3] && (ut3 = Y3[ft3] + ' Tw\n'), 0 === ft3 ? e3.push(ut3 + ht3(nt3, it3, p3) + at3) : ct3 === ot3 ? e3.push(ut3 + at3) : ct3 === st3 && e3.push(ut3 + ht3(nt3, it3, p3) + at3) } ;(e3 = ct3 === ot3 ? e3.join(' Tj\nT* ') : e3.join(' Tj\n')), (e3 += ' Tj\n') var dt3 = 'BT\n/' return ( (dt3 += St + ' ' + gt2 + ' Tf\n'), (dt3 += O2(gt2 * w3) + ' TL\n'), (dt3 += xr + '\n'), (dt3 += v5), (dt3 += e3), lt2((dt3 += 'ET')), (b2[St] = true), g3 ) }) var $e = (y2.__private__.clip = y2.clip = function (t3) { return lt2('evenodd' === t3 ? 'W*' : 'W'), this }) ;(y2.clipEvenOdd = function () { return $e('evenodd') }), (y2.__private__.discardPath = y2.discardPath = function () { return lt2('n'), this }) var Qe = (y2.__private__.isValidStyle = function (t3) { var e3 = false return ( -1 !== [ void 0, null, 'S', 'D', 'F', 'DF', 'FD', 'f', 'f*', 'B', 'B*', 'n', ].indexOf(t3) && (e3 = true), e3 ) }) y2.__private__.setDefaultPathOperation = y2.setDefaultPathOperation = function (t3) { return Qe(t3) && (g2 = t3), this } var tr2 = (y2.__private__.getStyle = y2.getStyle = function (t3) { var e3 = g2 switch (t3) { case 'D': case 'S': e3 = 'S' break case 'F': e3 = 'f' break case 'FD': case 'DF': e3 = 'B' break case 'f': case 'f*': case 'B': case 'B*': e3 = t3 } return e3 }), er = (y2.close = function () { return lt2('h'), this }) ;(y2.stroke = function () { return lt2('S'), this }), (y2.fill = function (t3) { return rr2('f', t3), this }), (y2.fillEvenOdd = function (t3) { return rr2('f*', t3), this }), (y2.fillStroke = function (t3) { return rr2('B', t3), this }), (y2.fillStrokeEvenOdd = function (t3) { return rr2('B*', t3), this }) var rr2 = function (e3, r3) { 'object' === _typeof$3(r3) ? ar2(r3, e3) : lt2(e3) }, nr = function (t3) { null === t3 || (S2 === x2.ADVANCED && void 0 === t3) || ((t3 = tr2(t3)), lt2(t3)) } function ir(t3, e3, r3, n2, i3) { var a2 = new M( e3 || this.boundingBox, r3 || this.xStep, n2 || this.yStep, this.gState, i3 || this.matrix ) a2.stream = this.stream var o3 = t3 + '$$' + this.cloneIndex++ + '$$' return Jt2(o3, a2), a2 } var ar2 = function (t3, e3) { var r3 = Bt2[t3.key], n2 = Ot2[r3] if (n2 instanceof B) lt2('q'), lt2(or(e3)), n2.gState && y2.setGState(n2.gState), lt2(t3.matrix.toString() + ' cm'), lt2('/' + r3 + ' sh'), lt2('Q') else if (n2 instanceof M) { var i3 = new Vt2(1, 0, 0, -1, 0, Rr()) t3.matrix && ((i3 = i3.multiply(t3.matrix || Yt2)), (r3 = ir.call( n2, t3.key, t3.boundingBox, t3.xStep, t3.yStep, i3 ).id)), lt2('q'), lt2('/Pattern cs'), lt2('/' + r3 + ' scn'), n2.gState && y2.setGState(n2.gState), lt2(e3), lt2('Q') } }, or = function (t3) { switch (t3) { case 'f': case 'F': return 'W n' case 'f*': return 'W* n' case 'B': return 'W S' case 'B*': return 'W* S' case 'S': return 'W S' case 'n': return 'W n' } }, sr2 = (y2.moveTo = function (t3, e3) { return lt2(O2(U2(t3)) + ' ' + O2(H4(e3)) + ' m'), this }), cr = (y2.lineTo = function (t3, e3) { return lt2(O2(U2(t3)) + ' ' + O2(H4(e3)) + ' l'), this }), ur = (y2.curveTo = function (t3, e3, r3, n2, i3, a2) { return ( lt2( [ O2(U2(t3)), O2(H4(e3)), O2(U2(r3)), O2(H4(n2)), O2(U2(i3)), O2(H4(a2)), 'c', ].join(' ') ), this ) }) ;(y2.__private__.line = y2.line = function (t3, e3, r3, n2, i3) { if (isNaN(t3) || isNaN(e3) || isNaN(r3) || isNaN(n2) || !Qe(i3)) throw new Error('Invalid arguments passed to jsPDF.line') return S2 === x2.COMPAT ? this.lines([[r3 - t3, n2 - e3]], t3, e3, [1, 1], i3 || 'S') : this.lines([[r3 - t3, n2 - e3]], t3, e3, [1, 1]).stroke() }), (y2.__private__.lines = y2.lines = function (t3, e3, r3, n2, i3, a2) { var o3, s3, c3, u3, h2, l2, f2, d4, p3, g3, m3, v5 if ( ('number' == typeof t3 && ((v5 = r3), (r3 = e3), (e3 = t3), (t3 = v5)), (n2 = n2 || [1, 1]), (a2 = a2 || false), isNaN(e3) || isNaN(r3) || !Array.isArray(t3) || !Array.isArray(n2) || !Qe(i3) || 'boolean' != typeof a2) ) throw new Error('Invalid arguments passed to jsPDF.lines') for ( sr2(e3, r3), o3 = n2[0], s3 = n2[1], u3 = t3.length, g3 = e3, m3 = r3, c3 = 0; c3 < u3; c3++ ) 2 === (h2 = t3[c3]).length ? ((g3 = h2[0] * o3 + g3), (m3 = h2[1] * s3 + m3), cr(g3, m3)) : ((l2 = h2[0] * o3 + g3), (f2 = h2[1] * s3 + m3), (d4 = h2[2] * o3 + g3), (p3 = h2[3] * s3 + m3), (g3 = h2[4] * o3 + g3), (m3 = h2[5] * s3 + m3), ur(l2, f2, d4, p3, g3, m3)) return a2 && er(), nr(i3), this }), (y2.path = function (t3) { for (var e3 = 0; e3 < t3.length; e3++) { var r3 = t3[e3], n2 = r3.c switch (r3.op) { case 'm': sr2(n2[0], n2[1]) break case 'l': cr(n2[0], n2[1]) break case 'c': ur.apply(this, n2) break case 'h': er() } } return this }), (y2.__private__.rect = y2.rect = function (t3, e3, r3, n2, i3) { if (isNaN(t3) || isNaN(e3) || isNaN(r3) || isNaN(n2) || !Qe(i3)) throw new Error('Invalid arguments passed to jsPDF.rect') return ( S2 === x2.COMPAT && (n2 = -n2), lt2([O2(U2(t3)), O2(H4(e3)), O2(U2(r3)), O2(U2(n2)), 're'].join(' ')), nr(i3), this ) }), (y2.__private__.triangle = y2.triangle = function (t3, e3, r3, n2, i3, a2, o3) { if ( isNaN(t3) || isNaN(e3) || isNaN(r3) || isNaN(n2) || isNaN(i3) || isNaN(a2) || !Qe(o3) ) throw new Error('Invalid arguments passed to jsPDF.triangle') return ( this.lines( [ [r3 - t3, n2 - e3], [i3 - r3, a2 - n2], [t3 - i3, e3 - a2], ], t3, e3, [1, 1], o3, true ), this ) }), (y2.__private__.roundedRect = y2.roundedRect = function (t3, e3, r3, n2, i3, a2, o3) { if ( isNaN(t3) || isNaN(e3) || isNaN(r3) || isNaN(n2) || isNaN(i3) || isNaN(a2) || !Qe(o3) ) throw new Error('Invalid arguments passed to jsPDF.roundedRect') var s3 = (4 / 3) * (Math.SQRT2 - 1) return ( (i3 = Math.min(i3, 0.5 * r3)), (a2 = Math.min(a2, 0.5 * n2)), this.lines( [ [r3 - 2 * i3, 0], [i3 * s3, 0, i3, a2 - a2 * s3, i3, a2], [0, n2 - 2 * a2], [0, a2 * s3, -i3 * s3, a2, -i3, a2], [2 * i3 - r3, 0], [-i3 * s3, 0, -i3, -a2 * s3, -i3, -a2], [0, 2 * a2 - n2], [0, -a2 * s3, i3 * s3, -a2, i3, -a2], ], t3 + i3, e3, [1, 1], o3, true ), this ) }), (y2.__private__.ellipse = y2.ellipse = function (t3, e3, r3, n2, i3) { if (isNaN(t3) || isNaN(e3) || isNaN(r3) || isNaN(n2) || !Qe(i3)) throw new Error('Invalid arguments passed to jsPDF.ellipse') var a2 = (4 / 3) * (Math.SQRT2 - 1) * r3, o3 = (4 / 3) * (Math.SQRT2 - 1) * n2 return ( sr2(t3 + r3, e3), ur(t3 + r3, e3 - o3, t3 + a2, e3 - n2, t3, e3 - n2), ur(t3 - a2, e3 - n2, t3 - r3, e3 - o3, t3 - r3, e3), ur(t3 - r3, e3 + o3, t3 - a2, e3 + n2, t3, e3 + n2), ur(t3 + a2, e3 + n2, t3 + r3, e3 + o3, t3 + r3, e3), nr(i3), this ) }), (y2.__private__.circle = y2.circle = function (t3, e3, r3, n2) { if (isNaN(t3) || isNaN(e3) || isNaN(r3) || !Qe(n2)) throw new Error('Invalid arguments passed to jsPDF.circle') return this.ellipse(t3, e3, r3, r3, n2) }), (y2.setFont = function (t3, e3, r3) { return ( r3 && (e3 = k2(e3, r3)), (St = qe(t3, e3, { disableWarning: false })), this ) }) var hr2 = (y2.__private__.getFont = y2.getFont = function () { return Ft2[qe.apply(y2, arguments)] }) ;(y2.__private__.getFontList = y2.getFontList = function () { var t3, e3, r3 = {} for (t3 in Ct2) if (Ct2.hasOwnProperty(t3)) for (e3 in ((r3[t3] = []), Ct2[t3])) Ct2[t3].hasOwnProperty(e3) && r3[t3].push(e3) return r3 }), (y2.addFont = function (t3, e3, r3, n2, i3) { var a2 = [ 'StandardEncoding', 'MacRomanEncoding', 'Identity-H', 'WinAnsiEncoding', ] return ( arguments[3] && -1 !== a2.indexOf(arguments[3]) ? (i3 = arguments[3]) : arguments[3] && -1 == a2.indexOf(arguments[3]) && (r3 = k2(r3, n2)), (i3 = i3 || 'Identity-H'), Pe.call(this, t3, e3, r3, i3) ) }) var lr, fr2 = e2.lineWidth || 0.200025, dr = (y2.__private__.getLineWidth = y2.getLineWidth = function () { return fr2 }), pr = (y2.__private__.setLineWidth = y2.setLineWidth = function (t3) { return (fr2 = t3), lt2(O2(U2(t3)) + ' w'), this }) y2.__private__.setLineDash = E$1.API.setLineDash = E$1.API.setLineDashPattern = function (t3, e3) { if (((t3 = t3 || []), (e3 = e3 || 0), isNaN(e3) || !Array.isArray(t3))) throw new Error('Invalid arguments passed to jsPDF.setLineDash') return ( (t3 = t3 .map(function (t4) { return O2(U2(t4)) }) .join(' ')), (e3 = O2(U2(e3))), lt2('[' + t3 + '] ' + e3 + ' d'), this ) } var gr = (y2.__private__.getLineHeight = y2.getLineHeight = function () { return gt2 * lr }) y2.__private__.getLineHeight = y2.getLineHeight = function () { return gt2 * lr } var mr = (y2.__private__.setLineHeightFactor = y2.setLineHeightFactor = function (t3) { return 'number' == typeof (t3 = t3 || 1.15) && (lr = t3), this }), vr = (y2.__private__.getLineHeightFactor = y2.getLineHeightFactor = function () { return lr }) mr(e2.lineHeight) var br = (y2.__private__.getHorizontalCoordinate = function (t3) { return U2(t3) }), yr = (y2.__private__.getVerticalCoordinate = function (t3) { return S2 === x2.ADVANCED ? t3 : Rt2[$2].mediaBox.topRightY - Rt2[$2].mediaBox.bottomLeftY - U2(t3) }), wr = (y2.__private__.getHorizontalCoordinateString = y2.getHorizontalCoordinateString = function (t3) { return O2(br(t3)) }), Nr = (y2.__private__.getVerticalCoordinateString = y2.getVerticalCoordinateString = function (t3) { return O2(yr(t3)) }), Lr = e2.strokeColor || '0 G' ;(y2.__private__.getStrokeColor = y2.getDrawColor = function () { return ee2(Lr) }), (y2.__private__.setStrokeColor = y2.setDrawColor = function (t3, e3, r3, n2) { return ( (Lr = re2({ ch1: t3, ch2: e3, ch3: r3, ch4: n2, pdfColorType: 'draw', precision: 2, })), lt2(Lr), this ) }) var Ar = e2.fillColor || '0 g' ;(y2.__private__.getFillColor = y2.getFillColor = function () { return ee2(Ar) }), (y2.__private__.setFillColor = y2.setFillColor = function (t3, e3, r3, n2) { return ( (Ar = re2({ ch1: t3, ch2: e3, ch3: r3, ch4: n2, pdfColorType: 'fill', precision: 2, })), lt2(Ar), this ) }) var xr = e2.textColor || '0 g', Sr = (y2.__private__.getTextColor = y2.getTextColor = function () { return ee2(xr) }) y2.__private__.setTextColor = y2.setTextColor = function (t3, e3, r3, n2) { return ( (xr = re2({ ch1: t3, ch2: e3, ch3: r3, ch4: n2, pdfColorType: 'text', precision: 3, })), this ) } var _r = e2.charSpace, Pr = (y2.__private__.getCharSpace = y2.getCharSpace = function () { return parseFloat(_r || 0) }) y2.__private__.setCharSpace = y2.setCharSpace = function (t3) { if (isNaN(t3)) throw new Error('Invalid argument passed to jsPDF.setCharSpace') return (_r = t3), this } var kr = 0 ;(y2.CapJoinStyles = { 0: 0, butt: 0, but: 0, miter: 0, 1: 1, round: 1, rounded: 1, circle: 1, 2: 2, projecting: 2, project: 2, square: 2, bevel: 2, }), (y2.__private__.setLineCap = y2.setLineCap = function (t3) { var e3 = y2.CapJoinStyles[t3] if (void 0 === e3) throw new Error( "Line cap style of '" + t3 + "' is not recognized. See or extend .CapJoinStyles property for valid styles" ) return (kr = e3), lt2(e3 + ' J'), this }) var Ir = 0 ;(y2.__private__.setLineJoin = y2.setLineJoin = function (t3) { var e3 = y2.CapJoinStyles[t3] if (void 0 === e3) throw new Error( "Line join style of '" + t3 + "' is not recognized. See or extend .CapJoinStyles property for valid styles" ) return (Ir = e3), lt2(e3 + ' j'), this }), (y2.__private__.setLineMiterLimit = y2.__private__.setMiterLimit = y2.setLineMiterLimit = y2.setMiterLimit = function (t3) { if (((t3 = t3 || 0), isNaN(t3))) throw new Error( 'Invalid argument passed to jsPDF.setLineMiterLimit' ) return lt2(O2(U2(t3)) + ' M'), this }), (y2.GState = j), (y2.setGState = function (t3) { ;(t3 = 'string' == typeof t3 ? Mt2[Et2[t3]] : Fr(null, t3)).equals(qt2) || (lt2('/' + t3.id + ' gs'), (qt2 = t3)) }) var Fr = function (t3, e3) { if (!t3 || !Et2[t3]) { var r3 = false for (var n2 in Mt2) if (Mt2.hasOwnProperty(n2) && Mt2[n2].equals(e3)) { r3 = true break } if (r3) e3 = Mt2[n2] else { var i3 = 'GS' + (Object.keys(Mt2).length + 1).toString(10) ;(Mt2[i3] = e3), (e3.id = i3) } return t3 && (Et2[t3] = e3.id), Tt2.publish('addGState', e3), e3 } } ;(y2.addGState = function (t3, e3) { return Fr(t3, e3), this }), (y2.saveGraphicsState = function () { return lt2('q'), jt2.push({ key: St, size: gt2, color: xr }), this }), (y2.restoreGraphicsState = function () { lt2('Q') var t3 = jt2.pop() return (St = t3.key), (gt2 = t3.size), (xr = t3.color), (qt2 = null), this }), (y2.setCurrentTransformationMatrix = function (t3) { return lt2(t3.toString() + ' cm'), this }), (y2.comment = function (t3) { return lt2('#' + t3), this }) var Cr = function (t3, e3) { var r3 = t3 || 0 Object.defineProperty(this, 'x', { enumerable: true, get: function () { return r3 }, set: function (t4) { isNaN(t4) || (r3 = parseFloat(t4)) }, }) var n2 = e3 || 0 Object.defineProperty(this, 'y', { enumerable: true, get: function () { return n2 }, set: function (t4) { isNaN(t4) || (n2 = parseFloat(t4)) }, }) var i3 = 'pt' return ( Object.defineProperty(this, 'type', { enumerable: true, get: function () { return i3 }, set: function (t4) { i3 = t4.toString() }, }), this ) }, jr = function (t3, e3, r3, n2) { Cr.call(this, t3, e3), (this.type = 'rect') var i3 = r3 || 0 Object.defineProperty(this, 'w', { enumerable: true, get: function () { return i3 }, set: function (t4) { isNaN(t4) || (i3 = parseFloat(t4)) }, }) var a2 = n2 || 0 return ( Object.defineProperty(this, 'h', { enumerable: true, get: function () { return a2 }, set: function (t4) { isNaN(t4) || (a2 = parseFloat(t4)) }, }), this ) }, Or = function () { ;(this.page = Dt2), (this.currentPage = $2), (this.pages = ot2.slice(0)), (this.pagesContext = Rt2.slice(0)), (this.x = Pt2), (this.y = kt2), (this.matrix = It2), (this.width = qr($2)), (this.height = Rr($2)), (this.outputDestination = ct2), (this.id = ''), (this.objectNumber = -1) } Or.prototype.restore = function () { ;(Dt2 = this.page), ($2 = this.currentPage), (Rt2 = this.pagesContext), (ot2 = this.pages), (Pt2 = this.x), (kt2 = this.y), (It2 = this.matrix), Dr($2, this.width), Tr($2, this.height), (ct2 = this.outputDestination) } var Br = function (t3, e3, r3, n2, i3) { Wt2.push(new Or()), (Dt2 = $2 = 0), (ot2 = []), (Pt2 = t3), (kt2 = e3), (It2 = i3), je([r3, n2]) }, Mr = function (t3) { if (Ht2[t3]) Wt2.pop().restore() else { var e3 = new Or(), r3 = 'Xo' + (Object.keys(zt2).length + 1).toString(10) ;(e3.id = r3), (Ht2[t3] = r3), (zt2[r3] = e3), Tt2.publish('addFormObject', e3), Wt2.pop().restore() } } for (var Er in ((y2.beginFormObject = function (t3, e3, r3, n2, i3) { return Br(t3, e3, r3, n2, i3), this }), (y2.endFormObject = function (t3) { return Mr(t3), this }), (y2.doFormObject = function (t3, e3) { var r3 = zt2[Ht2[t3]] return ( lt2('q'), lt2(e3.toString() + ' cm'), lt2('/' + r3.id + ' Do'), lt2('Q'), this ) }), (y2.getFormObject = function (t3) { var e3 = zt2[Ht2[t3]] return { x: e3.x, y: e3.y, width: e3.width, height: e3.height, matrix: e3.matrix, } }), (y2.save = function (t3, e3) { return ( (t3 = t3 || 'generated.pdf'), ((e3 = e3 || {}).returnPromise = e3.returnPromise || false), false === e3.returnPromise ? (l$1(We(He()), t3), 'function' == typeof l$1.unload && n$1.setTimeout && setTimeout(l$1.unload, 911), this) : new Promise(function (e4, r3) { try { var i3 = l$1(We(He()), t3) 'function' == typeof l$1.unload && n$1.setTimeout && setTimeout(l$1.unload, 911), e4(i3) } catch (t4) { r3(t4.message) } }) ) }), E$1.API)) E$1.API.hasOwnProperty(Er) && ('events' === Er && E$1.API.events.length ? (function (t3, e3) { var r3, n2, i3 for (i3 = e3.length - 1; -1 !== i3; i3--) (r3 = e3[i3][0]), (n2 = e3[i3][1]), t3.subscribe.apply( t3, [r3].concat('function' == typeof n2 ? [n2] : n2) ) })(Tt2, E$1.API.events) : (y2[Er] = E$1.API[Er])) var qr = (y2.getPageWidth = function (t3) { return ( (Rt2[(t3 = t3 || $2)].mediaBox.topRightX - Rt2[t3].mediaBox.bottomLeftX) / _t2 ) }), Dr = (y2.setPageWidth = function (t3, e3) { Rt2[t3].mediaBox.topRightX = e3 * _t2 + Rt2[t3].mediaBox.bottomLeftX }), Rr = (y2.getPageHeight = function (t3) { return ( (Rt2[(t3 = t3 || $2)].mediaBox.topRightY - Rt2[t3].mediaBox.bottomLeftY) / _t2 ) }), Tr = (y2.setPageHeight = function (t3, e3) { Rt2[t3].mediaBox.topRightY = e3 * _t2 + Rt2[t3].mediaBox.bottomLeftY }) return ( (y2.internal = { pdfEscape: Ce, getStyle: tr2, getFont: hr2, getFontSize: vt2, getCharSpace: Pr, getTextColor: Sr, getLineHeight: gr, getLineHeightFactor: vr, getLineWidth: dr, write: ft2, getHorizontalCoordinate: br, getVerticalCoordinate: yr, getCoordinateString: wr, getVerticalCoordinateString: Nr, collections: {}, newObject: Xt2, newAdditionalObject: $t2, newObjectDeferred: Kt2, newObjectDeferredBegin: Zt2, getFilters: ne2, putStream: ie2, events: Tt2, scaleFactor: _t2, pageSize: { getWidth: function () { return qr($2) }, setWidth: function (t3) { Dr($2, t3) }, getHeight: function () { return Rr($2) }, setHeight: function (t3) { Tr($2, t3) }, }, encryptionOptions: m2, encryption: Ye, getEncryptor: Je, output: Ve, getNumberOfPages: Ee, pages: ot2, out: lt2, f2: R2, f3: T2, getPageInfo: Xe, getPageInfoByObjId: Ke, getCurrentPageInfo: Ze, getPDFVersion: N2, Point: Cr, Rectangle: jr, Matrix: Vt2, hasHotfix: Ge, }), Object.defineProperty(y2.internal.pageSize, 'width', { get: function () { return qr($2) }, set: function (t3) { Dr($2, t3) }, enumerable: true, configurable: true, }), Object.defineProperty(y2.internal.pageSize, 'height', { get: function () { return Rr($2) }, set: function (t3) { Tr($2, t3) }, enumerable: true, configurable: true, }), ke.call(y2, pt3), (St = 'F1'), Oe(s2, i2), Tt2.publish('initialized'), y2 ) } ;(I.prototype.lsbFirstWord = function (t3) { return String.fromCharCode( (t3 >> 0) & 255, (t3 >> 8) & 255, (t3 >> 16) & 255, (t3 >> 24) & 255 ) }), (I.prototype.toHexString = function (t3) { return t3 .split('') .map(function (t4) { return ('0' + (255 & t4.charCodeAt(0)).toString(16)).slice(-2) }) .join('') }), (I.prototype.hexToBytes = function (t3) { for (var e2 = [], r2 = 0; r2 < t3.length; r2 += 2) e2.push(String.fromCharCode(parseInt(t3.substr(r2, 2), 16))) return e2.join('') }), (I.prototype.processOwnerPassword = function (t3, e2) { return P(x(e2).substr(0, 5), t3) }), (I.prototype.encryptor = function (t3, e2) { var r2 = x( this.encryptionKey + String.fromCharCode( 255 & t3, (t3 >> 8) & 255, (t3 >> 16) & 255, 255 & e2, (e2 >> 8) & 255 ) ).substr(0, 10) return function (t4) { return P(r2, t4) } }), (j.prototype.equals = function (e2) { var r2, n2 = 'id,objectNumber,equals' if (!e2 || _typeof$3(e2) !== _typeof$3(this)) return false var i2 = 0 for (r2 in this) if (!(n2.indexOf(r2) >= 0)) { if (this.hasOwnProperty(r2) && !e2.hasOwnProperty(r2)) return false if (this[r2] !== e2[r2]) return false i2++ } for (r2 in e2) e2.hasOwnProperty(r2) && n2.indexOf(r2) < 0 && i2-- return 0 === i2 }), (E$1.API = { events: [] }), (E$1.version = '2.5.1') var q = E$1.API, D = 1, R = function (t3) { return t3.replace(/\\/g, '\\\\').replace(/\(/g, '\\(').replace(/\)/g, '\\)') }, T$2 = function (t3) { return t3.replace(/\\\\/g, '\\').replace(/\\\(/g, '(').replace(/\\\)/g, ')') }, U$1 = function (t3) { return t3.toFixed(2) }, z$2 = function (t3) { return t3.toFixed(5) } q.__acroform__ = {} var H = function (t3, e2) { ;(t3.prototype = Object.create(e2.prototype)), (t3.prototype.constructor = t3) }, W = function (t3) { return t3 * D }, V$1 = function (t3) { var e2 = new ut(), r2 = At.internal.getHeight(t3) || 0, n2 = At.internal.getWidth(t3) || 0 return (e2.BBox = [0, 0, Number(U$1(n2)), Number(U$1(r2))]), e2 }, G = (q.__acroform__.setBit = function (t3, e2) { if (((t3 = t3 || 0), (e2 = e2 || 0), isNaN(t3) || isNaN(e2))) throw new Error( 'Invalid arguments passed to jsPDF.API.__acroform__.setBit' ) return (t3 |= 1 << e2) }), Y = (q.__acroform__.clearBit = function (t3, e2) { if (((t3 = t3 || 0), (e2 = e2 || 0), isNaN(t3) || isNaN(e2))) throw new Error( 'Invalid arguments passed to jsPDF.API.__acroform__.clearBit' ) return (t3 &= ~(1 << e2)) }), J = (q.__acroform__.getBit = function (t3, e2) { if (isNaN(t3) || isNaN(e2)) throw new Error( 'Invalid arguments passed to jsPDF.API.__acroform__.getBit' ) return 0 == (t3 & (1 << e2)) ? 0 : 1 }), X = (q.__acroform__.getBitForPdf = function (t3, e2) { if (isNaN(t3) || isNaN(e2)) throw new Error( 'Invalid arguments passed to jsPDF.API.__acroform__.getBitForPdf' ) return J(t3, e2 - 1) }), K = (q.__acroform__.setBitForPdf = function (t3, e2) { if (isNaN(t3) || isNaN(e2)) throw new Error( 'Invalid arguments passed to jsPDF.API.__acroform__.setBitForPdf' ) return G(t3, e2 - 1) }), Z$1 = (q.__acroform__.clearBitForPdf = function (t3, e2) { if (isNaN(t3) || isNaN(e2)) throw new Error( 'Invalid arguments passed to jsPDF.API.__acroform__.clearBitForPdf' ) return Y(t3, e2 - 1) }), $$g = (q.__acroform__.calculateCoordinates = function (t3, e2) { var r2 = e2.internal.getHorizontalCoordinate, n2 = e2.internal.getVerticalCoordinate, i2 = t3[0], a2 = t3[1], o2 = t3[2], s2 = t3[3], c2 = {} return ( (c2.lowerLeft_X = r2(i2) || 0), (c2.lowerLeft_Y = n2(a2 + s2) || 0), (c2.upperRight_X = r2(i2 + o2) || 0), (c2.upperRight_Y = n2(a2) || 0), [ Number(U$1(c2.lowerLeft_X)), Number(U$1(c2.lowerLeft_Y)), Number(U$1(c2.upperRight_X)), Number(U$1(c2.upperRight_Y)), ] ) }), Q = function (t3) { if (t3.appearanceStreamContent) return t3.appearanceStreamContent if (t3.V || t3.DV) { var e2 = [], r2 = t3._V || t3.DV, n2 = tt(t3, r2), i2 = t3.scope.internal.getFont(t3.fontName, t3.fontStyle).id e2.push('/Tx BMC'), e2.push('q'), e2.push('BT'), e2.push(t3.scope.__private__.encodeColorString(t3.color)), e2.push('/' + i2 + ' ' + U$1(n2.fontSize) + ' Tf'), e2.push('1 0 0 1 0 0 Tm'), e2.push(n2.text), e2.push('ET'), e2.push('Q'), e2.push('EMC') var a2 = V$1(t3) return (a2.scope = t3.scope), (a2.stream = e2.join('\n')), a2 } }, tt = function (t3, e2) { var r2 = 0 === t3.fontSize ? t3.maxFontSize : t3.fontSize, n2 = { text: '', fontSize: '' }, i2 = (e2 = ')' == (e2 = '(' == e2.substr(0, 1) ? e2.substr(1) : e2).substr(e2.length - 1) ? e2.substr(0, e2.length - 1) : e2).split(' ') i2 = t3.multiline ? i2.map(function (t4) { return t4.split('\n') }) : i2.map(function (t4) { return [t4] }) var a2 = r2, o2 = At.internal.getHeight(t3) || 0 o2 = o2 < 0 ? -o2 : o2 var s2 = At.internal.getWidth(t3) || 0 s2 = s2 < 0 ? -s2 : s2 var c2 = function (e3, r3, n3) { if (e3 + 1 < i2.length) { var a3 = r3 + ' ' + i2[e3 + 1][0] return et(a3, t3, n3).width <= s2 - 4 } return false } a2++ t: for (; a2 > 0; ) { ;(e2 = ''), a2-- var u2, h2, l2 = et('3', t3, a2).height, f2 = t3.multiline ? o2 - a2 : (o2 - l2) / 2, d3 = (f2 += 2), p2 = 0, g2 = 0, m2 = 0 if (a2 <= 0) { ;(e2 = '(...) Tj\n'), (e2 += '% Width of Text: ' + et(e2, t3, (a2 = 12)).width + ', FieldWidth:' + s2 + '\n') break } for (var v4 = '', b2 = 0, y2 = 0; y2 < i2.length; y2++) if (i2.hasOwnProperty(y2)) { var w2 = false if (1 !== i2[y2].length && m2 !== i2[y2].length - 1) { if ((l2 + 2) * (b2 + 2) + 2 > o2) continue t ;(v4 += i2[y2][m2]), (w2 = true), (g2 = y2), y2-- } else { v4 = ' ' == (v4 += i2[y2][m2] + ' ').substr(v4.length - 1) ? v4.substr(0, v4.length - 1) : v4 var N2 = parseInt(y2), L2 = c2(N2, v4, a2), A2 = y2 >= i2.length - 1 if (L2 && !A2) { ;(v4 += ' '), (m2 = 0) continue } if (L2 || A2) { if (A2) g2 = N2 else if (t3.multiline && (l2 + 2) * (b2 + 2) + 2 > o2) continue t } else { if (!t3.multiline) continue t if ((l2 + 2) * (b2 + 2) + 2 > o2) continue t g2 = N2 } } for (var x2 = '', S2 = p2; S2 <= g2; S2++) { var _2 = i2[S2] if (t3.multiline) { if (S2 === g2) { ;(x2 += _2[m2] + ' '), (m2 = (m2 + 1) % _2.length) continue } if (S2 === p2) { x2 += _2[_2.length - 1] + ' ' continue } } x2 += _2[0] + ' ' } switch ( ((x2 = ' ' == x2.substr(x2.length - 1) ? x2.substr(0, x2.length - 1) : x2), (h2 = et(x2, t3, a2).width), t3.textAlign) ) { case 'right': u2 = s2 - h2 - 2 break case 'center': u2 = (s2 - h2) / 2 break case 'left': default: u2 = 2 } ;(e2 += U$1(u2) + ' ' + U$1(d3) + ' Td\n'), (e2 += '(' + R(x2) + ') Tj\n'), (e2 += -U$1(u2) + ' 0 Td\n'), (d3 = -(a2 + 2)), (h2 = 0), (p2 = w2 ? g2 : g2 + 1), b2++, (v4 = '') } break } return (n2.text = e2), (n2.fontSize = a2), n2 }, et = function (t3, e2, r2) { var n2 = e2.scope.internal.getFont(e2.fontName, e2.fontStyle), i2 = e2.scope.getStringUnitWidth(t3, { font: n2, fontSize: parseFloat(r2), charSpace: 0, }) * parseFloat(r2) return { height: e2.scope.getStringUnitWidth('3', { font: n2, fontSize: parseFloat(r2), charSpace: 0, }) * parseFloat(r2) * 1.5, width: i2, } }, rt$1 = { fields: [], xForms: [], acroFormDictionaryRoot: null, printedOut: false, internal: null, isInitialized: false, }, nt = function (t3, e2) { var r2 = { type: 'reference', object: t3 } void 0 === e2.internal .getPageInfo(t3.page) .pageContext.annotations.find(function (t4) { return t4.type === r2.type && t4.object === r2.object }) && e2.internal.getPageInfo(t3.page).pageContext.annotations.push(r2) }, it = function (e2, r2) { for (var n2 in e2) if (e2.hasOwnProperty(n2)) { var i2 = n2, a2 = e2[n2] r2.internal.newObjectDeferredBegin(a2.objId, true), 'object' === _typeof$3(a2) && 'function' == typeof a2.putStream && a2.putStream(), delete e2[i2] } }, at = function (e2, r2) { if ( ((r2.scope = e2), void 0 !== e2.internal && (void 0 === e2.internal.acroformPlugin || false === e2.internal.acroformPlugin.isInitialized)) ) { if ( ((lt$1.FieldNum = 0), (e2.internal.acroformPlugin = JSON.parse(JSON.stringify(rt$1))), e2.internal.acroformPlugin.acroFormDictionaryRoot) ) throw new Error('Exception while creating AcroformDictionary') ;(D = e2.internal.scaleFactor), (e2.internal.acroformPlugin.acroFormDictionaryRoot = new ht()), (e2.internal.acroformPlugin.acroFormDictionaryRoot.scope = e2), (e2.internal.acroformPlugin.acroFormDictionaryRoot._eventID = e2.internal.events.subscribe('postPutResources', function () { !(function (t3) { t3.internal.events.unsubscribe( t3.internal.acroformPlugin.acroFormDictionaryRoot._eventID ), delete t3.internal.acroformPlugin.acroFormDictionaryRoot ._eventID, (t3.internal.acroformPlugin.printedOut = true) })(e2) })), e2.internal.events.subscribe('buildDocument', function () { !(function (t3) { t3.internal.acroformPlugin.acroFormDictionaryRoot.objId = void 0 var e3 = t3.internal.acroformPlugin.acroFormDictionaryRoot.Fields for (var r3 in e3) if (e3.hasOwnProperty(r3)) { var n2 = e3[r3] ;(n2.objId = void 0), n2.hasAnnotation && nt(n2, t3) } })(e2) }), e2.internal.events.subscribe('putCatalog', function () { !(function (t3) { if (void 0 === t3.internal.acroformPlugin.acroFormDictionaryRoot) throw new Error('putCatalogCallback: Root missing.') t3.internal.write( '/AcroForm ' + t3.internal.acroformPlugin.acroFormDictionaryRoot.objId + ' 0 R' ) })(e2) }), e2.internal.events.subscribe('postPutPages', function (r3) { !(function (e3, r4) { var n2 = !e3 for (var i2 in (e3 || (r4.internal.newObjectDeferredBegin( r4.internal.acroformPlugin.acroFormDictionaryRoot.objId, true ), r4.internal.acroformPlugin.acroFormDictionaryRoot.putStream()), (e3 = e3 || r4.internal.acroformPlugin.acroFormDictionaryRoot.Kids))) if (e3.hasOwnProperty(i2)) { var a2 = e3[i2], o2 = [], s2 = a2.Rect if ( (a2.Rect && (a2.Rect = $$g(a2.Rect, r4)), r4.internal.newObjectDeferredBegin(a2.objId, true), (a2.DA = At.createDefaultAppearanceStream(a2)), 'object' === _typeof$3(a2) && 'function' == typeof a2.getKeyValueListForStream && (o2 = a2.getKeyValueListForStream()), (a2.Rect = s2), a2.hasAppearanceStream && !a2.appearanceStreamContent) ) { var c2 = Q(a2) o2.push({ key: 'AP', value: '<>' }), r4.internal.acroformPlugin.xForms.push(c2) } if (a2.appearanceStreamContent) { var u2 = '' for (var h2 in a2.appearanceStreamContent) if (a2.appearanceStreamContent.hasOwnProperty(h2)) { var l2 = a2.appearanceStreamContent[h2] if ( ((u2 += '/' + h2 + ' '), (u2 += '<<'), Object.keys(l2).length >= 1 || Array.isArray(l2)) ) { for (var i2 in l2) if (l2.hasOwnProperty(i2)) { var f2 = l2[i2] 'function' == typeof f2 && (f2 = f2.call(r4, a2)), (u2 += '/' + i2 + ' ' + f2 + ' '), r4.internal.acroformPlugin.xForms.indexOf(f2) >= 0 || r4.internal.acroformPlugin.xForms.push(f2) } } else 'function' == typeof (f2 = l2) && (f2 = f2.call(r4, a2)), (u2 += '/' + i2 + ' ' + f2), r4.internal.acroformPlugin.xForms.indexOf(f2) >= 0 || r4.internal.acroformPlugin.xForms.push(f2) u2 += '>>' } o2.push({ key: 'AP', value: '<<\n' + u2 + '>>' }) } r4.internal.putStream({ additionalKeyValues: o2, objectId: a2.objId, }), r4.internal.out('endobj') } n2 && it(r4.internal.acroformPlugin.xForms, r4) })(r3, e2) }), (e2.internal.acroformPlugin.isInitialized = true) } }, ot = (q.__acroform__.arrayToPdfArray = function (e2, r2, n2) { var i2 = function (t3) { return t3 } if (Array.isArray(e2)) { for (var a2 = '[', o2 = 0; o2 < e2.length; o2++) switch ((0 !== o2 && (a2 += ' '), _typeof$3(e2[o2]))) { case 'boolean': case 'number': case 'object': a2 += e2[o2].toString() break case 'string': '/' !== e2[o2].substr(0, 1) ? (void 0 !== r2 && n2 && (i2 = n2.internal.getEncryptor(r2)), (a2 += '(' + R(i2(e2[o2].toString())) + ')')) : (a2 += e2[o2].toString()) } return (a2 += ']') } throw new Error( 'Invalid argument passed to jsPDF.__acroform__.arrayToPdfArray' ) }) var st = function (t3, e2, r2) { var n2 = function (t4) { return t4 } return ( void 0 !== e2 && r2 && (n2 = r2.internal.getEncryptor(e2)), (t3 = t3 || '').toString(), (t3 = '(' + R(n2(t3)) + ')') ) }, ct = function () { ;(this._objId = void 0), (this._scope = void 0), Object.defineProperty(this, 'objId', { get: function () { if (void 0 === this._objId) { if (void 0 === this.scope) return this._objId = this.scope.internal.newObjectDeferred() } return this._objId }, set: function (t3) { this._objId = t3 }, }), Object.defineProperty(this, 'scope', { value: this._scope, writable: true, }) } ;(ct.prototype.toString = function () { return this.objId + ' 0 R' }), (ct.prototype.putStream = function () { var t3 = this.getKeyValueListForStream() this.scope.internal.putStream({ data: this.stream, additionalKeyValues: t3, objectId: this.objId, }), this.scope.internal.out('endobj') }), (ct.prototype.getKeyValueListForStream = function () { var t3 = [], e2 = Object.getOwnPropertyNames(this).filter(function (t4) { return ( 'content' != t4 && 'appearanceStreamContent' != t4 && 'scope' != t4 && 'objId' != t4 && '_' != t4.substring(0, 1) ) }) for (var r2 in e2) if ( false === Object.getOwnPropertyDescriptor(this, e2[r2]).configurable ) { var n2 = e2[r2], i2 = this[n2] i2 && (Array.isArray(i2) ? t3.push({ key: n2, value: ot(i2, this.objId, this.scope) }) : i2 instanceof ct ? ((i2.scope = this.scope), t3.push({ key: n2, value: i2.objId + ' 0 R' })) : 'function' != typeof i2 && t3.push({ key: n2, value: i2 })) } return t3 }) var ut = function () { ct.call(this), Object.defineProperty(this, 'Type', { value: '/XObject', configurable: false, writable: true, }), Object.defineProperty(this, 'Subtype', { value: '/Form', configurable: false, writable: true, }), Object.defineProperty(this, 'FormType', { value: 1, configurable: false, writable: true, }) var t3, e2 = [] Object.defineProperty(this, 'BBox', { configurable: false, get: function () { return e2 }, set: function (t4) { e2 = t4 }, }), Object.defineProperty(this, 'Resources', { value: '2 0 R', configurable: false, writable: true, }), Object.defineProperty(this, 'stream', { enumerable: false, configurable: true, set: function (e3) { t3 = e3.trim() }, get: function () { return t3 || null }, }) } H(ut, ct) var ht = function () { ct.call(this) var t3, e2 = [] Object.defineProperty(this, 'Kids', { enumerable: false, configurable: true, get: function () { return e2.length > 0 ? e2 : void 0 }, }), Object.defineProperty(this, 'Fields', { enumerable: false, configurable: false, get: function () { return e2 }, }), Object.defineProperty(this, 'DA', { enumerable: false, configurable: false, get: function () { if (t3) { var e3 = function (t4) { return t4 } return ( this.scope && (e3 = this.scope.internal.getEncryptor(this.objId)), '(' + R(e3(t3)) + ')' ) } }, set: function (e3) { t3 = e3 }, }) } H(ht, ct) var lt$1 = function t2() { ct.call(this) var e2 = 4 Object.defineProperty(this, 'F', { enumerable: false, configurable: false, get: function () { return e2 }, set: function (t3) { if (isNaN(t3)) throw new Error('Invalid value "' + t3 + '" for attribute F supplied.') e2 = t3 }, }), Object.defineProperty(this, 'showWhenPrinted', { enumerable: true, configurable: true, get: function () { return Boolean(X(e2, 3)) }, set: function (t3) { true === Boolean(t3) ? (this.F = K(e2, 3)) : (this.F = Z$1(e2, 3)) }, }) var r2 = 0 Object.defineProperty(this, 'Ff', { enumerable: false, configurable: false, get: function () { return r2 }, set: function (t3) { if (isNaN(t3)) throw new Error('Invalid value "' + t3 + '" for attribute Ff supplied.') r2 = t3 }, }) var n2 = [] Object.defineProperty(this, 'Rect', { enumerable: false, configurable: false, get: function () { if (0 !== n2.length) return n2 }, set: function (t3) { n2 = void 0 !== t3 ? t3 : [] }, }), Object.defineProperty(this, 'x', { enumerable: true, configurable: true, get: function () { return !n2 || isNaN(n2[0]) ? 0 : n2[0] }, set: function (t3) { n2[0] = t3 }, }), Object.defineProperty(this, 'y', { enumerable: true, configurable: true, get: function () { return !n2 || isNaN(n2[1]) ? 0 : n2[1] }, set: function (t3) { n2[1] = t3 }, }), Object.defineProperty(this, 'width', { enumerable: true, configurable: true, get: function () { return !n2 || isNaN(n2[2]) ? 0 : n2[2] }, set: function (t3) { n2[2] = t3 }, }), Object.defineProperty(this, 'height', { enumerable: true, configurable: true, get: function () { return !n2 || isNaN(n2[3]) ? 0 : n2[3] }, set: function (t3) { n2[3] = t3 }, }) var i2 = '' Object.defineProperty(this, 'FT', { enumerable: true, configurable: false, get: function () { return i2 }, set: function (t3) { switch (t3) { case '/Btn': case '/Tx': case '/Ch': case '/Sig': i2 = t3 break default: throw new Error( 'Invalid value "' + t3 + '" for attribute FT supplied.' ) } }, }) var a2 = null Object.defineProperty(this, 'T', { enumerable: true, configurable: false, get: function () { if (!a2 || a2.length < 1) { if (this instanceof yt) return a2 = 'FieldObject' + t2.FieldNum++ } var e3 = function (t3) { return t3 } return ( this.scope && (e3 = this.scope.internal.getEncryptor(this.objId)), '(' + R(e3(a2)) + ')' ) }, set: function (t3) { a2 = t3.toString() }, }), Object.defineProperty(this, 'fieldName', { configurable: true, enumerable: true, get: function () { return a2 }, set: function (t3) { a2 = t3 }, }) var o2 = 'helvetica' Object.defineProperty(this, 'fontName', { enumerable: true, configurable: true, get: function () { return o2 }, set: function (t3) { o2 = t3 }, }) var s2 = 'normal' Object.defineProperty(this, 'fontStyle', { enumerable: true, configurable: true, get: function () { return s2 }, set: function (t3) { s2 = t3 }, }) var c2 = 0 Object.defineProperty(this, 'fontSize', { enumerable: true, configurable: true, get: function () { return c2 }, set: function (t3) { c2 = t3 }, }) var u2 = void 0 Object.defineProperty(this, 'maxFontSize', { enumerable: true, configurable: true, get: function () { return void 0 === u2 ? 50 / D : u2 }, set: function (t3) { u2 = t3 }, }) var h2 = 'black' Object.defineProperty(this, 'color', { enumerable: true, configurable: true, get: function () { return h2 }, set: function (t3) { h2 = t3 }, }) var l2 = '/F1 0 Tf 0 g' Object.defineProperty(this, 'DA', { enumerable: true, configurable: false, get: function () { if (!(!l2 || this instanceof yt || this instanceof Nt)) return st(l2, this.objId, this.scope) }, set: function (t3) { ;(t3 = t3.toString()), (l2 = t3) }, }) var f2 = null Object.defineProperty(this, 'DV', { enumerable: false, configurable: false, get: function () { if (f2) return this instanceof mt == false ? st(f2, this.objId, this.scope) : f2 }, set: function (t3) { ;(t3 = t3.toString()), (f2 = this instanceof mt == false ? '(' === t3.substr(0, 1) ? T$2(t3.substr(1, t3.length - 2)) : T$2(t3) : t3) }, }), Object.defineProperty(this, 'defaultValue', { enumerable: true, configurable: true, get: function () { return this instanceof mt == true ? T$2(f2.substr(1, f2.length - 1)) : f2 }, set: function (t3) { ;(t3 = t3.toString()), (f2 = this instanceof mt == true ? '/' + t3 : t3) }, }) var d3 = null Object.defineProperty(this, '_V', { enumerable: false, configurable: false, get: function () { if (d3) return d3 }, set: function (t3) { this.V = t3 }, }), Object.defineProperty(this, 'V', { enumerable: false, configurable: false, get: function () { if (d3) return this instanceof mt == false ? st(d3, this.objId, this.scope) : d3 }, set: function (t3) { ;(t3 = t3.toString()), (d3 = this instanceof mt == false ? '(' === t3.substr(0, 1) ? T$2(t3.substr(1, t3.length - 2)) : T$2(t3) : t3) }, }), Object.defineProperty(this, 'value', { enumerable: true, configurable: true, get: function () { return this instanceof mt == true ? T$2(d3.substr(1, d3.length - 1)) : d3 }, set: function (t3) { ;(t3 = t3.toString()), (d3 = this instanceof mt == true ? '/' + t3 : t3) }, }), Object.defineProperty(this, 'hasAnnotation', { enumerable: true, configurable: true, get: function () { return this.Rect }, }), Object.defineProperty(this, 'Type', { enumerable: true, configurable: false, get: function () { return this.hasAnnotation ? '/Annot' : null }, }), Object.defineProperty(this, 'Subtype', { enumerable: true, configurable: false, get: function () { return this.hasAnnotation ? '/Widget' : null }, }) var p2, g2 = false Object.defineProperty(this, 'hasAppearanceStream', { enumerable: true, configurable: true, get: function () { return g2 }, set: function (t3) { ;(t3 = Boolean(t3)), (g2 = t3) }, }), Object.defineProperty(this, 'page', { enumerable: true, configurable: true, get: function () { if (p2) return p2 }, set: function (t3) { p2 = t3 }, }), Object.defineProperty(this, 'readOnly', { enumerable: true, configurable: true, get: function () { return Boolean(X(this.Ff, 1)) }, set: function (t3) { true === Boolean(t3) ? (this.Ff = K(this.Ff, 1)) : (this.Ff = Z$1(this.Ff, 1)) }, }), Object.defineProperty(this, 'required', { enumerable: true, configurable: true, get: function () { return Boolean(X(this.Ff, 2)) }, set: function (t3) { true === Boolean(t3) ? (this.Ff = K(this.Ff, 2)) : (this.Ff = Z$1(this.Ff, 2)) }, }), Object.defineProperty(this, 'noExport', { enumerable: true, configurable: true, get: function () { return Boolean(X(this.Ff, 3)) }, set: function (t3) { true === Boolean(t3) ? (this.Ff = K(this.Ff, 3)) : (this.Ff = Z$1(this.Ff, 3)) }, }) var m2 = null Object.defineProperty(this, 'Q', { enumerable: true, configurable: false, get: function () { if (null !== m2) return m2 }, set: function (t3) { if (-1 === [0, 1, 2].indexOf(t3)) throw new Error('Invalid value "' + t3 + '" for attribute Q supplied.') m2 = t3 }, }), Object.defineProperty(this, 'textAlign', { get: function () { var t3 switch (m2) { case 0: default: t3 = 'left' break case 1: t3 = 'center' break case 2: t3 = 'right' } return t3 }, configurable: true, enumerable: true, set: function (t3) { switch (t3) { case 'right': case 2: m2 = 2 break case 'center': case 1: m2 = 1 break case 'left': case 0: default: m2 = 0 } }, }) } H(lt$1, ct) var ft = function () { lt$1.call(this), (this.FT = '/Ch'), (this.V = '()'), (this.fontName = 'zapfdingbats') var t3 = 0 Object.defineProperty(this, 'TI', { enumerable: true, configurable: false, get: function () { return t3 }, set: function (e3) { t3 = e3 }, }), Object.defineProperty(this, 'topIndex', { enumerable: true, configurable: true, get: function () { return t3 }, set: function (e3) { t3 = e3 }, }) var e2 = [] Object.defineProperty(this, 'Opt', { enumerable: true, configurable: false, get: function () { return ot(e2, this.objId, this.scope) }, set: function (t4) { var r2, n2 ;(n2 = []), 'string' == typeof (r2 = t4) && (n2 = (function (t5, e3, r3) { r3 || (r3 = 1) for (var n3, i2 = []; (n3 = e3.exec(t5)); ) i2.push(n3[r3]) return i2 })(r2, /\((.*?)\)/g)), (e2 = n2) }, }), (this.getOptions = function () { return e2 }), (this.setOptions = function (t4) { ;(e2 = t4), this.sort && e2.sort() }), (this.addOption = function (t4) { ;(t4 = (t4 = t4 || '').toString()), e2.push(t4), this.sort && e2.sort() }), (this.removeOption = function (t4, r2) { for ( r2 = r2 || false, t4 = (t4 = t4 || '').toString(); -1 !== e2.indexOf(t4) && (e2.splice(e2.indexOf(t4), 1), false !== r2); ); }), Object.defineProperty(this, 'combo', { enumerable: true, configurable: true, get: function () { return Boolean(X(this.Ff, 18)) }, set: function (t4) { true === Boolean(t4) ? (this.Ff = K(this.Ff, 18)) : (this.Ff = Z$1(this.Ff, 18)) }, }), Object.defineProperty(this, 'edit', { enumerable: true, configurable: true, get: function () { return Boolean(X(this.Ff, 19)) }, set: function (t4) { true === this.combo && (true === Boolean(t4) ? (this.Ff = K(this.Ff, 19)) : (this.Ff = Z$1(this.Ff, 19))) }, }), Object.defineProperty(this, 'sort', { enumerable: true, configurable: true, get: function () { return Boolean(X(this.Ff, 20)) }, set: function (t4) { true === Boolean(t4) ? ((this.Ff = K(this.Ff, 20)), e2.sort()) : (this.Ff = Z$1(this.Ff, 20)) }, }), Object.defineProperty(this, 'multiSelect', { enumerable: true, configurable: true, get: function () { return Boolean(X(this.Ff, 22)) }, set: function (t4) { true === Boolean(t4) ? (this.Ff = K(this.Ff, 22)) : (this.Ff = Z$1(this.Ff, 22)) }, }), Object.defineProperty(this, 'doNotSpellCheck', { enumerable: true, configurable: true, get: function () { return Boolean(X(this.Ff, 23)) }, set: function (t4) { true === Boolean(t4) ? (this.Ff = K(this.Ff, 23)) : (this.Ff = Z$1(this.Ff, 23)) }, }), Object.defineProperty(this, 'commitOnSelChange', { enumerable: true, configurable: true, get: function () { return Boolean(X(this.Ff, 27)) }, set: function (t4) { true === Boolean(t4) ? (this.Ff = K(this.Ff, 27)) : (this.Ff = Z$1(this.Ff, 27)) }, }), (this.hasAppearanceStream = false) } H(ft, lt$1) var dt = function () { ft.call(this), (this.fontName = 'helvetica'), (this.combo = false) } H(dt, ft) var pt = function () { dt.call(this), (this.combo = true) } H(pt, dt) var gt = function () { pt.call(this), (this.edit = true) } H(gt, pt) var mt = function () { lt$1.call(this), (this.FT = '/Btn'), Object.defineProperty(this, 'noToggleToOff', { enumerable: true, configurable: true, get: function () { return Boolean(X(this.Ff, 15)) }, set: function (t3) { true === Boolean(t3) ? (this.Ff = K(this.Ff, 15)) : (this.Ff = Z$1(this.Ff, 15)) }, }), Object.defineProperty(this, 'radio', { enumerable: true, configurable: true, get: function () { return Boolean(X(this.Ff, 16)) }, set: function (t3) { true === Boolean(t3) ? (this.Ff = K(this.Ff, 16)) : (this.Ff = Z$1(this.Ff, 16)) }, }), Object.defineProperty(this, 'pushButton', { enumerable: true, configurable: true, get: function () { return Boolean(X(this.Ff, 17)) }, set: function (t3) { true === Boolean(t3) ? (this.Ff = K(this.Ff, 17)) : (this.Ff = Z$1(this.Ff, 17)) }, }), Object.defineProperty(this, 'radioIsUnison', { enumerable: true, configurable: true, get: function () { return Boolean(X(this.Ff, 26)) }, set: function (t3) { true === Boolean(t3) ? (this.Ff = K(this.Ff, 26)) : (this.Ff = Z$1(this.Ff, 26)) }, }) var e2, r2 = {} Object.defineProperty(this, 'MK', { enumerable: false, configurable: false, get: function () { var t3 = function (t4) { return t4 } if ( (this.scope && (t3 = this.scope.internal.getEncryptor(this.objId)), 0 !== Object.keys(r2).length) ) { var e3, n2 = [] for (e3 in (n2.push('<<'), r2)) n2.push('/' + e3 + ' (' + R(t3(r2[e3])) + ')') return n2.push('>>'), n2.join('\n') } }, set: function (e3) { 'object' === _typeof$3(e3) && (r2 = e3) }, }), Object.defineProperty(this, 'caption', { enumerable: true, configurable: true, get: function () { return r2.CA || '' }, set: function (t3) { 'string' == typeof t3 && (r2.CA = t3) }, }), Object.defineProperty(this, 'AS', { enumerable: false, configurable: false, get: function () { return e2 }, set: function (t3) { e2 = t3 }, }), Object.defineProperty(this, 'appearanceState', { enumerable: true, configurable: true, get: function () { return e2.substr(1, e2.length - 1) }, set: function (t3) { e2 = '/' + t3 }, }) } H(mt, lt$1) var vt = function () { mt.call(this), (this.pushButton = true) } H(vt, mt) var bt = function () { mt.call(this), (this.radio = true), (this.pushButton = false) var t3 = [] Object.defineProperty(this, 'Kids', { enumerable: true, configurable: false, get: function () { return t3 }, set: function (e2) { t3 = void 0 !== e2 ? e2 : [] }, }) } H(bt, mt) var yt = function () { var e2, r2 lt$1.call(this), Object.defineProperty(this, 'Parent', { enumerable: false, configurable: false, get: function () { return e2 }, set: function (t3) { e2 = t3 }, }), Object.defineProperty(this, 'optionName', { enumerable: false, configurable: true, get: function () { return r2 }, set: function (t3) { r2 = t3 }, }) var n2, i2 = {} Object.defineProperty(this, 'MK', { enumerable: false, configurable: false, get: function () { var t3 = function (t4) { return t4 } this.scope && (t3 = this.scope.internal.getEncryptor(this.objId)) var e3, r3 = [] for (e3 in (r3.push('<<'), i2)) r3.push('/' + e3 + ' (' + R(t3(i2[e3])) + ')') return r3.push('>>'), r3.join('\n') }, set: function (e3) { 'object' === _typeof$3(e3) && (i2 = e3) }, }), Object.defineProperty(this, 'caption', { enumerable: true, configurable: true, get: function () { return i2.CA || '' }, set: function (t3) { 'string' == typeof t3 && (i2.CA = t3) }, }), Object.defineProperty(this, 'AS', { enumerable: false, configurable: false, get: function () { return n2 }, set: function (t3) { n2 = t3 }, }), Object.defineProperty(this, 'appearanceState', { enumerable: true, configurable: true, get: function () { return n2.substr(1, n2.length - 1) }, set: function (t3) { n2 = '/' + t3 }, }), (this.caption = 'l'), (this.appearanceState = 'Off'), (this._AppearanceType = At.RadioButton.Circle), (this.appearanceStreamContent = this._AppearanceType.createAppearanceStream( this.optionName )) } H(yt, lt$1), (bt.prototype.setAppearance = function (t3) { if (!('createAppearanceStream' in t3) || !('getCA' in t3)) throw new Error( "Couldn't assign Appearance to RadioButton. Appearance was Invalid!" ) for (var e2 in this.Kids) if (this.Kids.hasOwnProperty(e2)) { var r2 = this.Kids[e2] ;(r2.appearanceStreamContent = t3.createAppearanceStream( r2.optionName )), (r2.caption = t3.getCA()) } }), (bt.prototype.createOption = function (t3) { var e2 = new yt() return ( (e2.Parent = this), (e2.optionName = t3), this.Kids.push(e2), xt.call(this.scope, e2), e2 ) }) var wt = function () { mt.call(this), (this.fontName = 'zapfdingbats'), (this.caption = '3'), (this.appearanceState = 'On'), (this.value = 'On'), (this.textAlign = 'center'), (this.appearanceStreamContent = At.CheckBox.createAppearanceStream()) } H(wt, mt) var Nt = function () { lt$1.call(this), (this.FT = '/Tx'), Object.defineProperty(this, 'multiline', { enumerable: true, configurable: true, get: function () { return Boolean(X(this.Ff, 13)) }, set: function (t4) { true === Boolean(t4) ? (this.Ff = K(this.Ff, 13)) : (this.Ff = Z$1(this.Ff, 13)) }, }), Object.defineProperty(this, 'fileSelect', { enumerable: true, configurable: true, get: function () { return Boolean(X(this.Ff, 21)) }, set: function (t4) { true === Boolean(t4) ? (this.Ff = K(this.Ff, 21)) : (this.Ff = Z$1(this.Ff, 21)) }, }), Object.defineProperty(this, 'doNotSpellCheck', { enumerable: true, configurable: true, get: function () { return Boolean(X(this.Ff, 23)) }, set: function (t4) { true === Boolean(t4) ? (this.Ff = K(this.Ff, 23)) : (this.Ff = Z$1(this.Ff, 23)) }, }), Object.defineProperty(this, 'doNotScroll', { enumerable: true, configurable: true, get: function () { return Boolean(X(this.Ff, 24)) }, set: function (t4) { true === Boolean(t4) ? (this.Ff = K(this.Ff, 24)) : (this.Ff = Z$1(this.Ff, 24)) }, }), Object.defineProperty(this, 'comb', { enumerable: true, configurable: true, get: function () { return Boolean(X(this.Ff, 25)) }, set: function (t4) { true === Boolean(t4) ? (this.Ff = K(this.Ff, 25)) : (this.Ff = Z$1(this.Ff, 25)) }, }), Object.defineProperty(this, 'richText', { enumerable: true, configurable: true, get: function () { return Boolean(X(this.Ff, 26)) }, set: function (t4) { true === Boolean(t4) ? (this.Ff = K(this.Ff, 26)) : (this.Ff = Z$1(this.Ff, 26)) }, }) var t3 = null Object.defineProperty(this, 'MaxLen', { enumerable: true, configurable: false, get: function () { return t3 }, set: function (e2) { t3 = e2 }, }), Object.defineProperty(this, 'maxLength', { enumerable: true, configurable: true, get: function () { return t3 }, set: function (e2) { Number.isInteger(e2) && (t3 = e2) }, }), Object.defineProperty(this, 'hasAppearanceStream', { enumerable: true, configurable: true, get: function () { return this.V || this.DV }, }) } H(Nt, lt$1) var Lt = function () { Nt.call(this), Object.defineProperty(this, 'password', { enumerable: true, configurable: true, get: function () { return Boolean(X(this.Ff, 14)) }, set: function (t3) { true === Boolean(t3) ? (this.Ff = K(this.Ff, 14)) : (this.Ff = Z$1(this.Ff, 14)) }, }), (this.password = true) } H(Lt, Nt) var At = { CheckBox: { createAppearanceStream: function () { return { N: { On: At.CheckBox.YesNormal }, D: { On: At.CheckBox.YesPushDown, Off: At.CheckBox.OffPushDown }, } }, YesPushDown: function (t3) { var e2 = V$1(t3) e2.scope = t3.scope var r2 = [], n2 = t3.scope.internal.getFont(t3.fontName, t3.fontStyle).id, i2 = t3.scope.__private__.encodeColorString(t3.color), a2 = tt(t3, t3.caption) return ( r2.push('0.749023 g'), r2.push( '0 0 ' + U$1(At.internal.getWidth(t3)) + ' ' + U$1(At.internal.getHeight(t3)) + ' re' ), r2.push('f'), r2.push('BMC'), r2.push('q'), r2.push('0 0 1 rg'), r2.push('/' + n2 + ' ' + U$1(a2.fontSize) + ' Tf ' + i2), r2.push('BT'), r2.push(a2.text), r2.push('ET'), r2.push('Q'), r2.push('EMC'), (e2.stream = r2.join('\n')), e2 ) }, YesNormal: function (t3) { var e2 = V$1(t3) e2.scope = t3.scope var r2 = t3.scope.internal.getFont(t3.fontName, t3.fontStyle).id, n2 = t3.scope.__private__.encodeColorString(t3.color), i2 = [], a2 = At.internal.getHeight(t3), o2 = At.internal.getWidth(t3), s2 = tt(t3, t3.caption) return ( i2.push('1 g'), i2.push('0 0 ' + U$1(o2) + ' ' + U$1(a2) + ' re'), i2.push('f'), i2.push('q'), i2.push('0 0 1 rg'), i2.push('0 0 ' + U$1(o2 - 1) + ' ' + U$1(a2 - 1) + ' re'), i2.push('W'), i2.push('n'), i2.push('0 g'), i2.push('BT'), i2.push('/' + r2 + ' ' + U$1(s2.fontSize) + ' Tf ' + n2), i2.push(s2.text), i2.push('ET'), i2.push('Q'), (e2.stream = i2.join('\n')), e2 ) }, OffPushDown: function (t3) { var e2 = V$1(t3) e2.scope = t3.scope var r2 = [] return ( r2.push('0.749023 g'), r2.push( '0 0 ' + U$1(At.internal.getWidth(t3)) + ' ' + U$1(At.internal.getHeight(t3)) + ' re' ), r2.push('f'), (e2.stream = r2.join('\n')), e2 ) }, }, RadioButton: { Circle: { createAppearanceStream: function (t3) { var e2 = { D: { Off: At.RadioButton.Circle.OffPushDown }, N: {} } return ( (e2.N[t3] = At.RadioButton.Circle.YesNormal), (e2.D[t3] = At.RadioButton.Circle.YesPushDown), e2 ) }, getCA: function () { return 'l' }, YesNormal: function (t3) { var e2 = V$1(t3) e2.scope = t3.scope var r2 = [], n2 = At.internal.getWidth(t3) <= At.internal.getHeight(t3) ? At.internal.getWidth(t3) / 4 : At.internal.getHeight(t3) / 4 n2 = Number((0.9 * n2).toFixed(5)) var i2 = At.internal.Bezier_C, a2 = Number((n2 * i2).toFixed(5)) return ( r2.push('q'), r2.push( '1 0 0 1 ' + z$2(At.internal.getWidth(t3) / 2) + ' ' + z$2(At.internal.getHeight(t3) / 2) + ' cm' ), r2.push(n2 + ' 0 m'), r2.push(n2 + ' ' + a2 + ' ' + a2 + ' ' + n2 + ' 0 ' + n2 + ' c'), r2.push( '-' + a2 + ' ' + n2 + ' -' + n2 + ' ' + a2 + ' -' + n2 + ' 0 c' ), r2.push( '-' + n2 + ' -' + a2 + ' -' + a2 + ' -' + n2 + ' 0 -' + n2 + ' c' ), r2.push(a2 + ' -' + n2 + ' ' + n2 + ' -' + a2 + ' ' + n2 + ' 0 c'), r2.push('f'), r2.push('Q'), (e2.stream = r2.join('\n')), e2 ) }, YesPushDown: function (t3) { var e2 = V$1(t3) e2.scope = t3.scope var r2 = [], n2 = At.internal.getWidth(t3) <= At.internal.getHeight(t3) ? At.internal.getWidth(t3) / 4 : At.internal.getHeight(t3) / 4 n2 = Number((0.9 * n2).toFixed(5)) var i2 = Number((2 * n2).toFixed(5)), a2 = Number((i2 * At.internal.Bezier_C).toFixed(5)), o2 = Number((n2 * At.internal.Bezier_C).toFixed(5)) return ( r2.push('0.749023 g'), r2.push('q'), r2.push( '1 0 0 1 ' + z$2(At.internal.getWidth(t3) / 2) + ' ' + z$2(At.internal.getHeight(t3) / 2) + ' cm' ), r2.push(i2 + ' 0 m'), r2.push(i2 + ' ' + a2 + ' ' + a2 + ' ' + i2 + ' 0 ' + i2 + ' c'), r2.push( '-' + a2 + ' ' + i2 + ' -' + i2 + ' ' + a2 + ' -' + i2 + ' 0 c' ), r2.push( '-' + i2 + ' -' + a2 + ' -' + a2 + ' -' + i2 + ' 0 -' + i2 + ' c' ), r2.push(a2 + ' -' + i2 + ' ' + i2 + ' -' + a2 + ' ' + i2 + ' 0 c'), r2.push('f'), r2.push('Q'), r2.push('0 g'), r2.push('q'), r2.push( '1 0 0 1 ' + z$2(At.internal.getWidth(t3) / 2) + ' ' + z$2(At.internal.getHeight(t3) / 2) + ' cm' ), r2.push(n2 + ' 0 m'), r2.push(n2 + ' ' + o2 + ' ' + o2 + ' ' + n2 + ' 0 ' + n2 + ' c'), r2.push( '-' + o2 + ' ' + n2 + ' -' + n2 + ' ' + o2 + ' -' + n2 + ' 0 c' ), r2.push( '-' + n2 + ' -' + o2 + ' -' + o2 + ' -' + n2 + ' 0 -' + n2 + ' c' ), r2.push(o2 + ' -' + n2 + ' ' + n2 + ' -' + o2 + ' ' + n2 + ' 0 c'), r2.push('f'), r2.push('Q'), (e2.stream = r2.join('\n')), e2 ) }, OffPushDown: function (t3) { var e2 = V$1(t3) e2.scope = t3.scope var r2 = [], n2 = At.internal.getWidth(t3) <= At.internal.getHeight(t3) ? At.internal.getWidth(t3) / 4 : At.internal.getHeight(t3) / 4 n2 = Number((0.9 * n2).toFixed(5)) var i2 = Number((2 * n2).toFixed(5)), a2 = Number((i2 * At.internal.Bezier_C).toFixed(5)) return ( r2.push('0.749023 g'), r2.push('q'), r2.push( '1 0 0 1 ' + z$2(At.internal.getWidth(t3) / 2) + ' ' + z$2(At.internal.getHeight(t3) / 2) + ' cm' ), r2.push(i2 + ' 0 m'), r2.push(i2 + ' ' + a2 + ' ' + a2 + ' ' + i2 + ' 0 ' + i2 + ' c'), r2.push( '-' + a2 + ' ' + i2 + ' -' + i2 + ' ' + a2 + ' -' + i2 + ' 0 c' ), r2.push( '-' + i2 + ' -' + a2 + ' -' + a2 + ' -' + i2 + ' 0 -' + i2 + ' c' ), r2.push(a2 + ' -' + i2 + ' ' + i2 + ' -' + a2 + ' ' + i2 + ' 0 c'), r2.push('f'), r2.push('Q'), (e2.stream = r2.join('\n')), e2 ) }, }, Cross: { createAppearanceStream: function (t3) { var e2 = { D: { Off: At.RadioButton.Cross.OffPushDown }, N: {} } return ( (e2.N[t3] = At.RadioButton.Cross.YesNormal), (e2.D[t3] = At.RadioButton.Cross.YesPushDown), e2 ) }, getCA: function () { return '8' }, YesNormal: function (t3) { var e2 = V$1(t3) e2.scope = t3.scope var r2 = [], n2 = At.internal.calculateCross(t3) return ( r2.push('q'), r2.push( '1 1 ' + U$1(At.internal.getWidth(t3) - 2) + ' ' + U$1(At.internal.getHeight(t3) - 2) + ' re' ), r2.push('W'), r2.push('n'), r2.push(U$1(n2.x1.x) + ' ' + U$1(n2.x1.y) + ' m'), r2.push(U$1(n2.x2.x) + ' ' + U$1(n2.x2.y) + ' l'), r2.push(U$1(n2.x4.x) + ' ' + U$1(n2.x4.y) + ' m'), r2.push(U$1(n2.x3.x) + ' ' + U$1(n2.x3.y) + ' l'), r2.push('s'), r2.push('Q'), (e2.stream = r2.join('\n')), e2 ) }, YesPushDown: function (t3) { var e2 = V$1(t3) e2.scope = t3.scope var r2 = At.internal.calculateCross(t3), n2 = [] return ( n2.push('0.749023 g'), n2.push( '0 0 ' + U$1(At.internal.getWidth(t3)) + ' ' + U$1(At.internal.getHeight(t3)) + ' re' ), n2.push('f'), n2.push('q'), n2.push( '1 1 ' + U$1(At.internal.getWidth(t3) - 2) + ' ' + U$1(At.internal.getHeight(t3) - 2) + ' re' ), n2.push('W'), n2.push('n'), n2.push(U$1(r2.x1.x) + ' ' + U$1(r2.x1.y) + ' m'), n2.push(U$1(r2.x2.x) + ' ' + U$1(r2.x2.y) + ' l'), n2.push(U$1(r2.x4.x) + ' ' + U$1(r2.x4.y) + ' m'), n2.push(U$1(r2.x3.x) + ' ' + U$1(r2.x3.y) + ' l'), n2.push('s'), n2.push('Q'), (e2.stream = n2.join('\n')), e2 ) }, OffPushDown: function (t3) { var e2 = V$1(t3) e2.scope = t3.scope var r2 = [] return ( r2.push('0.749023 g'), r2.push( '0 0 ' + U$1(At.internal.getWidth(t3)) + ' ' + U$1(At.internal.getHeight(t3)) + ' re' ), r2.push('f'), (e2.stream = r2.join('\n')), e2 ) }, }, }, createDefaultAppearanceStream: function (t3) { var e2 = t3.scope.internal.getFont(t3.fontName, t3.fontStyle).id, r2 = t3.scope.__private__.encodeColorString(t3.color) return '/' + e2 + ' ' + t3.fontSize + ' Tf ' + r2 }, } ;(At.internal = { Bezier_C: 0.551915024494, calculateCross: function (t3) { var e2 = At.internal.getWidth(t3), r2 = At.internal.getHeight(t3), n2 = Math.min(e2, r2) return { x1: { x: (e2 - n2) / 2, y: (r2 - n2) / 2 + n2 }, x2: { x: (e2 - n2) / 2 + n2, y: (r2 - n2) / 2 }, x3: { x: (e2 - n2) / 2, y: (r2 - n2) / 2 }, x4: { x: (e2 - n2) / 2 + n2, y: (r2 - n2) / 2 + n2 }, } }, }), (At.internal.getWidth = function (e2) { var r2 = 0 return 'object' === _typeof$3(e2) && (r2 = W(e2.Rect[2])), r2 }), (At.internal.getHeight = function (e2) { var r2 = 0 return 'object' === _typeof$3(e2) && (r2 = W(e2.Rect[3])), r2 }) var xt = (q.addField = function (t3) { if ((at(this, t3), !(t3 instanceof lt$1))) throw new Error('Invalid argument passed to jsPDF.addField.') var e2 return ( (e2 = t3).scope.internal.acroformPlugin.printedOut && ((e2.scope.internal.acroformPlugin.printedOut = false), (e2.scope.internal.acroformPlugin.acroFormDictionaryRoot = null)), e2.scope.internal.acroformPlugin.acroFormDictionaryRoot.Fields.push(e2), (t3.page = t3.scope.internal.getCurrentPageInfo().pageNumber), this ) }) ;(q.AcroFormChoiceField = ft), (q.AcroFormListBox = dt), (q.AcroFormComboBox = pt), (q.AcroFormEditBox = gt), (q.AcroFormButton = mt), (q.AcroFormPushButton = vt), (q.AcroFormRadioButton = bt), (q.AcroFormCheckBox = wt), (q.AcroFormTextField = Nt), (q.AcroFormPasswordField = Lt), (q.AcroFormAppearance = At), (q.AcroForm = { ChoiceField: ft, ListBox: dt, ComboBox: pt, EditBox: gt, Button: mt, PushButton: vt, RadioButton: bt, CheckBox: wt, TextField: Nt, PasswordField: Lt, Appearance: At, }), (E$1.AcroForm = { ChoiceField: ft, ListBox: dt, ComboBox: pt, EditBox: gt, Button: mt, PushButton: vt, RadioButton: bt, CheckBox: wt, TextField: Nt, PasswordField: Lt, Appearance: At, }) E$1.AcroForm function _t$2(t3) { return t3.reduce(function (t4, e2, r2) { return (t4[e2] = r2), t4 }, {}) } !(function (e2) { e2.__addimage__ = {} var r2 = 'UNKNOWN', n2 = { PNG: [[137, 80, 78, 71]], TIFF: [ [77, 77, 0, 42], [73, 73, 42, 0], ], JPEG: [ [255, 216, 255, 224, void 0, void 0, 74, 70, 73, 70, 0], [255, 216, 255, 225, void 0, void 0, 69, 120, 105, 102, 0, 0], [255, 216, 255, 219], [255, 216, 255, 238], ], JPEG2000: [[0, 0, 0, 12, 106, 80, 32, 32]], GIF87a: [[71, 73, 70, 56, 55, 97]], GIF89a: [[71, 73, 70, 56, 57, 97]], WEBP: [[82, 73, 70, 70, void 0, void 0, void 0, void 0, 87, 69, 66, 80]], BMP: [ [66, 77], [66, 65], [67, 73], [67, 80], [73, 67], [80, 84], ], }, i2 = (e2.__addimage__.getImageFileTypeByImageData = function (t3, e3) { var i3, a3, o3, s3, c3, u2 = r2 if ( 'RGBA' === (e3 = e3 || r2) || (void 0 !== t3.data && t3.data instanceof Uint8ClampedArray && 'height' in t3 && 'width' in t3) ) return 'RGBA' if (x2(t3)) for (c3 in n2) for (o3 = n2[c3], i3 = 0; i3 < o3.length; i3 += 1) { for (s3 = true, a3 = 0; a3 < o3[i3].length; a3 += 1) if (void 0 !== o3[i3][a3] && o3[i3][a3] !== t3[a3]) { s3 = false break } if (true === s3) { u2 = c3 break } } else for (c3 in n2) for (o3 = n2[c3], i3 = 0; i3 < o3.length; i3 += 1) { for (s3 = true, a3 = 0; a3 < o3[i3].length; a3 += 1) if (void 0 !== o3[i3][a3] && o3[i3][a3] !== t3.charCodeAt(a3)) { s3 = false break } if (true === s3) { u2 = c3 break } } return u2 === r2 && e3 !== r2 && (u2 = e3), u2 }), a2 = function t3(e3) { for ( var r3 = this.internal.write, n3 = this.internal.putStream, i3 = (0, this.internal.getFilters)(); -1 !== i3.indexOf('FlateEncode'); ) i3.splice(i3.indexOf('FlateEncode'), 1) e3.objectId = this.internal.newObject() var a3 = [] if ( (a3.push({ key: 'Type', value: '/XObject' }), a3.push({ key: 'Subtype', value: '/Image' }), a3.push({ key: 'Width', value: e3.width }), a3.push({ key: 'Height', value: e3.height }), e3.colorSpace === b2.INDEXED ? a3.push({ key: 'ColorSpace', value: '[/Indexed /DeviceRGB ' + (e3.palette.length / 3 - 1) + ' ' + ('sMask' in e3 && void 0 !== e3.sMask ? e3.objectId + 2 : e3.objectId + 1) + ' 0 R]', }) : (a3.push({ key: 'ColorSpace', value: '/' + e3.colorSpace }), e3.colorSpace === b2.DEVICE_CMYK && a3.push({ key: 'Decode', value: '[1 0 1 0 1 0 1 0]' })), a3.push({ key: 'BitsPerComponent', value: e3.bitsPerComponent }), 'decodeParameters' in e3 && void 0 !== e3.decodeParameters && a3.push({ key: 'DecodeParms', value: '<<' + e3.decodeParameters + '>>', }), 'transparency' in e3 && Array.isArray(e3.transparency)) ) { for (var o3 = '', s3 = 0, c3 = e3.transparency.length; s3 < c3; s3++) o3 += e3.transparency[s3] + ' ' + e3.transparency[s3] + ' ' a3.push({ key: 'Mask', value: '[' + o3 + ']' }) } void 0 !== e3.sMask && a3.push({ key: 'SMask', value: e3.objectId + 1 + ' 0 R' }) var u2 = void 0 !== e3.filter ? ['/' + e3.filter] : void 0 if ( (n3({ data: e3.data, additionalKeyValues: a3, alreadyAppliedFilters: u2, objectId: e3.objectId, }), r3('endobj'), 'sMask' in e3 && void 0 !== e3.sMask) ) { var h3 = '/Predictor ' + e3.predictor + ' /Colors 1 /BitsPerComponent ' + e3.bitsPerComponent + ' /Columns ' + e3.width, l3 = { width: e3.width, height: e3.height, colorSpace: 'DeviceGray', bitsPerComponent: e3.bitsPerComponent, decodeParameters: h3, data: e3.sMask, } 'filter' in e3 && (l3.filter = e3.filter), t3.call(this, l3) } if (e3.colorSpace === b2.INDEXED) { var f3 = this.internal.newObject() n3({ data: _2(new Uint8Array(e3.palette)), objectId: f3 }), r3('endobj') } }, o2 = function () { var t3 = this.internal.collections.addImage_images for (var e3 in t3) a2.call(this, t3[e3]) }, s2 = function () { var t3, e3 = this.internal.collections.addImage_images, r3 = this.internal.write for (var n3 in e3) r3('/I' + (t3 = e3[n3]).index, t3.objectId, '0', 'R') }, c2 = function () { this.internal.collections.addImage_images || ((this.internal.collections.addImage_images = {}), this.internal.events.subscribe('putResources', o2), this.internal.events.subscribe('putXobjectDict', s2)) }, h2 = function () { var t3 = this.internal.collections.addImage_images return c2.call(this), t3 }, l2 = function () { return Object.keys(this.internal.collections.addImage_images).length }, f2 = function (t3) { return 'function' == typeof e2['process' + t3.toUpperCase()] }, d3 = function (e3) { return 'object' === _typeof$3(e3) && 1 === e3.nodeType }, p2 = function (t3, r3) { if ('IMG' === t3.nodeName && t3.hasAttribute('src')) { var n3 = '' + t3.getAttribute('src') if (0 === n3.indexOf('data:image/')) return u$2(unescape(n3).split('base64,').pop()) var i3 = e2.loadFile(n3, true) if (void 0 !== i3) return i3 } if ('CANVAS' === t3.nodeName) { if (0 === t3.width || 0 === t3.height) throw new Error( 'Given canvas must have data. Canvas width: ' + t3.width + ', height: ' + t3.height ) var a3 switch (r3) { case 'PNG': a3 = 'image/png' break case 'WEBP': a3 = 'image/webp' break case 'JPEG': case 'JPG': default: a3 = 'image/jpeg' } return u$2(t3.toDataURL(a3, 1).split('base64,').pop()) } }, g2 = function (t3) { var e3 = this.internal.collections.addImage_images if (e3) { for (var r3 in e3) if (t3 === e3[r3].alias) return e3[r3] } }, m2 = function (t3, e3, r3) { return ( t3 || e3 || ((t3 = -96), (e3 = -96)), t3 < 0 && (t3 = (-1 * r3.width * 72) / t3 / this.internal.scaleFactor), e3 < 0 && (e3 = (-1 * r3.height * 72) / e3 / this.internal.scaleFactor), 0 === t3 && (t3 = (e3 * r3.width) / r3.height), 0 === e3 && (e3 = (t3 * r3.height) / r3.width), [t3, e3] ) }, v4 = function (t3, e3, r3, n3, i3, a3) { var o3 = m2.call(this, r3, n3, i3), s3 = this.internal.getCoordinateString, c3 = this.internal.getVerticalCoordinateString, u2 = h2.call(this) if (((r3 = o3[0]), (n3 = o3[1]), (u2[i3.index] = i3), a3)) { a3 *= Math.PI / 180 var l3 = Math.cos(a3), f3 = Math.sin(a3), d4 = function (t4) { return t4.toFixed(4) }, p3 = [d4(l3), d4(f3), d4(-1 * f3), d4(l3), 0, 0, 'cm'] } this.internal.write('q'), a3 ? (this.internal.write( [1, '0', '0', 1, s3(t3), c3(e3 + n3), 'cm'].join(' ') ), this.internal.write(p3.join(' ')), this.internal.write( [s3(r3), '0', '0', s3(n3), '0', '0', 'cm'].join(' ') )) : this.internal.write( [s3(r3), '0', '0', s3(n3), s3(t3), c3(e3 + n3), 'cm'].join(' ') ), this.isAdvancedAPI() && this.internal.write([1, 0, 0, -1, 0, 0, 'cm'].join(' ')), this.internal.write('/I' + i3.index + ' Do'), this.internal.write('Q') }, b2 = (e2.color_spaces = { DEVICE_RGB: 'DeviceRGB', DEVICE_GRAY: 'DeviceGray', DEVICE_CMYK: 'DeviceCMYK', CAL_GREY: 'CalGray', CAL_RGB: 'CalRGB', LAB: 'Lab', ICC_BASED: 'ICCBased', INDEXED: 'Indexed', PATTERN: 'Pattern', SEPARATION: 'Separation', DEVICE_N: 'DeviceN', }) e2.decode = { DCT_DECODE: 'DCTDecode', FLATE_DECODE: 'FlateDecode', LZW_DECODE: 'LZWDecode', JPX_DECODE: 'JPXDecode', JBIG2_DECODE: 'JBIG2Decode', ASCII85_DECODE: 'ASCII85Decode', ASCII_HEX_DECODE: 'ASCIIHexDecode', RUN_LENGTH_DECODE: 'RunLengthDecode', CCITT_FAX_DECODE: 'CCITTFaxDecode', } var y2 = (e2.image_compression = { NONE: 'NONE', FAST: 'FAST', MEDIUM: 'MEDIUM', SLOW: 'SLOW', }), w2 = (e2.__addimage__.sHashCode = function (t3) { var e3, r3, n3 = 0 if ('string' == typeof t3) for (r3 = t3.length, e3 = 0; e3 < r3; e3++) (n3 = (n3 << 5) - n3 + t3.charCodeAt(e3)), (n3 |= 0) else if (x2(t3)) for (r3 = t3.byteLength / 2, e3 = 0; e3 < r3; e3++) (n3 = (n3 << 5) - n3 + t3[e3]), (n3 |= 0) return n3 }), N2 = (e2.__addimage__.validateStringAsBase64 = function (t3) { ;(t3 = t3 || '').toString().trim() var e3 = true return ( 0 === t3.length && (e3 = false), t3.length % 4 != 0 && (e3 = false), false === /^[A-Za-z0-9+/]+$/.test(t3.substr(0, t3.length - 2)) && (e3 = false), false === /^[A-Za-z0-9/][A-Za-z0-9+/]|[A-Za-z0-9+/]=|==$/.test(t3.substr(-2)) && (e3 = false), e3 ) }), L2 = (e2.__addimage__.extractImageFromDataUrl = function (t3) { var e3 = (t3 = t3 || '').split('base64,'), r3 = null if (2 === e3.length) { var n3 = /^data:(\w*\/\w*);*(charset=(?!charset=)[\w=-]*)*;*$/.exec( e3[0] ) Array.isArray(n3) && (r3 = { mimeType: n3[1], charset: n3[2], data: e3[1] }) } return r3 }), A2 = (e2.__addimage__.supportsArrayBuffer = function () { return ( 'undefined' != typeof ArrayBuffer && 'undefined' != typeof Uint8Array ) }) e2.__addimage__.isArrayBuffer = function (t3) { return A2() && t3 instanceof ArrayBuffer } var x2 = (e2.__addimage__.isArrayBufferView = function (t3) { return ( A2() && 'undefined' != typeof Uint32Array && (t3 instanceof Int8Array || t3 instanceof Uint8Array || ('undefined' != typeof Uint8ClampedArray && t3 instanceof Uint8ClampedArray) || t3 instanceof Int16Array || t3 instanceof Uint16Array || t3 instanceof Int32Array || t3 instanceof Uint32Array || t3 instanceof Float32Array || t3 instanceof Float64Array) ) }), S2 = (e2.__addimage__.binaryStringToUint8Array = function (t3) { for (var e3 = t3.length, r3 = new Uint8Array(e3), n3 = 0; n3 < e3; n3++) r3[n3] = t3.charCodeAt(n3) return r3 }), _2 = (e2.__addimage__.arrayBufferToBinaryString = function (t3) { for ( var e3 = '', r3 = x2(t3) ? t3 : new Uint8Array(t3), n3 = 0; n3 < r3.length; n3 += 8192 ) e3 += String.fromCharCode.apply(null, r3.subarray(n3, n3 + 8192)) return e3 }) e2.addImage = function () { var e3, n3, i3, a3, o3, s3, u2, h3, l3 if ( ('number' == typeof arguments[1] ? ((n3 = r2), (i3 = arguments[1]), (a3 = arguments[2]), (o3 = arguments[3]), (s3 = arguments[4]), (u2 = arguments[5]), (h3 = arguments[6]), (l3 = arguments[7])) : ((n3 = arguments[1]), (i3 = arguments[2]), (a3 = arguments[3]), (o3 = arguments[4]), (s3 = arguments[5]), (u2 = arguments[6]), (h3 = arguments[7]), (l3 = arguments[8])), 'object' === _typeof$3((e3 = arguments[0])) && !d3(e3) && 'imageData' in e3) ) { var f3 = e3 ;(e3 = f3.imageData), (n3 = f3.format || n3 || r2), (i3 = f3.x || i3 || 0), (a3 = f3.y || a3 || 0), (o3 = f3.w || f3.width || o3), (s3 = f3.h || f3.height || s3), (u2 = f3.alias || u2), (h3 = f3.compression || h3), (l3 = f3.rotation || f3.angle || l3) } var p3 = this.internal.getFilters() if ( (void 0 === h3 && -1 !== p3.indexOf('FlateEncode') && (h3 = 'SLOW'), isNaN(i3) || isNaN(a3)) ) throw new Error('Invalid coordinates passed to jsPDF.addImage') c2.call(this) var g3 = P2.call(this, e3, n3, u2, h3) return v4.call(this, i3, a3, o3, s3, g3, l3), this } var P2 = function (t3, n3, a3, o3) { var s3, c3, u2 if ('string' == typeof t3 && i2(t3) === r2) { t3 = unescape(t3) var h3 = k2(t3, false) ;('' !== h3 || void 0 !== (h3 = e2.loadFile(t3, true))) && (t3 = h3) } if ((d3(t3) && (t3 = p2(t3, n3)), (n3 = i2(t3, n3)), !f2(n3))) throw new Error( "addImage does not support files of type '" + n3 + "', please ensure that a plugin for '" + n3 + "' support is added." ) if ( ((null == (u2 = a3) || 0 === u2.length) && (a3 = (function (t4) { return 'string' == typeof t4 || x2(t4) ? w2(t4) : x2(t4.data) ? w2(t4.data) : null })(t3)), (s3 = g2.call(this, a3)) || (A2() && (t3 instanceof Uint8Array || 'RGBA' === n3 || ((c3 = t3), (t3 = S2(t3)))), (s3 = this['process' + n3.toUpperCase()]( t3, l2.call(this), a3, (function (t4) { return ( t4 && 'string' == typeof t4 && (t4 = t4.toUpperCase()), t4 in e2.image_compression ? t4 : y2.NONE ) })(o3), c3 ))), !s3) ) throw new Error( 'An unknown error occurred whilst processing the image.' ) return s3 }, k2 = (e2.__addimage__.convertBase64ToBinaryString = function (t3, e3) { var r3 e3 = 'boolean' != typeof e3 || e3 var n3, i3 = '' if ('string' == typeof t3) { n3 = null !== (r3 = L2(t3)) ? r3.data : t3 try { i3 = u$2(n3) } catch (t4) { if (e3) throw N2(n3) ? new Error( 'atob-Error in jsPDF.convertBase64ToBinaryString ' + t4.message ) : new Error( 'Supplied Data is not a valid base64-String jsPDF.convertBase64ToBinaryString ' ) } } return i3 }) e2.getImageProperties = function (t3) { var n3, a3, o3 = '' if ( (d3(t3) && (t3 = p2(t3)), 'string' == typeof t3 && i2(t3) === r2 && ('' === (o3 = k2(t3, false)) && (o3 = e2.loadFile(t3) || ''), (t3 = o3)), (a3 = i2(t3)), !f2(a3)) ) throw new Error( "addImage does not support files of type '" + a3 + "', please ensure that a plugin for '" + a3 + "' support is added." ) if ( (!A2() || t3 instanceof Uint8Array || (t3 = S2(t3)), !(n3 = this['process' + a3.toUpperCase()](t3))) ) throw new Error('An unknown error occurred whilst processing the image') return (n3.fileType = a3), n3 } })(E$1.API), (function (t3) { var e2 = function (t4) { if (void 0 !== t4 && '' != t4) return true } E$1.API.events.push([ 'addPage', function (t4) { this.internal.getPageInfo(t4.pageNumber).pageContext.annotations = [] }, ]), t3.events.push([ 'putPage', function (t4) { for ( var r2, n2, i2, a2 = this.internal.getCoordinateString, o2 = this.internal.getVerticalCoordinateString, s2 = this.internal.getPageInfoByObjId(t4.objId), c2 = t4.pageContext.annotations, u2 = false, h2 = 0; h2 < c2.length && !u2; h2++ ) switch ((r2 = c2[h2]).type) { case 'link': ;(e2(r2.options.url) || e2(r2.options.pageNumber)) && (u2 = true) break case 'reference': case 'text': case 'freetext': u2 = true } if (0 != u2) { this.internal.write('/Annots [') for (var l2 = 0; l2 < c2.length; l2++) { r2 = c2[l2] var f2 = this.internal.pdfEscape, d3 = this.internal.getEncryptor(t4.objId) switch (r2.type) { case 'reference': this.internal.write(' ' + r2.object.objId + ' 0 R ') break case 'text': var p2 = this.internal.newAdditionalObject(), g2 = this.internal.newAdditionalObject(), m2 = this.internal.getEncryptor(p2.objId), v4 = r2.title || 'Note' ;(i2 = '<>'), (p2.content = i2) var b2 = p2.objId + ' 0 R' ;(i2 = '<>' else if (r2.options.pageNumber) { switch ( ((i2 = '<= 0 }) t3.__arabicParser__.arabicLetterHasIsolatedForm = function (t4) { return o2(t4) && a2(t4) && e2[t4.charCodeAt(0)].length >= 1 } var u2 = (t3.__arabicParser__.arabicLetterHasFinalForm = function (t4) { return o2(t4) && a2(t4) && e2[t4.charCodeAt(0)].length >= 2 }) t3.__arabicParser__.arabicLetterHasInitialForm = function (t4) { return o2(t4) && a2(t4) && e2[t4.charCodeAt(0)].length >= 3 } var h2 = (t3.__arabicParser__.arabicLetterHasMedialForm = function (t4) { return o2(t4) && a2(t4) && 4 == e2[t4.charCodeAt(0)].length }), l2 = (t3.__arabicParser__.resolveLigatures = function (t4) { var e3 = 0, n3 = r2, i3 = '', a3 = 0 for (e3 = 0; e3 < t4.length; e3 += 1) void 0 !== n3[t4.charCodeAt(e3)] ? (a3++, 'number' == typeof (n3 = n3[t4.charCodeAt(e3)]) && ((i3 += String.fromCharCode(n3)), (n3 = r2), (a3 = 0)), e3 === t4.length - 1 && ((n3 = r2), (i3 += t4.charAt(e3 - (a3 - 1))), (e3 -= a3 - 1), (a3 = 0))) : ((n3 = r2), (i3 += t4.charAt(e3 - a3)), (e3 -= a3), (a3 = 0)) return i3 }) t3.__arabicParser__.isArabicDiacritic = function (t4) { return void 0 !== t4 && void 0 !== n2[t4.charCodeAt(0)] } var f2 = (t3.__arabicParser__.getCorrectForm = function (t4, e3, r3) { return o2(t4) ? false === a2(t4) ? -1 : !u2(t4) || (!o2(e3) && !o2(r3)) || (!o2(r3) && s2(e3)) || (s2(t4) && !o2(e3)) || (s2(t4) && c2(e3)) || (s2(t4) && s2(e3)) ? 0 : h2(t4) && o2(e3) && !s2(e3) && o2(r3) && u2(r3) ? 3 : s2(t4) || !o2(r3) ? 1 : 2 : -1 }), d3 = function (t4) { var r3 = 0, n3 = 0, i3 = 0, a3 = '', s3 = '', c3 = '', u3 = (t4 = t4 || '').split('\\s+'), h3 = [] for (r3 = 0; r3 < u3.length; r3 += 1) { for (h3.push(''), n3 = 0; n3 < u3[r3].length; n3 += 1) (a3 = u3[r3][n3]), (s3 = u3[r3][n3 - 1]), (c3 = u3[r3][n3 + 1]), o2(a3) ? ((i3 = f2(a3, s3, c3)), (h3[r3] += -1 !== i3 ? String.fromCharCode(e2[a3.charCodeAt(0)][i3]) : a3)) : (h3[r3] += a3) h3[r3] = l2(h3[r3]) } return h3.join(' ') }, p2 = (t3.__arabicParser__.processArabic = t3.processArabic = function () { var t4, e3 = 'string' == typeof arguments[0] ? arguments[0] : arguments[0].text, r3 = [] if (Array.isArray(e3)) { var n3 = 0 for (r3 = [], n3 = 0; n3 < e3.length; n3 += 1) Array.isArray(e3[n3]) ? r3.push([d3(e3[n3][0]), e3[n3][1], e3[n3][2]]) : r3.push([d3(e3[n3])]) t4 = r3 } else t4 = d3(e3) return 'string' == typeof arguments[0] ? t4 : ((arguments[0].text = t4), arguments[0]) }) t3.events.push(['preProcessText', p2]) })(E$1.API), (E$1.API.autoPrint = function (t3) { var e2 switch ( (((t3 = t3 || {}).variant = t3.variant || 'non-conform'), t3.variant) ) { case 'javascript': this.addJS('print({});') break case 'non-conform': default: this.internal.events.subscribe('postPutResources', function () { ;(e2 = this.internal.newObject()), this.internal.out('<<'), this.internal.out('/S /Named'), this.internal.out('/Type /Action'), this.internal.out('/N /Print'), this.internal.out('>>'), this.internal.out('endobj') }), this.internal.events.subscribe('putCatalog', function () { this.internal.out('/OpenAction ' + e2 + ' 0 R') }) } return this }), (function (t3) { var e2 = function () { var t4 = void 0 Object.defineProperty(this, 'pdf', { get: function () { return t4 }, set: function (e4) { t4 = e4 }, }) var e3 = 150 Object.defineProperty(this, 'width', { get: function () { return e3 }, set: function (t5) { ;(e3 = isNaN(t5) || false === Number.isInteger(t5) || t5 < 0 ? 150 : t5), this.getContext('2d').pageWrapXEnabled && (this.getContext('2d').pageWrapX = e3 + 1) }, }) var r2 = 300 Object.defineProperty(this, 'height', { get: function () { return r2 }, set: function (t5) { ;(r2 = isNaN(t5) || false === Number.isInteger(t5) || t5 < 0 ? 300 : t5), this.getContext('2d').pageWrapYEnabled && (this.getContext('2d').pageWrapY = r2 + 1) }, }) var n2 = [] Object.defineProperty(this, 'childNodes', { get: function () { return n2 }, set: function (t5) { n2 = t5 }, }) var i2 = {} Object.defineProperty(this, 'style', { get: function () { return i2 }, set: function (t5) { i2 = t5 }, }), Object.defineProperty(this, 'parentNode', {}) } ;(e2.prototype.getContext = function (t4, e3) { var r2 if ('2d' !== (t4 = t4 || '2d')) return null for (r2 in e3) this.pdf.context2d.hasOwnProperty(r2) && (this.pdf.context2d[r2] = e3[r2]) return (this.pdf.context2d._canvas = this), this.pdf.context2d }), (e2.prototype.toDataURL = function () { throw new Error('toDataURL is not implemented.') }), t3.events.push([ 'initialized', function () { ;(this.canvas = new e2()), (this.canvas.pdf = this) }, ]) })(E$1.API), (function (e2) { var r2 = { left: 0, top: 0, bottom: 0, right: 0 }, n2 = false, i2 = function () { void 0 === this.internal.__cell__ && ((this.internal.__cell__ = {}), (this.internal.__cell__.padding = 3), (this.internal.__cell__.headerFunction = void 0), (this.internal.__cell__.margins = Object.assign({}, r2)), (this.internal.__cell__.margins.width = this.getPageWidth()), a2.call(this)) }, a2 = function () { ;(this.internal.__cell__.lastCell = new o2()), (this.internal.__cell__.pages = 1) }, o2 = function () { var t3 = arguments[0] Object.defineProperty(this, 'x', { enumerable: true, get: function () { return t3 }, set: function (e4) { t3 = e4 }, }) var e3 = arguments[1] Object.defineProperty(this, 'y', { enumerable: true, get: function () { return e3 }, set: function (t4) { e3 = t4 }, }) var r3 = arguments[2] Object.defineProperty(this, 'width', { enumerable: true, get: function () { return r3 }, set: function (t4) { r3 = t4 }, }) var n3 = arguments[3] Object.defineProperty(this, 'height', { enumerable: true, get: function () { return n3 }, set: function (t4) { n3 = t4 }, }) var i3 = arguments[4] Object.defineProperty(this, 'text', { enumerable: true, get: function () { return i3 }, set: function (t4) { i3 = t4 }, }) var a3 = arguments[5] Object.defineProperty(this, 'lineNumber', { enumerable: true, get: function () { return a3 }, set: function (t4) { a3 = t4 }, }) var o3 = arguments[6] return ( Object.defineProperty(this, 'align', { enumerable: true, get: function () { return o3 }, set: function (t4) { o3 = t4 }, }), this ) } ;(o2.prototype.clone = function () { return new o2( this.x, this.y, this.width, this.height, this.text, this.lineNumber, this.align ) }), (o2.prototype.toArray = function () { return [ this.x, this.y, this.width, this.height, this.text, this.lineNumber, this.align, ] }), (e2.setHeaderFunction = function (t3) { return ( i2.call(this), (this.internal.__cell__.headerFunction = 'function' == typeof t3 ? t3 : void 0), this ) }), (e2.getTextDimensions = function (t3, e3) { i2.call(this) var r3 = (e3 = e3 || {}).fontSize || this.getFontSize(), n3 = e3.font || this.getFont(), a3 = e3.scaleFactor || this.internal.scaleFactor, o3 = 0, s3 = 0, c3 = 0, u2 = this if (!Array.isArray(t3) && 'string' != typeof t3) { if ('number' != typeof t3) throw new Error( 'getTextDimensions expects text-parameter to be of type String or type Number or an Array of Strings.' ) t3 = String(t3) } var h2 = e3.maxWidth h2 > 0 ? 'string' == typeof t3 ? (t3 = this.splitTextToSize(t3, h2)) : '[object Array]' === Object.prototype.toString.call(t3) && (t3 = t3.reduce(function (t4, e4) { return t4.concat(u2.splitTextToSize(e4, h2)) }, [])) : (t3 = Array.isArray(t3) ? t3 : [t3]) for (var l2 = 0; l2 < t3.length; l2++) o3 < (c3 = this.getStringUnitWidth(t3[l2], { font: n3 }) * r3) && (o3 = c3) return ( 0 !== o3 && (s3 = t3.length), { w: (o3 /= a3), h: Math.max( (s3 * r3 * this.getLineHeightFactor() - r3 * (this.getLineHeightFactor() - 1)) / a3, 0 ), } ) }), (e2.cellAddPage = function () { i2.call(this), this.addPage() var t3 = this.internal.__cell__.margins || r2 return ( (this.internal.__cell__.lastCell = new o2( t3.left, t3.top, void 0, void 0 )), (this.internal.__cell__.pages += 1), this ) }) var s2 = (e2.cell = function () { var t3 ;(t3 = arguments[0] instanceof o2 ? arguments[0] : new o2( arguments[0], arguments[1], arguments[2], arguments[3], arguments[4], arguments[5] )), i2.call(this) var e3 = this.internal.__cell__.lastCell, a3 = this.internal.__cell__.padding, s3 = this.internal.__cell__.margins || r2, c3 = this.internal.__cell__.tableHeaderRow, u2 = this.internal.__cell__.printHeaders return ( void 0 !== e3.lineNumber && (e3.lineNumber === t3.lineNumber ? ((t3.x = (e3.x || 0) + (e3.width || 0)), (t3.y = e3.y || 0)) : e3.y + e3.height + t3.height + s3.bottom > this.getPageHeight() ? (this.cellAddPage(), (t3.y = s3.top), u2 && c3 && (this.printHeaderRow(t3.lineNumber, true), (t3.y += c3[0].height))) : (t3.y = e3.y + e3.height || t3.y)), void 0 !== t3.text[0] && (this.rect( t3.x, t3.y, t3.width, t3.height, true === n2 ? 'FD' : void 0 ), 'right' === t3.align ? this.text(t3.text, t3.x + t3.width - a3, t3.y + a3, { align: 'right', baseline: 'top', }) : 'center' === t3.align ? this.text(t3.text, t3.x + t3.width / 2, t3.y + a3, { align: 'center', baseline: 'top', maxWidth: t3.width - a3 - a3, }) : this.text(t3.text, t3.x + a3, t3.y + a3, { align: 'left', baseline: 'top', maxWidth: t3.width - a3 - a3, })), (this.internal.__cell__.lastCell = t3), this ) }) e2.table = function (e3, n3, u2, h2, l2) { if ((i2.call(this), !u2)) throw new Error('No data for PDF table.') var f2, d3, p2, g2, m2 = [], v4 = [], b2 = [], y2 = {}, w2 = {}, N2 = [], L2 = [], A2 = (l2 = l2 || {}).autoSize || false, x2 = false !== l2.printHeaders, S2 = l2.css && void 0 !== l2.css['font-size'] ? 16 * l2.css['font-size'] : l2.fontSize || 12, _2 = l2.margins || Object.assign({ width: this.getPageWidth() }, r2), P2 = 'number' == typeof l2.padding ? l2.padding : 3, k2 = l2.headerBackgroundColor || '#c8c8c8', I2 = l2.headerTextColor || '#000' if ( (a2.call(this), (this.internal.__cell__.printHeaders = x2), (this.internal.__cell__.margins = _2), (this.internal.__cell__.table_font_size = S2), (this.internal.__cell__.padding = P2), (this.internal.__cell__.headerBackgroundColor = k2), (this.internal.__cell__.headerTextColor = I2), this.setFontSize(S2), null == h2) ) (v4 = m2 = Object.keys(u2[0])), (b2 = m2.map(function () { return 'left' })) else if (Array.isArray(h2) && 'object' === _typeof$3(h2[0])) for ( m2 = h2.map(function (t3) { return t3.name }), v4 = h2.map(function (t3) { return t3.prompt || t3.name || '' }), b2 = h2.map(function (t3) { return t3.align || 'left' }), f2 = 0; f2 < h2.length; f2 += 1 ) w2[h2[f2].name] = h2[f2].width * (19.049976 / 25.4) else Array.isArray(h2) && 'string' == typeof h2[0] && ((v4 = m2 = h2), (b2 = m2.map(function () { return 'left' }))) if (A2 || (Array.isArray(h2) && 'string' == typeof h2[0])) for (f2 = 0; f2 < m2.length; f2 += 1) { for ( y2[(g2 = m2[f2])] = u2.map(function (t3) { return t3[g2] }), this.setFont(void 0, 'bold'), N2.push( this.getTextDimensions(v4[f2], { fontSize: this.internal.__cell__.table_font_size, scaleFactor: this.internal.scaleFactor, }).w ), d3 = y2[g2], this.setFont(void 0, 'normal'), p2 = 0; p2 < d3.length; p2 += 1 ) N2.push( this.getTextDimensions(d3[p2], { fontSize: this.internal.__cell__.table_font_size, scaleFactor: this.internal.scaleFactor, }).w ) ;(w2[g2] = Math.max.apply(null, N2) + P2 + P2), (N2 = []) } if (x2) { var F2 = {} for (f2 = 0; f2 < m2.length; f2 += 1) (F2[m2[f2]] = {}), (F2[m2[f2]].text = v4[f2]), (F2[m2[f2]].align = b2[f2]) var C2 = c2.call(this, F2, w2) ;(L2 = m2.map(function (t3) { return new o2(e3, n3, w2[t3], C2, F2[t3].text, void 0, F2[t3].align) })), this.setTableHeaderRow(L2), this.printHeaderRow(1, false) } var j2 = h2.reduce(function (t3, e4) { return (t3[e4.name] = e4.align), t3 }, {}) for (f2 = 0; f2 < u2.length; f2 += 1) { 'rowStart' in l2 && l2.rowStart instanceof Function && l2.rowStart({ row: f2, data: u2[f2] }, this) var O2 = c2.call(this, u2[f2], w2) for (p2 = 0; p2 < m2.length; p2 += 1) { var B3 = u2[f2][m2[p2]] 'cellStart' in l2 && l2.cellStart instanceof Function && l2.cellStart({ row: f2, col: p2, data: B3 }, this), s2.call( this, new o2(e3, n3, w2[m2[p2]], O2, B3, f2 + 2, j2[m2[p2]]) ) } } return ( (this.internal.__cell__.table_x = e3), (this.internal.__cell__.table_y = n3), this ) } var c2 = function (t3, e3) { var r3 = this.internal.__cell__.padding, n3 = this.internal.__cell__.table_font_size, i3 = this.internal.scaleFactor return Object.keys(t3) .map(function (n4) { var i4 = t3[n4] return this.splitTextToSize( i4.hasOwnProperty('text') ? i4.text : i4, e3[n4] - r3 - r3 ) }, this) .map(function (t4) { return (this.getLineHeightFactor() * t4.length * n3) / i3 + r3 + r3 }, this) .reduce(function (t4, e4) { return Math.max(t4, e4) }, 0) } ;(e2.setTableHeaderRow = function (t3) { i2.call(this), (this.internal.__cell__.tableHeaderRow = t3) }), (e2.printHeaderRow = function (t3, e3) { if ((i2.call(this), !this.internal.__cell__.tableHeaderRow)) throw new Error('Property tableHeaderRow does not exist.') var r3 if ( ((n2 = true), 'function' == typeof this.internal.__cell__.headerFunction) ) { var a3 = this.internal.__cell__.headerFunction( this, this.internal.__cell__.pages ) this.internal.__cell__.lastCell = new o2( a3[0], a3[1], a3[2], a3[3], void 0, -1 ) } this.setFont(void 0, 'bold') for ( var c3 = [], u2 = 0; u2 < this.internal.__cell__.tableHeaderRow.length; u2 += 1 ) { ;(r3 = this.internal.__cell__.tableHeaderRow[u2].clone()), e3 && ((r3.y = this.internal.__cell__.margins.top || 0), c3.push(r3)), (r3.lineNumber = t3) var h2 = this.getTextColor() this.setTextColor(this.internal.__cell__.headerTextColor), this.setFillColor(this.internal.__cell__.headerBackgroundColor), s2.call(this, r3), this.setTextColor(h2) } c3.length > 0 && this.setTableHeaderRow(c3), this.setFont(void 0, 'normal'), (n2 = false) }) })(E$1.API) var Pt = { italic: ['italic', 'oblique', 'normal'], oblique: ['oblique', 'italic', 'normal'], normal: ['normal', 'oblique', 'italic'], }, kt = [ 'ultra-condensed', 'extra-condensed', 'condensed', 'semi-condensed', 'normal', 'semi-expanded', 'expanded', 'extra-expanded', 'ultra-expanded', ], It = _t$2(kt), Ft = [100, 200, 300, 400, 500, 600, 700, 800, 900], Ct = _t$2(Ft) function jt(t3) { var e2 = t3.family.replace(/"|'/g, '').toLowerCase(), r2 = (function (t4) { return Pt[(t4 = t4 || 'normal')] ? t4 : 'normal' })(t3.style), n2 = (function (t4) { if (!t4) return 400 if ('number' == typeof t4) return t4 >= 100 && t4 <= 900 && t4 % 100 == 0 ? t4 : 400 if (/^\d00$/.test(t4)) return parseInt(t4) switch (t4) { case 'bold': return 700 case 'normal': default: return 400 } })(t3.weight), i2 = (function (t4) { return 'number' == typeof It[(t4 = t4 || 'normal')] ? t4 : 'normal' })(t3.stretch) return { family: e2, style: r2, weight: n2, stretch: i2, src: t3.src || [], ref: t3.ref || { name: e2, style: [i2, r2, n2].join(' ') }, } } function Ot(t3, e2, r2, n2) { var i2 for (i2 = r2; i2 >= 0 && i2 < e2.length; i2 += n2) if (t3[e2[i2]]) return t3[e2[i2]] for (i2 = r2; i2 >= 0 && i2 < e2.length; i2 -= n2) if (t3[e2[i2]]) return t3[e2[i2]] } var Bt = { 'sans-serif': 'helvetica', fixed: 'courier', monospace: 'courier', terminal: 'courier', cursive: 'times', fantasy: 'times', serif: 'times', }, Mt = { caption: 'times', icon: 'times', menu: 'times', 'message-box': 'times', 'small-caption': 'times', 'status-bar': 'times', } function Et(t3) { return [t3.stretch, t3.style, t3.weight, t3.family].join(' ') } function qt(t3, e2, r2) { for ( var n2 = (r2 = r2 || {}).defaultFontFamily || 'times', i2 = Object.assign({}, Bt, r2.genericFontFamilies || {}), a2 = null, o2 = null, s2 = 0; s2 < e2.length; ++s2 ) if ( (i2[(a2 = jt(e2[s2])).family] && (a2.family = i2[a2.family]), t3.hasOwnProperty(a2.family)) ) { o2 = t3[a2.family] break } if (!(o2 = o2 || t3[n2])) throw new Error( "Could not find a font-family for the rule '" + Et(a2) + "' and default family '" + n2 + "'." ) if ( ((o2 = (function (t4, e3) { if (e3[t4]) return e3[t4] var r3 = It[t4], n3 = r3 <= It.normal ? -1 : 1, i3 = Ot(e3, kt, r3, n3) if (!i3) throw new Error( 'Could not find a matching font-stretch value for ' + t4 ) return i3 })(a2.stretch, o2)), (o2 = (function (t4, e3) { if (e3[t4]) return e3[t4] for (var r3 = Pt[t4], n3 = 0; n3 < r3.length; ++n3) if (e3[r3[n3]]) return e3[r3[n3]] throw new Error('Could not find a matching font-style for ' + t4) })(a2.style, o2)), !(o2 = (function (t4, e3) { if (e3[t4]) return e3[t4] if (400 === t4 && e3[500]) return e3[500] if (500 === t4 && e3[400]) return e3[400] var r3 = Ct[t4], n3 = Ot(e3, Ft, r3, t4 < 400 ? -1 : 1) if (!n3) throw new Error('Could not find a matching font-weight for value ' + t4) return n3 })(a2.weight, o2))) ) throw new Error("Failed to resolve a font for the rule '" + Et(a2) + "'.") return o2 } function Dt(t3) { return t3.trimLeft() } function Rt(t3, e2) { for (var r2 = 0; r2 < t3.length; ) { if (t3.charAt(r2) === e2) return [t3.substring(0, r2), t3.substring(r2 + 1)] r2 += 1 } return null } function Tt(t3) { var e2 = t3.match(/^(-[a-z_]|[a-z_])[a-z0-9_-]*/i) return null === e2 ? null : [e2[0], t3.substring(e2[0].length)] } var Ut, zt, Ht, Wt = ['times'] !(function (e2) { var r2, n2, i2, o2, s2, c2, u2, h2, l2, d3 = function (t3) { return ( (t3 = t3 || {}), (this.isStrokeTransparent = t3.isStrokeTransparent || false), (this.strokeOpacity = t3.strokeOpacity || 1), (this.strokeStyle = t3.strokeStyle || '#000000'), (this.fillStyle = t3.fillStyle || '#000000'), (this.isFillTransparent = t3.isFillTransparent || false), (this.fillOpacity = t3.fillOpacity || 1), (this.font = t3.font || '10px sans-serif'), (this.textBaseline = t3.textBaseline || 'alphabetic'), (this.textAlign = t3.textAlign || 'left'), (this.lineWidth = t3.lineWidth || 1), (this.lineJoin = t3.lineJoin || 'miter'), (this.lineCap = t3.lineCap || 'butt'), (this.path = t3.path || []), (this.transform = void 0 !== t3.transform ? t3.transform.clone() : new h2()), (this.globalCompositeOperation = t3.globalCompositeOperation || 'normal'), (this.globalAlpha = t3.globalAlpha || 1), (this.clip_path = t3.clip_path || []), (this.currentPoint = t3.currentPoint || new c2()), (this.miterLimit = t3.miterLimit || 10), (this.lastPoint = t3.lastPoint || new c2()), (this.lineDashOffset = t3.lineDashOffset || 0), (this.lineDash = t3.lineDash || []), (this.margin = t3.margin || [0, 0, 0, 0]), (this.prevPageLastElemOffset = t3.prevPageLastElemOffset || 0), (this.ignoreClearRect = 'boolean' != typeof t3.ignoreClearRect || t3.ignoreClearRect), this ) } e2.events.push([ 'initialized', function () { ;(this.context2d = new p2(this)), (r2 = this.internal.f2), (n2 = this.internal.getCoordinateString), (i2 = this.internal.getVerticalCoordinateString), (o2 = this.internal.getHorizontalCoordinate), (s2 = this.internal.getVerticalCoordinate), (c2 = this.internal.Point), (u2 = this.internal.Rectangle), (h2 = this.internal.Matrix), (l2 = new d3()) }, ]) var p2 = function (t3) { Object.defineProperty(this, 'canvas', { get: function () { return { parentNode: false, style: false } }, }) var e3 = t3 Object.defineProperty(this, 'pdf', { get: function () { return e3 }, }) var r3 = false Object.defineProperty(this, 'pageWrapXEnabled', { get: function () { return r3 }, set: function (t4) { r3 = Boolean(t4) }, }) var n3 = false Object.defineProperty(this, 'pageWrapYEnabled', { get: function () { return n3 }, set: function (t4) { n3 = Boolean(t4) }, }) var i3 = 0 Object.defineProperty(this, 'posX', { get: function () { return i3 }, set: function (t4) { isNaN(t4) || (i3 = t4) }, }) var a2 = 0 Object.defineProperty(this, 'posY', { get: function () { return a2 }, set: function (t4) { isNaN(t4) || (a2 = t4) }, }), Object.defineProperty(this, 'margin', { get: function () { return l2.margin }, set: function (t4) { var e4 'number' == typeof t4 ? (e4 = [t4, t4, t4, t4]) : (((e4 = new Array(4))[0] = t4[0]), (e4[1] = t4.length >= 2 ? t4[1] : e4[0]), (e4[2] = t4.length >= 3 ? t4[2] : e4[0]), (e4[3] = t4.length >= 4 ? t4[3] : e4[1])), (l2.margin = e4) }, }) var o3 = false Object.defineProperty(this, 'autoPaging', { get: function () { return o3 }, set: function (t4) { o3 = t4 }, }) var s3 = 0 Object.defineProperty(this, 'lastBreak', { get: function () { return s3 }, set: function (t4) { s3 = t4 }, }) var c3 = [] Object.defineProperty(this, 'pageBreaks', { get: function () { return c3 }, set: function (t4) { c3 = t4 }, }), Object.defineProperty(this, 'ctx', { get: function () { return l2 }, set: function (t4) { t4 instanceof d3 && (l2 = t4) }, }), Object.defineProperty(this, 'path', { get: function () { return l2.path }, set: function (t4) { l2.path = t4 }, }) var u3 = [] Object.defineProperty(this, 'ctxStack', { get: function () { return u3 }, set: function (t4) { u3 = t4 }, }), Object.defineProperty(this, 'fillStyle', { get: function () { return this.ctx.fillStyle }, set: function (t4) { var e4 ;(e4 = g2(t4)), (this.ctx.fillStyle = e4.style), (this.ctx.isFillTransparent = 0 === e4.a), (this.ctx.fillOpacity = e4.a), this.pdf.setFillColor(e4.r, e4.g, e4.b, { a: e4.a }), this.pdf.setTextColor(e4.r, e4.g, e4.b, { a: e4.a }) }, }), Object.defineProperty(this, 'strokeStyle', { get: function () { return this.ctx.strokeStyle }, set: function (t4) { var e4 = g2(t4) ;(this.ctx.strokeStyle = e4.style), (this.ctx.isStrokeTransparent = 0 === e4.a), (this.ctx.strokeOpacity = e4.a), 0 === e4.a ? this.pdf.setDrawColor(255, 255, 255) : (e4.a, this.pdf.setDrawColor(e4.r, e4.g, e4.b)) }, }), Object.defineProperty(this, 'lineCap', { get: function () { return this.ctx.lineCap }, set: function (t4) { ;-1 !== ['butt', 'round', 'square'].indexOf(t4) && ((this.ctx.lineCap = t4), this.pdf.setLineCap(t4)) }, }), Object.defineProperty(this, 'lineWidth', { get: function () { return this.ctx.lineWidth }, set: function (t4) { isNaN(t4) || ((this.ctx.lineWidth = t4), this.pdf.setLineWidth(t4)) }, }), Object.defineProperty(this, 'lineJoin', { get: function () { return this.ctx.lineJoin }, set: function (t4) { ;-1 !== ['bevel', 'round', 'miter'].indexOf(t4) && ((this.ctx.lineJoin = t4), this.pdf.setLineJoin(t4)) }, }), Object.defineProperty(this, 'miterLimit', { get: function () { return this.ctx.miterLimit }, set: function (t4) { isNaN(t4) || ((this.ctx.miterLimit = t4), this.pdf.setMiterLimit(t4)) }, }), Object.defineProperty(this, 'textBaseline', { get: function () { return this.ctx.textBaseline }, set: function (t4) { this.ctx.textBaseline = t4 }, }), Object.defineProperty(this, 'textAlign', { get: function () { return this.ctx.textAlign }, set: function (t4) { ;-1 !== ['right', 'end', 'center', 'left', 'start'].indexOf(t4) && (this.ctx.textAlign = t4) }, }) var h3 = null function f2(t4, e4) { if (null === h3) { var r4 = (function (t5) { var e5 = [] return ( Object.keys(t5).forEach(function (r5) { t5[r5].forEach(function (t6) { var n4 = null switch (t6) { case 'bold': n4 = { family: r5, weight: 'bold' } break case 'italic': n4 = { family: r5, style: 'italic' } break case 'bolditalic': n4 = { family: r5, weight: 'bold', style: 'italic' } break case '': case 'normal': n4 = { family: r5 } } null !== n4 && ((n4.ref = { name: r5, style: t6 }), e5.push(n4)) }) }), e5 ) })(t4.getFontList()) h3 = (function (t5) { for (var e5 = {}, r5 = 0; r5 < t5.length; ++r5) { var n4 = jt(t5[r5]), i4 = n4.family, a3 = n4.stretch, o4 = n4.style, s4 = n4.weight ;(e5[i4] = e5[i4] || {}), (e5[i4][a3] = e5[i4][a3] || {}), (e5[i4][a3][o4] = e5[i4][a3][o4] || {}), (e5[i4][a3][o4][s4] = n4) } return e5 })(r4.concat(e4)) } return h3 } var p3 = null Object.defineProperty(this, 'fontFaces', { get: function () { return p3 }, set: function (t4) { ;(h3 = null), (p3 = t4) }, }), Object.defineProperty(this, 'font', { get: function () { return this.ctx.font }, set: function (t4) { var e4 if ( ((this.ctx.font = t4), null !== (e4 = /^\s*(?=(?:(?:[-a-z]+\s*){0,2}(italic|oblique))?)(?=(?:(?:[-a-z]+\s*){0,2}(small-caps))?)(?=(?:(?:[-a-z]+\s*){0,2}(bold(?:er)?|lighter|[1-9]00))?)(?:(?:normal|\1|\2|\3)\s*){0,3}((?:xx?-)?(?:small|large)|medium|smaller|larger|[.\d]+(?:\%|in|[cem]m|ex|p[ctx]))(?:\s*\/\s*(normal|[.\d]+(?:\%|in|[cem]m|ex|p[ctx])))?\s*([-_,\"\'\sa-z]+?)\s*$/i.exec( t4 ))) ) { var r4 = e4[1], n4 = (e4[2], e4[3]), i4 = e4[4], a3 = (e4[5], e4[6]), o4 = /^([.\d]+)((?:%|in|[cem]m|ex|p[ctx]))$/i.exec(i4)[2] ;(i4 = 'px' === o4 ? Math.floor(parseFloat(i4) * this.pdf.internal.scaleFactor) : 'em' === o4 ? Math.floor(parseFloat(i4) * this.pdf.getFontSize()) : Math.floor(parseFloat(i4) * this.pdf.internal.scaleFactor)), this.pdf.setFontSize(i4) var s4 = (function (t5) { var e5, r5, n5 = [], i5 = t5.trim() if ('' === i5) return Wt if (i5 in Mt) return [Mt[i5]] for (; '' !== i5; ) { switch (((r5 = null), (e5 = (i5 = Dt(i5)).charAt(0)))) { case '"': case "'": r5 = Rt(i5.substring(1), e5) break default: r5 = Tt(i5) } if (null === r5) return Wt if ( (n5.push(r5[0]), '' !== (i5 = Dt(r5[1])) && ',' !== i5.charAt(0)) ) return Wt i5 = i5.replace(/^,/, '') } return n5 })(a3) if (this.fontFaces) { var c4 = qt( f2(this.pdf, this.fontFaces), s4.map(function (t5) { return { family: t5, stretch: 'normal', weight: n4, style: r4, } }) ) this.pdf.setFont(c4.ref.name, c4.ref.style) } else { var u4 = '' ;('bold' === n4 || parseInt(n4, 10) >= 700 || 'bold' === r4) && (u4 = 'bold'), 'italic' === r4 && (u4 += 'italic'), 0 === u4.length && (u4 = 'normal') for ( var h4 = '', l3 = { arial: 'Helvetica', Arial: 'Helvetica', verdana: 'Helvetica', Verdana: 'Helvetica', helvetica: 'Helvetica', Helvetica: 'Helvetica', 'sans-serif': 'Helvetica', fixed: 'Courier', monospace: 'Courier', terminal: 'Courier', cursive: 'Times', fantasy: 'Times', serif: 'Times', }, d4 = 0; d4 < s4.length; d4++ ) { if ( void 0 !== this.pdf.internal.getFont(s4[d4], u4, { noFallback: true, disableWarning: true, }) ) { h4 = s4[d4] break } if ( 'bolditalic' === u4 && void 0 !== this.pdf.internal.getFont(s4[d4], 'bold', { noFallback: true, disableWarning: true, }) ) (h4 = s4[d4]), (u4 = 'bold') else if ( void 0 !== this.pdf.internal.getFont(s4[d4], 'normal', { noFallback: true, disableWarning: true, }) ) { ;(h4 = s4[d4]), (u4 = 'normal') break } } if ('' === h4) { for (var p4 = 0; p4 < s4.length; p4++) if (l3[s4[p4]]) { h4 = l3[s4[p4]] break } } ;(h4 = '' === h4 ? 'Times' : h4), this.pdf.setFont(h4, u4) } } }, }), Object.defineProperty(this, 'globalCompositeOperation', { get: function () { return this.ctx.globalCompositeOperation }, set: function (t4) { this.ctx.globalCompositeOperation = t4 }, }), Object.defineProperty(this, 'globalAlpha', { get: function () { return this.ctx.globalAlpha }, set: function (t4) { this.ctx.globalAlpha = t4 }, }), Object.defineProperty(this, 'lineDashOffset', { get: function () { return this.ctx.lineDashOffset }, set: function (t4) { ;(this.ctx.lineDashOffset = t4), T2.call(this) }, }), Object.defineProperty(this, 'lineDash', { get: function () { return this.ctx.lineDash }, set: function (t4) { ;(this.ctx.lineDash = t4), T2.call(this) }, }), Object.defineProperty(this, 'ignoreClearRect', { get: function () { return this.ctx.ignoreClearRect }, set: function (t4) { this.ctx.ignoreClearRect = Boolean(t4) }, }) } ;(p2.prototype.setLineDash = function (t3) { this.lineDash = t3 }), (p2.prototype.getLineDash = function () { return this.lineDash.length % 2 ? this.lineDash.concat(this.lineDash) : this.lineDash.slice() }), (p2.prototype.fill = function () { A2.call(this, 'fill', false) }), (p2.prototype.stroke = function () { A2.call(this, 'stroke', false) }), (p2.prototype.beginPath = function () { this.path = [{ type: 'begin' }] }), (p2.prototype.moveTo = function (t3, e3) { if (isNaN(t3) || isNaN(e3)) throw ( (a$2.error('jsPDF.context2d.moveTo: Invalid arguments', arguments), new Error('Invalid arguments passed to jsPDF.context2d.moveTo')) ) var r3 = this.ctx.transform.applyToPoint(new c2(t3, e3)) this.path.push({ type: 'mt', x: r3.x, y: r3.y }), (this.ctx.lastPoint = new c2(t3, e3)) }), (p2.prototype.closePath = function () { var e3 = new c2(0, 0), r3 = 0 for (r3 = this.path.length - 1; -1 !== r3; r3--) if ( 'begin' === this.path[r3].type && 'object' === _typeof$3(this.path[r3 + 1]) && 'number' == typeof this.path[r3 + 1].x ) { e3 = new c2(this.path[r3 + 1].x, this.path[r3 + 1].y) break } this.path.push({ type: 'close' }), (this.ctx.lastPoint = new c2(e3.x, e3.y)) }), (p2.prototype.lineTo = function (t3, e3) { if (isNaN(t3) || isNaN(e3)) throw ( (a$2.error('jsPDF.context2d.lineTo: Invalid arguments', arguments), new Error('Invalid arguments passed to jsPDF.context2d.lineTo')) ) var r3 = this.ctx.transform.applyToPoint(new c2(t3, e3)) this.path.push({ type: 'lt', x: r3.x, y: r3.y }), (this.ctx.lastPoint = new c2(r3.x, r3.y)) }), (p2.prototype.clip = function () { ;(this.ctx.clip_path = JSON.parse(JSON.stringify(this.path))), A2.call(this, null, true) }), (p2.prototype.quadraticCurveTo = function (t3, e3, r3, n3) { if (isNaN(r3) || isNaN(n3) || isNaN(t3) || isNaN(e3)) throw ( (a$2.error( 'jsPDF.context2d.quadraticCurveTo: Invalid arguments', arguments ), new Error( 'Invalid arguments passed to jsPDF.context2d.quadraticCurveTo' )) ) var i3 = this.ctx.transform.applyToPoint(new c2(r3, n3)), o3 = this.ctx.transform.applyToPoint(new c2(t3, e3)) this.path.push({ type: 'qct', x1: o3.x, y1: o3.y, x: i3.x, y: i3.y }), (this.ctx.lastPoint = new c2(i3.x, i3.y)) }), (p2.prototype.bezierCurveTo = function (t3, e3, r3, n3, i3, o3) { if ( isNaN(i3) || isNaN(o3) || isNaN(t3) || isNaN(e3) || isNaN(r3) || isNaN(n3) ) throw ( (a$2.error( 'jsPDF.context2d.bezierCurveTo: Invalid arguments', arguments ), new Error( 'Invalid arguments passed to jsPDF.context2d.bezierCurveTo' )) ) var s3 = this.ctx.transform.applyToPoint(new c2(i3, o3)), u3 = this.ctx.transform.applyToPoint(new c2(t3, e3)), h3 = this.ctx.transform.applyToPoint(new c2(r3, n3)) this.path.push({ type: 'bct', x1: u3.x, y1: u3.y, x2: h3.x, y2: h3.y, x: s3.x, y: s3.y, }), (this.ctx.lastPoint = new c2(s3.x, s3.y)) }), (p2.prototype.arc = function (t3, e3, r3, n3, i3, o3) { if (isNaN(t3) || isNaN(e3) || isNaN(r3) || isNaN(n3) || isNaN(i3)) throw ( (a$2.error('jsPDF.context2d.arc: Invalid arguments', arguments), new Error('Invalid arguments passed to jsPDF.context2d.arc')) ) if (((o3 = Boolean(o3)), !this.ctx.transform.isIdentity)) { var s3 = this.ctx.transform.applyToPoint(new c2(t3, e3)) ;(t3 = s3.x), (e3 = s3.y) var u3 = this.ctx.transform.applyToPoint(new c2(0, r3)), h3 = this.ctx.transform.applyToPoint(new c2(0, 0)) r3 = Math.sqrt(Math.pow(u3.x - h3.x, 2) + Math.pow(u3.y - h3.y, 2)) } Math.abs(i3 - n3) >= 2 * Math.PI && ((n3 = 0), (i3 = 2 * Math.PI)), this.path.push({ type: 'arc', x: t3, y: e3, radius: r3, startAngle: n3, endAngle: i3, counterclockwise: o3, }) }), (p2.prototype.arcTo = function (t3, e3, r3, n3, i3) { throw new Error('arcTo not implemented.') }), (p2.prototype.rect = function (t3, e3, r3, n3) { if (isNaN(t3) || isNaN(e3) || isNaN(r3) || isNaN(n3)) throw ( (a$2.error('jsPDF.context2d.rect: Invalid arguments', arguments), new Error('Invalid arguments passed to jsPDF.context2d.rect')) ) this.moveTo(t3, e3), this.lineTo(t3 + r3, e3), this.lineTo(t3 + r3, e3 + n3), this.lineTo(t3, e3 + n3), this.lineTo(t3, e3), this.lineTo(t3 + r3, e3), this.lineTo(t3, e3) }), (p2.prototype.fillRect = function (t3, e3, r3, n3) { if (isNaN(t3) || isNaN(e3) || isNaN(r3) || isNaN(n3)) throw ( (a$2.error('jsPDF.context2d.fillRect: Invalid arguments', arguments), new Error('Invalid arguments passed to jsPDF.context2d.fillRect')) ) if (!m2.call(this)) { var i3 = {} 'butt' !== this.lineCap && ((i3.lineCap = this.lineCap), (this.lineCap = 'butt')), 'miter' !== this.lineJoin && ((i3.lineJoin = this.lineJoin), (this.lineJoin = 'miter')), this.beginPath(), this.rect(t3, e3, r3, n3), this.fill(), i3.hasOwnProperty('lineCap') && (this.lineCap = i3.lineCap), i3.hasOwnProperty('lineJoin') && (this.lineJoin = i3.lineJoin) } }), (p2.prototype.strokeRect = function (t3, e3, r3, n3) { if (isNaN(t3) || isNaN(e3) || isNaN(r3) || isNaN(n3)) throw ( (a$2.error( 'jsPDF.context2d.strokeRect: Invalid arguments', arguments ), new Error('Invalid arguments passed to jsPDF.context2d.strokeRect')) ) v4.call(this) || (this.beginPath(), this.rect(t3, e3, r3, n3), this.stroke()) }), (p2.prototype.clearRect = function (t3, e3, r3, n3) { if (isNaN(t3) || isNaN(e3) || isNaN(r3) || isNaN(n3)) throw ( (a$2.error('jsPDF.context2d.clearRect: Invalid arguments', arguments), new Error('Invalid arguments passed to jsPDF.context2d.clearRect')) ) this.ignoreClearRect || ((this.fillStyle = '#ffffff'), this.fillRect(t3, e3, r3, n3)) }), (p2.prototype.save = function (t3) { t3 = 'boolean' != typeof t3 || t3 for ( var e3 = this.pdf.internal.getCurrentPageInfo().pageNumber, r3 = 0; r3 < this.pdf.internal.getNumberOfPages(); r3++ ) this.pdf.setPage(r3 + 1), this.pdf.internal.out('q') if ((this.pdf.setPage(e3), t3)) { this.ctx.fontSize = this.pdf.internal.getFontSize() var n3 = new d3(this.ctx) this.ctxStack.push(this.ctx), (this.ctx = n3) } }), (p2.prototype.restore = function (t3) { t3 = 'boolean' != typeof t3 || t3 for ( var e3 = this.pdf.internal.getCurrentPageInfo().pageNumber, r3 = 0; r3 < this.pdf.internal.getNumberOfPages(); r3++ ) this.pdf.setPage(r3 + 1), this.pdf.internal.out('Q') this.pdf.setPage(e3), t3 && 0 !== this.ctxStack.length && ((this.ctx = this.ctxStack.pop()), (this.fillStyle = this.ctx.fillStyle), (this.strokeStyle = this.ctx.strokeStyle), (this.font = this.ctx.font), (this.lineCap = this.ctx.lineCap), (this.lineWidth = this.ctx.lineWidth), (this.lineJoin = this.ctx.lineJoin), (this.lineDash = this.ctx.lineDash), (this.lineDashOffset = this.ctx.lineDashOffset)) }), (p2.prototype.toDataURL = function () { throw new Error('toDataUrl not implemented.') }) var g2 = function (t3) { var e3, r3, n3, i3 if ((true === t3.isCanvasGradient && (t3 = t3.getColor()), !t3)) return { r: 0, g: 0, b: 0, a: 0, style: t3 } if ( /transparent|rgba\s*\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*,\s*0+\s*\)/.test( t3 ) ) (e3 = 0), (r3 = 0), (n3 = 0), (i3 = 0) else { var a2 = /rgb\s*\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*\)/.exec(t3) if (null !== a2) (e3 = parseInt(a2[1])), (r3 = parseInt(a2[2])), (n3 = parseInt(a2[3])), (i3 = 1) else if ( null !== (a2 = /rgba\s*\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*,\s*([\d.]+)\s*\)/.exec( t3 )) ) (e3 = parseInt(a2[1])), (r3 = parseInt(a2[2])), (n3 = parseInt(a2[3])), (i3 = parseFloat(a2[4])) else { if (((i3 = 1), 'string' == typeof t3 && '#' !== t3.charAt(0))) { var o3 = new f$2(t3) t3 = o3.ok ? o3.toHex() : '#000000' } 4 === t3.length ? ((e3 = t3.substring(1, 2)), (e3 += e3), (r3 = t3.substring(2, 3)), (r3 += r3), (n3 = t3.substring(3, 4)), (n3 += n3)) : ((e3 = t3.substring(1, 3)), (r3 = t3.substring(3, 5)), (n3 = t3.substring(5, 7))), (e3 = parseInt(e3, 16)), (r3 = parseInt(r3, 16)), (n3 = parseInt(n3, 16)) } } return { r: e3, g: r3, b: n3, a: i3, style: t3 } }, m2 = function () { return this.ctx.isFillTransparent || 0 == this.globalAlpha }, v4 = function () { return Boolean(this.ctx.isStrokeTransparent || 0 == this.globalAlpha) } ;(p2.prototype.fillText = function (t3, e3, r3, n3) { if (isNaN(e3) || isNaN(r3) || 'string' != typeof t3) throw ( (a$2.error('jsPDF.context2d.fillText: Invalid arguments', arguments), new Error('Invalid arguments passed to jsPDF.context2d.fillText')) ) if (((n3 = isNaN(n3) ? void 0 : n3), !m2.call(this))) { var i3 = q2(this.ctx.transform.rotation), o3 = this.ctx.transform.scaleX C2.call(this, { text: t3, x: e3, y: r3, scale: o3, angle: i3, align: this.textAlign, maxWidth: n3, }) } }), (p2.prototype.strokeText = function (t3, e3, r3, n3) { if (isNaN(e3) || isNaN(r3) || 'string' != typeof t3) throw ( (a$2.error( 'jsPDF.context2d.strokeText: Invalid arguments', arguments ), new Error('Invalid arguments passed to jsPDF.context2d.strokeText')) ) if (!v4.call(this)) { n3 = isNaN(n3) ? void 0 : n3 var i3 = q2(this.ctx.transform.rotation), o3 = this.ctx.transform.scaleX C2.call(this, { text: t3, x: e3, y: r3, scale: o3, renderingMode: 'stroke', angle: i3, align: this.textAlign, maxWidth: n3, }) } }), (p2.prototype.measureText = function (t3) { if ('string' != typeof t3) throw ( (a$2.error( 'jsPDF.context2d.measureText: Invalid arguments', arguments ), new Error('Invalid arguments passed to jsPDF.context2d.measureText')) ) var e3 = this.pdf, r3 = this.pdf.internal.scaleFactor, n3 = e3.internal.getFontSize(), i3 = (e3.getStringUnitWidth(t3) * n3) / e3.internal.scaleFactor, o3 = function (t4) { var e4 = (t4 = t4 || {}).width || 0 return ( Object.defineProperty(this, 'width', { get: function () { return e4 }, }), this ) } return new o3({ width: (i3 *= Math.round(((96 * r3) / 72) * 1e4) / 1e4) }) }), (p2.prototype.scale = function (t3, e3) { if (isNaN(t3) || isNaN(e3)) throw ( (a$2.error('jsPDF.context2d.scale: Invalid arguments', arguments), new Error('Invalid arguments passed to jsPDF.context2d.scale')) ) var r3 = new h2(t3, 0, 0, e3, 0, 0) this.ctx.transform = this.ctx.transform.multiply(r3) }), (p2.prototype.rotate = function (t3) { if (isNaN(t3)) throw ( (a$2.error('jsPDF.context2d.rotate: Invalid arguments', arguments), new Error('Invalid arguments passed to jsPDF.context2d.rotate')) ) var e3 = new h2( Math.cos(t3), Math.sin(t3), -Math.sin(t3), Math.cos(t3), 0, 0 ) this.ctx.transform = this.ctx.transform.multiply(e3) }), (p2.prototype.translate = function (t3, e3) { if (isNaN(t3) || isNaN(e3)) throw ( (a$2.error('jsPDF.context2d.translate: Invalid arguments', arguments), new Error('Invalid arguments passed to jsPDF.context2d.translate')) ) var r3 = new h2(1, 0, 0, 1, t3, e3) this.ctx.transform = this.ctx.transform.multiply(r3) }), (p2.prototype.transform = function (t3, e3, r3, n3, i3, o3) { if ( isNaN(t3) || isNaN(e3) || isNaN(r3) || isNaN(n3) || isNaN(i3) || isNaN(o3) ) throw ( (a$2.error('jsPDF.context2d.transform: Invalid arguments', arguments), new Error('Invalid arguments passed to jsPDF.context2d.transform')) ) var s3 = new h2(t3, e3, r3, n3, i3, o3) this.ctx.transform = this.ctx.transform.multiply(s3) }), (p2.prototype.setTransform = function (t3, e3, r3, n3, i3, a2) { ;(t3 = isNaN(t3) ? 1 : t3), (e3 = isNaN(e3) ? 0 : e3), (r3 = isNaN(r3) ? 0 : r3), (n3 = isNaN(n3) ? 1 : n3), (i3 = isNaN(i3) ? 0 : i3), (a2 = isNaN(a2) ? 0 : a2), (this.ctx.transform = new h2(t3, e3, r3, n3, i3, a2)) }) var b2 = function () { return ( this.margin[0] > 0 || this.margin[1] > 0 || this.margin[2] > 0 || this.margin[3] > 0 ) } p2.prototype.drawImage = function (t3, e3, r3, n3, i3, a2, o3, s3, c3) { var l3 = this.pdf.getImageProperties(t3), f2 = 1, d4 = 1, p3 = 1, g3 = 1 void 0 !== n3 && void 0 !== s3 && ((p3 = s3 / n3), (g3 = c3 / i3), (f2 = ((l3.width / n3) * s3) / n3), (d4 = ((l3.height / i3) * c3) / i3)), void 0 === a2 && ((a2 = e3), (o3 = r3), (e3 = 0), (r3 = 0)), void 0 !== n3 && void 0 === s3 && ((s3 = n3), (c3 = i3)), void 0 === n3 && void 0 === s3 && ((s3 = l3.width), (c3 = l3.height)) for ( var m3, v5 = this.ctx.transform.decompose(), w3 = q2(v5.rotate.shx), A3 = new h2(), S3 = (A3 = (A3 = (A3 = A3.multiply(v5.translate)).multiply( v5.skew )).multiply(v5.scale)).applyToRectangle( new u2(a2 - e3 * p3, o3 - r3 * g3, n3 * f2, i3 * d4) ), _3 = y2.call(this, S3), P3 = [], k3 = 0; k3 < _3.length; k3 += 1 ) -1 === P3.indexOf(_3[k3]) && P3.push(_3[k3]) if ((L2(P3), this.autoPaging)) for (var I3 = P3[0], F3 = P3[P3.length - 1], C3 = I3; C3 < F3 + 1; C3++) { this.pdf.setPage(C3) var j3 = this.pdf.internal.pageSize.width - this.margin[3] - this.margin[1], O3 = 1 === C3 ? this.posY + this.margin[0] : this.margin[0], B4 = this.pdf.internal.pageSize.height - this.posY - this.margin[0] - this.margin[2], M3 = this.pdf.internal.pageSize.height - this.margin[0] - this.margin[2], E3 = 1 === C3 ? 0 : B4 + (C3 - 2) * M3 if (0 !== this.ctx.clip_path.length) { var D3 = this.path ;(m3 = JSON.parse(JSON.stringify(this.ctx.clip_path))), (this.path = N2( m3, this.posX + this.margin[3], -E3 + O3 + this.ctx.prevPageLastElemOffset )), x2.call(this, 'fill', true), (this.path = D3) } var R3 = JSON.parse(JSON.stringify(S3)) R3 = N2( [R3], this.posX + this.margin[3], -E3 + O3 + this.ctx.prevPageLastElemOffset )[0] var T3 = (C3 > I3 || C3 < F3) && b2.call(this) T3 && (this.pdf.saveGraphicsState(), this.pdf .rect(this.margin[3], this.margin[0], j3, M3, null) .clip() .discardPath()), this.pdf.addImage(t3, 'JPEG', R3.x, R3.y, R3.w, R3.h, null, null, w3), T3 && this.pdf.restoreGraphicsState() } else this.pdf.addImage(t3, 'JPEG', S3.x, S3.y, S3.w, S3.h, null, null, w3) } var y2 = function (t3, e3, r3) { var n3 = [] ;(e3 = e3 || this.pdf.internal.pageSize.width), (r3 = r3 || this.pdf.internal.pageSize.height - this.margin[0] - this.margin[2]) var i3 = this.posY + this.ctx.prevPageLastElemOffset switch (t3.type) { default: case 'mt': case 'lt': n3.push(Math.floor((t3.y + i3) / r3) + 1) break case 'arc': n3.push(Math.floor((t3.y + i3 - t3.radius) / r3) + 1), n3.push(Math.floor((t3.y + i3 + t3.radius) / r3) + 1) break case 'qct': var a2 = D2( this.ctx.lastPoint.x, this.ctx.lastPoint.y, t3.x1, t3.y1, t3.x, t3.y ) n3.push(Math.floor((a2.y + i3) / r3) + 1), n3.push(Math.floor((a2.y + a2.h + i3) / r3) + 1) break case 'bct': var o3 = R2( this.ctx.lastPoint.x, this.ctx.lastPoint.y, t3.x1, t3.y1, t3.x2, t3.y2, t3.x, t3.y ) n3.push(Math.floor((o3.y + i3) / r3) + 1), n3.push(Math.floor((o3.y + o3.h + i3) / r3) + 1) break case 'rect': n3.push(Math.floor((t3.y + i3) / r3) + 1), n3.push(Math.floor((t3.y + t3.h + i3) / r3) + 1) } for (var s3 = 0; s3 < n3.length; s3 += 1) for (; this.pdf.internal.getNumberOfPages() < n3[s3]; ) w2.call(this) return n3 }, w2 = function () { var t3 = this.fillStyle, e3 = this.strokeStyle, r3 = this.font, n3 = this.lineCap, i3 = this.lineWidth, a2 = this.lineJoin this.pdf.addPage(), (this.fillStyle = t3), (this.strokeStyle = e3), (this.font = r3), (this.lineCap = n3), (this.lineWidth = i3), (this.lineJoin = a2) }, N2 = function (t3, e3, r3) { for (var n3 = 0; n3 < t3.length; n3++) switch (t3[n3].type) { case 'bct': ;(t3[n3].x2 += e3), (t3[n3].y2 += r3) case 'qct': ;(t3[n3].x1 += e3), (t3[n3].y1 += r3) case 'mt': case 'lt': case 'arc': default: ;(t3[n3].x += e3), (t3[n3].y += r3) } return t3 }, L2 = function (t3) { return t3.sort(function (t4, e3) { return t4 - e3 }) }, A2 = function (t3, e3) { for ( var r3, n3, i3 = this.fillStyle, a2 = this.strokeStyle, o3 = this.lineCap, s3 = this.lineWidth, c3 = Math.abs(s3 * this.ctx.transform.scaleX), u3 = this.lineJoin, h3 = JSON.parse(JSON.stringify(this.path)), l3 = JSON.parse(JSON.stringify(this.path)), f2 = [], d4 = 0; d4 < l3.length; d4++ ) if (void 0 !== l3[d4].x) for (var p3 = y2.call(this, l3[d4]), g3 = 0; g3 < p3.length; g3 += 1) -1 === f2.indexOf(p3[g3]) && f2.push(p3[g3]) for (var m3 = 0; m3 < f2.length; m3++) for (; this.pdf.internal.getNumberOfPages() < f2[m3]; ) w2.call(this) if ((L2(f2), this.autoPaging)) for ( var v5 = f2[0], A3 = f2[f2.length - 1], S3 = v5; S3 < A3 + 1; S3++ ) { this.pdf.setPage(S3), (this.fillStyle = i3), (this.strokeStyle = a2), (this.lineCap = o3), (this.lineWidth = c3), (this.lineJoin = u3) var _3 = this.pdf.internal.pageSize.width - this.margin[3] - this.margin[1], P3 = 1 === S3 ? this.posY + this.margin[0] : this.margin[0], k3 = this.pdf.internal.pageSize.height - this.posY - this.margin[0] - this.margin[2], I3 = this.pdf.internal.pageSize.height - this.margin[0] - this.margin[2], F3 = 1 === S3 ? 0 : k3 + (S3 - 2) * I3 if (0 !== this.ctx.clip_path.length) { var C3 = this.path ;(r3 = JSON.parse(JSON.stringify(this.ctx.clip_path))), (this.path = N2( r3, this.posX + this.margin[3], -F3 + P3 + this.ctx.prevPageLastElemOffset )), x2.call(this, t3, true), (this.path = C3) } if ( ((n3 = JSON.parse(JSON.stringify(h3))), (this.path = N2( n3, this.posX + this.margin[3], -F3 + P3 + this.ctx.prevPageLastElemOffset )), false === e3 || 0 === S3) ) { var j3 = (S3 > v5 || S3 < A3) && b2.call(this) j3 && (this.pdf.saveGraphicsState(), this.pdf .rect(this.margin[3], this.margin[0], _3, I3, null) .clip() .discardPath()), x2.call(this, t3, e3), j3 && this.pdf.restoreGraphicsState() } this.lineWidth = s3 } else (this.lineWidth = c3), x2.call(this, t3, e3), (this.lineWidth = s3) this.path = h3 }, x2 = function (t3, e3) { if ( ('stroke' !== t3 || e3 || !v4.call(this)) && ('stroke' === t3 || e3 || !m2.call(this)) ) { for ( var r3, n3, i3 = [], a2 = this.path, o3 = 0; o3 < a2.length; o3++ ) { var s3 = a2[o3] switch (s3.type) { case 'begin': i3.push({ begin: true }) break case 'close': i3.push({ close: true }) break case 'mt': i3.push({ start: s3, deltas: [], abs: [] }) break case 'lt': var c3 = i3.length if ( a2[o3 - 1] && !isNaN(a2[o3 - 1].x) && ((r3 = [s3.x - a2[o3 - 1].x, s3.y - a2[o3 - 1].y]), c3 > 0) ) { for (; c3 >= 0; c3--) if (true !== i3[c3 - 1].close && true !== i3[c3 - 1].begin) { i3[c3 - 1].deltas.push(r3), i3[c3 - 1].abs.push(s3) break } } break case 'bct': ;(r3 = [ s3.x1 - a2[o3 - 1].x, s3.y1 - a2[o3 - 1].y, s3.x2 - a2[o3 - 1].x, s3.y2 - a2[o3 - 1].y, s3.x - a2[o3 - 1].x, s3.y - a2[o3 - 1].y, ]), i3[i3.length - 1].deltas.push(r3) break case 'qct': var u3 = a2[o3 - 1].x + (2 / 3) * (s3.x1 - a2[o3 - 1].x), h3 = a2[o3 - 1].y + (2 / 3) * (s3.y1 - a2[o3 - 1].y), l3 = s3.x + (2 / 3) * (s3.x1 - s3.x), f2 = s3.y + (2 / 3) * (s3.y1 - s3.y), d4 = s3.x, p3 = s3.y ;(r3 = [ u3 - a2[o3 - 1].x, h3 - a2[o3 - 1].y, l3 - a2[o3 - 1].x, f2 - a2[o3 - 1].y, d4 - a2[o3 - 1].x, p3 - a2[o3 - 1].y, ]), i3[i3.length - 1].deltas.push(r3) break case 'arc': i3.push({ deltas: [], abs: [], arc: true }), Array.isArray(i3[i3.length - 1].abs) && i3[i3.length - 1].abs.push(s3) } } n3 = e3 ? null : 'stroke' === t3 ? 'stroke' : 'fill' for (var g3 = false, b3 = 0; b3 < i3.length; b3++) if (i3[b3].arc) for (var y3 = i3[b3].abs, w3 = 0; w3 < y3.length; w3++) { var N3 = y3[w3] 'arc' === N3.type ? P2.call( this, N3.x, N3.y, N3.radius, N3.startAngle, N3.endAngle, N3.counterclockwise, void 0, e3, !g3 ) : j2.call(this, N3.x, N3.y), (g3 = true) } else if (true === i3[b3].close) this.pdf.internal.out('h'), (g3 = false) else if (true !== i3[b3].begin) { var L3 = i3[b3].start.x, A3 = i3[b3].start.y O2.call(this, i3[b3].deltas, L3, A3), (g3 = true) } n3 && k2.call(this, n3), e3 && I2.call(this) } }, S2 = function (t3) { var e3 = this.pdf.internal.getFontSize() / this.pdf.internal.scaleFactor, r3 = e3 * (this.pdf.internal.getLineHeightFactor() - 1) switch (this.ctx.textBaseline) { case 'bottom': return t3 - r3 case 'top': return t3 + e3 - r3 case 'hanging': return t3 + e3 - 2 * r3 case 'middle': return t3 + e3 / 2 - r3 case 'ideographic': return t3 case 'alphabetic': default: return t3 } }, _2 = function (t3) { return ( t3 + (this.pdf.internal.getFontSize() / this.pdf.internal.scaleFactor) * (this.pdf.internal.getLineHeightFactor() - 1) ) } ;(p2.prototype.createLinearGradient = function () { var t3 = function () {} return ( (t3.colorStops = []), (t3.addColorStop = function (t4, e3) { this.colorStops.push([t4, e3]) }), (t3.getColor = function () { return 0 === this.colorStops.length ? '#000000' : this.colorStops[0][1] }), (t3.isCanvasGradient = true), t3 ) }), (p2.prototype.createPattern = function () { return this.createLinearGradient() }), (p2.prototype.createRadialGradient = function () { return this.createLinearGradient() }) var P2 = function (t3, e3, r3, n3, i3, a2, o3, s3, c3) { for ( var u3 = M2.call(this, r3, n3, i3, a2), h3 = 0; h3 < u3.length; h3++ ) { var l3 = u3[h3] 0 === h3 && (c3 ? F2.call(this, l3.x1 + t3, l3.y1 + e3) : j2.call(this, l3.x1 + t3, l3.y1 + e3)), B3.call(this, t3, e3, l3.x2, l3.y2, l3.x3, l3.y3, l3.x4, l3.y4) } s3 ? I2.call(this) : k2.call(this, o3) }, k2 = function (t3) { switch (t3) { case 'stroke': this.pdf.internal.out('S') break case 'fill': this.pdf.internal.out('f') } }, I2 = function () { this.pdf.clip(), this.pdf.discardPath() }, F2 = function (t3, e3) { this.pdf.internal.out(n2(t3) + ' ' + i2(e3) + ' m') }, C2 = function (t3) { var e3 switch (t3.align) { case 'right': case 'end': e3 = 'right' break case 'center': e3 = 'center' break case 'left': case 'start': default: e3 = 'left' } var r3 = this.pdf.getTextDimensions(t3.text), n3 = S2.call(this, t3.y), i3 = _2.call(this, n3) - r3.h, a2 = this.ctx.transform.applyToPoint(new c2(t3.x, n3)), o3 = this.ctx.transform.decompose(), s3 = new h2() s3 = (s3 = (s3 = s3.multiply(o3.translate)).multiply(o3.skew)).multiply( o3.scale ) for ( var l3, f2, d4, p3 = this.ctx.transform.applyToRectangle( new u2(t3.x, n3, r3.w, r3.h) ), g3 = s3.applyToRectangle(new u2(t3.x, i3, r3.w, r3.h)), m3 = y2.call(this, g3), v5 = [], w3 = 0; w3 < m3.length; w3 += 1 ) -1 === v5.indexOf(m3[w3]) && v5.push(m3[w3]) if ((L2(v5), this.autoPaging)) for ( var A3 = v5[0], P3 = v5[v5.length - 1], k3 = A3; k3 < P3 + 1; k3++ ) { this.pdf.setPage(k3) var I3 = 1 === k3 ? this.posY + this.margin[0] : this.margin[0], F3 = this.pdf.internal.pageSize.height - this.posY - this.margin[0] - this.margin[2], C3 = this.pdf.internal.pageSize.height - this.margin[2], j3 = C3 - this.margin[0], O3 = this.pdf.internal.pageSize.width - this.margin[1], B4 = O3 - this.margin[3], M3 = 1 === k3 ? 0 : F3 + (k3 - 2) * j3 if (0 !== this.ctx.clip_path.length) { var E3 = this.path ;(l3 = JSON.parse(JSON.stringify(this.ctx.clip_path))), (this.path = N2(l3, this.posX + this.margin[3], -1 * M3 + I3)), x2.call(this, 'fill', true), (this.path = E3) } var q3 = N2( [JSON.parse(JSON.stringify(g3))], this.posX + this.margin[3], -M3 + I3 + this.ctx.prevPageLastElemOffset )[0] t3.scale >= 0.01 && ((f2 = this.pdf.internal.getFontSize()), this.pdf.setFontSize(f2 * t3.scale), (d4 = this.lineWidth), (this.lineWidth = d4 * t3.scale)) var D3 = 'text' !== this.autoPaging if (D3 || q3.y + q3.h <= C3) { if (D3 || (q3.y >= I3 && q3.x <= O3)) { var R3 = D3 ? t3.text : this.pdf.splitTextToSize( t3.text, t3.maxWidth || O3 - q3.x )[0], T3 = N2( [JSON.parse(JSON.stringify(p3))], this.posX + this.margin[3], -M3 + I3 + this.ctx.prevPageLastElemOffset )[0], U2 = D3 && (k3 > A3 || k3 < P3) && b2.call(this) U2 && (this.pdf.saveGraphicsState(), this.pdf .rect(this.margin[3], this.margin[0], B4, j3, null) .clip() .discardPath()), this.pdf.text(R3, T3.x, T3.y, { angle: t3.angle, align: e3, renderingMode: t3.renderingMode, }), U2 && this.pdf.restoreGraphicsState() } } else q3.y < C3 && (this.ctx.prevPageLastElemOffset += C3 - q3.y) t3.scale >= 0.01 && (this.pdf.setFontSize(f2), (this.lineWidth = d4)) } else t3.scale >= 0.01 && ((f2 = this.pdf.internal.getFontSize()), this.pdf.setFontSize(f2 * t3.scale), (d4 = this.lineWidth), (this.lineWidth = d4 * t3.scale)), this.pdf.text(t3.text, a2.x + this.posX, a2.y + this.posY, { angle: t3.angle, align: e3, renderingMode: t3.renderingMode, maxWidth: t3.maxWidth, }), t3.scale >= 0.01 && (this.pdf.setFontSize(f2), (this.lineWidth = d4)) }, j2 = function (t3, e3, r3, a2) { ;(r3 = r3 || 0), (a2 = a2 || 0), this.pdf.internal.out(n2(t3 + r3) + ' ' + i2(e3 + a2) + ' l') }, O2 = function (t3, e3, r3) { return this.pdf.lines(t3, e3, r3, null, null) }, B3 = function (t3, e3, n3, i3, a2, c3, u3, h3) { this.pdf.internal.out( [ r2(o2(n3 + t3)), r2(s2(i3 + e3)), r2(o2(a2 + t3)), r2(s2(c3 + e3)), r2(o2(u3 + t3)), r2(s2(h3 + e3)), 'c', ].join(' ') ) }, M2 = function (t3, e3, r3, n3) { for (var i3 = 2 * Math.PI, a2 = Math.PI / 2; e3 > r3; ) e3 -= i3 var o3 = Math.abs(r3 - e3) o3 < i3 && n3 && (o3 = i3 - o3) for (var s3 = [], c3 = n3 ? -1 : 1, u3 = e3; o3 > 1e-5; ) { var h3 = u3 + c3 * Math.min(o3, a2) s3.push(E2.call(this, t3, u3, h3)), (o3 -= Math.abs(h3 - u3)), (u3 = h3) } return s3 }, E2 = function (t3, e3, r3) { var n3 = (r3 - e3) / 2, i3 = t3 * Math.cos(n3), a2 = t3 * Math.sin(n3), o3 = i3, s3 = -a2, c3 = o3 * o3 + s3 * s3, u3 = c3 + o3 * i3 + s3 * a2, h3 = ((4 / 3) * (Math.sqrt(2 * c3 * u3) - u3)) / (o3 * a2 - s3 * i3), l3 = o3 - h3 * s3, f2 = s3 + h3 * o3, d4 = l3, p3 = -f2, g3 = n3 + e3, m3 = Math.cos(g3), v5 = Math.sin(g3) return { x1: t3 * Math.cos(e3), y1: t3 * Math.sin(e3), x2: l3 * m3 - f2 * v5, y2: l3 * v5 + f2 * m3, x3: d4 * m3 - p3 * v5, y3: d4 * v5 + p3 * m3, x4: t3 * Math.cos(r3), y4: t3 * Math.sin(r3), } }, q2 = function (t3) { return (180 * t3) / Math.PI }, D2 = function (t3, e3, r3, n3, i3, a2) { var o3 = t3 + 0.5 * (r3 - t3), s3 = e3 + 0.5 * (n3 - e3), c3 = i3 + 0.5 * (r3 - i3), h3 = a2 + 0.5 * (n3 - a2), l3 = Math.min(t3, i3, o3, c3), f2 = Math.max(t3, i3, o3, c3), d4 = Math.min(e3, a2, s3, h3), p3 = Math.max(e3, a2, s3, h3) return new u2(l3, d4, f2 - l3, p3 - d4) }, R2 = function (t3, e3, r3, n3, i3, a2, o3, s3) { var c3, h3, l3, f2, d4, p3, g3, m3, v5, b3, y3, w3, N3, L3, A3 = r3 - t3, x3 = n3 - e3, S3 = i3 - r3, _3 = a2 - n3, P3 = o3 - i3, k3 = s3 - a2 for (h3 = 0; h3 < 41; h3++) (v5 = (g3 = (l3 = t3 + (c3 = h3 / 40) * A3) + c3 * ((d4 = r3 + c3 * S3) - l3)) + c3 * (d4 + c3 * (i3 + c3 * P3 - d4) - g3)), (b3 = (m3 = (f2 = e3 + c3 * x3) + c3 * ((p3 = n3 + c3 * _3) - f2)) + c3 * (p3 + c3 * (a2 + c3 * k3 - p3) - m3)), 0 == h3 ? ((y3 = v5), (w3 = b3), (N3 = v5), (L3 = b3)) : ((y3 = Math.min(y3, v5)), (w3 = Math.min(w3, b3)), (N3 = Math.max(N3, v5)), (L3 = Math.max(L3, b3))) return new u2( Math.round(y3), Math.round(w3), Math.round(N3 - y3), Math.round(L3 - w3) ) }, T2 = function () { if ( this.prevLineDash || this.ctx.lineDash.length || this.ctx.lineDashOffset ) { var t3, e3, r3 = ((t3 = this.ctx.lineDash), (e3 = this.ctx.lineDashOffset), JSON.stringify({ lineDash: t3, lineDashOffset: e3 })) this.prevLineDash !== r3 && (this.pdf.setLineDash(this.ctx.lineDash, this.ctx.lineDashOffset), (this.prevLineDash = r3)) } } })(E$1.API), (function (t3) { var r2 = function (t4) { var e2, r3, n3, i3, a3, o2, s2, c2, u2, h2 for ( /[^\x00-\xFF]/.test(t4), r3 = [], n3 = 0, i3 = (t4 += e2 = '\0\0\0\0'.slice(t4.length % 4 || 4)).length; i3 > n3; n3 += 4 ) 0 !== (a3 = (t4.charCodeAt(n3) << 24) + (t4.charCodeAt(n3 + 1) << 16) + (t4.charCodeAt(n3 + 2) << 8) + t4.charCodeAt(n3 + 3)) ? ((o2 = (a3 = ((a3 = ((a3 = ((a3 = (a3 - (h2 = a3 % 85)) / 85) - (u2 = a3 % 85)) / 85) - (c2 = a3 % 85)) / 85) - (s2 = a3 % 85)) / 85) % 85), r3.push(o2 + 33, s2 + 33, c2 + 33, u2 + 33, h2 + 33)) : r3.push(122) return ( (function (t5, e3) { for (var r4 = e3; r4 > 0; r4--) t5.pop() })(r3, e2.length), String.fromCharCode.apply(String, r3) + '~>' ) }, n2 = function (t4) { var e2, r3, n3, i3, a3, o2 = String, s2 = 'length', c2 = 255, u2 = 'charCodeAt', h2 = 'slice', l2 = 'replace' for ( t4[h2](-2), t4 = t4[h2](0, -2)[l2](/\s/g, '')[l2]('z', '!!!!!'), n3 = [], i3 = 0, a3 = (t4 += e2 = 'uuuuu'[h2](t4[s2] % 5 || 5))[s2]; a3 > i3; i3 += 5 ) (r3 = 52200625 * (t4[u2](i3) - 33) + 614125 * (t4[u2](i3 + 1) - 33) + 7225 * (t4[u2](i3 + 2) - 33) + 85 * (t4[u2](i3 + 3) - 33) + (t4[u2](i3 + 4) - 33)), n3.push(c2 & (r3 >> 24), c2 & (r3 >> 16), c2 & (r3 >> 8), c2 & r3) return ( (function (t5, e3) { for (var r4 = e3; r4 > 0; r4--) t5.pop() })(n3, e2[s2]), o2.fromCharCode.apply(o2, n3) ) }, i2 = function (t4) { var e2 = new RegExp(/^([0-9A-Fa-f]{2})+$/) if ( (-1 !== (t4 = t4.replace(/\s/g, '')).indexOf('>') && (t4 = t4.substr(0, t4.indexOf('>'))), t4.length % 2 && (t4 += '0'), false === e2.test(t4)) ) return '' for (var r3 = '', n3 = 0; n3 < t4.length; n3 += 2) r3 += String.fromCharCode('0x' + (t4[n3] + t4[n3 + 1])) return r3 }, a2 = function (t4) { for (var r3 = new Uint8Array(t4.length), n3 = t4.length; n3--; ) r3[n3] = t4.charCodeAt(n3) return (t4 = (r3 = zlibSync(r3)).reduce(function (t5, e2) { return t5 + String.fromCharCode(e2) }, '')) } t3.processDataByFilters = function (t4, e2) { var o2 = 0, s2 = t4 || '', c2 = [] for ( 'string' == typeof (e2 = e2 || []) && (e2 = [e2]), o2 = 0; o2 < e2.length; o2 += 1 ) switch (e2[o2]) { case 'ASCII85Decode': case '/ASCII85Decode': ;(s2 = n2(s2)), c2.push('/ASCII85Encode') break case 'ASCII85Encode': case '/ASCII85Encode': ;(s2 = r2(s2)), c2.push('/ASCII85Decode') break case 'ASCIIHexDecode': case '/ASCIIHexDecode': ;(s2 = i2(s2)), c2.push('/ASCIIHexEncode') break case 'ASCIIHexEncode': case '/ASCIIHexEncode': ;(s2 = s2 .split('') .map(function (t5) { return ('0' + t5.charCodeAt().toString(16)).slice(-2) }) .join('') + '>'), c2.push('/ASCIIHexDecode') break case 'FlateEncode': case '/FlateEncode': ;(s2 = a2(s2)), c2.push('/FlateDecode') break default: throw new Error('The filter: "' + e2[o2] + '" is not implemented') } return { data: s2, reverseChain: c2.reverse().join(' ') } } })(E$1.API), (function (t3) { ;(t3.loadFile = function (t4, e2, r2) { return (function (t5, e3, r3) { ;(e3 = false !== e3), (r3 = 'function' == typeof r3 ? r3 : function () {}) var n2 = void 0 try { n2 = (function (t6, e4, r4) { var n3 = new XMLHttpRequest(), i2 = 0, a2 = function (t7) { var e5 = t7.length, r5 = [], n4 = String.fromCharCode for (i2 = 0; i2 < e5; i2 += 1) r5.push(n4(255 & t7.charCodeAt(i2))) return r5.join('') } if ( (n3.open('GET', t6, !e4), n3.overrideMimeType('text/plain; charset=x-user-defined'), false === e4 && (n3.onload = function () { 200 === n3.status ? r4(a2(this.responseText)) : r4(void 0) }), n3.send(null), e4 && 200 === n3.status) ) return a2(n3.responseText) })(t5, e3, r3) } catch (t6) {} return n2 })(t4, e2, r2) }), (t3.loadImageFile = t3.loadFile) })(E$1.API), (function (e2) { function r2() { return ( n$1.html2canvas ? Promise.resolve(n$1.html2canvas) : Promise.resolve().then(function () { return html2canvas_esm }) ) .catch(function (t3) { return Promise.reject(new Error('Could not load html2canvas: ' + t3)) }) .then(function (t3) { return t3.default ? t3.default : t3 }) } function i2() { return ( n$1.DOMPurify ? Promise.resolve(n$1.DOMPurify) : Promise.resolve().then(function () { return purify_es }) ) .catch(function (t3) { return Promise.reject(new Error('Could not load dompurify: ' + t3)) }) .then(function (t3) { return t3.default ? t3.default : t3 }) } var a2 = function (e3) { var r3 = _typeof$3(e3) return 'undefined' === r3 ? 'undefined' : 'string' === r3 || e3 instanceof String ? 'string' : 'number' === r3 || e3 instanceof Number ? 'number' : 'function' === r3 || e3 instanceof Function ? 'function' : e3 && e3.constructor === Array ? 'array' : e3 && 1 === e3.nodeType ? 'element' : 'object' === r3 ? 'object' : 'unknown' }, o2 = function (t3, e3) { var r3 = document.createElement(t3) for (var n2 in (e3.className && (r3.className = e3.className), e3.innerHTML && e3.dompurify && (r3.innerHTML = e3.dompurify.sanitize(e3.innerHTML)), e3.style)) r3.style[n2] = e3.style[n2] return r3 }, s2 = function t3(e3) { var r3 = Object.assign( t3.convert(Promise.resolve()), JSON.parse(JSON.stringify(t3.template)) ), n2 = t3.convert(Promise.resolve(), r3) return (n2 = (n2 = n2.setProgress(1, t3, 1, [t3])).set(e3)) } ;((s2.prototype = Object.create(Promise.prototype)).constructor = s2), (s2.convert = function (t3, e3) { return (t3.__proto__ = e3 || s2.prototype), t3 }), (s2.template = { prop: { src: null, container: null, overlay: null, canvas: null, img: null, pdf: null, pageSize: null, callback: function () {}, }, progress: { val: 0, state: null, n: 0, stack: [] }, opt: { filename: 'file.pdf', margin: [0, 0, 0, 0], enableLinks: true, x: 0, y: 0, html2canvas: {}, jsPDF: {}, backgroundColor: 'transparent', }, }), (s2.prototype.from = function (t3, e3) { return this.then(function () { switch ( (e3 = e3 || (function (t4) { switch (a2(t4)) { case 'string': return 'string' case 'element': return 'canvas' === t4.nodeName.toLowerCase() ? 'canvas' : 'element' default: return 'unknown' } })(t3)) ) { case 'string': return this.then(i2).then(function (e4) { return this.set({ src: o2('div', { innerHTML: t3, dompurify: e4 }), }) }) case 'element': return this.set({ src: t3 }) case 'canvas': return this.set({ canvas: t3 }) case 'img': return this.set({ img: t3 }) default: return this.error('Unknown source type.') } }) }), (s2.prototype.to = function (t3) { switch (t3) { case 'container': return this.toContainer() case 'canvas': return this.toCanvas() case 'img': return this.toImg() case 'pdf': return this.toPdf() default: return this.error('Invalid target.') } }), (s2.prototype.toContainer = function () { return this.thenList([ function () { return ( this.prop.src || this.error('Cannot duplicate - no source HTML.') ) }, function () { return this.prop.pageSize || this.setPageSize() }, ]).then(function () { var t3 = { position: 'relative', display: 'inline-block', width: ('number' != typeof this.opt.width || isNaN(this.opt.width) || 'number' != typeof this.opt.windowWidth || isNaN(this.opt.windowWidth) ? Math.max( this.prop.src.clientWidth, this.prop.src.scrollWidth, this.prop.src.offsetWidth ) : this.opt.windowWidth) + 'px', left: 0, right: 0, top: 0, margin: 'auto', backgroundColor: this.opt.backgroundColor, }, e3 = (function t4(e4, r3) { for ( var n2 = 3 === e4.nodeType ? document.createTextNode(e4.nodeValue) : e4.cloneNode(false), i3 = e4.firstChild; i3; i3 = i3.nextSibling ) (true !== r3 && 1 === i3.nodeType && 'SCRIPT' === i3.nodeName) || n2.appendChild(t4(i3, r3)) return ( 1 === e4.nodeType && ('CANVAS' === e4.nodeName ? ((n2.width = e4.width), (n2.height = e4.height), n2.getContext('2d').drawImage(e4, 0, 0)) : ('TEXTAREA' !== e4.nodeName && 'SELECT' !== e4.nodeName) || (n2.value = e4.value), n2.addEventListener( 'load', function () { ;(n2.scrollTop = e4.scrollTop), (n2.scrollLeft = e4.scrollLeft) }, true )), n2 ) })(this.prop.src, this.opt.html2canvas.javascriptEnabled) 'BODY' === e3.tagName && (t3.height = Math.max( document.body.scrollHeight, document.body.offsetHeight, document.documentElement.clientHeight, document.documentElement.scrollHeight, document.documentElement.offsetHeight ) + 'px'), (this.prop.overlay = o2('div', { className: 'html2pdf__overlay', style: { position: 'fixed', overflow: 'hidden', zIndex: 1e3, left: '-100000px', right: 0, bottom: 0, top: 0, }, })), (this.prop.container = o2('div', { className: 'html2pdf__container', style: t3, })), this.prop.container.appendChild(e3), this.prop.container.firstChild.appendChild( o2('div', { style: { clear: 'both', border: '0 none transparent', margin: 0, padding: 0, height: 0, }, }) ), (this.prop.container.style.float = 'none'), this.prop.overlay.appendChild(this.prop.container), document.body.appendChild(this.prop.overlay), (this.prop.container.firstChild.style.position = 'relative'), (this.prop.container.height = Math.max( this.prop.container.firstChild.clientHeight, this.prop.container.firstChild.scrollHeight, this.prop.container.firstChild.offsetHeight ) + 'px') }) }), (s2.prototype.toCanvas = function () { var t3 = [ function () { return ( document.body.contains(this.prop.container) || this.toContainer() ) }, ] return this.thenList(t3) .then(r2) .then(function (t4) { var e3 = Object.assign({}, this.opt.html2canvas) return delete e3.onrendered, t4(this.prop.container, e3) }) .then(function (t4) { ;(this.opt.html2canvas.onrendered || function () {})(t4), (this.prop.canvas = t4), document.body.removeChild(this.prop.overlay) }) }), (s2.prototype.toContext2d = function () { var t3 = [ function () { return ( document.body.contains(this.prop.container) || this.toContainer() ) }, ] return this.thenList(t3) .then(r2) .then(function (t4) { var e3 = this.opt.jsPDF, r3 = this.opt.fontFaces, n2 = 'number' != typeof this.opt.width || isNaN(this.opt.width) || 'number' != typeof this.opt.windowWidth || isNaN(this.opt.windowWidth) ? 1 : this.opt.width / this.opt.windowWidth, i3 = Object.assign( { async: true, allowTaint: true, scale: n2, scrollX: this.opt.scrollX || 0, scrollY: this.opt.scrollY || 0, backgroundColor: '#ffffff', imageTimeout: 15e3, logging: true, proxy: null, removeContainer: true, foreignObjectRendering: false, useCORS: false, }, this.opt.html2canvas ) if ( (delete i3.onrendered, (e3.context2d.autoPaging = void 0 === this.opt.autoPaging || this.opt.autoPaging), (e3.context2d.posX = this.opt.x), (e3.context2d.posY = this.opt.y), (e3.context2d.margin = this.opt.margin), (e3.context2d.fontFaces = r3), r3) ) for (var a3 = 0; a3 < r3.length; ++a3) { var o3 = r3[a3], s3 = o3.src.find(function (t5) { return 'truetype' === t5.format }) s3 && e3.addFont(s3.url, o3.ref.name, o3.ref.style) } return ( (i3.windowHeight = i3.windowHeight || 0), (i3.windowHeight = 0 == i3.windowHeight ? Math.max( this.prop.container.clientHeight, this.prop.container.scrollHeight, this.prop.container.offsetHeight ) : i3.windowHeight), e3.context2d.save(true), t4(this.prop.container, i3) ) }) .then(function (t4) { this.opt.jsPDF.context2d.restore(true), (this.opt.html2canvas.onrendered || function () {})(t4), (this.prop.canvas = t4), document.body.removeChild(this.prop.overlay) }) }), (s2.prototype.toImg = function () { return this.thenList([ function () { return this.prop.canvas || this.toCanvas() }, ]).then(function () { var t3 = this.prop.canvas.toDataURL( 'image/' + this.opt.image.type, this.opt.image.quality ) ;(this.prop.img = document.createElement('img')), (this.prop.img.src = t3) }) }), (s2.prototype.toPdf = function () { return this.thenList([ function () { return this.toContext2d() }, ]).then(function () { this.prop.pdf = this.prop.pdf || this.opt.jsPDF }) }), (s2.prototype.output = function (t3, e3, r3) { return 'img' === (r3 = r3 || 'pdf').toLowerCase() || 'image' === r3.toLowerCase() ? this.outputImg(t3, e3) : this.outputPdf(t3, e3) }), (s2.prototype.outputPdf = function (t3, e3) { return this.thenList([ function () { return this.prop.pdf || this.toPdf() }, ]).then(function () { return this.prop.pdf.output(t3, e3) }) }), (s2.prototype.outputImg = function (t3) { return this.thenList([ function () { return this.prop.img || this.toImg() }, ]).then(function () { switch (t3) { case void 0: case 'img': return this.prop.img case 'datauristring': case 'dataurlstring': return this.prop.img.src case 'datauri': case 'dataurl': return (document.location.href = this.prop.img.src) default: throw 'Image output type "' + t3 + '" is not supported.' } }) }), (s2.prototype.save = function (t3) { return this.thenList([ function () { return this.prop.pdf || this.toPdf() }, ]) .set(t3 ? { filename: t3 } : null) .then(function () { this.prop.pdf.save(this.opt.filename) }) }), (s2.prototype.doCallback = function () { return this.thenList([ function () { return this.prop.pdf || this.toPdf() }, ]).then(function () { this.prop.callback(this.prop.pdf) }) }), (s2.prototype.set = function (t3) { if ('object' !== a2(t3)) return this var e3 = Object.keys(t3 || {}).map(function (e4) { if (e4 in s2.template.prop) return function () { this.prop[e4] = t3[e4] } switch (e4) { case 'margin': return this.setMargin.bind(this, t3.margin) case 'jsPDF': return function () { return (this.opt.jsPDF = t3.jsPDF), this.setPageSize() } case 'pageSize': return this.setPageSize.bind(this, t3.pageSize) default: return function () { this.opt[e4] = t3[e4] } } }, this) return this.then(function () { return this.thenList(e3) }) }), (s2.prototype.get = function (t3, e3) { return this.then(function () { var r3 = t3 in s2.template.prop ? this.prop[t3] : this.opt[t3] return e3 ? e3(r3) : r3 }) }), (s2.prototype.setMargin = function (t3) { return this.then(function () { switch (a2(t3)) { case 'number': t3 = [t3, t3, t3, t3] case 'array': if ( (2 === t3.length && (t3 = [t3[0], t3[1], t3[0], t3[1]]), 4 === t3.length) ) break default: return this.error('Invalid margin array.') } this.opt.margin = t3 }).then(this.setPageSize) }), (s2.prototype.setPageSize = function (t3) { function e3(t4, e4) { return Math.floor(((t4 * e4) / 72) * 96) } return this.then(function () { ;(t3 = t3 || E$1.getPageSize(this.opt.jsPDF)).hasOwnProperty( 'inner' ) || ((t3.inner = { width: t3.width - this.opt.margin[1] - this.opt.margin[3], height: t3.height - this.opt.margin[0] - this.opt.margin[2], }), (t3.inner.px = { width: e3(t3.inner.width, t3.k), height: e3(t3.inner.height, t3.k), }), (t3.inner.ratio = t3.inner.height / t3.inner.width)), (this.prop.pageSize = t3) }) }), (s2.prototype.setProgress = function (t3, e3, r3, n2) { return ( null != t3 && (this.progress.val = t3), null != e3 && (this.progress.state = e3), null != r3 && (this.progress.n = r3), null != n2 && (this.progress.stack = n2), (this.progress.ratio = this.progress.val / this.progress.state), this ) }), (s2.prototype.updateProgress = function (t3, e3, r3, n2) { return this.setProgress( t3 ? this.progress.val + t3 : null, e3 || null, r3 ? this.progress.n + r3 : null, n2 ? this.progress.stack.concat(n2) : null ) }), (s2.prototype.then = function (t3, e3) { var r3 = this return this.thenCore(t3, e3, function (t4, e4) { return ( r3.updateProgress(null, null, 1, [t4]), Promise.prototype.then .call(this, function (e5) { return r3.updateProgress(null, t4), e5 }) .then(t4, e4) .then(function (t5) { return r3.updateProgress(1), t5 }) ) }) }), (s2.prototype.thenCore = function (t3, e3, r3) { r3 = r3 || Promise.prototype.then t3 && (t3 = t3.bind(this)), e3 && (e3 = e3.bind(this)) var n2 = -1 !== Promise.toString().indexOf('[native code]') && 'Promise' === Promise.name ? this : s2.convert(Object.assign({}, this), Promise.prototype), i3 = r3.call(n2, t3, e3) return s2.convert(i3, this.__proto__) }), (s2.prototype.thenExternal = function (t3, e3) { return Promise.prototype.then.call(this, t3, e3) }), (s2.prototype.thenList = function (t3) { var e3 = this return ( t3.forEach(function (t4) { e3 = e3.thenCore(t4) }), e3 ) }), (s2.prototype.catch = function (t3) { t3 && (t3 = t3.bind(this)) var e3 = Promise.prototype.catch.call(this, t3) return s2.convert(e3, this) }), (s2.prototype.catchExternal = function (t3) { return Promise.prototype.catch.call(this, t3) }), (s2.prototype.error = function (t3) { return this.then(function () { throw new Error(t3) }) }), (s2.prototype.using = s2.prototype.set), (s2.prototype.saveAs = s2.prototype.save), (s2.prototype.export = s2.prototype.output), (s2.prototype.run = s2.prototype.then), (E$1.getPageSize = function (e3, r3, n2) { if ('object' === _typeof$3(e3)) { var i3 = e3 ;(e3 = i3.orientation), (r3 = i3.unit || r3), (n2 = i3.format || n2) } ;(r3 = r3 || 'mm'), (n2 = n2 || 'a4'), (e3 = ('' + (e3 || 'P')).toLowerCase()) var a3, o3 = ('' + n2).toLowerCase(), s3 = { a0: [2383.94, 3370.39], a1: [1683.78, 2383.94], a2: [1190.55, 1683.78], a3: [841.89, 1190.55], a4: [595.28, 841.89], a5: [419.53, 595.28], a6: [297.64, 419.53], a7: [209.76, 297.64], a8: [147.4, 209.76], a9: [104.88, 147.4], a10: [73.7, 104.88], b0: [2834.65, 4008.19], b1: [2004.09, 2834.65], b2: [1417.32, 2004.09], b3: [1000.63, 1417.32], b4: [708.66, 1000.63], b5: [498.9, 708.66], b6: [354.33, 498.9], b7: [249.45, 354.33], b8: [175.75, 249.45], b9: [124.72, 175.75], b10: [87.87, 124.72], c0: [2599.37, 3676.54], c1: [1836.85, 2599.37], c2: [1298.27, 1836.85], c3: [918.43, 1298.27], c4: [649.13, 918.43], c5: [459.21, 649.13], c6: [323.15, 459.21], c7: [229.61, 323.15], c8: [161.57, 229.61], c9: [113.39, 161.57], c10: [79.37, 113.39], dl: [311.81, 623.62], letter: [612, 792], 'government-letter': [576, 756], legal: [612, 1008], 'junior-legal': [576, 360], ledger: [1224, 792], tabloid: [792, 1224], 'credit-card': [153, 243], } switch (r3) { case 'pt': a3 = 1 break case 'mm': a3 = 72 / 25.4 break case 'cm': a3 = 72 / 2.54 break case 'in': a3 = 72 break case 'px': a3 = 0.75 break case 'pc': case 'em': a3 = 12 break case 'ex': a3 = 6 break default: throw 'Invalid unit: ' + r3 } var c2, u2 = 0, h2 = 0 if (s3.hasOwnProperty(o3)) (u2 = s3[o3][1] / a3), (h2 = s3[o3][0] / a3) else try { ;(u2 = n2[1]), (h2 = n2[0]) } catch (t3) { throw new Error('Invalid format: ' + n2) } if ('p' === e3 || 'portrait' === e3) (e3 = 'p'), h2 > u2 && ((c2 = h2), (h2 = u2), (u2 = c2)) else { if ('l' !== e3 && 'landscape' !== e3) throw 'Invalid orientation: ' + e3 ;(e3 = 'l'), u2 > h2 && ((c2 = h2), (h2 = u2), (u2 = c2)) } return { width: h2, height: u2, unit: r3, k: a3, orientation: e3 } }), (e2.html = function (t3, e3) { ;((e3 = e3 || {}).callback = e3.callback || function () {}), (e3.html2canvas = e3.html2canvas || {}), (e3.html2canvas.canvas = e3.html2canvas.canvas || this.canvas), (e3.jsPDF = e3.jsPDF || this), (e3.fontFaces = e3.fontFaces ? e3.fontFaces.map(jt) : null) var r3 = new s2(e3) return e3.worker ? r3 : r3.from(t3).doCallback() }) })(E$1.API), (E$1.API.addJS = function (t3) { return ( (Ht = t3), this.internal.events.subscribe('postPutResources', function () { ;(Ut = this.internal.newObject()), this.internal.out('<<'), this.internal.out('/Names [(EmbeddedJS) ' + (Ut + 1) + ' 0 R]'), this.internal.out('>>'), this.internal.out('endobj'), (zt = this.internal.newObject()), this.internal.out('<<'), this.internal.out('/S /JavaScript'), this.internal.out('/JS (' + Ht + ')'), this.internal.out('>>'), this.internal.out('endobj') }), this.internal.events.subscribe('putCatalog', function () { void 0 !== Ut && void 0 !== zt && this.internal.out('/Names <>') }), this ) }), (function (t3) { var e2 t3.events.push([ 'postPutResources', function () { var t4 = this, r2 = /^(\d+) 0 obj$/ if (this.outline.root.children.length > 0) for ( var n2 = t4.outline.render().split(/\r\n/), i2 = 0; i2 < n2.length; i2++ ) { var a2 = n2[i2], o2 = r2.exec(a2) if (null != o2) { var s2 = o2[1] t4.internal.newObjectDeferredBegin(s2, false) } t4.internal.write(a2) } if (this.outline.createNamedDestinations) { var c2 = this.internal.pages.length, u2 = [] for (i2 = 0; i2 < c2; i2++) { var h2 = t4.internal.newObject() u2.push(h2) var l2 = t4.internal.getPageInfo(i2 + 1) t4.internal.write( '<< /D[' + l2.objId + ' 0 R /XYZ null null null]>> endobj' ) } var f2 = t4.internal.newObject() t4.internal.write('<< /Names [ ') for (i2 = 0; i2 < u2.length; i2++) t4.internal.write('(page_' + (i2 + 1) + ')' + u2[i2] + ' 0 R') t4.internal.write(' ] >>', 'endobj'), (e2 = t4.internal.newObject()), t4.internal.write('<< /Dests ' + f2 + ' 0 R'), t4.internal.write('>>', 'endobj') } }, ]), t3.events.push([ 'putCatalog', function () { this.outline.root.children.length > 0 && (this.internal.write( '/Outlines', this.outline.makeRef(this.outline.root) ), this.outline.createNamedDestinations && this.internal.write('/Names ' + e2 + ' 0 R')) }, ]), t3.events.push([ 'initialized', function () { var t4 = this ;(t4.outline = { createNamedDestinations: false, root: { children: [] }, }), (t4.outline.add = function (t5, e3, r2) { var n2 = { title: e3, options: r2, children: [] } return null == t5 && (t5 = this.root), t5.children.push(n2), n2 }), (t4.outline.render = function () { return ( (this.ctx = {}), (this.ctx.val = ''), (this.ctx.pdf = t4), this.genIds_r(this.root), this.renderRoot(this.root), this.renderItems(this.root), this.ctx.val ) }), (t4.outline.genIds_r = function (e3) { e3.id = t4.internal.newObjectDeferred() for (var r2 = 0; r2 < e3.children.length; r2++) this.genIds_r(e3.children[r2]) }), (t4.outline.renderRoot = function (t5) { this.objStart(t5), this.line('/Type /Outlines'), t5.children.length > 0 && (this.line('/First ' + this.makeRef(t5.children[0])), this.line( '/Last ' + this.makeRef(t5.children[t5.children.length - 1]) )), this.line('/Count ' + this.count_r({ count: 0 }, t5)), this.objEnd() }), (t4.outline.renderItems = function (e3) { for ( var r2 = this.ctx.pdf.internal.getVerticalCoordinateString, n2 = 0; n2 < e3.children.length; n2++ ) { var i2 = e3.children[n2] this.objStart(i2), this.line('/Title ' + this.makeString(i2.title)), this.line('/Parent ' + this.makeRef(e3)), n2 > 0 && this.line('/Prev ' + this.makeRef(e3.children[n2 - 1])), n2 < e3.children.length - 1 && this.line('/Next ' + this.makeRef(e3.children[n2 + 1])), i2.children.length > 0 && (this.line('/First ' + this.makeRef(i2.children[0])), this.line( '/Last ' + this.makeRef(i2.children[i2.children.length - 1]) )) var a2 = (this.count = this.count_r({ count: 0 }, i2)) if ( (a2 > 0 && this.line('/Count ' + a2), i2.options && i2.options.pageNumber) ) { var o2 = t4.internal.getPageInfo(i2.options.pageNumber) this.line( '/Dest [' + o2.objId + ' 0 R /XYZ 0 ' + r2(0) + ' 0]' ) } this.objEnd() } for (var s2 = 0; s2 < e3.children.length; s2++) this.renderItems(e3.children[s2]) }), (t4.outline.line = function (t5) { this.ctx.val += t5 + '\r\n' }), (t4.outline.makeRef = function (t5) { return t5.id + ' 0 R' }), (t4.outline.makeString = function (e3) { return '(' + t4.internal.pdfEscape(e3) + ')' }), (t4.outline.objStart = function (t5) { this.ctx.val += '\r\n' + t5.id + ' 0 obj\r\n<<\r\n' }), (t4.outline.objEnd = function () { this.ctx.val += '>> \r\nendobj\r\n' }), (t4.outline.count_r = function (t5, e3) { for (var r2 = 0; r2 < e3.children.length; r2++) t5.count++, this.count_r(t5, e3.children[r2]) return t5.count }) }, ]) })(E$1.API), (function (t3) { var e2 = [192, 193, 194, 195, 196, 197, 198, 199] t3.processJPEG = function (t4, r2, n2, i2, a2, o2) { var s2, c2 = this.decode.DCT_DECODE, u2 = null if ( 'string' == typeof t4 || this.__addimage__.isArrayBuffer(t4) || this.__addimage__.isArrayBufferView(t4) ) { switch ( ((t4 = a2 || t4), (t4 = this.__addimage__.isArrayBuffer(t4) ? new Uint8Array(t4) : t4), (s2 = (function (t5) { for ( var r3, n3 = 256 * t5.charCodeAt(4) + t5.charCodeAt(5), i3 = t5.length, a3 = { width: 0, height: 0, numcomponents: 1 }, o3 = 4; o3 < i3; o3 += 2 ) { if (((o3 += n3), -1 !== e2.indexOf(t5.charCodeAt(o3 + 1)))) { ;(r3 = 256 * t5.charCodeAt(o3 + 5) + t5.charCodeAt(o3 + 6)), (a3 = { width: 256 * t5.charCodeAt(o3 + 7) + t5.charCodeAt(o3 + 8), height: r3, numcomponents: t5.charCodeAt(o3 + 9), }) break } n3 = 256 * t5.charCodeAt(o3 + 2) + t5.charCodeAt(o3 + 3) } return a3 })( (t4 = this.__addimage__.isArrayBufferView(t4) ? this.__addimage__.arrayBufferToBinaryString(t4) : t4) )).numcomponents) ) { case 1: o2 = this.color_spaces.DEVICE_GRAY break case 4: o2 = this.color_spaces.DEVICE_CMYK break case 3: o2 = this.color_spaces.DEVICE_RGB } u2 = { data: t4, width: s2.width, height: s2.height, colorSpace: o2, bitsPerComponent: 8, filter: c2, index: r2, alias: n2, } } return u2 } })(E$1.API) var Vt, Gt, Yt, Jt, Xt, Kt = (function () { var t3, e2, i2 function a2(t4) { var e3, r2, n2, i3, a3, o3, s2, c2, u2, h2, l2, f2, d3, p2 for ( this.data = t4, this.pos = 8, this.palette = [], this.imgData = [], this.transparency = {}, this.animation = null, this.text = {}, o3 = null; ; ) { switch ( ((e3 = this.readUInt32()), (u2 = function () { var t5, e4 for (e4 = [], t5 = 0; t5 < 4; ++t5) e4.push(String.fromCharCode(this.data[this.pos++])) return e4 } .call(this) .join(''))) ) { case 'IHDR': ;(this.width = this.readUInt32()), (this.height = this.readUInt32()), (this.bits = this.data[this.pos++]), (this.colorType = this.data[this.pos++]), (this.compressionMethod = this.data[this.pos++]), (this.filterMethod = this.data[this.pos++]), (this.interlaceMethod = this.data[this.pos++]) break case 'acTL': this.animation = { numFrames: this.readUInt32(), numPlays: this.readUInt32() || 1 / 0, frames: [], } break case 'PLTE': this.palette = this.read(e3) break case 'fcTL': o3 && this.animation.frames.push(o3), (this.pos += 4), (o3 = { width: this.readUInt32(), height: this.readUInt32(), xOffset: this.readUInt32(), yOffset: this.readUInt32(), }), (a3 = this.readUInt16()), (i3 = this.readUInt16() || 100), (o3.delay = (1e3 * a3) / i3), (o3.disposeOp = this.data[this.pos++]), (o3.blendOp = this.data[this.pos++]), (o3.data = []) break case 'IDAT': case 'fdAT': for ( 'fdAT' === u2 && ((this.pos += 4), (e3 -= 4)), t4 = (null != o3 ? o3.data : void 0) || this.imgData, f2 = 0; 0 <= e3 ? f2 < e3 : f2 > e3; 0 <= e3 ? ++f2 : --f2 ) t4.push(this.data[this.pos++]) break case 'tRNS': switch (((this.transparency = {}), this.colorType)) { case 3: if ( ((n2 = this.palette.length / 3), (this.transparency.indexed = this.read(e3)), this.transparency.indexed.length > n2) ) throw new Error('More transparent colors than palette size') if ((h2 = n2 - this.transparency.indexed.length) > 0) for ( d3 = 0; 0 <= h2 ? d3 < h2 : d3 > h2; 0 <= h2 ? ++d3 : --d3 ) this.transparency.indexed.push(255) break case 0: this.transparency.grayscale = this.read(e3)[0] break case 2: this.transparency.rgb = this.read(e3) } break case 'tEXt': ;(s2 = (l2 = this.read(e3)).indexOf(0)), (c2 = String.fromCharCode.apply(String, l2.slice(0, s2))), (this.text[c2] = String.fromCharCode.apply( String, l2.slice(s2 + 1) )) break case 'IEND': return ( o3 && this.animation.frames.push(o3), (this.colors = function () { switch (this.colorType) { case 0: case 3: case 4: return 1 case 2: case 6: return 3 } }.call(this)), (this.hasAlphaChannel = 4 === (p2 = this.colorType) || 6 === p2), (r2 = this.colors + (this.hasAlphaChannel ? 1 : 0)), (this.pixelBitlength = this.bits * r2), (this.colorSpace = function () { switch (this.colors) { case 1: return 'DeviceGray' case 3: return 'DeviceRGB' } }.call(this)), void (this.imgData = new Uint8Array(this.imgData)) ) default: this.pos += e3 } if (((this.pos += 4), this.pos > this.data.length)) throw new Error('Incomplete or corrupt PNG file') } } ;(a2.prototype.read = function (t4) { var e3, r2 for (r2 = [], e3 = 0; 0 <= t4 ? e3 < t4 : e3 > t4; 0 <= t4 ? ++e3 : --e3) r2.push(this.data[this.pos++]) return r2 }), (a2.prototype.readUInt32 = function () { return ( (this.data[this.pos++] << 24) | (this.data[this.pos++] << 16) | (this.data[this.pos++] << 8) | this.data[this.pos++] ) }), (a2.prototype.readUInt16 = function () { return (this.data[this.pos++] << 8) | this.data[this.pos++] }), (a2.prototype.decodePixels = function (t4) { var e3 = this.pixelBitlength / 8, n2 = new Uint8Array(this.width * this.height * e3), i3 = 0, a3 = this if ((null == t4 && (t4 = this.imgData), 0 === t4.length)) return new Uint8Array(0) function o3(r2, o4, s2, c2) { var u2, h2, l2, f2, d3, p2, g2, m2, v4, b2, y2, w2, N2, L2, A2, x2, S2, _2, P2, k2, I2, F2 = Math.ceil((a3.width - r2) / s2), C2 = Math.ceil((a3.height - o4) / c2), j2 = a3.width == F2 && a3.height == C2 for ( L2 = e3 * F2, w2 = j2 ? n2 : new Uint8Array(L2 * C2), p2 = t4.length, N2 = 0, h2 = 0; N2 < C2 && i3 < p2; ) { switch (t4[i3++]) { case 0: for (f2 = S2 = 0; S2 < L2; f2 = S2 += 1) w2[h2++] = t4[i3++] break case 1: for (f2 = _2 = 0; _2 < L2; f2 = _2 += 1) (u2 = t4[i3++]), (d3 = f2 < e3 ? 0 : w2[h2 - e3]), (w2[h2++] = (u2 + d3) % 256) break case 2: for (f2 = P2 = 0; P2 < L2; f2 = P2 += 1) (u2 = t4[i3++]), (l2 = (f2 - (f2 % e3)) / e3), (A2 = N2 && w2[(N2 - 1) * L2 + l2 * e3 + (f2 % e3)]), (w2[h2++] = (A2 + u2) % 256) break case 3: for (f2 = k2 = 0; k2 < L2; f2 = k2 += 1) (u2 = t4[i3++]), (l2 = (f2 - (f2 % e3)) / e3), (d3 = f2 < e3 ? 0 : w2[h2 - e3]), (A2 = N2 && w2[(N2 - 1) * L2 + l2 * e3 + (f2 % e3)]), (w2[h2++] = (u2 + Math.floor((d3 + A2) / 2)) % 256) break case 4: for (f2 = I2 = 0; I2 < L2; f2 = I2 += 1) (u2 = t4[i3++]), (l2 = (f2 - (f2 % e3)) / e3), (d3 = f2 < e3 ? 0 : w2[h2 - e3]), 0 === N2 ? (A2 = x2 = 0) : ((A2 = w2[(N2 - 1) * L2 + l2 * e3 + (f2 % e3)]), (x2 = l2 && w2[(N2 - 1) * L2 + (l2 - 1) * e3 + (f2 % e3)])), (g2 = d3 + A2 - x2), (m2 = Math.abs(g2 - d3)), (b2 = Math.abs(g2 - A2)), (y2 = Math.abs(g2 - x2)), (v4 = m2 <= b2 && m2 <= y2 ? d3 : b2 <= y2 ? A2 : x2), (w2[h2++] = (u2 + v4) % 256) break default: throw new Error('Invalid filter algorithm: ' + t4[i3 - 1]) } if (!j2) { var O2 = ((o4 + N2 * c2) * a3.width + r2) * e3, B3 = N2 * L2 for (f2 = 0; f2 < F2; f2 += 1) { for (var M2 = 0; M2 < e3; M2 += 1) n2[O2++] = w2[B3++] O2 += (s2 - 1) * e3 } } N2++ } } return ( (t4 = unzlibSync(t4)), 1 == a3.interlaceMethod ? (o3(0, 0, 8, 8), o3(4, 0, 8, 8), o3(0, 4, 4, 8), o3(2, 0, 4, 4), o3(0, 2, 2, 4), o3(1, 0, 2, 2), o3(0, 1, 1, 2)) : o3(0, 0, 1, 1), n2 ) }), (a2.prototype.decodePalette = function () { var t4, e3, r2, n2, i3, a3, o3, s2, c2 for ( r2 = this.palette, a3 = this.transparency.indexed || [], i3 = new Uint8Array((a3.length || 0) + r2.length), n2 = 0, t4 = 0, e3 = o3 = 0, s2 = r2.length; o3 < s2; e3 = o3 += 3 ) (i3[n2++] = r2[e3]), (i3[n2++] = r2[e3 + 1]), (i3[n2++] = r2[e3 + 2]), (i3[n2++] = null != (c2 = a3[t4++]) ? c2 : 255) return i3 }), (a2.prototype.copyToImageData = function (t4, e3) { var r2, n2, i3, a3, o3, s2, c2, u2, h2, l2, f2 if ( ((n2 = this.colors), (h2 = null), (r2 = this.hasAlphaChannel), this.palette.length && ((h2 = null != (f2 = this._decodedPalette) ? f2 : (this._decodedPalette = this.decodePalette())), (n2 = 4), (r2 = true)), (u2 = (i3 = t4.data || t4).length), (o3 = h2 || e3), (a3 = s2 = 0), 1 === n2) ) for (; a3 < u2; ) (c2 = h2 ? 4 * e3[a3 / 4] : s2), (l2 = o3[c2++]), (i3[a3++] = l2), (i3[a3++] = l2), (i3[a3++] = l2), (i3[a3++] = r2 ? o3[c2++] : 255), (s2 = c2) else for (; a3 < u2; ) (c2 = h2 ? 4 * e3[a3 / 4] : s2), (i3[a3++] = o3[c2++]), (i3[a3++] = o3[c2++]), (i3[a3++] = o3[c2++]), (i3[a3++] = r2 ? o3[c2++] : 255), (s2 = c2) }), (a2.prototype.decode = function () { var t4 return ( (t4 = new Uint8Array(this.width * this.height * 4)), this.copyToImageData(t4, this.decodePixels()), t4 ) }) var o2 = function () { if ('[object Window]' === Object.prototype.toString.call(n$1)) { try { ;(e2 = n$1.document.createElement('canvas')), (i2 = e2.getContext('2d')) } catch (t4) { return false } return true } return false } return ( o2(), (t3 = function (t4) { var r2 if (true === o2()) return ( (i2.width = t4.width), (i2.height = t4.height), i2.clearRect(0, 0, t4.width, t4.height), i2.putImageData(t4, 0, 0), ((r2 = new Image()).src = e2.toDataURL()), r2 ) throw new Error( 'This method requires a Browser with Canvas-capability.' ) }), (a2.prototype.decodeFrames = function (e3) { var r2, n2, i3, a3, o3, s2, c2, u2 if (this.animation) { for ( u2 = [], n2 = o3 = 0, s2 = (c2 = this.animation.frames).length; o3 < s2; n2 = ++o3 ) (r2 = c2[n2]), (i3 = e3.createImageData(r2.width, r2.height)), (a3 = this.decodePixels(new Uint8Array(r2.data))), this.copyToImageData(i3, a3), (r2.imageData = i3), u2.push((r2.image = t3(i3))) return u2 } }), (a2.prototype.renderFrame = function (t4, e3) { var r2, n2, i3 return ( (r2 = (n2 = this.animation.frames)[e3]), (i3 = n2[e3 - 1]), 0 === e3 && t4.clearRect(0, 0, this.width, this.height), 1 === (null != i3 ? i3.disposeOp : void 0) ? t4.clearRect(i3.xOffset, i3.yOffset, i3.width, i3.height) : 2 === (null != i3 ? i3.disposeOp : void 0) && t4.putImageData(i3.imageData, i3.xOffset, i3.yOffset), 0 === r2.blendOp && t4.clearRect(r2.xOffset, r2.yOffset, r2.width, r2.height), t4.drawImage(r2.image, r2.xOffset, r2.yOffset) ) }), (a2.prototype.animate = function (t4) { var e3, r2, n2, i3, a3, o3, s2 = this return ( (r2 = 0), (o3 = this.animation), (i3 = o3.numFrames), (n2 = o3.frames), (a3 = o3.numPlays), (e3 = function () { var o4, c2 if ( ((o4 = r2++ % i3), (c2 = n2[o4]), s2.renderFrame(t4, o4), i3 > 1 && r2 / i3 < a3) ) return (s2.animation._timeout = setTimeout(e3, c2.delay)) })() ) }), (a2.prototype.stopAnimation = function () { var t4 return clearTimeout( null != (t4 = this.animation) ? t4._timeout : void 0 ) }), (a2.prototype.render = function (t4) { var e3, r2 return ( t4._png && t4._png.stopAnimation(), (t4._png = this), (t4.width = this.width), (t4.height = this.height), (e3 = t4.getContext('2d')), this.animation ? (this.decodeFrames(e3), this.animate(e3)) : ((r2 = e3.createImageData(this.width, this.height)), this.copyToImageData(r2, this.decodePixels()), e3.putImageData(r2, 0, 0)) ) }), a2 ) })() /** * @license * * Copyright (c) 2014 James Robb, https://github.com/jamesbrobb * * Permission is hereby granted, free of charge, to any person obtaining * a copy of this software and associated documentation files (the * "Software"), to deal in the Software without restriction, including * without limitation the rights to use, copy, modify, merge, publish, * distribute, sublicense, and/or sell copies of the Software, and to * permit persons to whom the Software is furnished to do so, subject to * the following conditions: * * The above copyright notice and this permission notice shall be * included in all copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE * LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION * OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. * ==================================================================== */ /** * @license * (c) Dean McNamee , 2013. * * https://github.com/deanm/omggif * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to * deal in the Software without restriction, including without limitation the * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or * sell copies of the Software, and to permit persons to whom the Software is * furnished to do so, subject to the following conditions: * * The above copyright notice and this permission notice shall be included in * all copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS * IN THE SOFTWARE. * * omggif is a JavaScript implementation of a GIF 89a encoder and decoder, * including animation and compression. It does not rely on any specific * underlying system, so should run in the browser, Node, or Plask. */ function Zt(t3) { var e2 = 0 if ( 71 !== t3[e2++] || 73 !== t3[e2++] || 70 !== t3[e2++] || 56 !== t3[e2++] || 56 != ((t3[e2++] + 1) & 253) || 97 !== t3[e2++] ) throw new Error('Invalid GIF 87a/89a header.') var r2 = t3[e2++] | (t3[e2++] << 8), n2 = t3[e2++] | (t3[e2++] << 8), i2 = t3[e2++], a2 = i2 >> 7, o2 = 1 << ((7 & i2) + 1) t3[e2++] t3[e2++] var s2 = null, c2 = null a2 && ((s2 = e2), (c2 = o2), (e2 += 3 * o2)) var u2 = true, h2 = [], l2 = 0, f2 = null, d3 = 0, p2 = null for (this.width = r2, this.height = n2; u2 && e2 < t3.length; ) switch (t3[e2++]) { case 33: switch (t3[e2++]) { case 255: if ( 11 !== t3[e2] || (78 == t3[e2 + 1] && 69 == t3[e2 + 2] && 84 == t3[e2 + 3] && 83 == t3[e2 + 4] && 67 == t3[e2 + 5] && 65 == t3[e2 + 6] && 80 == t3[e2 + 7] && 69 == t3[e2 + 8] && 50 == t3[e2 + 9] && 46 == t3[e2 + 10] && 48 == t3[e2 + 11] && 3 == t3[e2 + 12] && 1 == t3[e2 + 13] && 0 == t3[e2 + 16]) ) (e2 += 14), (p2 = t3[e2++] | (t3[e2++] << 8)), e2++ else for (e2 += 12; ; ) { if (!((P2 = t3[e2++]) >= 0)) throw Error('Invalid block size') if (0 === P2) break e2 += P2 } break case 249: if (4 !== t3[e2++] || 0 !== t3[e2 + 4]) throw new Error('Invalid graphics extension block.') var g2 = t3[e2++] ;(l2 = t3[e2++] | (t3[e2++] << 8)), (f2 = t3[e2++]), 0 == (1 & g2) && (f2 = null), (d3 = (g2 >> 2) & 7), e2++ break case 254: for (;;) { if (!((P2 = t3[e2++]) >= 0)) throw Error('Invalid block size') if (0 === P2) break e2 += P2 } break default: throw new Error( 'Unknown graphic control label: 0x' + t3[e2 - 1].toString(16) ) } break case 44: var m2 = t3[e2++] | (t3[e2++] << 8), v4 = t3[e2++] | (t3[e2++] << 8), b2 = t3[e2++] | (t3[e2++] << 8), y2 = t3[e2++] | (t3[e2++] << 8), w2 = t3[e2++], N2 = (w2 >> 6) & 1, L2 = 1 << ((7 & w2) + 1), A2 = s2, x2 = c2, S2 = false if (w2 >> 7) { S2 = true ;(A2 = e2), (x2 = L2), (e2 += 3 * L2) } var _2 = e2 for (e2++; ; ) { var P2 if (!((P2 = t3[e2++]) >= 0)) throw Error('Invalid block size') if (0 === P2) break e2 += P2 } h2.push({ x: m2, y: v4, width: b2, height: y2, has_local_palette: S2, palette_offset: A2, palette_size: x2, data_offset: _2, data_length: e2 - _2, transparent_index: f2, interlaced: !!N2, delay: l2, disposal: d3, }) break case 59: u2 = false break default: throw new Error('Unknown gif block: 0x' + t3[e2 - 1].toString(16)) } ;(this.numFrames = function () { return h2.length }), (this.loopCount = function () { return p2 }), (this.frameInfo = function (t4) { if (t4 < 0 || t4 >= h2.length) throw new Error('Frame index out of range.') return h2[t4] }), (this.decodeAndBlitFrameBGRA = function (e3, n3) { var i3 = this.frameInfo(e3), a3 = i3.width * i3.height, o3 = new Uint8Array(a3) $t(t3, i3.data_offset, o3, a3) var s3 = i3.palette_offset, c3 = i3.transparent_index null === c3 && (c3 = 256) var u3 = i3.width, h3 = r2 - u3, l3 = u3, f3 = 4 * (i3.y * r2 + i3.x), d4 = 4 * ((i3.y + i3.height) * r2 + i3.x), p3 = f3, g3 = 4 * h3 true === i3.interlaced && (g3 += 4 * r2 * 7) for (var m3 = 8, v5 = 0, b3 = o3.length; v5 < b3; ++v5) { var y3 = o3[v5] if ( (0 === l3 && ((l3 = u3), (p3 += g3) >= d4 && ((g3 = 4 * h3 + 4 * r2 * (m3 - 1)), (p3 = f3 + (u3 + h3) * (m3 << 1)), (m3 >>= 1))), y3 === c3) ) p3 += 4 else { var w3 = t3[s3 + 3 * y3], N3 = t3[s3 + 3 * y3 + 1], L3 = t3[s3 + 3 * y3 + 2] ;(n3[p3++] = L3), (n3[p3++] = N3), (n3[p3++] = w3), (n3[p3++] = 255) } --l3 } }), (this.decodeAndBlitFrameRGBA = function (e3, n3) { var i3 = this.frameInfo(e3), a3 = i3.width * i3.height, o3 = new Uint8Array(a3) $t(t3, i3.data_offset, o3, a3) var s3 = i3.palette_offset, c3 = i3.transparent_index null === c3 && (c3 = 256) var u3 = i3.width, h3 = r2 - u3, l3 = u3, f3 = 4 * (i3.y * r2 + i3.x), d4 = 4 * ((i3.y + i3.height) * r2 + i3.x), p3 = f3, g3 = 4 * h3 true === i3.interlaced && (g3 += 4 * r2 * 7) for (var m3 = 8, v5 = 0, b3 = o3.length; v5 < b3; ++v5) { var y3 = o3[v5] if ( (0 === l3 && ((l3 = u3), (p3 += g3) >= d4 && ((g3 = 4 * h3 + 4 * r2 * (m3 - 1)), (p3 = f3 + (u3 + h3) * (m3 << 1)), (m3 >>= 1))), y3 === c3) ) p3 += 4 else { var w3 = t3[s3 + 3 * y3], N3 = t3[s3 + 3 * y3 + 1], L3 = t3[s3 + 3 * y3 + 2] ;(n3[p3++] = w3), (n3[p3++] = N3), (n3[p3++] = L3), (n3[p3++] = 255) } --l3 } }) } function $t(t3, e2, r2, n2) { for ( var i2 = t3[e2++], o2 = 1 << i2, s2 = o2 + 1, c2 = s2 + 1, u2 = i2 + 1, h2 = (1 << u2) - 1, l2 = 0, f2 = 0, d3 = 0, p2 = t3[e2++], g2 = new Int32Array(4096), m2 = null; ; ) { for (; l2 < 16 && 0 !== p2; ) (f2 |= t3[e2++] << l2), (l2 += 8), 1 === p2 ? (p2 = t3[e2++]) : --p2 if (l2 < u2) break var v4 = f2 & h2 if (((f2 >>= u2), (l2 -= u2), v4 !== o2)) { if (v4 === s2) break for (var b2 = v4 < c2 ? v4 : m2, y2 = 0, w2 = b2; w2 > o2; ) (w2 = g2[w2] >> 8), ++y2 var N2 = w2 if (d3 + y2 + (b2 !== v4 ? 1 : 0) > n2) return void a$2.log('Warning, gif stream longer than expected.') r2[d3++] = N2 var L2 = (d3 += y2) for (b2 !== v4 && (r2[d3++] = N2), w2 = b2; y2--; ) (w2 = g2[w2]), (r2[--L2] = 255 & w2), (w2 >>= 8) null !== m2 && c2 < 4096 && ((g2[c2++] = (m2 << 8) | N2), c2 >= h2 + 1 && u2 < 12 && (++u2, (h2 = (h2 << 1) | 1))), (m2 = v4) } else (c2 = s2 + 1), (h2 = (1 << (u2 = i2 + 1)) - 1), (m2 = null) } return d3 !== n2 && a$2.log('Warning, gif stream shorter than expected.'), r2 } /** * @license Copyright (c) 2008, Adobe Systems Incorporated All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. * Neither the name of Adobe Systems Incorporated nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ function Qt(t3) { var e2, r2, n2, i2, a2, o2 = Math.floor, s2 = new Array(64), c2 = new Array(64), u2 = new Array(64), h2 = new Array(64), l2 = new Array(65535), f2 = new Array(65535), d3 = new Array(64), p2 = new Array(64), g2 = [], m2 = 0, v4 = 7, b2 = new Array(64), y2 = new Array(64), w2 = new Array(64), N2 = new Array(256), L2 = new Array(2048), A2 = [ 0, 1, 5, 6, 14, 15, 27, 28, 2, 4, 7, 13, 16, 26, 29, 42, 3, 8, 12, 17, 25, 30, 41, 43, 9, 11, 18, 24, 31, 40, 44, 53, 10, 19, 23, 32, 39, 45, 52, 54, 20, 22, 33, 38, 46, 51, 55, 60, 21, 34, 37, 47, 50, 56, 59, 61, 35, 36, 48, 49, 57, 58, 62, 63, ], x2 = [0, 0, 1, 5, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0], S2 = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11], _2 = [0, 0, 2, 1, 3, 3, 2, 4, 3, 5, 5, 4, 4, 0, 0, 1, 125], P2 = [ 1, 2, 3, 0, 4, 17, 5, 18, 33, 49, 65, 6, 19, 81, 97, 7, 34, 113, 20, 50, 129, 145, 161, 8, 35, 66, 177, 193, 21, 82, 209, 240, 36, 51, 98, 114, 130, 9, 10, 22, 23, 24, 25, 26, 37, 38, 39, 40, 41, 42, 52, 53, 54, 55, 56, 57, 58, 67, 68, 69, 70, 71, 72, 73, 74, 83, 84, 85, 86, 87, 88, 89, 90, 99, 100, 101, 102, 103, 104, 105, 106, 115, 116, 117, 118, 119, 120, 121, 122, 131, 132, 133, 134, 135, 136, 137, 138, 146, 147, 148, 149, 150, 151, 152, 153, 154, 162, 163, 164, 165, 166, 167, 168, 169, 170, 178, 179, 180, 181, 182, 183, 184, 185, 186, 194, 195, 196, 197, 198, 199, 200, 201, 202, 210, 211, 212, 213, 214, 215, 216, 217, 218, 225, 226, 227, 228, 229, 230, 231, 232, 233, 234, 241, 242, 243, 244, 245, 246, 247, 248, 249, 250, ], k2 = [0, 0, 3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0], I2 = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11], F2 = [0, 0, 2, 1, 2, 4, 4, 3, 4, 7, 5, 4, 4, 0, 1, 2, 119], C2 = [ 0, 1, 2, 3, 17, 4, 5, 33, 49, 6, 18, 65, 81, 7, 97, 113, 19, 34, 50, 129, 8, 20, 66, 145, 161, 177, 193, 9, 35, 51, 82, 240, 21, 98, 114, 209, 10, 22, 36, 52, 225, 37, 241, 23, 24, 25, 26, 38, 39, 40, 41, 42, 53, 54, 55, 56, 57, 58, 67, 68, 69, 70, 71, 72, 73, 74, 83, 84, 85, 86, 87, 88, 89, 90, 99, 100, 101, 102, 103, 104, 105, 106, 115, 116, 117, 118, 119, 120, 121, 122, 130, 131, 132, 133, 134, 135, 136, 137, 138, 146, 147, 148, 149, 150, 151, 152, 153, 154, 162, 163, 164, 165, 166, 167, 168, 169, 170, 178, 179, 180, 181, 182, 183, 184, 185, 186, 194, 195, 196, 197, 198, 199, 200, 201, 202, 210, 211, 212, 213, 214, 215, 216, 217, 218, 226, 227, 228, 229, 230, 231, 232, 233, 234, 242, 243, 244, 245, 246, 247, 248, 249, 250, ] function j2(t4, e3) { for (var r3 = 0, n3 = 0, i3 = new Array(), a3 = 1; a3 <= 16; a3++) { for (var o3 = 1; o3 <= t4[a3]; o3++) (i3[e3[n3]] = []), (i3[e3[n3]][0] = r3), (i3[e3[n3]][1] = a3), n3++, r3++ r3 *= 2 } return i3 } function O2(t4) { for (var e3 = t4[0], r3 = t4[1] - 1; r3 >= 0; ) e3 & (1 << r3) && (m2 |= 1 << v4), r3--, --v4 < 0 && (255 == m2 ? (B3(255), B3(0)) : B3(m2), (v4 = 7), (m2 = 0)) } function B3(t4) { g2.push(t4) } function M2(t4) { B3((t4 >> 8) & 255), B3(255 & t4) } function E2(t4, e3, r3, n3, i3) { for ( var a3, o3 = i3[0], s3 = i3[240], c3 = (function (t5, e4) { var r4, n4, i4, a4, o4, s4, c4, u4, h4, l3, f3 = 0 for (h4 = 0; h4 < 8; ++h4) { ;(r4 = t5[f3]), (n4 = t5[f3 + 1]), (i4 = t5[f3 + 2]), (a4 = t5[f3 + 3]), (o4 = t5[f3 + 4]), (s4 = t5[f3 + 5]), (c4 = t5[f3 + 6]) var p3 = r4 + (u4 = t5[f3 + 7]), g4 = r4 - u4, m4 = n4 + c4, v6 = n4 - c4, b4 = i4 + s4, y4 = i4 - s4, w4 = a4 + o4, N3 = a4 - o4, L3 = p3 + w4, A3 = p3 - w4, x3 = m4 + b4, S3 = m4 - b4 ;(t5[f3] = L3 + x3), (t5[f3 + 4] = L3 - x3) var _3 = 0.707106781 * (S3 + A3) ;(t5[f3 + 2] = A3 + _3), (t5[f3 + 6] = A3 - _3) var P3 = 0.382683433 * ((L3 = N3 + y4) - (S3 = v6 + g4)), k3 = 0.5411961 * L3 + P3, I3 = 1.306562965 * S3 + P3, F3 = 0.707106781 * (x3 = y4 + v6), C3 = g4 + F3, j3 = g4 - F3 ;(t5[f3 + 5] = j3 + k3), (t5[f3 + 3] = j3 - k3), (t5[f3 + 1] = C3 + I3), (t5[f3 + 7] = C3 - I3), (f3 += 8) } for (f3 = 0, h4 = 0; h4 < 8; ++h4) { ;(r4 = t5[f3]), (n4 = t5[f3 + 8]), (i4 = t5[f3 + 16]), (a4 = t5[f3 + 24]), (o4 = t5[f3 + 32]), (s4 = t5[f3 + 40]), (c4 = t5[f3 + 48]) var O3 = r4 + (u4 = t5[f3 + 56]), B4 = r4 - u4, M3 = n4 + c4, E3 = n4 - c4, q3 = i4 + s4, D2 = i4 - s4, R2 = a4 + o4, T2 = a4 - o4, U2 = O3 + R2, z2 = O3 - R2, H4 = M3 + q3, W2 = M3 - q3 ;(t5[f3] = U2 + H4), (t5[f3 + 32] = U2 - H4) var V2 = 0.707106781 * (W2 + z2) ;(t5[f3 + 16] = z2 + V2), (t5[f3 + 48] = z2 - V2) var G2 = 0.382683433 * ((U2 = T2 + D2) - (W2 = E3 + B4)), Y2 = 0.5411961 * U2 + G2, J2 = 1.306562965 * W2 + G2, X2 = 0.707106781 * (H4 = D2 + E3), K2 = B4 + X2, Z2 = B4 - X2 ;(t5[f3 + 40] = Z2 + Y2), (t5[f3 + 24] = Z2 - Y2), (t5[f3 + 8] = K2 + J2), (t5[f3 + 56] = K2 - J2), f3++ } for (h4 = 0; h4 < 64; ++h4) (l3 = t5[h4] * e4[h4]), (d3[h4] = l3 > 0 ? (l3 + 0.5) | 0 : (l3 - 0.5) | 0) return d3 })(t4, e3), u3 = 0; u3 < 64; ++u3 ) p2[A2[u3]] = c3[u3] var h3 = p2[0] - r3 ;(r3 = p2[0]), 0 == h3 ? O2(n3[0]) : (O2(n3[f2[(a3 = 32767 + h3)]]), O2(l2[a3])) for (var g3 = 63; g3 > 0 && 0 == p2[g3]; ) g3-- if (0 == g3) return O2(o3), r3 for (var m3, v5 = 1; v5 <= g3; ) { for (var b3 = v5; 0 == p2[v5] && v5 <= g3; ) ++v5 var y3 = v5 - b3 if (y3 >= 16) { m3 = y3 >> 4 for (var w3 = 1; w3 <= m3; ++w3) O2(s3) y3 &= 15 } ;(a3 = 32767 + p2[v5]), O2(i3[(y3 << 4) + f2[a3]]), O2(l2[a3]), v5++ } return 63 != g3 && O2(o3), r3 } function q2(t4) { ;((t4 = Math.min(Math.max(t4, 1), 100)), a2 != t4) && (!(function (t5) { for ( var e3 = [ 16, 11, 10, 16, 24, 40, 51, 61, 12, 12, 14, 19, 26, 58, 60, 55, 14, 13, 16, 24, 40, 57, 69, 56, 14, 17, 22, 29, 51, 87, 80, 62, 18, 22, 37, 56, 68, 109, 103, 77, 24, 35, 55, 64, 81, 104, 113, 92, 49, 64, 78, 87, 103, 121, 120, 101, 72, 92, 95, 98, 112, 100, 103, 99, ], r3 = 0; r3 < 64; r3++ ) { var n3 = o2((e3[r3] * t5 + 50) / 100) ;(n3 = Math.min(Math.max(n3, 1), 255)), (s2[A2[r3]] = n3) } for ( var i3 = [ 17, 18, 24, 47, 99, 99, 99, 99, 18, 21, 26, 66, 99, 99, 99, 99, 24, 26, 56, 99, 99, 99, 99, 99, 47, 66, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, 99, ], a3 = 0; a3 < 64; a3++ ) { var l3 = o2((i3[a3] * t5 + 50) / 100) ;(l3 = Math.min(Math.max(l3, 1), 255)), (c2[A2[a3]] = l3) } for ( var f3 = [ 1, 1.387039845, 1.306562965, 1.175875602, 1, 0.785694958, 0.5411961, 0.275899379, ], d4 = 0, p3 = 0; p3 < 8; p3++ ) for (var g3 = 0; g3 < 8; g3++) (u2[d4] = 1 / (s2[A2[d4]] * f3[p3] * f3[g3] * 8)), (h2[d4] = 1 / (c2[A2[d4]] * f3[p3] * f3[g3] * 8)), d4++ })(t4 < 50 ? Math.floor(5e3 / t4) : Math.floor(200 - 2 * t4)), (a2 = t4)) } ;(this.encode = function (t4, a3) { a3 && q2(a3), (g2 = new Array()), (m2 = 0), (v4 = 7), M2(65496), M2(65504), M2(16), B3(74), B3(70), B3(73), B3(70), B3(0), B3(1), B3(1), B3(0), M2(1), M2(1), B3(0), B3(0), (function () { M2(65499), M2(132), B3(0) for (var t5 = 0; t5 < 64; t5++) B3(s2[t5]) B3(1) for (var e3 = 0; e3 < 64; e3++) B3(c2[e3]) })(), (function (t5, e3) { M2(65472), M2(17), B3(8), M2(e3), M2(t5), B3(3), B3(1), B3(17), B3(0), B3(2), B3(17), B3(1), B3(3), B3(17), B3(1) })(t4.width, t4.height), (function () { M2(65476), M2(418), B3(0) for (var t5 = 0; t5 < 16; t5++) B3(x2[t5 + 1]) for (var e3 = 0; e3 <= 11; e3++) B3(S2[e3]) B3(16) for (var r3 = 0; r3 < 16; r3++) B3(_2[r3 + 1]) for (var n3 = 0; n3 <= 161; n3++) B3(P2[n3]) B3(1) for (var i3 = 0; i3 < 16; i3++) B3(k2[i3 + 1]) for (var a4 = 0; a4 <= 11; a4++) B3(I2[a4]) B3(17) for (var o4 = 0; o4 < 16; o4++) B3(F2[o4 + 1]) for (var s3 = 0; s3 <= 161; s3++) B3(C2[s3]) })(), M2(65498), M2(12), B3(3), B3(1), B3(0), B3(2), B3(17), B3(3), B3(17), B3(0), B3(63), B3(0) var o3 = 0, l3 = 0, f3 = 0 ;(m2 = 0), (v4 = 7), (this.encode.displayName = '_encode_') for ( var d4, p3, N3, A3, j3, D2, R2, T2, U2, z2 = t4.data, H4 = t4.width, W2 = t4.height, V2 = 4 * H4, G2 = 0; G2 < W2; ) { for (d4 = 0; d4 < V2; ) { for (j3 = V2 * G2 + d4, R2 = -1, T2 = 0, U2 = 0; U2 < 64; U2++) (D2 = j3 + (T2 = U2 >> 3) * V2 + (R2 = 4 * (7 & U2))), G2 + T2 >= W2 && (D2 -= V2 * (G2 + 1 + T2 - W2)), d4 + R2 >= V2 && (D2 -= d4 + R2 - V2 + 4), (p3 = z2[D2++]), (N3 = z2[D2++]), (A3 = z2[D2++]), (b2[U2] = ((L2[p3] + L2[(N3 + 256) >> 0] + L2[(A3 + 512) >> 0]) >> 16) - 128), (y2[U2] = ((L2[(p3 + 768) >> 0] + L2[(N3 + 1024) >> 0] + L2[(A3 + 1280) >> 0]) >> 16) - 128), (w2[U2] = ((L2[(p3 + 1280) >> 0] + L2[(N3 + 1536) >> 0] + L2[(A3 + 1792) >> 0]) >> 16) - 128) ;(o3 = E2(b2, u2, o3, e2, n2)), (l3 = E2(y2, h2, l3, r2, i2)), (f3 = E2(w2, h2, f3, r2, i2)), (d4 += 32) } G2 += 8 } if (v4 >= 0) { var Y2 = [] ;(Y2[1] = v4 + 1), (Y2[0] = (1 << (v4 + 1)) - 1), O2(Y2) } return M2(65497), new Uint8Array(g2) }), (t3 = t3 || 50), (function () { for (var t4 = String.fromCharCode, e3 = 0; e3 < 256; e3++) N2[e3] = t4(e3) })(), (e2 = j2(x2, S2)), (r2 = j2(k2, I2)), (n2 = j2(_2, P2)), (i2 = j2(F2, C2)), (function () { for (var t4 = 1, e3 = 2, r3 = 1; r3 <= 15; r3++) { for (var n3 = t4; n3 < e3; n3++) (f2[32767 + n3] = r3), (l2[32767 + n3] = []), (l2[32767 + n3][1] = r3), (l2[32767 + n3][0] = n3) for (var i3 = -(e3 - 1); i3 <= -t4; i3++) (f2[32767 + i3] = r3), (l2[32767 + i3] = []), (l2[32767 + i3][1] = r3), (l2[32767 + i3][0] = e3 - 1 + i3) ;(t4 <<= 1), (e3 <<= 1) } })(), (function () { for (var t4 = 0; t4 < 256; t4++) (L2[t4] = 19595 * t4), (L2[(t4 + 256) >> 0] = 38470 * t4), (L2[(t4 + 512) >> 0] = 7471 * t4 + 32768), (L2[(t4 + 768) >> 0] = -11059 * t4), (L2[(t4 + 1024) >> 0] = -21709 * t4), (L2[(t4 + 1280) >> 0] = 32768 * t4 + 8421375), (L2[(t4 + 1536) >> 0] = -27439 * t4), (L2[(t4 + 1792) >> 0] = -5329 * t4) })(), q2(t3) } /** * @license * Copyright (c) 2017 Aras Abbasi * * Licensed under the MIT License. * http://opensource.org/licenses/mit-license */ function te(t3, e2) { if ( ((this.pos = 0), (this.buffer = t3), (this.datav = new DataView(t3.buffer)), (this.is_with_alpha = !!e2), (this.bottom_up = true), (this.flag = String.fromCharCode(this.buffer[0]) + String.fromCharCode(this.buffer[1])), (this.pos += 2), -1 === ['BM', 'BA', 'CI', 'CP', 'IC', 'PT'].indexOf(this.flag)) ) throw new Error('Invalid BMP File') this.parseHeader(), this.parseBGR() } function ee(t3) { function e2(t4) { if (!t4) throw Error('assert :P') } function r2(t4, e3, r3) { for (var n3 = 0; 4 > n3; n3++) if (t4[e3 + n3] != r3.charCodeAt(n3)) return true return false } function n2(t4, e3, r3, n3, i3) { for (var a3 = 0; a3 < i3; a3++) t4[e3 + a3] = r3[n3 + a3] } function i2(t4, e3, r3, n3) { for (var i3 = 0; i3 < n3; i3++) t4[e3 + i3] = r3 } function a2(t4) { return new Int32Array(t4) } function o2(t4, e3) { for (var r3 = [], n3 = 0; n3 < t4; n3++) r3.push(new e3()) return r3 } function s2(t4, e3) { var r3 = [] return ( (function t5(r4, n3, i3) { for ( var a3 = i3[n3], o3 = 0; o3 < a3 && (r4.push(i3.length > n3 + 1 ? [] : new e3()), !(i3.length < n3 + 1)); o3++ ) t5(r4[o3], n3 + 1, i3) })(r3, 0, t4), r3 ) } var c2 = function () { var t4 = this function c3(t5, e3) { for (var r3 = (1 << (e3 - 1)) >>> 0; t5 & r3; ) r3 >>>= 1 return r3 ? (t5 & (r3 - 1)) + r3 : t5 } function u3(t5, r3, n3, i3, a3) { e2(!(i3 % n3)) do { t5[r3 + (i3 -= n3)] = a3 } while (0 < i3) } function h3(t5, r3, n3, i3, o3) { if ((e2(2328 >= o3), 512 >= o3)) var s3 = a2(512) else if (null == (s3 = a2(o3))) return 0 return (function (t6, r4, n4, i4, o4, s4) { var h4, f4, d5 = r4, p4 = 1 << n4, g4 = a2(16), m4 = a2(16) for ( e2(0 != o4), e2(null != i4), e2(null != t6), e2(0 < n4), f4 = 0; f4 < o4; ++f4 ) { if (15 < i4[f4]) return 0 ++g4[i4[f4]] } if (g4[0] == o4) return 0 for (m4[1] = 0, h4 = 1; 15 > h4; ++h4) { if (g4[h4] > 1 << h4) return 0 m4[h4 + 1] = m4[h4] + g4[h4] } for (f4 = 0; f4 < o4; ++f4) (h4 = i4[f4]), 0 < i4[f4] && (s4[m4[h4]++] = f4) if (1 == m4[15]) return ( ((i4 = new l3()).g = 0), (i4.value = s4[0]), u3(t6, d5, 1, p4, i4), p4 ) var v6, b4 = -1, y4 = p4 - 1, w4 = 0, N4 = 1, L4 = 1, A4 = 1 << n4 for (f4 = 0, h4 = 1, o4 = 2; h4 <= n4; ++h4, o4 <<= 1) { if (((N4 += L4 <<= 1), 0 > (L4 -= g4[h4]))) return 0 for (; 0 < g4[h4]; --g4[h4]) ((i4 = new l3()).g = h4), (i4.value = s4[f4++]), u3(t6, d5 + w4, o4, A4, i4), (w4 = c3(w4, h4)) } for (h4 = n4 + 1, o4 = 2; 15 >= h4; ++h4, o4 <<= 1) { if (((N4 += L4 <<= 1), 0 > (L4 -= g4[h4]))) return 0 for (; 0 < g4[h4]; --g4[h4]) { if (((i4 = new l3()), (w4 & y4) != b4)) { for ( d5 += A4, v6 = 1 << ((b4 = h4) - n4); 15 > b4 && !(0 >= (v6 -= g4[b4])); ) ++b4, (v6 <<= 1) ;(p4 += A4 = 1 << (v6 = b4 - n4)), (t6[r4 + (b4 = w4 & y4)].g = v6 + n4), (t6[r4 + b4].value = d5 - r4 - b4) } ;(i4.g = h4 - n4), (i4.value = s4[f4++]), u3(t6, d5 + (w4 >> n4), o4, A4, i4), (w4 = c3(w4, h4)) } } return N4 != 2 * m4[15] - 1 ? 0 : p4 })(t5, r3, n3, i3, o3, s3) } function l3() { this.value = this.g = 0 } function f3() { this.value = this.g = 0 } function d4() { ;(this.G = o2(5, l3)), (this.H = a2(5)), (this.jc = this.Qb = this.qb = this.nd = 0), (this.pd = o2(Dr, f3)) } function p3(t5, r3, n3, i3) { e2(null != t5), e2(null != r3), e2(2147483648 > i3), (t5.Ca = 254), (t5.I = 0), (t5.b = -8), (t5.Ka = 0), (t5.oa = r3), (t5.pa = n3), (t5.Jd = r3), (t5.Yc = n3 + i3), (t5.Zc = 4 <= i3 ? n3 + i3 - 4 + 1 : n3), _2(t5) } function g3(t5, e3) { for (var r3 = 0; 0 < e3--; ) r3 |= k2(t5, 128) << e3 return r3 } function m3(t5, e3) { var r3 = g3(t5, e3) return P2(t5) ? -r3 : r3 } function v5(t5, r3, n3, i3) { var a3, o3 = 0 for ( e2(null != t5), e2(null != r3), e2(4294967288 > i3), t5.Sb = i3, t5.Ra = 0, t5.u = 0, t5.h = 0, 4 < i3 && (i3 = 4), a3 = 0; a3 < i3; ++a3 ) o3 += r3[n3 + a3] << (8 * a3) ;(t5.Ra = o3), (t5.bb = i3), (t5.oa = r3), (t5.pa = n3) } function b3(t5) { for (; 8 <= t5.u && t5.bb < t5.Sb; ) (t5.Ra >>>= 8), (t5.Ra += (t5.oa[t5.pa + t5.bb] << (Ur - 8)) >>> 0), ++t5.bb, (t5.u -= 8) A3(t5) && ((t5.h = 1), (t5.u = 0)) } function y3(t5, r3) { if ((e2(0 <= r3), !t5.h && r3 <= Tr)) { var n3 = L3(t5) & Rr[r3] return (t5.u += r3), b3(t5), n3 } return (t5.h = 1), (t5.u = 0) } function w3() { ;(this.b = this.Ca = this.I = 0), (this.oa = []), (this.pa = 0), (this.Jd = []), (this.Yc = 0), (this.Zc = []), (this.Ka = 0) } function N3() { ;(this.Ra = 0), (this.oa = []), (this.h = this.u = this.bb = this.Sb = this.pa = 0) } function L3(t5) { return (t5.Ra >>> (t5.u & (Ur - 1))) >>> 0 } function A3(t5) { return e2(t5.bb <= t5.Sb), t5.h || (t5.bb == t5.Sb && t5.u > Ur) } function x2(t5, e3) { ;(t5.u = e3), (t5.h = A3(t5)) } function S2(t5) { t5.u >= zr && (e2(t5.u >= zr), b3(t5)) } function _2(t5) { e2(null != t5 && null != t5.oa), t5.pa < t5.Zc ? ((t5.I = (t5.oa[t5.pa++] | (t5.I << 8)) >>> 0), (t5.b += 8)) : (e2(null != t5 && null != t5.oa), t5.pa < t5.Yc ? ((t5.b += 8), (t5.I = t5.oa[t5.pa++] | (t5.I << 8))) : t5.Ka ? (t5.b = 0) : ((t5.I <<= 8), (t5.b += 8), (t5.Ka = 1))) } function P2(t5) { return g3(t5, 1) } function k2(t5, e3) { var r3 = t5.Ca 0 > t5.b && _2(t5) var n3 = t5.b, i3 = (r3 * e3) >>> 8, a3 = (t5.I >>> n3 > i3) + 0 for ( a3 ? ((r3 -= i3), (t5.I -= ((i3 + 1) << n3) >>> 0)) : (r3 = i3 + 1), n3 = r3, i3 = 0; 256 <= n3; ) (i3 += 8), (n3 >>= 8) return ( (n3 = 7 ^ (i3 + Hr[n3])), (t5.b -= n3), (t5.Ca = (r3 << n3) - 1), a3 ) } function I2(t5, e3, r3) { ;(t5[e3 + 0] = (r3 >> 24) & 255), (t5[e3 + 1] = (r3 >> 16) & 255), (t5[e3 + 2] = (r3 >> 8) & 255), (t5[e3 + 3] = (r3 >> 0) & 255) } function F2(t5, e3) { return (t5[e3 + 0] << 0) | (t5[e3 + 1] << 8) } function C2(t5, e3) { return F2(t5, e3) | (t5[e3 + 2] << 16) } function j2(t5, e3) { return F2(t5, e3) | (F2(t5, e3 + 2) << 16) } function O2(t5, r3) { var n3 = 1 << r3 return ( e2(null != t5), e2(0 < r3), (t5.X = a2(n3)), null == t5.X ? 0 : ((t5.Mb = 32 - r3), (t5.Xa = r3), 1) ) } function B3(t5, r3) { e2(null != t5), e2(null != r3), e2(t5.Xa == r3.Xa), n2(r3.X, 0, t5.X, 0, 1 << r3.Xa) } function M2() { ;(this.X = []), (this.Xa = this.Mb = 0) } function E2(t5, r3, n3, i3) { e2(null != n3), e2(null != i3) var a3 = n3[0], o3 = i3[0] return ( 0 == a3 && (a3 = (t5 * o3 + r3 / 2) / r3), 0 == o3 && (o3 = (r3 * a3 + t5 / 2) / t5), 0 >= a3 || 0 >= o3 ? 0 : ((n3[0] = a3), (i3[0] = o3), 1) ) } function q2(t5, e3) { return (t5 + (1 << e3) - 1) >>> e3 } function D2(t5, e3) { return ( (((((4278255360 & t5) + (4278255360 & e3)) >>> 0) & 4278255360) + ((((16711935 & t5) + (16711935 & e3)) >>> 0) & 16711935)) >>> 0 ) } function R2(e3, r3) { t4[r3] = function (r4, n3, i3, a3, o3, s3, c4) { var u4 for (u4 = 0; u4 < o3; ++u4) { var h4 = t4[e3](s3[c4 + u4 - 1], i3, a3 + u4) s3[c4 + u4] = D2(r4[n3 + u4], h4) } } } function T2() { this.ud = this.hd = this.jd = 0 } function U2(t5, e3) { return (((4278124286 & (t5 ^ e3)) >>> 1) + (t5 & e3)) >>> 0 } function z2(t5) { return 0 <= t5 && 256 > t5 ? t5 : 0 > t5 ? 0 : 255 < t5 ? 255 : void 0 } function H4(t5, e3) { return z2(t5 + ((t5 - e3 + 0.5) >> 1)) } function W2(t5, e3, r3) { return Math.abs(e3 - r3) - Math.abs(t5 - r3) } function V2(t5, e3, r3, n3, i3, a3, o3) { for (n3 = a3[o3 - 1], r3 = 0; r3 < i3; ++r3) a3[o3 + r3] = n3 = D2(t5[e3 + r3], n3) } function G2(t5, e3, r3, n3, i3) { var a3 for (a3 = 0; a3 < r3; ++a3) { var o3 = t5[e3 + a3], s3 = (o3 >> 8) & 255, c4 = 16711935 & (c4 = (c4 = 16711935 & o3) + ((s3 << 16) + s3)) n3[i3 + a3] = ((4278255360 & o3) + c4) >>> 0 } } function Y2(t5, e3) { ;(e3.jd = (t5 >> 0) & 255), (e3.hd = (t5 >> 8) & 255), (e3.ud = (t5 >> 16) & 255) } function J2(t5, e3, r3, n3, i3, a3) { var o3 for (o3 = 0; o3 < n3; ++o3) { var s3 = e3[r3 + o3], c4 = s3 >>> 8, u4 = s3, h4 = 255 & (h4 = (h4 = s3 >>> 16) + ((((t5.jd << 24) >> 24) * ((c4 << 24) >> 24)) >>> 5)) u4 = 255 & (u4 = (u4 = u4 + ((((t5.hd << 24) >> 24) * ((c4 << 24) >> 24)) >>> 5)) + ((((t5.ud << 24) >> 24) * ((h4 << 24) >> 24)) >>> 5)) i3[a3 + o3] = (4278255360 & s3) + (h4 << 16) + u4 } } function X2(e3, r3, n3, i3, a3) { ;(t4[r3] = function (t5, e4, r4, n4, o3, s3, c4, u4, h4) { for (n4 = c4; n4 < u4; ++n4) for (c4 = 0; c4 < h4; ++c4) o3[s3++] = a3(r4[i3(t5[e4++])]) }), (t4[e3] = function (e4, r4, o3, s3, c4, u4, h4) { var l4 = 8 >> e4.b, f4 = e4.Ea, d5 = e4.K[0], p4 = e4.w if (8 > l4) for (e4 = (1 << e4.b) - 1, p4 = (1 << l4) - 1; r4 < o3; ++r4) { var g4, m4 = 0 for (g4 = 0; g4 < f4; ++g4) g4 & e4 || (m4 = i3(s3[c4++])), (u4[h4++] = a3(d5[m4 & p4])), (m4 >>= l4) } else t4['VP8LMapColor' + n3](s3, c4, d5, p4, u4, h4, r4, o3, f4) }) } function K2(t5, e3, r3, n3, i3) { for (r3 = e3 + r3; e3 < r3; ) { var a3 = t5[e3++] ;(n3[i3++] = (a3 >> 16) & 255), (n3[i3++] = (a3 >> 8) & 255), (n3[i3++] = (a3 >> 0) & 255) } } function Z2(t5, e3, r3, n3, i3) { for (r3 = e3 + r3; e3 < r3; ) { var a3 = t5[e3++] ;(n3[i3++] = (a3 >> 16) & 255), (n3[i3++] = (a3 >> 8) & 255), (n3[i3++] = (a3 >> 0) & 255), (n3[i3++] = (a3 >> 24) & 255) } } function $2(t5, e3, r3, n3, i3) { for (r3 = e3 + r3; e3 < r3; ) { var a3 = (((o3 = t5[e3++]) >> 16) & 240) | ((o3 >> 12) & 15), o3 = ((o3 >> 0) & 240) | ((o3 >> 28) & 15) ;(n3[i3++] = a3), (n3[i3++] = o3) } } function Q2(t5, e3, r3, n3, i3) { for (r3 = e3 + r3; e3 < r3; ) { var a3 = (((o3 = t5[e3++]) >> 16) & 248) | ((o3 >> 13) & 7), o3 = ((o3 >> 5) & 224) | ((o3 >> 3) & 31) ;(n3[i3++] = a3), (n3[i3++] = o3) } } function tt2(t5, e3, r3, n3, i3) { for (r3 = e3 + r3; e3 < r3; ) { var a3 = t5[e3++] ;(n3[i3++] = (a3 >> 0) & 255), (n3[i3++] = (a3 >> 8) & 255), (n3[i3++] = (a3 >> 16) & 255) } } function et2(t5, e3, r3, i3, a3, o3) { if (0 == o3) for (r3 = e3 + r3; e3 < r3; ) I2( i3, (((o3 = t5[e3++])[0] >> 24) | ((o3[1] >> 8) & 65280) | ((o3[2] << 8) & 16711680) | (o3[3] << 24)) >>> 0 ), (a3 += 32) else n2(i3, a3, t5, e3, r3) } function rt2(e3, r3) { ;(t4[r3][0] = t4[e3 + '0']), (t4[r3][1] = t4[e3 + '1']), (t4[r3][2] = t4[e3 + '2']), (t4[r3][3] = t4[e3 + '3']), (t4[r3][4] = t4[e3 + '4']), (t4[r3][5] = t4[e3 + '5']), (t4[r3][6] = t4[e3 + '6']), (t4[r3][7] = t4[e3 + '7']), (t4[r3][8] = t4[e3 + '8']), (t4[r3][9] = t4[e3 + '9']), (t4[r3][10] = t4[e3 + '10']), (t4[r3][11] = t4[e3 + '11']), (t4[r3][12] = t4[e3 + '12']), (t4[r3][13] = t4[e3 + '13']), (t4[r3][14] = t4[e3 + '0']), (t4[r3][15] = t4[e3 + '0']) } function nt2(t5) { return t5 == Hn || t5 == Wn || t5 == Vn || t5 == Gn } function it2() { ;(this.eb = []), (this.size = this.A = this.fb = 0) } function at2() { ;(this.y = []), (this.f = []), (this.ea = []), (this.F = []), (this.Tc = this.Ed = this.Cd = this.Fd = this.lb = this.Db = this.Ab = this.fa = this.J = this.W = this.N = this.O = 0) } function ot2() { ;(this.Rd = this.height = this.width = this.S = 0), (this.f = {}), (this.f.RGBA = new it2()), (this.f.kb = new at2()), (this.sd = null) } function st2() { ;(this.width = [0]), (this.height = [0]), (this.Pd = [0]), (this.Qd = [0]), (this.format = [0]) } function ct2() { this.Id = this.fd = this.Md = this.hb = this.ib = this.da = this.bd = this.cd = this.j = this.v = this.Da = this.Sd = this.ob = 0 } function ut2(t5) { return alert('todo:WebPSamplerProcessPlane'), t5.T } function ht2(t5, e3) { var r3 = t5.T, i3 = e3.ba.f.RGBA, a3 = i3.eb, o3 = i3.fb + t5.ka * i3.A, s3 = vi2[e3.ba.S], c4 = t5.y, u4 = t5.O, h4 = t5.f, l4 = t5.N, f4 = t5.ea, d5 = t5.W, p4 = e3.cc, g4 = e3.dc, m4 = e3.Mc, v6 = e3.Nc, b4 = t5.ka, y4 = t5.ka + t5.T, w4 = t5.U, N4 = (w4 + 1) >> 1 for ( 0 == b4 ? s3( c4, u4, null, null, h4, l4, f4, d5, h4, l4, f4, d5, a3, o3, null, null, w4 ) : (s3( e3.ec, e3.fc, c4, u4, p4, g4, m4, v6, h4, l4, f4, d5, a3, o3 - i3.A, a3, o3, w4 ), ++r3); b4 + 2 < y4; b4 += 2 ) (p4 = h4), (g4 = l4), (m4 = f4), (v6 = d5), (l4 += t5.Rc), (d5 += t5.Rc), (o3 += 2 * i3.A), s3( c4, (u4 += 2 * t5.fa) - t5.fa, c4, u4, p4, g4, m4, v6, h4, l4, f4, d5, a3, o3 - i3.A, a3, o3, w4 ) return ( (u4 += t5.fa), t5.j + y4 < t5.o ? (n2(e3.ec, e3.fc, c4, u4, w4), n2(e3.cc, e3.dc, h4, l4, N4), n2(e3.Mc, e3.Nc, f4, d5, N4), r3--) : 1 & y4 || s3( c4, u4, null, null, h4, l4, f4, d5, h4, l4, f4, d5, a3, o3 + i3.A, null, null, w4 ), r3 ) } function lt2(t5, r3, n3) { var i3 = t5.F, a3 = [t5.J] if (null != i3) { var o3 = t5.U, s3 = r3.ba.S, c4 = s3 == Tn || s3 == Vn r3 = r3.ba.f.RGBA var u4 = [0], h4 = t5.ka ;(u4[0] = t5.T), t5.Kb && (0 == h4 ? --u4[0] : (--h4, (a3[0] -= t5.width)), t5.j + t5.ka + t5.T == t5.o && (u4[0] = t5.o - t5.j - h4)) var l4 = r3.eb h4 = r3.fb + h4 * r3.A ;(t5 = Sn(i3, a3[0], t5.width, o3, u4, l4, h4 + (c4 ? 0 : 3), r3.A)), e2(n3 == u4), t5 && nt2(s3) && An(l4, h4, c4, o3, u4, r3.A) } return 0 } function ft2(t5) { var e3 = t5.ma, r3 = e3.ba.S, n3 = 11 > r3, i3 = r3 == qn || r3 == Rn || r3 == Tn || r3 == Un || 12 == r3 || nt2(r3) if ( ((e3.memory = null), (e3.Ib = null), (e3.Jb = null), (e3.Nd = null), !Mr(e3.Oa, t5, i3 ? 11 : 12)) ) return 0 if ((i3 && nt2(r3) && br(), t5.da)) alert('todo:use_scaling') else { if (n3) { if (((e3.Ib = ut2), t5.Kb)) { if ( ((r3 = (t5.U + 1) >> 1), (e3.memory = a2(t5.U + 2 * r3)), null == e3.memory) ) return 0 ;(e3.ec = e3.memory), (e3.fc = 0), (e3.cc = e3.ec), (e3.dc = e3.fc + t5.U), (e3.Mc = e3.cc), (e3.Nc = e3.dc + r3), (e3.Ib = ht2), br() } } else alert('todo:EmitYUV') i3 && ((e3.Jb = lt2), n3 && mr()) } if (n3 && !Ci) { for (t5 = 0; 256 > t5; ++t5) (ji[t5] = (89858 * (t5 - 128) + _i) >> Si), (Mi[t5] = -22014 * (t5 - 128) + _i), (Bi[t5] = -45773 * (t5 - 128)), (Oi[t5] = (113618 * (t5 - 128) + _i) >> Si) for (t5 = Pi; t5 < ki; ++t5) (e3 = (76283 * (t5 - 16) + _i) >> Si), (Ei[t5 - Pi] = Vt2(e3, 255)), (qi[t5 - Pi] = Vt2((e3 + 8) >> 4, 15)) Ci = 1 } return 1 } function dt2(t5) { var r3 = t5.ma, n3 = t5.U, i3 = t5.T return ( e2(!(1 & t5.ka)), 0 >= n3 || 0 >= i3 ? 0 : ((n3 = r3.Ib(t5, r3)), null != r3.Jb && r3.Jb(t5, r3, n3), (r3.Dc += n3), 1) ) } function pt3(t5) { t5.ma.memory = null } function gt2(t5, e3, r3, n3) { return 47 != y3(t5, 8) ? 0 : ((e3[0] = y3(t5, 14) + 1), (r3[0] = y3(t5, 14) + 1), (n3[0] = y3(t5, 1)), 0 != y3(t5, 3) ? 0 : !t5.h) } function mt2(t5, e3) { if (4 > t5) return t5 + 1 var r3 = (t5 - 2) >> 1 return ((2 + (1 & t5)) << r3) + y3(e3, r3) + 1 } function vt2(t5, e3) { return 120 < e3 ? e3 - 120 : 1 <= (r3 = ((r3 = $n[e3 - 1]) >> 4) * t5 + (8 - (15 & r3))) ? r3 : 1 var r3 } function bt2(t5, e3, r3) { var n3 = L3(r3), i3 = t5[(e3 += 255 & n3)].g - 8 return ( 0 < i3 && (x2(r3, r3.u + 8), (n3 = L3(r3)), (e3 += t5[e3].value), (e3 += n3 & ((1 << i3) - 1))), x2(r3, r3.u + t5[e3].g), t5[e3].value ) } function yt2(t5, r3, n3) { return ( (n3.g += t5.g), (n3.value += (t5.value << r3) >>> 0), e2(8 >= n3.g), t5.g ) } function wt2(t5, r3, n3) { var i3 = t5.xc return ( e2((r3 = 0 == i3 ? 0 : t5.vc[t5.md * (n3 >> i3) + (r3 >> i3)]) < t5.Wb), t5.Ya[r3] ) } function Nt2(t5, r3, i3, a3) { var o3 = t5.ab, s3 = t5.c * r3, c4 = t5.C r3 = c4 + r3 var u4 = i3, h4 = a3 for (a3 = t5.Ta, i3 = t5.Ua; 0 < o3--; ) { var l4 = t5.gc[o3], f4 = c4, d5 = r3, p4 = u4, g4 = h4, m4 = ((h4 = a3), (u4 = i3), l4.Ea) switch ((e2(f4 < d5), e2(d5 <= l4.nc), l4.hc)) { case 2: Gr(p4, g4, (d5 - f4) * m4, h4, u4) break case 0: var v6 = f4, b4 = d5, y4 = h4, w4 = u4, N4 = (_3 = l4).Ea 0 == v6 && (Wr(p4, g4, null, null, 1, y4, w4), V2(p4, g4 + 1, 0, 0, N4 - 1, y4, w4 + 1), (g4 += N4), (w4 += N4), ++v6) for ( var L4 = 1 << _3.b, A4 = L4 - 1, x3 = q2(N4, _3.b), S3 = _3.K, _3 = _3.w + (v6 >> _3.b) * x3; v6 < b4; ) { var P3 = S3, k3 = _3, I3 = 1 for (Vr(p4, g4, y4, w4 - N4, 1, y4, w4); I3 < N4; ) { var F3 = (I3 & ~A4) + L4 F3 > N4 && (F3 = N4), (0, Zr[(P3[k3++] >> 8) & 15])( p4, g4 + +I3, y4, w4 + I3 - N4, F3 - I3, y4, w4 + I3 ), (I3 = F3) } ;(g4 += N4), (w4 += N4), ++v6 & A4 || (_3 += x3) } d5 != l4.nc && n2(h4, u4 - m4, h4, u4 + (d5 - f4 - 1) * m4, m4) break case 1: for ( m4 = p4, b4 = g4, N4 = (p4 = l4.Ea) - (w4 = p4 & ~(y4 = (g4 = 1 << l4.b) - 1)), v6 = q2(p4, l4.b), L4 = l4.K, l4 = l4.w + (f4 >> l4.b) * v6; f4 < d5; ) { for ( A4 = L4, x3 = l4, S3 = new T2(), _3 = b4 + w4, P3 = b4 + p4; b4 < _3; ) Y2(A4[x3++], S3), $r(S3, m4, b4, g4, h4, u4), (b4 += g4), (u4 += g4) b4 < P3 && (Y2(A4[x3++], S3), $r(S3, m4, b4, N4, h4, u4), (b4 += N4), (u4 += N4)), ++f4 & y4 || (l4 += v6) } break case 3: if (p4 == h4 && g4 == u4 && 0 < l4.b) { for ( b4 = h4, p4 = m4 = u4 + (d5 - f4) * m4 - (w4 = (d5 - f4) * q2(l4.Ea, l4.b)), g4 = h4, y4 = u4, v6 = [], w4 = (N4 = w4) - 1; 0 <= w4; --w4 ) v6[w4] = g4[y4 + w4] for (w4 = N4 - 1; 0 <= w4; --w4) b4[p4 + w4] = v6[w4] Yr(l4, f4, d5, h4, m4, h4, u4) } else Yr(l4, f4, d5, p4, g4, h4, u4) } ;(u4 = a3), (h4 = i3) } h4 != i3 && n2(a3, i3, u4, h4, s3) } function Lt2(t5, r3) { var n3 = t5.V, i3 = t5.Ba + t5.c * t5.C, a3 = r3 - t5.C if ((e2(r3 <= t5.l.o), e2(16 >= a3), 0 < a3)) { var o3 = t5.l, s3 = t5.Ta, c4 = t5.Ua, u4 = o3.width if ( (Nt2(t5, a3, n3, i3), (a3 = c4 = [c4]), e2((n3 = t5.C) < (i3 = r3)), e2(o3.v < o3.va), i3 > o3.o && (i3 = o3.o), n3 < o3.j) ) { var h4 = o3.j - n3 n3 = o3.j a3[0] += h4 * u4 } if ( (n3 >= i3 ? (n3 = 0) : ((a3[0] += 4 * o3.v), (o3.ka = n3 - o3.j), (o3.U = o3.va - o3.v), (o3.T = i3 - n3), (n3 = 1)), n3) ) { if (((c4 = c4[0]), 11 > (n3 = t5.ca).S)) { var l4 = n3.f.RGBA, f4 = ((i3 = n3.S), (a3 = o3.U), (o3 = o3.T), (h4 = l4.eb), l4.A), d5 = o3 for (l4 = l4.fb + t5.Ma * l4.A; 0 < d5--; ) { var p4 = s3, g4 = c4, m4 = a3, v6 = h4, b4 = l4 switch (i3) { case En: Qr(p4, g4, m4, v6, b4) break case qn: tn(p4, g4, m4, v6, b4) break case Hn: tn(p4, g4, m4, v6, b4), An(v6, b4, 0, m4, 1, 0) break case Dn: nn(p4, g4, m4, v6, b4) break case Rn: et2(p4, g4, m4, v6, b4, 1) break case Wn: et2(p4, g4, m4, v6, b4, 1), An(v6, b4, 0, m4, 1, 0) break case Tn: et2(p4, g4, m4, v6, b4, 0) break case Vn: et2(p4, g4, m4, v6, b4, 0), An(v6, b4, 1, m4, 1, 0) break case Un: en2(p4, g4, m4, v6, b4) break case Gn: en2(p4, g4, m4, v6, b4), xn(v6, b4, m4, 1, 0) break case zn: rn(p4, g4, m4, v6, b4) break default: e2(0) } ;(c4 += u4), (l4 += f4) } t5.Ma += o3 } else alert('todo:EmitRescaledRowsYUVA') e2(t5.Ma <= n3.height) } } ;(t5.C = r3), e2(t5.C <= t5.i) } function At2(t5) { var e3 if (0 < t5.ua) return 0 for (e3 = 0; e3 < t5.Wb; ++e3) { var r3 = t5.Ya[e3].G, n3 = t5.Ya[e3].H if ( 0 < r3[1][n3[1] + 0].g || 0 < r3[2][n3[2] + 0].g || 0 < r3[3][n3[3] + 0].g ) return 0 } return 1 } function xt2(t5, r3, n3, i3, a3, o3) { if (0 != t5.Z) { var s3 = t5.qd, c4 = t5.rd for (e2(null != mi[t5.Z]); r3 < n3; ++r3) mi[t5.Z](s3, c4, i3, a3, i3, a3, o3), (s3 = i3), (c4 = a3), (a3 += o3) ;(t5.qd = s3), (t5.rd = c4) } } function St(t5, r3) { var n3 = t5.l.ma, i3 = 0 == n3.Z || 1 == n3.Z ? t5.l.j : t5.C i3 = t5.C < i3 ? i3 : t5.C if ((e2(r3 <= t5.l.o), r3 > i3)) { var a3 = t5.l.width, o3 = n3.ca, s3 = n3.tb + a3 * i3, c4 = t5.V, u4 = t5.Ba + t5.c * i3, h4 = t5.gc e2(1 == t5.ab), e2(3 == h4[0].hc), Xr(h4[0], i3, r3, c4, u4, o3, s3), xt2(n3, i3, r3, o3, s3, a3) } t5.C = t5.Ma = r3 } function _t2(t5, r3, n3, i3, a3, o3, s3) { var c4 = t5.$ / i3, u4 = t5.$ % i3, h4 = t5.m, l4 = t5.s, f4 = n3 + t5.$, d5 = f4 a3 = n3 + i3 * a3 var p4 = n3 + i3 * o3, g4 = 280 + l4.ua, m4 = t5.Pb ? c4 : 16777216, v6 = 0 < l4.ua ? l4.Wa : null, b4 = l4.wc, y4 = f4 < p4 ? wt2(l4, u4, c4) : null e2(t5.C < o3), e2(p4 <= a3) var w4 = false t: for (;;) { for (; w4 || f4 < p4; ) { var N4 = 0 if (c4 >= m4) { var _3 = f4 - n3 e2((m4 = t5).Pb), (m4.wd = m4.m), (m4.xd = _3), 0 < m4.s.ua && B3(m4.s.Wa, m4.s.vb), (m4 = c4 + ti) } if ( (u4 & b4 || (y4 = wt2(l4, u4, c4)), e2(null != y4), y4.Qb && ((r3[f4] = y4.qb), (w4 = true)), !w4) ) if ((S2(h4), y4.jc)) { ;(N4 = h4), (_3 = r3) var P3 = f4, k3 = y4.pd[L3(N4) & (Dr - 1)] e2(y4.jc), 256 > k3.g ? (x2(N4, N4.u + k3.g), (_3[P3] = k3.value), (N4 = 0)) : (x2(N4, N4.u + k3.g - 256), e2(256 <= k3.value), (N4 = k3.value)), 0 == N4 && (w4 = true) } else N4 = bt2(y4.G[0], y4.H[0], h4) if (h4.h) break if (w4 || 256 > N4) { if (!w4) if (y4.nd) r3[f4] = (y4.qb | (N4 << 8)) >>> 0 else { if ( (S2(h4), (w4 = bt2(y4.G[1], y4.H[1], h4)), S2(h4), (_3 = bt2(y4.G[2], y4.H[2], h4)), (P3 = bt2(y4.G[3], y4.H[3], h4)), h4.h) ) break r3[f4] = ((P3 << 24) | (w4 << 16) | (N4 << 8) | _3) >>> 0 } if ( ((w4 = false), ++f4, ++u4 >= i3 && ((u4 = 0), ++c4, null != s3 && c4 <= o3 && !(c4 % 16) && s3(t5, c4), null != v6)) ) for (; d5 < f4; ) (N4 = r3[d5++]), (v6.X[((506832829 * N4) & 4294967295) >>> v6.Mb] = N4) } else if (280 > N4) { if ( ((N4 = mt2(N4 - 256, h4)), (_3 = bt2(y4.G[4], y4.H[4], h4)), S2(h4), (_3 = vt2(i3, (_3 = mt2(_3, h4)))), h4.h) ) break if (f4 - n3 < _3 || a3 - f4 < N4) break t for (P3 = 0; P3 < N4; ++P3) r3[f4 + P3] = r3[f4 + P3 - _3] for (f4 += N4, u4 += N4; u4 >= i3; ) (u4 -= i3), ++c4, null != s3 && c4 <= o3 && !(c4 % 16) && s3(t5, c4) if ((e2(f4 <= a3), u4 & b4 && (y4 = wt2(l4, u4, c4)), null != v6)) for (; d5 < f4; ) (N4 = r3[d5++]), (v6.X[((506832829 * N4) & 4294967295) >>> v6.Mb] = N4) } else { if (!(N4 < g4)) break t for (w4 = N4 - 280, e2(null != v6); d5 < f4; ) (N4 = r3[d5++]), (v6.X[((506832829 * N4) & 4294967295) >>> v6.Mb] = N4) ;(N4 = f4), e2(!(w4 >>> (_3 = v6).Xa)), (r3[N4] = _3.X[w4]), (w4 = true) } w4 || e2(h4.h == A3(h4)) } if (t5.Pb && h4.h && f4 < a3) e2(t5.m.h), (t5.a = 5), (t5.m = t5.wd), (t5.$ = t5.xd), 0 < t5.s.ua && B3(t5.s.vb, t5.s.Wa) else { if (h4.h) break t null != s3 && s3(t5, c4 > o3 ? o3 : c4), (t5.a = 0), (t5.$ = f4 - n3) } return 1 } return (t5.a = 3), 0 } function Pt2(t5) { e2(null != t5), (t5.vc = null), (t5.yc = null), (t5.Ya = null) var r3 = t5.Wa null != r3 && (r3.X = null), (t5.vb = null), e2(null != t5) } function kt2() { var e3 = new or() return null == e3 ? null : ((e3.a = 0), (e3.xb = gi), rt2('Predictor', 'VP8LPredictors'), rt2('Predictor', 'VP8LPredictors_C'), rt2('PredictorAdd', 'VP8LPredictorsAdd'), rt2('PredictorAdd', 'VP8LPredictorsAdd_C'), (Gr = G2), ($r = J2), (Qr = K2), (tn = Z2), (en2 = $2), (rn = Q2), (nn = tt2), (t4.VP8LMapColor32b = Jr), (t4.VP8LMapColor8b = Kr), e3) } function It2(t5, r3, n3, s3, c4) { var u4 = 1, f4 = [t5], p4 = [r3], g4 = s3.m, m4 = s3.s, v6 = null, b4 = 0 t: for (;;) { if (n3) for (; u4 && y3(g4, 1); ) { var w4 = f4, N4 = p4, A4 = s3, _3 = 1, P3 = A4.m, k3 = A4.gc[A4.ab], I3 = y3(P3, 2) if (A4.Oc & (1 << I3)) u4 = 0 else { switch ( ((A4.Oc |= 1 << I3), (k3.hc = I3), (k3.Ea = w4[0]), (k3.nc = N4[0]), (k3.K = [null]), ++A4.ab, e2(4 >= A4.ab), I3) ) { case 0: case 1: ;(k3.b = y3(P3, 3) + 2), (_3 = It2(q2(k3.Ea, k3.b), q2(k3.nc, k3.b), 0, A4, k3.K)), (k3.K = k3.K[0]) break case 3: var F3, C3 = y3(P3, 8) + 1, j3 = 16 < C3 ? 0 : 4 < C3 ? 1 : 2 < C3 ? 2 : 3 if ( ((w4[0] = q2(k3.Ea, j3)), (k3.b = j3), (F3 = _3 = It2(C3, 1, 0, A4, k3.K))) ) { var B4, M3 = C3, E3 = k3, R3 = 1 << (8 >> E3.b), T3 = a2(R3) if (null == T3) F3 = 0 else { var U3 = E3.K[0], z3 = E3.w for (T3[0] = E3.K[0][0], B4 = 1; B4 < 1 * M3; ++B4) T3[B4] = D2(U3[z3 + B4], T3[B4 - 1]) for (; B4 < 4 * R3; ++B4) T3[B4] = 0 ;(E3.K[0] = null), (E3.K[0] = T3), (F3 = 1) } } _3 = F3 break case 2: break default: e2(0) } u4 = _3 } } if ( ((f4 = f4[0]), (p4 = p4[0]), u4 && y3(g4, 1) && !(u4 = 1 <= (b4 = y3(g4, 4)) && 11 >= b4)) ) { s3.a = 3 break t } var H5 if ((H5 = u4)) e: { var W3, V3, G3, Y3 = s3, J3 = f4, X3 = p4, K3 = b4, Z3 = n3, $3 = Y3.m, Q3 = Y3.s, tt3 = [null], et3 = 1, rt3 = 0, nt3 = Qn[K3] r: for (;;) { if (Z3 && y3($3, 1)) { var it3 = y3($3, 3) + 2, at3 = q2(J3, it3), ot3 = q2(X3, it3), st3 = at3 * ot3 if (!It2(at3, ot3, 0, Y3, tt3)) break r for (tt3 = tt3[0], Q3.xc = it3, W3 = 0; W3 < st3; ++W3) { var ct3 = (tt3[W3] >> 8) & 65535 ;(tt3[W3] = ct3), ct3 >= et3 && (et3 = ct3 + 1) } } if ($3.h) break r for (V3 = 0; 5 > V3; ++V3) { var ut3 = Xn[V3] !V3 && 0 < K3 && (ut3 += 1 << K3), rt3 < ut3 && (rt3 = ut3) } var ht3 = o2(et3 * nt3, l3), lt3 = et3, ft3 = o2(lt3, d4) if (null == ft3) var dt3 = null else e2(65536 >= lt3), (dt3 = ft3) var pt4 = a2(rt3) if (null == dt3 || null == pt4 || null == ht3) { Y3.a = 1 break r } var gt3 = ht3 for (W3 = G3 = 0; W3 < et3; ++W3) { var mt3 = dt3[W3], vt3 = mt3.G, bt3 = mt3.H, wt3 = 0, Nt3 = 1, Lt3 = 0 for (V3 = 0; 5 > V3; ++V3) { ;(ut3 = Xn[V3]), (vt3[V3] = gt3), (bt3[V3] = G3), !V3 && 0 < K3 && (ut3 += 1 << K3) n: { var At3, xt3 = ut3, St2 = Y3, kt3 = pt4, Ft3 = gt3, Ct3 = G3, jt3 = 0, Ot3 = St2.m, Bt3 = y3(Ot3, 1) if ((i2(kt3, 0, 0, xt3), Bt3)) { var Mt3 = y3(Ot3, 1) + 1, Et3 = y3(Ot3, 1), qt3 = y3(Ot3, 0 == Et3 ? 1 : 8) ;(kt3[qt3] = 1), 2 == Mt3 && (kt3[(qt3 = y3(Ot3, 8))] = 1) var Dt3 = 1 } else { var Rt3 = a2(19), Tt3 = y3(Ot3, 4) + 4 if (19 < Tt3) { St2.a = 3 var Ut3 = 0 break n } for (At3 = 0; At3 < Tt3; ++At3) Rt3[Zn[At3]] = y3(Ot3, 3) var zt3 = void 0, Ht3 = void 0, Wt3 = St2, Vt3 = Rt3, Gt3 = xt3, Yt3 = kt3, Jt3 = 0, Xt3 = Wt3.m, Kt3 = 8, Zt3 = o2(128, l3) i: for (; h3(Zt3, 0, 7, Vt3, 19); ) { if (y3(Xt3, 1)) { var $t3 = 2 + 2 * y3(Xt3, 3) if ((zt3 = 2 + y3(Xt3, $t3)) > Gt3) break i } else zt3 = Gt3 for (Ht3 = 0; Ht3 < Gt3 && zt3--; ) { S2(Xt3) var Qt3 = Zt3[0 + (127 & L3(Xt3))] x2(Xt3, Xt3.u + Qt3.g) var te3 = Qt3.value if (16 > te3) (Yt3[Ht3++] = te3), 0 != te3 && (Kt3 = te3) else { var ee3 = 16 == te3, re3 = te3 - 16, ne3 = Jn[re3], ie3 = y3(Xt3, Yn[re3]) + ne3 if (Ht3 + ie3 > Gt3) break i for (var ae3 = ee3 ? Kt3 : 0; 0 < ie3--; ) Yt3[Ht3++] = ae3 } } Jt3 = 1 break i } Jt3 || (Wt3.a = 3), (Dt3 = Jt3) } ;(Dt3 = Dt3 && !Ot3.h) && (jt3 = h3(Ft3, Ct3, 8, kt3, xt3)), Dt3 && 0 != jt3 ? (Ut3 = jt3) : ((St2.a = 3), (Ut3 = 0)) } if (0 == Ut3) break r if ( (Nt3 && 1 == Kn[V3] && (Nt3 = 0 == gt3[G3].g), (wt3 += gt3[G3].g), (G3 += Ut3), 3 >= V3) ) { var oe3, se3 = pt4[0] for (oe3 = 1; oe3 < ut3; ++oe3) pt4[oe3] > se3 && (se3 = pt4[oe3]) Lt3 += se3 } } if ( ((mt3.nd = Nt3), (mt3.Qb = 0), Nt3 && ((mt3.qb = ((vt3[3][bt3[3] + 0].value << 24) | (vt3[1][bt3[1] + 0].value << 16) | vt3[2][bt3[2] + 0].value) >>> 0), 0 == wt3 && 256 > vt3[0][bt3[0] + 0].value && ((mt3.Qb = 1), (mt3.qb += vt3[0][bt3[0] + 0].value << 8))), (mt3.jc = !mt3.Qb && 6 > Lt3), mt3.jc) ) { var ce3, ue3 = mt3 for (ce3 = 0; ce3 < Dr; ++ce3) { var he3 = ce3, le3 = ue3.pd[he3], fe3 = ue3.G[0][ue3.H[0] + he3] 256 <= fe3.value ? ((le3.g = fe3.g + 256), (le3.value = fe3.value)) : ((le3.g = 0), (le3.value = 0), (he3 >>= yt2(fe3, 8, le3)), (he3 >>= yt2(ue3.G[1][ue3.H[1] + he3], 16, le3)), (he3 >>= yt2(ue3.G[2][ue3.H[2] + he3], 0, le3)), yt2(ue3.G[3][ue3.H[3] + he3], 24, le3)) } } } ;(Q3.vc = tt3), (Q3.Wb = et3), (Q3.Ya = dt3), (Q3.yc = ht3), (H5 = 1) break e } H5 = 0 } if (!(u4 = H5)) { s3.a = 3 break t } if (0 < b4) { if (((m4.ua = 1 << b4), !O2(m4.Wa, b4))) { ;(s3.a = 1), (u4 = 0) break t } } else m4.ua = 0 var de3 = s3, pe3 = f4, ge3 = p4, me3 = de3.s, ve3 = me3.xc if ( ((de3.c = pe3), (de3.i = ge3), (me3.md = q2(pe3, ve3)), (me3.wc = 0 == ve3 ? -1 : (1 << ve3) - 1), n3) ) { s3.xb = pi break t } if (null == (v6 = a2(f4 * p4))) { ;(s3.a = 1), (u4 = 0) break t } u4 = (u4 = _t2(s3, v6, 0, f4, p4, p4, null)) && !g4.h break t } return ( u4 ? (null != c4 ? (c4[0] = v6) : (e2(null == v6), e2(n3)), (s3.$ = 0), n3 || Pt2(m4)) : Pt2(m4), u4 ) } function Ft2(t5, r3) { var n3 = t5.c * t5.i, i3 = n3 + r3 + 16 * r3 return ( e2(t5.c <= r3), (t5.V = a2(i3)), null == t5.V ? ((t5.Ta = null), (t5.Ua = 0), (t5.a = 1), 0) : ((t5.Ta = t5.V), (t5.Ua = t5.Ba + n3 + r3), 1) ) } function Ct2(t5, r3) { var n3 = t5.C, i3 = r3 - n3, a3 = t5.V, o3 = t5.Ba + t5.c * n3 for (e2(r3 <= t5.l.o); 0 < i3; ) { var s3 = 16 < i3 ? 16 : i3, c4 = t5.l.ma, u4 = t5.l.width, h4 = u4 * s3, l4 = c4.ca, f4 = c4.tb + u4 * n3, d5 = t5.Ta, p4 = t5.Ua Nt2(t5, s3, a3, o3), _n(d5, p4, l4, f4, h4), xt2(c4, n3, n3 + s3, l4, f4, u4), (i3 -= s3), (a3 += s3 * t5.c), (n3 += s3) } e2(n3 == r3), (t5.C = t5.Ma = r3) } function jt2() { this.ub = this.yd = this.td = this.Rb = 0 } function Ot2() { this.Kd = this.Ld = this.Ud = this.Td = this.i = this.c = 0 } function Bt2() { ;(this.Fb = this.Bb = this.Cb = 0), (this.Zb = a2(4)), (this.Lb = a2(4)) } function Mt2() { this.Yb = (function () { var t5 = [] return ( (function t6(e3, r3, n3) { for ( var i3 = n3[r3], a3 = 0; a3 < i3 && (e3.push(n3.length > r3 + 1 ? [] : 0), !(n3.length < r3 + 1)); a3++ ) t6(e3[a3], r3 + 1, n3) })(t5, 0, [3, 11]), t5 ) })() } function Et2() { ;(this.jb = a2(3)), (this.Wc = s2([4, 8], Mt2)), (this.Xc = s2([4, 17], Mt2)) } function qt2() { ;(this.Pc = this.wb = this.Tb = this.zd = 0), (this.vd = new a2(4)), (this.od = new a2(4)) } function Dt2() { this.ld = this.La = this.dd = this.tc = 0 } function Rt2() { this.Na = this.la = 0 } function Tt2() { ;(this.Sc = [0, 0]), (this.Eb = [0, 0]), (this.Qc = [0, 0]), (this.ia = this.lc = 0) } function Ut2() { ;(this.ad = a2(384)), (this.Za = 0), (this.Ob = a2(16)), (this.$b = this.Ad = this.ia = this.Gc = this.Hc = this.Dd = 0) } function zt2() { ;(this.uc = this.M = this.Nb = 0), (this.wa = Array(new Dt2())), (this.Y = 0), (this.ya = Array(new Ut2())), (this.aa = 0), (this.l = new Gt2()) } function Ht2() { ;(this.y = a2(16)), (this.f = a2(8)), (this.ea = a2(8)) } function Wt2() { ;(this.cb = this.a = 0), (this.sc = ''), (this.m = new w3()), (this.Od = new jt2()), (this.Kc = new Ot2()), (this.ed = new qt2()), (this.Qa = new Bt2()), (this.Ic = this.$c = this.Aa = 0), (this.D = new zt2()), (this.Xb = this.Va = this.Hb = this.zb = this.yb = this.Ub = this.za = 0), (this.Jc = o2(8, w3)), (this.ia = 0), (this.pb = o2(4, Tt2)), (this.Pa = new Et2()), (this.Bd = this.kc = 0), (this.Ac = []), (this.Bc = 0), (this.zc = [0, 0, 0, 0]), (this.Gd = Array(new Ht2())), (this.Hd = 0), (this.rb = Array(new Rt2())), (this.sb = 0), (this.wa = Array(new Dt2())), (this.Y = 0), (this.oc = []), (this.pc = 0), (this.sa = []), (this.ta = 0), (this.qa = []), (this.ra = 0), (this.Ha = []), (this.B = this.R = this.Ia = 0), (this.Ec = []), (this.M = this.ja = this.Vb = this.Fc = 0), (this.ya = Array(new Ut2())), (this.L = this.aa = 0), (this.gd = s2([4, 2], Dt2)), (this.ga = null), (this.Fa = []), (this.Cc = this.qc = this.P = 0), (this.Gb = []), (this.Uc = 0), (this.mb = []), (this.nb = 0), (this.rc = []), (this.Ga = this.Vc = 0) } function Vt2(t5, e3) { return 0 > t5 ? 0 : t5 > e3 ? e3 : t5 } function Gt2() { ;(this.T = this.U = this.ka = this.height = this.width = 0), (this.y = []), (this.f = []), (this.ea = []), (this.Rc = this.fa = this.W = this.N = this.O = 0), (this.ma = 'void'), (this.put = 'VP8IoPutHook'), (this.ac = 'VP8IoSetupHook'), (this.bc = 'VP8IoTeardownHook'), (this.ha = this.Kb = 0), (this.data = []), (this.hb = this.ib = this.da = this.o = this.j = this.va = this.v = this.Da = this.ob = this.w = 0), (this.F = []), (this.J = 0) } function Yt2() { var t5 = new Wt2() return ( null != t5 && ((t5.a = 0), (t5.sc = 'OK'), (t5.cb = 0), (t5.Xb = 0), ni || (ni = Zt2)), t5 ) } function Jt2(t5, e3, r3) { return 0 == t5.a && ((t5.a = e3), (t5.sc = r3), (t5.cb = 0)), 0 } function Xt2(t5, e3, r3) { return 3 <= r3 && 157 == t5[e3 + 0] && 1 == t5[e3 + 1] && 42 == t5[e3 + 2] } function Kt2(t5, r3) { if (null == t5) return 0 if (((t5.a = 0), (t5.sc = 'OK'), null == r3)) return Jt2(t5, 2, 'null VP8Io passed to VP8GetHeaders()') var n3 = r3.data, a3 = r3.w, o3 = r3.ha if (4 > o3) return Jt2(t5, 7, 'Truncated header.') var s3 = n3[a3 + 0] | (n3[a3 + 1] << 8) | (n3[a3 + 2] << 16), c4 = t5.Od if ( ((c4.Rb = !(1 & s3)), (c4.td = (s3 >> 1) & 7), (c4.yd = (s3 >> 4) & 1), (c4.ub = s3 >> 5), 3 < c4.td) ) return Jt2(t5, 3, 'Incorrect keyframe parameters.') if (!c4.yd) return Jt2(t5, 4, 'Frame not displayable.') ;(a3 += 3), (o3 -= 3) var u4 = t5.Kc if (c4.Rb) { if (7 > o3) return Jt2(t5, 7, 'cannot parse picture header') if (!Xt2(n3, a3, o3)) return Jt2(t5, 3, 'Bad code word') ;(u4.c = 16383 & ((n3[a3 + 4] << 8) | n3[a3 + 3])), (u4.Td = n3[a3 + 4] >> 6), (u4.i = 16383 & ((n3[a3 + 6] << 8) | n3[a3 + 5])), (u4.Ud = n3[a3 + 6] >> 6), (a3 += 7), (o3 -= 7), (t5.za = (u4.c + 15) >> 4), (t5.Ub = (u4.i + 15) >> 4), (r3.width = u4.c), (r3.height = u4.i), (r3.Da = 0), (r3.j = 0), (r3.v = 0), (r3.va = r3.width), (r3.o = r3.height), (r3.da = 0), (r3.ib = r3.width), (r3.hb = r3.height), (r3.U = r3.width), (r3.T = r3.height), i2((s3 = t5.Pa).jb, 0, 255, s3.jb.length), e2(null != (s3 = t5.Qa)), (s3.Cb = 0), (s3.Bb = 0), (s3.Fb = 1), i2(s3.Zb, 0, 0, s3.Zb.length), i2(s3.Lb, 0, 0, s3.Lb) } if (c4.ub > o3) return Jt2(t5, 7, 'bad partition length') p3((s3 = t5.m), n3, a3, c4.ub), (a3 += c4.ub), (o3 -= c4.ub), c4.Rb && ((u4.Ld = P2(s3)), (u4.Kd = P2(s3))), (u4 = t5.Qa) var h4, l4 = t5.Pa if ((e2(null != s3), e2(null != u4), (u4.Cb = P2(s3)), u4.Cb)) { if (((u4.Bb = P2(s3)), P2(s3))) { for (u4.Fb = P2(s3), h4 = 0; 4 > h4; ++h4) u4.Zb[h4] = P2(s3) ? m3(s3, 7) : 0 for (h4 = 0; 4 > h4; ++h4) u4.Lb[h4] = P2(s3) ? m3(s3, 6) : 0 } if (u4.Bb) for (h4 = 0; 3 > h4; ++h4) l4.jb[h4] = P2(s3) ? g3(s3, 8) : 255 } else u4.Bb = 0 if (s3.Ka) return Jt2(t5, 3, 'cannot parse segment header') if ( (((u4 = t5.ed).zd = P2(s3)), (u4.Tb = g3(s3, 6)), (u4.wb = g3(s3, 3)), (u4.Pc = P2(s3)), u4.Pc && P2(s3)) ) { for (l4 = 0; 4 > l4; ++l4) P2(s3) && (u4.vd[l4] = m3(s3, 6)) for (l4 = 0; 4 > l4; ++l4) P2(s3) && (u4.od[l4] = m3(s3, 6)) } if (((t5.L = 0 == u4.Tb ? 0 : u4.zd ? 1 : 2), s3.Ka)) return Jt2(t5, 3, 'cannot parse filter header') var f4 = o3 if ( ((o3 = h4 = a3), (a3 = h4 + f4), (u4 = f4), (t5.Xb = (1 << g3(t5.m, 2)) - 1), f4 < 3 * (l4 = t5.Xb)) ) n3 = 7 else { for (h4 += 3 * l4, u4 -= 3 * l4, f4 = 0; f4 < l4; ++f4) { var d5 = n3[o3 + 0] | (n3[o3 + 1] << 8) | (n3[o3 + 2] << 16) d5 > u4 && (d5 = u4), p3(t5.Jc[+f4], n3, h4, d5), (h4 += d5), (u4 -= d5), (o3 += 3) } p3(t5.Jc[+l4], n3, h4, u4), (n3 = h4 < a3 ? 0 : 5) } if (0 != n3) return Jt2(t5, n3, 'cannot parse partitions') for ( n3 = g3((h4 = t5.m), 7), o3 = P2(h4) ? m3(h4, 4) : 0, a3 = P2(h4) ? m3(h4, 4) : 0, u4 = P2(h4) ? m3(h4, 4) : 0, l4 = P2(h4) ? m3(h4, 4) : 0, h4 = P2(h4) ? m3(h4, 4) : 0, f4 = t5.Qa, d5 = 0; 4 > d5; ++d5 ) { if (f4.Cb) { var v6 = f4.Zb[d5] f4.Fb || (v6 += n3) } else { if (0 < d5) { t5.pb[d5] = t5.pb[0] continue } v6 = n3 } var b4 = t5.pb[d5] ;(b4.Sc[0] = ei[Vt2(v6 + o3, 127)]), (b4.Sc[1] = ri[Vt2(v6 + 0, 127)]), (b4.Eb[0] = 2 * ei[Vt2(v6 + a3, 127)]), (b4.Eb[1] = (101581 * ri[Vt2(v6 + u4, 127)]) >> 16), 8 > b4.Eb[1] && (b4.Eb[1] = 8), (b4.Qc[0] = ei[Vt2(v6 + l4, 117)]), (b4.Qc[1] = ri[Vt2(v6 + h4, 127)]), (b4.lc = v6 + h4) } if (!c4.Rb) return Jt2(t5, 4, 'Not a key frame.') for (P2(s3), c4 = t5.Pa, n3 = 0; 4 > n3; ++n3) { for (o3 = 0; 8 > o3; ++o3) for (a3 = 0; 3 > a3; ++a3) for (u4 = 0; 11 > u4; ++u4) (l4 = k2(s3, ui[n3][o3][a3][u4]) ? g3(s3, 8) : si[n3][o3][a3][u4]), (c4.Wc[n3][o3].Yb[a3][u4] = l4) for (o3 = 0; 17 > o3; ++o3) c4.Xc[n3][o3] = c4.Wc[n3][hi[o3]] } return (t5.kc = P2(s3)), t5.kc && (t5.Bd = g3(s3, 8)), (t5.cb = 1) } function Zt2(t5, e3, r3, n3, i3, a3, o3) { var s3 = e3[i3].Yb[r3] for (r3 = 0; 16 > i3; ++i3) { if (!k2(t5, s3[r3 + 0])) return i3 for (; !k2(t5, s3[r3 + 1]); ) if (((s3 = e3[++i3].Yb[0]), (r3 = 0), 16 == i3)) return 16 var c4 = e3[i3 + 1].Yb if (k2(t5, s3[r3 + 2])) { var u4 = t5, h4 = 0 if (k2(u4, (f4 = s3)[(l4 = r3) + 3])) if (k2(u4, f4[l4 + 6])) { for ( s3 = 0, l4 = 2 * (h4 = k2(u4, f4[l4 + 8])) + (f4 = k2(u4, f4[l4 + 9 + h4])), h4 = 0, f4 = ii[l4]; f4[s3]; ++s3 ) h4 += h4 + k2(u4, f4[s3]) h4 += 3 + (8 << l4) } else k2(u4, f4[l4 + 7]) ? ((h4 = 7 + 2 * k2(u4, 165)), (h4 += k2(u4, 145))) : (h4 = 5 + k2(u4, 159)) else h4 = k2(u4, f4[l4 + 4]) ? 3 + k2(u4, f4[l4 + 5]) : 2 s3 = c4[2] } else (h4 = 1), (s3 = c4[1]) ;(c4 = o3 + ai[i3]), 0 > (u4 = t5).b && _2(u4) var l4, f4 = u4.b, d5 = ((l4 = u4.Ca >> 1) - (u4.I >> f4)) >> 31 --u4.b, (u4.Ca += d5), (u4.Ca |= 1), (u4.I -= ((l4 + 1) & d5) << f4), (a3[c4] = ((h4 ^ d5) - d5) * n3[(0 < i3) + 0]) } return 16 } function $t2(t5) { var e3 = t5.rb[t5.sb - 1] ;(e3.la = 0), (e3.Na = 0), i2(t5.zc, 0, 0, t5.zc.length), (t5.ja = 0) } function Qt2(t5, r3) { if (null == t5) return 0 if (null == r3) return Jt2(t5, 2, 'NULL VP8Io parameter in VP8Decode().') if (!t5.cb && !Kt2(t5, r3)) return 0 if ((e2(t5.cb), null == r3.ac || r3.ac(r3))) { r3.ob && (t5.L = 0) var s3 = Ri[t5.L] if ( (2 == t5.L ? ((t5.yb = 0), (t5.zb = 0)) : ((t5.yb = (r3.v - s3) >> 4), (t5.zb = (r3.j - s3) >> 4), 0 > t5.yb && (t5.yb = 0), 0 > t5.zb && (t5.zb = 0)), (t5.Va = (r3.o + 15 + s3) >> 4), (t5.Hb = (r3.va + 15 + s3) >> 4), t5.Hb > t5.za && (t5.Hb = t5.za), t5.Va > t5.Ub && (t5.Va = t5.Ub), 0 < t5.L) ) { var c4 = t5.ed for (s3 = 0; 4 > s3; ++s3) { var u4 if (t5.Qa.Cb) { var h4 = t5.Qa.Lb[s3] t5.Qa.Fb || (h4 += c4.Tb) } else h4 = c4.Tb for (u4 = 0; 1 >= u4; ++u4) { var l4 = t5.gd[s3][u4], f4 = h4 if ( (c4.Pc && ((f4 += c4.vd[0]), u4 && (f4 += c4.od[0])), 0 < (f4 = 0 > f4 ? 0 : 63 < f4 ? 63 : f4)) ) { var d5 = f4 0 < c4.wb && (d5 = 4 < c4.wb ? d5 >> 2 : d5 >> 1) > 9 - c4.wb && (d5 = 9 - c4.wb), 1 > d5 && (d5 = 1), (l4.dd = d5), (l4.tc = 2 * f4 + d5), (l4.ld = 40 <= f4 ? 2 : 15 <= f4 ? 1 : 0) } else l4.tc = 0 l4.La = u4 } } } s3 = 0 } else Jt2(t5, 6, 'Frame setup failed'), (s3 = t5.a) if ((s3 = 0 == s3)) { if (s3) { ;(t5.$c = 0), 0 < t5.Aa || (t5.Ic = Ui) t: { s3 = t5.Ic c4 = 4 * (d5 = t5.za) var p4 = 32 * d5, g4 = d5 + 1, m4 = 0 < t5.L ? d5 * (0 < t5.Aa ? 2 : 1) : 0, v6 = (2 == t5.Aa ? 2 : 1) * d5 if ( (l4 = c4 + 832 + (u4 = ((3 * (16 * s3 + Ri[t5.L])) / 2) * p4) + (h4 = null != t5.Fa && 0 < t5.Fa.length ? t5.Kc.c * t5.Kc.i : 0)) != l4 ) s3 = 0 else { if (l4 > t5.Vb) { if ( ((t5.Vb = 0), (t5.Ec = a2(l4)), (t5.Fc = 0), null == t5.Ec) ) { s3 = Jt2(t5, 1, 'no memory during frame initialization.') break t } t5.Vb = l4 } ;(l4 = t5.Ec), (f4 = t5.Fc), (t5.Ac = l4), (t5.Bc = f4), (f4 += c4), (t5.Gd = o2(p4, Ht2)), (t5.Hd = 0), (t5.rb = o2(g4 + 1, Rt2)), (t5.sb = 1), (t5.wa = m4 ? o2(m4, Dt2) : null), (t5.Y = 0), (t5.D.Nb = 0), (t5.D.wa = t5.wa), (t5.D.Y = t5.Y), 0 < t5.Aa && (t5.D.Y += d5), e2(true), (t5.oc = l4), (t5.pc = f4), (f4 += 832), (t5.ya = o2(v6, Ut2)), (t5.aa = 0), (t5.D.ya = t5.ya), (t5.D.aa = t5.aa), 2 == t5.Aa && (t5.D.aa += d5), (t5.R = 16 * d5), (t5.B = 8 * d5), (d5 = (p4 = Ri[t5.L]) * t5.R), (p4 = (p4 / 2) * t5.B), (t5.sa = l4), (t5.ta = f4 + d5), (t5.qa = t5.sa), (t5.ra = t5.ta + 16 * s3 * t5.R + p4), (t5.Ha = t5.qa), (t5.Ia = t5.ra + 8 * s3 * t5.B + p4), (t5.$c = 0), (f4 += u4), (t5.mb = h4 ? l4 : null), (t5.nb = h4 ? f4 : null), e2(f4 + h4 <= t5.Fc + t5.Vb), $t2(t5), i2(t5.Ac, t5.Bc, 0, c4), (s3 = 1) } } if (s3) { if ( ((r3.ka = 0), (r3.y = t5.sa), (r3.O = t5.ta), (r3.f = t5.qa), (r3.N = t5.ra), (r3.ea = t5.Ha), (r3.Vd = t5.Ia), (r3.fa = t5.R), (r3.Rc = t5.B), (r3.F = null), (r3.J = 0), !Cn) ) { for (s3 = -255; 255 >= s3; ++s3) Pn[255 + s3] = 0 > s3 ? -s3 : s3 for (s3 = -1020; 1020 >= s3; ++s3) kn[1020 + s3] = -128 > s3 ? -128 : 127 < s3 ? 127 : s3 for (s3 = -112; 112 >= s3; ++s3) In[112 + s3] = -16 > s3 ? -16 : 15 < s3 ? 15 : s3 for (s3 = -255; 510 >= s3; ++s3) Fn[255 + s3] = 0 > s3 ? 0 : 255 < s3 ? 255 : s3 Cn = 1 } ;(an = ue2), (on2 = ae2), (cn = oe2), (un = se2), (hn = ce2), (sn = ie2), (ln2 = Je), (fn2 = Xe), (dn = $e), (pn = Qe), (gn = Ke), (mn2 = Ze), (vn = tr2), (bn2 = er), (yn = ze), (wn = He), (Nn = We), (Ln = Ve), (fi2[0] = xe), (fi2[1] = le2), (fi2[2] = Le2), (fi2[3] = Ae), (fi2[4] = Se), (fi2[5] = Pe), (fi2[6] = _e), (fi2[7] = ke), (fi2[8] = Fe), (fi2[9] = Ie), (li[0] = ve2), (li[1] = de2), (li[2] = pe2), (li[3] = ge2), (li[4] = be2), (li[5] = ye2), (li[6] = we2), (di[0] = Be), (di[1] = fe2), (di[2] = Ce), (di[3] = je), (di[4] = Ee), (di[5] = Me), (di[6] = qe), (s3 = 1) } else s3 = 0 } s3 && (s3 = (function (t6, r4) { for (t6.M = 0; t6.M < t6.Va; ++t6.M) { var o3, s4 = t6.Jc[t6.M & t6.Xb], c5 = t6.m, u5 = t6 for (o3 = 0; o3 < u5.za; ++o3) { var h5 = c5, l5 = u5, f5 = l5.Ac, d6 = l5.Bc + 4 * o3, p5 = l5.zc, g5 = l5.ya[l5.aa + o3] if ( (l5.Qa.Bb ? (g5.$b = k2(h5, l5.Pa.jb[0]) ? 2 + k2(h5, l5.Pa.jb[2]) : k2(h5, l5.Pa.jb[1])) : (g5.$b = 0), l5.kc && (g5.Ad = k2(h5, l5.Bd)), (g5.Za = !k2(h5, 145) + 0), g5.Za) ) { var m5 = g5.Ob, v7 = 0 for (l5 = 0; 4 > l5; ++l5) { var b4, y4 = p5[0 + l5] for (b4 = 0; 4 > b4; ++b4) { y4 = ci[f5[d6 + b4]][y4] for (var w4 = oi[k2(h5, y4[0])]; 0 < w4; ) w4 = oi[2 * w4 + k2(h5, y4[w4])] ;(y4 = -w4), (f5[d6 + b4] = y4) } n2(m5, v7, f5, d6, 4), (v7 += 4), (p5[0 + l5] = y4) } } else (y4 = k2(h5, 156) ? k2(h5, 128) ? 1 : 3 : k2(h5, 163) ? 2 : 0), (g5.Ob[0] = y4), i2(f5, d6, y4, 4), i2(p5, 0, y4, 4) g5.Dd = k2(h5, 142) ? k2(h5, 114) ? k2(h5, 183) ? 1 : 3 : 2 : 0 } if (u5.m.Ka) return Jt2(t6, 7, 'Premature end-of-partition0 encountered.') for (; t6.ja < t6.za; ++t6.ja) { if ( ((u5 = s4), (h5 = (c5 = t6).rb[c5.sb - 1]), (f5 = c5.rb[c5.sb + c5.ja]), (o3 = c5.ya[c5.aa + c5.ja]), (d6 = c5.kc ? o3.Ad : 0)) ) (h5.la = f5.la = 0), o3.Za || (h5.Na = f5.Na = 0), (o3.Hc = 0), (o3.Gc = 0), (o3.ia = 0) else { var N4, L4 ;(h5 = f5), (f5 = u5), (d6 = c5.Pa.Xc), (p5 = c5.ya[c5.aa + c5.ja]), (g5 = c5.pb[p5.$b]) if ( ((l5 = p5.ad), (m5 = 0), (v7 = c5.rb[c5.sb - 1]), (y4 = b4 = 0), i2(l5, m5, 0, 384), p5.Za) ) var A4 = 0, x3 = d6[3] else { w4 = a2(16) var S3 = h5.Na + v7.Na if ( ((S3 = ni(f5, d6[1], S3, g5.Eb, 0, w4, 0)), (h5.Na = v7.Na = (0 < S3) + 0), 1 < S3) ) an(w4, 0, l5, m5) else { var _3 = (w4[0] + 3) >> 3 for (w4 = 0; 256 > w4; w4 += 16) l5[m5 + w4] = _3 } ;(A4 = 1), (x3 = d6[0]) } var P3 = 15 & h5.la, I3 = 15 & v7.la for (w4 = 0; 4 > w4; ++w4) { var F3 = 1 & I3 for (_3 = L4 = 0; 4 > _3; ++_3) (P3 = (P3 >> 1) | ((F3 = (S3 = ni( f5, x3, (S3 = F3 + (1 & P3)), g5.Sc, A4, l5, m5 )) > A4) << 7)), (L4 = (L4 << 2) | (3 < S3 ? 3 : 1 < S3 ? 2 : 0 != l5[m5 + 0])), (m5 += 16) ;(P3 >>= 4), (I3 = (I3 >> 1) | (F3 << 7)), (b4 = ((b4 << 8) | L4) >>> 0) } for (x3 = P3, A4 = I3 >> 4, N4 = 0; 4 > N4; N4 += 2) { for ( L4 = 0, P3 = h5.la >> (4 + N4), I3 = v7.la >> (4 + N4), w4 = 0; 2 > w4; ++w4 ) { for (F3 = 1 & I3, _3 = 0; 2 > _3; ++_3) (S3 = F3 + (1 & P3)), (P3 = (P3 >> 1) | ((F3 = 0 < (S3 = ni(f5, d6[2], S3, g5.Qc, 0, l5, m5))) << 3)), (L4 = (L4 << 2) | (3 < S3 ? 3 : 1 < S3 ? 2 : 0 != l5[m5 + 0])), (m5 += 16) ;(P3 >>= 2), (I3 = (I3 >> 1) | (F3 << 5)) } ;(y4 |= L4 << (4 * N4)), (x3 |= (P3 << 4) << N4), (A4 |= (240 & I3) << N4) } ;(h5.la = x3), (v7.la = A4), (p5.Hc = b4), (p5.Gc = y4), (p5.ia = 43690 & y4 ? 0 : g5.ia), (d6 = !(b4 | y4)) } if ( (0 < c5.L && ((c5.wa[c5.Y + c5.ja] = c5.gd[o3.$b][o3.Za]), (c5.wa[c5.Y + c5.ja].La |= !d6)), u5.Ka) ) return Jt2(t6, 7, 'Premature end-of-file encountered.') } if ( ($t2(t6), (c5 = r4), (u5 = 1), (o3 = (s4 = t6).D), (h5 = 0 < s4.L && s4.M >= s4.zb && s4.M <= s4.Va), 0 == s4.Aa) ) t: { if ( ((o3.M = s4.M), (o3.uc = h5), Or(s4, o3), (u5 = 1), (o3 = (L4 = s4.D).Nb), (h5 = (y4 = Ri[s4.L]) * s4.R), (f5 = (y4 / 2) * s4.B), (w4 = 16 * o3 * s4.R), (_3 = 8 * o3 * s4.B), (d6 = s4.sa), (p5 = s4.ta - h5 + w4), (g5 = s4.qa), (l5 = s4.ra - f5 + _3), (m5 = s4.Ha), (v7 = s4.Ia - f5 + _3), (I3 = 0 == (P3 = L4.M)), (b4 = P3 >= s4.Va - 1), 2 == s4.Aa && Or(s4, L4), L4.uc) ) for ( F3 = (S3 = s4).D.M, e2(S3.D.uc), L4 = S3.yb; L4 < S3.Hb; ++L4 ) { ;(A4 = L4), (x3 = F3) var C3 = (j3 = (U3 = S3).D).Nb N4 = U3.R var j3 = j3.wa[j3.Y + A4], O3 = U3.sa, B4 = U3.ta + 16 * C3 * N4 + 16 * A4, M3 = j3.dd, E3 = j3.tc if (0 != E3) if ((e2(3 <= E3), 1 == U3.L)) 0 < A4 && wn(O3, B4, N4, E3 + 4), j3.La && Ln(O3, B4, N4, E3), 0 < x3 && yn(O3, B4, N4, E3 + 4), j3.La && Nn(O3, B4, N4, E3) else { var q3 = U3.B, D3 = U3.qa, R3 = U3.ra + 8 * C3 * q3 + 8 * A4, T3 = U3.Ha, U3 = U3.Ia + 8 * C3 * q3 + 8 * A4 C3 = j3.ld 0 < A4 && (fn2(O3, B4, N4, E3 + 4, M3, C3), pn(D3, R3, T3, U3, q3, E3 + 4, M3, C3)), j3.La && (mn2(O3, B4, N4, E3, M3, C3), bn2(D3, R3, T3, U3, q3, E3, M3, C3)), 0 < x3 && (ln2(O3, B4, N4, E3 + 4, M3, C3), dn(D3, R3, T3, U3, q3, E3 + 4, M3, C3)), j3.La && (gn(O3, B4, N4, E3, M3, C3), vn(D3, R3, T3, U3, q3, E3, M3, C3)) } } if ((s4.ia && alert('todo:DitherRow'), null != c5.put)) { if ( ((L4 = 16 * P3), (P3 = 16 * (P3 + 1)), I3 ? ((c5.y = s4.sa), (c5.O = s4.ta + w4), (c5.f = s4.qa), (c5.N = s4.ra + _3), (c5.ea = s4.Ha), (c5.W = s4.Ia + _3)) : ((L4 -= y4), (c5.y = d6), (c5.O = p5), (c5.f = g5), (c5.N = l5), (c5.ea = m5), (c5.W = v7)), b4 || (P3 -= y4), P3 > c5.o && (P3 = c5.o), (c5.F = null), (c5.J = null), null != s4.Fa && 0 < s4.Fa.length && L4 < P3 && ((c5.J = lr(s4, c5, L4, P3 - L4)), (c5.F = s4.mb), null == c5.F && 0 == c5.F.length)) ) { u5 = Jt2(s4, 3, 'Could not decode alpha data.') break t } L4 < c5.j && ((y4 = c5.j - L4), (L4 = c5.j), e2(!(1 & y4)), (c5.O += s4.R * y4), (c5.N += s4.B * (y4 >> 1)), (c5.W += s4.B * (y4 >> 1)), null != c5.F && (c5.J += c5.width * y4)), L4 < P3 && ((c5.O += c5.v), (c5.N += c5.v >> 1), (c5.W += c5.v >> 1), null != c5.F && (c5.J += c5.v), (c5.ka = L4 - c5.j), (c5.U = c5.va - c5.v), (c5.T = P3 - L4), (u5 = c5.put(c5))) } o3 + 1 != s4.Ic || b4 || (n2(s4.sa, s4.ta - h5, d6, p5 + 16 * s4.R, h5), n2(s4.qa, s4.ra - f5, g5, l5 + 8 * s4.B, f5), n2(s4.Ha, s4.Ia - f5, m5, v7 + 8 * s4.B, f5)) } if (!u5) return Jt2(t6, 6, 'Output aborted.') } return 1 })(t5, r3)), null != r3.bc && r3.bc(r3), (s3 &= 1) } return s3 ? ((t5.cb = 0), s3) : 0 } function te2(t5, e3, r3, n3, i3) { ;(i3 = t5[e3 + r3 + 32 * n3] + (i3 >> 3)), (t5[e3 + r3 + 32 * n3] = -256 & i3 ? (0 > i3 ? 0 : 255) : i3) } function ee2(t5, e3, r3, n3, i3, a3) { te2(t5, e3, 0, r3, n3 + i3), te2(t5, e3, 1, r3, n3 + a3), te2(t5, e3, 2, r3, n3 - a3), te2(t5, e3, 3, r3, n3 - i3) } function re2(t5) { return ((20091 * t5) >> 16) + t5 } function ne2(t5, e3, r3, n3) { var i3, o3 = 0, s3 = a2(16) for (i3 = 0; 4 > i3; ++i3) { var c4 = t5[e3 + 0] + t5[e3 + 8], u4 = t5[e3 + 0] - t5[e3 + 8], h4 = ((35468 * t5[e3 + 4]) >> 16) - re2(t5[e3 + 12]), l4 = re2(t5[e3 + 4]) + ((35468 * t5[e3 + 12]) >> 16) ;(s3[o3 + 0] = c4 + l4), (s3[o3 + 1] = u4 + h4), (s3[o3 + 2] = u4 - h4), (s3[o3 + 3] = c4 - l4), (o3 += 4), e3++ } for (i3 = o3 = 0; 4 > i3; ++i3) (c4 = (t5 = s3[o3 + 0] + 4) + s3[o3 + 8]), (u4 = t5 - s3[o3 + 8]), (h4 = ((35468 * s3[o3 + 4]) >> 16) - re2(s3[o3 + 12])), te2( r3, n3, 0, 0, c4 + (l4 = re2(s3[o3 + 4]) + ((35468 * s3[o3 + 12]) >> 16)) ), te2(r3, n3, 1, 0, u4 + h4), te2(r3, n3, 2, 0, u4 - h4), te2(r3, n3, 3, 0, c4 - l4), o3++, (n3 += 32) } function ie2(t5, e3, r3, n3) { var i3 = t5[e3 + 0] + 4, a3 = (35468 * t5[e3 + 4]) >> 16, o3 = re2(t5[e3 + 4]), s3 = (35468 * t5[e3 + 1]) >> 16 ee2(r3, n3, 0, i3 + o3, (t5 = re2(t5[e3 + 1])), s3), ee2(r3, n3, 1, i3 + a3, t5, s3), ee2(r3, n3, 2, i3 - a3, t5, s3), ee2(r3, n3, 3, i3 - o3, t5, s3) } function ae2(t5, e3, r3, n3, i3) { ne2(t5, e3, r3, n3), i3 && ne2(t5, e3 + 16, r3, n3 + 4) } function oe2(t5, e3, r3, n3) { on2(t5, e3 + 0, r3, n3, 1), on2(t5, e3 + 32, r3, n3 + 128, 1) } function se2(t5, e3, r3, n3) { var i3 for (t5 = t5[e3 + 0] + 4, i3 = 0; 4 > i3; ++i3) for (e3 = 0; 4 > e3; ++e3) te2(r3, n3, e3, i3, t5) } function ce2(t5, e3, r3, n3) { t5[e3 + 0] && un(t5, e3 + 0, r3, n3), t5[e3 + 16] && un(t5, e3 + 16, r3, n3 + 4), t5[e3 + 32] && un(t5, e3 + 32, r3, n3 + 128), t5[e3 + 48] && un(t5, e3 + 48, r3, n3 + 128 + 4) } function ue2(t5, e3, r3, n3) { var i3, o3 = a2(16) for (i3 = 0; 4 > i3; ++i3) { var s3 = t5[e3 + 0 + i3] + t5[e3 + 12 + i3], c4 = t5[e3 + 4 + i3] + t5[e3 + 8 + i3], u4 = t5[e3 + 4 + i3] - t5[e3 + 8 + i3], h4 = t5[e3 + 0 + i3] - t5[e3 + 12 + i3] ;(o3[0 + i3] = s3 + c4), (o3[8 + i3] = s3 - c4), (o3[4 + i3] = h4 + u4), (o3[12 + i3] = h4 - u4) } for (i3 = 0; 4 > i3; ++i3) (s3 = (t5 = o3[0 + 4 * i3] + 3) + o3[3 + 4 * i3]), (c4 = o3[1 + 4 * i3] + o3[2 + 4 * i3]), (u4 = o3[1 + 4 * i3] - o3[2 + 4 * i3]), (h4 = t5 - o3[3 + 4 * i3]), (r3[n3 + 0] = (s3 + c4) >> 3), (r3[n3 + 16] = (h4 + u4) >> 3), (r3[n3 + 32] = (s3 - c4) >> 3), (r3[n3 + 48] = (h4 - u4) >> 3), (n3 += 64) } function he2(t5, e3, r3) { var n3, i3 = e3 - 32, a3 = Bn, o3 = 255 - t5[i3 - 1] for (n3 = 0; n3 < r3; ++n3) { var s3, c4 = a3, u4 = o3 + t5[e3 - 1] for (s3 = 0; s3 < r3; ++s3) t5[e3 + s3] = c4[u4 + t5[i3 + s3]] e3 += 32 } } function le2(t5, e3) { he2(t5, e3, 4) } function fe2(t5, e3) { he2(t5, e3, 8) } function de2(t5, e3) { he2(t5, e3, 16) } function pe2(t5, e3) { var r3 for (r3 = 0; 16 > r3; ++r3) n2(t5, e3 + 32 * r3, t5, e3 - 32, 16) } function ge2(t5, e3) { var r3 for (r3 = 16; 0 < r3; --r3) i2(t5, e3, t5[e3 - 1], 16), (e3 += 32) } function me2(t5, e3, r3) { var n3 for (n3 = 0; 16 > n3; ++n3) i2(e3, r3 + 32 * n3, t5, 16) } function ve2(t5, e3) { var r3, n3 = 16 for (r3 = 0; 16 > r3; ++r3) n3 += t5[e3 - 1 + 32 * r3] + t5[e3 + r3 - 32] me2(n3 >> 5, t5, e3) } function be2(t5, e3) { var r3, n3 = 8 for (r3 = 0; 16 > r3; ++r3) n3 += t5[e3 - 1 + 32 * r3] me2(n3 >> 4, t5, e3) } function ye2(t5, e3) { var r3, n3 = 8 for (r3 = 0; 16 > r3; ++r3) n3 += t5[e3 + r3 - 32] me2(n3 >> 4, t5, e3) } function we2(t5, e3) { me2(128, t5, e3) } function Ne2(t5, e3, r3) { return (t5 + 2 * e3 + r3 + 2) >> 2 } function Le2(t5, e3) { var r3, i3 = e3 - 32 i3 = new Uint8Array([ Ne2(t5[i3 - 1], t5[i3 + 0], t5[i3 + 1]), Ne2(t5[i3 + 0], t5[i3 + 1], t5[i3 + 2]), Ne2(t5[i3 + 1], t5[i3 + 2], t5[i3 + 3]), Ne2(t5[i3 + 2], t5[i3 + 3], t5[i3 + 4]), ]) for (r3 = 0; 4 > r3; ++r3) n2(t5, e3 + 32 * r3, i3, 0, i3.length) } function Ae(t5, e3) { var r3 = t5[e3 - 1], n3 = t5[e3 - 1 + 32], i3 = t5[e3 - 1 + 64], a3 = t5[e3 - 1 + 96] I2(t5, e3 + 0, 16843009 * Ne2(t5[e3 - 1 - 32], r3, n3)), I2(t5, e3 + 32, 16843009 * Ne2(r3, n3, i3)), I2(t5, e3 + 64, 16843009 * Ne2(n3, i3, a3)), I2(t5, e3 + 96, 16843009 * Ne2(i3, a3, a3)) } function xe(t5, e3) { var r3, n3 = 4 for (r3 = 0; 4 > r3; ++r3) n3 += t5[e3 + r3 - 32] + t5[e3 - 1 + 32 * r3] for (n3 >>= 3, r3 = 0; 4 > r3; ++r3) i2(t5, e3 + 32 * r3, n3, 4) } function Se(t5, e3) { var r3 = t5[e3 - 1 + 0], n3 = t5[e3 - 1 + 32], i3 = t5[e3 - 1 + 64], a3 = t5[e3 - 1 - 32], o3 = t5[e3 + 0 - 32], s3 = t5[e3 + 1 - 32], c4 = t5[e3 + 2 - 32], u4 = t5[e3 + 3 - 32] ;(t5[e3 + 0 + 96] = Ne2(n3, i3, t5[e3 - 1 + 96])), (t5[e3 + 1 + 96] = t5[e3 + 0 + 64] = Ne2(r3, n3, i3)), (t5[e3 + 2 + 96] = t5[e3 + 1 + 64] = t5[e3 + 0 + 32] = Ne2(a3, r3, n3)), (t5[e3 + 3 + 96] = t5[e3 + 2 + 64] = t5[e3 + 1 + 32] = t5[e3 + 0 + 0] = Ne2(o3, a3, r3)), (t5[e3 + 3 + 64] = t5[e3 + 2 + 32] = t5[e3 + 1 + 0] = Ne2(s3, o3, a3)), (t5[e3 + 3 + 32] = t5[e3 + 2 + 0] = Ne2(c4, s3, o3)), (t5[e3 + 3 + 0] = Ne2(u4, c4, s3)) } function _e(t5, e3) { var r3 = t5[e3 + 1 - 32], n3 = t5[e3 + 2 - 32], i3 = t5[e3 + 3 - 32], a3 = t5[e3 + 4 - 32], o3 = t5[e3 + 5 - 32], s3 = t5[e3 + 6 - 32], c4 = t5[e3 + 7 - 32] ;(t5[e3 + 0 + 0] = Ne2(t5[e3 + 0 - 32], r3, n3)), (t5[e3 + 1 + 0] = t5[e3 + 0 + 32] = Ne2(r3, n3, i3)), (t5[e3 + 2 + 0] = t5[e3 + 1 + 32] = t5[e3 + 0 + 64] = Ne2(n3, i3, a3)), (t5[e3 + 3 + 0] = t5[e3 + 2 + 32] = t5[e3 + 1 + 64] = t5[e3 + 0 + 96] = Ne2(i3, a3, o3)), (t5[e3 + 3 + 32] = t5[e3 + 2 + 64] = t5[e3 + 1 + 96] = Ne2(a3, o3, s3)), (t5[e3 + 3 + 64] = t5[e3 + 2 + 96] = Ne2(o3, s3, c4)), (t5[e3 + 3 + 96] = Ne2(s3, c4, c4)) } function Pe(t5, e3) { var r3 = t5[e3 - 1 + 0], n3 = t5[e3 - 1 + 32], i3 = t5[e3 - 1 + 64], a3 = t5[e3 - 1 - 32], o3 = t5[e3 + 0 - 32], s3 = t5[e3 + 1 - 32], c4 = t5[e3 + 2 - 32], u4 = t5[e3 + 3 - 32] ;(t5[e3 + 0 + 0] = t5[e3 + 1 + 64] = (a3 + o3 + 1) >> 1), (t5[e3 + 1 + 0] = t5[e3 + 2 + 64] = (o3 + s3 + 1) >> 1), (t5[e3 + 2 + 0] = t5[e3 + 3 + 64] = (s3 + c4 + 1) >> 1), (t5[e3 + 3 + 0] = (c4 + u4 + 1) >> 1), (t5[e3 + 0 + 96] = Ne2(i3, n3, r3)), (t5[e3 + 0 + 64] = Ne2(n3, r3, a3)), (t5[e3 + 0 + 32] = t5[e3 + 1 + 96] = Ne2(r3, a3, o3)), (t5[e3 + 1 + 32] = t5[e3 + 2 + 96] = Ne2(a3, o3, s3)), (t5[e3 + 2 + 32] = t5[e3 + 3 + 96] = Ne2(o3, s3, c4)), (t5[e3 + 3 + 32] = Ne2(s3, c4, u4)) } function ke(t5, e3) { var r3 = t5[e3 + 0 - 32], n3 = t5[e3 + 1 - 32], i3 = t5[e3 + 2 - 32], a3 = t5[e3 + 3 - 32], o3 = t5[e3 + 4 - 32], s3 = t5[e3 + 5 - 32], c4 = t5[e3 + 6 - 32], u4 = t5[e3 + 7 - 32] ;(t5[e3 + 0 + 0] = (r3 + n3 + 1) >> 1), (t5[e3 + 1 + 0] = t5[e3 + 0 + 64] = (n3 + i3 + 1) >> 1), (t5[e3 + 2 + 0] = t5[e3 + 1 + 64] = (i3 + a3 + 1) >> 1), (t5[e3 + 3 + 0] = t5[e3 + 2 + 64] = (a3 + o3 + 1) >> 1), (t5[e3 + 0 + 32] = Ne2(r3, n3, i3)), (t5[e3 + 1 + 32] = t5[e3 + 0 + 96] = Ne2(n3, i3, a3)), (t5[e3 + 2 + 32] = t5[e3 + 1 + 96] = Ne2(i3, a3, o3)), (t5[e3 + 3 + 32] = t5[e3 + 2 + 96] = Ne2(a3, o3, s3)), (t5[e3 + 3 + 64] = Ne2(o3, s3, c4)), (t5[e3 + 3 + 96] = Ne2(s3, c4, u4)) } function Ie(t5, e3) { var r3 = t5[e3 - 1 + 0], n3 = t5[e3 - 1 + 32], i3 = t5[e3 - 1 + 64], a3 = t5[e3 - 1 + 96] ;(t5[e3 + 0 + 0] = (r3 + n3 + 1) >> 1), (t5[e3 + 2 + 0] = t5[e3 + 0 + 32] = (n3 + i3 + 1) >> 1), (t5[e3 + 2 + 32] = t5[e3 + 0 + 64] = (i3 + a3 + 1) >> 1), (t5[e3 + 1 + 0] = Ne2(r3, n3, i3)), (t5[e3 + 3 + 0] = t5[e3 + 1 + 32] = Ne2(n3, i3, a3)), (t5[e3 + 3 + 32] = t5[e3 + 1 + 64] = Ne2(i3, a3, a3)), (t5[e3 + 3 + 64] = t5[e3 + 2 + 64] = t5[e3 + 0 + 96] = t5[e3 + 1 + 96] = t5[e3 + 2 + 96] = t5[e3 + 3 + 96] = a3) } function Fe(t5, e3) { var r3 = t5[e3 - 1 + 0], n3 = t5[e3 - 1 + 32], i3 = t5[e3 - 1 + 64], a3 = t5[e3 - 1 + 96], o3 = t5[e3 - 1 - 32], s3 = t5[e3 + 0 - 32], c4 = t5[e3 + 1 - 32], u4 = t5[e3 + 2 - 32] ;(t5[e3 + 0 + 0] = t5[e3 + 2 + 32] = (r3 + o3 + 1) >> 1), (t5[e3 + 0 + 32] = t5[e3 + 2 + 64] = (n3 + r3 + 1) >> 1), (t5[e3 + 0 + 64] = t5[e3 + 2 + 96] = (i3 + n3 + 1) >> 1), (t5[e3 + 0 + 96] = (a3 + i3 + 1) >> 1), (t5[e3 + 3 + 0] = Ne2(s3, c4, u4)), (t5[e3 + 2 + 0] = Ne2(o3, s3, c4)), (t5[e3 + 1 + 0] = t5[e3 + 3 + 32] = Ne2(r3, o3, s3)), (t5[e3 + 1 + 32] = t5[e3 + 3 + 64] = Ne2(n3, r3, o3)), (t5[e3 + 1 + 64] = t5[e3 + 3 + 96] = Ne2(i3, n3, r3)), (t5[e3 + 1 + 96] = Ne2(a3, i3, n3)) } function Ce(t5, e3) { var r3 for (r3 = 0; 8 > r3; ++r3) n2(t5, e3 + 32 * r3, t5, e3 - 32, 8) } function je(t5, e3) { var r3 for (r3 = 0; 8 > r3; ++r3) i2(t5, e3, t5[e3 - 1], 8), (e3 += 32) } function Oe(t5, e3, r3) { var n3 for (n3 = 0; 8 > n3; ++n3) i2(e3, r3 + 32 * n3, t5, 8) } function Be(t5, e3) { var r3, n3 = 8 for (r3 = 0; 8 > r3; ++r3) n3 += t5[e3 + r3 - 32] + t5[e3 - 1 + 32 * r3] Oe(n3 >> 4, t5, e3) } function Me(t5, e3) { var r3, n3 = 4 for (r3 = 0; 8 > r3; ++r3) n3 += t5[e3 + r3 - 32] Oe(n3 >> 3, t5, e3) } function Ee(t5, e3) { var r3, n3 = 4 for (r3 = 0; 8 > r3; ++r3) n3 += t5[e3 - 1 + 32 * r3] Oe(n3 >> 3, t5, e3) } function qe(t5, e3) { Oe(128, t5, e3) } function De(t5, e3, r3) { var n3 = t5[e3 - r3], i3 = t5[e3 + 0], a3 = 3 * (i3 - n3) + jn[1020 + t5[e3 - 2 * r3] - t5[e3 + r3]], o3 = On[112 + ((a3 + 4) >> 3)] ;(t5[e3 - r3] = Bn[255 + n3 + On[112 + ((a3 + 3) >> 3)]]), (t5[e3 + 0] = Bn[255 + i3 - o3]) } function Re(t5, e3, r3, n3) { var i3 = t5[e3 + 0], a3 = t5[e3 + r3] return ( Mn[255 + t5[e3 - 2 * r3] - t5[e3 - r3]] > n3 || Mn[255 + a3 - i3] > n3 ) } function Te(t5, e3, r3, n3) { return ( 4 * Mn[255 + t5[e3 - r3] - t5[e3 + 0]] + Mn[255 + t5[e3 - 2 * r3] - t5[e3 + r3]] <= n3 ) } function Ue(t5, e3, r3, n3, i3) { var a3 = t5[e3 - 3 * r3], o3 = t5[e3 - 2 * r3], s3 = t5[e3 - r3], c4 = t5[e3 + 0], u4 = t5[e3 + r3], h4 = t5[e3 + 2 * r3], l4 = t5[e3 + 3 * r3] return 4 * Mn[255 + s3 - c4] + Mn[255 + o3 - u4] > n3 ? 0 : Mn[255 + t5[e3 - 4 * r3] - a3] <= i3 && Mn[255 + a3 - o3] <= i3 && Mn[255 + o3 - s3] <= i3 && Mn[255 + l4 - h4] <= i3 && Mn[255 + h4 - u4] <= i3 && Mn[255 + u4 - c4] <= i3 } function ze(t5, e3, r3, n3) { var i3 = 2 * n3 + 1 for (n3 = 0; 16 > n3; ++n3) Te(t5, e3 + n3, r3, i3) && De(t5, e3 + n3, r3) } function He(t5, e3, r3, n3) { var i3 = 2 * n3 + 1 for (n3 = 0; 16 > n3; ++n3) Te(t5, e3 + n3 * r3, 1, i3) && De(t5, e3 + n3 * r3, 1) } function We(t5, e3, r3, n3) { var i3 for (i3 = 3; 0 < i3; --i3) ze(t5, (e3 += 4 * r3), r3, n3) } function Ve(t5, e3, r3, n3) { var i3 for (i3 = 3; 0 < i3; --i3) He(t5, (e3 += 4), r3, n3) } function Ge(t5, e3, r3, n3, i3, a3, o3, s3) { for (a3 = 2 * a3 + 1; 0 < i3--; ) { if (Ue(t5, e3, r3, a3, o3)) if (Re(t5, e3, r3, s3)) De(t5, e3, r3) else { var c4 = t5, u4 = e3, h4 = r3, l4 = c4[u4 - 2 * h4], f4 = c4[u4 - h4], d5 = c4[u4 + 0], p4 = c4[u4 + h4], g4 = c4[u4 + 2 * h4], m4 = (27 * (b4 = jn[1020 + 3 * (d5 - f4) + jn[1020 + l4 - p4]]) + 63) >> 7, v6 = (18 * b4 + 63) >> 7, b4 = (9 * b4 + 63) >> 7 ;(c4[u4 - 3 * h4] = Bn[255 + c4[u4 - 3 * h4] + b4]), (c4[u4 - 2 * h4] = Bn[255 + l4 + v6]), (c4[u4 - h4] = Bn[255 + f4 + m4]), (c4[u4 + 0] = Bn[255 + d5 - m4]), (c4[u4 + h4] = Bn[255 + p4 - v6]), (c4[u4 + 2 * h4] = Bn[255 + g4 - b4]) } e3 += n3 } } function Ye(t5, e3, r3, n3, i3, a3, o3, s3) { for (a3 = 2 * a3 + 1; 0 < i3--; ) { if (Ue(t5, e3, r3, a3, o3)) if (Re(t5, e3, r3, s3)) De(t5, e3, r3) else { var c4 = t5, u4 = e3, h4 = r3, l4 = c4[u4 - h4], f4 = c4[u4 + 0], d5 = c4[u4 + h4], p4 = On[112 + (((g4 = 3 * (f4 - l4)) + 4) >> 3)], g4 = On[112 + ((g4 + 3) >> 3)], m4 = (p4 + 1) >> 1 ;(c4[u4 - 2 * h4] = Bn[255 + c4[u4 - 2 * h4] + m4]), (c4[u4 - h4] = Bn[255 + l4 + g4]), (c4[u4 + 0] = Bn[255 + f4 - p4]), (c4[u4 + h4] = Bn[255 + d5 - m4]) } e3 += n3 } } function Je(t5, e3, r3, n3, i3, a3) { Ge(t5, e3, r3, 1, 16, n3, i3, a3) } function Xe(t5, e3, r3, n3, i3, a3) { Ge(t5, e3, 1, r3, 16, n3, i3, a3) } function Ke(t5, e3, r3, n3, i3, a3) { var o3 for (o3 = 3; 0 < o3; --o3) Ye(t5, (e3 += 4 * r3), r3, 1, 16, n3, i3, a3) } function Ze(t5, e3, r3, n3, i3, a3) { var o3 for (o3 = 3; 0 < o3; --o3) Ye(t5, (e3 += 4), 1, r3, 16, n3, i3, a3) } function $e(t5, e3, r3, n3, i3, a3, o3, s3) { Ge(t5, e3, i3, 1, 8, a3, o3, s3), Ge(r3, n3, i3, 1, 8, a3, o3, s3) } function Qe(t5, e3, r3, n3, i3, a3, o3, s3) { Ge(t5, e3, 1, i3, 8, a3, o3, s3), Ge(r3, n3, 1, i3, 8, a3, o3, s3) } function tr2(t5, e3, r3, n3, i3, a3, o3, s3) { Ye(t5, e3 + 4 * i3, i3, 1, 8, a3, o3, s3), Ye(r3, n3 + 4 * i3, i3, 1, 8, a3, o3, s3) } function er(t5, e3, r3, n3, i3, a3, o3, s3) { Ye(t5, e3 + 4, 1, i3, 8, a3, o3, s3), Ye(r3, n3 + 4, 1, i3, 8, a3, o3, s3) } function rr2() { ;(this.ba = new ot2()), (this.ec = []), (this.cc = []), (this.Mc = []), (this.Dc = this.Nc = this.dc = this.fc = 0), (this.Oa = new ct2()), (this.memory = 0), (this.Ib = 'OutputFunc'), (this.Jb = 'OutputAlphaFunc'), (this.Nd = 'OutputRowFunc') } function nr() { ;(this.data = []), (this.offset = this.kd = this.ha = this.w = 0), (this.na = []), (this.xa = this.gb = this.Ja = this.Sa = this.P = 0) } function ir() { ;(this.nc = this.Ea = this.b = this.hc = 0), (this.K = []), (this.w = 0) } function ar2() { ;(this.ua = 0), (this.Wa = new M2()), (this.vb = new M2()), (this.md = this.xc = this.wc = 0), (this.vc = []), (this.Wb = 0), (this.Ya = new d4()), (this.yc = new l3()) } function or() { ;(this.xb = this.a = 0), (this.l = new Gt2()), (this.ca = new ot2()), (this.V = []), (this.Ba = 0), (this.Ta = []), (this.Ua = 0), (this.m = new N3()), (this.Pb = 0), (this.wd = new N3()), (this.Ma = this.$ = this.C = this.i = this.c = this.xd = 0), (this.s = new ar2()), (this.ab = 0), (this.gc = o2(4, ir)), (this.Oc = 0) } function sr2() { ;(this.Lc = this.Z = this.$a = this.i = this.c = 0), (this.l = new Gt2()), (this.ic = 0), (this.ca = []), (this.tb = 0), (this.qd = null), (this.rd = 0) } function cr(t5, e3, r3, n3, i3, a3, o3) { for (t5 = null == t5 ? 0 : t5[e3 + 0], e3 = 0; e3 < o3; ++e3) (i3[a3 + e3] = (t5 + r3[n3 + e3]) & 255), (t5 = i3[a3 + e3]) } function ur(t5, e3, r3, n3, i3, a3, o3) { var s3 if (null == t5) cr(null, null, r3, n3, i3, a3, o3) else for (s3 = 0; s3 < o3; ++s3) i3[a3 + s3] = (t5[e3 + s3] + r3[n3 + s3]) & 255 } function hr2(t5, e3, r3, n3, i3, a3, o3) { if (null == t5) cr(null, null, r3, n3, i3, a3, o3) else { var s3, c4 = t5[e3 + 0], u4 = c4, h4 = c4 for (s3 = 0; s3 < o3; ++s3) (u4 = h4 + (c4 = t5[e3 + s3]) - u4), (h4 = (r3[n3 + s3] + (-256 & u4 ? (0 > u4 ? 0 : 255) : u4)) & 255), (u4 = c4), (i3[a3 + s3] = h4) } } function lr(t5, r3, i3, o3) { var s3 = r3.width, c4 = r3.o if ((e2(null != t5 && null != r3), 0 > i3 || 0 >= o3 || i3 + o3 > c4)) return null if (!t5.Cc) { if (null == t5.ga) { var u4 if ( ((t5.ga = new sr2()), (u4 = null == t5.ga) || ((u4 = r3.width * r3.o), e2(0 == t5.Gb.length), (t5.Gb = a2(u4)), (t5.Uc = 0), null == t5.Gb ? (u4 = 0) : ((t5.mb = t5.Gb), (t5.nb = t5.Uc), (t5.rc = null), (u4 = 1)), (u4 = !u4)), !u4) ) { u4 = t5.ga var h4 = t5.Fa, l4 = t5.P, f4 = t5.qc, d5 = t5.mb, p4 = t5.nb, g4 = l4 + 1, m4 = f4 - 1, b4 = u4.l if ( (e2(null != h4 && null != d5 && null != r3), (mi[0] = null), (mi[1] = cr), (mi[2] = ur), (mi[3] = hr2), (u4.ca = d5), (u4.tb = p4), (u4.c = r3.width), (u4.i = r3.height), e2(0 < u4.c && 0 < u4.i), 1 >= f4) ) r3 = 0 else if ( ((u4.$a = (h4[l4 + 0] >> 0) & 3), (u4.Z = (h4[l4 + 0] >> 2) & 3), (u4.Lc = (h4[l4 + 0] >> 4) & 3), (l4 = (h4[l4 + 0] >> 6) & 3), 0 > u4.$a || 1 < u4.$a || 4 <= u4.Z || 1 < u4.Lc || l4) ) r3 = 0 else if ( ((b4.put = dt2), (b4.ac = ft2), (b4.bc = pt3), (b4.ma = u4), (b4.width = r3.width), (b4.height = r3.height), (b4.Da = r3.Da), (b4.v = r3.v), (b4.va = r3.va), (b4.j = r3.j), (b4.o = r3.o), u4.$a) ) t: { e2(1 == u4.$a), (r3 = kt2()) e: for (;;) { if (null == r3) { r3 = 0 break t } if ( (e2(null != u4), (u4.mc = r3), (r3.c = u4.c), (r3.i = u4.i), (r3.l = u4.l), (r3.l.ma = u4), (r3.l.width = u4.c), (r3.l.height = u4.i), (r3.a = 0), v5(r3.m, h4, g4, m4), !It2(u4.c, u4.i, 1, r3, null)) ) break e if ( (1 == r3.ab && 3 == r3.gc[0].hc && At2(r3.s) ? ((u4.ic = 1), (h4 = r3.c * r3.i), (r3.Ta = null), (r3.Ua = 0), (r3.V = a2(h4)), (r3.Ba = 0), null == r3.V ? ((r3.a = 1), (r3 = 0)) : (r3 = 1)) : ((u4.ic = 0), (r3 = Ft2(r3, u4.c))), !r3) ) break e r3 = 1 break t } ;(u4.mc = null), (r3 = 0) } else r3 = m4 >= u4.c * u4.i u4 = !r3 } if (u4) return null 1 != t5.ga.Lc ? (t5.Ga = 0) : (o3 = c4 - i3) } e2(null != t5.ga), e2(i3 + o3 <= c4) t: { if (((r3 = (h4 = t5.ga).c), (c4 = h4.l.o), 0 == h4.$a)) { if ( ((g4 = t5.rc), (m4 = t5.Vc), (b4 = t5.Fa), (l4 = t5.P + 1 + i3 * r3), (f4 = t5.mb), (d5 = t5.nb + i3 * r3), e2(l4 <= t5.P + t5.qc), 0 != h4.Z) ) for (e2(null != mi[h4.Z]), u4 = 0; u4 < o3; ++u4) mi[h4.Z](g4, m4, b4, l4, f4, d5, r3), (g4 = f4), (m4 = d5), (d5 += r3), (l4 += r3) else for (u4 = 0; u4 < o3; ++u4) n2(f4, d5, b4, l4, r3), (g4 = f4), (m4 = d5), (d5 += r3), (l4 += r3) ;(t5.rc = g4), (t5.Vc = m4) } else { if ( (e2(null != h4.mc), (r3 = i3 + o3), e2(null != (u4 = h4.mc)), e2(r3 <= u4.i), u4.C >= r3) ) r3 = 1 else if ((h4.ic || mr(), h4.ic)) { ;(h4 = u4.V), (g4 = u4.Ba), (m4 = u4.c) var y4 = u4.i, w4 = ((b4 = 1), (l4 = u4.$ / m4), (f4 = u4.$ % m4), (d5 = u4.m), (p4 = u4.s), u4.$), N4 = m4 * y4, L4 = m4 * r3, x3 = p4.wc, _3 = w4 < L4 ? wt2(p4, f4, l4) : null e2(w4 <= N4), e2(r3 <= y4), e2(At2(p4)) e: for (;;) { for (; !d5.h && w4 < L4; ) { if ( (f4 & x3 || (_3 = wt2(p4, f4, l4)), e2(null != _3), S2(d5), 256 > (y4 = bt2(_3.G[0], _3.H[0], d5))) ) (h4[g4 + w4] = y4), ++w4, ++f4 >= m4 && ((f4 = 0), ++l4 <= r3 && !(l4 % 16) && St(u4, l4)) else { if (!(280 > y4)) { b4 = 0 break e } y4 = mt2(y4 - 256, d5) var P3, k3 = bt2(_3.G[4], _3.H[4], d5) if ( (S2(d5), !( w4 >= (k3 = vt2(m4, (k3 = mt2(k3, d5)))) && N4 - w4 >= y4 )) ) { b4 = 0 break e } for (P3 = 0; P3 < y4; ++P3) h4[g4 + w4 + P3] = h4[g4 + w4 + P3 - k3] for (w4 += y4, f4 += y4; f4 >= m4; ) (f4 -= m4), ++l4 <= r3 && !(l4 % 16) && St(u4, l4) w4 < L4 && f4 & x3 && (_3 = wt2(p4, f4, l4)) } e2(d5.h == A3(d5)) } St(u4, l4 > r3 ? r3 : l4) break e } !b4 || (d5.h && w4 < N4) ? ((b4 = 0), (u4.a = d5.h ? 5 : 3)) : (u4.$ = w4), (r3 = b4) } else r3 = _t2(u4, u4.V, u4.Ba, u4.c, u4.i, r3, Ct2) if (!r3) { o3 = 0 break t } } i3 + o3 >= c4 && (t5.Cc = 1), (o3 = 1) } if (!o3) return null if ( t5.Cc && (null != (o3 = t5.ga) && (o3.mc = null), (t5.ga = null), 0 < t5.Ga) ) return alert('todo:WebPDequantizeLevels'), null } return t5.nb + i3 * s3 } function fr2(t5, e3, r3, n3, i3, a3) { for (; 0 < i3--; ) { var o3, s3 = t5, c4 = e3 + (r3 ? 1 : 0), u4 = t5, h4 = e3 + (r3 ? 0 : 3) for (o3 = 0; o3 < n3; ++o3) { var l4 = u4[h4 + 4 * o3] 255 != l4 && ((l4 *= 32897), (s3[c4 + 4 * o3 + 0] = (s3[c4 + 4 * o3 + 0] * l4) >> 23), (s3[c4 + 4 * o3 + 1] = (s3[c4 + 4 * o3 + 1] * l4) >> 23), (s3[c4 + 4 * o3 + 2] = (s3[c4 + 4 * o3 + 2] * l4) >> 23)) } e3 += a3 } } function dr(t5, e3, r3, n3, i3) { for (; 0 < n3--; ) { var a3 for (a3 = 0; a3 < r3; ++a3) { var o3 = t5[e3 + 2 * a3 + 0], s3 = 15 & (u4 = t5[e3 + 2 * a3 + 1]), c4 = 4369 * s3, u4 = (((240 & u4) | (u4 >> 4)) * c4) >> 16 ;(t5[e3 + 2 * a3 + 0] = (((((240 & o3) | (o3 >> 4)) * c4) >> 16) & 240) | ((((((15 & o3) | (o3 << 4)) * c4) >> 16) >> 4) & 15)), (t5[e3 + 2 * a3 + 1] = (240 & u4) | s3) } e3 += i3 } } function pr(t5, e3, r3, n3, i3, a3, o3, s3) { var c4, u4, h4 = 255 for (u4 = 0; u4 < i3; ++u4) { for (c4 = 0; c4 < n3; ++c4) { var l4 = t5[e3 + c4] ;(a3[o3 + 4 * c4] = l4), (h4 &= l4) } ;(e3 += r3), (o3 += s3) } return 255 != h4 } function gr(t5, e3, r3, n3, i3) { var a3 for (a3 = 0; a3 < i3; ++a3) r3[n3 + a3] = t5[e3 + a3] >> 8 } function mr() { ;(An = fr2), (xn = dr), (Sn = pr), (_n = gr) } function vr(r3, n3, i3) { t4[r3] = function ( t5, r4, a3, o3, s3, c4, u4, h4, l4, f4, d5, p4, g4, m4, v6, b4, y4 ) { var w4, N4 = (y4 - 1) >> 1, L4 = s3[c4 + 0] | (u4[h4 + 0] << 16), A4 = l4[f4 + 0] | (d5[p4 + 0] << 16) e2(null != t5) var x3 = (3 * L4 + A4 + 131074) >> 2 for ( n3(t5[r4 + 0], 255 & x3, x3 >> 16, g4, m4), null != a3 && ((x3 = (3 * A4 + L4 + 131074) >> 2), n3(a3[o3 + 0], 255 & x3, x3 >> 16, v6, b4)), w4 = 1; w4 <= N4; ++w4 ) { var S3 = s3[c4 + w4] | (u4[h4 + w4] << 16), _3 = l4[f4 + w4] | (d5[p4 + w4] << 16), P3 = L4 + S3 + A4 + _3 + 524296, k3 = (P3 + 2 * (S3 + A4)) >> 3 ;(x3 = (k3 + L4) >> 1), (L4 = ((P3 = (P3 + 2 * (L4 + _3)) >> 3) + S3) >> 1), n3( t5[r4 + 2 * w4 - 1], 255 & x3, x3 >> 16, g4, m4 + (2 * w4 - 1) * i3 ), n3( t5[r4 + 2 * w4 - 0], 255 & L4, L4 >> 16, g4, m4 + (2 * w4 - 0) * i3 ), null != a3 && ((x3 = (P3 + A4) >> 1), (L4 = (k3 + _3) >> 1), n3( a3[o3 + 2 * w4 - 1], 255 & x3, x3 >> 16, v6, b4 + (2 * w4 - 1) * i3 ), n3( a3[o3 + 2 * w4 + 0], 255 & L4, L4 >> 16, v6, b4 + (2 * w4 + 0) * i3 )), (L4 = S3), (A4 = _3) } 1 & y4 || ((x3 = (3 * L4 + A4 + 131074) >> 2), n3(t5[r4 + y4 - 1], 255 & x3, x3 >> 16, g4, m4 + (y4 - 1) * i3), null != a3 && ((x3 = (3 * A4 + L4 + 131074) >> 2), n3(a3[o3 + y4 - 1], 255 & x3, x3 >> 16, v6, b4 + (y4 - 1) * i3))) } } function br() { ;(vi2[En] = bi), (vi2[qn] = wi), (vi2[Dn] = yi), (vi2[Rn] = Ni), (vi2[Tn] = Li), (vi2[Un] = Ai), (vi2[zn] = xi), (vi2[Hn] = wi), (vi2[Wn] = Ni), (vi2[Vn] = Li), (vi2[Gn] = Ai) } function yr(t5) { return t5 & ~Fi ? (0 > t5 ? 0 : 255) : t5 >> Ii } function wr(t5, e3) { return yr(((19077 * t5) >> 8) + ((26149 * e3) >> 8) - 14234) } function Nr(t5, e3, r3) { return yr( ((19077 * t5) >> 8) - ((6419 * e3) >> 8) - ((13320 * r3) >> 8) + 8708 ) } function Lr(t5, e3) { return yr(((19077 * t5) >> 8) + ((33050 * e3) >> 8) - 17685) } function Ar(t5, e3, r3, n3, i3) { ;(n3[i3 + 0] = wr(t5, r3)), (n3[i3 + 1] = Nr(t5, e3, r3)), (n3[i3 + 2] = Lr(t5, e3)) } function xr(t5, e3, r3, n3, i3) { ;(n3[i3 + 0] = Lr(t5, e3)), (n3[i3 + 1] = Nr(t5, e3, r3)), (n3[i3 + 2] = wr(t5, r3)) } function Sr(t5, e3, r3, n3, i3) { var a3 = Nr(t5, e3, r3) ;(e3 = ((a3 << 3) & 224) | (Lr(t5, e3) >> 3)), (n3[i3 + 0] = (248 & wr(t5, r3)) | (a3 >> 5)), (n3[i3 + 1] = e3) } function _r(t5, e3, r3, n3, i3) { var a3 = (240 & Lr(t5, e3)) | 15 ;(n3[i3 + 0] = (240 & wr(t5, r3)) | (Nr(t5, e3, r3) >> 4)), (n3[i3 + 1] = a3) } function Pr(t5, e3, r3, n3, i3) { ;(n3[i3 + 0] = 255), Ar(t5, e3, r3, n3, i3 + 1) } function kr(t5, e3, r3, n3, i3) { xr(t5, e3, r3, n3, i3), (n3[i3 + 3] = 255) } function Ir(t5, e3, r3, n3, i3) { Ar(t5, e3, r3, n3, i3), (n3[i3 + 3] = 255) } function Vt2(t5, e3) { return 0 > t5 ? 0 : t5 > e3 ? e3 : t5 } function Fr(e3, r3, n3) { t4[e3] = function (t5, e4, i3, a3, o3, s3, c4, u4, h4) { for (var l4 = u4 + (-2 & h4) * n3; u4 != l4; ) r3(t5[e4 + 0], i3[a3 + 0], o3[s3 + 0], c4, u4), r3(t5[e4 + 1], i3[a3 + 0], o3[s3 + 0], c4, u4 + n3), (e4 += 2), ++a3, ++s3, (u4 += 2 * n3) 1 & h4 && r3(t5[e4 + 0], i3[a3 + 0], o3[s3 + 0], c4, u4) } } function Cr(t5, e3, r3) { return 0 == r3 ? (0 == t5 ? (0 == e3 ? 6 : 5) : 0 == e3 ? 4 : 0) : r3 } function jr(t5, e3, r3, n3, i3) { switch (t5 >>> 30) { case 3: on2(e3, r3, n3, i3, 0) break case 2: sn(e3, r3, n3, i3) break case 1: un(e3, r3, n3, i3) } } function Or(t5, e3) { var r3, a3, o3 = e3.M, s3 = e3.Nb, c4 = t5.oc, u4 = t5.pc + 40, h4 = t5.oc, l4 = t5.pc + 584, f4 = t5.oc, d5 = t5.pc + 600 for (r3 = 0; 16 > r3; ++r3) c4[u4 + 32 * r3 - 1] = 129 for (r3 = 0; 8 > r3; ++r3) (h4[l4 + 32 * r3 - 1] = 129), (f4[d5 + 32 * r3 - 1] = 129) for ( 0 < o3 ? (c4[u4 - 1 - 32] = h4[l4 - 1 - 32] = f4[d5 - 1 - 32] = 129) : (i2(c4, u4 - 32 - 1, 127, 21), i2(h4, l4 - 32 - 1, 127, 9), i2(f4, d5 - 32 - 1, 127, 9)), a3 = 0; a3 < t5.za; ++a3 ) { var p4 = e3.ya[e3.aa + a3] if (0 < a3) { for (r3 = -1; 16 > r3; ++r3) n2(c4, u4 + 32 * r3 - 4, c4, u4 + 32 * r3 + 12, 4) for (r3 = -1; 8 > r3; ++r3) n2(h4, l4 + 32 * r3 - 4, h4, l4 + 32 * r3 + 4, 4), n2(f4, d5 + 32 * r3 - 4, f4, d5 + 32 * r3 + 4, 4) } var g4 = t5.Gd, m4 = t5.Hd + a3, v6 = p4.ad, b4 = p4.Hc if ( (0 < o3 && (n2(c4, u4 - 32, g4[m4].y, 0, 16), n2(h4, l4 - 32, g4[m4].f, 0, 8), n2(f4, d5 - 32, g4[m4].ea, 0, 8)), p4.Za) ) { var y4 = c4, w4 = u4 - 32 + 16 for ( 0 < o3 && (a3 >= t5.za - 1 ? i2(y4, w4, g4[m4].y[15], 4) : n2(y4, w4, g4[m4 + 1].y, 0, 4)), r3 = 0; 4 > r3; r3++ ) y4[w4 + 128 + r3] = y4[w4 + 256 + r3] = y4[w4 + 384 + r3] = y4[w4 + 0 + r3] for (r3 = 0; 16 > r3; ++r3, b4 <<= 2) (y4 = c4), (w4 = u4 + Di[r3]), fi2[p4.Ob[r3]](y4, w4), jr(b4, v6, 16 * +r3, y4, w4) } else if (((y4 = Cr(a3, o3, p4.Ob[0])), li[y4](c4, u4), 0 != b4)) for (r3 = 0; 16 > r3; ++r3, b4 <<= 2) jr(b4, v6, 16 * +r3, c4, u4 + Di[r3]) for ( r3 = p4.Gc, y4 = Cr(a3, o3, p4.Dd), di[y4](h4, l4), di[y4](f4, d5), b4 = v6, y4 = h4, w4 = l4, 255 & (p4 = r3 >> 0) && (170 & p4 ? cn(b4, 256, y4, w4) : hn(b4, 256, y4, w4)), p4 = f4, b4 = d5, 255 & (r3 >>= 8) && (170 & r3 ? cn(v6, 320, p4, b4) : hn(v6, 320, p4, b4)), o3 < t5.Ub - 1 && (n2(g4[m4].y, 0, c4, u4 + 480, 16), n2(g4[m4].f, 0, h4, l4 + 224, 8), n2(g4[m4].ea, 0, f4, d5 + 224, 8)), r3 = 8 * s3 * t5.B, g4 = t5.sa, m4 = t5.ta + 16 * a3 + 16 * s3 * t5.R, v6 = t5.qa, p4 = t5.ra + 8 * a3 + r3, b4 = t5.Ha, y4 = t5.Ia + 8 * a3 + r3, r3 = 0; 16 > r3; ++r3 ) n2(g4, m4 + r3 * t5.R, c4, u4 + 32 * r3, 16) for (r3 = 0; 8 > r3; ++r3) n2(v6, p4 + r3 * t5.B, h4, l4 + 32 * r3, 8), n2(b4, y4 + r3 * t5.B, f4, d5 + 32 * r3, 8) } } function Br(t5, n3, i3, a3, o3, s3, c4, u4, h4) { var l4 = [0], f4 = [0], d5 = 0, p4 = null != h4 ? h4.kd : 0, g4 = null != h4 ? h4 : new nr() if (null == t5 || 12 > i3) return 7 ;(g4.data = t5), (g4.w = n3), (g4.ha = i3), (n3 = [n3]), (i3 = [i3]), (g4.gb = [g4.gb]) t: { var m4 = n3, b4 = i3, y4 = g4.gb if ( (e2(null != t5), e2(null != b4), e2(null != y4), (y4[0] = 0), 12 <= b4[0] && !r2(t5, m4[0], 'RIFF')) ) { if (r2(t5, m4[0] + 8, 'WEBP')) { y4 = 3 break t } var w4 = j2(t5, m4[0] + 4) if (12 > w4 || 4294967286 < w4) { y4 = 3 break t } if (p4 && w4 > b4[0] - 8) { y4 = 7 break t } ;(y4[0] = w4), (m4[0] += 12), (b4[0] -= 12) } y4 = 0 } if (0 != y4) return y4 for (w4 = 0 < g4.gb[0], i3 = i3[0]; ; ) { t: { var L4 = t5 ;(b4 = n3), (y4 = i3) var A4 = l4, x3 = f4, S3 = (m4 = [0]) if ((((k3 = d5 = [d5])[0] = 0), 8 > y4[0])) y4 = 7 else { if (!r2(L4, b4[0], 'VP8X')) { if (10 != j2(L4, b4[0] + 4)) { y4 = 3 break t } if (18 > y4[0]) { y4 = 7 break t } var _3 = j2(L4, b4[0] + 8), P3 = 1 + C2(L4, b4[0] + 12) if (2147483648 <= P3 * (L4 = 1 + C2(L4, b4[0] + 15))) { y4 = 3 break t } null != S3 && (S3[0] = _3), null != A4 && (A4[0] = P3), null != x3 && (x3[0] = L4), (b4[0] += 18), (y4[0] -= 18), (k3[0] = 1) } y4 = 0 } } if (((d5 = d5[0]), (m4 = m4[0]), 0 != y4)) return y4 if (((b4 = !!(2 & m4)), !w4 && d5)) return 3 if ( (null != s3 && (s3[0] = !!(16 & m4)), null != c4 && (c4[0] = b4), null != u4 && (u4[0] = 0), (c4 = l4[0]), (m4 = f4[0]), d5 && b4 && null == h4) ) { y4 = 0 break } if (4 > i3) { y4 = 7 break } if ((w4 && d5) || (!w4 && !d5 && !r2(t5, n3[0], 'ALPH'))) { ;(i3 = [i3]), (g4.na = [g4.na]), (g4.P = [g4.P]), (g4.Sa = [g4.Sa]) t: { ;(_3 = t5), (y4 = n3), (w4 = i3) var k3 = g4.gb ;(A4 = g4.na), (x3 = g4.P), (S3 = g4.Sa) ;(P3 = 22), e2(null != _3), e2(null != w4), (L4 = y4[0]) var I3 = w4[0] for ( e2(null != A4), e2(null != S3), A4[0] = null, x3[0] = null, S3[0] = 0; ; ) { if (((y4[0] = L4), (w4[0] = I3), 8 > I3)) { y4 = 7 break t } var F3 = j2(_3, L4 + 4) if (4294967286 < F3) { y4 = 3 break t } var O3 = (8 + F3 + 1) & -2 if (((P3 += O3), 0 < k3 && P3 > k3)) { y4 = 3 break t } if (!r2(_3, L4, 'VP8 ') || !r2(_3, L4, 'VP8L')) { y4 = 0 break t } if (I3[0] < O3) { y4 = 7 break t } r2(_3, L4, 'ALPH') || ((A4[0] = _3), (x3[0] = L4 + 8), (S3[0] = F3)), (L4 += O3), (I3 -= O3) } } if ( ((i3 = i3[0]), (g4.na = g4.na[0]), (g4.P = g4.P[0]), (g4.Sa = g4.Sa[0]), 0 != y4) ) break } ;(i3 = [i3]), (g4.Ja = [g4.Ja]), (g4.xa = [g4.xa]) t: if ( ((k3 = t5), (y4 = n3), (w4 = i3), (A4 = g4.gb[0]), (x3 = g4.Ja), (S3 = g4.xa), (_3 = y4[0]), (L4 = !r2(k3, _3, 'VP8 ')), (P3 = !r2(k3, _3, 'VP8L')), e2(null != k3), e2(null != w4), e2(null != x3), e2(null != S3), 8 > w4[0]) ) y4 = 7 else { if (L4 || P3) { if (((k3 = j2(k3, _3 + 4)), 12 <= A4 && k3 > A4 - 12)) { y4 = 3 break t } if (p4 && k3 > w4[0] - 8) { y4 = 7 break t } ;(x3[0] = k3), (y4[0] += 8), (w4[0] -= 8), (S3[0] = P3) } else (S3[0] = 5 <= w4[0] && 47 == k3[_3 + 0] && !(k3[_3 + 4] >> 5)), (x3[0] = w4[0]) y4 = 0 } if ( ((i3 = i3[0]), (g4.Ja = g4.Ja[0]), (g4.xa = g4.xa[0]), (n3 = n3[0]), 0 != y4) ) break if (4294967286 < g4.Ja) return 3 if ( (null == u4 || b4 || (u4[0] = g4.xa ? 2 : 1), (c4 = [c4]), (m4 = [m4]), g4.xa) ) { if (5 > i3) { y4 = 7 break } ;(u4 = c4), (p4 = m4), (b4 = s3), null == t5 || 5 > i3 ? (t5 = 0) : 5 <= i3 && 47 == t5[n3 + 0] && !(t5[n3 + 4] >> 5) ? ((w4 = [0]), (k3 = [0]), (A4 = [0]), v5((x3 = new N3()), t5, n3, i3), gt2(x3, w4, k3, A4) ? (null != u4 && (u4[0] = w4[0]), null != p4 && (p4[0] = k3[0]), null != b4 && (b4[0] = A4[0]), (t5 = 1)) : (t5 = 0)) : (t5 = 0) } else { if (10 > i3) { y4 = 7 break } ;(u4 = m4), null == t5 || 10 > i3 || !Xt2(t5, n3 + 3, i3 - 3) ? (t5 = 0) : ((p4 = t5[n3 + 0] | (t5[n3 + 1] << 8) | (t5[n3 + 2] << 16)), (b4 = 16383 & ((t5[n3 + 7] << 8) | t5[n3 + 6])), (t5 = 16383 & ((t5[n3 + 9] << 8) | t5[n3 + 8])), 1 & p4 || 3 < ((p4 >> 1) & 7) || !((p4 >> 4) & 1) || p4 >> 5 >= g4.Ja || !b4 || !t5 ? (t5 = 0) : (c4 && (c4[0] = b4), u4 && (u4[0] = t5), (t5 = 1))) } if (!t5) return 3 if (((c4 = c4[0]), (m4 = m4[0]), d5 && (l4[0] != c4 || f4[0] != m4))) return 3 null != h4 && ((h4[0] = g4), (h4.offset = n3 - h4.w), e2(4294967286 > n3 - h4.w), e2(h4.offset == h4.ha - i3)) break } return 0 == y4 || (7 == y4 && d5 && null == h4) ? (null != s3 && (s3[0] |= null != g4.na && 0 < g4.na.length), null != a3 && (a3[0] = c4), null != o3 && (o3[0] = m4), 0) : y4 } function Mr(t5, e3, r3) { var n3 = e3.width, i3 = e3.height, a3 = 0, o3 = 0, s3 = n3, c4 = i3 if ( ((e3.Da = null != t5 && 0 < t5.Da), e3.Da && ((s3 = t5.cd), (c4 = t5.bd), (a3 = t5.v), (o3 = t5.j), 11 > r3 || ((a3 &= -2), (o3 &= -2)), 0 > a3 || 0 > o3 || 0 >= s3 || 0 >= c4 || a3 + s3 > n3 || o3 + c4 > i3)) ) return 0 if ( ((e3.v = a3), (e3.j = o3), (e3.va = a3 + s3), (e3.o = o3 + c4), (e3.U = s3), (e3.T = c4), (e3.da = null != t5 && 0 < t5.da), e3.da) ) { if (!E2(s3, c4, (r3 = [t5.ib]), (a3 = [t5.hb]))) return 0 ;(e3.ib = r3[0]), (e3.hb = a3[0]) } return ( (e3.ob = null != t5 && t5.ob), (e3.Kb = null == t5 || !t5.Sd), e3.da && ((e3.ob = e3.ib < (3 * n3) / 4 && e3.hb < (3 * i3) / 4), (e3.Kb = 0)), 1 ) } function Er(t5) { if (null == t5) return 2 if (11 > t5.S) { var e3 = t5.f.RGBA ;(e3.fb += (t5.height - 1) * e3.A), (e3.A = -e3.A) } else (e3 = t5.f.kb), (t5 = t5.height), (e3.O += (t5 - 1) * e3.fa), (e3.fa = -e3.fa), (e3.N += ((t5 - 1) >> 1) * e3.Ab), (e3.Ab = -e3.Ab), (e3.W += ((t5 - 1) >> 1) * e3.Db), (e3.Db = -e3.Db), null != e3.F && ((e3.J += (t5 - 1) * e3.lb), (e3.lb = -e3.lb)) return 0 } function qr(t5, e3, r3, n3) { if (null == n3 || 0 >= t5 || 0 >= e3) return 2 if (null != r3) { if (r3.Da) { var i3 = r3.cd, o3 = r3.bd, s3 = -2 & r3.v, c4 = -2 & r3.j if ( 0 > s3 || 0 > c4 || 0 >= i3 || 0 >= o3 || s3 + i3 > t5 || c4 + o3 > e3 ) return 2 ;(t5 = i3), (e3 = o3) } if (r3.da) { if (!E2(t5, e3, (i3 = [r3.ib]), (o3 = [r3.hb]))) return 2 ;(t5 = i3[0]), (e3 = o3[0]) } } ;(n3.width = t5), (n3.height = e3) t: { var u4 = n3.width, h4 = n3.height if (((t5 = n3.S), 0 >= u4 || 0 >= h4 || !(t5 >= En && 13 > t5))) t5 = 2 else { if (0 >= n3.Rd && null == n3.sd) { s3 = o3 = i3 = e3 = 0 var l4 = (c4 = u4 * zi[t5]) * h4 if ( (11 > t5 || ((o3 = ((h4 + 1) / 2) * (e3 = (u4 + 1) / 2)), 12 == t5 && (s3 = (i3 = u4) * h4)), null == (h4 = a2(l4 + 2 * o3 + s3))) ) { t5 = 1 break t } ;(n3.sd = h4), 11 > t5 ? (((u4 = n3.f.RGBA).eb = h4), (u4.fb = 0), (u4.A = c4), (u4.size = l4)) : (((u4 = n3.f.kb).y = h4), (u4.O = 0), (u4.fa = c4), (u4.Fd = l4), (u4.f = h4), (u4.N = 0 + l4), (u4.Ab = e3), (u4.Cd = o3), (u4.ea = h4), (u4.W = 0 + l4 + o3), (u4.Db = e3), (u4.Ed = o3), 12 == t5 && ((u4.F = h4), (u4.J = 0 + l4 + 2 * o3)), (u4.Tc = s3), (u4.lb = i3)) } if ( ((e3 = 1), (i3 = n3.S), (o3 = n3.width), (s3 = n3.height), i3 >= En && 13 > i3) ) if (11 > i3) (t5 = n3.f.RGBA), (e3 &= (c4 = Math.abs(t5.A)) * (s3 - 1) + o3 <= t5.size), (e3 &= c4 >= o3 * zi[i3]), (e3 &= null != t5.eb) else { ;(t5 = n3.f.kb), (c4 = (o3 + 1) / 2), (l4 = (s3 + 1) / 2), (u4 = Math.abs(t5.fa)) h4 = Math.abs(t5.Ab) var f4 = Math.abs(t5.Db), d5 = Math.abs(t5.lb), p4 = d5 * (s3 - 1) + o3 ;(e3 &= u4 * (s3 - 1) + o3 <= t5.Fd), (e3 &= h4 * (l4 - 1) + c4 <= t5.Cd), (e3 = (e3 &= f4 * (l4 - 1) + c4 <= t5.Ed) & (u4 >= o3) & (h4 >= c4) & (f4 >= c4)), (e3 &= null != t5.y), (e3 &= null != t5.f), (e3 &= null != t5.ea), 12 == i3 && ((e3 &= d5 >= o3), (e3 &= p4 <= t5.Tc), (e3 &= null != t5.F)) } else e3 = 0 t5 = e3 ? 0 : 2 } } return 0 != t5 || (null != r3 && r3.fd && (t5 = Er(n3))), t5 } var Dr = 64, Rr = [ 0, 1, 3, 7, 15, 31, 63, 127, 255, 511, 1023, 2047, 4095, 8191, 16383, 32767, 65535, 131071, 262143, 524287, 1048575, 2097151, 4194303, 8388607, 16777215, ], Tr = 24, Ur = 32, zr = 8, Hr = [ 0, 0, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, ] R2('Predictor0', 'PredictorAdd0'), (t4.Predictor0 = function () { return 4278190080 }), (t4.Predictor1 = function (t5) { return t5 }), (t4.Predictor2 = function (t5, e3, r3) { return e3[r3 + 0] }), (t4.Predictor3 = function (t5, e3, r3) { return e3[r3 + 1] }), (t4.Predictor4 = function (t5, e3, r3) { return e3[r3 - 1] }), (t4.Predictor5 = function (t5, e3, r3) { return U2(U2(t5, e3[r3 + 1]), e3[r3 + 0]) }), (t4.Predictor6 = function (t5, e3, r3) { return U2(t5, e3[r3 - 1]) }), (t4.Predictor7 = function (t5, e3, r3) { return U2(t5, e3[r3 + 0]) }), (t4.Predictor8 = function (t5, e3, r3) { return U2(e3[r3 - 1], e3[r3 + 0]) }), (t4.Predictor9 = function (t5, e3, r3) { return U2(e3[r3 + 0], e3[r3 + 1]) }), (t4.Predictor10 = function (t5, e3, r3) { return U2(U2(t5, e3[r3 - 1]), U2(e3[r3 + 0], e3[r3 + 1])) }), (t4.Predictor11 = function (t5, e3, r3) { var n3 = e3[r3 + 0] return 0 >= W2( (n3 >> 24) & 255, (t5 >> 24) & 255, ((e3 = e3[r3 - 1]) >> 24) & 255 ) + W2((n3 >> 16) & 255, (t5 >> 16) & 255, (e3 >> 16) & 255) + W2((n3 >> 8) & 255, (t5 >> 8) & 255, (e3 >> 8) & 255) + W2(255 & n3, 255 & t5, 255 & e3) ? n3 : t5 }), (t4.Predictor12 = function (t5, e3, r3) { var n3 = e3[r3 + 0] return ( ((z2( ((t5 >> 24) & 255) + ((n3 >> 24) & 255) - (((e3 = e3[r3 - 1]) >> 24) & 255) ) << 24) | (z2(((t5 >> 16) & 255) + ((n3 >> 16) & 255) - ((e3 >> 16) & 255)) << 16) | (z2(((t5 >> 8) & 255) + ((n3 >> 8) & 255) - ((e3 >> 8) & 255)) << 8) | z2((255 & t5) + (255 & n3) - (255 & e3))) >>> 0 ) }), (t4.Predictor13 = function (t5, e3, r3) { var n3 = e3[r3 - 1] return ( ((H4(((t5 = U2(t5, e3[r3 + 0])) >> 24) & 255, (n3 >> 24) & 255) << 24) | (H4((t5 >> 16) & 255, (n3 >> 16) & 255) << 16) | (H4((t5 >> 8) & 255, (n3 >> 8) & 255) << 8) | H4((t5 >> 0) & 255, (n3 >> 0) & 255)) >>> 0 ) }) var Wr = t4.PredictorAdd0 ;(t4.PredictorAdd1 = V2), R2('Predictor2', 'PredictorAdd2'), R2('Predictor3', 'PredictorAdd3'), R2('Predictor4', 'PredictorAdd4'), R2('Predictor5', 'PredictorAdd5'), R2('Predictor6', 'PredictorAdd6'), R2('Predictor7', 'PredictorAdd7'), R2('Predictor8', 'PredictorAdd8'), R2('Predictor9', 'PredictorAdd9'), R2('Predictor10', 'PredictorAdd10'), R2('Predictor11', 'PredictorAdd11'), R2('Predictor12', 'PredictorAdd12'), R2('Predictor13', 'PredictorAdd13') var Vr = t4.PredictorAdd2 X2( 'ColorIndexInverseTransform', 'MapARGB', '32b', function (t5) { return (t5 >> 8) & 255 }, function (t5) { return t5 } ), X2( 'VP8LColorIndexInverseTransformAlpha', 'MapAlpha', '8b', function (t5) { return t5 }, function (t5) { return (t5 >> 8) & 255 } ) var Gr, Yr = t4.ColorIndexInverseTransform, Jr = t4.MapARGB, Xr = t4.VP8LColorIndexInverseTransformAlpha, Kr = t4.MapAlpha, Zr = (t4.VP8LPredictorsAdd = []) ;(Zr.length = 16), ((t4.VP8LPredictors = []).length = 16), ((t4.VP8LPredictorsAdd_C = []).length = 16), ((t4.VP8LPredictors_C = []).length = 16) var $r, Qr, tn, en2, rn, nn, an, on2, sn, cn, un, hn, ln2, fn2, dn, pn, gn, mn2, vn, bn2, yn, wn, Nn, Ln, An, xn, Sn, _n, Pn = a2(511), kn = a2(2041), In = a2(225), Fn = a2(767), Cn = 0, jn = kn, On = In, Bn = Fn, Mn = Pn, En = 0, qn = 1, Dn = 2, Rn = 3, Tn = 4, Un = 5, zn = 6, Hn = 7, Wn = 8, Vn = 9, Gn = 10, Yn = [2, 3, 7], Jn = [3, 3, 11], Xn = [280, 256, 256, 256, 40], Kn = [0, 1, 1, 1, 0], Zn = [17, 18, 0, 1, 2, 3, 4, 5, 16, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15], $n = [ 24, 7, 23, 25, 40, 6, 39, 41, 22, 26, 38, 42, 56, 5, 55, 57, 21, 27, 54, 58, 37, 43, 72, 4, 71, 73, 20, 28, 53, 59, 70, 74, 36, 44, 88, 69, 75, 52, 60, 3, 87, 89, 19, 29, 86, 90, 35, 45, 68, 76, 85, 91, 51, 61, 104, 2, 103, 105, 18, 30, 102, 106, 34, 46, 84, 92, 67, 77, 101, 107, 50, 62, 120, 1, 119, 121, 83, 93, 17, 31, 100, 108, 66, 78, 118, 122, 33, 47, 117, 123, 49, 63, 99, 109, 82, 94, 0, 116, 124, 65, 79, 16, 32, 98, 110, 48, 115, 125, 81, 95, 64, 114, 126, 97, 111, 80, 113, 127, 96, 112, ], Qn = [ 2954, 2956, 2958, 2962, 2970, 2986, 3018, 3082, 3212, 3468, 3980, 5004, ], ti = 8, ei = [ 4, 5, 6, 7, 8, 9, 10, 10, 11, 12, 13, 14, 15, 16, 17, 17, 18, 19, 20, 20, 21, 21, 22, 22, 23, 23, 24, 25, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 91, 93, 95, 96, 98, 100, 101, 102, 104, 106, 108, 110, 112, 114, 116, 118, 122, 124, 126, 128, 130, 132, 134, 136, 138, 140, 143, 145, 148, 151, 154, 157, ], ri = [ 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 60, 62, 64, 66, 68, 70, 72, 74, 76, 78, 80, 82, 84, 86, 88, 90, 92, 94, 96, 98, 100, 102, 104, 106, 108, 110, 112, 114, 116, 119, 122, 125, 128, 131, 134, 137, 140, 143, 146, 149, 152, 155, 158, 161, 164, 167, 170, 173, 177, 181, 185, 189, 193, 197, 201, 205, 209, 213, 217, 221, 225, 229, 234, 239, 245, 249, 254, 259, 264, 269, 274, 279, 284, ], ni = null, ii = [ [173, 148, 140, 0], [176, 155, 140, 135, 0], [180, 157, 141, 134, 130, 0], [254, 254, 243, 230, 196, 177, 153, 140, 133, 130, 129, 0], ], ai = [0, 1, 4, 8, 5, 2, 3, 6, 9, 12, 13, 10, 7, 11, 14, 15], oi = [-0, 1, -1, 2, -2, 3, 4, 6, -3, 5, -4, -5, -6, 7, -7, 8, -8, -9], si = [ [ [ [128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128], [128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128], [128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128], ], [ [253, 136, 254, 255, 228, 219, 128, 128, 128, 128, 128], [189, 129, 242, 255, 227, 213, 255, 219, 128, 128, 128], [106, 126, 227, 252, 214, 209, 255, 255, 128, 128, 128], ], [ [1, 98, 248, 255, 236, 226, 255, 255, 128, 128, 128], [181, 133, 238, 254, 221, 234, 255, 154, 128, 128, 128], [78, 134, 202, 247, 198, 180, 255, 219, 128, 128, 128], ], [ [1, 185, 249, 255, 243, 255, 128, 128, 128, 128, 128], [184, 150, 247, 255, 236, 224, 128, 128, 128, 128, 128], [77, 110, 216, 255, 236, 230, 128, 128, 128, 128, 128], ], [ [1, 101, 251, 255, 241, 255, 128, 128, 128, 128, 128], [170, 139, 241, 252, 236, 209, 255, 255, 128, 128, 128], [37, 116, 196, 243, 228, 255, 255, 255, 128, 128, 128], ], [ [1, 204, 254, 255, 245, 255, 128, 128, 128, 128, 128], [207, 160, 250, 255, 238, 128, 128, 128, 128, 128, 128], [102, 103, 231, 255, 211, 171, 128, 128, 128, 128, 128], ], [ [1, 152, 252, 255, 240, 255, 128, 128, 128, 128, 128], [177, 135, 243, 255, 234, 225, 128, 128, 128, 128, 128], [80, 129, 211, 255, 194, 224, 128, 128, 128, 128, 128], ], [ [1, 1, 255, 128, 128, 128, 128, 128, 128, 128, 128], [246, 1, 255, 128, 128, 128, 128, 128, 128, 128, 128], [255, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128], ], ], [ [ [198, 35, 237, 223, 193, 187, 162, 160, 145, 155, 62], [131, 45, 198, 221, 172, 176, 220, 157, 252, 221, 1], [68, 47, 146, 208, 149, 167, 221, 162, 255, 223, 128], ], [ [1, 149, 241, 255, 221, 224, 255, 255, 128, 128, 128], [184, 141, 234, 253, 222, 220, 255, 199, 128, 128, 128], [81, 99, 181, 242, 176, 190, 249, 202, 255, 255, 128], ], [ [1, 129, 232, 253, 214, 197, 242, 196, 255, 255, 128], [99, 121, 210, 250, 201, 198, 255, 202, 128, 128, 128], [23, 91, 163, 242, 170, 187, 247, 210, 255, 255, 128], ], [ [1, 200, 246, 255, 234, 255, 128, 128, 128, 128, 128], [109, 178, 241, 255, 231, 245, 255, 255, 128, 128, 128], [44, 130, 201, 253, 205, 192, 255, 255, 128, 128, 128], ], [ [1, 132, 239, 251, 219, 209, 255, 165, 128, 128, 128], [94, 136, 225, 251, 218, 190, 255, 255, 128, 128, 128], [22, 100, 174, 245, 186, 161, 255, 199, 128, 128, 128], ], [ [1, 182, 249, 255, 232, 235, 128, 128, 128, 128, 128], [124, 143, 241, 255, 227, 234, 128, 128, 128, 128, 128], [35, 77, 181, 251, 193, 211, 255, 205, 128, 128, 128], ], [ [1, 157, 247, 255, 236, 231, 255, 255, 128, 128, 128], [121, 141, 235, 255, 225, 227, 255, 255, 128, 128, 128], [45, 99, 188, 251, 195, 217, 255, 224, 128, 128, 128], ], [ [1, 1, 251, 255, 213, 255, 128, 128, 128, 128, 128], [203, 1, 248, 255, 255, 128, 128, 128, 128, 128, 128], [137, 1, 177, 255, 224, 255, 128, 128, 128, 128, 128], ], ], [ [ [253, 9, 248, 251, 207, 208, 255, 192, 128, 128, 128], [175, 13, 224, 243, 193, 185, 249, 198, 255, 255, 128], [73, 17, 171, 221, 161, 179, 236, 167, 255, 234, 128], ], [ [1, 95, 247, 253, 212, 183, 255, 255, 128, 128, 128], [239, 90, 244, 250, 211, 209, 255, 255, 128, 128, 128], [155, 77, 195, 248, 188, 195, 255, 255, 128, 128, 128], ], [ [1, 24, 239, 251, 218, 219, 255, 205, 128, 128, 128], [201, 51, 219, 255, 196, 186, 128, 128, 128, 128, 128], [69, 46, 190, 239, 201, 218, 255, 228, 128, 128, 128], ], [ [1, 191, 251, 255, 255, 128, 128, 128, 128, 128, 128], [223, 165, 249, 255, 213, 255, 128, 128, 128, 128, 128], [141, 124, 248, 255, 255, 128, 128, 128, 128, 128, 128], ], [ [1, 16, 248, 255, 255, 128, 128, 128, 128, 128, 128], [190, 36, 230, 255, 236, 255, 128, 128, 128, 128, 128], [149, 1, 255, 128, 128, 128, 128, 128, 128, 128, 128], ], [ [1, 226, 255, 128, 128, 128, 128, 128, 128, 128, 128], [247, 192, 255, 128, 128, 128, 128, 128, 128, 128, 128], [240, 128, 255, 128, 128, 128, 128, 128, 128, 128, 128], ], [ [1, 134, 252, 255, 255, 128, 128, 128, 128, 128, 128], [213, 62, 250, 255, 255, 128, 128, 128, 128, 128, 128], [55, 93, 255, 128, 128, 128, 128, 128, 128, 128, 128], ], [ [128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128], [128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128], [128, 128, 128, 128, 128, 128, 128, 128, 128, 128, 128], ], ], [ [ [202, 24, 213, 235, 186, 191, 220, 160, 240, 175, 255], [126, 38, 182, 232, 169, 184, 228, 174, 255, 187, 128], [61, 46, 138, 219, 151, 178, 240, 170, 255, 216, 128], ], [ [1, 112, 230, 250, 199, 191, 247, 159, 255, 255, 128], [166, 109, 228, 252, 211, 215, 255, 174, 128, 128, 128], [39, 77, 162, 232, 172, 180, 245, 178, 255, 255, 128], ], [ [1, 52, 220, 246, 198, 199, 249, 220, 255, 255, 128], [124, 74, 191, 243, 183, 193, 250, 221, 255, 255, 128], [24, 71, 130, 219, 154, 170, 243, 182, 255, 255, 128], ], [ [1, 182, 225, 249, 219, 240, 255, 224, 128, 128, 128], [149, 150, 226, 252, 216, 205, 255, 171, 128, 128, 128], [28, 108, 170, 242, 183, 194, 254, 223, 255, 255, 128], ], [ [1, 81, 230, 252, 204, 203, 255, 192, 128, 128, 128], [123, 102, 209, 247, 188, 196, 255, 233, 128, 128, 128], [20, 95, 153, 243, 164, 173, 255, 203, 128, 128, 128], ], [ [1, 222, 248, 255, 216, 213, 128, 128, 128, 128, 128], [168, 175, 246, 252, 235, 205, 255, 255, 128, 128, 128], [47, 116, 215, 255, 211, 212, 255, 255, 128, 128, 128], ], [ [1, 121, 236, 253, 212, 214, 255, 255, 128, 128, 128], [141, 84, 213, 252, 201, 202, 255, 219, 128, 128, 128], [42, 80, 160, 240, 162, 185, 255, 205, 128, 128, 128], ], [ [1, 1, 255, 128, 128, 128, 128, 128, 128, 128, 128], [244, 1, 255, 128, 128, 128, 128, 128, 128, 128, 128], [238, 1, 255, 128, 128, 128, 128, 128, 128, 128, 128], ], ], ], ci = [ [ [231, 120, 48, 89, 115, 113, 120, 152, 112], [152, 179, 64, 126, 170, 118, 46, 70, 95], [175, 69, 143, 80, 85, 82, 72, 155, 103], [56, 58, 10, 171, 218, 189, 17, 13, 152], [114, 26, 17, 163, 44, 195, 21, 10, 173], [121, 24, 80, 195, 26, 62, 44, 64, 85], [144, 71, 10, 38, 171, 213, 144, 34, 26], [170, 46, 55, 19, 136, 160, 33, 206, 71], [63, 20, 8, 114, 114, 208, 12, 9, 226], [81, 40, 11, 96, 182, 84, 29, 16, 36], ], [ [134, 183, 89, 137, 98, 101, 106, 165, 148], [72, 187, 100, 130, 157, 111, 32, 75, 80], [66, 102, 167, 99, 74, 62, 40, 234, 128], [41, 53, 9, 178, 241, 141, 26, 8, 107], [74, 43, 26, 146, 73, 166, 49, 23, 157], [65, 38, 105, 160, 51, 52, 31, 115, 128], [104, 79, 12, 27, 217, 255, 87, 17, 7], [87, 68, 71, 44, 114, 51, 15, 186, 23], [47, 41, 14, 110, 182, 183, 21, 17, 194], [66, 45, 25, 102, 197, 189, 23, 18, 22], ], [ [88, 88, 147, 150, 42, 46, 45, 196, 205], [43, 97, 183, 117, 85, 38, 35, 179, 61], [39, 53, 200, 87, 26, 21, 43, 232, 171], [56, 34, 51, 104, 114, 102, 29, 93, 77], [39, 28, 85, 171, 58, 165, 90, 98, 64], [34, 22, 116, 206, 23, 34, 43, 166, 73], [107, 54, 32, 26, 51, 1, 81, 43, 31], [68, 25, 106, 22, 64, 171, 36, 225, 114], [34, 19, 21, 102, 132, 188, 16, 76, 124], [62, 18, 78, 95, 85, 57, 50, 48, 51], ], [ [193, 101, 35, 159, 215, 111, 89, 46, 111], [60, 148, 31, 172, 219, 228, 21, 18, 111], [112, 113, 77, 85, 179, 255, 38, 120, 114], [40, 42, 1, 196, 245, 209, 10, 25, 109], [88, 43, 29, 140, 166, 213, 37, 43, 154], [61, 63, 30, 155, 67, 45, 68, 1, 209], [100, 80, 8, 43, 154, 1, 51, 26, 71], [142, 78, 78, 16, 255, 128, 34, 197, 171], [41, 40, 5, 102, 211, 183, 4, 1, 221], [51, 50, 17, 168, 209, 192, 23, 25, 82], ], [ [138, 31, 36, 171, 27, 166, 38, 44, 229], [67, 87, 58, 169, 82, 115, 26, 59, 179], [63, 59, 90, 180, 59, 166, 93, 73, 154], [40, 40, 21, 116, 143, 209, 34, 39, 175], [47, 15, 16, 183, 34, 223, 49, 45, 183], [46, 17, 33, 183, 6, 98, 15, 32, 183], [57, 46, 22, 24, 128, 1, 54, 17, 37], [65, 32, 73, 115, 28, 128, 23, 128, 205], [40, 3, 9, 115, 51, 192, 18, 6, 223], [87, 37, 9, 115, 59, 77, 64, 21, 47], ], [ [104, 55, 44, 218, 9, 54, 53, 130, 226], [64, 90, 70, 205, 40, 41, 23, 26, 57], [54, 57, 112, 184, 5, 41, 38, 166, 213], [30, 34, 26, 133, 152, 116, 10, 32, 134], [39, 19, 53, 221, 26, 114, 32, 73, 255], [31, 9, 65, 234, 2, 15, 1, 118, 73], [75, 32, 12, 51, 192, 255, 160, 43, 51], [88, 31, 35, 67, 102, 85, 55, 186, 85], [56, 21, 23, 111, 59, 205, 45, 37, 192], [55, 38, 70, 124, 73, 102, 1, 34, 98], ], [ [125, 98, 42, 88, 104, 85, 117, 175, 82], [95, 84, 53, 89, 128, 100, 113, 101, 45], [75, 79, 123, 47, 51, 128, 81, 171, 1], [57, 17, 5, 71, 102, 57, 53, 41, 49], [38, 33, 13, 121, 57, 73, 26, 1, 85], [41, 10, 67, 138, 77, 110, 90, 47, 114], [115, 21, 2, 10, 102, 255, 166, 23, 6], [101, 29, 16, 10, 85, 128, 101, 196, 26], [57, 18, 10, 102, 102, 213, 34, 20, 43], [117, 20, 15, 36, 163, 128, 68, 1, 26], ], [ [102, 61, 71, 37, 34, 53, 31, 243, 192], [69, 60, 71, 38, 73, 119, 28, 222, 37], [68, 45, 128, 34, 1, 47, 11, 245, 171], [62, 17, 19, 70, 146, 85, 55, 62, 70], [37, 43, 37, 154, 100, 163, 85, 160, 1], [63, 9, 92, 136, 28, 64, 32, 201, 85], [75, 15, 9, 9, 64, 255, 184, 119, 16], [86, 6, 28, 5, 64, 255, 25, 248, 1], [56, 8, 17, 132, 137, 255, 55, 116, 128], [58, 15, 20, 82, 135, 57, 26, 121, 40], ], [ [164, 50, 31, 137, 154, 133, 25, 35, 218], [51, 103, 44, 131, 131, 123, 31, 6, 158], [86, 40, 64, 135, 148, 224, 45, 183, 128], [22, 26, 17, 131, 240, 154, 14, 1, 209], [45, 16, 21, 91, 64, 222, 7, 1, 197], [56, 21, 39, 155, 60, 138, 23, 102, 213], [83, 12, 13, 54, 192, 255, 68, 47, 28], [85, 26, 85, 85, 128, 128, 32, 146, 171], [18, 11, 7, 63, 144, 171, 4, 4, 246], [35, 27, 10, 146, 174, 171, 12, 26, 128], ], [ [190, 80, 35, 99, 180, 80, 126, 54, 45], [85, 126, 47, 87, 176, 51, 41, 20, 32], [101, 75, 128, 139, 118, 146, 116, 128, 85], [56, 41, 15, 176, 236, 85, 37, 9, 62], [71, 30, 17, 119, 118, 255, 17, 18, 138], [101, 38, 60, 138, 55, 70, 43, 26, 142], [146, 36, 19, 30, 171, 255, 97, 27, 20], [138, 45, 61, 62, 219, 1, 81, 188, 64], [32, 41, 20, 117, 151, 142, 20, 21, 163], [112, 19, 12, 61, 195, 128, 48, 4, 24], ], ], ui = [ [ [ [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], ], [ [176, 246, 255, 255, 255, 255, 255, 255, 255, 255, 255], [223, 241, 252, 255, 255, 255, 255, 255, 255, 255, 255], [249, 253, 253, 255, 255, 255, 255, 255, 255, 255, 255], ], [ [255, 244, 252, 255, 255, 255, 255, 255, 255, 255, 255], [234, 254, 254, 255, 255, 255, 255, 255, 255, 255, 255], [253, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], ], [ [255, 246, 254, 255, 255, 255, 255, 255, 255, 255, 255], [239, 253, 254, 255, 255, 255, 255, 255, 255, 255, 255], [254, 255, 254, 255, 255, 255, 255, 255, 255, 255, 255], ], [ [255, 248, 254, 255, 255, 255, 255, 255, 255, 255, 255], [251, 255, 254, 255, 255, 255, 255, 255, 255, 255, 255], [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], ], [ [255, 253, 254, 255, 255, 255, 255, 255, 255, 255, 255], [251, 254, 254, 255, 255, 255, 255, 255, 255, 255, 255], [254, 255, 254, 255, 255, 255, 255, 255, 255, 255, 255], ], [ [255, 254, 253, 255, 254, 255, 255, 255, 255, 255, 255], [250, 255, 254, 255, 254, 255, 255, 255, 255, 255, 255], [254, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], ], [ [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], ], ], [ [ [217, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], [225, 252, 241, 253, 255, 255, 254, 255, 255, 255, 255], [234, 250, 241, 250, 253, 255, 253, 254, 255, 255, 255], ], [ [255, 254, 255, 255, 255, 255, 255, 255, 255, 255, 255], [223, 254, 254, 255, 255, 255, 255, 255, 255, 255, 255], [238, 253, 254, 254, 255, 255, 255, 255, 255, 255, 255], ], [ [255, 248, 254, 255, 255, 255, 255, 255, 255, 255, 255], [249, 254, 255, 255, 255, 255, 255, 255, 255, 255, 255], [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], ], [ [255, 253, 255, 255, 255, 255, 255, 255, 255, 255, 255], [247, 254, 255, 255, 255, 255, 255, 255, 255, 255, 255], [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], ], [ [255, 253, 254, 255, 255, 255, 255, 255, 255, 255, 255], [252, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], ], [ [255, 254, 254, 255, 255, 255, 255, 255, 255, 255, 255], [253, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], ], [ [255, 254, 253, 255, 255, 255, 255, 255, 255, 255, 255], [250, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], [254, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], ], [ [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], ], ], [ [ [186, 251, 250, 255, 255, 255, 255, 255, 255, 255, 255], [234, 251, 244, 254, 255, 255, 255, 255, 255, 255, 255], [251, 251, 243, 253, 254, 255, 254, 255, 255, 255, 255], ], [ [255, 253, 254, 255, 255, 255, 255, 255, 255, 255, 255], [236, 253, 254, 255, 255, 255, 255, 255, 255, 255, 255], [251, 253, 253, 254, 254, 255, 255, 255, 255, 255, 255], ], [ [255, 254, 254, 255, 255, 255, 255, 255, 255, 255, 255], [254, 254, 254, 255, 255, 255, 255, 255, 255, 255, 255], [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], ], [ [255, 254, 255, 255, 255, 255, 255, 255, 255, 255, 255], [254, 254, 255, 255, 255, 255, 255, 255, 255, 255, 255], [254, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], ], [ [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], [254, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], ], [ [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], ], [ [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], ], [ [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], ], ], [ [ [248, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], [250, 254, 252, 254, 255, 255, 255, 255, 255, 255, 255], [248, 254, 249, 253, 255, 255, 255, 255, 255, 255, 255], ], [ [255, 253, 253, 255, 255, 255, 255, 255, 255, 255, 255], [246, 253, 253, 255, 255, 255, 255, 255, 255, 255, 255], [252, 254, 251, 254, 254, 255, 255, 255, 255, 255, 255], ], [ [255, 254, 252, 255, 255, 255, 255, 255, 255, 255, 255], [248, 254, 253, 255, 255, 255, 255, 255, 255, 255, 255], [253, 255, 254, 254, 255, 255, 255, 255, 255, 255, 255], ], [ [255, 251, 254, 255, 255, 255, 255, 255, 255, 255, 255], [245, 251, 254, 255, 255, 255, 255, 255, 255, 255, 255], [253, 253, 254, 255, 255, 255, 255, 255, 255, 255, 255], ], [ [255, 251, 253, 255, 255, 255, 255, 255, 255, 255, 255], [252, 253, 254, 255, 255, 255, 255, 255, 255, 255, 255], [255, 254, 255, 255, 255, 255, 255, 255, 255, 255, 255], ], [ [255, 252, 255, 255, 255, 255, 255, 255, 255, 255, 255], [249, 255, 254, 255, 255, 255, 255, 255, 255, 255, 255], [255, 255, 254, 255, 255, 255, 255, 255, 255, 255, 255], ], [ [255, 255, 253, 255, 255, 255, 255, 255, 255, 255, 255], [250, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], ], [ [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], [254, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], [255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255], ], ], ], hi = [0, 1, 2, 3, 6, 4, 5, 6, 6, 6, 6, 6, 6, 6, 6, 7, 0], li = [], fi2 = [], di = [], pi = 1, gi = 2, mi = [], vi2 = [] vr('UpsampleRgbLinePair', Ar, 3), vr('UpsampleBgrLinePair', xr, 3), vr('UpsampleRgbaLinePair', Ir, 4), vr('UpsampleBgraLinePair', kr, 4), vr('UpsampleArgbLinePair', Pr, 4), vr('UpsampleRgba4444LinePair', _r, 2), vr('UpsampleRgb565LinePair', Sr, 2) var bi = t4.UpsampleRgbLinePair, yi = t4.UpsampleBgrLinePair, wi = t4.UpsampleRgbaLinePair, Ni = t4.UpsampleBgraLinePair, Li = t4.UpsampleArgbLinePair, Ai = t4.UpsampleRgba4444LinePair, xi = t4.UpsampleRgb565LinePair, Si = 16, _i = 1 << (Si - 1), Pi = -227, ki = 482, Ii = 6, Fi = (256 << Ii) - 1, Ci = 0, ji = a2(256), Oi = a2(256), Bi = a2(256), Mi = a2(256), Ei = a2(ki - Pi), qi = a2(ki - Pi) Fr('YuvToRgbRow', Ar, 3), Fr('YuvToBgrRow', xr, 3), Fr('YuvToRgbaRow', Ir, 4), Fr('YuvToBgraRow', kr, 4), Fr('YuvToArgbRow', Pr, 4), Fr('YuvToRgba4444Row', _r, 2), Fr('YuvToRgb565Row', Sr, 2) var Di = [ 0, 4, 8, 12, 128, 132, 136, 140, 256, 260, 264, 268, 384, 388, 392, 396, ], Ri = [0, 2, 8], Ti = [8, 7, 6, 4, 4, 2, 2, 2, 1, 1, 1, 1], Ui = 1 this.WebPDecodeRGBA = function (t5, r3, n3, i3, a3) { var o3 = qn, s3 = new rr2(), c4 = new ot2() ;(s3.ba = c4), (c4.S = o3), (c4.width = [c4.width]), (c4.height = [c4.height]) var u4 = c4.width, h4 = c4.height, l4 = new st2() if (null == l4 || null == t5) var f4 = 2 else e2(null != l4), (f4 = Br( t5, r3, n3, l4.width, l4.height, l4.Pd, l4.Qd, l4.format, null )) if ( (0 != f4 ? (u4 = 0) : (null != u4 && (u4[0] = l4.width[0]), null != h4 && (h4[0] = l4.height[0]), (u4 = 1)), u4) ) { ;(c4.width = c4.width[0]), (c4.height = c4.height[0]), null != i3 && (i3[0] = c4.width), null != a3 && (a3[0] = c4.height) t: { if ( ((i3 = new Gt2()), ((a3 = new nr()).data = t5), (a3.w = r3), (a3.ha = n3), (a3.kd = 1), (r3 = [0]), e2(null != a3), (0 == (t5 = Br(a3.data, a3.w, a3.ha, null, null, null, r3, null, a3)) || 7 == t5) && r3[0] && (t5 = 4), 0 == (r3 = t5)) ) { if ( (e2(null != s3), (i3.data = a3.data), (i3.w = a3.w + a3.offset), (i3.ha = a3.ha - a3.offset), (i3.put = dt2), (i3.ac = ft2), (i3.bc = pt3), (i3.ma = s3), a3.xa) ) { if (null == (t5 = kt2())) { s3 = 1 break t } if ( (function (t6, r4) { var n4 = [0], i4 = [0], a4 = [0] e: for (;;) { if (null == t6) return 0 if (null == r4) return (t6.a = 2), 0 if ( ((t6.l = r4), (t6.a = 0), v5(t6.m, r4.data, r4.w, r4.ha), !gt2(t6.m, n4, i4, a4)) ) { t6.a = 3 break e } if ( ((t6.xb = gi), (r4.width = n4[0]), (r4.height = i4[0]), !It2(n4[0], i4[0], 1, t6, null)) ) break e return 1 } return e2(0 != t6.a), 0 })(t5, i3) ) { if ((i3 = 0 == (r3 = qr(i3.width, i3.height, s3.Oa, s3.ba)))) { e: { i3 = t5 r: for (;;) { if (null == i3) { i3 = 0 break e } if ( (e2(null != i3.s.yc), e2(null != i3.s.Ya), e2(0 < i3.s.Wb), e2(null != (n3 = i3.l)), e2(null != (a3 = n3.ma)), 0 != i3.xb) ) { if ( ((i3.ca = a3.ba), (i3.tb = a3.tb), e2(null != i3.ca), !Mr(a3.Oa, n3, Rn)) ) { i3.a = 2 break r } if (!Ft2(i3, n3.width)) break r if (n3.da) break r if ( ((n3.da || nt2(i3.ca.S)) && mr(), 11 > i3.ca.S || (alert('todo:WebPInitConvertARGBToYUV'), null != i3.ca.f.kb.F && mr()), i3.Pb && 0 < i3.s.ua && null == i3.s.vb.X && !O2(i3.s.vb, i3.s.Wa.Xa)) ) { i3.a = 1 break r } i3.xb = 0 } if (!_t2(i3, i3.V, i3.Ba, i3.c, i3.i, n3.o, Lt2)) break r ;(a3.Dc = i3.Ma), (i3 = 1) break e } e2(0 != i3.a), (i3 = 0) } i3 = !i3 } i3 && (r3 = t5.a) } else r3 = t5.a } else { if (null == (t5 = new Yt2())) { s3 = 1 break t } if ( ((t5.Fa = a3.na), (t5.P = a3.P), (t5.qc = a3.Sa), Kt2(t5, i3)) ) { if (0 == (r3 = qr(i3.width, i3.height, s3.Oa, s3.ba))) { if ( ((t5.Aa = 0), (n3 = s3.Oa), e2(null != (a3 = t5)), null != n3) ) { if ( 0 < (u4 = 0 > (u4 = n3.Md) ? 0 : 100 < u4 ? 255 : (255 * u4) / 100) ) { for (h4 = l4 = 0; 4 > h4; ++h4) 12 > (f4 = a3.pb[h4]).lc && (f4.ia = (u4 * Ti[0 > f4.lc ? 0 : f4.lc]) >> 3), (l4 |= f4.ia) l4 && (alert('todo:VP8InitRandom'), (a3.ia = 1)) } ;(a3.Ga = n3.Id), 100 < a3.Ga ? (a3.Ga = 100) : 0 > a3.Ga && (a3.Ga = 0) } Qt2(t5, i3) || (r3 = t5.a) } } else r3 = t5.a } 0 == r3 && null != s3.Oa && s3.Oa.fd && (r3 = Er(s3.ba)) } s3 = r3 } o3 = 0 != s3 ? null : 11 > o3 ? c4.f.RGBA.eb : c4.f.kb.y } else o3 = null return o3 } var zi = [3, 4, 3, 4, 4, 2, 2, 4, 4, 4, 2, 1, 1] } function u2(t4, e3) { for (var r3 = '', n3 = 0; n3 < 4; n3++) r3 += String.fromCharCode(t4[e3++]) return r3 } function h2(t4, e3) { return ((t4[e3 + 0] << 0) | (t4[e3 + 1] << 8) | (t4[e3 + 2] << 16)) >>> 0 } function l2(t4, e3) { return ( ((t4[e3 + 0] << 0) | (t4[e3 + 1] << 8) | (t4[e3 + 2] << 16) | (t4[e3 + 3] << 24)) >>> 0 ) } new c2() var f2 = [0], d3 = [0], p2 = [], g2 = new c2(), m2 = t3, v4 = (function (t4, e3) { var r3 = {}, n3 = 0, i3 = false, a3 = 0, o3 = 0 if ( ((r3.frames = []), !(function (t5, e4, r4, n4) { for (var i4 = 0; i4 < n4; i4++) if (t5[e4 + i4] != r4.charCodeAt(i4)) return true return false })(t4, e3, 'RIFF', 4)) ) { var s3, c3 l2(t4, (e3 += 4)) for (e3 += 8; e3 < t4.length; ) { var f3 = u2(t4, e3), d4 = l2(t4, (e3 += 4)) e3 += 4 var p3 = d4 + (1 & d4) switch (f3) { case 'VP8 ': case 'VP8L': void 0 === r3.frames[n3] && (r3.frames[n3] = {}) ;((v5 = r3.frames[n3]).src_off = i3 ? o3 : e3 - 8), (v5.src_size = a3 + d4 + 8), n3++, i3 && ((i3 = false), (a3 = 0), (o3 = 0)) break case 'VP8X': ;(v5 = r3.header = {}).feature_flags = t4[e3] var g3 = e3 + 4 v5.canvas_width = 1 + h2(t4, g3) g3 += 3 v5.canvas_height = 1 + h2(t4, g3) g3 += 3 break case 'ALPH': ;(i3 = true), (a3 = p3 + 8), (o3 = e3 - 8) break case 'ANIM': ;(v5 = r3.header).bgcolor = l2(t4, e3) g3 = e3 + 4 v5.loop_count = ((s3 = t4)[(c3 = g3) + 0] << 0) | (s3[c3 + 1] << 8) g3 += 2 break case 'ANMF': var m3, v5 ;((v5 = r3.frames[n3] = {}).offset_x = 2 * h2(t4, e3)), (e3 += 3), (v5.offset_y = 2 * h2(t4, e3)), (e3 += 3), (v5.width = 1 + h2(t4, e3)), (e3 += 3), (v5.height = 1 + h2(t4, e3)), (e3 += 3), (v5.duration = h2(t4, e3)), (e3 += 3), (m3 = t4[e3++]), (v5.dispose = 1 & m3), (v5.blend = (m3 >> 1) & 1) } 'ANMF' != f3 && (e3 += p3) } return r3 } })(m2, 0) ;(v4.response = m2), (v4.rgbaoutput = true), (v4.dataurl = false) var b2 = v4.header ? v4.header : null, y2 = v4.frames ? v4.frames : null if (b2) { ;(b2.loop_counter = b2.loop_count), (f2 = [b2.canvas_height]), (d3 = [b2.canvas_width]) for (var w2 = 0; w2 < y2.length && 0 != y2[w2].blend; w2++); } var N2 = y2[0], L2 = g2.WebPDecodeRGBA(m2, N2.src_off, N2.src_size, d3, f2) ;(N2.rgba = L2), (N2.imgwidth = d3[0]), (N2.imgheight = f2[0]) for (var A2 = 0; A2 < d3[0] * f2[0] * 4; A2++) p2[A2] = L2[A2] return (this.width = d3), (this.height = f2), (this.data = p2), this } !(function (t3) { var r2 = function () { return 'function' == typeof zlibSync }, n2 = function (r3, n3, a3, h3) { var l3 = 4, f3 = s2 switch (h3) { case t3.image_compression.FAST: ;(l3 = 1), (f3 = o2) break case t3.image_compression.MEDIUM: ;(l3 = 6), (f3 = c2) break case t3.image_compression.SLOW: ;(l3 = 9), (f3 = u2) } r3 = i2(r3, n3, a3, f3) var d3 = zlibSync(r3, { level: l3 }) return t3.__addimage__.arrayBufferToBinaryString(d3) }, i2 = function (t4, e2, r3, n3) { for ( var i3, a3, o3, s3 = t4.length / e2, c3 = new Uint8Array(t4.length + s3), u3 = l2(), h3 = 0; h3 < s3; h3 += 1 ) { if (((o3 = h3 * e2), (i3 = t4.subarray(o3, o3 + e2)), n3)) c3.set(n3(i3, r3, a3), o3 + h3) else { for (var d3, p2 = u3.length, g2 = []; d3 < p2; d3 += 1) g2[d3] = u3[d3](i3, r3, a3) var m2 = f2(g2.concat()) c3.set(g2[m2], o3 + h3) } a3 = i3 } return c3 }, a2 = function (t4) { var e2 = Array.apply([], t4) return e2.unshift(0), e2 }, o2 = function (t4, e2) { var r3, n3 = [], i3 = t4.length n3[0] = 1 for (var a3 = 0; a3 < i3; a3 += 1) (r3 = t4[a3 - e2] || 0), (n3[a3 + 1] = (t4[a3] - r3 + 256) & 255) return n3 }, s2 = function (t4, e2, r3) { var n3, i3 = [], a3 = t4.length i3[0] = 2 for (var o3 = 0; o3 < a3; o3 += 1) (n3 = (r3 && r3[o3]) || 0), (i3[o3 + 1] = (t4[o3] - n3 + 256) & 255) return i3 }, c2 = function (t4, e2, r3) { var n3, i3, a3 = [], o3 = t4.length a3[0] = 3 for (var s3 = 0; s3 < o3; s3 += 1) (n3 = t4[s3 - e2] || 0), (i3 = (r3 && r3[s3]) || 0), (a3[s3 + 1] = (t4[s3] + 256 - ((n3 + i3) >>> 1)) & 255) return a3 }, u2 = function (t4, e2, r3) { var n3, i3, a3, o3, s3 = [], c3 = t4.length s3[0] = 4 for (var u3 = 0; u3 < c3; u3 += 1) (n3 = t4[u3 - e2] || 0), (i3 = (r3 && r3[u3]) || 0), (a3 = (r3 && r3[u3 - e2]) || 0), (o3 = h2(n3, i3, a3)), (s3[u3 + 1] = (t4[u3] - o3 + 256) & 255) return s3 }, h2 = function (t4, e2, r3) { if (t4 === e2 && e2 === r3) return t4 var n3 = Math.abs(e2 - r3), i3 = Math.abs(t4 - r3), a3 = Math.abs(t4 + e2 - r3 - r3) return n3 <= i3 && n3 <= a3 ? t4 : i3 <= a3 ? e2 : r3 }, l2 = function () { return [a2, o2, s2, c2, u2] }, f2 = function (t4) { var e2 = t4.map(function (t5) { return t5.reduce(function (t6, e3) { return t6 + Math.abs(e3) }, 0) }) return e2.indexOf(Math.min.apply(null, e2)) } t3.processPNG = function (e2, i3, a3, o3) { var s3, c3, u3, h3, l3, f3, d3, p2, g2, m2, v4, b2, y2, w2, N2, L2 = this.decode.FLATE_DECODE, A2 = '' if ( (this.__addimage__.isArrayBuffer(e2) && (e2 = new Uint8Array(e2)), this.__addimage__.isArrayBufferView(e2)) ) { if ( ((e2 = (u3 = new Kt(e2)).imgData), (c3 = u3.bits), (s3 = u3.colorSpace), (l3 = u3.colors), -1 !== [4, 6].indexOf(u3.colorType)) ) { if (8 === u3.bits) { ;(g2 = (p2 = 32 == u3.pixelBitlength ? new Uint32Array(u3.decodePixels().buffer) : 16 == u3.pixelBitlength ? new Uint16Array(u3.decodePixels().buffer) : new Uint8Array(u3.decodePixels().buffer)).length), (v4 = new Uint8Array(g2 * u3.colors)), (m2 = new Uint8Array(g2)) var x2, S2 = u3.pixelBitlength - u3.bits for (w2 = 0, N2 = 0; w2 < g2; w2++) { for (y2 = p2[w2], x2 = 0; x2 < S2; ) (v4[N2++] = (y2 >>> x2) & 255), (x2 += u3.bits) m2[w2] = (y2 >>> x2) & 255 } } if (16 === u3.bits) { ;(g2 = (p2 = new Uint32Array(u3.decodePixels().buffer)).length), (v4 = new Uint8Array(g2 * (32 / u3.pixelBitlength) * u3.colors)), (m2 = new Uint8Array(g2 * (32 / u3.pixelBitlength))), (b2 = u3.colors > 1), (w2 = 0), (N2 = 0) for (var _2 = 0; w2 < g2; ) (y2 = p2[w2++]), (v4[N2++] = (y2 >>> 0) & 255), b2 && ((v4[N2++] = (y2 >>> 16) & 255), (y2 = p2[w2++]), (v4[N2++] = (y2 >>> 0) & 255)), (m2[_2++] = (y2 >>> 16) & 255) c3 = 8 } o3 !== t3.image_compression.NONE && r2() ? ((e2 = n2(v4, u3.width * u3.colors, u3.colors, o3)), (d3 = n2(m2, u3.width, 1, o3))) : ((e2 = v4), (d3 = m2), (L2 = void 0)) } if ( 3 === u3.colorType && ((s3 = this.color_spaces.INDEXED), (f3 = u3.palette), u3.transparency.indexed) ) { var P2 = u3.transparency.indexed, k2 = 0 for (w2 = 0, g2 = P2.length; w2 < g2; ++w2) k2 += P2[w2] if ((k2 /= 255) === g2 - 1 && -1 !== P2.indexOf(0)) h3 = [P2.indexOf(0)] else if (k2 !== g2) { for ( p2 = u3.decodePixels(), m2 = new Uint8Array(p2.length), w2 = 0, g2 = p2.length; w2 < g2; w2++ ) m2[w2] = P2[p2[w2]] d3 = n2(m2, u3.width, 1) } } var I2 = (function (e3) { var r3 switch (e3) { case t3.image_compression.FAST: r3 = 11 break case t3.image_compression.MEDIUM: r3 = 13 break case t3.image_compression.SLOW: r3 = 14 break default: r3 = 12 } return r3 })(o3) return ( L2 === this.decode.FLATE_DECODE && (A2 = '/Predictor ' + I2 + ' '), (A2 += '/Colors ' + l3 + ' /BitsPerComponent ' + c3 + ' /Columns ' + u3.width), (this.__addimage__.isArrayBuffer(e2) || this.__addimage__.isArrayBufferView(e2)) && (e2 = this.__addimage__.arrayBufferToBinaryString(e2)), ((d3 && this.__addimage__.isArrayBuffer(d3)) || this.__addimage__.isArrayBufferView(d3)) && (d3 = this.__addimage__.arrayBufferToBinaryString(d3)), { alias: a3, data: e2, index: i3, filter: L2, decodeParameters: A2, transparency: h3, palette: f3, sMask: d3, predictor: I2, width: u3.width, height: u3.height, bitsPerComponent: c3, colorSpace: s3, } ) } } })(E$1.API), (function (t3) { ;(t3.processGIF89A = function (e2, r2, n2, i2) { var a2 = new Zt(e2), o2 = a2.width, s2 = a2.height, c2 = [] a2.decodeAndBlitFrameRGBA(0, c2) var u2 = { data: c2, width: o2, height: s2 }, h2 = new Qt(100).encode(u2, 100) return t3.processJPEG.call(this, h2, r2, n2, i2) }), (t3.processGIF87A = t3.processGIF89A) })(E$1.API), (te.prototype.parseHeader = function () { if ( ((this.fileSize = this.datav.getUint32(this.pos, true)), (this.pos += 4), (this.reserved = this.datav.getUint32(this.pos, true)), (this.pos += 4), (this.offset = this.datav.getUint32(this.pos, true)), (this.pos += 4), (this.headerSize = this.datav.getUint32(this.pos, true)), (this.pos += 4), (this.width = this.datav.getUint32(this.pos, true)), (this.pos += 4), (this.height = this.datav.getInt32(this.pos, true)), (this.pos += 4), (this.planes = this.datav.getUint16(this.pos, true)), (this.pos += 2), (this.bitPP = this.datav.getUint16(this.pos, true)), (this.pos += 2), (this.compress = this.datav.getUint32(this.pos, true)), (this.pos += 4), (this.rawSize = this.datav.getUint32(this.pos, true)), (this.pos += 4), (this.hr = this.datav.getUint32(this.pos, true)), (this.pos += 4), (this.vr = this.datav.getUint32(this.pos, true)), (this.pos += 4), (this.colors = this.datav.getUint32(this.pos, true)), (this.pos += 4), (this.importantColors = this.datav.getUint32(this.pos, true)), (this.pos += 4), 16 === this.bitPP && this.is_with_alpha && (this.bitPP = 15), this.bitPP < 15) ) { var t3 = 0 === this.colors ? 1 << this.bitPP : this.colors this.palette = new Array(t3) for (var e2 = 0; e2 < t3; e2++) { var r2 = this.datav.getUint8(this.pos++, true), n2 = this.datav.getUint8(this.pos++, true), i2 = this.datav.getUint8(this.pos++, true), a2 = this.datav.getUint8(this.pos++, true) this.palette[e2] = { red: i2, green: n2, blue: r2, quad: a2 } } } this.height < 0 && ((this.height *= -1), (this.bottom_up = false)) }), (te.prototype.parseBGR = function () { this.pos = this.offset try { var t3 = 'bit' + this.bitPP, e2 = this.width * this.height * 4 ;(this.data = new Uint8Array(e2)), this[t3]() } catch (t4) { a$2.log('bit decode error:' + t4) } }), (te.prototype.bit1 = function () { var t3, e2 = Math.ceil(this.width / 8), r2 = e2 % 4 for (t3 = this.height - 1; t3 >= 0; t3--) { for ( var n2 = this.bottom_up ? t3 : this.height - 1 - t3, i2 = 0; i2 < e2; i2++ ) for ( var a2 = this.datav.getUint8(this.pos++, true), o2 = n2 * this.width * 4 + 8 * i2 * 4, s2 = 0; s2 < 8 && 8 * i2 + s2 < this.width; s2++ ) { var c2 = this.palette[(a2 >> (7 - s2)) & 1] ;(this.data[o2 + 4 * s2] = c2.blue), (this.data[o2 + 4 * s2 + 1] = c2.green), (this.data[o2 + 4 * s2 + 2] = c2.red), (this.data[o2 + 4 * s2 + 3] = 255) } 0 !== r2 && (this.pos += 4 - r2) } }), (te.prototype.bit4 = function () { for ( var t3 = Math.ceil(this.width / 2), e2 = t3 % 4, r2 = this.height - 1; r2 >= 0; r2-- ) { for ( var n2 = this.bottom_up ? r2 : this.height - 1 - r2, i2 = 0; i2 < t3; i2++ ) { var a2 = this.datav.getUint8(this.pos++, true), o2 = n2 * this.width * 4 + 2 * i2 * 4, s2 = a2 >> 4, c2 = 15 & a2, u2 = this.palette[s2] if ( ((this.data[o2] = u2.blue), (this.data[o2 + 1] = u2.green), (this.data[o2 + 2] = u2.red), (this.data[o2 + 3] = 255), 2 * i2 + 1 >= this.width) ) break ;(u2 = this.palette[c2]), (this.data[o2 + 4] = u2.blue), (this.data[o2 + 4 + 1] = u2.green), (this.data[o2 + 4 + 2] = u2.red), (this.data[o2 + 4 + 3] = 255) } 0 !== e2 && (this.pos += 4 - e2) } }), (te.prototype.bit8 = function () { for (var t3 = this.width % 4, e2 = this.height - 1; e2 >= 0; e2--) { for ( var r2 = this.bottom_up ? e2 : this.height - 1 - e2, n2 = 0; n2 < this.width; n2++ ) { var i2 = this.datav.getUint8(this.pos++, true), a2 = r2 * this.width * 4 + 4 * n2 if (i2 < this.palette.length) { var o2 = this.palette[i2] ;(this.data[a2] = o2.red), (this.data[a2 + 1] = o2.green), (this.data[a2 + 2] = o2.blue), (this.data[a2 + 3] = 255) } else (this.data[a2] = 255), (this.data[a2 + 1] = 255), (this.data[a2 + 2] = 255), (this.data[a2 + 3] = 255) } 0 !== t3 && (this.pos += 4 - t3) } }), (te.prototype.bit15 = function () { for ( var t3 = this.width % 3, e2 = parseInt('11111', 2), r2 = this.height - 1; r2 >= 0; r2-- ) { for ( var n2 = this.bottom_up ? r2 : this.height - 1 - r2, i2 = 0; i2 < this.width; i2++ ) { var a2 = this.datav.getUint16(this.pos, true) this.pos += 2 var o2 = (((a2 & e2) / e2) * 255) | 0, s2 = ((((a2 >> 5) & e2) / e2) * 255) | 0, c2 = ((((a2 >> 10) & e2) / e2) * 255) | 0, u2 = a2 >> 15 ? 255 : 0, h2 = n2 * this.width * 4 + 4 * i2 ;(this.data[h2] = c2), (this.data[h2 + 1] = s2), (this.data[h2 + 2] = o2), (this.data[h2 + 3] = u2) } this.pos += t3 } }), (te.prototype.bit16 = function () { for ( var t3 = this.width % 3, e2 = parseInt('11111', 2), r2 = parseInt('111111', 2), n2 = this.height - 1; n2 >= 0; n2-- ) { for ( var i2 = this.bottom_up ? n2 : this.height - 1 - n2, a2 = 0; a2 < this.width; a2++ ) { var o2 = this.datav.getUint16(this.pos, true) this.pos += 2 var s2 = (((o2 & e2) / e2) * 255) | 0, c2 = ((((o2 >> 5) & r2) / r2) * 255) | 0, u2 = (((o2 >> 11) / e2) * 255) | 0, h2 = i2 * this.width * 4 + 4 * a2 ;(this.data[h2] = u2), (this.data[h2 + 1] = c2), (this.data[h2 + 2] = s2), (this.data[h2 + 3] = 255) } this.pos += t3 } }), (te.prototype.bit24 = function () { for (var t3 = this.height - 1; t3 >= 0; t3--) { for ( var e2 = this.bottom_up ? t3 : this.height - 1 - t3, r2 = 0; r2 < this.width; r2++ ) { var n2 = this.datav.getUint8(this.pos++, true), i2 = this.datav.getUint8(this.pos++, true), a2 = this.datav.getUint8(this.pos++, true), o2 = e2 * this.width * 4 + 4 * r2 ;(this.data[o2] = a2), (this.data[o2 + 1] = i2), (this.data[o2 + 2] = n2), (this.data[o2 + 3] = 255) } this.pos += this.width % 4 } }), (te.prototype.bit32 = function () { for (var t3 = this.height - 1; t3 >= 0; t3--) for ( var e2 = this.bottom_up ? t3 : this.height - 1 - t3, r2 = 0; r2 < this.width; r2++ ) { var n2 = this.datav.getUint8(this.pos++, true), i2 = this.datav.getUint8(this.pos++, true), a2 = this.datav.getUint8(this.pos++, true), o2 = this.datav.getUint8(this.pos++, true), s2 = e2 * this.width * 4 + 4 * r2 ;(this.data[s2] = a2), (this.data[s2 + 1] = i2), (this.data[s2 + 2] = n2), (this.data[s2 + 3] = o2) } }), (te.prototype.getData = function () { return this.data }), (function (t3) { t3.processBMP = function (e2, r2, n2, i2) { var a2 = new te(e2, false), o2 = a2.width, s2 = a2.height, c2 = { data: a2.getData(), width: o2, height: s2 }, u2 = new Qt(100).encode(c2, 100) return t3.processJPEG.call(this, u2, r2, n2, i2) } })(E$1.API), (ee.prototype.getData = function () { return this.data }), (function (t3) { t3.processWEBP = function (e2, r2, n2, i2) { var a2 = new ee(e2), o2 = a2.width, s2 = a2.height, c2 = { data: a2.getData(), width: o2, height: s2 }, u2 = new Qt(100).encode(c2, 100) return t3.processJPEG.call(this, u2, r2, n2, i2) } })(E$1.API), (E$1.API.processRGBA = function (t3, e2, r2) { for ( var n2 = t3.data, i2 = n2.length, a2 = new Uint8Array((i2 / 4) * 3), o2 = new Uint8Array(i2 / 4), s2 = 0, c2 = 0, u2 = 0; u2 < i2; u2 += 4 ) { var h2 = n2[u2], l2 = n2[u2 + 1], f2 = n2[u2 + 2], d3 = n2[u2 + 3] ;(a2[s2++] = h2), (a2[s2++] = l2), (a2[s2++] = f2), (o2[c2++] = d3) } var p2 = this.__addimage__.arrayBufferToBinaryString(a2) return { alpha: this.__addimage__.arrayBufferToBinaryString(o2), data: p2, index: e2, alias: r2, colorSpace: 'DeviceRGB', bitsPerComponent: 8, width: t3.width, height: t3.height, } }), (E$1.API.setLanguage = function (t3) { return ( void 0 === this.internal.languageSettings && ((this.internal.languageSettings = {}), (this.internal.languageSettings.isSubscribed = false)), void 0 !== { af: 'Afrikaans', sq: 'Albanian', ar: 'Arabic (Standard)', 'ar-DZ': 'Arabic (Algeria)', 'ar-BH': 'Arabic (Bahrain)', 'ar-EG': 'Arabic (Egypt)', 'ar-IQ': 'Arabic (Iraq)', 'ar-JO': 'Arabic (Jordan)', 'ar-KW': 'Arabic (Kuwait)', 'ar-LB': 'Arabic (Lebanon)', 'ar-LY': 'Arabic (Libya)', 'ar-MA': 'Arabic (Morocco)', 'ar-OM': 'Arabic (Oman)', 'ar-QA': 'Arabic (Qatar)', 'ar-SA': 'Arabic (Saudi Arabia)', 'ar-SY': 'Arabic (Syria)', 'ar-TN': 'Arabic (Tunisia)', 'ar-AE': 'Arabic (U.A.E.)', 'ar-YE': 'Arabic (Yemen)', an: 'Aragonese', hy: 'Armenian', as: 'Assamese', ast: 'Asturian', az: 'Azerbaijani', eu: 'Basque', be: 'Belarusian', bn: 'Bengali', bs: 'Bosnian', br: 'Breton', bg: 'Bulgarian', my: 'Burmese', ca: 'Catalan', ch: 'Chamorro', ce: 'Chechen', zh: 'Chinese', 'zh-HK': 'Chinese (Hong Kong)', 'zh-CN': 'Chinese (PRC)', 'zh-SG': 'Chinese (Singapore)', 'zh-TW': 'Chinese (Taiwan)', cv: 'Chuvash', co: 'Corsican', cr: 'Cree', hr: 'Croatian', cs: 'Czech', da: 'Danish', nl: 'Dutch (Standard)', 'nl-BE': 'Dutch (Belgian)', en: 'English', 'en-AU': 'English (Australia)', 'en-BZ': 'English (Belize)', 'en-CA': 'English (Canada)', 'en-IE': 'English (Ireland)', 'en-JM': 'English (Jamaica)', 'en-NZ': 'English (New Zealand)', 'en-PH': 'English (Philippines)', 'en-ZA': 'English (South Africa)', 'en-TT': 'English (Trinidad & Tobago)', 'en-GB': 'English (United Kingdom)', 'en-US': 'English (United States)', 'en-ZW': 'English (Zimbabwe)', eo: 'Esperanto', et: 'Estonian', fo: 'Faeroese', fj: 'Fijian', fi: 'Finnish', fr: 'French (Standard)', 'fr-BE': 'French (Belgium)', 'fr-CA': 'French (Canada)', 'fr-FR': 'French (France)', 'fr-LU': 'French (Luxembourg)', 'fr-MC': 'French (Monaco)', 'fr-CH': 'French (Switzerland)', fy: 'Frisian', fur: 'Friulian', gd: 'Gaelic (Scots)', 'gd-IE': 'Gaelic (Irish)', gl: 'Galacian', ka: 'Georgian', de: 'German (Standard)', 'de-AT': 'German (Austria)', 'de-DE': 'German (Germany)', 'de-LI': 'German (Liechtenstein)', 'de-LU': 'German (Luxembourg)', 'de-CH': 'German (Switzerland)', el: 'Greek', gu: 'Gujurati', ht: 'Haitian', he: 'Hebrew', hi: 'Hindi', hu: 'Hungarian', is: 'Icelandic', id: 'Indonesian', iu: 'Inuktitut', ga: 'Irish', it: 'Italian (Standard)', 'it-CH': 'Italian (Switzerland)', ja: 'Japanese', kn: 'Kannada', ks: 'Kashmiri', kk: 'Kazakh', km: 'Khmer', ky: 'Kirghiz', tlh: 'Klingon', ko: 'Korean', 'ko-KP': 'Korean (North Korea)', 'ko-KR': 'Korean (South Korea)', la: 'Latin', lv: 'Latvian', lt: 'Lithuanian', lb: 'Luxembourgish', mk: 'North Macedonia', ms: 'Malay', ml: 'Malayalam', mt: 'Maltese', mi: 'Maori', mr: 'Marathi', mo: 'Moldavian', nv: 'Navajo', ng: 'Ndonga', ne: 'Nepali', no: 'Norwegian', nb: 'Norwegian (Bokmal)', nn: 'Norwegian (Nynorsk)', oc: 'Occitan', or: 'Oriya', om: 'Oromo', fa: 'Persian', 'fa-IR': 'Persian/Iran', pl: 'Polish', pt: 'Portuguese', 'pt-BR': 'Portuguese (Brazil)', pa: 'Punjabi', 'pa-IN': 'Punjabi (India)', 'pa-PK': 'Punjabi (Pakistan)', qu: 'Quechua', rm: 'Rhaeto-Romanic', ro: 'Romanian', 'ro-MO': 'Romanian (Moldavia)', ru: 'Russian', 'ru-MO': 'Russian (Moldavia)', sz: 'Sami (Lappish)', sg: 'Sango', sa: 'Sanskrit', sc: 'Sardinian', sd: 'Sindhi', si: 'Singhalese', sr: 'Serbian', sk: 'Slovak', sl: 'Slovenian', so: 'Somani', sb: 'Sorbian', es: 'Spanish', 'es-AR': 'Spanish (Argentina)', 'es-BO': 'Spanish (Bolivia)', 'es-CL': 'Spanish (Chile)', 'es-CO': 'Spanish (Colombia)', 'es-CR': 'Spanish (Costa Rica)', 'es-DO': 'Spanish (Dominican Republic)', 'es-EC': 'Spanish (Ecuador)', 'es-SV': 'Spanish (El Salvador)', 'es-GT': 'Spanish (Guatemala)', 'es-HN': 'Spanish (Honduras)', 'es-MX': 'Spanish (Mexico)', 'es-NI': 'Spanish (Nicaragua)', 'es-PA': 'Spanish (Panama)', 'es-PY': 'Spanish (Paraguay)', 'es-PE': 'Spanish (Peru)', 'es-PR': 'Spanish (Puerto Rico)', 'es-ES': 'Spanish (Spain)', 'es-UY': 'Spanish (Uruguay)', 'es-VE': 'Spanish (Venezuela)', sx: 'Sutu', sw: 'Swahili', sv: 'Swedish', 'sv-FI': 'Swedish (Finland)', 'sv-SV': 'Swedish (Sweden)', ta: 'Tamil', tt: 'Tatar', te: 'Teluga', th: 'Thai', tig: 'Tigre', ts: 'Tsonga', tn: 'Tswana', tr: 'Turkish', tk: 'Turkmen', uk: 'Ukrainian', hsb: 'Upper Sorbian', ur: 'Urdu', ve: 'Venda', vi: 'Vietnamese', vo: 'Volapuk', wa: 'Walloon', cy: 'Welsh', xh: 'Xhosa', ji: 'Yiddish', zu: 'Zulu', }[t3] && ((this.internal.languageSettings.languageCode = t3), false === this.internal.languageSettings.isSubscribed && (this.internal.events.subscribe('putCatalog', function () { this.internal.write( '/Lang (' + this.internal.languageSettings.languageCode + ')' ) }), (this.internal.languageSettings.isSubscribed = true))), this ) }), (Vt = E$1.API), (Gt = Vt.getCharWidthsArray = function (e2, r2) { var n2, i2, a2 = (r2 = r2 || {}).font || this.internal.getFont(), o2 = r2.fontSize || this.internal.getFontSize(), s2 = r2.charSpace || this.internal.getCharSpace(), c2 = r2.widths ? r2.widths : a2.metadata.Unicode.widths, u2 = c2.fof ? c2.fof : 1, h2 = r2.kerning ? r2.kerning : a2.metadata.Unicode.kerning, l2 = h2.fof ? h2.fof : 1, f2 = false !== r2.doKerning, d3 = 0, p2 = e2.length, g2 = 0, m2 = c2[0] || u2, v4 = [] for (n2 = 0; n2 < p2; n2++) (i2 = e2.charCodeAt(n2)), 'function' == typeof a2.metadata.widthOfString ? v4.push( (a2.metadata.widthOfGlyph(a2.metadata.characterToGlyph(i2)) + s2 * (1e3 / o2) || 0) / 1e3 ) : ((d3 = f2 && 'object' === _typeof$3(h2[i2]) && !isNaN(parseInt(h2[i2][g2], 10)) ? h2[i2][g2] / l2 : 0), v4.push((c2[i2] || m2) / u2 + d3)), (g2 = i2) return v4 }), (Yt = Vt.getStringUnitWidth = function (t3, e2) { var r2 = (e2 = e2 || {}).fontSize || this.internal.getFontSize(), n2 = e2.font || this.internal.getFont(), i2 = e2.charSpace || this.internal.getCharSpace() return ( Vt.processArabic && (t3 = Vt.processArabic(t3)), 'function' == typeof n2.metadata.widthOfString ? n2.metadata.widthOfString(t3, r2, i2) / r2 : Gt.apply(this, arguments).reduce(function (t4, e3) { return t4 + e3 }, 0) ) }), (Jt = function (t3, e2, r2, n2) { for ( var i2 = [], a2 = 0, o2 = t3.length, s2 = 0; a2 !== o2 && s2 + e2[a2] < r2; ) (s2 += e2[a2]), a2++ i2.push(t3.slice(0, a2)) var c2 = a2 for (s2 = 0; a2 !== o2; ) s2 + e2[a2] > n2 && (i2.push(t3.slice(c2, a2)), (s2 = 0), (c2 = a2)), (s2 += e2[a2]), a2++ return c2 !== a2 && i2.push(t3.slice(c2, a2)), i2 }), (Xt = function (t3, e2, r2) { r2 || (r2 = {}) var n2, i2, a2, o2, s2, c2, u2, h2 = [], l2 = [h2], f2 = r2.textIndent || 0, d3 = 0, p2 = 0, g2 = t3.split(' '), m2 = Gt.apply(this, [' ', r2])[0] if ((c2 = -1 === r2.lineIndent ? g2[0].length + 2 : r2.lineIndent || 0)) { var v4 = Array(c2).join(' '), b2 = [] g2.map(function (t4) { ;(t4 = t4.split(/\s*\n/)).length > 1 ? (b2 = b2.concat( t4.map(function (t5, e3) { return (e3 && t5.length ? '\n' : '') + t5 }) )) : b2.push(t4[0]) }), (g2 = b2), (c2 = Yt.apply(this, [v4, r2])) } for (a2 = 0, o2 = g2.length; a2 < o2; a2++) { var y2 = 0 if ( ((n2 = g2[a2]), c2 && '\n' == n2[0] && ((n2 = n2.substr(1)), (y2 = 1)), f2 + d3 + (p2 = (i2 = Gt.apply(this, [n2, r2])).reduce(function (t4, e3) { return t4 + e3 }, 0)) > e2 || y2) ) { if (p2 > e2) { for ( s2 = Jt.apply(this, [n2, i2, e2 - (f2 + d3), e2]), h2.push(s2.shift()), h2 = [s2.pop()]; s2.length; ) l2.push([s2.shift()]) p2 = i2 .slice(n2.length - (h2[0] ? h2[0].length : 0)) .reduce(function (t4, e3) { return t4 + e3 }, 0) } else h2 = [n2] l2.push(h2), (f2 = p2 + c2), (d3 = m2) } else h2.push(n2), (f2 += d3 + p2), (d3 = m2) } return ( (u2 = c2 ? function (t4, e3) { return (e3 ? v4 : '') + t4.join(' ') } : function (t4) { return t4.join(' ') }), l2.map(u2) ) }), (Vt.splitTextToSize = function (t3, e2, r2) { var n2, i2 = (r2 = r2 || {}).fontSize || this.internal.getFontSize(), a2 = function (t4) { if (t4.widths && t4.kerning) return { widths: t4.widths, kerning: t4.kerning } var e3 = this.internal.getFont(t4.fontName, t4.fontStyle) return e3.metadata.Unicode ? { widths: e3.metadata.Unicode.widths || { 0: 1 }, kerning: e3.metadata.Unicode.kerning || {}, } : { font: e3.metadata, fontSize: this.internal.getFontSize(), charSpace: this.internal.getCharSpace(), } }.call(this, r2) n2 = Array.isArray(t3) ? t3 : String(t3).split(/\r?\n/) var o2 = (1 * this.internal.scaleFactor * e2) / i2 ;(a2.textIndent = r2.textIndent ? (1 * r2.textIndent * this.internal.scaleFactor) / i2 : 0), (a2.lineIndent = r2.lineIndent) var s2, c2, u2 = [] for (s2 = 0, c2 = n2.length; s2 < c2; s2++) u2 = u2.concat(Xt.apply(this, [n2[s2], o2, a2])) return u2 }), (function (e2) { e2.__fontmetrics__ = e2.__fontmetrics__ || {} for ( var r2 = 'klmnopqrstuvwxyz', n2 = {}, i2 = {}, a2 = 0; a2 < r2.length; a2++ ) (n2[r2[a2]] = '0123456789abcdef'[a2]), (i2['0123456789abcdef'[a2]] = r2[a2]) var o2 = function (t3) { return '0x' + parseInt(t3, 10).toString(16) }, s2 = (e2.__fontmetrics__.compress = function (e3) { var r3, n3, a3, c3, u3 = ['{'] for (var h3 in e3) { if ( ((r3 = e3[h3]), isNaN(parseInt(h3, 10)) ? (n3 = "'" + h3 + "'") : ((h3 = parseInt(h3, 10)), (n3 = (n3 = o2(h3).slice(2)).slice(0, -1) + i2[n3.slice(-1)])), 'number' == typeof r3) ) r3 < 0 ? ((a3 = o2(r3).slice(3)), (c3 = '-')) : ((a3 = o2(r3).slice(2)), (c3 = '')), (a3 = c3 + a3.slice(0, -1) + i2[a3.slice(-1)]) else { if ('object' !== _typeof$3(r3)) throw new Error( "Don't know what to do with value type " + _typeof$3(r3) + '.' ) a3 = s2(r3) } u3.push(n3 + a3) } return u3.push('}'), u3.join('') }), c2 = (e2.__fontmetrics__.uncompress = function (t3) { if ('string' != typeof t3) throw new Error('Invalid argument passed to uncompress.') for ( var e3, r3, i3, a3, o3 = {}, s3 = 1, c3 = o3, u3 = [], h3 = '', l3 = '', f2 = t3.length - 1, d3 = 1; d3 < f2; d3 += 1 ) "'" == (a3 = t3[d3]) ? e3 ? ((i3 = e3.join('')), (e3 = void 0)) : (e3 = []) : e3 ? e3.push(a3) : '{' == a3 ? (u3.push([c3, i3]), (c3 = {}), (i3 = void 0)) : '}' == a3 ? (((r3 = u3.pop())[0][r3[1]] = c3), (i3 = void 0), (c3 = r3[0])) : '-' == a3 ? (s3 = -1) : void 0 === i3 ? n2.hasOwnProperty(a3) ? ((h3 += n2[a3]), (i3 = parseInt(h3, 16) * s3), (s3 = 1), (h3 = '')) : (h3 += a3) : n2.hasOwnProperty(a3) ? ((l3 += n2[a3]), (c3[i3] = parseInt(l3, 16) * s3), (s3 = 1), (i3 = void 0), (l3 = '')) : (l3 += a3) return o3 }), u2 = { codePages: ['WinAnsiEncoding'], WinAnsiEncoding: c2( '{19m8n201n9q201o9r201s9l201t9m201u8m201w9n201x9o201y8o202k8q202l8r202m9p202q8p20aw8k203k8t203t8v203u9v2cq8s212m9t15m8w15n9w2dw9s16k8u16l9u17s9z17x8y17y9y}' ), }, h2 = { Unicode: { Courier: u2, 'Courier-Bold': u2, 'Courier-BoldOblique': u2, 'Courier-Oblique': u2, Helvetica: u2, 'Helvetica-Bold': u2, 'Helvetica-BoldOblique': u2, 'Helvetica-Oblique': u2, 'Times-Roman': u2, 'Times-Bold': u2, 'Times-BoldItalic': u2, 'Times-Italic': u2, }, }, l2 = { Unicode: { 'Courier-Oblique': c2("{'widths'{k3w'fof'6o}'kerning'{'fof'-6o}}"), 'Times-BoldItalic': c2( "{'widths'{k3o2q4ycx2r201n3m201o6o201s2l201t2l201u2l201w3m201x3m201y3m2k1t2l2r202m2n2n3m2o3m2p5n202q6o2r1w2s2l2t2l2u3m2v3t2w1t2x2l2y1t2z1w3k3m3l3m3m3m3n3m3o3m3p3m3q3m3r3m3s3m203t2l203u2l3v2l3w3t3x3t3y3t3z3m4k5n4l4m4m4m4n4m4o4s4p4m4q4m4r4s4s4y4t2r4u3m4v4m4w3x4x5t4y4s4z4s5k3x5l4s5m4m5n3r5o3x5p4s5q4m5r5t5s4m5t3x5u3x5v2l5w1w5x2l5y3t5z3m6k2l6l3m6m3m6n2w6o3m6p2w6q2l6r3m6s3r6t1w6u1w6v3m6w1w6x4y6y3r6z3m7k3m7l3m7m2r7n2r7o1w7p3r7q2w7r4m7s3m7t2w7u2r7v2n7w1q7x2n7y3t202l3mcl4mal2ram3man3mao3map3mar3mas2lat4uau1uav3maw3way4uaz2lbk2sbl3t'fof'6obo2lbp3tbq3mbr1tbs2lbu1ybv3mbz3mck4m202k3mcm4mcn4mco4mcp4mcq5ycr4mcs4mct4mcu4mcv4mcw2r2m3rcy2rcz2rdl4sdm4sdn4sdo4sdp4sdq4sds4sdt4sdu4sdv4sdw4sdz3mek3mel3mem3men3meo3mep3meq4ser2wes2wet2weu2wev2wew1wex1wey1wez1wfl3rfm3mfn3mfo3mfp3mfq3mfr3tfs3mft3rfu3rfv3rfw3rfz2w203k6o212m6o2dw2l2cq2l3t3m3u2l17s3x19m3m}'kerning'{cl{4qu5kt5qt5rs17ss5ts}201s{201ss}201t{cks4lscmscnscoscpscls2wu2yu201ts}201x{2wu2yu}2k{201ts}2w{4qx5kx5ou5qx5rs17su5tu}2x{17su5tu5ou}2y{4qx5kx5ou5qx5rs17ss5ts}'fof'-6ofn{17sw5tw5ou5qw5rs}7t{cksclscmscnscoscps4ls}3u{17su5tu5os5qs}3v{17su5tu5os5qs}7p{17su5tu}ck{4qu5kt5qt5rs17ss5ts}4l{4qu5kt5qt5rs17ss5ts}cm{4qu5kt5qt5rs17ss5ts}cn{4qu5kt5qt5rs17ss5ts}co{4qu5kt5qt5rs17ss5ts}cp{4qu5kt5qt5rs17ss5ts}6l{4qu5ou5qw5rt17su5tu}5q{ckuclucmucnucoucpu4lu}5r{ckuclucmucnucoucpu4lu}7q{cksclscmscnscoscps4ls}6p{4qu5ou5qw5rt17sw5tw}ek{4qu5ou5qw5rt17su5tu}el{4qu5ou5qw5rt17su5tu}em{4qu5ou5qw5rt17su5tu}en{4qu5ou5qw5rt17su5tu}eo{4qu5ou5qw5rt17su5tu}ep{4qu5ou5qw5rt17su5tu}es{17ss5ts5qs4qu}et{4qu5ou5qw5rt17sw5tw}eu{4qu5ou5qw5rt17ss5ts}ev{17ss5ts5qs4qu}6z{17sw5tw5ou5qw5rs}fm{17sw5tw5ou5qw5rs}7n{201ts}fo{17sw5tw5ou5qw5rs}fp{17sw5tw5ou5qw5rs}fq{17sw5tw5ou5qw5rs}7r{cksclscmscnscoscps4ls}fs{17sw5tw5ou5qw5rs}ft{17su5tu}fu{17su5tu}fv{17su5tu}fw{17su5tu}fz{cksclscmscnscoscps4ls}}}" ), 'Helvetica-Bold': c2( "{'widths'{k3s2q4scx1w201n3r201o6o201s1w201t1w201u1w201w3m201x3m201y3m2k1w2l2l202m2n2n3r2o3r2p5t202q6o2r1s2s2l2t2l2u2r2v3u2w1w2x2l2y1w2z1w3k3r3l3r3m3r3n3r3o3r3p3r3q3r3r3r3s3r203t2l203u2l3v2l3w3u3x3u3y3u3z3x4k6l4l4s4m4s4n4s4o4s4p4m4q3x4r4y4s4s4t1w4u3r4v4s4w3x4x5n4y4s4z4y5k4m5l4y5m4s5n4m5o3x5p4s5q4m5r5y5s4m5t4m5u3x5v2l5w1w5x2l5y3u5z3r6k2l6l3r6m3x6n3r6o3x6p3r6q2l6r3x6s3x6t1w6u1w6v3r6w1w6x5t6y3x6z3x7k3x7l3x7m2r7n3r7o2l7p3x7q3r7r4y7s3r7t3r7u3m7v2r7w1w7x2r7y3u202l3rcl4sal2lam3ran3rao3rap3rar3ras2lat4tau2pav3raw3uay4taz2lbk2sbl3u'fof'6obo2lbp3xbq3rbr1wbs2lbu2obv3rbz3xck4s202k3rcm4scn4sco4scp4scq6ocr4scs4mct4mcu4mcv4mcw1w2m2zcy1wcz1wdl4sdm4ydn4ydo4ydp4ydq4yds4ydt4sdu4sdv4sdw4sdz3xek3rel3rem3ren3reo3rep3req5ter3res3ret3reu3rev3rew1wex1wey1wez1wfl3xfm3xfn3xfo3xfp3xfq3xfr3ufs3xft3xfu3xfv3xfw3xfz3r203k6o212m6o2dw2l2cq2l3t3r3u2l17s4m19m3r}'kerning'{cl{4qs5ku5ot5qs17sv5tv}201t{2ww4wy2yw}201w{2ks}201x{2ww4wy2yw}2k{201ts201xs}2w{7qs4qu5kw5os5qw5rs17su5tu7tsfzs}2x{5ow5qs}2y{7qs4qu5kw5os5qw5rs17su5tu7tsfzs}'fof'-6o7p{17su5tu5ot}ck{4qs5ku5ot5qs17sv5tv}4l{4qs5ku5ot5qs17sv5tv}cm{4qs5ku5ot5qs17sv5tv}cn{4qs5ku5ot5qs17sv5tv}co{4qs5ku5ot5qs17sv5tv}cp{4qs5ku5ot5qs17sv5tv}6l{17st5tt5os}17s{2kwclvcmvcnvcovcpv4lv4wwckv}5o{2kucltcmtcntcotcpt4lt4wtckt}5q{2ksclscmscnscoscps4ls4wvcks}5r{2ks4ws}5t{2kwclvcmvcnvcovcpv4lv4wwckv}eo{17st5tt5os}fu{17su5tu5ot}6p{17ss5ts}ek{17st5tt5os}el{17st5tt5os}em{17st5tt5os}en{17st5tt5os}6o{201ts}ep{17st5tt5os}es{17ss5ts}et{17ss5ts}eu{17ss5ts}ev{17ss5ts}6z{17su5tu5os5qt}fm{17su5tu5os5qt}fn{17su5tu5os5qt}fo{17su5tu5os5qt}fp{17su5tu5os5qt}fq{17su5tu5os5qt}fs{17su5tu5os5qt}ft{17su5tu5ot}7m{5os}fv{17su5tu5ot}fw{17su5tu5ot}}}" ), Courier: c2("{'widths'{k3w'fof'6o}'kerning'{'fof'-6o}}"), 'Courier-BoldOblique': c2( "{'widths'{k3w'fof'6o}'kerning'{'fof'-6o}}" ), 'Times-Bold': c2( "{'widths'{k3q2q5ncx2r201n3m201o6o201s2l201t2l201u2l201w3m201x3m201y3m2k1t2l2l202m2n2n3m2o3m2p6o202q6o2r1w2s2l2t2l2u3m2v3t2w1t2x2l2y1t2z1w3k3m3l3m3m3m3n3m3o3m3p3m3q3m3r3m3s3m203t2l203u2l3v2l3w3t3x3t3y3t3z3m4k5x4l4s4m4m4n4s4o4s4p4m4q3x4r4y4s4y4t2r4u3m4v4y4w4m4x5y4y4s4z4y5k3x5l4y5m4s5n3r5o4m5p4s5q4s5r6o5s4s5t4s5u4m5v2l5w1w5x2l5y3u5z3m6k2l6l3m6m3r6n2w6o3r6p2w6q2l6r3m6s3r6t1w6u2l6v3r6w1w6x5n6y3r6z3m7k3r7l3r7m2w7n2r7o2l7p3r7q3m7r4s7s3m7t3m7u2w7v2r7w1q7x2r7y3o202l3mcl4sal2lam3man3mao3map3mar3mas2lat4uau1yav3maw3tay4uaz2lbk2sbl3t'fof'6obo2lbp3rbr1tbs2lbu2lbv3mbz3mck4s202k3mcm4scn4sco4scp4scq6ocr4scs4mct4mcu4mcv4mcw2r2m3rcy2rcz2rdl4sdm4ydn4ydo4ydp4ydq4yds4ydt4sdu4sdv4sdw4sdz3rek3mel3mem3men3meo3mep3meq4ser2wes2wet2weu2wev2wew1wex1wey1wez1wfl3rfm3mfn3mfo3mfp3mfq3mfr3tfs3mft3rfu3rfv3rfw3rfz3m203k6o212m6o2dw2l2cq2l3t3m3u2l17s4s19m3m}'kerning'{cl{4qt5ks5ot5qy5rw17sv5tv}201t{cks4lscmscnscoscpscls4wv}2k{201ts}2w{4qu5ku7mu5os5qx5ru17su5tu}2x{17su5tu5ou5qs}2y{4qv5kv7mu5ot5qz5ru17su5tu}'fof'-6o7t{cksclscmscnscoscps4ls}3u{17su5tu5os5qu}3v{17su5tu5os5qu}fu{17su5tu5ou5qu}7p{17su5tu5ou5qu}ck{4qt5ks5ot5qy5rw17sv5tv}4l{4qt5ks5ot5qy5rw17sv5tv}cm{4qt5ks5ot5qy5rw17sv5tv}cn{4qt5ks5ot5qy5rw17sv5tv}co{4qt5ks5ot5qy5rw17sv5tv}cp{4qt5ks5ot5qy5rw17sv5tv}6l{17st5tt5ou5qu}17s{ckuclucmucnucoucpu4lu4wu}5o{ckuclucmucnucoucpu4lu4wu}5q{ckzclzcmzcnzcozcpz4lz4wu}5r{ckxclxcmxcnxcoxcpx4lx4wu}5t{ckuclucmucnucoucpu4lu4wu}7q{ckuclucmucnucoucpu4lu}6p{17sw5tw5ou5qu}ek{17st5tt5qu}el{17st5tt5ou5qu}em{17st5tt5qu}en{17st5tt5qu}eo{17st5tt5qu}ep{17st5tt5ou5qu}es{17ss5ts5qu}et{17sw5tw5ou5qu}eu{17sw5tw5ou5qu}ev{17ss5ts5qu}6z{17sw5tw5ou5qu5rs}fm{17sw5tw5ou5qu5rs}fn{17sw5tw5ou5qu5rs}fo{17sw5tw5ou5qu5rs}fp{17sw5tw5ou5qu5rs}fq{17sw5tw5ou5qu5rs}7r{cktcltcmtcntcotcpt4lt5os}fs{17sw5tw5ou5qu5rs}ft{17su5tu5ou5qu}7m{5os}fv{17su5tu5ou5qu}fw{17su5tu5ou5qu}fz{cksclscmscnscoscps4ls}}}" ), Symbol: c2( "{'widths'{k3uaw4r19m3m2k1t2l2l202m2y2n3m2p5n202q6o3k3m2s2l2t2l2v3r2w1t3m3m2y1t2z1wbk2sbl3r'fof'6o3n3m3o3m3p3m3q3m3r3m3s3m3t3m3u1w3v1w3w3r3x3r3y3r3z2wbp3t3l3m5v2l5x2l5z3m2q4yfr3r7v3k7w1o7x3k}'kerning'{'fof'-6o}}" ), Helvetica: c2( "{'widths'{k3p2q4mcx1w201n3r201o6o201s1q201t1q201u1q201w2l201x2l201y2l2k1w2l1w202m2n2n3r2o3r2p5t202q6o2r1n2s2l2t2l2u2r2v3u2w1w2x2l2y1w2z1w3k3r3l3r3m3r3n3r3o3r3p3r3q3r3r3r3s3r203t2l203u2l3v1w3w3u3x3u3y3u3z3r4k6p4l4m4m4m4n4s4o4s4p4m4q3x4r4y4s4s4t1w4u3m4v4m4w3r4x5n4y4s4z4y5k4m5l4y5m4s5n4m5o3x5p4s5q4m5r5y5s4m5t4m5u3x5v1w5w1w5x1w5y2z5z3r6k2l6l3r6m3r6n3m6o3r6p3r6q1w6r3r6s3r6t1q6u1q6v3m6w1q6x5n6y3r6z3r7k3r7l3r7m2l7n3m7o1w7p3r7q3m7r4s7s3m7t3m7u3m7v2l7w1u7x2l7y3u202l3rcl4mal2lam3ran3rao3rap3rar3ras2lat4tau2pav3raw3uay4taz2lbk2sbl3u'fof'6obo2lbp3rbr1wbs2lbu2obv3rbz3xck4m202k3rcm4mcn4mco4mcp4mcq6ocr4scs4mct4mcu4mcv4mcw1w2m2ncy1wcz1wdl4sdm4ydn4ydo4ydp4ydq4yds4ydt4sdu4sdv4sdw4sdz3xek3rel3rem3ren3reo3rep3req5ter3mes3ret3reu3rev3rew1wex1wey1wez1wfl3rfm3rfn3rfo3rfp3rfq3rfr3ufs3xft3rfu3rfv3rfw3rfz3m203k6o212m6o2dw2l2cq2l3t3r3u1w17s4m19m3r}'kerning'{5q{4wv}cl{4qs5kw5ow5qs17sv5tv}201t{2wu4w1k2yu}201x{2wu4wy2yu}17s{2ktclucmucnu4otcpu4lu4wycoucku}2w{7qs4qz5k1m17sy5ow5qx5rsfsu5ty7tufzu}2x{17sy5ty5oy5qs}2y{7qs4qz5k1m17sy5ow5qx5rsfsu5ty7tufzu}'fof'-6o7p{17sv5tv5ow}ck{4qs5kw5ow5qs17sv5tv}4l{4qs5kw5ow5qs17sv5tv}cm{4qs5kw5ow5qs17sv5tv}cn{4qs5kw5ow5qs17sv5tv}co{4qs5kw5ow5qs17sv5tv}cp{4qs5kw5ow5qs17sv5tv}6l{17sy5ty5ow}do{17st5tt}4z{17st5tt}7s{fst}dm{17st5tt}dn{17st5tt}5o{ckwclwcmwcnwcowcpw4lw4wv}dp{17st5tt}dq{17st5tt}7t{5ow}ds{17st5tt}5t{2ktclucmucnu4otcpu4lu4wycoucku}fu{17sv5tv5ow}6p{17sy5ty5ow5qs}ek{17sy5ty5ow}el{17sy5ty5ow}em{17sy5ty5ow}en{5ty}eo{17sy5ty5ow}ep{17sy5ty5ow}es{17sy5ty5qs}et{17sy5ty5ow5qs}eu{17sy5ty5ow5qs}ev{17sy5ty5ow5qs}6z{17sy5ty5ow5qs}fm{17sy5ty5ow5qs}fn{17sy5ty5ow5qs}fo{17sy5ty5ow5qs}fp{17sy5ty5qs}fq{17sy5ty5ow5qs}7r{5ow}fs{17sy5ty5ow5qs}ft{17sv5tv5ow}7m{5ow}fv{17sv5tv5ow}fw{17sv5tv5ow}}}" ), 'Helvetica-BoldOblique': c2( "{'widths'{k3s2q4scx1w201n3r201o6o201s1w201t1w201u1w201w3m201x3m201y3m2k1w2l2l202m2n2n3r2o3r2p5t202q6o2r1s2s2l2t2l2u2r2v3u2w1w2x2l2y1w2z1w3k3r3l3r3m3r3n3r3o3r3p3r3q3r3r3r3s3r203t2l203u2l3v2l3w3u3x3u3y3u3z3x4k6l4l4s4m4s4n4s4o4s4p4m4q3x4r4y4s4s4t1w4u3r4v4s4w3x4x5n4y4s4z4y5k4m5l4y5m4s5n4m5o3x5p4s5q4m5r5y5s4m5t4m5u3x5v2l5w1w5x2l5y3u5z3r6k2l6l3r6m3x6n3r6o3x6p3r6q2l6r3x6s3x6t1w6u1w6v3r6w1w6x5t6y3x6z3x7k3x7l3x7m2r7n3r7o2l7p3x7q3r7r4y7s3r7t3r7u3m7v2r7w1w7x2r7y3u202l3rcl4sal2lam3ran3rao3rap3rar3ras2lat4tau2pav3raw3uay4taz2lbk2sbl3u'fof'6obo2lbp3xbq3rbr1wbs2lbu2obv3rbz3xck4s202k3rcm4scn4sco4scp4scq6ocr4scs4mct4mcu4mcv4mcw1w2m2zcy1wcz1wdl4sdm4ydn4ydo4ydp4ydq4yds4ydt4sdu4sdv4sdw4sdz3xek3rel3rem3ren3reo3rep3req5ter3res3ret3reu3rev3rew1wex1wey1wez1wfl3xfm3xfn3xfo3xfp3xfq3xfr3ufs3xft3xfu3xfv3xfw3xfz3r203k6o212m6o2dw2l2cq2l3t3r3u2l17s4m19m3r}'kerning'{cl{4qs5ku5ot5qs17sv5tv}201t{2ww4wy2yw}201w{2ks}201x{2ww4wy2yw}2k{201ts201xs}2w{7qs4qu5kw5os5qw5rs17su5tu7tsfzs}2x{5ow5qs}2y{7qs4qu5kw5os5qw5rs17su5tu7tsfzs}'fof'-6o7p{17su5tu5ot}ck{4qs5ku5ot5qs17sv5tv}4l{4qs5ku5ot5qs17sv5tv}cm{4qs5ku5ot5qs17sv5tv}cn{4qs5ku5ot5qs17sv5tv}co{4qs5ku5ot5qs17sv5tv}cp{4qs5ku5ot5qs17sv5tv}6l{17st5tt5os}17s{2kwclvcmvcnvcovcpv4lv4wwckv}5o{2kucltcmtcntcotcpt4lt4wtckt}5q{2ksclscmscnscoscps4ls4wvcks}5r{2ks4ws}5t{2kwclvcmvcnvcovcpv4lv4wwckv}eo{17st5tt5os}fu{17su5tu5ot}6p{17ss5ts}ek{17st5tt5os}el{17st5tt5os}em{17st5tt5os}en{17st5tt5os}6o{201ts}ep{17st5tt5os}es{17ss5ts}et{17ss5ts}eu{17ss5ts}ev{17ss5ts}6z{17su5tu5os5qt}fm{17su5tu5os5qt}fn{17su5tu5os5qt}fo{17su5tu5os5qt}fp{17su5tu5os5qt}fq{17su5tu5os5qt}fs{17su5tu5os5qt}ft{17su5tu5ot}7m{5os}fv{17su5tu5ot}fw{17su5tu5ot}}}" ), ZapfDingbats: c2("{'widths'{k4u2k1w'fof'6o}'kerning'{'fof'-6o}}"), 'Courier-Bold': c2("{'widths'{k3w'fof'6o}'kerning'{'fof'-6o}}"), 'Times-Italic': c2( "{'widths'{k3n2q4ycx2l201n3m201o5t201s2l201t2l201u2l201w3r201x3r201y3r2k1t2l2l202m2n2n3m2o3m2p5n202q5t2r1p2s2l2t2l2u3m2v4n2w1t2x2l2y1t2z1w3k3m3l3m3m3m3n3m3o3m3p3m3q3m3r3m3s3m203t2l203u2l3v2l3w4n3x4n3y4n3z3m4k5w4l3x4m3x4n4m4o4s4p3x4q3x4r4s4s4s4t2l4u2w4v4m4w3r4x5n4y4m4z4s5k3x5l4s5m3x5n3m5o3r5p4s5q3x5r5n5s3x5t3r5u3r5v2r5w1w5x2r5y2u5z3m6k2l6l3m6m3m6n2w6o3m6p2w6q1w6r3m6s3m6t1w6u1w6v2w6w1w6x4s6y3m6z3m7k3m7l3m7m2r7n2r7o1w7p3m7q2w7r4m7s2w7t2w7u2r7v2s7w1v7x2s7y3q202l3mcl3xal2ram3man3mao3map3mar3mas2lat4wau1vav3maw4nay4waz2lbk2sbl4n'fof'6obo2lbp3mbq3obr1tbs2lbu1zbv3mbz3mck3x202k3mcm3xcn3xco3xcp3xcq5tcr4mcs3xct3xcu3xcv3xcw2l2m2ucy2lcz2ldl4mdm4sdn4sdo4sdp4sdq4sds4sdt4sdu4sdv4sdw4sdz3mek3mel3mem3men3meo3mep3meq4mer2wes2wet2weu2wev2wew1wex1wey1wez1wfl3mfm3mfn3mfo3mfp3mfq3mfr4nfs3mft3mfu3mfv3mfw3mfz2w203k6o212m6m2dw2l2cq2l3t3m3u2l17s3r19m3m}'kerning'{cl{5kt4qw}201s{201sw}201t{201tw2wy2yy6q-t}201x{2wy2yy}2k{201tw}2w{7qs4qy7rs5ky7mw5os5qx5ru17su5tu}2x{17ss5ts5os}2y{7qs4qy7rs5ky7mw5os5qx5ru17su5tu}'fof'-6o6t{17ss5ts5qs}7t{5os}3v{5qs}7p{17su5tu5qs}ck{5kt4qw}4l{5kt4qw}cm{5kt4qw}cn{5kt4qw}co{5kt4qw}cp{5kt4qw}6l{4qs5ks5ou5qw5ru17su5tu}17s{2ks}5q{ckvclvcmvcnvcovcpv4lv}5r{ckuclucmucnucoucpu4lu}5t{2ks}6p{4qs5ks5ou5qw5ru17su5tu}ek{4qs5ks5ou5qw5ru17su5tu}el{4qs5ks5ou5qw5ru17su5tu}em{4qs5ks5ou5qw5ru17su5tu}en{4qs5ks5ou5qw5ru17su5tu}eo{4qs5ks5ou5qw5ru17su5tu}ep{4qs5ks5ou5qw5ru17su5tu}es{5ks5qs4qs}et{4qs5ks5ou5qw5ru17su5tu}eu{4qs5ks5qw5ru17su5tu}ev{5ks5qs4qs}ex{17ss5ts5qs}6z{4qv5ks5ou5qw5ru17su5tu}fm{4qv5ks5ou5qw5ru17su5tu}fn{4qv5ks5ou5qw5ru17su5tu}fo{4qv5ks5ou5qw5ru17su5tu}fp{4qv5ks5ou5qw5ru17su5tu}fq{4qv5ks5ou5qw5ru17su5tu}7r{5os}fs{4qv5ks5ou5qw5ru17su5tu}ft{17su5tu5qs}fu{17su5tu5qs}fv{17su5tu5qs}fw{17su5tu5qs}}}" ), 'Times-Roman': c2( "{'widths'{k3n2q4ycx2l201n3m201o6o201s2l201t2l201u2l201w2w201x2w201y2w2k1t2l2l202m2n2n3m2o3m2p5n202q6o2r1m2s2l2t2l2u3m2v3s2w1t2x2l2y1t2z1w3k3m3l3m3m3m3n3m3o3m3p3m3q3m3r3m3s3m203t2l203u2l3v1w3w3s3x3s3y3s3z2w4k5w4l4s4m4m4n4m4o4s4p3x4q3r4r4s4s4s4t2l4u2r4v4s4w3x4x5t4y4s4z4s5k3r5l4s5m4m5n3r5o3x5p4s5q4s5r5y5s4s5t4s5u3x5v2l5w1w5x2l5y2z5z3m6k2l6l2w6m3m6n2w6o3m6p2w6q2l6r3m6s3m6t1w6u1w6v3m6w1w6x4y6y3m6z3m7k3m7l3m7m2l7n2r7o1w7p3m7q3m7r4s7s3m7t3m7u2w7v3k7w1o7x3k7y3q202l3mcl4sal2lam3man3mao3map3mar3mas2lat4wau1vav3maw3say4waz2lbk2sbl3s'fof'6obo2lbp3mbq2xbr1tbs2lbu1zbv3mbz2wck4s202k3mcm4scn4sco4scp4scq5tcr4mcs3xct3xcu3xcv3xcw2l2m2tcy2lcz2ldl4sdm4sdn4sdo4sdp4sdq4sds4sdt4sdu4sdv4sdw4sdz3mek2wel2wem2wen2weo2wep2weq4mer2wes2wet2weu2wev2wew1wex1wey1wez1wfl3mfm3mfn3mfo3mfp3mfq3mfr3sfs3mft3mfu3mfv3mfw3mfz3m203k6o212m6m2dw2l2cq2l3t3m3u1w17s4s19m3m}'kerning'{cl{4qs5ku17sw5ou5qy5rw201ss5tw201ws}201s{201ss}201t{ckw4lwcmwcnwcowcpwclw4wu201ts}2k{201ts}2w{4qs5kw5os5qx5ru17sx5tx}2x{17sw5tw5ou5qu}2y{4qs5kw5os5qx5ru17sx5tx}'fof'-6o7t{ckuclucmucnucoucpu4lu5os5rs}3u{17su5tu5qs}3v{17su5tu5qs}7p{17sw5tw5qs}ck{4qs5ku17sw5ou5qy5rw201ss5tw201ws}4l{4qs5ku17sw5ou5qy5rw201ss5tw201ws}cm{4qs5ku17sw5ou5qy5rw201ss5tw201ws}cn{4qs5ku17sw5ou5qy5rw201ss5tw201ws}co{4qs5ku17sw5ou5qy5rw201ss5tw201ws}cp{4qs5ku17sw5ou5qy5rw201ss5tw201ws}6l{17su5tu5os5qw5rs}17s{2ktclvcmvcnvcovcpv4lv4wuckv}5o{ckwclwcmwcnwcowcpw4lw4wu}5q{ckyclycmycnycoycpy4ly4wu5ms}5r{cktcltcmtcntcotcpt4lt4ws}5t{2ktclvcmvcnvcovcpv4lv4wuckv}7q{cksclscmscnscoscps4ls}6p{17su5tu5qw5rs}ek{5qs5rs}el{17su5tu5os5qw5rs}em{17su5tu5os5qs5rs}en{17su5qs5rs}eo{5qs5rs}ep{17su5tu5os5qw5rs}es{5qs}et{17su5tu5qw5rs}eu{17su5tu5qs5rs}ev{5qs}6z{17sv5tv5os5qx5rs}fm{5os5qt5rs}fn{17sv5tv5os5qx5rs}fo{17sv5tv5os5qx5rs}fp{5os5qt5rs}fq{5os5qt5rs}7r{ckuclucmucnucoucpu4lu5os}fs{17sv5tv5os5qx5rs}ft{17ss5ts5qs}fu{17sw5tw5qs}fv{17sw5tw5qs}fw{17ss5ts5qs}fz{ckuclucmucnucoucpu4lu5os5rs}}}" ), 'Helvetica-Oblique': c2( "{'widths'{k3p2q4mcx1w201n3r201o6o201s1q201t1q201u1q201w2l201x2l201y2l2k1w2l1w202m2n2n3r2o3r2p5t202q6o2r1n2s2l2t2l2u2r2v3u2w1w2x2l2y1w2z1w3k3r3l3r3m3r3n3r3o3r3p3r3q3r3r3r3s3r203t2l203u2l3v1w3w3u3x3u3y3u3z3r4k6p4l4m4m4m4n4s4o4s4p4m4q3x4r4y4s4s4t1w4u3m4v4m4w3r4x5n4y4s4z4y5k4m5l4y5m4s5n4m5o3x5p4s5q4m5r5y5s4m5t4m5u3x5v1w5w1w5x1w5y2z5z3r6k2l6l3r6m3r6n3m6o3r6p3r6q1w6r3r6s3r6t1q6u1q6v3m6w1q6x5n6y3r6z3r7k3r7l3r7m2l7n3m7o1w7p3r7q3m7r4s7s3m7t3m7u3m7v2l7w1u7x2l7y3u202l3rcl4mal2lam3ran3rao3rap3rar3ras2lat4tau2pav3raw3uay4taz2lbk2sbl3u'fof'6obo2lbp3rbr1wbs2lbu2obv3rbz3xck4m202k3rcm4mcn4mco4mcp4mcq6ocr4scs4mct4mcu4mcv4mcw1w2m2ncy1wcz1wdl4sdm4ydn4ydo4ydp4ydq4yds4ydt4sdu4sdv4sdw4sdz3xek3rel3rem3ren3reo3rep3req5ter3mes3ret3reu3rev3rew1wex1wey1wez1wfl3rfm3rfn3rfo3rfp3rfq3rfr3ufs3xft3rfu3rfv3rfw3rfz3m203k6o212m6o2dw2l2cq2l3t3r3u1w17s4m19m3r}'kerning'{5q{4wv}cl{4qs5kw5ow5qs17sv5tv}201t{2wu4w1k2yu}201x{2wu4wy2yu}17s{2ktclucmucnu4otcpu4lu4wycoucku}2w{7qs4qz5k1m17sy5ow5qx5rsfsu5ty7tufzu}2x{17sy5ty5oy5qs}2y{7qs4qz5k1m17sy5ow5qx5rsfsu5ty7tufzu}'fof'-6o7p{17sv5tv5ow}ck{4qs5kw5ow5qs17sv5tv}4l{4qs5kw5ow5qs17sv5tv}cm{4qs5kw5ow5qs17sv5tv}cn{4qs5kw5ow5qs17sv5tv}co{4qs5kw5ow5qs17sv5tv}cp{4qs5kw5ow5qs17sv5tv}6l{17sy5ty5ow}do{17st5tt}4z{17st5tt}7s{fst}dm{17st5tt}dn{17st5tt}5o{ckwclwcmwcnwcowcpw4lw4wv}dp{17st5tt}dq{17st5tt}7t{5ow}ds{17st5tt}5t{2ktclucmucnu4otcpu4lu4wycoucku}fu{17sv5tv5ow}6p{17sy5ty5ow5qs}ek{17sy5ty5ow}el{17sy5ty5ow}em{17sy5ty5ow}en{5ty}eo{17sy5ty5ow}ep{17sy5ty5ow}es{17sy5ty5qs}et{17sy5ty5ow5qs}eu{17sy5ty5ow5qs}ev{17sy5ty5ow5qs}6z{17sy5ty5ow5qs}fm{17sy5ty5ow5qs}fn{17sy5ty5ow5qs}fo{17sy5ty5ow5qs}fp{17sy5ty5qs}fq{17sy5ty5ow5qs}7r{5ow}fs{17sy5ty5ow5qs}ft{17sv5tv5ow}7m{5ow}fv{17sv5tv5ow}fw{17sv5tv5ow}}}" ), }, } e2.events.push([ 'addFont', function (t3) { var e3 = t3.font, r3 = l2.Unicode[e3.postScriptName] r3 && ((e3.metadata.Unicode = {}), (e3.metadata.Unicode.widths = r3.widths), (e3.metadata.Unicode.kerning = r3.kerning)) var n3 = h2.Unicode[e3.postScriptName] n3 && ((e3.metadata.Unicode.encoding = n3), (e3.encoding = n3.codePages[0])) }, ]) })(E$1.API), (function (t3) { var e2 = function (t4) { for (var e3 = t4.length, r2 = new Uint8Array(e3), n2 = 0; n2 < e3; n2++) r2[n2] = t4.charCodeAt(n2) return r2 } t3.API.events.push([ 'addFont', function (r2) { var n2 = void 0, i2 = r2.font, a2 = r2.instance if (!i2.isStandardFont) { if (void 0 === a2) throw new Error( "Font does not exist in vFS, import fonts or remove declaration doc.addFont('" + i2.postScriptName + "')." ) if ( 'string' != typeof (n2 = false === a2.existsFileInVFS(i2.postScriptName) ? a2.loadFile(i2.postScriptName) : a2.getFileFromVFS(i2.postScriptName)) ) throw new Error( "Font is not stored as string-data in vFS, import fonts or remove declaration doc.addFont('" + i2.postScriptName + "')." ) !(function (r3, n3) { ;(n3 = /^\x00\x01\x00\x00/.test(n3) ? e2(n3) : e2(u$2(n3))), (r3.metadata = t3.API.TTFFont.open(n3)), (r3.metadata.Unicode = r3.metadata.Unicode || { encoding: {}, kerning: {}, widths: [], }), (r3.metadata.glyIdsUsed = [0]) })(i2, n2) } }, ]) })(E$1), (function (t3) { function e2() { return ( n$1.canvg ? Promise.resolve(n$1.canvg) : Promise.resolve().then(function () { return index_es }) ) .catch(function (t4) { return Promise.reject(new Error('Could not load canvg: ' + t4)) }) .then(function (t4) { return t4.default ? t4.default : t4 }) } E$1.API.addSvgAsImage = function (t4, r2, n2, i2, o2, s2, c2, u2) { if (isNaN(r2) || isNaN(n2)) throw ( (a$2.error('jsPDF.addSvgAsImage: Invalid coordinates', arguments), new Error('Invalid coordinates passed to jsPDF.addSvgAsImage')) ) if (isNaN(i2) || isNaN(o2)) throw ( (a$2.error('jsPDF.addSvgAsImage: Invalid measurements', arguments), new Error( 'Invalid measurements (width and/or height) passed to jsPDF.addSvgAsImage' )) ) var h2 = document.createElement('canvas') ;(h2.width = i2), (h2.height = o2) var l2 = h2.getContext('2d') ;(l2.fillStyle = '#fff'), l2.fillRect(0, 0, h2.width, h2.height) var f2 = { ignoreMouse: true, ignoreAnimation: true, ignoreDimensions: true, }, d3 = this return e2() .then( function (e3) { return e3.fromString(l2, t4, f2) }, function () { return Promise.reject(new Error('Could not load canvg.')) } ) .then(function (t5) { return t5.render(f2) }) .then(function () { d3.addImage(h2.toDataURL('image/jpeg', 1), r2, n2, i2, o2, c2, u2) }) } })(), (E$1.API.putTotalPages = function (t3) { var e2, r2 = 0 parseInt(this.internal.getFont().id.substr(1), 10) < 15 ? ((e2 = new RegExp(t3, 'g')), (r2 = this.internal.getNumberOfPages())) : ((e2 = new RegExp(this.pdfEscape16(t3, this.internal.getFont()), 'g')), (r2 = this.pdfEscape16( this.internal.getNumberOfPages() + '', this.internal.getFont() ))) for (var n2 = 1; n2 <= this.internal.getNumberOfPages(); n2++) for (var i2 = 0; i2 < this.internal.pages[n2].length; i2++) this.internal.pages[n2][i2] = this.internal.pages[n2][i2].replace( e2, r2 ) return this }), (E$1.API.viewerPreferences = function (e2, r2) { var n2 ;(e2 = e2 || {}), (r2 = r2 || false) var i2, a2, o2, s2 = { HideToolbar: { defaultValue: false, value: false, type: 'boolean', explicitSet: false, valueSet: [true, false], pdfVersion: 1.3, }, HideMenubar: { defaultValue: false, value: false, type: 'boolean', explicitSet: false, valueSet: [true, false], pdfVersion: 1.3, }, HideWindowUI: { defaultValue: false, value: false, type: 'boolean', explicitSet: false, valueSet: [true, false], pdfVersion: 1.3, }, FitWindow: { defaultValue: false, value: false, type: 'boolean', explicitSet: false, valueSet: [true, false], pdfVersion: 1.3, }, CenterWindow: { defaultValue: false, value: false, type: 'boolean', explicitSet: false, valueSet: [true, false], pdfVersion: 1.3, }, DisplayDocTitle: { defaultValue: false, value: false, type: 'boolean', explicitSet: false, valueSet: [true, false], pdfVersion: 1.4, }, NonFullScreenPageMode: { defaultValue: 'UseNone', value: 'UseNone', type: 'name', explicitSet: false, valueSet: ['UseNone', 'UseOutlines', 'UseThumbs', 'UseOC'], pdfVersion: 1.3, }, Direction: { defaultValue: 'L2R', value: 'L2R', type: 'name', explicitSet: false, valueSet: ['L2R', 'R2L'], pdfVersion: 1.3, }, ViewArea: { defaultValue: 'CropBox', value: 'CropBox', type: 'name', explicitSet: false, valueSet: ['MediaBox', 'CropBox', 'TrimBox', 'BleedBox', 'ArtBox'], pdfVersion: 1.4, }, ViewClip: { defaultValue: 'CropBox', value: 'CropBox', type: 'name', explicitSet: false, valueSet: ['MediaBox', 'CropBox', 'TrimBox', 'BleedBox', 'ArtBox'], pdfVersion: 1.4, }, PrintArea: { defaultValue: 'CropBox', value: 'CropBox', type: 'name', explicitSet: false, valueSet: ['MediaBox', 'CropBox', 'TrimBox', 'BleedBox', 'ArtBox'], pdfVersion: 1.4, }, PrintClip: { defaultValue: 'CropBox', value: 'CropBox', type: 'name', explicitSet: false, valueSet: ['MediaBox', 'CropBox', 'TrimBox', 'BleedBox', 'ArtBox'], pdfVersion: 1.4, }, PrintScaling: { defaultValue: 'AppDefault', value: 'AppDefault', type: 'name', explicitSet: false, valueSet: ['AppDefault', 'None'], pdfVersion: 1.6, }, Duplex: { defaultValue: '', value: 'none', type: 'name', explicitSet: false, valueSet: [ 'Simplex', 'DuplexFlipShortEdge', 'DuplexFlipLongEdge', 'none', ], pdfVersion: 1.7, }, PickTrayByPDFSize: { defaultValue: false, value: false, type: 'boolean', explicitSet: false, valueSet: [true, false], pdfVersion: 1.7, }, PrintPageRange: { defaultValue: '', value: '', type: 'array', explicitSet: false, valueSet: null, pdfVersion: 1.7, }, NumCopies: { defaultValue: 1, value: 1, type: 'integer', explicitSet: false, valueSet: null, pdfVersion: 1.7, }, }, c2 = Object.keys(s2), u2 = [], h2 = 0, l2 = 0, f2 = 0 function d3(t3, e3) { var r3, n3 = false for (r3 = 0; r3 < t3.length; r3 += 1) t3[r3] === e3 && (n3 = true) return n3 } if ( (void 0 === this.internal.viewerpreferences && ((this.internal.viewerpreferences = {}), (this.internal.viewerpreferences.configuration = JSON.parse( JSON.stringify(s2) )), (this.internal.viewerpreferences.isSubscribed = false)), (n2 = this.internal.viewerpreferences.configuration), 'reset' === e2 || true === r2) ) { var p2 = c2.length for (f2 = 0; f2 < p2; f2 += 1) (n2[c2[f2]].value = n2[c2[f2]].defaultValue), (n2[c2[f2]].explicitSet = false) } if ('object' === _typeof$3(e2)) { for (a2 in e2) if (((o2 = e2[a2]), d3(c2, a2) && void 0 !== o2)) { if ('boolean' === n2[a2].type && 'boolean' == typeof o2) n2[a2].value = o2 else if ('name' === n2[a2].type && d3(n2[a2].valueSet, o2)) n2[a2].value = o2 else if ('integer' === n2[a2].type && Number.isInteger(o2)) n2[a2].value = o2 else if ('array' === n2[a2].type) { for (h2 = 0; h2 < o2.length; h2 += 1) if ( ((i2 = true), 1 === o2[h2].length && 'number' == typeof o2[h2][0]) ) u2.push(String(o2[h2] - 1)) else if (o2[h2].length > 1) { for (l2 = 0; l2 < o2[h2].length; l2 += 1) 'number' != typeof o2[h2][l2] && (i2 = false) true === i2 && u2.push([o2[h2][0] - 1, o2[h2][1] - 1].join(' ')) } n2[a2].value = '[' + u2.join(' ') + ']' } else n2[a2].value = n2[a2].defaultValue n2[a2].explicitSet = true } } return ( false === this.internal.viewerpreferences.isSubscribed && (this.internal.events.subscribe('putCatalog', function () { var t3, e3 = [] for (t3 in n2) true === n2[t3].explicitSet && ('name' === n2[t3].type ? e3.push('/' + t3 + ' /' + n2[t3].value) : e3.push('/' + t3 + ' ' + n2[t3].value)) 0 !== e3.length && this.internal.write( '/ViewerPreferences\n<<\n' + e3.join('\n') + '\n>>' ) }), (this.internal.viewerpreferences.isSubscribed = true)), (this.internal.viewerpreferences.configuration = n2), this ) }), (function (t3) { var e2 = function () { var t4 = '', e3 = unescape( encodeURIComponent('') ), r3 = unescape(encodeURIComponent(t4)), n2 = unescape( encodeURIComponent(this.internal.__metadata__.metadata) ), i2 = unescape( encodeURIComponent('') ), a2 = unescape(encodeURIComponent('')), o2 = r3.length + n2.length + i2.length + e3.length + a2.length ;(this.internal.__metadata__.metadata_object_number = this.internal.newObject()), this.internal.write( '<< /Type /Metadata /Subtype /XML /Length ' + o2 + ' >>' ), this.internal.write('stream'), this.internal.write(e3 + r3 + n2 + i2 + a2), this.internal.write('endstream'), this.internal.write('endobj') }, r2 = function () { this.internal.__metadata__.metadata_object_number && this.internal.write( '/Metadata ' + this.internal.__metadata__.metadata_object_number + ' 0 R' ) } t3.addMetadata = function (t4, n2) { return ( void 0 === this.internal.__metadata__ && ((this.internal.__metadata__ = { metadata: t4, namespaceuri: n2 || 'http://jspdf.default.namespaceuri/', }), this.internal.events.subscribe('putCatalog', r2), this.internal.events.subscribe('postPutResources', e2)), this ) } })(E$1.API), (function (t3) { var e2 = t3.API, r2 = (e2.pdfEscape16 = function (t4, e3) { for ( var r3, n3 = e3.metadata.Unicode.widths, i3 = ['', '0', '00', '000', '0000'], a2 = [''], o2 = 0, s2 = t4.length; o2 < s2; ++o2 ) { if ( ((r3 = e3.metadata.characterToGlyph(t4.charCodeAt(o2))), e3.metadata.glyIdsUsed.push(r3), (e3.metadata.toUnicode[r3] = t4.charCodeAt(o2)), -1 == n3.indexOf(r3) && (n3.push(r3), n3.push([parseInt(e3.metadata.widthOfGlyph(r3), 10)])), '0' == r3) ) return a2.join('') ;(r3 = r3.toString(16)), a2.push(i3[4 - r3.length], r3) } return a2.join('') }), n2 = function (t4) { var e3, r3, n3, i3, a2, o2, s2 for ( a2 = '/CIDInit /ProcSet findresource begin\n12 dict begin\nbegincmap\n/CIDSystemInfo <<\n /Registry (Adobe)\n /Ordering (UCS)\n /Supplement 0\n>> def\n/CMapName /Adobe-Identity-UCS def\n/CMapType 2 def\n1 begincodespacerange\n<0000>\nendcodespacerange', n3 = [], o2 = 0, s2 = (r3 = Object.keys(t4).sort(function (t5, e4) { return t5 - e4 })).length; o2 < s2; o2++ ) (e3 = r3[o2]), n3.length >= 100 && ((a2 += '\n' + n3.length + ' beginbfchar\n' + n3.join('\n') + '\nendbfchar'), (n3 = [])), void 0 !== t4[e3] && null !== t4[e3] && 'function' == typeof t4[e3].toString && ((i3 = ('0000' + t4[e3].toString(16)).slice(-4)), (e3 = ('0000' + (+e3).toString(16)).slice(-4)), n3.push('<' + e3 + '><' + i3 + '>')) return ( n3.length && (a2 += '\n' + n3.length + ' beginbfchar\n' + n3.join('\n') + '\nendbfchar\n'), (a2 += 'endcmap\nCMapName currentdict /CMap defineresource pop\nend\nend') ) } e2.events.push([ 'putFont', function (e3) { !(function (e4) { var r3 = e4.font, i3 = e4.out, a2 = e4.newObject, o2 = e4.putStream if ( r3.metadata instanceof t3.API.TTFFont && 'Identity-H' === r3.encoding ) { for ( var s2 = r3.metadata.Unicode.widths, c2 = r3.metadata.subset.encode(r3.metadata.glyIdsUsed, 1), u2 = '', h2 = 0; h2 < c2.length; h2++ ) u2 += String.fromCharCode(c2[h2]) var l2 = a2() o2({ data: u2, addLength1: true, objectId: l2 }), i3('endobj') var f2 = a2() o2({ data: n2(r3.metadata.toUnicode), addLength1: true, objectId: f2, }), i3('endobj') var d3 = a2() i3('<<'), i3('/Type /FontDescriptor'), i3('/FontName /' + F$1(r3.fontName)), i3('/FontFile2 ' + l2 + ' 0 R'), i3('/FontBBox ' + t3.API.PDFObject.convert(r3.metadata.bbox)), i3('/Flags ' + r3.metadata.flags), i3('/StemV ' + r3.metadata.stemV), i3('/ItalicAngle ' + r3.metadata.italicAngle), i3('/Ascent ' + r3.metadata.ascender), i3('/Descent ' + r3.metadata.decender), i3('/CapHeight ' + r3.metadata.capHeight), i3('>>'), i3('endobj') var p2 = a2() i3('<<'), i3('/Type /Font'), i3('/BaseFont /' + F$1(r3.fontName)), i3('/FontDescriptor ' + d3 + ' 0 R'), i3('/W ' + t3.API.PDFObject.convert(s2)), i3('/CIDToGIDMap /Identity'), i3('/DW 1000'), i3('/Subtype /CIDFontType2'), i3('/CIDSystemInfo'), i3('<<'), i3('/Supplement 0'), i3('/Registry (Adobe)'), i3('/Ordering (' + r3.encoding + ')'), i3('>>'), i3('>>'), i3('endobj'), (r3.objectNumber = a2()), i3('<<'), i3('/Type /Font'), i3('/Subtype /Type0'), i3('/ToUnicode ' + f2 + ' 0 R'), i3('/BaseFont /' + F$1(r3.fontName)), i3('/Encoding /' + r3.encoding), i3('/DescendantFonts [' + p2 + ' 0 R]'), i3('>>'), i3('endobj'), (r3.isAlreadyPutted = true) } })(e3) }, ]) e2.events.push([ 'putFont', function (e3) { !(function (e4) { var r3 = e4.font, i3 = e4.out, a2 = e4.newObject, o2 = e4.putStream if ( r3.metadata instanceof t3.API.TTFFont && 'WinAnsiEncoding' === r3.encoding ) { for ( var s2 = r3.metadata.rawData, c2 = '', u2 = 0; u2 < s2.length; u2++ ) c2 += String.fromCharCode(s2[u2]) var h2 = a2() o2({ data: c2, addLength1: true, objectId: h2 }), i3('endobj') var l2 = a2() o2({ data: n2(r3.metadata.toUnicode), addLength1: true, objectId: l2, }), i3('endobj') var f2 = a2() i3('<<'), i3('/Descent ' + r3.metadata.decender), i3('/CapHeight ' + r3.metadata.capHeight), i3('/StemV ' + r3.metadata.stemV), i3('/Type /FontDescriptor'), i3('/FontFile2 ' + h2 + ' 0 R'), i3('/Flags 96'), i3('/FontBBox ' + t3.API.PDFObject.convert(r3.metadata.bbox)), i3('/FontName /' + F$1(r3.fontName)), i3('/ItalicAngle ' + r3.metadata.italicAngle), i3('/Ascent ' + r3.metadata.ascender), i3('>>'), i3('endobj'), (r3.objectNumber = a2()) for (var d3 = 0; d3 < r3.metadata.hmtx.widths.length; d3++) r3.metadata.hmtx.widths[d3] = parseInt( r3.metadata.hmtx.widths[d3] * (1e3 / r3.metadata.head.unitsPerEm) ) i3( '<>' ), i3('endobj'), (r3.isAlreadyPutted = true) } })(e3) }, ]) var i2 = function (t4) { var e3, n3 = t4.text || '', i3 = t4.x, a2 = t4.y, o2 = t4.options || {}, s2 = t4.mutex || {}, c2 = s2.pdfEscape, u2 = s2.activeFontKey, h2 = s2.fonts, l2 = u2, f2 = '', d3 = 0, p2 = '', g2 = h2[l2].encoding if ('Identity-H' !== h2[l2].encoding) return { text: n3, x: i3, y: a2, options: o2, mutex: s2 } for ( p2 = n3, l2 = u2, Array.isArray(n3) && (p2 = n3[0]), d3 = 0; d3 < p2.length; d3 += 1 ) h2[l2].metadata.hasOwnProperty('cmap') && (e3 = h2[l2].metadata.cmap.unicode.codeMap[p2[d3].charCodeAt(0)]), e3 || (p2[d3].charCodeAt(0) < 256 && h2[l2].metadata.hasOwnProperty('Unicode')) ? (f2 += p2[d3]) : (f2 += '') var m2 = '' return ( parseInt(l2.slice(1)) < 14 || 'WinAnsiEncoding' === g2 ? (m2 = c2(f2, l2) .split('') .map(function (t5) { return t5.charCodeAt(0).toString(16) }) .join('')) : 'Identity-H' === g2 && (m2 = r2(f2, h2[l2])), (s2.isHex = true), { text: m2, x: i3, y: a2, options: o2, mutex: s2 } ) } e2.events.push([ 'postProcessText', function (t4) { var e3 = t4.text || '', r3 = [], n3 = { text: e3, x: t4.x, y: t4.y, options: t4.options, mutex: t4.mutex, } if (Array.isArray(e3)) { var a2 = 0 for (a2 = 0; a2 < e3.length; a2 += 1) Array.isArray(e3[a2]) && 3 === e3[a2].length ? r3.push([ i2(Object.assign({}, n3, { text: e3[a2][0] })).text, e3[a2][1], e3[a2][2], ]) : r3.push(i2(Object.assign({}, n3, { text: e3[a2] })).text) t4.text = r3 } else t4.text = i2(Object.assign({}, n3, { text: e3 })).text }, ]) })(E$1), (function (t3) { var e2 = function () { return void 0 === this.internal.vFS && (this.internal.vFS = {}), true } ;(t3.existsFileInVFS = function (t4) { return e2.call(this), void 0 !== this.internal.vFS[t4] }), (t3.addFileToVFS = function (t4, r2) { return e2.call(this), (this.internal.vFS[t4] = r2), this }), (t3.getFileFromVFS = function (t4) { return ( e2.call(this), void 0 !== this.internal.vFS[t4] ? this.internal.vFS[t4] : null ) }) })(E$1.API), (function (t3) { t3.__bidiEngine__ = t3.prototype.__bidiEngine__ = function (t4) { var r3, n2, i2, a2, o2, s2, c2, u2 = e2, h2 = [ [0, 3, 0, 1, 0, 0, 0], [0, 3, 0, 1, 2, 2, 0], [0, 3, 0, 17, 2, 0, 1], [0, 3, 5, 5, 4, 1, 0], [0, 3, 21, 21, 4, 0, 1], [0, 3, 5, 5, 4, 2, 0], ], l2 = [ [2, 0, 1, 1, 0, 1, 0], [2, 0, 1, 1, 0, 2, 0], [2, 0, 2, 1, 3, 2, 0], [2, 0, 2, 33, 3, 1, 1], ], f2 = { L: 0, R: 1, EN: 2, AN: 3, N: 4, B: 5, S: 6 }, d3 = { 0: 0, 5: 1, 6: 2, 7: 3, 32: 4, 251: 5, 254: 6, 255: 7 }, p2 = [ '(', ')', '(', '<', '>', '<', '[', ']', '[', '{', '}', '{', '\xAB', '\xBB', '\xAB', '\u2039', '\u203A', '\u2039', '\u2045', '\u2046', '\u2045', '\u207D', '\u207E', '\u207D', '\u208D', '\u208E', '\u208D', '\u2264', '\u2265', '\u2264', '\u2329', '\u232A', '\u2329', '\uFE59', '\uFE5A', '\uFE59', '\uFE5B', '\uFE5C', '\uFE5B', '\uFE5D', '\uFE5E', '\uFE5D', '\uFE64', '\uFE65', '\uFE64', ], g2 = new RegExp( /^([1-4|9]|1[0-9]|2[0-9]|3[0168]|4[04589]|5[012]|7[78]|159|16[0-9]|17[0-2]|21[569]|22[03489]|250)$/ ), m2 = false, v4 = 0 this.__bidiEngine__ = {} var b2 = function (t5) { var e3 = t5.charCodeAt(), r4 = e3 >> 8, n3 = d3[r4] return void 0 !== n3 ? u2[256 * n3 + (255 & e3)] : 252 === r4 || 253 === r4 ? 'AL' : g2.test(r4) ? 'L' : 8 === r4 ? 'R' : 'N' }, y2 = function (t5) { for (var e3, r4 = 0; r4 < t5.length; r4++) { if ('L' === (e3 = b2(t5.charAt(r4)))) return false if ('R' === e3) return true } return false }, w2 = function (t5, e3, o3, s3) { var c3, u3, h3, l3, f3 = e3[s3] switch (f3) { case 'L': case 'R': m2 = false break case 'N': case 'AN': break case 'EN': m2 && (f3 = 'AN') break case 'AL': ;(m2 = true), (f3 = 'R') break case 'WS': f3 = 'N' break case 'CS': s3 < 1 || s3 + 1 >= e3.length || ('EN' !== (c3 = o3[s3 - 1]) && 'AN' !== c3) || ('EN' !== (u3 = e3[s3 + 1]) && 'AN' !== u3) ? (f3 = 'N') : m2 && (u3 = 'AN'), (f3 = u3 === c3 ? u3 : 'N') break case 'ES': f3 = 'EN' === (c3 = s3 > 0 ? o3[s3 - 1] : 'B') && s3 + 1 < e3.length && 'EN' === e3[s3 + 1] ? 'EN' : 'N' break case 'ET': if (s3 > 0 && 'EN' === o3[s3 - 1]) { f3 = 'EN' break } if (m2) { f3 = 'N' break } for (h3 = s3 + 1, l3 = e3.length; h3 < l3 && 'ET' === e3[h3]; ) h3++ f3 = h3 < l3 && 'EN' === e3[h3] ? 'EN' : 'N' break case 'NSM': if (i2 && !a2) { for (l3 = e3.length, h3 = s3 + 1; h3 < l3 && 'NSM' === e3[h3]; ) h3++ if (h3 < l3) { var d4 = t5[s3], p3 = (d4 >= 1425 && d4 <= 2303) || 64286 === d4 if (((c3 = e3[h3]), p3 && ('R' === c3 || 'AL' === c3))) { f3 = 'R' break } } } f3 = s3 < 1 || 'B' === (c3 = e3[s3 - 1]) ? 'N' : o3[s3 - 1] break case 'B': ;(m2 = false), (r3 = true), (f3 = v4) break case 'S': ;(n2 = true), (f3 = 'N') break case 'LRE': case 'RLE': case 'LRO': case 'RLO': case 'PDF': m2 = false break case 'BN': f3 = 'N' } return f3 }, N2 = function (t5, e3, r4) { var n3 = t5.split('') return ( r4 && L2(n3, r4, { hiLevel: v4 }), n3.reverse(), e3 && e3.reverse(), n3.join('') ) }, L2 = function (t5, e3, i3) { var a3, o3, s3, c3, u3, d4 = -1, p3 = t5.length, g3 = 0, y3 = [], N3 = v4 ? l2 : h2, L3 = [] for (m2 = false, r3 = false, n2 = false, o3 = 0; o3 < p3; o3++) L3[o3] = b2(t5[o3]) for (s3 = 0; s3 < p3; s3++) { if ( ((u3 = g3), (y3[s3] = w2(t5, L3, y3, s3)), (a3 = 240 & (g3 = N3[u3][f2[y3[s3]]])), (g3 &= 15), (e3[s3] = c3 = N3[g3][5]), a3 > 0) ) if (16 === a3) { for (o3 = d4; o3 < s3; o3++) e3[o3] = 1 d4 = -1 } else d4 = -1 if (N3[g3][6]) -1 === d4 && (d4 = s3) else if (d4 > -1) { for (o3 = d4; o3 < s3; o3++) e3[o3] = c3 d4 = -1 } 'B' === L3[s3] && (e3[s3] = 0), (i3.hiLevel |= c3) } n2 && (function (t6, e4, r4) { for (var n3 = 0; n3 < r4; n3++) if ('S' === t6[n3]) { e4[n3] = v4 for (var i4 = n3 - 1; i4 >= 0 && 'WS' === t6[i4]; i4--) e4[i4] = v4 } })(L3, e3, p3) }, A2 = function (t5, e3, n3, i3, a3) { if (!(a3.hiLevel < t5)) { if (1 === t5 && 1 === v4 && !r3) return e3.reverse(), void (n3 && n3.reverse()) for (var o3, s3, c3, u3, h3 = e3.length, l3 = 0; l3 < h3; ) { if (i3[l3] >= t5) { for (c3 = l3 + 1; c3 < h3 && i3[c3] >= t5; ) c3++ for (u3 = l3, s3 = c3 - 1; u3 < s3; u3++, s3--) (o3 = e3[u3]), (e3[u3] = e3[s3]), (e3[s3] = o3), n3 && ((o3 = n3[u3]), (n3[u3] = n3[s3]), (n3[s3] = o3)) l3 = c3 } l3++ } } }, x2 = function (t5, e3, r4) { var n3 = t5.split(''), i3 = { hiLevel: v4 } return ( r4 || (r4 = []), L2(n3, r4, i3), (function (t6, e4, r5) { if (0 !== r5.hiLevel && c2) for (var n4, i4 = 0; i4 < t6.length; i4++) 1 === e4[i4] && (n4 = p2.indexOf(t6[i4])) >= 0 && (t6[i4] = p2[n4 + 1]) })(n3, r4, i3), A2(2, n3, e3, r4, i3), A2(1, n3, e3, r4, i3), n3.join('') ) } return ( (this.__bidiEngine__.doBidiReorder = function (t5, e3, r4) { if ( ((function (t6, e4) { if (e4) for (var r5 = 0; r5 < t6.length; r5++) e4[r5] = r5 void 0 === a2 && (a2 = y2(t6)), void 0 === s2 && (s2 = y2(t6)) })(t5, e3), i2 || !o2 || s2) ) if (i2 && o2 && a2 ^ s2) (v4 = a2 ? 1 : 0), (t5 = N2(t5, e3, r4)) else if (!i2 && o2 && s2) (v4 = a2 ? 1 : 0), (t5 = x2(t5, e3, r4)), (t5 = N2(t5, e3)) else if (!i2 || a2 || o2 || s2) { if (i2 && !o2 && a2 ^ s2) (t5 = N2(t5, e3)), a2 ? ((v4 = 0), (t5 = x2(t5, e3, r4))) : ((v4 = 1), (t5 = x2(t5, e3, r4)), (t5 = N2(t5, e3))) else if (i2 && a2 && !o2 && s2) (v4 = 1), (t5 = x2(t5, e3, r4)), (t5 = N2(t5, e3)) else if (!i2 && !o2 && a2 ^ s2) { var n3 = c2 a2 ? ((v4 = 1), (t5 = x2(t5, e3, r4)), (v4 = 0), (c2 = false), (t5 = x2(t5, e3, r4)), (c2 = n3)) : ((v4 = 0), (t5 = x2(t5, e3, r4)), (t5 = N2(t5, e3)), (v4 = 1), (c2 = false), (t5 = x2(t5, e3, r4)), (c2 = n3), (t5 = N2(t5, e3))) } } else (v4 = 0), (t5 = x2(t5, e3, r4)) else (v4 = a2 ? 1 : 0), (t5 = x2(t5, e3, r4)) return t5 }), (this.__bidiEngine__.setOptions = function (t5) { t5 && ((i2 = t5.isInputVisual), (o2 = t5.isOutputVisual), (a2 = t5.isInputRtl), (s2 = t5.isOutputRtl), (c2 = t5.isSymmetricSwapping)) }), this.__bidiEngine__.setOptions(t4), this.__bidiEngine__ ) } var e2 = [ 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'S', 'B', 'S', 'WS', 'B', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'B', 'B', 'B', 'S', 'WS', 'N', 'N', 'ET', 'ET', 'ET', 'N', 'N', 'N', 'N', 'N', 'ES', 'CS', 'ES', 'CS', 'CS', 'EN', 'EN', 'EN', 'EN', 'EN', 'EN', 'EN', 'EN', 'EN', 'EN', 'CS', 'N', 'N', 'N', 'N', 'N', 'N', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'N', 'N', 'N', 'N', 'N', 'N', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'N', 'N', 'N', 'N', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'B', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'CS', 'N', 'ET', 'ET', 'ET', 'ET', 'N', 'N', 'N', 'N', 'L', 'N', 'N', 'BN', 'N', 'N', 'ET', 'ET', 'EN', 'EN', 'N', 'L', 'N', 'N', 'N', 'EN', 'L', 'N', 'N', 'N', 'N', 'N', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'N', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'N', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'N', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'N', 'N', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'N', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'N', 'L', 'N', 'N', 'N', 'N', 'N', 'ET', 'N', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'R', 'NSM', 'R', 'NSM', 'NSM', 'R', 'NSM', 'NSM', 'R', 'NSM', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'N', 'N', 'N', 'N', 'N', 'R', 'R', 'R', 'R', 'R', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'AN', 'AN', 'AN', 'AN', 'AN', 'AN', 'N', 'N', 'AL', 'ET', 'ET', 'AL', 'CS', 'AL', 'N', 'N', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'AL', 'AL', 'N', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'AN', 'AN', 'AN', 'AN', 'AN', 'AN', 'AN', 'AN', 'AN', 'AN', 'ET', 'AN', 'AN', 'AL', 'AL', 'AL', 'NSM', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'AN', 'N', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'AL', 'AL', 'NSM', 'NSM', 'N', 'NSM', 'NSM', 'NSM', 'NSM', 'AL', 'AL', 'EN', 'EN', 'EN', 'EN', 'EN', 'EN', 'EN', 'EN', 'EN', 'EN', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'N', 'AL', 'AL', 'NSM', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'N', 'N', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'AL', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'R', 'R', 'N', 'N', 'N', 'N', 'R', 'N', 'N', 'N', 'N', 'N', 'WS', 'WS', 'WS', 'WS', 'WS', 'WS', 'WS', 'WS', 'WS', 'WS', 'WS', 'BN', 'BN', 'BN', 'L', 'R', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'WS', 'B', 'LRE', 'RLE', 'PDF', 'LRO', 'RLO', 'CS', 'ET', 'ET', 'ET', 'ET', 'ET', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'CS', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'WS', 'BN', 'BN', 'BN', 'BN', 'BN', 'N', 'LRI', 'RLI', 'FSI', 'PDI', 'BN', 'BN', 'BN', 'BN', 'BN', 'BN', 'EN', 'L', 'N', 'N', 'EN', 'EN', 'EN', 'EN', 'EN', 'EN', 'ES', 'ES', 'N', 'N', 'N', 'L', 'EN', 'EN', 'EN', 'EN', 'EN', 'EN', 'EN', 'EN', 'EN', 'EN', 'ES', 'ES', 'N', 'N', 'N', 'N', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'N', 'N', 'N', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'ET', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'L', 'L', 'L', 'L', 'L', 'N', 'N', 'N', 'N', 'N', 'R', 'NSM', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'ES', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'N', 'R', 'R', 'R', 'R', 'R', 'N', 'R', 'N', 'R', 'R', 'N', 'R', 'R', 'N', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'R', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'NSM', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'CS', 'N', 'CS', 'N', 'N', 'CS', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'ET', 'N', 'N', 'ES', 'ES', 'N', 'N', 'N', 'N', 'N', 'ET', 'ET', 'N', 'N', 'N', 'N', 'N', 'AL', 'AL', 'AL', 'AL', 'AL', 'N', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'AL', 'N', 'N', 'BN', 'N', 'N', 'N', 'ET', 'ET', 'ET', 'N', 'N', 'N', 'N', 'N', 'ES', 'CS', 'ES', 'CS', 'CS', 'EN', 'EN', 'EN', 'EN', 'EN', 'EN', 'EN', 'EN', 'EN', 'EN', 'CS', 'N', 'N', 'N', 'N', 'N', 'N', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'N', 'N', 'N', 'N', 'N', 'N', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'L', 'N', 'N', 'N', 'L', 'L', 'L', 'L', 'L', 'L', 'N', 'N', 'L', 'L', 'L', 'L', 'L', 'L', 'N', 'N', 'L', 'L', 'L', 'L', 'L', 'L', 'N', 'N', 'L', 'L', 'L', 'N', 'N', 'N', 'ET', 'ET', 'N', 'N', 'N', 'ET', 'ET', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', 'N', ], r2 = new t3.__bidiEngine__({ isInputVisual: true }) t3.API.events.push([ 'postProcessText', function (t4) { var e3 = t4.text, n2 = (t4.x, t4.y, t4.options || {}), i2 = (t4.mutex, n2.lang, []) if ( ((n2.isInputVisual = 'boolean' != typeof n2.isInputVisual || n2.isInputVisual), r2.setOptions(n2), '[object Array]' === Object.prototype.toString.call(e3)) ) { var a2 = 0 for (i2 = [], a2 = 0; a2 < e3.length; a2 += 1) '[object Array]' === Object.prototype.toString.call(e3[a2]) ? i2.push([r2.doBidiReorder(e3[a2][0]), e3[a2][1], e3[a2][2]]) : i2.push([r2.doBidiReorder(e3[a2])]) t4.text = i2 } else t4.text = r2.doBidiReorder(e3) r2.setOptions({ isInputVisual: true }) }, ]) })(E$1), (E$1.API.TTFFont = (function () { function t3(t4) { var e2 if ( ((this.rawData = t4), (e2 = this.contents = new ne(t4)), (this.contents.pos = 4), 'ttcf' === e2.readString(4)) ) throw new Error('TTCF not supported.') ;(e2.pos = 0), this.parse(), (this.subset = new Le(this)), this.registerTTF() } return ( (t3.open = function (e2) { return new t3(e2) }), (t3.prototype.parse = function () { return ( (this.directory = new ie(this.contents)), (this.head = new se(this)), (this.name = new pe(this)), (this.cmap = new ue(this)), (this.toUnicode = {}), (this.hhea = new he(this)), (this.maxp = new ge(this)), (this.hmtx = new me(this)), (this.post = new fe(this)), (this.os2 = new le(this)), (this.loca = new Ne(this)), (this.glyf = new be(this)), (this.ascender = (this.os2.exists && this.os2.ascender) || this.hhea.ascender), (this.decender = (this.os2.exists && this.os2.decender) || this.hhea.decender), (this.lineGap = (this.os2.exists && this.os2.lineGap) || this.hhea.lineGap), (this.bbox = [ this.head.xMin, this.head.yMin, this.head.xMax, this.head.yMax, ]) ) }), (t3.prototype.registerTTF = function () { var t4, e2, r2, n2, i2 if ( ((this.scaleFactor = 1e3 / this.head.unitsPerEm), (this.bbox = function () { var e3, r3, n3, i3 for (i3 = [], e3 = 0, r3 = (n3 = this.bbox).length; e3 < r3; e3++) (t4 = n3[e3]), i3.push(Math.round(t4 * this.scaleFactor)) return i3 }.call(this)), (this.stemV = 0), this.post.exists ? ((r2 = 255 & (n2 = this.post.italic_angle)), 0 != (32768 & (e2 = n2 >> 16)) && (e2 = -(1 + (65535 ^ e2))), (this.italicAngle = +(e2 + '.' + r2))) : (this.italicAngle = 0), (this.ascender = Math.round(this.ascender * this.scaleFactor)), (this.decender = Math.round(this.decender * this.scaleFactor)), (this.lineGap = Math.round(this.lineGap * this.scaleFactor)), (this.capHeight = (this.os2.exists && this.os2.capHeight) || this.ascender), (this.xHeight = (this.os2.exists && this.os2.xHeight) || 0), (this.familyClass = ((this.os2.exists && this.os2.familyClass) || 0) >> 8), (this.isSerif = 1 === (i2 = this.familyClass) || 2 === i2 || 3 === i2 || 4 === i2 || 5 === i2 || 7 === i2), (this.isScript = 10 === this.familyClass), (this.flags = 0), this.post.isFixedPitch && (this.flags |= 1), this.isSerif && (this.flags |= 2), this.isScript && (this.flags |= 8), 0 !== this.italicAngle && (this.flags |= 64), (this.flags |= 32), !this.cmap.unicode) ) throw new Error('No unicode cmap for font') }), (t3.prototype.characterToGlyph = function (t4) { var e2 return (null != (e2 = this.cmap.unicode) ? e2.codeMap[t4] : void 0) || 0 }), (t3.prototype.widthOfGlyph = function (t4) { var e2 return ( (e2 = 1e3 / this.head.unitsPerEm), this.hmtx.forGlyph(t4).advance * e2 ) }), (t3.prototype.widthOfString = function (t4, e2, r2) { var n2, i2, a2, o2 for ( a2 = 0, i2 = 0, o2 = (t4 = '' + t4).length; 0 <= o2 ? i2 < o2 : i2 > o2; i2 = 0 <= o2 ? ++i2 : --i2 ) (n2 = t4.charCodeAt(i2)), (a2 += this.widthOfGlyph(this.characterToGlyph(n2)) + r2 * (1e3 / e2) || 0) return a2 * (e2 / 1e3) }), (t3.prototype.lineHeight = function (t4, e2) { var r2 return ( null == e2 && (e2 = false), (r2 = e2 ? this.lineGap : 0), ((this.ascender + r2 - this.decender) / 1e3) * t4 ) }), t3 ) })()) var re, ne = (function () { function t3(t4) { ;(this.data = null != t4 ? t4 : []), (this.pos = 0), (this.length = this.data.length) } return ( (t3.prototype.readByte = function () { return this.data[this.pos++] }), (t3.prototype.writeByte = function (t4) { return (this.data[this.pos++] = t4) }), (t3.prototype.readUInt32 = function () { return ( 16777216 * this.readByte() + (this.readByte() << 16) + (this.readByte() << 8) + this.readByte() ) }), (t3.prototype.writeUInt32 = function (t4) { return ( this.writeByte((t4 >>> 24) & 255), this.writeByte((t4 >> 16) & 255), this.writeByte((t4 >> 8) & 255), this.writeByte(255 & t4) ) }), (t3.prototype.readInt32 = function () { var t4 return (t4 = this.readUInt32()) >= 2147483648 ? t4 - 4294967296 : t4 }), (t3.prototype.writeInt32 = function (t4) { return t4 < 0 && (t4 += 4294967296), this.writeUInt32(t4) }), (t3.prototype.readUInt16 = function () { return (this.readByte() << 8) | this.readByte() }), (t3.prototype.writeUInt16 = function (t4) { return this.writeByte((t4 >> 8) & 255), this.writeByte(255 & t4) }), (t3.prototype.readInt16 = function () { var t4 return (t4 = this.readUInt16()) >= 32768 ? t4 - 65536 : t4 }), (t3.prototype.writeInt16 = function (t4) { return t4 < 0 && (t4 += 65536), this.writeUInt16(t4) }), (t3.prototype.readString = function (t4) { var e2, r2 for ( r2 = [], e2 = 0; 0 <= t4 ? e2 < t4 : e2 > t4; e2 = 0 <= t4 ? ++e2 : --e2 ) r2[e2] = String.fromCharCode(this.readByte()) return r2.join('') }), (t3.prototype.writeString = function (t4) { var e2, r2, n2 for ( n2 = [], e2 = 0, r2 = t4.length; 0 <= r2 ? e2 < r2 : e2 > r2; e2 = 0 <= r2 ? ++e2 : --e2 ) n2.push(this.writeByte(t4.charCodeAt(e2))) return n2 }), (t3.prototype.readShort = function () { return this.readInt16() }), (t3.prototype.writeShort = function (t4) { return this.writeInt16(t4) }), (t3.prototype.readLongLong = function () { var t4, e2, r2, n2, i2, a2, o2, s2 return ( (t4 = this.readByte()), (e2 = this.readByte()), (r2 = this.readByte()), (n2 = this.readByte()), (i2 = this.readByte()), (a2 = this.readByte()), (o2 = this.readByte()), (s2 = this.readByte()), 128 & t4 ? -1 * (72057594037927940 * (255 ^ t4) + 281474976710656 * (255 ^ e2) + 1099511627776 * (255 ^ r2) + 4294967296 * (255 ^ n2) + 16777216 * (255 ^ i2) + 65536 * (255 ^ a2) + 256 * (255 ^ o2) + (255 ^ s2) + 1) : 72057594037927940 * t4 + 281474976710656 * e2 + 1099511627776 * r2 + 4294967296 * n2 + 16777216 * i2 + 65536 * a2 + 256 * o2 + s2 ) }), (t3.prototype.writeLongLong = function (t4) { var e2, r2 return ( (e2 = Math.floor(t4 / 4294967296)), (r2 = 4294967295 & t4), this.writeByte((e2 >> 24) & 255), this.writeByte((e2 >> 16) & 255), this.writeByte((e2 >> 8) & 255), this.writeByte(255 & e2), this.writeByte((r2 >> 24) & 255), this.writeByte((r2 >> 16) & 255), this.writeByte((r2 >> 8) & 255), this.writeByte(255 & r2) ) }), (t3.prototype.readInt = function () { return this.readInt32() }), (t3.prototype.writeInt = function (t4) { return this.writeInt32(t4) }), (t3.prototype.read = function (t4) { var e2, r2 for ( e2 = [], r2 = 0; 0 <= t4 ? r2 < t4 : r2 > t4; r2 = 0 <= t4 ? ++r2 : --r2 ) e2.push(this.readByte()) return e2 }), (t3.prototype.write = function (t4) { var e2, r2, n2, i2 for (i2 = [], r2 = 0, n2 = t4.length; r2 < n2; r2++) (e2 = t4[r2]), i2.push(this.writeByte(e2)) return i2 }), t3 ) })(), ie = (function () { var t3 function e2(t4) { var e3, r2, n2 for ( this.scalarType = t4.readInt(), this.tableCount = t4.readShort(), this.searchRange = t4.readShort(), this.entrySelector = t4.readShort(), this.rangeShift = t4.readShort(), this.tables = {}, r2 = 0, n2 = this.tableCount; 0 <= n2 ? r2 < n2 : r2 > n2; r2 = 0 <= n2 ? ++r2 : --r2 ) (e3 = { tag: t4.readString(4), checksum: t4.readInt(), offset: t4.readInt(), length: t4.readInt(), }), (this.tables[e3.tag] = e3) } return ( (e2.prototype.encode = function (e3) { var r2, n2, i2, a2, o2, s2, c2, u2, h2, l2, f2, d3, p2 for (p2 in ((f2 = Object.keys(e3).length), (s2 = Math.log(2)), (h2 = 16 * Math.floor(Math.log(f2) / s2)), (a2 = Math.floor(h2 / s2)), (u2 = 16 * f2 - h2), (n2 = new ne()).writeInt(this.scalarType), n2.writeShort(f2), n2.writeShort(h2), n2.writeShort(a2), n2.writeShort(u2), (i2 = 16 * f2), (c2 = n2.pos + i2), (o2 = null), (d3 = []), e3)) for ( l2 = e3[p2], n2.writeString(p2), n2.writeInt(t3(l2)), n2.writeInt(c2), n2.writeInt(l2.length), d3 = d3.concat(l2), 'head' === p2 && (o2 = c2), c2 += l2.length; c2 % 4; ) d3.push(0), c2++ return ( n2.write(d3), (r2 = 2981146554 - t3(n2.data)), (n2.pos = o2 + 8), n2.writeUInt32(r2), n2.data ) }), (t3 = function (t4) { var e3, r2, n2, i2 for (t4 = ve.call(t4); t4.length % 4; ) t4.push(0) for ( n2 = new ne(t4), r2 = 0, e3 = 0, i2 = t4.length; e3 < i2; e3 = e3 += 4 ) r2 += n2.readUInt32() return 4294967295 & r2 }), e2 ) })(), ae = {}.hasOwnProperty, oe = function (t3, e2) { for (var r2 in e2) ae.call(e2, r2) && (t3[r2] = e2[r2]) function n2() { this.constructor = t3 } return ( (n2.prototype = e2.prototype), (t3.prototype = new n2()), (t3.__super__ = e2.prototype), t3 ) } re = (function () { function t3(t4) { var e2 ;(this.file = t4), (e2 = this.file.directory.tables[this.tag]), (this.exists = !!e2), e2 && ((this.offset = e2.offset), (this.length = e2.length), this.parse(this.file.contents)) } return ( (t3.prototype.parse = function () {}), (t3.prototype.encode = function () {}), (t3.prototype.raw = function () { return this.exists ? ((this.file.contents.pos = this.offset), this.file.contents.read(this.length)) : null }), t3 ) })() var se = (function (t3) { function e2() { return e2.__super__.constructor.apply(this, arguments) } return ( oe(e2, re), (e2.prototype.tag = 'head'), (e2.prototype.parse = function (t4) { return ( (t4.pos = this.offset), (this.version = t4.readInt()), (this.revision = t4.readInt()), (this.checkSumAdjustment = t4.readInt()), (this.magicNumber = t4.readInt()), (this.flags = t4.readShort()), (this.unitsPerEm = t4.readShort()), (this.created = t4.readLongLong()), (this.modified = t4.readLongLong()), (this.xMin = t4.readShort()), (this.yMin = t4.readShort()), (this.xMax = t4.readShort()), (this.yMax = t4.readShort()), (this.macStyle = t4.readShort()), (this.lowestRecPPEM = t4.readShort()), (this.fontDirectionHint = t4.readShort()), (this.indexToLocFormat = t4.readShort()), (this.glyphDataFormat = t4.readShort()) ) }), (e2.prototype.encode = function (t4) { var e3 return ( (e3 = new ne()).writeInt(this.version), e3.writeInt(this.revision), e3.writeInt(this.checkSumAdjustment), e3.writeInt(this.magicNumber), e3.writeShort(this.flags), e3.writeShort(this.unitsPerEm), e3.writeLongLong(this.created), e3.writeLongLong(this.modified), e3.writeShort(this.xMin), e3.writeShort(this.yMin), e3.writeShort(this.xMax), e3.writeShort(this.yMax), e3.writeShort(this.macStyle), e3.writeShort(this.lowestRecPPEM), e3.writeShort(this.fontDirectionHint), e3.writeShort(t4), e3.writeShort(this.glyphDataFormat), e3.data ) }), e2 ) })(), ce = (function () { function t3(t4, e2) { var r2, n2, i2, a2, o2, s2, c2, u2, h2, l2, f2, d3, p2, g2, m2, v4, b2 switch ( ((this.platformID = t4.readUInt16()), (this.encodingID = t4.readShort()), (this.offset = e2 + t4.readInt()), (h2 = t4.pos), (t4.pos = this.offset), (this.format = t4.readUInt16()), (this.length = t4.readUInt16()), (this.language = t4.readUInt16()), (this.isUnicode = (3 === this.platformID && 1 === this.encodingID && 4 === this.format) || (0 === this.platformID && 4 === this.format)), (this.codeMap = {}), this.format) ) { case 0: for (s2 = 0; s2 < 256; ++s2) this.codeMap[s2] = t4.readByte() break case 4: for ( f2 = t4.readUInt16(), l2 = f2 / 2, t4.pos += 6, i2 = (function () { var e3, r3 for ( r3 = [], s2 = e3 = 0; 0 <= l2 ? e3 < l2 : e3 > l2; s2 = 0 <= l2 ? ++e3 : --e3 ) r3.push(t4.readUInt16()) return r3 })(), t4.pos += 2, p2 = (function () { var e3, r3 for ( r3 = [], s2 = e3 = 0; 0 <= l2 ? e3 < l2 : e3 > l2; s2 = 0 <= l2 ? ++e3 : --e3 ) r3.push(t4.readUInt16()) return r3 })(), c2 = (function () { var e3, r3 for ( r3 = [], s2 = e3 = 0; 0 <= l2 ? e3 < l2 : e3 > l2; s2 = 0 <= l2 ? ++e3 : --e3 ) r3.push(t4.readUInt16()) return r3 })(), u2 = (function () { var e3, r3 for ( r3 = [], s2 = e3 = 0; 0 <= l2 ? e3 < l2 : e3 > l2; s2 = 0 <= l2 ? ++e3 : --e3 ) r3.push(t4.readUInt16()) return r3 })(), n2 = (this.length - t4.pos + this.offset) / 2, o2 = (function () { var e3, r3 for ( r3 = [], s2 = e3 = 0; 0 <= n2 ? e3 < n2 : e3 > n2; s2 = 0 <= n2 ? ++e3 : --e3 ) r3.push(t4.readUInt16()) return r3 })(), s2 = m2 = 0, b2 = i2.length; m2 < b2; s2 = ++m2 ) for ( g2 = i2[s2], r2 = v4 = d3 = p2[s2]; d3 <= g2 ? v4 <= g2 : v4 >= g2; r2 = d3 <= g2 ? ++v4 : --v4 ) 0 === u2[s2] ? (a2 = r2 + c2[s2]) : 0 !== (a2 = o2[u2[s2] / 2 + (r2 - d3) - (l2 - s2)] || 0) && (a2 += c2[s2]), (this.codeMap[r2] = 65535 & a2) } t4.pos = h2 } return ( (t3.encode = function (t4, e2) { var r2, n2, i2, a2, o2, s2, c2, u2, h2, l2, f2, d3, p2, g2, m2, v4, b2, y2, w2, N2, L2, A2, x2, S2, _2, P2, k2, I2, F2, C2, j2, O2, B3, M2, E2, q2, D2, R2, T2, U2, z2, H4, W2, V2, G2, Y2 switch ( ((I2 = new ne()), (a2 = Object.keys(t4).sort(function (t5, e3) { return t5 - e3 })), e2) ) { case 'macroman': for ( p2 = 0, g2 = (function () { var t5 = [] for (d3 = 0; d3 < 256; ++d3) t5.push(0) return t5 })(), v4 = { 0: 0 }, i2 = {}, F2 = 0, B3 = a2.length; F2 < B3; F2++ ) null == v4[(W2 = t4[(n2 = a2[F2])])] && (v4[W2] = ++p2), (i2[n2] = { old: t4[n2], new: v4[t4[n2]] }), (g2[n2] = v4[t4[n2]]) return ( I2.writeUInt16(1), I2.writeUInt16(0), I2.writeUInt32(12), I2.writeUInt16(0), I2.writeUInt16(262), I2.writeUInt16(0), I2.write(g2), { charMap: i2, subtable: I2.data, maxGlyphID: p2 + 1 } ) case 'unicode': for ( P2 = [], h2 = [], b2 = 0, v4 = {}, r2 = {}, m2 = c2 = null, C2 = 0, M2 = a2.length; C2 < M2; C2++ ) null == v4[(w2 = t4[(n2 = a2[C2])])] && (v4[w2] = ++b2), (r2[n2] = { old: w2, new: v4[w2] }), (o2 = v4[w2] - n2), (null != m2 && o2 === c2) || (m2 && h2.push(m2), P2.push(n2), (c2 = o2)), (m2 = n2) for ( m2 && h2.push(m2), h2.push(65535), P2.push(65535), S2 = 2 * (x2 = P2.length), A2 = 2 * Math.pow(Math.log(x2) / Math.LN2, 2), l2 = Math.log(A2 / 2) / Math.LN2, L2 = 2 * x2 - A2, s2 = [], N2 = [], f2 = [], d3 = j2 = 0, E2 = P2.length; j2 < E2; d3 = ++j2 ) { if (((_2 = P2[d3]), (u2 = h2[d3]), 65535 === _2)) { s2.push(0), N2.push(0) break } if (_2 - (k2 = r2[_2].new) >= 32768) for ( s2.push(0), N2.push(2 * (f2.length + x2 - d3)), n2 = O2 = _2; _2 <= u2 ? O2 <= u2 : O2 >= u2; n2 = _2 <= u2 ? ++O2 : --O2 ) f2.push(r2[n2].new) else s2.push(k2 - _2), N2.push(0) } for ( I2.writeUInt16(3), I2.writeUInt16(1), I2.writeUInt32(12), I2.writeUInt16(4), I2.writeUInt16(16 + 8 * x2 + 2 * f2.length), I2.writeUInt16(0), I2.writeUInt16(S2), I2.writeUInt16(A2), I2.writeUInt16(l2), I2.writeUInt16(L2), z2 = 0, q2 = h2.length; z2 < q2; z2++ ) (n2 = h2[z2]), I2.writeUInt16(n2) for (I2.writeUInt16(0), H4 = 0, D2 = P2.length; H4 < D2; H4++) (n2 = P2[H4]), I2.writeUInt16(n2) for (V2 = 0, R2 = s2.length; V2 < R2; V2++) (o2 = s2[V2]), I2.writeUInt16(o2) for (G2 = 0, T2 = N2.length; G2 < T2; G2++) (y2 = N2[G2]), I2.writeUInt16(y2) for (Y2 = 0, U2 = f2.length; Y2 < U2; Y2++) (p2 = f2[Y2]), I2.writeUInt16(p2) return { charMap: r2, subtable: I2.data, maxGlyphID: b2 + 1 } } }), t3 ) })(), ue = (function (t3) { function e2() { return e2.__super__.constructor.apply(this, arguments) } return ( oe(e2, re), (e2.prototype.tag = 'cmap'), (e2.prototype.parse = function (t4) { var e3, r2, n2 for ( t4.pos = this.offset, this.version = t4.readUInt16(), n2 = t4.readUInt16(), this.tables = [], this.unicode = null, r2 = 0; 0 <= n2 ? r2 < n2 : r2 > n2; r2 = 0 <= n2 ? ++r2 : --r2 ) (e3 = new ce(t4, this.offset)), this.tables.push(e3), e3.isUnicode && null == this.unicode && (this.unicode = e3) return true }), (e2.encode = function (t4, e3) { var r2, n2 return ( null == e3 && (e3 = 'macroman'), (r2 = ce.encode(t4, e3)), (n2 = new ne()).writeUInt16(0), n2.writeUInt16(1), (r2.table = n2.data.concat(r2.subtable)), r2 ) }), e2 ) })(), he = (function (t3) { function e2() { return e2.__super__.constructor.apply(this, arguments) } return ( oe(e2, re), (e2.prototype.tag = 'hhea'), (e2.prototype.parse = function (t4) { return ( (t4.pos = this.offset), (this.version = t4.readInt()), (this.ascender = t4.readShort()), (this.decender = t4.readShort()), (this.lineGap = t4.readShort()), (this.advanceWidthMax = t4.readShort()), (this.minLeftSideBearing = t4.readShort()), (this.minRightSideBearing = t4.readShort()), (this.xMaxExtent = t4.readShort()), (this.caretSlopeRise = t4.readShort()), (this.caretSlopeRun = t4.readShort()), (this.caretOffset = t4.readShort()), (t4.pos += 8), (this.metricDataFormat = t4.readShort()), (this.numberOfMetrics = t4.readUInt16()) ) }), e2 ) })(), le = (function (t3) { function e2() { return e2.__super__.constructor.apply(this, arguments) } return ( oe(e2, re), (e2.prototype.tag = 'OS/2'), (e2.prototype.parse = function (t4) { if ( ((t4.pos = this.offset), (this.version = t4.readUInt16()), (this.averageCharWidth = t4.readShort()), (this.weightClass = t4.readUInt16()), (this.widthClass = t4.readUInt16()), (this.type = t4.readShort()), (this.ySubscriptXSize = t4.readShort()), (this.ySubscriptYSize = t4.readShort()), (this.ySubscriptXOffset = t4.readShort()), (this.ySubscriptYOffset = t4.readShort()), (this.ySuperscriptXSize = t4.readShort()), (this.ySuperscriptYSize = t4.readShort()), (this.ySuperscriptXOffset = t4.readShort()), (this.ySuperscriptYOffset = t4.readShort()), (this.yStrikeoutSize = t4.readShort()), (this.yStrikeoutPosition = t4.readShort()), (this.familyClass = t4.readShort()), (this.panose = (function () { var e3, r2 for (r2 = [], e3 = 0; e3 < 10; ++e3) r2.push(t4.readByte()) return r2 })()), (this.charRange = (function () { var e3, r2 for (r2 = [], e3 = 0; e3 < 4; ++e3) r2.push(t4.readInt()) return r2 })()), (this.vendorID = t4.readString(4)), (this.selection = t4.readShort()), (this.firstCharIndex = t4.readShort()), (this.lastCharIndex = t4.readShort()), this.version > 0 && ((this.ascent = t4.readShort()), (this.descent = t4.readShort()), (this.lineGap = t4.readShort()), (this.winAscent = t4.readShort()), (this.winDescent = t4.readShort()), (this.codePageRange = (function () { var e3, r2 for (r2 = [], e3 = 0; e3 < 2; e3 = ++e3) r2.push(t4.readInt()) return r2 })()), this.version > 1)) ) return ( (this.xHeight = t4.readShort()), (this.capHeight = t4.readShort()), (this.defaultChar = t4.readShort()), (this.breakChar = t4.readShort()), (this.maxContext = t4.readShort()) ) }), e2 ) })(), fe = (function (t3) { function e2() { return e2.__super__.constructor.apply(this, arguments) } return ( oe(e2, re), (e2.prototype.tag = 'post'), (e2.prototype.parse = function (t4) { var e3, r2, n2 switch ( ((t4.pos = this.offset), (this.format = t4.readInt()), (this.italicAngle = t4.readInt()), (this.underlinePosition = t4.readShort()), (this.underlineThickness = t4.readShort()), (this.isFixedPitch = t4.readInt()), (this.minMemType42 = t4.readInt()), (this.maxMemType42 = t4.readInt()), (this.minMemType1 = t4.readInt()), (this.maxMemType1 = t4.readInt()), this.format) ) { case 65536: break case 131072: var i2 for ( r2 = t4.readUInt16(), this.glyphNameIndex = [], i2 = 0; 0 <= r2 ? i2 < r2 : i2 > r2; i2 = 0 <= r2 ? ++i2 : --i2 ) this.glyphNameIndex.push(t4.readUInt16()) for (this.names = [], n2 = []; t4.pos < this.offset + this.length; ) (e3 = t4.readByte()), n2.push(this.names.push(t4.readString(e3))) return n2 case 151552: return (r2 = t4.readUInt16()), (this.offsets = t4.read(r2)) case 196608: break case 262144: return (this.map = function () { var e4, r3, n3 for ( n3 = [], i2 = e4 = 0, r3 = this.file.maxp.numGlyphs; 0 <= r3 ? e4 < r3 : e4 > r3; i2 = 0 <= r3 ? ++e4 : --e4 ) n3.push(t4.readUInt32()) return n3 }.call(this)) } }), e2 ) })(), de = function (t3, e2) { ;(this.raw = t3), (this.length = t3.length), (this.platformID = e2.platformID), (this.encodingID = e2.encodingID), (this.languageID = e2.languageID) }, pe = (function (t3) { function e2() { return e2.__super__.constructor.apply(this, arguments) } return ( oe(e2, re), (e2.prototype.tag = 'name'), (e2.prototype.parse = function (t4) { var e3, r2, n2, i2, a2, o2, s2, c2, u2, h2, l2 for ( t4.pos = this.offset, t4.readShort(), e3 = t4.readShort(), o2 = t4.readShort(), r2 = [], i2 = 0; 0 <= e3 ? i2 < e3 : i2 > e3; i2 = 0 <= e3 ? ++i2 : --i2 ) r2.push({ platformID: t4.readShort(), encodingID: t4.readShort(), languageID: t4.readShort(), nameID: t4.readShort(), length: t4.readShort(), offset: this.offset + o2 + t4.readShort(), }) for (s2 = {}, i2 = u2 = 0, h2 = r2.length; u2 < h2; i2 = ++u2) (n2 = r2[i2]), (t4.pos = n2.offset), (c2 = t4.readString(n2.length)), (a2 = new de(c2, n2)), null == s2[(l2 = n2.nameID)] && (s2[l2] = []), s2[n2.nameID].push(a2) ;(this.strings = s2), (this.copyright = s2[0]), (this.fontFamily = s2[1]), (this.fontSubfamily = s2[2]), (this.uniqueSubfamily = s2[3]), (this.fontName = s2[4]), (this.version = s2[5]) try { this.postscriptName = s2[6][0].raw.replace( /[\x00-\x19\x80-\xff]/g, '' ) } catch (t5) { this.postscriptName = s2[4][0].raw.replace( /[\x00-\x19\x80-\xff]/g, '' ) } return ( (this.trademark = s2[7]), (this.manufacturer = s2[8]), (this.designer = s2[9]), (this.description = s2[10]), (this.vendorUrl = s2[11]), (this.designerUrl = s2[12]), (this.license = s2[13]), (this.licenseUrl = s2[14]), (this.preferredFamily = s2[15]), (this.preferredSubfamily = s2[17]), (this.compatibleFull = s2[18]), (this.sampleText = s2[19]) ) }), e2 ) })(), ge = (function (t3) { function e2() { return e2.__super__.constructor.apply(this, arguments) } return ( oe(e2, re), (e2.prototype.tag = 'maxp'), (e2.prototype.parse = function (t4) { return ( (t4.pos = this.offset), (this.version = t4.readInt()), (this.numGlyphs = t4.readUInt16()), (this.maxPoints = t4.readUInt16()), (this.maxContours = t4.readUInt16()), (this.maxCompositePoints = t4.readUInt16()), (this.maxComponentContours = t4.readUInt16()), (this.maxZones = t4.readUInt16()), (this.maxTwilightPoints = t4.readUInt16()), (this.maxStorage = t4.readUInt16()), (this.maxFunctionDefs = t4.readUInt16()), (this.maxInstructionDefs = t4.readUInt16()), (this.maxStackElements = t4.readUInt16()), (this.maxSizeOfInstructions = t4.readUInt16()), (this.maxComponentElements = t4.readUInt16()), (this.maxComponentDepth = t4.readUInt16()) ) }), e2 ) })(), me = (function (t3) { function e2() { return e2.__super__.constructor.apply(this, arguments) } return ( oe(e2, re), (e2.prototype.tag = 'hmtx'), (e2.prototype.parse = function (t4) { var e3, r2, n2, i2, a2, o2, s2 for ( t4.pos = this.offset, this.metrics = [], e3 = 0, o2 = this.file.hhea.numberOfMetrics; 0 <= o2 ? e3 < o2 : e3 > o2; e3 = 0 <= o2 ? ++e3 : --e3 ) this.metrics.push({ advance: t4.readUInt16(), lsb: t4.readInt16() }) for ( n2 = this.file.maxp.numGlyphs - this.file.hhea.numberOfMetrics, this.leftSideBearings = (function () { var r3, i3 for ( i3 = [], e3 = r3 = 0; 0 <= n2 ? r3 < n2 : r3 > n2; e3 = 0 <= n2 ? ++r3 : --r3 ) i3.push(t4.readInt16()) return i3 })(), this.widths = function () { var t5, e4, r3, n3 for ( n3 = [], t5 = 0, e4 = (r3 = this.metrics).length; t5 < e4; t5++ ) (i2 = r3[t5]), n3.push(i2.advance) return n3 }.call(this), r2 = this.widths[this.widths.length - 1], s2 = [], e3 = a2 = 0; 0 <= n2 ? a2 < n2 : a2 > n2; e3 = 0 <= n2 ? ++a2 : --a2 ) s2.push(this.widths.push(r2)) return s2 }), (e2.prototype.forGlyph = function (t4) { return t4 in this.metrics ? this.metrics[t4] : { advance: this.metrics[this.metrics.length - 1].advance, lsb: this.leftSideBearings[t4 - this.metrics.length], } }), e2 ) })(), ve = [].slice, be = (function (t3) { function e2() { return e2.__super__.constructor.apply(this, arguments) } return ( oe(e2, re), (e2.prototype.tag = 'glyf'), (e2.prototype.parse = function () { return (this.cache = {}) }), (e2.prototype.glyphFor = function (t4) { var e3, r2, n2, i2, a2, o2, s2, c2, u2, h2 return t4 in this.cache ? this.cache[t4] : ((i2 = this.file.loca), (e3 = this.file.contents), (r2 = i2.indexOf(t4)), 0 === (n2 = i2.lengthOf(t4)) ? (this.cache[t4] = null) : ((e3.pos = this.offset + r2), (a2 = (o2 = new ne(e3.read(n2))).readShort()), (c2 = o2.readShort()), (h2 = o2.readShort()), (s2 = o2.readShort()), (u2 = o2.readShort()), (this.cache[t4] = -1 === a2 ? new we(o2, c2, h2, s2, u2) : new ye(o2, a2, c2, h2, s2, u2)), this.cache[t4])) }), (e2.prototype.encode = function (t4, e3, r2) { var n2, i2, a2, o2, s2 for (a2 = [], i2 = [], o2 = 0, s2 = e3.length; o2 < s2; o2++) (n2 = t4[e3[o2]]), i2.push(a2.length), n2 && (a2 = a2.concat(n2.encode(r2))) return i2.push(a2.length), { table: a2, offsets: i2 } }), e2 ) })(), ye = (function () { function t3(t4, e2, r2, n2, i2, a2) { ;(this.raw = t4), (this.numberOfContours = e2), (this.xMin = r2), (this.yMin = n2), (this.xMax = i2), (this.yMax = a2), (this.compound = false) } return ( (t3.prototype.encode = function () { return this.raw.data }), t3 ) })(), we = (function () { function t3(t4, e2, r2, n2, i2) { var a2, o2 for ( this.raw = t4, this.xMin = e2, this.yMin = r2, this.xMax = n2, this.yMax = i2, this.compound = true, this.glyphIDs = [], this.glyphOffsets = [], a2 = this.raw; (o2 = a2.readShort()), this.glyphOffsets.push(a2.pos), this.glyphIDs.push(a2.readUInt16()), 32 & o2; ) (a2.pos += 1 & o2 ? 4 : 2), 128 & o2 ? (a2.pos += 8) : 64 & o2 ? (a2.pos += 4) : 8 & o2 && (a2.pos += 2) } return ( (t3.prototype.encode = function () { var t4, e2, r2 for ( e2 = new ne(ve.call(this.raw.data)), t4 = 0, r2 = this.glyphIDs.length; t4 < r2; ++t4 ) e2.pos = this.glyphOffsets[t4] return e2.data }), t3 ) })(), Ne = (function (t3) { function e2() { return e2.__super__.constructor.apply(this, arguments) } return ( oe(e2, re), (e2.prototype.tag = 'loca'), (e2.prototype.parse = function (t4) { var e3, r2 return ( (t4.pos = this.offset), (e3 = this.file.head.indexToLocFormat), (this.offsets = 0 === e3 ? function () { var e4, n2 for (n2 = [], r2 = 0, e4 = this.length; r2 < e4; r2 += 2) n2.push(2 * t4.readUInt16()) return n2 }.call(this) : function () { var e4, n2 for (n2 = [], r2 = 0, e4 = this.length; r2 < e4; r2 += 4) n2.push(t4.readUInt32()) return n2 }.call(this)) ) }), (e2.prototype.indexOf = function (t4) { return this.offsets[t4] }), (e2.prototype.lengthOf = function (t4) { return this.offsets[t4 + 1] - this.offsets[t4] }), (e2.prototype.encode = function (t4, e3) { for ( var r2 = new Uint32Array(this.offsets.length), n2 = 0, i2 = 0, a2 = 0; a2 < r2.length; ++a2 ) if (((r2[a2] = n2), i2 < e3.length && e3[i2] == a2)) { ++i2, (r2[a2] = n2) var o2 = this.offsets[a2], s2 = this.offsets[a2 + 1] - o2 s2 > 0 && (n2 += s2) } for (var c2 = new Array(4 * r2.length), u2 = 0; u2 < r2.length; ++u2) (c2[4 * u2 + 3] = 255 & r2[u2]), (c2[4 * u2 + 2] = (65280 & r2[u2]) >> 8), (c2[4 * u2 + 1] = (16711680 & r2[u2]) >> 16), (c2[4 * u2] = (4278190080 & r2[u2]) >> 24) return c2 }), e2 ) })(), Le = (function () { function t3(t4) { ;(this.font = t4), (this.subset = {}), (this.unicodes = {}), (this.next = 33) } return ( (t3.prototype.generateCmap = function () { var t4, e2, r2, n2, i2 for (e2 in ((n2 = this.font.cmap.tables[0].codeMap), (t4 = {}), (i2 = this.subset))) (r2 = i2[e2]), (t4[e2] = n2[r2]) return t4 }), (t3.prototype.glyphsFor = function (t4) { var e2, r2, n2, i2, a2, o2, s2 for (n2 = {}, a2 = 0, o2 = t4.length; a2 < o2; a2++) n2[(i2 = t4[a2])] = this.font.glyf.glyphFor(i2) for (i2 in ((e2 = []), n2)) (null != (r2 = n2[i2]) ? r2.compound : void 0) && e2.push.apply(e2, r2.glyphIDs) if (e2.length > 0) for (i2 in (s2 = this.glyphsFor(e2))) (r2 = s2[i2]), (n2[i2] = r2) return n2 }), (t3.prototype.encode = function (t4, e2) { var r2, n2, i2, a2, o2, s2, c2, u2, h2, l2, f2, d3, p2, g2, m2 for (n2 in ((r2 = ue.encode(this.generateCmap(), 'unicode')), (a2 = this.glyphsFor(t4)), (f2 = { 0: 0 }), (m2 = r2.charMap))) f2[(s2 = m2[n2]).old] = s2.new for (d3 in ((l2 = r2.maxGlyphID), a2)) d3 in f2 || (f2[d3] = l2++) return ( (u2 = (function (t5) { var e3, r3 for (e3 in ((r3 = {}), t5)) r3[t5[e3]] = e3 return r3 })(f2)), (h2 = Object.keys(u2).sort(function (t5, e3) { return t5 - e3 })), (p2 = (function () { var t5, e3, r3 for (r3 = [], t5 = 0, e3 = h2.length; t5 < e3; t5++) (o2 = h2[t5]), r3.push(u2[o2]) return r3 })()), (i2 = this.font.glyf.encode(a2, p2, f2)), (c2 = this.font.loca.encode(i2.offsets, p2)), (g2 = { cmap: this.font.cmap.raw(), glyf: i2.table, loca: c2, hmtx: this.font.hmtx.raw(), hhea: this.font.hhea.raw(), maxp: this.font.maxp.raw(), post: this.font.post.raw(), name: this.font.name.raw(), head: this.font.head.encode(e2), }), this.font.os2.exists && (g2['OS/2'] = this.font.os2.raw()), this.font.directory.encode(g2) ) }), t3 ) })() E$1.API.PDFObject = (function () { var t3 function e2() {} return ( (t3 = function (t4, e3) { return (Array(e3 + 1).join('0') + t4).slice(-e3) }), (e2.convert = function (r2) { var n2, i2, a2, o2 if (Array.isArray(r2)) return ( '[' + (function () { var t4, i3, a3 for (a3 = [], t4 = 0, i3 = r2.length; t4 < i3; t4++) (n2 = r2[t4]), a3.push(e2.convert(n2)) return a3 })().join(' ') + ']' ) if ('string' == typeof r2) return '/' + r2 if (null != r2 ? r2.isString : void 0) return '(' + r2 + ')' if (r2 instanceof Date) return ( '(D:' + t3(r2.getUTCFullYear(), 4) + t3(r2.getUTCMonth(), 2) + t3(r2.getUTCDate(), 2) + t3(r2.getUTCHours(), 2) + t3(r2.getUTCMinutes(), 2) + t3(r2.getUTCSeconds(), 2) + 'Z)' ) if ('[object Object]' === {}.toString.call(r2)) { for (i2 in ((a2 = ['<<']), r2)) (o2 = r2[i2]), a2.push('/' + i2 + ' ' + e2.convert(o2)) return a2.push('>>'), a2.join('\n') } return '' + r2 }), e2 ) })() /*! * html2canvas 1.4.1 * Copyright (c) 2022 Niklas von Hertzen * Released under MIT License */ /*! ***************************************************************************** Copyright (c) Microsoft Corporation. Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted. THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. ***************************************************************************** */ var extendStatics$2 = function (d3, b2) { extendStatics$2 = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d4, b3) { d4.__proto__ = b3 }) || function (d4, b3) { for (var p2 in b3) if (Object.prototype.hasOwnProperty.call(b3, p2)) d4[p2] = b3[p2] } return extendStatics$2(d3, b2) } function __extends$3(d3, b2) { if (typeof b2 !== 'function' && b2 !== null) throw new TypeError( 'Class extends value ' + String(b2) + ' is not a constructor or null' ) extendStatics$2(d3, b2) function __() { this.constructor = d3 } d3.prototype = b2 === null ? Object.create(b2) : ((__.prototype = b2.prototype), new __()) } var __assign$k = function () { __assign$k = Object.assign || function __assign2(t3) { for (var s2, i2 = 1, n2 = arguments.length; i2 < n2; i2++) { s2 = arguments[i2] for (var p2 in s2) if (Object.prototype.hasOwnProperty.call(s2, p2)) t3[p2] = s2[p2] } return t3 } return __assign$k.apply(this, arguments) } function __awaiter(thisArg, _arguments, P2, generator) { function adopt(value2) { return value2 instanceof P2 ? value2 : new P2(function (resolve2) { resolve2(value2) }) } return new (P2 || (P2 = Promise))(function (resolve2, reject2) { function fulfilled(value2) { try { step(generator.next(value2)) } catch (e2) { reject2(e2) } } function rejected(value2) { try { step(generator['throw'](value2)) } catch (e2) { reject2(e2) } } function step(result) { result.done ? resolve2(result.value) : adopt(result.value).then(fulfilled, rejected) } step((generator = generator.apply(thisArg, _arguments || [])).next()) }) } function __generator(thisArg, body) { var _2 = { label: 0, sent: function () { if (t3[0] & 1) throw t3[1] return t3[1] }, trys: [], ops: [], }, f2, y2, t3, g2 return ( (g2 = { next: verb(0), throw: verb(1), return: verb(2) }), typeof Symbol === 'function' && (g2[Symbol.iterator] = function () { return this }), g2 ) function verb(n2) { return function (v4) { return step([n2, v4]) } } function step(op) { if (f2) throw new TypeError('Generator is already executing.') while (_2) try { if ( ((f2 = 1), y2 && (t3 = op[0] & 2 ? y2['return'] : op[0] ? y2['throw'] || ((t3 = y2['return']) && t3.call(y2), 0) : y2.next) && !(t3 = t3.call(y2, op[1])).done) ) return t3 if (((y2 = 0), t3)) op = [op[0] & 2, t3.value] switch (op[0]) { case 0: case 1: t3 = op break case 4: _2.label++ return { value: op[1], done: false } case 5: _2.label++ y2 = op[1] op = [0] continue case 7: op = _2.ops.pop() _2.trys.pop() continue default: if ( !((t3 = _2.trys), (t3 = t3.length > 0 && t3[t3.length - 1])) && (op[0] === 6 || op[0] === 2) ) { _2 = 0 continue } if (op[0] === 3 && (!t3 || (op[1] > t3[0] && op[1] < t3[3]))) { _2.label = op[1] break } if (op[0] === 6 && _2.label < t3[1]) { _2.label = t3[1] t3 = op break } if (t3 && _2.label < t3[2]) { _2.label = t3[2] _2.ops.push(op) break } if (t3[2]) _2.ops.pop() _2.trys.pop() continue } op = body.call(thisArg, _2) } catch (e2) { op = [6, e2] y2 = 0 } finally { f2 = t3 = 0 } if (op[0] & 5) throw op[1] return { value: op[0] ? op[1] : void 0, done: true } } } function __spreadArray$7(to, from, pack2) { if (pack2 || arguments.length === 2) for (var i2 = 0, l2 = from.length, ar2; i2 < l2; i2++) { if (ar2 || !(i2 in from)) { if (!ar2) ar2 = Array.prototype.slice.call(from, 0, i2) ar2[i2] = from[i2] } } return to.concat(ar2 || from) } var Bounds = (function () { function Bounds2(left2, top2, width, height) { this.left = left2 this.top = top2 this.width = width this.height = height } Bounds2.prototype.add = function (x2, y2, w2, h2) { return new Bounds2( this.left + x2, this.top + y2, this.width + w2, this.height + h2 ) } Bounds2.fromClientRect = function (context2, clientRect) { return new Bounds2( clientRect.left + context2.windowBounds.left, clientRect.top + context2.windowBounds.top, clientRect.width, clientRect.height ) } Bounds2.fromDOMRectList = function (context2, domRectList) { var domRect = Array.from(domRectList).find(function (rect) { return rect.width !== 0 }) return domRect ? new Bounds2( domRect.left + context2.windowBounds.left, domRect.top + context2.windowBounds.top, domRect.width, domRect.height ) : Bounds2.EMPTY } Bounds2.EMPTY = new Bounds2(0, 0, 0, 0) return Bounds2 })() var parseBounds = function (context2, node2) { return Bounds.fromClientRect(context2, node2.getBoundingClientRect()) } var parseDocumentSize = function (document2) { var body = document2.body var documentElement = document2.documentElement if (!body || !documentElement) { throw new Error('Unable to get document size') } var width = Math.max( Math.max(body.scrollWidth, documentElement.scrollWidth), Math.max(body.offsetWidth, documentElement.offsetWidth), Math.max(body.clientWidth, documentElement.clientWidth) ) var height = Math.max( Math.max(body.scrollHeight, documentElement.scrollHeight), Math.max(body.offsetHeight, documentElement.offsetHeight), Math.max(body.clientHeight, documentElement.clientHeight) ) return new Bounds(0, 0, width, height) } var toCodePoints$1 = function (str) { var codePoints = [] var i2 = 0 var length2 = str.length while (i2 < length2) { var value2 = str.charCodeAt(i2++) if (value2 >= 55296 && value2 <= 56319 && i2 < length2) { var extra = str.charCodeAt(i2++) if ((extra & 64512) === 56320) { codePoints.push(((value2 & 1023) << 10) + (extra & 1023) + 65536) } else { codePoints.push(value2) i2-- } } else { codePoints.push(value2) } } return codePoints } var fromCodePoint$1 = function () { var codePoints = [] for (var _i = 0; _i < arguments.length; _i++) { codePoints[_i] = arguments[_i] } if (String.fromCodePoint) { return String.fromCodePoint.apply(String, codePoints) } var length2 = codePoints.length if (!length2) { return '' } var codeUnits = [] var index2 = -1 var result = '' while (++index2 < length2) { var codePoint = codePoints[index2] if (codePoint <= 65535) { codeUnits.push(codePoint) } else { codePoint -= 65536 codeUnits.push((codePoint >> 10) + 55296, (codePoint % 1024) + 56320) } if (index2 + 1 === length2 || codeUnits.length > 16384) { result += String.fromCharCode.apply(String, codeUnits) codeUnits.length = 0 } } return result } var chars$2 = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/' var lookup$2 = typeof Uint8Array === 'undefined' ? [] : new Uint8Array(256) for (var i$2$1 = 0; i$2$1 < chars$2.length; i$2$1++) { lookup$2[chars$2.charCodeAt(i$2$1)] = i$2$1 } var chars$1$1 = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/' var lookup$1$1 = typeof Uint8Array === 'undefined' ? [] : new Uint8Array(256) for (var i$1$1 = 0; i$1$1 < chars$1$1.length; i$1$1++) { lookup$1$1[chars$1$1.charCodeAt(i$1$1)] = i$1$1 } var decode$1 = function (base642) { var bufferLength = base642.length * 0.75, len2 = base642.length, i2, p2 = 0, encoded1, encoded2, encoded3, encoded4 if (base642[base642.length - 1] === '=') { bufferLength-- if (base642[base642.length - 2] === '=') { bufferLength-- } } var buffer = typeof ArrayBuffer !== 'undefined' && typeof Uint8Array !== 'undefined' && typeof Uint8Array.prototype.slice !== 'undefined' ? new ArrayBuffer(bufferLength) : new Array(bufferLength) var bytes = Array.isArray(buffer) ? buffer : new Uint8Array(buffer) for (i2 = 0; i2 < len2; i2 += 4) { encoded1 = lookup$1$1[base642.charCodeAt(i2)] encoded2 = lookup$1$1[base642.charCodeAt(i2 + 1)] encoded3 = lookup$1$1[base642.charCodeAt(i2 + 2)] encoded4 = lookup$1$1[base642.charCodeAt(i2 + 3)] bytes[p2++] = (encoded1 << 2) | (encoded2 >> 4) bytes[p2++] = ((encoded2 & 15) << 4) | (encoded3 >> 2) bytes[p2++] = ((encoded3 & 3) << 6) | (encoded4 & 63) } return buffer } var polyUint16Array$1 = function (buffer) { var length2 = buffer.length var bytes = [] for (var i2 = 0; i2 < length2; i2 += 2) { bytes.push((buffer[i2 + 1] << 8) | buffer[i2]) } return bytes } var polyUint32Array$1 = function (buffer) { var length2 = buffer.length var bytes = [] for (var i2 = 0; i2 < length2; i2 += 4) { bytes.push( (buffer[i2 + 3] << 24) | (buffer[i2 + 2] << 16) | (buffer[i2 + 1] << 8) | buffer[i2] ) } return bytes } var UTRIE2_SHIFT_2$1 = 5 var UTRIE2_SHIFT_1$1 = 6 + 5 var UTRIE2_INDEX_SHIFT$1 = 2 var UTRIE2_SHIFT_1_2$1 = UTRIE2_SHIFT_1$1 - UTRIE2_SHIFT_2$1 var UTRIE2_LSCP_INDEX_2_OFFSET$1 = 65536 >> UTRIE2_SHIFT_2$1 var UTRIE2_DATA_BLOCK_LENGTH$1 = 1 << UTRIE2_SHIFT_2$1 var UTRIE2_DATA_MASK$1 = UTRIE2_DATA_BLOCK_LENGTH$1 - 1 var UTRIE2_LSCP_INDEX_2_LENGTH$1 = 1024 >> UTRIE2_SHIFT_2$1 var UTRIE2_INDEX_2_BMP_LENGTH$1 = UTRIE2_LSCP_INDEX_2_OFFSET$1 + UTRIE2_LSCP_INDEX_2_LENGTH$1 var UTRIE2_UTF8_2B_INDEX_2_OFFSET$1 = UTRIE2_INDEX_2_BMP_LENGTH$1 var UTRIE2_UTF8_2B_INDEX_2_LENGTH$1 = 2048 >> 6 var UTRIE2_INDEX_1_OFFSET$1 = UTRIE2_UTF8_2B_INDEX_2_OFFSET$1 + UTRIE2_UTF8_2B_INDEX_2_LENGTH$1 var UTRIE2_OMITTED_BMP_INDEX_1_LENGTH$1 = 65536 >> UTRIE2_SHIFT_1$1 var UTRIE2_INDEX_2_BLOCK_LENGTH$1 = 1 << UTRIE2_SHIFT_1_2$1 var UTRIE2_INDEX_2_MASK$1 = UTRIE2_INDEX_2_BLOCK_LENGTH$1 - 1 var slice16$1 = function (view2, start2, end2) { if (view2.slice) { return view2.slice(start2, end2) } return new Uint16Array(Array.prototype.slice.call(view2, start2, end2)) } var slice32$1 = function (view2, start2, end2) { if (view2.slice) { return view2.slice(start2, end2) } return new Uint32Array(Array.prototype.slice.call(view2, start2, end2)) } var createTrieFromBase64$1 = function (base642, _byteLength) { var buffer = decode$1(base642) var view32 = Array.isArray(buffer) ? polyUint32Array$1(buffer) : new Uint32Array(buffer) var view16 = Array.isArray(buffer) ? polyUint16Array$1(buffer) : new Uint16Array(buffer) var headerLength = 24 var index2 = slice16$1(view16, headerLength / 2, view32[4] / 2) var data2 = view32[5] === 2 ? slice16$1(view16, (headerLength + view32[4]) / 2) : slice32$1(view32, Math.ceil((headerLength + view32[4]) / 4)) return new Trie$1(view32[0], view32[1], view32[2], view32[3], index2, data2) } var Trie$1 = (function () { function Trie2( initialValue, errorValue, highStart, highValueIndex, index2, data2 ) { this.initialValue = initialValue this.errorValue = errorValue this.highStart = highStart this.highValueIndex = highValueIndex this.index = index2 this.data = data2 } Trie2.prototype.get = function (codePoint) { var ix if (codePoint >= 0) { if (codePoint < 55296 || (codePoint > 56319 && codePoint <= 65535)) { ix = this.index[codePoint >> UTRIE2_SHIFT_2$1] ix = (ix << UTRIE2_INDEX_SHIFT$1) + (codePoint & UTRIE2_DATA_MASK$1) return this.data[ix] } if (codePoint <= 65535) { ix = this.index[ UTRIE2_LSCP_INDEX_2_OFFSET$1 + ((codePoint - 55296) >> UTRIE2_SHIFT_2$1) ] ix = (ix << UTRIE2_INDEX_SHIFT$1) + (codePoint & UTRIE2_DATA_MASK$1) return this.data[ix] } if (codePoint < this.highStart) { ix = UTRIE2_INDEX_1_OFFSET$1 - UTRIE2_OMITTED_BMP_INDEX_1_LENGTH$1 + (codePoint >> UTRIE2_SHIFT_1$1) ix = this.index[ix] ix += (codePoint >> UTRIE2_SHIFT_2$1) & UTRIE2_INDEX_2_MASK$1 ix = this.index[ix] ix = (ix << UTRIE2_INDEX_SHIFT$1) + (codePoint & UTRIE2_DATA_MASK$1) return this.data[ix] } if (codePoint <= 1114111) { return this.data[this.highValueIndex] } } return this.errorValue } return Trie2 })() var chars$3 = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/' var lookup$3 = typeof Uint8Array === 'undefined' ? [] : new Uint8Array(256) for (var i$3$1 = 0; i$3$1 < chars$3.length; i$3$1++) { lookup$3[chars$3.charCodeAt(i$3$1)] = i$3$1 } var base64$1 = 'KwAAAAAAAAAACA4AUD0AADAgAAACAAAAAAAIABAAGABAAEgAUABYAGAAaABgAGgAYgBqAF8AZwBgAGgAcQB5AHUAfQCFAI0AlQCdAKIAqgCyALoAYABoAGAAaABgAGgAwgDKAGAAaADGAM4A0wDbAOEA6QDxAPkAAQEJAQ8BFwF1AH0AHAEkASwBNAE6AUIBQQFJAVEBWQFhAWgBcAF4ATAAgAGGAY4BlQGXAZ8BpwGvAbUBvQHFAc0B0wHbAeMB6wHxAfkBAQIJAvEBEQIZAiECKQIxAjgCQAJGAk4CVgJeAmQCbAJ0AnwCgQKJApECmQKgAqgCsAK4ArwCxAIwAMwC0wLbAjAA4wLrAvMC+AIAAwcDDwMwABcDHQMlAy0DNQN1AD0DQQNJA0kDSQNRA1EDVwNZA1kDdQB1AGEDdQBpA20DdQN1AHsDdQCBA4kDkQN1AHUAmQOhA3UAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AKYDrgN1AHUAtgO+A8YDzgPWAxcD3gPjA+sD8wN1AHUA+wMDBAkEdQANBBUEHQQlBCoEFwMyBDgEYABABBcDSARQBFgEYARoBDAAcAQzAXgEgASIBJAEdQCXBHUAnwSnBK4EtgS6BMIEyAR1AHUAdQB1AHUAdQCVANAEYABgAGAAYABgAGAAYABgANgEYADcBOQEYADsBPQE/AQEBQwFFAUcBSQFLAU0BWQEPAVEBUsFUwVbBWAAYgVgAGoFcgV6BYIFigWRBWAAmQWfBaYFYABgAGAAYABgAKoFYACxBbAFuQW6BcEFwQXHBcEFwQXPBdMF2wXjBeoF8gX6BQIGCgYSBhoGIgYqBjIGOgZgAD4GRgZMBmAAUwZaBmAAYABgAGAAYABgAGAAYABgAGAAYABgAGIGYABpBnAGYABgAGAAYABgAGAAYABgAGAAYAB4Bn8GhQZgAGAAYAB1AHcDFQSLBmAAYABgAJMGdQA9A3UAmwajBqsGqwaVALMGuwbDBjAAywbSBtIG1QbSBtIG0gbSBtIG0gbdBuMG6wbzBvsGAwcLBxMHAwcbByMHJwcsBywHMQcsB9IGOAdAB0gHTgfSBkgHVgfSBtIG0gbSBtIG0gbSBtIG0gbSBiwHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAdgAGAALAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAdbB2MHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsB2kH0gZwB64EdQB1AHUAdQB1AHUAdQB1AHUHfQdgAIUHjQd1AHUAlQedB2AAYAClB6sHYACzB7YHvgfGB3UAzgfWBzMB3gfmB1EB7gf1B/0HlQENAQUIDQh1ABUIHQglCBcDLQg1CD0IRQhNCEEDUwh1AHUAdQBbCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIaQhjCGQIZQhmCGcIaAhpCGMIZAhlCGYIZwhoCGkIYwhkCGUIZghnCGgIcAh3CHoIMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwAIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIgggwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAALAcsBywHLAcsBywHLAcsBywHLAcsB4oILAcsB44I0gaWCJ4Ipgh1AHUAqgiyCHUAdQB1AHUAdQB1AHUAdQB1AHUAtwh8AXUAvwh1AMUIyQjRCNkI4AjoCHUAdQB1AO4I9gj+CAYJDgkTCS0HGwkjCYIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiCCIIIggiAAIAAAAFAAYABgAGIAXwBgAHEAdQBFAJUAogCyAKAAYABgAEIA4ABGANMA4QDxAMEBDwE1AFwBLAE6AQEBUQF4QkhCmEKoQrhCgAHIQsAB0MLAAcABwAHAAeDC6ABoAHDCwMMAAcABwAHAAdDDGMMAAcAB6MM4wwjDWMNow3jDaABoAGgAaABoAGgAaABoAGgAaABoAGgAaABoAGgAaABoAGgAaABoAEjDqABWw6bDqABpg6gAaABoAHcDvwOPA+gAaABfA/8DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DvwO/A78DpcPAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcAB9cPKwkyCToJMAB1AHUAdQBCCUoJTQl1AFUJXAljCWcJawkwADAAMAAwAHMJdQB2CX4JdQCECYoJjgmWCXUAngkwAGAAYABxAHUApgn3A64JtAl1ALkJdQDACTAAMAAwADAAdQB1AHUAdQB1AHUAdQB1AHUAowYNBMUIMAAwADAAMADICcsJ0wnZCRUE4QkwAOkJ8An4CTAAMAB1AAAKvwh1AAgKDwoXCh8KdQAwACcKLgp1ADYKqAmICT4KRgowADAAdQB1AE4KMAB1AFYKdQBeCnUAZQowADAAMAAwADAAMAAwADAAMAAVBHUAbQowADAAdQC5CXUKMAAwAHwBxAijBogEMgF9CoQKiASMCpQKmgqIBKIKqgquCogEDQG2Cr4KxgrLCjAAMADTCtsKCgHjCusK8Qr5CgELMAAwADAAMAB1AIsECQsRC3UANAEZCzAAMAAwADAAMAB1ACELKQswAHUANAExCzkLdQBBC0kLMABRC1kLMAAwADAAMAAwADAAdQBhCzAAMAAwAGAAYABpC3ELdwt/CzAAMACHC4sLkwubC58Lpwt1AK4Ltgt1APsDMAAwADAAMAAwADAAMAAwAL4LwwvLC9IL1wvdCzAAMADlC+kL8Qv5C/8LSQswADAAMAAwADAAMAAwADAAMAAHDDAAMAAwADAAMAAODBYMHgx1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1ACYMMAAwADAAdQB1AHUALgx1AHUAdQB1AHUAdQA2DDAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwAHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AD4MdQBGDHUAdQB1AHUAdQB1AEkMdQB1AHUAdQB1AFAMMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwAHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQBYDHUAdQB1AF8MMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUA+wMVBGcMMAAwAHwBbwx1AHcMfwyHDI8MMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAYABgAJcMMAAwADAAdQB1AJ8MlQClDDAAMACtDCwHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsB7UMLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHdQB1AHUAdQB1AHUAdQB1AHUAdQB1AHUAdQB1AA0EMAC9DDAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAsBywHLAcsBywHLAcsBywHLQcwAMEMyAwsBywHLAcsBywHLAcsBywHLAcsBywHzAwwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwAHUAdQB1ANQM2QzhDDAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMABgAGAAYABgAGAAYABgAOkMYADxDGAA+AwADQYNYABhCWAAYAAODTAAMAAwADAAFg1gAGAAHg37AzAAMAAwADAAYABgACYNYAAsDTQNPA1gAEMNPg1LDWAAYABgAGAAYABgAGAAYABgAGAAUg1aDYsGVglhDV0NcQBnDW0NdQ15DWAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAlQCBDZUAiA2PDZcNMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAnw2nDTAAMAAwADAAMAAwAHUArw23DTAAMAAwADAAMAAwADAAMAAwADAAMAB1AL8NMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAB1AHUAdQB1AHUAdQDHDTAAYABgAM8NMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAA1w11ANwNMAAwAD0B5A0wADAAMAAwADAAMADsDfQN/A0EDgwOFA4wABsOMAAwADAAMAAwADAAMAAwANIG0gbSBtIG0gbSBtIG0gYjDigOwQUuDsEFMw7SBjoO0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIGQg5KDlIOVg7SBtIGXg5lDm0OdQ7SBtIGfQ6EDooOjQ6UDtIGmg6hDtIG0gaoDqwO0ga0DrwO0gZgAGAAYADEDmAAYAAkBtIGzA5gANIOYADaDokO0gbSBt8O5w7SBu8O0gb1DvwO0gZgAGAAxA7SBtIG0gbSBtIGYABgAGAAYAAED2AAsAUMD9IG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIGFA8sBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAccD9IGLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHJA8sBywHLAcsBywHLAccDywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywPLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAc0D9IG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIGLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAccD9IG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIGFA8sBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHLAcsBywHPA/SBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gbSBtIG0gYUD0QPlQCVAJUAMAAwADAAMACVAJUAlQCVAJUAlQCVAEwPMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAA//8EAAQABAAEAAQABAAEAAQABAANAAMAAQABAAIABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQACgATABcAHgAbABoAHgAXABYAEgAeABsAGAAPABgAHABLAEsASwBLAEsASwBLAEsASwBLABgAGAAeAB4AHgATAB4AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQABYAGwASAB4AHgAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAWAA0AEQAeAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAAQABAAEAAQABAAFAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAJABYAGgAbABsAGwAeAB0AHQAeAE8AFwAeAA0AHgAeABoAGwBPAE8ADgBQAB0AHQAdAE8ATwAXAE8ATwBPABYAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAdAFAAUABQAFAAUABQAFAAUAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAFAAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAeAB4AHgAeAFAATwBAAE8ATwBPAEAATwBQAFAATwBQAB4AHgAeAB4AHgAeAB0AHQAdAB0AHgAdAB4ADgBQAFAAUABQAFAAHgAeAB4AHgAeAB4AHgBQAB4AUAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4ABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAJAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAkACQAJAAkACQAJAAkABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAeAB4AHgAeAFAAHgAeAB4AKwArAFAAUABQAFAAGABQACsAKwArACsAHgAeAFAAHgBQAFAAUAArAFAAKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4ABAAEAAQABAAEAAQABAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAUAAeAB4AHgAeAB4AHgBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAYAA0AKwArAB4AHgAbACsABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQADQAEAB4ABAAEAB4ABAAEABMABAArACsAKwArACsAKwArACsAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAKwArACsAKwBWAFYAVgBWAB4AHgArACsAKwArACsAKwArACsAKwArACsAHgAeAB4AHgAeAB4AHgAeAB4AGgAaABoAGAAYAB4AHgAEAAQABAAEAAQABAAEAAQABAAEAAQAEwAEACsAEwATAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABABLAEsASwBLAEsASwBLAEsASwBLABoAGQAZAB4AUABQAAQAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQABMAUAAEAAQABAAEAAQABAAEAB4AHgAEAAQABAAEAAQABABQAFAABAAEAB4ABAAEAAQABABQAFAASwBLAEsASwBLAEsASwBLAEsASwBQAFAAUAAeAB4AUAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwAeAFAABABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAFAAKwArACsAKwArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQAUABQAB4AHgAYABMAUAArACsABAAbABsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAFAABAAEAAQABAAEAFAABAAEAAQAUAAEAAQABAAEAAQAKwArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAArACsAHgArAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArACsAKwArACsAKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAB4ABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAUAAEAAQABAAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQAFAABAAEAA0ADQBLAEsASwBLAEsASwBLAEsASwBLAB4AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAArAFAAUABQAFAAUABQAFAAUAArACsAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUAArACsAKwBQAFAAUABQACsAKwAEAFAABAAEAAQABAAEAAQABAArACsABAAEACsAKwAEAAQABABQACsAKwArACsAKwArACsAKwAEACsAKwArACsAUABQACsAUABQAFAABAAEACsAKwBLAEsASwBLAEsASwBLAEsASwBLAFAAUAAaABoAUABQAFAAUABQAEwAHgAbAFAAHgAEACsAKwAEAAQABAArAFAAUABQAFAAUABQACsAKwArACsAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQACsAUABQACsAUABQACsAKwAEACsABAAEAAQABAAEACsAKwArACsABAAEACsAKwAEAAQABAArACsAKwAEACsAKwArACsAKwArACsAUABQAFAAUAArAFAAKwArACsAKwArACsAKwBLAEsASwBLAEsASwBLAEsASwBLAAQABABQAFAAUAAEAB4AKwArACsAKwArACsAKwArACsAKwAEAAQABAArAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQACsAUABQAFAAUABQACsAKwAEAFAABAAEAAQABAAEAAQABAAEACsABAAEAAQAKwAEAAQABAArACsAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAABAAEACsAKwBLAEsASwBLAEsASwBLAEsASwBLAB4AGwArACsAKwArACsAKwArAFAABAAEAAQABAAEAAQAKwAEAAQABAArAFAAUABQAFAAUABQAFAAUAArACsAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAArACsABAAEACsAKwAEAAQABAArACsAKwArACsAKwArAAQABAAEACsAKwArACsAUABQACsAUABQAFAABAAEACsAKwBLAEsASwBLAEsASwBLAEsASwBLAB4AUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArAAQAUAArAFAAUABQAFAAUABQACsAKwArAFAAUABQACsAUABQAFAAUAArACsAKwBQAFAAKwBQACsAUABQACsAKwArAFAAUAArACsAKwBQAFAAUAArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArAAQABAAEAAQABAArACsAKwAEAAQABAArAAQABAAEAAQAKwArAFAAKwArACsAKwArACsABAArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAUABQAFAAHgAeAB4AHgAeAB4AGwAeACsAKwArACsAKwAEAAQABAAEAAQAUABQAFAAUABQAFAAUABQACsAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAUAAEAAQABAAEAAQABAAEACsABAAEAAQAKwAEAAQABAAEACsAKwArACsAKwArACsABAAEACsAUABQAFAAKwArACsAKwArAFAAUAAEAAQAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAKwAOAFAAUABQAFAAUABQAFAAHgBQAAQABAAEAA4AUABQAFAAUABQAFAAUABQACsAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAKwArAAQAUAAEAAQABAAEAAQABAAEACsABAAEAAQAKwAEAAQABAAEACsAKwArACsAKwArACsABAAEACsAKwArACsAKwArACsAUAArAFAAUAAEAAQAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwBQAFAAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAFAABAAEAAQABAAEAAQABAArAAQABAAEACsABAAEAAQABABQAB4AKwArACsAKwBQAFAAUAAEAFAAUABQAFAAUABQAFAAUABQAFAABAAEACsAKwBLAEsASwBLAEsASwBLAEsASwBLAFAAUABQAFAAUABQAFAAUABQABoAUABQAFAAUABQAFAAKwAEAAQABAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQACsAUAArACsAUABQAFAAUABQAFAAUAArACsAKwAEACsAKwArACsABAAEAAQABAAEAAQAKwAEACsABAAEAAQABAAEAAQABAAEACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArAAQABAAeACsAKwArACsAKwArACsAKwArACsAKwArAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXAAqAFwAXAAqACoAKgAqACoAKgAqACsAKwArACsAGwBcAFwAXABcAFwAXABcACoAKgAqACoAKgAqACoAKgAeAEsASwBLAEsASwBLAEsASwBLAEsADQANACsAKwArACsAKwBcAFwAKwBcACsAXABcAFwAXABcACsAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACsAXAArAFwAXABcAFwAXABcAFwAXABcAFwAKgBcAFwAKgAqACoAKgAqACoAKgAqACoAXAArACsAXABcAFwAXABcACsAXAArACoAKgAqACoAKgAqACsAKwBLAEsASwBLAEsASwBLAEsASwBLACsAKwBcAFwAXABcAFAADgAOAA4ADgAeAA4ADgAJAA4ADgANAAkAEwATABMAEwATAAkAHgATAB4AHgAeAAQABAAeAB4AHgAeAB4AHgBLAEsASwBLAEsASwBLAEsASwBLAFAAUABQAFAAUABQAFAAUABQAFAADQAEAB4ABAAeAAQAFgARABYAEQAEAAQAUABQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQADQAEAAQABAAEAAQADQAEAAQAUABQAFAAUABQAAQABAAEAAQABAAEAAQABAAEAAQABAArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAArAA0ADQAeAB4AHgAeAB4AHgAEAB4AHgAeAB4AHgAeACsAHgAeAA4ADgANAA4AHgAeAB4AHgAeAAkACQArACsAKwArACsAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgBcAEsASwBLAEsASwBLAEsASwBLAEsADQANAB4AHgAeAB4AXABcAFwAXABcAFwAKgAqACoAKgBcAFwAXABcACoAKgAqAFwAKgAqACoAXABcACoAKgAqACoAKgAqACoAXABcAFwAKgAqACoAKgBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACoAKgAqACoAKgAqACoAKgAqACoAKgAqAFwAKgBLAEsASwBLAEsASwBLAEsASwBLACoAKgAqACoAKgAqAFAAUABQAFAAUABQACsAUAArACsAKwArACsAUAArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgBQAFAAUABQAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAUAArACsAUABQAFAAUABQAFAAUAArAFAAKwBQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAKwArAFAAUABQAFAAUABQAFAAKwBQACsAUABQAFAAUAArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsABAAEAAQAHgANAB4AHgAeAB4AHgAeAB4AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUAArACsADQBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAANAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAWABEAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAA0ADQANAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAAQABAAEACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAANAA0AKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUAArAAQABAArACsAKwArACsAKwArACsAKwArACsAKwBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqAA0ADQAVAFwADQAeAA0AGwBcACoAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwAeAB4AEwATAA0ADQAOAB4AEwATAB4ABAAEAAQACQArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUAAEAAQAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQAUAArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAArACsAKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArACsAHgArACsAKwATABMASwBLAEsASwBLAEsASwBLAEsASwBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXAArACsAXABcAFwAXABcACsAKwArACsAKwArACsAKwArACsAKwBcAFwAXABcAFwAXABcAFwAXABcAFwAXAArACsAKwArAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAXAArACsAKwAqACoAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAArACsAHgAeAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcACoAKgAqACoAKgAqACoAKgAqACoAKwAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKwArAAQASwBLAEsASwBLAEsASwBLAEsASwArACsAKwArACsAKwBLAEsASwBLAEsASwBLAEsASwBLACsAKwArACsAKwArACoAKgAqACoAKgAqACoAXAAqACoAKgAqACoAKgArACsABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsABAAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABABQAFAAUABQAFAAUABQACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwANAA0AHgANAA0ADQANAB4AHgAeAB4AHgAeAB4AHgAeAB4ABAAEAAQABAAEAAQABAAEAAQAHgAeAB4AHgAeAB4AHgAeAB4AKwArACsABAAEAAQAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABABQAFAASwBLAEsASwBLAEsASwBLAEsASwBQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwAeAB4AHgAeAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArAA0ADQANAA0ADQBLAEsASwBLAEsASwBLAEsASwBLACsAKwArAFAAUABQAEsASwBLAEsASwBLAEsASwBLAEsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAA0ADQBQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUAAeAB4AHgAeAB4AHgAeAB4AKwArACsAKwArACsAKwArAAQABAAEAB4ABAAEAAQABAAEAAQABAAEAAQABAAEAAQABABQAFAAUABQAAQAUABQAFAAUABQAFAABABQAFAABAAEAAQAUAArACsAKwArACsABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsABAAEAAQABAAEAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwArAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAKwBQACsAUAArAFAAKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeACsAKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArAB4AHgAeAB4AHgAeAB4AHgBQAB4AHgAeAFAAUABQACsAHgAeAB4AHgAeAB4AHgAeAB4AHgBQAFAAUABQACsAKwAeAB4AHgAeAB4AHgArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwArAFAAUABQACsAHgAeAB4AHgAeAB4AHgAOAB4AKwANAA0ADQANAA0ADQANAAkADQANAA0ACAAEAAsABAAEAA0ACQANAA0ADAAdAB0AHgAXABcAFgAXABcAFwAWABcAHQAdAB4AHgAUABQAFAANAAEAAQAEAAQABAAEAAQACQAaABoAGgAaABoAGgAaABoAHgAXABcAHQAVABUAHgAeAB4AHgAeAB4AGAAWABEAFQAVABUAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4ADQAeAA0ADQANAA0AHgANAA0ADQAHAB4AHgAeAB4AKwAEAAQABAAEAAQABAAEAAQABAAEAFAAUAArACsATwBQAFAAUABQAFAAHgAeAB4AFgARAE8AUABPAE8ATwBPAFAAUABQAFAAUAAeAB4AHgAWABEAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArABsAGwAbABsAGwAbABsAGgAbABsAGwAbABsAGwAbABsAGwAbABsAGwAbABsAGgAbABsAGwAbABoAGwAbABoAGwAbABsAGwAbABsAGwAbABsAGwAbABsAGwAbABsAGwAbAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAHgAeAFAAGgAeAB0AHgBQAB4AGgAeAB4AHgAeAB4AHgAeAB4AHgBPAB4AUAAbAB4AHgBQAFAAUABQAFAAHgAeAB4AHQAdAB4AUAAeAFAAHgBQAB4AUABPAFAAUAAeAB4AHgAeAB4AHgAeAFAAUABQAFAAUAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAFAAHgBQAFAAUABQAE8ATwBQAFAAUABQAFAATwBQAFAATwBQAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAFAAUABQAFAATwBPAE8ATwBPAE8ATwBPAE8ATwBQAFAAUABQAFAAUABQAFAAUAAeAB4AUABQAFAAUABPAB4AHgArACsAKwArAB0AHQAdAB0AHQAdAB0AHQAdAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB0AHgAdAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAdAB4AHQAdAB4AHgAeAB0AHQAeAB4AHQAeAB4AHgAdAB4AHQAbABsAHgAdAB4AHgAeAB4AHQAeAB4AHQAdAB0AHQAeAB4AHQAeAB0AHgAdAB0AHQAdAB0AHQAeAB0AHgAeAB4AHgAeAB0AHQAdAB0AHgAeAB4AHgAdAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAdAB4AHgAeAB0AHgAeAB4AHgAeAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAdAB0AHgAeAB0AHQAdAB0AHgAeAB0AHQAeAB4AHQAdAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB0AHQAeAB4AHQAdAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHQAeAB4AHgAdAB4AHgAeAB4AHgAeAB4AHQAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AFAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeABYAEQAWABEAHgAeAB4AHgAeAB4AHQAeAB4AHgAeAB4AHgAeACUAJQAeAB4AHgAeAB4AHgAeAB4AHgAWABEAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AJQAlACUAJQAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAFAAHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHgAeAB4AHgAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAeAB4AHQAdAB0AHQAeAB4AHgAeAB4AHgAeAB4AHgAeAB0AHQAeAB0AHQAdAB0AHQAdAB0AHgAeAB4AHgAeAB4AHgAeAB0AHQAeAB4AHQAdAB4AHgAeAB4AHQAdAB4AHgAeAB4AHQAdAB0AHgAeAB0AHgAeAB0AHQAdAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAdAB0AHQAdAB4AHgAeAB4AHgAeAB4AHgAeAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAlACUAJQAlAB4AHQAdAB4AHgAdAB4AHgAeAB4AHQAdAB4AHgAeAB4AJQAlAB0AHQAlAB4AJQAlACUAIAAlACUAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAlACUAJQAeAB4AHgAeAB0AHgAdAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAdAB0AHgAdAB0AHQAeAB0AJQAdAB0AHgAdAB0AHgAdAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeACUAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHQAdAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAlACUAJQAlACUAJQAlACUAJQAlACUAJQAdAB0AHQAdACUAHgAlACUAJQAdACUAJQAdAB0AHQAlACUAHQAdACUAHQAdACUAJQAlAB4AHQAeAB4AHgAeAB0AHQAlAB0AHQAdAB0AHQAdACUAJQAlACUAJQAdACUAJQAgACUAHQAdACUAJQAlACUAJQAlACUAJQAeAB4AHgAlACUAIAAgACAAIAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB0AHgAeAB4AFwAXABcAFwAXABcAHgATABMAJQAeAB4AHgAWABEAFgARABYAEQAWABEAFgARABYAEQAWABEATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeABYAEQAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAWABEAFgARABYAEQAWABEAFgARAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AFgARABYAEQAWABEAFgARABYAEQAWABEAFgARABYAEQAWABEAFgARABYAEQAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAWABEAFgARAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AFgARAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAdAB0AHQAdAB0AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AUABQAFAAUAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAEAAQABAAeAB4AKwArACsAKwArABMADQANAA0AUAATAA0AUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAUAANACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXAA0ADQANAA0ADQANAA0ADQAeAA0AFgANAB4AHgAXABcAHgAeABcAFwAWABEAFgARABYAEQAWABEADQANAA0ADQATAFAADQANAB4ADQANAB4AHgAeAB4AHgAMAAwADQANAA0AHgANAA0AFgANAA0ADQANAA0ADQANAA0AHgANAB4ADQANAB4AHgAeACsAKwArACsAKwArACsAKwArACsAKwArACsAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACsAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAKwArACsAKwArACsAKwArACsAKwArACsAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAlACUAJQAlACUAJQAlACUAJQAlACUAJQArACsAKwArAA0AEQARACUAJQBHAFcAVwAWABEAFgARABYAEQAWABEAFgARACUAJQAWABEAFgARABYAEQAWABEAFQAWABEAEQAlAFcAVwBXAFcAVwBXAFcAVwBXAAQABAAEAAQABAAEACUAVwBXAFcAVwA2ACUAJQBXAFcAVwBHAEcAJQAlACUAKwBRAFcAUQBXAFEAVwBRAFcAUQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFEAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBRAFcAUQBXAFEAVwBXAFcAVwBXAFcAUQBXAFcAVwBXAFcAVwBRAFEAKwArAAQABAAVABUARwBHAFcAFQBRAFcAUQBXAFEAVwBRAFcAUQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFEAVwBRAFcAUQBXAFcAVwBXAFcAVwBRAFcAVwBXAFcAVwBXAFEAUQBXAFcAVwBXABUAUQBHAEcAVwArACsAKwArACsAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAKwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAKwAlACUAVwBXAFcAVwAlACUAJQAlACUAJQAlACUAJQAlACsAKwArACsAKwArACsAKwArACsAKwArAFEAUQBRAFEAUQBRAFEAUQBRAFEAUQBRAFEAUQBRAFEAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQArAFcAVwBXAFcAVwBXAFcAVwBXAFcAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQBPAE8ATwBPAE8ATwBPAE8AJQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXACUAJQAlAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAEcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAKwArACsAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAADQATAA0AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABLAEsASwBLAEsASwBLAEsASwBLAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAFAABAAEAAQABAAeAAQABAAEAAQABAAEAAQABAAEAAQAHgBQAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AUABQAAQABABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAeAA0ADQANAA0ADQArACsAKwArACsAKwArACsAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAFAAUABQAFAAUABQAFAAUABQAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AUAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgBQAB4AHgAeAB4AHgAeAFAAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAHgAeAB4AHgAeAB4AHgAeAB4AKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAeAB4AUABQAFAAUABQAFAAUABQAFAAUABQAAQAUABQAFAABABQAFAAUABQAAQAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAAeAB4AHgAeAAQAKwArACsAUABQAFAAUABQAFAAHgAeABoAHgArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAADgAOABMAEwArACsAKwArACsAKwArACsABAAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwANAA0ASwBLAEsASwBLAEsASwBLAEsASwArACsAKwArACsAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABABQAFAAUABQAFAAUAAeAB4AHgBQAA4AUABQAAQAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAA0ADQBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArACsAKwArACsAKwArACsAKwArAB4AWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYAFgAWABYACsAKwArAAQAHgAeAB4AHgAeAB4ADQANAA0AHgAeAB4AHgArAFAASwBLAEsASwBLAEsASwBLAEsASwArACsAKwArAB4AHgBcAFwAXABcAFwAKgBcAFwAXABcAFwAXABcAFwAXABcAEsASwBLAEsASwBLAEsASwBLAEsAXABcAFwAXABcACsAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwArAFAAUABQAAQAUABQAFAAUABQAFAAUABQAAQABAArACsASwBLAEsASwBLAEsASwBLAEsASwArACsAHgANAA0ADQBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAKgAqACoAXAAqACoAKgBcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXAAqAFwAKgAqACoAXABcACoAKgBcAFwAXABcAFwAKgAqAFwAKgBcACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFwAXABcACoAKgBQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAA0ADQBQAFAAUAAEAAQAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUAArACsAUABQAFAAUABQAFAAKwArAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQADQAEAAQAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAVABVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBUAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVAFUAVQBVACsAKwArACsAKwArACsAKwArACsAKwArAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAWQBZAFkAKwArACsAKwBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAWgBaAFoAKwArACsAKwAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYABgAGAAYAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXACUAJQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAJQAlACUAJQAlACUAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAKwArACsAKwArAFYABABWAFYAVgBWAFYAVgBWAFYAVgBWAB4AVgBWAFYAVgBWAFYAVgBWAFYAVgBWAFYAVgArAFYAVgBWAFYAVgArAFYAKwBWAFYAKwBWAFYAKwBWAFYAVgBWAFYAVgBWAFYAVgBWAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAEQAWAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUAAaAB4AKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAGAARABEAGAAYABMAEwAWABEAFAArACsAKwArACsAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACUAJQAlACUAJQAWABEAFgARABYAEQAWABEAFgARABYAEQAlACUAFgARACUAJQAlACUAJQAlACUAEQAlABEAKwAVABUAEwATACUAFgARABYAEQAWABEAJQAlACUAJQAlACUAJQAlACsAJQAbABoAJQArACsAKwArAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAAcAKwATACUAJQAbABoAJQAlABYAEQAlACUAEQAlABEAJQBXAFcAVwBXAFcAVwBXAFcAVwBXABUAFQAlACUAJQATACUAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXABYAJQARACUAJQAlAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwAWACUAEQAlABYAEQARABYAEQARABUAVwBRAFEAUQBRAFEAUQBRAFEAUQBRAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAEcARwArACsAVwBXAFcAVwBXAFcAKwArAFcAVwBXAFcAVwBXACsAKwBXAFcAVwBXAFcAVwArACsAVwBXAFcAKwArACsAGgAbACUAJQAlABsAGwArAB4AHgAeAB4AHgAeAB4AKwArACsAKwArACsAKwArACsAKwAEAAQABAAQAB0AKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsADQANAA0AKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArAB4AHgAeAB4AHgAeAB4AHgAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgBQAFAAHgAeAB4AKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAAQAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAA0AUABQAFAAUAArACsAKwArAFAAUABQAFAAUABQAFAAUAANAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwAeACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAKwArAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUAArACsAKwBQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwANAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAeAB4AUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUAArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArAA0AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAUABQAFAAUABQAAQABAAEACsABAAEACsAKwArACsAKwAEAAQABAAEAFAAUABQAFAAKwBQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAAQABAAEACsAKwArACsABABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAA0ADQANAA0ADQANAA0ADQAeACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAeAFAAUABQAFAAUABQAFAAUAAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAArACsAKwArAFAAUABQAFAAUAANAA0ADQANAA0ADQAUACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsADQANAA0ADQANAA0ADQBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAB4AHgAeAB4AKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAAQABAAEAAQAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUAArAAQABAANACsAKwBQAFAAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAAQABAAEAAQABAAEAAQABAAEAAQABABQAFAAUABQAB4AHgAeAB4AHgArACsAKwArACsAKwAEAAQABAAEAAQABAAEAA0ADQAeAB4AHgAeAB4AKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsABABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAQABAAEAAQABAAEAAQABAAEAAQABAAeAB4AHgANAA0ADQANACsAKwArACsAKwArACsAKwArACsAKwAeACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArACsAKwBLAEsASwBLAEsASwBLAEsASwBLACsAKwArACsAKwArAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEACsASwBLAEsASwBLAEsASwBLAEsASwANAA0ADQANAFAABAAEAFAAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAeAA4AUAArACsAKwArACsAKwArACsAKwAEAFAAUABQAFAADQANAB4ADQAEAAQABAAEAB4ABAAEAEsASwBLAEsASwBLAEsASwBLAEsAUAAOAFAADQANAA0AKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAANAA0AHgANAA0AHgAEACsAUABQAFAAUABQAFAAUAArAFAAKwBQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAA0AKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsABAAEAAQABAArAFAAUABQAFAAUABQAFAAUAArACsAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQACsAUABQAFAAUABQACsABAAEAFAABAAEAAQABAAEAAQABAArACsABAAEACsAKwAEAAQABAArACsAUAArACsAKwArACsAKwAEACsAKwArACsAKwBQAFAAUABQAFAABAAEACsAKwAEAAQABAAEAAQABAAEACsAKwArAAQABAAEAAQABAArACsAKwArACsAKwArACsAKwArACsABAAEAAQABAAEAAQABABQAFAAUABQAA0ADQANAA0AHgBLAEsASwBLAEsASwBLAEsASwBLAA0ADQArAB4ABABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAAQABAAEAFAAUAAeAFAAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAArACsABAAEAAQABAAEAAQABAAEAAQADgANAA0AEwATAB4AHgAeAA0ADQANAA0ADQANAA0ADQANAA0ADQANAA0ADQANAFAAUABQAFAABAAEACsAKwAEAA0ADQAeAFAAKwArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAFAAKwArACsAKwArACsAKwBLAEsASwBLAEsASwBLAEsASwBLACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAXABcAFwAKwArACoAKgAqACoAKgAqACoAKgAqACoAKgAqACoAKgAqACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwBcAFwADQANAA0AKgBQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAeACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwBQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAKwArAFAAKwArAFAAUABQAFAAUABQAFAAUAArAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQAKwAEAAQAKwArAAQABAAEAAQAUAAEAFAABAAEAA0ADQANACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAArACsABAAEAAQABAAEAAQABABQAA4AUAAEACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAABAAEAAQABAAEAAQABAAEAAQABABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAFAABAAEAAQABAAOAB4ADQANAA0ADQAOAB4ABAArACsAKwArACsAKwArACsAUAAEAAQABAAEAAQABAAEAAQABAAEAAQAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAA0ADQANAFAADgAOAA4ADQANACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAEAAQABAAEACsABAAEAAQABAAEAAQABAAEAFAADQANAA0ADQANACsAKwArACsAKwArACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwAOABMAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQACsAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAArACsAKwAEACsABAAEACsABAAEAAQABAAEAAQABABQAAQAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAUABQAFAAUABQAFAAKwBQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQAKwAEAAQAKwAEAAQABAAEAAQAUAArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAABAAEAAQABAAeAB4AKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAB4AHgAeAB4AHgAeAB4AHgAaABoAGgAaAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwArACsAKwArACsAKwArAA0AUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsADQANAA0ADQANACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAASABIAEgAQwBDAEMAUABQAFAAUABDAFAAUABQAEgAQwBIAEMAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAASABDAEMAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwAJAAkACQAJAAkACQAJABYAEQArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABIAEMAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwANAA0AKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArAAQABAAEAAQABAANACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEAA0ADQANAB4AHgAeAB4AHgAeAFAAUABQAFAADQAeACsAKwArACsAKwArACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwArAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAANAA0AHgAeACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwAEAFAABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArACsAKwArACsAKwAEAAQABAAEAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAARwBHABUARwAJACsAKwArACsAKwArACsAKwArACsAKwAEAAQAKwArACsAKwArACsAKwArACsAKwArACsAKwArAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXACsAKwArACsAKwArACsAKwBXAFcAVwBXAFcAVwBXAFcAVwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUQBRAFEAKwArACsAKwArACsAKwArACsAKwArACsAKwBRAFEAUQBRACsAKwArACsAKwArACsAKwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUAArACsAHgAEAAQADQAEAAQABAAEACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwArACsAKwArAB4AHgAeAB4AHgAeAB4AKwArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAAQABAAEAAQABAAeAB4AHgAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAB4AHgAEAAQABAAEAAQABAAEAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4ABAAEAAQABAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4ABAAEAAQAHgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwArACsAKwArACsAKwArACsAKwArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwArACsAKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwBQAFAAKwArAFAAKwArAFAAUAArACsAUABQAFAAUAArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeACsAUAArAFAAUABQAFAAUABQAFAAKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwBQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAHgAeAFAAUABQAFAAUAArAFAAKwArACsAUABQAFAAUABQAFAAUAArAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAHgBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgBQAFAAUABQAFAAUABQAFAAUABQAFAAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAB4AHgAeAB4AHgAeAB4AHgAeACsAKwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAEsASwBLAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAeAB4AHgAeAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAeAB4AHgAeAB4AHgAeAB4ABAAeAB4AHgAeAB4AHgAeAB4AHgAeAAQAHgAeAA0ADQANAA0AHgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAEAAQABAAEAAQAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAAQABAAEAAQABAAEAAQAKwAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArAAQABAAEAAQABAAEAAQAKwAEAAQAKwAEAAQABAAEAAQAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwAEAAQABAAEAAQABAAEAFAAUABQAFAAUABQAFAAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwBQAB4AKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArABsAUABQAFAAUABQACsAKwBQAFAAUABQAFAAUABQAFAAUAAEAAQABAAEAAQABAAEACsAKwArACsAKwArACsAKwArAB4AHgAeAB4ABAAEAAQABAAEAAQABABQACsAKwArACsASwBLAEsASwBLAEsASwBLAEsASwArACsAKwArABYAFgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAGgBQAFAAUAAaAFAAUABQAFAAKwArACsAKwArACsAKwArACsAKwArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAeAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQACsAKwBQAFAAUABQACsAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwBQAFAAKwBQACsAKwBQACsAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAKwBQACsAUAArACsAKwArACsAKwBQACsAKwArACsAUAArAFAAKwBQACsAUABQAFAAKwBQAFAAKwBQACsAKwBQACsAUAArAFAAKwBQACsAUAArAFAAUAArAFAAKwArAFAAUABQAFAAKwBQAFAAUABQAFAAUABQACsAUABQAFAAUAArAFAAUABQAFAAKwBQACsAUABQAFAAUABQAFAAUABQAFAAUAArAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAArACsAKwArACsAUABQAFAAKwBQAFAAUABQAFAAKwBQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwAeAB4AKwArACsAKwArACsAKwArACsAKwArACsAKwArAE8ATwBPAE8ATwBPAE8ATwBPAE8ATwBPAE8AJQAlACUAHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHgAeAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB4AHgAeACUAJQAlAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAdAB0AHQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQApACkAKQApACkAKQApACkAKQApACkAKQApACkAKQApACkAKQApACkAKQApACkAKQApACkAJQAlACUAJQAlACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAeAB4AJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlAB4AHgAlACUAJQAlACUAHgAlACUAJQAlACUAIAAgACAAJQAlACAAJQAlACAAIAAgACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACEAIQAhACEAIQAlACUAIAAgACUAJQAgACAAIAAgACAAIAAgACAAIAAgACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAJQAlACUAIAAlACUAJQAlACAAIAAgACUAIAAgACAAJQAlACUAJQAlACUAJQAgACUAIAAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAHgAlAB4AJQAeACUAJQAlACUAJQAgACUAJQAlACUAHgAlAB4AHgAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlAB4AHgAeAB4AHgAeAB4AJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAeAB4AHgAeAB4AHgAeAB4AHgAeACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACAAIAAlACUAJQAlACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACAAJQAlACUAJQAgACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAHgAeAB4AHgAeAB4AHgAeACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAeAB4AHgAeAB4AHgAlACUAJQAlACUAJQAlACAAIAAgACUAJQAlACAAIAAgACAAIAAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeABcAFwAXABUAFQAVAB4AHgAeAB4AJQAlACUAIAAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACAAIAAgACUAJQAlACUAJQAlACUAJQAlACAAJQAlACUAJQAlACUAJQAlACUAJQAlACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AJQAlACUAJQAlACUAJQAlACUAJQAlACUAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AJQAlACUAJQAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeACUAJQAlACUAJQAlACUAJQAeAB4AHgAeAB4AHgAeAB4AHgAeACUAJQAlACUAJQAlAB4AHgAeAB4AHgAeAB4AHgAlACUAJQAlACUAJQAlACUAHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAgACUAJQAgACUAJQAlACUAJQAlACUAJQAgACAAIAAgACAAIAAgACAAJQAlACUAJQAlACUAIAAlACUAJQAlACUAJQAlACUAJQAgACAAIAAgACAAIAAgACAAIAAgACUAJQAgACAAIAAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAgACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACAAIAAlACAAIAAlACAAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAgACAAIAAlACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAJQAlAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AKwAeAB4AHgAeAB4AHgAeAB4AHgAeAB4AHgArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAEsASwBLAEsASwBLAEsASwBLAEsAKwArACsAKwArACsAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAKwArAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXACUAJQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwAlACUAJQAlACUAJQAlACUAJQAlACUAVwBXACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQBXAFcAVwBXAFcAVwBXAFcAVwBXAFcAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAJQAlACUAKwAEACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArACsAKwArAA==' var LETTER_NUMBER_MODIFIER = 50 var BK = 1 var CR$1 = 2 var LF$1 = 3 var CM = 4 var NL = 5 var WJ = 7 var ZW = 8 var GL = 9 var SP = 10 var ZWJ$1 = 11 var B2 = 12 var BA = 13 var BB = 14 var HY = 15 var CB = 16 var CL = 17 var CP = 18 var EX = 19 var IN = 20 var NS = 21 var OP = 22 var QU = 23 var IS = 24 var NU = 25 var PO = 26 var PR = 27 var SY = 28 var AI = 29 var AL = 30 var CJ = 31 var EB = 32 var EM = 33 var H2 = 34 var H3 = 35 var HL = 36 var ID = 37 var JL = 38 var JV = 39 var JT = 40 var RI$1 = 41 var SA = 42 var XX = 43 var ea_OP = [9001, 65288] var BREAK_MANDATORY = '!' var BREAK_NOT_ALLOWED$1 = '\xD7' var BREAK_ALLOWED$1 = '\xF7' var UnicodeTrie$1 = createTrieFromBase64$1(base64$1) var ALPHABETICS = [AL, HL] var HARD_LINE_BREAKS = [BK, CR$1, LF$1, NL] var SPACE$1 = [SP, ZW] var PREFIX_POSTFIX = [PR, PO] var LINE_BREAKS = HARD_LINE_BREAKS.concat(SPACE$1) var KOREAN_SYLLABLE_BLOCK = [JL, JV, JT, H2, H3] var HYPHEN = [HY, BA] var codePointsToCharacterClasses = function (codePoints, lineBreak2) { if (lineBreak2 === void 0) { lineBreak2 = 'strict' } var types2 = [] var indices = [] var categories = [] codePoints.forEach(function (codePoint, index2) { var classType = UnicodeTrie$1.get(codePoint) if (classType > LETTER_NUMBER_MODIFIER) { categories.push(true) classType -= LETTER_NUMBER_MODIFIER } else { categories.push(false) } if (['normal', 'auto', 'loose'].indexOf(lineBreak2) !== -1) { if ([8208, 8211, 12316, 12448].indexOf(codePoint) !== -1) { indices.push(index2) return types2.push(CB) } } if (classType === CM || classType === ZWJ$1) { if (index2 === 0) { indices.push(index2) return types2.push(AL) } var prev = types2[index2 - 1] if (LINE_BREAKS.indexOf(prev) === -1) { indices.push(indices[index2 - 1]) return types2.push(prev) } indices.push(index2) return types2.push(AL) } indices.push(index2) if (classType === CJ) { return types2.push(lineBreak2 === 'strict' ? NS : ID) } if (classType === SA) { return types2.push(AL) } if (classType === AI) { return types2.push(AL) } if (classType === XX) { if ( (codePoint >= 131072 && codePoint <= 196605) || (codePoint >= 196608 && codePoint <= 262141) ) { return types2.push(ID) } else { return types2.push(AL) } } types2.push(classType) }) return [indices, types2, categories] } var isAdjacentWithSpaceIgnored = function (a2, b2, currentIndex, classTypes) { var current2 = classTypes[currentIndex] if (Array.isArray(a2) ? a2.indexOf(current2) !== -1 : a2 === current2) { var i2 = currentIndex while (i2 <= classTypes.length) { i2++ var next = classTypes[i2] if (next === b2) { return true } if (next !== SP) { break } } } if (current2 === SP) { var i2 = currentIndex while (i2 > 0) { i2-- var prev = classTypes[i2] if (Array.isArray(a2) ? a2.indexOf(prev) !== -1 : a2 === prev) { var n2 = currentIndex while (n2 <= classTypes.length) { n2++ var next = classTypes[n2] if (next === b2) { return true } if (next !== SP) { break } } } if (prev !== SP) { break } } } return false } var previousNonSpaceClassType = function (currentIndex, classTypes) { var i2 = currentIndex while (i2 >= 0) { var type4 = classTypes[i2] if (type4 === SP) { i2-- } else { return type4 } } return 0 } var _lineBreakAtIndex = function ( codePoints, classTypes, indicies, index2, forbiddenBreaks ) { if (indicies[index2] === 0) { return BREAK_NOT_ALLOWED$1 } var currentIndex = index2 - 1 if ( Array.isArray(forbiddenBreaks) && forbiddenBreaks[currentIndex] === true ) { return BREAK_NOT_ALLOWED$1 } var beforeIndex = currentIndex - 1 var afterIndex = currentIndex + 1 var current2 = classTypes[currentIndex] var before2 = beforeIndex >= 0 ? classTypes[beforeIndex] : 0 var next = classTypes[afterIndex] if (current2 === CR$1 && next === LF$1) { return BREAK_NOT_ALLOWED$1 } if (HARD_LINE_BREAKS.indexOf(current2) !== -1) { return BREAK_MANDATORY } if (HARD_LINE_BREAKS.indexOf(next) !== -1) { return BREAK_NOT_ALLOWED$1 } if (SPACE$1.indexOf(next) !== -1) { return BREAK_NOT_ALLOWED$1 } if (previousNonSpaceClassType(currentIndex, classTypes) === ZW) { return BREAK_ALLOWED$1 } if (UnicodeTrie$1.get(codePoints[currentIndex]) === ZWJ$1) { return BREAK_NOT_ALLOWED$1 } if ( (current2 === EB || current2 === EM) && UnicodeTrie$1.get(codePoints[afterIndex]) === ZWJ$1 ) { return BREAK_NOT_ALLOWED$1 } if (current2 === WJ || next === WJ) { return BREAK_NOT_ALLOWED$1 } if (current2 === GL) { return BREAK_NOT_ALLOWED$1 } if ([SP, BA, HY].indexOf(current2) === -1 && next === GL) { return BREAK_NOT_ALLOWED$1 } if ([CL, CP, EX, IS, SY].indexOf(next) !== -1) { return BREAK_NOT_ALLOWED$1 } if (previousNonSpaceClassType(currentIndex, classTypes) === OP) { return BREAK_NOT_ALLOWED$1 } if (isAdjacentWithSpaceIgnored(QU, OP, currentIndex, classTypes)) { return BREAK_NOT_ALLOWED$1 } if (isAdjacentWithSpaceIgnored([CL, CP], NS, currentIndex, classTypes)) { return BREAK_NOT_ALLOWED$1 } if (isAdjacentWithSpaceIgnored(B2, B2, currentIndex, classTypes)) { return BREAK_NOT_ALLOWED$1 } if (current2 === SP) { return BREAK_ALLOWED$1 } if (current2 === QU || next === QU) { return BREAK_NOT_ALLOWED$1 } if (next === CB || current2 === CB) { return BREAK_ALLOWED$1 } if ([BA, HY, NS].indexOf(next) !== -1 || current2 === BB) { return BREAK_NOT_ALLOWED$1 } if (before2 === HL && HYPHEN.indexOf(current2) !== -1) { return BREAK_NOT_ALLOWED$1 } if (current2 === SY && next === HL) { return BREAK_NOT_ALLOWED$1 } if (next === IN) { return BREAK_NOT_ALLOWED$1 } if ( (ALPHABETICS.indexOf(next) !== -1 && current2 === NU) || (ALPHABETICS.indexOf(current2) !== -1 && next === NU) ) { return BREAK_NOT_ALLOWED$1 } if ( (current2 === PR && [ID, EB, EM].indexOf(next) !== -1) || ([ID, EB, EM].indexOf(current2) !== -1 && next === PO) ) { return BREAK_NOT_ALLOWED$1 } if ( (ALPHABETICS.indexOf(current2) !== -1 && PREFIX_POSTFIX.indexOf(next) !== -1) || (PREFIX_POSTFIX.indexOf(current2) !== -1 && ALPHABETICS.indexOf(next) !== -1) ) { return BREAK_NOT_ALLOWED$1 } if ( ([PR, PO].indexOf(current2) !== -1 && (next === NU || ([OP, HY].indexOf(next) !== -1 && classTypes[afterIndex + 1] === NU))) || ([OP, HY].indexOf(current2) !== -1 && next === NU) || (current2 === NU && [NU, SY, IS].indexOf(next) !== -1) ) { return BREAK_NOT_ALLOWED$1 } if ([NU, SY, IS, CL, CP].indexOf(next) !== -1) { var prevIndex = currentIndex while (prevIndex >= 0) { var type4 = classTypes[prevIndex] if (type4 === NU) { return BREAK_NOT_ALLOWED$1 } else if ([SY, IS].indexOf(type4) !== -1) { prevIndex-- } else { break } } } if ([PR, PO].indexOf(next) !== -1) { var prevIndex = [CL, CP].indexOf(current2) !== -1 ? beforeIndex : currentIndex while (prevIndex >= 0) { var type4 = classTypes[prevIndex] if (type4 === NU) { return BREAK_NOT_ALLOWED$1 } else if ([SY, IS].indexOf(type4) !== -1) { prevIndex-- } else { break } } } if ( (JL === current2 && [JL, JV, H2, H3].indexOf(next) !== -1) || ([JV, H2].indexOf(current2) !== -1 && [JV, JT].indexOf(next) !== -1) || ([JT, H3].indexOf(current2) !== -1 && next === JT) ) { return BREAK_NOT_ALLOWED$1 } if ( (KOREAN_SYLLABLE_BLOCK.indexOf(current2) !== -1 && [IN, PO].indexOf(next) !== -1) || (KOREAN_SYLLABLE_BLOCK.indexOf(next) !== -1 && current2 === PR) ) { return BREAK_NOT_ALLOWED$1 } if ( ALPHABETICS.indexOf(current2) !== -1 && ALPHABETICS.indexOf(next) !== -1 ) { return BREAK_NOT_ALLOWED$1 } if (current2 === IS && ALPHABETICS.indexOf(next) !== -1) { return BREAK_NOT_ALLOWED$1 } if ( (ALPHABETICS.concat(NU).indexOf(current2) !== -1 && next === OP && ea_OP.indexOf(codePoints[afterIndex]) === -1) || (ALPHABETICS.concat(NU).indexOf(next) !== -1 && current2 === CP) ) { return BREAK_NOT_ALLOWED$1 } if (current2 === RI$1 && next === RI$1) { var i2 = indicies[currentIndex] var count2 = 1 while (i2 > 0) { i2-- if (classTypes[i2] === RI$1) { count2++ } else { break } } if (count2 % 2 !== 0) { return BREAK_NOT_ALLOWED$1 } } if (current2 === EB && next === EM) { return BREAK_NOT_ALLOWED$1 } return BREAK_ALLOWED$1 } var cssFormattedClasses = function (codePoints, options2) { if (!options2) { options2 = { lineBreak: 'normal', wordBreak: 'normal' } } var _a2 = codePointsToCharacterClasses(codePoints, options2.lineBreak), indicies = _a2[0], classTypes = _a2[1], isLetterNumber = _a2[2] if ( options2.wordBreak === 'break-all' || options2.wordBreak === 'break-word' ) { classTypes = classTypes.map(function (type4) { return [NU, AL, SA].indexOf(type4) !== -1 ? ID : type4 }) } var forbiddenBreakpoints = options2.wordBreak === 'keep-all' ? isLetterNumber.map(function (letterNumber, i2) { return ( letterNumber && codePoints[i2] >= 19968 && codePoints[i2] <= 40959 ) }) : void 0 return [indicies, classTypes, forbiddenBreakpoints] } var Break = (function () { function Break2(codePoints, lineBreak2, start2, end2) { this.codePoints = codePoints this.required = lineBreak2 === BREAK_MANDATORY this.start = start2 this.end = end2 } Break2.prototype.slice = function () { return fromCodePoint$1.apply( void 0, this.codePoints.slice(this.start, this.end) ) } return Break2 })() var LineBreaker = function (str, options2) { var codePoints = toCodePoints$1(str) var _a2 = cssFormattedClasses(codePoints, options2), indicies = _a2[0], classTypes = _a2[1], forbiddenBreakpoints = _a2[2] var length2 = codePoints.length var lastEnd = 0 var nextIndex = 0 return { next: function () { if (nextIndex >= length2) { return { done: true, value: null } } var lineBreak2 = BREAK_NOT_ALLOWED$1 while ( nextIndex < length2 && (lineBreak2 = _lineBreakAtIndex( codePoints, classTypes, indicies, ++nextIndex, forbiddenBreakpoints )) === BREAK_NOT_ALLOWED$1 ) {} if (lineBreak2 !== BREAK_NOT_ALLOWED$1 || nextIndex === length2) { var value2 = new Break(codePoints, lineBreak2, lastEnd, nextIndex) lastEnd = nextIndex return { value: value2, done: false } } return { done: true, value: null } }, } } var FLAG_UNRESTRICTED = 1 << 0 var FLAG_ID = 1 << 1 var FLAG_INTEGER = 1 << 2 var FLAG_NUMBER = 1 << 3 var LINE_FEED = 10 var SOLIDUS = 47 var REVERSE_SOLIDUS = 92 var CHARACTER_TABULATION = 9 var SPACE = 32 var QUOTATION_MARK = 34 var EQUALS_SIGN = 61 var NUMBER_SIGN = 35 var DOLLAR_SIGN = 36 var PERCENTAGE_SIGN = 37 var APOSTROPHE = 39 var LEFT_PARENTHESIS = 40 var RIGHT_PARENTHESIS = 41 var LOW_LINE = 95 var HYPHEN_MINUS = 45 var EXCLAMATION_MARK = 33 var LESS_THAN_SIGN = 60 var GREATER_THAN_SIGN = 62 var COMMERCIAL_AT = 64 var LEFT_SQUARE_BRACKET = 91 var RIGHT_SQUARE_BRACKET = 93 var CIRCUMFLEX_ACCENT = 61 var LEFT_CURLY_BRACKET = 123 var QUESTION_MARK = 63 var RIGHT_CURLY_BRACKET = 125 var VERTICAL_LINE = 124 var TILDE = 126 var CONTROL = 128 var REPLACEMENT_CHARACTER = 65533 var ASTERISK = 42 var PLUS_SIGN = 43 var COMMA = 44 var COLON = 58 var SEMICOLON = 59 var FULL_STOP = 46 var NULL = 0 var BACKSPACE = 8 var LINE_TABULATION = 11 var SHIFT_OUT = 14 var INFORMATION_SEPARATOR_ONE = 31 var DELETE = 127 var EOF$1 = -1 var ZERO = 48 var a$1 = 97 var e$2 = 101 var f$1 = 102 var u$1 = 117 var z$1 = 122 var A = 65 var E = 69 var F = 70 var U = 85 var Z = 90 var isDigit = function (codePoint) { return codePoint >= ZERO && codePoint <= 57 } var isSurrogateCodePoint = function (codePoint) { return codePoint >= 55296 && codePoint <= 57343 } var isHex = function (codePoint) { return ( isDigit(codePoint) || (codePoint >= A && codePoint <= F) || (codePoint >= a$1 && codePoint <= f$1) ) } var isLowerCaseLetter = function (codePoint) { return codePoint >= a$1 && codePoint <= z$1 } var isUpperCaseLetter = function (codePoint) { return codePoint >= A && codePoint <= Z } var isLetter = function (codePoint) { return isLowerCaseLetter(codePoint) || isUpperCaseLetter(codePoint) } var isNonASCIICodePoint = function (codePoint) { return codePoint >= CONTROL } var isWhiteSpace = function (codePoint) { return ( codePoint === LINE_FEED || codePoint === CHARACTER_TABULATION || codePoint === SPACE ) } var isNameStartCodePoint = function (codePoint) { return ( isLetter(codePoint) || isNonASCIICodePoint(codePoint) || codePoint === LOW_LINE ) } var isNameCodePoint = function (codePoint) { return ( isNameStartCodePoint(codePoint) || isDigit(codePoint) || codePoint === HYPHEN_MINUS ) } var isNonPrintableCodePoint = function (codePoint) { return ( (codePoint >= NULL && codePoint <= BACKSPACE) || codePoint === LINE_TABULATION || (codePoint >= SHIFT_OUT && codePoint <= INFORMATION_SEPARATOR_ONE) || codePoint === DELETE ) } var isValidEscape = function (c1, c2) { if (c1 !== REVERSE_SOLIDUS) { return false } return c2 !== LINE_FEED } var isIdentifierStart = function (c1, c2, c3) { if (c1 === HYPHEN_MINUS) { return isNameStartCodePoint(c2) || isValidEscape(c2, c3) } else if (isNameStartCodePoint(c1)) { return true } else if (c1 === REVERSE_SOLIDUS && isValidEscape(c1, c2)) { return true } return false } var isNumberStart = function (c1, c2, c3) { if (c1 === PLUS_SIGN || c1 === HYPHEN_MINUS) { if (isDigit(c2)) { return true } return c2 === FULL_STOP && isDigit(c3) } if (c1 === FULL_STOP) { return isDigit(c2) } return isDigit(c1) } var stringToNumber = function (codePoints) { var c2 = 0 var sign = 1 if (codePoints[c2] === PLUS_SIGN || codePoints[c2] === HYPHEN_MINUS) { if (codePoints[c2] === HYPHEN_MINUS) { sign = -1 } c2++ } var integers = [] while (isDigit(codePoints[c2])) { integers.push(codePoints[c2++]) } var int = integers.length ? parseInt(fromCodePoint$1.apply(void 0, integers), 10) : 0 if (codePoints[c2] === FULL_STOP) { c2++ } var fraction = [] while (isDigit(codePoints[c2])) { fraction.push(codePoints[c2++]) } var fracd = fraction.length var frac = fracd ? parseInt(fromCodePoint$1.apply(void 0, fraction), 10) : 0 if (codePoints[c2] === E || codePoints[c2] === e$2) { c2++ } var expsign = 1 if (codePoints[c2] === PLUS_SIGN || codePoints[c2] === HYPHEN_MINUS) { if (codePoints[c2] === HYPHEN_MINUS) { expsign = -1 } c2++ } var exponent = [] while (isDigit(codePoints[c2])) { exponent.push(codePoints[c2++]) } var exp = exponent.length ? parseInt(fromCodePoint$1.apply(void 0, exponent), 10) : 0 return ( sign * (int + frac * Math.pow(10, -fracd)) * Math.pow(10, expsign * exp) ) } var LEFT_PARENTHESIS_TOKEN = { type: 2, } var RIGHT_PARENTHESIS_TOKEN = { type: 3, } var COMMA_TOKEN = { type: 4 } var SUFFIX_MATCH_TOKEN = { type: 13 } var PREFIX_MATCH_TOKEN = { type: 8 } var COLUMN_TOKEN = { type: 21 } var DASH_MATCH_TOKEN = { type: 9 } var INCLUDE_MATCH_TOKEN = { type: 10 } var LEFT_CURLY_BRACKET_TOKEN = { type: 11, } var RIGHT_CURLY_BRACKET_TOKEN = { type: 12, } var SUBSTRING_MATCH_TOKEN = { type: 14 } var BAD_URL_TOKEN = { type: 23 } var BAD_STRING_TOKEN = { type: 1 } var CDO_TOKEN = { type: 25 } var CDC_TOKEN = { type: 24 } var COLON_TOKEN = { type: 26 } var SEMICOLON_TOKEN = { type: 27 } var LEFT_SQUARE_BRACKET_TOKEN = { type: 28, } var RIGHT_SQUARE_BRACKET_TOKEN = { type: 29, } var WHITESPACE_TOKEN = { type: 31 } var EOF_TOKEN = { type: 32 } var Tokenizer = (function () { function Tokenizer2() { this._value = [] } Tokenizer2.prototype.write = function (chunk2) { this._value = this._value.concat(toCodePoints$1(chunk2)) } Tokenizer2.prototype.read = function () { var tokens = [] var token = this.consumeToken() while (token !== EOF_TOKEN) { tokens.push(token) token = this.consumeToken() } return tokens } Tokenizer2.prototype.consumeToken = function () { var codePoint = this.consumeCodePoint() switch (codePoint) { case QUOTATION_MARK: return this.consumeStringToken(QUOTATION_MARK) case NUMBER_SIGN: var c1 = this.peekCodePoint(0) var c2 = this.peekCodePoint(1) var c3 = this.peekCodePoint(2) if (isNameCodePoint(c1) || isValidEscape(c2, c3)) { var flags = isIdentifierStart(c1, c2, c3) ? FLAG_ID : FLAG_UNRESTRICTED var value2 = this.consumeName() return { type: 5, value: value2, flags } } break case DOLLAR_SIGN: if (this.peekCodePoint(0) === EQUALS_SIGN) { this.consumeCodePoint() return SUFFIX_MATCH_TOKEN } break case APOSTROPHE: return this.consumeStringToken(APOSTROPHE) case LEFT_PARENTHESIS: return LEFT_PARENTHESIS_TOKEN case RIGHT_PARENTHESIS: return RIGHT_PARENTHESIS_TOKEN case ASTERISK: if (this.peekCodePoint(0) === EQUALS_SIGN) { this.consumeCodePoint() return SUBSTRING_MATCH_TOKEN } break case PLUS_SIGN: if ( isNumberStart(codePoint, this.peekCodePoint(0), this.peekCodePoint(1)) ) { this.reconsumeCodePoint(codePoint) return this.consumeNumericToken() } break case COMMA: return COMMA_TOKEN case HYPHEN_MINUS: var e1 = codePoint var e2 = this.peekCodePoint(0) var e3 = this.peekCodePoint(1) if (isNumberStart(e1, e2, e3)) { this.reconsumeCodePoint(codePoint) return this.consumeNumericToken() } if (isIdentifierStart(e1, e2, e3)) { this.reconsumeCodePoint(codePoint) return this.consumeIdentLikeToken() } if (e2 === HYPHEN_MINUS && e3 === GREATER_THAN_SIGN) { this.consumeCodePoint() this.consumeCodePoint() return CDC_TOKEN } break case FULL_STOP: if ( isNumberStart(codePoint, this.peekCodePoint(0), this.peekCodePoint(1)) ) { this.reconsumeCodePoint(codePoint) return this.consumeNumericToken() } break case SOLIDUS: if (this.peekCodePoint(0) === ASTERISK) { this.consumeCodePoint() while (true) { var c4 = this.consumeCodePoint() if (c4 === ASTERISK) { c4 = this.consumeCodePoint() if (c4 === SOLIDUS) { return this.consumeToken() } } if (c4 === EOF$1) { return this.consumeToken() } } } break case COLON: return COLON_TOKEN case SEMICOLON: return SEMICOLON_TOKEN case LESS_THAN_SIGN: if ( this.peekCodePoint(0) === EXCLAMATION_MARK && this.peekCodePoint(1) === HYPHEN_MINUS && this.peekCodePoint(2) === HYPHEN_MINUS ) { this.consumeCodePoint() this.consumeCodePoint() return CDO_TOKEN } break case COMMERCIAL_AT: var a1 = this.peekCodePoint(0) var a2 = this.peekCodePoint(1) var a3 = this.peekCodePoint(2) if (isIdentifierStart(a1, a2, a3)) { var value2 = this.consumeName() return { type: 7, value: value2 } } break case LEFT_SQUARE_BRACKET: return LEFT_SQUARE_BRACKET_TOKEN case REVERSE_SOLIDUS: if (isValidEscape(codePoint, this.peekCodePoint(0))) { this.reconsumeCodePoint(codePoint) return this.consumeIdentLikeToken() } break case RIGHT_SQUARE_BRACKET: return RIGHT_SQUARE_BRACKET_TOKEN case CIRCUMFLEX_ACCENT: if (this.peekCodePoint(0) === EQUALS_SIGN) { this.consumeCodePoint() return PREFIX_MATCH_TOKEN } break case LEFT_CURLY_BRACKET: return LEFT_CURLY_BRACKET_TOKEN case RIGHT_CURLY_BRACKET: return RIGHT_CURLY_BRACKET_TOKEN case u$1: case U: var u1 = this.peekCodePoint(0) var u2 = this.peekCodePoint(1) if (u1 === PLUS_SIGN && (isHex(u2) || u2 === QUESTION_MARK)) { this.consumeCodePoint() this.consumeUnicodeRangeToken() } this.reconsumeCodePoint(codePoint) return this.consumeIdentLikeToken() case VERTICAL_LINE: if (this.peekCodePoint(0) === EQUALS_SIGN) { this.consumeCodePoint() return DASH_MATCH_TOKEN } if (this.peekCodePoint(0) === VERTICAL_LINE) { this.consumeCodePoint() return COLUMN_TOKEN } break case TILDE: if (this.peekCodePoint(0) === EQUALS_SIGN) { this.consumeCodePoint() return INCLUDE_MATCH_TOKEN } break case EOF$1: return EOF_TOKEN } if (isWhiteSpace(codePoint)) { this.consumeWhiteSpace() return WHITESPACE_TOKEN } if (isDigit(codePoint)) { this.reconsumeCodePoint(codePoint) return this.consumeNumericToken() } if (isNameStartCodePoint(codePoint)) { this.reconsumeCodePoint(codePoint) return this.consumeIdentLikeToken() } return { type: 6, value: fromCodePoint$1(codePoint) } } Tokenizer2.prototype.consumeCodePoint = function () { var value2 = this._value.shift() return typeof value2 === 'undefined' ? -1 : value2 } Tokenizer2.prototype.reconsumeCodePoint = function (codePoint) { this._value.unshift(codePoint) } Tokenizer2.prototype.peekCodePoint = function (delta) { if (delta >= this._value.length) { return -1 } return this._value[delta] } Tokenizer2.prototype.consumeUnicodeRangeToken = function () { var digits = [] var codePoint = this.consumeCodePoint() while (isHex(codePoint) && digits.length < 6) { digits.push(codePoint) codePoint = this.consumeCodePoint() } var questionMarks = false while (codePoint === QUESTION_MARK && digits.length < 6) { digits.push(codePoint) codePoint = this.consumeCodePoint() questionMarks = true } if (questionMarks) { var start_1 = parseInt( fromCodePoint$1.apply( void 0, digits.map(function (digit) { return digit === QUESTION_MARK ? ZERO : digit }) ), 16 ) var end2 = parseInt( fromCodePoint$1.apply( void 0, digits.map(function (digit) { return digit === QUESTION_MARK ? F : digit }) ), 16 ) return { type: 30, start: start_1, end: end2 } } var start2 = parseInt(fromCodePoint$1.apply(void 0, digits), 16) if ( this.peekCodePoint(0) === HYPHEN_MINUS && isHex(this.peekCodePoint(1)) ) { this.consumeCodePoint() codePoint = this.consumeCodePoint() var endDigits = [] while (isHex(codePoint) && endDigits.length < 6) { endDigits.push(codePoint) codePoint = this.consumeCodePoint() } var end2 = parseInt(fromCodePoint$1.apply(void 0, endDigits), 16) return { type: 30, start: start2, end: end2 } } else { return { type: 30, start: start2, end: start2 } } } Tokenizer2.prototype.consumeIdentLikeToken = function () { var value2 = this.consumeName() if ( value2.toLowerCase() === 'url' && this.peekCodePoint(0) === LEFT_PARENTHESIS ) { this.consumeCodePoint() return this.consumeUrlToken() } else if (this.peekCodePoint(0) === LEFT_PARENTHESIS) { this.consumeCodePoint() return { type: 19, value: value2 } } return { type: 20, value: value2 } } Tokenizer2.prototype.consumeUrlToken = function () { var value2 = [] this.consumeWhiteSpace() if (this.peekCodePoint(0) === EOF$1) { return { type: 22, value: '' } } var next = this.peekCodePoint(0) if (next === APOSTROPHE || next === QUOTATION_MARK) { var stringToken = this.consumeStringToken(this.consumeCodePoint()) if (stringToken.type === 0) { this.consumeWhiteSpace() if ( this.peekCodePoint(0) === EOF$1 || this.peekCodePoint(0) === RIGHT_PARENTHESIS ) { this.consumeCodePoint() return { type: 22, value: stringToken.value } } } this.consumeBadUrlRemnants() return BAD_URL_TOKEN } while (true) { var codePoint = this.consumeCodePoint() if (codePoint === EOF$1 || codePoint === RIGHT_PARENTHESIS) { return { type: 22, value: fromCodePoint$1.apply(void 0, value2) } } else if (isWhiteSpace(codePoint)) { this.consumeWhiteSpace() if ( this.peekCodePoint(0) === EOF$1 || this.peekCodePoint(0) === RIGHT_PARENTHESIS ) { this.consumeCodePoint() return { type: 22, value: fromCodePoint$1.apply(void 0, value2) } } this.consumeBadUrlRemnants() return BAD_URL_TOKEN } else if ( codePoint === QUOTATION_MARK || codePoint === APOSTROPHE || codePoint === LEFT_PARENTHESIS || isNonPrintableCodePoint(codePoint) ) { this.consumeBadUrlRemnants() return BAD_URL_TOKEN } else if (codePoint === REVERSE_SOLIDUS) { if (isValidEscape(codePoint, this.peekCodePoint(0))) { value2.push(this.consumeEscapedCodePoint()) } else { this.consumeBadUrlRemnants() return BAD_URL_TOKEN } } else { value2.push(codePoint) } } } Tokenizer2.prototype.consumeWhiteSpace = function () { while (isWhiteSpace(this.peekCodePoint(0))) { this.consumeCodePoint() } } Tokenizer2.prototype.consumeBadUrlRemnants = function () { while (true) { var codePoint = this.consumeCodePoint() if (codePoint === RIGHT_PARENTHESIS || codePoint === EOF$1) { return } if (isValidEscape(codePoint, this.peekCodePoint(0))) { this.consumeEscapedCodePoint() } } } Tokenizer2.prototype.consumeStringSlice = function (count2) { var SLICE_STACK_SIZE = 5e4 var value2 = '' while (count2 > 0) { var amount = Math.min(SLICE_STACK_SIZE, count2) value2 += fromCodePoint$1.apply(void 0, this._value.splice(0, amount)) count2 -= amount } this._value.shift() return value2 } Tokenizer2.prototype.consumeStringToken = function (endingCodePoint) { var value2 = '' var i2 = 0 do { var codePoint = this._value[i2] if ( codePoint === EOF$1 || codePoint === void 0 || codePoint === endingCodePoint ) { value2 += this.consumeStringSlice(i2) return { type: 0, value: value2 } } if (codePoint === LINE_FEED) { this._value.splice(0, i2) return BAD_STRING_TOKEN } if (codePoint === REVERSE_SOLIDUS) { var next = this._value[i2 + 1] if (next !== EOF$1 && next !== void 0) { if (next === LINE_FEED) { value2 += this.consumeStringSlice(i2) i2 = -1 this._value.shift() } else if (isValidEscape(codePoint, next)) { value2 += this.consumeStringSlice(i2) value2 += fromCodePoint$1(this.consumeEscapedCodePoint()) i2 = -1 } } } i2++ } while (true) } Tokenizer2.prototype.consumeNumber = function () { var repr = [] var type4 = FLAG_INTEGER var c1 = this.peekCodePoint(0) if (c1 === PLUS_SIGN || c1 === HYPHEN_MINUS) { repr.push(this.consumeCodePoint()) } while (isDigit(this.peekCodePoint(0))) { repr.push(this.consumeCodePoint()) } c1 = this.peekCodePoint(0) var c2 = this.peekCodePoint(1) if (c1 === FULL_STOP && isDigit(c2)) { repr.push(this.consumeCodePoint(), this.consumeCodePoint()) type4 = FLAG_NUMBER while (isDigit(this.peekCodePoint(0))) { repr.push(this.consumeCodePoint()) } } c1 = this.peekCodePoint(0) c2 = this.peekCodePoint(1) var c3 = this.peekCodePoint(2) if ( (c1 === E || c1 === e$2) && (((c2 === PLUS_SIGN || c2 === HYPHEN_MINUS) && isDigit(c3)) || isDigit(c2)) ) { repr.push(this.consumeCodePoint(), this.consumeCodePoint()) type4 = FLAG_NUMBER while (isDigit(this.peekCodePoint(0))) { repr.push(this.consumeCodePoint()) } } return [stringToNumber(repr), type4] } Tokenizer2.prototype.consumeNumericToken = function () { var _a2 = this.consumeNumber(), number4 = _a2[0], flags = _a2[1] var c1 = this.peekCodePoint(0) var c2 = this.peekCodePoint(1) var c3 = this.peekCodePoint(2) if (isIdentifierStart(c1, c2, c3)) { var unit = this.consumeName() return { type: 15, number: number4, flags, unit } } if (c1 === PERCENTAGE_SIGN) { this.consumeCodePoint() return { type: 16, number: number4, flags } } return { type: 17, number: number4, flags } } Tokenizer2.prototype.consumeEscapedCodePoint = function () { var codePoint = this.consumeCodePoint() if (isHex(codePoint)) { var hex2 = fromCodePoint$1(codePoint) while (isHex(this.peekCodePoint(0)) && hex2.length < 6) { hex2 += fromCodePoint$1(this.consumeCodePoint()) } if (isWhiteSpace(this.peekCodePoint(0))) { this.consumeCodePoint() } var hexCodePoint = parseInt(hex2, 16) if ( hexCodePoint === 0 || isSurrogateCodePoint(hexCodePoint) || hexCodePoint > 1114111 ) { return REPLACEMENT_CHARACTER } return hexCodePoint } if (codePoint === EOF$1) { return REPLACEMENT_CHARACTER } return codePoint } Tokenizer2.prototype.consumeName = function () { var result = '' while (true) { var codePoint = this.consumeCodePoint() if (isNameCodePoint(codePoint)) { result += fromCodePoint$1(codePoint) } else if (isValidEscape(codePoint, this.peekCodePoint(0))) { result += fromCodePoint$1(this.consumeEscapedCodePoint()) } else { this.reconsumeCodePoint(codePoint) return result } } } return Tokenizer2 })() var Parser$1 = (function () { function Parser2(tokens) { this._tokens = tokens } Parser2.create = function (value2) { var tokenizer = new Tokenizer() tokenizer.write(value2) return new Parser2(tokenizer.read()) } Parser2.parseValue = function (value2) { return Parser2.create(value2).parseComponentValue() } Parser2.parseValues = function (value2) { return Parser2.create(value2).parseComponentValues() } Parser2.prototype.parseComponentValue = function () { var token = this.consumeToken() while (token.type === 31) { token = this.consumeToken() } if (token.type === 32) { throw new SyntaxError('Error parsing CSS component value, unexpected EOF') } this.reconsumeToken(token) var value2 = this.consumeComponentValue() do { token = this.consumeToken() } while (token.type === 31) if (token.type === 32) { return value2 } throw new SyntaxError( 'Error parsing CSS component value, multiple values found when expecting only one' ) } Parser2.prototype.parseComponentValues = function () { var values2 = [] while (true) { var value2 = this.consumeComponentValue() if (value2.type === 32) { return values2 } values2.push(value2) values2.push() } } Parser2.prototype.consumeComponentValue = function () { var token = this.consumeToken() switch (token.type) { case 11: case 28: case 2: return this.consumeSimpleBlock(token.type) case 19: return this.consumeFunction(token) } return token } Parser2.prototype.consumeSimpleBlock = function (type4) { var block = { type: type4, values: [] } var token = this.consumeToken() while (true) { if (token.type === 32 || isEndingTokenFor(token, type4)) { return block } this.reconsumeToken(token) block.values.push(this.consumeComponentValue()) token = this.consumeToken() } } Parser2.prototype.consumeFunction = function (functionToken) { var cssFunction = { name: functionToken.value, values: [], type: 18, } while (true) { var token = this.consumeToken() if (token.type === 32 || token.type === 3) { return cssFunction } this.reconsumeToken(token) cssFunction.values.push(this.consumeComponentValue()) } } Parser2.prototype.consumeToken = function () { var token = this._tokens.shift() return typeof token === 'undefined' ? EOF_TOKEN : token } Parser2.prototype.reconsumeToken = function (token) { this._tokens.unshift(token) } return Parser2 })() var isDimensionToken = function (token) { return token.type === 15 } var isNumberToken = function (token) { return token.type === 17 } var isIdentToken = function (token) { return token.type === 20 } var isStringToken = function (token) { return token.type === 0 } var isIdentWithValue = function (token, value2) { return isIdentToken(token) && token.value === value2 } var nonWhiteSpace = function (token) { return token.type !== 31 } var nonFunctionArgSeparator = function (token) { return token.type !== 31 && token.type !== 4 } var parseFunctionArgs = function (tokens) { var args = [] var arg = [] tokens.forEach(function (token) { if (token.type === 4) { if (arg.length === 0) { throw new Error('Error parsing function args, zero tokens for arg') } args.push(arg) arg = [] return } if (token.type !== 31) { arg.push(token) } }) if (arg.length) { args.push(arg) } return args } var isEndingTokenFor = function (token, type4) { if (type4 === 11 && token.type === 12) { return true } if (type4 === 28 && token.type === 29) { return true } return type4 === 2 && token.type === 3 } var isLength$3 = function (token) { return token.type === 17 || token.type === 15 } var isLengthPercentage = function (token) { return token.type === 16 || isLength$3(token) } var parseLengthPercentageTuple = function (tokens) { return tokens.length > 1 ? [tokens[0], tokens[1]] : [tokens[0]] } var ZERO_LENGTH = { type: 17, number: 0, flags: FLAG_INTEGER, } var FIFTY_PERCENT = { type: 16, number: 50, flags: FLAG_INTEGER, } var HUNDRED_PERCENT = { type: 16, number: 100, flags: FLAG_INTEGER, } var getAbsoluteValueForTuple = function (tuple, width, height) { var x2 = tuple[0], y2 = tuple[1] return [ getAbsoluteValue(x2, width), getAbsoluteValue(typeof y2 !== 'undefined' ? y2 : x2, height), ] } var getAbsoluteValue = function (token, parent2) { if (token.type === 16) { return (token.number / 100) * parent2 } if (isDimensionToken(token)) { switch (token.unit) { case 'rem': case 'em': return 16 * token.number case 'px': default: return token.number } } return token.number } var DEG = 'deg' var GRAD = 'grad' var RAD = 'rad' var TURN = 'turn' var angle = { name: 'angle', parse: function (_context, value2) { if (value2.type === 15) { switch (value2.unit) { case DEG: return (Math.PI * value2.number) / 180 case GRAD: return (Math.PI / 200) * value2.number case RAD: return value2.number case TURN: return Math.PI * 2 * value2.number } } throw new Error('Unsupported angle type') }, } var isAngle = function (value2) { if (value2.type === 15) { if ( value2.unit === DEG || value2.unit === GRAD || value2.unit === RAD || value2.unit === TURN ) { return true } } return false } var parseNamedSide = function (tokens) { var sideOrCorner = tokens .filter(isIdentToken) .map(function (ident) { return ident.value }) .join(' ') switch (sideOrCorner) { case 'to bottom right': case 'to right bottom': case 'left top': case 'top left': return [ZERO_LENGTH, ZERO_LENGTH] case 'to top': case 'bottom': return deg(0) case 'to bottom left': case 'to left bottom': case 'right top': case 'top right': return [ZERO_LENGTH, HUNDRED_PERCENT] case 'to right': case 'left': return deg(90) case 'to top left': case 'to left top': case 'right bottom': case 'bottom right': return [HUNDRED_PERCENT, HUNDRED_PERCENT] case 'to bottom': case 'top': return deg(180) case 'to top right': case 'to right top': case 'left bottom': case 'bottom left': return [HUNDRED_PERCENT, ZERO_LENGTH] case 'to left': case 'right': return deg(270) } return 0 } var deg = function (deg2) { return (Math.PI * deg2) / 180 } var color$1$1 = { name: 'color', parse: function (context2, value2) { if (value2.type === 18) { var colorFunction = SUPPORTED_COLOR_FUNCTIONS[value2.name] if (typeof colorFunction === 'undefined') { throw new Error( 'Attempting to parse an unsupported color function "' + value2.name + '"' ) } return colorFunction(context2, value2.values) } if (value2.type === 5) { if (value2.value.length === 3) { var r2 = value2.value.substring(0, 1) var g2 = value2.value.substring(1, 2) var b2 = value2.value.substring(2, 3) return pack( parseInt(r2 + r2, 16), parseInt(g2 + g2, 16), parseInt(b2 + b2, 16), 1 ) } if (value2.value.length === 4) { var r2 = value2.value.substring(0, 1) var g2 = value2.value.substring(1, 2) var b2 = value2.value.substring(2, 3) var a2 = value2.value.substring(3, 4) return pack( parseInt(r2 + r2, 16), parseInt(g2 + g2, 16), parseInt(b2 + b2, 16), parseInt(a2 + a2, 16) / 255 ) } if (value2.value.length === 6) { var r2 = value2.value.substring(0, 2) var g2 = value2.value.substring(2, 4) var b2 = value2.value.substring(4, 6) return pack(parseInt(r2, 16), parseInt(g2, 16), parseInt(b2, 16), 1) } if (value2.value.length === 8) { var r2 = value2.value.substring(0, 2) var g2 = value2.value.substring(2, 4) var b2 = value2.value.substring(4, 6) var a2 = value2.value.substring(6, 8) return pack( parseInt(r2, 16), parseInt(g2, 16), parseInt(b2, 16), parseInt(a2, 16) / 255 ) } } if (value2.type === 20) { var namedColor = COLORS[value2.value.toUpperCase()] if (typeof namedColor !== 'undefined') { return namedColor } } return COLORS.TRANSPARENT }, } var isTransparent = function (color2) { return (255 & color2) === 0 } var asString = function (color2) { var alpha = 255 & color2 var blue = 255 & (color2 >> 8) var green = 255 & (color2 >> 16) var red = 255 & (color2 >> 24) return alpha < 255 ? 'rgba(' + red + ',' + green + ',' + blue + ',' + alpha / 255 + ')' : 'rgb(' + red + ',' + green + ',' + blue + ')' } var pack = function (r2, g2, b2, a2) { return ( ((r2 << 24) | (g2 << 16) | (b2 << 8) | (Math.round(a2 * 255) << 0)) >>> 0 ) } var getTokenColorValue = function (token, i2) { if (token.type === 17) { return token.number } if (token.type === 16) { var max3 = i2 === 3 ? 1 : 255 return i2 === 3 ? (token.number / 100) * max3 : Math.round((token.number / 100) * max3) } return 0 } var rgb = function (_context, args) { var tokens = args.filter(nonFunctionArgSeparator) if (tokens.length === 3) { var _a2 = tokens.map(getTokenColorValue), r2 = _a2[0], g2 = _a2[1], b2 = _a2[2] return pack(r2, g2, b2, 1) } if (tokens.length === 4) { var _b2 = tokens.map(getTokenColorValue), r2 = _b2[0], g2 = _b2[1], b2 = _b2[2], a2 = _b2[3] return pack(r2, g2, b2, a2) } return 0 } function hue2rgb(t1, t22, hue) { if (hue < 0) { hue += 1 } if (hue >= 1) { hue -= 1 } if (hue < 1 / 6) { return (t22 - t1) * hue * 6 + t1 } else if (hue < 1 / 2) { return t22 } else if (hue < 2 / 3) { return (t22 - t1) * 6 * (2 / 3 - hue) + t1 } else { return t1 } } var hsl = function (context2, args) { var tokens = args.filter(nonFunctionArgSeparator) var hue = tokens[0], saturation = tokens[1], lightness = tokens[2], alpha = tokens[3] var h2 = (hue.type === 17 ? deg(hue.number) : angle.parse(context2, hue)) / (Math.PI * 2) var s2 = isLengthPercentage(saturation) ? saturation.number / 100 : 0 var l2 = isLengthPercentage(lightness) ? lightness.number / 100 : 0 var a2 = typeof alpha !== 'undefined' && isLengthPercentage(alpha) ? getAbsoluteValue(alpha, 1) : 1 if (s2 === 0) { return pack(l2 * 255, l2 * 255, l2 * 255, 1) } var t22 = l2 <= 0.5 ? l2 * (s2 + 1) : l2 + s2 - l2 * s2 var t1 = l2 * 2 - t22 var r2 = hue2rgb(t1, t22, h2 + 1 / 3) var g2 = hue2rgb(t1, t22, h2) var b2 = hue2rgb(t1, t22, h2 - 1 / 3) return pack(r2 * 255, g2 * 255, b2 * 255, a2) } var SUPPORTED_COLOR_FUNCTIONS = { hsl, hsla: hsl, rgb, rgba: rgb, } var parseColor = function (context2, value2) { return color$1$1.parse( context2, Parser$1.create(value2).parseComponentValue() ) } var COLORS = { ALICEBLUE: 4042850303, ANTIQUEWHITE: 4209760255, AQUA: 16777215, AQUAMARINE: 2147472639, AZURE: 4043309055, BEIGE: 4126530815, BISQUE: 4293182719, BLACK: 255, BLANCHEDALMOND: 4293643775, BLUE: 65535, BLUEVIOLET: 2318131967, BROWN: 2771004159, BURLYWOOD: 3736635391, CADETBLUE: 1604231423, CHARTREUSE: 2147418367, CHOCOLATE: 3530104575, CORAL: 4286533887, CORNFLOWERBLUE: 1687547391, CORNSILK: 4294499583, CRIMSON: 3692313855, CYAN: 16777215, DARKBLUE: 35839, DARKCYAN: 9145343, DARKGOLDENROD: 3095837695, DARKGRAY: 2846468607, DARKGREEN: 6553855, DARKGREY: 2846468607, DARKKHAKI: 3182914559, DARKMAGENTA: 2332068863, DARKOLIVEGREEN: 1433087999, DARKORANGE: 4287365375, DARKORCHID: 2570243327, DARKRED: 2332033279, DARKSALMON: 3918953215, DARKSEAGREEN: 2411499519, DARKSLATEBLUE: 1211993087, DARKSLATEGRAY: 793726975, DARKSLATEGREY: 793726975, DARKTURQUOISE: 13554175, DARKVIOLET: 2483082239, DEEPPINK: 4279538687, DEEPSKYBLUE: 12582911, DIMGRAY: 1768516095, DIMGREY: 1768516095, DODGERBLUE: 512819199, FIREBRICK: 2988581631, FLORALWHITE: 4294635775, FORESTGREEN: 579543807, FUCHSIA: 4278255615, GAINSBORO: 3705462015, GHOSTWHITE: 4177068031, GOLD: 4292280575, GOLDENROD: 3668254975, GRAY: 2155905279, GREEN: 8388863, GREENYELLOW: 2919182335, GREY: 2155905279, HONEYDEW: 4043305215, HOTPINK: 4285117695, INDIANRED: 3445382399, INDIGO: 1258324735, IVORY: 4294963455, KHAKI: 4041641215, LAVENDER: 3873897215, LAVENDERBLUSH: 4293981695, LAWNGREEN: 2096890111, LEMONCHIFFON: 4294626815, LIGHTBLUE: 2916673279, LIGHTCORAL: 4034953471, LIGHTCYAN: 3774873599, LIGHTGOLDENRODYELLOW: 4210742015, LIGHTGRAY: 3553874943, LIGHTGREEN: 2431553791, LIGHTGREY: 3553874943, LIGHTPINK: 4290167295, LIGHTSALMON: 4288707327, LIGHTSEAGREEN: 548580095, LIGHTSKYBLUE: 2278488831, LIGHTSLATEGRAY: 2005441023, LIGHTSLATEGREY: 2005441023, LIGHTSTEELBLUE: 2965692159, LIGHTYELLOW: 4294959359, LIME: 16711935, LIMEGREEN: 852308735, LINEN: 4210091775, MAGENTA: 4278255615, MAROON: 2147483903, MEDIUMAQUAMARINE: 1724754687, MEDIUMBLUE: 52735, MEDIUMORCHID: 3126187007, MEDIUMPURPLE: 2473647103, MEDIUMSEAGREEN: 1018393087, MEDIUMSLATEBLUE: 2070474495, MEDIUMSPRINGGREEN: 16423679, MEDIUMTURQUOISE: 1221709055, MEDIUMVIOLETRED: 3340076543, MIDNIGHTBLUE: 421097727, MINTCREAM: 4127193855, MISTYROSE: 4293190143, MOCCASIN: 4293178879, NAVAJOWHITE: 4292783615, NAVY: 33023, OLDLACE: 4260751103, OLIVE: 2155872511, OLIVEDRAB: 1804477439, ORANGE: 4289003775, ORANGERED: 4282712319, ORCHID: 3664828159, PALEGOLDENROD: 4008225535, PALEGREEN: 2566625535, PALETURQUOISE: 2951671551, PALEVIOLETRED: 3681588223, PAPAYAWHIP: 4293907967, PEACHPUFF: 4292524543, PERU: 3448061951, PINK: 4290825215, PLUM: 3718307327, POWDERBLUE: 2967529215, PURPLE: 2147516671, REBECCAPURPLE: 1714657791, RED: 4278190335, ROSYBROWN: 3163525119, ROYALBLUE: 1097458175, SADDLEBROWN: 2336560127, SALMON: 4202722047, SANDYBROWN: 4104413439, SEAGREEN: 780883967, SEASHELL: 4294307583, SIENNA: 2689740287, SILVER: 3233857791, SKYBLUE: 2278484991, SLATEBLUE: 1784335871, SLATEGRAY: 1887473919, SLATEGREY: 1887473919, SNOW: 4294638335, SPRINGGREEN: 16744447, STEELBLUE: 1182971135, TAN: 3535047935, TEAL: 8421631, THISTLE: 3636451583, TOMATO: 4284696575, TRANSPARENT: 0, TURQUOISE: 1088475391, VIOLET: 4001558271, WHEAT: 4125012991, WHITE: 4294967295, WHITESMOKE: 4126537215, YELLOW: 4294902015, YELLOWGREEN: 2597139199, } var backgroundClip = { name: 'background-clip', initialValue: 'border-box', prefix: false, type: 1, parse: function (_context, tokens) { return tokens.map(function (token) { if (isIdentToken(token)) { switch (token.value) { case 'padding-box': return 1 case 'content-box': return 2 } } return 0 }) }, } var backgroundColor$1 = { name: 'background-color', initialValue: 'transparent', prefix: false, type: 3, format: 'color', } var parseColorStop = function (context2, args) { var color2 = color$1$1.parse(context2, args[0]) var stop2 = args[1] return stop2 && isLengthPercentage(stop2) ? { color: color2, stop: stop2 } : { color: color2, stop: null } } var processColorStops = function (stops, lineLength) { var first2 = stops[0] var last2 = stops[stops.length - 1] if (first2.stop === null) { first2.stop = ZERO_LENGTH } if (last2.stop === null) { last2.stop = HUNDRED_PERCENT } var processStops = [] var previous = 0 for (var i2 = 0; i2 < stops.length; i2++) { var stop_1 = stops[i2].stop if (stop_1 !== null) { var absoluteValue = getAbsoluteValue(stop_1, lineLength) if (absoluteValue > previous) { processStops.push(absoluteValue) } else { processStops.push(previous) } previous = absoluteValue } else { processStops.push(null) } } var gapBegin = null for (var i2 = 0; i2 < processStops.length; i2++) { var stop_2 = processStops[i2] if (stop_2 === null) { if (gapBegin === null) { gapBegin = i2 } } else if (gapBegin !== null) { var gapLength = i2 - gapBegin var beforeGap = processStops[gapBegin - 1] var gapValue = (stop_2 - beforeGap) / (gapLength + 1) for (var g2 = 1; g2 <= gapLength; g2++) { processStops[gapBegin + g2 - 1] = gapValue * g2 } gapBegin = null } } return stops.map(function (_a2, i3) { var color2 = _a2.color return { color: color2, stop: Math.max(Math.min(1, processStops[i3] / lineLength), 0), } }) } var getAngleFromCorner = function (corner, width, height) { var centerX = width / 2 var centerY = height / 2 var x2 = getAbsoluteValue(corner[0], width) - centerX var y2 = centerY - getAbsoluteValue(corner[1], height) return (Math.atan2(y2, x2) + Math.PI * 2) % (Math.PI * 2) } var calculateGradientDirection = function (angle2, width, height) { var radian = typeof angle2 === 'number' ? angle2 : getAngleFromCorner(angle2, width, height) var lineLength = Math.abs(width * Math.sin(radian)) + Math.abs(height * Math.cos(radian)) var halfWidth = width / 2 var halfHeight = height / 2 var halfLineLength = lineLength / 2 var yDiff = Math.sin(radian - Math.PI / 2) * halfLineLength var xDiff = Math.cos(radian - Math.PI / 2) * halfLineLength return [ lineLength, halfWidth - xDiff, halfWidth + xDiff, halfHeight - yDiff, halfHeight + yDiff, ] } var distance$1 = function (a2, b2) { return Math.sqrt(a2 * a2 + b2 * b2) } var findCorner = function (width, height, x2, y2, closest2) { var corners = [ [0, 0], [0, height], [width, 0], [width, height], ] return corners.reduce( function (stat, corner) { var cx = corner[0], cy = corner[1] var d3 = distance$1(x2 - cx, y2 - cy) if (closest2 ? d3 < stat.optimumDistance : d3 > stat.optimumDistance) { return { optimumCorner: corner, optimumDistance: d3, } } return stat }, { optimumDistance: closest2 ? Infinity : -Infinity, optimumCorner: null, } ).optimumCorner } var calculateRadius = function (gradient, x2, y2, width, height) { var rx = 0 var ry = 0 switch (gradient.size) { case 0: if (gradient.shape === 0) { rx = ry = Math.min( Math.abs(x2), Math.abs(x2 - width), Math.abs(y2), Math.abs(y2 - height) ) } else if (gradient.shape === 1) { rx = Math.min(Math.abs(x2), Math.abs(x2 - width)) ry = Math.min(Math.abs(y2), Math.abs(y2 - height)) } break case 2: if (gradient.shape === 0) { rx = ry = Math.min( distance$1(x2, y2), distance$1(x2, y2 - height), distance$1(x2 - width, y2), distance$1(x2 - width, y2 - height) ) } else if (gradient.shape === 1) { var c2 = Math.min(Math.abs(y2), Math.abs(y2 - height)) / Math.min(Math.abs(x2), Math.abs(x2 - width)) var _a2 = findCorner(width, height, x2, y2, true), cx = _a2[0], cy = _a2[1] rx = distance$1(cx - x2, (cy - y2) / c2) ry = c2 * rx } break case 1: if (gradient.shape === 0) { rx = ry = Math.max( Math.abs(x2), Math.abs(x2 - width), Math.abs(y2), Math.abs(y2 - height) ) } else if (gradient.shape === 1) { rx = Math.max(Math.abs(x2), Math.abs(x2 - width)) ry = Math.max(Math.abs(y2), Math.abs(y2 - height)) } break case 3: if (gradient.shape === 0) { rx = ry = Math.max( distance$1(x2, y2), distance$1(x2, y2 - height), distance$1(x2 - width, y2), distance$1(x2 - width, y2 - height) ) } else if (gradient.shape === 1) { var c2 = Math.max(Math.abs(y2), Math.abs(y2 - height)) / Math.max(Math.abs(x2), Math.abs(x2 - width)) var _b2 = findCorner(width, height, x2, y2, false), cx = _b2[0], cy = _b2[1] rx = distance$1(cx - x2, (cy - y2) / c2) ry = c2 * rx } break } if (Array.isArray(gradient.size)) { rx = getAbsoluteValue(gradient.size[0], width) ry = gradient.size.length === 2 ? getAbsoluteValue(gradient.size[1], height) : rx } return [rx, ry] } var linearGradient = function (context2, tokens) { var angle$1 = deg(180) var stops = [] parseFunctionArgs(tokens).forEach(function (arg, i2) { if (i2 === 0) { var firstToken = arg[0] if (firstToken.type === 20 && firstToken.value === 'to') { angle$1 = parseNamedSide(arg) return } else if (isAngle(firstToken)) { angle$1 = angle.parse(context2, firstToken) return } } var colorStop = parseColorStop(context2, arg) stops.push(colorStop) }) return { angle: angle$1, stops, type: 1 } } var prefixLinearGradient = function (context2, tokens) { var angle$1 = deg(180) var stops = [] parseFunctionArgs(tokens).forEach(function (arg, i2) { if (i2 === 0) { var firstToken = arg[0] if ( firstToken.type === 20 && ['top', 'left', 'right', 'bottom'].indexOf(firstToken.value) !== -1 ) { angle$1 = parseNamedSide(arg) return } else if (isAngle(firstToken)) { angle$1 = (angle.parse(context2, firstToken) + deg(270)) % deg(360) return } } var colorStop = parseColorStop(context2, arg) stops.push(colorStop) }) return { angle: angle$1, stops, type: 1, } } var webkitGradient = function (context2, tokens) { var angle2 = deg(180) var stops = [] var type4 = 1 var shape = 0 var size = 3 var position2 = [] parseFunctionArgs(tokens).forEach(function (arg, i2) { var firstToken = arg[0] if (i2 === 0) { if (isIdentToken(firstToken) && firstToken.value === 'linear') { type4 = 1 return } else if (isIdentToken(firstToken) && firstToken.value === 'radial') { type4 = 2 return } } if (firstToken.type === 18) { if (firstToken.name === 'from') { var color2 = color$1$1.parse(context2, firstToken.values[0]) stops.push({ stop: ZERO_LENGTH, color: color2 }) } else if (firstToken.name === 'to') { var color2 = color$1$1.parse(context2, firstToken.values[0]) stops.push({ stop: HUNDRED_PERCENT, color: color2 }) } else if (firstToken.name === 'color-stop') { var values2 = firstToken.values.filter(nonFunctionArgSeparator) if (values2.length === 2) { var color2 = color$1$1.parse(context2, values2[1]) var stop_1 = values2[0] if (isNumberToken(stop_1)) { stops.push({ stop: { type: 16, number: stop_1.number * 100, flags: stop_1.flags, }, color: color2, }) } } } } }) return type4 === 1 ? { angle: (angle2 + deg(180)) % deg(360), stops, type: type4, } : { size, shape, stops, position: position2, type: type4 } } var CLOSEST_SIDE = 'closest-side' var FARTHEST_SIDE = 'farthest-side' var CLOSEST_CORNER = 'closest-corner' var FARTHEST_CORNER = 'farthest-corner' var CIRCLE = 'circle' var ELLIPSE = 'ellipse' var COVER = 'cover' var CONTAIN = 'contain' var radialGradient = function (context2, tokens) { var shape = 0 var size = 3 var stops = [] var position2 = [] parseFunctionArgs(tokens).forEach(function (arg, i2) { var isColorStop = true if (i2 === 0) { var isAtPosition_1 = false isColorStop = arg.reduce(function (acc, token) { if (isAtPosition_1) { if (isIdentToken(token)) { switch (token.value) { case 'center': position2.push(FIFTY_PERCENT) return acc case 'top': case 'left': position2.push(ZERO_LENGTH) return acc case 'right': case 'bottom': position2.push(HUNDRED_PERCENT) return acc } } else if (isLengthPercentage(token) || isLength$3(token)) { position2.push(token) } } else if (isIdentToken(token)) { switch (token.value) { case CIRCLE: shape = 0 return false case ELLIPSE: shape = 1 return false case 'at': isAtPosition_1 = true return false case CLOSEST_SIDE: size = 0 return false case COVER: case FARTHEST_SIDE: size = 1 return false case CONTAIN: case CLOSEST_CORNER: size = 2 return false case FARTHEST_CORNER: size = 3 return false } } else if (isLength$3(token) || isLengthPercentage(token)) { if (!Array.isArray(size)) { size = [] } size.push(token) return false } return acc }, isColorStop) } if (isColorStop) { var colorStop = parseColorStop(context2, arg) stops.push(colorStop) } }) return { size, shape, stops, position: position2, type: 2 } } var prefixRadialGradient = function (context2, tokens) { var shape = 0 var size = 3 var stops = [] var position2 = [] parseFunctionArgs(tokens).forEach(function (arg, i2) { var isColorStop = true if (i2 === 0) { isColorStop = arg.reduce(function (acc, token) { if (isIdentToken(token)) { switch (token.value) { case 'center': position2.push(FIFTY_PERCENT) return false case 'top': case 'left': position2.push(ZERO_LENGTH) return false case 'right': case 'bottom': position2.push(HUNDRED_PERCENT) return false } } else if (isLengthPercentage(token) || isLength$3(token)) { position2.push(token) return false } return acc }, isColorStop) } else if (i2 === 1) { isColorStop = arg.reduce(function (acc, token) { if (isIdentToken(token)) { switch (token.value) { case CIRCLE: shape = 0 return false case ELLIPSE: shape = 1 return false case CONTAIN: case CLOSEST_SIDE: size = 0 return false case FARTHEST_SIDE: size = 1 return false case CLOSEST_CORNER: size = 2 return false case COVER: case FARTHEST_CORNER: size = 3 return false } } else if (isLength$3(token) || isLengthPercentage(token)) { if (!Array.isArray(size)) { size = [] } size.push(token) return false } return acc }, isColorStop) } if (isColorStop) { var colorStop = parseColorStop(context2, arg) stops.push(colorStop) } }) return { size, shape, stops, position: position2, type: 2 } } var isLinearGradient$1 = function (background) { return background.type === 1 } var isRadialGradient$1 = function (background) { return background.type === 2 } var image$1 = { name: 'image', parse: function (context2, value2) { if (value2.type === 22) { var image_1 = { url: value2.value, type: 0 } context2.cache.addImage(value2.value) return image_1 } if (value2.type === 18) { var imageFunction = SUPPORTED_IMAGE_FUNCTIONS[value2.name] if (typeof imageFunction === 'undefined') { throw new Error( 'Attempting to parse an unsupported image function "' + value2.name + '"' ) } return imageFunction(context2, value2.values) } throw new Error('Unsupported image type ' + value2.type) }, } function isSupportedImage(value2) { return ( !(value2.type === 20 && value2.value === 'none') && (value2.type !== 18 || !!SUPPORTED_IMAGE_FUNCTIONS[value2.name]) ) } var SUPPORTED_IMAGE_FUNCTIONS = { 'linear-gradient': linearGradient, '-moz-linear-gradient': prefixLinearGradient, '-ms-linear-gradient': prefixLinearGradient, '-o-linear-gradient': prefixLinearGradient, '-webkit-linear-gradient': prefixLinearGradient, 'radial-gradient': radialGradient, '-moz-radial-gradient': prefixRadialGradient, '-ms-radial-gradient': prefixRadialGradient, '-o-radial-gradient': prefixRadialGradient, '-webkit-radial-gradient': prefixRadialGradient, '-webkit-gradient': webkitGradient, } var backgroundImage = { name: 'background-image', initialValue: 'none', type: 1, prefix: false, parse: function (context2, tokens) { if (tokens.length === 0) { return [] } var first2 = tokens[0] if (first2.type === 20 && first2.value === 'none') { return [] } return tokens .filter(function (value2) { return nonFunctionArgSeparator(value2) && isSupportedImage(value2) }) .map(function (value2) { return image$1.parse(context2, value2) }) }, } var backgroundOrigin = { name: 'background-origin', initialValue: 'border-box', prefix: false, type: 1, parse: function (_context, tokens) { return tokens.map(function (token) { if (isIdentToken(token)) { switch (token.value) { case 'padding-box': return 1 case 'content-box': return 2 } } return 0 }) }, } var backgroundPosition = { name: 'background-position', initialValue: '0% 0%', type: 1, prefix: false, parse: function (_context, tokens) { return parseFunctionArgs(tokens) .map(function (values2) { return values2.filter(isLengthPercentage) }) .map(parseLengthPercentageTuple) }, } var backgroundRepeat = { name: 'background-repeat', initialValue: 'repeat', prefix: false, type: 1, parse: function (_context, tokens) { return parseFunctionArgs(tokens) .map(function (values2) { return values2 .filter(isIdentToken) .map(function (token) { return token.value }) .join(' ') }) .map(parseBackgroundRepeat) }, } var parseBackgroundRepeat = function (value2) { switch (value2) { case 'no-repeat': return 1 case 'repeat-x': case 'repeat no-repeat': return 2 case 'repeat-y': case 'no-repeat repeat': return 3 case 'repeat': default: return 0 } } var BACKGROUND_SIZE ;(function (BACKGROUND_SIZE2) { BACKGROUND_SIZE2['AUTO'] = 'auto' BACKGROUND_SIZE2['CONTAIN'] = 'contain' BACKGROUND_SIZE2['COVER'] = 'cover' })(BACKGROUND_SIZE || (BACKGROUND_SIZE = {})) var backgroundSize = { name: 'background-size', initialValue: '0', prefix: false, type: 1, parse: function (_context, tokens) { return parseFunctionArgs(tokens).map(function (values2) { return values2.filter(isBackgroundSizeInfoToken) }) }, } var isBackgroundSizeInfoToken = function (value2) { return isIdentToken(value2) || isLengthPercentage(value2) } var borderColorForSide = function (side) { return { name: 'border-' + side + '-color', initialValue: 'transparent', prefix: false, type: 3, format: 'color', } } var borderTopColor = borderColorForSide('top') var borderRightColor = borderColorForSide('right') var borderBottomColor = borderColorForSide('bottom') var borderLeftColor = borderColorForSide('left') var borderRadiusForSide = function (side) { return { name: 'border-radius-' + side, initialValue: '0 0', prefix: false, type: 1, parse: function (_context, tokens) { return parseLengthPercentageTuple(tokens.filter(isLengthPercentage)) }, } } var borderTopLeftRadius = borderRadiusForSide('top-left') var borderTopRightRadius = borderRadiusForSide('top-right') var borderBottomRightRadius = borderRadiusForSide('bottom-right') var borderBottomLeftRadius = borderRadiusForSide('bottom-left') var borderStyleForSide = function (side) { return { name: 'border-' + side + '-style', initialValue: 'solid', prefix: false, type: 2, parse: function (_context, style2) { switch (style2) { case 'none': return 0 case 'dashed': return 2 case 'dotted': return 3 case 'double': return 4 } return 1 }, } } var borderTopStyle = borderStyleForSide('top') var borderRightStyle = borderStyleForSide('right') var borderBottomStyle = borderStyleForSide('bottom') var borderLeftStyle = borderStyleForSide('left') var borderWidthForSide = function (side) { return { name: 'border-' + side + '-width', initialValue: '0', type: 0, prefix: false, parse: function (_context, token) { if (isDimensionToken(token)) { return token.number } return 0 }, } } var borderTopWidth = borderWidthForSide('top') var borderRightWidth = borderWidthForSide('right') var borderBottomWidth = borderWidthForSide('bottom') var borderLeftWidth = borderWidthForSide('left') var color$2 = { name: 'color', initialValue: 'transparent', prefix: false, type: 3, format: 'color', } var direction = { name: 'direction', initialValue: 'ltr', prefix: false, type: 2, parse: function (_context, direction2) { switch (direction2) { case 'rtl': return 1 case 'ltr': default: return 0 } }, } var display = { name: 'display', initialValue: 'inline-block', prefix: false, type: 1, parse: function (_context, tokens) { return tokens.filter(isIdentToken).reduce(function (bit, token) { return bit | parseDisplayValue(token.value) }, 0) }, } var parseDisplayValue = function (display2) { switch (display2) { case 'block': case '-webkit-box': return 2 case 'inline': return 4 case 'run-in': return 8 case 'flow': return 16 case 'flow-root': return 32 case 'table': return 64 case 'flex': case '-webkit-flex': return 128 case 'grid': case '-ms-grid': return 256 case 'ruby': return 512 case 'subgrid': return 1024 case 'list-item': return 2048 case 'table-row-group': return 4096 case 'table-header-group': return 8192 case 'table-footer-group': return 16384 case 'table-row': return 32768 case 'table-cell': return 65536 case 'table-column-group': return 131072 case 'table-column': return 262144 case 'table-caption': return 524288 case 'ruby-base': return 1048576 case 'ruby-text': return 2097152 case 'ruby-base-container': return 4194304 case 'ruby-text-container': return 8388608 case 'contents': return 16777216 case 'inline-block': return 33554432 case 'inline-list-item': return 67108864 case 'inline-table': return 134217728 case 'inline-flex': return 268435456 case 'inline-grid': return 536870912 } return 0 } var float = { name: 'float', initialValue: 'none', prefix: false, type: 2, parse: function (_context, float3) { switch (float3) { case 'left': return 1 case 'right': return 2 case 'inline-start': return 3 case 'inline-end': return 4 } return 0 }, } var letterSpacing = { name: 'letter-spacing', initialValue: '0', prefix: false, type: 0, parse: function (_context, token) { if (token.type === 20 && token.value === 'normal') { return 0 } if (token.type === 17) { return token.number } if (token.type === 15) { return token.number } return 0 }, } var LINE_BREAK ;(function (LINE_BREAK2) { LINE_BREAK2['NORMAL'] = 'normal' LINE_BREAK2['STRICT'] = 'strict' })(LINE_BREAK || (LINE_BREAK = {})) var lineBreak = { name: 'line-break', initialValue: 'normal', prefix: false, type: 2, parse: function (_context, lineBreak2) { switch (lineBreak2) { case 'strict': return LINE_BREAK.STRICT case 'normal': default: return LINE_BREAK.NORMAL } }, } var lineHeight = { name: 'line-height', initialValue: 'normal', prefix: false, type: 4, } var computeLineHeight = function (token, fontSize2) { if (isIdentToken(token) && token.value === 'normal') { return 1.2 * fontSize2 } else if (token.type === 17) { return fontSize2 * token.number } else if (isLengthPercentage(token)) { return getAbsoluteValue(token, fontSize2) } return fontSize2 } var listStyleImage = { name: 'list-style-image', initialValue: 'none', type: 0, prefix: false, parse: function (context2, token) { if (token.type === 20 && token.value === 'none') { return null } return image$1.parse(context2, token) }, } var listStylePosition = { name: 'list-style-position', initialValue: 'outside', prefix: false, type: 2, parse: function (_context, position2) { switch (position2) { case 'inside': return 0 case 'outside': default: return 1 } }, } var listStyleType = { name: 'list-style-type', initialValue: 'none', prefix: false, type: 2, parse: function (_context, type4) { switch (type4) { case 'disc': return 0 case 'circle': return 1 case 'square': return 2 case 'decimal': return 3 case 'cjk-decimal': return 4 case 'decimal-leading-zero': return 5 case 'lower-roman': return 6 case 'upper-roman': return 7 case 'lower-greek': return 8 case 'lower-alpha': return 9 case 'upper-alpha': return 10 case 'arabic-indic': return 11 case 'armenian': return 12 case 'bengali': return 13 case 'cambodian': return 14 case 'cjk-earthly-branch': return 15 case 'cjk-heavenly-stem': return 16 case 'cjk-ideographic': return 17 case 'devanagari': return 18 case 'ethiopic-numeric': return 19 case 'georgian': return 20 case 'gujarati': return 21 case 'gurmukhi': return 22 case 'hebrew': return 22 case 'hiragana': return 23 case 'hiragana-iroha': return 24 case 'japanese-formal': return 25 case 'japanese-informal': return 26 case 'kannada': return 27 case 'katakana': return 28 case 'katakana-iroha': return 29 case 'khmer': return 30 case 'korean-hangul-formal': return 31 case 'korean-hanja-formal': return 32 case 'korean-hanja-informal': return 33 case 'lao': return 34 case 'lower-armenian': return 35 case 'malayalam': return 36 case 'mongolian': return 37 case 'myanmar': return 38 case 'oriya': return 39 case 'persian': return 40 case 'simp-chinese-formal': return 41 case 'simp-chinese-informal': return 42 case 'tamil': return 43 case 'telugu': return 44 case 'thai': return 45 case 'tibetan': return 46 case 'trad-chinese-formal': return 47 case 'trad-chinese-informal': return 48 case 'upper-armenian': return 49 case 'disclosure-open': return 50 case 'disclosure-closed': return 51 case 'none': default: return -1 } }, } var marginForSide = function (side) { return { name: 'margin-' + side, initialValue: '0', prefix: false, type: 4, } } var marginTop = marginForSide('top') var marginRight = marginForSide('right') var marginBottom = marginForSide('bottom') var marginLeft = marginForSide('left') var overflow = { name: 'overflow', initialValue: 'visible', prefix: false, type: 1, parse: function (_context, tokens) { return tokens.filter(isIdentToken).map(function (overflow2) { switch (overflow2.value) { case 'hidden': return 1 case 'scroll': return 2 case 'clip': return 3 case 'auto': return 4 case 'visible': default: return 0 } }) }, } var overflowWrap = { name: 'overflow-wrap', initialValue: 'normal', prefix: false, type: 2, parse: function (_context, overflow2) { switch (overflow2) { case 'break-word': return 'break-word' case 'normal': default: return 'normal' } }, } var paddingForSide = function (side) { return { name: 'padding-' + side, initialValue: '0', prefix: false, type: 3, format: 'length-percentage', } } var paddingTop = paddingForSide('top') var paddingRight = paddingForSide('right') var paddingBottom = paddingForSide('bottom') var paddingLeft = paddingForSide('left') var textAlign = { name: 'text-align', initialValue: 'left', prefix: false, type: 2, parse: function (_context, textAlign2) { switch (textAlign2) { case 'right': return 2 case 'center': case 'justify': return 1 case 'left': default: return 0 } }, } var position$1 = { name: 'position', initialValue: 'static', prefix: false, type: 2, parse: function (_context, position2) { switch (position2) { case 'relative': return 1 case 'absolute': return 2 case 'fixed': return 3 case 'sticky': return 4 } return 0 }, } var textShadow = { name: 'text-shadow', initialValue: 'none', type: 1, prefix: false, parse: function (context2, tokens) { if (tokens.length === 1 && isIdentWithValue(tokens[0], 'none')) { return [] } return parseFunctionArgs(tokens).map(function (values2) { var shadow = { color: COLORS.TRANSPARENT, offsetX: ZERO_LENGTH, offsetY: ZERO_LENGTH, blur: ZERO_LENGTH, } var c2 = 0 for (var i2 = 0; i2 < values2.length; i2++) { var token = values2[i2] if (isLength$3(token)) { if (c2 === 0) { shadow.offsetX = token } else if (c2 === 1) { shadow.offsetY = token } else { shadow.blur = token } c2++ } else { shadow.color = color$1$1.parse(context2, token) } } return shadow }) }, } var textTransform = { name: 'text-transform', initialValue: 'none', prefix: false, type: 2, parse: function (_context, textTransform2) { switch (textTransform2) { case 'uppercase': return 2 case 'lowercase': return 1 case 'capitalize': return 3 } return 0 }, } var transform$1 = { name: 'transform', initialValue: 'none', prefix: true, type: 0, parse: function (_context, token) { if (token.type === 20 && token.value === 'none') { return null } if (token.type === 18) { var transformFunction = SUPPORTED_TRANSFORM_FUNCTIONS[token.name] if (typeof transformFunction === 'undefined') { throw new Error( 'Attempting to parse an unsupported transform function "' + token.name + '"' ) } return transformFunction(token.values) } return null }, } var matrix$2 = function (args) { var values2 = args .filter(function (arg) { return arg.type === 17 }) .map(function (arg) { return arg.number }) return values2.length === 6 ? values2 : null } var matrix3d = function (args) { var values2 = args .filter(function (arg) { return arg.type === 17 }) .map(function (arg) { return arg.number }) var a1 = values2[0], b1 = values2[1] values2[2] values2[3] var a2 = values2[4], b2 = values2[5] values2[6] values2[7] values2[8] values2[9] values2[10] values2[11] var a4 = values2[12], b4 = values2[13] values2[14] values2[15] return values2.length === 16 ? [a1, b1, a2, b2, a4, b4] : null } var SUPPORTED_TRANSFORM_FUNCTIONS = { matrix: matrix$2, matrix3d, } var DEFAULT_VALUE = { type: 16, number: 50, flags: FLAG_INTEGER, } var DEFAULT = [DEFAULT_VALUE, DEFAULT_VALUE] var transformOrigin = { name: 'transform-origin', initialValue: '50% 50%', prefix: true, type: 1, parse: function (_context, tokens) { var origins = tokens.filter(isLengthPercentage) if (origins.length !== 2) { return DEFAULT } return [origins[0], origins[1]] }, } var visibility = { name: 'visible', initialValue: 'none', prefix: false, type: 2, parse: function (_context, visibility2) { switch (visibility2) { case 'hidden': return 1 case 'collapse': return 2 case 'visible': default: return 0 } }, } var WORD_BREAK ;(function (WORD_BREAK2) { WORD_BREAK2['NORMAL'] = 'normal' WORD_BREAK2['BREAK_ALL'] = 'break-all' WORD_BREAK2['KEEP_ALL'] = 'keep-all' })(WORD_BREAK || (WORD_BREAK = {})) var wordBreak = { name: 'word-break', initialValue: 'normal', prefix: false, type: 2, parse: function (_context, wordBreak2) { switch (wordBreak2) { case 'break-all': return WORD_BREAK.BREAK_ALL case 'keep-all': return WORD_BREAK.KEEP_ALL case 'normal': default: return WORD_BREAK.NORMAL } }, } var zIndex = { name: 'z-index', initialValue: 'auto', prefix: false, type: 0, parse: function (_context, token) { if (token.type === 20) { return { auto: true, order: 0 } } if (isNumberToken(token)) { return { auto: false, order: token.number } } throw new Error('Invalid z-index number parsed') }, } var time$1 = { name: 'time', parse: function (_context, value2) { if (value2.type === 15) { switch (value2.unit.toLowerCase()) { case 's': return 1e3 * value2.number case 'ms': return value2.number } } throw new Error('Unsupported time type') }, } var opacity = { name: 'opacity', initialValue: '1', type: 0, prefix: false, parse: function (_context, token) { if (isNumberToken(token)) { return token.number } return 1 }, } var textDecorationColor = { name: 'text-decoration-color', initialValue: 'transparent', prefix: false, type: 3, format: 'color', } var textDecorationLine = { name: 'text-decoration-line', initialValue: 'none', prefix: false, type: 1, parse: function (_context, tokens) { return tokens .filter(isIdentToken) .map(function (token) { switch (token.value) { case 'underline': return 1 case 'overline': return 2 case 'line-through': return 3 case 'none': return 4 } return 0 }) .filter(function (line) { return line !== 0 }) }, } var fontFamily = { name: 'font-family', initialValue: '', prefix: false, type: 1, parse: function (_context, tokens) { var accumulator = [] var results = [] tokens.forEach(function (token) { switch (token.type) { case 20: case 0: accumulator.push(token.value) break case 17: accumulator.push(token.number.toString()) break case 4: results.push(accumulator.join(' ')) accumulator.length = 0 break } }) if (accumulator.length) { results.push(accumulator.join(' ')) } return results.map(function (result) { return result.indexOf(' ') === -1 ? result : "'" + result + "'" }) }, } var fontSize = { name: 'font-size', initialValue: '0', prefix: false, type: 3, format: 'length', } var fontWeight = { name: 'font-weight', initialValue: 'normal', type: 0, prefix: false, parse: function (_context, token) { if (isNumberToken(token)) { return token.number } if (isIdentToken(token)) { switch (token.value) { case 'bold': return 700 case 'normal': default: return 400 } } return 400 }, } var fontVariant = { name: 'font-variant', initialValue: 'none', type: 1, prefix: false, parse: function (_context, tokens) { return tokens.filter(isIdentToken).map(function (token) { return token.value }) }, } var fontStyle = { name: 'font-style', initialValue: 'normal', prefix: false, type: 2, parse: function (_context, overflow2) { switch (overflow2) { case 'oblique': return 'oblique' case 'italic': return 'italic' case 'normal': default: return 'normal' } }, } var contains = function (bit, value2) { return (bit & value2) !== 0 } var content = { name: 'content', initialValue: 'none', type: 1, prefix: false, parse: function (_context, tokens) { if (tokens.length === 0) { return [] } var first2 = tokens[0] if (first2.type === 20 && first2.value === 'none') { return [] } return tokens }, } var counterIncrement = { name: 'counter-increment', initialValue: 'none', prefix: true, type: 1, parse: function (_context, tokens) { if (tokens.length === 0) { return null } var first2 = tokens[0] if (first2.type === 20 && first2.value === 'none') { return null } var increments = [] var filtered = tokens.filter(nonWhiteSpace) for (var i2 = 0; i2 < filtered.length; i2++) { var counter2 = filtered[i2] var next = filtered[i2 + 1] if (counter2.type === 20) { var increment = next && isNumberToken(next) ? next.number : 1 increments.push({ counter: counter2.value, increment }) } } return increments }, } var counterReset = { name: 'counter-reset', initialValue: 'none', prefix: true, type: 1, parse: function (_context, tokens) { if (tokens.length === 0) { return [] } var resets = [] var filtered = tokens.filter(nonWhiteSpace) for (var i2 = 0; i2 < filtered.length; i2++) { var counter2 = filtered[i2] var next = filtered[i2 + 1] if (isIdentToken(counter2) && counter2.value !== 'none') { var reset2 = next && isNumberToken(next) ? next.number : 0 resets.push({ counter: counter2.value, reset: reset2 }) } } return resets }, } var duration = { name: 'duration', initialValue: '0s', prefix: false, type: 1, parse: function (context2, tokens) { return tokens.filter(isDimensionToken).map(function (token) { return time$1.parse(context2, token) }) }, } var quotes = { name: 'quotes', initialValue: 'none', prefix: true, type: 1, parse: function (_context, tokens) { if (tokens.length === 0) { return null } var first2 = tokens[0] if (first2.type === 20 && first2.value === 'none') { return null } var quotes2 = [] var filtered = tokens.filter(isStringToken) if (filtered.length % 2 !== 0) { return null } for (var i2 = 0; i2 < filtered.length; i2 += 2) { var open_1 = filtered[i2].value var close_1 = filtered[i2 + 1].value quotes2.push({ open: open_1, close: close_1 }) } return quotes2 }, } var getQuote = function (quotes2, depth, open2) { if (!quotes2) { return '' } var quote = quotes2[Math.min(depth, quotes2.length - 1)] if (!quote) { return '' } return open2 ? quote.open : quote.close } var boxShadow = { name: 'box-shadow', initialValue: 'none', type: 1, prefix: false, parse: function (context2, tokens) { if (tokens.length === 1 && isIdentWithValue(tokens[0], 'none')) { return [] } return parseFunctionArgs(tokens).map(function (values2) { var shadow = { color: 255, offsetX: ZERO_LENGTH, offsetY: ZERO_LENGTH, blur: ZERO_LENGTH, spread: ZERO_LENGTH, inset: false, } var c2 = 0 for (var i2 = 0; i2 < values2.length; i2++) { var token = values2[i2] if (isIdentWithValue(token, 'inset')) { shadow.inset = true } else if (isLength$3(token)) { if (c2 === 0) { shadow.offsetX = token } else if (c2 === 1) { shadow.offsetY = token } else if (c2 === 2) { shadow.blur = token } else { shadow.spread = token } c2++ } else { shadow.color = color$1$1.parse(context2, token) } } return shadow }) }, } var paintOrder = { name: 'paint-order', initialValue: 'normal', prefix: false, type: 1, parse: function (_context, tokens) { var DEFAULT_VALUE2 = [0, 1, 2] var layers = [] tokens.filter(isIdentToken).forEach(function (token) { switch (token.value) { case 'stroke': layers.push(1) break case 'fill': layers.push(0) break case 'markers': layers.push(2) break } }) DEFAULT_VALUE2.forEach(function (value2) { if (layers.indexOf(value2) === -1) { layers.push(value2) } }) return layers }, } var webkitTextStrokeColor = { name: '-webkit-text-stroke-color', initialValue: 'currentcolor', prefix: false, type: 3, format: 'color', } var webkitTextStrokeWidth = { name: '-webkit-text-stroke-width', initialValue: '0', type: 0, prefix: false, parse: function (_context, token) { if (isDimensionToken(token)) { return token.number } return 0 }, } var CSSParsedDeclaration = (function () { function CSSParsedDeclaration2(context2, declaration) { var _a2, _b2 this.animationDuration = parse$2( context2, duration, declaration.animationDuration ) this.backgroundClip = parse$2( context2, backgroundClip, declaration.backgroundClip ) this.backgroundColor = parse$2( context2, backgroundColor$1, declaration.backgroundColor ) this.backgroundImage = parse$2( context2, backgroundImage, declaration.backgroundImage ) this.backgroundOrigin = parse$2( context2, backgroundOrigin, declaration.backgroundOrigin ) this.backgroundPosition = parse$2( context2, backgroundPosition, declaration.backgroundPosition ) this.backgroundRepeat = parse$2( context2, backgroundRepeat, declaration.backgroundRepeat ) this.backgroundSize = parse$2( context2, backgroundSize, declaration.backgroundSize ) this.borderTopColor = parse$2( context2, borderTopColor, declaration.borderTopColor ) this.borderRightColor = parse$2( context2, borderRightColor, declaration.borderRightColor ) this.borderBottomColor = parse$2( context2, borderBottomColor, declaration.borderBottomColor ) this.borderLeftColor = parse$2( context2, borderLeftColor, declaration.borderLeftColor ) this.borderTopLeftRadius = parse$2( context2, borderTopLeftRadius, declaration.borderTopLeftRadius ) this.borderTopRightRadius = parse$2( context2, borderTopRightRadius, declaration.borderTopRightRadius ) this.borderBottomRightRadius = parse$2( context2, borderBottomRightRadius, declaration.borderBottomRightRadius ) this.borderBottomLeftRadius = parse$2( context2, borderBottomLeftRadius, declaration.borderBottomLeftRadius ) this.borderTopStyle = parse$2( context2, borderTopStyle, declaration.borderTopStyle ) this.borderRightStyle = parse$2( context2, borderRightStyle, declaration.borderRightStyle ) this.borderBottomStyle = parse$2( context2, borderBottomStyle, declaration.borderBottomStyle ) this.borderLeftStyle = parse$2( context2, borderLeftStyle, declaration.borderLeftStyle ) this.borderTopWidth = parse$2( context2, borderTopWidth, declaration.borderTopWidth ) this.borderRightWidth = parse$2( context2, borderRightWidth, declaration.borderRightWidth ) this.borderBottomWidth = parse$2( context2, borderBottomWidth, declaration.borderBottomWidth ) this.borderLeftWidth = parse$2( context2, borderLeftWidth, declaration.borderLeftWidth ) this.boxShadow = parse$2(context2, boxShadow, declaration.boxShadow) this.color = parse$2(context2, color$2, declaration.color) this.direction = parse$2(context2, direction, declaration.direction) this.display = parse$2(context2, display, declaration.display) this.float = parse$2(context2, float, declaration.cssFloat) this.fontFamily = parse$2(context2, fontFamily, declaration.fontFamily) this.fontSize = parse$2(context2, fontSize, declaration.fontSize) this.fontStyle = parse$2(context2, fontStyle, declaration.fontStyle) this.fontVariant = parse$2(context2, fontVariant, declaration.fontVariant) this.fontWeight = parse$2(context2, fontWeight, declaration.fontWeight) this.letterSpacing = parse$2( context2, letterSpacing, declaration.letterSpacing ) this.lineBreak = parse$2(context2, lineBreak, declaration.lineBreak) this.lineHeight = parse$2(context2, lineHeight, declaration.lineHeight) this.listStyleImage = parse$2( context2, listStyleImage, declaration.listStyleImage ) this.listStylePosition = parse$2( context2, listStylePosition, declaration.listStylePosition ) this.listStyleType = parse$2( context2, listStyleType, declaration.listStyleType ) this.marginTop = parse$2(context2, marginTop, declaration.marginTop) this.marginRight = parse$2(context2, marginRight, declaration.marginRight) this.marginBottom = parse$2( context2, marginBottom, declaration.marginBottom ) this.marginLeft = parse$2(context2, marginLeft, declaration.marginLeft) this.opacity = parse$2(context2, opacity, declaration.opacity) var overflowTuple = parse$2(context2, overflow, declaration.overflow) this.overflowX = overflowTuple[0] this.overflowY = overflowTuple[overflowTuple.length > 1 ? 1 : 0] this.overflowWrap = parse$2( context2, overflowWrap, declaration.overflowWrap ) this.paddingTop = parse$2(context2, paddingTop, declaration.paddingTop) this.paddingRight = parse$2( context2, paddingRight, declaration.paddingRight ) this.paddingBottom = parse$2( context2, paddingBottom, declaration.paddingBottom ) this.paddingLeft = parse$2(context2, paddingLeft, declaration.paddingLeft) this.paintOrder = parse$2(context2, paintOrder, declaration.paintOrder) this.position = parse$2(context2, position$1, declaration.position) this.textAlign = parse$2(context2, textAlign, declaration.textAlign) this.textDecorationColor = parse$2( context2, textDecorationColor, (_a2 = declaration.textDecorationColor) !== null && _a2 !== void 0 ? _a2 : declaration.color ) this.textDecorationLine = parse$2( context2, textDecorationLine, (_b2 = declaration.textDecorationLine) !== null && _b2 !== void 0 ? _b2 : declaration.textDecoration ) this.textShadow = parse$2(context2, textShadow, declaration.textShadow) this.textTransform = parse$2( context2, textTransform, declaration.textTransform ) this.transform = parse$2(context2, transform$1, declaration.transform) this.transformOrigin = parse$2( context2, transformOrigin, declaration.transformOrigin ) this.visibility = parse$2(context2, visibility, declaration.visibility) this.webkitTextStrokeColor = parse$2( context2, webkitTextStrokeColor, declaration.webkitTextStrokeColor ) this.webkitTextStrokeWidth = parse$2( context2, webkitTextStrokeWidth, declaration.webkitTextStrokeWidth ) this.wordBreak = parse$2(context2, wordBreak, declaration.wordBreak) this.zIndex = parse$2(context2, zIndex, declaration.zIndex) } CSSParsedDeclaration2.prototype.isVisible = function () { return this.display > 0 && this.opacity > 0 && this.visibility === 0 } CSSParsedDeclaration2.prototype.isTransparent = function () { return isTransparent(this.backgroundColor) } CSSParsedDeclaration2.prototype.isTransformed = function () { return this.transform !== null } CSSParsedDeclaration2.prototype.isPositioned = function () { return this.position !== 0 } CSSParsedDeclaration2.prototype.isPositionedWithZIndex = function () { return this.isPositioned() && !this.zIndex.auto } CSSParsedDeclaration2.prototype.isFloating = function () { return this.float !== 0 } CSSParsedDeclaration2.prototype.isInlineLevel = function () { return ( contains(this.display, 4) || contains(this.display, 33554432) || contains(this.display, 268435456) || contains(this.display, 536870912) || contains(this.display, 67108864) || contains(this.display, 134217728) ) } return CSSParsedDeclaration2 })() var CSSParsedPseudoDeclaration = (function () { function CSSParsedPseudoDeclaration2(context2, declaration) { this.content = parse$2(context2, content, declaration.content) this.quotes = parse$2(context2, quotes, declaration.quotes) } return CSSParsedPseudoDeclaration2 })() var CSSParsedCounterDeclaration = (function () { function CSSParsedCounterDeclaration2(context2, declaration) { this.counterIncrement = parse$2( context2, counterIncrement, declaration.counterIncrement ) this.counterReset = parse$2( context2, counterReset, declaration.counterReset ) } return CSSParsedCounterDeclaration2 })() var parse$2 = function (context2, descriptor, style2) { var tokenizer = new Tokenizer() var value2 = style2 !== null && typeof style2 !== 'undefined' ? style2.toString() : descriptor.initialValue tokenizer.write(value2) var parser2 = new Parser$1(tokenizer.read()) switch (descriptor.type) { case 2: var token = parser2.parseComponentValue() return descriptor.parse( context2, isIdentToken(token) ? token.value : descriptor.initialValue ) case 0: return descriptor.parse(context2, parser2.parseComponentValue()) case 1: return descriptor.parse(context2, parser2.parseComponentValues()) case 4: return parser2.parseComponentValue() case 3: switch (descriptor.format) { case 'angle': return angle.parse(context2, parser2.parseComponentValue()) case 'color': return color$1$1.parse(context2, parser2.parseComponentValue()) case 'image': return image$1.parse(context2, parser2.parseComponentValue()) case 'length': var length_1 = parser2.parseComponentValue() return isLength$3(length_1) ? length_1 : ZERO_LENGTH case 'length-percentage': var value_1 = parser2.parseComponentValue() return isLengthPercentage(value_1) ? value_1 : ZERO_LENGTH case 'time': return time$1.parse(context2, parser2.parseComponentValue()) } break } } var elementDebuggerAttribute = 'data-html2canvas-debug' var getElementDebugType = function (element) { var attribute = element.getAttribute(elementDebuggerAttribute) switch (attribute) { case 'all': return 1 case 'clone': return 2 case 'parse': return 3 case 'render': return 4 default: return 0 } } var isDebugging = function (element, type4) { var elementType = getElementDebugType(element) return elementType === 1 || type4 === elementType } var ElementContainer = (function () { function ElementContainer2(context2, element) { this.context = context2 this.textNodes = [] this.elements = [] this.flags = 0 if (isDebugging(element, 3)) { debugger } this.styles = new CSSParsedDeclaration( context2, window.getComputedStyle(element, null) ) if (isHTMLElementNode(element)) { if ( this.styles.animationDuration.some(function (duration2) { return duration2 > 0 }) ) { element.style.animationDuration = '0s' } if (this.styles.transform !== null) { element.style.transform = 'none' } } this.bounds = parseBounds(this.context, element) if (isDebugging(element, 4)) { this.flags |= 16 } } return ElementContainer2 })() var base64 = 'AAAAAAAAAAAAEA4AGBkAAFAaAAACAAAAAAAIABAAGAAwADgACAAQAAgAEAAIABAACAAQAAgAEAAIABAACAAQAAgAEAAIABAAQABIAEQATAAIABAACAAQAAgAEAAIABAAVABcAAgAEAAIABAACAAQAGAAaABwAHgAgACIAI4AlgAIABAAmwCjAKgAsAC2AL4AvQDFAMoA0gBPAVYBWgEIAAgACACMANoAYgFkAWwBdAF8AX0BhQGNAZUBlgGeAaMBlQGWAasBswF8AbsBwwF0AcsBYwHTAQgA2wG/AOMBdAF8AekB8QF0AfkB+wHiAHQBfAEIAAMC5gQIAAsCEgIIAAgAFgIeAggAIgIpAggAMQI5AkACygEIAAgASAJQAlgCYAIIAAgACAAKBQoFCgUTBRMFGQUrBSsFCAAIAAgACAAIAAgACAAIAAgACABdAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABoAmgCrwGvAQgAbgJ2AggAHgEIAAgACADnAXsCCAAIAAgAgwIIAAgACAAIAAgACACKAggAkQKZAggAPADJAAgAoQKkAqwCsgK6AsICCADJAggA0AIIAAgACAAIANYC3gIIAAgACAAIAAgACABAAOYCCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAkASoB+QIEAAgACAA8AEMCCABCBQgACABJBVAFCAAIAAgACAAIAAgACAAIAAgACABTBVoFCAAIAFoFCABfBWUFCAAIAAgACAAIAAgAbQUIAAgACAAIAAgACABzBXsFfQWFBYoFigWKBZEFigWKBYoFmAWfBaYFrgWxBbkFCAAIAAgACAAIAAgACAAIAAgACAAIAMEFCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAMgFCADQBQgACAAIAAgACAAIAAgACAAIAAgACAAIAO4CCAAIAAgAiQAIAAgACABAAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAD0AggACAD8AggACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIANYFCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAMDvwAIAAgAJAIIAAgACAAIAAgACAAIAAgACwMTAwgACAB9BOsEGwMjAwgAKwMyAwsFYgE3A/MEPwMIAEUDTQNRAwgAWQOsAGEDCAAIAAgACAAIAAgACABpAzQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFOgU0BTUFNgU3BTgFOQU6BTQFNQU2BTcFOAU5BToFNAU1BTYFNwU4BTkFIQUoBSwFCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABtAwgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABMAEwACAAIAAgACAAIABgACAAIAAgACAC/AAgACAAyAQgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACACAAIAAwAAgACAAIAAgACAAIAAgACAAIAAAARABIAAgACAAIABQASAAIAAgAIABwAEAAjgCIABsAqAC2AL0AigDQAtwC+IJIQqVAZUBWQqVAZUBlQGVAZUBlQGrC5UBlQGVAZUBlQGVAZUBlQGVAXsKlQGVAbAK6wsrDGUMpQzlDJUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAZUBlQGVAfAKAAuZA64AtwCJALoC6ADwAAgAuACgA/oEpgO6AqsD+AAIAAgAswMIAAgACAAIAIkAuwP5AfsBwwPLAwgACAAIAAgACADRA9kDCAAIAOED6QMIAAgACAAIAAgACADuA/YDCAAIAP4DyQAIAAgABgQIAAgAXQAOBAgACAAIAAgACAAIABMECAAIAAgACAAIAAgACAD8AAQBCAAIAAgAGgQiBCoECAExBAgAEAEIAAgACAAIAAgACAAIAAgACAAIAAgACAA4BAgACABABEYECAAIAAgATAQYAQgAVAQIAAgACAAIAAgACAAIAAgACAAIAFoECAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAOQEIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAB+BAcACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAEABhgSMBAgACAAIAAgAlAQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAwAEAAQABAADAAMAAwADAAQABAAEAAQABAAEAAQABHATAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAdQMIAAgACAAIAAgACAAIAMkACAAIAAgAfQMIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACACFA4kDCAAIAAgACAAIAOcBCAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAIcDCAAIAAgACAAIAAgACAAIAAgACAAIAJEDCAAIAAgACADFAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABgBAgAZgQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAbAQCBXIECAAIAHkECAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACABAAJwEQACjBKoEsgQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAC6BMIECAAIAAgACAAIAAgACABmBAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAxwQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAGYECAAIAAgAzgQIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgAigWKBYoFigWKBYoFigWKBd0FXwUIAOIF6gXxBYoF3gT5BQAGCAaKBYoFigWKBYoFigWKBYoFigWKBYoFigXWBIoFigWKBYoFigWKBYoFigWKBYsFEAaKBYoFigWKBYoFigWKBRQGCACKBYoFigWKBQgACAAIANEECAAIABgGigUgBggAJgYIAC4GMwaKBYoF0wQ3Bj4GigWKBYoFigWKBYoFigWKBYoFigWKBYoFigUIAAgACAAIAAgACAAIAAgAigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWKBYoFigWLBf///////wQABAAEAAQABAAEAAQABAAEAAQAAwAEAAQAAgAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAAAAAAAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAQADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAUAAAAFAAUAAAAFAAUAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABAAEAAQABAAEAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUAAQAAAAUABQAFAAUABQAFAAAAAAAFAAUAAAAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAFAAUAAQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABwAFAAUABQAFAAAABwAHAAcAAAAHAAcABwAFAAEAAAAAAAAAAAAAAAAAAAAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAcABwAFAAUABQAFAAcABwAFAAUAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAAAAQABAAAAAAAAAAAAAAAFAAUABQAFAAAABwAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAHAAcABwAHAAcAAAAHAAcAAAAAAAUABQAHAAUAAQAHAAEABwAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABwABAAUABQAFAAUAAAAAAAAAAAAAAAEAAQABAAEAAQABAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABwAFAAUAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUAAQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQABQANAAQABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQABAAEAAQABAAEAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABAAEAAQABAAEAAQABAAEAAQABAAEAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEAAQABAAEAAQABAAEAAQABAAAAAAAAAAAAAAAAAAAAAAABQAHAAUABQAFAAAAAAAAAAcABQAFAAUABQAFAAQABAAEAAQABAAEAAQABAAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAEAAQABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUAAAAFAAUABQAFAAUAAAAFAAUABQAAAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAAAAAAAAAAAAUABQAFAAcAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAHAAUAAAAHAAcABwAFAAUABQAFAAUABQAFAAUABwAHAAcABwAFAAcABwAAAAUABQAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABwAHAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAUABwAHAAUABQAFAAUAAAAAAAcABwAAAAAABwAHAAUAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAABQAFAAcAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAABwAHAAcABQAFAAAAAAAAAAAABQAFAAAAAAAFAAUABQAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAFAAUABQAFAAUAAAAFAAUABwAAAAcABwAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAFAAUABwAFAAUABQAFAAAAAAAHAAcAAAAAAAcABwAFAAAAAAAAAAAAAAAAAAAABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAcABwAAAAAAAAAHAAcABwAAAAcABwAHAAUAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAABQAHAAcABwAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABwAHAAcABwAAAAUABQAFAAAABQAFAAUABQAAAAAAAAAAAAAAAAAAAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAcABQAHAAcABQAHAAcAAAAFAAcABwAAAAcABwAFAAUAAAAAAAAAAAAAAAAAAAAFAAUAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAcABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAAAAUABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAAAAAAAAAFAAcABwAFAAUABQAAAAUAAAAHAAcABwAHAAcABwAHAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAHAAUABQAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAABwAFAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAUAAAAFAAAAAAAAAAAABwAHAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABwAFAAUABQAFAAUAAAAFAAUAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABwAFAAUABQAFAAUABQAAAAUABQAHAAcABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAcABQAFAAAAAAAAAAAABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAcABQAFAAAAAAAAAAAAAAAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAHAAUABQAFAAUABQAFAAUABwAHAAcABwAHAAcABwAHAAUABwAHAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABwAHAAcABwAFAAUABwAHAAcAAAAAAAAAAAAHAAcABQAHAAcABwAHAAcABwAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAcABwAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABQAHAAUABQAFAAUABQAFAAUAAAAFAAAABQAAAAAABQAFAAUABQAFAAUABQAFAAcABwAHAAcABwAHAAUABQAFAAUABQAFAAUABQAFAAUAAAAAAAUABQAFAAUABQAHAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUABwAFAAcABwAHAAcABwAFAAcABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAUABQAFAAUABwAHAAUABQAHAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAcABQAFAAcABwAHAAUABwAFAAUABQAHAAcAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAHAAcABwAHAAcABwAHAAUABQAFAAUABQAFAAUABQAHAAcABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUAAAAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAcABQAFAAUABQAFAAUABQAAAAAAAAAAAAUAAAAAAAAAAAAAAAAABQAAAAAABwAFAAUAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAAABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUAAAAFAAUABQAFAAUABQAFAAUABQAFAAAAAAAAAAAABQAAAAAAAAAFAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAHAAUABQAHAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABwAHAAcABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAUABQAFAAUABQAHAAcAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAcABwAFAAUABQAFAAcABwAFAAUABwAHAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAFAAcABwAFAAUABwAHAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAFAAcAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAFAAUABQAAAAAABQAFAAAAAAAAAAAAAAAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABQAFAAcABwAAAAAAAAAAAAAABwAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABwAFAAcABwAFAAcABwAAAAcABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAAAAAAAAAAAAAAAAAFAAUABQAAAAUABQAAAAAAAAAAAAAABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAAAAAAAAAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABQAHAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABwAFAAUABQAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAHAAcABQAFAAUABQAFAAUABQAFAAUABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAcABwAFAAUABQAHAAcABQAHAAUABQAAAAAAAAAAAAAAAAAFAAAABwAHAAcABQAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABwAHAAcABwAAAAAABwAHAAAAAAAHAAcABwAAAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAHAAAAAAAFAAUABQAFAAUABQAFAAAAAAAAAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAcABwAFAAUABQAFAAUABQAFAAUABwAHAAUABQAFAAcABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAHAAcABQAFAAUABQAFAAUABwAFAAcABwAFAAcABQAFAAcABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAHAAcABQAFAAUABQAAAAAABwAHAAcABwAFAAUABwAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABwAHAAUABQAFAAUABQAFAAUABQAHAAcABQAHAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABwAFAAcABwAFAAUABQAFAAUABQAHAAUAAAAAAAAAAAAAAAAAAAAAAAcABwAFAAUABQAFAAcABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAcABwAFAAUABQAFAAUABQAFAAUABQAHAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAcABwAFAAUABQAFAAAAAAAFAAUABwAHAAcABwAFAAAAAAAAAAcAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABwAHAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABQAFAAUABQAFAAUABQAAAAUABQAFAAUABQAFAAcABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUAAAAHAAUABQAFAAUABQAFAAUABwAFAAUABwAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUAAAAAAAAABQAAAAUABQAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAHAAcABwAHAAcAAAAFAAUAAAAHAAcABQAHAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABwAHAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAAAAAAAAAAAAAAAAAAABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAAAAUABQAFAAAAAAAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAAAAAAAAAAABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAUABQAFAAUABQAAAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABQAAAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAFAAUABQAAAAAABQAFAAUABQAFAAUABQAAAAUABQAAAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFAAUABQAFAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABQAFAAUABQAFAAUABQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAFAAUABQAFAAUADgAOAA4ADgAOAA4ADwAPAA8ADwAPAA8ADwAPAA8ADwAPAA8ADwAPAA8ADwAPAA8ADwAPAA8ADwAPAA8ADwAPAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAHAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAcABwAHAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAgACAAIAAAAAAAAAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAMAAwADAAMAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkACQAJAAkAAAAAAAAAAAAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAKAAoACgAAAAAAAAAAAAsADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwACwAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAMAAwADAAAAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4ADgAAAAAAAAAAAAAAAAAAAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAA4ADgAOAA4ADgAOAA4ADgAOAAAAAAAAAAAADgAOAA4AAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAA4ADgAAAA4ADgAOAA4ADgAOAAAADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4AAAAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4AAAAAAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAAAA4AAAAOAAAAAAAAAAAAAAAAAA4AAAAAAAAAAAAAAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAAAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAAAAAADgAAAAAAAAAAAA4AAAAOAAAAAAAAAAAADgAOAA4AAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAOAA4AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAAAAAAAAAAAA4AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4ADgAOAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAAAAAADgAOAA4ADgAOAA4ADgAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAAAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4AAAAAAA4ADgAOAA4ADgAOAA4ADgAOAAAADgAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4AAAAAAAAAAAAAAAAADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAA4ADgAOAA4ADgAOAAAAAAAAAAAAAAAAAAAAAAAAAAAADgAOAA4ADgAOAA4AAAAAAAAAAAAAAAAAAAAAAA4ADgAOAA4ADgAOAA4ADgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4AAAAOAA4ADgAOAA4ADgAAAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4ADgAOAA4AAAAAAAAAAAA=' var chars$1 = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/' var lookup$1 = typeof Uint8Array === 'undefined' ? [] : new Uint8Array(256) for (var i$1$2 = 0; i$1$2 < chars$1.length; i$1$2++) { lookup$1[chars$1.charCodeAt(i$1$2)] = i$1$2 } var decode$2 = function (base642) { var bufferLength = base642.length * 0.75, len2 = base642.length, i2, p2 = 0, encoded1, encoded2, encoded3, encoded4 if (base642[base642.length - 1] === '=') { bufferLength-- if (base642[base642.length - 2] === '=') { bufferLength-- } } var buffer = typeof ArrayBuffer !== 'undefined' && typeof Uint8Array !== 'undefined' && typeof Uint8Array.prototype.slice !== 'undefined' ? new ArrayBuffer(bufferLength) : new Array(bufferLength) var bytes = Array.isArray(buffer) ? buffer : new Uint8Array(buffer) for (i2 = 0; i2 < len2; i2 += 4) { encoded1 = lookup$1[base642.charCodeAt(i2)] encoded2 = lookup$1[base642.charCodeAt(i2 + 1)] encoded3 = lookup$1[base642.charCodeAt(i2 + 2)] encoded4 = lookup$1[base642.charCodeAt(i2 + 3)] bytes[p2++] = (encoded1 << 2) | (encoded2 >> 4) bytes[p2++] = ((encoded2 & 15) << 4) | (encoded3 >> 2) bytes[p2++] = ((encoded3 & 3) << 6) | (encoded4 & 63) } return buffer } var polyUint16Array = function (buffer) { var length2 = buffer.length var bytes = [] for (var i2 = 0; i2 < length2; i2 += 2) { bytes.push((buffer[i2 + 1] << 8) | buffer[i2]) } return bytes } var polyUint32Array = function (buffer) { var length2 = buffer.length var bytes = [] for (var i2 = 0; i2 < length2; i2 += 4) { bytes.push( (buffer[i2 + 3] << 24) | (buffer[i2 + 2] << 16) | (buffer[i2 + 1] << 8) | buffer[i2] ) } return bytes } var UTRIE2_SHIFT_2 = 5 var UTRIE2_SHIFT_1 = 6 + 5 var UTRIE2_INDEX_SHIFT = 2 var UTRIE2_SHIFT_1_2 = UTRIE2_SHIFT_1 - UTRIE2_SHIFT_2 var UTRIE2_LSCP_INDEX_2_OFFSET = 65536 >> UTRIE2_SHIFT_2 var UTRIE2_DATA_BLOCK_LENGTH = 1 << UTRIE2_SHIFT_2 var UTRIE2_DATA_MASK = UTRIE2_DATA_BLOCK_LENGTH - 1 var UTRIE2_LSCP_INDEX_2_LENGTH = 1024 >> UTRIE2_SHIFT_2 var UTRIE2_INDEX_2_BMP_LENGTH = UTRIE2_LSCP_INDEX_2_OFFSET + UTRIE2_LSCP_INDEX_2_LENGTH var UTRIE2_UTF8_2B_INDEX_2_OFFSET = UTRIE2_INDEX_2_BMP_LENGTH var UTRIE2_UTF8_2B_INDEX_2_LENGTH = 2048 >> 6 var UTRIE2_INDEX_1_OFFSET = UTRIE2_UTF8_2B_INDEX_2_OFFSET + UTRIE2_UTF8_2B_INDEX_2_LENGTH var UTRIE2_OMITTED_BMP_INDEX_1_LENGTH = 65536 >> UTRIE2_SHIFT_1 var UTRIE2_INDEX_2_BLOCK_LENGTH = 1 << UTRIE2_SHIFT_1_2 var UTRIE2_INDEX_2_MASK = UTRIE2_INDEX_2_BLOCK_LENGTH - 1 var slice16 = function (view2, start2, end2) { if (view2.slice) { return view2.slice(start2, end2) } return new Uint16Array(Array.prototype.slice.call(view2, start2, end2)) } var slice32 = function (view2, start2, end2) { if (view2.slice) { return view2.slice(start2, end2) } return new Uint32Array(Array.prototype.slice.call(view2, start2, end2)) } var createTrieFromBase64 = function (base642, _byteLength) { var buffer = decode$2(base642) var view32 = Array.isArray(buffer) ? polyUint32Array(buffer) : new Uint32Array(buffer) var view16 = Array.isArray(buffer) ? polyUint16Array(buffer) : new Uint16Array(buffer) var headerLength = 24 var index2 = slice16(view16, headerLength / 2, view32[4] / 2) var data2 = view32[5] === 2 ? slice16(view16, (headerLength + view32[4]) / 2) : slice32(view32, Math.ceil((headerLength + view32[4]) / 4)) return new Trie(view32[0], view32[1], view32[2], view32[3], index2, data2) } var Trie = (function () { function Trie2( initialValue, errorValue, highStart, highValueIndex, index2, data2 ) { this.initialValue = initialValue this.errorValue = errorValue this.highStart = highStart this.highValueIndex = highValueIndex this.index = index2 this.data = data2 } Trie2.prototype.get = function (codePoint) { var ix if (codePoint >= 0) { if (codePoint < 55296 || (codePoint > 56319 && codePoint <= 65535)) { ix = this.index[codePoint >> UTRIE2_SHIFT_2] ix = (ix << UTRIE2_INDEX_SHIFT) + (codePoint & UTRIE2_DATA_MASK) return this.data[ix] } if (codePoint <= 65535) { ix = this.index[ UTRIE2_LSCP_INDEX_2_OFFSET + ((codePoint - 55296) >> UTRIE2_SHIFT_2) ] ix = (ix << UTRIE2_INDEX_SHIFT) + (codePoint & UTRIE2_DATA_MASK) return this.data[ix] } if (codePoint < this.highStart) { ix = UTRIE2_INDEX_1_OFFSET - UTRIE2_OMITTED_BMP_INDEX_1_LENGTH + (codePoint >> UTRIE2_SHIFT_1) ix = this.index[ix] ix += (codePoint >> UTRIE2_SHIFT_2) & UTRIE2_INDEX_2_MASK ix = this.index[ix] ix = (ix << UTRIE2_INDEX_SHIFT) + (codePoint & UTRIE2_DATA_MASK) return this.data[ix] } if (codePoint <= 1114111) { return this.data[this.highValueIndex] } } return this.errorValue } return Trie2 })() var chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/' var lookup = typeof Uint8Array === 'undefined' ? [] : new Uint8Array(256) for (var i$4 = 0; i$4 < chars.length; i$4++) { lookup[chars.charCodeAt(i$4)] = i$4 } var Prepend = 1 var CR = 2 var LF = 3 var Control = 4 var Extend = 5 var SpacingMark = 7 var L = 8 var V = 9 var T$1 = 10 var LV = 11 var LVT = 12 var ZWJ = 13 var Extended_Pictographic = 14 var RI = 15 var toCodePoints = function (str) { var codePoints = [] var i2 = 0 var length2 = str.length while (i2 < length2) { var value2 = str.charCodeAt(i2++) if (value2 >= 55296 && value2 <= 56319 && i2 < length2) { var extra = str.charCodeAt(i2++) if ((extra & 64512) === 56320) { codePoints.push(((value2 & 1023) << 10) + (extra & 1023) + 65536) } else { codePoints.push(value2) i2-- } } else { codePoints.push(value2) } } return codePoints } var fromCodePoint = function () { var codePoints = [] for (var _i = 0; _i < arguments.length; _i++) { codePoints[_i] = arguments[_i] } if (String.fromCodePoint) { return String.fromCodePoint.apply(String, codePoints) } var length2 = codePoints.length if (!length2) { return '' } var codeUnits = [] var index2 = -1 var result = '' while (++index2 < length2) { var codePoint = codePoints[index2] if (codePoint <= 65535) { codeUnits.push(codePoint) } else { codePoint -= 65536 codeUnits.push((codePoint >> 10) + 55296, (codePoint % 1024) + 56320) } if (index2 + 1 === length2 || codeUnits.length > 16384) { result += String.fromCharCode.apply(String, codeUnits) codeUnits.length = 0 } } return result } var UnicodeTrie = createTrieFromBase64(base64) var BREAK_NOT_ALLOWED = '\xD7' var BREAK_ALLOWED = '\xF7' var codePointToClass = function (codePoint) { return UnicodeTrie.get(codePoint) } var _graphemeBreakAtIndex = function (_codePoints, classTypes, index2) { var prevIndex = index2 - 2 var prev = classTypes[prevIndex] var current2 = classTypes[index2 - 1] var next = classTypes[index2] if (current2 === CR && next === LF) { return BREAK_NOT_ALLOWED } if (current2 === CR || current2 === LF || current2 === Control) { return BREAK_ALLOWED } if (next === CR || next === LF || next === Control) { return BREAK_ALLOWED } if (current2 === L && [L, V, LV, LVT].indexOf(next) !== -1) { return BREAK_NOT_ALLOWED } if ((current2 === LV || current2 === V) && (next === V || next === T$1)) { return BREAK_NOT_ALLOWED } if ((current2 === LVT || current2 === T$1) && next === T$1) { return BREAK_NOT_ALLOWED } if (next === ZWJ || next === Extend) { return BREAK_NOT_ALLOWED } if (next === SpacingMark) { return BREAK_NOT_ALLOWED } if (current2 === Prepend) { return BREAK_NOT_ALLOWED } if (current2 === ZWJ && next === Extended_Pictographic) { while (prev === Extend) { prev = classTypes[--prevIndex] } if (prev === Extended_Pictographic) { return BREAK_NOT_ALLOWED } } if (current2 === RI && next === RI) { var countRI = 0 while (prev === RI) { countRI++ prev = classTypes[--prevIndex] } if (countRI % 2 === 0) { return BREAK_NOT_ALLOWED } } return BREAK_ALLOWED } var GraphemeBreaker = function (str) { var codePoints = toCodePoints(str) var length2 = codePoints.length var index2 = 0 var lastEnd = 0 var classTypes = codePoints.map(codePointToClass) return { next: function () { if (index2 >= length2) { return { done: true, value: null } } var graphemeBreak = BREAK_NOT_ALLOWED while ( index2 < length2 && (graphemeBreak = _graphemeBreakAtIndex( codePoints, classTypes, ++index2 )) === BREAK_NOT_ALLOWED ) {} if (graphemeBreak !== BREAK_NOT_ALLOWED || index2 === length2) { var value2 = fromCodePoint.apply( null, codePoints.slice(lastEnd, index2) ) lastEnd = index2 return { value: value2, done: false } } return { done: true, value: null } }, } } var splitGraphemes = function (str) { var breaker = GraphemeBreaker(str) var graphemes = [] var bk while (!(bk = breaker.next()).done) { if (bk.value) { graphemes.push(bk.value.slice()) } } return graphemes } var testRangeBounds = function (document2) { var TEST_HEIGHT = 123 if (document2.createRange) { var range3 = document2.createRange() if (range3.getBoundingClientRect) { var testElement = document2.createElement('boundtest') testElement.style.height = TEST_HEIGHT + 'px' testElement.style.display = 'block' document2.body.appendChild(testElement) range3.selectNode(testElement) var rangeBounds = range3.getBoundingClientRect() var rangeHeight = Math.round(rangeBounds.height) document2.body.removeChild(testElement) if (rangeHeight === TEST_HEIGHT) { return true } } } return false } var testIOSLineBreak = function (document2) { var testElement = document2.createElement('boundtest') testElement.style.width = '50px' testElement.style.display = 'block' testElement.style.fontSize = '12px' testElement.style.letterSpacing = '0px' testElement.style.wordSpacing = '0px' document2.body.appendChild(testElement) var range3 = document2.createRange() testElement.innerHTML = typeof ''.repeat === 'function' ? '👨'.repeat(10) : '' var node2 = testElement.firstChild var textList = toCodePoints$1(node2.data).map(function (i2) { return fromCodePoint$1(i2) }) var offset2 = 0 var prev = {} var supports = textList.every(function (text2, i2) { range3.setStart(node2, offset2) range3.setEnd(node2, offset2 + text2.length) var rect = range3.getBoundingClientRect() offset2 += text2.length var boundAhead = rect.x > prev.x || rect.y > prev.y prev = rect if (i2 === 0) { return true } return boundAhead }) document2.body.removeChild(testElement) return supports } var testCORS = function () { return typeof new Image().crossOrigin !== 'undefined' } var testResponseType = function () { return typeof new XMLHttpRequest().responseType === 'string' } var testSVG = function (document2) { var img = new Image() var canvas = document2.createElement('canvas') var ctx = canvas.getContext('2d') if (!ctx) { return false } img.src = "data:image/svg+xml," try { ctx.drawImage(img, 0, 0) canvas.toDataURL() } catch (e2) { return false } return true } var isGreenPixel = function (data2) { return ( data2[0] === 0 && data2[1] === 255 && data2[2] === 0 && data2[3] === 255 ) } var testForeignObject = function (document2) { var canvas = document2.createElement('canvas') var size = 100 canvas.width = size canvas.height = size var ctx = canvas.getContext('2d') if (!ctx) { return Promise.reject(false) } ctx.fillStyle = 'rgb(0, 255, 0)' ctx.fillRect(0, 0, size, size) var img = new Image() var greenImageSrc = canvas.toDataURL() img.src = greenImageSrc var svg2 = createForeignObjectSVG(size, size, 0, 0, img) ctx.fillStyle = 'red' ctx.fillRect(0, 0, size, size) return loadSerializedSVG$1(svg2) .then(function (img2) { ctx.drawImage(img2, 0, 0) var data2 = ctx.getImageData(0, 0, size, size).data ctx.fillStyle = 'red' ctx.fillRect(0, 0, size, size) var node2 = document2.createElement('div') node2.style.backgroundImage = 'url(' + greenImageSrc + ')' node2.style.height = size + 'px' return isGreenPixel(data2) ? loadSerializedSVG$1(createForeignObjectSVG(size, size, 0, 0, node2)) : Promise.reject(false) }) .then(function (img2) { ctx.drawImage(img2, 0, 0) return isGreenPixel(ctx.getImageData(0, 0, size, size).data) }) .catch(function () { return false }) } var createForeignObjectSVG = function (width, height, x2, y2, node2) { var xmlns = 'http://www.w3.org/2000/svg' var svg2 = document.createElementNS(xmlns, 'svg') var foreignObject = document.createElementNS(xmlns, 'foreignObject') svg2.setAttributeNS(null, 'width', width.toString()) svg2.setAttributeNS(null, 'height', height.toString()) foreignObject.setAttributeNS(null, 'width', '100%') foreignObject.setAttributeNS(null, 'height', '100%') foreignObject.setAttributeNS(null, 'x', x2.toString()) foreignObject.setAttributeNS(null, 'y', y2.toString()) foreignObject.setAttributeNS(null, 'externalResourcesRequired', 'true') svg2.appendChild(foreignObject) foreignObject.appendChild(node2) return svg2 } var loadSerializedSVG$1 = function (svg2) { return new Promise(function (resolve2, reject2) { var img = new Image() img.onload = function () { return resolve2(img) } img.onerror = reject2 img.src = 'data:image/svg+xml;charset=utf-8,' + encodeURIComponent(new XMLSerializer().serializeToString(svg2)) }) } var FEATURES = { get SUPPORT_RANGE_BOUNDS() { var value2 = testRangeBounds(document) Object.defineProperty(FEATURES, 'SUPPORT_RANGE_BOUNDS', { value: value2 }) return value2 }, get SUPPORT_WORD_BREAKING() { var value2 = FEATURES.SUPPORT_RANGE_BOUNDS && testIOSLineBreak(document) Object.defineProperty(FEATURES, 'SUPPORT_WORD_BREAKING', { value: value2 }) return value2 }, get SUPPORT_SVG_DRAWING() { var value2 = testSVG(document) Object.defineProperty(FEATURES, 'SUPPORT_SVG_DRAWING', { value: value2 }) return value2 }, get SUPPORT_FOREIGNOBJECT_DRAWING() { var value2 = typeof Array.from === 'function' && typeof window.fetch === 'function' ? testForeignObject(document) : Promise.resolve(false) Object.defineProperty(FEATURES, 'SUPPORT_FOREIGNOBJECT_DRAWING', { value: value2, }) return value2 }, get SUPPORT_CORS_IMAGES() { var value2 = testCORS() Object.defineProperty(FEATURES, 'SUPPORT_CORS_IMAGES', { value: value2 }) return value2 }, get SUPPORT_RESPONSE_TYPE() { var value2 = testResponseType() Object.defineProperty(FEATURES, 'SUPPORT_RESPONSE_TYPE', { value: value2 }) return value2 }, get SUPPORT_CORS_XHR() { var value2 = 'withCredentials' in new XMLHttpRequest() Object.defineProperty(FEATURES, 'SUPPORT_CORS_XHR', { value: value2 }) return value2 }, get SUPPORT_NATIVE_TEXT_SEGMENTATION() { var value2 = !!(typeof Intl !== 'undefined' && Intl.Segmenter) Object.defineProperty(FEATURES, 'SUPPORT_NATIVE_TEXT_SEGMENTATION', { value: value2, }) return value2 }, } var TextBounds = (function () { function TextBounds2(text2, bounds) { this.text = text2 this.bounds = bounds } return TextBounds2 })() var parseTextBounds = function (context2, value2, styles, node2) { var textList = breakText(value2, styles) var textBounds = [] var offset2 = 0 textList.forEach(function (text2) { if (styles.textDecorationLine.length || text2.trim().length > 0) { if (FEATURES.SUPPORT_RANGE_BOUNDS) { var clientRects = createRange( node2, offset2, text2.length ).getClientRects() if (clientRects.length > 1) { var subSegments = segmentGraphemes(text2) var subOffset_1 = 0 subSegments.forEach(function (subSegment) { textBounds.push( new TextBounds( subSegment, Bounds.fromDOMRectList( context2, createRange( node2, subOffset_1 + offset2, subSegment.length ).getClientRects() ) ) ) subOffset_1 += subSegment.length }) } else { textBounds.push( new TextBounds(text2, Bounds.fromDOMRectList(context2, clientRects)) ) } } else { var replacementNode = node2.splitText(text2.length) textBounds.push( new TextBounds(text2, getWrapperBounds(context2, node2)) ) node2 = replacementNode } } else if (!FEATURES.SUPPORT_RANGE_BOUNDS) { node2 = node2.splitText(text2.length) } offset2 += text2.length }) return textBounds } var getWrapperBounds = function (context2, node2) { var ownerDocument = node2.ownerDocument if (ownerDocument) { var wrapper = ownerDocument.createElement('html2canvaswrapper') wrapper.appendChild(node2.cloneNode(true)) var parentNode2 = node2.parentNode if (parentNode2) { parentNode2.replaceChild(wrapper, node2) var bounds = parseBounds(context2, wrapper) if (wrapper.firstChild) { parentNode2.replaceChild(wrapper.firstChild, wrapper) } return bounds } } return Bounds.EMPTY } var createRange = function (node2, offset2, length2) { var ownerDocument = node2.ownerDocument if (!ownerDocument) { throw new Error('Node has no owner document') } var range3 = ownerDocument.createRange() range3.setStart(node2, offset2) range3.setEnd(node2, offset2 + length2) return range3 } var segmentGraphemes = function (value2) { if (FEATURES.SUPPORT_NATIVE_TEXT_SEGMENTATION) { var segmenter = new Intl.Segmenter(void 0, { granularity: 'grapheme' }) return Array.from(segmenter.segment(value2)).map(function (segment) { return segment.segment }) } return splitGraphemes(value2) } var segmentWords = function (value2, styles) { if (FEATURES.SUPPORT_NATIVE_TEXT_SEGMENTATION) { var segmenter = new Intl.Segmenter(void 0, { granularity: 'word', }) return Array.from(segmenter.segment(value2)).map(function (segment) { return segment.segment }) } return breakWords(value2, styles) } var breakText = function (value2, styles) { return styles.letterSpacing !== 0 ? segmentGraphemes(value2) : segmentWords(value2, styles) } var wordSeparators = [32, 160, 4961, 65792, 65793, 4153, 4241] var breakWords = function (str, styles) { var breaker = LineBreaker(str, { lineBreak: styles.lineBreak, wordBreak: styles.overflowWrap === 'break-word' ? 'break-word' : styles.wordBreak, }) var words = [] var bk var _loop_1 = function () { if (bk.value) { var value2 = bk.value.slice() var codePoints = toCodePoints$1(value2) var word_1 = '' codePoints.forEach(function (codePoint) { if (wordSeparators.indexOf(codePoint) === -1) { word_1 += fromCodePoint$1(codePoint) } else { if (word_1.length) { words.push(word_1) } words.push(fromCodePoint$1(codePoint)) word_1 = '' } }) if (word_1.length) { words.push(word_1) } } } while (!(bk = breaker.next()).done) { _loop_1() } return words } var TextContainer = (function () { function TextContainer2(context2, node2, styles) { this.text = transform$2(node2.data, styles.textTransform) this.textBounds = parseTextBounds(context2, this.text, styles, node2) } return TextContainer2 })() var transform$2 = function (text2, transform3) { switch (transform3) { case 1: return text2.toLowerCase() case 3: return text2.replace(CAPITALIZE, capitalize$1) case 2: return text2.toUpperCase() default: return text2 } } var CAPITALIZE = /(^|\s|:|-|\(|\))([a-z])/g var capitalize$1 = function (m2, p1, p2) { if (m2.length > 0) { return p1 + p2.toUpperCase() } return m2 } var ImageElementContainer = (function (_super) { __extends$3(ImageElementContainer2, _super) function ImageElementContainer2(context2, img) { var _this = _super.call(this, context2, img) || this _this.src = img.currentSrc || img.src _this.intrinsicWidth = img.naturalWidth _this.intrinsicHeight = img.naturalHeight _this.context.cache.addImage(_this.src) return _this } return ImageElementContainer2 })(ElementContainer) var CanvasElementContainer = (function (_super) { __extends$3(CanvasElementContainer2, _super) function CanvasElementContainer2(context2, canvas) { var _this = _super.call(this, context2, canvas) || this _this.canvas = canvas _this.intrinsicWidth = canvas.width _this.intrinsicHeight = canvas.height return _this } return CanvasElementContainer2 })(ElementContainer) var SVGElementContainer = (function (_super) { __extends$3(SVGElementContainer2, _super) function SVGElementContainer2(context2, img) { var _this = _super.call(this, context2, img) || this var s2 = new XMLSerializer() var bounds = parseBounds(context2, img) img.setAttribute('width', bounds.width + 'px') img.setAttribute('height', bounds.height + 'px') _this.svg = 'data:image/svg+xml,' + encodeURIComponent(s2.serializeToString(img)) _this.intrinsicWidth = img.width.baseVal.value _this.intrinsicHeight = img.height.baseVal.value _this.context.cache.addImage(_this.svg) return _this } return SVGElementContainer2 })(ElementContainer) var LIElementContainer = (function (_super) { __extends$3(LIElementContainer2, _super) function LIElementContainer2(context2, element) { var _this = _super.call(this, context2, element) || this _this.value = element.value return _this } return LIElementContainer2 })(ElementContainer) var OLElementContainer = (function (_super) { __extends$3(OLElementContainer2, _super) function OLElementContainer2(context2, element) { var _this = _super.call(this, context2, element) || this _this.start = element.start _this.reversed = typeof element.reversed === 'boolean' && element.reversed === true return _this } return OLElementContainer2 })(ElementContainer) var CHECKBOX_BORDER_RADIUS = [ { type: 15, flags: 0, unit: 'px', number: 3, }, ] var RADIO_BORDER_RADIUS = [ { type: 16, flags: 0, number: 50, }, ] var reformatInputBounds = function (bounds) { if (bounds.width > bounds.height) { return new Bounds( bounds.left + (bounds.width - bounds.height) / 2, bounds.top, bounds.height, bounds.height ) } else if (bounds.width < bounds.height) { return new Bounds( bounds.left, bounds.top + (bounds.height - bounds.width) / 2, bounds.width, bounds.width ) } return bounds } var getInputValue = function (node2) { var value2 = node2.type === PASSWORD ? new Array(node2.value.length + 1).join('\u2022') : node2.value return value2.length === 0 ? node2.placeholder || '' : value2 } var CHECKBOX = 'checkbox' var RADIO = 'radio' var PASSWORD = 'password' var INPUT_COLOR = 707406591 var InputElementContainer = (function (_super) { __extends$3(InputElementContainer2, _super) function InputElementContainer2(context2, input) { var _this = _super.call(this, context2, input) || this _this.type = input.type.toLowerCase() _this.checked = input.checked _this.value = getInputValue(input) if (_this.type === CHECKBOX || _this.type === RADIO) { _this.styles.backgroundColor = 3739148031 _this.styles.borderTopColor = _this.styles.borderRightColor = _this.styles.borderBottomColor = _this.styles.borderLeftColor = 2779096575 _this.styles.borderTopWidth = _this.styles.borderRightWidth = _this.styles.borderBottomWidth = _this.styles.borderLeftWidth = 1 _this.styles.borderTopStyle = _this.styles.borderRightStyle = _this.styles.borderBottomStyle = _this.styles.borderLeftStyle = 1 _this.styles.backgroundClip = [0] _this.styles.backgroundOrigin = [0] _this.bounds = reformatInputBounds(_this.bounds) } switch (_this.type) { case CHECKBOX: _this.styles.borderTopRightRadius = _this.styles.borderTopLeftRadius = _this.styles.borderBottomRightRadius = _this.styles.borderBottomLeftRadius = CHECKBOX_BORDER_RADIUS break case RADIO: _this.styles.borderTopRightRadius = _this.styles.borderTopLeftRadius = _this.styles.borderBottomRightRadius = _this.styles.borderBottomLeftRadius = RADIO_BORDER_RADIUS break } return _this } return InputElementContainer2 })(ElementContainer) var SelectElementContainer = (function (_super) { __extends$3(SelectElementContainer2, _super) function SelectElementContainer2(context2, element) { var _this = _super.call(this, context2, element) || this var option2 = element.options[element.selectedIndex || 0] _this.value = option2 ? option2.text || '' : '' return _this } return SelectElementContainer2 })(ElementContainer) var TextareaElementContainer = (function (_super) { __extends$3(TextareaElementContainer2, _super) function TextareaElementContainer2(context2, element) { var _this = _super.call(this, context2, element) || this _this.value = element.value return _this } return TextareaElementContainer2 })(ElementContainer) var IFrameElementContainer = (function (_super) { __extends$3(IFrameElementContainer2, _super) function IFrameElementContainer2(context2, iframe) { var _this = _super.call(this, context2, iframe) || this _this.src = iframe.src _this.width = parseInt(iframe.width, 10) || 0 _this.height = parseInt(iframe.height, 10) || 0 _this.backgroundColor = _this.styles.backgroundColor try { if ( iframe.contentWindow && iframe.contentWindow.document && iframe.contentWindow.document.documentElement ) { _this.tree = parseTree( context2, iframe.contentWindow.document.documentElement ) var documentBackgroundColor = iframe.contentWindow.document .documentElement ? parseColor( context2, getComputedStyle(iframe.contentWindow.document.documentElement) .backgroundColor ) : COLORS.TRANSPARENT var bodyBackgroundColor = iframe.contentWindow.document.body ? parseColor( context2, getComputedStyle(iframe.contentWindow.document.body) .backgroundColor ) : COLORS.TRANSPARENT _this.backgroundColor = isTransparent(documentBackgroundColor) ? isTransparent(bodyBackgroundColor) ? _this.styles.backgroundColor : bodyBackgroundColor : documentBackgroundColor } } catch (e2) {} return _this } return IFrameElementContainer2 })(ElementContainer) var LIST_OWNERS = ['OL', 'UL', 'MENU'] var parseNodeTree = function (context2, node2, parent2, root2) { for ( var childNode = node2.firstChild, nextNode = void 0; childNode; childNode = nextNode ) { nextNode = childNode.nextSibling if (isTextNode(childNode) && childNode.data.trim().length > 0) { parent2.textNodes.push( new TextContainer(context2, childNode, parent2.styles) ) } else if (isElementNode(childNode)) { if (isSlotElement$1(childNode) && childNode.assignedNodes) { childNode.assignedNodes().forEach(function (childNode2) { return parseNodeTree(context2, childNode2, parent2, root2) }) } else { var container = createContainer(context2, childNode) if (container.styles.isVisible()) { if (createsRealStackingContext(childNode, container, root2)) { container.flags |= 4 } else if (createsStackingContext(container.styles)) { container.flags |= 2 } if (LIST_OWNERS.indexOf(childNode.tagName) !== -1) { container.flags |= 8 } parent2.elements.push(container) childNode.slot if (childNode.shadowRoot) { parseNodeTree(context2, childNode.shadowRoot, container, root2) } else if ( !isTextareaElement(childNode) && !isSVGElement(childNode) && !isSelectElement(childNode) ) { parseNodeTree(context2, childNode, container, root2) } } } } } } var createContainer = function (context2, element) { if (isImageElement(element)) { return new ImageElementContainer(context2, element) } if (isCanvasElement(element)) { return new CanvasElementContainer(context2, element) } if (isSVGElement(element)) { return new SVGElementContainer(context2, element) } if (isLIElement(element)) { return new LIElementContainer(context2, element) } if (isOLElement(element)) { return new OLElementContainer(context2, element) } if (isInputElement(element)) { return new InputElementContainer(context2, element) } if (isSelectElement(element)) { return new SelectElementContainer(context2, element) } if (isTextareaElement(element)) { return new TextareaElementContainer(context2, element) } if (isIFrameElement(element)) { return new IFrameElementContainer(context2, element) } return new ElementContainer(context2, element) } var parseTree = function (context2, element) { var container = createContainer(context2, element) container.flags |= 4 parseNodeTree(context2, element, container, container) return container } var createsRealStackingContext = function (node2, container, root2) { return ( container.styles.isPositionedWithZIndex() || container.styles.opacity < 1 || container.styles.isTransformed() || (isBodyElement(node2) && root2.styles.isTransparent()) ) } var createsStackingContext = function (styles) { return styles.isPositioned() || styles.isFloating() } var isTextNode = function (node2) { return node2.nodeType === Node.TEXT_NODE } var isElementNode = function (node2) { return node2.nodeType === Node.ELEMENT_NODE } var isHTMLElementNode = function (node2) { return ( isElementNode(node2) && typeof node2.style !== 'undefined' && !isSVGElementNode(node2) ) } var isSVGElementNode = function (element) { return typeof element.className === 'object' } var isLIElement = function (node2) { return node2.tagName === 'LI' } var isOLElement = function (node2) { return node2.tagName === 'OL' } var isInputElement = function (node2) { return node2.tagName === 'INPUT' } var isHTMLElement = function (node2) { return node2.tagName === 'HTML' } var isSVGElement = function (node2) { return node2.tagName === 'svg' } var isBodyElement = function (node2) { return node2.tagName === 'BODY' } var isCanvasElement = function (node2) { return node2.tagName === 'CANVAS' } var isVideoElement = function (node2) { return node2.tagName === 'VIDEO' } var isImageElement = function (node2) { return node2.tagName === 'IMG' } var isIFrameElement = function (node2) { return node2.tagName === 'IFRAME' } var isStyleElement = function (node2) { return node2.tagName === 'STYLE' } var isScriptElement = function (node2) { return node2.tagName === 'SCRIPT' } var isTextareaElement = function (node2) { return node2.tagName === 'TEXTAREA' } var isSelectElement = function (node2) { return node2.tagName === 'SELECT' } var isSlotElement$1 = function (node2) { return node2.tagName === 'SLOT' } var isCustomElement = function (node2) { return node2.tagName.indexOf('-') > 0 } var CounterState = (function () { function CounterState2() { this.counters = {} } CounterState2.prototype.getCounterValue = function (name2) { var counter2 = this.counters[name2] if (counter2 && counter2.length) { return counter2[counter2.length - 1] } return 1 } CounterState2.prototype.getCounterValues = function (name2) { var counter2 = this.counters[name2] return counter2 ? counter2 : [] } CounterState2.prototype.pop = function (counters) { var _this = this counters.forEach(function (counter2) { return _this.counters[counter2].pop() }) } CounterState2.prototype.parse = function (style2) { var _this = this var counterIncrement2 = style2.counterIncrement var counterReset2 = style2.counterReset var canReset = true if (counterIncrement2 !== null) { counterIncrement2.forEach(function (entry) { var counter2 = _this.counters[entry.counter] if (counter2 && entry.increment !== 0) { canReset = false if (!counter2.length) { counter2.push(1) } counter2[Math.max(0, counter2.length - 1)] += entry.increment } }) } var counterNames = [] if (canReset) { counterReset2.forEach(function (entry) { var counter2 = _this.counters[entry.counter] counterNames.push(entry.counter) if (!counter2) { counter2 = _this.counters[entry.counter] = [] } counter2.push(entry.reset) }) } return counterNames } return CounterState2 })() var ROMAN_UPPER = { integers: [1e3, 900, 500, 400, 100, 90, 50, 40, 10, 9, 5, 4, 1], values: [ 'M', 'CM', 'D', 'CD', 'C', 'XC', 'L', 'XL', 'X', 'IX', 'V', 'IV', 'I', ], } var ARMENIAN = { integers: [ 9e3, 8e3, 7e3, 6e3, 5e3, 4e3, 3e3, 2e3, 1e3, 900, 800, 700, 600, 500, 400, 300, 200, 100, 90, 80, 70, 60, 50, 40, 30, 20, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, ], values: [ '\u0554', '\u0553', '\u0552', '\u0551', '\u0550', '\u054F', '\u054E', '\u054D', '\u054C', '\u054B', '\u054A', '\u0549', '\u0548', '\u0547', '\u0546', '\u0545', '\u0544', '\u0543', '\u0542', '\u0541', '\u0540', '\u053F', '\u053E', '\u053D', '\u053C', '\u053B', '\u053A', '\u0539', '\u0538', '\u0537', '\u0536', '\u0535', '\u0534', '\u0533', '\u0532', '\u0531', ], } var HEBREW = { integers: [ 1e4, 9e3, 8e3, 7e3, 6e3, 5e3, 4e3, 3e3, 2e3, 1e3, 400, 300, 200, 100, 90, 80, 70, 60, 50, 40, 30, 20, 19, 18, 17, 16, 15, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, ], values: [ '\u05D9\u05F3', '\u05D8\u05F3', '\u05D7\u05F3', '\u05D6\u05F3', '\u05D5\u05F3', '\u05D4\u05F3', '\u05D3\u05F3', '\u05D2\u05F3', '\u05D1\u05F3', '\u05D0\u05F3', '\u05EA', '\u05E9', '\u05E8', '\u05E7', '\u05E6', '\u05E4', '\u05E2', '\u05E1', '\u05E0', '\u05DE', '\u05DC', '\u05DB', '\u05D9\u05D8', '\u05D9\u05D7', '\u05D9\u05D6', '\u05D8\u05D6', '\u05D8\u05D5', '\u05D9', '\u05D8', '\u05D7', '\u05D6', '\u05D5', '\u05D4', '\u05D3', '\u05D2', '\u05D1', '\u05D0', ], } var GEORGIAN = { integers: [ 1e4, 9e3, 8e3, 7e3, 6e3, 5e3, 4e3, 3e3, 2e3, 1e3, 900, 800, 700, 600, 500, 400, 300, 200, 100, 90, 80, 70, 60, 50, 40, 30, 20, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, ], values: [ '\u10F5', '\u10F0', '\u10EF', '\u10F4', '\u10EE', '\u10ED', '\u10EC', '\u10EB', '\u10EA', '\u10E9', '\u10E8', '\u10E7', '\u10E6', '\u10E5', '\u10E4', '\u10F3', '\u10E2', '\u10E1', '\u10E0', '\u10DF', '\u10DE', '\u10DD', '\u10F2', '\u10DC', '\u10DB', '\u10DA', '\u10D9', '\u10D8', '\u10D7', '\u10F1', '\u10D6', '\u10D5', '\u10D4', '\u10D3', '\u10D2', '\u10D1', '\u10D0', ], } var createAdditiveCounter = function ( value2, min3, max3, symbols, fallback, suffix2 ) { if (value2 < min3 || value2 > max3) { return createCounterText(value2, fallback, suffix2.length > 0) } return ( symbols.integers.reduce(function (string3, integer4, index2) { while (value2 >= integer4) { value2 -= integer4 string3 += symbols.values[index2] } return string3 }, '') + suffix2 ) } var createCounterStyleWithSymbolResolver = function ( value2, codePointRangeLength, isNumeric2, resolver ) { var string3 = '' do { if (!isNumeric2) { value2-- } string3 = resolver(value2) + string3 value2 /= codePointRangeLength } while (value2 * codePointRangeLength >= codePointRangeLength) return string3 } var createCounterStyleFromRange = function ( value2, codePointRangeStart, codePointRangeEnd, isNumeric2, suffix2 ) { var codePointRangeLength = codePointRangeEnd - codePointRangeStart + 1 return ( (value2 < 0 ? '-' : '') + (createCounterStyleWithSymbolResolver( Math.abs(value2), codePointRangeLength, isNumeric2, function (codePoint) { return fromCodePoint$1( Math.floor(codePoint % codePointRangeLength) + codePointRangeStart ) } ) + suffix2) ) } var createCounterStyleFromSymbols = function (value2, symbols, suffix2) { if (suffix2 === void 0) { suffix2 = '. ' } var codePointRangeLength = symbols.length return ( createCounterStyleWithSymbolResolver( Math.abs(value2), codePointRangeLength, false, function (codePoint) { return symbols[Math.floor(codePoint % codePointRangeLength)] } ) + suffix2 ) } var CJK_ZEROS = 1 << 0 var CJK_TEN_COEFFICIENTS = 1 << 1 var CJK_TEN_HIGH_COEFFICIENTS = 1 << 2 var CJK_HUNDRED_COEFFICIENTS = 1 << 3 var createCJKCounter = function ( value2, numbers, multipliers, negativeSign, suffix2, flags ) { if (value2 < -9999 || value2 > 9999) { return createCounterText(value2, 4, suffix2.length > 0) } var tmp = Math.abs(value2) var string3 = suffix2 if (tmp === 0) { return numbers[0] + string3 } for (var digit = 0; tmp > 0 && digit <= 4; digit++) { var coefficient = tmp % 10 if (coefficient === 0 && contains(flags, CJK_ZEROS) && string3 !== '') { string3 = numbers[coefficient] + string3 } else if ( coefficient > 1 || (coefficient === 1 && digit === 0) || (coefficient === 1 && digit === 1 && contains(flags, CJK_TEN_COEFFICIENTS)) || (coefficient === 1 && digit === 1 && contains(flags, CJK_TEN_HIGH_COEFFICIENTS) && value2 > 100) || (coefficient === 1 && digit > 1 && contains(flags, CJK_HUNDRED_COEFFICIENTS)) ) { string3 = numbers[coefficient] + (digit > 0 ? multipliers[digit - 1] : '') + string3 } else if (coefficient === 1 && digit > 0) { string3 = multipliers[digit - 1] + string3 } tmp = Math.floor(tmp / 10) } return (value2 < 0 ? negativeSign : '') + string3 } var CHINESE_INFORMAL_MULTIPLIERS = '\u5341\u767E\u5343\u842C' var CHINESE_FORMAL_MULTIPLIERS = '\u62FE\u4F70\u4EDF\u842C' var JAPANESE_NEGATIVE = '\u30DE\u30A4\u30CA\u30B9' var KOREAN_NEGATIVE = '\uB9C8\uC774\uB108\uC2A4' var createCounterText = function (value2, type4, appendSuffix) { var defaultSuffix = appendSuffix ? '. ' : '' var cjkSuffix = appendSuffix ? '\u3001' : '' var koreanSuffix = appendSuffix ? ', ' : '' var spaceSuffix = appendSuffix ? ' ' : '' switch (type4) { case 0: return '\u2022' + spaceSuffix case 1: return '\u25E6' + spaceSuffix case 2: return '\u25FE' + spaceSuffix case 5: var string3 = createCounterStyleFromRange( value2, 48, 57, true, defaultSuffix ) return string3.length < 4 ? '0' + string3 : string3 case 4: return createCounterStyleFromSymbols( value2, '\u3007\u4E00\u4E8C\u4E09\u56DB\u4E94\u516D\u4E03\u516B\u4E5D', cjkSuffix ) case 6: return createAdditiveCounter( value2, 1, 3999, ROMAN_UPPER, 3, defaultSuffix ).toLowerCase() case 7: return createAdditiveCounter( value2, 1, 3999, ROMAN_UPPER, 3, defaultSuffix ) case 8: return createCounterStyleFromRange(value2, 945, 969, false, defaultSuffix) case 9: return createCounterStyleFromRange(value2, 97, 122, false, defaultSuffix) case 10: return createCounterStyleFromRange(value2, 65, 90, false, defaultSuffix) case 11: return createCounterStyleFromRange( value2, 1632, 1641, true, defaultSuffix ) case 12: case 49: return createAdditiveCounter(value2, 1, 9999, ARMENIAN, 3, defaultSuffix) case 35: return createAdditiveCounter( value2, 1, 9999, ARMENIAN, 3, defaultSuffix ).toLowerCase() case 13: return createCounterStyleFromRange( value2, 2534, 2543, true, defaultSuffix ) case 14: case 30: return createCounterStyleFromRange( value2, 6112, 6121, true, defaultSuffix ) case 15: return createCounterStyleFromSymbols( value2, '\u5B50\u4E11\u5BC5\u536F\u8FB0\u5DF3\u5348\u672A\u7533\u9149\u620C\u4EA5', cjkSuffix ) case 16: return createCounterStyleFromSymbols( value2, '\u7532\u4E59\u4E19\u4E01\u620A\u5DF1\u5E9A\u8F9B\u58EC\u7678', cjkSuffix ) case 17: case 48: return createCJKCounter( value2, '\u96F6\u4E00\u4E8C\u4E09\u56DB\u4E94\u516D\u4E03\u516B\u4E5D', CHINESE_INFORMAL_MULTIPLIERS, '\u8CA0', cjkSuffix, CJK_TEN_COEFFICIENTS | CJK_TEN_HIGH_COEFFICIENTS | CJK_HUNDRED_COEFFICIENTS ) case 47: return createCJKCounter( value2, '\u96F6\u58F9\u8CB3\u53C3\u8086\u4F0D\u9678\u67D2\u634C\u7396', CHINESE_FORMAL_MULTIPLIERS, '\u8CA0', cjkSuffix, CJK_ZEROS | CJK_TEN_COEFFICIENTS | CJK_TEN_HIGH_COEFFICIENTS | CJK_HUNDRED_COEFFICIENTS ) case 42: return createCJKCounter( value2, '\u96F6\u4E00\u4E8C\u4E09\u56DB\u4E94\u516D\u4E03\u516B\u4E5D', CHINESE_INFORMAL_MULTIPLIERS, '\u8D1F', cjkSuffix, CJK_TEN_COEFFICIENTS | CJK_TEN_HIGH_COEFFICIENTS | CJK_HUNDRED_COEFFICIENTS ) case 41: return createCJKCounter( value2, '\u96F6\u58F9\u8D30\u53C1\u8086\u4F0D\u9646\u67D2\u634C\u7396', CHINESE_FORMAL_MULTIPLIERS, '\u8D1F', cjkSuffix, CJK_ZEROS | CJK_TEN_COEFFICIENTS | CJK_TEN_HIGH_COEFFICIENTS | CJK_HUNDRED_COEFFICIENTS ) case 26: return createCJKCounter( value2, '\u3007\u4E00\u4E8C\u4E09\u56DB\u4E94\u516D\u4E03\u516B\u4E5D', '\u5341\u767E\u5343\u4E07', JAPANESE_NEGATIVE, cjkSuffix, 0 ) case 25: return createCJKCounter( value2, '\u96F6\u58F1\u5F10\u53C2\u56DB\u4F0D\u516D\u4E03\u516B\u4E5D', '\u62FE\u767E\u5343\u4E07', JAPANESE_NEGATIVE, cjkSuffix, CJK_ZEROS | CJK_TEN_COEFFICIENTS | CJK_TEN_HIGH_COEFFICIENTS ) case 31: return createCJKCounter( value2, '\uC601\uC77C\uC774\uC0BC\uC0AC\uC624\uC721\uCE60\uD314\uAD6C', '\uC2ED\uBC31\uCC9C\uB9CC', KOREAN_NEGATIVE, koreanSuffix, CJK_ZEROS | CJK_TEN_COEFFICIENTS | CJK_TEN_HIGH_COEFFICIENTS ) case 33: return createCJKCounter( value2, '\u96F6\u4E00\u4E8C\u4E09\u56DB\u4E94\u516D\u4E03\u516B\u4E5D', '\u5341\u767E\u5343\u842C', KOREAN_NEGATIVE, koreanSuffix, 0 ) case 32: return createCJKCounter( value2, '\u96F6\u58F9\u8CB3\u53C3\u56DB\u4E94\u516D\u4E03\u516B\u4E5D', '\u62FE\u767E\u5343', KOREAN_NEGATIVE, koreanSuffix, CJK_ZEROS | CJK_TEN_COEFFICIENTS | CJK_TEN_HIGH_COEFFICIENTS ) case 18: return createCounterStyleFromRange( value2, 2406, 2415, true, defaultSuffix ) case 20: return createAdditiveCounter(value2, 1, 19999, GEORGIAN, 3, defaultSuffix) case 21: return createCounterStyleFromRange( value2, 2790, 2799, true, defaultSuffix ) case 22: return createCounterStyleFromRange( value2, 2662, 2671, true, defaultSuffix ) case 22: return createAdditiveCounter(value2, 1, 10999, HEBREW, 3, defaultSuffix) case 23: return createCounterStyleFromSymbols( value2, '\u3042\u3044\u3046\u3048\u304A\u304B\u304D\u304F\u3051\u3053\u3055\u3057\u3059\u305B\u305D\u305F\u3061\u3064\u3066\u3068\u306A\u306B\u306C\u306D\u306E\u306F\u3072\u3075\u3078\u307B\u307E\u307F\u3080\u3081\u3082\u3084\u3086\u3088\u3089\u308A\u308B\u308C\u308D\u308F\u3090\u3091\u3092\u3093' ) case 24: return createCounterStyleFromSymbols( value2, '\u3044\u308D\u306F\u306B\u307B\u3078\u3068\u3061\u308A\u306C\u308B\u3092\u308F\u304B\u3088\u305F\u308C\u305D\u3064\u306D\u306A\u3089\u3080\u3046\u3090\u306E\u304A\u304F\u3084\u307E\u3051\u3075\u3053\u3048\u3066\u3042\u3055\u304D\u3086\u3081\u307F\u3057\u3091\u3072\u3082\u305B\u3059' ) case 27: return createCounterStyleFromRange( value2, 3302, 3311, true, defaultSuffix ) case 28: return createCounterStyleFromSymbols( value2, '\u30A2\u30A4\u30A6\u30A8\u30AA\u30AB\u30AD\u30AF\u30B1\u30B3\u30B5\u30B7\u30B9\u30BB\u30BD\u30BF\u30C1\u30C4\u30C6\u30C8\u30CA\u30CB\u30CC\u30CD\u30CE\u30CF\u30D2\u30D5\u30D8\u30DB\u30DE\u30DF\u30E0\u30E1\u30E2\u30E4\u30E6\u30E8\u30E9\u30EA\u30EB\u30EC\u30ED\u30EF\u30F0\u30F1\u30F2\u30F3', cjkSuffix ) case 29: return createCounterStyleFromSymbols( value2, '\u30A4\u30ED\u30CF\u30CB\u30DB\u30D8\u30C8\u30C1\u30EA\u30CC\u30EB\u30F2\u30EF\u30AB\u30E8\u30BF\u30EC\u30BD\u30C4\u30CD\u30CA\u30E9\u30E0\u30A6\u30F0\u30CE\u30AA\u30AF\u30E4\u30DE\u30B1\u30D5\u30B3\u30A8\u30C6\u30A2\u30B5\u30AD\u30E6\u30E1\u30DF\u30B7\u30F1\u30D2\u30E2\u30BB\u30B9', cjkSuffix ) case 34: return createCounterStyleFromRange( value2, 3792, 3801, true, defaultSuffix ) case 37: return createCounterStyleFromRange( value2, 6160, 6169, true, defaultSuffix ) case 38: return createCounterStyleFromRange( value2, 4160, 4169, true, defaultSuffix ) case 39: return createCounterStyleFromRange( value2, 2918, 2927, true, defaultSuffix ) case 40: return createCounterStyleFromRange( value2, 1776, 1785, true, defaultSuffix ) case 43: return createCounterStyleFromRange( value2, 3046, 3055, true, defaultSuffix ) case 44: return createCounterStyleFromRange( value2, 3174, 3183, true, defaultSuffix ) case 45: return createCounterStyleFromRange( value2, 3664, 3673, true, defaultSuffix ) case 46: return createCounterStyleFromRange( value2, 3872, 3881, true, defaultSuffix ) case 3: default: return createCounterStyleFromRange(value2, 48, 57, true, defaultSuffix) } } var IGNORE_ATTRIBUTE = 'data-html2canvas-ignore' var DocumentCloner = (function () { function DocumentCloner2(context2, element, options2) { this.context = context2 this.options = options2 this.scrolledElements = [] this.referenceElement = element this.counters = new CounterState() this.quoteDepth = 0 if (!element.ownerDocument) { throw new Error('Cloned element does not have an owner document') } this.documentElement = this.cloneNode( element.ownerDocument.documentElement, false ) } DocumentCloner2.prototype.toIFrame = function (ownerDocument, windowSize) { var _this = this var iframe = createIFrameContainer(ownerDocument, windowSize) if (!iframe.contentWindow) { return Promise.reject('Unable to find iframe window') } var scrollX = ownerDocument.defaultView.pageXOffset var scrollY = ownerDocument.defaultView.pageYOffset var cloneWindow = iframe.contentWindow var documentClone = cloneWindow.document var iframeLoad = iframeLoader(iframe).then(function () { return __awaiter(_this, void 0, void 0, function () { var onclone, referenceElement return __generator(this, function (_a2) { switch (_a2.label) { case 0: this.scrolledElements.forEach(restoreNodeScroll) if (cloneWindow) { cloneWindow.scrollTo(windowSize.left, windowSize.top) if ( /(iPad|iPhone|iPod)/g.test(navigator.userAgent) && (cloneWindow.scrollY !== windowSize.top || cloneWindow.scrollX !== windowSize.left) ) { this.context.logger.warn( 'Unable to restore scroll position for cloned document' ) this.context.windowBounds = this.context.windowBounds.add( cloneWindow.scrollX - windowSize.left, cloneWindow.scrollY - windowSize.top, 0, 0 ) } } onclone = this.options.onclone referenceElement = this.clonedReferenceElement if (typeof referenceElement === 'undefined') { return [ 2, Promise.reject( 'Error finding the ' + this.referenceElement.nodeName + ' in the cloned document' ), ] } if (!(documentClone.fonts && documentClone.fonts.ready)) return [3, 2] return [4, documentClone.fonts.ready] case 1: _a2.sent() _a2.label = 2 case 2: if (!/(AppleWebKit)/g.test(navigator.userAgent)) return [3, 4] return [4, imagesReady(documentClone)] case 3: _a2.sent() _a2.label = 4 case 4: if (typeof onclone === 'function') { return [ 2, Promise.resolve() .then(function () { return onclone(documentClone, referenceElement) }) .then(function () { return iframe }), ] } return [2, iframe] } }) }) }) documentClone.open() documentClone.write(serializeDoctype(document.doctype) + '') restoreOwnerScroll(this.referenceElement.ownerDocument, scrollX, scrollY) documentClone.replaceChild( documentClone.adoptNode(this.documentElement), documentClone.documentElement ) documentClone.close() return iframeLoad } DocumentCloner2.prototype.createElementClone = function (node2) { if (isDebugging(node2, 2)) { debugger } if (isCanvasElement(node2)) { return this.createCanvasClone(node2) } if (isVideoElement(node2)) { return this.createVideoClone(node2) } if (isStyleElement(node2)) { return this.createStyleClone(node2) } var clone2 = node2.cloneNode(false) if (isImageElement(clone2)) { if ( isImageElement(node2) && node2.currentSrc && node2.currentSrc !== node2.src ) { clone2.src = node2.currentSrc clone2.srcset = '' } if (clone2.loading === 'lazy') { clone2.loading = 'eager' } } if (isCustomElement(clone2)) { return this.createCustomElementClone(clone2) } return clone2 } DocumentCloner2.prototype.createCustomElementClone = function (node2) { var clone2 = document.createElement('html2canvascustomelement') copyCSSStyles(node2.style, clone2) return clone2 } DocumentCloner2.prototype.createStyleClone = function (node2) { try { var sheet = node2.sheet if (sheet && sheet.cssRules) { var css2 = [].slice .call(sheet.cssRules, 0) .reduce(function (css3, rule2) { if (rule2 && typeof rule2.cssText === 'string') { return css3 + rule2.cssText } return css3 }, '') var style2 = node2.cloneNode(false) style2.textContent = css2 return style2 } } catch (e2) { this.context.logger.error('Unable to access cssRules property', e2) if (e2.name !== 'SecurityError') { throw e2 } } return node2.cloneNode(false) } DocumentCloner2.prototype.createCanvasClone = function (canvas) { var _a2 if (this.options.inlineImages && canvas.ownerDocument) { var img = canvas.ownerDocument.createElement('img') try { img.src = canvas.toDataURL() return img } catch (e2) { this.context.logger.info( 'Unable to inline canvas contents, canvas is tainted', canvas ) } } var clonedCanvas = canvas.cloneNode(false) try { clonedCanvas.width = canvas.width clonedCanvas.height = canvas.height var ctx = canvas.getContext('2d') var clonedCtx = clonedCanvas.getContext('2d') if (clonedCtx) { if (!this.options.allowTaint && ctx) { clonedCtx.putImageData( ctx.getImageData(0, 0, canvas.width, canvas.height), 0, 0 ) } else { var gl = (_a2 = canvas.getContext('webgl2')) !== null && _a2 !== void 0 ? _a2 : canvas.getContext('webgl') if (gl) { var attribs = gl.getContextAttributes() if ( (attribs === null || attribs === void 0 ? void 0 : attribs.preserveDrawingBuffer) === false ) { this.context.logger.warn( 'Unable to clone WebGL context as it has preserveDrawingBuffer=false', canvas ) } } clonedCtx.drawImage(canvas, 0, 0) } } return clonedCanvas } catch (e2) { this.context.logger.info( 'Unable to clone canvas as it is tainted', canvas ) } return clonedCanvas } DocumentCloner2.prototype.createVideoClone = function (video) { var canvas = video.ownerDocument.createElement('canvas') canvas.width = video.offsetWidth canvas.height = video.offsetHeight var ctx = canvas.getContext('2d') try { if (ctx) { ctx.drawImage(video, 0, 0, canvas.width, canvas.height) if (!this.options.allowTaint) { ctx.getImageData(0, 0, canvas.width, canvas.height) } } return canvas } catch (e2) { this.context.logger.info('Unable to clone video as it is tainted', video) } var blankCanvas = video.ownerDocument.createElement('canvas') blankCanvas.width = video.offsetWidth blankCanvas.height = video.offsetHeight return blankCanvas } DocumentCloner2.prototype.appendChildNode = function ( clone2, child, copyStyles ) { if ( !isElementNode(child) || (!isScriptElement(child) && !child.hasAttribute(IGNORE_ATTRIBUTE) && (typeof this.options.ignoreElements !== 'function' || !this.options.ignoreElements(child))) ) { if ( !this.options.copyStyles || !isElementNode(child) || !isStyleElement(child) ) { clone2.appendChild(this.cloneNode(child, copyStyles)) } } } DocumentCloner2.prototype.cloneChildNodes = function ( node2, clone2, copyStyles ) { var _this = this for ( var child = node2.shadowRoot ? node2.shadowRoot.firstChild : node2.firstChild; child; child = child.nextSibling ) { if ( isElementNode(child) && isSlotElement$1(child) && typeof child.assignedNodes === 'function' ) { var assignedNodes = child.assignedNodes() if (assignedNodes.length) { assignedNodes.forEach(function (assignedNode) { return _this.appendChildNode(clone2, assignedNode, copyStyles) }) } } else { this.appendChildNode(clone2, child, copyStyles) } } } DocumentCloner2.prototype.cloneNode = function (node2, copyStyles) { if (isTextNode(node2)) { return document.createTextNode(node2.data) } if (!node2.ownerDocument) { return node2.cloneNode(false) } var window2 = node2.ownerDocument.defaultView if ( window2 && isElementNode(node2) && (isHTMLElementNode(node2) || isSVGElementNode(node2)) ) { var clone2 = this.createElementClone(node2) clone2.style.transitionProperty = 'none' var style2 = window2.getComputedStyle(node2) var styleBefore = window2.getComputedStyle(node2, ':before') var styleAfter = window2.getComputedStyle(node2, ':after') if (this.referenceElement === node2 && isHTMLElementNode(clone2)) { this.clonedReferenceElement = clone2 } if (isBodyElement(clone2)) { createPseudoHideStyles(clone2) } var counters = this.counters.parse( new CSSParsedCounterDeclaration(this.context, style2) ) var before2 = this.resolvePseudoContent( node2, clone2, styleBefore, PseudoElementType.BEFORE ) if (isCustomElement(node2)) { copyStyles = true } if (!isVideoElement(node2)) { this.cloneChildNodes(node2, clone2, copyStyles) } if (before2) { clone2.insertBefore(before2, clone2.firstChild) } var after2 = this.resolvePseudoContent( node2, clone2, styleAfter, PseudoElementType.AFTER ) if (after2) { clone2.appendChild(after2) } this.counters.pop(counters) if ( (style2 && (this.options.copyStyles || isSVGElementNode(node2)) && !isIFrameElement(node2)) || copyStyles ) { copyCSSStyles(style2, clone2) } if (node2.scrollTop !== 0 || node2.scrollLeft !== 0) { this.scrolledElements.push([clone2, node2.scrollLeft, node2.scrollTop]) } if ( (isTextareaElement(node2) || isSelectElement(node2)) && (isTextareaElement(clone2) || isSelectElement(clone2)) ) { clone2.value = node2.value } return clone2 } return node2.cloneNode(false) } DocumentCloner2.prototype.resolvePseudoContent = function ( node2, clone2, style2, pseudoElt ) { var _this = this if (!style2) { return } var value2 = style2.content var document2 = clone2.ownerDocument if ( !document2 || !value2 || value2 === 'none' || value2 === '-moz-alt-content' || style2.display === 'none' ) { return } this.counters.parse(new CSSParsedCounterDeclaration(this.context, style2)) var declaration = new CSSParsedPseudoDeclaration(this.context, style2) var anonymousReplacedElement = document2.createElement( 'html2canvaspseudoelement' ) copyCSSStyles(style2, anonymousReplacedElement) declaration.content.forEach(function (token) { if (token.type === 0) { anonymousReplacedElement.appendChild( document2.createTextNode(token.value) ) } else if (token.type === 22) { var img = document2.createElement('img') img.src = token.value img.style.opacity = '1' anonymousReplacedElement.appendChild(img) } else if (token.type === 18) { if (token.name === 'attr') { var attr = token.values.filter(isIdentToken) if (attr.length) { anonymousReplacedElement.appendChild( document2.createTextNode(node2.getAttribute(attr[0].value) || '') ) } } else if (token.name === 'counter') { var _a2 = token.values.filter(nonFunctionArgSeparator), counter2 = _a2[0], counterStyle = _a2[1] if (counter2 && isIdentToken(counter2)) { var counterState = _this.counters.getCounterValue(counter2.value) var counterType = counterStyle && isIdentToken(counterStyle) ? listStyleType.parse(_this.context, counterStyle.value) : 3 anonymousReplacedElement.appendChild( document2.createTextNode( createCounterText(counterState, counterType, false) ) ) } } else if (token.name === 'counters') { var _b2 = token.values.filter(nonFunctionArgSeparator), counter2 = _b2[0], delim = _b2[1], counterStyle = _b2[2] if (counter2 && isIdentToken(counter2)) { var counterStates = _this.counters.getCounterValues(counter2.value) var counterType_1 = counterStyle && isIdentToken(counterStyle) ? listStyleType.parse(_this.context, counterStyle.value) : 3 var separator = delim && delim.type === 0 ? delim.value : '' var text2 = counterStates .map(function (value3) { return createCounterText(value3, counterType_1, false) }) .join(separator) anonymousReplacedElement.appendChild( document2.createTextNode(text2) ) } } else; } else if (token.type === 20) { switch (token.value) { case 'open-quote': anonymousReplacedElement.appendChild( document2.createTextNode( getQuote(declaration.quotes, _this.quoteDepth++, true) ) ) break case 'close-quote': anonymousReplacedElement.appendChild( document2.createTextNode( getQuote(declaration.quotes, --_this.quoteDepth, false) ) ) break default: anonymousReplacedElement.appendChild( document2.createTextNode(token.value) ) } } }) anonymousReplacedElement.className = PSEUDO_HIDE_ELEMENT_CLASS_BEFORE + ' ' + PSEUDO_HIDE_ELEMENT_CLASS_AFTER var newClassName = pseudoElt === PseudoElementType.BEFORE ? ' ' + PSEUDO_HIDE_ELEMENT_CLASS_BEFORE : ' ' + PSEUDO_HIDE_ELEMENT_CLASS_AFTER if (isSVGElementNode(clone2)) { clone2.className.baseValue += newClassName } else { clone2.className += newClassName } return anonymousReplacedElement } DocumentCloner2.destroy = function (container) { if (container.parentNode) { container.parentNode.removeChild(container) return true } return false } return DocumentCloner2 })() var PseudoElementType ;(function (PseudoElementType2) { PseudoElementType2[(PseudoElementType2['BEFORE'] = 0)] = 'BEFORE' PseudoElementType2[(PseudoElementType2['AFTER'] = 1)] = 'AFTER' })(PseudoElementType || (PseudoElementType = {})) var createIFrameContainer = function (ownerDocument, bounds) { var cloneIframeContainer = ownerDocument.createElement('iframe') cloneIframeContainer.className = 'html2canvas-container' cloneIframeContainer.style.visibility = 'hidden' cloneIframeContainer.style.position = 'fixed' cloneIframeContainer.style.left = '-10000px' cloneIframeContainer.style.top = '0px' cloneIframeContainer.style.border = '0' cloneIframeContainer.width = bounds.width.toString() cloneIframeContainer.height = bounds.height.toString() cloneIframeContainer.scrolling = 'no' cloneIframeContainer.setAttribute(IGNORE_ATTRIBUTE, 'true') ownerDocument.body.appendChild(cloneIframeContainer) return cloneIframeContainer } var imageReady = function (img) { return new Promise(function (resolve2) { if (img.complete) { resolve2() return } if (!img.src) { resolve2() return } img.onload = resolve2 img.onerror = resolve2 }) } var imagesReady = function (document2) { return Promise.all([].slice.call(document2.images, 0).map(imageReady)) } var iframeLoader = function (iframe) { return new Promise(function (resolve2, reject2) { var cloneWindow = iframe.contentWindow if (!cloneWindow) { return reject2('No window assigned for iframe') } var documentClone = cloneWindow.document cloneWindow.onload = iframe.onload = function () { cloneWindow.onload = iframe.onload = null var interval = setInterval(function () { if ( documentClone.body.childNodes.length > 0 && documentClone.readyState === 'complete' ) { clearInterval(interval) resolve2(iframe) } }, 50) } }) } var ignoredStyleProperties = ['all', 'd', 'content'] var copyCSSStyles = function (style2, target2) { for (var i2 = style2.length - 1; i2 >= 0; i2--) { var property2 = style2.item(i2) if (ignoredStyleProperties.indexOf(property2) === -1) { target2.style.setProperty(property2, style2.getPropertyValue(property2)) } } return target2 } var serializeDoctype = function (doctype) { var str = '' if (doctype) { str += '' } return str } var restoreOwnerScroll = function (ownerDocument, x2, y2) { if ( ownerDocument && ownerDocument.defaultView && (x2 !== ownerDocument.defaultView.pageXOffset || y2 !== ownerDocument.defaultView.pageYOffset) ) { ownerDocument.defaultView.scrollTo(x2, y2) } } var restoreNodeScroll = function (_a2) { var element = _a2[0], x2 = _a2[1], y2 = _a2[2] element.scrollLeft = x2 element.scrollTop = y2 } var PSEUDO_BEFORE = ':before' var PSEUDO_AFTER = ':after' var PSEUDO_HIDE_ELEMENT_CLASS_BEFORE = '___html2canvas___pseudoelement_before' var PSEUDO_HIDE_ELEMENT_CLASS_AFTER = '___html2canvas___pseudoelement_after' var PSEUDO_HIDE_ELEMENT_STYLE = '{\n content: "" !important;\n display: none !important;\n}' var createPseudoHideStyles = function (body) { createStyles( body, '.' + PSEUDO_HIDE_ELEMENT_CLASS_BEFORE + PSEUDO_BEFORE + PSEUDO_HIDE_ELEMENT_STYLE + '\n .' + PSEUDO_HIDE_ELEMENT_CLASS_AFTER + PSEUDO_AFTER + PSEUDO_HIDE_ELEMENT_STYLE ) } var createStyles = function (body, styles) { var document2 = body.ownerDocument if (document2) { var style2 = document2.createElement('style') style2.textContent = styles body.appendChild(style2) } } var CacheStorage = (function () { function CacheStorage2() {} CacheStorage2.getOrigin = function (url2) { var link2 = CacheStorage2._link if (!link2) { return 'about:blank' } link2.href = url2 link2.href = link2.href return link2.protocol + link2.hostname + link2.port } CacheStorage2.isSameOrigin = function (src) { return CacheStorage2.getOrigin(src) === CacheStorage2._origin } CacheStorage2.setContext = function (window2) { CacheStorage2._link = window2.document.createElement('a') CacheStorage2._origin = CacheStorage2.getOrigin(window2.location.href) } CacheStorage2._origin = 'about:blank' return CacheStorage2 })() var Cache = (function () { function Cache2(context2, _options) { this.context = context2 this._options = _options this._cache = {} } Cache2.prototype.addImage = function (src) { var result = Promise.resolve() if (this.has(src)) { return result } if (isBlobImage(src) || isRenderable(src)) { ;(this._cache[src] = this.loadImage(src)).catch(function () {}) return result } return result } Cache2.prototype.match = function (src) { return this._cache[src] } Cache2.prototype.loadImage = function (key2) { return __awaiter(this, void 0, void 0, function () { var isSameOrigin, useCORS, useProxy, src var _this = this return __generator(this, function (_a2) { switch (_a2.label) { case 0: isSameOrigin = CacheStorage.isSameOrigin(key2) useCORS = !isInlineImage(key2) && this._options.useCORS === true && FEATURES.SUPPORT_CORS_IMAGES && !isSameOrigin useProxy = !isInlineImage(key2) && !isSameOrigin && !isBlobImage(key2) && typeof this._options.proxy === 'string' && FEATURES.SUPPORT_CORS_XHR && !useCORS if ( !isSameOrigin && this._options.allowTaint === false && !isInlineImage(key2) && !isBlobImage(key2) && !useProxy && !useCORS ) { return [2] } src = key2 if (!useProxy) return [3, 2] return [4, this.proxy(src)] case 1: src = _a2.sent() _a2.label = 2 case 2: this.context.logger.debug('Added image ' + key2.substring(0, 256)) return [ 4, new Promise(function (resolve2, reject2) { var img = new Image() img.onload = function () { return resolve2(img) } img.onerror = reject2 if (isInlineBase64Image(src) || useCORS) { img.crossOrigin = 'anonymous' } img.src = src if (img.complete === true) { setTimeout(function () { return resolve2(img) }, 500) } if (_this._options.imageTimeout > 0) { setTimeout(function () { return reject2( 'Timed out (' + _this._options.imageTimeout + 'ms) loading image' ) }, _this._options.imageTimeout) } }), ] case 3: return [2, _a2.sent()] } }) }) } Cache2.prototype.has = function (key2) { return typeof this._cache[key2] !== 'undefined' } Cache2.prototype.keys = function () { return Promise.resolve(Object.keys(this._cache)) } Cache2.prototype.proxy = function (src) { var _this = this var proxy = this._options.proxy if (!proxy) { throw new Error('No proxy defined') } var key2 = src.substring(0, 256) return new Promise(function (resolve2, reject2) { var responseType = FEATURES.SUPPORT_RESPONSE_TYPE ? 'blob' : 'text' var xhr2 = new XMLHttpRequest() xhr2.onload = function () { if (xhr2.status === 200) { if (responseType === 'text') { resolve2(xhr2.response) } else { var reader_1 = new FileReader() reader_1.addEventListener( 'load', function () { return resolve2(reader_1.result) }, false ) reader_1.addEventListener( 'error', function (e2) { return reject2(e2) }, false ) reader_1.readAsDataURL(xhr2.response) } } else { reject2( 'Failed to proxy resource ' + key2 + ' with status code ' + xhr2.status ) } } xhr2.onerror = reject2 var queryString = proxy.indexOf('?') > -1 ? '&' : '?' xhr2.open( 'GET', '' + proxy + queryString + 'url=' + encodeURIComponent(src) + '&responseType=' + responseType ) if (responseType !== 'text' && xhr2 instanceof XMLHttpRequest) { xhr2.responseType = responseType } if (_this._options.imageTimeout) { var timeout_1 = _this._options.imageTimeout xhr2.timeout = timeout_1 xhr2.ontimeout = function () { return reject2('Timed out (' + timeout_1 + 'ms) proxying ' + key2) } } xhr2.send() }) } return Cache2 })() var INLINE_SVG = /^data:image\/svg\+xml/i var INLINE_BASE64 = /^data:image\/.*;base64,/i var INLINE_IMG = /^data:image\/.*/i var isRenderable = function (src) { return FEATURES.SUPPORT_SVG_DRAWING || !isSVG(src) } var isInlineImage = function (src) { return INLINE_IMG.test(src) } var isInlineBase64Image = function (src) { return INLINE_BASE64.test(src) } var isBlobImage = function (src) { return src.substr(0, 4) === 'blob' } var isSVG = function (src) { return src.substr(-3).toLowerCase() === 'svg' || INLINE_SVG.test(src) } var Vector = (function () { function Vector2(x2, y2) { this.type = 0 this.x = x2 this.y = y2 } Vector2.prototype.add = function (deltaX, deltaY) { return new Vector2(this.x + deltaX, this.y + deltaY) } return Vector2 })() var lerp$2 = function (a2, b2, t3) { return new Vector(a2.x + (b2.x - a2.x) * t3, a2.y + (b2.y - a2.y) * t3) } var BezierCurve$2 = (function () { function BezierCurve2(start2, startControl, endControl, end2) { this.type = 1 this.start = start2 this.startControl = startControl this.endControl = endControl this.end = end2 } BezierCurve2.prototype.subdivide = function (t3, firstHalf) { var ab = lerp$2(this.start, this.startControl, t3) var bc = lerp$2(this.startControl, this.endControl, t3) var cd = lerp$2(this.endControl, this.end, t3) var abbc = lerp$2(ab, bc, t3) var bccd = lerp$2(bc, cd, t3) var dest = lerp$2(abbc, bccd, t3) return firstHalf ? new BezierCurve2(this.start, ab, abbc, dest) : new BezierCurve2(dest, bccd, cd, this.end) } BezierCurve2.prototype.add = function (deltaX, deltaY) { return new BezierCurve2( this.start.add(deltaX, deltaY), this.startControl.add(deltaX, deltaY), this.endControl.add(deltaX, deltaY), this.end.add(deltaX, deltaY) ) } BezierCurve2.prototype.reverse = function () { return new BezierCurve2( this.end, this.endControl, this.startControl, this.start ) } return BezierCurve2 })() var isBezierCurve = function (path) { return path.type === 1 } var BoundCurves = (function () { function BoundCurves2(element) { var styles = element.styles var bounds = element.bounds var _a2 = getAbsoluteValueForTuple( styles.borderTopLeftRadius, bounds.width, bounds.height ), tlh = _a2[0], tlv = _a2[1] var _b2 = getAbsoluteValueForTuple( styles.borderTopRightRadius, bounds.width, bounds.height ), trh = _b2[0], trv = _b2[1] var _c2 = getAbsoluteValueForTuple( styles.borderBottomRightRadius, bounds.width, bounds.height ), brh = _c2[0], brv = _c2[1] var _d = getAbsoluteValueForTuple( styles.borderBottomLeftRadius, bounds.width, bounds.height ), blh = _d[0], blv = _d[1] var factors = [] factors.push((tlh + trh) / bounds.width) factors.push((blh + brh) / bounds.width) factors.push((tlv + blv) / bounds.height) factors.push((trv + brv) / bounds.height) var maxFactor = Math.max.apply(Math, factors) if (maxFactor > 1) { tlh /= maxFactor tlv /= maxFactor trh /= maxFactor trv /= maxFactor brh /= maxFactor brv /= maxFactor blh /= maxFactor blv /= maxFactor } var topWidth = bounds.width - trh var rightHeight = bounds.height - brv var bottomWidth = bounds.width - brh var leftHeight = bounds.height - blv var borderTopWidth2 = styles.borderTopWidth var borderRightWidth2 = styles.borderRightWidth var borderBottomWidth2 = styles.borderBottomWidth var borderLeftWidth2 = styles.borderLeftWidth var paddingTop2 = getAbsoluteValue(styles.paddingTop, element.bounds.width) var paddingRight2 = getAbsoluteValue( styles.paddingRight, element.bounds.width ) var paddingBottom2 = getAbsoluteValue( styles.paddingBottom, element.bounds.width ) var paddingLeft2 = getAbsoluteValue( styles.paddingLeft, element.bounds.width ) this.topLeftBorderDoubleOuterBox = tlh > 0 || tlv > 0 ? getCurvePoints( bounds.left + borderLeftWidth2 / 3, bounds.top + borderTopWidth2 / 3, tlh - borderLeftWidth2 / 3, tlv - borderTopWidth2 / 3, CORNER.TOP_LEFT ) : new Vector( bounds.left + borderLeftWidth2 / 3, bounds.top + borderTopWidth2 / 3 ) this.topRightBorderDoubleOuterBox = tlh > 0 || tlv > 0 ? getCurvePoints( bounds.left + topWidth, bounds.top + borderTopWidth2 / 3, trh - borderRightWidth2 / 3, trv - borderTopWidth2 / 3, CORNER.TOP_RIGHT ) : new Vector( bounds.left + bounds.width - borderRightWidth2 / 3, bounds.top + borderTopWidth2 / 3 ) this.bottomRightBorderDoubleOuterBox = brh > 0 || brv > 0 ? getCurvePoints( bounds.left + bottomWidth, bounds.top + rightHeight, brh - borderRightWidth2 / 3, brv - borderBottomWidth2 / 3, CORNER.BOTTOM_RIGHT ) : new Vector( bounds.left + bounds.width - borderRightWidth2 / 3, bounds.top + bounds.height - borderBottomWidth2 / 3 ) this.bottomLeftBorderDoubleOuterBox = blh > 0 || blv > 0 ? getCurvePoints( bounds.left + borderLeftWidth2 / 3, bounds.top + leftHeight, blh - borderLeftWidth2 / 3, blv - borderBottomWidth2 / 3, CORNER.BOTTOM_LEFT ) : new Vector( bounds.left + borderLeftWidth2 / 3, bounds.top + bounds.height - borderBottomWidth2 / 3 ) this.topLeftBorderDoubleInnerBox = tlh > 0 || tlv > 0 ? getCurvePoints( bounds.left + (borderLeftWidth2 * 2) / 3, bounds.top + (borderTopWidth2 * 2) / 3, tlh - (borderLeftWidth2 * 2) / 3, tlv - (borderTopWidth2 * 2) / 3, CORNER.TOP_LEFT ) : new Vector( bounds.left + (borderLeftWidth2 * 2) / 3, bounds.top + (borderTopWidth2 * 2) / 3 ) this.topRightBorderDoubleInnerBox = tlh > 0 || tlv > 0 ? getCurvePoints( bounds.left + topWidth, bounds.top + (borderTopWidth2 * 2) / 3, trh - (borderRightWidth2 * 2) / 3, trv - (borderTopWidth2 * 2) / 3, CORNER.TOP_RIGHT ) : new Vector( bounds.left + bounds.width - (borderRightWidth2 * 2) / 3, bounds.top + (borderTopWidth2 * 2) / 3 ) this.bottomRightBorderDoubleInnerBox = brh > 0 || brv > 0 ? getCurvePoints( bounds.left + bottomWidth, bounds.top + rightHeight, brh - (borderRightWidth2 * 2) / 3, brv - (borderBottomWidth2 * 2) / 3, CORNER.BOTTOM_RIGHT ) : new Vector( bounds.left + bounds.width - (borderRightWidth2 * 2) / 3, bounds.top + bounds.height - (borderBottomWidth2 * 2) / 3 ) this.bottomLeftBorderDoubleInnerBox = blh > 0 || blv > 0 ? getCurvePoints( bounds.left + (borderLeftWidth2 * 2) / 3, bounds.top + leftHeight, blh - (borderLeftWidth2 * 2) / 3, blv - (borderBottomWidth2 * 2) / 3, CORNER.BOTTOM_LEFT ) : new Vector( bounds.left + (borderLeftWidth2 * 2) / 3, bounds.top + bounds.height - (borderBottomWidth2 * 2) / 3 ) this.topLeftBorderStroke = tlh > 0 || tlv > 0 ? getCurvePoints( bounds.left + borderLeftWidth2 / 2, bounds.top + borderTopWidth2 / 2, tlh - borderLeftWidth2 / 2, tlv - borderTopWidth2 / 2, CORNER.TOP_LEFT ) : new Vector( bounds.left + borderLeftWidth2 / 2, bounds.top + borderTopWidth2 / 2 ) this.topRightBorderStroke = tlh > 0 || tlv > 0 ? getCurvePoints( bounds.left + topWidth, bounds.top + borderTopWidth2 / 2, trh - borderRightWidth2 / 2, trv - borderTopWidth2 / 2, CORNER.TOP_RIGHT ) : new Vector( bounds.left + bounds.width - borderRightWidth2 / 2, bounds.top + borderTopWidth2 / 2 ) this.bottomRightBorderStroke = brh > 0 || brv > 0 ? getCurvePoints( bounds.left + bottomWidth, bounds.top + rightHeight, brh - borderRightWidth2 / 2, brv - borderBottomWidth2 / 2, CORNER.BOTTOM_RIGHT ) : new Vector( bounds.left + bounds.width - borderRightWidth2 / 2, bounds.top + bounds.height - borderBottomWidth2 / 2 ) this.bottomLeftBorderStroke = blh > 0 || blv > 0 ? getCurvePoints( bounds.left + borderLeftWidth2 / 2, bounds.top + leftHeight, blh - borderLeftWidth2 / 2, blv - borderBottomWidth2 / 2, CORNER.BOTTOM_LEFT ) : new Vector( bounds.left + borderLeftWidth2 / 2, bounds.top + bounds.height - borderBottomWidth2 / 2 ) this.topLeftBorderBox = tlh > 0 || tlv > 0 ? getCurvePoints(bounds.left, bounds.top, tlh, tlv, CORNER.TOP_LEFT) : new Vector(bounds.left, bounds.top) this.topRightBorderBox = trh > 0 || trv > 0 ? getCurvePoints( bounds.left + topWidth, bounds.top, trh, trv, CORNER.TOP_RIGHT ) : new Vector(bounds.left + bounds.width, bounds.top) this.bottomRightBorderBox = brh > 0 || brv > 0 ? getCurvePoints( bounds.left + bottomWidth, bounds.top + rightHeight, brh, brv, CORNER.BOTTOM_RIGHT ) : new Vector(bounds.left + bounds.width, bounds.top + bounds.height) this.bottomLeftBorderBox = blh > 0 || blv > 0 ? getCurvePoints( bounds.left, bounds.top + leftHeight, blh, blv, CORNER.BOTTOM_LEFT ) : new Vector(bounds.left, bounds.top + bounds.height) this.topLeftPaddingBox = tlh > 0 || tlv > 0 ? getCurvePoints( bounds.left + borderLeftWidth2, bounds.top + borderTopWidth2, Math.max(0, tlh - borderLeftWidth2), Math.max(0, tlv - borderTopWidth2), CORNER.TOP_LEFT ) : new Vector( bounds.left + borderLeftWidth2, bounds.top + borderTopWidth2 ) this.topRightPaddingBox = trh > 0 || trv > 0 ? getCurvePoints( bounds.left + Math.min(topWidth, bounds.width - borderRightWidth2), bounds.top + borderTopWidth2, topWidth > bounds.width + borderRightWidth2 ? 0 : Math.max(0, trh - borderRightWidth2), Math.max(0, trv - borderTopWidth2), CORNER.TOP_RIGHT ) : new Vector( bounds.left + bounds.width - borderRightWidth2, bounds.top + borderTopWidth2 ) this.bottomRightPaddingBox = brh > 0 || brv > 0 ? getCurvePoints( bounds.left + Math.min(bottomWidth, bounds.width - borderLeftWidth2), bounds.top + Math.min(rightHeight, bounds.height - borderBottomWidth2), Math.max(0, brh - borderRightWidth2), Math.max(0, brv - borderBottomWidth2), CORNER.BOTTOM_RIGHT ) : new Vector( bounds.left + bounds.width - borderRightWidth2, bounds.top + bounds.height - borderBottomWidth2 ) this.bottomLeftPaddingBox = blh > 0 || blv > 0 ? getCurvePoints( bounds.left + borderLeftWidth2, bounds.top + Math.min(leftHeight, bounds.height - borderBottomWidth2), Math.max(0, blh - borderLeftWidth2), Math.max(0, blv - borderBottomWidth2), CORNER.BOTTOM_LEFT ) : new Vector( bounds.left + borderLeftWidth2, bounds.top + bounds.height - borderBottomWidth2 ) this.topLeftContentBox = tlh > 0 || tlv > 0 ? getCurvePoints( bounds.left + borderLeftWidth2 + paddingLeft2, bounds.top + borderTopWidth2 + paddingTop2, Math.max(0, tlh - (borderLeftWidth2 + paddingLeft2)), Math.max(0, tlv - (borderTopWidth2 + paddingTop2)), CORNER.TOP_LEFT ) : new Vector( bounds.left + borderLeftWidth2 + paddingLeft2, bounds.top + borderTopWidth2 + paddingTop2 ) this.topRightContentBox = trh > 0 || trv > 0 ? getCurvePoints( bounds.left + Math.min( topWidth, bounds.width + borderLeftWidth2 + paddingLeft2 ), bounds.top + borderTopWidth2 + paddingTop2, topWidth > bounds.width + borderLeftWidth2 + paddingLeft2 ? 0 : trh - borderLeftWidth2 + paddingLeft2, trv - (borderTopWidth2 + paddingTop2), CORNER.TOP_RIGHT ) : new Vector( bounds.left + bounds.width - (borderRightWidth2 + paddingRight2), bounds.top + borderTopWidth2 + paddingTop2 ) this.bottomRightContentBox = brh > 0 || brv > 0 ? getCurvePoints( bounds.left + Math.min( bottomWidth, bounds.width - (borderLeftWidth2 + paddingLeft2) ), bounds.top + Math.min( rightHeight, bounds.height + borderTopWidth2 + paddingTop2 ), Math.max(0, brh - (borderRightWidth2 + paddingRight2)), brv - (borderBottomWidth2 + paddingBottom2), CORNER.BOTTOM_RIGHT ) : new Vector( bounds.left + bounds.width - (borderRightWidth2 + paddingRight2), bounds.top + bounds.height - (borderBottomWidth2 + paddingBottom2) ) this.bottomLeftContentBox = blh > 0 || blv > 0 ? getCurvePoints( bounds.left + borderLeftWidth2 + paddingLeft2, bounds.top + leftHeight, Math.max(0, blh - (borderLeftWidth2 + paddingLeft2)), blv - (borderBottomWidth2 + paddingBottom2), CORNER.BOTTOM_LEFT ) : new Vector( bounds.left + borderLeftWidth2 + paddingLeft2, bounds.top + bounds.height - (borderBottomWidth2 + paddingBottom2) ) } return BoundCurves2 })() var CORNER ;(function (CORNER2) { CORNER2[(CORNER2['TOP_LEFT'] = 0)] = 'TOP_LEFT' CORNER2[(CORNER2['TOP_RIGHT'] = 1)] = 'TOP_RIGHT' CORNER2[(CORNER2['BOTTOM_RIGHT'] = 2)] = 'BOTTOM_RIGHT' CORNER2[(CORNER2['BOTTOM_LEFT'] = 3)] = 'BOTTOM_LEFT' })(CORNER || (CORNER = {})) var getCurvePoints = function (x2, y2, r1, r2, position2) { var kappa = 4 * ((Math.sqrt(2) - 1) / 3) var ox = r1 * kappa var oy = r2 * kappa var xm = x2 + r1 var ym = y2 + r2 switch (position2) { case CORNER.TOP_LEFT: return new BezierCurve$2( new Vector(x2, ym), new Vector(x2, ym - oy), new Vector(xm - ox, y2), new Vector(xm, y2) ) case CORNER.TOP_RIGHT: return new BezierCurve$2( new Vector(x2, y2), new Vector(x2 + ox, y2), new Vector(xm, ym - oy), new Vector(xm, ym) ) case CORNER.BOTTOM_RIGHT: return new BezierCurve$2( new Vector(xm, y2), new Vector(xm, y2 + oy), new Vector(x2 + ox, ym), new Vector(x2, ym) ) case CORNER.BOTTOM_LEFT: default: return new BezierCurve$2( new Vector(xm, ym), new Vector(xm - ox, ym), new Vector(x2, y2 + oy), new Vector(x2, y2) ) } } var calculateBorderBoxPath = function (curves) { return [ curves.topLeftBorderBox, curves.topRightBorderBox, curves.bottomRightBorderBox, curves.bottomLeftBorderBox, ] } var calculateContentBoxPath = function (curves) { return [ curves.topLeftContentBox, curves.topRightContentBox, curves.bottomRightContentBox, curves.bottomLeftContentBox, ] } var calculatePaddingBoxPath = function (curves) { return [ curves.topLeftPaddingBox, curves.topRightPaddingBox, curves.bottomRightPaddingBox, curves.bottomLeftPaddingBox, ] } var TransformEffect = (function () { function TransformEffect2(offsetX, offsetY, matrix2) { this.offsetX = offsetX this.offsetY = offsetY this.matrix = matrix2 this.type = 0 this.target = 2 | 4 } return TransformEffect2 })() var ClipEffect = (function () { function ClipEffect2(path, target2) { this.path = path this.target = target2 this.type = 1 } return ClipEffect2 })() var OpacityEffect = (function () { function OpacityEffect2(opacity2) { this.opacity = opacity2 this.type = 2 this.target = 2 | 4 } return OpacityEffect2 })() var isTransformEffect = function (effect2) { return effect2.type === 0 } var isClipEffect = function (effect2) { return effect2.type === 1 } var isOpacityEffect = function (effect2) { return effect2.type === 2 } var equalPath = function (a2, b2) { if (a2.length === b2.length) { return a2.some(function (v4, i2) { return v4 === b2[i2] }) } return false } var transformPath$1 = function (path, deltaX, deltaY, deltaW, deltaH) { return path.map(function (point, index2) { switch (index2) { case 0: return point.add(deltaX, deltaY) case 1: return point.add(deltaX + deltaW, deltaY) case 2: return point.add(deltaX + deltaW, deltaY + deltaH) case 3: return point.add(deltaX, deltaY + deltaH) } return point }) } var StackingContext = (function () { function StackingContext2(container) { this.element = container this.inlineLevel = [] this.nonInlineLevel = [] this.negativeZIndex = [] this.zeroOrAutoZIndexOrTransformedOrOpacity = [] this.positiveZIndex = [] this.nonPositionedFloats = [] this.nonPositionedInlineLevel = [] } return StackingContext2 })() var ElementPaint = (function () { function ElementPaint2(container, parent2) { this.container = container this.parent = parent2 this.effects = [] this.curves = new BoundCurves(this.container) if (this.container.styles.opacity < 1) { this.effects.push(new OpacityEffect(this.container.styles.opacity)) } if (this.container.styles.transform !== null) { var offsetX = this.container.bounds.left + this.container.styles.transformOrigin[0].number var offsetY = this.container.bounds.top + this.container.styles.transformOrigin[1].number var matrix2 = this.container.styles.transform this.effects.push(new TransformEffect(offsetX, offsetY, matrix2)) } if (this.container.styles.overflowX !== 0) { var borderBox = calculateBorderBoxPath(this.curves) var paddingBox2 = calculatePaddingBoxPath(this.curves) if (equalPath(borderBox, paddingBox2)) { this.effects.push(new ClipEffect(borderBox, 2 | 4)) } else { this.effects.push(new ClipEffect(borderBox, 2)) this.effects.push(new ClipEffect(paddingBox2, 4)) } } } ElementPaint2.prototype.getEffects = function (target2) { var inFlow = [2, 3].indexOf(this.container.styles.position) === -1 var parent2 = this.parent var effects = this.effects.slice(0) while (parent2) { var croplessEffects = parent2.effects.filter(function (effect2) { return !isClipEffect(effect2) }) if ( inFlow || parent2.container.styles.position !== 0 || !parent2.parent ) { effects.unshift.apply(effects, croplessEffects) inFlow = [2, 3].indexOf(parent2.container.styles.position) === -1 if (parent2.container.styles.overflowX !== 0) { var borderBox = calculateBorderBoxPath(parent2.curves) var paddingBox2 = calculatePaddingBoxPath(parent2.curves) if (!equalPath(borderBox, paddingBox2)) { effects.unshift(new ClipEffect(paddingBox2, 2 | 4)) } } } else { effects.unshift.apply(effects, croplessEffects) } parent2 = parent2.parent } return effects.filter(function (effect2) { return contains(effect2.target, target2) }) } return ElementPaint2 })() var parseStackTree = function ( parent2, stackingContext, realStackingContext, listItems ) { parent2.container.elements.forEach(function (child) { var treatAsRealStackingContext = contains(child.flags, 4) var createsStackingContext2 = contains(child.flags, 2) var paintContainer = new ElementPaint(child, parent2) if (contains(child.styles.display, 2048)) { listItems.push(paintContainer) } var listOwnerItems = contains(child.flags, 8) ? [] : listItems if (treatAsRealStackingContext || createsStackingContext2) { var parentStack = treatAsRealStackingContext || child.styles.isPositioned() ? realStackingContext : stackingContext var stack = new StackingContext(paintContainer) if ( child.styles.isPositioned() || child.styles.opacity < 1 || child.styles.isTransformed() ) { var order_1 = child.styles.zIndex.order if (order_1 < 0) { var index_1 = 0 parentStack.negativeZIndex.some(function (current2, i2) { if (order_1 > current2.element.container.styles.zIndex.order) { index_1 = i2 return false } else if (index_1 > 0) { return true } return false }) parentStack.negativeZIndex.splice(index_1, 0, stack) } else if (order_1 > 0) { var index_2 = 0 parentStack.positiveZIndex.some(function (current2, i2) { if (order_1 >= current2.element.container.styles.zIndex.order) { index_2 = i2 + 1 return false } else if (index_2 > 0) { return true } return false }) parentStack.positiveZIndex.splice(index_2, 0, stack) } else { parentStack.zeroOrAutoZIndexOrTransformedOrOpacity.push(stack) } } else { if (child.styles.isFloating()) { parentStack.nonPositionedFloats.push(stack) } else { parentStack.nonPositionedInlineLevel.push(stack) } } parseStackTree( paintContainer, stack, treatAsRealStackingContext ? stack : realStackingContext, listOwnerItems ) } else { if (child.styles.isInlineLevel()) { stackingContext.inlineLevel.push(paintContainer) } else { stackingContext.nonInlineLevel.push(paintContainer) } parseStackTree( paintContainer, stackingContext, realStackingContext, listOwnerItems ) } if (contains(child.flags, 8)) { processListItems(child, listOwnerItems) } }) } var processListItems = function (owner, elements2) { var numbering = owner instanceof OLElementContainer ? owner.start : 1 var reversed = owner instanceof OLElementContainer ? owner.reversed : false for (var i2 = 0; i2 < elements2.length; i2++) { var item2 = elements2[i2] if ( item2.container instanceof LIElementContainer && typeof item2.container.value === 'number' && item2.container.value !== 0 ) { numbering = item2.container.value } item2.listValue = createCounterText( numbering, item2.container.styles.listStyleType, true ) numbering += reversed ? -1 : 1 } } var parseStackingContexts = function (container) { var paintContainer = new ElementPaint(container, null) var root2 = new StackingContext(paintContainer) var listItems = [] parseStackTree(paintContainer, root2, root2, listItems) processListItems(paintContainer.container, listItems) return root2 } var parsePathForBorder = function (curves, borderSide) { switch (borderSide) { case 0: return createPathFromCurves( curves.topLeftBorderBox, curves.topLeftPaddingBox, curves.topRightBorderBox, curves.topRightPaddingBox ) case 1: return createPathFromCurves( curves.topRightBorderBox, curves.topRightPaddingBox, curves.bottomRightBorderBox, curves.bottomRightPaddingBox ) case 2: return createPathFromCurves( curves.bottomRightBorderBox, curves.bottomRightPaddingBox, curves.bottomLeftBorderBox, curves.bottomLeftPaddingBox ) case 3: default: return createPathFromCurves( curves.bottomLeftBorderBox, curves.bottomLeftPaddingBox, curves.topLeftBorderBox, curves.topLeftPaddingBox ) } } var parsePathForBorderDoubleOuter = function (curves, borderSide) { switch (borderSide) { case 0: return createPathFromCurves( curves.topLeftBorderBox, curves.topLeftBorderDoubleOuterBox, curves.topRightBorderBox, curves.topRightBorderDoubleOuterBox ) case 1: return createPathFromCurves( curves.topRightBorderBox, curves.topRightBorderDoubleOuterBox, curves.bottomRightBorderBox, curves.bottomRightBorderDoubleOuterBox ) case 2: return createPathFromCurves( curves.bottomRightBorderBox, curves.bottomRightBorderDoubleOuterBox, curves.bottomLeftBorderBox, curves.bottomLeftBorderDoubleOuterBox ) case 3: default: return createPathFromCurves( curves.bottomLeftBorderBox, curves.bottomLeftBorderDoubleOuterBox, curves.topLeftBorderBox, curves.topLeftBorderDoubleOuterBox ) } } var parsePathForBorderDoubleInner = function (curves, borderSide) { switch (borderSide) { case 0: return createPathFromCurves( curves.topLeftBorderDoubleInnerBox, curves.topLeftPaddingBox, curves.topRightBorderDoubleInnerBox, curves.topRightPaddingBox ) case 1: return createPathFromCurves( curves.topRightBorderDoubleInnerBox, curves.topRightPaddingBox, curves.bottomRightBorderDoubleInnerBox, curves.bottomRightPaddingBox ) case 2: return createPathFromCurves( curves.bottomRightBorderDoubleInnerBox, curves.bottomRightPaddingBox, curves.bottomLeftBorderDoubleInnerBox, curves.bottomLeftPaddingBox ) case 3: default: return createPathFromCurves( curves.bottomLeftBorderDoubleInnerBox, curves.bottomLeftPaddingBox, curves.topLeftBorderDoubleInnerBox, curves.topLeftPaddingBox ) } } var parsePathForBorderStroke = function (curves, borderSide) { switch (borderSide) { case 0: return createStrokePathFromCurves( curves.topLeftBorderStroke, curves.topRightBorderStroke ) case 1: return createStrokePathFromCurves( curves.topRightBorderStroke, curves.bottomRightBorderStroke ) case 2: return createStrokePathFromCurves( curves.bottomRightBorderStroke, curves.bottomLeftBorderStroke ) case 3: default: return createStrokePathFromCurves( curves.bottomLeftBorderStroke, curves.topLeftBorderStroke ) } } var createStrokePathFromCurves = function (outer1, outer2) { var path = [] if (isBezierCurve(outer1)) { path.push(outer1.subdivide(0.5, false)) } else { path.push(outer1) } if (isBezierCurve(outer2)) { path.push(outer2.subdivide(0.5, true)) } else { path.push(outer2) } return path } var createPathFromCurves = function (outer1, inner1, outer2, inner2) { var path = [] if (isBezierCurve(outer1)) { path.push(outer1.subdivide(0.5, false)) } else { path.push(outer1) } if (isBezierCurve(outer2)) { path.push(outer2.subdivide(0.5, true)) } else { path.push(outer2) } if (isBezierCurve(inner2)) { path.push(inner2.subdivide(0.5, true).reverse()) } else { path.push(inner2) } if (isBezierCurve(inner1)) { path.push(inner1.subdivide(0.5, false).reverse()) } else { path.push(inner1) } return path } var paddingBox = function (element) { var bounds = element.bounds var styles = element.styles return bounds.add( styles.borderLeftWidth, styles.borderTopWidth, -(styles.borderRightWidth + styles.borderLeftWidth), -(styles.borderTopWidth + styles.borderBottomWidth) ) } var contentBox = function (element) { var styles = element.styles var bounds = element.bounds var paddingLeft2 = getAbsoluteValue(styles.paddingLeft, bounds.width) var paddingRight2 = getAbsoluteValue(styles.paddingRight, bounds.width) var paddingTop2 = getAbsoluteValue(styles.paddingTop, bounds.width) var paddingBottom2 = getAbsoluteValue(styles.paddingBottom, bounds.width) return bounds.add( paddingLeft2 + styles.borderLeftWidth, paddingTop2 + styles.borderTopWidth, -( styles.borderRightWidth + styles.borderLeftWidth + paddingLeft2 + paddingRight2 ), -( styles.borderTopWidth + styles.borderBottomWidth + paddingTop2 + paddingBottom2 ) ) } var calculateBackgroundPositioningArea = function (backgroundOrigin2, element) { if (backgroundOrigin2 === 0) { return element.bounds } if (backgroundOrigin2 === 2) { return contentBox(element) } return paddingBox(element) } var calculateBackgroundPaintingArea = function (backgroundClip2, element) { if (backgroundClip2 === 0) { return element.bounds } if (backgroundClip2 === 2) { return contentBox(element) } return paddingBox(element) } var calculateBackgroundRendering = function (container, index2, intrinsicSize) { var backgroundPositioningArea = calculateBackgroundPositioningArea( getBackgroundValueForIndex(container.styles.backgroundOrigin, index2), container ) var backgroundPaintingArea = calculateBackgroundPaintingArea( getBackgroundValueForIndex(container.styles.backgroundClip, index2), container ) var backgroundImageSize = calculateBackgroundSize( getBackgroundValueForIndex(container.styles.backgroundSize, index2), intrinsicSize, backgroundPositioningArea ) var sizeWidth = backgroundImageSize[0], sizeHeight = backgroundImageSize[1] var position2 = getAbsoluteValueForTuple( getBackgroundValueForIndex(container.styles.backgroundPosition, index2), backgroundPositioningArea.width - sizeWidth, backgroundPositioningArea.height - sizeHeight ) var path = calculateBackgroundRepeatPath( getBackgroundValueForIndex(container.styles.backgroundRepeat, index2), position2, backgroundImageSize, backgroundPositioningArea, backgroundPaintingArea ) var offsetX = Math.round(backgroundPositioningArea.left + position2[0]) var offsetY = Math.round(backgroundPositioningArea.top + position2[1]) return [path, offsetX, offsetY, sizeWidth, sizeHeight] } var isAuto = function (token) { return isIdentToken(token) && token.value === BACKGROUND_SIZE.AUTO } var hasIntrinsicValue = function (value2) { return typeof value2 === 'number' } var calculateBackgroundSize = function (size, _a2, bounds) { var intrinsicWidth = _a2[0], intrinsicHeight = _a2[1], intrinsicProportion = _a2[2] var first2 = size[0], second = size[1] if (!first2) { return [0, 0] } if (isLengthPercentage(first2) && second && isLengthPercentage(second)) { return [ getAbsoluteValue(first2, bounds.width), getAbsoluteValue(second, bounds.height), ] } var hasIntrinsicProportion = hasIntrinsicValue(intrinsicProportion) if ( isIdentToken(first2) && (first2.value === BACKGROUND_SIZE.CONTAIN || first2.value === BACKGROUND_SIZE.COVER) ) { if (hasIntrinsicValue(intrinsicProportion)) { var targetRatio = bounds.width / bounds.height return targetRatio < intrinsicProportion !== (first2.value === BACKGROUND_SIZE.COVER) ? [bounds.width, bounds.width / intrinsicProportion] : [bounds.height * intrinsicProportion, bounds.height] } return [bounds.width, bounds.height] } var hasIntrinsicWidth = hasIntrinsicValue(intrinsicWidth) var hasIntrinsicHeight = hasIntrinsicValue(intrinsicHeight) var hasIntrinsicDimensions = hasIntrinsicWidth || hasIntrinsicHeight if (isAuto(first2) && (!second || isAuto(second))) { if (hasIntrinsicWidth && hasIntrinsicHeight) { return [intrinsicWidth, intrinsicHeight] } if (!hasIntrinsicProportion && !hasIntrinsicDimensions) { return [bounds.width, bounds.height] } if (hasIntrinsicDimensions && hasIntrinsicProportion) { var width_1 = hasIntrinsicWidth ? intrinsicWidth : intrinsicHeight * intrinsicProportion var height_1 = hasIntrinsicHeight ? intrinsicHeight : intrinsicWidth / intrinsicProportion return [width_1, height_1] } var width_2 = hasIntrinsicWidth ? intrinsicWidth : bounds.width var height_2 = hasIntrinsicHeight ? intrinsicHeight : bounds.height return [width_2, height_2] } if (hasIntrinsicProportion) { var width_3 = 0 var height_3 = 0 if (isLengthPercentage(first2)) { width_3 = getAbsoluteValue(first2, bounds.width) } else if (isLengthPercentage(second)) { height_3 = getAbsoluteValue(second, bounds.height) } if (isAuto(first2)) { width_3 = height_3 * intrinsicProportion } else if (!second || isAuto(second)) { height_3 = width_3 / intrinsicProportion } return [width_3, height_3] } var width = null var height = null if (isLengthPercentage(first2)) { width = getAbsoluteValue(first2, bounds.width) } else if (second && isLengthPercentage(second)) { height = getAbsoluteValue(second, bounds.height) } if (width !== null && (!second || isAuto(second))) { height = hasIntrinsicWidth && hasIntrinsicHeight ? (width / intrinsicWidth) * intrinsicHeight : bounds.height } if (height !== null && isAuto(first2)) { width = hasIntrinsicWidth && hasIntrinsicHeight ? (height / intrinsicHeight) * intrinsicWidth : bounds.width } if (width !== null && height !== null) { return [width, height] } throw new Error('Unable to calculate background-size for element') } var getBackgroundValueForIndex = function (values2, index2) { var value2 = values2[index2] if (typeof value2 === 'undefined') { return values2[0] } return value2 } var calculateBackgroundRepeatPath = function ( repeat2, _a2, _b2, backgroundPositioningArea, backgroundPaintingArea ) { var x2 = _a2[0], y2 = _a2[1] var width = _b2[0], height = _b2[1] switch (repeat2) { case 2: return [ new Vector( Math.round(backgroundPositioningArea.left), Math.round(backgroundPositioningArea.top + y2) ), new Vector( Math.round( backgroundPositioningArea.left + backgroundPositioningArea.width ), Math.round(backgroundPositioningArea.top + y2) ), new Vector( Math.round( backgroundPositioningArea.left + backgroundPositioningArea.width ), Math.round(height + backgroundPositioningArea.top + y2) ), new Vector( Math.round(backgroundPositioningArea.left), Math.round(height + backgroundPositioningArea.top + y2) ), ] case 3: return [ new Vector( Math.round(backgroundPositioningArea.left + x2), Math.round(backgroundPositioningArea.top) ), new Vector( Math.round(backgroundPositioningArea.left + x2 + width), Math.round(backgroundPositioningArea.top) ), new Vector( Math.round(backgroundPositioningArea.left + x2 + width), Math.round( backgroundPositioningArea.height + backgroundPositioningArea.top ) ), new Vector( Math.round(backgroundPositioningArea.left + x2), Math.round( backgroundPositioningArea.height + backgroundPositioningArea.top ) ), ] case 1: return [ new Vector( Math.round(backgroundPositioningArea.left + x2), Math.round(backgroundPositioningArea.top + y2) ), new Vector( Math.round(backgroundPositioningArea.left + x2 + width), Math.round(backgroundPositioningArea.top + y2) ), new Vector( Math.round(backgroundPositioningArea.left + x2 + width), Math.round(backgroundPositioningArea.top + y2 + height) ), new Vector( Math.round(backgroundPositioningArea.left + x2), Math.round(backgroundPositioningArea.top + y2 + height) ), ] default: return [ new Vector( Math.round(backgroundPaintingArea.left), Math.round(backgroundPaintingArea.top) ), new Vector( Math.round( backgroundPaintingArea.left + backgroundPaintingArea.width ), Math.round(backgroundPaintingArea.top) ), new Vector( Math.round( backgroundPaintingArea.left + backgroundPaintingArea.width ), Math.round(backgroundPaintingArea.height + backgroundPaintingArea.top) ), new Vector( Math.round(backgroundPaintingArea.left), Math.round(backgroundPaintingArea.height + backgroundPaintingArea.top) ), ] } } var SMALL_IMAGE = 'data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7' var SAMPLE_TEXT = 'Hidden Text' var FontMetrics = (function () { function FontMetrics2(document2) { this._data = {} this._document = document2 } FontMetrics2.prototype.parseMetrics = function (fontFamily2, fontSize2) { var container = this._document.createElement('div') var img = this._document.createElement('img') var span = this._document.createElement('span') var body = this._document.body container.style.visibility = 'hidden' container.style.fontFamily = fontFamily2 container.style.fontSize = fontSize2 container.style.margin = '0' container.style.padding = '0' container.style.whiteSpace = 'nowrap' body.appendChild(container) img.src = SMALL_IMAGE img.width = 1 img.height = 1 img.style.margin = '0' img.style.padding = '0' img.style.verticalAlign = 'baseline' span.style.fontFamily = fontFamily2 span.style.fontSize = fontSize2 span.style.margin = '0' span.style.padding = '0' span.appendChild(this._document.createTextNode(SAMPLE_TEXT)) container.appendChild(span) container.appendChild(img) var baseline = img.offsetTop - span.offsetTop + 2 container.removeChild(span) container.appendChild(this._document.createTextNode(SAMPLE_TEXT)) container.style.lineHeight = 'normal' img.style.verticalAlign = 'super' var middle = img.offsetTop - container.offsetTop + 2 body.removeChild(container) return { baseline, middle } } FontMetrics2.prototype.getMetrics = function (fontFamily2, fontSize2) { var key2 = fontFamily2 + ' ' + fontSize2 if (typeof this._data[key2] === 'undefined') { this._data[key2] = this.parseMetrics(fontFamily2, fontSize2) } return this._data[key2] } return FontMetrics2 })() var Renderer = (function () { function Renderer2(context2, options2) { this.context = context2 this.options = options2 } return Renderer2 })() var MASK_OFFSET = 1e4 var CanvasRenderer = (function (_super) { __extends$3(CanvasRenderer2, _super) function CanvasRenderer2(context2, options2) { var _this = _super.call(this, context2, options2) || this _this._activeEffects = [] _this.canvas = options2.canvas ? options2.canvas : document.createElement('canvas') _this.ctx = _this.canvas.getContext('2d') if (!options2.canvas) { _this.canvas.width = Math.floor(options2.width * options2.scale) _this.canvas.height = Math.floor(options2.height * options2.scale) _this.canvas.style.width = options2.width + 'px' _this.canvas.style.height = options2.height + 'px' } _this.fontMetrics = new FontMetrics(document) _this.ctx.scale(_this.options.scale, _this.options.scale) _this.ctx.translate(-options2.x, -options2.y) _this.ctx.textBaseline = 'bottom' _this._activeEffects = [] _this.context.logger.debug( 'Canvas renderer initialized (' + options2.width + 'x' + options2.height + ') with scale ' + options2.scale ) return _this } CanvasRenderer2.prototype.applyEffects = function (effects) { var _this = this while (this._activeEffects.length) { this.popEffect() } effects.forEach(function (effect2) { return _this.applyEffect(effect2) }) } CanvasRenderer2.prototype.applyEffect = function (effect2) { this.ctx.save() if (isOpacityEffect(effect2)) { this.ctx.globalAlpha = effect2.opacity } if (isTransformEffect(effect2)) { this.ctx.translate(effect2.offsetX, effect2.offsetY) this.ctx.transform( effect2.matrix[0], effect2.matrix[1], effect2.matrix[2], effect2.matrix[3], effect2.matrix[4], effect2.matrix[5] ) this.ctx.translate(-effect2.offsetX, -effect2.offsetY) } if (isClipEffect(effect2)) { this.path(effect2.path) this.ctx.clip() } this._activeEffects.push(effect2) } CanvasRenderer2.prototype.popEffect = function () { this._activeEffects.pop() this.ctx.restore() } CanvasRenderer2.prototype.renderStack = function (stack) { return __awaiter(this, void 0, void 0, function () { var styles return __generator(this, function (_a2) { switch (_a2.label) { case 0: styles = stack.element.container.styles if (!styles.isVisible()) return [3, 2] return [4, this.renderStackContent(stack)] case 1: _a2.sent() _a2.label = 2 case 2: return [2] } }) }) } CanvasRenderer2.prototype.renderNode = function (paint) { return __awaiter(this, void 0, void 0, function () { return __generator(this, function (_a2) { switch (_a2.label) { case 0: if (contains(paint.container.flags, 16)) { debugger } if (!paint.container.styles.isVisible()) return [3, 3] return [4, this.renderNodeBackgroundAndBorders(paint)] case 1: _a2.sent() return [4, this.renderNodeContent(paint)] case 2: _a2.sent() _a2.label = 3 case 3: return [2] } }) }) } CanvasRenderer2.prototype.renderTextWithLetterSpacing = function ( text2, letterSpacing2, baseline ) { var _this = this if (letterSpacing2 === 0) { this.ctx.fillText( text2.text, text2.bounds.left, text2.bounds.top + baseline ) } else { var letters = segmentGraphemes(text2.text) letters.reduce(function (left2, letter) { _this.ctx.fillText(letter, left2, text2.bounds.top + baseline) return left2 + _this.ctx.measureText(letter).width }, text2.bounds.left) } } CanvasRenderer2.prototype.createFontStyle = function (styles) { var fontVariant2 = styles.fontVariant .filter(function (variant) { return variant === 'normal' || variant === 'small-caps' }) .join('') var fontFamily2 = fixIOSSystemFonts(styles.fontFamily).join(', ') var fontSize2 = isDimensionToken(styles.fontSize) ? '' + styles.fontSize.number + styles.fontSize.unit : styles.fontSize.number + 'px' return [ [ styles.fontStyle, fontVariant2, styles.fontWeight, fontSize2, fontFamily2, ].join(' '), fontFamily2, fontSize2, ] } CanvasRenderer2.prototype.renderTextNode = function (text2, styles) { return __awaiter(this, void 0, void 0, function () { var _a2, font2, fontFamily2, fontSize2, _b2, baseline, middle, paintOrder2 var _this = this return __generator(this, function (_c2) { ;(_a2 = this.createFontStyle(styles)), (font2 = _a2[0]), (fontFamily2 = _a2[1]), (fontSize2 = _a2[2]) this.ctx.font = font2 this.ctx.direction = styles.direction === 1 ? 'rtl' : 'ltr' this.ctx.textAlign = 'left' this.ctx.textBaseline = 'alphabetic' ;(_b2 = this.fontMetrics.getMetrics(fontFamily2, fontSize2)), (baseline = _b2.baseline), (middle = _b2.middle) paintOrder2 = styles.paintOrder text2.textBounds.forEach(function (text3) { paintOrder2.forEach(function (paintOrderLayer) { switch (paintOrderLayer) { case 0: _this.ctx.fillStyle = asString(styles.color) _this.renderTextWithLetterSpacing( text3, styles.letterSpacing, baseline ) var textShadows = styles.textShadow if (textShadows.length && text3.text.trim().length) { textShadows .slice(0) .reverse() .forEach(function (textShadow2) { _this.ctx.shadowColor = asString(textShadow2.color) _this.ctx.shadowOffsetX = textShadow2.offsetX.number * _this.options.scale _this.ctx.shadowOffsetY = textShadow2.offsetY.number * _this.options.scale _this.ctx.shadowBlur = textShadow2.blur.number _this.renderTextWithLetterSpacing( text3, styles.letterSpacing, baseline ) }) _this.ctx.shadowColor = '' _this.ctx.shadowOffsetX = 0 _this.ctx.shadowOffsetY = 0 _this.ctx.shadowBlur = 0 } if (styles.textDecorationLine.length) { _this.ctx.fillStyle = asString( styles.textDecorationColor || styles.color ) styles.textDecorationLine.forEach(function ( textDecorationLine2 ) { switch (textDecorationLine2) { case 1: _this.ctx.fillRect( text3.bounds.left, Math.round(text3.bounds.top + baseline), text3.bounds.width, 1 ) break case 2: _this.ctx.fillRect( text3.bounds.left, Math.round(text3.bounds.top), text3.bounds.width, 1 ) break case 3: _this.ctx.fillRect( text3.bounds.left, Math.ceil(text3.bounds.top + middle), text3.bounds.width, 1 ) break } }) } break case 1: if (styles.webkitTextStrokeWidth && text3.text.trim().length) { _this.ctx.strokeStyle = asString(styles.webkitTextStrokeColor) _this.ctx.lineWidth = styles.webkitTextStrokeWidth _this.ctx.lineJoin = !!window.chrome ? 'miter' : 'round' _this.ctx.strokeText( text3.text, text3.bounds.left, text3.bounds.top + baseline ) } _this.ctx.strokeStyle = '' _this.ctx.lineWidth = 0 _this.ctx.lineJoin = 'miter' break } }) }) return [2] }) }) } CanvasRenderer2.prototype.renderReplacedElement = function ( container, curves, image2 ) { if ( image2 && container.intrinsicWidth > 0 && container.intrinsicHeight > 0 ) { var box2 = contentBox(container) var path = calculatePaddingBoxPath(curves) this.path(path) this.ctx.save() this.ctx.clip() this.ctx.drawImage( image2, 0, 0, container.intrinsicWidth, container.intrinsicHeight, box2.left, box2.top, box2.width, box2.height ) this.ctx.restore() } } CanvasRenderer2.prototype.renderNodeContent = function (paint) { return __awaiter(this, void 0, void 0, function () { var container, curves, styles, _i, _a2, child, image2, image2, iframeRenderer, canvas, size, _b2, fontFamily2, fontSize2, baseline, bounds, x2, textBounds, img, image2, url2, fontFamily2, bounds return __generator(this, function (_c2) { switch (_c2.label) { case 0: this.applyEffects(paint.getEffects(4)) container = paint.container curves = paint.curves styles = container.styles ;(_i = 0), (_a2 = container.textNodes) _c2.label = 1 case 1: if (!(_i < _a2.length)) return [3, 4] child = _a2[_i] return [4, this.renderTextNode(child, styles)] case 2: _c2.sent() _c2.label = 3 case 3: _i++ return [3, 1] case 4: if (!(container instanceof ImageElementContainer)) return [3, 8] _c2.label = 5 case 5: _c2.trys.push([5, 7, , 8]) return [4, this.context.cache.match(container.src)] case 6: image2 = _c2.sent() this.renderReplacedElement(container, curves, image2) return [3, 8] case 7: _c2.sent() this.context.logger.error('Error loading image ' + container.src) return [3, 8] case 8: if (container instanceof CanvasElementContainer) { this.renderReplacedElement(container, curves, container.canvas) } if (!(container instanceof SVGElementContainer)) return [3, 12] _c2.label = 9 case 9: _c2.trys.push([9, 11, , 12]) return [4, this.context.cache.match(container.svg)] case 10: image2 = _c2.sent() this.renderReplacedElement(container, curves, image2) return [3, 12] case 11: _c2.sent() this.context.logger.error( 'Error loading svg ' + container.svg.substring(0, 255) ) return [3, 12] case 12: if ( !(container instanceof IFrameElementContainer && container.tree) ) return [3, 14] iframeRenderer = new CanvasRenderer2(this.context, { scale: this.options.scale, backgroundColor: container.backgroundColor, x: 0, y: 0, width: container.width, height: container.height, }) return [4, iframeRenderer.render(container.tree)] case 13: canvas = _c2.sent() if (container.width && container.height) { this.ctx.drawImage( canvas, 0, 0, container.width, container.height, container.bounds.left, container.bounds.top, container.bounds.width, container.bounds.height ) } _c2.label = 14 case 14: if (container instanceof InputElementContainer) { size = Math.min(container.bounds.width, container.bounds.height) if (container.type === CHECKBOX) { if (container.checked) { this.ctx.save() this.path([ new Vector( container.bounds.left + size * 0.39363, container.bounds.top + size * 0.79 ), new Vector( container.bounds.left + size * 0.16, container.bounds.top + size * 0.5549 ), new Vector( container.bounds.left + size * 0.27347, container.bounds.top + size * 0.44071 ), new Vector( container.bounds.left + size * 0.39694, container.bounds.top + size * 0.5649 ), new Vector( container.bounds.left + size * 0.72983, container.bounds.top + size * 0.23 ), new Vector( container.bounds.left + size * 0.84, container.bounds.top + size * 0.34085 ), new Vector( container.bounds.left + size * 0.39363, container.bounds.top + size * 0.79 ), ]) this.ctx.fillStyle = asString(INPUT_COLOR) this.ctx.fill() this.ctx.restore() } } else if (container.type === RADIO) { if (container.checked) { this.ctx.save() this.ctx.beginPath() this.ctx.arc( container.bounds.left + size / 2, container.bounds.top + size / 2, size / 4, 0, Math.PI * 2, true ) this.ctx.fillStyle = asString(INPUT_COLOR) this.ctx.fill() this.ctx.restore() } } } if (isTextInputElement(container) && container.value.length) { ;(_b2 = this.createFontStyle(styles)), (fontFamily2 = _b2[0]), (fontSize2 = _b2[1]) baseline = this.fontMetrics.getMetrics( fontFamily2, fontSize2 ).baseline this.ctx.font = fontFamily2 this.ctx.fillStyle = asString(styles.color) this.ctx.textBaseline = 'alphabetic' this.ctx.textAlign = canvasTextAlign(container.styles.textAlign) bounds = contentBox(container) x2 = 0 switch (container.styles.textAlign) { case 1: x2 += bounds.width / 2 break case 2: x2 += bounds.width break } textBounds = bounds.add(x2, 0, 0, -bounds.height / 2 + 1) this.ctx.save() this.path([ new Vector(bounds.left, bounds.top), new Vector(bounds.left + bounds.width, bounds.top), new Vector( bounds.left + bounds.width, bounds.top + bounds.height ), new Vector(bounds.left, bounds.top + bounds.height), ]) this.ctx.clip() this.renderTextWithLetterSpacing( new TextBounds(container.value, textBounds), styles.letterSpacing, baseline ) this.ctx.restore() this.ctx.textBaseline = 'alphabetic' this.ctx.textAlign = 'left' } if (!contains(container.styles.display, 2048)) return [3, 20] if (!(container.styles.listStyleImage !== null)) return [3, 19] img = container.styles.listStyleImage if (!(img.type === 0)) return [3, 18] image2 = void 0 url2 = img.url _c2.label = 15 case 15: _c2.trys.push([15, 17, , 18]) return [4, this.context.cache.match(url2)] case 16: image2 = _c2.sent() this.ctx.drawImage( image2, container.bounds.left - (image2.width + 10), container.bounds.top ) return [3, 18] case 17: _c2.sent() this.context.logger.error('Error loading list-style-image ' + url2) return [3, 18] case 18: return [3, 20] case 19: if (paint.listValue && container.styles.listStyleType !== -1) { fontFamily2 = this.createFontStyle(styles)[0] this.ctx.font = fontFamily2 this.ctx.fillStyle = asString(styles.color) this.ctx.textBaseline = 'middle' this.ctx.textAlign = 'right' bounds = new Bounds( container.bounds.left, container.bounds.top + getAbsoluteValue( container.styles.paddingTop, container.bounds.width ), container.bounds.width, computeLineHeight(styles.lineHeight, styles.fontSize.number) / 2 + 1 ) this.renderTextWithLetterSpacing( new TextBounds(paint.listValue, bounds), styles.letterSpacing, computeLineHeight(styles.lineHeight, styles.fontSize.number) / 2 + 2 ) this.ctx.textBaseline = 'bottom' this.ctx.textAlign = 'left' } _c2.label = 20 case 20: return [2] } }) }) } CanvasRenderer2.prototype.renderStackContent = function (stack) { return __awaiter(this, void 0, void 0, function () { var _i, _a2, child, _b2, _c2, child, _d, _e, child, _f, _g, child, _h, _j, child, _k, _l, child, _m, _o, child return __generator(this, function (_p) { switch (_p.label) { case 0: if (contains(stack.element.container.flags, 16)) { debugger } return [4, this.renderNodeBackgroundAndBorders(stack.element)] case 1: _p.sent() ;(_i = 0), (_a2 = stack.negativeZIndex) _p.label = 2 case 2: if (!(_i < _a2.length)) return [3, 5] child = _a2[_i] return [4, this.renderStack(child)] case 3: _p.sent() _p.label = 4 case 4: _i++ return [3, 2] case 5: return [4, this.renderNodeContent(stack.element)] case 6: _p.sent() ;(_b2 = 0), (_c2 = stack.nonInlineLevel) _p.label = 7 case 7: if (!(_b2 < _c2.length)) return [3, 10] child = _c2[_b2] return [4, this.renderNode(child)] case 8: _p.sent() _p.label = 9 case 9: _b2++ return [3, 7] case 10: ;(_d = 0), (_e = stack.nonPositionedFloats) _p.label = 11 case 11: if (!(_d < _e.length)) return [3, 14] child = _e[_d] return [4, this.renderStack(child)] case 12: _p.sent() _p.label = 13 case 13: _d++ return [3, 11] case 14: ;(_f = 0), (_g = stack.nonPositionedInlineLevel) _p.label = 15 case 15: if (!(_f < _g.length)) return [3, 18] child = _g[_f] return [4, this.renderStack(child)] case 16: _p.sent() _p.label = 17 case 17: _f++ return [3, 15] case 18: ;(_h = 0), (_j = stack.inlineLevel) _p.label = 19 case 19: if (!(_h < _j.length)) return [3, 22] child = _j[_h] return [4, this.renderNode(child)] case 20: _p.sent() _p.label = 21 case 21: _h++ return [3, 19] case 22: ;(_k = 0), (_l = stack.zeroOrAutoZIndexOrTransformedOrOpacity) _p.label = 23 case 23: if (!(_k < _l.length)) return [3, 26] child = _l[_k] return [4, this.renderStack(child)] case 24: _p.sent() _p.label = 25 case 25: _k++ return [3, 23] case 26: ;(_m = 0), (_o = stack.positiveZIndex) _p.label = 27 case 27: if (!(_m < _o.length)) return [3, 30] child = _o[_m] return [4, this.renderStack(child)] case 28: _p.sent() _p.label = 29 case 29: _m++ return [3, 27] case 30: return [2] } }) }) } CanvasRenderer2.prototype.mask = function (paths) { this.ctx.beginPath() this.ctx.moveTo(0, 0) this.ctx.lineTo(this.canvas.width, 0) this.ctx.lineTo(this.canvas.width, this.canvas.height) this.ctx.lineTo(0, this.canvas.height) this.ctx.lineTo(0, 0) this.formatPath(paths.slice(0).reverse()) this.ctx.closePath() } CanvasRenderer2.prototype.path = function (paths) { this.ctx.beginPath() this.formatPath(paths) this.ctx.closePath() } CanvasRenderer2.prototype.formatPath = function (paths) { var _this = this paths.forEach(function (point, index2) { var start2 = isBezierCurve(point) ? point.start : point if (index2 === 0) { _this.ctx.moveTo(start2.x, start2.y) } else { _this.ctx.lineTo(start2.x, start2.y) } if (isBezierCurve(point)) { _this.ctx.bezierCurveTo( point.startControl.x, point.startControl.y, point.endControl.x, point.endControl.y, point.end.x, point.end.y ) } }) } CanvasRenderer2.prototype.renderRepeat = function ( path, pattern4, offsetX, offsetY ) { this.path(path) this.ctx.fillStyle = pattern4 this.ctx.translate(offsetX, offsetY) this.ctx.fill() this.ctx.translate(-offsetX, -offsetY) } CanvasRenderer2.prototype.resizeImage = function (image2, width, height) { var _a2 if (image2.width === width && image2.height === height) { return image2 } var ownerDocument = (_a2 = this.canvas.ownerDocument) !== null && _a2 !== void 0 ? _a2 : document var canvas = ownerDocument.createElement('canvas') canvas.width = Math.max(1, width) canvas.height = Math.max(1, height) var ctx = canvas.getContext('2d') ctx.drawImage( image2, 0, 0, image2.width, image2.height, 0, 0, width, height ) return canvas } CanvasRenderer2.prototype.renderBackgroundImage = function (container) { return __awaiter(this, void 0, void 0, function () { var index2, _loop_1, this_1, _i, _a2, backgroundImage2 return __generator(this, function (_b2) { switch (_b2.label) { case 0: index2 = container.styles.backgroundImage.length - 1 _loop_1 = function (backgroundImage3) { var image2, url2, _c2, path, x2, y2, width, height, pattern4, _d, path, x2, y2, width, height, _e, lineLength, x0, x1, y0, y1, canvas, ctx, gradient_1, pattern4, _f, path, left2, top_1, width, height, position2, x2, y2, _g, rx, ry, radialGradient_1, midX, midY, f2, invF return __generator(this, function (_h) { switch (_h.label) { case 0: if (!(backgroundImage3.type === 0)) return [3, 5] image2 = void 0 url2 = backgroundImage3.url _h.label = 1 case 1: _h.trys.push([1, 3, , 4]) return [4, this_1.context.cache.match(url2)] case 2: image2 = _h.sent() return [3, 4] case 3: _h.sent() this_1.context.logger.error( 'Error loading background-image ' + url2 ) return [3, 4] case 4: if (image2) { ;(_c2 = calculateBackgroundRendering(container, index2, [ image2.width, image2.height, image2.width / image2.height, ])), (path = _c2[0]), (x2 = _c2[1]), (y2 = _c2[2]), (width = _c2[3]), (height = _c2[4]) pattern4 = this_1.ctx.createPattern( this_1.resizeImage(image2, width, height), 'repeat' ) this_1.renderRepeat(path, pattern4, x2, y2) } return [3, 6] case 5: if (isLinearGradient$1(backgroundImage3)) { ;(_d = calculateBackgroundRendering(container, index2, [ null, null, null, ])), (path = _d[0]), (x2 = _d[1]), (y2 = _d[2]), (width = _d[3]), (height = _d[4]) ;(_e = calculateGradientDirection( backgroundImage3.angle, width, height )), (lineLength = _e[0]), (x0 = _e[1]), (x1 = _e[2]), (y0 = _e[3]), (y1 = _e[4]) canvas = document.createElement('canvas') canvas.width = width canvas.height = height ctx = canvas.getContext('2d') gradient_1 = ctx.createLinearGradient(x0, y0, x1, y1) processColorStops( backgroundImage3.stops, lineLength ).forEach(function (colorStop) { return gradient_1.addColorStop( colorStop.stop, asString(colorStop.color) ) }) ctx.fillStyle = gradient_1 ctx.fillRect(0, 0, width, height) if (width > 0 && height > 0) { pattern4 = this_1.ctx.createPattern(canvas, 'repeat') this_1.renderRepeat(path, pattern4, x2, y2) } } else if (isRadialGradient$1(backgroundImage3)) { ;(_f = calculateBackgroundRendering(container, index2, [ null, null, null, ])), (path = _f[0]), (left2 = _f[1]), (top_1 = _f[2]), (width = _f[3]), (height = _f[4]) position2 = backgroundImage3.position.length === 0 ? [FIFTY_PERCENT] : backgroundImage3.position x2 = getAbsoluteValue(position2[0], width) y2 = getAbsoluteValue( position2[position2.length - 1], height ) ;(_g = calculateRadius( backgroundImage3, x2, y2, width, height )), (rx = _g[0]), (ry = _g[1]) if (rx > 0 && ry > 0) { radialGradient_1 = this_1.ctx.createRadialGradient( left2 + x2, top_1 + y2, 0, left2 + x2, top_1 + y2, rx ) processColorStops( backgroundImage3.stops, rx * 2 ).forEach(function (colorStop) { return radialGradient_1.addColorStop( colorStop.stop, asString(colorStop.color) ) }) this_1.path(path) this_1.ctx.fillStyle = radialGradient_1 if (rx !== ry) { midX = container.bounds.left + 0.5 * container.bounds.width midY = container.bounds.top + 0.5 * container.bounds.height f2 = ry / rx invF = 1 / f2 this_1.ctx.save() this_1.ctx.translate(midX, midY) this_1.ctx.transform(1, 0, 0, f2, 0, 0) this_1.ctx.translate(-midX, -midY) this_1.ctx.fillRect( left2, invF * (top_1 - midY) + midY, width, height * invF ) this_1.ctx.restore() } else { this_1.ctx.fill() } } } _h.label = 6 case 6: index2-- return [2] } }) } this_1 = this ;(_i = 0), (_a2 = container.styles.backgroundImage.slice(0).reverse()) _b2.label = 1 case 1: if (!(_i < _a2.length)) return [3, 4] backgroundImage2 = _a2[_i] return [5, _loop_1(backgroundImage2)] case 2: _b2.sent() _b2.label = 3 case 3: _i++ return [3, 1] case 4: return [2] } }) }) } CanvasRenderer2.prototype.renderSolidBorder = function ( color2, side, curvePoints ) { return __awaiter(this, void 0, void 0, function () { return __generator(this, function (_a2) { this.path(parsePathForBorder(curvePoints, side)) this.ctx.fillStyle = asString(color2) this.ctx.fill() return [2] }) }) } CanvasRenderer2.prototype.renderDoubleBorder = function ( color2, width, side, curvePoints ) { return __awaiter(this, void 0, void 0, function () { var outerPaths, innerPaths return __generator(this, function (_a2) { switch (_a2.label) { case 0: if (!(width < 3)) return [3, 2] return [4, this.renderSolidBorder(color2, side, curvePoints)] case 1: _a2.sent() return [2] case 2: outerPaths = parsePathForBorderDoubleOuter(curvePoints, side) this.path(outerPaths) this.ctx.fillStyle = asString(color2) this.ctx.fill() innerPaths = parsePathForBorderDoubleInner(curvePoints, side) this.path(innerPaths) this.ctx.fill() return [2] } }) }) } CanvasRenderer2.prototype.renderNodeBackgroundAndBorders = function (paint) { return __awaiter(this, void 0, void 0, function () { var styles, hasBackground, borders, backgroundPaintingArea, side, _i, borders_1, border var _this = this return __generator(this, function (_a2) { switch (_a2.label) { case 0: this.applyEffects(paint.getEffects(2)) styles = paint.container.styles hasBackground = !isTransparent(styles.backgroundColor) || styles.backgroundImage.length borders = [ { style: styles.borderTopStyle, color: styles.borderTopColor, width: styles.borderTopWidth, }, { style: styles.borderRightStyle, color: styles.borderRightColor, width: styles.borderRightWidth, }, { style: styles.borderBottomStyle, color: styles.borderBottomColor, width: styles.borderBottomWidth, }, { style: styles.borderLeftStyle, color: styles.borderLeftColor, width: styles.borderLeftWidth, }, ] backgroundPaintingArea = calculateBackgroundCurvedPaintingArea( getBackgroundValueForIndex(styles.backgroundClip, 0), paint.curves ) if (!(hasBackground || styles.boxShadow.length)) return [3, 2] this.ctx.save() this.path(backgroundPaintingArea) this.ctx.clip() if (!isTransparent(styles.backgroundColor)) { this.ctx.fillStyle = asString(styles.backgroundColor) this.ctx.fill() } return [4, this.renderBackgroundImage(paint.container)] case 1: _a2.sent() this.ctx.restore() styles.boxShadow .slice(0) .reverse() .forEach(function (shadow) { _this.ctx.save() var borderBoxArea = calculateBorderBoxPath(paint.curves) var maskOffset = shadow.inset ? 0 : MASK_OFFSET var shadowPaintingArea = transformPath$1( borderBoxArea, -maskOffset + (shadow.inset ? 1 : -1) * shadow.spread.number, (shadow.inset ? 1 : -1) * shadow.spread.number, shadow.spread.number * (shadow.inset ? -2 : 2), shadow.spread.number * (shadow.inset ? -2 : 2) ) if (shadow.inset) { _this.path(borderBoxArea) _this.ctx.clip() _this.mask(shadowPaintingArea) } else { _this.mask(borderBoxArea) _this.ctx.clip() _this.path(shadowPaintingArea) } _this.ctx.shadowOffsetX = shadow.offsetX.number + maskOffset _this.ctx.shadowOffsetY = shadow.offsetY.number _this.ctx.shadowColor = asString(shadow.color) _this.ctx.shadowBlur = shadow.blur.number _this.ctx.fillStyle = shadow.inset ? asString(shadow.color) : 'rgba(0,0,0,1)' _this.ctx.fill() _this.ctx.restore() }) _a2.label = 2 case 2: side = 0 ;(_i = 0), (borders_1 = borders) _a2.label = 3 case 3: if (!(_i < borders_1.length)) return [3, 13] border = borders_1[_i] if ( !( border.style !== 0 && !isTransparent(border.color) && border.width > 0 ) ) return [3, 11] if (!(border.style === 2)) return [3, 5] return [ 4, this.renderDashedDottedBorder( border.color, border.width, side, paint.curves, 2 ), ] case 4: _a2.sent() return [3, 11] case 5: if (!(border.style === 3)) return [3, 7] return [ 4, this.renderDashedDottedBorder( border.color, border.width, side, paint.curves, 3 ), ] case 6: _a2.sent() return [3, 11] case 7: if (!(border.style === 4)) return [3, 9] return [ 4, this.renderDoubleBorder( border.color, border.width, side, paint.curves ), ] case 8: _a2.sent() return [3, 11] case 9: return [4, this.renderSolidBorder(border.color, side, paint.curves)] case 10: _a2.sent() _a2.label = 11 case 11: side++ _a2.label = 12 case 12: _i++ return [3, 3] case 13: return [2] } }) }) } CanvasRenderer2.prototype.renderDashedDottedBorder = function ( color2, width, side, curvePoints, style2 ) { return __awaiter(this, void 0, void 0, function () { var strokePaths, boxPaths, startX, startY, endX, endY, length2, dashLength, spaceLength, useLineDash, multiplier, numberOfDashes, minSpace, maxSpace, path1, path2, path1, path2 return __generator(this, function (_a2) { this.ctx.save() strokePaths = parsePathForBorderStroke(curvePoints, side) boxPaths = parsePathForBorder(curvePoints, side) if (style2 === 2) { this.path(boxPaths) this.ctx.clip() } if (isBezierCurve(boxPaths[0])) { startX = boxPaths[0].start.x startY = boxPaths[0].start.y } else { startX = boxPaths[0].x startY = boxPaths[0].y } if (isBezierCurve(boxPaths[1])) { endX = boxPaths[1].end.x endY = boxPaths[1].end.y } else { endX = boxPaths[1].x endY = boxPaths[1].y } if (side === 0 || side === 2) { length2 = Math.abs(startX - endX) } else { length2 = Math.abs(startY - endY) } this.ctx.beginPath() if (style2 === 3) { this.formatPath(strokePaths) } else { this.formatPath(boxPaths.slice(0, 2)) } dashLength = width < 3 ? width * 3 : width * 2 spaceLength = width < 3 ? width * 2 : width if (style2 === 3) { dashLength = width spaceLength = width } useLineDash = true if (length2 <= dashLength * 2) { useLineDash = false } else if (length2 <= dashLength * 2 + spaceLength) { multiplier = length2 / (2 * dashLength + spaceLength) dashLength *= multiplier spaceLength *= multiplier } else { numberOfDashes = Math.floor( (length2 + spaceLength) / (dashLength + spaceLength) ) minSpace = (length2 - numberOfDashes * dashLength) / (numberOfDashes - 1) maxSpace = (length2 - (numberOfDashes + 1) * dashLength) / numberOfDashes spaceLength = maxSpace <= 0 || Math.abs(spaceLength - minSpace) < Math.abs(spaceLength - maxSpace) ? minSpace : maxSpace } if (useLineDash) { if (style2 === 3) { this.ctx.setLineDash([0, dashLength + spaceLength]) } else { this.ctx.setLineDash([dashLength, spaceLength]) } } if (style2 === 3) { this.ctx.lineCap = 'round' this.ctx.lineWidth = width } else { this.ctx.lineWidth = width * 2 + 1.1 } this.ctx.strokeStyle = asString(color2) this.ctx.stroke() this.ctx.setLineDash([]) if (style2 === 2) { if (isBezierCurve(boxPaths[0])) { path1 = boxPaths[3] path2 = boxPaths[0] this.ctx.beginPath() this.formatPath([ new Vector(path1.end.x, path1.end.y), new Vector(path2.start.x, path2.start.y), ]) this.ctx.stroke() } if (isBezierCurve(boxPaths[1])) { path1 = boxPaths[1] path2 = boxPaths[2] this.ctx.beginPath() this.formatPath([ new Vector(path1.end.x, path1.end.y), new Vector(path2.start.x, path2.start.y), ]) this.ctx.stroke() } } this.ctx.restore() return [2] }) }) } CanvasRenderer2.prototype.render = function (element) { return __awaiter(this, void 0, void 0, function () { var stack return __generator(this, function (_a2) { switch (_a2.label) { case 0: if (this.options.backgroundColor) { this.ctx.fillStyle = asString(this.options.backgroundColor) this.ctx.fillRect( this.options.x, this.options.y, this.options.width, this.options.height ) } stack = parseStackingContexts(element) return [4, this.renderStack(stack)] case 1: _a2.sent() this.applyEffects([]) return [2, this.canvas] } }) }) } return CanvasRenderer2 })(Renderer) var isTextInputElement = function (container) { if (container instanceof TextareaElementContainer) { return true } else if (container instanceof SelectElementContainer) { return true } else if ( container instanceof InputElementContainer && container.type !== RADIO && container.type !== CHECKBOX ) { return true } return false } var calculateBackgroundCurvedPaintingArea = function (clip2, curves) { switch (clip2) { case 0: return calculateBorderBoxPath(curves) case 2: return calculateContentBoxPath(curves) case 1: default: return calculatePaddingBoxPath(curves) } } var canvasTextAlign = function (textAlign2) { switch (textAlign2) { case 1: return 'center' case 2: return 'right' case 0: default: return 'left' } } var iOSBrokenFonts = ['-apple-system', 'system-ui'] var fixIOSSystemFonts = function (fontFamilies) { return /iPhone OS 15_(0|1)/.test(window.navigator.userAgent) ? fontFamilies.filter(function (fontFamily2) { return iOSBrokenFonts.indexOf(fontFamily2) === -1 }) : fontFamilies } var ForeignObjectRenderer = (function (_super) { __extends$3(ForeignObjectRenderer2, _super) function ForeignObjectRenderer2(context2, options2) { var _this = _super.call(this, context2, options2) || this _this.canvas = options2.canvas ? options2.canvas : document.createElement('canvas') _this.ctx = _this.canvas.getContext('2d') _this.options = options2 _this.canvas.width = Math.floor(options2.width * options2.scale) _this.canvas.height = Math.floor(options2.height * options2.scale) _this.canvas.style.width = options2.width + 'px' _this.canvas.style.height = options2.height + 'px' _this.ctx.scale(_this.options.scale, _this.options.scale) _this.ctx.translate(-options2.x, -options2.y) _this.context.logger.debug( 'EXPERIMENTAL ForeignObject renderer initialized (' + options2.width + 'x' + options2.height + ' at ' + options2.x + ',' + options2.y + ') with scale ' + options2.scale ) return _this } ForeignObjectRenderer2.prototype.render = function (element) { return __awaiter(this, void 0, void 0, function () { var svg2, img return __generator(this, function (_a2) { switch (_a2.label) { case 0: svg2 = createForeignObjectSVG( this.options.width * this.options.scale, this.options.height * this.options.scale, this.options.scale, this.options.scale, element ) return [4, loadSerializedSVG(svg2)] case 1: img = _a2.sent() if (this.options.backgroundColor) { this.ctx.fillStyle = asString(this.options.backgroundColor) this.ctx.fillRect( 0, 0, this.options.width * this.options.scale, this.options.height * this.options.scale ) } this.ctx.drawImage( img, -this.options.x * this.options.scale, -this.options.y * this.options.scale ) return [2, this.canvas] } }) }) } return ForeignObjectRenderer2 })(Renderer) var loadSerializedSVG = function (svg2) { return new Promise(function (resolve2, reject2) { var img = new Image() img.onload = function () { resolve2(img) } img.onerror = reject2 img.src = 'data:image/svg+xml;charset=utf-8,' + encodeURIComponent(new XMLSerializer().serializeToString(svg2)) }) } var Logger = (function () { function Logger2(_a2) { var id2 = _a2.id, enabled = _a2.enabled this.id = id2 this.enabled = enabled this.start = Date.now() } Logger2.prototype.debug = function () { var args = [] for (var _i = 0; _i < arguments.length; _i++) { args[_i] = arguments[_i] } if (this.enabled) { if ( typeof window !== 'undefined' && window.console && typeof console.debug === 'function' ) { console.debug.apply( console, __spreadArray$7([this.id, this.getTime() + 'ms'], args) ) } else { this.info.apply(this, args) } } } Logger2.prototype.getTime = function () { return Date.now() - this.start } Logger2.prototype.info = function () { var args = [] for (var _i = 0; _i < arguments.length; _i++) { args[_i] = arguments[_i] } if (this.enabled) { if ( typeof window !== 'undefined' && window.console && typeof console.info === 'function' ) { console.info.apply( console, __spreadArray$7([this.id, this.getTime() + 'ms'], args) ) } } } Logger2.prototype.warn = function () { var args = [] for (var _i = 0; _i < arguments.length; _i++) { args[_i] = arguments[_i] } if (this.enabled) { if ( typeof window !== 'undefined' && window.console && typeof console.warn === 'function' ) { console.warn.apply( console, __spreadArray$7([this.id, this.getTime() + 'ms'], args) ) } else { this.info.apply(this, args) } } } Logger2.prototype.error = function () { var args = [] for (var _i = 0; _i < arguments.length; _i++) { args[_i] = arguments[_i] } if (this.enabled) { if ( typeof window !== 'undefined' && window.console && typeof console.error === 'function' ) { console.error.apply( console, __spreadArray$7([this.id, this.getTime() + 'ms'], args) ) } else { this.info.apply(this, args) } } } Logger2.instances = {} return Logger2 })() var Context = (function () { function Context2(options2, windowBounds) { var _a2 this.windowBounds = windowBounds this.instanceName = '#' + Context2.instanceCount++ this.logger = new Logger({ id: this.instanceName, enabled: options2.logging, }) this.cache = (_a2 = options2.cache) !== null && _a2 !== void 0 ? _a2 : new Cache(this, options2) } Context2.instanceCount = 1 return Context2 })() var html2canvas = function (element, options2) { if (options2 === void 0) { options2 = {} } return renderElement(element, options2) } if (typeof window !== 'undefined') { CacheStorage.setContext(window) } var renderElement = function (element, opts) { return __awaiter(void 0, void 0, void 0, function () { var ownerDocument, defaultView, resourceOptions, contextOptions, windowOptions, windowBounds, context2, foreignObjectRendering, cloneOptions, documentCloner, clonedElement, container, _a2, width, height, left2, top2, backgroundColor2, renderOptions, canvas, renderer2, root2, renderer2 var _b2, _c2, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t2 return __generator(this, function (_u) { switch (_u.label) { case 0: if (!element || typeof element !== 'object') { return [ 2, Promise.reject('Invalid element provided as first argument'), ] } ownerDocument = element.ownerDocument if (!ownerDocument) { throw new Error('Element is not attached to a Document') } defaultView = ownerDocument.defaultView if (!defaultView) { throw new Error('Document is not attached to a Window') } resourceOptions = { allowTaint: (_b2 = opts.allowTaint) !== null && _b2 !== void 0 ? _b2 : false, imageTimeout: (_c2 = opts.imageTimeout) !== null && _c2 !== void 0 ? _c2 : 15e3, proxy: opts.proxy, useCORS: (_d = opts.useCORS) !== null && _d !== void 0 ? _d : false, } contextOptions = __assign$k( { logging: (_e = opts.logging) !== null && _e !== void 0 ? _e : true, cache: opts.cache, }, resourceOptions ) windowOptions = { windowWidth: (_f = opts.windowWidth) !== null && _f !== void 0 ? _f : defaultView.innerWidth, windowHeight: (_g = opts.windowHeight) !== null && _g !== void 0 ? _g : defaultView.innerHeight, scrollX: (_h = opts.scrollX) !== null && _h !== void 0 ? _h : defaultView.pageXOffset, scrollY: (_j = opts.scrollY) !== null && _j !== void 0 ? _j : defaultView.pageYOffset, } windowBounds = new Bounds( windowOptions.scrollX, windowOptions.scrollY, windowOptions.windowWidth, windowOptions.windowHeight ) context2 = new Context(contextOptions, windowBounds) foreignObjectRendering = (_k = opts.foreignObjectRendering) !== null && _k !== void 0 ? _k : false cloneOptions = { allowTaint: (_l = opts.allowTaint) !== null && _l !== void 0 ? _l : false, onclone: opts.onclone, ignoreElements: opts.ignoreElements, inlineImages: foreignObjectRendering, copyStyles: foreignObjectRendering, } context2.logger.debug( 'Starting document clone with size ' + windowBounds.width + 'x' + windowBounds.height + ' scrolled to ' + -windowBounds.left + ',' + -windowBounds.top ) documentCloner = new DocumentCloner(context2, element, cloneOptions) clonedElement = documentCloner.clonedReferenceElement if (!clonedElement) { return [ 2, Promise.reject('Unable to find element in cloned iframe'), ] } return [4, documentCloner.toIFrame(ownerDocument, windowBounds)] case 1: container = _u.sent() ;(_a2 = isBodyElement(clonedElement) || isHTMLElement(clonedElement) ? parseDocumentSize(clonedElement.ownerDocument) : parseBounds(context2, clonedElement)), (width = _a2.width), (height = _a2.height), (left2 = _a2.left), (top2 = _a2.top) backgroundColor2 = parseBackgroundColor( context2, clonedElement, opts.backgroundColor ) renderOptions = { canvas: opts.canvas, backgroundColor: backgroundColor2, scale: (_o = (_m = opts.scale) !== null && _m !== void 0 ? _m : defaultView.devicePixelRatio) !== null && _o !== void 0 ? _o : 1, x: ((_p = opts.x) !== null && _p !== void 0 ? _p : 0) + left2, y: ((_q = opts.y) !== null && _q !== void 0 ? _q : 0) + top2, width: (_r = opts.width) !== null && _r !== void 0 ? _r : Math.ceil(width), height: (_s = opts.height) !== null && _s !== void 0 ? _s : Math.ceil(height), } if (!foreignObjectRendering) return [3, 3] context2.logger.debug( 'Document cloned, using foreign object rendering' ) renderer2 = new ForeignObjectRenderer(context2, renderOptions) return [4, renderer2.render(clonedElement)] case 2: canvas = _u.sent() return [3, 5] case 3: context2.logger.debug( 'Document cloned, element located at ' + left2 + ',' + top2 + ' with size ' + width + 'x' + height + ' using computed rendering' ) context2.logger.debug('Starting DOM parsing') root2 = parseTree(context2, clonedElement) if (backgroundColor2 === root2.styles.backgroundColor) { root2.styles.backgroundColor = COLORS.TRANSPARENT } context2.logger.debug( 'Starting renderer for element at ' + renderOptions.x + ',' + renderOptions.y + ' with size ' + renderOptions.width + 'x' + renderOptions.height ) renderer2 = new CanvasRenderer(context2, renderOptions) return [4, renderer2.render(root2)] case 4: canvas = _u.sent() _u.label = 5 case 5: if ( (_t2 = opts.removeContainer) !== null && _t2 !== void 0 ? _t2 : true ) { if (!DocumentCloner.destroy(container)) { context2.logger.error( 'Cannot detach cloned iframe as it is not in the DOM anymore' ) } } context2.logger.debug('Finished rendering') return [2, canvas] } }) }) } var parseBackgroundColor = function ( context2, element, backgroundColorOverride ) { var ownerDocument = element.ownerDocument var documentBackgroundColor = ownerDocument.documentElement ? parseColor( context2, getComputedStyle(ownerDocument.documentElement).backgroundColor ) : COLORS.TRANSPARENT var bodyBackgroundColor = ownerDocument.body ? parseColor(context2, getComputedStyle(ownerDocument.body).backgroundColor) : COLORS.TRANSPARENT var defaultBackgroundColor = typeof backgroundColorOverride === 'string' ? parseColor(context2, backgroundColorOverride) : backgroundColorOverride === null ? COLORS.TRANSPARENT : 4294967295 return element === ownerDocument.documentElement ? isTransparent(documentBackgroundColor) ? isTransparent(bodyBackgroundColor) ? defaultBackgroundColor : bodyBackgroundColor : documentBackgroundColor : defaultBackgroundColor } var html2canvas_esm = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: html2canvas, }, Symbol.toStringTag, { value: 'Module' } ) ) function resolveUrl(url2, baseUrl) { if (url2.match(/^[a-z]+:\/\//i)) { return url2 } if (url2.match(/^\/\//)) { return window.location.protocol + url2 } if (url2.match(/^[a-z]+:/i)) { return url2 } const doc = document.implementation.createHTMLDocument() const base2 = doc.createElement('base') const a2 = doc.createElement('a') doc.head.appendChild(base2) doc.body.appendChild(a2) if (baseUrl) { base2.href = baseUrl } a2.href = url2 return a2.href } const uuid$1 = (() => { let counter2 = 0 const random2 = () => `0000${((Math.random() * 36 ** 4) << 0).toString(36)}`.slice(-4) return () => { counter2 += 1 return `u${random2()}${counter2}` } })() function toArray$4(arrayLike) { const arr = [] for (let i2 = 0, l2 = arrayLike.length; i2 < l2; i2++) { arr.push(arrayLike[i2]) } return arr } function px(node2, styleProperty) { const win = node2.ownerDocument.defaultView || window const val2 = win.getComputedStyle(node2).getPropertyValue(styleProperty) return val2 ? parseFloat(val2.replace('px', '')) : 0 } function getNodeWidth(node2) { const leftBorder = px(node2, 'border-left-width') const rightBorder = px(node2, 'border-right-width') return node2.clientWidth + leftBorder + rightBorder } function getNodeHeight(node2) { const topBorder = px(node2, 'border-top-width') const bottomBorder = px(node2, 'border-bottom-width') return node2.clientHeight + topBorder + bottomBorder } function getImageSize(targetNode, options2 = {}) { const width = options2.width || getNodeWidth(targetNode) const height = options2.height || getNodeHeight(targetNode) return { width, height } } function getPixelRatio() { let ratio let FINAL_PROCESS try { FINAL_PROCESS = process } catch (e2) {} const val2 = FINAL_PROCESS && FINAL_PROCESS.env ? FINAL_PROCESS.env.devicePixelRatio : null if (val2) { ratio = parseInt(val2, 10) if (Number.isNaN(ratio)) { ratio = 1 } } return ratio || window.devicePixelRatio || 1 } const canvasDimensionLimit = 16384 function checkCanvasDimensions(canvas) { if ( canvas.width > canvasDimensionLimit || canvas.height > canvasDimensionLimit ) { if ( canvas.width > canvasDimensionLimit && canvas.height > canvasDimensionLimit ) { if (canvas.width > canvas.height) { canvas.height *= canvasDimensionLimit / canvas.width canvas.width = canvasDimensionLimit } else { canvas.width *= canvasDimensionLimit / canvas.height canvas.height = canvasDimensionLimit } } else if (canvas.width > canvasDimensionLimit) { canvas.height *= canvasDimensionLimit / canvas.width canvas.width = canvasDimensionLimit } else { canvas.width *= canvasDimensionLimit / canvas.height canvas.height = canvasDimensionLimit } } } function canvasToBlob(canvas, options2 = {}) { if (canvas.toBlob) { return new Promise((resolve2) => { canvas.toBlob( resolve2, options2.type ? options2.type : 'image/png', options2.quality ? options2.quality : 1 ) }) } return new Promise((resolve2) => { const binaryString = window.atob( canvas .toDataURL( options2.type ? options2.type : void 0, options2.quality ? options2.quality : void 0 ) .split(',')[1] ) const len2 = binaryString.length const binaryArray = new Uint8Array(len2) for (let i2 = 0; i2 < len2; i2 += 1) { binaryArray[i2] = binaryString.charCodeAt(i2) } resolve2( new Blob([binaryArray], { type: options2.type ? options2.type : 'image/png', }) ) }) } function createImage$1(url2) { return new Promise((resolve2, reject2) => { const img = new Image() img.decode = () => resolve2(img) img.onload = () => resolve2(img) img.onerror = reject2 img.crossOrigin = 'anonymous' img.decoding = 'async' img.src = url2 }) } async function svgToDataURL(svg2) { return Promise.resolve() .then(() => new XMLSerializer().serializeToString(svg2)) .then(encodeURIComponent) .then((html2) => `data:image/svg+xml;charset=utf-8,${html2}`) } async function nodeToDataURL(node2, width, height) { const xmlns = 'http://www.w3.org/2000/svg' const svg2 = document.createElementNS(xmlns, 'svg') const foreignObject = document.createElementNS(xmlns, 'foreignObject') svg2.setAttribute('width', `${width}`) svg2.setAttribute('height', `${height}`) svg2.setAttribute('viewBox', `0 0 ${width} ${height}`) foreignObject.setAttribute('width', '100%') foreignObject.setAttribute('height', '100%') foreignObject.setAttribute('x', '0') foreignObject.setAttribute('y', '0') foreignObject.setAttribute('externalResourcesRequired', 'true') svg2.appendChild(foreignObject) foreignObject.appendChild(node2) return svgToDataURL(svg2) } const isInstanceOfElement = (node2, instance) => { if (node2 instanceof instance) return true const nodePrototype = Object.getPrototypeOf(node2) if (nodePrototype === null) return false return ( nodePrototype.constructor.name === instance.name || isInstanceOfElement(nodePrototype, instance) ) } function formatCSSText(style2) { const content2 = style2.getPropertyValue('content') return `${style2.cssText} content: '${content2.replace(/'|"/g, '')}';` } function formatCSSProperties(style2) { return toArray$4(style2) .map((name2) => { const value2 = style2.getPropertyValue(name2) const priority = style2.getPropertyPriority(name2) return `${name2}: ${value2}${priority ? ' !important' : ''};` }) .join(' ') } function getPseudoElementStyle(className, pseudo, style2) { const selector2 = `.${className}:${pseudo}` const cssText = style2.cssText ? formatCSSText(style2) : formatCSSProperties(style2) return document.createTextNode(`${selector2}{${cssText}}`) } function clonePseudoElement(nativeNode, clonedNode, pseudo) { const style2 = window.getComputedStyle(nativeNode, pseudo) const content2 = style2.getPropertyValue('content') if (content2 === '' || content2 === 'none') { return } const className = uuid$1() try { clonedNode.className = `${clonedNode.className} ${className}` } catch (err) { return } const styleElement = document.createElement('style') styleElement.appendChild(getPseudoElementStyle(className, pseudo, style2)) clonedNode.appendChild(styleElement) } function clonePseudoElements(nativeNode, clonedNode) { clonePseudoElement(nativeNode, clonedNode, ':before') clonePseudoElement(nativeNode, clonedNode, ':after') } const WOFF = 'application/font-woff' const JPEG = 'image/jpeg' const mimes = { woff: WOFF, woff2: WOFF, ttf: 'application/font-truetype', eot: 'application/vnd.ms-fontobject', png: 'image/png', jpg: JPEG, jpeg: JPEG, gif: 'image/gif', tiff: 'image/tiff', svg: 'image/svg+xml', webp: 'image/webp', } function getExtension(url2) { const match2 = /\.([^./]*?)$/g.exec(url2) return match2 ? match2[1] : '' } function getMimeType(url2) { const extension = getExtension(url2).toLowerCase() return mimes[extension] || '' } function getContentFromDataUrl(dataURL) { return dataURL.split(/,/)[1] } function isDataUrl(url2) { return url2.search(/^(data:)/) !== -1 } function makeDataUrl(content2, mimeType) { return `data:${mimeType};base64,${content2}` } async function fetchAsDataURL(url2, init2, process2) { const res = await fetch(url2, init2) if (res.status === 404) { throw new Error(`Resource "${res.url}" not found`) } const blob = await res.blob() return new Promise((resolve2, reject2) => { const reader = new FileReader() reader.onerror = reject2 reader.onloadend = () => { try { resolve2(process2({ res, result: reader.result })) } catch (error2) { reject2(error2) } } reader.readAsDataURL(blob) }) } const cache$1 = {} function getCacheKey(url2, contentType, includeQueryParams) { let key2 = url2.replace(/\?.*/, '') if (includeQueryParams) { key2 = url2 } if (/ttf|otf|eot|woff2?/i.test(key2)) { key2 = key2.replace(/.*\//, '') } return contentType ? `[${contentType}]${key2}` : key2 } async function resourceToDataURL(resourceUrl, contentType, options2) { const cacheKey = getCacheKey( resourceUrl, contentType, options2.includeQueryParams ) if (cache$1[cacheKey] != null) { return cache$1[cacheKey] } if (options2.cacheBust) { resourceUrl += (/\?/.test(resourceUrl) ? '&' : '?') + new Date().getTime() } let dataURL try { const content2 = await fetchAsDataURL( resourceUrl, options2.fetchRequestInit, ({ res, result }) => { if (!contentType) { contentType = res.headers.get('Content-Type') || '' } return getContentFromDataUrl(result) } ) dataURL = makeDataUrl(content2, contentType) } catch (error2) { dataURL = options2.imagePlaceholder || '' let msg = `Failed to fetch resource: ${resourceUrl}` if (error2) { msg = typeof error2 === 'string' ? error2 : error2.message } if (msg) { console.warn(msg) } } cache$1[cacheKey] = dataURL return dataURL } async function cloneCanvasElement(canvas) { const dataURL = canvas.toDataURL() if (dataURL === 'data:,') { return canvas.cloneNode(false) } return createImage$1(dataURL) } async function cloneVideoElement(video, options2) { if (video.currentSrc) { const canvas = document.createElement('canvas') const ctx = canvas.getContext('2d') canvas.width = video.clientWidth canvas.height = video.clientHeight ctx === null || ctx === void 0 ? void 0 : ctx.drawImage(video, 0, 0, canvas.width, canvas.height) const dataURL2 = canvas.toDataURL() return createImage$1(dataURL2) } const poster = video.poster const contentType = getMimeType(poster) const dataURL = await resourceToDataURL(poster, contentType, options2) return createImage$1(dataURL) } async function cloneIFrameElement(iframe) { var _a2 try { if ( (_a2 = iframe === null || iframe === void 0 ? void 0 : iframe.contentDocument) === null || _a2 === void 0 ? void 0 : _a2.body ) { return await cloneNode(iframe.contentDocument.body, {}, true) } } catch (_b2) {} return iframe.cloneNode(false) } async function cloneSingleNode(node2, options2) { if (isInstanceOfElement(node2, HTMLCanvasElement)) { return cloneCanvasElement(node2) } if (isInstanceOfElement(node2, HTMLVideoElement)) { return cloneVideoElement(node2, options2) } if (isInstanceOfElement(node2, HTMLIFrameElement)) { return cloneIFrameElement(node2) } return node2.cloneNode(false) } const isSlotElement = (node2) => node2.tagName != null && node2.tagName.toUpperCase() === 'SLOT' async function cloneChildren(nativeNode, clonedNode, options2) { var _a2, _b2 let children = [] if (isSlotElement(nativeNode) && nativeNode.assignedNodes) { children = toArray$4(nativeNode.assignedNodes()) } else if ( isInstanceOfElement(nativeNode, HTMLIFrameElement) && ((_a2 = nativeNode.contentDocument) === null || _a2 === void 0 ? void 0 : _a2.body) ) { children = toArray$4(nativeNode.contentDocument.body.childNodes) } else { children = toArray$4( ((_b2 = nativeNode.shadowRoot) !== null && _b2 !== void 0 ? _b2 : nativeNode ).childNodes ) } if ( children.length === 0 || isInstanceOfElement(nativeNode, HTMLVideoElement) ) { return clonedNode } await children.reduce( (deferred, child) => deferred .then(() => cloneNode(child, options2)) .then((clonedChild) => { if (clonedChild) { clonedNode.appendChild(clonedChild) } }), Promise.resolve() ) return clonedNode } function cloneCSSStyle(nativeNode, clonedNode) { const targetStyle = clonedNode.style if (!targetStyle) { return } const sourceStyle = window.getComputedStyle(nativeNode) if (sourceStyle.cssText) { targetStyle.cssText = sourceStyle.cssText targetStyle.transformOrigin = sourceStyle.transformOrigin } else { toArray$4(sourceStyle).forEach((name2) => { let value2 = sourceStyle.getPropertyValue(name2) if (name2 === 'font-size' && value2.endsWith('px')) { const reducedFont = Math.floor(parseFloat(value2.substring(0, value2.length - 2))) - 0.1 value2 = `${reducedFont}px` } if ( isInstanceOfElement(nativeNode, HTMLIFrameElement) && name2 === 'display' && value2 === 'inline' ) { value2 = 'block' } if (name2 === 'd' && clonedNode.getAttribute('d')) { value2 = `path(${clonedNode.getAttribute('d')})` } targetStyle.setProperty( name2, value2, sourceStyle.getPropertyPriority(name2) ) }) } } function cloneInputValue(nativeNode, clonedNode) { if (isInstanceOfElement(nativeNode, HTMLTextAreaElement)) { clonedNode.innerHTML = nativeNode.value } if (isInstanceOfElement(nativeNode, HTMLInputElement)) { clonedNode.setAttribute('value', nativeNode.value) } } function cloneSelectValue(nativeNode, clonedNode) { if (isInstanceOfElement(nativeNode, HTMLSelectElement)) { const clonedSelect = clonedNode const selectedOption = Array.from(clonedSelect.children).find( (child) => nativeNode.value === child.getAttribute('value') ) if (selectedOption) { selectedOption.setAttribute('selected', '') } } } function decorate(nativeNode, clonedNode) { if (isInstanceOfElement(clonedNode, Element)) { cloneCSSStyle(nativeNode, clonedNode) clonePseudoElements(nativeNode, clonedNode) cloneInputValue(nativeNode, clonedNode) cloneSelectValue(nativeNode, clonedNode) } return clonedNode } async function ensureSVGSymbols(clone2, options2) { const uses = clone2.querySelectorAll ? clone2.querySelectorAll('use') : [] if (uses.length === 0) { return clone2 } const processedDefs = {} for (let i2 = 0; i2 < uses.length; i2++) { const use3 = uses[i2] const id2 = use3.getAttribute('xlink:href') if (id2) { const exist = clone2.querySelector(id2) const definition = document.querySelector(id2) if (!exist && definition && !processedDefs[id2]) { processedDefs[id2] = await cloneNode(definition, options2, true) } } } const nodes = Object.values(processedDefs) if (nodes.length) { const ns = 'http://www.w3.org/1999/xhtml' const svg2 = document.createElementNS(ns, 'svg') svg2.setAttribute('xmlns', ns) svg2.style.position = 'absolute' svg2.style.width = '0' svg2.style.height = '0' svg2.style.overflow = 'hidden' svg2.style.display = 'none' const defs = document.createElementNS(ns, 'defs') svg2.appendChild(defs) for (let i2 = 0; i2 < nodes.length; i2++) { defs.appendChild(nodes[i2]) } clone2.appendChild(svg2) } return clone2 } async function cloneNode(node2, options2, isRoot) { if (!isRoot && options2.filter && !options2.filter(node2)) { return null } return Promise.resolve(node2) .then((clonedNode) => cloneSingleNode(clonedNode, options2)) .then((clonedNode) => cloneChildren(node2, clonedNode, options2)) .then((clonedNode) => decorate(node2, clonedNode)) .then((clonedNode) => ensureSVGSymbols(clonedNode, options2)) } const URL_REGEX = /url\((['"]?)([^'"]+?)\1\)/g const URL_WITH_FORMAT_REGEX = /url\([^)]+\)\s*format\((["']?)([^"']+)\1\)/g const FONT_SRC_REGEX = /src:\s*(?:url\([^)]+\)\s*format\([^)]+\)[,;]\s*)+/g function toRegex(url2) { const escaped = url2.replace(/([.*+?^${}()|\[\]\/\\])/g, '\\$1') return new RegExp(`(url\\(['"]?)(${escaped})(['"]?\\))`, 'g') } function parseURLs(cssText) { const urls = [] cssText.replace(URL_REGEX, (raw, quotation, url2) => { urls.push(url2) return raw }) return urls.filter((url2) => !isDataUrl(url2)) } async function embed( cssText, resourceURL, baseURL2, options2, getContentFromUrl ) { try { const resolvedURL = baseURL2 ? resolveUrl(resourceURL, baseURL2) : resourceURL const contentType = getMimeType(resourceURL) let dataURL if (getContentFromUrl) { const content2 = await getContentFromUrl(resolvedURL) dataURL = makeDataUrl(content2, contentType) } else { dataURL = await resourceToDataURL(resolvedURL, contentType, options2) } return cssText.replace(toRegex(resourceURL), `$1${dataURL}$3`) } catch (error2) {} return cssText } function filterPreferredFontFormat(str, { preferredFontFormat }) { return !preferredFontFormat ? str : str.replace(FONT_SRC_REGEX, (match2) => { while (true) { const [src, , format2] = URL_WITH_FORMAT_REGEX.exec(match2) || [] if (!format2) { return '' } if (format2 === preferredFontFormat) { return `src: ${src};` } } }) } function shouldEmbed(url2) { return url2.search(URL_REGEX) !== -1 } async function embedResources(cssText, baseUrl, options2) { if (!shouldEmbed(cssText)) { return cssText } const filteredCSSText = filterPreferredFontFormat(cssText, options2) const urls = parseURLs(filteredCSSText) return urls.reduce( (deferred, url2) => deferred.then((css2) => embed(css2, url2, baseUrl, options2)), Promise.resolve(filteredCSSText) ) } async function embedProp(propName, node2, options2) { var _a2 const propValue = (_a2 = node2.style) === null || _a2 === void 0 ? void 0 : _a2.getPropertyValue(propName) if (propValue) { const cssString = await embedResources(propValue, null, options2) node2.style.setProperty( propName, cssString, node2.style.getPropertyPriority(propName) ) return true } return false } async function embedBackground(clonedNode, options2) { if (!(await embedProp('background', clonedNode, options2))) { await embedProp('background-image', clonedNode, options2) } if (!(await embedProp('mask', clonedNode, options2))) { await embedProp('mask-image', clonedNode, options2) } } async function embedImageNode(clonedNode, options2) { const isImageElement2 = isInstanceOfElement(clonedNode, HTMLImageElement) if ( !(isImageElement2 && !isDataUrl(clonedNode.src)) && !( isInstanceOfElement(clonedNode, SVGImageElement) && !isDataUrl(clonedNode.href.baseVal) ) ) { return } const url2 = isImageElement2 ? clonedNode.src : clonedNode.href.baseVal const dataURL = await resourceToDataURL(url2, getMimeType(url2), options2) await new Promise((resolve2, reject2) => { clonedNode.onload = resolve2 clonedNode.onerror = reject2 const image2 = clonedNode if (image2.decode) { image2.decode = resolve2 } if (image2.loading === 'lazy') { image2.loading = 'eager' } if (isImageElement2) { clonedNode.srcset = '' clonedNode.src = dataURL } else { clonedNode.href.baseVal = dataURL } }) } async function embedChildren(clonedNode, options2) { const children = toArray$4(clonedNode.childNodes) const deferreds = children.map((child) => embedImages(child, options2)) await Promise.all(deferreds).then(() => clonedNode) } async function embedImages(clonedNode, options2) { if (isInstanceOfElement(clonedNode, Element)) { await embedBackground(clonedNode, options2) await embedImageNode(clonedNode, options2) await embedChildren(clonedNode, options2) } } function applyStyle(node2, options2) { const { style: style2 } = node2 if (options2.backgroundColor) { style2.backgroundColor = options2.backgroundColor } if (options2.width) { style2.width = `${options2.width}px` } if (options2.height) { style2.height = `${options2.height}px` } const manual = options2.style if (manual != null) { Object.keys(manual).forEach((key2) => { style2[key2] = manual[key2] }) } return node2 } const cssFetchCache = {} async function fetchCSS(url2) { let cache2 = cssFetchCache[url2] if (cache2 != null) { return cache2 } const res = await fetch(url2) const cssText = await res.text() cache2 = { url: url2, cssText } cssFetchCache[url2] = cache2 return cache2 } async function embedFonts(data2, options2) { let cssText = data2.cssText const regexUrl = /url\(["']?([^"')]+)["']?\)/g const fontLocs = cssText.match(/url\([^)]+\)/g) || [] const loadFonts = fontLocs.map(async (loc) => { let url2 = loc.replace(regexUrl, '$1') if (!url2.startsWith('https://')) { url2 = new URL(url2, data2.url).href } return fetchAsDataURL(url2, options2.fetchRequestInit, ({ result }) => { cssText = cssText.replace(loc, `url(${result})`) return [loc, result] }) }) return Promise.all(loadFonts).then(() => cssText) } function parseCSS(source2) { if (source2 == null) { return [] } const result = [] const commentsRegex = /(\/\*[\s\S]*?\*\/)/gi let cssText = source2.replace(commentsRegex, '') const keyframesRegex = new RegExp( '((@.*?keyframes [\\s\\S]*?){([\\s\\S]*?}\\s*?)})', 'gi' ) while (true) { const matches2 = keyframesRegex.exec(cssText) if (matches2 === null) { break } result.push(matches2[0]) } cssText = cssText.replace(keyframesRegex, '') const importRegex = /@import[\s\S]*?url\([^)]*\)[\s\S]*?;/gi const combinedCSSRegex = '((\\s*?(?:\\/\\*[\\s\\S]*?\\*\\/)?\\s*?@media[\\s\\S]*?){([\\s\\S]*?)}\\s*?})|(([\\s\\S]*?){([\\s\\S]*?)})' const unifiedRegex = new RegExp(combinedCSSRegex, 'gi') while (true) { let matches2 = importRegex.exec(cssText) if (matches2 === null) { matches2 = unifiedRegex.exec(cssText) if (matches2 === null) { break } else { importRegex.lastIndex = unifiedRegex.lastIndex } } else { unifiedRegex.lastIndex = importRegex.lastIndex } result.push(matches2[0]) } return result } async function getCSSRules(styleSheets, options2) { const ret = [] const deferreds = [] styleSheets.forEach((sheet) => { if ('cssRules' in sheet) { try { toArray$4(sheet.cssRules || []).forEach((item2, index2) => { if (item2.type === CSSRule.IMPORT_RULE) { let importIndex = index2 + 1 const url2 = item2.href const deferred = fetchCSS(url2) .then((metadata) => embedFonts(metadata, options2)) .then((cssText) => parseCSS(cssText).forEach((rule2) => { try { sheet.insertRule( rule2, rule2.startsWith('@import') ? (importIndex += 1) : sheet.cssRules.length ) } catch (error2) { console.error('Error inserting rule from remote css', { rule: rule2, error: error2, }) } }) ) .catch((e2) => { console.error('Error loading remote css', e2.toString()) }) deferreds.push(deferred) } }) } catch (e2) { const inline = styleSheets.find((a2) => a2.href == null) || document.styleSheets[0] if (sheet.href != null) { deferreds.push( fetchCSS(sheet.href) .then((metadata) => embedFonts(metadata, options2)) .then((cssText) => parseCSS(cssText).forEach((rule2) => { inline.insertRule(rule2, sheet.cssRules.length) }) ) .catch((err) => { console.error('Error loading remote stylesheet', err) }) ) } console.error('Error inlining remote css file', e2) } } }) return Promise.all(deferreds).then(() => { styleSheets.forEach((sheet) => { if ('cssRules' in sheet) { try { toArray$4(sheet.cssRules || []).forEach((item2) => { ret.push(item2) }) } catch (e2) { console.error(`Error while reading CSS rules from ${sheet.href}`, e2) } } }) return ret }) } function getWebFontRules(cssRules) { return cssRules .filter((rule2) => rule2.type === CSSRule.FONT_FACE_RULE) .filter((rule2) => shouldEmbed(rule2.style.getPropertyValue('src'))) } async function parseWebFontRules(node2, options2) { if (node2.ownerDocument == null) { throw new Error('Provided element is not within a Document') } const styleSheets = toArray$4(node2.ownerDocument.styleSheets) const cssRules = await getCSSRules(styleSheets, options2) return getWebFontRules(cssRules) } async function getWebFontCSS(node2, options2) { const rules2 = await parseWebFontRules(node2, options2) const cssTexts = await Promise.all( rules2.map((rule2) => { const baseUrl = rule2.parentStyleSheet ? rule2.parentStyleSheet.href : null return embedResources(rule2.cssText, baseUrl, options2) }) ) return cssTexts.join('\n') } async function embedWebFonts(clonedNode, options2) { const cssText = options2.fontEmbedCSS != null ? options2.fontEmbedCSS : options2.skipFonts ? null : await getWebFontCSS(clonedNode, options2) if (cssText) { const styleNode = document.createElement('style') const sytleContent = document.createTextNode(cssText) styleNode.appendChild(sytleContent) if (clonedNode.firstChild) { clonedNode.insertBefore(styleNode, clonedNode.firstChild) } else { clonedNode.appendChild(styleNode) } } } async function toSvg(node2, options2 = {}) { const { width, height } = getImageSize(node2, options2) const clonedNode = await cloneNode(node2, options2, true) await embedWebFonts(clonedNode, options2) await embedImages(clonedNode, options2) applyStyle(clonedNode, options2) const datauri = await nodeToDataURL(clonedNode, width, height) return datauri } async function toCanvas(node2, options2 = {}) { const { width, height } = getImageSize(node2, options2) const svg2 = await toSvg(node2, options2) const img = await createImage$1(svg2) const canvas = document.createElement('canvas') const context2 = canvas.getContext('2d') const ratio = options2.pixelRatio || getPixelRatio() const canvasWidth = options2.canvasWidth || width const canvasHeight = options2.canvasHeight || height canvas.width = canvasWidth * ratio canvas.height = canvasHeight * ratio if (!options2.skipAutoScale) { checkCanvasDimensions(canvas) } canvas.style.width = `${canvasWidth}` canvas.style.height = `${canvasHeight}` if (options2.backgroundColor) { context2.fillStyle = options2.backgroundColor context2.fillRect(0, 0, canvas.width, canvas.height) } context2.drawImage(img, 0, 0, canvas.width, canvas.height) return canvas } async function toPng(node2, options2 = {}) { const canvas = await toCanvas(node2, options2) return canvas.toDataURL() } async function toBlob(node2, options2 = {}) { const canvas = await toCanvas(node2, options2) const blob = await canvasToBlob(canvas) return blob } const paperSize = { A4: { w: 210, h: 297, }, A3: { w: 297, h: 420, }, Letter: { w: 215.9, h: 279.4, }, Legal: { w: 215.9, h: 355.6, }, Tabloid: { w: 279.4, h: 431.8, }, B5: { w: 176, h: 250, }, B4: { w: 250, h: 353, }, C5: { w: 162, h: 229, }, } const paperTypeList = () => { let list2 = [] for (let key2 in paperSize) { let data2 = { name: key2, value: key2, } list2.push(data2) } return list2 } var print$1 = { exports: {} } ;(function (module2, exports2) { ;(function webpackUniversalModuleDefinition(root2, factory) { module2.exports = factory() })(window, function () { return (function (modules2) { var installedModules = {} function __webpack_require__2(moduleId) { if (installedModules[moduleId]) { return installedModules[moduleId].exports } var module3 = (installedModules[moduleId] = { i: moduleId, l: false, exports: {}, }) modules2[moduleId].call( module3.exports, module3, module3.exports, __webpack_require__2 ) module3.l = true return module3.exports } __webpack_require__2.m = modules2 __webpack_require__2.c = installedModules __webpack_require__2.d = function (exports3, name2, getter) { if (!__webpack_require__2.o(exports3, name2)) { Object.defineProperty(exports3, name2, { enumerable: true, get: getter, }) } } __webpack_require__2.r = function (exports3) { if (typeof Symbol !== 'undefined' && Symbol.toStringTag) { Object.defineProperty(exports3, Symbol.toStringTag, { value: 'Module', }) } Object.defineProperty(exports3, '__esModule', { value: true }) } __webpack_require__2.t = function (value2, mode2) { if (mode2 & 1) value2 = __webpack_require__2(value2) if (mode2 & 8) return value2 if ( mode2 & 4 && typeof value2 === 'object' && value2 && value2.__esModule ) return value2 var ns = /* @__PURE__ */ Object.create(null) __webpack_require__2.r(ns) Object.defineProperty(ns, 'default', { enumerable: true, value: value2, }) if (mode2 & 2 && typeof value2 != 'string') for (var key2 in value2) __webpack_require__2.d( ns, key2, function (key3) { return value2[key3] }.bind(null, key2) ) return ns } __webpack_require__2.n = function (module3) { var getter = module3 && module3.__esModule ? function getDefault() { return module3['default'] } : function getModuleExports() { return module3 } __webpack_require__2.d(getter, 'a', getter) return getter } __webpack_require__2.o = function (object4, property2) { return Object.prototype.hasOwnProperty.call(object4, property2) } __webpack_require__2.p = '' return __webpack_require__2((__webpack_require__2.s = 0)) })({ './src/index.js': function ( module3, __webpack_exports__, __webpack_require__2 ) { __webpack_require__2.r(__webpack_exports__) __webpack_require__2('./src/sass/index.scss') var _js_init__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__2('./src/js/init.js') var printJS2 = _js_init__WEBPACK_IMPORTED_MODULE_1__['default'].init if (typeof window !== 'undefined') { window.printJS = printJS2 } __webpack_exports__['default'] = printJS2 }, './src/js/browser.js': function ( module3, __webpack_exports__, __webpack_require__2 ) { __webpack_require__2.r(__webpack_exports__) var Browser2 = { isFirefox: function isFirefox2() { return typeof InstallTrigger !== 'undefined' }, isIE: function isIE() { return ( navigator.userAgent.indexOf('MSIE') !== -1 || !!document.documentMode ) }, isEdge: function isEdge() { return !Browser2.isIE() && !!window.StyleMedia }, isChrome: function isChrome() { var context2 = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : window return !!context2.chrome }, isSafari: function isSafari() { return ( Object.prototype.toString .call(window.HTMLElement) .indexOf('Constructor') > 0 || navigator.userAgent.toLowerCase().indexOf('safari') !== -1 ) }, isIOSChrome: function isIOSChrome() { return navigator.userAgent.toLowerCase().indexOf('crios') !== -1 }, } __webpack_exports__['default'] = Browser2 }, './src/js/functions.js': function ( module3, __webpack_exports__, __webpack_require__2 ) { __webpack_require__2.r(__webpack_exports__) __webpack_require__2.d(__webpack_exports__, 'addWrapper', function () { return addWrapper }) __webpack_require__2.d( __webpack_exports__, 'capitalizePrint', function () { return capitalizePrint } ) __webpack_require__2.d( __webpack_exports__, 'collectStyles', function () { return collectStyles } ) __webpack_require__2.d(__webpack_exports__, 'addHeader', function () { return addHeader }) __webpack_require__2.d(__webpack_exports__, 'cleanUp', function () { return cleanUp }) __webpack_require__2.d(__webpack_exports__, 'isRawHTML', function () { return isRawHTML }) var _modal__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__2('./src/js/modal.js') var _browser__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__2( './src/js/browser.js' ) function _typeof2(obj) { '@babel/helpers - typeof' if ( typeof Symbol === 'function' && typeof Symbol.iterator === 'symbol' ) { _typeof2 = function _typeof3(obj2) { return typeof obj2 } } else { _typeof2 = function _typeof3(obj2) { return obj2 && typeof Symbol === 'function' && obj2.constructor === Symbol && obj2 !== Symbol.prototype ? 'symbol' : typeof obj2 } } return _typeof2(obj) } function addWrapper(htmlData, params2) { var bodyStyle = 'font-family:' + params2.font + ' !important; font-size: ' + params2.font_size + ' !important; width:100%;' return '
' + htmlData + '
' } function capitalizePrint(obj) { return obj.charAt(0).toUpperCase() + obj.slice(1) } function collectStyles(element, params2) { var win = document.defaultView || window var elementStyle = '' var styles = win.getComputedStyle(element, '') for (var key2 = 0; key2 < styles.length; key2++) { if ( params2.targetStyles.indexOf('*') !== -1 || params2.targetStyle.indexOf(styles[key2]) !== -1 || targetStylesMatch(params2.targetStyles, styles[key2]) ) { if (styles.getPropertyValue(styles[key2])) elementStyle += styles[key2] + ':' + styles.getPropertyValue(styles[key2]) + ';' } } elementStyle += 'max-width: ' + params2.maxWidth + 'px !important; font-size: ' + params2.font_size + ' !important;' return elementStyle } function targetStylesMatch(styles, value2) { for (var i2 = 0; i2 < styles.length; i2++) { if ( _typeof2(value2) === 'object' && value2.indexOf(styles[i2]) !== -1 ) return true } return false } function addHeader(printElement, params2) { var headerContainer = document.createElement('div') if (isRawHTML(params2.header)) { headerContainer.innerHTML = params2.header } else { var headerElement = document.createElement('h1') var headerNode = document.createTextNode(params2.header) headerElement.appendChild(headerNode) headerElement.setAttribute('style', params2.headerStyle) headerContainer.appendChild(headerElement) } printElement.insertBefore(headerContainer, printElement.childNodes[0]) } function cleanUp(params2) { if (params2.showModal) _modal__WEBPACK_IMPORTED_MODULE_0__['default'].close() if (params2.onLoadingEnd) params2.onLoadingEnd() if (params2.showModal || params2.onLoadingStart) window.URL.revokeObjectURL(params2.printable) var event = 'mouseover' if ( _browser__WEBPACK_IMPORTED_MODULE_1__['default'].isChrome() || _browser__WEBPACK_IMPORTED_MODULE_1__['default'].isFirefox() ) { event = 'focus' } var handler = function handler2() { window.removeEventListener(event, handler2) params2.onPrintDialogClose() var iframe = document.getElementById(params2.frameId) if (iframe) { iframe.remove() } } window.addEventListener(event, handler) } function isRawHTML(raw) { var regexHtml = new RegExp( '<([A-Za-z][A-Za-z0-9]*)\\b[^>]*>(.*?)' ) return regexHtml.test(raw) } }, './src/js/html.js': function ( module3, __webpack_exports__, __webpack_require__2 ) { __webpack_require__2.r(__webpack_exports__) var _functions__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__2( './src/js/functions.js' ) var _print__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__2('./src/js/print.js') function _typeof2(obj) { '@babel/helpers - typeof' if ( typeof Symbol === 'function' && typeof Symbol.iterator === 'symbol' ) { _typeof2 = function _typeof3(obj2) { return typeof obj2 } } else { _typeof2 = function _typeof3(obj2) { return obj2 && typeof Symbol === 'function' && obj2.constructor === Symbol && obj2 !== Symbol.prototype ? 'symbol' : typeof obj2 } } return _typeof2(obj) } __webpack_exports__['default'] = { print: function print2(params2, printFrame) { var printElement = isHtmlElement(params2.printable) ? params2.printable : document.getElementById(params2.printable) if (!printElement) { window.console.error( 'Invalid HTML element id: ' + params2.printable ) return } params2.printableElement = cloneElement(printElement, params2) if (params2.header) { Object(_functions__WEBPACK_IMPORTED_MODULE_0__['addHeader'])( params2.printableElement, params2 ) } _print__WEBPACK_IMPORTED_MODULE_1__['default'].send( params2, printFrame ) }, } function cloneElement(element, params2) { var clone2 = element.cloneNode() var childNodesArray = Array.prototype.slice.call(element.childNodes) for (var i2 = 0; i2 < childNodesArray.length; i2++) { if (params2.ignoreElements.indexOf(childNodesArray[i2].id) !== -1) { continue } var clonedChild = cloneElement(childNodesArray[i2], params2) clone2.appendChild(clonedChild) } if (params2.scanStyles && element.nodeType === 1) { clone2.setAttribute( 'style', Object(_functions__WEBPACK_IMPORTED_MODULE_0__['collectStyles'])( element, params2 ) ) } switch (element.tagName) { case 'SELECT': clone2.value = element.value break case 'CANVAS': clone2.getContext('2d').drawImage(element, 0, 0) break } return clone2 } function isHtmlElement(printable) { return ( _typeof2(printable) === 'object' && printable && (printable instanceof HTMLElement || printable.nodeType === 1) ) } }, './src/js/image.js': function ( module3, __webpack_exports__, __webpack_require__2 ) { __webpack_require__2.r(__webpack_exports__) var _functions__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__2( './src/js/functions.js' ) var _print__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__2('./src/js/print.js') var _browser__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__2( './src/js/browser.js' ) __webpack_exports__['default'] = { print: function print2(params2, printFrame) { if (params2.printable.constructor !== Array) { params2.printable = [params2.printable] } params2.printableElement = document.createElement('div') params2.printable.forEach(function (src) { var img = document.createElement('img') img.setAttribute('style', params2.imageStyle) img.src = src if ( _browser__WEBPACK_IMPORTED_MODULE_2__['default'].isFirefox() ) { var fullyQualifiedSrc = img.src img.src = fullyQualifiedSrc } var imageWrapper = document.createElement('div') imageWrapper.appendChild(img) params2.printableElement.appendChild(imageWrapper) }) if (params2.header) Object(_functions__WEBPACK_IMPORTED_MODULE_0__['addHeader'])( params2.printableElement, params2 ) _print__WEBPACK_IMPORTED_MODULE_1__['default'].send( params2, printFrame ) }, } }, './src/js/init.js': function ( module3, __webpack_exports__, __webpack_require__2 ) { __webpack_require__2.r(__webpack_exports__) var _browser__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__2( './src/js/browser.js' ) var _modal__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__2('./src/js/modal.js') var _pdf__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__2('./src/js/pdf.js') var _html__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__2('./src/js/html.js') var _raw_html__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__2( './src/js/raw-html.js' ) var _image__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__2('./src/js/image.js') var _json__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__2('./src/js/json.js') function _typeof2(obj) { '@babel/helpers - typeof' if ( typeof Symbol === 'function' && typeof Symbol.iterator === 'symbol' ) { _typeof2 = function _typeof3(obj2) { return typeof obj2 } } else { _typeof2 = function _typeof3(obj2) { return obj2 && typeof Symbol === 'function' && obj2.constructor === Symbol && obj2 !== Symbol.prototype ? 'symbol' : typeof obj2 } } return _typeof2(obj) } var printTypes = ['pdf', 'html', 'image', 'json', 'raw-html'] __webpack_exports__['default'] = { init: function init2() { var params2 = { printable: null, fallbackPrintable: null, type: 'pdf', header: null, headerStyle: 'font-weight: 300;', maxWidth: 800, properties: null, gridHeaderStyle: 'font-weight: bold; padding: 5px; border: 1px solid #dddddd;', gridStyle: 'border: 1px solid lightgray; margin-bottom: -1px;', showModal: false, onError: function onError(error2) { throw error2 }, onLoadingStart: null, onLoadingEnd: null, onPrintDialogClose: function onPrintDialogClose() {}, onIncompatibleBrowser: function onIncompatibleBrowser() {}, modalMessage: 'Retrieving Document...', frameId: 'printJS', printableElement: null, documentTitle: 'Document', targetStyle: [ 'clear', 'display', 'width', 'min-width', 'height', 'min-height', 'max-height', ], targetStyles: ['border', 'box', 'break', 'text-decoration'], ignoreElements: [], repeatTableHeader: true, css: null, style: null, scanStyles: true, base64: false, onPdfOpen: null, font: 'TimesNewRoman', font_size: '12pt', honorMarginPadding: true, honorColor: false, imageStyle: 'max-width: 100%;', } var args = arguments[0] if (args === void 0) { throw new Error('printJS expects at least 1 attribute.') } switch (_typeof2(args)) { case 'string': params2.printable = encodeURI(args) params2.fallbackPrintable = params2.printable params2.type = arguments[1] || params2.type break case 'object': params2.printable = args.printable params2.fallbackPrintable = typeof args.fallbackPrintable !== 'undefined' ? args.fallbackPrintable : params2.printable params2.fallbackPrintable = params2.base64 ? 'data:application/pdf;base64,'.concat( params2.fallbackPrintable ) : params2.fallbackPrintable for (var k2 in params2) { if (k2 === 'printable' || k2 === 'fallbackPrintable') continue params2[k2] = typeof args[k2] !== 'undefined' ? args[k2] : params2[k2] } break default: throw new Error( 'Unexpected argument type! Expected "string" or "object", got ' + _typeof2(args) ) } if (!params2.printable) throw new Error('Missing printable information.') if ( !params2.type || typeof params2.type !== 'string' || printTypes.indexOf(params2.type.toLowerCase()) === -1 ) { throw new Error( 'Invalid print type. Available types are: pdf, html, image and json.' ) } if (params2.showModal) _modal__WEBPACK_IMPORTED_MODULE_1__['default'].show(params2) if (params2.onLoadingStart) params2.onLoadingStart() var usedFrame = document.getElementById(params2.frameId) if (usedFrame) usedFrame.parentNode.removeChild(usedFrame) var printFrame = document.createElement('iframe') if (_browser__WEBPACK_IMPORTED_MODULE_0__['default'].isFirefox()) { printFrame.setAttribute( 'style', 'width: 1px; height: 100px; position: fixed; left: 0; top: 0; opacity: 0; border-width: 0; margin: 0; padding: 0' ) } else { printFrame.setAttribute( 'style', 'visibility: hidden; height: 0; width: 0; position: absolute; border: 0' ) } printFrame.setAttribute('id', params2.frameId) if (params2.type !== 'pdf') { printFrame.srcdoc = '' + params2.documentTitle + '' if (params2.css) { if (!Array.isArray(params2.css)) params2.css = [params2.css] params2.css.forEach(function (file2) { printFrame.srcdoc += '' }) } printFrame.srcdoc += '' } switch (params2.type) { case 'pdf': if (_browser__WEBPACK_IMPORTED_MODULE_0__['default'].isIE()) { try { console.info( "Print.js doesn't support PDF printing in Internet Explorer." ) var win = window.open(params2.fallbackPrintable, '_blank') win.focus() params2.onIncompatibleBrowser() } catch (error2) { params2.onError(error2) } finally { if (params2.showModal) _modal__WEBPACK_IMPORTED_MODULE_1__['default'].close() if (params2.onLoadingEnd) params2.onLoadingEnd() } } else { _pdf__WEBPACK_IMPORTED_MODULE_2__['default'].print( params2, printFrame ) } break case 'image': _image__WEBPACK_IMPORTED_MODULE_5__['default'].print( params2, printFrame ) break case 'html': _html__WEBPACK_IMPORTED_MODULE_3__['default'].print( params2, printFrame ) break case 'raw-html': _raw_html__WEBPACK_IMPORTED_MODULE_4__['default'].print( params2, printFrame ) break case 'json': _json__WEBPACK_IMPORTED_MODULE_6__['default'].print( params2, printFrame ) break } }, } }, './src/js/json.js': function ( module3, __webpack_exports__, __webpack_require__2 ) { __webpack_require__2.r(__webpack_exports__) var _functions__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__2( './src/js/functions.js' ) var _print__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__2('./src/js/print.js') function _typeof2(obj) { '@babel/helpers - typeof' if ( typeof Symbol === 'function' && typeof Symbol.iterator === 'symbol' ) { _typeof2 = function _typeof3(obj2) { return typeof obj2 } } else { _typeof2 = function _typeof3(obj2) { return obj2 && typeof Symbol === 'function' && obj2.constructor === Symbol && obj2 !== Symbol.prototype ? 'symbol' : typeof obj2 } } return _typeof2(obj) } __webpack_exports__['default'] = { print: function print2(params2, printFrame) { if (_typeof2(params2.printable) !== 'object') { throw new Error('Invalid javascript data object (JSON).') } if (typeof params2.repeatTableHeader !== 'boolean') { throw new Error( 'Invalid value for repeatTableHeader attribute (JSON).' ) } if (!params2.properties || !Array.isArray(params2.properties)) { throw new Error('Invalid properties array for your JSON data.') } params2.properties = params2.properties.map(function (property2) { return { field: _typeof2(property2) === 'object' ? property2.field : property2, displayName: _typeof2(property2) === 'object' ? property2.displayName : property2, columnSize: _typeof2(property2) === 'object' && property2.columnSize ? property2.columnSize + ';' : 100 / params2.properties.length + '%;', } }) params2.printableElement = document.createElement('div') if (params2.header) { Object(_functions__WEBPACK_IMPORTED_MODULE_0__['addHeader'])( params2.printableElement, params2 ) } params2.printableElement.innerHTML += jsonToHTML(params2) _print__WEBPACK_IMPORTED_MODULE_1__['default'].send( params2, printFrame ) }, } function jsonToHTML(params2) { var data2 = params2.printable var properties = params2.properties var htmlData = '' if (params2.repeatTableHeader) { htmlData += '' } htmlData += '' for (var a2 = 0; a2 < properties.length; a2++) { htmlData += '' } htmlData += '' if (params2.repeatTableHeader) { htmlData += '' } htmlData += '' for (var i2 = 0; i2 < data2.length; i2++) { htmlData += '' for (var n2 = 0; n2 < properties.length; n2++) { var stringData = data2[i2] var property2 = properties[n2].field.split('.') if (property2.length > 1) { for (var p2 = 0; p2 < property2.length; p2++) { stringData = stringData[property2[p2]] } } else { stringData = stringData[properties[n2].field] } htmlData += '' } htmlData += '' } htmlData += '
' + Object( _functions__WEBPACK_IMPORTED_MODULE_0__['capitalizePrint'] )(properties[a2].displayName) + '
' + stringData + '
' return htmlData } }, './src/js/modal.js': function ( module3, __webpack_exports__, __webpack_require__2 ) { __webpack_require__2.r(__webpack_exports__) var Modal = { show: function show(params2) { var modalStyle = 'font-family:sans-serif; display:table; text-align:center; font-weight:300; font-size:30px; left:0; top:0;position:fixed; z-index: 9990;color: #0460B5; width: 100%; height: 100%; background-color:rgba(255,255,255,.9);transition: opacity .3s ease;' var printModal = document.createElement('div') printModal.setAttribute('style', modalStyle) printModal.setAttribute('id', 'printJS-Modal') var contentDiv = document.createElement('div') contentDiv.setAttribute( 'style', 'display:table-cell; vertical-align:middle; padding-bottom:100px;' ) var closeButton = document.createElement('div') closeButton.setAttribute('class', 'printClose') closeButton.setAttribute('id', 'printClose') contentDiv.appendChild(closeButton) var spinner = document.createElement('span') spinner.setAttribute('class', 'printSpinner') contentDiv.appendChild(spinner) var messageNode = document.createTextNode(params2.modalMessage) contentDiv.appendChild(messageNode) printModal.appendChild(contentDiv) document.getElementsByTagName('body')[0].appendChild(printModal) document .getElementById('printClose') .addEventListener('click', function () { Modal.close() }) }, close: function close2() { var printModal = document.getElementById('printJS-Modal') if (printModal) { printModal.parentNode.removeChild(printModal) } }, } __webpack_exports__['default'] = Modal }, './src/js/pdf.js': function ( module3, __webpack_exports__, __webpack_require__2 ) { __webpack_require__2.r(__webpack_exports__) var _print__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__2('./src/js/print.js') var _functions__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__2( './src/js/functions.js' ) __webpack_exports__['default'] = { print: function print2(params2, printFrame) { if (params2.base64) { var bytesArray = Uint8Array.from( atob(params2.printable), function (c2) { return c2.charCodeAt(0) } ) createBlobAndPrint(params2, printFrame, bytesArray) return } params2.printable = /^(blob|http|\/\/)/i.test(params2.printable) ? params2.printable : window.location.origin + (params2.printable.charAt(0) !== '/' ? '/' + params2.printable : params2.printable) var req = new window.XMLHttpRequest() req.responseType = 'arraybuffer' req.addEventListener('error', function () { Object(_functions__WEBPACK_IMPORTED_MODULE_1__['cleanUp'])( params2 ) params2.onError(req.statusText, req) }) req.addEventListener('load', function () { if ([200, 201].indexOf(req.status) === -1) { Object(_functions__WEBPACK_IMPORTED_MODULE_1__['cleanUp'])( params2 ) params2.onError(req.statusText, req) return } createBlobAndPrint(params2, printFrame, req.response) }) req.open('GET', params2.printable, true) req.send() }, } function createBlobAndPrint(params2, printFrame, data2) { var localPdf = new window.Blob([data2], { type: 'application/pdf', }) localPdf = window.URL.createObjectURL(localPdf) printFrame.setAttribute('src', localPdf) _print__WEBPACK_IMPORTED_MODULE_0__['default'].send( params2, printFrame ) } }, './src/js/print.js': function ( module3, __webpack_exports__, __webpack_require__2 ) { __webpack_require__2.r(__webpack_exports__) var _browser__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__2( './src/js/browser.js' ) var _functions__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__2( './src/js/functions.js' ) var Print = { send: function send(params2, printFrame) { document.getElementsByTagName('body')[0].appendChild(printFrame) var iframeElement = document.getElementById(params2.frameId) iframeElement.onload = function () { if (params2.type === 'pdf') { if ( _browser__WEBPACK_IMPORTED_MODULE_0__['default'].isFirefox() ) { setTimeout(function () { return performPrint(iframeElement, params2) }, 1e3) } else { performPrint(iframeElement, params2) } return } var printDocument = iframeElement.contentWindow || iframeElement.contentDocument if (printDocument.document) printDocument = printDocument.document printDocument.body.appendChild(params2.printableElement) if (params2.type !== 'pdf' && params2.style) { var style2 = document.createElement('style') style2.innerHTML = params2.style printDocument.head.appendChild(style2) } var images = printDocument.getElementsByTagName('img') if (images.length > 0) { loadIframeImages(Array.from(images)).then(function () { return performPrint(iframeElement, params2) }) } else { performPrint(iframeElement, params2) } } }, } function performPrint(iframeElement, params2) { try { iframeElement.focus() if ( _browser__WEBPACK_IMPORTED_MODULE_0__['default'].isEdge() || _browser__WEBPACK_IMPORTED_MODULE_0__['default'].isIE() ) { try { iframeElement.contentWindow.document.execCommand( 'print', false, null ) } catch (e2) { iframeElement.contentWindow.print() } } else { iframeElement.contentWindow.print() } } catch (error2) { params2.onError(error2) } finally { if (_browser__WEBPACK_IMPORTED_MODULE_0__['default'].isFirefox()) { iframeElement.style.visibility = 'hidden' iframeElement.style.left = '-1px' } Object(_functions__WEBPACK_IMPORTED_MODULE_1__['cleanUp'])(params2) } } function loadIframeImages(images) { var promises = images.map(function (image2) { if (image2.src && image2.src !== window.location.href) { return loadIframeImage(image2) } }) return Promise.all(promises) } function loadIframeImage(image2) { return new Promise(function (resolve2) { var pollImage = function pollImage2() { !image2 || typeof image2.naturalWidth === 'undefined' || image2.naturalWidth === 0 || !image2.complete ? setTimeout(pollImage2, 500) : resolve2() } pollImage() }) } __webpack_exports__['default'] = Print }, './src/js/raw-html.js': function ( module3, __webpack_exports__, __webpack_require__2 ) { __webpack_require__2.r(__webpack_exports__) var _print__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__2('./src/js/print.js') __webpack_exports__['default'] = { print: function print2(params2, printFrame) { params2.printableElement = document.createElement('div') params2.printableElement.setAttribute('style', 'width:100%') params2.printableElement.innerHTML = params2.printable _print__WEBPACK_IMPORTED_MODULE_0__['default'].send( params2, printFrame ) }, } }, './src/sass/index.scss': function ( module3, exports3, __webpack_require__2 ) {}, 0: function (module3, exports3, __webpack_require__2) { module3.exports = __webpack_require__2('./src/index.js') }, })['default'] }) })(print$1) var printJS = /* @__PURE__ */ getDefaultExportFromCjs(print$1.exports) const electron = window.electron function getImg(element) { return new Promise((resolve2, reject2) => { toPng(element) .then(function (canvas) { const imageUrl = canvas const bufferData = base64ToUint8Array(imageUrl) resolve2({ imageUrl, bufferData, }) }) .catch((err) => { reject2(err) }) }) } function getImg1( element, canvasOpts = { dpi: 600, useCORS: true, allowTaint: false, tainttest: true, logging: false, } ) { return new Promise((resolve2, reject2) => { html2canvas(element, canvasOpts) .then(function (canvas) { const imageUrl = canvas.toDataURL('image/png') const bufferData = base64ToUint8Array(imageUrl) resolve2({ imageUrl, bufferData, }) }) .catch((err) => { reject2(err) }) }) } let isPdf = false function exportPdf( element, filename, filePath = null, pdfOpts = { orientation: 'p', unit: 'mm', format: 'A4', } ) { if (isPdf) return return new Promise((resolve2, reject2) => { isPdf = true toCanvas(element, { quality: 1 }) .then(function (canvas) { let pdf = new E$1(pdfOpts) let ctx = canvas.getContext('2d') if (!ctx) { return } const w2 = pdfOpts.orientation?.match(/^p/) ? 'w' : 'h' const h2 = pdfOpts.orientation?.match(/^p/) ? 'h' : 'w' let aw = lodash$2.exports.isArray(pdfOpts.format) ? pdfOpts.format[0] : paperSize[String(pdfOpts.format)][w2] let ah = lodash$2.exports.isArray(pdfOpts.format) ? pdfOpts.format[1] : paperSize[String(pdfOpts.format)][h2] let imgHeight = Math.floor((ah * canvas.width) / aw) let renderedHeight = 0 while (renderedHeight < canvas.height) { let page2 = document.createElement('canvas') page2.width = canvas.width page2.height = Math.min(imgHeight, canvas.height - renderedHeight) page2 .getContext('2d') ?.putImageData( ctx.getImageData( 0, renderedHeight, canvas.width, Math.min(imgHeight, canvas.height - renderedHeight) ), 0, 0 ) pdf.addImage( page2.toDataURL('image/jpeg', 1), 'JPEG', 0, 0, aw, Math.min(ah, (aw * page2.height) / page2.width) ) renderedHeight += imgHeight if (renderedHeight < canvas.height) { pdf.addPage() } } if (filePath && window.electron) { let rawdata = pdf.output('arraybuffer') specifiedDownload(filePath, filename, 'pdf', rawdata) } else { pdf.save(filename) } isPdf = false resolve2(pdf) }) .catch((err) => { isPdf = false reject2(err) }) }) } let isPrint = false function print(printable, type4 = 'html', targetStyles = ['*']) { if (isPrint) return return new Promise((resolve2, reject2) => { isPrint = true let focuser = setInterval( () => window.dispatchEvent(new Event('focus')), 500 ) printJS({ printable, type: type4, targetStyles, onError: (err) => { isPrint = false reject2(err) }, onLoadingEnd: () => {}, onPrintDialogClose: () => { clearInterval(focuser) isPrint = false resolve2(true) }, }) }) } function download(url2, filename, suffix2) { const aLink = document.createElement('a') aLink.style.display = 'none' aLink.href = url2 aLink.download = `${filename}.${suffix2}` document.body.appendChild(aLink) aLink.click() document.body.removeChild(aLink) } function specifiedDownload(path, filename, suffix2, rawdata) { if (!electron) return '' const fs = require('fs') let buffer = new Buffer(rawdata) const url2 = `${path}/${filename}.${suffix2}` fs.writeFile(url2, buffer, function (e2) { if (e2) throw e2 ElMessage({ message: `${filename}.${suffix2}\u6307\u5B9A\u8DEF\u5F84\u5BFC\u51FA\u6210\u529F`, type: 'success', customClass: 'cms-el-message el-message--success', }) }) } function base64toFile(dataurl, filename = 'file') { let mime = dataurl.split(',')[0].split(':')[1].split(';')[0] let suffix2 = mime.split('/')[1] let bstr = window.atob(dataurl.split(',')[1]) let n2 = bstr.length let u8arr = new Uint8Array(n2) while (n2--) { u8arr[n2] = bstr.charCodeAt(n2) } let file2 = new File([u8arr], `${filename}.${suffix2}`, { type: mime, }) return file2 } function base64ToUint8Array(base64String) { const rawData = window.atob(base64String.split(',')[1]) const outputArray = new Uint8Array(rawData.length) for (let i2 = 0; i2 < rawData.length; ++i2) { outputArray[i2] = rawData.charCodeAt(i2) } return outputArray } const controllerState = reactive({}) const ControllerEventType = { UNION_CHART: 'UNION_CHART', UN_UNION_CHART: 'UN_UNION_CHART', CHART_DATA: 'CHART_DATA', UNION_FILTER: 'UNION_FILTER', UN_UNION_FILTER: 'UN_UNION_FILTER', DESTROY_CONTROLLER: 'DESTROY_CONTROLLER', FILTER_DATA: 'FILTER_DATA', CONTROLLER_STATE_CHANGED: 'CONTROLLER_STATE_CHANGED', } function emit(eventType, detail) { dispatchEvent( new CustomEvent(eventType, { detail, }) ) } function on$1(eventType, cb) { useEventListener(window, eventType, (e2) => { cb(e2.detail) }) } on$1(ControllerEventType.UNION_CHART, function (detail) { controllerState[detail.controllerId] = detail }) on$1(ControllerEventType.UN_UNION_CHART, function (detail) { delete controllerState[detail.controllerId] }) on$1(ControllerEventType.UNION_FILTER, function (detail) { let controllerDetail = controllerState[detail.controllerId] if (!controllerDetail) { controllerDetail = { isFilter: true, controllerId: detail.controllerId, relativeList: detail.relativeList || [], chartIds: [detail.chartId], } } else { if (detail.relativeList) { controllerDetail.relativeList = controllerDetail.relativeList.concat( detail.relativeList ) } if (detail.chartId) { controllerDetail.chartIds = controllerDetail.chartIds.concat([ detail.chartId, ]) } } controllerState[detail.controllerId] = controllerDetail }) on$1(ControllerEventType.UN_UNION_FILTER, function (detail) { let controllerDetail = controllerState[detail.prevControllerId] if (controllerDetail) { controllerDetail.relativeList = controllerDetail.relativeList.filter( (item2) => item2.chartId !== detail.removeChartId ) controllerDetail.chartIds = controllerDetail.chartIds.filter( (item2) => item2 !== detail.removeChartId ) } }) on$1(ControllerEventType.DESTROY_CONTROLLER, function (detail) { delete controllerState[detail.controllerId] }) function getControllerDetailListByChartId(chartId) { const list2 = [] for (const controllerId in controllerState) { const controllerDetail = controllerState[controllerId] if (controllerDetail.isFilter) continue for (const item2 of controllerDetail.relativeList) { if (item2.chartId === chartId) { list2.push(controllerDetail) } } } return list2 } watchDebounced( controllerState, (val2) => { emit(ControllerEventType.CONTROLLER_STATE_CHANGED, val2) }, { debounce: 500, maxWait: 1e3 } ) window.controllerState = controllerState const methodList = { 0: '\u6C42\u548C', 1: '\u5E73\u5747\u503C', 2: '\u6700\u5C0F\u503C', 3: '\u6700\u5927\u503C', 4: '\u8BA1\u6570', 5: '\u53BB\u91CD\u8BA1\u6570', } const exportExcelIcon = 'path://M467.968 216.064L382.976 343.04l-12.8 25.6-14.336-25.088c-1.024-2.048-2.56-3.584-4.096-5.632l-0.512-0.512-87.04-121.344H206.848l137.728 178.688-123.392 176.128h54.784l76.8-123.904 0.512-1.024c1.024-1.536 2.048-2.56 3.072-4.096l14.848-20.992 12.8 26.112c7.68 11.776 38.4 61.44 70.656 113.664l5.632 9.728h57.344l-122.88-178.176 130.56-176.128H467.968zM781.824 185.344c-10.24 0-18.944 8.192-18.944 18.944 0 10.24 8.192 18.944 18.944 18.944h89.6c10.24 0 18.944-8.192 18.944-18.944 0-10.24-8.192-18.944-18.944-18.944h-89.6zM781.824 370.176c-10.24 0-18.944 8.192-18.944 18.944s8.192 18.944 18.944 18.944h89.6c5.12 0 9.728-2.048 13.312-5.632s5.632-8.192 5.632-13.312c0-10.24-8.192-18.944-18.944-18.944h-89.6zM781.824 544.768c-10.24 0-18.944 8.192-18.944 18.944s8.192 18.944 18.944 18.944h89.6c5.12 0 9.728-2.048 13.312-5.632s5.632-8.192 5.632-13.312c0-10.24-8.192-18.944-18.944-18.944h-89.6zM634.368 88.064H97.28c-22.528 0-40.96 18.432-40.96 40.96V657.92c0 22.528 18.432 40.96 40.96 40.96h537.088c22.528 0 40.96-18.432 40.96-40.96v-528.896c0-22.528-18.432-40.96-40.96-40.96zM97.28 679.424c-11.776 0-20.992-9.728-20.992-20.992v-528.896c0-11.776 9.728-20.992 20.992-20.992h537.088c11.776 0 20.992 9.728 20.992 20.992V657.92c0 11.776-9.728 20.992-20.992 20.992H97.28zM916.992 840.192H323.584c-28.16 0-50.688-22.528-50.688-50.688v-90.624h20.48V789.504c0 16.384 13.312 30.208 30.208 30.208H916.48c16.384 0 30.208-13.312 30.208-30.208v-811.008c0-16.384-13.312-30.208-30.208-30.208H323.584c-16.384 0-30.208 13.312-30.208 30.208v109.568h-20.48v-109.568c0-28.16 22.528-50.688 50.688-50.688H916.48c28.16 0 50.688 22.528 50.688 50.688V789.504c0 27.648-22.528 50.688-50.176 50.688z' const exportImageIcon = 'path://M512 137.728c-3.584 0-7.168 1.536-10.752 5.12l-138.24 138.24c-6.656 6.656-6.656 14.848 0 20.992 4.096 4.096 8.192 5.12 10.752 5.12s6.656-1.024 10.24-4.608l112.64-112.64V798.72c0 10.752 4.608 15.36 15.36 15.36s15.36-4.608 15.36-15.36v-609.28l112.64 112.64c3.072 3.072 6.656 5.12 10.752 5.12 3.584 0 7.168-1.536 10.752-5.12 6.656-6.656 6.656-14.848 0-20.992l-138.24-138.24c-3.584-3.072-7.168-5.12-11.264-5.12zM235.52-46.08c-61.44 0-107.52 46.08-107.52 107.52v322.56c0 61.44 46.08 107.52 107.52 107.52h92.16c10.752 0 15.36-4.608 15.36-15.36s-4.608-15.36-15.36-15.36H235.52c-44.544 0-76.8-32.256-76.8-76.8v-322.56c0-44.544 32.256-76.8 76.8-76.8h552.96c44.544 0 76.8 32.256 76.8 76.8v322.56c0 44.544-32.256 76.8-76.8 76.8h-92.16c-10.752 0-15.36 4.608-15.36 15.36s4.608 15.36 15.36 15.36h92.16c61.44 0 107.52-46.08 107.52-107.52v-322.56c0-61.44-46.08-107.52-107.52-107.52H235.52z' const dateFormatList = [ { value: 'yyyy-MM-dd HH:mm:ss', label: 'yyyy-MM-dd HH:mm:ss', }, { value: 'yyyy-MM-dd HH:mm', label: 'yyyy-MM-dd HH:mm', }, { value: 'yyyy-MM-dd HH', label: 'yyyy-MM-dd HH', }, { value: 'yyyy-MM-dd', label: 'yyyy-MM-dd', }, { value: 'yyyy-MM', label: 'yyyy-MM', }, { value: 'yyyy', label: 'yyyy', }, { value: 'HH:mm:ss', label: 'HH:mm:ss', }, { value: 'HH:mm', label: 'HH:mm', }, { value: 'HH', label: 'HH', }, ] const DIMENSION_LIST = [ { id: '0', fieldName: '\u8BB0\u5F55\u65F6\u95F4', fieldType: 3, aliasName: '', sort: 0, align: 0, mode: 0, timeFormat: 'yyyy-MM-dd HH:mm:ss', }, { id: '0', fieldName: '\u53D8\u91CF\u540D', fieldType: 1, aliasName: '', sort: 0, align: 0, mode: 0, dataFormat: 0, }, ] var DATA_TYPE = /* @__PURE__ */ ((DATA_TYPE2) => { DATA_TYPE2[(DATA_TYPE2['AGGREGATE'] = 0)] = 'AGGREGATE' DATA_TYPE2[(DATA_TYPE2['HISTORY'] = 1)] = 'HISTORY' DATA_TYPE2[(DATA_TYPE2['VARIABLE'] = 2)] = 'VARIABLE' return DATA_TYPE2 })(DATA_TYPE || {}) const tableTypeList = [ { type: 'concise', label: '\u7B80\u6D01', icon: 'icon-jianjie', color: '#90A7EB', }, { type: 'stripe', label: '\u6591\u9A6C\u7EBF', icon: 'icon-banmaxian', color: '#8CA0D1', }, { type: 'border', label: '\u7EBF\u6846', icon: 'icon-xiankuang', color: '#3d6eff', }, ] const textAlignList = [ { label: '\u5DE6\u5BF9\u9F50', value: 'left', }, { label: '\u5C45\u4E2D', value: 'center', }, { label: '\u53F3\u5BF9\u9F50', value: 'right', }, ] const pageSizeList = [ { label: '10\u6761/\u9875', value: 10, }, { label: '20\u6761/\u9875', value: 20, }, { label: '30\u6761/\u9875', value: 30, }, { label: '50\u6761/\u9875', value: 50, }, { label: '100\u6761/\u9875', value: 100, }, ] const pageTypeList = [ { label: '\u5206\u9875', value: 'page', }, { label: '\u5468\u671F\u6EDA\u52A8', value: 'cycleScroll', }, { label: '\u8FDE\u7EED\u6EDA\u52A8', value: 'continuScroll', }, ] const borderStyleList = [ { label: '\u65E0', src: '', value: 'none', }, { label: '\u76F4\u7EBF', src: '', value: 'solid', }, { label: '\u865A\u7EBF', src: '', value: 'dashed', }, { label: '\u5706\u70B9', src: '', value: 'dotted', }, ] const locationList$1 = [ { label: '\u5E95\u90E8', value: 'bottom', }, { label: '\u9876\u90E8', value: 'top', }, ] const calculationListEnum = { sum: 1, average: 2, max: 3, min: 4, median: 5, variance: 6, deviation: 7, hidden: 0, } const calculationList = [ { label: '\u6C42\u548C', value: 'sum', }, { label: '\u5E73\u5747', value: 'average', }, { label: '\u6700\u5927\u503C', value: 'max', }, { label: '\u6700\u5C0F\u503C', value: 'min', }, { label: '\u4E2D\u4F4D\u6570', value: 'median', }, { label: '\u65B9\u5DEE', value: 'variance', }, { label: '\u6807\u51C6\u5DEE', value: 'deviation', }, { label: '\u9690\u85CF', value: 'hidden', }, ] const totalRangeList = [ { label: '\u67E5\u8BE2\u5408\u8BA1', value: 'total', }, { label: '\u5206\u9875\u5408\u8BA1', value: 'paging', }, ] const cycleList = (key2, obj1, obj2) => { const map2 = obj2.reduce((t3, c2, ci) => { t3[c2.prop] = ci return t3 }, {}) for (let i2 = 0; i2 < obj1.length; i2++) { let item2 = obj1[i2] let num2 = 0 for (let o2 = 0; o2 < obj2.length; o2++) { if (item2[key2] == obj2[o2][key2]) { num2++ obj1[i2] = obj2[o2] break } } if (num2 <= 0) { if (item2.children) { cycleList(key2, item2.children, obj2) } else { obj1.splice(i2--, 1) } } } obj1.sort((a2, b2) => { return map2[a2.prop] - map2[b2.prop] }) } const setColumnList = (obj1, obj2) => { if (obj1.length && obj2.length) { cycleList('prop', obj1, obj2) for (let o2 = 0; o2 < obj2.length; o2++) { let obj2Item = obj2[o2] let num2 = 0 const cycleObj1 = (obj2Item2, list2) => { for (let o1 = 0; o1 < list2.length; o1++) { let item2 = list2[o1] if (item2.id == obj2Item2.id && item2.prop == obj2Item2.prop) { num2++ break } else if (item2.children) { cycleObj1(obj2Item2, item2.children) } } } cycleObj1(obj2Item, obj1) if (num2 <= 0) { obj1.push(obj2[o2]) } } } else { obj2.forEach((item2) => { obj1.push(item2) }) } obj1.sort((a2, b2) => { if (a2.type > b2.type) { return 1 } else if (a2.type < b2.type) { return -1 } else { return 0 } }) } function isNumber$e(val2) { var regPos = /^[0-9]+.?[0-9]*/ if (regPos.test(val2)) { return true } else { return false } } const getMappingData = (list2) => { let mapKey = {} let mapName = {} list2.forEach((item2) => { let method4 = item2.method let id2 = item2.id let name2 = item2.name let aliasName = item2.aliasName let fieldName = item2.fieldName if (method4 != null && Number(method4) >= 0) { mapKey[id2 + '-' + method4] = name2 mapName[id2 + '-' + method4] = aliasName || fieldName + `(${methodList[method4]})` } else { mapKey[id2] = name2 mapName[id2] = aliasName || fieldName } }) return { mapKey, mapName } } const getdefaultMappingData = (dimissions, indexes) => { let mapKey = {} let mapName = {} dimissions.forEach((item2) => { let id2 = item2.id let aliasName = item2.aliasName let fieldName = item2.fieldName mapKey[id2] = fieldName mapName[id2] = aliasName || fieldName }) indexes.forEach((item2) => { let id2 = item2.id let mode2 = item2.mode let aliasName = item2.aliasName let fieldName = item2.fieldName if (mode2 != null && Number(mode2) >= 0) { mapKey[id2 + '-' + mode2] = fieldName mapName[id2 + '-' + mode2] = aliasName || fieldName + `(${methodList[mode2]})` } }) return { mapKey, mapName } } const whereJsonMap = reactive({}) function fetchDataSetFieldList(dataSetId, dataSetType) { return new Promise((resolve2, reject2) => { if (dataSetType == 2) { request({ url: `/api/v1/dataconfig/filingtable/${dataSetId}/headers`, method: 'get', silent: true, }) .then((res) => { resolve2(res) }) .catch((err) => { reject2(err) }) } if (dataSetType == 3) { request({ url: `/api/v1/dataconfig/aggregatetable/${dataSetId}/headers`, method: 'get', silent: true, }) .then((res) => { resolve2(res) }) .catch((err) => { reject2(err) }) } }) } function uniqueFun(arr, key2) { const res = /* @__PURE__ */ new Map() return arr.filter((item2) => !res.has(item2[key2]) && res.set(item2[key2], 1)) } const isChartPie = (node2) => { if (node2.is && /^ChartPie/.test(node2.is)) return true return false } const useCacheCharts = (node2) => { if (node2.is && /^ChartBar/.test(node2.is)) return true if (node2.is && /^ChartLine/.test(node2.is)) return true return false } const isUseCache = (node2) => { const dataConfig = node2.props.dataConfig if ( dataConfig?.dataSetId && useCacheCharts(node2) && dataConfig?.dataSetType == '2' && dataConfig?.useCache ) return true return false } const controlList = { MaxThen: 0, MaxOrEqualsThen: 1, MinThen: 2, MinOrEqualsThen: 3, Equals: 4, NotEquals: 5, Like: 6, In: 7, NotIn: 8, Xor: 9, Between: 10, } async function fetchData( node2, nodeId, dataSetId, dimissions, indexes, whereJson2, limit2 = null, pageSize = null, pageIndex2 = null, total2 = false ) { let filterControllerList = getControllerDetailListByChartId(nodeId) let filters = [] filterControllerList.forEach((item2) => { let relativeList = item2.relativeList.filter((item1) => { return item1.chartId == nodeId && item1.field }) if (relativeList[0] && relativeList[0].field) filters.push({ control: controlList[item2.type], combine: 0, values: item2.value?.constructor === Array ? item2.value : [item2.value], fieldName: relativeList[0].field, innerFilters: [], }) }) const noAggregation = () => { if (isUseCache(node2)) return true if (node2.is == 'ChartTable') return false if (node2.is === 'ChartCard') return true if (dimissionsList.length <= 0) return true return false } const dimissionsList = dimissions .filter((d3) => d3.id) .map((item2) => { return { aliasName: item2.aliasName, fieldName: item2.id, sort: item2.sort || 0, timeFormat: item2.timeFormat, } }) const noDimensions = () => { if ( node2.props.dataConfig?.dataType === 1 && node2.props.dataConfig?.isVariableName ) return true if (node2.is === 'ChartTable') return false if (node2.is === 'ChartCard') return true if (dimissionsList.length <= 0) return true return false } let searchData = { dataSetId, dimensions: dimissionsList, measures: indexes .filter((i2) => i2.id) .map((item2) => { let mode2 = node2.props.dataConfig?.dataType === 2 ? 4 : item2.mode return { aliasName: item2.aliasName, fieldName: item2.id + '', mode: parseFloat(mode2), dataFormat: item2.dataFormat || 0, sort: item2.sort || 0, mergeType: node2.props.tableConfig.totalRowOption.totalRange === 'total' || node2.props.tableConfig.tableBodyOption.pageType !== 'page' ? calculationListEnum[ node2.props.tableConfig.tableOption.columnOptionList.find( (e2) => e2.prop === item2.id + '-' + mode2 )?.calculation ] : 0, } }), filters: isUseCache(node2) ? null : filters, total: total2, pageSize, pageIndex: pageIndex2, limit: limit2, noAggregation: noAggregation(), noDimensions: noDimensions(), whereJson: whereJson2, } return new Promise((resolve2, reject2) => { if (isUseCache(node2)) { searchData.measures.push({ fieldName: '_id', mode: -1, dataFormat: 0, sort: 0, }) request({ url: `/api/v1/data/getcache`, method: 'post', data: searchData, silent: true, }) .then((res) => { const list2 = res.values ? res.values : [] const mapping = res.mapping || [] const total22 = res.total const mergeResults = res.mergeResults resolve2({ list: list2, mapping, total: total22, mergeResults }) }) .catch((err) => { reject2(err) }) } else { request({ url: `/api/v1/data/aggregate`, method: 'post', data: searchData, silent: true, }) .then((res) => { if (res.errorMsg) { resolve2(res) } else { const list2 = res.values || [] const mapping = res.mapping || [] const total22 = res.total const mergeResults = res.mergeResults resolve2({ list: list2, mapping, total: total22, mergeResults }) } }) .catch((err) => { reject2(err) }) } }) } async function exportChartsExcel( filename = '\u56FE\u8868', charts2 = [], exportTable = false, exportControl = false, exportImage = false, path = '' ) { let chartsList = [] const SUFFIX = 'png' let param = new FormData() for (let i2 = 0; i2 < charts2.length; i2++) { let c2 = charts2[i2] let nodeId = c2.id let chartNode = CanvasNode$1.getById(nodeId) let props2 = chartNode?.props let dataSetId = props2?.dataConfig.dataSetId || 'history' let dimissions = props2?.dataConfig.dimissions let indexes = props2?.dataConfig.indexes.filter((i22) => i22.id) let name2 = c2.sheetName ?? chartNode?.name + '_' + Math.random().toString().slice(-4) if ( chartNode === void 0 || (!indexes.length && chartNode.is?.includes('ChartTable')) ) break if (isUseCache(chartNode)) indexes = uniqueFun(indexes, 'id') let filterControllerList = getControllerDetailListByChartId(nodeId) let filters = [] let controlStrings = [] let whereJson2 = void 0 let historyTimeRanges = void 0 const initFilter = () => { if (whereJsonMap[nodeId]?.label) { whereJson2 = whereJsonMap[nodeId]?.value if (exportControl) controlStrings.push([whereJsonMap[nodeId].label]) } filterControllerList.forEach((item2) => { let relativeList = item2.relativeList.filter((item1) => { return item1.chartId == nodeId && item1.field })[0] if (relativeList) { let value2 = item2.value?.constructor === Array ? item2.value : [item2.value] filters.push({ control: controlList[item2.type], combine: 0, values: value2, fieldName: relativeList.field, innerFilters: [], }) if (exportControl) { if (item2.type == 'Between') { controlStrings.push([relativeList.field, value2.join('-')]) } else { controlStrings.push([relativeList.field, value2.join(',')]) } } } }) } let excelData = void 0 if (c2.is === 'ChartLineTrend') { let chartProps = CanvasNode$1.getById(c2.id)?.props if (c2.isRealtime || !chartProps?.archivingDataTimeRange.length) { if (chartProps?.excelData) { let cloneExcelData = lodash$2.exports.cloneDeep(chartProps.excelData) cloneExcelData.rows.forEach((item2) => { item2['\u8BB0\u5F55\u65F6\u95F4'] = dayjs( item2['\u8BB0\u5F55\u65F6\u95F4'] ).format('YYYY-MM-DD HH:mm:ss') }) excelData = cloneExcelData } if ( chartProps?.realTimeControlString && chartProps.realTimeControlString.length ) { controlStrings.push(chartProps.realTimeControlString) } } else { initFilter() historyTimeRanges = chartProps?.archivingDataTimeRange || [] } } else { initFilter() } let searchData = { sheetName: name2, dataSetId, dimensions: dimissions .filter((d3) => d3.id) .map((item2) => { return { fieldName: dataSetId === 'history' ? item2.fieldName : item2.id, sort: item2.sort || 0, aliasName: Language$1.t(item2.aliasName), } }), measures: indexes.map((item2) => { return { fieldName: '' + item2.id, aliasName: Language$1.t(item2.aliasName), mode: parseFloat(item2.mode), dataFormat: item2.dataFormat || 0, sort: item2.sort || 0, } }), filters, total: false, pageSize: null, pageIndex: null, limit: isChartPie(chartNode) ? props2?.pieConfig.dataConfig.runningLimit : props2?.dataConfig.runningLimit, exportTable, exportControl, exportImage, controlStrings, isCache: isUseCache(chartNode), insertImages: [`${nodeId}.${SUFFIX}`], whereJson: whereJson2, noDimensions: props2?.dataConfig.isVariableName ? true : false, historyTimeRanges, excelData, } chartsList.push(searchData) } param.append('request', JSON.stringify(chartsList)) if (exportImage) { for (let i2 = 0; i2 < charts2.length; i2++) { let id2 = charts2[i2].id let chartDom = document.getElementById(id2) if (chartDom) { chartDom.classList.add('hiddenAllShadow') let { imageUrl } = await getImg1(chartDom) let file2 = base64toFile(imageUrl, id2) param.append(`${id2}.${SUFFIX}`, file2) chartDom.classList.remove('hiddenAllShadow') } } } const electron2 = window.electron return new Promise((resolve2, reject2) => { request({ url: `/api/v1/data/excel?name=${filename || '\u56FE\u8868'}&path=${ electron2 ? path : '' }`, method: 'post', data: param, responseType: 'arraybuffer', silent: true, }) .then((res) => { let name2 = filename + '_' + dayjs(new Date()).format('YYYYMMDDHHmmss') if (path && electron2) { resolve2({ data: res, path }) ElMessage({ message: `${name2}.xlsx\u6307\u5B9A\u8DEF\u5F84\u5BFC\u51FA\u6210\u529F`, type: 'success', customClass: 'cms-el-message el-message--success', }) } else { let blob = new Blob([res], { type: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet', }) let reader = new FileReader() reader.readAsDataURL(blob) reader.onload = function (e2) { download(String(e2.target?.result), name2, 'xlsx') resolve2({ data: res, path: '' }) } } }) .catch((err) => { console.warn('\u5BFC\u51FA\u5931\u8D25\u62C9' + err) reject2(err) }) }) } function judgeDivisor(m2, n2) { let num2 = {} var i2 = 0 m2 = m2 % n2 while (m2 != 0 && !(m2 in num2)) { num2[m2] = i2++ m2 = (m2 * 10) % n2 } return m2 == 0 } const end$1 = (max3, min3, splitNumber) => { let length2 = 0 if (String(max3).split('.').length > 1) { length2 = String(max3).split('.')[1].length } length2 += String(splitNumber).length let data1 = max3 - min3 let data2 = data1 / splitNumber let newNum if (judgeDivisor(data1, splitNumber)) { newNum = data2 } else { newNum = data2 + 1 / Math.pow(10, length2) } if (newNum >= 0) { return Math.ceil(newNum) } else { return Math.floor(newNum) } } const getarea = (num2, type4, zf) => { num2 = Math.abs(num2) if (num2 == 0) { return 0 } let splitnum = 1 let daitnum = String(num2) if (daitnum.split('.')[0].length > 1) { let nownum = String(daitnum.split('.')[0]).length for (let i2 = 0; i2 <= nownum; i2++) { splitnum = splitnum * 10 } } num2 = num2 / splitnum let numlength = String(num2) let endnum = '' let breaknum = '' for (let i2 = 0; i2 < numlength.length; i2++) { endnum += numlength[i2] if (numlength[i2] !== '.') { if (Number(numlength[i2]) > 0) { breaknum = Number(numlength[i2]) endnum = Number(endnum) break } } } endnum = Number(endnum) breaknum = Number(breaknum) let newNum if (type4 == 'min') { if ((endnum * zf - endnum / breaknum) * splitnum == 0) { newNum = (endnum * zf - endnum / breaknum / 10) * splitnum } else { newNum = (endnum * zf - endnum / breaknum) * splitnum } } else { newNum = (endnum * zf + endnum / breaknum) * splitnum } if (newNum >= 0) { return Math.ceil(newNum) } else { return Math.floor(newNum) } } const transformHistoryData = (res, props2) => { let { list: list2, mapping } = res if (props2.dataConfig.dataType === 1 && props2.dataConfig.isVariableName) { let arr = [] let indexes = props2.dataConfig.indexes let dimensions = props2.dataConfig.dimissions list2.map((item2) => { delete item2?.['\u8BB0\u5F55\u65F6\u95F4'] dimensions.forEach((i2) => { i2.fieldName && delete item2?.[i2.fieldName] i2.aliasName && delete item2?.[i2.aliasName] }) let keys3 = Object.keys(item2) for (const key2 of keys3) { let obj = {} keys3.forEach((i2) => { let index2 = indexes.find( (item22) => item22.fieldName + '(' + item22.mode + ')' === i2 ) obj[index2.aliasName || i2] = i2 === key2 ? item2[key2] : null }) arr.push(obj) } }) list2 = arr } return { list: list2, mapping } } class Widget { is = '' name = '' authorizationRequired = false category icon permission canvasView settingsView props styleConfig = {} onCreate constructor(object4 = {}) { const widget = Widget.store[object4.is] || this Object.assign(widget, object4) Widget.store[widget.is] = widget return widget } static store = {} static get list() { const store2 = Widget.store const array4 = [] for (const key2 in store2) { array4.push(store2[key2]) } return array4 } static async loadExternalWidgets(externalWidgetsAPI) { try { const urlList = await request(`${externalWidgetsAPI}`) const promises = [] for (const url2 of urlList) { const promise2 = Widget.importExternalWidgets(baseURL + url2) promises.push(promise2) } await Promise.all(promises) } catch (error2) { setTimeout(() => { throw error2 }) } } static async importExternalWidgets(url2) { try { window.Vue = Vue window.ElementPlus = ElementPlus const externalModule = await import( /* @vite-ignore */ `${url2}?importWidgets&t=${Date.now()}` ) const externalExports = externalModule.default || window.__importWidgets const widgetObjectList = [].concat(externalExports) for (const widgetInfo of widgetObjectList) { new Widget(widgetInfo) } } catch (error2) { setTimeout(() => { throw error2 }) } } static sortInfo = { base: ['Line', 'Circle', 'Rect', 'StaticText'], readWrite: [ 'NumberShow', 'NumberInput', 'ReadWriteInput', 'SwitchButton', 'JogButton', 'ControlButton', 'SelectControl', 'RadioControl', 'CheckboxControl', 'DynamicCircle', 'DynamicText', 'DynamicImg', 'Progress', ], chart: [ 'Sheet', 'ChartBar', 'ChartBarHorizontal', 'ChartBarHorizontalStacked', 'ChartBarStacked', 'ChartCard', 'ChartLine', 'ChartLineArea', 'ChartLineAreaStacked', 'ChartPie', 'ChartPieRing', 'ChartPieRose', 'ChartTable', 'ChartLineTrend', ], run: ['LogManage', 'PermissionManage', 'ChartLineTrendConfig'], } } const params$1 = new URL(location.href).searchParams const widgetsURL = params$1.get('widgets') if (widgetsURL) { await Widget.importExternalWidgets(widgetsURL) } var __glob_0_15 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, Widget, }, Symbol.toStringTag, { value: 'Module' } ) ) function userBehaviorAnalysis(behavior) { const common = { remoteTime: new Date().toISOString(), } const data2 = { common, behavior, } return request({ url: '/api/v1/userbehavioranalysis', method: 'post', data: data2, }) } function getPageAnalysisData() { let globalCallBlocks = 0 let pageCallBlocks = 0 let componentCallBlocks = 0 let standardCanvasNodes = 0 let imgCanvasNodes = 0 let chartCanvasNodes = 0 let controlCanvasNodes = 0 let runningCanvasNodes = 0 const project = app.current.project const page2 = project.current.page const childNodes = page2.document.body.childNodes let systemBlocks = project.blocks let pageBlocks = page2.document.body.blocks globalCallBlocks = calcBlocks(systemBlocks) let componentAnalysisData = calcCanvasNodes(childNodes) componentCallBlocks = componentAnalysisData.callBlocks standardCanvasNodes = componentAnalysisData.standardCanvasNodes imgCanvasNodes = componentAnalysisData.imgCanvasNodes chartCanvasNodes = componentAnalysisData.chartCanvasNodes controlCanvasNodes = componentAnalysisData.controlCanvasNodes runningCanvasNodes = componentAnalysisData.runningCanvasNodes pageCallBlocks = calcBlocks(pageBlocks) return { projectEvents: globalCallBlocks, pageEvents: pageCallBlocks + componentCallBlocks, standardComponents: standardCanvasNodes, imgComponents: imgCanvasNodes, chartComponents: chartCanvasNodes, controlComponents: controlCanvasNodes, runningComponents: runningCanvasNodes, } } function calcBlocks(blocks2) { let callBlocks = 0 blocks2.forEach((block) => { if (block.class === OnBlock.class) { block.children.forEach((element) => { if (element.class === IfBlock.class) { callBlocks += element.children.length } else if (element.class === CallBlock.class) { callBlocks++ } }) } }) return callBlocks } function calcCanvasNodes(childNodes) { let callBlocks = 0 let standardCanvasNodes = 0 let imgCanvasNodes = 0 let chartCanvasNodes = 0 let controlCanvasNodes = 0 let runningCanvasNodes = 0 childNodes.forEach((node2) => { if (!node2.is) return if (node2.is === 'Group') { callBlocks += calcBlocks(node2.blocks) let { callBlocks: ac, standardCanvasNodes: standard, imgCanvasNodes: imgs, chartCanvasNodes: charts2, } = calcCanvasNodes(node2.childNodes) callBlocks += ac standardCanvasNodes += standard imgCanvasNodes += imgs chartCanvasNodes += charts2 } else { let category = node2.is === 'Img' ? 'img' : Widget.store[node2.is]?.category switch (category) { case 'img': imgCanvasNodes++ break case 'chart': chartCanvasNodes++ break case 'controller': controlCanvasNodes++ break case 'run': runningCanvasNodes++ break default: standardCanvasNodes++ } callBlocks += calcBlocks(node2.blocks) } }) return { callBlocks, standardCanvasNodes, imgCanvasNodes, chartCanvasNodes, controlCanvasNodes, runningCanvasNodes, } } function getPictures() { return request({ url: `/api/v1/view/node/tree`, method: 'get', }) } function addPicture(params2, copyFrom) { return request({ url: `/api/v1/view/node?copyFrom=${copyFrom || ''}`, method: 'post', data: params2, }) } function changePicture(id2, params2) { return request({ url: `/api/v1/view/node/${id2}`, method: 'put', data: params2, }) } function pageSort(id2, params2) { return request({ url: `/api/v1/view/node/${id2}/sort`, method: 'post', data: params2, }) } function delPicture(id2) { return request({ url: `/api/v1/view/node/${id2}`, method: 'delete', }) } function batchDelPicture(ids) { return request({ url: `/api/v1/view/node/range`, method: 'delete', data: ids, }) } function getPicturesContent(id2) { return request({ url: `/api/v1/view/content/${id2}`, method: 'get', }) } async function savePicturesContent(id2, params2, silent = false) { const statistics = JSON.stringify(await getPageAnalysisData()) return request({ url: `/api/v1/view/content/${id2}`, method: 'put', data: { ...params2, statistics, }, silent, }) } function searchVariable(deviceId, groupId, type4, keyword) { return request({ url: `/api/v1/variable/query`, method: 'get', params: { deviceId, groupId, type: type4, keyword }, silent: true, }) } function getAllPicture(keyword) { return request({ url: `/api/v1/view/node`, method: 'get', params: { keyword }, }) } function checkVariable(data2) { return request({ url: `/api/v1/variable/check`, method: 'post', data: data2, }) } const TIME_THRESHOLD = 1e3 let clearLastDialogInfoTimer = null let pageManager class PageManager extends Base { id = 'PageManager' name = '\u9875\u9762\u63A7\u5236\u5668' topPageZIndex = '99' dialogPages = [] miniPagesId = [] currentDialogPageUUID = '' static lastDialogInfo constructor() { super() if (pageManager) { return pageManager } pageManager = this } get currentPage() { return this.dialogPages.filter( (dialogPage) => dialogPage.dialog._props.uuid === this.currentDialogPageUUID )[0] } getDialogPageById(id2) { const dialogPages = this.dialogPages.filter( (dialogPage) => id2 === dialogPage.dialog._props.uuid ) if (dialogPages.length) { return dialogPages[0].dialog } else { return null } } removeMiniPagesById(id2) { this.miniPagesId = this.miniPagesId.filter((page2) => page2.id !== id2) } removeDialogPagesById(id2) { this.dialogPages = this.dialogPages.filter( (dialogPage) => dialogPage.dialog._props.uuid !== id2 ) } jumpRoute(pageId) { setTimeout(() => { if (this.dialogPages.length && this.currentPage) { const currentPage2 = this.currentPage const currentDialog = currentPage2?.dialog currentPage2?.pageIds.push(pageId) currentDialog._props.loadPage(pageId) } else { push$4({ id: pageId + '', }) } }) } reloadRoute() { if (this.currentPage) { const pageId = this.currentPage?.pageIds[this.currentPage?.pageIds.length - 1] this.currentPage.dialog._props.loadPage(pageId) } else { reload() } } backRoute() { if (this.dialogPages.length && this.currentPage) { const currentPage2 = this.currentPage const currentDialog = currentPage2?.dialog if (currentPage2?.pageIds.length > 1) { currentPage2?.pageIds.pop() currentDialog._props.loadPage( currentPage2?.pageIds[currentPage2.pageIds.length - 1] ) } else { currentDialog._props.dialogClose() } } else { back() } } closeRoute() { if (this.currentPage) { this.currentPage.dialog._props.dialogClose() this.removeDialogPagesById(this.currentPage.dialog._props.uuid) } else { this.dialogPages.forEach(({ dialog: dialogPage }) => { dialogPage._props.dialogClose() }) this.dialogPages = [] } } async alertRoute( targetPageId, title, fixedSize, width, height, target2, closeBtn ) { if (this.dialogPages.length < 3) { if ( PageManager.lastDialogInfo?.pageId === String(targetPageId) && new Date().getTime() - PageManager.lastDialogInfo?.timestamp < TIME_THRESHOLD ) { ElMessage.warning( Language$1._t( '\u89E6\u53D1\u4E8B\u4EF6\u52A8\u4F5C\u6267\u884C\u5931\u8D25\uFF0C\u8BF7\u68C0\u67E5\u914D\u7F6E' ) ) clearLastDialogInfoTimer = setTimeout(() => { PageManager.lastDialogInfo = { timestamp: 0, pageId: '', } }, TIME_THRESHOLD) } else { const dialog = ( await Promise.resolve().then(function () { return DialogPage }) ).default const dialogComponent = await dialog({ id: targetPageId, title: String(title), fixedSize, width, height, closeBtn, operationAble: target2 !== 'dialog', }) clearTimeout(clearLastDialogInfoTimer) PageManager.lastDialogInfo = { timestamp: new Date().getTime(), pageId: String(targetPageId), } this.dialogPages.push({ dialog: dialogComponent, pageIds: [targetPageId], }) } } else { ElMessage.warning( Language$1._t('\u6700\u591A\u53EA\u80FD\u6253\u5F003\u4E2A\u5F39\u7A97') ) } } async exportCurrentPage( pageInfo, type4, filename, format2, orientation, specifiedSavePath, timeout = 2e3 ) { exportLoading.open() let bodyInfo = null if (pageInfo.id) { await getPicturesContent(pageInfo.id).then((res) => { if (res) { bodyInfo = JSON.parse(res.content).body } }) } else { bodyInfo = { id: pageInfo.elementId, } } return new Promise((resolve2) => { let timer2 = setTimeout(async () => { let rootDom = document.getElementById(bodyInfo.id) if (!rootDom) { ElMessage.warning( Language$1._t('\u5F53\u524D\u753B\u9762\u4E0D\u53EF\u5BFC\u51FA') + type4 ) console.warn('!rootDom') exportLoading.close() return } let name2 = filename + '_' + dayjs(new Date()).format('YYYYMMDDHHmmss') if (type4 == 'PDF') { let pdfOpts = { format: format2, unit: 'mm', orientation, } await exportPdf(rootDom, name2, specifiedSavePath, pdfOpts) } if (type4 == 'Image') { const { imageUrl, bufferData } = await getImg(rootDom) if (specifiedSavePath && window.electron) { specifiedDownload(specifiedSavePath, name2, 'png', bufferData) } else { download(imageUrl, name2, 'png') } } exportLoading.close() clearTimeout(timer2) resolve2() }, timeout) }) } async printCurrentPage(pageInfo, timeout = 2e3) { exportLoading.open(Language$1._t('\u6253\u5370\u51C6\u5907\u4E2D')) let bodyInfo = null if (pageInfo.id) { await getPicturesContent(pageInfo.id).then((res) => { if (res) { bodyInfo = JSON.parse(res.content).body } }) } else { bodyInfo = { id: pageInfo.elementId, } } return new Promise((resolve2) => { let timer2 = setTimeout(async () => { let rootDom = document.getElementById(bodyInfo.id) if (!rootDom) { ElMessage.warning( Language$1._t('\u5F53\u524D\u753B\u9762\u4E0D\u53EF\u6253\u5370') ) console.warn('!rootDom') exportLoading.close() return } await print(rootDom) clearTimeout(timer2) exportLoading.close() resolve2() }, timeout) }) } async exportChartsData( pageComponent, filename, type4, exportContent, specifiedSavePath, timeout = 1e3 ) { exportLoading.open() const { page: page2, component: component2 } = pageComponent let pageId = page2.id let bodyInfo = null await getPicturesContent(pageId).then((res) => { if (res) { bodyInfo = JSON.parse(res.content).body } }) return new Promise((resolve2) => { let timer2 = setTimeout(async () => { let rootDom = document.getElementById(bodyInfo.id) if (!rootDom) { ElMessage.warning( Language$1._t( '\u5F53\u524D\u753B\u9762\u4E0D\u53EF\u5BFC\u51FA\u5173\u8054\u56FE\u8868' ) ) console.warn('!rootDom') exportLoading.close() return } let data2 = false let filter2 = false let effect2 = false exportContent.forEach((item2) => { if (item2.indexOf('data') >= 0) data2 = true if (item2.indexOf('filter') >= 0) filter2 = true if (item2.indexOf('effect') >= 0) effect2 = true }) await exportChartsExcel( filename, component2, data2, filter2, effect2, specifiedSavePath ).catch((err) => { console.warn(err) }) exportLoading.close() clearTimeout(timer2) }, timeout) resolve2() }) } } var __glob_0_10 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, PageManager, }, Symbol.toStringTag, { value: 'Module' } ) ) const outputTypeList = [ { name: '\u5BFC\u51FA', value: 'export', }, { name: '\u6253\u5370', value: 'print', }, ] const outputTargetList = [ { name: '\u5F53\u524D\u9875\u9762', value: 'currentPage', }, { name: '\u5173\u8054\u56FE\u8868', value: 'correlationCharts', }, ] const exportTypeList1 = [ { name: 'PDF', value: 'PDF', }, { name: '\u56FE\u7247', value: 'Image', }, ] const exportTypeList2 = [ { name: 'Excel', value: 'Excel', }, ] const chartsExportContentList = [ { name: '\u56FE\u8868\u6570\u636E', value: 'data', }, { name: '\u7B5B\u9009\u6761\u4EF6', value: 'filter', }, { name: '\u56FE\u8868\u6548\u679C', value: 'effect', }, ] const layoutList = [ { name: '\u7EB5\u5411', value: 'portrait', }, { name: '\u6A2A\u5411', value: 'landscape', }, ] const filterList = [ { value: 'Equals', label: '==', }, { value: 'NotEquals', label: '!=', }, { value: 'MaxThen', label: '>', }, { value: 'MinThen', label: '<', }, { value: 'MaxOrEqualsThen', label: '>=', }, { value: 'MinOrEqualsThen', label: '<=', }, { value: 'Between', label: '\u533A\u95F4', }, { value: 'unNull', label: '\u4E0D\u4E3A\u7A7A', }, { value: 'null', label: '\u4E3A\u7A7A', }, ] const showAll = ['', 'Between'] const showOne = [ 'Equals', 'NotEquals', 'MaxThen', 'MinThen', 'MaxOrEqualsThen', 'MinOrEqualsThen', ] const unShow = ['null', 'unNull'] function visibleChange(dropDownSelect, val2) { if (mode === 'editing') { let { popperPaneRef, popperRef, selectWrapper, selectRef } = dropDownSelect let popRef = popperPaneRef || popperRef let selRef = selectWrapper || selectRef if (!selRef) return if (!val2) { popRef.style.opacity = 0 } else { popRef.style.opacity = 1 } setTimeout(() => { let popoverHeight = popRef.clientHeight let selectHeight = selRef.clientHeight let offsetY = 12 let bodyHeight = parseFloat( app.current.project.current.page.document.body.style.height + '' ) let height = popoverHeight + selectHeight + selRef.parentNode.offsetTop + offsetY if (bodyHeight - height >= 0) { popRef.style.left = 0 popRef.style.top = selectHeight + offsetY + 'px' } else { popRef.style.left = 0 popRef.style.top = -(popoverHeight + offsetY) + 'px' } }) } } class HttpError extends Error { constructor(errorMessage, statusCode) { const trueProto = new.target.prototype super(`${errorMessage}: Status code '${statusCode}'`) this.statusCode = statusCode this.__proto__ = trueProto } } class TimeoutError extends Error { constructor(errorMessage = 'A timeout occurred.') { const trueProto = new.target.prototype super(errorMessage) this.__proto__ = trueProto } } class AbortError extends Error { constructor(errorMessage = 'An abort occurred.') { const trueProto = new.target.prototype super(errorMessage) this.__proto__ = trueProto } } class UnsupportedTransportError extends Error { constructor(message2, transport) { const trueProto = new.target.prototype super(message2) this.transport = transport this.errorType = 'UnsupportedTransportError' this.__proto__ = trueProto } } class DisabledTransportError extends Error { constructor(message2, transport) { const trueProto = new.target.prototype super(message2) this.transport = transport this.errorType = 'DisabledTransportError' this.__proto__ = trueProto } } class FailedToStartTransportError extends Error { constructor(message2, transport) { const trueProto = new.target.prototype super(message2) this.transport = transport this.errorType = 'FailedToStartTransportError' this.__proto__ = trueProto } } class FailedToNegotiateWithServerError extends Error { constructor(message2) { const trueProto = new.target.prototype super(message2) this.errorType = 'FailedToNegotiateWithServerError' this.__proto__ = trueProto } } class AggregateErrors extends Error { constructor(message2, innerErrors) { const trueProto = new.target.prototype super(message2) this.innerErrors = innerErrors this.__proto__ = trueProto } } class HttpResponse { constructor(statusCode, statusText, content2) { this.statusCode = statusCode this.statusText = statusText this.content = content2 } } class HttpClient { get(url2, options2) { return this.send({ ...options2, method: 'GET', url: url2, }) } post(url2, options2) { return this.send({ ...options2, method: 'POST', url: url2, }) } delete(url2, options2) { return this.send({ ...options2, method: 'DELETE', url: url2, }) } getCookieString(url2) { return '' } } var LogLevel ;(function (LogLevel2) { LogLevel2[(LogLevel2['Trace'] = 0)] = 'Trace' LogLevel2[(LogLevel2['Debug'] = 1)] = 'Debug' LogLevel2[(LogLevel2['Information'] = 2)] = 'Information' LogLevel2[(LogLevel2['Warning'] = 3)] = 'Warning' LogLevel2[(LogLevel2['Error'] = 4)] = 'Error' LogLevel2[(LogLevel2['Critical'] = 5)] = 'Critical' LogLevel2[(LogLevel2['None'] = 6)] = 'None' })(LogLevel || (LogLevel = {})) class NullLogger { constructor() {} log(_logLevel, _message) {} } NullLogger.instance = new NullLogger() const VERSION$2 = '6.0.23' class Arg { static isRequired(val2, name2) { if (val2 === null || val2 === void 0) { throw new Error(`The '${name2}' argument is required.`) } } static isNotEmpty(val2, name2) { if (!val2 || val2.match(/^\s*$/)) { throw new Error(`The '${name2}' argument should not be empty.`) } } static isIn(val2, values2, name2) { if (!(val2 in values2)) { throw new Error(`Unknown ${name2} value: ${val2}.`) } } } class Platform { static get isBrowser() { return typeof window === 'object' && typeof window.document === 'object' } static get isWebWorker() { return typeof self === 'object' && 'importScripts' in self } static get isReactNative() { return typeof window === 'object' && typeof window.document === 'undefined' } static get isNode() { return !this.isBrowser && !this.isWebWorker && !this.isReactNative } } function getDataDetail(data2, includeContent) { let detail = '' if (isArrayBuffer(data2)) { detail = `Binary data of length ${data2.byteLength}` if (includeContent) { detail += `. Content: '${formatArrayBuffer(data2)}'` } } else if (typeof data2 === 'string') { detail = `String data of length ${data2.length}` if (includeContent) { detail += `. Content: '${data2}'` } } return detail } function formatArrayBuffer(data2) { const view2 = new Uint8Array(data2) let str = '' view2.forEach((num2) => { const pad3 = num2 < 16 ? '0' : '' str += `0x${pad3}${num2.toString(16)} ` }) return str.substr(0, str.length - 1) } function isArrayBuffer(val2) { return ( val2 && typeof ArrayBuffer !== 'undefined' && (val2 instanceof ArrayBuffer || (val2.constructor && val2.constructor.name === 'ArrayBuffer')) ) } async function sendMessage( logger, transportName, httpClient, url2, accessTokenFactory, content2, options2 ) { let headers = {} if (accessTokenFactory) { const token = await accessTokenFactory() if (token) { headers = { ['Authorization']: `Bearer ${token}`, } } } const [name2, value2] = getUserAgentHeader() headers[name2] = value2 logger.log( LogLevel.Trace, `(${transportName} transport) sending data. ${getDataDetail( content2, options2.logMessageContent )}.` ) const responseType = isArrayBuffer(content2) ? 'arraybuffer' : 'text' const response = await httpClient.post(url2, { content: content2, headers: { ...headers, ...options2.headers }, responseType, timeout: options2.timeout, withCredentials: options2.withCredentials, }) logger.log( LogLevel.Trace, `(${transportName} transport) request complete. Response status: ${response.statusCode}.` ) } function createLogger$1(logger) { if (logger === void 0) { return new ConsoleLogger(LogLevel.Information) } if (logger === null) { return NullLogger.instance } if (logger.log !== void 0) { return logger } return new ConsoleLogger(logger) } class SubjectSubscription { constructor(subject, observer) { this._subject = subject this._observer = observer } dispose() { const index2 = this._subject.observers.indexOf(this._observer) if (index2 > -1) { this._subject.observers.splice(index2, 1) } if (this._subject.observers.length === 0 && this._subject.cancelCallback) { this._subject.cancelCallback().catch((_2) => {}) } } } class ConsoleLogger { constructor(minimumLogLevel) { this._minLevel = minimumLogLevel this.out = console } log(logLevel, message2) { if (logLevel >= this._minLevel) { const msg = `[${new Date().toISOString()}] ${ LogLevel[logLevel] }: ${message2}` switch (logLevel) { case LogLevel.Critical: case LogLevel.Error: this.out.error(msg) break case LogLevel.Warning: this.out.warn(msg) break case LogLevel.Information: this.out.info(msg) break default: this.out.log(msg) break } } } } function getUserAgentHeader() { let userAgentHeaderName = 'X-SignalR-User-Agent' if (Platform.isNode) { userAgentHeaderName = 'User-Agent' } return [ userAgentHeaderName, constructUserAgent( VERSION$2, getOsName(), getRuntime(), getRuntimeVersion() ), ] } function constructUserAgent(version2, os, runtime, runtimeVersion) { let userAgent2 = 'Microsoft SignalR/' const majorAndMinor = version2.split('.') userAgent2 += `${majorAndMinor[0]}.${majorAndMinor[1]}` userAgent2 += ` (${version2}; ` if (os && os !== '') { userAgent2 += `${os}; ` } else { userAgent2 += 'Unknown OS; ' } userAgent2 += `${runtime}` if (runtimeVersion) { userAgent2 += `; ${runtimeVersion}` } else { userAgent2 += '; Unknown Runtime Version' } userAgent2 += ')' return userAgent2 } function getOsName() { if (Platform.isNode) { switch (process.platform) { case 'win32': return 'Windows NT' case 'darwin': return 'macOS' case 'linux': return 'Linux' default: return process.platform } } else { return '' } } function getRuntimeVersion() { if (Platform.isNode) { return process.versions.node } return void 0 } function getRuntime() { if (Platform.isNode) { return 'NodeJS' } else { return 'Browser' } } function getErrorString(e2) { if (e2.stack) { return e2.stack } else if (e2.message) { return e2.message } return `${e2}` } function getGlobalThis$1() { if (typeof globalThis !== 'undefined') { return globalThis } if (typeof self !== 'undefined') { return self } if (typeof window !== 'undefined') { return window } if (typeof global !== 'undefined') { return global } throw new Error('could not find global') } class FetchHttpClient extends HttpClient { constructor(logger) { super() this._logger = logger if (typeof fetch === 'undefined') { const requireFunc = typeof __webpack_require__ === 'function' ? __non_webpack_require__ : require this._jar = new (requireFunc('tough-cookie').CookieJar)() this._fetchType = requireFunc('node-fetch') this._fetchType = requireFunc('fetch-cookie')(this._fetchType, this._jar) } else { this._fetchType = fetch.bind(getGlobalThis$1()) } if (typeof AbortController === 'undefined') { const requireFunc = typeof __webpack_require__ === 'function' ? __non_webpack_require__ : require this._abortControllerType = requireFunc('abort-controller') } else { this._abortControllerType = AbortController } } async send(request3) { if (request3.abortSignal && request3.abortSignal.aborted) { throw new AbortError() } if (!request3.method) { throw new Error('No method defined.') } if (!request3.url) { throw new Error('No url defined.') } const abortController = new this._abortControllerType() let error2 if (request3.abortSignal) { request3.abortSignal.onabort = () => { abortController.abort() error2 = new AbortError() } } let timeoutId = null if (request3.timeout) { const msTimeout = request3.timeout timeoutId = setTimeout(() => { abortController.abort() this._logger.log(LogLevel.Warning, `Timeout from HTTP request.`) error2 = new TimeoutError() }, msTimeout) } let response try { response = await this._fetchType(request3.url, { body: request3.content, cache: 'no-cache', credentials: request3.withCredentials === true ? 'include' : 'same-origin', headers: { 'Content-Type': 'text/plain;charset=UTF-8', 'X-Requested-With': 'XMLHttpRequest', ...request3.headers, }, method: request3.method, mode: 'cors', redirect: 'follow', signal: abortController.signal, }) } catch (e2) { if (error2) { throw error2 } this._logger.log(LogLevel.Warning, `Error from HTTP request. ${e2}.`) throw e2 } finally { if (timeoutId) { clearTimeout(timeoutId) } if (request3.abortSignal) { request3.abortSignal.onabort = null } } if (!response.ok) { const errorMessage = await deserializeContent(response, 'text') throw new HttpError(errorMessage || response.statusText, response.status) } const content2 = deserializeContent(response, request3.responseType) const payload = await content2 return new HttpResponse(response.status, response.statusText, payload) } getCookieString(url2) { let cookies2 = '' if (Platform.isNode && this._jar) { this._jar.getCookies(url2, (e2, c2) => (cookies2 = c2.join('; '))) } return cookies2 } } function deserializeContent(response, responseType) { let content2 switch (responseType) { case 'arraybuffer': content2 = response.arrayBuffer() break case 'text': content2 = response.text() break case 'blob': case 'document': case 'json': throw new Error(`${responseType} is not supported.`) default: content2 = response.text() break } return content2 } class XhrHttpClient extends HttpClient { constructor(logger) { super() this._logger = logger } send(request3) { if (request3.abortSignal && request3.abortSignal.aborted) { return Promise.reject(new AbortError()) } if (!request3.method) { return Promise.reject(new Error('No method defined.')) } if (!request3.url) { return Promise.reject(new Error('No url defined.')) } return new Promise((resolve2, reject2) => { const xhr2 = new XMLHttpRequest() xhr2.open(request3.method, request3.url, true) xhr2.withCredentials = request3.withCredentials === void 0 ? true : request3.withCredentials xhr2.setRequestHeader('X-Requested-With', 'XMLHttpRequest') xhr2.setRequestHeader('Content-Type', 'text/plain;charset=UTF-8') const headers = request3.headers if (headers) { Object.keys(headers).forEach((header) => { xhr2.setRequestHeader(header, headers[header]) }) } if (request3.responseType) { xhr2.responseType = request3.responseType } if (request3.abortSignal) { request3.abortSignal.onabort = () => { xhr2.abort() reject2(new AbortError()) } } if (request3.timeout) { xhr2.timeout = request3.timeout } xhr2.onload = () => { if (request3.abortSignal) { request3.abortSignal.onabort = null } if (xhr2.status >= 200 && xhr2.status < 300) { resolve2( new HttpResponse( xhr2.status, xhr2.statusText, xhr2.response || xhr2.responseText ) ) } else { reject2( new HttpError( xhr2.response || xhr2.responseText || xhr2.statusText, xhr2.status ) ) } } xhr2.onerror = () => { this._logger.log( LogLevel.Warning, `Error from HTTP request. ${xhr2.status}: ${xhr2.statusText}.` ) reject2(new HttpError(xhr2.statusText, xhr2.status)) } xhr2.ontimeout = () => { this._logger.log(LogLevel.Warning, `Timeout from HTTP request.`) reject2(new TimeoutError()) } xhr2.send(request3.content || '') }) } } class DefaultHttpClient extends HttpClient { constructor(logger) { super() if (typeof fetch !== 'undefined' || Platform.isNode) { this._httpClient = new FetchHttpClient(logger) } else if (typeof XMLHttpRequest !== 'undefined') { this._httpClient = new XhrHttpClient(logger) } else { throw new Error('No usable HttpClient found.') } } send(request3) { if (request3.abortSignal && request3.abortSignal.aborted) { return Promise.reject(new AbortError()) } if (!request3.method) { return Promise.reject(new Error('No method defined.')) } if (!request3.url) { return Promise.reject(new Error('No url defined.')) } return this._httpClient.send(request3) } getCookieString(url2) { return this._httpClient.getCookieString(url2) } } class TextMessageFormat { static write(output) { return `${output}${TextMessageFormat.RecordSeparator}` } static parse(input) { if (input[input.length - 1] !== TextMessageFormat.RecordSeparator) { throw new Error('Message is incomplete.') } const messages2 = input.split(TextMessageFormat.RecordSeparator) messages2.pop() return messages2 } } TextMessageFormat.RecordSeparatorCode = 30 TextMessageFormat.RecordSeparator = String.fromCharCode( TextMessageFormat.RecordSeparatorCode ) class HandshakeProtocol { writeHandshakeRequest(handshakeRequest) { return TextMessageFormat.write(JSON.stringify(handshakeRequest)) } parseHandshakeResponse(data2) { let messageData let remainingData if (isArrayBuffer(data2)) { const binaryData = new Uint8Array(data2) const separatorIndex = binaryData.indexOf( TextMessageFormat.RecordSeparatorCode ) if (separatorIndex === -1) { throw new Error('Message is incomplete.') } const responseLength = separatorIndex + 1 messageData = String.fromCharCode.apply( null, Array.prototype.slice.call(binaryData.slice(0, responseLength)) ) remainingData = binaryData.byteLength > responseLength ? binaryData.slice(responseLength).buffer : null } else { const textData = data2 const separatorIndex = textData.indexOf(TextMessageFormat.RecordSeparator) if (separatorIndex === -1) { throw new Error('Message is incomplete.') } const responseLength = separatorIndex + 1 messageData = textData.substring(0, responseLength) remainingData = textData.length > responseLength ? textData.substring(responseLength) : null } const messages2 = TextMessageFormat.parse(messageData) const response = JSON.parse(messages2[0]) if (response.type) { throw new Error('Expected a handshake response from the server.') } const responseMessage = response return [remainingData, responseMessage] } } var MessageType ;(function (MessageType2) { MessageType2[(MessageType2['Invocation'] = 1)] = 'Invocation' MessageType2[(MessageType2['StreamItem'] = 2)] = 'StreamItem' MessageType2[(MessageType2['Completion'] = 3)] = 'Completion' MessageType2[(MessageType2['StreamInvocation'] = 4)] = 'StreamInvocation' MessageType2[(MessageType2['CancelInvocation'] = 5)] = 'CancelInvocation' MessageType2[(MessageType2['Ping'] = 6)] = 'Ping' MessageType2[(MessageType2['Close'] = 7)] = 'Close' })(MessageType || (MessageType = {})) class Subject { constructor() { this.observers = [] } next(item2) { for (const observer of this.observers) { observer.next(item2) } } error(err) { for (const observer of this.observers) { if (observer.error) { observer.error(err) } } } complete() { for (const observer of this.observers) { if (observer.complete) { observer.complete() } } } subscribe(observer) { this.observers.push(observer) return new SubjectSubscription(this, observer) } } const DEFAULT_TIMEOUT_IN_MS = 30 * 1e3 const DEFAULT_PING_INTERVAL_IN_MS = 15 * 1e3 var HubConnectionState ;(function (HubConnectionState2) { HubConnectionState2['Disconnected'] = 'Disconnected' HubConnectionState2['Connecting'] = 'Connecting' HubConnectionState2['Connected'] = 'Connected' HubConnectionState2['Disconnecting'] = 'Disconnecting' HubConnectionState2['Reconnecting'] = 'Reconnecting' })(HubConnectionState || (HubConnectionState = {})) class HubConnection { constructor(connection2, logger, protocol, reconnectPolicy) { this._nextKeepAlive = 0 this._freezeEventListener = () => { this._logger.log( LogLevel.Warning, 'The page is being frozen, this will likely lead to the connection being closed and messages being lost. For more information see the docs at https://docs.microsoft.com/aspnet/core/signalr/javascript-client#bsleep' ) } Arg.isRequired(connection2, 'connection') Arg.isRequired(logger, 'logger') Arg.isRequired(protocol, 'protocol') this.serverTimeoutInMilliseconds = DEFAULT_TIMEOUT_IN_MS this.keepAliveIntervalInMilliseconds = DEFAULT_PING_INTERVAL_IN_MS this._logger = logger this._protocol = protocol this.connection = connection2 this._reconnectPolicy = reconnectPolicy this._handshakeProtocol = new HandshakeProtocol() this.connection.onreceive = (data2) => this._processIncomingData(data2) this.connection.onclose = (error2) => this._connectionClosed(error2) this._callbacks = {} this._methods = {} this._closedCallbacks = [] this._reconnectingCallbacks = [] this._reconnectedCallbacks = [] this._invocationId = 0 this._receivedHandshakeResponse = false this._connectionState = HubConnectionState.Disconnected this._connectionStarted = false this._cachedPingMessage = this._protocol.writeMessage({ type: MessageType.Ping, }) } static create(connection2, logger, protocol, reconnectPolicy) { return new HubConnection(connection2, logger, protocol, reconnectPolicy) } get state() { return this._connectionState } get connectionId() { return this.connection ? this.connection.connectionId || null : null } get baseUrl() { return this.connection.baseUrl || '' } set baseUrl(url2) { if ( this._connectionState !== HubConnectionState.Disconnected && this._connectionState !== HubConnectionState.Reconnecting ) { throw new Error( 'The HubConnection must be in the Disconnected or Reconnecting state to change the url.' ) } if (!url2) { throw new Error('The HubConnection url must be a valid url.') } this.connection.baseUrl = url2 } start() { this._startPromise = this._startWithStateTransitions() return this._startPromise } async _startWithStateTransitions() { if (this._connectionState !== HubConnectionState.Disconnected) { return Promise.reject( new Error( "Cannot start a HubConnection that is not in the 'Disconnected' state." ) ) } this._connectionState = HubConnectionState.Connecting this._logger.log(LogLevel.Debug, 'Starting HubConnection.') try { await this._startInternal() if (Platform.isBrowser) { window.document.addEventListener('freeze', this._freezeEventListener) } this._connectionState = HubConnectionState.Connected this._connectionStarted = true this._logger.log(LogLevel.Debug, 'HubConnection connected successfully.') } catch (e2) { this._connectionState = HubConnectionState.Disconnected this._logger.log( LogLevel.Debug, `HubConnection failed to start successfully because of error '${e2}'.` ) return Promise.reject(e2) } } async _startInternal() { this._stopDuringStartError = void 0 this._receivedHandshakeResponse = false const handshakePromise = new Promise((resolve2, reject2) => { this._handshakeResolver = resolve2 this._handshakeRejecter = reject2 }) await this.connection.start(this._protocol.transferFormat) try { const handshakeRequest = { protocol: this._protocol.name, version: this._protocol.version, } this._logger.log(LogLevel.Debug, 'Sending handshake request.') await this._sendMessage( this._handshakeProtocol.writeHandshakeRequest(handshakeRequest) ) this._logger.log( LogLevel.Information, `Using HubProtocol '${this._protocol.name}'.` ) this._cleanupTimeout() this._resetTimeoutPeriod() this._resetKeepAliveInterval() await handshakePromise if (this._stopDuringStartError) { throw this._stopDuringStartError } } catch (e2) { this._logger.log( LogLevel.Debug, `Hub handshake failed with error '${e2}' during start(). Stopping HubConnection.` ) this._cleanupTimeout() this._cleanupPingTimer() await this.connection.stop(e2) throw e2 } } async stop() { const startPromise = this._startPromise this._stopPromise = this._stopInternal() await this._stopPromise try { await startPromise } catch (e2) {} } _stopInternal(error2) { if (this._connectionState === HubConnectionState.Disconnected) { this._logger.log( LogLevel.Debug, `Call to HubConnection.stop(${error2}) ignored because it is already in the disconnected state.` ) return Promise.resolve() } if (this._connectionState === HubConnectionState.Disconnecting) { this._logger.log( LogLevel.Debug, `Call to HttpConnection.stop(${error2}) ignored because the connection is already in the disconnecting state.` ) return this._stopPromise } this._connectionState = HubConnectionState.Disconnecting this._logger.log(LogLevel.Debug, 'Stopping HubConnection.') if (this._reconnectDelayHandle) { this._logger.log( LogLevel.Debug, 'Connection stopped during reconnect delay. Done reconnecting.' ) clearTimeout(this._reconnectDelayHandle) this._reconnectDelayHandle = void 0 this._completeClose() return Promise.resolve() } this._cleanupTimeout() this._cleanupPingTimer() this._stopDuringStartError = error2 || new Error( 'The connection was stopped before the hub handshake could complete.' ) return this.connection.stop(error2) } stream(methodName, ...args) { const [streams, streamIds] = this._replaceStreamingParams(args) const invocationDescriptor = this._createStreamInvocation( methodName, args, streamIds ) let promiseQueue const subject = new Subject() subject.cancelCallback = () => { const cancelInvocation = this._createCancelInvocation( invocationDescriptor.invocationId ) delete this._callbacks[invocationDescriptor.invocationId] return promiseQueue.then(() => { return this._sendWithProtocol(cancelInvocation) }) } this._callbacks[invocationDescriptor.invocationId] = ( invocationEvent, error2 ) => { if (error2) { subject.error(error2) return } else if (invocationEvent) { if (invocationEvent.type === MessageType.Completion) { if (invocationEvent.error) { subject.error(new Error(invocationEvent.error)) } else { subject.complete() } } else { subject.next(invocationEvent.item) } } } promiseQueue = this._sendWithProtocol(invocationDescriptor).catch((e2) => { subject.error(e2) delete this._callbacks[invocationDescriptor.invocationId] }) this._launchStreams(streams, promiseQueue) return subject } _sendMessage(message2) { this._resetKeepAliveInterval() return this.connection.send(message2) } _sendWithProtocol(message2) { return this._sendMessage(this._protocol.writeMessage(message2)) } send(methodName, ...args) { const [streams, streamIds] = this._replaceStreamingParams(args) const sendPromise = this._sendWithProtocol( this._createInvocation(methodName, args, true, streamIds) ) this._launchStreams(streams, sendPromise) return sendPromise } invoke(methodName, ...args) { const [streams, streamIds] = this._replaceStreamingParams(args) const invocationDescriptor = this._createInvocation( methodName, args, false, streamIds ) const p2 = new Promise((resolve2, reject2) => { this._callbacks[invocationDescriptor.invocationId] = ( invocationEvent, error2 ) => { if (error2) { reject2(error2) return } else if (invocationEvent) { if (invocationEvent.type === MessageType.Completion) { if (invocationEvent.error) { reject2(new Error(invocationEvent.error)) } else { resolve2(invocationEvent.result) } } else { reject2( new Error(`Unexpected message type: ${invocationEvent.type}`) ) } } } const promiseQueue = this._sendWithProtocol(invocationDescriptor).catch( (e2) => { reject2(e2) delete this._callbacks[invocationDescriptor.invocationId] } ) this._launchStreams(streams, promiseQueue) }) return p2 } on(methodName, newMethod) { if (!methodName || !newMethod) { return } methodName = methodName.toLowerCase() if (!this._methods[methodName]) { this._methods[methodName] = [] } if (this._methods[methodName].indexOf(newMethod) !== -1) { return } this._methods[methodName].push(newMethod) } off(methodName, method4) { if (!methodName) { return } methodName = methodName.toLowerCase() const handlers2 = this._methods[methodName] if (!handlers2) { return } if (method4) { const removeIdx = handlers2.indexOf(method4) if (removeIdx !== -1) { handlers2.splice(removeIdx, 1) if (handlers2.length === 0) { delete this._methods[methodName] } } } else { delete this._methods[methodName] } } onclose(callback) { if (callback) { this._closedCallbacks.push(callback) } } onreconnecting(callback) { if (callback) { this._reconnectingCallbacks.push(callback) } } onreconnected(callback) { if (callback) { this._reconnectedCallbacks.push(callback) } } _processIncomingData(data2) { this._cleanupTimeout() if (!this._receivedHandshakeResponse) { data2 = this._processHandshakeResponse(data2) this._receivedHandshakeResponse = true } if (data2) { const messages2 = this._protocol.parseMessages(data2, this._logger) for (const message2 of messages2) { switch (message2.type) { case MessageType.Invocation: this._invokeClientMethod(message2) break case MessageType.StreamItem: case MessageType.Completion: { const callback = this._callbacks[message2.invocationId] if (callback) { if (message2.type === MessageType.Completion) { delete this._callbacks[message2.invocationId] } try { callback(message2) } catch (e2) { this._logger.log( LogLevel.Error, `Stream callback threw error: ${getErrorString(e2)}` ) } } break } case MessageType.Ping: break case MessageType.Close: { this._logger.log( LogLevel.Information, 'Close message received from server.' ) const error2 = message2.error ? new Error( 'Server returned an error on close: ' + message2.error ) : void 0 if (message2.allowReconnect === true) { this.connection.stop(error2) } else { this._stopPromise = this._stopInternal(error2) } break } default: this._logger.log( LogLevel.Warning, `Invalid message type: ${message2.type}.` ) break } } } this._resetTimeoutPeriod() } _processHandshakeResponse(data2) { let responseMessage let remainingData try { ;[remainingData, responseMessage] = this._handshakeProtocol.parseHandshakeResponse(data2) } catch (e2) { const message2 = 'Error parsing handshake response: ' + e2 this._logger.log(LogLevel.Error, message2) const error2 = new Error(message2) this._handshakeRejecter(error2) throw error2 } if (responseMessage.error) { const message2 = 'Server returned handshake error: ' + responseMessage.error this._logger.log(LogLevel.Error, message2) const error2 = new Error(message2) this._handshakeRejecter(error2) throw error2 } else { this._logger.log(LogLevel.Debug, 'Server handshake complete.') } this._handshakeResolver() return remainingData } _resetKeepAliveInterval() { if (this.connection.features.inherentKeepAlive) { return } this._nextKeepAlive = new Date().getTime() + this.keepAliveIntervalInMilliseconds this._cleanupPingTimer() } _resetTimeoutPeriod() { if ( !this.connection.features || !this.connection.features.inherentKeepAlive ) { this._timeoutHandle = setTimeout( () => this.serverTimeout(), this.serverTimeoutInMilliseconds ) if (this._pingServerHandle === void 0) { let nextPing = this._nextKeepAlive - new Date().getTime() if (nextPing < 0) { nextPing = 0 } this._pingServerHandle = setTimeout(async () => { if (this._connectionState === HubConnectionState.Connected) { try { await this._sendMessage(this._cachedPingMessage) } catch { this._cleanupPingTimer() } } }, nextPing) } } } serverTimeout() { this.connection.stop( new Error( 'Server timeout elapsed without receiving a message from the server.' ) ) } _invokeClientMethod(invocationMessage) { const methods = this._methods[invocationMessage.target.toLowerCase()] if (methods) { try { methods.forEach((m2) => m2.apply(this, invocationMessage.arguments)) } catch (e2) { this._logger.log( LogLevel.Error, `A callback for the method ${invocationMessage.target.toLowerCase()} threw error '${e2}'.` ) } if (invocationMessage.invocationId) { const message2 = 'Server requested a response, which is not supported in this version of the client.' this._logger.log(LogLevel.Error, message2) this._stopPromise = this._stopInternal(new Error(message2)) } } else { this._logger.log( LogLevel.Warning, `No client method with the name '${invocationMessage.target}' found.` ) } } _connectionClosed(error2) { this._logger.log( LogLevel.Debug, `HubConnection.connectionClosed(${error2}) called while in state ${this._connectionState}.` ) this._stopDuringStartError = this._stopDuringStartError || error2 || new Error( 'The underlying connection was closed before the hub handshake could complete.' ) if (this._handshakeResolver) { this._handshakeResolver() } this._cancelCallbacksWithError( error2 || new Error( 'Invocation canceled due to the underlying connection being closed.' ) ) this._cleanupTimeout() this._cleanupPingTimer() if (this._connectionState === HubConnectionState.Disconnecting) { this._completeClose(error2) } else if ( this._connectionState === HubConnectionState.Connected && this._reconnectPolicy ) { this._reconnect(error2) } else if (this._connectionState === HubConnectionState.Connected) { this._completeClose(error2) } } _completeClose(error2) { if (this._connectionStarted) { this._connectionState = HubConnectionState.Disconnected this._connectionStarted = false if (Platform.isBrowser) { window.document.removeEventListener('freeze', this._freezeEventListener) } try { this._closedCallbacks.forEach((c2) => c2.apply(this, [error2])) } catch (e2) { this._logger.log( LogLevel.Error, `An onclose callback called with error '${error2}' threw error '${e2}'.` ) } } } async _reconnect(error2) { const reconnectStartTime = Date.now() let previousReconnectAttempts = 0 let retryError = error2 !== void 0 ? error2 : new Error('Attempting to reconnect due to a unknown error.') let nextRetryDelay = this._getNextRetryDelay( previousReconnectAttempts++, 0, retryError ) if (nextRetryDelay === null) { this._logger.log( LogLevel.Debug, 'Connection not reconnecting because the IRetryPolicy returned null on the first reconnect attempt.' ) this._completeClose(error2) return } this._connectionState = HubConnectionState.Reconnecting if (error2) { this._logger.log( LogLevel.Information, `Connection reconnecting because of error '${error2}'.` ) } else { this._logger.log(LogLevel.Information, 'Connection reconnecting.') } if (this._reconnectingCallbacks.length !== 0) { try { this._reconnectingCallbacks.forEach((c2) => c2.apply(this, [error2])) } catch (e2) { this._logger.log( LogLevel.Error, `An onreconnecting callback called with error '${error2}' threw error '${e2}'.` ) } if (this._connectionState !== HubConnectionState.Reconnecting) { this._logger.log( LogLevel.Debug, 'Connection left the reconnecting state in onreconnecting callback. Done reconnecting.' ) return } } while (nextRetryDelay !== null) { this._logger.log( LogLevel.Information, `Reconnect attempt number ${previousReconnectAttempts} will start in ${nextRetryDelay} ms.` ) await new Promise((resolve2) => { this._reconnectDelayHandle = setTimeout(resolve2, nextRetryDelay) }) this._reconnectDelayHandle = void 0 if (this._connectionState !== HubConnectionState.Reconnecting) { this._logger.log( LogLevel.Debug, 'Connection left the reconnecting state during reconnect delay. Done reconnecting.' ) return } try { await this._startInternal() this._connectionState = HubConnectionState.Connected this._logger.log( LogLevel.Information, 'HubConnection reconnected successfully.' ) if (this._reconnectedCallbacks.length !== 0) { try { this._reconnectedCallbacks.forEach((c2) => c2.apply(this, [this.connection.connectionId]) ) } catch (e2) { this._logger.log( LogLevel.Error, `An onreconnected callback called with connectionId '${this.connection.connectionId}; threw error '${e2}'.` ) } } return } catch (e2) { this._logger.log( LogLevel.Information, `Reconnect attempt failed because of error '${e2}'.` ) if (this._connectionState !== HubConnectionState.Reconnecting) { this._logger.log( LogLevel.Debug, `Connection moved to the '${this._connectionState}' from the reconnecting state during reconnect attempt. Done reconnecting.` ) if (this._connectionState === HubConnectionState.Disconnecting) { this._completeClose() } return } retryError = e2 instanceof Error ? e2 : new Error(e2.toString()) nextRetryDelay = this._getNextRetryDelay( previousReconnectAttempts++, Date.now() - reconnectStartTime, retryError ) } } this._logger.log( LogLevel.Information, `Reconnect retries have been exhausted after ${ Date.now() - reconnectStartTime } ms and ${previousReconnectAttempts} failed attempts. Connection disconnecting.` ) this._completeClose() } _getNextRetryDelay(previousRetryCount, elapsedMilliseconds, retryReason) { try { return this._reconnectPolicy.nextRetryDelayInMilliseconds({ elapsedMilliseconds, previousRetryCount, retryReason, }) } catch (e2) { this._logger.log( LogLevel.Error, `IRetryPolicy.nextRetryDelayInMilliseconds(${previousRetryCount}, ${elapsedMilliseconds}) threw error '${e2}'.` ) return null } } _cancelCallbacksWithError(error2) { const callbacks = this._callbacks this._callbacks = {} Object.keys(callbacks).forEach((key2) => { const callback = callbacks[key2] try { callback(null, error2) } catch (e2) { this._logger.log( LogLevel.Error, `Stream 'error' callback called with '${error2}' threw error: ${getErrorString( e2 )}` ) } }) } _cleanupPingTimer() { if (this._pingServerHandle) { clearTimeout(this._pingServerHandle) this._pingServerHandle = void 0 } } _cleanupTimeout() { if (this._timeoutHandle) { clearTimeout(this._timeoutHandle) } } _createInvocation(methodName, args, nonblocking, streamIds) { if (nonblocking) { if (streamIds.length !== 0) { return { arguments: args, streamIds, target: methodName, type: MessageType.Invocation, } } else { return { arguments: args, target: methodName, type: MessageType.Invocation, } } } else { const invocationId = this._invocationId this._invocationId++ if (streamIds.length !== 0) { return { arguments: args, invocationId: invocationId.toString(), streamIds, target: methodName, type: MessageType.Invocation, } } else { return { arguments: args, invocationId: invocationId.toString(), target: methodName, type: MessageType.Invocation, } } } } _launchStreams(streams, promiseQueue) { if (streams.length === 0) { return } if (!promiseQueue) { promiseQueue = Promise.resolve() } for (const streamId in streams) { streams[streamId].subscribe({ complete: () => { promiseQueue = promiseQueue.then(() => this._sendWithProtocol(this._createCompletionMessage(streamId)) ) }, error: (err) => { let message2 if (err instanceof Error) { message2 = err.message } else if (err && err.toString) { message2 = err.toString() } else { message2 = 'Unknown error' } promiseQueue = promiseQueue.then(() => this._sendWithProtocol( this._createCompletionMessage(streamId, message2) ) ) }, next: (item2) => { promiseQueue = promiseQueue.then(() => this._sendWithProtocol( this._createStreamItemMessage(streamId, item2) ) ) }, }) } } _replaceStreamingParams(args) { const streams = [] const streamIds = [] for (let i2 = 0; i2 < args.length; i2++) { const argument = args[i2] if (this._isObservable(argument)) { const streamId = this._invocationId this._invocationId++ streams[streamId] = argument streamIds.push(streamId.toString()) args.splice(i2, 1) } } return [streams, streamIds] } _isObservable(arg) { return arg && arg.subscribe && typeof arg.subscribe === 'function' } _createStreamInvocation(methodName, args, streamIds) { const invocationId = this._invocationId this._invocationId++ if (streamIds.length !== 0) { return { arguments: args, invocationId: invocationId.toString(), streamIds, target: methodName, type: MessageType.StreamInvocation, } } else { return { arguments: args, invocationId: invocationId.toString(), target: methodName, type: MessageType.StreamInvocation, } } } _createCancelInvocation(id2) { return { invocationId: id2, type: MessageType.CancelInvocation, } } _createStreamItemMessage(id2, item2) { return { invocationId: id2, item: item2, type: MessageType.StreamItem, } } _createCompletionMessage(id2, error2, result) { if (error2) { return { error: error2, invocationId: id2, type: MessageType.Completion, } } return { invocationId: id2, result, type: MessageType.Completion, } } } const DEFAULT_RETRY_DELAYS_IN_MILLISECONDS = [0, 2e3, 1e4, 3e4, null] class DefaultReconnectPolicy { constructor(retryDelays) { this._retryDelays = retryDelays !== void 0 ? [...retryDelays, null] : DEFAULT_RETRY_DELAYS_IN_MILLISECONDS } nextRetryDelayInMilliseconds(retryContext) { return this._retryDelays[retryContext.previousRetryCount] } } class HeaderNames {} HeaderNames.Authorization = 'Authorization' HeaderNames.Cookie = 'Cookie' var HttpTransportType ;(function (HttpTransportType2) { HttpTransportType2[(HttpTransportType2['None'] = 0)] = 'None' HttpTransportType2[(HttpTransportType2['WebSockets'] = 1)] = 'WebSockets' HttpTransportType2[(HttpTransportType2['ServerSentEvents'] = 2)] = 'ServerSentEvents' HttpTransportType2[(HttpTransportType2['LongPolling'] = 4)] = 'LongPolling' })(HttpTransportType || (HttpTransportType = {})) var TransferFormat ;(function (TransferFormat2) { TransferFormat2[(TransferFormat2['Text'] = 1)] = 'Text' TransferFormat2[(TransferFormat2['Binary'] = 2)] = 'Binary' })(TransferFormat || (TransferFormat = {})) class AbortController$1 { constructor() { this._isAborted = false this.onabort = null } abort() { if (!this._isAborted) { this._isAborted = true if (this.onabort) { this.onabort() } } } get signal() { return this } get aborted() { return this._isAborted } } class LongPollingTransport { constructor(httpClient, accessTokenFactory, logger, options2) { this._httpClient = httpClient this._accessTokenFactory = accessTokenFactory this._logger = logger this._pollAbort = new AbortController$1() this._options = options2 this._running = false this.onreceive = null this.onclose = null } get pollAborted() { return this._pollAbort.aborted } async connect(url2, transferFormat) { Arg.isRequired(url2, 'url') Arg.isRequired(transferFormat, 'transferFormat') Arg.isIn(transferFormat, TransferFormat, 'transferFormat') this._url = url2 this._logger.log(LogLevel.Trace, '(LongPolling transport) Connecting.') if ( transferFormat === TransferFormat.Binary && typeof XMLHttpRequest !== 'undefined' && typeof new XMLHttpRequest().responseType !== 'string' ) { throw new Error( 'Binary protocols over XmlHttpRequest not implementing advanced features are not supported.' ) } const [name2, value2] = getUserAgentHeader() const headers = { [name2]: value2, ...this._options.headers } const pollOptions = { abortSignal: this._pollAbort.signal, headers, timeout: 1e5, withCredentials: this._options.withCredentials, } if (transferFormat === TransferFormat.Binary) { pollOptions.responseType = 'arraybuffer' } const token = await this._getAccessToken() this._updateHeaderToken(pollOptions, token) const pollUrl = `${url2}&_=${Date.now()}` this._logger.log( LogLevel.Trace, `(LongPolling transport) polling: ${pollUrl}.` ) const response = await this._httpClient.get(pollUrl, pollOptions) if (response.statusCode !== 200) { this._logger.log( LogLevel.Error, `(LongPolling transport) Unexpected response code: ${response.statusCode}.` ) this._closeError = new HttpError( response.statusText || '', response.statusCode ) this._running = false } else { this._running = true } this._receiving = this._poll(this._url, pollOptions) } async _getAccessToken() { if (this._accessTokenFactory) { return await this._accessTokenFactory() } return null } _updateHeaderToken(request3, token) { if (!request3.headers) { request3.headers = {} } if (token) { request3.headers[HeaderNames.Authorization] = `Bearer ${token}` return } if (request3.headers[HeaderNames.Authorization]) { delete request3.headers[HeaderNames.Authorization] } } async _poll(url2, pollOptions) { try { while (this._running) { const token = await this._getAccessToken() this._updateHeaderToken(pollOptions, token) try { const pollUrl = `${url2}&_=${Date.now()}` this._logger.log( LogLevel.Trace, `(LongPolling transport) polling: ${pollUrl}.` ) const response = await this._httpClient.get(pollUrl, pollOptions) if (response.statusCode === 204) { this._logger.log( LogLevel.Information, '(LongPolling transport) Poll terminated by server.' ) this._running = false } else if (response.statusCode !== 200) { this._logger.log( LogLevel.Error, `(LongPolling transport) Unexpected response code: ${response.statusCode}.` ) this._closeError = new HttpError( response.statusText || '', response.statusCode ) this._running = false } else { if (response.content) { this._logger.log( LogLevel.Trace, `(LongPolling transport) data received. ${getDataDetail( response.content, this._options.logMessageContent )}.` ) if (this.onreceive) { this.onreceive(response.content) } } else { this._logger.log( LogLevel.Trace, '(LongPolling transport) Poll timed out, reissuing.' ) } } } catch (e2) { if (!this._running) { this._logger.log( LogLevel.Trace, `(LongPolling transport) Poll errored after shutdown: ${e2.message}` ) } else { if (e2 instanceof TimeoutError) { this._logger.log( LogLevel.Trace, '(LongPolling transport) Poll timed out, reissuing.' ) } else { this._closeError = e2 this._running = false } } } } } finally { this._logger.log( LogLevel.Trace, '(LongPolling transport) Polling complete.' ) if (!this.pollAborted) { this._raiseOnClose() } } } async send(data2) { if (!this._running) { return Promise.reject( new Error('Cannot send until the transport is connected') ) } return sendMessage( this._logger, 'LongPolling', this._httpClient, this._url, this._accessTokenFactory, data2, this._options ) } async stop() { this._logger.log( LogLevel.Trace, '(LongPolling transport) Stopping polling.' ) this._running = false this._pollAbort.abort() try { await this._receiving this._logger.log( LogLevel.Trace, `(LongPolling transport) sending DELETE request to ${this._url}.` ) const headers = {} const [name2, value2] = getUserAgentHeader() headers[name2] = value2 const deleteOptions = { headers: { ...headers, ...this._options.headers }, timeout: this._options.timeout, withCredentials: this._options.withCredentials, } const token = await this._getAccessToken() this._updateHeaderToken(deleteOptions, token) await this._httpClient.delete(this._url, deleteOptions) this._logger.log( LogLevel.Trace, '(LongPolling transport) DELETE request sent.' ) } finally { this._logger.log(LogLevel.Trace, '(LongPolling transport) Stop finished.') this._raiseOnClose() } } _raiseOnClose() { if (this.onclose) { let logMessage = '(LongPolling transport) Firing onclose event.' if (this._closeError) { logMessage += ' Error: ' + this._closeError } this._logger.log(LogLevel.Trace, logMessage) this.onclose(this._closeError) } } } class ServerSentEventsTransport { constructor(httpClient, accessTokenFactory, logger, options2) { this._httpClient = httpClient this._accessTokenFactory = accessTokenFactory this._logger = logger this._options = options2 this.onreceive = null this.onclose = null } async connect(url2, transferFormat) { Arg.isRequired(url2, 'url') Arg.isRequired(transferFormat, 'transferFormat') Arg.isIn(transferFormat, TransferFormat, 'transferFormat') this._logger.log(LogLevel.Trace, '(SSE transport) Connecting.') this._url = url2 if (this._accessTokenFactory) { const token = await this._accessTokenFactory() if (token) { url2 += (url2.indexOf('?') < 0 ? '?' : '&') + `access_token=${encodeURIComponent(token)}` } } return new Promise((resolve2, reject2) => { let opened = false if (transferFormat !== TransferFormat.Text) { reject2( new Error( "The Server-Sent Events transport only supports the 'Text' transfer format" ) ) return } let eventSource if (Platform.isBrowser || Platform.isWebWorker) { eventSource = new this._options.EventSource(url2, { withCredentials: this._options.withCredentials, }) } else { const cookies2 = this._httpClient.getCookieString(url2) const headers = {} headers.Cookie = cookies2 const [name2, value2] = getUserAgentHeader() headers[name2] = value2 eventSource = new this._options.EventSource(url2, { withCredentials: this._options.withCredentials, headers: { ...headers, ...this._options.headers }, }) } try { eventSource.onmessage = (e2) => { if (this.onreceive) { try { this._logger.log( LogLevel.Trace, `(SSE transport) data received. ${getDataDetail( e2.data, this._options.logMessageContent )}.` ) this.onreceive(e2.data) } catch (error2) { this._close(error2) return } } } eventSource.onerror = (e2) => { if (opened) { this._close() } else { reject2( new Error( 'EventSource failed to connect. The connection could not be found on the server, either the connection ID is not present on the server, or a proxy is refusing/buffering the connection. If you have multiple servers check that sticky sessions are enabled.' ) ) } } eventSource.onopen = () => { this._logger.log( LogLevel.Information, `SSE connected to ${this._url}` ) this._eventSource = eventSource opened = true resolve2() } } catch (e2) { reject2(e2) return } }) } async send(data2) { if (!this._eventSource) { return Promise.reject( new Error('Cannot send until the transport is connected') ) } return sendMessage( this._logger, 'SSE', this._httpClient, this._url, this._accessTokenFactory, data2, this._options ) } stop() { this._close() return Promise.resolve() } _close(e2) { if (this._eventSource) { this._eventSource.close() this._eventSource = void 0 if (this.onclose) { this.onclose(e2) } } } } class WebSocketTransport { constructor( httpClient, accessTokenFactory, logger, logMessageContent, webSocketConstructor, headers ) { this._logger = logger this._accessTokenFactory = accessTokenFactory this._logMessageContent = logMessageContent this._webSocketConstructor = webSocketConstructor this._httpClient = httpClient this.onreceive = null this.onclose = null this._headers = headers } async connect(url2, transferFormat) { Arg.isRequired(url2, 'url') Arg.isRequired(transferFormat, 'transferFormat') Arg.isIn(transferFormat, TransferFormat, 'transferFormat') this._logger.log(LogLevel.Trace, '(WebSockets transport) Connecting.') if (this._accessTokenFactory) { const token = await this._accessTokenFactory() if (token) { url2 += (url2.indexOf('?') < 0 ? '?' : '&') + `access_token=${encodeURIComponent(token)}` } } return new Promise((resolve2, reject2) => { url2 = url2.replace(/^http/, 'ws') let webSocket const cookies2 = this._httpClient.getCookieString(url2) let opened = false if (Platform.isNode) { const headers = {} const [name2, value2] = getUserAgentHeader() headers[name2] = value2 if (cookies2) { headers[HeaderNames.Cookie] = `${cookies2}` } webSocket = new this._webSocketConstructor(url2, void 0, { headers: { ...headers, ...this._headers }, }) } if (!webSocket) { webSocket = new this._webSocketConstructor(url2) } if (transferFormat === TransferFormat.Binary) { webSocket.binaryType = 'arraybuffer' } webSocket.onopen = (_event2) => { this._logger.log( LogLevel.Information, `WebSocket connected to ${url2}.` ) this._webSocket = webSocket opened = true resolve2() } webSocket.onerror = (event) => { let error2 = null if (typeof ErrorEvent !== 'undefined' && event instanceof ErrorEvent) { error2 = event.error } else { error2 = 'There was an error with the transport' } this._logger.log( LogLevel.Information, `(WebSockets transport) ${error2}.` ) } webSocket.onmessage = (message2) => { this._logger.log( LogLevel.Trace, `(WebSockets transport) data received. ${getDataDetail( message2.data, this._logMessageContent )}.` ) if (this.onreceive) { try { this.onreceive(message2.data) } catch (error2) { this._close(error2) return } } } webSocket.onclose = (event) => { if (opened) { this._close(event) } else { let error2 = null if ( typeof ErrorEvent !== 'undefined' && event instanceof ErrorEvent ) { error2 = event.error } else { error2 = 'WebSocket failed to connect. The connection could not be found on the server, either the endpoint may not be a SignalR endpoint, the connection ID is not present on the server, or there is a proxy blocking WebSockets. If you have multiple servers check that sticky sessions are enabled.' } reject2(new Error(error2)) } } }) } send(data2) { if ( this._webSocket && this._webSocket.readyState === this._webSocketConstructor.OPEN ) { this._logger.log( LogLevel.Trace, `(WebSockets transport) sending data. ${getDataDetail( data2, this._logMessageContent )}.` ) this._webSocket.send(data2) return Promise.resolve() } return Promise.reject('WebSocket is not in the OPEN state') } stop() { if (this._webSocket) { this._close(void 0) } return Promise.resolve() } _close(event) { if (this._webSocket) { this._webSocket.onclose = () => {} this._webSocket.onmessage = () => {} this._webSocket.onerror = () => {} this._webSocket.close() this._webSocket = void 0 } this._logger.log(LogLevel.Trace, '(WebSockets transport) socket closed.') if (this.onclose) { if ( this._isCloseEvent(event) && (event.wasClean === false || event.code !== 1e3) ) { this.onclose( new Error( `WebSocket closed with status code: ${event.code} (${ event.reason || 'no reason given' }).` ) ) } else if (event instanceof Error) { this.onclose(event) } else { this.onclose() } } } _isCloseEvent(event) { return ( event && typeof event.wasClean === 'boolean' && typeof event.code === 'number' ) } } const MAX_REDIRECTS = 100 class HttpConnection { constructor(url2, options2 = {}) { this._stopPromiseResolver = () => {} this.features = {} this._negotiateVersion = 1 Arg.isRequired(url2, 'url') this._logger = createLogger$1(options2.logger) this.baseUrl = this._resolveUrl(url2) options2 = options2 || {} options2.logMessageContent = options2.logMessageContent === void 0 ? false : options2.logMessageContent if ( typeof options2.withCredentials === 'boolean' || options2.withCredentials === void 0 ) { options2.withCredentials = options2.withCredentials === void 0 ? true : options2.withCredentials } else { throw new Error( "withCredentials option was not a 'boolean' or 'undefined' value" ) } options2.timeout = options2.timeout === void 0 ? 100 * 1e3 : options2.timeout let webSocketModule = null let eventSourceModule = null if (Platform.isNode && typeof require !== 'undefined') { const requireFunc = typeof __webpack_require__ === 'function' ? __non_webpack_require__ : require webSocketModule = requireFunc('ws') eventSourceModule = requireFunc('eventsource') } if ( !Platform.isNode && typeof WebSocket !== 'undefined' && !options2.WebSocket ) { options2.WebSocket = WebSocket } else if (Platform.isNode && !options2.WebSocket) { if (webSocketModule) { options2.WebSocket = webSocketModule } } if ( !Platform.isNode && typeof EventSource !== 'undefined' && !options2.EventSource ) { options2.EventSource = EventSource } else if (Platform.isNode && !options2.EventSource) { if (typeof eventSourceModule !== 'undefined') { options2.EventSource = eventSourceModule } } this._httpClient = options2.httpClient || new DefaultHttpClient(this._logger) this._connectionState = 'Disconnected' this._connectionStarted = false this._options = options2 this.onreceive = null this.onclose = null } async start(transferFormat) { transferFormat = transferFormat || TransferFormat.Binary Arg.isIn(transferFormat, TransferFormat, 'transferFormat') this._logger.log( LogLevel.Debug, `Starting connection with transfer format '${TransferFormat[transferFormat]}'.` ) if (this._connectionState !== 'Disconnected') { return Promise.reject( new Error( "Cannot start an HttpConnection that is not in the 'Disconnected' state." ) ) } this._connectionState = 'Connecting' this._startInternalPromise = this._startInternal(transferFormat) await this._startInternalPromise if (this._connectionState === 'Disconnecting') { const message2 = 'Failed to start the HttpConnection before stop() was called.' this._logger.log(LogLevel.Error, message2) await this._stopPromise return Promise.reject(new Error(message2)) } else if (this._connectionState !== 'Connected') { const message2 = "HttpConnection.startInternal completed gracefully but didn't enter the connection into the connected state!" this._logger.log(LogLevel.Error, message2) return Promise.reject(new Error(message2)) } this._connectionStarted = true } send(data2) { if (this._connectionState !== 'Connected') { return Promise.reject( new Error( "Cannot send data if the connection is not in the 'Connected' State." ) ) } if (!this._sendQueue) { this._sendQueue = new TransportSendQueue(this.transport) } return this._sendQueue.send(data2) } async stop(error2) { if (this._connectionState === 'Disconnected') { this._logger.log( LogLevel.Debug, `Call to HttpConnection.stop(${error2}) ignored because the connection is already in the disconnected state.` ) return Promise.resolve() } if (this._connectionState === 'Disconnecting') { this._logger.log( LogLevel.Debug, `Call to HttpConnection.stop(${error2}) ignored because the connection is already in the disconnecting state.` ) return this._stopPromise } this._connectionState = 'Disconnecting' this._stopPromise = new Promise((resolve2) => { this._stopPromiseResolver = resolve2 }) await this._stopInternal(error2) await this._stopPromise } async _stopInternal(error2) { this._stopError = error2 try { await this._startInternalPromise } catch (e2) {} if (this.transport) { try { await this.transport.stop() } catch (e2) { this._logger.log( LogLevel.Error, `HttpConnection.transport.stop() threw error '${e2}'.` ) this._stopConnection() } this.transport = void 0 } else { this._logger.log( LogLevel.Debug, 'HttpConnection.transport is undefined in HttpConnection.stop() because start() failed.' ) } } async _startInternal(transferFormat) { let url2 = this.baseUrl this._accessTokenFactory = this._options.accessTokenFactory try { if (this._options.skipNegotiation) { if (this._options.transport === HttpTransportType.WebSockets) { this.transport = this._constructTransport( HttpTransportType.WebSockets ) await this._startTransport(url2, transferFormat) } else { throw new Error( 'Negotiation can only be skipped when using the WebSocket transport directly.' ) } } else { let negotiateResponse = null let redirects = 0 do { negotiateResponse = await this._getNegotiationResponse(url2) if ( this._connectionState === 'Disconnecting' || this._connectionState === 'Disconnected' ) { throw new Error('The connection was stopped during negotiation.') } if (negotiateResponse.error) { throw new Error(negotiateResponse.error) } if (negotiateResponse.ProtocolVersion) { throw new Error( 'Detected a connection attempt to an ASP.NET SignalR Server. This client only supports connecting to an ASP.NET Core SignalR Server. See https://aka.ms/signalr-core-differences for details.' ) } if (negotiateResponse.url) { url2 = negotiateResponse.url } if (negotiateResponse.accessToken) { const accessToken = negotiateResponse.accessToken this._accessTokenFactory = () => accessToken } redirects++ } while (negotiateResponse.url && redirects < MAX_REDIRECTS) if (redirects === MAX_REDIRECTS && negotiateResponse.url) { throw new Error('Negotiate redirection limit exceeded.') } await this._createTransport( url2, this._options.transport, negotiateResponse, transferFormat ) } if (this.transport instanceof LongPollingTransport) { this.features.inherentKeepAlive = true } if (this._connectionState === 'Connecting') { this._logger.log( LogLevel.Debug, 'The HttpConnection connected successfully.' ) this._connectionState = 'Connected' } } catch (e2) { this._logger.log(LogLevel.Error, 'Failed to start the connection: ' + e2) this._connectionState = 'Disconnected' this.transport = void 0 this._stopPromiseResolver() return Promise.reject(e2) } } async _getNegotiationResponse(url2) { const headers = {} if (this._accessTokenFactory) { const token = await this._accessTokenFactory() if (token) { headers[HeaderNames.Authorization] = `Bearer ${token}` } } const [name2, value2] = getUserAgentHeader() headers[name2] = value2 const negotiateUrl = this._resolveNegotiateUrl(url2) this._logger.log( LogLevel.Debug, `Sending negotiation request: ${negotiateUrl}.` ) try { const response = await this._httpClient.post(negotiateUrl, { content: '', headers: { ...headers, ...this._options.headers }, timeout: this._options.timeout, withCredentials: this._options.withCredentials, }) if (response.statusCode !== 200) { return Promise.reject( new Error( `Unexpected status code returned from negotiate '${response.statusCode}'` ) ) } const negotiateResponse = JSON.parse(response.content) if ( !negotiateResponse.negotiateVersion || negotiateResponse.negotiateVersion < 1 ) { negotiateResponse.connectionToken = negotiateResponse.connectionId } return negotiateResponse } catch (e2) { let errorMessage = 'Failed to complete negotiation with the server: ' + e2 if (e2 instanceof HttpError) { if (e2.statusCode === 404) { errorMessage = errorMessage + ' Either this is not a SignalR endpoint or there is a proxy blocking the connection.' } } this._logger.log(LogLevel.Error, errorMessage) return Promise.reject(new FailedToNegotiateWithServerError(errorMessage)) } } _createConnectUrl(url2, connectionToken) { if (!connectionToken) { return url2 } return ( url2 + (url2.indexOf('?') === -1 ? '?' : '&') + `id=${connectionToken}` ) } async _createTransport( url2, requestedTransport, negotiateResponse, requestedTransferFormat ) { let connectUrl = this._createConnectUrl( url2, negotiateResponse.connectionToken ) if (this._isITransport(requestedTransport)) { this._logger.log( LogLevel.Debug, 'Connection was provided an instance of ITransport, using that directly.' ) this.transport = requestedTransport await this._startTransport(connectUrl, requestedTransferFormat) this.connectionId = negotiateResponse.connectionId return } const transportExceptions = [] const transports = negotiateResponse.availableTransports || [] let negotiate = negotiateResponse for (const endpoint of transports) { const transportOrError = this._resolveTransportOrError( endpoint, requestedTransport, requestedTransferFormat ) if (transportOrError instanceof Error) { transportExceptions.push(`${endpoint.transport} failed:`) transportExceptions.push(transportOrError) } else if (this._isITransport(transportOrError)) { this.transport = transportOrError if (!negotiate) { try { negotiate = await this._getNegotiationResponse(url2) } catch (ex) { return Promise.reject(ex) } connectUrl = this._createConnectUrl(url2, negotiate.connectionToken) } try { await this._startTransport(connectUrl, requestedTransferFormat) this.connectionId = negotiate.connectionId return } catch (ex) { this._logger.log( LogLevel.Error, `Failed to start the transport '${endpoint.transport}': ${ex}` ) negotiate = void 0 transportExceptions.push( new FailedToStartTransportError( `${endpoint.transport} failed: ${ex}`, HttpTransportType[endpoint.transport] ) ) if (this._connectionState !== 'Connecting') { const message2 = 'Failed to select transport before stop() was called.' this._logger.log(LogLevel.Debug, message2) return Promise.reject(new Error(message2)) } } } } if (transportExceptions.length > 0) { return Promise.reject( new AggregateErrors( `Unable to connect to the server with any of the available transports. ${transportExceptions.join( ' ' )}`, transportExceptions ) ) } return Promise.reject( new Error( 'None of the transports supported by the client are supported by the server.' ) ) } _constructTransport(transport) { switch (transport) { case HttpTransportType.WebSockets: if (!this._options.WebSocket) { throw new Error("'WebSocket' is not supported in your environment.") } return new WebSocketTransport( this._httpClient, this._accessTokenFactory, this._logger, this._options.logMessageContent, this._options.WebSocket, this._options.headers || {} ) case HttpTransportType.ServerSentEvents: if (!this._options.EventSource) { throw new Error("'EventSource' is not supported in your environment.") } return new ServerSentEventsTransport( this._httpClient, this._accessTokenFactory, this._logger, this._options ) case HttpTransportType.LongPolling: return new LongPollingTransport( this._httpClient, this._accessTokenFactory, this._logger, this._options ) default: throw new Error(`Unknown transport: ${transport}.`) } } _startTransport(url2, transferFormat) { this.transport.onreceive = this.onreceive this.transport.onclose = (e2) => this._stopConnection(e2) return this.transport.connect(url2, transferFormat) } _resolveTransportOrError( endpoint, requestedTransport, requestedTransferFormat ) { const transport = HttpTransportType[endpoint.transport] if (transport === null || transport === void 0) { this._logger.log( LogLevel.Debug, `Skipping transport '${endpoint.transport}' because it is not supported by this client.` ) return new Error( `Skipping transport '${endpoint.transport}' because it is not supported by this client.` ) } else { if (transportMatches(requestedTransport, transport)) { const transferFormats = endpoint.transferFormats.map( (s2) => TransferFormat[s2] ) if (transferFormats.indexOf(requestedTransferFormat) >= 0) { if ( (transport === HttpTransportType.WebSockets && !this._options.WebSocket) || (transport === HttpTransportType.ServerSentEvents && !this._options.EventSource) ) { this._logger.log( LogLevel.Debug, `Skipping transport '${HttpTransportType[transport]}' because it is not supported in your environment.'` ) return new UnsupportedTransportError( `'${HttpTransportType[transport]}' is not supported in your environment.`, transport ) } else { this._logger.log( LogLevel.Debug, `Selecting transport '${HttpTransportType[transport]}'.` ) try { return this._constructTransport(transport) } catch (ex) { return ex } } } else { this._logger.log( LogLevel.Debug, `Skipping transport '${HttpTransportType[transport]}' because it does not support the requested transfer format '${TransferFormat[requestedTransferFormat]}'.` ) return new Error( `'${HttpTransportType[transport]}' does not support ${TransferFormat[requestedTransferFormat]}.` ) } } else { this._logger.log( LogLevel.Debug, `Skipping transport '${HttpTransportType[transport]}' because it was disabled by the client.` ) return new DisabledTransportError( `'${HttpTransportType[transport]}' is disabled by the client.`, transport ) } } } _isITransport(transport) { return transport && typeof transport === 'object' && 'connect' in transport } _stopConnection(error2) { this._logger.log( LogLevel.Debug, `HttpConnection.stopConnection(${error2}) called while in state ${this._connectionState}.` ) this.transport = void 0 error2 = this._stopError || error2 this._stopError = void 0 if (this._connectionState === 'Disconnected') { this._logger.log( LogLevel.Debug, `Call to HttpConnection.stopConnection(${error2}) was ignored because the connection is already in the disconnected state.` ) return } if (this._connectionState === 'Connecting') { this._logger.log( LogLevel.Warning, `Call to HttpConnection.stopConnection(${error2}) was ignored because the connection is still in the connecting state.` ) throw new Error( `HttpConnection.stopConnection(${error2}) was called while the connection is still in the connecting state.` ) } if (this._connectionState === 'Disconnecting') { this._stopPromiseResolver() } if (error2) { this._logger.log( LogLevel.Error, `Connection disconnected with error '${error2}'.` ) } else { this._logger.log(LogLevel.Information, 'Connection disconnected.') } if (this._sendQueue) { this._sendQueue.stop().catch((e2) => { this._logger.log( LogLevel.Error, `TransportSendQueue.stop() threw error '${e2}'.` ) }) this._sendQueue = void 0 } this.connectionId = void 0 this._connectionState = 'Disconnected' if (this._connectionStarted) { this._connectionStarted = false try { if (this.onclose) { this.onclose(error2) } } catch (e2) { this._logger.log( LogLevel.Error, `HttpConnection.onclose(${error2}) threw error '${e2}'.` ) } } } _resolveUrl(url2) { if ( url2.lastIndexOf('https://', 0) === 0 || url2.lastIndexOf('http://', 0) === 0 ) { return url2 } if (!Platform.isBrowser) { throw new Error(`Cannot resolve '${url2}'.`) } const aTag = window.document.createElement('a') aTag.href = url2 this._logger.log( LogLevel.Information, `Normalizing '${url2}' to '${aTag.href}'.` ) return aTag.href } _resolveNegotiateUrl(url2) { const index2 = url2.indexOf('?') let negotiateUrl = url2.substring(0, index2 === -1 ? url2.length : index2) if (negotiateUrl[negotiateUrl.length - 1] !== '/') { negotiateUrl += '/' } negotiateUrl += 'negotiate' negotiateUrl += index2 === -1 ? '' : url2.substring(index2) if (negotiateUrl.indexOf('negotiateVersion') === -1) { negotiateUrl += index2 === -1 ? '?' : '&' negotiateUrl += 'negotiateVersion=' + this._negotiateVersion } return negotiateUrl } } function transportMatches(requestedTransport, actualTransport) { return !requestedTransport || (actualTransport & requestedTransport) !== 0 } class TransportSendQueue { constructor(_transport) { this._transport = _transport this._buffer = [] this._executing = true this._sendBufferedData = new PromiseSource() this._transportResult = new PromiseSource() this._sendLoopPromise = this._sendLoop() } send(data2) { this._bufferData(data2) if (!this._transportResult) { this._transportResult = new PromiseSource() } return this._transportResult.promise } stop() { this._executing = false this._sendBufferedData.resolve() return this._sendLoopPromise } _bufferData(data2) { if (this._buffer.length && typeof this._buffer[0] !== typeof data2) { throw new Error( `Expected data to be of type ${typeof this ._buffer} but was of type ${typeof data2}` ) } this._buffer.push(data2) this._sendBufferedData.resolve() } async _sendLoop() { while (true) { await this._sendBufferedData.promise if (!this._executing) { if (this._transportResult) { this._transportResult.reject('Connection stopped.') } break } this._sendBufferedData = new PromiseSource() const transportResult = this._transportResult this._transportResult = void 0 const data2 = typeof this._buffer[0] === 'string' ? this._buffer.join('') : TransportSendQueue._concatBuffers(this._buffer) this._buffer.length = 0 try { await this._transport.send(data2) transportResult.resolve() } catch (error2) { transportResult.reject(error2) } } } static _concatBuffers(arrayBuffers) { const totalLength = arrayBuffers .map((b2) => b2.byteLength) .reduce((a2, b2) => a2 + b2) const result = new Uint8Array(totalLength) let offset2 = 0 for (const item2 of arrayBuffers) { result.set(new Uint8Array(item2), offset2) offset2 += item2.byteLength } return result.buffer } } class PromiseSource { constructor() { this.promise = new Promise( (resolve2, reject2) => ([this._resolver, this._rejecter] = [resolve2, reject2]) ) } resolve() { this._resolver() } reject(reason) { this._rejecter(reason) } } const JSON_HUB_PROTOCOL_NAME = 'json' class JsonHubProtocol { constructor() { this.name = JSON_HUB_PROTOCOL_NAME this.version = 1 this.transferFormat = TransferFormat.Text } parseMessages(input, logger) { if (typeof input !== 'string') { throw new Error('Invalid input for JSON hub protocol. Expected a string.') } if (!input) { return [] } if (logger === null) { logger = NullLogger.instance } const messages2 = TextMessageFormat.parse(input) const hubMessages = [] for (const message2 of messages2) { const parsedMessage = JSON.parse(message2) if (typeof parsedMessage.type !== 'number') { throw new Error('Invalid payload.') } switch (parsedMessage.type) { case MessageType.Invocation: this._isInvocationMessage(parsedMessage) break case MessageType.StreamItem: this._isStreamItemMessage(parsedMessage) break case MessageType.Completion: this._isCompletionMessage(parsedMessage) break case MessageType.Ping: break case MessageType.Close: break default: logger.log( LogLevel.Information, "Unknown message type '" + parsedMessage.type + "' ignored." ) continue } hubMessages.push(parsedMessage) } return hubMessages } writeMessage(message2) { return TextMessageFormat.write(JSON.stringify(message2)) } _isInvocationMessage(message2) { this._assertNotEmptyString( message2.target, 'Invalid payload for Invocation message.' ) if (message2.invocationId !== void 0) { this._assertNotEmptyString( message2.invocationId, 'Invalid payload for Invocation message.' ) } } _isStreamItemMessage(message2) { this._assertNotEmptyString( message2.invocationId, 'Invalid payload for StreamItem message.' ) if (message2.item === void 0) { throw new Error('Invalid payload for StreamItem message.') } } _isCompletionMessage(message2) { if (message2.result && message2.error) { throw new Error('Invalid payload for Completion message.') } if (!message2.result && message2.error) { this._assertNotEmptyString( message2.error, 'Invalid payload for Completion message.' ) } this._assertNotEmptyString( message2.invocationId, 'Invalid payload for Completion message.' ) } _assertNotEmptyString(value2, errorMessage) { if (typeof value2 !== 'string' || value2 === '') { throw new Error(errorMessage) } } } const LogLevelNameMapping = { trace: LogLevel.Trace, debug: LogLevel.Debug, info: LogLevel.Information, information: LogLevel.Information, warn: LogLevel.Warning, warning: LogLevel.Warning, error: LogLevel.Error, critical: LogLevel.Critical, none: LogLevel.None, } function parseLogLevel(name2) { const mapping = LogLevelNameMapping[name2.toLowerCase()] if (typeof mapping !== 'undefined') { return mapping } else { throw new Error(`Unknown log level: ${name2}`) } } class HubConnectionBuilder { configureLogging(logging) { Arg.isRequired(logging, 'logging') if (isLogger(logging)) { this.logger = logging } else if (typeof logging === 'string') { const logLevel = parseLogLevel(logging) this.logger = new ConsoleLogger(logLevel) } else { this.logger = new ConsoleLogger(logging) } return this } withUrl(url2, transportTypeOrOptions) { Arg.isRequired(url2, 'url') Arg.isNotEmpty(url2, 'url') this.url = url2 if (typeof transportTypeOrOptions === 'object') { this.httpConnectionOptions = { ...this.httpConnectionOptions, ...transportTypeOrOptions, } } else { this.httpConnectionOptions = { ...this.httpConnectionOptions, transport: transportTypeOrOptions, } } return this } withHubProtocol(protocol) { Arg.isRequired(protocol, 'protocol') this.protocol = protocol return this } withAutomaticReconnect(retryDelaysOrReconnectPolicy) { if (this.reconnectPolicy) { throw new Error('A reconnectPolicy has already been set.') } if (!retryDelaysOrReconnectPolicy) { this.reconnectPolicy = new DefaultReconnectPolicy() } else if (Array.isArray(retryDelaysOrReconnectPolicy)) { this.reconnectPolicy = new DefaultReconnectPolicy( retryDelaysOrReconnectPolicy ) } else { this.reconnectPolicy = retryDelaysOrReconnectPolicy } return this } build() { const httpConnectionOptions = this.httpConnectionOptions || {} if (httpConnectionOptions.logger === void 0) { httpConnectionOptions.logger = this.logger } if (!this.url) { throw new Error( "The 'HubConnectionBuilder.withUrl' method must be called before building the connection." ) } const connection2 = new HttpConnection(this.url, httpConnectionOptions) return HubConnection.create( connection2, this.logger || NullLogger.instance, this.protocol || new JsonHubProtocol(), this.reconnectPolicy ) } } function isLogger(logger) { return logger.log !== void 0 } let clientType_id = `browser_${`${dayjs().format( 'YYYYMMDDHHmmssSSS' )}_${Math.random().toString(36).slice(2)}`}` let local_id = localStorage.getItem('local_id') let currentClientId_local = '' if (!local_id) { localStorage.setItem('local_id', clientType_id) currentClientId_local = clientType_id } else { currentClientId_local = local_id } class Socket { url = `/hubs/v1/variables?clientId=${currentClientId_local}` name = '\u53D8\u91CF\u670D\u52A1' connection callbackMap = /* @__PURE__ */ new Map() constructor(object4 = {}) { Object.assign(this, object4) this.connection = Socket.createConnection(this.url) Socket.lockWS() } call(...args) { this.connection.invoke(...args) } on(type4, callback, params2 = {}) { const connection2 = this.connection const callbackId = `callback_${Math.random().toString(32).slice(-8)}` const callbackInfo = { type: type4, params: params2, callbackId, } connection2.invoke('on', callbackInfo) connection2.on(callbackId, callback) this.callbackMap.set(callback, callbackInfo) return () => { this.off(type4, callback) } } useOn(...args) { const off2 = this.on(...args) onUnmounted(() => { this.off(args[0], args[1]) }) return off2 } off(type4, callback) { const connection2 = this.connection const callbackInfo = this.callbackMap.get(callback) if (!callbackInfo) return const callbackId = callbackInfo.callbackId connection2.invoke('off', callbackInfo) connection2.off(callbackId) this.callbackMap.delete(callback) } startCount = 0 async start() { if (this.startCount) return let resolve2 const promise2 = new Promise((r2) => (resolve2 = r2)) const self2 = this const singleToast = createSingleToast() const connection2 = this.connection const toast2 = function (...args) { if (args[2] !== -1) { singleToast(...args) } const methodMap = { warning: 'warn', error: 'error', } const method4 = methodMap[args[1]] || 'log' console[method4]('[Socket]', ...args) } const start2 = async () => { if (connection2.state !== 'Disconnected') return if (this.startCount) toast2( `${Language$1._t(self2.name)}\uFF1A${Language$1._t( '\u8FDE\u63A5\u5DF2\u65AD\u5F00\uFF0C\u91CD\u65B0\u8FDE\u63A5\u4E2D' )}...`, 'warning', 0 ) self2.startCount += 1 const first2 = this.startCount === 1 connection2 .start() .then(() => { if (first2) { toast2( `${Language$1._t(self2.name)}\uFF1A${Language$1._t( '\u8FDE\u63A5\u6210\u529F' )}`, 'success', -1 ) resolve2() } else { toast2( `${Language$1._t(self2.name)}\uFF1A${Language$1._t( '\u91CD\u65B0\u8FDE\u63A5\u6210\u529F' )}`, 'success' ) for (const [, callbackInfo] of this.callbackMap) { connection2.invoke('on', callbackInfo) } } }) .catch(() => { const delay2 = Math.min(this.startCount * 1e3, 1e4) toast2( `${Language$1._t(self2.name)}\uFF1A${Language$1._t( '\u8FDE\u63A5\u5931\u8D25' )}\uFF0C${delay2 / 1e3}${Language$1._t('s\u540E\u91CD\u8BD5')}`, 'error', 0 ) setTimeout(start2, delay2) }) } connection2.onclose(async () => { toast2( `${Language$1._t(self2.name)}\uFF1A${Language$1._t( '\u8FDE\u63A5\u5DF2\u65AD\u5F00' )}`, 'error', 0 ) await start2() }) await start2() return promise2 } static lockWS() { navigator.locks?.request('ws', { mode: 'shared' }, function () { return new Promise(() => {}) }) } static createConnection(url2) { const connection2 = new HubConnectionBuilder() .withUrl(`${baseURL}${url2}`) .configureLogging(LogLevel.Information) .build() return connection2 } } var __glob_0_13 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, Socket, }, Symbol.toStringTag, { value: 'Module' } ) ) class Variable extends Base { constructor(Ce = {}, Ee = app.current.project) { super(), (this.project = Ee) const _e = Variable.getByName(Ce.name, Ee), Be = _e || this return Object.assign(Be, Ce), _e || (Ee.variableMap[Be.name] = Be), Be } project collectStatus = !1 dataQuality _value oldValue /** 仅由后端推送时更新 */ serverValue updateTime = '' id = '' tunnelType = null // 变量通道类型 groupId = null // 变量组 name = '' description = '' type = NaN // 数据类型 typeName = '' // 数据类型名称 readWriteMode = 0 // 读写访问 archiveSetting = null // 历史归档配置 historicBriefMsg = null // 归档配置简要信息 historicGroupId = null // 归档关联的历史组id historicGroupName = null // 归档关联的历史组名称 // IO变量 address = '' interval = 1e3 // 采集间隔 collectMode = 0 // 采集模式 stringLength = null //字符长度 zoom = null // 缩放比 digit = null // 小数位数 readWriteRule = 1 // 读写规则 // 系统变量 scopeType = 0 // 变量作用域 // 内部变量 initType = 0 // 初始值类型 setValue = null // 初始值 // 逻辑变量 expression = null // 映射变量 mappingVariable = null // 访问变量 shareTag = null /** 更新属性,不触发下发 */ assign(Ce) { const Ee = { ...Ce } return ( 'value' in Ee && (Ee.value !== this._value && (Ee._value = Ee.value), delete Ee.value), Object.assign(this, Ee), this ) } get value() { return this._value } /** * 自动下发 */ set value(Ce) { this.set(Ce) } get() { return this._value } /** * 下发且同步更新本地 */ set(Ce) { Variable.applyPost(this, Ce, this.value), (this._value = Ce) } /** * 仅下发,不马上更新本地 * @param newValue */ post(Ce) { Variable.applyPost(this, Ce, this.value) } /** * 合并所有变量变更,统一下发 */ static postBufferMap = /* @__PURE__ */ new Map() /** * 收集变化 * @param variable * @param newValue */ static applyPost(Ce, Ee, _e) { let Be = Variable.postBufferMap.get(Ce.name) Be ? (Be.newValue = Ee) : ((Be = { variable: Ce, newValue: Ee, value: _e, }), Variable.postBufferMap.set(Ce.name, Be)), setTimeout(() => { const Ie = Variable.postBufferMap Ie.size && ((Variable.postBufferMap = /* @__PURE__ */ new Map()), Variable.post(Ie)) }) } /** * 下发,如果失败则恢复旧值 * @param map * @returns */ static post(Ce) { if (!Ce.size) return const Ee = {}, _e = {} for (const [Be, { newValue: Ie }] of Ce) (_e[Be] = Ie), (Ee[Be] = String(_e[Be])) request .post('/api/v1/variable/setvalues', Ee) .then((Be) => { let Ie = '' for (const Se in Be.items) { const xe = Be.items[Se] if (xe.quality) { Ie += `${Se}: ${xe.errorMsg || Language$1._t('下发失败')}` const Te = Ce.get(Se) if (Te) { const { variable: De, value: $e } = Te De._value = $e } } if (xe.quality == 0) { const Te = Ce.get(Se) if (Te) { const { variable: De, newValue: $e } = Te $e != xe.value && (De._value = xe.value) } } } Be.allSuccess || (console.error(Be), toast(Ie, 'error')) }) .catch(() => { for (const [, { variable: Be, value: Ie }] of Ce) Be._value = Ie }) } remove() { const Ce = this.project.variableMap delete Ce[this.name] } static get map() { return app.current.project.variableMap } static get valueMap() { return app.current.project.variableValueMap } static get oldValueMap() { return app.current.project.variableOldValueMap } static getByName(Ce, Ee = app.current.project) { return Ee.variableMap[Ce] } /** * 读写变量 * 仅下发,不更新本地 * 下发成功后,后端会重新推送过来才会更新本地 * @example * Variable.store.varName = 'varValue' */ static get store() { return new Proxy(Variable.valueMap, { get(Ce, Ee) { return Variable.getByName(Ee)?.value }, set(Ce, Ee, _e) { return new Variable({ name: Ee }).post(_e), !0 }, }) } /** * 读写变量 * 不下发,仅更新本地 */ static get _store() { return new Proxy(Variable.valueMap, { get(Ce, Ee) { return Variable.getByName(Ee)?.value }, set(Ce, Ee, _e) { const Be = new Variable({ name: Ee }) return (Be._value = _e), !0 }, }) } /** * 读写变量 * 下发,且同步更新本地 */ static get _store_() { return new Proxy(Variable.valueMap, { get(Ce, Ee) { return Variable.getByName(Ee)?.value }, set(Ce, Ee, _e) { const Be = new Variable({ name: Ee }) return (Be.value = _e), !0 }, }) } static socket /** * 启动变量监听 * {@link app} 创建完成后启动 * */ static async start() { const Ce = (this.socket = new Socket()), Ee = Ce.connection let _e const Be = new Promise((Te) => (_e = Te)) Ee.on( 'variablesChange', /** * @param data *``` { "System_Date": { "type": 11, "typeName": "日期", "tunnelType": 2, "config": { "scopeType": 0, "initType": 0, "setValue": null, "exitValue": null, "readWriteMode": 1 }, "description": "Variable:SysVarDesc:System_Date", "name": "System_Date", "collectStatus": true, "value": "2024/11/7 00:00:00", "dataQuality": 0, "updateTime": "2024-11-07T02:21:21.181Z" } } *``` */ (Te) => { Ie(Te) } ), Ee.on('OnReceivedAllVariablesChanged', (Te) => { Ie(Se(Te)) }), Ee.on('OnReceivedVariableChanged', (Te) => { Ie(Te) }) function Ie(Te) { xe(function () { for (const $e in Te) { const ke = Te[$e], Ve = new Variable({ name: $e }) 'value' in ke && ((ke.oldValue = Ve.value), (ke.serverValue = ke.value)), Ve.assign(ke) } _e(Te) }) } function Se(Te) { const De = {} for (const $e in Te) { const ke = Te[$e] if ('new' in ke) { const Ve = { name: ke.name, ...ke.new, dataQuality: ke.new?.dataQuality ?? void 0, } De[$e] = Ve } } return De } function xe(Te) { document.hidden ? Te() : requestAnimationFrame(() => { Te() }) } return await Ce.start(), Be } /** * 后端推送的类型不正确,临时转换处理 * @todo 后端处理正确后,应该去掉 * @param value * @returns */ static convertRemoteValue(Ce) { return ( Ce === 'True' && (Ce = !0), Ce === 'False' && (Ce = !1), Ce && typeof Ce == 'string' && !isNaN(Number(Ce)) && (Ce = Number(Ce)), Ce ) } static isVarName(Ce) { return Expression.isValidVariableName(Ce) } /** * 通过表达式求值 * @deprecated 请使用 {@link Expression} * @param code 表达式 * @returns 值 * @example * Variable.exp('m') * Variable.exp('m * n') * Variable.exp('m > n ? 1 : 0') */ static exp(Ce) { return console.warn('Variable.exp 已弃用'), Expression.getValue(Ce) } /** * 监听表达式的值的变化 * @deprecated 请使用 {@link Expression} */ static watchExp(Ce, Ee) { return new Expression(Ce).watch(Ee) } /** * 表达式输入框tooltip提示 * @deprecated 请使用 {@link Expression} */ static get expTitleTip() { return Expression.inputTip } /** * 数据类型 */ static types = { 0: { code: 'binary', label: '二进制变量', classify: '二进制', }, 1: { code: 'int8', label: '有符号8位整型', classify: '整型', }, 2: { code: 'uint8', label: '无符号8位整型', classify: '整型', }, 3: { code: 'int16', label: '有符号16位整型', classify: '整型', }, 4: { code: 'uint16', label: '无符号16位整型', classify: '整型', }, 5: { code: 'int32', label: '有符号32位整型', classify: '整型', }, 6: { code: 'uint32', label: '无符号32位整型', classify: '整型', }, 7: { code: 'int64', label: '有符号64位整型', classify: '整型', }, 8: { code: 'uint64', label: '无符号64位整型', classify: '整型', }, 9: { code: 'float32', label: 'F32位浮点数IEEE754', classify: '浮点型', }, 10: { code: 'float64', label: 'F64位浮点数IEEE754', classify: '浮点型', }, 11: { code: 'date', label: '日期', classify: '时间', }, 12: { code: 'time', label: '时间', classify: '时间', }, 13: { code: 'datetime', label: '日期时间', classify: '时间', }, 14: { code: 'string', label: '字符串', classify: '字符串', }, 15: { code: 'wstring', label: '宽字符串', classify: '字符串', }, 16: { code: 'str8', label: '文本变量8位字符集', classify: '字符串', }, 17: { code: 'str16', label: '文本变量16位字符集', classify: '字符串', }, 18: { code: 'timer', label: '定时器', classify: '整型', }, 19: { code: 'ASCII', label: 'ASCII字符集', classify: '字符串', }, } /** * 数据类型分类 */ static typeClassify = { 二进制: 0, 整型: 1, 浮点型: 2, 字符串: 3, 时间: 4, } /** * 分类下数据类型 */ static get typeClassifyMap() { const Ce = {} for (let [Ee, _e] of Object.entries(Variable.types)) { const Be = _e.classify Ce[Be] || (Ce[Be] = { value: Variable.typeClassify[Be], types: [], labels: [], codes: [], }), Ce[Be].types.push(Number(Ee)), Ce[Be].labels.push(_e.label), Ce[Be].codes.push(_e.code) } return Ce } /** * 通过code获取字符label * @param code 字符code * @returns */ static getLabelByCode(Ce) { const Ee = Object.values(Variable.types).find((_e) => _e.code === Ce) return Ee && Ee.label } /** * 根据变量名判断变量是否存在 * @param name string * @returns variable[] */ static async isVariableByName(Ce) { return ( await request({ url: '/api/v1/variable/query', method: 'get', params: { keyword: Ce, keywordOnlySearchName: !0, }, silent: !0, }) ).result } // 变量通道类型 static tunnelTypes = { 1: '外部变量', 2: '系统变量', 3: '内部变量', 4: '逻辑变量', 5: 'I/O映射', 6: 'CMS站点', } /** * 获取变量通道类型 * @param tunnelType Variable['tunnelType'] * @returns string */ static getTunnelName(Ce) { return Ce === null ? '' : Variable.tunnelTypes[Ce] || '' } /** * 判断某分类下数据类型 * @param classifyKey 数据类型分类 key * @param type 数据类型 key * @param label 数据类型 label 值 * @param code 数据类型 code 值 * @example * Variable.checkTypeClassify('整型', {type: 2}) * Variable.checkTypeClassify(['整型','浮点型'], {type: 2}) */ static checkTypeClassify(Ce, Ee = {}) { let _e = !1 for (let [Be, Ie] of Object.entries(Ee)) if (Ie !== void 0) { _e = (typeof Ce == 'string' ? [Ce] : Ce) .reduce( (Te, De) => Te.concat(Variable.typeClassifyMap[De][`${Be}s`]), [] ) .includes(Ie) break } return _e } /** * 判断是否是二进制 */ static isBinaryType(Ce = {}) { return Variable.checkTypeClassify('二进制', Ce) } /** * 判断是否是int类型 */ static isIntType(Ce = {}) { return Variable.checkTypeClassify('整型', Ce) } /** * 判断是否是浮点型 */ static isFloatType(Ce = {}) { return Variable.checkTypeClassify('浮点型', Ce) } /** * 判断是否是字符串 */ static isStringType(Ce = {}) { return Variable.checkTypeClassify('字符串', Ce) } /** * 判断是否是时间 */ static isTimeType(Ce = {}) { return Variable.checkTypeClassify('时间', Ce) } /** * 判断是否是数字 */ static isNumberType(Ce = {}) { return Variable.checkTypeClassify(['整型', '浮点型'], Ce) } /** * 读写访问 */ static readWriteModeTypes = { 0: '读写', 1: '只读', 2: '只写', } /** * 读写规则 */ static readWriteRuleTypes = { 1: '舍位取数', 2: '四舍五入', 3: '进位取数', } /** * 初始值类型 */ static InitTypeTypes = { 1: '设定值', 2: '保存值', 0: '无', } /** * 变量作用域 */ static scopeTypeTypes = { 0: '服务端', 1: '客户端', } /** * 采集模式 */ static collectModes = { 1: '页面使用', // 被动采集,页面模式 0: '服务运行', // 主动采集,服务模式 } } var __glob_0_14 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, Variable, }, Symbol.toStringTag, { value: 'Module' } ) ) class Expression extends Base { constructor(expression = {}) { if (typeof expression === 'string') { expression = { code: expression } } super() Object.assign(this, expression) } code = '' toString() { return this.code } toValue(throwError2 = false) { return Expression.getValue(this.code, throwError2) } watch(callback) { const unWatch = watch$1(() => this.toValue(), callback) return unWatch } static get $vars() { return app.current.project.variableValueMap } static TOKEN_REG = /(["'`])((\\.|[^])*?)(\1)|(\/\/)(.*)|(\/\*)([^]*?)(\*\/)|(\.\s*)?([^`~!@#%^&*()\-=+[{}\];:'"\\|,<.>/?\s]+)/g static codeFunctionCache = /* @__PURE__ */ new Map() static inputTip = `\u5B57\u7B26\u4E32\u4F7F\u7528\u82F1\u6587\u5F15\u53F7 "str" 'str'` static getValue(code2, throwError2 = false, $vars = Expression.$vars) { let fn2 = Expression.codeFunctionCache.get(code2) try { if (!fn2) { fn2 = Function( ` var $vars = arguments[0] var __vs__ = $vars with($vars) { return (function(){ "use strict" return (${code2}) })() } ` ) Expression.codeFunctionCache.set(code2, fn2) } var value2 = fn2($vars) return value2 } catch (error2) { if (throwError2) { throw error2 } } } static getVars(code2) { let tokens = code2.match(Expression.TOKEN_REG) || [] let vars = tokens.filter((v4) => Variable.isVarName(v4)) vars = [...new Set(vars)] return vars } static isValidVariableName(name2) { try { return Function(name2, `return ${name2}==="${name2}"`)(name2) } catch { return false } } static isValid(code2 = '') { try { Function(`return (${code2})`) return true } catch (error2) { return false } } static string(text2) { return this.wrapQuotes(text2) } static wrapQuotes(text2) { return `"${text2.replace(/['"`\\\s]/g, '\\$&')}"` } static unwrapQuotes(code2) { if (/^['"`]/.test(code2)) { return Expression.getValue(code2) ?? code2 } return code2 } static valueToCode(value2) { if (value2 === void 0) return 'undefined' try { return JSON.stringify(value2) } catch (error2) { console.error(`valueToCode error\uFF1A${error2}, value\uFF1A${value2}`) return 'undefined' } } static inputToValue(input, type4) { if (type4 === 'boolean') { if (input === 'true' || input === '1') { return true } if (input === 'false' || input === '0') { return false } } if (type4 === 'number') { let val2 = Number(input) if (!isNaN(val2)) { return val2 } } return input } } var __glob_0_6 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, Expression, }, Symbol.toStringTag, { value: 'Module' } ) ) const wm = /* @__PURE__ */ new WeakMap() class Block extends Base { class = this.constructor.class children = [] id = utils.createRandomId() get isExpand() { let rs2 = wm.get(this)?.expand || false return rs2 } set isExpand(bool2) { const privateMembers = wm.get(this) || {} privateMembers.expand = bool2 wm.set(this, privateMembers) for (const child of this.children) { child.isExpand = bool2 } } constructor(object4 = {}) { super() if (this.constructor === Block) { let block if (object4.class === OnBlock.class) { block = new OnBlock(object4) block.event = new EventBlock(object4.event) } if (object4.class === IfBlock.class) { block = new IfBlock(object4) } if (object4.class === CallBlock.class) { block = new CallBlock(object4) } if (!block) { console.error('[Block] unknown', object4) block = this } for (const [i2, child] of (object4.children || []).entries()) { block.children[i2] = new Block(child) } return block } } static createArray(objectArray) { for (const [i2, object4] of objectArray.entries()) { objectArray[i2] = new Block(object4) } return objectArray } static codeToValue(code2) { try { return Function(`return ${code2}`)() } catch (error2) { console.error(`codeToValue error\uFF1A${error2}, code\uFF1A${code2}`) } } static valueToCode(value2) { if (value2 === void 0) return 'undefined' try { return JSON.stringify(value2) } catch (error2) { console.error(`valueToCode error\uFF1A${error2}, value\uFF1A${value2}`) return 'undefined' } } static fixValue(value2) { try { return Function(`return ${value2}`)() } catch (error2) { return value2 } } toCode() { return '' } } class OnBlock extends Block { static class = 'OnBlock' event = new EventBlock() isEnable = true _onProps constructor(object4 = {}) { super() Object.assign(this, object4) } toJSON() { return { ...this, _onProps: void 0, } } toCode() { return ` ${this.children.map((c2) => c2.toCode()).join('\n')} ` } getCallback() { const f2 = Expression.getValue( ` async function(event){ ${this.toCode()} } `, true ) return f2 } getCallbackCatch() { const self2 = this async function fCatch(event = {}) { let f2 try { f2 = self2.getCallback() await f2(event) } catch (error2) { toast( `${Language$1._t('\u4E8B\u4EF6\u914D\u7F6E\u6709\u8BEF')}\uFF1A` + error2, 'warning' ) console.error( '\u4E8B\u4EF6\u914D\u7F6E\u6709\u8BEF\uFF1A', error2, '\n', f2 || self2.toCode(), '\n', self2 ) } } return fCatch } getOnProp() { if (this._onProps) { return this._onProps } const onProps = {} const type4 = this.event.type const Type2 = type4.replace(/^./, ($2) => $2.toUpperCase()) const Capture = ['focus', 'blur'].includes(type4) ? `Capture` : '' const onType = `on${Type2}${Capture}` const callback = this.getCallbackCatch() onProps[onType] = callback if (onProps.onMounted) { onProps.onVnodeMounted = onProps.onMounted } if (onProps.onUnmounted) { onProps.onVnodeUnmounted = onProps.onUnmounted } if (type4 === 'broadcast') { const broadcastCallback = (e2) => { if (!(e2 instanceof CustomEvent)) return const message2 = e2.detail const expression = this.event.detail.expression || 'undefined' const value2 = Expression.getValue(expression, true) if (value2 === message2) { callback() } } onProps.onVnodeMounted = function () { addEventListener('broadcast', broadcastCallback) } onProps.onVnodeUnmounted = function () { removeEventListener('broadcast', broadcastCallback) } } if (type4 === EventBlock.types.variable) { const callback2 = this.getCallbackCatch() const expression = this.event.detail.expression || 'undefined' let condition2 = this.event.detail.condition ?? 0 let firstError = true let value2 = void 0 let lastValue = Expression.getValue(expression) const ifCallback = { 0() {}, 1() { if (!!value2 !== !!lastValue && value2) { callback2() } }, 2() { if (!!value2 !== !!lastValue && !value2) { callback2() } }, 3() { if (value2 !== lastValue) { callback2() } }, 4() { if (!!value2 !== !!lastValue) { callback2() } }, }[condition2] let lastVariableChangeFlag = Variable.state.variableChangeFlag const variableCallback = () => { if (lastVariableChangeFlag === Variable.state.variableChangeFlag) { return } lastVariableChangeFlag = Variable.state.variableChangeFlag try { value2 = Expression.getValue(expression, true) ifCallback() lastValue = value2 } catch (error2) { toast(String(error2), 'warning') if (firstError) { firstError = false console.error(error2) } } } let off2 onProps.onVnodeMounted = function () { off2 = watchEffect(variableCallback) } onProps.onVnodeUnmounted = function () { off2() } } if (type4 === EventBlock.types.timer) { const callback2 = this.getCallbackCatch() const detail = this.event.detail let timer2 onProps.onVnodeMounted = function () { timer2 = app.dataeventSocket.on('BeginInterval', callback2, { startTime: new Date(detail.start), interval: detail.frequency, intervalType: detail.unit, endTime: detail.end === '' ? null : new Date(detail.end), }) } onProps.onVnodeUnmounted = function () { timer2?.() } } if (type4 === EventBlock.types.alarm) { const callback2 = this.getCallbackCatch() const detail = this.event.detail let alarmTimer = [] onProps.onVnodeMounted = function () { detail.checkedList.forEach((item2) => { let offTimer = app.dataeventSocket.on('BeginAlarmEvent', callback2, { alarmPointID: item2, }) alarmTimer.push(offTimer) }) } onProps.onVnodeUnmounted = function () { alarmTimer.forEach((timer2) => { timer2() }) } } if (type4 === EventBlock.types.alarmRecovery) { const callback2 = this.getCallbackCatch() const detail = this.event.detail let alarmRecovery onProps.onVnodeMounted = function () { alarmRecovery = app.dataeventSocket.on('BeginAlarmsEvent', callback2, { alarmPointIDs: detail.checkedList, all: detail.triggerType === 1, }) } onProps.onVnodeUnmounted = function () { alarmRecovery?.() } } this._onProps = onProps return onProps } static getOnPropList(onBlockList) { const onPropList = [] for (const onBlock of onBlockList) { if (onBlock instanceof OnBlock) { onPropList.push(onBlock.getOnProp()) } else { console.warn('!(onBlock instanceof OnBlock)', OnBlock) } } return onPropList } static getBlockById(id2) { const loop = (CanvasNodeList2) => { for (const canvasNode of CanvasNodeList2) { for (const block of canvasNode.blocks) { if (id2 === block.id) { return block } } const rs2 = loop(canvasNode.children) if (rs2) { return rs2 } } } return loop(app.current.project.current.page.document.body.children) } } class EventBlock extends Block { static class = 'EventBlock' static types = { click: 'click', dblclick: 'dblclick', contextmenu: 'contextmenu', mousedown: 'mousedown', mouseup: 'mouseup', mouseenter: 'mouseenter', mouseleave: 'mouseleave', focus: 'focus', blur: 'blur', change: 'change', mouselongpress: 'mouselongpress', hover: 'hover', timer: 'timer', variable: 'variable', alarm: 'alarm', alarmRecovery: 'alarmRecovery', broadcast: 'broadcast', mounted: 'mounted', unmounted: 'unmounted', __DIVISION__: '__DIVISION__', clickCell: 'clickCell', } static triggerDiyNameEventList = [ EventBlock.types.__DIVISION__, EventBlock.types.variable, EventBlock.types.broadcast, ] type = EventBlock.types.click name = '\u9F20\u6807\u5355\u51FB' detail = {} arguments = [] eventCategory = 'CanvasNodeBlock' isPrivateEvent = false supportActionType = { CanvasNodeBlock: true, PageManagerBlock: true, ProjectBlock: true, onlyOneSelf: false, } constructor(object4 = {}) { super() Object.assign(this, object4) } toCode() { if (!this.detail) return `` return `${this.detail?.expression}` } } class IfBlock extends Block { static class = 'IfBlock' expression = 'true' constructor(object4 = {}) { super() Object.assign(this, object4) } toCode() { return ` if( ${String(this.expression) || 'false'} ){ ${this.children.map((c2) => c2.toCode()).join('\n')} }` } } class CallBlock extends Block { static class = 'CallBlock' object method = '' name = '' arguments = [] constructor(object4 = {}) { super() Object.assign(this, object4) this.object && (this.object = new ObjectBlock(this.object)) for (const [i2, arg] of this.arguments.entries()) { this.arguments[i2] = new ArgumentBlock(arg) } } toCode() { if (!this.method) return '' if ( this.object?.class === 'ProjectBlock' && this.method === 'setVariable' ) { return ` ${Expression.unwrapQuotes( this.arguments[0].expression )} = ${this.arguments[1].toCode()} ` } return ` await __call__( "${this.object?.class}", "${this.object?.id}", "${this.method}", [${this.arguments.map((a2) => a2.toCode()).join(', ')}] ) ` } static objectClassMap = { Project: 'Project', Page: 'Page', CanvasNode: 'CanvasNode', } static async __call__(blockClass, id2, method4, args) { try { const model = ObjectBlock.findModel(blockClass, id2) const fn2 = model.methods?.[method4] || model[method4] const rs2 = fn2.apply(model, args) CallBlock.__call__.rs = rs2 return rs2 } catch (error2) { console.error(arguments) console.error(error2) } } static MAX_DURATION = 1e4 static _callCount = 0 static macroTaskStart static callErrorTipShowing = false static async checkCallError() { CallBlock._callCount += 1 const now2 = new Date() await Promise.resolve() if (!CallBlock.macroTaskStart) { CallBlock.macroTaskStart = now2 setTimeout(() => { CallBlock.macroTaskStart = void 0 }) postMessage('') addEventListener('message', function f2() { removeEventListener('message', f2) CallBlock.macroTaskStart = void 0 }) } if ( now2.getTime() - CallBlock.macroTaskStart.getTime() > CallBlock.MAX_DURATION ) { if (!CallBlock.callErrorTipShowing) { toast( Language$1._t( '\u68C0\u6D4B\u5230\u4E8B\u4EF6\u6267\u884C\u5361\u6B7B\uFF0C\u8BF7\u68C0\u67E5\u903B\u8F91\u91CD\u65B0\u914D\u7F6E' ), 'error', 0 ) CallBlock.callErrorTipShowing = true setTimeout(() => { CallBlock.callErrorTipShowing = false }, 0) } return true } return false } } window.__call__ = CallBlock.__call__ class MethodBlock extends Block { object = '' type = '' name = '' method = '' arguments = [] constructor(obj = {}) { super() obj = JSON.parse(JSON.stringify(obj)) Object.assign(this, obj) for (const [i2, child] of this.arguments.entries()) { this.arguments[i2] = new ArgumentBlock(child) } } cloneNode() { const nodeNew = new MethodBlock(this) function cloneId(node2) { node2.id = String(node2.id).replace( /\|.*?$/, `|${Math.random().toString(32).slice(-6)}` ) for (const child of node2.children) { cloneId(child) } } cloneId(nodeNew) return nodeNew } } class ArgumentBlock extends Block { static class = 'ArgumentBlock' static types = { string: 'string', number: 'number', boolean: 'boolean', Array: 'Array', Object: 'Object', } static views = { text: 'text', number: 'number', date: 'date', slide: 'slide', switch: 'switch', radio: 'radio', checkbox: 'checkbox', select: 'select', color: 'color', image: 'image', variableName: 'variableName', page: 'page', charts: 'charts', currentPage: 'currentPage', file: 'file', } name = '\u53C2\u6570' expression = '"Hello World!"' type = ArgumentBlock.types.string view = ArgumentBlock.views.text unit = '' min = 0 max = 100 step = 1 appendVariableEvent = false options = [] static convertOptions(_options) { let options2 = [] for (let option2 of _options) { if (typeof option2 !== 'object') { option2 = { name: String(option2), value: option2, } } options2.push({ name: Block.fixValue(option2.name || option2.value), expression: option2.expression || Block.valueToCode(Block.fixValue(option2.value)), get value() { return Block.codeToValue(this.expression) }, }) } return options2 } constructor(object4 = {}) { super() Object.assign(this, object4) if (!object4.view) { const typeViewMap = { [ArgumentBlock.types.string]: ArgumentBlock.views.text, [ArgumentBlock.types.number]: ArgumentBlock.views.number, [ArgumentBlock.types.boolean]: ArgumentBlock.views.checkbox, } let view2 = typeViewMap[this.type] if (view2) this.view = view2 } this.options = ArgumentBlock.convertOptions(this.options) if (!object4.expression) { const typeExpressionMap = { [ArgumentBlock.types.string]: this.expression, [ArgumentBlock.types.number]: '1', [ArgumentBlock.types.boolean]: 'true', [ArgumentBlock.types.Object]: '{}', [ArgumentBlock.types.Array]: '[]', } const expression = typeExpressionMap[this.type] if (expression) this.expression = expression if (this.options.length) { const option0 = this.options[0] if (this.type === ArgumentBlock.types.Array) { this.expression = `[${option0.expression}]` } else { this.expression = option0.expression } } } } toCode() { return `(${this.expression ?? 'undefined'})` } } class ObjectBlock extends Block { static class = 'ObjectBlock' id = '' name = '' static privateConfig static methodList = [ new MethodBlock({ method: 'example', name: '\u53C2\u6570\u793A\u4F8B', arguments: [ new ArgumentBlock({ name: 'string', type: ArgumentBlock.types.string, }), new ArgumentBlock({ name: 'number', type: ArgumentBlock.types.number, unit: 'px', }), new ArgumentBlock({ name: 'boolean', type: ArgumentBlock.types.boolean, }), new ArgumentBlock({ name: 'options', view: ArgumentBlock.views.radio, options: [ { name: 'option0', value: '"value0"' }, { name: 'option1', value: '"value1"' }, ], }), new ArgumentBlock({ name: 'options', view: ArgumentBlock.views.select, options: [ { name: 'option0', value: '"value0"' }, { name: 'option1', value: '"value1"' }, ], }), new ArgumentBlock({ name: 'page', view: ArgumentBlock.views.page, expression: '', }), new ArgumentBlock({ name: 'currentPage', view: ArgumentBlock.views.currentPage, }), ], }), ] constructor(object4 = {}) { super() Object.assign(this, object4) if (this.constructor === ObjectBlock) { let block if (object4.class === ProjectBlock.class) { block = new ProjectBlock(object4) } if (object4.class === PageBlock.class) { block = new PageBlock(object4) } if (object4.class === PageManagerBlock.class) { block = new PageManagerBlock(object4) } if (object4.class === CanvasNodeBlock.class) { block = new CanvasNodeBlock(object4) } if (!block) { console.error('todo') } return block } } static findModel(blockClass, id2) { let model if (blockClass === CanvasNodeBlock.class) { model = CanvasNode$1.getById(id2) } else if (blockClass === PageBlock.class) { model = app.current.project.current.page } else if (blockClass === ProjectBlock.class) { model = app.current.project } else if (blockClass === PageManagerBlock.class) { model = new PageManager() } else { throw new Error( `\u627E\u4E0D\u5230\u8BE5\u7C7B\u578B\uFF1A${blockClass}:${id2}` ) } if (!model) { console.warn('\u627E\u4E0D\u5230model\uFF1A', ...arguments) } return model } static getObjectBlock(blockClass) { let objectBlock if (blockClass === CanvasNodeBlock.class) { objectBlock = CanvasNodeBlock } else if (blockClass === ProjectBlock.class) { objectBlock = ProjectBlock } else if (blockClass === PageManagerBlock.class) { objectBlock = PageManagerBlock } else { throw new Error(`\u627E\u4E0D\u5230\u8BE5\u7C7B\u578B\uFF1A${blockClass}`) } return objectBlock } static getMethodInfo(method4) { return method4 } } class ProjectBlock extends ObjectBlock { static class = 'ProjectBlock' name = '' static supportActionType = { ProjectBlock: true, PageManagerBlock: true, CanvasNodeBlock: false, onlyOneSelf: false, } static eventList = [ { type: EventBlock.types.mounted, name: '\u7CFB\u7EDF\u542F\u52A8' }, { type: EventBlock.types.variable, name: '\u53D8\u91CF\u53D8\u5316', hasConfig: true, detail: { type: EventBlock.types.variable, expression: '', condition: 1, name: '', }, }, { type: EventBlock.types.timer, name: '\u8FBE\u5230\u5B9A\u65F6\u6267\u884C', hasConfig: true, detail: { type: EventBlock.types.timer, name: '\u8FBE\u5230\u5B9A\u65F6\u6267\u884C', start: new Date(), frequency: 1, frequencyType: 0, end: '', unit: 0, }, }, { type: EventBlock.types.alarm, name: '\u62A5\u8B66\u89E6\u53D1', hasConfig: true, detail: { type: EventBlock.types.alarm, name: '\u62A5\u8B66\u89E6\u53D1', point: [], checkedList: [], }, }, { type: EventBlock.types.alarmRecovery, name: '\u62A5\u8B66\u6062\u590D', hasConfig: true, detail: { type: EventBlock.types.alarmRecovery, name: '\u62A5\u8B66\u6062\u590D', triggerType: 1, point: [], checkedList: [], }, }, { type: EventBlock.types.broadcast, name: '\u63A5\u6536\u5230\u5E7F\u64AD', hasConfig: true, detail: { name: '', type: EventBlock.types.broadcast, expression: '"message"', }, }, ] static methodList = [ new MethodBlock({ method: 'toast', name: '\u7CFB\u7EDF\u63D0\u793A', arguments: [ new ArgumentBlock({ name: '\u6D88\u606F', expression: '"Hello World!"', }), new ArgumentBlock({ name: '\u7C7B\u578B', view: ArgumentBlock.views.radio, options: [ { name: '\u4FE1\u606F', value: '"info"', }, { name: '\u6210\u529F', value: '"success"', }, { name: '\u8B66\u544A', value: '"warning"', }, { name: '\u9519\u8BEF', value: '"error"', }, ], }), ], }), new MethodBlock({ method: 'setVariable', name: '\u8BBE\u7F6E\u53D8\u91CF', arguments: [ new ArgumentBlock({ name: '\u53D8\u91CF\u540D', view: ArgumentBlock.views.variableName, expression: '', }), new ArgumentBlock({ name: '\u53D8\u91CF\u503C', expression: '""', }), ], }), new MethodBlock({ method: 'waiting', name: '\u7B49\u5F85', arguments: [ new ArgumentBlock({ name: '\u65F6\u957F', type: ArgumentBlock.types.number, expression: '1000', unit: 'ms', }), ], }), new MethodBlock({ method: 'sendBroadcast', name: '\u53D1\u9001\u5E7F\u64AD', arguments: [ new ArgumentBlock({ name: '\u5E7F\u64AD\u5185\u5BB9', expression: '"message"', }), ], }), new MethodBlock({ method: 'openVirtualKeyboard', name: '\u5F00\u542F\u865A\u62DF\u952E\u76D8', }), new MethodBlock({ method: 'closeVirtualKeyboard', name: '\u5173\u95ED\u865A\u62DF\u952E\u76D8', }), new MethodBlock({ method: 'audioPlay', name: '\u64AD\u653E\u97F3\u9891', arguments: [ new ArgumentBlock({ name: '\u6587\u4EF6', view: ArgumentBlock.views.file, expression: '""', }), new ArgumentBlock({ name: '\u91CD\u590D\u64AD\u653E', view: ArgumentBlock.views.checkbox, expression: 'true', }), ], }), new MethodBlock({ method: 'audioPause', name: '\u505C\u6B62\u97F3\u9891\u64AD\u653E', }), ] constructor(object4 = {}) { super() Object.assign(this, object4) } } class PageBlock extends ObjectBlock { static class = 'PageBlock' static methodList = [] constructor(object4 = {}) { super() Object.assign(this, object4) } } class PageManagerBlock extends ObjectBlock { static class = 'PageManagerBlock' static supportActionType = { PageManagerBlock: true, ProjectBlock: true, CanvasNodeBlock: true, onlyOneSelf: false, } static eventList = [ { type: EventBlock.types.mounted, name: '\u753B\u9762\u8F7D\u5165' }, { type: EventBlock.types.unmounted, name: '\u753B\u9762\u9000\u51FA', supportActionType: { PageManagerBlock: false, CanvasNodeBlock: false, }, }, { type: EventBlock.types.variable, name: '\u53D8\u91CF\u53D8\u5316', hasConfig: true, detail: { type: EventBlock.types.variable, expression: '', condition: 1, }, }, { type: EventBlock.types.broadcast, name: '\u63A5\u6536\u5230\u5E7F\u64AD', hasConfig: true, detail: { type: EventBlock.types.broadcast, expression: '"message"', }, }, ] static methodList = [ new MethodBlock({ method: 'jumpRoute', name: '\u8DF3\u8F6C\u753B\u9762', arguments: [ new ArgumentBlock({ name: '\u76EE\u6807\u753B\u9762', view: ArgumentBlock.views.page, expression: '', options: [], }), ], }), new MethodBlock({ method: 'reloadRoute', name: '\u91CD\u8F7D\u753B\u9762', arguments: [], }), new MethodBlock({ method: 'backRoute', name: '\u8FD4\u56DE\u4E0A\u4E00\u753B\u9762', arguments: [], }), new MethodBlock({ method: 'closeRoute', name: '\u5173\u95ED\u753B\u9762', arguments: [], }), new MethodBlock({ method: 'alertRoute', name: '\u5F39\u7A97\u753B\u9762', arguments: [ new ArgumentBlock({ name: '\u76EE\u6807\u753B\u9762', view: ArgumentBlock.views.page, expression: '', }), new ArgumentBlock({ name: '\u6807\u9898', }), new ArgumentBlock({ name: '\u56FA\u5B9A', type: ArgumentBlock.types.boolean, view: ArgumentBlock.views.checkbox, expression: 'false', }), new ArgumentBlock({ name: 'W', type: ArgumentBlock.types.number, unit: 'px', expression: '500', }), new ArgumentBlock({ name: 'H', type: ArgumentBlock.types.number, unit: 'px', expression: '500', }), new ArgumentBlock({ name: '\u5C5E\u6027', view: ArgumentBlock.views.radio, options: [ { name: '\u56FA\u5B9A', value: '"dialog"', }, { name: '\u81EA\u7531', value: '"_blank"', }, ], }), new ArgumentBlock({ name: '\u5173\u95ED\u6309\u94AE', view: ArgumentBlock.views.radio, options: [ { name: '\u6709', value: 'true', }, { name: '\u65E0', value: 'false', }, ], }), ], }), new MethodBlock({ method: 'exportCurrentPage', name: '\u5BFC\u51FA\u753B\u9762', arguments: [ new ArgumentBlock({ name: '\u76EE\u6807\u9875\u9762', view: ArgumentBlock.views.currentPage, }), new ArgumentBlock({ name: '\u683C\u5F0F', view: ArgumentBlock.views.radio, options: exportTypeList1.map((e2) => ({ ...e2, value: `"${e2.value}"`, })), }), new ArgumentBlock({ name: '\u6587\u4EF6\u547D\u540D', type: ArgumentBlock.types.string, expression: '""', }), new ArgumentBlock({ name: '\u7EB8\u5F20\u5927\u5C0F', view: ArgumentBlock.views.select, options: paperTypeList().map((e2) => ({ ...e2, value: `"${e2.value}"`, })), }), new ArgumentBlock({ name: '\u5E03\u5C40', view: ArgumentBlock.views.radio, options: layoutList.map((e2) => ({ ...e2, value: `"${e2.value}"` })), }), new ArgumentBlock({ name: '\u4FDD\u5B58\u8DEF\u5F84', type: ArgumentBlock.types.string, expression: '""', }), ], }), new MethodBlock({ method: 'printCurrentPage', name: '\u6253\u5370\u753B\u9762', arguments: [ new ArgumentBlock({ name: '\u76EE\u6807\u9875\u9762', view: ArgumentBlock.views.currentPage, }), ], }), new MethodBlock({ method: 'exportChartsData', name: '\u5BFC\u51FA\u56FE\u8868\u6570\u636E', arguments: [ new ArgumentBlock({ name: '\u5173\u8054\u56FE\u8868', type: ArgumentBlock.types.Object, view: ArgumentBlock.views.charts, }), new ArgumentBlock({ name: '\u6587\u4EF6\u547D\u540D', type: ArgumentBlock.types.string, expression: '""', }), new ArgumentBlock({ name: '\u5BFC\u51FA\u683C\u5F0F', view: ArgumentBlock.views.radio, options: exportTypeList2.map((e2) => ({ ...e2, value: `"${e2.value}"`, })), }), new ArgumentBlock({ name: '\u5BFC\u51FA\u5185\u5BB9', type: ArgumentBlock.types.Array, view: ArgumentBlock.views.checkbox, options: chartsExportContentList.map((e2) => ({ ...e2, value: `"${e2.value}"`, })), }), new ArgumentBlock({ name: '\u4FDD\u5B58\u8DEF\u5F84', type: ArgumentBlock.types.string, expression: '""', }), ], }), ] constructor(object4 = {}) { super() Object.assign(this, object4) } } class CanvasNodeBlock extends ObjectBlock { static class = 'CanvasNodeBlock' static supportActionType = { PageManagerBlock: true, ProjectBlock: true, CanvasNodeBlock: true, onlyOneSelf: false, } static privateConfig = { Img: { eventList: [], methodList: [ new MethodBlock({ method: 'setFilename', name: '\u8BBE\u7F6E\u56FE\u7247', arguments: [ new ArgumentBlock({ view: ArgumentBlock.views.image, name: '\u56FE\u7247\u540D', expression: '""', }), ], }), ], }, Sheet: { eventList: [ new EventBlock({ type: EventBlock.types.clickCell, name: '\u9009\u4E2D\u5355\u5143\u683C', arguments: [ { 类别: '\u4E8B\u4EF6\u53C2\u6570', 参数: 'event.cell.computedContent', 说明: '\u8FD4\u56DE\u6240\u9009\u4E2D\u5355\u5143\u683C\u7684\u5B57\u6BB5\u503C', }, { 类别: '\u4E8B\u4EF6\u53C2\u6570', 参数: 'event.row.cells[0].computedContent', 说明: '\u8FD4\u56DE\u6240\u9009\u4E2D\u884C\u67D0\u5355\u5143\u683C\u7684\u5B57\u6BB5\u503C', 示例: 'event.row.cells[0].computedContent \u4E3A\u6240\u9009\u4E2D\u884C\u7B2C1\u4E2A\u5355\u5143\u683C\u7684\u5B57\u6BB5\u503C', }, { 类别: '\u4E8B\u4EF6\u53C2\u6570', 参数: 'event.col.cells[0].computedContent', 说明: '\u8FD4\u56DE\u6240\u9009\u4E2D\u5217\u67D0\u5355\u5143\u683C\u7684\u5B57\u6BB5\u503C', 示例: 'event.col.cells[0].computedContent \u4E3A\u6240\u9009\u4E2D\u5217\u7B2C1\u4E2A\u5355\u5143\u683C\u7684\u5B57\u6BB5\u503C', }, ], }), ], methodList: [], }, ChartTable: { eventList: [ new EventBlock({ type: EventBlock.types.clickCell, name: '\u9009\u4E2D\u5355\u5143\u683C', arguments: [ { 类别: '\u4E8B\u4EF6\u53C2\u6570', 参数: 'event.cell.name', 说明: '\u8FD4\u56DE\u6240\u9009\u4E2D\u5355\u5143\u683C\u7684\u5B57\u6BB5\u540D', }, { 类别: '\u4E8B\u4EF6\u53C2\u6570', 参数: 'event.cell.value', 说明: '\u8FD4\u56DE\u6240\u9009\u4E2D\u5355\u5143\u683C\u7684\u5B57\u6BB5\u503C', }, { 类别: '\u4E8B\u4EF6\u53C2\u6570', 参数: 'event.row.cells[0].name', 说明: '\u8FD4\u56DE\u6240\u9009\u4E2D\u884C\u67D0\u5355\u5143\u683C\u7684\u5B57\u6BB5\u540D', 示例: 'event.row.cells[0].name\u4E3A\u6240\u9009\u4E2D\u884C\u7B2C1\u4E2A\u5355\u5143\u683C\u7684\u5B57\u6BB5\u540D', }, { 类别: '\u4E8B\u4EF6\u53C2\u6570', 参数: 'event.row.cells[0].value', 说明: '\u8FD4\u56DE\u6240\u9009\u4E2D\u884C\u67D0\u5355\u5143\u683C\u7684\u5B57\u6BB5\u503C', 示例: 'event.row.cells[0].value\u4E3A\u6240\u9009\u4E2D\u884C\u7B2C1\u4E2A\u5355\u5143\u683C\u7684\u5B57\u6BB5\u503C', }, ], }), ], methodList: [], }, DateRange: { eventList: [], methodList: [ new MethodBlock({ method: 'setDateTimer', name: '\u8BBE\u7F6E\u65F6\u95F4\u7B5B\u9009', arguments: [ new ArgumentBlock({ view: ArgumentBlock.views.date, name: '\u5F00\u59CB\u65F6\u95F4', expression: `"${dayjs(new Date()).format( 'YYYY-MM-DD HH:mm:ss' )}"`, }), new ArgumentBlock({ view: ArgumentBlock.views.date, name: '\u7ED3\u675F\u65F6\u95F4', expression: `"${dayjs(new Date()).format( 'YYYY-MM-DD HH:mm:ss' )}"`, }), ], }), ], }, DateSelector: { eventList: [], methodList: [ new MethodBlock({ method: 'getValueToVariable', name: '\u83B7\u53D6\u63A7\u4EF6\u503C\u81F3\u53D8\u91CF', arguments: [ new ArgumentBlock({ view: ArgumentBlock.views.variableName, name: '\u53D8\u91CF', }), ], }), new MethodBlock({ method: 'setValue', name: '\u8BBE\u7F6E\u63A7\u4EF6\u503C', arguments: [ new ArgumentBlock({ name: '\u503C', }), ], }), ], }, Input: { eventList: [], methodList: [ new MethodBlock({ method: 'getValueToVariable', name: '\u83B7\u53D6\u63A7\u4EF6\u503C\u81F3\u53D8\u91CF', arguments: [ new ArgumentBlock({ view: ArgumentBlock.views.variableName, name: '\u53D8\u91CF', }), ], }), new MethodBlock({ method: 'setValue', name: '\u8BBE\u7F6E\u63A7\u4EF6\u503C', arguments: [ new ArgumentBlock({ name: '\u503C', }), ], }), ], }, Select: { eventList: [], methodList: [ new MethodBlock({ method: 'getValueToVariable', name: '\u83B7\u53D6\u63A7\u4EF6\u503C\u81F3\u53D8\u91CF', arguments: [ new ArgumentBlock({ view: ArgumentBlock.views.variableName, name: '\u53D8\u91CF', }), ], }), new MethodBlock({ method: 'setValue', name: '\u8BBE\u7F6E\u63A7\u4EF6\u503C', arguments: [ new ArgumentBlock({ name: '\u503C', }), ], }), ], }, DropDownList: { eventList: [], methodList: [ new MethodBlock({ method: 'setSelectValue', name: '\u8BBE\u7F6E\u5217\u8868\u7B5B\u9009', arguments: [ new ArgumentBlock({ type: ArgumentBlock.types.string, name: '\u7B5B\u9009\u503C', expression: '""', }), ], }), ], }, TextInput: { eventList: [], methodList: [ new MethodBlock({ method: 'setValue', name: '\u8BBE\u7F6E\u6587\u672C\u7B5B\u9009', arguments: [ new ArgumentBlock({ type: ArgumentBlock.types.string, name: '\u8F93\u5165\u503C', expression: '""', }), ], }), ], }, Filter: { eventList: [], methodList: [ new MethodBlock({ method: 'getValueToVariable', name: '\u83B7\u53D6\u63A7\u4EF6\u503C\u81F3\u53D8\u91CF', arguments: [ new ArgumentBlock({ view: ArgumentBlock.views.variableName, name: '\u53D8\u91CF', }), ], }), new MethodBlock({ method: 'setValue', name: '\u8BBE\u7F6E\u63A7\u4EF6\u503C', arguments: [ new ArgumentBlock({ name: '\u503C', }), ], }), ], }, PageFrame: { eventList: [], methodList: [ new MethodBlock({ method: 'setTargetPage', name: '\u8BBE\u7F6E\u753B\u9762', arguments: [ new ArgumentBlock({ name: '\u76EE\u6807\u753B\u9762', view: ArgumentBlock.views.page, expression: '', }), ], }), ], }, NumberFilter: { eventList: [], methodList: [ new MethodBlock({ method: 'setNumberFilter', name: '\u8BBE\u7F6E\u6570\u503C\u7B5B\u9009', arguments: [ new ArgumentBlock({ name: '\u6761\u4EF6', view: ArgumentBlock.views.select, options: filterList.map((e2) => ({ value: `"${e2.value}"`, name: e2.label, })), expression: '', }), new ArgumentBlock({ name: '\u503C', type: ArgumentBlock.types.string, expression: '', }), new ArgumentBlock({ name: '\u503C', type: ArgumentBlock.types.string, expression: '', }), ], }), ], }, ReadWriteInput: { eventList: [], methodList: [ new MethodBlock({ method: 'getValueToVariable', name: '\u83B7\u53D6\u63A7\u4EF6\u503C\u81F3\u53D8\u91CF', arguments: [ new ArgumentBlock({ name: '\u53D8\u91CF', view: ArgumentBlock.views.variableName, expression: '', }), ], }), ], }, NumberInput: { eventList: [], methodList: [ new MethodBlock({ method: 'getValueToVariable', name: '\u83B7\u53D6\u63A7\u4EF6\u503C\u81F3\u53D8\u91CF', arguments: [ new ArgumentBlock({ name: '\u53D8\u91CF', view: ArgumentBlock.views.variableName, expression: '', }), ], }), ], }, RadioControl: { eventList: [], methodList: [ new MethodBlock({ method: 'getValueToVariable', name: '\u83B7\u53D6\u63A7\u4EF6\u503C\u81F3\u53D8\u91CF', arguments: [ new ArgumentBlock({ view: ArgumentBlock.views.variableName, name: '\u53D8\u91CF', expression: '', }), ], }), ], }, SelectControl: { eventList: [], methodList: [ new MethodBlock({ method: 'getValueToVariable', name: '\u83B7\u53D6\u63A7\u4EF6\u503C\u81F3\u53D8\u91CF', arguments: [ new ArgumentBlock({ view: ArgumentBlock.views.variableName, name: '\u53D8\u91CF', expression: '', }), ], }), ], }, CheckboxControl: { eventList: [], methodList: [ new MethodBlock({ method: 'getValueToVariable', name: '\u83B7\u53D6\u63A7\u4EF6\u503C\u81F3\u53D8\u91CF', arguments: [ new ArgumentBlock({ view: ArgumentBlock.views.variableName, name: '\u53D8\u91CF', expression: '', }), ], }), ], }, } static eventList = [ { type: EventBlock.types.click, name: '\u9F20\u6807\u5355\u51FB' }, { type: EventBlock.types.dblclick, name: '\u9F20\u6807\u53CC\u51FB' }, { type: EventBlock.types.contextmenu, name: '\u9F20\u6807\u53F3\u952E' }, { type: EventBlock.types.mousedown, name: '\u9F20\u6807\u6309\u4E0B' }, { type: EventBlock.types.mouseup, name: '\u9F20\u6807\u677E\u5F00' }, { type: EventBlock.types.mouseenter, name: '\u9F20\u6807\u79FB\u5165' }, { type: EventBlock.types.mouseleave, name: '\u9F20\u6807\u79FB\u51FA' }, { type: EventBlock.types.hover, name: '\u9F20\u6807\u505C\u653E' }, { type: EventBlock.types.mouselongpress, name: '\u9F20\u6807\u957F\u6309' }, { type: EventBlock.types.focus, name: '\u83B7\u5F97\u7126\u70B9' }, { type: EventBlock.types.blur, name: '\u5931\u53BB\u7126\u70B9' }, { type: EventBlock.types.change, name: '\u8F93\u5165\u53D8\u5316', arguments: [ { 类别: '\u4E8B\u4EF6\u53C2\u6570', 参数: 'event.target.value', 说明: '\u5F53\u524D\u63A7\u4EF6\u503C', }, ], }, { type: EventBlock.types.__DIVISION__, name: '\u5206\u5272\u7EBF' }, { type: EventBlock.types.mounted, name: '\u7EC4\u4EF6\u8F7D\u5165' }, { type: EventBlock.types.unmounted, name: '\u7EC4\u4EF6\u9000\u51FA' }, { type: EventBlock.types.__DIVISION__, name: '\u5206\u5272\u7EBF' }, { type: EventBlock.types.variable, name: '\u53D8\u91CF\u53D8\u5316', hasConfig: true, detail: { type: EventBlock.types.variable, expression: '', condition: 1, name: '', }, supportActionType: { PageManagerBlock: false, onlyOneSelf: true, }, }, { type: EventBlock.types.broadcast, name: '\u63A5\u6536\u5230\u5E7F\u64AD', hasConfig: true, detail: { name: '', type: EventBlock.types.broadcast, expression: '"message"', }, supportActionType: { onlyOneSelf: true, }, }, ] static methodList = [ new MethodBlock({ method: 'toggleVisible', name: '\u663E\u793A/\u9690\u85CF', type: '\u53EF\u89C1\u6027\u7C7B', arguments: [ new ArgumentBlock({ name: '\u6A21\u5F0F', view: ArgumentBlock.views.radio, expression: '"toggle"', options: [ { value: '"show"', name: '\u663E\u793A', }, { value: '"hide"', name: '\u9690\u85CF', }, { value: '"toggle"', name: '\u5207\u6362', }, ], }), ], }), new MethodBlock({ method: 'setWidthHeight', name: '\u5C3A\u5BF8', type: '\u5E03\u5C40\u5C3A\u5BF8\u7C7B', arguments: [ new ArgumentBlock({ name: '\u6A21\u5F0F', view: ArgumentBlock.views.radio, options: [ { name: '"\u7EDD\u5BF9\u5C3A\u5BF8"', value: '"absolute"' }, { name: '"\u767E\u5206\u6BD4"', value: '"percentage"' }, ], }), new ArgumentBlock({ type: ArgumentBlock.types.number, name: 'W', unit: 'px/%', expression: '100', }), new ArgumentBlock({ type: ArgumentBlock.types.number, name: 'H', unit: 'px/%', expression: '100', }), ], }), new MethodBlock({ method: 'setLetTop', name: '\u79FB\u52A8', type: '\u5E03\u5C40\u5C3A\u5BF8\u7C7B', arguments: [ new ArgumentBlock({ name: '\u6A21\u5F0F', view: ArgumentBlock.views.radio, options: [ { name: '"\u76F8\u5BF9\u5750\u6807"', value: '"relative"' }, { name: '"\u7EDD\u5BF9\u5750\u6807"', value: '"absolute"' }, ], }), new ArgumentBlock({ type: ArgumentBlock.types.number, name: 'X', unit: 'px', }), new ArgumentBlock({ type: ArgumentBlock.types.number, name: 'Y', unit: 'px', }), ], }), new MethodBlock({ method: 'setRotate', name: '\u65CB\u8F6C', type: '\u5E03\u5C40\u5C3A\u5BF8\u7C7B', arguments: [ new ArgumentBlock({ view: ArgumentBlock.views.radio, options: [ { name: '"\u76F8\u5BF9\u89D2\u5EA6"', value: '"relative"' }, { name: '"\u7EDD\u5BF9\u89D2\u5EA6"', value: '"absolute"' }, ], }), new ArgumentBlock({ type: ArgumentBlock.types.number, name: '\u89D2\u5EA6', unit: '\u5EA6', }), new ArgumentBlock({ type: ArgumentBlock.types.number, name: '\u53C2\u8003\u504F\u79FBX', expression: '0', }), new ArgumentBlock({ type: ArgumentBlock.types.number, name: '\u53C2\u8003\u504F\u79FBY', expression: '0', }), ], }), new MethodBlock({ method: 'setTextStyle', name: '\u6587\u672C\u6837\u5F0F', type: '\u6587\u672C\u7C7B', arguments: [ new ArgumentBlock({ view: ArgumentBlock.views.color, name: '\u989C\u8272', expression: '"rgba(0, 0, 0, 1)"', }), new ArgumentBlock({ type: ArgumentBlock.types.number, name: '\u5B57\u53F7', unit: 'px', expression: '14', }), new ArgumentBlock({ type: ArgumentBlock.types.boolean, view: ArgumentBlock.views.checkbox, name: '\u7C97\u4F53', expression: 'false', }), new ArgumentBlock({ type: ArgumentBlock.types.boolean, view: ArgumentBlock.views.checkbox, name: '\u659C\u4F53', expression: 'false', }), new ArgumentBlock({ type: ArgumentBlock.types.boolean, view: ArgumentBlock.views.checkbox, name: '\u4E0B\u5212\u7EBF', expression: 'false', }), new ArgumentBlock({ view: ArgumentBlock.views.radio, name: '\u6C34\u5E73\u5BF9\u9F50', options: [ { name: '"\u5DE6\u4FA7"', value: '"left"' }, { name: '"\u5C45\u4E2D"', value: '"center"' }, { name: '"\u53F3\u4FA7"', value: '"right"' }, ], expression: '"center"', }), new ArgumentBlock({ type: ArgumentBlock.types.number, name: '\u5B57\u95F4\u8DDD', unit: 'px', expression: '0', }), new ArgumentBlock({ type: ArgumentBlock.types.number, name: '\u884C\u95F4\u8DDD', unit: 'px', expression: '14', }), ], }), new MethodBlock({ method: 'setTextContent', name: '\u6587\u672C\u5185\u5BB9', type: '\u6587\u672C\u7C7B', arguments: [ new ArgumentBlock({ view: ArgumentBlock.views.text, name: '\u6587\u672C\u5185\u5BB9', }), ], }), new MethodBlock({ method: 'setBackground', name: '\u80CC\u666F', type: '\u5916\u89C2\u7C7B', arguments: [ new ArgumentBlock({ view: ArgumentBlock.views.color, name: '\u989C\u8272', expression: '"rgba(0, 0, 0, 1)"', }), new ArgumentBlock({ view: ArgumentBlock.views.image, name: '\u80CC\u666F\u56FE', expression: '""', }), new ArgumentBlock({ view: ArgumentBlock.views.select, options: [ { name: '\u81EA\u9002\u5E94', value: '"contain"' }, { name: '\u62C9\u4F38', value: '"100% 100%"' }, { name: '\u5B9E\u9645\u5927\u5C0F', value: '"auto"' }, { name: '\u8986\u76D6', value: '"cover"' }, ], expression: '"100% 100%"', name: '\u5C55\u793A\u6A21\u5F0F', }), ], }), new MethodBlock({ method: 'setBorder', name: '\u8FB9\u6846', type: '\u5916\u89C2\u7C7B', arguments: [ new ArgumentBlock({ view: ArgumentBlock.views.color, name: '\u989C\u8272', expression: '"rgba(0, 0, 0, 1)"', }), new ArgumentBlock({ type: ArgumentBlock.types.number, name: '\u7EBF\u5BBD', unit: 'px', expression: '1', }), new ArgumentBlock({ view: ArgumentBlock.views.radio, name: '\u7EBF\u578B', options: [ { name: '"\u65E0"', value: '"none"', }, { name: '"\u76F4\u7EBF"', value: '"solid"', }, { name: '"\u865A\u7EBF"', value: '"dashed"', }, { name: '"\u5706\u70B9"', value: '"dotted"', }, ], expression: '"solid"', }), ], }), new MethodBlock({ method: 'setBorderRadius', name: '\u5706\u89D2', type: '\u5916\u89C2\u7C7B', arguments: [ new ArgumentBlock({ type: ArgumentBlock.types.number, name: '\u5706\u89D2', unit: 'px', }), ], }), new MethodBlock({ method: 'setBoxShadow', name: '\u9634\u5F71', type: '\u5916\u89C2\u7C7B', arguments: [ new ArgumentBlock({ view: ArgumentBlock.views.radio, name: '\u6A21\u5F0F', options: [ { name: '"\u5916\u90E8"', value: '"outset"' }, { name: '"\u5185\u90E8"', value: '"inset"' }, ], }), new ArgumentBlock({ name: '\u6C34\u5E73', view: ArgumentBlock.views.slide, type: ArgumentBlock.types.number, min: -50, max: 50, }), new ArgumentBlock({ name: '\u5782\u76F4', view: ArgumentBlock.views.slide, type: ArgumentBlock.types.number, min: -50, max: 50, }), new ArgumentBlock({ name: '\u6A21\u7CCA', view: ArgumentBlock.views.slide, type: ArgumentBlock.types.number, min: 0, max: 50, }), new ArgumentBlock({ name: '\u5927\u5C0F', view: ArgumentBlock.views.slide, type: ArgumentBlock.types.number, min: -50, max: 50, }), new ArgumentBlock({ name: '\u989C\u8272', view: ArgumentBlock.views.color, expression: '"rgba(0, 0, 0, 1)"', }), ], }), new MethodBlock({ method: 'setOpacity', name: '\u4E0D\u900F\u660E\u5EA6', type: '\u53EF\u89C1\u6027\u7C7B', arguments: [ new ArgumentBlock({ name: '\u4E0D\u900F\u660E\u5EA6', view: ArgumentBlock.views.number, expression: '100', }), ], }), new MethodBlock({ method: 'toggleBling', name: '\u95EA\u70C1', type: '\u53EF\u89C1\u6027\u7C7B', arguments: [ new ArgumentBlock({ name: '\u6A21\u5F0F', view: ArgumentBlock.views.radio, expression: 'true', options: [ { value: 'true', name: '\u5F00\u59CB\u95EA\u70C1', }, { value: 'false', name: '\u505C\u6B62\u95EA\u70C1', }, ], }), new ArgumentBlock({ name: '\u95EA\u70C1\u901F\u7387', view: ArgumentBlock.views.radio, expression: '"slow"', options: [ { value: '"slow"', name: '\u6162', }, { value: '"medium"', name: '\u4E2D', }, { value: '"fast"', name: '\u5FEB', }, ], }), ], }), new MethodBlock({ method: 'toggleEnable', name: '\u542F\u7528/\u7981\u7528', type: '\u64CD\u4F5C\u7C7B', arguments: [ new ArgumentBlock({ name: '\u6A21\u5F0F', view: ArgumentBlock.views.radio, expression: '"toggle"', options: [ { value: '"enable"', name: '\u542F\u7528', }, { value: '"disable"', name: '\u7981\u7528', }, { value: '"toggle"', name: '\u5207\u6362', }, ], }), ], }), new MethodBlock({ method: 'dispatchEvent', name: '\u89E6\u53D1\u4E8B\u4EF6', type: '\u64CD\u4F5C\u7C7B', arguments: [ new ArgumentBlock({ name: '\u4E8B\u4EF6', view: ArgumentBlock.views.select, appendVariableEvent: true, options: CanvasNodeBlock.eventList .filter((e2) => { const excludeList = EventBlock.triggerDiyNameEventList if (excludeList.includes(e2.type)) return return true }) .map((e2) => { return { value: `"${e2.type}"`, name: e2.name, } }), }), ], }), ] constructor(object4 = {}) { super() Object.assign(this, object4) } } var __glob_0_2 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, Block, OnBlock, EventBlock, IfBlock, CallBlock, MethodBlock, ArgumentBlock, ObjectBlock, ProjectBlock, PageBlock, PageManagerBlock, CanvasNodeBlock, }, Symbol.toStringTag, { value: 'Module' } ) ) function styleConverter(style2) { const properties = { rotate: { get() { if (style2.rotate === 'none') return 0 return parseFloat(String(style2.rotate)) }, set(value2) { style2.rotate = `${value2}deg` }, }, opacity: { get() { const opacity2 = Number(style2.opacity ?? 1) || 1 const opacity100 = +(opacity2 * 100).toFixed() return opacity100 }, set(value2) { style2.opacity = (value2 / 100).toFixed(2) }, }, boxShadow: { get() { let rs2 = [ ['rgba(0, 0, 0, 1)', 0, 0, 0, 0], ['rgba(0, 0, 0, 1)', 0, 0, 0, 0], ] const reg = /(#\S+|rgba?\(.*?\)) (\S+)px (\S+)px (\S+)px (\S+)px,\s+(#\S+|rgba?\(.*?\)) (\S+)px (\S+)px (\S+)px (\S+)px inset/ let res = reg.exec(style2.boxShadow || '') if (res) { rs2 = [ [res[1], +res[2], +res[3], +res[4], +res[5]], [res[6], +res[7], +res[8], +res[9], +res[10]], ] } return rs2 }, set([o2 = [], i2 = []]) { const value2 = [ `${o2[0]} ${o2[1]}px ${o2[2]}px ${o2[3]}px ${o2[4]}px`, `${i2[0]} ${i2[1]}px ${i2[2]}px ${i2[3]}px ${i2[4]}px inset`, ].join(', ') style2.boxShadow = value2 }, }, backgroundImage: { get() { const reg = /[^/\\()'"`.,\s]+?(\.jpg|\.jpeg|\.png|\.gif|\.svg)/gi const res = style2.backgroundImage?.match(reg) return res ? res[0] : '' }, set(imageFileName) { style2.backgroundImage = imageFileName ? `url("/api/v1/view/image/${imageFileName}")` : '' }, }, } const proxy = new Proxy(style2, { get(style22, key2) { const value2 = style22[key2] if (typeof properties[key2]?.get === 'function') { return properties[key2].get() } if (typeof value2 === 'string' && /px$/.test(value2)) { return parseFloat(value2) } return value2 }, set(style22, key2, value2) { if (typeof properties[key2]?.set === 'function') { properties[key2].set(value2) return true } if (typeof value2 === 'number') { style22[key2] = `${value2}px` return true } style22[key2] = value2 return true }, }) return proxy } window.styleConverter = styleConverter class CanvasNode$1 extends Base { constructor(object4 = {}) { object4 = JSON.parse(JSON.stringify(object4)) super() Object.assign(this.style, object4.style) Object.assign(this, { ...object4, style: this.style }) Block.createArray(this.blocks) for (const [i2, child] of this.childNodes.entries()) { this.childNodes[i2] = new CanvasNode$1(child) } Widget.store[this.is]?.onCreate?.(this) } toJSON() { return { id: this.id, name: this.name, tagName: this.tagName, style: this.style, langStyleMap: this.langStyleMap, is: this.is, props: this.props, blocks: this.blocks, childNodes: this.childNodes, permission: this.permission, locked: this.locked, aspectRatioLocked: this.aspectRatioLocked, } } id = utils.createRandomId() name = '' is = '' tagName = '' props = {} blocks = [] methods = {} permission = false get selected() { return this._selected } set selected(boolean) { const selectedList = CanvasNode$1.selectedList if (!this.selected && boolean) { selectedList.push(this) } else if (this.selected && !boolean) { selectedList.splice(selectedList.indexOf(this), 1) } this._selected = boolean } _selected = false static get selectedList() { return app.current.project.current.page.selectedCanvasNodeList } locked = false aspectRatioLocked = false style = {} computedStyle = (function (node2) { return new Proxy(node2.style, { get(style2, key2) { if (/^(__isVue|__v_|Symbol)/.test(String(key2))) return style2[key2] if (!node2.isGroup()) { let value2 = node2.langStyle[key2] ?? style2[key2] if (!value2 && node2.computedStyleCache?.[key2]) { return node2.computedStyleCache[key2] } if (!value2 && node2.dom) { const computedStyle = getComputedStyle(node2.dom) value2 = computedStyle[key2] node2.computedStyleCache = { ...computedStyle } } return value2 } else { let value2 if (CanvasNode$1.GROUP_SELF_STYLE_KEY_REG.test(String(key2))) { return node2.langStyle[key2] } else { for (const child of node2.childNodes) { let val2 = child.computedStyle[key2] if (value2 === void 0) value2 = val2 if (val2 !== value2) return } } return value2 } }, set(target2, key2, value2) { if (!node2.isGroup()) { node2.langStyle[key2] = value2 } else { if (CanvasNode$1.GROUP_SELF_STYLE_KEY_REG.test(String(key2))) { node2.langStyle[key2] = value2 } else { if (key2 === 'rotate') { delete node2.style.rotate } for (const child of node2.childNodes) { child.computedStyle[key2] = value2 } } } return true }, }) })(this) static GROUP_SELF_STYLE_KEY_REG = /^(left|top|width|height|visibility)$/i convertedStyle = styleConverter(this.computedStyle) langStyle = ((node2) => { return new Proxy(this.style, { get(style2, key2) { return node2.getLangStyleValue(key2) }, set(style2, key2, value2) { node2.setLangStyleValue(key2, value2) return true }, }) })(this) computedStyleCache get styleProxy() { return this.convertedStyle } langStyleMap = {} getLangStyleValue(key2) { return ( this.langStyleMap[$$f.language.followLang]?.[key2] ?? this.style[key2] ) } setLangStyleValue(key2, value2) { if (typeof key2 != 'string') return let lang = $$f.language.followLang if (!/^(fontSize)$/.test(key2)) { this.style[key2] = value2 return } if (lang === 'original') { this.style[key2] = value2 } else { if (!this.style[key2]) { this.style[key2] = this.computedStyle[key2] } this.langStyleMap[lang] = { ...this.langStyleMap[lang], [key2]: value2, } } } get dom() { return document.getElementById(this.id) } get parentNode() { return this.dom?.parentElement.__canvasNode } childNodes = [] get children() { return this.childNodes } get childrenReversed() { return new Proxy(this.children, { get(o2, k2) { if (typeof k2 === 'string' && !isNaN(Number(k2))) { const _index = Number(k2) const index2 = o2.length - 1 - _index return o2[index2] } return o2[k2] }, set(o2, k2, v4) { if (typeof k2 === 'string' && !isNaN(Number(k2))) { const _index = Number(k2) const index2 = o2.length - 1 - _index if (index2 < 0) { const arr = [] arr.length = -index2 o2.unshift(...arr) o2[0] = v4 return true } o2[index2] = v4 return true } o2[k2] = v4 return true }, deleteProperty(o2, k2) { if (typeof k2 === 'string' && !isNaN(Number(k2))) { const _index = Number(k2) const index2 = o2.length - 1 - _index o2.splice(index2, 1) } return true }, }) } setDefaultProps(defaultProps2) { const props2 = this.props defaultProps2 = structuredClone(defaultProps2) merge2(props2, defaultProps2) function merge2(obj, obj_) { if (obj === null || obj_ === null) return obj const keys3 = [ .../* @__PURE__ */ new Set([...Object.keys(obj), ...Object.keys(obj_)]), ] for (const key2 of keys3) { const value2 = obj[key2] const value_ = obj_[key2] if (typeof value2 !== typeof value_) { if (value_ === void 0) { continue } obj[key2] = value_ continue } if (Array.isArray(value2) && Array.isArray(value2)) { continue } if (typeof value2 === 'object' && typeof value_ === 'object') { merge2(value2, value_) continue } } return obj } return props2 } cloneNode() { const clonedCanvasNode = new CanvasNode$1(this) const idClonedMap = {} loopCanvasNode(clonedCanvasNode) function loopCanvasNode(clonedNode) { const newId = String(clonedNode.id).replace( /\[clone\|.*?\]|$/, `[clone|${Math.random().toString(32).slice(-6)}]` ) idClonedMap[clonedNode.id] = newId for (const child of clonedNode.childNodes) { loopCanvasNode(child) } } const loopCache = /* @__PURE__ */ new WeakMap() loop(clonedCanvasNode) function loop(obj) { if (!obj || typeof obj !== 'object') return if (loopCache.get(obj)) return loopCache.set(obj, true) for (const key2 in obj) { if (idClonedMap[obj[key2]]) { obj[key2] = idClonedMap[obj[key2]] } if (typeof obj[key2] === 'object') { loop(obj[key2]) } } } return clonedCanvasNode } isGroup() { return this.is === 'Group' } remove() { if (!this.parentNode) return const list2 = this.parentNode.childNodes list2.splice(list2.indexOf(this), 1) } appendChild(child) { child.remove() this.childNodes.push(child) } getTriggerDiyNameEventList() { return this.blocks.filter((item2) => EventBlock.triggerDiyNameEventList.includes(item2.event.type) ) } static styleProxy = new Proxy(Object(), { get(target2, key2) { const selectedList = CanvasNode$1.getSelectedOrBodyList() const value2 = CanvasNode$1.getSameStyleProxyValue(selectedList, key2) return value2 }, set(target2, key2, value2) { const selectedList = CanvasNode$1.getSelectedOrBodyList() CanvasNode$1.setSameStyleProxyValue(selectedList, key2, value2) return true }, }) static getSelectedOrBodyList() { return CanvasNode$1.selectedList.length ? CanvasNode$1.selectedList : [CanvasNode$1.getBody()] } static getUnlockedSelectedList() { return this.selectedList.filter((item2) => !item2.locked) } static getSameStyleProxyValue(nodes, key2) { let value2 for (const child of nodes) { const val2 = child.computedStyle[key2] if (value2 === void 0) value2 = val2 if (val2 !== value2) { value2 = void 0 break } } return styleConverter({ [key2]: value2 })[key2] } static setSameStyleProxyValue(nodes, key2, value2) { for (const child of nodes) { child.styleProxy[key2] = value2 } } static getById(id2) { const dom = document.getElementById(id2) const node2 = dom?.__canvasNode return node2 } static getBody() { return app.current.project.current.page.document.body } toggleVisible(visibleState = '') { switch (visibleState) { case 'show': this.style.visibility = 'visible' break case 'hide': this.style.visibility = 'hidden' break default: this.style.visibility = this.style.visibility === 'hidden' ? 'visible' : 'hidden' break } } addClass(className) { this.dom?.classList.add(className) } removeClass(className) { this.dom?.classList.remove(className) } hasClass(className) { return this.dom?.classList.contains(className) } toggleClass(className) { if (this.hasClass(className)) { this.removeClass(className) } else { this.addClass(className) } } toggleEnable(enableState = '') { switch (enableState) { case 'enable': this.removeClass('forbidden') break case 'disable': this.addClass('forbidden') break default: this.toggleClass('forbidden') break } } setOpacity(opacity2) { this.styleProxy.opacity = opacity2 } toggleBling(isStarted, speed = 'fast') { const speedClass = 'bling-' + speed ;['slow', 'medium', 'fast'].forEach((item2) => { this.removeClass('bling-' + item2) }) if (isStarted) { this.addClass(speedClass) } } setWidthHeight(mode2, w2, h2) { if (mode2 === 'absolute') { this.styleProxy.width = w2 this.styleProxy.height = h2 } if (mode2 === 'percentage') { const _setWH = (nodes) => { for (const node2 of nodes) { if (node2.isGroup()) { _setWH(node2.childNodes) } else { const { width, height } = node2.styleProxy node2.styleProxy.width = Math.floor(width * w2 * 0.01) node2.styleProxy.height = Math.floor(height * h2 * 0.01) } } } _setWH([this]) } } setLetTop(mode2, x2, y2) { this.styleProxy.left = mode2 === 'absolute' ? x2 : this.styleProxy.left + x2 this.styleProxy.top = mode2 === 'absolute' ? y2 : this.styleProxy.top + y2 } setRotate(mode2, deg2, originX, originY) { if (mode2 === 'absolute') { this.styleProxy.transformOrigin = `${originX}px ${originY}px` this.styleProxy.rotate = deg2 } if (mode2 === 'relative') { const _setRotate = (nodes) => { for (const node2 of nodes) { if (node2.isGroup()) { _setRotate(node2.childNodes) } else { const { rotate: rotate2 = 0 } = node2.styleProxy node2.styleProxy.transformOrigin = `${originX}px ${originY}px` node2.styleProxy.rotate = rotate2 + deg2 } } } _setRotate([this]) } } setTextStyle( color2, fontSize2, bold, italic, underline, textAlign2, letterSpacing2, lineHeight2 ) { Object.assign(this.styleProxy, { color: color2, fontSize: fontSize2, fontWeight: bold ? 'bold' : '', fontStyle: italic ? 'italic' : '', textDecoration: underline ? 'underline' : '', textAlign: textAlign2, letterSpacing: letterSpacing2, lineHeight: lineHeight2, }) } setTextContent(content2) { const _setTextContent = (nodes) => { for (const node2 of nodes) { if (node2.isGroup()) { _setTextContent(node2.childNodes) } else { const el2 = node2.dom if ( el2 && !Array.from(el2.children).find((e2) => e2.nodeName != 'BR') ) { el2.textContent = content2 } } } } _setTextContent([this]) } setBackgroundColor(color2) { this.styleProxy.backgroundColor = color2 } setBackground(backgroundColor2, backgroundImage2, backgroundSize2) { Object.assign(this.styleProxy, { backgroundColor: backgroundColor2, backgroundImage: backgroundImage2, backgroundSize: backgroundSize2, backgroundPosition: 'center', backgroundRepeat: 'no-repeat', }) } setBorder(color2, width, style2) { Object.assign(this.styleProxy, { borderColor: color2, borderWidth: width, borderStyle: style2, }) } setBorderRadius(borderRadius) { this.styleProxy.borderRadius = borderRadius } setBoxShadow(mode2, horizontal, vertical, blur, spread3, color2) { let boxShadow2 = this.styleProxy.boxShadow boxShadow2[ { outset: 0, inset: 1, }[mode2] ] = [color2, horizontal, vertical, blur, spread3] this.styleProxy.boxShadow = boxShadow2 } dispatchEvent(type4) { let block = OnBlock.getBlockById(type4) block ? block.isEnable && block.getCallbackCatch()() : this.dom?.dispatchEvent(new Event(type4)) } toggleExpandAllBlock(isExpand) { const loop = (blocks2) => { for (const block of blocks2) { block.isExpand = isExpand if (block.children) { loop(block.children) } } } loop(this.blocks) } } var __glob_0_3 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, CanvasNode: CanvasNode$1, }, Symbol.toStringTag, { value: 'Module' } ) ) class PageHistory extends Base { constructor(page2) { super() this.page = page2 } page stack = [] cursor = -1 watching = false start() { this.watch() } stop() { this.unwatch() this.stack.length = 0 this.cursor = -1 } pause() { this.unwatch() } resume() { this.watch() } init() { if (this.cursor === -1) { this.stack.length = 0 this.cursor = 0 this.stack.push(this.getNewItem()) } } watch() { if (app.running) return if (this.watching) return this.watching = true this.init() const _watchCallback = lodash$2.exports.debounce( () => this.watchCallback(), PageHistory.DEBOUNCE_DELAY ) const callback = (event) => { if (event instanceof KeyboardEvent) { if (utils.isInputActive()) { return } } if (event instanceof FocusEvent && event.target instanceof Element) { if (!utils.isInputActive(event.target)) { return } } _watchCallback() } for (const eventType of PageHistory.WATCH_EVENT_TYPES) { addEventListener(eventType, callback, true) } const unwatch = () => { this.watching = false for (const eventType of PageHistory.WATCH_EVENT_TYPES) { removeEventListener(eventType, callback, true) } } this.unwatch = unwatch return unwatch } unwatch = () => {} watchCallback() { if (this.page !== $$f.page) { this.unwatch() return } this.record() } record() { const newItem = this.getNewItem() if (!this.isChanged(newItem)) { return } this.page.save(true) this.stack.length = this.cursor + 1 this.stack.push(newItem) this.cursor++ if (this.stack.length > PageHistory.MAX) { this.stack.splice(1, 1) this.cursor-- } } isChanged(newItem) { return this.getCurrentItem().json !== newItem.json } getNewItem() { return new HistoryItem(this.page.document) } getCurrentItem() { return this.stack[this.cursor] } apply(item2) { const document2 = item2.object document2.body = new CanvasNode$1(document2.body) this.merge(this.page.document, document2) const selectedCanvasNodeList = [...this.page.selectedCanvasNodeList] this.page.selectedCanvasNodeList.length = 0 for (const node2 of selectedCanvasNodeList) { if (CanvasNode$1.getById(node2.id)) { this.page.selectedCanvasNodeList.push(node2) } } this.page.save(true) } merge(obj, obj_) { const mergeCache = /* @__PURE__ */ new Map() const merge2 = function (obj2, obj_2) { if (mergeCache.get(obj2)) { return } else { mergeCache.set(obj2, true) } if (Array.isArray(obj2) && Array.isArray(obj_2)) { if (obj2[0]?.id || obj_2[0]?.id) { const objCopy = [...obj2] for (const [i_, item_] of obj_2.entries()) { const item2 = objCopy.find((item22) => item22.id === item_.id) obj2[i_] = item2 } } obj2.length = obj_2.length } for (const key2 in obj2) { if (!(key2 in obj_2)) { delete obj2[key2] } } for (const k2 in obj_2) { const v4 = obj2[k2] const v_ = obj_2[k2] if (typeof v4 !== 'object' || v4 === null) { if (v4 != v_) { obj2[k2] = v_ continue } } if (v4?.constructor !== v_?.constructor) { if (typeof v4?.constructor === 'function') { if (!(v4 instanceof Node)) { obj2[k2] = v_ continue } } } if (typeof v4 === 'object' && typeof v_ === 'object') { if (v4?.constructor !== Object && v_?.constructor !== Object) { if (v4?.id || v_?.id) { if (v4?.id !== v_?.id) { obj2[k2] = v_ continue } } } merge2(v4, v_) } } return obj2 } return merge2(obj, obj_) } undo() { if (!this.canUndo()) return this.cursor -= 1 const item2 = this.getCurrentItem() this.apply(item2) } redo() { if (!this.canRedo()) return this.cursor += 1 const item2 = this.getCurrentItem() this.apply(item2) } canUndo() { return this.cursor > 0 } canRedo() { return this.stack.length > this.cursor + 1 } static MAX = 50 static DEBOUNCE_DELAY = 50 static WATCH_EVENT_TYPES = ['mouseup', 'drop', 'change', 'blur', 'keyup'] } class HistoryItem { constructor(item2) { this.json = JSON.stringify(item2, null, 2) } json = '' get object() { return JSON.parse(this.json) } } var __glob_0_9 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, PageHistory, HistoryItem, }, Symbol.toStringTag, { value: 'Module' } ) ) const state$6 = reactive({ current: { get nodes() { return app.current.project.current.page.selectedCanvasNodeList || [] }, copyNodes: [], cuting: false, zoom: 1, translateX: 0, translateY: 0, model: '', selectId: '', }, get permissions() { return app.current.project?.current.page?.permissions || [] }, document: { get body() { return app.current.project.current.page.document.body }, set body(v4) { app.current.project.current.page.document.body = v4 }, }, }) window.editorState = state$6 function eachNode(handler, root2 = state$6.document.body) { function loop(node2) { handler(node2) for (const child of node2.childNodes || []) { loop(child) } } loop(root2) } function isGroup(node2) { return node2.is === 'Group' } function eachRootChildNode(handler) { for (const child of state$6.document.body.childNodes || []) { handler(child) } } function getSelectedNodes() { return state$6.current.nodes } function getUnLockedSelectedNodes() { return getSelectedNodes().filter((n2) => !n2.locked) } function getUnwrapGroupNodes(nodes) { const list2 = [] for (const node2 of nodes) { if (!isGroup(node2)) { list2.push(node2) } else { const subList = getUnwrapGroupNodes(node2.childNodes || []) list2.push(...subList) } } return list2 } function getRootNode() { return state$6.document.body } function getParentNodeListByDom(dom) { const list2 = [] function loop(dom2) { if (!dom2) return const node2 = getNodeByDom(dom2) if (node2) { list2.unshift(node2) } loop(dom2.parentElement) } loop(dom) return list2 } function getChildNodes(parent2) { return parent2.childNodes || [] } function getParentNode$1(node2) { const dom = getDomByNode(node2) if (dom && dom.parentElement) { return getClosestNodeByDom(dom.parentElement) } } function getDomByNode(node2) { return document.getElementById(node2.id) } function getRectByNode(node2) { return getDomByNode(node2)?.getBoundingClientRect() } function getNodeByDom(dom) { const node2 = dom.__canvasNode return node2 } function getClosestNodeByDom(dom) { return getParentNodeListByDom(dom).at(-1) } function getChildNodeFromList(parent2, list2) { return list2.find((node2) => isChildTo(node2, parent2)) } function isSelectedNode(node2) { return node2.selected } function hasSelectedNodes() { return !!state$6.current.nodes.length } function isRootNode(node2) { return node2 === state$6.document.body } function isChildTo(child, parent2) { return parent2.childNodes?.includes(child) } const MIN_SIXE = 1 * 1024 * 1024 const MAX_WIDTH = 2560 const MAX_HEIGHT = 1900 function uploadBefore(file2) { return new Promise((resolve2, reject2) => { let image2 = new Image() image2.src = URL.createObjectURL(file2) image2.onload = () => { let resultBlob if (file2.size > MIN_SIXE) { resultBlob = compressUpload(image2, file2, MAX_WIDTH, MAX_HEIGHT) } else { resultBlob = new Blob([file2]) } resolve2(resultBlob) URL.revokeObjectURL(image2.src) } image2.onerror = () => { reject2() } }) } function compressUpload( image2, file2, maxWidth = 4096, maxHeight = 2160, quality = 0.4 ) { let canvas = document.createElement('canvas') let ctx = canvas.getContext('2d') let { width, height } = image2 let newWidth = width let newHeight = height if (width > maxWidth && height > maxHeight) { const rate = Math.min(maxWidth / width, maxHeight / height) newWidth = width * rate newHeight = height * rate } else if (width > maxWidth) { newWidth = maxWidth newHeight = (maxWidth / width) * height } else if (height > maxHeight) { newWidth = maxHeight newHeight = (maxHeight / height) * width } else { newWidth = width newHeight = height } canvas.width = newWidth canvas.height = newHeight ctx?.drawImage(image2, 0, 0, newWidth, newHeight) let compressData = canvas.toDataURL(file2.type || 'image/jpeg', quality) let blobImg = dataURItoBlob(compressData) return blobImg } function dataURItoBlob(data2) { let byteString if (data2.split(',')[0].indexOf('base64') >= 0) { byteString = atob(data2.split(',')[1]) } else { byteString = unescape(data2.split(',')[1]) } let mimeString = data2.split(',')[0].split(':')[1].split(';')[0] let ia = new Uint8Array(byteString.length) for (let i2 = 0; i2 < byteString.length; i2 += 1) { ia[i2] = byteString.charCodeAt(i2) } return new Blob([ia], { type: mimeString }) } function createProjectImg(groupKey, imageKey) { return new Promise((resolve2, reject2) => { request({ url: `/api/v1/view/image/fromgallery`, method: 'post', data: { groupKey, imageKey, }, silent: true, }) .then((res) => { resolve2(res) }) .catch(() => { reject2() }) }) } const copyNodeInfo = /* @__PURE__ */ new WeakMap() const createRandomId = () => { return ( (Math.random() * 1e7).toString(16).substr(0, 4) + new Date().getTime() + Math.random().toString().substr(2, 5) ) } const getParentNode = (node2) => { let parentNode2 = new CanvasNode$1({ id: '', name: '', style: {}, childNodes: [], props: {}, }) if (!state$6.document.body) return parentNode2 const recursion = (parent2) => { if (parentNode2.id && parentNode2.name) return if (!parent2.childNodes) return for (let i2 = 0; i2 < parent2.childNodes.length; i2++) { const item2 = parent2.childNodes[i2] if (item2.id === node2.id) { parentNode2 = parent2 break } else if (item2.childNodes && !item2.is) { recursion(item2) } } } recursion(state$6.document.body) return parentNode2 } const getParentNodeById = (parentId) => { let parentNode2 = new CanvasNode$1({ id: '', name: '', style: {}, childNodes: [], props: {}, }) if (!state$6.document.body) return parentNode2 const recursion = (parent2) => { if (parentNode2.id && parentNode2.name) return if (!parent2.childNodes) return for (let i2 = 0; i2 < parent2.childNodes.length; i2++) { const item2 = parent2.childNodes[i2] if (item2.id === parentId) { parentNode2 = item2 break } else if (item2.childNodes && !item2.is) { recursion(item2) } } } recursion(state$6.document.body) return parentNode2 } const getNodeById = (id2) => { let parentList = [] const childNodes = state$6.document.body.childNodes || [] let node2 = new CanvasNode$1({ id: '', name: '', style: {}, childNodes: [], props: {}, }) if (!childNodes || !childNodes.length) return node2 const recursion = (list2) => { for (let i2 = 0; i2 < list2.length; i2++) { const item2 = list2[i2] if (item2.id === id2) { node2 = item2 break } else if (item2.childNodes && !item2.is) { parentList = item2.childNodes recursion(parentList) } } } recursion(childNodes) return node2 } function getNodeDom(node2) { return document.getElementById(node2.id) } function getNodeRect(node2) { return getNodeDom(node2).getBoundingClientRect() } function getOffsetValue(node2) { const dom = getNodeDom(node2) return { x: dom.offsetLeft, y: dom.offsetTop, } } function setNodeRect(node2, { width, height }) { styleConverter(node2.style).width = width styleConverter(node2.style).height = height } function getNodePos(node2) { const nodeRect = getNodeRect(node2) const relativeNodeRect = getNodeRect(state$6.document.body) const x2 = nodeRect.x - relativeNodeRect.x const y2 = nodeRect.y - relativeNodeRect.y return { x: x2, y: y2 } } function setNodePos(node2, { x: x2, y: y2 }, parentId) { let parent2 = getParentNode(node2) if (!parent2.id && !parent2.name && parentId) { parent2 = getParentNodeById(parentId) } if (!parent2.id && !parent2.name) parent2 = state$6.document.body if ([state$6.document.body].includes(parent2)) { styleConverter(node2.style).left = x2 styleConverter(node2.style).top = y2 return } const parentPos = getNodePos(parent2) const offsetX = x2 - parentPos.x const offsetY = y2 - parentPos.y styleConverter(node2.style).left = offsetX styleConverter(node2.style).top = offsetY } function selectNode$1(node2, e2) { if (!(e2.ctrlKey || e2.shiftKey || e2.metaKey)) state$6.current.nodes.length = 0 const selectNodes = state$6.current.nodes const iLen = selectNodes.length for (let i2 = 0; i2 < iLen; i2++) { const item2 = state$6.current.nodes[i2] if (item2.id === node2.id) { state$6.current.nodes.splice(i2, 1) return } } const firstSelectNode = state$6.current.nodes[0] if (iLen === 0 || firstSelectNode?.parentNode === node2.parentNode) { state$6.current.nodes.push(node2) } } const allSelectNode = () => { if (!state$6.document.body.childNodes) return state$6.current.nodes.length = 0 for ( let i2 = 0, iLen = state$6.document.body.childNodes.length; i2 < iLen; i2++ ) { const node2 = state$6.document.body.childNodes[i2] state$6.current.nodes.push(node2) } } const deleteNode = (node2) => { let parentList = [] const childNodes = state$6.document.body.childNodes || [] if (!childNodes || !childNodes.length) return null const recursion = (list2) => { for (let i2 = 0; i2 < list2.length; i2++) { const item2 = list2[i2] if (item2.id === node2.id) { list2.splice(i2, 1) break } else if (item2.childNodes) { parentList = item2.childNodes recursion(parentList) } } } recursion(childNodes) } const createNode = (oldNode) => { return oldNode.cloneNode() } const creatCopyNode = (node2, index2, nodeList2) => { let parentList = [] const childNodes = nodeList2 || state$6.document.body.childNodes || [] if (!childNodes || !childNodes.length) return null const loop = (list2) => { for (let i2 = 0; i2 < list2.length; i2++) { const item2 = list2[i2] if ([item2].includes(node2)) { let _node = createNode(node2) list2.splice(index2 ?? list2.length, 0, _node) break } else if (item2.childNodes && !item2.is) { parentList = item2.childNodes loop(parentList) } } } loop(childNodes) } const copyNode$1 = (model) => { if (!state$6.current.nodes.length) return let nodes = lodash$2.exports.cloneDeep(state$6.current.nodes) || [] state$6.current.copyNodes = nodes const pageId = app.current.project.current.page?.id for (let i2 = 0, iLen = state$6.current.copyNodes.length; i2 < iLen; i2++) { const node2 = state$6.current.copyNodes[i2] const parent2 = getParentNode(node2) const { x: x2, y: y2 } = getOffsetValue(node2) const nodeInfo = { node: node2, parentId: parent2.id, x: x2, y: y2, initX: x2, initY: y2, pageId, pastedPageIds: /* @__PURE__ */ new Set(), } copyNodeInfo.set(node2, nodeInfo) } if (model === 'copy') { state$6.current.cuting = false } else { state$6.current.cuting = true for (let i2 = 0, iLen = state$6.current.copyNodes.length; i2 < iLen; i2++) { const node2 = state$6.current.copyNodes[i2] deleteNode(node2) } } } const pasteNode = () => { let newNodeList = [] if (!state$6.current.copyNodes.length) return newNodeList const pageId = app.current.project.current.page?.id const copyNode0 = state$6.current.copyNodes.find( (n2) => n2.id !== state$6.document.body.id ) let isOffset = false if (copyNode0) { const nodeInfo0 = copyNodeInfo.get(copyNode0) let pasted = false if (!pasted) { pasted = nodeInfo0.pastedPageIds.has(pageId) ? true : false nodeInfo0.pastedPageIds.add(pageId) } isOffset = nodeInfo0.pageId !== pageId && !pasted ? false : true } for (let i2 = 0, iLen = state$6.current.copyNodes.length; i2 < iLen; i2++) { let node2 = state$6.current.copyNodes[i2] if (state$6.document.body.id === node2.id) continue const nodeInfo = copyNodeInfo.get(node2) const offset2 = state$6.current.cuting || !isOffset ? 0 : 10 const x2 = isOffset ? nodeInfo.x : nodeInfo.initX const y2 = isOffset ? nodeInfo.y : nodeInfo.initY let left2 = x2 + offset2 let top2 = y2 + offset2 if (node2.parentNode?.isGroup()) { const parentNode2 = getGroupNode$1(node2) if (parentNode2) { left2 = left2 + parentNode2.dom?.offsetLeft top2 = top2 + parentNode2.dom?.offsetTop } } styleConverter(node2.style).left = left2 styleConverter(node2.style).top = top2 copyNodeInfo.set(node2, { node: node2, x: left2, y: top2, parentId: nodeInfo.parentId, initX: nodeInfo.initX, initY: nodeInfo.initY, pageId: nodeInfo.pageId, pastedPageIds: nodeInfo.pastedPageIds, }) const newNode = createNode(node2) if (!state$6.document.body.childNodes) return newNodeList state$6.document.body.childNodes.push(newNode) newNodeList.push(newNode) } if (state$6.current.cuting) state$6.current.cuting = false state$6.current.nodes.length = 0 state$6.current.nodes.push(...newNodeList) return newNodeList } const splitNode = (node2) => { const childNodes = state$6.document.body.childNodes || [] const list2 = node2.childNodes || [] let index2 = 0 for (let i2 = 0, iLen = childNodes.length; i2 < iLen; i2++) { const item2 = childNodes[i2] if (item2.id === node2.id) { index2 = i2 break } } const parentLeft = Number(String(node2.style.left).replace('px', '')) const parentTop = Number(String(node2.style.top).replace('px', '')) let parentIndex = 0 list2.forEach((item2) => { let left2 = Number(String(item2.style.left).replace('px', '')) let top2 = Number(String(item2.style.top).replace('px', '')) if (node2.parentNode?.isGroup() && node2.dom) { parentIndex = node2.parentNode?.childNodes.findIndex( (item22) => item22.id === node2.id ) item2.style.left = left2 + node2.dom?.offsetLeft + 'px' item2.style.top = top2 + node2.dom?.offsetTop + 'px' } else { item2.style.left = parentLeft + left2 + 'px' item2.style.top = parentTop + top2 + 'px' } }) for (let i2 = 0, iLen = list2.length; i2 < iLen; i2++) { const item2 = list2[i2] node2.parentNode?.isGroup() ? node2.parentNode.childNodes.splice(parentIndex++, 0, item2) : childNodes.splice(index2++, 0, item2) } deleteNode(node2) } const splitCurrentNode = () => { const currentNodes = [...state$6.current.nodes] state$6.current.nodes.length = 0 for (let i2 = 0, iLen = currentNodes.length; i2 < iLen; i2++) { const node2 = currentNodes[i2] if (node2.isGroup()) { splitNode(node2) state$6.current.nodes.push(...node2.childNodes) } } } const combinationNode = (nodes) => { nodes = nodes ? nodes : CanvasNode$1.selectedList if (nodes.length <= 1) return const groupNode = new CanvasNode$1({ name: '\u7EC4\u5408', is: 'Group', style: { position: 'absolute', }, }) let arr = [] const filterSortNodes = (nodes2) => { if (!nodes2 || !nodes2.length) return const zNodes2 = CanvasNode$1.selectedList[0]?.parentNode?.childNodes if (!zNodes2?.length) return const groupNodesInZIndex = [...zNodes2].filter((zn) => nodes2.find((sn) => sn.id === zn.id) ) nodes2.forEach((node2) => { arr.push([...zNodes2].findIndex((sn) => sn.id === node2.id)) }) return groupNodesInZIndex } let zNodes = filterSortNodes(nodes) if (zNodes) { nodes = zNodes } let topZIndex = -1 const getTopZIndex = (nodes2) => { if (!nodes2?.length) return -1 const topZIndexNode = nodes2[nodes2.length - 1] const pageNodes = app.current.project.current.page.document.body.childNodes const indexBeforeGroup = pageNodes.findIndex( (pn) => pn.id === topZIndexNode.id ) if (indexBeforeGroup == -1) return -1 const indexAfterGroup = indexBeforeGroup + 1 - nodes2.length return indexAfterGroup } topZIndex = getTopZIndex(nodes) for (const node2 of nodes) { groupNode.appendChild(node2) } const nodePosList = nodes.map((node2) => getNodePos(node2)) const left2 = Math.min(...nodePosList.map((n2) => n2.x)) const top2 = Math.min(...nodePosList.map((n2) => n2.y)) let isParentGroup = false let parentGroup = { childNodes: [], } const canvasRect = getRectByNode(state$6.document.body) const nodeRectList = nodes.map((node2) => { const nodePos = getNodePos(node2) const nodeRect = getNodeRect(node2) let right22 = 0 let bottom22 = 0 let left22 = 0 let top22 = 0 if (node2.parentNode?.isGroup() && canvasRect) { left22 = nodePos.x top22 = nodePos.y right22 = nodeRect.right - canvasRect.x bottom22 = nodeRect.bottom - canvasRect.y isParentGroup = true parentGroup = node2.parentNode } else { right22 = nodePos.x + nodeRect.width bottom22 = nodePos.y + nodeRect.height isParentGroup = false } return { right: right22, bottom: bottom22, left: left22, top: top22, } }) const right2 = Math.max(...nodeRectList.map((n2) => n2.right)) const bottom2 = Math.max(...nodeRectList.map((n2) => n2.bottom)) if (isParentGroup) { const left22 = Math.min(...nodeRectList.map((n2) => n2.left)) const top22 = Math.min(...nodeRectList.map((n2) => n2.top)) const nodeParentPos = getNodePos(nodes[0].parentNode) setNodePos(groupNode, { x: left22 - nodeParentPos.x, y: top22 - nodeParentPos.y, }) setNodeRect(groupNode, { width: right2 - left22, height: bottom2 - top22 }) } else { setNodePos(groupNode, { x: left2, y: top2 }) setNodeRect(groupNode, { width: right2 - left2, height: bottom2 - top2 }) } if (!groupNode.childNodes) return for (let i2 = 0, iLen = groupNode.childNodes.length; i2 < iLen; i2++) { const node2 = groupNode.childNodes[i2] const nodePos = getNodePos(node2) const nodeRect = getNodeRect(node2) const nodeParentPos = getNodePos(node2.parentNode) let x2 let y2 if (isParentGroup) { x2 = nodePos.x - nodeParentPos.x - parseFloat(groupNode.style.left) y2 = nodePos.y - nodeParentPos.y - parseFloat(groupNode.style.top) } else { x2 = nodePos.x - left2 + (nodeRect.width - node2.dom?.offsetWidth) / 2 - nodeParentPos.x y2 = nodePos.y - top2 + (nodeRect.height - node2.dom?.offsetHeight) / 2 - nodeParentPos.y } setNodePos(node2, { x: x2, y: y2 }) } if (!state$6.document.body.childNodes) return if (isParentGroup) { parentGroup.childNodes.splice(Math.min(...arr), 0, groupNode) } else { state$6.document.body.childNodes.splice(topZIndex, 0, groupNode) } state$6.current.nodes.length = 0 state$6.current.nodes.push(groupNode) } const setLeft = () => { if (!state$6.current.nodes.length) return if (state$6.current.nodes.length === 1) { const node2 = state$6.current.nodes[0] const nodeRect = getRectByNode(node2) if (node2.locked) return const width = node2?.dom?.offsetWidth const nodeTop = styleConverter(node2.style).top const distance2 = (nodeRect?.width - width) / 2 setNodePos(node2, { x: distance2, y: nodeTop }) return } const { firstNodeRect, firstNode } = getFirstNodeRect() for (let i2 = 0, iLen = state$6.current.nodes.length; i2 < iLen; i2++) { const node2 = state$6.current.nodes[i2] if (node2.id !== firstNode.id) { const nodeTop = styleConverter(node2.style).top const nodeRect = getRectByNode(node2) if (node2.locked) continue const distance2 = nodeRect.left - firstNodeRect.left setNodePos(node2, { x: styleConverter(node2.style).left - distance2, y: nodeTop, }) } } } const setRight = () => { if (!state$6.current.nodes.length) return const canvasRect = getRectByNode(state$6.document.body) if (!canvasRect) return if (state$6.current.nodes.length === 1) { const node2 = state$6.current.nodes[0] const nodeRect = getRectByNode(node2) if (node2.locked) return const nodeTop = styleConverter(node2.style).top const width = node2?.dom?.offsetWidth const distance2 = (nodeRect?.width - width) / 2 setNodePos(node2, { x: canvasRect.width + distance2 - nodeRect?.width, y: nodeTop, }) return } const { firstNodeRect, firstNode } = getFirstNodeRect() for (let i2 = 0, iLen = state$6.current.nodes.length; i2 < iLen; i2++) { const node2 = state$6.current.nodes[i2] if (node2.id !== firstNode.id) { const nodeTop = styleConverter(node2.style).top const nodeRect = getRectByNode(node2) if (node2.locked) continue const distance2 = nodeRect.left + nodeRect.width - firstNodeRect.left - firstNodeRect?.width setNodePos(node2, { x: styleConverter(node2.style).left - distance2, y: nodeTop, }) } } } const setTop = () => { if (!state$6.current.nodes.length) return if (state$6.current.nodes.length === 1) { const node2 = state$6.current.nodes[0] const nodeRect = getRectByNode(node2) if (node2.locked) return const left2 = styleConverter(node2.style).left const height = node2?.dom?.offsetHeight const distance2 = (nodeRect?.height - height) / 2 setNodePos(node2, { x: left2, y: distance2 }) return } const { firstNodeRect, firstNode } = getFirstNodeRect() for (let i2 = 0, iLen = state$6.current.nodes.length; i2 < iLen; i2++) { const node2 = state$6.current.nodes[i2] if (node2.id !== firstNode.id) { const nodeLeft = styleConverter(node2.style).left const nodeRect = getRectByNode(node2) if (node2.locked) continue const distance2 = nodeRect.top - firstNodeRect.top setNodePos(node2, { x: nodeLeft, y: styleConverter(node2.style).top - distance2, }) } } } const setBottom = () => { if (!state$6.current.nodes.length) return const canvasRect = getRectByNode(state$6.document.body) if (!canvasRect) return if (state$6.current.nodes.length === 1) { const node2 = state$6.current.nodes[0] const nodeRect = getRectByNode(node2) if (node2.locked) return const left2 = styleConverter(node2.style).left const height = node2?.dom?.offsetHeight const distance2 = (nodeRect?.height - height) / 2 setNodePos(node2, { x: left2, y: canvasRect.height + distance2 - nodeRect?.height, }) return } const { firstNodeRect, firstNode } = getFirstNodeRect() for (let i2 = 0, iLen = state$6.current.nodes.length; i2 < iLen; i2++) { const node2 = state$6.current.nodes[i2] if (node2.id !== firstNode.id) { const nodeLeft = styleConverter(node2.style).left const nodeRect = getRectByNode(node2) if (node2.locked) continue const distance2 = nodeRect.top + nodeRect.height - firstNodeRect.top - firstNodeRect?.height setNodePos(node2, { x: nodeLeft, y: styleConverter(node2.style).top - distance2, }) } } } const getFirstNodeRect = () => { const model = state$6.current.model || 'click' let firstNode = null if (model === 'click') { for (let i2 = 0, iLen = state$6.current.nodes.length; i2 < iLen; i2++) { const node2 = state$6.current.nodes[i2] if (!node2.locked) { firstNode = node2 break } } if (!firstNode) return } else { firstNode = state$6.current.nodes.find( (e2) => e2.id === state$6.current.selectId ) } const firstNodeRect = getRectByNode(firstNode) return { firstNodeRect, firstNode, } } const moveComponent = (model, size = 1) => { if (!state$6.current.nodes.length) return for (let i2 = 0, iLen = state$6.current.nodes.length; i2 < iLen; i2++) { const node2 = state$6.current.nodes[i2] if (node2.locked) continue let nodeTop = styleConverter(node2.style).top let nodeLeft = styleConverter(node2.style).left switch (model) { case 'top': nodeTop -= size break case 'right': nodeLeft += size break case 'bottom': nodeTop += size break case 'left': nodeLeft -= size break } setNodePos(node2, { x: nodeLeft, y: nodeTop }) } } const setMiddle = (model) => { if (!state$6.current.nodes.length) return const canvasRect = getRectByNode(state$6.document.body) if (!canvasRect) return const config2 = { vertical: { targetKey: 'top', volume: 'width', coordinates: 'x' }, horizontal: { targetKey: 'left', volume: 'height', coordinates: 'y' }, } const targetKey = config2[model].targetKey const volume = config2[model].volume const coordinates = config2[model].coordinates if ( state$6.current.nodes.length === 1 && state$6.current.nodes[0]?.parentNode?.isGroup() ) { return } const { firstNode } = getFirstNodeRect() const benchmarkNode = state$6.current.nodes.length === 1 ? state$6.document.body : firstNode const benchmarkNodeRect = getRectByNode(benchmarkNode) if (!benchmarkNodeRect) return const start2 = benchmarkNodeRect[coordinates] - canvasRect[coordinates] const most = start2 + benchmarkNodeRect[volume] let startCoordinates = start2 let endCoordinates = most let centerCoordinates = (endCoordinates - startCoordinates) / 2 + startCoordinates for (let i2 = 0, iLen = state$6.current.nodes.length; i2 < iLen; i2++) { const node2 = state$6.current.nodes[i2] if (node2.locked || node2.id === firstNode.id) continue const nodeTargetKey = styleConverter(node2.style)[targetKey] const nodeRect = getRectByNode(node2) if (!nodeRect) continue let xy = centerCoordinates - node2.styleProxy[volume] / 2 if (model === 'vertical') { if (node2.parentNode?.isGroup()) { const parentNode2 = getGroupNode$1(node2) if (parentNode2) { xy = xy - parentNode2.styleProxy.left } } setNodePos(node2, { x: xy, y: nodeTargetKey }) } else { if (node2.parentNode?.isGroup()) { const parentNode2 = getGroupNode$1(node2) if (parentNode2) { xy = xy - parentNode2.styleProxy.top } } setNodePos(node2, { x: nodeTargetKey, y: xy }) } } } const setSameSize = (model) => { if (state$6.current.nodes.length <= 1) return const benchmarkNode = state$6.current.nodes[0] const benchmarkNodeRect = benchmarkNode.styleProxy if (!benchmarkNodeRect) return let value2 = benchmarkNodeRect[model] for (let i2 = 0, iLen = state$6.current.nodes.length; i2 < iLen; i2++) { const node2 = state$6.current.nodes[i2] if (node2.locked) continue const nodeRect = node2.styleProxy if (!nodeRect) continue switch (model) { case 'width': setNodeRect(node2, { width: value2, height: nodeRect.height }) break case 'height': setNodeRect(node2, { width: nodeRect.width, height: value2 }) break } } } const isometric = (model) => { if (state$6.current.nodes.length <= 2) return let space = 0 const config2 = { vertical: { offset: 'top', volume: 'height', coordinates: 'y' }, horizontal: { offset: 'left', volume: 'width', coordinates: 'x' }, } const getSpace = () => { let startSide = 0 let endSide = 0 let maxSize = 0 let nodesMaxSize = 0 let remainSpace = 0 let _space = 0 for (let i2 = 0, iLen = state$6.current.nodes.length; i2 < iLen; i2++) { const node2 = state$6.current.nodes[i2] const style2 = getComputedStyle(node2.dom) const styleProxy = styleConverter(style2) const nodeStartSide = styleProxy[config2[model].offset] const nodeEndSide = nodeStartSide + styleProxy[config2[model].volume] if (i2 === 0) startSide = nodeStartSide if (startSide > nodeStartSide) startSide = nodeStartSide if (endSide < nodeEndSide) endSide = nodeEndSide nodesMaxSize += styleProxy[config2[model].volume] } maxSize = endSide - startSide remainSpace = maxSize - nodesMaxSize _space = remainSpace / (state$6.current.nodes.length - 1) return _space } space = getSpace() let beforeNodeSide = 0 let list2 = lodash$2.exports.cloneDeep(state$6.current.nodes) list2.sort((node1, node2) => { const node1style = getComputedStyle(node1.dom) const node1Rect = styleConverter(node1style) const node1Left = node1Rect[config2[model].offset] const node2style = getComputedStyle(node2.dom) const node2Rect = styleConverter(node2style) const node2Left = node2Rect[config2[model].offset] return node1Left - node2Left }) for (let i2 = 0, iLen = list2.length; i2 < iLen; i2++) { const item2 = list2[i2] if (i2 === 0 || i2 === list2.length - 1) continue for (let n2 = 0, nLen = state$6.current.nodes.length; n2 < nLen; n2++) { const beforeNode = list2[i2 - 1] const thisNode = state$6.current.nodes[n2] if (item2.id === thisNode.id) { const style2 = getComputedStyle(beforeNode.dom) const beforeNodeRect = styleConverter(style2) const startSide = beforeNodeRect[config2[model].offset] if (beforeNodeSide === 0) beforeNodeSide = startSide beforeNodeSide = beforeNodeSide + space + beforeNodeRect[config2[model].volume] if (model === 'vertical') { const nodeLeft = styleConverter(thisNode.style).left setNodePos(thisNode, { x: nodeLeft, y: beforeNodeSide }) } else { const nodeTop = styleConverter(thisNode.style).top setNodePos(thisNode, { x: beforeNodeSide, y: nodeTop }) } break } } } } const setZIndex$1 = (model) => { for (let i2 = 0, iLen = state$6.current.nodes.length; i2 < iLen; i2++) { const item2 = state$6.current.nodes[i2] const parent2 = item2?.parentNode?.isGroup() ? item2.parentNode : getParentNode(item2) if (!parent2.childNodes) continue for (let n2 = 0, nLen = parent2.childNodes.length; n2 < nLen; n2++) { const element = parent2.childNodes[n2] if (element.id === item2.id) { const index2 = model === 'bottom' ? 0 : parent2.childNodes.length parent2.childNodes.splice(n2, 1) parent2.childNodes.splice(index2, 0, item2) break } } } } function treeSelectSort(treeData, current2, isCloneDeep = false) { const _current = isCloneDeep ? lodash$2.exports.cloneDeep(current2) : current2 let index2 = 0 const wm2 = /* @__PURE__ */ new WeakMap() function loop(obj) { if (!obj.childNodes) return for (const item2 of obj.childNodes) { index2++ for (const element of _current) { if (element.id !== item2.id) continue wm2.set(element, index2) break } if (item2.childNodes) loop(item2) } } loop(treeData) return _current.sort((a2, b2) => wm2.get(a2) - wm2.get(b2)) } function moveZIndex(model) { function move(currentNode) { const parent2 = getParentNode$1(currentNode) if (!parent2) return false const fun = { before: () => { for (let i2 = 0, iLen = parent2.childNodes.length; i2 < iLen; i2++) { const targetNode = parent2.childNodes[i2] if (targetNode.id !== currentNode.id) continue if (i2 === 0 && parent2.childNodes.length === 1) { return false } const index2 = state$6.current.nodes.findIndex( (node2) => node2.id === targetNode.id ) if (index2 !== i2) { parent2.childNodes.splice(i2, 1) let index22 = i2 parent2.childNodes.splice(index22 - 1, 0, targetNode) break } } return true }, after: () => { for (let i2 = parent2.childNodes.length - 1; i2 >= 0; i2--) { const targetNode = parent2.childNodes[i2] if (targetNode.id !== currentNode.id) continue if ( i2 === parent2.childNodes.length - 1 && parent2.childNodes.length === 1 ) { return false } const index2 = state$6.current.nodes.findIndex( (node2) => node2.id === targetNode.id ) if (parent2.childNodes.length - 1 - index2 !== i2) { parent2.childNodes.splice(i2, 1) let index22 = i2 parent2.childNodes.splice(index22 + 1, 0, targetNode) break } } return true }, } return fun[model]() } let isRun = true treeSelectSort(state$6.document.body, state$6.current.nodes) const list2 = model === 'before' ? state$6.current.nodes : state$6.current.nodes.reverse() for (const currentNode of list2) { isRun = move(currentNode) if (!isRun) break } } const getPermissions = (childNodes = []) => { let permissions = [] if (!childNodes) return permissions const loop = (childNodes2) => { for (let i2 = 0, iLen = childNodes2.length; i2 < iLen; i2++) { const node2 = childNodes2[i2] if (node2.permission) { permissions.push({ id: node2.id, name: node2.name, }) } if (node2.childNodes && node2.childNodes.length) loop(node2.childNodes) } } loop(childNodes) return permissions } const save = async (silent) => { app.current.project.current.page.save(silent) } const setCanvasZoom = (zoom) => { state$6.current.zoom = zoom state$6.current.translateX = 0 state$6.current.translateY = 0 } const copyClipboardImg = () => { const getImageUrl = (file2) => { return new Promise((resolve2, reject2) => { uploadBefore(file2).then((fileData) => { let newFile = new File([fileData], 'img.png') let param = new FormData() param.append('formFile', newFile) request({ url: `/api/v1/view/image`, method: 'post', data: param, }) .then((res) => { resolve2(res) }) .catch((err) => { reject2(err) }) }) }) } const setNode = (filename) => { let style2 = { position: 'absolute', left: '0px', top: '0px', } let newImgData = new CanvasNode$1({ id: createRandomId(), is: 'Img', name: '\u7C98\u8D34\u56FE\u7247', props: { filename, }, style: style2, childNodes: [], }) CanvasNode$1.getBody().appendChild(newImgData) } return new Promise((resolve2, reject2) => { if (navigator.clipboard) { navigator.clipboard ?.read() .then((res) => { let clipboardItem = res[0] for (const type4 of clipboardItem.types) { if (type4.indexOf('image') > -1) { clipboardItem .getType(type4) .then((res1) => { getImageUrl(res1).then((res2) => { setNode(res2) resolve2(true) }) }) .catch((err) => { console.error(err) }) } else { reject2(false) } } }) .catch(() => { reject2(false) }) } else { reject2(false) } }) } const emptyClipboard = () => { return new Promise((resolve2, reject2) => { let copyText = window.getSelection()?.toString() || '' if (navigator.clipboard) { if (copyText == '') { navigator.clipboard .writeText('') .then(() => { resolve2(true) }) .catch(() => { reject2(false) }) } } else { reject2(false) } }) } function lockedComponent(locked) { for (let i2 = 0, iLen = state$6.current.nodes.length; i2 < iLen; i2++) { const item2 = state$6.current.nodes[i2] item2.locked = locked } } function toggleComponentVisible(node2, visible) { eachNode((childNode) => { visible ? (childNode.style.visibility = 'inherit') : (childNode.style.visibility = 'hidden') }, node2) } function batchToggleComponentVisible(visible) { for (let i2 = 0, iLen = state$6.current.nodes.length; i2 < iLen; i2++) { const node2 = state$6.current.nodes[i2] toggleComponentVisible(node2, visible) } } function setDeepComponent(node2, key2, value2) { eachNode((childNode) => { childNode[key2] = value2 }, node2) } function batchSetDeepComponent(key2, value2) { const selectNodes = app.current.project.current.page.selectedCanvasNodeList const iLen = selectNodes.length for (let i2 = 0; i2 < iLen; i2++) { const node2 = selectNodes[i2] setDeepComponent(node2, key2, value2) } } const getGroupNode$1 = (nodes) => { let node2 if (nodes.parentNode) { node2 = nodes.parentNode.isGroup() ? getGroupNode$1(nodes.parentNode) : nodes } return node2 } class Page extends Base { id = '' name = '' children = [] document = { body: new CanvasNode$1({ name: '\u753B\u5E03', style: { width: '1920px', height: '1080px', backgroundColor: '#fff', }, }), } selectedCanvasNodeList = new Proxy([], { set(o2, k2, v4) { o2 = reactive(o2) if (v4 instanceof CanvasNode$1) { v4._selected = true } if (k2 === 'length') { o2.slice(v4, o2.length).forEach((n2) => { n2._selected = false }) } o2[k2] = v4 return true }, deleteProperty(o2, k2) { const v4 = reactive(o2[k2]) if (v4 instanceof CanvasNode$1) { v4._selected = false } return true }, }) history = new PageHistory(this) type = 1 updateTime sort parent hasEvent = false permissions = [] get parentId() { return this.parent?.id } constructor(object4 = {}) { if (object4.id) { const page2 = Page.getPageById(object4.id) if (page2) { return page2 } } super() Object.assign(this, object4) for (const [i2, child] of this.children.entries()) { this.children[i2] = new Page({ ...child, parent: this }) } } static getPageById(id2) { const loop = (pageList) => { for (const page2 of pageList) { if (id2 === page2.id) { return page2 } const rs2 = loop(page2.children) if (rs2) { return rs2 } } } return loop(app.current.project.pageList) } async copyPage() { const copyPage = async (page2) => { let sort3 = page2.getSort() if (sort3 != null) { sort3++ } const getId2 = async (pageNode) => { const id2 = JSON.parse(JSON.stringify(pageNode.id)) const data2 = { name: pageNode.name, parentId: pageNode.parentId || null, type: pageNode.type, sort: sort3 ? sort3 + 1 : 1, } const newId2 = pageNode.type === 0 ? await addPicture(data2) : await addPicture(data2, Number(id2)) return Number(newId2) } let newId = String(await getId2(page2)) let _page = lodash$2.exports.cloneDeep(page2) let newPage = new Page({ document: _page.document, permissions: _page.permissions, type: _page.type, id: newId, name: _page.name + '-' + newId, parent: void 0, children: [], }) if (!page2.parent) { Page.appendPageList(newPage, sort3) } if (page2.parent) { page2.parent?.appendChild(newPage, sort3) } return newPage } try { const page2 = await copyPage(this) const newPage = Page.getPageById(page2.id) if (!newPage) { console.warn('\u627E\u4E0D\u5230\u8BE5\u9875\u9762' + page2.id) return } const res = await getPicturesContent(newPage.id) let bodyInfo = res.content ? JSON.parse(res.content).body : {} let oldBody = new CanvasNode$1(bodyInfo) let newBody = oldBody.cloneNode().toJSON() let data2 = { ...res, content: JSON.stringify({ body: newBody, }), permissions: res.permissions, } await savePicturesContent(newPage.id, data2) return newPage } catch (error2) { toast('\u526F\u672C\u4FDD\u5B58\u5931\u8D25', 'error') } } static appendPageList(child, sort3 = null) { child.parent = void 0 const pageList = app.current.project.pageList if (sort3 != null) { pageList.splice(sort3, 0, child) } else { pageList.push(child) } } appendChild(child, sort3 = null) { child.remove() child.parent = this if (sort3 != null) { this.children.splice(sort3, 0, child) } else { this.children.push(child) } } remove() { const list2 = this.parent ? this.parent.children : app.current.project.pageList if (list2.indexOf(this) >= 0) list2.splice(list2.indexOf(this), 1) } getSort() { const list2 = this.parent ? this.parent.children : app.current.project.pageList let sort3 = list2.indexOf(this) return sort3 >= 0 ? sort3 : null } async save(silent = false) { const project = app.current.project const page2 = this const pageId = this.id if (!pageId && !silent) { toast('\u9875\u9762id\u4E0D\u80FD\u4E3A\u7A7A', 'error') return } project.moduleSavedStatusMap.Page = 'saving' const childNodes = page2.document.body.childNodes let permissions = page2.permissions let newPermissions = lodash$2.exports.uniqBy( [...getPermissions(childNodes), ...permissions], 'id' ) const filterPermissions = () => { let list2 = newPermissions.filter(function (per) { let have = false const loop = (childNodes2) => { if (have) return for (let i2 = 0, iLen = childNodes2.length; i2 < iLen; i2++) { const node2 = childNodes2[i2] if (node2.id === per.id) { have = true break } if (node2.childNodes && node2.childNodes.length) loop(node2.childNodes) } } if (!childNodes) return loop(childNodes) if (have) return per }) return list2 } project.current.page.permissions = filterPermissions() let hasEvent = this.document.body.blocks.length > 0 let data2 = { content: JSON.stringify(this.document), permissions: JSON.stringify(this.permissions), hasEvent, } this.hasEvent = hasEvent let savePagePromise = new Promise((resolve2, reject2) => { savePicturesContent(this.id, data2, true).then( (res) => { resolve2(res) }, (err) => { ElMessage.error('\u4FDD\u5B58\u5931\u8D25') reject2(err) } ) }) Promise.all([savePagePromise]) .then(() => { project.moduleSavedStatusMap.Page = 'saved' if (!silent) { toast('\u4FDD\u5B58\u6210\u529F', 'success') } }) .catch(() => { project.moduleSavedStatusMap.Page = 'fail' }) Language$1.collect(pageId) } } var __glob_0_8 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, Page, }, Symbol.toStringTag, { value: 'Module' } ) ) const audio = new Audio('') function checkFileType(fileUrl) { const ACCEPT = ['mp3', 'wav'] const suffix2 = fileUrl.slice(fileUrl.lastIndexOf('.') + 1) if (!ACCEPT.includes(suffix2)) { const message2 = Language$1._t( '\u8BF7\u9009\u62E9\u6B63\u786E\u7684\u97F3\u9891\u6587\u4EF6' ) + ` (${ACCEPT.join('/').toUpperCase()})` toast(message2, 'error') return false } return true } function audioPlay(fileUrl, loop) { audioPause() if (!checkFileType(fileUrl)) { return } audio.loop = loop audio.src = `${baseURL}/api/v1/view/resource/${fileUrl}` audio.play() } function audioPause() { audio.pause() } class Project$2 extends CanvasNode$1 { id = '' identifier = '' name = '' path = '' createTime = '' updateTime = '' constructor(object4 = {}) { const id2 = object4.id || '' if (Project$2.cache[id2]) return Project$2.cache[id2] super() Object.assign(this, object4) Block.createArray(this.blocks) Project$2.cache[id2] = this } static cache = {} get saved() { return this.saveStatus === 'saved' } get saveStatus() { const saveStatusTypes = Project$2.saveStatusTypes for (const name2 in this.moduleSavedStatusMap) { const status = this.moduleSavedStatusMap[name2] if (status === saveStatusTypes.saving) { return saveStatusTypes.saving } if (status === saveStatusTypes.fail) { return saveStatusTypes.fail } if (status === saveStatusTypes.unsaved) { return saveStatusTypes.unsaved } } return saveStatusTypes.saved } moduleSavedStatusMap = { Variable: 'saved', Page: 'saved', Base: 'saved', Data: 'saved', Alarm: 'saved', Language: 'saved', Connection: 'saved', } static saveStatusTypes = { saved: 'saved', saving: 'saving', fail: 'fail', unsaved: 'unsaved', } pageList = [] languageList = [] variableMap = {} variableValueMap = new Proxy(this.variableMap, { get(target2, name2) { if (!{}.hasOwnProperty.call(target2, name2)) { return target2[name2] } return target2[name2]?.value }, set(target2, name2, value2) { const variable = target2[name2] variable.set(value2) return true }, }) variableOldValueMap = new Proxy(this.variableMap, { get(target2, name2) { return target2[name2]?.oldValue ?? target2[name2]?.value }, }) current = { page: new Page(), language: new Language$1({ lang: 'original' }, this), pageList: [], } blocks = [] remove() { const projectList = app.projectList projectList.splice(projectList.indexOf(this)) } toast(...args) { toast(...args) } setVariable(name2, value2) { Variable.map[name2].set(value2) } waiting(time2 = 0) { return new Promise((resolve2) => { setTimeout(() => resolve2(true), time2) }) } sendBroadcast(message2) { const event = new CustomEvent(`broadcast`, { detail: message2, }) window.dispatchEvent(event) } openVirtualKeyboard() { dispatchEvent(new Event('openVirtualKeyboard')) } closeVirtualKeyboard() { dispatchEvent(new Event('closeVirtualKeyboard')) } audioPlay(fileUrl, loop) { audioPlay(fileUrl, loop) } audioPause() { audioPause() } } var __glob_0_11 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, Project: Project$2, }, Symbol.toStringTag, { value: 'Module' } ) ) class Config extends Base { isFullAllWindow = false isFullScreen = true isMenu = true sync() { const localConfig = this.getSession() Object.assign(this, localConfig) this.setSession() } getSession() { return Session.get(Config.STORAGE_KEY) || {} } setSession() { Session.set(Config.STORAGE_KEY, this) } constructor() { super() const self2 = this this.sync() return new Proxy(this, { get(obj, key2) { const session = self2.getSession() return session[key2] }, set(obj, key2, value2) { obj[key2] = value2 self2.setSession() return true }, }) } static STORAGE_KEY = 'config' } var __glob_0_5 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, Config, }, Symbol.toStringTag, { value: 'Module' } ) ) let app class App extends Base { constructor() { if (app) return app super() app = this window.app = app } config = new Config() mode = mode editing = editing running = running current = { project: new Proxy(new Project$2(), { get(o2, k2) { if (k2 === 'variableMap') { console.error('!project') throw '!project' } return o2[k2] }, }), } projectList = [] winList = [] viewStatus = { toolbar: { expended: true, }, sidebar: { expended: true, width: 230, limit: { min: 230, max: 600, }, content: { page: { expended: true, height: '50%', }, node: { expended: true, height: '50%', }, }, }, componentBox: { show: true, }, } dataeventSocket = {} async setCurrentProject(object4) { const project = new Project$2(object4) app.current.project = project let info = await request.get(`/api/v1/project/${object4.id}/info`) Object.assign(project, info) App.updateCurrentProjectLocalInfo() await request.get(`/api/v1/event/get?key=${project.id}`).then((res) => { if (!res) return project.blocks = Block.createArray(res) }) if (app.editing) { this.unwatchProjectBlocks() this.unwatchProjectBlocks = watch$1( () => { return project.blocks }, lodash$2.exports.debounce((blocks2) => { request({ url: `/api/v1/event/addorupdate?key=${project.id}`, method: 'post', data: JSON.stringify(blocks2), silent: true, }) }, 500), { deep: true, } ) } } unwatchProjectBlocks() {} static updateCurrentProjectLocalInfo() { const project = app.current.project if (!project.identifier) return Session.set('X-Project-ID', project.id) Session.set('X-Project', project.identifier) Session.set('X-Project-Name', project.name) const maxAge = 60 * 60 * 24 * 365 * 100 document.cookie = `project=${project.identifier}; max-age=${maxAge}` document.cookie = `X-Project=${project.identifier}; max-age=${maxAge}` } } addEventListener('focus', App.updateCurrentProjectLocalInfo) function createApp() { return new App() } function getApp() { return new App() } async function closeTip(msg, btnList) { client.invoke( ({ electron: electron2 }, msg2, btnList2) => { let { dialog, BrowserWindow } = electron2 const win = BrowserWindow.getFocusedWindow() win?.webContents.once('will-prevent-unload', (event) => { event.preventDefault() const choice = dialog.showMessageBoxSync(win, { type: 'question', buttons: btnList2, title: '\u63D0\u793A', message: msg2, defaultId: 0, cancelId: 1, noLink: true, }) const leave = choice === 1 if (leave) { event.defaultPrevented = false } }) }, msg, btnList ) } window.onbeforeunload = () => { let isUnSave = void 0 let saved = !app.current.project.saved let isClient2 = client.isClient() saved && (isUnSave = true) if (isClient2) { if (opener === null) { app.winList = app.winList.filter((win) => !win.closed) saved = app.winList.some((win) => !win.app.current.project.saved) saved && (isUnSave = true) } if (isUnSave) { closeTip( '\u5B58\u5728\u5DE5\u7A0B\u6587\u4EF6\u88AB\u4FEE\u6539\uFF0C\u5173\u95ED\u540E\u6240\u505A\u4FEE\u6539\u5C06\u4F1A\u4E22\u5931\uFF0C\u662F\u5426\u5173\u95ED\u7A97\u53E3', ['\u5173\u95ED', '\u53D6\u6D88'] ) } else if (opener === null && app.winList.length > 0) { isUnSave = true closeTip( '\u5B58\u5728\u5DE5\u7A0B\u5904\u4E8E\u7F16\u8F91\u72B6\u6001\uFF0C\u5173\u95ED\u6B64\u9875\u9762\u4F1A\u540C\u65F6\u5173\u95ED\u5176\u4ED6\u5DE5\u7A0B\u9875\u9762\uFF0C\u662F\u5426\u7EE7\u7EED\u64CD\u4F5C\uFF1F', ['\u662F', '\u5426'] ) } } return isUnSave } window.onunload = async () => { if (opener && editing) { await request.post('/api/v1/project/service/stop') } } var __glob_0_0 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, get app() { return app }, App, createApp, getApp, }, Symbol.toStringTag, { value: 'Module' } ) ) const getters = { get app() { return getApp() }, get project() { return this.app.current.project }, get page() { return this.app.current.project.current.page }, get document() { return this.app.current.project.current.page.document }, get body() { return this.app.current.project.current.page.document.body }, get selectedCanvasNodeList() { return this.app.current.project.current.page.selectedCanvasNodeList }, get nodes() { return this.selectedCanvasNodeList }, get language() { return this.app.current.project.current.language }, } const $$f = getters var __glob_0_16 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, getters, $: $$f, default: getters, App, createApp, getApp, get app() { return app }, }, Symbol.toStringTag, { value: 'Module' } ) ) var zhCn$1 = {} ;(function (exports2) { Object.defineProperty(exports2, '__esModule', { value: true }) var zhCn2 = { name: 'zh-cn', el: { colorpicker: { confirm: '\u786E\u5B9A', clear: '\u6E05\u7A7A', }, datepicker: { now: '\u6B64\u523B', today: '\u4ECA\u5929', cancel: '\u53D6\u6D88', clear: '\u6E05\u7A7A', confirm: '\u786E\u5B9A', selectDate: '\u9009\u62E9\u65E5\u671F', selectTime: '\u9009\u62E9\u65F6\u95F4', startDate: '\u5F00\u59CB\u65E5\u671F', startTime: '\u5F00\u59CB\u65F6\u95F4', endDate: '\u7ED3\u675F\u65E5\u671F', endTime: '\u7ED3\u675F\u65F6\u95F4', prevYear: '\u524D\u4E00\u5E74', nextYear: '\u540E\u4E00\u5E74', prevMonth: '\u4E0A\u4E2A\u6708', nextMonth: '\u4E0B\u4E2A\u6708', year: '\u5E74', month1: '1 \u6708', month2: '2 \u6708', month3: '3 \u6708', month4: '4 \u6708', month5: '5 \u6708', month6: '6 \u6708', month7: '7 \u6708', month8: '8 \u6708', month9: '9 \u6708', month10: '10 \u6708', month11: '11 \u6708', month12: '12 \u6708', weeks: { sun: '\u65E5', mon: '\u4E00', tue: '\u4E8C', wed: '\u4E09', thu: '\u56DB', fri: '\u4E94', sat: '\u516D', }, months: { jan: '\u4E00\u6708', feb: '\u4E8C\u6708', mar: '\u4E09\u6708', apr: '\u56DB\u6708', may: '\u4E94\u6708', jun: '\u516D\u6708', jul: '\u4E03\u6708', aug: '\u516B\u6708', sep: '\u4E5D\u6708', oct: '\u5341\u6708', nov: '\u5341\u4E00\u6708', dec: '\u5341\u4E8C\u6708', }, }, select: { loading: '\u52A0\u8F7D\u4E2D', noMatch: '\u65E0\u5339\u914D\u6570\u636E', noData: '\u65E0\u6570\u636E', placeholder: '\u8BF7\u9009\u62E9', }, cascader: { noMatch: '\u65E0\u5339\u914D\u6570\u636E', loading: '\u52A0\u8F7D\u4E2D', placeholder: '\u8BF7\u9009\u62E9', noData: '\u6682\u65E0\u6570\u636E', }, pagination: { goto: '\u524D\u5F80', pagesize: '\u6761/\u9875', total: '\u5171 {total} \u6761', pageClassifier: '\u9875', deprecationWarning: '\u4F60\u4F7F\u7528\u4E86\u4E00\u4E9B\u5DF2\u88AB\u5E9F\u5F03\u7684\u7528\u6CD5\uFF0C\u8BF7\u53C2\u8003 el-pagination \u7684\u5B98\u65B9\u6587\u6863', }, messagebox: { title: '\u63D0\u793A', confirm: '\u786E\u5B9A', cancel: '\u53D6\u6D88', error: '\u8F93\u5165\u7684\u6570\u636E\u4E0D\u5408\u6CD5!', }, upload: { deleteTip: '\u6309 delete \u952E\u53EF\u5220\u9664', delete: '\u5220\u9664', preview: '\u67E5\u770B\u56FE\u7247', continue: '\u7EE7\u7EED\u4E0A\u4F20', }, table: { emptyText: '\u6682\u65E0\u6570\u636E', confirmFilter: '\u7B5B\u9009', resetFilter: '\u91CD\u7F6E', clearFilter: '\u5168\u90E8', sumText: '\u5408\u8BA1', }, tree: { emptyText: '\u6682\u65E0\u6570\u636E', }, transfer: { noMatch: '\u65E0\u5339\u914D\u6570\u636E', noData: '\u65E0\u6570\u636E', titles: ['\u5217\u8868 1', '\u5217\u8868 2'], filterPlaceholder: '\u8BF7\u8F93\u5165\u641C\u7D22\u5185\u5BB9', noCheckedFormat: '\u5171 {total} \u9879', hasCheckedFormat: '\u5DF2\u9009 {checked}/{total} \u9879', }, image: { error: '\u52A0\u8F7D\u5931\u8D25', }, pageHeader: { title: '\u8FD4\u56DE', }, popconfirm: { confirmButtonText: '\u786E\u5B9A', cancelButtonText: '\u53D6\u6D88', }, }, } exports2['default'] = zhCn2 })(zhCn$1) var zhCn = /* @__PURE__ */ getDefaultExportFromCjs(zhCn$1) var en$1 = {} ;(function (exports2) { Object.defineProperty(exports2, '__esModule', { value: true }) var English2 = { name: 'en', el: { colorpicker: { confirm: 'OK', clear: 'Clear', }, datepicker: { now: 'Now', today: 'Today', cancel: 'Cancel', clear: 'Clear', confirm: 'OK', selectDate: 'Select date', selectTime: 'Select time', startDate: 'Start Date', startTime: 'Start Time', endDate: 'End Date', endTime: 'End Time', prevYear: 'Previous Year', nextYear: 'Next Year', prevMonth: 'Previous Month', nextMonth: 'Next Month', year: '', month1: 'January', month2: 'February', month3: 'March', month4: 'April', month5: 'May', month6: 'June', month7: 'July', month8: 'August', month9: 'September', month10: 'October', month11: 'November', month12: 'December', week: 'week', weeks: { sun: 'Sun', mon: 'Mon', tue: 'Tue', wed: 'Wed', thu: 'Thu', fri: 'Fri', sat: 'Sat', }, months: { jan: 'Jan', feb: 'Feb', mar: 'Mar', apr: 'Apr', may: 'May', jun: 'Jun', jul: 'Jul', aug: 'Aug', sep: 'Sep', oct: 'Oct', nov: 'Nov', dec: 'Dec', }, }, select: { loading: 'Loading', noMatch: 'No matching data', noData: 'No data', placeholder: 'Select', }, cascader: { noMatch: 'No matching data', loading: 'Loading', placeholder: 'Select', noData: 'No data', }, pagination: { goto: 'Go to', pagesize: '/page', total: 'Total {total}', pageClassifier: '', deprecationWarning: 'Deprecated usages detected, please refer to the el-pagination documentation for more details', }, messagebox: { title: 'Message', confirm: 'OK', cancel: 'Cancel', error: 'Illegal input', }, upload: { deleteTip: 'press delete to remove', delete: 'Delete', preview: 'Preview', continue: 'Continue', }, table: { emptyText: 'No Data', confirmFilter: 'Confirm', resetFilter: 'Reset', clearFilter: 'All', sumText: 'Sum', }, tree: { emptyText: 'No Data', }, transfer: { noMatch: 'No matching data', noData: 'No data', titles: ['List 1', 'List 2'], filterPlaceholder: 'Enter keyword', noCheckedFormat: '{total} items', hasCheckedFormat: '{checked}/{total} checked', }, image: { error: 'FAILED', }, pageHeader: { title: 'Back', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } exports2['default'] = English2 })(en$1) var en = /* @__PURE__ */ getDefaultExportFromCjs(en$1) var ja$1 = {} ;(function (exports2) { Object.defineProperty(exports2, '__esModule', { value: true }) var ja2 = { name: 'ja', el: { colorpicker: { confirm: 'OK', clear: '\u30AF\u30EA\u30A2', }, datepicker: { now: '\u73FE\u5728', today: '\u4ECA\u65E5', cancel: '\u30AD\u30E3\u30F3\u30BB\u30EB', clear: '\u30AF\u30EA\u30A2', confirm: 'OK', selectDate: '\u65E5\u4ED8\u3092\u9078\u629E', selectTime: '\u6642\u9593\u3092\u9078\u629E', startDate: '\u958B\u59CB\u65E5', startTime: '\u958B\u59CB\u6642\u9593', endDate: '\u7D42\u4E86\u65E5', endTime: '\u7D42\u4E86\u6642\u9593', prevYear: '\u524D\u5E74', nextYear: '\u7FCC\u5E74', prevMonth: '\u524D\u6708', nextMonth: '\u7FCC\u6708', year: '\u5E74', month1: '1\u6708', month2: '2\u6708', month3: '3\u6708', month4: '4\u6708', month5: '5\u6708', month6: '6\u6708', month7: '7\u6708', month8: '8\u6708', month9: '9\u6708', month10: '10\u6708', month11: '11\u6708', month12: '12\u6708', weeks: { sun: '\u65E5', mon: '\u6708', tue: '\u706B', wed: '\u6C34', thu: '\u6728', fri: '\u91D1', sat: '\u571F', }, months: { jan: '1\u6708', feb: '2\u6708', mar: '3\u6708', apr: '4\u6708', may: '5\u6708', jun: '6\u6708', jul: '7\u6708', aug: '8\u6708', sep: '9\u6708', oct: '10\u6708', nov: '11\u6708', dec: '12\u6708', }, }, select: { loading: '\u30ED\u30FC\u30C9\u4E2D', noMatch: '\u30C7\u30FC\u30BF\u306A\u3057', noData: '\u30C7\u30FC\u30BF\u306A\u3057', placeholder: '\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044', }, cascader: { noMatch: '\u30C7\u30FC\u30BF\u306A\u3057', loading: '\u30ED\u30FC\u30C9\u4E2D', placeholder: '\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044', noData: '\u30C7\u30FC\u30BF\u306A\u3057', }, pagination: { goto: '', pagesize: '\u4EF6/\u30DA\u30FC\u30B8', total: '\u7DCF\u8A08 {total} \u4EF6', pageClassifier: '\u30DA\u30FC\u30B8\u76EE\u3078', }, messagebox: { title: '\u30E1\u30C3\u30BB\u30FC\u30B8', confirm: 'OK', cancel: '\u30AD\u30E3\u30F3\u30BB\u30EB', error: '\u6B63\u3057\u304F\u306A\u3044\u5165\u529B', }, upload: { deleteTip: 'Del\u30AD\u30FC\u3092\u62BC\u3057\u3066\u524A\u9664\u3059\u308B', delete: '\u524A\u9664\u3059\u308B', preview: '\u30D7\u30EC\u30D3\u30E5\u30FC', continue: '\u7D9A\u884C\u3059\u308B', }, table: { emptyText: '\u30C7\u30FC\u30BF\u306A\u3057', confirmFilter: '\u78BA\u8A8D', resetFilter: '\u521D\u671F\u5316', clearFilter: '\u3059\u3079\u3066', sumText: '\u5408\u8A08', }, tree: { emptyText: '\u30C7\u30FC\u30BF\u306A\u3057', }, transfer: { noMatch: '\u30C7\u30FC\u30BF\u306A\u3057', noData: '\u30C7\u30FC\u30BF\u306A\u3057', titles: ['\u30EA\u30B9\u30C8 1', '\u30EA\u30B9\u30C8 2'], filterPlaceholder: '\u30AD\u30FC\u30EF\u30FC\u30C9\u3092\u5165\u529B', noCheckedFormat: '\u7DCF\u8A08 {total} \u4EF6', hasCheckedFormat: '{checked}/{total} \u3092\u9078\u629E\u3057\u305F', }, image: { error: '\u5931\u6557', }, pageHeader: { title: '\u623B\u308B', }, popconfirm: { confirmButtonText: '\u306F\u3044', cancelButtonText: '\u3044\u3044\u3048', }, }, } exports2['default'] = ja2 })(ja$1) var ja = /* @__PURE__ */ getDefaultExportFromCjs(ja$1) var th$1 = {} ;(function (exports2) { Object.defineProperty(exports2, '__esModule', { value: true }) var th2 = { name: 'th', el: { colorpicker: { confirm: '\u0E15\u0E01\u0E25\u0E07', clear: '\u0E25\u0E49\u0E32\u0E07\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25', }, datepicker: { now: '\u0E15\u0E2D\u0E19\u0E19\u0E35\u0E49', today: '\u0E27\u0E31\u0E19\u0E19\u0E35\u0E49', cancel: '\u0E22\u0E01\u0E40\u0E25\u0E34\u0E01', clear: '\u0E25\u0E49\u0E32\u0E07\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25', confirm: '\u0E15\u0E01\u0E25\u0E07', selectDate: '\u0E40\u0E25\u0E37\u0E2D\u0E01\u0E27\u0E31\u0E19\u0E17\u0E35\u0E48', selectTime: '\u0E40\u0E25\u0E37\u0E2D\u0E01\u0E40\u0E27\u0E25\u0E32', startDate: '\u0E27\u0E31\u0E19\u0E17\u0E35\u0E48\u0E40\u0E23\u0E34\u0E48\u0E21\u0E15\u0E49\u0E19', startTime: '\u0E40\u0E27\u0E25\u0E32\u0E40\u0E23\u0E34\u0E48\u0E21\u0E15\u0E49\u0E19', endDate: '\u0E27\u0E31\u0E19\u0E17\u0E35\u0E48\u0E2A\u0E34\u0E49\u0E19\u0E2A\u0E38\u0E14', endTime: '\u0E40\u0E27\u0E25\u0E32\u0E2A\u0E34\u0E49\u0E19\u0E2A\u0E38\u0E14', prevYear: '\u0E1B\u0E35\u0E01\u0E48\u0E2D\u0E19\u0E2B\u0E19\u0E49\u0E32', nextYear: '\u0E1B\u0E35\u0E16\u0E31\u0E14\u0E44\u0E1B', prevMonth: '\u0E40\u0E14\u0E37\u0E2D\u0E19\u0E01\u0E48\u0E2D\u0E19\u0E2B\u0E19\u0E49\u0E32', nextMonth: '\u0E40\u0E14\u0E37\u0E2D\u0E19\u0E16\u0E31\u0E14\u0E44\u0E1B', year: '\u0E1B\u0E35', month1: '\u0E21\u0E01\u0E23\u0E32\u0E04\u0E21', month2: '\u0E01\u0E38\u0E21\u0E20\u0E32\u0E1E\u0E31\u0E19\u0E18\u0E4C', month3: '\u0E21\u0E35\u0E19\u0E32\u0E04\u0E21', month4: '\u0E40\u0E21\u0E29\u0E32\u0E22\u0E19', month5: '\u0E1E\u0E24\u0E29\u0E20\u0E32\u0E04\u0E21', month6: '\u0E21\u0E34\u0E16\u0E38\u0E19\u0E32\u0E22\u0E19', month7: '\u0E01\u0E23\u0E01\u0E0E\u0E32\u0E04\u0E21', month8: '\u0E2A\u0E34\u0E07\u0E2B\u0E32\u0E04\u0E21', month9: '\u0E01\u0E31\u0E19\u0E22\u0E32\u0E22\u0E19', month10: '\u0E15\u0E38\u0E25\u0E32\u0E04\u0E21', month11: '\u0E1E\u0E24\u0E28\u0E08\u0E34\u0E01\u0E32\u0E22\u0E19', month12: '\u0E18\u0E31\u0E19\u0E27\u0E32\u0E04\u0E21', weeks: { sun: '\u0E2D\u0E32', mon: '\u0E08', tue: '\u0E2D', wed: '\u0E1E', thu: '\u0E1E\u0E24', fri: '\u0E28', sat: '\u0E2A', }, months: { jan: '\u0E21\u0E01\u0E23\u0E32', feb: '\u0E01\u0E38\u0E21\u0E20\u0E32', mar: '\u0E21\u0E35\u0E19\u0E32', apr: '\u0E40\u0E21\u0E29\u0E32', may: '\u0E1E\u0E24\u0E29\u0E20\u0E32', jun: '\u0E21\u0E34\u0E16\u0E38\u0E19\u0E32', jul: '\u0E01\u0E23\u0E01\u0E0E\u0E32', aug: '\u0E2A\u0E34\u0E07\u0E2B\u0E32', sep: '\u0E01\u0E31\u0E19\u0E22\u0E32', oct: '\u0E15\u0E38\u0E25\u0E32', nov: '\u0E1E\u0E24\u0E28\u0E08\u0E34\u0E01\u0E32', dec: '\u0E18\u0E31\u0E19\u0E27\u0E32', }, }, select: { loading: '\u0E01\u0E33\u0E25\u0E31\u0E07\u0E42\u0E2B\u0E25\u0E14', noMatch: '\u0E44\u0E21\u0E48\u0E1E\u0E1A\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E17\u0E35\u0E48\u0E15\u0E23\u0E07\u0E01\u0E31\u0E19', noData: '\u0E44\u0E21\u0E48\u0E1E\u0E1A\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25', placeholder: '\u0E40\u0E25\u0E37\u0E2D\u0E01', }, cascader: { noMatch: '\u0E44\u0E21\u0E48\u0E1E\u0E1A\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E17\u0E35\u0E48\u0E15\u0E23\u0E07\u0E01\u0E31\u0E19', loading: '\u0E01\u0E33\u0E25\u0E31\u0E07\u0E42\u0E2B\u0E25\u0E14', placeholder: '\u0E40\u0E25\u0E37\u0E2D\u0E01', noData: '\u0E44\u0E21\u0E48\u0E1E\u0E1A\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25', }, pagination: { goto: '\u0E44\u0E1B\u0E17\u0E35\u0E48', pagesize: '/\u0E2B\u0E19\u0E49\u0E32', total: '\u0E17\u0E31\u0E49\u0E07\u0E2B\u0E21\u0E14 {total}', pageClassifier: '', }, messagebox: { title: '\u0E02\u0E49\u0E2D\u0E04\u0E27\u0E32\u0E21', confirm: '\u0E15\u0E01\u0E25\u0E07', cancel: '\u0E22\u0E01\u0E40\u0E25\u0E34\u0E01', error: '\u0E04\u0E38\u0E13\u0E1B\u0E49\u0E2D\u0E19\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E44\u0E21\u0E48\u0E16\u0E39\u0E01\u0E15\u0E49\u0E2D\u0E07', }, upload: { deleteTip: '\u0E01\u0E14\u0E1B\u0E38\u0E48\u0E21 "\u0E25\u0E1A" \u0E40\u0E1E\u0E37\u0E48\u0E2D\u0E25\u0E1A\u0E2D\u0E2D\u0E01', delete: '\u0E25\u0E1A', preview: '\u0E15\u0E31\u0E27\u0E2D\u0E22\u0E48\u0E32\u0E07', continue: '\u0E17\u0E33\u0E15\u0E48\u0E2D', }, table: { emptyText: '\u0E44\u0E21\u0E48\u0E1E\u0E1A\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25', confirmFilter: '\u0E22\u0E37\u0E19\u0E22\u0E31\u0E19', resetFilter: '\u0E23\u0E35\u0E40\u0E0B\u0E47\u0E15', clearFilter: '\u0E17\u0E31\u0E49\u0E07\u0E2B\u0E21\u0E14', sumText: '\u0E23\u0E27\u0E21', }, tree: { emptyText: '\u0E44\u0E21\u0E48\u0E1E\u0E1A\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25', }, transfer: { noMatch: '\u0E44\u0E21\u0E48\u0E1E\u0E1A\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25\u0E17\u0E35\u0E48\u0E15\u0E23\u0E07\u0E01\u0E31\u0E19', noData: '\u0E44\u0E21\u0E48\u0E1E\u0E1A\u0E02\u0E49\u0E2D\u0E21\u0E39\u0E25', titles: ['List 1', 'List 2'], filterPlaceholder: '\u0E01\u0E23\u0E2D\u0E01\u0E04\u0E35\u0E22\u0E4C\u0E40\u0E27\u0E34\u0E23\u0E4C\u0E14', noCheckedFormat: '{total} items', hasCheckedFormat: '{checked}/{total} checked', }, image: { error: 'FAILED', }, pageHeader: { title: '\u0E22\u0E49\u0E2D\u0E19\u0E01\u0E25\u0E31\u0E1A', }, popconfirm: { confirmButtonText: 'Yes', cancelButtonText: 'No', }, }, } exports2['default'] = th2 })(th$1) var th = /* @__PURE__ */ getDefaultExportFromCjs(th$1) const modulesFiles$1 = { '../../node_modules/element-plus/es/locale/lang/af.mjs': __glob_8_0, '../../node_modules/element-plus/es/locale/lang/ar.mjs': __glob_8_1, '../../node_modules/element-plus/es/locale/lang/az.mjs': __glob_8_2, '../../node_modules/element-plus/es/locale/lang/bg.mjs': __glob_8_3, '../../node_modules/element-plus/es/locale/lang/bn.mjs': __glob_8_4, '../../node_modules/element-plus/es/locale/lang/ca.mjs': __glob_8_5, '../../node_modules/element-plus/es/locale/lang/cs.mjs': __glob_8_6, '../../node_modules/element-plus/es/locale/lang/da.mjs': __glob_8_7, '../../node_modules/element-plus/es/locale/lang/de.mjs': __glob_8_8, '../../node_modules/element-plus/es/locale/lang/el.mjs': __glob_8_9, '../../node_modules/element-plus/es/locale/lang/en.mjs': __glob_8_10, '../../node_modules/element-plus/es/locale/lang/eo.mjs': __glob_8_11, '../../node_modules/element-plus/es/locale/lang/es.mjs': __glob_8_12, '../../node_modules/element-plus/es/locale/lang/et.mjs': __glob_8_13, '../../node_modules/element-plus/es/locale/lang/eu.mjs': __glob_8_14, '../../node_modules/element-plus/es/locale/lang/fa.mjs': __glob_8_15, '../../node_modules/element-plus/es/locale/lang/fi.mjs': __glob_8_16, '../../node_modules/element-plus/es/locale/lang/fr.mjs': __glob_8_17, '../../node_modules/element-plus/es/locale/lang/he.mjs': __glob_8_18, '../../node_modules/element-plus/es/locale/lang/hr.mjs': __glob_8_19, '../../node_modules/element-plus/es/locale/lang/hu.mjs': __glob_8_20, '../../node_modules/element-plus/es/locale/lang/hy-am.mjs': __glob_8_21, '../../node_modules/element-plus/es/locale/lang/id.mjs': __glob_8_22, '../../node_modules/element-plus/es/locale/lang/it.mjs': __glob_8_23, '../../node_modules/element-plus/es/locale/lang/ja.mjs': __glob_8_24, '../../node_modules/element-plus/es/locale/lang/kk.mjs': __glob_8_25, '../../node_modules/element-plus/es/locale/lang/km.mjs': __glob_8_26, '../../node_modules/element-plus/es/locale/lang/ko.mjs': __glob_8_27, '../../node_modules/element-plus/es/locale/lang/ku.mjs': __glob_8_28, '../../node_modules/element-plus/es/locale/lang/ky.mjs': __glob_8_29, '../../node_modules/element-plus/es/locale/lang/lt.mjs': __glob_8_30, '../../node_modules/element-plus/es/locale/lang/lv.mjs': __glob_8_31, '../../node_modules/element-plus/es/locale/lang/mg.mjs': __glob_8_32, '../../node_modules/element-plus/es/locale/lang/mn.mjs': __glob_8_33, '../../node_modules/element-plus/es/locale/lang/nb-no.mjs': __glob_8_34, '../../node_modules/element-plus/es/locale/lang/nl.mjs': __glob_8_35, '../../node_modules/element-plus/es/locale/lang/pa.mjs': __glob_8_36, '../../node_modules/element-plus/es/locale/lang/pl.mjs': __glob_8_37, '../../node_modules/element-plus/es/locale/lang/pt-br.mjs': __glob_8_38, '../../node_modules/element-plus/es/locale/lang/pt.mjs': __glob_8_39, '../../node_modules/element-plus/es/locale/lang/ro.mjs': __glob_8_40, '../../node_modules/element-plus/es/locale/lang/ru.mjs': __glob_8_41, '../../node_modules/element-plus/es/locale/lang/sk.mjs': __glob_8_42, '../../node_modules/element-plus/es/locale/lang/sl.mjs': __glob_8_43, '../../node_modules/element-plus/es/locale/lang/sr.mjs': __glob_8_44, '../../node_modules/element-plus/es/locale/lang/sv.mjs': __glob_8_45, '../../node_modules/element-plus/es/locale/lang/ta.mjs': __glob_8_46, '../../node_modules/element-plus/es/locale/lang/th.mjs': __glob_8_47, '../../node_modules/element-plus/es/locale/lang/tk.mjs': __glob_8_48, '../../node_modules/element-plus/es/locale/lang/tr.mjs': __glob_8_49, '../../node_modules/element-plus/es/locale/lang/ug-cn.mjs': __glob_8_50, '../../node_modules/element-plus/es/locale/lang/uk.mjs': __glob_8_51, '../../node_modules/element-plus/es/locale/lang/uz-uz.mjs': __glob_8_52, '../../node_modules/element-plus/es/locale/lang/vi.mjs': __glob_8_53, '../../node_modules/element-plus/es/locale/lang/zh-cn.mjs': __glob_8_54, '../../node_modules/element-plus/es/locale/lang/zh-tw.mjs': __glob_8_55, } const locales = {} const regex = /..\/..\/node_modules\/element-plus\/es\/locale\/lang\// const regex2 = /\.mjs/ for (const key2 in modulesFiles$1) { locales[key2.replace(regex, '').replace(regex2, '')] = modulesFiles$1[key2].default } class Language$1 extends Base { project lang followLang map = {} staticMap = {} constructor( { lang, running: running2 = false }, project = app.current.project ) { super() this.project = project this.lang = lang this.followLang = this.lang === 'auto' ? navigator.language : this.lang running2 && this.setLang(this.lang) this.fetch() } static isOriginal() { try { const project = app.current.project const { language } = project.current return language.lang === 'original' } catch (error2) { return false } } setLang(lang) { localStorage.setItem('lang', lang) } async fetch() { if (this.followLang === 'original') { Language$1.trigger(this) return } const mappingType = 1 const result = await request.put( `/api/v1/multiplelanguage/${mappingType}/${this.followLang}` ) this.map = this.handleMap(result) this.staticMap = await request.get(`/api/v1/multiplelanguage/static`) Language$1.trigger(this) } handleMap(maps) { let res = {} maps.map((item2) => { res[item2.originalText] = item2.translationText }) return res } static scope(namespace) { return function (rawText) { return Language$1._t(rawText, namespace) } } static initDefautLangInRun(running2) { if (!running2) return const lang = localStorage.getItem('lang') const _lang = lang === null ? 'auto' : lang app.current.project.current.language = new Language$1({ lang: _lang }) } static langs = { original: 'original', auto: 'auto', 'zh-CN': 'zh-CN', 'en-US': 'en-US', } static store = [] static collectingRef = ref(0) static collecting = false static collect(pageId) { Language$1.resetStore() this.collecting = true Language$1.collectingRef.value = Math.random() nextTick(() => { this.saveRawText(pageId) this.collecting = false }) } static getTranslateText = (rawText) => { const _rawText = rawText.trim() const language = app.current.project?.current?.language return language?.map[_rawText] || rawText } static t(rawText) { Language$1.collectingRef.value if (!rawText) return rawText const text2 = Language$1.getTranslateText(rawText) if (Language$1.collecting && Language$1.isOriginal()) { Language$1.store.push(rawText.trim()) } return text2 } static _t(rawText, namespace = 'UI') { if (!rawText) return rawText const language = app.current.project?.current?.language const map2 = language?.staticMap[namespace] || {} return map2[rawText] || rawText } static toLanguage(rawText, noLanguage) { if (noLanguage) return rawText return Language$1._t(rawText) } static saveRawText(pageId, clear2 = false) { if (!Language$1.isOriginal()) return Language$1.triggerRenderFn() setTimeout(() => { const data2 = { mappingType: 1, pageId: String(pageId), originalTexts: clear2 ? [] : [...new Set(Language$1.store)], } request.put('/api/v1/multiplelanguage/sync', data2, { silent: true }) }, 0) } static resetStore() { Language$1.store.length = 0 } static list = [] static useChange(fn2) { Language$1.list.push(fn2) onUnmounted(() => { Language$1.remove(fn2) }) } static trigger(lang) { const fns = Language$1.list if (!fns || fns.length === 0) return false for (let i2 = 0, fn2; (fn2 = fns[i2]); i2++) { fn2(lang) } } static remove(fn2) { const fns = Language$1.list for (let len2 = fns.length - 1; len2 >= 0; len2--) { const _fn = fns[len2] if (_fn === fn2) { fns.splice(len2, 1) } } } static triggerRenderData = reactive({ i: 0 }) static triggerRenderFn() { Language$1.triggerRenderData.i = Math.random() } static useElementPlusI18n() { let local = ref(zhCn) const map2 = { original: zhCn, 'zh-CN': zhCn, 'en-US': en, ja, th, ...locales, } const initLang = (language) => { local.value = map2[language.followLang] || en } Language$1.useChange((language) => { initLang(language) }) onMounted(() => { initLang(app.current.project.current.language) }) return { local } } static getLangReqHeader() { const acceptLang = Language$1.isOriginal() ? 'zh-CN' : app.current.project.current.language.followLang return `${acceptLang},zh-CN;q=0.9,en-US;q=0.8,en;q=0.7,ja;q=0.6,th;q=0.5` } } window.t = Language$1.t window._t = Language$1._t var __glob_0_7 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, Language: Language$1, }, Symbol.toStringTag, { value: 'Module' } ) ) let baseURL = '' const params = new URLSearchParams(location.search) baseURL = baseURL || params.get('baseURL') || '' console.info('[baseURL]', baseURL) const service = axios.create({ baseURL, headers: { 'Content-Type': 'application/json;charset=UTF-8', }, }) let reqNum = 0 let loadingOptions = { fullscreen: true, background: 'rgba(0,0,0,.05)', customClass: 'delay-loading', } let loadingInstance let lastClickTime = Date.now() addEventListener( 'click', () => { lastClickTime = Date.now() }, true ) const setLoading = (silent) => { if (silent) return reqNum++ if (reqNum === 1) { loadingInstance = ElLoading.service({ ...loadingOptions, customClass: `${loadingOptions.customClass} ${ Date.now() - lastClickTime < 16 ? 'locked' : '' }`, }) } } const closeLoading = (silent) => { if (silent) return reqNum-- if (reqNum <= 0) { reqNum = 0 loadingInstance && loadingInstance.close() } } service.interceptors.request.use( async (config2) => { setLoading(config2.silent) const token = Session.get('Token') if (token) { config2.headers['Authorization'] = `Bearer ${token}` } config2.headers['X-Project'] = Session.get('X-Project') try { config2.headers['Accept-Language'] = Language$1.getLangReqHeader() } catch (error2) {} if (app.running) { config2.headers['environment'] = 'runningtime' } if (typeof config2.data !== 'object') { config2.data = JSON.stringify(config2.data) } return config2 }, (error2) => { return Promise.reject(error2) } ) service.interceptors.response.use( (response) => { closeLoading(response.config.silent) if (/api\//.test(response.config.url) && /^ { Session.remove('Token') history.go() }) .catch(() => { console.warn('x') }) return Promise.reject(error2) } if (status == 409 && app.editing) { Session.remove('X-Project') ElMessageBox.alert( Language$1._t('\u662F\u5426\u91CD\u65B0\u767B\u5F55'), Language$1._t('\u767B\u5F55\u5DF2\u5931\u6548'), { confirmButtonText: Language$1._t('\u786E\u8BA4'), } ).then(() => { router$1.replace('/').then(() => { history.go() }) }) return Promise.reject(error2) } toast(Language$1._t(message2), 'error', 15e3) return Promise.reject(error2) } ) const request = service window.request = request const userInfo = reactive({ user: {}, permissions: { all: false, pages: [], widgets: [], }, }) function hasPagePermission(page2) { const permissions = userInfo.permissions if (permissions.all) { return true } return permissions.pages.find((pageId) => String(pageId) === String(page2.id)) } function hasWidgetPermission(widget) { const permissions = userInfo.permissions if (permissions.all) { return true } return permissions.widgets.find( (widgetId) => String(widgetId) === String(widget.id) ) } window.userInfo = userInfo const getPageTreeData = async () => { const changeFieldChildToChildren = (list2) => { const recursion = (list22) => { for (let i2 = 0; i2 < list22.length; i2++) { let item2 = list22[i2] item2.id = String(item2.id) item2.children = item2.child delete item2.child delete item2.parentId if (item2.children.length) { recursion(item2.children) } } } recursion(list2) return list2 } return getPictures().then((res) => { const newRes = changeFieldChildToChildren(res) app.current.project.pageList = newRes.map((item2) => { return new Page(item2) }) return newRes }) } const selectPage = async (page2) => { if (page2.type === 0 || !page2.id) return const project = app.current.project project.current.page.history.pause() project.current.page.selectedCanvasNodeList.length = 0 const pageContentPromise = getPicturesContent(page2.id).then((res) => { let document2 = res.content || page2.document let permissions = res.permissions || [] try { document2 = JSON.parse(document2) permissions = JSON.parse(permissions) } catch (error2) {} document2.body = new CanvasNode$1(document2.body) page2.document = document2 page2.permissions = permissions }) await Promise.all([pageContentPromise]) if (project.current.page !== page2) { project.current.page.document.body = new CanvasNode$1({ style: { ...project.current.page.document.body.style, }, }) } project.current.page = page2 page2.history.resume() } const createFile$1 = async (model) => { const currentPage2 = app.current.project.current.page const parent2 = currentPage2.parent const name2 = model === 'folders' ? '\u65B0\u5EFA\u6587\u4EF6\u5939' : '\u65B0\u5EFA\u9875\u9762' const type4 = model === 'folders' ? 0 : 1 let sort3 = currentPage2.getSort() if (sort3 != null) { sort3++ } const newId = await addPicture({ name: name2, parentId: parent2?.id || null, type: type4, sort: sort3 ? sort3 + 1 : 1, }) let newPage = new Page({ id: String(newId), parent: parent2, name: name2 + '-' + newId, type: type4, }) if (!currentPage2.id || !newPage.parent) { Page.appendPageList(newPage, sort3) } if (parent2) { parent2.appendChild(newPage, sort3) } return newPage } const deletePage = async (page2) => { await delPicture(page2.id) closePageTab(page2.id) page2.remove() } const batchDelPage = async (pages) => { const ids = pages.map((page2) => page2.id) await batchDelPicture(ids) closePageTab(ids) for (const page2 of pages) { page2.remove() Language$1.saveRawText(page2.id, true) } checkHomePage('delete') } const setHomePage = async (id2) => { app.current.project.current.homePageId = id2 return request.put('/api/v1/view/home', { homeNodeId: id2 }).then((res) => { if (res) app.current.project.current.homePageId = String(res) }) } const getHomePageId = async () => { const res = await request.get('/api/v1/view/home') app.current.project.current.homePageId = String(res) return res } const checkHomePage = (type4) => { if (type4 === 'create') { if (!app.current.project.current.homePageId) getHomePageId() } if (type4 === 'delete') { if (!app.current.project.current.homePageId) { getHomePageId() } else { const home = Page.getPageById(app.current.project.current.homePageId) if (!home || !home.id) { app.current.project.current.homePageId = void 0 getHomePageId() } } } } const addPageTab = (page2) => { if (page2.type === 0 || !page2.id) return const pageList = app.current.project.current.pageList if (!pageList.includes(page2)) { pageList.push(page2) } selectPage(page2) } const closePageTab = (pageIds, onlySelf = false) => { if (pageIds instanceof Array) { for (const id2 of pageIds) { deleteTab(id2, onlySelf) } } else { deleteTab(pageIds, onlySelf) } const tabPageList = app.current.project.current.pageList if (!tabPageList.length) { const emptyPage = new Page() app.current.project.current.page = emptyPage replace$4(emptyPage) return } const currentPageId = app.current.project.current.page.id if (!tabPageList.some((page2) => page2.id === currentPageId)) { const firstPage = tabPageList[0] selectPage(firstPage) replace$4(firstPage) } } const deleteTab = (pageId, onlySelf = false) => { if (!onlySelf) { const page2 = app.current.project.pageList.find( (page22) => page22.id === pageId ) if (page2 && page2.children) { page2.children.forEach((page22) => { deleteTab(page22.id) }) } } const tabPageList = app.current.project.current.pageList const pageIndex2 = tabPageList.findIndex((page2) => page2.id === pageId) if (pageIndex2 === -1) return tabPageList.splice(pageIndex2, 1) } const closeAllPageTabs = () => { app.current.project.current.pageList = [] const emptyPage = new Page() app.current.project.current.page = emptyPage replace$4(emptyPage) } const closeElsePageTabs = (pageId) => { app.current.project.current.pageList = app.current.project.current.pageList.filter((page2) => page2.id === pageId) replace$4({ id: pageId }) } let CacheSocket = null const initSocket = async function () { CacheSocket = new Socket({ url: '/hubs/v1/datacache', name: '\u5B9E\u65F6\u670D\u52A1', }) await CacheSocket.start() } const authorizeInfo = reactive({ licenseInfo: { usedVariables: 0, totalVariable: 0, usedDevices: 0, totalDevices: 0, useClient: 0, totalClient: 0, services: {}, protocals: {}, components: {}, }, }) const accessSocketInVision = async () => { const socket = new Socket({ url: '/hubs/v1/cmsv2authorization', name: '\u8FD0\u884C\u7248\u8BBF\u95EE', }) await socket.start() } const getLicenseInfo = async () => { authorizeInfo.licenseInfo = await request.get(`/api/v1/license/info`) } const checkWidgetAuth = (is2) => { if (!Widget.store[is2]?.authorizationRequired) return true const componentKeys = Object.keys(authorizeInfo.licenseInfo.components) return componentKeys.includes(is2) } const notFound = () => Promise.resolve().then(function () { return _404NotFound$1 }) const routes = [ { path: '/', name: '/', component: () => Promise.resolve().then(function () { return Frame$1 }), children: [ { path: '/', name: '', component: () => Promise.resolve().then(function () { return Projects$1 }), }, ], }, { path: '/editing/project/:projectId', component: () => Promise.resolve().then(function () { return Project$1 }), children: [ { path: 'vars', name: 'vars', component: () => Promise.resolve().then(function () { return Vars$1 }), }, { path: 'page/:pageId?', name: 'page', component: () => Promise.resolve().then(function () { return Pages$1 }), beforeEnter: async () => { await getPageTreeData() await getHomePageId() return true }, }, { path: 'history', name: 'history', component: () => Promise.resolve().then(function () { return History$3 }), }, { path: 'basis', name: 'basis', component: () => Promise.resolve().then(function () { return Basis$1 }), }, { path: 'lang', name: 'lang', component: () => Promise.resolve().then(function () { return Lang$1 }), }, { path: 'connection', name: 'connection', component: () => Promise.resolve().then(function () { return Connection$1 }), }, { path: 'data', name: 'data', component: () => Promise.resolve().then(function () { return Data$1 }), }, { path: 'alarm', name: 'alarm', component: () => Promise.resolve().then(function () { return Alarm$1 }), }, ], }, { path: '/login', name: 'login', component: () => Promise.resolve().then(function () { return login$1 }), }, { path: '/running/project/:projectId/page/:pageId?', name: 'running', component: () => Promise.resolve().then(function () { return Run$1 }), }, { path: '/404', name: '404', component: notFound }, { path: '/:pathMatch(.*)*', name: 'not-found', component: notFound, }, ] const vueFileMap = { '../App.vue': () => Promise.resolve().then(function () { return App$1 }), '../components/left-menu.vue': () => Promise.resolve().then(function () { return leftMenu$1 }), '../components/scaling-zoom.vue': () => Promise.resolve().then(function () { return scalingZoom }), '../components/theme-menu.vue': () => Promise.resolve().then(function () { return themeMenu }), '../layout/login.vue': () => Promise.resolve().then(function () { return login$1 }), '../views/404NotFound.vue': () => Promise.resolve().then(function () { return _404NotFound$1 }), '../components/AsyncComponent/AsyncComponent.vue': () => Promise.resolve().then(function () { return AsyncComponent }), '../components/DialogPage/DialogPage.vue': () => Promise.resolve().then(function () { return DialogPage$2 }), '../components/EllipsisTooltip/EllipsisTooltip.vue': () => Promise.resolve().then(function () { return EllipsisTooltip$1 }), '../components/MiniPagesMenu/MiniPagesMenu.vue': () => Promise.resolve().then(function () { return MiniPagesMenu$1 }), '../components/TitleTooltip/TitleTooltip.vue': () => Promise.resolve().then(function () { return TitleTooltip }), '../components/VirtualKeyboard/VirtualKeyboard.vue': () => Promise.resolve().then(function () { return VirtualKeyboard$1 }), '../components/VirtualTree/TreeNode.vue': () => Promise.resolve().then(function () { return TreeNode$2 }), '../components/VirtualTree/VirtualTree.vue': () => Promise.resolve().then(function () { return VirtualTree$1 }), '../components/collapse/collapse.vue': () => Promise.resolve().then(function () { return collapse$1 }), '../components/component-styles/module-appearance.vue': () => Promise.resolve().then(function () { return moduleAppearance$1 }), '../components/component-styles/module-function.vue': () => Promise.resolve().then(function () { return moduleFunction$1 }), '../components/component-styles/module-opacity.vue': () => Promise.resolve().then(function () { return moduleOpacity$1 }), '../components/component-styles/module-permission.vue': () => Promise.resolve().then(function () { return modulePermission$1 }), '../components/component-styles/module-position.vue': () => Promise.resolve().then(function () { return modulePosition$1 }), '../components/component-styles/module-text.vue': () => Promise.resolve().then(function () { return moduleText$1 }), '../components/component-styles/module-title.vue': () => Promise.resolve().then(function () { return moduleTitle$1 }), '../components/gallery/GalleryMaterial.vue': () => Promise.resolve().then(function () { return GalleryMaterial$1 }), '../components/gallery/OfficialMaterial.vue': () => Promise.resolve().then(function () { return OfficialMaterial$1 }), '../components/gallery/gallery.vue': () => Promise.resolve().then(function () { return gallery }), '../sdk/components/SettingItem.vue': () => Promise.resolve().then(function () { return SettingItem }), '../views/Frame/Frame.vue': () => Promise.resolve().then(function () { return Frame$1 }), '../views/Frame/Header.vue': () => Promise.resolve().then(function () { return Header$5 }), '../views/Project/Project.vue': () => Promise.resolve().then(function () { return Project$1 }), '../views/Projects/Projects.vue': () => Promise.resolve().then(function () { return Projects$1 }), '../views/Run/Run.vue': () => Promise.resolve().then(function () { return Run$1 }), '../views/picture-management/index.vue': () => Promise.resolve().then(function () { return index$a }), '../widgets/CheckboxControl/CheckboxControl.settings.vue': () => Promise.resolve().then(function () { return __glob_1_0 }), '../widgets/CheckboxControl/CheckboxControl.vue': () => Promise.resolve().then(function () { return __glob_1_1 }), '../widgets/DateSelector/DateSelector.settings.vue': () => Promise.resolve().then(function () { return __glob_1_2 }), '../widgets/DateSelector/DateSelector.vue': () => Promise.resolve().then(function () { return __glob_1_3 }), '../widgets/Filter/DateIcon.vue': () => Promise.resolve().then(function () { return __glob_1_4 }), '../widgets/Filter/Filter.settings.vue': () => Promise.resolve().then(function () { return __glob_1_5 }), '../widgets/Filter/Filter.vue': () => Promise.resolve().then(function () { return __glob_1_6 }), '../widgets/Progress/Progress.settings.vue': () => Promise.resolve().then(function () { return __glob_1_7 }), '../widgets/Progress/Progress.vue': () => Promise.resolve().then(function () { return __glob_1_8 }), '../widgets/QueryButton/QueryButton.settings.vue': () => Promise.resolve().then(function () { return __glob_1_9 }), '../widgets/QueryButton/QueryButton.vue': () => Promise.resolve().then(function () { return __glob_1_10 }), '../widgets/RadioControl/RadioControl.settings.vue': () => Promise.resolve().then(function () { return __glob_1_11 }), '../widgets/RadioControl/RadioControl.vue': () => Promise.resolve().then(function () { return __glob_1_12 }), '../widgets/Select/OptionConfigDialog.vue': () => Promise.resolve().then(function () { return __glob_1_13 }), '../widgets/Select/Select.settings.vue': () => Promise.resolve().then(function () { return __glob_1_14 }), '../widgets/Select/Select.vue': () => Promise.resolve().then(function () { return __glob_1_15 }), '../widgets/SelectControl/SelectControl.settings.vue': () => Promise.resolve().then(function () { return __glob_1_16 }), '../widgets/SelectControl/SelectControl.vue': () => Promise.resolve().then(function () { return __glob_1_17 }), '../widgets/Sheet/DataToolbar.vue': () => Promise.resolve().then(function () { return __glob_1_18 }), '../widgets/Sheet/Sheet.settings.vue': () => Promise.resolve().then(function () { return __glob_1_19 }), '../widgets/Sheet/Sheet.vue': () => Promise.resolve().then(function () { return __glob_1_20 }), '../widgets/Unauthorized/Unauthorized.settings.vue': () => Promise.resolve().then(function () { return __glob_1_21 }), '../widgets/Unauthorized/Unauthorized.vue': () => Promise.resolve().then(function () { return __glob_1_22 }), '../components/component-styles/function-dialogs/function-dialog-btn.vue': () => Promise.resolve().then(function () { return functionDialogBtn$1 }), '../components/component-styles/function-dialogs/function-dialog-variate.vue': () => Promise.resolve().then(function () { return functionDialogVariate }), '../components/component-styles/function-dialogs/function-dialog.vue': () => Promise.resolve().then(function () { return functionDialog$1 }), '../components/component-styles/function-items/function-input-precision.vue': () => Promise.resolve().then(function () { return functionInputPrecision }), '../components/component-styles/function-items/function-input-range.vue': () => Promise.resolve().then(function () { return functionInputRange }), '../components/component-styles/function-items/function-jump-page.vue': () => Promise.resolve().then(function () { return functionJumpPage }), '../components/component-styles/function-items/function-popup.vue': () => Promise.resolve().then(function () { return functionPopup$1 }), '../components/component-styles/function-items/function-relate-variable.vue': () => Promise.resolve().then(function () { return functionRelateVariable }), '../components/component-styles/function-items/function-send-variable.vue': () => Promise.resolve().then(function () { return functionSendVariable$1 }), '../components/component-styles/function-items/function-show-dialog.vue': () => Promise.resolve().then(function () { return functionShowDialog }), '../components/component-styles/function-items/function-tree.vue': () => Promise.resolve().then(function () { return functionTree$1 }), '../components/gallery/component/PanelLayout.vue': () => Promise.resolve().then(function () { return PanelLayout$3 }), '../components/picture-management/picture-production/component-event.vue': () => Promise.resolve().then(function () { return componentEvent }), '../components/picture-management/picture-production/component-object.vue': () => Promise.resolve().then(function () { return componentObject }), '../components/picture-management/picture-production/component-style.vue': () => Promise.resolve().then(function () { return componentStyle }), '../components/picture-management/picture-production/drag-choose-component-box.vue': () => Promise.resolve().then(function () { return dragChooseComponentBox$1 }), '../components/picture-management/picture-production/picture-header.vue': () => Promise.resolve().then(function () { return pictureHeader }), '../components/picture-management/picture-production/project-page.vue': () => Promise.resolve().then(function () { return projectPage }), '../components/picture-management/variable-management/add-device-form.vue': () => Promise.resolve().then(function () { return addDeviceForm }), '../components/picture-management/variable-management/add-device-group-form.vue': () => Promise.resolve().then(function () { return addDeviceGroupForm }), '../components/picture-management/variable-management/address-config.vue': () => Promise.resolve().then(function () { return addressConfig }), '../components/picture-management/variable-management/associated-variable.vue': () => Promise.resolve().then(function () { return associatedVariable }), '../components/picture-management/variable-management/compoment-table-inner.vue': () => Promise.resolve().then(function () { return compomentTableInner }), '../components/picture-management/variable-management/compoment-table.vue': () => Promise.resolve().then(function () { return compomentTable }), '../components/picture-management/variable-management/compoment-ztree-inner.vue': () => Promise.resolve().then(function () { return compomentZtreeInner }), '../components/picture-management/variable-management/compoment-ztree.vue': () => Promise.resolve().then(function () { return compomentZtree }), '../components/picture-management/variable-management/history-archive.vue': () => Promise.resolve().then(function () { return historyArchive }), '../views/Project/Alarm/Alarm.vue': () => Promise.resolve().then(function () { return Alarm$1 }), '../views/Project/Basis/Basis.vue': () => Promise.resolve().then(function () { return Basis$1 }), '../views/Project/Connection/Connection.vue': () => Promise.resolve().then(function () { return Connection$1 }), '../views/Project/Data/Data.vue': () => Promise.resolve().then(function () { return Data$1 }), '../views/Project/History/History.vue': () => Promise.resolve().then(function () { return History$3 }), '../views/Project/Lang/Lang.vue': () => Promise.resolve().then(function () { return Lang$1 }), '../views/Project/Pages/Pages.vue': () => Promise.resolve().then(function () { return Pages$1 }), '../views/Project/Vars/Vars.vue': () => Promise.resolve().then(function () { return Vars$1 }), '../views/Projects/components/BackupDialog.vue': () => Promise.resolve().then(function () { return BackupDialog$1 }), '../views/Projects/components/CreateProjectDialog.vue': () => Promise.resolve().then(function () { return CreateProjectDialog$1 }), '../views/Projects/components/HandleProjectConflict.vue': () => Promise.resolve().then(function () { return HandleProjectConflict$1 }), '../views/Projects/components/ModifyLevel.vue': () => Promise.resolve().then(function () { return ModifyLevel$1 }), '../views/Projects/components/RecoveryDataDialog.vue': () => Promise.resolve().then(function () { return RecoveryDataDialog$1 }), '../views/Projects/components/RenameDialog.vue': () => Promise.resolve().then(function () { return RenameDialog$1 }), '../views/Projects/components/TipDialog.vue': () => Promise.resolve().then(function () { return TipDialog$1 }), '../views/Projects/components/VersionUpdate.vue': () => Promise.resolve().then(function () { return VersionUpdate$1 }), '../views/Projects/components/createFolderDialog.vue': () => Promise.resolve().then(function () { return createFolderDialog }), '../views/Run/AuthorizeInfo/AuthorizeInfo.vue': () => Promise.resolve().then(function () { return AuthorizeInfo$1 }), '../views/Run/AuthorizeInfo/UnauthorizedLabel.vue': () => Promise.resolve().then(function () { return UnauthorizedLabel$1 }), '../views/Run/Menu/Menu.vue': () => Promise.resolve().then(function () { return Menu$1 }), '../views/Run/RunSetting/RunSetting.vue': () => Promise.resolve().then(function () { return RunSetting$1 }), '../views/picture-management/picture-production/index.vue': () => Promise.resolve().then(function () { return index$7 }), '../views/picture-management/resources-management/index.vue': () => Promise.resolve().then(function () { return index$5 }), '../views/picture-management/variable-management/index.vue': () => Promise.resolve().then(function () { return index$3 }), '../widgets/CheckboxControl/components/ExpressionFn.vue': () => Promise.resolve().then(function () { return ExpressionFn$1 }), '../widgets/CheckboxControl/components/RelationVariable.vue': () => Promise.resolve().then(function () { return RelationVariable$1 }), '../widgets/QueryButton/settings/ControllerCharts.vue': () => Promise.resolve().then(function () { return ControllerCharts$1 }), '../widgets/RadioControl/components/ButtonStyle.vue': () => Promise.resolve().then(function () { return ButtonStyle$1 }), '../widgets/RadioControl/components/OptionsTable.vue': () => Promise.resolve().then(function () { return OptionsTable$1 }), '../components/picture-management/picture-production/component-box/index.vue': () => Promise.resolve().then(function () { return index$8 }), '../views/Project/Alarm/Sidebar/Sidebar.vue': () => Promise.resolve().then(function () { return Sidebar$1 }), '../views/Project/Alarm/components/AlarmTable.vue': () => Promise.resolve().then(function () { return AlarmTable$1 }), '../views/Project/Alarm/components/SelectAlarmTypes.vue': () => Promise.resolve().then(function () { return SelectAlarmTypes$1 }), '../views/Project/Basis/Classes/Classes.vue': () => Promise.resolve().then(function () { return Classes$1 }), '../views/Project/Connection/EditorForm/ChoiceField.vue': () => Promise.resolve().then(function () { return ChoiceField$2 }), '../views/Project/Connection/EditorForm/ChoiceFieldDialog.vue': () => Promise.resolve().then(function () { return ChoiceFieldDialog$1 }), '../views/Project/Connection/EditorForm/EditorForm.vue': () => Promise.resolve().then(function () { return EditorForm$1 }), '../views/Project/Connection/EditorForm/Filter.vue': () => Promise.resolve().then(function () { return Filter }), '../views/Project/Connection/EditorForm/MappingTable.vue': () => Promise.resolve().then(function () { return MappingTable }), '../views/Project/Connection/EditorForm/Sort.vue': () => Promise.resolve().then(function () { return Sort }), '../views/Project/Connection/EditorForm/TriggerSetting.vue': () => Promise.resolve().then(function () { return TriggerSetting$2 }), '../views/Project/Connection/EditorForm/TriggerSettingConfig.vue': () => Promise.resolve().then(function () { return TriggerSettingConfig$1 }), '../views/Project/Connection/EditorForm/VarTable.vue': () => Promise.resolve().then(function () { return VarTable }), '../views/Project/Connection/EditorForm/dataBaseTable.vue': () => Promise.resolve().then(function () { return dataBaseTable }), '../views/Project/Connection/EditorTable/EditorTable.vue': () => Promise.resolve().then(function () { return EditorTable$1 }), '../views/Project/Connection/Sidebar/Sidebar.vue': () => Promise.resolve().then(function () { return Sidebar$5 }), '../views/Project/Data/DataAggregation/DataAggregation.vue': () => Promise.resolve().then(function () { return DataAggregation }), '../views/Project/Data/Sidebar/Sidebar.vue': () => Promise.resolve().then(function () { return Sidebar$3 }), '../views/Project/Data/VariableTag/VariableTag.vue': () => Promise.resolve().then(function () { return VariableTag }), '../views/Project/Data/components/Header.vue': () => Promise.resolve().then(function () { return Header$1 }), '../views/Project/History/Dialog/HistoryConfig.vue': () => Promise.resolve().then(function () { return HistoryConfig }), '../views/Project/History/Dialog/MoveFolder.vue': () => Promise.resolve().then(function () { return MoveFolder$1 }), '../views/Project/History/Dialog/StorageSet.vue': () => Promise.resolve().then(function () { return StorageSet }), '../views/Project/History/Dialog/Tip.vue': () => Promise.resolve().then(function () { return Tip }), '../views/Project/History/HistoryList/HistoryList.vue': () => Promise.resolve().then(function () { return HistoryList$1 }), '../views/Project/History/Table/Table.vue': () => Promise.resolve().then(function () { return Table$1 }), '../views/Project/History/components/DataBackup.vue': () => Promise.resolve().then(function () { return DataBackup }), '../views/Project/History/components/HistoryDialog.vue': () => Promise.resolve().then(function () { return HistoryDialog }), '../views/Project/History/components/TriggerFrequency.vue': () => Promise.resolve().then(function () { return TriggerFrequency$3 }), '../views/Project/Lang/ContentTable/ContentTable.vue': () => Promise.resolve().then(function () { return ContentTable$1 }), '../views/Project/Lang/Sidebar/Sidebar.vue': () => Promise.resolve().then(function () { return Sidebar$7 }), '../views/Project/Pages/Editor/Editor.vue': () => Promise.resolve().then(function () { return Editor$1 }), '../views/Project/Pages/Sidebar/Sidebar.vue': () => Promise.resolve().then(function () { return Sidebar$9 }), '../views/Project/Pages/Viewer/Viewer.vue': () => Promise.resolve().then(function () { return Viewer$1 }), '../views/Project/Vars/Header/Header.vue': () => Promise.resolve().then(function () { return Header$3 }), '../views/Project/Vars/Sidebar/Sidebar.vue': () => Promise.resolve().then(function () { return Sidebar$b }), '../views/Project/Vars/Table/Table.vue': () => Promise.resolve().then(function () { return Table$3 }), '../views/Project/Vars/components/ReadWriteInput.vue': () => Promise.resolve().then(function () { return ReadWriteInput$1 }), '../views/Project/Vars/components/VarReferenceConfig.vue': () => Promise.resolve().then(function () { return VarReferenceConfig$1 }), '../views/Run/Menu/Login/Login.vue': () => Promise.resolve().then(function () { return Login$1 }), '../views/Run/Menu/User/User.vue': () => Promise.resolve().then(function () { return User$1 }), '../widgets/Sheet/components/ContextMenu/ContextMenu.vue': () => Promise.resolve().then(function () { return ContextMenu$1 }), '../widgets/Sheet/components/SlantLine/SlantLine.vue': () => Promise.resolve().then(function () { return SlantLine$1 }), '../widgets/Sheet/components/Toolbar/ToolColorPicker.vue': () => Promise.resolve().then(function () { return ToolColorPicker }), '../widgets/Sheet/components/Toolbar/Toolbar.vue': () => Promise.resolve().then(function () { return Toolbar$3 }), '../widgets/Sheet/components/settings/Cell.vue': () => Promise.resolve().then(function () { return Cell }), '../widgets/Sheet/components/settings/CellElement.vue': () => Promise.resolve().then(function () { return CellElement$1 }), '../widgets/Sheet/components/settings/Data.vue': () => Promise.resolve().then(function () { return Data$3 }), '../widgets/Sheet/components/settings/DataFieldConfigDialog.vue': () => Promise.resolve().then(function () { return DataFieldConfigDialog$1 }), '../widgets/Sheet/components/settings/QueryConditions.vue': () => Promise.resolve().then(function () { return QueryConditions$1 }), '../widgets/Sheet/components/settings/ReportSetting.vue': () => Promise.resolve().then(function () { return ReportSetting$1 }), '../widgets/Sheet/components/settings/StyleConditionsDialog.vue': () => Promise.resolve().then(function () { return StyleConditionsDialog$1 }), '../widgets/Sheet/components/settings/Title.vue': () => Promise.resolve().then(function () { return Title$1 }), '../widgets/Sheet/components/settings/Type.vue': () => Promise.resolve().then(function () { return Type$1 }), '../components/picture-management/picture-production/component-box/component/default-module.vue': () => Promise.resolve().then(function () { return defaultModule }), '../components/picture-management/picture-production/component-box/component/run-module.vue': () => Promise.resolve().then(function () { return runModule$1 }), '../components/picture-management/picture-production/component-box/component/standard-controls.vue': () => Promise.resolve().then(function () { return standardControls }), '../views/Project/Alarm/Sidebar/components/AlarmLevelsConf.vue': () => Promise.resolve().then(function () { return AlarmLevelsConf$1 }), '../views/Project/Alarm/Sidebar/components/AlarmRecordsConf.vue': () => Promise.resolve().then(function () { return AlarmRecordsConf$1 }), '../views/Project/Alarm/Sidebar/components/AlarmTypeConf.vue': () => Promise.resolve().then(function () { return AlarmTypeConf$1 }), '../views/Project/Alarm/Sidebar/components/AlarmTypesConf.vue': () => Promise.resolve().then(function () { return AlarmTypesConf$1 }), '../views/Project/Alarm/Sidebar/components/SheetCreateDialog.vue': () => Promise.resolve().then(function () { return SheetCreateDialog$1 }), '../views/Project/Connection/EditorTable/components/ModifyRowsConfig.vue': () => Promise.resolve().then(function () { return ModifyRowsConfig$1 }), '../views/Project/Connection/Sidebar/components/CreateConnection.vue': () => Promise.resolve().then(function () { return CreateConnection$1 }), '../views/Project/Connection/Sidebar/components/CreateData.vue': () => Promise.resolve().then(function () { return CreateData }), '../views/Project/Connection/Sidebar/components/SqlConfigDialog.vue': () => Promise.resolve().then(function () { return SqlConfigDialog$1 }), '../views/Project/Connection/Sidebar/components/databaseConfig.vue': () => Promise.resolve().then(function () { return databaseConfig$1 }), '../views/Project/Connection/Sidebar/components/previewDatabaseTable.vue': () => Promise.resolve().then(function () { return previewDatabaseTable }), '../views/Project/Connection/Sidebar/components/selectDataTable.vue': () => Promise.resolve().then(function () { return selectDataTable$1 }), '../views/Project/Data/DataAggregation/components/ChoiceField.vue': () => Promise.resolve().then(function () { return ChoiceField$1 }), '../views/Project/Data/DataAggregation/components/FieldConfig.vue': () => Promise.resolve().then(function () { return FieldConfig$1 }), '../views/Project/Data/DataAggregation/components/FilterConditions.vue': () => Promise.resolve().then(function () { return FilterConditions$1 }), '../views/Project/Data/DataAggregation/components/TriggerConfig.vue': () => Promise.resolve().then(function () { return TriggerConfig$1 }), '../views/Project/Data/Sidebar/components/SheetCreateDialog.vue': () => Promise.resolve().then(function () { return SheetCreateDialog$3 }), '../views/Project/Data/VariableTag/components/ExpConfigDialog.vue': () => Promise.resolve().then(function () { return ExpConfigDialog$4 }), '../views/Project/Data/VariableTag/components/FieldType.vue': () => Promise.resolve().then(function () { return FieldType$1 }), '../views/Project/Data/VariableTag/components/FormulaConfigDialog.vue': () => Promise.resolve().then(function () { return FormulaConfigDialog$1 }), '../views/Project/Data/VariableTag/components/InputCode.vue': () => Promise.resolve().then(function () { return InputCode$1 }), '../views/Project/Data/VariableTag/components/RelevanceButton.vue': () => Promise.resolve().then(function () { return RelevanceButton$1 }), '../views/Project/Data/VariableTag/components/TriggerFrequency.vue': () => Promise.resolve().then(function () { return TriggerFrequency$1 }), '../views/Project/Data/VariableTag/components/TriggerSetting.vue': () => Promise.resolve().then(function () { return TriggerSetting$1 }), '../views/Project/Data/VariableTag/components/cacheSetting.vue': () => Promise.resolve().then(function () { return cacheSetting }), '../views/Project/Data/VariableTag/components/noDataButton.vue': () => Promise.resolve().then(function () { return noDataButton$1 }), '../views/Project/Data/VariableTag/components/storageSetting.vue': () => Promise.resolve().then(function () { return storageSetting$1 }), '../views/Project/Lang/ContentTable/components/ExportFile.vue': () => Promise.resolve().then(function () { return ExportFile }), '../views/Project/Lang/ContentTable/components/ImportFile.vue': () => Promise.resolve().then(function () { return ImportFile$1 }), '../views/Project/Lang/Sidebar/components/CmsSwitch.vue': () => Promise.resolve().then(function () { return CmsSwitch$1 }), '../views/Project/Lang/Sidebar/components/CreateDialog.vue': () => Promise.resolve().then(function () { return CreateDialog$1 }), '../views/Project/Pages/Editor/Board/Board.vue': () => Promise.resolve().then(function () { return Board$1 }), '../views/Project/Pages/Editor/Empty/Empty.vue': () => Promise.resolve().then(function () { return Empty$1 }), '../views/Project/Pages/Editor/Settings/Settings.vue': () => Promise.resolve().then(function () { return Settings$1 }), '../views/Project/Pages/Editor/Tab/Tab.vue': () => Promise.resolve().then(function () { return Tab$1 }), '../views/Project/Pages/Sidebar/CanvasNodeList/CanvasNodeList.vue': () => Promise.resolve().then(function () { return CanvasNodeList$1 }), '../views/Project/Pages/Sidebar/PageList/PageList.vue': () => Promise.resolve().then(function () { return PageList$1 }), '../views/Project/Vars/Header/components/Filter.vue': () => Promise.resolve().then(function () { return Filter$3 }), '../views/Project/Vars/Sidebar/components/IOTunnelDriveTree.vue': () => Promise.resolve().then(function () { return IOTunnelDriveTree$1 }), '../views/Project/Vars/Sidebar/components/IOTunnelOperate.vue': () => Promise.resolve().then(function () { return IOTunnelOperate }), '../views/Project/Vars/Sidebar/components/InnerTunnelOperate.vue': () => Promise.resolve().then(function () { return InnerTunnelOperate }), '../views/Project/Vars/Sidebar/components/SUBTunnelOperate.vue': () => Promise.resolve().then(function () { return SUBTunnelOperate }), '../views/Project/Vars/Sidebar/components/VarGroupOperate.vue': () => Promise.resolve().then(function () { return VarGroupOperate }), '../views/Project/Vars/Sidebar/components/VarNameConfig.vue': () => Promise.resolve().then(function () { return VarNameConfig }), '../views/Project/Vars/Table/components/ImportFile.vue': () => Promise.resolve().then(function () { return ImportFile$2 }), '../views/Project/Vars/Table/components/VarAddressConfig.vue': () => Promise.resolve().then(function () { return VarAddressConfig }), '../views/Project/Vars/Table/components/VarBatchCreate.vue': () => Promise.resolve().then(function () { return VarBatchCreate }), '../views/Project/Vars/Table/components/VarBatchIssue.vue': () => Promise.resolve().then(function () { return VarBatchIssue }), '../views/Project/Vars/Table/components/VarBatchModify.vue': () => Promise.resolve().then(function () { return VarBatchModify }), '../views/Project/Vars/Table/components/VarHistoricArchiveConfig.vue': () => Promise.resolve().then(function () { return VarHistoricArchiveConfig$1 }), '../views/Project/Vars/Table/components/VarReferenceListCheck.vue': () => Promise.resolve().then(function () { return VarReferenceListCheck }), '../views/Project/Pages/Editor/Board/ApplicationResource/ApplicationResource.vue': () => Promise.resolve().then(function () { return ApplicationResource$1 }), '../views/Project/Pages/Editor/Board/Canvas/Canvas.vue': () => Promise.resolve().then(function () { return Canvas$1 }), '../views/Project/Pages/Editor/Board/Canvas/CanvasNode.vue': () => Promise.resolve().then(function () { return CanvasNode }), '../views/Project/Pages/Editor/Board/History/History.vue': () => Promise.resolve().then(function () { return History$1 }), '../views/Project/Pages/Editor/Board/Selector/Resizer.vue': () => Promise.resolve().then(function () { return Resizer$1 }), '../views/Project/Pages/Editor/Board/Selector/Selected.vue': () => Promise.resolve().then(function () { return Selected$1 }), '../views/Project/Pages/Editor/Board/Selector/Selector.vue': () => Promise.resolve().then(function () { return Selector$1 }), '../views/Project/Pages/Editor/Board/Toolbar/LanguageSelect.vue': () => Promise.resolve().then(function () { return LanguageSelect$1 }), '../views/Project/Pages/Editor/Board/Toolbar/Toolbar.vue': () => Promise.resolve().then(function () { return Toolbar$1 }), '../views/Project/Pages/Editor/Board/Toolbar/ZoomSelect.vue': () => Promise.resolve().then(function () { return ZoomSelect$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/Icon.vue': () => Promise.resolve().then(function () { return Icon$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/WidgetLib.vue': () => Promise.resolve().then(function () { return WidgetLib$1 }), '../views/Project/Pages/Editor/Board/Zoom/Zoom.vue': () => Promise.resolve().then(function () { return Zoom$1 }), '../views/Project/Pages/Editor/Settings/Events/Events.vue': () => Promise.resolve().then(function () { return Events$1 }), '../views/Project/Pages/Editor/Settings/Style/Style.vue': () => Promise.resolve().then(function () { return Style$1 }), '../views/Project/Pages/Editor/Settings/WidgetSettings/InputSettings.vue': () => Promise.resolve().then(function () { return InputSettings$1 }), '../views/Project/Pages/Editor/Settings/WidgetSettings/Permission.vue': () => Promise.resolve().then(function () { return Permission$1 }), '../views/Project/Pages/Editor/Settings/WidgetSettings/WidgetSettings.vue': () => Promise.resolve().then(function () { return WidgetSettings$1 }), '../views/Project/Pages/Editor/Settings/components/SettingItem.vue': () => Promise.resolve().then(function () { return SettingItem$2 }), '../views/Project/Pages/Editor/Board/ApplicationResource/Panels/PanelContent.vue': () => Promise.resolve().then(function () { return PanelContent$1 }), '../views/Project/Pages/Editor/Board/ApplicationResource/Panels/PanelLayout.vue': () => Promise.resolve().then(function () { return PanelLayout$1 }), '../views/Project/Pages/Editor/Settings/Events/components/ActionPopover.vue': () => Promise.resolve().then(function () { return ActionPopover$1 }), '../views/Project/Pages/Editor/Settings/Events/components/ActionSetting.vue': () => Promise.resolve().then(function () { return ActionSetting$1 }), '../views/Project/Pages/Editor/Settings/Events/components/ActionTargetPopover.vue': () => Promise.resolve().then(function () { return ActionTargetPopover$1 }), '../views/Project/Pages/Editor/Settings/Events/components/AlarmRecoverySetting.vue': () => Promise.resolve().then(function () { return AlarmRecoverySetting$1 }), '../views/Project/Pages/Editor/Settings/Events/components/AlarmSetting.vue': () => Promise.resolve().then(function () { return AlarmSetting$1 }), '../views/Project/Pages/Editor/Settings/Events/components/ConditionSetting.vue': () => Promise.resolve().then(function () { return ConditionSetting$1 }), '../views/Project/Pages/Editor/Settings/Events/components/EventPopover.vue': () => Promise.resolve().then(function () { return EventPopover$1 }), '../views/Project/Pages/Editor/Settings/Events/components/EventSettings.vue': () => Promise.resolve().then(function () { return EventSettings }), '../views/Project/Pages/Editor/Settings/Events/components/ExpConfigDialog.vue': () => Promise.resolve().then(function () { return ExpConfigDialog$3 }), '../views/Project/Pages/Editor/Settings/Events/components/Footer.vue': () => Promise.resolve().then(function () { return Footer$1 }), '../views/Project/Pages/Editor/Settings/Events/components/OnBroadcastSetting.vue': () => Promise.resolve().then(function () { return OnBroadcastSetting$1 }), '../views/Project/Pages/Editor/Settings/Events/components/Popover.vue': () => Promise.resolve().then(function () { return Popover$1 }), '../views/Project/Pages/Editor/Settings/Events/components/TimerSetting.vue': () => Promise.resolve().then(function () { return TimerSetting$1 }), '../views/Project/Pages/Editor/Settings/Events/components/VarConditionConfig.vue': () => Promise.resolve().then(function () { return VarConditionConfig$1 }), '../views/Project/Pages/Editor/Settings/Style/components/AppearanceSettings.vue': () => Promise.resolve().then(function () { return AppearanceSettings$1 }), '../views/Project/Pages/Editor/Settings/Style/components/BackgroundImageSetting.vue': () => Promise.resolve().then(function () { return BackgroundImageSetting$1 }), '../views/Project/Pages/Editor/Settings/Style/components/TextSettings.vue': () => Promise.resolve().then(function () { return TextSettings$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/A/A.settings.vue': () => Promise.resolve().then(function () { return __glob_2_0$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/A/A.vue': () => Promise.resolve().then(function () { return __glob_2_1$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Button/Button.settings.vue': () => Promise.resolve().then(function () { return __glob_2_2$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Button/Button.vue': () => Promise.resolve().then(function () { return __glob_2_3$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/Chart.settings.vue': () => Promise.resolve().then(function () { return __glob_2_4$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/Chart.vue': () => Promise.resolve().then(function () { return __glob_2_5$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartBar/ChartBar.settings.vue': () => Promise.resolve().then(function () { return __glob_2_6$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartBar/ChartBar.vue': () => Promise.resolve().then(function () { return __glob_2_7$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartBar/SetChart.vue': () => Promise.resolve().then(function () { return __glob_2_8$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartBarHorizontal/ChartBarHorizontal.settings.vue': () => Promise.resolve().then(function () { return __glob_2_9$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartBarHorizontal/ChartBarHorizontal.vue': () => Promise.resolve().then(function () { return __glob_2_10 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartBarHorizontalStacked/ChartBarHorizontalStacked.settings.vue': () => Promise.resolve().then(function () { return __glob_2_11 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartBarHorizontalStacked/ChartBarHorizontalStacked.vue': () => Promise.resolve().then(function () { return __glob_2_12 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartBarStacked/ChartBarStacked.settings.vue': () => Promise.resolve().then(function () { return __glob_2_13 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartBarStacked/ChartBarStacked.vue': () => Promise.resolve().then(function () { return __glob_2_14 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartCard/ChartCard.settings.vue': () => Promise.resolve().then(function () { return __glob_2_15 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartCard/ChartCard.vue': () => Promise.resolve().then(function () { return __glob_2_16 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLine/ChartLine.settings.vue': () => Promise.resolve().then(function () { return __glob_2_17 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLine/ChartLine.vue': () => Promise.resolve().then(function () { return __glob_2_18 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLine/SetChart.vue': () => Promise.resolve().then(function () { return __glob_2_19 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineArea/ChartLineArea.settings.vue': () => Promise.resolve().then(function () { return __glob_2_20 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineArea/ChartLineArea.vue': () => Promise.resolve().then(function () { return __glob_2_21 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineAreaStacked/ChartLineAreaStacked.settings.vue': () => Promise.resolve().then(function () { return __glob_2_22 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineAreaStacked/ChartLineAreaStacked.vue': () => Promise.resolve().then(function () { return __glob_2_23 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrend/Chart.vue': () => Promise.resolve().then(function () { return __glob_2_24 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrend/ChartLineTrend.settings.vue': () => Promise.resolve().then(function () { return __glob_2_25 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrend/ChartLineTrend.vue': () => Promise.resolve().then(function () { return __glob_2_26 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrendConfig/ChartLineTrendConfig.settings.vue': () => Promise.resolve().then(function () { return __glob_2_27 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrendConfig/ChartLineTrendConfig.vue': () => Promise.resolve().then(function () { return __glob_2_28 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartMixed/ChartMixed.settings.vue': () => Promise.resolve().then(function () { return __glob_2_29 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartMixed/ChartMixed.vue': () => Promise.resolve().then(function () { return __glob_2_30 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartPie/ChartPie.settings.vue': () => Promise.resolve().then(function () { return __glob_2_31 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartPie/ChartPie.vue': () => Promise.resolve().then(function () { return __glob_2_32 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartPie/Label.vue': () => Promise.resolve().then(function () { return __glob_2_33 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartPie/SetChart.vue': () => Promise.resolve().then(function () { return __glob_2_34 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartPieRing/ChartPieRing.settings.vue': () => Promise.resolve().then(function () { return __glob_2_35 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartPieRing/ChartPieRing.vue': () => Promise.resolve().then(function () { return __glob_2_36 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartPieRing/SetChart.vue': () => Promise.resolve().then(function () { return __glob_2_37 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartPieRose/ChartPieRose.settings.vue': () => Promise.resolve().then(function () { return __glob_2_38 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartPieRose/ChartPieRose.vue': () => Promise.resolve().then(function () { return __glob_2_39 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartTable/ChartTable.settings.vue': () => Promise.resolve().then(function () { return __glob_2_40 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartTable/ChartTable.vue': () => Promise.resolve().then(function () { return __glob_2_41 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Circle/Circle.settings.vue': () => Promise.resolve().then(function () { return __glob_2_42 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Circle/Circle.vue': () => Promise.resolve().then(function () { return __glob_2_43 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ControlButton/ControlButton.settings.vue': () => Promise.resolve().then(function () { return __glob_2_44 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ControlButton/ControlButton.vue': () => Promise.resolve().then(function () { return __glob_2_45 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DateRange/DateRange.settings.vue': () => Promise.resolve().then(function () { return __glob_2_46 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DateRange/DateRange.vue': () => Promise.resolve().then(function () { return __glob_2_47 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropDownList/DropDownList.settings.vue': () => Promise.resolve().then(function () { return __glob_2_48 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropDownList/DropDownList.vue': () => Promise.resolve().then(function () { return __glob_2_49 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropdownMenu/DropdownMenu.settings.vue': () => Promise.resolve().then(function () { return __glob_2_50 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropdownMenu/DropdownMenu.vue': () => Promise.resolve().then(function () { return __glob_2_51 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropdownMenuVertical/DropdownMenuVertical.settings.vue': () => Promise.resolve().then(function () { return __glob_2_52 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropdownMenuVertical/DropdownMenuVertical.vue': () => Promise.resolve().then(function () { return __glob_2_53 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropdownMenuVertical2/DropdownMenuVertical2.settings.vue': () => Promise.resolve().then(function () { return __glob_2_54 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropdownMenuVertical2/DropdownMenuVertical2.vue': () => Promise.resolve().then(function () { return __glob_2_55 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Dynamic/Dynamic.settings.vue': () => Promise.resolve().then(function () { return __glob_2_56 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DynamicCircle/DynamicCircle.settings.vue': () => Promise.resolve().then(function () { return __glob_2_57 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DynamicCircle/DynamicCircle.vue': () => Promise.resolve().then(function () { return __glob_2_58 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DynamicImg/DynamicImg.settings.vue': () => Promise.resolve().then(function () { return __glob_2_59 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DynamicImg/DynamicImg.vue': () => Promise.resolve().then(function () { return __glob_2_60 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DynamicRect/DynamicRect.settings.vue': () => Promise.resolve().then(function () { return __glob_2_61 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DynamicRect/DynamicRect.vue': () => Promise.resolve().then(function () { return __glob_2_62 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DynamicText/DynamicText.settings.vue': () => Promise.resolve().then(function () { return __glob_2_63 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DynamicText/DynamicText.vue': () => Promise.resolve().then(function () { return __glob_2_64 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Exp/Exp.settings.vue': () => Promise.resolve().then(function () { return __glob_2_65 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Exp/Exp.vue': () => Promise.resolve().then(function () { return __glob_2_66 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ExportButton/ExportButton.settings.vue': () => Promise.resolve().then(function () { return __glob_2_67 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ExportButton/ExportButton.vue': () => Promise.resolve().then(function () { return __glob_2_68 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Group/Group.settings.vue': () => Promise.resolve().then(function () { return __glob_2_69 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Group/Group.vue': () => Promise.resolve().then(function () { return __glob_2_70 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Img/Img.settings.vue': () => Promise.resolve().then(function () { return __glob_2_71 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Img/Img.vue': () => Promise.resolve().then(function () { return __glob_2_72 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Input/Input.settings.vue': () => Promise.resolve().then(function () { return __glob_2_73 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Input/Input.vue': () => Promise.resolve().then(function () { return __glob_2_74 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/JogButton/JogButton.settings.vue': () => Promise.resolve().then(function () { return __glob_2_75 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/JogButton/JogButton.vue': () => Promise.resolve().then(function () { return __glob_2_76 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/JumpButton/JumpButton.settings.vue': () => Promise.resolve().then(function () { return __glob_2_77 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/JumpButton/JumpButton.vue': () => Promise.resolve().then(function () { return __glob_2_78 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Language/Language.settings.vue': () => Promise.resolve().then(function () { return __glob_2_79 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Language/Language.vue': () => Promise.resolve().then(function () { return __glob_2_80 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Line/Line.settings.vue': () => Promise.resolve().then(function () { return __glob_2_81 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Line/Line.vue': () => Promise.resolve().then(function () { return __glob_2_82 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/LogManage/LogManage.settings.vue': () => Promise.resolve().then(function () { return __glob_2_83 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/LogManage/LogManage.vue': () => Promise.resolve().then(function () { return __glob_2_84 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Login/Login.settings.vue': () => Promise.resolve().then(function () { return __glob_2_85 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Login/Login.vue': () => Promise.resolve().then(function () { return __glob_2_86 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/NumberFilter/NumberFilter.settings.vue': () => Promise.resolve().then(function () { return __glob_2_87 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/NumberFilter/NumberFilter.vue': () => Promise.resolve().then(function () { return __glob_2_88 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/NumberInput/NumberInput.settings.vue': () => Promise.resolve().then(function () { return __glob_2_89 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/NumberInput/NumberInput.vue': () => Promise.resolve().then(function () { return __glob_2_90 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/NumberShow/NumberShow.settings.vue': () => Promise.resolve().then(function () { return __glob_2_91 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/NumberShow/NumberShow.vue': () => Promise.resolve().then(function () { return __glob_2_92 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PageFrame/PageFrame.settings.vue': () => Promise.resolve().then(function () { return __glob_2_93 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PageFrame/PageFrame.vue': () => Promise.resolve().then(function () { return __glob_2_94 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PageList/PageList.settings.vue': () => Promise.resolve().then(function () { return __glob_2_95 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PageList/PageList.vue': () => Promise.resolve().then(function () { return __glob_2_96 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PermissionManage/PermissionManage.settings.vue': () => Promise.resolve().then(function () { return __glob_2_97 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PermissionManage/PermissionManage.vue': () => Promise.resolve().then(function () { return __glob_2_98 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PopupWindowButton/PopupWindowButton.settings.vue': () => Promise.resolve().then(function () { return __glob_2_99 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PopupWindowButton/PopupWindowButton.vue': () => Promise.resolve().then(function () { return __glob_2_100 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ReadWriteInput/ReadWriteInput.settings.vue': () => Promise.resolve().then(function () { return __glob_2_101 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ReadWriteInput/ReadWriteInput.vue': () => Promise.resolve().then(function () { return __glob_2_102 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Rect/Rect.settings.vue': () => Promise.resolve().then(function () { return __glob_2_103 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Rect/Rect.vue': () => Promise.resolve().then(function () { return __glob_2_104 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/RouterLink/RouterLink.settings.vue': () => Promise.resolve().then(function () { return __glob_2_105 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/RouterLink/RouterLink.vue': () => Promise.resolve().then(function () { return __glob_2_106 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ShutdownButton/ShutdownButton.settings.vue': () => Promise.resolve().then(function () { return __glob_2_107 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ShutdownButton/ShutdownButton.vue': () => Promise.resolve().then(function () { return __glob_2_108 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/StaticText/StaticText.settings.vue': () => Promise.resolve().then(function () { return __glob_2_109 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/StaticText/StaticText.vue': () => Promise.resolve().then(function () { return __glob_2_110 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/SwitchButton/SwitchButton.settings.vue': () => Promise.resolve().then(function () { return __glob_2_111 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/SwitchButton/SwitchButton.vue': () => Promise.resolve().then(function () { return __glob_2_112 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/TextInput/TextInput.settings.vue': () => Promise.resolve().then(function () { return __glob_2_113 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/TextInput/TextInput.vue': () => Promise.resolve().then(function () { return __glob_2_114 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/UserInformation/UserInformation.settings.vue': () => Promise.resolve().then(function () { return __glob_2_115 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/UserInformation/UserInformation.vue': () => Promise.resolve().then(function () { return __glob_2_116 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/VarList/VarList.settings.vue': () => Promise.resolve().then(function () { return __glob_2_117 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/VarList/VarList.vue': () => Promise.resolve().then(function () { return __glob_2_118 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/VirtualKeyboardButton/VirtualKeyboardButton.settings.vue': () => Promise.resolve().then(function () { return __glob_2_119 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/VirtualKeyboardButton/VirtualKeyboardButton.vue': () => Promise.resolve().then(function () { return __glob_2_120 }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/ExpConfigDialog.vue': () => Promise.resolve().then(function () { return ExpConfigDialog$1 }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/charts.vue': () => Promise.resolve().then(function () { return charts }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/checkbox.vue': () => Promise.resolve().then(function () { return checkbox }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/checkboxGroup.vue': () => Promise.resolve().then(function () { return checkboxGroup$1 }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/color.vue': () => Promise.resolve().then(function () { return color }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/currentPage.vue': () => Promise.resolve().then(function () { return currentPage }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/date.vue': () => Promise.resolve().then(function () { return date }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/file.vue': () => Promise.resolve().then(function () { return file }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/image.vue': () => Promise.resolve().then(function () { return image }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/number.vue': () => Promise.resolve().then(function () { return number$1 }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/page.vue': () => Promise.resolve().then(function () { return page }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/radio.vue': () => Promise.resolve().then(function () { return radio }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/select.vue': () => Promise.resolve().then(function () { return select }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/slide.vue': () => Promise.resolve().then(function () { return slide }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/text.vue': () => Promise.resolve().then(function () { return text }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/variableName.vue': () => Promise.resolve().then(function () { return variableName }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Button/settings/ConfirmBoxSetting.vue': () => Promise.resolve().then(function () { return ConfirmBoxSetting$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrendConfig/components/CurveAnalysis.vue': () => Promise.resolve().then(function () { return CurveAnalysis }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrendConfig/components/CurveDefine.vue': () => Promise.resolve().then(function () { return CurveDefine }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrendConfig/components/EditCurveGroup.vue': () => Promise.resolve().then(function () { return EditCurveGroup$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartTable/components/TableColumn.vue': () => Promise.resolve().then(function () { return TableColumn$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DateRange/controller/ControllerIcon.vue': () => Promise.resolve().then(function () { return ControllerIcon }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DateRange/controller/DateRangeIcon.vue': () => Promise.resolve().then(function () { return DateRangeIcon$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DateRange/settings/ControllerCharts.vue': () => Promise.resolve().then(function () { return ControllerCharts$5 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropdownMenu/components/function-tree.vue': () => Promise.resolve().then(function () { return functionTree$3 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropdownMenu/components/menu-style.vue': () => Promise.resolve().then(function () { return menuStyle }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropdownMenu/components/styleSetting.vue': () => Promise.resolve().then(function () { return styleSetting }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropdownMenu/components/type.vue': () => Promise.resolve().then(function () { return type }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Dynamic/components/Condition.vue': () => Promise.resolve().then(function () { return Condition$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Dynamic/components/StatusItem.vue': () => Promise.resolve().then(function () { return StatusItem$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ExportButton/settings/ControllerCharts.vue': () => Promise.resolve().then(function () { return ControllerCharts$3 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/LogManage/components/DeviceLog.vue': () => Promise.resolve().then(function () { return DeviceLog }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/LogManage/components/LoginLog.vue': () => Promise.resolve().then(function () { return LoginLog }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/LogManage/components/ModuleLog.vue': () => Promise.resolve().then(function () { return ModuleLog }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Login/components/Shadow.vue': () => Promise.resolve().then(function () { return Shadow$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Login/components/ShapeConfiguration.vue': () => Promise.resolve().then(function () { return ShapeConfiguration$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Login/components/TextConfiguration.vue': () => Promise.resolve().then(function () { return TextConfiguration$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PermissionManage/components/RoleManage.vue': () => Promise.resolve().then(function () { return RoleManage }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PermissionManage/components/UserManage.vue': () => Promise.resolve().then(function () { return UserManage }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/SwitchButton/components/Switch.vue': () => Promise.resolve().then(function () { return Switch$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/other/StyleConditionsDialog.vue': () => Promise.resolve().then(function () { return StyleConditionsDialog$2 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/Data.vue': () => Promise.resolve().then(function () { return Data$5 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/DataDimissions.vue': () => Promise.resolve().then(function () { return DataDimissions$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/DataFeildConfig.vue': () => Promise.resolve().then(function () { return DataFeildConfig$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/DataIndexes.vue': () => Promise.resolve().then(function () { return DataIndexes$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/DataZoom.vue': () => Promise.resolve().then(function () { return DataZoom$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/DataZoomConfig.vue': () => Promise.resolve().then(function () { return DataZoomConfig$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/Grid.vue': () => Promise.resolve().then(function () { return Grid$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/Label.vue': () => Promise.resolve().then(function () { return Label$2 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/Legend.vue': () => Promise.resolve().then(function () { return Legend$3 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/LegendColor.vue': () => Promise.resolve().then(function () { return LegendColor$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/MarkLineConfig.vue': () => Promise.resolve().then(function () { return MarkLineConfig$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/Padding.vue': () => Promise.resolve().then(function () { return Padding$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/QueryConditions.vue': () => Promise.resolve().then(function () { return QueryConditions$5 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/StyleConditions.vue': () => Promise.resolve().then(function () { return StyleConditions$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/Title.vue': () => Promise.resolve().then(function () { return Title$3 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/Toolbox.vue': () => Promise.resolve().then(function () { return Toolbox }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/Type.vue': () => Promise.resolve().then(function () { return Type$4 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/XAxis.vue': () => Promise.resolve().then(function () { return XAxis$3 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/YAxis.vue': () => Promise.resolve().then(function () { return YAxis$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/_.vue': () => Promise.resolve().then(function () { return _ }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartCard/components/settings/Dialog.vue': () => Promise.resolve().then(function () { return Dialog$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartCard/components/settings/LabelSettings.vue': () => Promise.resolve().then(function () { return LabelSettings$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrend/components/settings/Legend.vue': () => Promise.resolve().then(function () { return Legend$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrend/components/settings/QueryConditions.vue': () => Promise.resolve().then(function () { return QueryConditions$3 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrend/components/settings/SetChart.vue': () => Promise.resolve().then(function () { return SetChart$3 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrend/components/settings/Toolbar.vue': () => Promise.resolve().then(function () { return Toolbar$5 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrend/components/settings/XAxis.vue': () => Promise.resolve().then(function () { return XAxis$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartTable/components/settings/Dialog.vue': () => Promise.resolve().then(function () { return Dialog$3 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartTable/components/settings/HeaderSettingDialog.vue': () => Promise.resolve().then(function () { return HeaderSettingDialog$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PermissionManage/components/dialogs/ManageDialog.vue': () => Promise.resolve().then(function () { return ManageDialog }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PermissionManage/components/dialogs/ResetDialog.vue': () => Promise.resolve().then(function () { return ResetDialog$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PermissionManage/components/dialogs/RoleDialog.vue': () => Promise.resolve().then(function () { return RoleDialog$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PermissionManage/components/dialogs/UserDialog.vue': () => Promise.resolve().then(function () { return UserDialog }), } for (const filePath in vueFileMap) { const component2 = vueFileMap[filePath] routes.push({ path: filePath .replace(/^../, '/:path(.*)') .replace(/([^/\\]+)\.vue$/, ':file($1|$1.vue)?'), component: component2, }) } const router = createRouter({ history: createWebHashHistory(), routes, }) let lastProjectId = Session.get('X-Project-ID') + '' let userInfoLoaded = false let licenseInfoLoaded = false router.beforeEach(async (to, from, next) => { await projectInit(to, from) next() }) let isStartSocket = false async function projectInit(to, from) { let { projectId } = to.params if (projectId !== from.params.projectId) { await app.setCurrentProject({ id: projectId + '', }) } if (projectId) { if (!isStartSocket) { isStartSocket = true await Promise.all([ Variable.start(), initSocket(), (async () => { if (to.name === 'running') { app.dataeventSocket = new Socket({ url: `/hubs/v1/dataevent`, name: '\u5168\u5C40\u4E8B\u4EF6', }) await app.dataeventSocket.start() } })(), (async () => { if (app.running) await accessSocketInVision() })(), ]) } } const token = Session.get('Token') let type4 = '' if (!editing && !token) { type4 = 'Tourist' } if (!token || (projectId && lastProjectId !== projectId)) { lastProjectId = projectId const rs2 = await request({ url: `/api/v1/auth/requesttoken`, method: 'post', data: type4, }) Session.set('Token', rs2) } if (projectId && !userInfoLoaded) { const user2 = await request('/api/v1/authority/user/current') Variable._store['Client_LoginUser'] = user2.name const permissions = await request( `/api/v1/authority/roleclaim/user/${user2.id}` ) userInfo.user = user2 userInfo.permissions.all = permissions.all userInfo.permissions.pages = permissions.left userInfo.permissions.widgets = permissions.right userInfoLoaded = true } if (!licenseInfoLoaded) { await getLicenseInfo() licenseInfoLoaded = true } } var router$1 = router var moduleA = { namespaced: true, modules: { account: { state: { name: 'tom', age: 18, sex: true, }, getters: { getAge(state2) { if (state2.age >= 18) return '\u6210\u5E74' return '\u672A\u6210\u5E74' }, }, mutations: { setAge(state2, age) { state2.age = age }, }, actions: { setAgeActions(context2, age) { setTimeout(() => { context2.commit('setAge', age) }, 1e3) }, }, }, }, } var __glob_1_0$1 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: moduleA, }, Symbol.toStringTag, { value: 'Module' } ) ) var moduleB = { namespaced: true, modules: { account: { state: { name: 'Anne', age: 16, sex: false, }, getters: { getAge(state2) { if (state2.age >= 18) return '\u6210\u5E74' return '\u672A\u6210\u5E74' }, }, mutations: { setAge(state2, age) { state2.age = age }, }, actions: { setAgeActions(context2, age) { setTimeout(() => { context2.commit('setAge', age) }, 1e3) }, }, }, }, } var __glob_1_1$1 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: moduleB, }, Symbol.toStringTag, { value: 'Module' } ) ) var pictureProduction = { namespaced: true, modules: { constant: { selectComponent: { selectAttribute: 'style', data: { id: '', name: '', alias: '', type: '', moduleType: 'standardControls', style: {}, event: {}, }, list: [], }, pageContent: { projectId: '', id: '', name: '', canvasBox: { drag: { model: 'off', space: false, ctrl: false, mousedown: false, canvasLeftInit: 0, canvasTopInit: 0, initX: 0, initY: 0, }, width: 0, height: 0, left: 0, top: 0, x: 0, y: 0, zoom: 100, backgroundColor: '#ffffff', }, components: [], }, }, account: { state: { constant: { selectComponent: { selectAttribute: 'style', data: { id: '', name: '', alias: '', type: '', style: {}, event: {}, }, list: [], }, pageContent: { projectId: '', id: '', name: '', canvasBox: { drag: { model: 'off', space: false, ctrl: false, mousedown: false, canvasLeftInit: 0, canvasTopInit: 0, initX: 0, initY: 0, }, width: 0, height: 0, left: 0, top: 0, x: 0, y: 0, zoom: 100, backgroundColor: '#ffffff', }, components: [], }, }, pageContent: { projectId: '', id: '', name: '', canvasBox: { drag: { model: 'off', space: false, ctrl: false, mousedown: false, canvasLeftInit: 0, canvasTopInit: 0, initX: 0, initY: 0, }, width: 0, height: 0, left: 0, top: 0, x: 0, y: 0, zoom: 100, backgroundColor: '#ffffff', }, components: [], }, cacheComponents: { state: 'off', list: [], }, }, mutations: { setPageContent(state2, pageContent) { state2.pageContent = pageContent }, setPageContentComponents(state2, components) { state2.pageContent.components = components }, addPageContentComponents(state2, components) { state2.pageContent.components.push(components) }, editPageContentComponents(state2, data2) { state2.pageContent.components[data2.index] = JSON.parse( JSON.stringify(data2.components) ) }, setCacheComponents(state2, components) { state2.cacheComponents.list = components }, }, }, }, } var __glob_1_2$1 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: pictureProduction, }, Symbol.toStringTag, { value: 'Module' } ) ) /*! * vuex v4.1.0 * (c) 2022 Evan You * @license MIT */ var storeKey = 'store' function useStore(key2) { if (key2 === void 0) key2 = null return inject(key2 !== null ? key2 : storeKey) } function find$4(list2, f2) { return list2.filter(f2)[0] } function deepCopy$1(obj, cache2) { if (cache2 === void 0) cache2 = [] if (obj === null || typeof obj !== 'object') { return obj } var hit = find$4(cache2, function (c2) { return c2.original === obj }) if (hit) { return hit.copy } var copy2 = Array.isArray(obj) ? [] : {} cache2.push({ original: obj, copy: copy2, }) Object.keys(obj).forEach(function (key2) { copy2[key2] = deepCopy$1(obj[key2], cache2) }) return copy2 } function forEachValue(obj, fn2) { Object.keys(obj).forEach(function (key2) { return fn2(obj[key2], key2) }) } function isObject$r(obj) { return obj !== null && typeof obj === 'object' } function isPromise(val2) { return val2 && typeof val2.then === 'function' } function partial(fn2, arg) { return function () { return fn2(arg) } } function genericSubscribe(fn2, subs, options2) { if (subs.indexOf(fn2) < 0) { options2 && options2.prepend ? subs.unshift(fn2) : subs.push(fn2) } return function () { var i2 = subs.indexOf(fn2) if (i2 > -1) { subs.splice(i2, 1) } } } function resetStore(store2, hot) { store2._actions = /* @__PURE__ */ Object.create(null) store2._mutations = /* @__PURE__ */ Object.create(null) store2._wrappedGetters = /* @__PURE__ */ Object.create(null) store2._modulesNamespaceMap = /* @__PURE__ */ Object.create(null) var state2 = store2.state installModule(store2, state2, [], store2._modules.root, true) resetStoreState(store2, state2, hot) } function resetStoreState(store2, state2, hot) { var oldState = store2._state var oldScope = store2._scope store2.getters = {} store2._makeLocalGettersCache = /* @__PURE__ */ Object.create(null) var wrappedGetters = store2._wrappedGetters var computedObj = {} var computedCache = {} var scope = effectScope(true) scope.run(function () { forEachValue(wrappedGetters, function (fn2, key2) { computedObj[key2] = partial(fn2, store2) computedCache[key2] = computed(function () { return computedObj[key2]() }) Object.defineProperty(store2.getters, key2, { get: function () { return computedCache[key2].value }, enumerable: true, }) }) }) store2._state = reactive({ data: state2, }) store2._scope = scope if (store2.strict) { enableStrictMode(store2) } if (oldState) { if (hot) { store2._withCommit(function () { oldState.data = null }) } } if (oldScope) { oldScope.stop() } } function installModule(store2, rootState, path, module2, hot) { var isRoot = !path.length var namespace = store2._modules.getNamespace(path) if (module2.namespaced) { if (store2._modulesNamespaceMap[namespace] && false) { console.error( '[vuex] duplicate namespace ' + namespace + ' for the namespaced module ' + path.join('/') ) } store2._modulesNamespaceMap[namespace] = module2 } if (!isRoot && !hot) { var parentState = getNestedState(rootState, path.slice(0, -1)) var moduleName = path[path.length - 1] store2._withCommit(function () { parentState[moduleName] = module2.state }) } var local = (module2.context = makeLocalContext(store2, namespace, path)) module2.forEachMutation(function (mutation, key2) { var namespacedType = namespace + key2 registerMutation(store2, namespacedType, mutation, local) }) module2.forEachAction(function (action, key2) { var type4 = action.root ? key2 : namespace + key2 var handler = action.handler || action registerAction$1(store2, type4, handler, local) }) module2.forEachGetter(function (getter, key2) { var namespacedType = namespace + key2 registerGetter(store2, namespacedType, getter, local) }) module2.forEachChild(function (child, key2) { installModule(store2, rootState, path.concat(key2), child, hot) }) } function makeLocalContext(store2, namespace, path) { var noNamespace = namespace === '' var local = { dispatch: noNamespace ? store2.dispatch : function (_type, _payload, _options) { var args = unifyObjectStyle(_type, _payload, _options) var payload = args.payload var options2 = args.options var type4 = args.type if (!options2 || !options2.root) { type4 = namespace + type4 } return store2.dispatch(type4, payload) }, commit: noNamespace ? store2.commit : function (_type, _payload, _options) { var args = unifyObjectStyle(_type, _payload, _options) var payload = args.payload var options2 = args.options var type4 = args.type if (!options2 || !options2.root) { type4 = namespace + type4 } store2.commit(type4, payload, options2) }, } Object.defineProperties(local, { getters: { get: noNamespace ? function () { return store2.getters } : function () { return makeLocalGetters(store2, namespace) }, }, state: { get: function () { return getNestedState(store2.state, path) }, }, }) return local } function makeLocalGetters(store2, namespace) { if (!store2._makeLocalGettersCache[namespace]) { var gettersProxy = {} var splitPos = namespace.length Object.keys(store2.getters).forEach(function (type4) { if (type4.slice(0, splitPos) !== namespace) { return } var localType = type4.slice(splitPos) Object.defineProperty(gettersProxy, localType, { get: function () { return store2.getters[type4] }, enumerable: true, }) }) store2._makeLocalGettersCache[namespace] = gettersProxy } return store2._makeLocalGettersCache[namespace] } function registerMutation(store2, type4, handler, local) { var entry = store2._mutations[type4] || (store2._mutations[type4] = []) entry.push(function wrappedMutationHandler(payload) { handler.call(store2, local.state, payload) }) } function registerAction$1(store2, type4, handler, local) { var entry = store2._actions[type4] || (store2._actions[type4] = []) entry.push(function wrappedActionHandler(payload) { var res = handler.call( store2, { dispatch: local.dispatch, commit: local.commit, getters: local.getters, state: local.state, rootGetters: store2.getters, rootState: store2.state, }, payload ) if (!isPromise(res)) { res = Promise.resolve(res) } if (store2._devtoolHook) { return res.catch(function (err) { store2._devtoolHook.emit('vuex:error', err) throw err }) } else { return res } }) } function registerGetter(store2, type4, rawGetter, local) { if (store2._wrappedGetters[type4]) { return } store2._wrappedGetters[type4] = function wrappedGetter(store3) { return rawGetter(local.state, local.getters, store3.state, store3.getters) } } function enableStrictMode(store2) { watch$1( function () { return store2._state.data }, function () {}, { deep: true, flush: 'sync' } ) } function getNestedState(state2, path) { return path.reduce(function (state3, key2) { return state3[key2] }, state2) } function unifyObjectStyle(type4, payload, options2) { if (isObject$r(type4) && type4.type) { options2 = payload payload = type4 type4 = type4.type } return { type: type4, payload, options: options2 } } var LABEL_VUEX_BINDINGS = 'vuex bindings' var MUTATIONS_LAYER_ID = 'vuex:mutations' var ACTIONS_LAYER_ID = 'vuex:actions' var INSPECTOR_ID = 'vuex' var actionId = 0 function addDevtools(app2, store2) { setupDevtoolsPlugin( { id: 'org.vuejs.vuex', app: app2, label: 'Vuex', homepage: 'https://next.vuex.vuejs.org/', logo: 'https://vuejs.org/images/icons/favicon-96x96.png', packageName: 'vuex', componentStateTypes: [LABEL_VUEX_BINDINGS], }, function (api) { api.addTimelineLayer({ id: MUTATIONS_LAYER_ID, label: 'Vuex Mutations', color: COLOR_LIME_500, }) api.addTimelineLayer({ id: ACTIONS_LAYER_ID, label: 'Vuex Actions', color: COLOR_LIME_500, }) api.addInspector({ id: INSPECTOR_ID, label: 'Vuex', icon: 'storage', treeFilterPlaceholder: 'Filter stores...', }) api.on.getInspectorTree(function (payload) { if (payload.app === app2 && payload.inspectorId === INSPECTOR_ID) { if (payload.filter) { var nodes = [] flattenStoreForInspectorTree( nodes, store2._modules.root, payload.filter, '' ) payload.rootNodes = nodes } else { payload.rootNodes = [ formatStoreForInspectorTree(store2._modules.root, ''), ] } } }) api.on.getInspectorState(function (payload) { if (payload.app === app2 && payload.inspectorId === INSPECTOR_ID) { var modulePath = payload.nodeId makeLocalGetters(store2, modulePath) payload.state = formatStoreForInspectorState( getStoreModule(store2._modules, modulePath), modulePath === 'root' ? store2.getters : store2._makeLocalGettersCache, modulePath ) } }) api.on.editInspectorState(function (payload) { if (payload.app === app2 && payload.inspectorId === INSPECTOR_ID) { var modulePath = payload.nodeId var path = payload.path if (modulePath !== 'root') { path = modulePath.split('/').filter(Boolean).concat(path) } store2._withCommit(function () { payload.set(store2._state.data, path, payload.state.value) }) } }) store2.subscribe(function (mutation, state2) { var data2 = {} if (mutation.payload) { data2.payload = mutation.payload } data2.state = state2 api.notifyComponentUpdate() api.sendInspectorTree(INSPECTOR_ID) api.sendInspectorState(INSPECTOR_ID) api.addTimelineEvent({ layerId: MUTATIONS_LAYER_ID, event: { time: Date.now(), title: mutation.type, data: data2, }, }) }) store2.subscribeAction({ before: function (action, state2) { var data2 = {} if (action.payload) { data2.payload = action.payload } action._id = actionId++ action._time = Date.now() data2.state = state2 api.addTimelineEvent({ layerId: ACTIONS_LAYER_ID, event: { time: action._time, title: action.type, groupId: action._id, subtitle: 'start', data: data2, }, }) }, after: function (action, state2) { var data2 = {} var duration2 = Date.now() - action._time data2.duration = { _custom: { type: 'duration', display: duration2 + 'ms', tooltip: 'Action duration', value: duration2, }, } if (action.payload) { data2.payload = action.payload } data2.state = state2 api.addTimelineEvent({ layerId: ACTIONS_LAYER_ID, event: { time: Date.now(), title: action.type, groupId: action._id, subtitle: 'end', data: data2, }, }) }, }) } ) } var COLOR_LIME_500 = 8702998 var COLOR_DARK = 6710886 var COLOR_WHITE = 16777215 var TAG_NAMESPACED = { label: 'namespaced', textColor: COLOR_WHITE, backgroundColor: COLOR_DARK, } function extractNameFromPath(path) { return path && path !== 'root' ? path.split('/').slice(-2, -1)[0] : 'Root' } function formatStoreForInspectorTree(module2, path) { return { id: path || 'root', label: extractNameFromPath(path), tags: module2.namespaced ? [TAG_NAMESPACED] : [], children: Object.keys(module2._children).map(function (moduleName) { return formatStoreForInspectorTree( module2._children[moduleName], path + moduleName + '/' ) }), } } function flattenStoreForInspectorTree(result, module2, filter2, path) { if (path.includes(filter2)) { result.push({ id: path || 'root', label: path.endsWith('/') ? path.slice(0, path.length - 1) : path || 'Root', tags: module2.namespaced ? [TAG_NAMESPACED] : [], }) } Object.keys(module2._children).forEach(function (moduleName) { flattenStoreForInspectorTree( result, module2._children[moduleName], filter2, path + moduleName + '/' ) }) } function formatStoreForInspectorState(module2, getters2, path) { getters2 = path === 'root' ? getters2 : getters2[path] var gettersKeys = Object.keys(getters2) var storeState = { state: Object.keys(module2.state).map(function (key2) { return { key: key2, editable: true, value: module2.state[key2], } }), } if (gettersKeys.length) { var tree = transformPathsToObjectTree(getters2) storeState.getters = Object.keys(tree).map(function (key2) { return { key: key2.endsWith('/') ? extractNameFromPath(key2) : key2, editable: false, value: canThrow(function () { return tree[key2] }), } }) } return storeState } function transformPathsToObjectTree(getters2) { var result = {} Object.keys(getters2).forEach(function (key2) { var path = key2.split('/') if (path.length > 1) { var target2 = result var leafKey = path.pop() path.forEach(function (p2) { if (!target2[p2]) { target2[p2] = { _custom: { value: {}, display: p2, tooltip: 'Module', abstract: true, }, } } target2 = target2[p2]._custom.value }) target2[leafKey] = canThrow(function () { return getters2[key2] }) } else { result[key2] = canThrow(function () { return getters2[key2] }) } }) return result } function getStoreModule(moduleMap2, path) { var names2 = path.split('/').filter(function (n2) { return n2 }) return names2.reduce( function (module2, moduleName, i2) { var child = module2[moduleName] if (!child) { throw new Error( 'Missing module "' + moduleName + '" for path "' + path + '".' ) } return i2 === names2.length - 1 ? child : child._children }, path === 'root' ? moduleMap2 : moduleMap2.root._children ) } function canThrow(cb) { try { return cb() } catch (e2) { return e2 } } var Module = function Module2(rawModule, runtime) { this.runtime = runtime this._children = /* @__PURE__ */ Object.create(null) this._rawModule = rawModule var rawState = rawModule.state this.state = (typeof rawState === 'function' ? rawState() : rawState) || {} } var prototypeAccessors$1 = { namespaced: { configurable: true } } prototypeAccessors$1.namespaced.get = function () { return !!this._rawModule.namespaced } Module.prototype.addChild = function addChild2(key2, module2) { this._children[key2] = module2 } Module.prototype.removeChild = function removeChild2(key2) { delete this._children[key2] } Module.prototype.getChild = function getChild2(key2) { return this._children[key2] } Module.prototype.hasChild = function hasChild(key2) { return key2 in this._children } Module.prototype.update = function update2(rawModule) { this._rawModule.namespaced = rawModule.namespaced if (rawModule.actions) { this._rawModule.actions = rawModule.actions } if (rawModule.mutations) { this._rawModule.mutations = rawModule.mutations } if (rawModule.getters) { this._rawModule.getters = rawModule.getters } } Module.prototype.forEachChild = function forEachChild(fn2) { forEachValue(this._children, fn2) } Module.prototype.forEachGetter = function forEachGetter(fn2) { if (this._rawModule.getters) { forEachValue(this._rawModule.getters, fn2) } } Module.prototype.forEachAction = function forEachAction(fn2) { if (this._rawModule.actions) { forEachValue(this._rawModule.actions, fn2) } } Module.prototype.forEachMutation = function forEachMutation(fn2) { if (this._rawModule.mutations) { forEachValue(this._rawModule.mutations, fn2) } } Object.defineProperties(Module.prototype, prototypeAccessors$1) var ModuleCollection = function ModuleCollection2(rawRootModule) { this.register([], rawRootModule, false) } ModuleCollection.prototype.get = function get2(path) { return path.reduce(function (module2, key2) { return module2.getChild(key2) }, this.root) } ModuleCollection.prototype.getNamespace = function getNamespace(path) { var module2 = this.root return path.reduce(function (namespace, key2) { module2 = module2.getChild(key2) return namespace + (module2.namespaced ? key2 + '/' : '') }, '') } ModuleCollection.prototype.update = function update$1(rawRootModule) { update([], this.root, rawRootModule) } ModuleCollection.prototype.register = function register3( path, rawModule, runtime ) { var this$1$1 = this if (runtime === void 0) runtime = true var newModule = new Module(rawModule, runtime) if (path.length === 0) { this.root = newModule } else { var parent2 = this.get(path.slice(0, -1)) parent2.addChild(path[path.length - 1], newModule) } if (rawModule.modules) { forEachValue(rawModule.modules, function (rawChildModule, key2) { this$1$1.register(path.concat(key2), rawChildModule, runtime) }) } } ModuleCollection.prototype.unregister = function unregister2(path) { var parent2 = this.get(path.slice(0, -1)) var key2 = path[path.length - 1] var child = parent2.getChild(key2) if (!child) { return } if (!child.runtime) { return } parent2.removeChild(key2) } ModuleCollection.prototype.isRegistered = function isRegistered(path) { var parent2 = this.get(path.slice(0, -1)) var key2 = path[path.length - 1] if (parent2) { return parent2.hasChild(key2) } return false } function update(path, targetModule, newModule) { targetModule.update(newModule) if (newModule.modules) { for (var key2 in newModule.modules) { if (!targetModule.getChild(key2)) { return } update( path.concat(key2), targetModule.getChild(key2), newModule.modules[key2] ) } } } function createStore(options2) { return new Store$1(options2) } var Store$1 = function Store2(options2) { var this$1$1 = this if (options2 === void 0) options2 = {} var plugins2 = options2.plugins if (plugins2 === void 0) plugins2 = [] var strict = options2.strict if (strict === void 0) strict = false var devtools2 = options2.devtools this._committing = false this._actions = /* @__PURE__ */ Object.create(null) this._actionSubscribers = [] this._mutations = /* @__PURE__ */ Object.create(null) this._wrappedGetters = /* @__PURE__ */ Object.create(null) this._modules = new ModuleCollection(options2) this._modulesNamespaceMap = /* @__PURE__ */ Object.create(null) this._subscribers = [] this._makeLocalGettersCache = /* @__PURE__ */ Object.create(null) this._scope = null this._devtools = devtools2 var store2 = this var ref2 = this var dispatch2 = ref2.dispatch var commit2 = ref2.commit this.dispatch = function boundDispatch(type4, payload) { return dispatch2.call(store2, type4, payload) } this.commit = function boundCommit(type4, payload, options3) { return commit2.call(store2, type4, payload, options3) } this.strict = strict var state2 = this._modules.root.state installModule(this, state2, [], this._modules.root) resetStoreState(this, state2) plugins2.forEach(function (plugin) { return plugin(this$1$1) }) } var prototypeAccessors = { state: { configurable: true } } Store$1.prototype.install = function install2(app2, injectKey) { app2.provide(injectKey || storeKey, this) app2.config.globalProperties.$store = this var useDevtools = this._devtools !== void 0 ? this._devtools : false if (useDevtools) { addDevtools(app2, this) } } prototypeAccessors.state.get = function () { return this._state.data } prototypeAccessors.state.set = function (v4) {} Store$1.prototype.commit = function commit(_type, _payload, _options) { var this$1$1 = this var ref2 = unifyObjectStyle(_type, _payload, _options) var type4 = ref2.type var payload = ref2.payload var mutation = { type: type4, payload } var entry = this._mutations[type4] if (!entry) { return } this._withCommit(function () { entry.forEach(function commitIterator(handler) { handler(payload) }) }) this._subscribers.slice().forEach(function (sub2) { return sub2(mutation, this$1$1.state) }) } Store$1.prototype.dispatch = function dispatch(_type, _payload) { var this$1$1 = this var ref2 = unifyObjectStyle(_type, _payload) var type4 = ref2.type var payload = ref2.payload var action = { type: type4, payload } var entry = this._actions[type4] if (!entry) { return } try { this._actionSubscribers .slice() .filter(function (sub2) { return sub2.before }) .forEach(function (sub2) { return sub2.before(action, this$1$1.state) }) } catch (e2) {} var result = entry.length > 1 ? Promise.all( entry.map(function (handler) { return handler(payload) }) ) : entry[0](payload) return new Promise(function (resolve2, reject2) { result.then( function (res) { try { this$1$1._actionSubscribers .filter(function (sub2) { return sub2.after }) .forEach(function (sub2) { return sub2.after(action, this$1$1.state) }) } catch (e2) {} resolve2(res) }, function (error2) { try { this$1$1._actionSubscribers .filter(function (sub2) { return sub2.error }) .forEach(function (sub2) { return sub2.error(action, this$1$1.state, error2) }) } catch (e2) {} reject2(error2) } ) }) } Store$1.prototype.subscribe = function subscribe2(fn2, options2) { return genericSubscribe(fn2, this._subscribers, options2) } Store$1.prototype.subscribeAction = function subscribeAction(fn2, options2) { var subs = typeof fn2 === 'function' ? { before: fn2 } : fn2 return genericSubscribe(subs, this._actionSubscribers, options2) } Store$1.prototype.watch = function watch$1$1(getter, cb, options2) { var this$1$1 = this return watch$1( function () { return getter(this$1$1.state, this$1$1.getters) }, cb, Object.assign({}, options2) ) } Store$1.prototype.replaceState = function replaceState(state2) { var this$1$1 = this this._withCommit(function () { this$1$1._state.data = state2 }) } Store$1.prototype.registerModule = function registerModule( path, rawModule, options2 ) { if (options2 === void 0) options2 = {} if (typeof path === 'string') { path = [path] } this._modules.register(path, rawModule) installModule( this, this.state, path, this._modules.get(path), options2.preserveState ) resetStoreState(this, this.state) } Store$1.prototype.unregisterModule = function unregisterModule(path) { var this$1$1 = this if (typeof path === 'string') { path = [path] } this._modules.unregister(path) this._withCommit(function () { var parentState = getNestedState(this$1$1.state, path.slice(0, -1)) delete parentState[path[path.length - 1]] }) resetStore(this) } Store$1.prototype.hasModule = function hasModule(path) { if (typeof path === 'string') { path = [path] } return this._modules.isRegistered(path) } Store$1.prototype.hotUpdate = function hotUpdate(newOptions) { this._modules.update(newOptions) resetStore(this, true) } Store$1.prototype._withCommit = function _withCommit(fn2) { var committing = this._committing this._committing = true fn2() this._committing = committing } Object.defineProperties(Store$1.prototype, prototypeAccessors) var mapState = normalizeNamespace(function (namespace, states) { var res = {} normalizeMap(states).forEach(function (ref2) { var key2 = ref2.key var val2 = ref2.val res[key2] = function mappedState() { var state2 = this.$store.state var getters2 = this.$store.getters if (namespace) { var module2 = getModuleByNamespace(this.$store, 'mapState', namespace) if (!module2) { return } state2 = module2.context.state getters2 = module2.context.getters } return typeof val2 === 'function' ? val2.call(this, state2, getters2) : state2[val2] } res[key2].vuex = true }) return res }) var mapMutations = normalizeNamespace(function (namespace, mutations) { var res = {} normalizeMap(mutations).forEach(function (ref2) { var key2 = ref2.key var val2 = ref2.val res[key2] = function mappedMutation() { var args = [], len2 = arguments.length while (len2--) args[len2] = arguments[len2] var commit2 = this.$store.commit if (namespace) { var module2 = getModuleByNamespace( this.$store, 'mapMutations', namespace ) if (!module2) { return } commit2 = module2.context.commit } return typeof val2 === 'function' ? val2.apply(this, [commit2].concat(args)) : commit2.apply(this.$store, [val2].concat(args)) } }) return res }) var mapGetters = normalizeNamespace(function (namespace, getters2) { var res = {} normalizeMap(getters2).forEach(function (ref2) { var key2 = ref2.key var val2 = ref2.val val2 = namespace + val2 res[key2] = function mappedGetter() { if ( namespace && !getModuleByNamespace(this.$store, 'mapGetters', namespace) ) { return } return this.$store.getters[val2] } res[key2].vuex = true }) return res }) var mapActions = normalizeNamespace(function (namespace, actions2) { var res = {} normalizeMap(actions2).forEach(function (ref2) { var key2 = ref2.key var val2 = ref2.val res[key2] = function mappedAction() { var args = [], len2 = arguments.length while (len2--) args[len2] = arguments[len2] var dispatch2 = this.$store.dispatch if (namespace) { var module2 = getModuleByNamespace(this.$store, 'mapActions', namespace) if (!module2) { return } dispatch2 = module2.context.dispatch } return typeof val2 === 'function' ? val2.apply(this, [dispatch2].concat(args)) : dispatch2.apply(this.$store, [val2].concat(args)) } }) return res }) var createNamespacedHelpers = function (namespace) { return { mapState: mapState.bind(null, namespace), mapGetters: mapGetters.bind(null, namespace), mapMutations: mapMutations.bind(null, namespace), mapActions: mapActions.bind(null, namespace), } } function normalizeMap(map2) { if (!isValidMap(map2)) { return [] } return Array.isArray(map2) ? map2.map(function (key2) { return { key: key2, val: key2 } }) : Object.keys(map2).map(function (key2) { return { key: key2, val: map2[key2] } }) } function isValidMap(map2) { return Array.isArray(map2) || isObject$r(map2) } function normalizeNamespace(fn2) { return function (namespace, map2) { if (typeof namespace !== 'string') { map2 = namespace namespace = '' } else if (namespace.charAt(namespace.length - 1) !== '/') { namespace += '/' } return fn2(namespace, map2) } } function getModuleByNamespace(store2, helper2, namespace) { var module2 = store2._modulesNamespaceMap[namespace] return module2 } function createLogger(ref2) { if (ref2 === void 0) ref2 = {} var collapsed = ref2.collapsed if (collapsed === void 0) collapsed = true var filter2 = ref2.filter if (filter2 === void 0) filter2 = function (mutation, stateBefore, stateAfter) { return true } var transformer = ref2.transformer if (transformer === void 0) transformer = function (state2) { return state2 } var mutationTransformer = ref2.mutationTransformer if (mutationTransformer === void 0) mutationTransformer = function (mut) { return mut } var actionFilter = ref2.actionFilter if (actionFilter === void 0) actionFilter = function (action, state2) { return true } var actionTransformer = ref2.actionTransformer if (actionTransformer === void 0) actionTransformer = function (act) { return act } var logMutations = ref2.logMutations if (logMutations === void 0) logMutations = true var logActions = ref2.logActions if (logActions === void 0) logActions = true var logger = ref2.logger if (logger === void 0) logger = console return function (store2) { var prevState = deepCopy$1(store2.state) if (typeof logger === 'undefined') { return } if (logMutations) { store2.subscribe(function (mutation, state2) { var nextState = deepCopy$1(state2) if (filter2(mutation, prevState, nextState)) { var formattedTime = getFormattedTime() var formattedMutation = mutationTransformer(mutation) var message2 = 'mutation ' + mutation.type + formattedTime startMessage(logger, message2, collapsed) logger.log( '%c prev state', 'color: #9E9E9E; font-weight: bold', transformer(prevState) ) logger.log( '%c mutation', 'color: #03A9F4; font-weight: bold', formattedMutation ) logger.log( '%c next state', 'color: #4CAF50; font-weight: bold', transformer(nextState) ) endMessage(logger) } prevState = nextState }) } if (logActions) { store2.subscribeAction(function (action, state2) { if (actionFilter(action, state2)) { var formattedTime = getFormattedTime() var formattedAction = actionTransformer(action) var message2 = 'action ' + action.type + formattedTime startMessage(logger, message2, collapsed) logger.log( '%c action', 'color: #03A9F4; font-weight: bold', formattedAction ) endMessage(logger) } }) } } } function startMessage(logger, message2, collapsed) { var startMessage2 = collapsed ? logger.groupCollapsed : logger.group try { startMessage2.call(logger, message2) } catch (e2) { logger.log(message2) } } function endMessage(logger) { try { logger.groupEnd() } catch (e2) { logger.log('\u2014\u2014 log end \u2014\u2014') } } function getFormattedTime() { var time2 = new Date() return ( ' @ ' + pad$1(time2.getHours(), 2) + ':' + pad$1(time2.getMinutes(), 2) + ':' + pad$1(time2.getSeconds(), 2) + '.' + pad$1(time2.getMilliseconds(), 3) ) } function repeat$2(str, times) { return new Array(times + 1).join(str) } function pad$1(num2, maxLength) { return repeat$2('0', maxLength - num2.toString().length) + num2 } var index$o = { version: '4.1.0', Store: Store$1, storeKey, createStore, useStore, mapState, mapMutations, mapGetters, mapActions, createNamespacedHelpers, createLogger, } var vuex_esmBundler = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: index$o, Store: Store$1, createLogger, createNamespacedHelpers, createStore, mapActions, mapGetters, mapMutations, mapState, storeKey, useStore, }, Symbol.toStringTag, { value: 'Module' } ) ) const modulesFiles = { './modules/moduleA.ts': __glob_1_0$1, './modules/moduleB.ts': __glob_1_1$1, './modules/picture-production.ts': __glob_1_2$1, } const modules$1 = {} for (const key2 in modulesFiles) { modules$1[key2.replace(/(\.\/modules\/|\.ts)/g, '')] = modulesFiles[key2].default } var store$5 = createStore({ modules: modules$1, strict: false, }) var setupDefaults$9 = { cookies: { path: '/', }, treeOptions: { parentKey: 'parentId', key: 'id', children: 'children', }, parseDateFormat: 'yyyy-MM-dd HH:mm:ss', firstDayOfWeek: 1, } var setupDefaults_1 = setupDefaults$9 function arrayEach$g(list2, iterate2, context2) { if (list2) { if (list2.forEach) { list2.forEach(iterate2, context2) } else { for (var index2 = 0, len2 = list2.length; index2 < len2; index2++) { iterate2.call(context2, list2[index2], index2, list2) } } } } var arrayEach_1 = arrayEach$g var objectToString$5 = Object.prototype.toString var staticObjectToString = objectToString$5 var objectToString$4 = staticObjectToString function helperCreateInInObjectString$5(type4) { return function (obj) { return '[object ' + type4 + ']' === objectToString$4.call(obj) } } var helperCreateInInObjectString_1 = helperCreateInInObjectString$5 var helperCreateInInObjectString$4 = helperCreateInInObjectString_1 var isArray$A = Array.isArray || helperCreateInInObjectString$4('Array') var isArray_1$1 = isArray$A function hasOwnProp$a(obj, key2) { return obj && obj.hasOwnProperty ? obj.hasOwnProperty(key2) : false } var hasOwnProp_1 = hasOwnProp$a var hasOwnProp$9 = hasOwnProp_1 function objectEach$5(obj, iterate2, context2) { if (obj) { for (var key2 in obj) { if (hasOwnProp$9(obj, key2)) { iterate2.call(context2, obj[key2], key2, obj) } } } } var objectEach_1 = objectEach$5 var isArray$z = isArray_1$1 var arrayEach$f = arrayEach_1 var objectEach$4 = objectEach_1 function each$z(obj, iterate2, context2) { if (obj) { return (isArray$z(obj) ? arrayEach$f : objectEach$4)( obj, iterate2, context2 ) } return obj } var each_1 = each$z function helperCreateInTypeof$6(type4) { return function (obj) { return typeof obj === type4 } } var helperCreateInTypeof_1 = helperCreateInTypeof$6 var helperCreateInTypeof$5 = helperCreateInTypeof_1 var isFunction$i = helperCreateInTypeof$5('function') var isFunction_1$1 = isFunction$i var each$y = each_1 function helperCreateGetObjects$3(name2, getIndex) { var proMethod = Object[name2] return function (obj) { var result = [] if (obj) { if (proMethod) { return proMethod(obj) } each$y( obj, getIndex > 1 ? function (key2) { result.push(['' + key2, obj[key2]]) } : function () { result.push(arguments[getIndex]) } ) } return result } } var helperCreateGetObjects_1 = helperCreateGetObjects$3 var helperCreateGetObjects$2 = helperCreateGetObjects_1 var keys$g = helperCreateGetObjects$2('keys', 1) var keys_1$1 = keys$g var objectToString$3 = staticObjectToString var objectEach$3 = objectEach_1 var arrayEach$e = arrayEach_1 function getCativeCtor(val2, args) { var Ctor = val2.__proto__.constructor return args ? new Ctor(args) : new Ctor() } function handleValueClone(item2, isDeep) { return isDeep ? copyValue$1(item2, isDeep) : item2 } function copyValue$1(val2, isDeep) { if (val2) { switch (objectToString$3.call(val2)) { case '[object Object]': { var restObj = Object.create(val2.__proto__) objectEach$3(val2, function (item2, key2) { restObj[key2] = handleValueClone(item2, isDeep) }) return restObj } case '[object Date]': case '[object RegExp]': { return getCativeCtor(val2, val2.valueOf()) } case '[object Array]': case '[object Arguments]': { var restArr = [] arrayEach$e(val2, function (item2) { restArr.push(handleValueClone(item2, isDeep)) }) return restArr } case '[object Set]': { var restSet = getCativeCtor(val2) restSet.forEach(function (item2) { restSet.add(handleValueClone(item2, isDeep)) }) return restSet } case '[object Map]': { var restMap = getCativeCtor(val2) restMap.forEach(function (item2, key2) { restMap.set(key2, handleValueClone(item2, isDeep)) }) return restMap } } } return val2 } function clone$a(obj, deep) { if (obj) { return copyValue$1(obj, deep) } return obj } var clone_1 = clone$a var arrayEach$d = arrayEach_1 var keys$f = keys_1$1 var isArray$y = isArray_1$1 var clone$9 = clone_1 var objectAssignFns = Object.assign function handleAssign(destination, args, isClone) { var len2 = args.length for (var source2, index2 = 1; index2 < len2; index2++) { source2 = args[index2] arrayEach$d( keys$f(args[index2]), isClone ? function (key2) { destination[key2] = clone$9(source2[key2], isClone) } : function (key2) { destination[key2] = source2[key2] } ) } return destination } var assign$d = function (target2) { if (target2) { var args = arguments if (target2 === true) { if (args.length > 1) { target2 = isArray$y(target2[1]) ? [] : {} return handleAssign(target2, args, true) } } else { return objectAssignFns ? objectAssignFns.apply(Object, args) : handleAssign(target2, args) } } return target2 } var assign_1 = assign$d var setupDefaults$8 = setupDefaults_1 var arrayEach$c = arrayEach_1 var each$x = each_1 var isFunction$h = isFunction_1$1 var assign$c = assign_1 var XEUtils$1 = function () {} function mixin$1() { arrayEach$c(arguments, function (methods) { each$x(methods, function (fn2, name2) { XEUtils$1[name2] = isFunction$h(fn2) ? function () { var result = fn2.apply(XEUtils$1.$context, arguments) XEUtils$1.$context = null return result } : fn2 }) }) } function setup$1(options2) { return assign$c(setupDefaults$8, options2) } XEUtils$1.VERSION = '3.5.14' XEUtils$1.mixin = mixin$1 XEUtils$1.setup = setup$1 var ctor = XEUtils$1 function lastArrayEach$3(obj, iterate2, context2) { for (var len2 = obj.length - 1; len2 >= 0; len2--) { iterate2.call(context2, obj[len2], len2, obj) } } var lastArrayEach_1 = lastArrayEach$3 var lastArrayEach$2 = lastArrayEach_1 var keys$e = keys_1$1 function lastObjectEach$2(obj, iterate2, context2) { lastArrayEach$2(keys$e(obj), function (key2) { iterate2.call(context2, obj[key2], key2, obj) }) } var lastObjectEach_1 = lastObjectEach$2 function isNull$9(obj) { return obj === null } var isNull_1 = isNull$9 var isNull$8 = isNull_1 function property$6(name2, defs) { return function (obj) { return isNull$8(obj) ? defs : obj[name2] } } var property_1 = property$6 var each$w = each_1 var isFunction$g = isFunction_1$1 var property$5 = property_1 function objectMap$1(obj, iterate2, context2) { var result = {} if (obj) { if (iterate2) { if (!isFunction$g(iterate2)) { iterate2 = property$5(iterate2) } each$w(obj, function (val2, index2) { result[index2] = iterate2.call(context2, val2, index2, obj) }) } else { return obj } } return result } var objectMap_1 = objectMap$1 function isPlainObject$7(obj) { return obj ? obj.constructor === Object : false } var isPlainObject_1 = isPlainObject$7 var isArray$x = isArray_1$1 var isPlainObject$6 = isPlainObject_1 var each$v = each_1 function handleMerge(target2, source2) { if ( (isPlainObject$6(target2) && isPlainObject$6(source2)) || (isArray$x(target2) && isArray$x(source2)) ) { each$v(source2, function (obj, key2) { target2[key2] = handleMerge(target2[key2], obj) }) return target2 } return source2 } var merge$2 = function (target2) { if (!target2) { target2 = {} } var args = arguments var len2 = args.length for (var source2, index2 = 1; index2 < len2; index2++) { source2 = args[index2] if (source2) { handleMerge(target2, source2) } } return target2 } var merge_1 = merge$2 var each$u = each_1 function map$8(obj, iterate2, context2) { var result = [] if (obj && arguments.length > 1) { if (obj.map) { return obj.map(iterate2, context2) } else { each$u(obj, function () { result.push(iterate2.apply(context2, arguments)) }) } } return result } var map_1 = map$8 var hasOwnProp$8 = hasOwnProp_1 var isArray$w = isArray_1$1 function helperCreateIterateHandle$4( prop, useArray, restIndex, matchValue, defaultValue ) { return function (obj, iterate2, context2) { if (obj && iterate2) { if (prop && obj[prop]) { return obj[prop](iterate2, context2) } else { if (useArray && isArray$w(obj)) { for (var index2 = 0, len2 = obj.length; index2 < len2; index2++) { if ( !!iterate2.call(context2, obj[index2], index2, obj) === matchValue ) { return [true, false, index2, obj[index2]][restIndex] } } } else { for (var key2 in obj) { if (hasOwnProp$8(obj, key2)) { if ( !!iterate2.call(context2, obj[key2], key2, obj) === matchValue ) { return [true, false, key2, obj[key2]][restIndex] } } } } } } return defaultValue } } var helperCreateIterateHandle_1 = helperCreateIterateHandle$4 var helperCreateIterateHandle$3 = helperCreateIterateHandle_1 var some$2 = helperCreateIterateHandle$3('some', 1, 0, true, false) var some_1 = some$2 var helperCreateIterateHandle$2 = helperCreateIterateHandle_1 var every$2 = helperCreateIterateHandle$2('every', 1, 1, false, true) var every_1 = every$2 var hasOwnProp$7 = hasOwnProp_1 function includes$5(obj, val2) { if (obj) { if (obj.includes) { return obj.includes(val2) } for (var key2 in obj) { if (hasOwnProp$7(obj, key2)) { if (val2 === obj[key2]) { return true } } } } return false } var includes_1 = includes$5 var isArray$v = isArray_1$1 var includes$4 = includes_1 function includeArrays$2(array1, array22) { var len2 var index2 = 0 if (isArray$v(array1) && isArray$v(array22)) { for (len2 = array22.length; index2 < len2; index2++) { if (!includes$4(array1, array22[index2])) { return false } } return true } return includes$4(array1, array22) } var includeArrays_1 = includeArrays$2 var each$t = each_1 var includes$3 = includes_1 var isFunction$f = isFunction_1$1 var property$4 = property_1 function uniq$2(array4, iterate2, context2) { var result = [] if (iterate2) { if (!isFunction$f(iterate2)) { iterate2 = property$4(iterate2) } var val2, valMap = {} each$t(array4, function (item2, key2) { val2 = iterate2.call(context2, item2, key2, array4) if (!valMap[val2]) { valMap[val2] = 1 result.push(item2) } }) } else { each$t(array4, function (value2) { if (!includes$3(result, value2)) { result.push(value2) } }) } return result } var uniq_1 = uniq$2 var map$7 = map_1 function toArray$3(list2) { return map$7(list2, function (item2) { return item2 }) } var toArray_1 = toArray$3 var uniq$1 = uniq_1 var toArray$2 = toArray_1 function union$1() { var args = arguments var result = [] var index2 = 0 var len2 = args.length for (; index2 < len2; index2++) { result = result.concat(toArray$2(args[index2])) } return uniq$1(result) } var union_1 = union$1 var staticStrUndefined$b = 'undefined' var staticStrUndefined_1 = staticStrUndefined$b var staticStrUndefined$a = staticStrUndefined_1 var helperCreateInTypeof$4 = helperCreateInTypeof_1 var isUndefined$a = helperCreateInTypeof$4(staticStrUndefined$a) var isUndefined_1 = isUndefined$a var isNull$7 = isNull_1 var isUndefined$9 = isUndefined_1 function eqNull$8(obj) { return isNull$7(obj) || isUndefined$9(obj) } var eqNull_1 = eqNull$8 var staticHGKeyRE$2 = /(.+)?\[(\d+)\]$/ var staticHGKeyRE_1 = staticHGKeyRE$2 function helperGetHGSKeys$3(property2) { return property2 ? property2.splice && property2.join ? property2 : ('' + property2) .replace(/(\[\d+\])\.?/g, '$1.') .replace(/\.$/, '') .split('.') : [] } var helperGetHGSKeys_1 = helperGetHGSKeys$3 var staticHGKeyRE$1 = staticHGKeyRE_1 var helperGetHGSKeys$2 = helperGetHGSKeys_1 var hasOwnProp$6 = hasOwnProp_1 var isUndefined$8 = isUndefined_1 var eqNull$7 = eqNull_1 function get$7(obj, property2, defaultValue) { if (eqNull$7(obj)) { return defaultValue } var result = getValueByPath(obj, property2) return isUndefined$8(result) ? defaultValue : result } function getDeepProps(obj, key2) { var matchs = key2 ? key2.match(staticHGKeyRE$1) : '' return matchs ? matchs[1] ? obj[matchs[1]] ? obj[matchs[1]][matchs[2]] : void 0 : obj[matchs[2]] : obj[key2] } function getValueByPath(obj, property2) { if (obj) { var rest, props2, len2 var index2 = 0 if (obj[property2] || hasOwnProp$6(obj, property2)) { return obj[property2] } else { props2 = helperGetHGSKeys$2(property2) len2 = props2.length if (len2) { for (rest = obj; index2 < len2; index2++) { rest = getDeepProps(rest, props2[index2]) if (eqNull$7(rest)) { if (index2 === len2 - 1) { return rest } return } } } return rest } } } var get_1 = get$7 var arrayEach$b = arrayEach_1 var toArray$1 = toArray_1 var map$6 = map_1 var isArray$u = isArray_1$1 var isFunction$e = isFunction_1$1 var isPlainObject$5 = isPlainObject_1 var isUndefined$7 = isUndefined_1 var isNull$6 = isNull_1 var eqNull$6 = eqNull_1 var get$6 = get_1 var property$3 = property_1 var ORDER_PROP_ASC = 'asc' var ORDER_PROP_DESC = 'desc' function handleSort(v12, v22) { if (isUndefined$7(v12)) { return 1 } if (isNull$6(v12)) { return isUndefined$7(v22) ? -1 : 1 } return v12 && v12.localeCompare ? v12.localeCompare(v22) : v12 > v22 ? 1 : -1 } function buildMultiOrders(name2, confs, compares) { return function (item1, item2) { var v12 = item1[name2] var v22 = item2[name2] if (v12 === v22) { return compares ? compares(item1, item2) : 0 } return confs.order === ORDER_PROP_DESC ? handleSort(v22, v12) : handleSort(v12, v22) } } function getSortConfs(arr, list2, fieldConfs, context2) { var sortConfs = [] fieldConfs = isArray$u(fieldConfs) ? fieldConfs : [fieldConfs] arrayEach$b(fieldConfs, function (handle, index2) { if (handle) { var field2 = handle var order2 if (isArray$u(handle)) { field2 = handle[0] order2 = handle[1] } else if (isPlainObject$5(handle)) { field2 = handle.field order2 = handle.order } sortConfs.push({ field: field2, order: order2 || ORDER_PROP_ASC, }) arrayEach$b( list2, isFunction$e(field2) ? function (item2, key2) { item2[index2] = field2.call(context2, item2.data, key2, arr) } : function (item2) { item2[index2] = field2 ? get$6(item2.data, field2) : item2.data } ) } }) return sortConfs } function orderBy$3(arr, fieldConfs, context2) { if (arr) { if (eqNull$6(fieldConfs)) { return toArray$1(arr).sort(handleSort) } var compares var list2 = map$6(arr, function (item2) { return { data: item2 } }) var sortConfs = getSortConfs(arr, list2, fieldConfs, context2) var len2 = sortConfs.length - 1 while (len2 >= 0) { compares = buildMultiOrders(len2, sortConfs[len2], compares) len2-- } if (compares) { list2 = list2.sort(compares) } return map$6(list2, property$3('data')) } return [] } var orderBy_1 = orderBy$3 var orderBy$2 = orderBy_1 var sortBy$1 = orderBy$2 var sortBy_1 = sortBy$1 function random$3(minVal, maxVal) { return minVal >= maxVal ? minVal : (minVal = minVal >> 0) + Math.round(Math.random() * ((maxVal || 9) - minVal)) } var random_1 = random$3 var helperCreateGetObjects$1 = helperCreateGetObjects_1 var values$7 = helperCreateGetObjects$1('values', 0) var values_1 = values$7 var random$2 = random_1 var values$6 = values_1 function shuffle$2(array4) { var index2 var result = [] var list2 = values$6(array4) var len2 = list2.length - 1 for (; len2 >= 0; len2--) { index2 = len2 > 0 ? random$2(0, len2) : 0 result.push(list2[index2]) list2.splice(index2, 1) } return result } var shuffle_1 = shuffle$2 var shuffle$1 = shuffle_1 function sample$1(array4, number4) { var result = shuffle$1(array4) if (arguments.length <= 1) { return result[0] } if (number4 < result.length) { result.length = number4 || 0 } return result } var sample_1 = sample$1 function helperCreateToNumber$2(handle) { return function (str) { if (str) { var num2 = handle(str && str.replace ? str.replace(/,/g, '') : str) if (!isNaN(num2)) { return num2 } } return 0 } } var helperCreateToNumber_1 = helperCreateToNumber$2 var helperCreateToNumber$1 = helperCreateToNumber_1 var toNumber$7 = helperCreateToNumber$1(parseFloat) var toNumber_1 = toNumber$7 var toNumber$6 = toNumber_1 function slice$9(array4, startIndex, endIndex) { var result = [] var argsSize = arguments.length if (array4) { startIndex = argsSize >= 2 ? toNumber$6(startIndex) : 0 endIndex = argsSize >= 3 ? toNumber$6(endIndex) : array4.length if (array4.slice) { return array4.slice(startIndex, endIndex) } for (; startIndex < endIndex; startIndex++) { result.push(array4[startIndex]) } } return result } var slice_1 = slice$9 var each$s = each_1 function filter$2(obj, iterate2, context2) { var result = [] if (obj && iterate2) { if (obj.filter) { return obj.filter(iterate2, context2) } each$s(obj, function (val2, key2) { if (iterate2.call(context2, val2, key2, obj)) { result.push(val2) } }) } return result } var filter_1 = filter$2 var helperCreateIterateHandle$1 = helperCreateIterateHandle_1 var findKey$1 = helperCreateIterateHandle$1('', 0, 2, true) var findKey_1 = findKey$1 var helperCreateIterateHandle = helperCreateIterateHandle_1 var find$3 = helperCreateIterateHandle('find', 1, 3, true) var find_1 = find$3 var isArray$t = isArray_1$1 var values$5 = values_1 function findLast$1(obj, iterate2, context2) { if (obj) { if (!isArray$t(obj)) { obj = values$5(obj) } for (var len2 = obj.length - 1; len2 >= 0; len2--) { if (iterate2.call(context2, obj[len2], len2, obj)) { return obj[len2] } } } } var findLast_1 = findLast$1 var keys$d = keys_1$1 function reduce$2(array4, callback, initialValue) { if (array4) { var len2, reduceMethod var index2 = 0 var context2 = null var previous = initialValue var isInitialVal = arguments.length > 2 var keyList = keys$d(array4) if (array4.length && array4.reduce) { reduceMethod = function () { return callback.apply(context2, arguments) } if (isInitialVal) { return array4.reduce(reduceMethod, previous) } return array4.reduce(reduceMethod) } if (isInitialVal) { index2 = 1 previous = array4[keyList[0]] } for (len2 = keyList.length; index2 < len2; index2++) { previous = callback.call( context2, previous, array4[keyList[index2]], index2, array4 ) } return previous } } var reduce_1 = reduce$2 var isArray$s = isArray_1$1 function copyWithin$1(array4, target2, start2, end2) { if (isArray$s(array4) && array4.copyWithin) { return array4.copyWithin(target2, start2, end2) } var replaceIndex, replaceArray var targetIndex = target2 >> 0 var startIndex = start2 >> 0 var len2 = array4.length var endIndex = arguments.length > 3 ? end2 >> 0 : len2 if (targetIndex < len2) { targetIndex = targetIndex >= 0 ? targetIndex : len2 + targetIndex if (targetIndex >= 0) { startIndex = startIndex >= 0 ? startIndex : len2 + startIndex endIndex = endIndex >= 0 ? endIndex : len2 + endIndex if (startIndex < endIndex) { for ( replaceIndex = 0, replaceArray = array4.slice(startIndex, endIndex); targetIndex < len2; targetIndex++ ) { if (replaceArray.length <= replaceIndex) { break } array4[targetIndex] = replaceArray[replaceIndex++] } } } } return array4 } var copyWithin_1 = copyWithin$1 var isArray$r = isArray_1$1 function chunk$1(array4, size) { var index2 var result = [] var arrLen = size >> 0 || 1 if (isArray$r(array4)) { if (arrLen >= 0 && array4.length > arrLen) { index2 = 0 while (index2 < array4.length) { result.push(array4.slice(index2, index2 + arrLen)) index2 += arrLen } } else { result = array4.length ? [array4] : array4 } } return result } var chunk_1 = chunk$1 var map$5 = map_1 var property$2 = property_1 function pluck$2(obj, key2) { return map$5(obj, property$2(key2)) } var pluck_1 = pluck$2 var isFunction$d = isFunction_1$1 var eqNull$5 = eqNull_1 var get$5 = get_1 var arrayEach$a = arrayEach_1 function helperCreateMinMax$2(handle) { return function (arr, iterate2) { if (arr && arr.length) { var rest, itemIndex arrayEach$a(arr, function (itemVal, index2) { if (iterate2) { itemVal = isFunction$d(iterate2) ? iterate2(itemVal, index2, arr) : get$5(itemVal, iterate2) } if (!eqNull$5(itemVal) && (eqNull$5(rest) || handle(rest, itemVal))) { itemIndex = index2 rest = itemVal } }) return arr[itemIndex] } return rest } } var helperCreateMinMax_1 = helperCreateMinMax$2 var helperCreateMinMax$1 = helperCreateMinMax_1 var max$8 = helperCreateMinMax$1(function (rest, itemVal) { return rest < itemVal }) var max_1 = max$8 var pluck$1 = pluck_1 var max$7 = max_1 function unzip$2(arrays) { var index2, maxItem, len2 var result = [] if (arrays && arrays.length) { index2 = 0 maxItem = max$7(arrays, function (item2) { return item2 ? item2.length : 0 }) for (len2 = maxItem ? maxItem.length : 0; index2 < len2; index2++) { result.push(pluck$1(arrays, index2)) } } return result } var unzip_1 = unzip$2 var unzip$1 = unzip_1 function zip$1() { return unzip$1(arguments) } var zip_1 = zip$1 var values$4 = values_1 var each$r = each_1 function zipObject$1(props2, arr) { var result = {} arr = arr || [] each$r(values$4(props2), function (val2, key2) { result[val2] = arr[key2] }) return result } var zipObject_1 = zipObject$1 var isArray$q = isArray_1$1 var arrayEach$9 = arrayEach_1 function flattenDeep(array4, deep) { var result = [] arrayEach$9(array4, function (vals) { result = result.concat( isArray$q(vals) ? (deep ? flattenDeep(vals, deep) : vals) : [vals] ) }) return result } function flatten$1(array4, deep) { if (isArray$q(array4)) { return flattenDeep(array4, deep) } return [] } var flatten_1 = flatten$1 var map$4 = map_1 var isArray$p = isArray_1$1 function deepGetObj(obj, path) { var index2 = 0 var len2 = path.length while (obj && index2 < len2) { obj = obj[path[index2++]] } return len2 && obj ? obj : 0 } function invoke$1(list2, path) { var func var args = arguments var params2 = [] var paths = [] var index2 = 2 var len2 = args.length for (; index2 < len2; index2++) { params2.push(args[index2]) } if (isArray$p(path)) { len2 = path.length - 1 for (index2 = 0; index2 < len2; index2++) { paths.push(path[index2]) } path = path[len2] } return map$4(list2, function (context2) { if (paths.length) { context2 = deepGetObj(context2, paths) } func = context2[path] || path if (func && func.apply) { return func.apply(context2, params2) } }) } var invoke_1 = invoke$1 function helperDeleteProperty$2(obj, property2) { try { delete obj[property2] } catch (e2) { obj[property2] = void 0 } } var helperDeleteProperty_1 = helperDeleteProperty$2 var isArray$o = isArray_1$1 var lastArrayEach$1 = lastArrayEach_1 var lastObjectEach$1 = lastObjectEach_1 function lastEach$2(obj, iterate2, context2) { if (obj) { return (isArray$o(obj) ? lastArrayEach$1 : lastObjectEach$1)( obj, iterate2, context2 ) } return obj } var lastEach_1 = lastEach$2 var helperCreateInTypeof$3 = helperCreateInTypeof_1 var isObject$q = helperCreateInTypeof$3('object') var isObject_1$1 = isObject$q var helperDeleteProperty$1 = helperDeleteProperty_1 var isPlainObject$4 = isPlainObject_1 var isObject$p = isObject_1$1 var isArray$n = isArray_1$1 var isNull$5 = isNull_1 var assign$b = assign_1 var objectEach$2 = objectEach_1 function clear$5(obj, defs, assigns) { if (obj) { var len2 var isDefs = arguments.length > 1 && (isNull$5(defs) || !isObject$p(defs)) var extds = isDefs ? assigns : defs if (isPlainObject$4(obj)) { objectEach$2( obj, isDefs ? function (val2, key2) { obj[key2] = defs } : function (val2, key2) { helperDeleteProperty$1(obj, key2) } ) if (extds) { assign$b(obj, extds) } } else if (isArray$n(obj)) { if (isDefs) { len2 = obj.length while (len2 > 0) { len2-- obj[len2] = defs } } else { obj.length = 0 } if (extds) { obj.push.apply(obj, extds) } } } return obj } var clear_1 = clear$5 var helperDeleteProperty = helperDeleteProperty_1 var isFunction$c = isFunction_1$1 var isArray$m = isArray_1$1 var each$q = each_1 var arrayEach$8 = arrayEach_1 var lastEach$1 = lastEach_1 var clear$4 = clear_1 var eqNull$4 = eqNull_1 function pluckProperty(name2) { return function (obj, key2) { return key2 === name2 } } function remove$2(obj, iterate2, context2) { if (obj) { if (!eqNull$4(iterate2)) { var removeKeys = [] var rest = [] if (!isFunction$c(iterate2)) { iterate2 = pluckProperty(iterate2) } each$q(obj, function (item2, index2, rest2) { if (iterate2.call(context2, item2, index2, rest2)) { removeKeys.push(index2) } }) if (isArray$m(obj)) { lastEach$1(removeKeys, function (item2, key2) { rest.push(obj[item2]) obj.splice(item2, 1) }) } else { rest = {} arrayEach$8(removeKeys, function (key2) { rest[key2] = obj[key2] helperDeleteProperty(obj, key2) }) } return rest } return clear$4(obj) } return obj } var remove_1 = remove$2 var setupDefaults$7 = setupDefaults_1 var orderBy$1 = orderBy_1 var clone$8 = clone_1 var eqNull$3 = eqNull_1 var each$p = each_1 var remove$1 = remove_1 var assign$a = assign_1 function strictTree(array4, optChildren) { each$p(array4, function (item2) { if (item2[optChildren] && !item2[optChildren].length) { remove$1(item2, optChildren) } }) } function toArrayTree$1(array4, options2) { var opts = assign$a({}, setupDefaults$7.treeOptions, options2) var optStrict = opts.strict var optKey = opts.key var optParentKey = opts.parentKey var optChildren = opts.children var optMapChildren = opts.mapChildren var optSortKey = opts.sortKey var optReverse = opts.reverse var optData = opts.data var result = [] var treeMap = {} var idsMap = {} var id2, treeData, parentId if (optSortKey) { array4 = orderBy$1(clone$8(array4), optSortKey) if (optReverse) { array4 = array4.reverse() } } each$p(array4, function (item2) { id2 = item2[optKey] idsMap[id2] = true }) each$p(array4, function (item2) { id2 = item2[optKey] if (optData) { treeData = {} treeData[optData] = item2 } else { treeData = item2 } parentId = item2[optParentKey] treeMap[id2] = treeMap[id2] || [] treeMap[parentId] = treeMap[parentId] || [] treeMap[parentId].push(treeData) treeData[optKey] = id2 treeData[optParentKey] = parentId treeData[optChildren] = treeMap[id2] if (optMapChildren) { treeData[optMapChildren] = treeMap[id2] } if (!optStrict || (optStrict && eqNull$3(parentId))) { if (!idsMap[parentId]) { result.push(treeData) } } }) if (optStrict) { strictTree(array4, optChildren) } return result } var toArrayTree_1 = toArrayTree$1 var setupDefaults$6 = setupDefaults_1 var each$o = each_1 var assign$9 = assign_1 function unTreeList(result, array4, opts) { var optChildren = opts.children var optData = opts.data var optClear = opts.clear each$o(array4, function (item2) { var children = item2[optChildren] if (optData) { item2 = item2[optData] } result.push(item2) if (children && children.length) { unTreeList(result, children, opts) } if (optClear) { delete item2[optChildren] } }) return result } function toTreeArray$1(array4, options2) { return unTreeList( [], array4, assign$9({}, setupDefaults$6.treeOptions, options2) ) } var toTreeArray_1 = toTreeArray$1 function helperCreateTreeFunc$4(handle) { return function (obj, iterate2, options2, context2) { var opts = options2 || {} var optChildren = opts.children || 'children' return handle(null, obj, iterate2, context2, [], [], optChildren, opts) } } var helperCreateTreeFunc_1 = helperCreateTreeFunc$4 var helperCreateTreeFunc$3 = helperCreateTreeFunc_1 function findTreeItem( parent2, obj, iterate2, context2, path, node2, parseChildren, opts ) { if (obj) { var item2, index2, len2, paths, nodes, match2 for (index2 = 0, len2 = obj.length; index2 < len2; index2++) { item2 = obj[index2] paths = path.concat(['' + index2]) nodes = node2.concat([item2]) if (iterate2.call(context2, item2, index2, obj, paths, parent2, nodes)) { return { index: index2, item: item2, path: paths, items: obj, parent: parent2, nodes, } } if (parseChildren && item2) { match2 = findTreeItem( item2, item2[parseChildren], iterate2, context2, paths.concat([parseChildren]), nodes, parseChildren ) if (match2) { return match2 } } } } } var findTree$1 = helperCreateTreeFunc$3(findTreeItem) var findTree_1 = findTree$1 var helperCreateTreeFunc$2 = helperCreateTreeFunc_1 var each$n = each_1 function eachTreeItem( parent2, obj, iterate2, context2, path, node2, parseChildren, opts ) { var paths, nodes each$n(obj, function (item2, index2) { paths = path.concat(['' + index2]) nodes = node2.concat([item2]) iterate2.call(context2, item2, index2, obj, paths, parent2, nodes) if (item2 && parseChildren) { paths.push(parseChildren) eachTreeItem( item2, item2[parseChildren], iterate2, context2, paths, nodes, parseChildren ) } }) } var eachTree$2 = helperCreateTreeFunc$2(eachTreeItem) var eachTree_1 = eachTree$2 var helperCreateTreeFunc$1 = helperCreateTreeFunc_1 var map$3 = map_1 function mapTreeItem( parent2, obj, iterate2, context2, path, node2, parseChildren, opts ) { var paths, nodes, rest var mapChildren = opts.mapChildren || parseChildren return map$3(obj, function (item2, index2) { paths = path.concat(['' + index2]) nodes = node2.concat([item2]) rest = iterate2.call(context2, item2, index2, obj, paths, parent2, nodes) if (rest && item2 && parseChildren && item2[parseChildren]) { rest[mapChildren] = mapTreeItem( item2, item2[parseChildren], iterate2, context2, paths, nodes, parseChildren, opts ) } return rest }) } var mapTree$1 = helperCreateTreeFunc$1(mapTreeItem) var mapTree_1 = mapTree$1 var eachTree$1 = eachTree_1 function filterTree$1(obj, iterate2, options2, context2) { var result = [] if (obj && iterate2) { eachTree$1( obj, function (item2, index2, items, path, parent2, nodes) { if ( iterate2.call(context2, item2, index2, items, path, parent2, nodes) ) { result.push(item2) } }, options2 ) } return result } var filterTree_1 = filterTree$1 var helperCreateTreeFunc = helperCreateTreeFunc_1 var arrayEach$7 = arrayEach_1 var assign$8 = assign_1 function searchTreeItem( parentAllow, parent2, obj, iterate2, context2, path, node2, parseChildren, opts ) { var paths, nodes, rest, isAllow, hasChild2 var rests = [] var hasOriginal = opts.original var sourceData = opts.data var mapChildren = opts.mapChildren || parseChildren arrayEach$7(obj, function (item2, index2) { paths = path.concat(['' + index2]) nodes = node2.concat([item2]) isAllow = parentAllow || iterate2.call(context2, item2, index2, obj, paths, parent2, nodes) hasChild2 = parseChildren && item2[parseChildren] if (isAllow || hasChild2) { if (hasOriginal) { rest = item2 } else { rest = assign$8({}, item2) if (sourceData) { rest[sourceData] = item2 } } rest[mapChildren] = searchTreeItem( isAllow, item2, item2[parseChildren], iterate2, context2, paths, nodes, parseChildren, opts ) if (isAllow || rest[mapChildren].length) { rests.push(rest) } } else if (isAllow) { rests.push(rest) } }) return rests } var searchTree$1 = helperCreateTreeFunc(function ( parent2, obj, iterate2, context2, path, nodes, parseChildren, opts ) { return searchTreeItem( 0, parent2, obj, iterate2, context2, path, nodes, parseChildren, opts ) }) var searchTree_1 = searchTree$1 function arrayIndexOf$2(list2, val2) { if (list2.indexOf) { return list2.indexOf(val2) } for (var index2 = 0, len2 = list2.length; index2 < len2; index2++) { if (val2 === list2[index2]) { return index2 } } } var arrayIndexOf_1 = arrayIndexOf$2 function arrayLastIndexOf$2(list2, val2) { if (list2.lastIndexOf) { return list2.lastIndexOf(val2) } for (var len2 = list2.length - 1; len2 >= 0; len2--) { if (val2 === list2[len2]) { return len2 } } return -1 } var arrayLastIndexOf_1 = arrayLastIndexOf$2 var helperCreateInTypeof$2 = helperCreateInTypeof_1 var isNumber$d = helperCreateInTypeof$2('number') var isNumber_1 = isNumber$d var isNumber$c = isNumber_1 function isNumberNaN$1(obj) { return isNumber$c(obj) && isNaN(obj) } var _isNaN = isNumberNaN$1 var helperCreateInTypeof$1 = helperCreateInTypeof_1 var isString$c = helperCreateInTypeof$1('string') var isString_1 = isString$c var helperCreateInInObjectString$3 = helperCreateInInObjectString_1 var isDate$9 = helperCreateInInObjectString$3('Date') var isDate_1 = isDate$9 var staticParseInt$5 = parseInt var staticParseInt_1 = staticParseInt$5 function helperGetUTCDateTime$1(resMaps) { return Date.UTC( resMaps.y, resMaps.M || 0, resMaps.d || 1, resMaps.H || 0, resMaps.m || 0, resMaps.s || 0, resMaps.S || 0 ) } var helperGetUTCDateTime_1 = helperGetUTCDateTime$1 function helperGetDateTime$c(date4) { return date4.getTime() } var helperGetDateTime_1 = helperGetDateTime$c var staticParseInt$4 = staticParseInt_1 var helperGetUTCDateTime = helperGetUTCDateTime_1 var helperGetDateTime$b = helperGetDateTime_1 var isString$b = isString_1 var isDate$8 = isDate_1 function getParseRule(txt) { return '(\\d{' + txt + '})' } function toParseMs(num2) { if (num2 < 10) { return num2 * 100 } else if (num2 < 100) { return num2 * 10 } return num2 } function toParseNum(num2) { return isNaN(num2) ? num2 : staticParseInt$4(num2) } var d2 = getParseRule(2) var d1or2 = getParseRule('1,2') var d1or7 = getParseRule('1,7') var d3or4 = getParseRule('3,4') var place = '.{1}' var d1Or2RE = place + d1or2 var dzZ = '(([zZ])|([-+]\\d{2}:?\\d{2}))' var defaulParseStrs = [ d3or4, d1Or2RE, d1Or2RE, d1Or2RE, d1Or2RE, d1Or2RE, place + d1or7, dzZ, ] var defaulParseREs = [] for (var len$1 = defaulParseStrs.length - 1; len$1 >= 0; len$1--) { var rule = '' for (var i$3 = 0; i$3 < len$1 + 1; i$3++) { rule += defaulParseStrs[i$3] } defaulParseREs.push(new RegExp('^' + rule + '$')) } function parseDefaultRules(str) { var matchRest, resMaps = {} for (var i2 = 0, dfrLen = defaulParseREs.length; i2 < dfrLen; i2++) { matchRest = str.match(defaulParseREs[i2]) if (matchRest) { resMaps.y = matchRest[1] resMaps.M = matchRest[2] resMaps.d = matchRest[3] resMaps.H = matchRest[4] resMaps.m = matchRest[5] resMaps.s = matchRest[6] resMaps.S = matchRest[7] resMaps.Z = matchRest[8] break } } return resMaps } var customParseStrs = [ ['yyyy', d3or4], ['yy', d2], ['MM', d2], ['M', d1or2], ['dd', d2], ['d', d1or2], ['HH', d2], ['H', d1or2], ['mm', d2], ['m', d1or2], ['ss', d2], ['s', d1or2], ['SSS', getParseRule(3)], ['S', d1or7], ['Z', dzZ], ] var parseRuleMaps = {} var parseRuleKeys = ['\\[([^\\]]+)\\]'] for (var i$3 = 0; i$3 < customParseStrs.length; i$3++) { var itemRule = customParseStrs[i$3] parseRuleMaps[itemRule[0]] = itemRule[1] + '?' parseRuleKeys.push(itemRule[0]) } var customParseRes = new RegExp(parseRuleKeys.join('|'), 'g') var cacheFormatMaps = {} function parseCustomRules(str, format2) { var cacheItem = cacheFormatMaps[format2] if (!cacheItem) { var posIndexs = [] var re2 = format2 .replace(/([$(){}*+.?\\^|])/g, '\\$1') .replace(customParseRes, function (text2, val2) { var firstChar = text2.charAt(0) if (firstChar === '[') { return val2 } posIndexs.push(firstChar) return parseRuleMaps[text2] }) cacheItem = cacheFormatMaps[format2] = { _i: posIndexs, _r: new RegExp(re2), } } var resMaps = {} var matchRest = str.match(cacheItem._r) if (matchRest) { var _i = cacheItem._i for (var i2 = 1, len2 = matchRest.length; i2 < len2; i2++) { resMaps[_i[i2 - 1]] = matchRest[i2] } return resMaps } return resMaps } function parseTimeZone(resMaps) { if (/^[zZ]/.test(resMaps.Z)) { return new Date(helperGetUTCDateTime(resMaps)) } else { var matchRest = resMaps.Z.match(/([-+])(\d{2}):?(\d{2})/) if (matchRest) { return new Date( helperGetUTCDateTime(resMaps) - (matchRest[1] === '-' ? -1 : 1) * staticParseInt$4(matchRest[2]) * 36e5 + staticParseInt$4(matchRest[3]) * 6e4 ) } } return new Date('') } function toStringDate$d(str, format2) { if (str) { var isDType = isDate$8(str) if (isDType || (!format2 && /^[0-9]{11,15}$/.test(str))) { return new Date( isDType ? helperGetDateTime$b(str) : staticParseInt$4(str) ) } if (isString$b(str)) { var resMaps = format2 ? parseCustomRules(str, format2) : parseDefaultRules(str) if (resMaps.y) { if (resMaps.M) { resMaps.M = toParseNum(resMaps.M) - 1 } if (resMaps.S) { resMaps.S = toParseMs(toParseNum(resMaps.S.substring(0, 3))) } if (resMaps.Z) { return parseTimeZone(resMaps) } else { return new Date( resMaps.y, resMaps.M || 0, resMaps.d || 1, resMaps.H || 0, resMaps.m || 0, resMaps.s || 0, resMaps.S || 0 ) } } } } return new Date('') } var toStringDate_1 = toStringDate$d function helperNewDate$4() { return new Date() } var helperNewDate_1 = helperNewDate$4 var isDate$7 = isDate_1 var toStringDate$c = toStringDate_1 var helperNewDate$3 = helperNewDate_1 function isLeapYear$2(date4) { var year var currentDate = date4 ? toStringDate$c(date4) : helperNewDate$3() if (isDate$7(currentDate)) { year = currentDate.getFullYear() return year % 4 === 0 && (year % 100 !== 0 || year % 400 === 0) } return false } var isLeapYear_1 = isLeapYear$2 var isArray$l = isArray_1$1 var hasOwnProp$5 = hasOwnProp_1 function forOf$1(obj, iterate2, context2) { if (obj) { if (isArray$l(obj)) { for (var index2 = 0, len2 = obj.length; index2 < len2; index2++) { if (iterate2.call(context2, obj[index2], index2, obj) === false) { break } } } else { for (var key2 in obj) { if (hasOwnProp$5(obj, key2)) { if (iterate2.call(context2, obj[key2], key2, obj) === false) { break } } } } } } var forOf_1 = forOf$1 var isArray$k = isArray_1$1 var keys$c = hasOwnProp_1 function lastForOf$1(obj, iterate2, context2) { if (obj) { var len2, list2 if (isArray$k(obj)) { for (len2 = obj.length - 1; len2 >= 0; len2--) { if (iterate2.call(context2, obj[len2], len2, obj) === false) { break } } } else { list2 = keys$c(obj) for (len2 = list2.length - 1; len2 >= 0; len2--) { if ( iterate2.call(context2, obj[list2[len2]], list2[len2], obj) === false ) { break } } } } } var lastForOf_1 = lastForOf$1 var isArray$j = isArray_1$1 var isString$a = isString_1 var hasOwnProp$4 = hasOwnProp_1 function helperCreateIndexOf$2(name2, callback) { return function (obj, val2) { if (obj) { if (obj[name2]) { return obj[name2](val2) } if (isString$a(obj) || isArray$j(obj)) { return callback(obj, val2) } for (var key2 in obj) { if (hasOwnProp$4(obj, key2)) { if (val2 === obj[key2]) { return key2 } } } } return -1 } } var helperCreateIndexOf_1 = helperCreateIndexOf$2 var helperCreateIndexOf$1 = helperCreateIndexOf_1 var arrayIndexOf$1 = arrayIndexOf_1 var indexOf$4 = helperCreateIndexOf$1('indexOf', arrayIndexOf$1) var indexOf_1 = indexOf$4 var helperCreateIndexOf = helperCreateIndexOf_1 var arrayLastIndexOf$1 = arrayLastIndexOf_1 var lastIndexOf$2 = helperCreateIndexOf('lastIndexOf', arrayLastIndexOf$1) var lastIndexOf_1 = lastIndexOf$2 var isArray$i = isArray_1$1 var isString$9 = isString_1 var each$m = each_1 function getSize$4(obj) { var len2 = 0 if (isString$9(obj) || isArray$i(obj)) { return obj.length } each$m(obj, function () { len2++ }) return len2 } var getSize_1 = getSize$4 var isNumber$b = isNumber_1 function isNumberFinite$1(obj) { return isNumber$b(obj) && isFinite(obj) } var _isFinite = isNumberFinite$1 var isArray$h = isArray_1$1 var isNull$4 = isNull_1 var isInteger$2 = function (obj) { return !isNull$4(obj) && !isNaN(obj) && !isArray$h(obj) && obj % 1 === 0 } var isInteger_1 = isInteger$2 var isArray$g = isArray_1$1 var isInteger$1 = isInteger_1 var isNull$3 = isNull_1 function isFloat$1(obj) { return !isNull$3(obj) && !isNaN(obj) && !isArray$g(obj) && !isInteger$1(obj) } var isFloat_1 = isFloat$1 var helperCreateInTypeof = helperCreateInTypeof_1 var isBoolean$3 = helperCreateInTypeof('boolean') var isBoolean_1 = isBoolean$3 var helperCreateInInObjectString$2 = helperCreateInInObjectString_1 var isRegExp$7 = helperCreateInInObjectString$2('RegExp') var isRegExp_1 = isRegExp$7 var helperCreateInInObjectString$1 = helperCreateInInObjectString_1 var isError$2 = helperCreateInInObjectString$1('Error') var isError_1 = isError$2 function isTypeError$1(obj) { return obj ? obj.constructor === TypeError : false } var isTypeError_1 = isTypeError$1 function isEmpty$2(obj) { for (var key2 in obj) { return false } return true } var isEmpty_1 = isEmpty$2 var staticStrUndefined$9 = staticStrUndefined_1 var supportSymbol = typeof Symbol !== staticStrUndefined$9 function isSymbol$5(obj) { return supportSymbol && Symbol.isSymbol ? Symbol.isSymbol(obj) : typeof obj === 'symbol' } var isSymbol_1 = isSymbol$5 var helperCreateInInObjectString = helperCreateInInObjectString_1 var isArguments$3 = helperCreateInInObjectString('Arguments') var isArguments_1$1 = isArguments$3 var isString$8 = isString_1 var isNumber$a = isNumber_1 function isElement$1(obj) { return !!(obj && isString$8(obj.nodeName) && isNumber$a(obj.nodeType)) } var isElement_1 = isElement$1 var staticStrUndefined$8 = staticStrUndefined_1 var staticDocument$3 = typeof document === staticStrUndefined$8 ? 0 : document var staticDocument_1 = staticDocument$3 var staticDocument$2 = staticDocument_1 function isDocument$1(obj) { return !!(obj && staticDocument$2 && obj.nodeType === 9) } var isDocument_1 = isDocument$1 var staticStrUndefined$7 = staticStrUndefined_1 var staticWindow$2 = typeof window === staticStrUndefined$7 ? 0 : window var staticWindow_1 = staticWindow$2 var staticWindow$1 = staticWindow_1 function isWindow$1(obj) { return staticWindow$1 && !!(obj && obj === obj.window) } var isWindow_1 = isWindow$1 var staticStrUndefined$6 = staticStrUndefined_1 var supportFormData = typeof FormData !== staticStrUndefined$6 function isFormData$1(obj) { return supportFormData && obj instanceof FormData } var isFormData_1 = isFormData$1 var staticStrUndefined$5 = staticStrUndefined_1 var supportMap = typeof Map !== staticStrUndefined$5 function isMap$3(obj) { return supportMap && obj instanceof Map } var isMap_1$1 = isMap$3 var staticStrUndefined$4 = staticStrUndefined_1 var supportWeakMap = typeof WeakMap !== staticStrUndefined$4 function isWeakMap$1(obj) { return supportWeakMap && obj instanceof WeakMap } var isWeakMap_1 = isWeakMap$1 var staticStrUndefined$3 = staticStrUndefined_1 var supportSet = typeof Set !== staticStrUndefined$3 function isSet$3(obj) { return supportSet && obj instanceof Set } var isSet_1$1 = isSet$3 var staticStrUndefined$2 = staticStrUndefined_1 var supportWeakSet = typeof WeakSet !== staticStrUndefined$2 function isWeakSet$1(obj) { return supportWeakSet && obj instanceof WeakSet } var isWeakSet_1 = isWeakSet$1 var isFunction$b = isFunction_1$1 var isString$7 = isString_1 var isArray$f = isArray_1$1 var hasOwnProp$3 = hasOwnProp_1 function helperCreateiterateIndexOf$2(callback) { return function (obj, iterate2, context2) { if (obj && isFunction$b(iterate2)) { if (isArray$f(obj) || isString$7(obj)) { return callback(obj, iterate2, context2) } for (var key2 in obj) { if (hasOwnProp$3(obj, key2)) { if (iterate2.call(context2, obj[key2], key2, obj)) { return key2 } } } } return -1 } } var helperCreateiterateIndexOf_1 = helperCreateiterateIndexOf$2 var helperCreateiterateIndexOf$1 = helperCreateiterateIndexOf_1 var findIndexOf$3 = helperCreateiterateIndexOf$1(function ( obj, iterate2, context2 ) { for (var index2 = 0, len2 = obj.length; index2 < len2; index2++) { if (iterate2.call(context2, obj[index2], index2, obj)) { return index2 } } return -1 }) var findIndexOf_1 = findIndexOf$3 var isNumber$9 = isNumber_1 var isArray$e = isArray_1$1 var isString$6 = isString_1 var isRegExp$6 = isRegExp_1 var isDate$6 = isDate_1 var isBoolean$2 = isBoolean_1 var isUndefined$6 = isUndefined_1 var keys$b = keys_1$1 var every$1 = every_1 function helperEqualCompare$2(val1, val2, compare2, func, key2, obj1, obj2) { if (val1 === val2) { return true } if ( val1 && val2 && !isNumber$9(val1) && !isNumber$9(val2) && !isString$6(val1) && !isString$6(val2) ) { if (isRegExp$6(val1)) { return compare2('' + val1, '' + val2, key2, obj1, obj2) } if (isDate$6(val1) || isBoolean$2(val1)) { return compare2(+val1, +val2, key2, obj1, obj2) } else { var result, val1Keys, val2Keys var isObj1Arr = isArray$e(val1) var isObj2Arr = isArray$e(val2) if ( isObj1Arr || isObj2Arr ? isObj1Arr && isObj2Arr : val1.constructor === val2.constructor ) { val1Keys = keys$b(val1) val2Keys = keys$b(val2) if (func) { result = func(val1, val2, key2) } if (val1Keys.length === val2Keys.length) { return isUndefined$6(result) ? every$1(val1Keys, function (key3, index2) { return ( key3 === val2Keys[index2] && helperEqualCompare$2( val1[key3], val2[val2Keys[index2]], compare2, func, isObj1Arr || isObj2Arr ? index2 : key3, val1, val2 ) ) }) : !!result } return false } } } return compare2(val1, val2, key2, obj1, obj2) } var helperEqualCompare_1 = helperEqualCompare$2 function helperDefaultCompare$2(v12, v22) { return v12 === v22 } var helperDefaultCompare_1 = helperDefaultCompare$2 var helperEqualCompare$1 = helperEqualCompare_1 var helperDefaultCompare$1 = helperDefaultCompare_1 function isEqual$2(obj1, obj2) { return helperEqualCompare$1(obj1, obj2, helperDefaultCompare$1) } var isEqual_1 = isEqual$2 var keys$a = keys_1$1 var findIndexOf$2 = findIndexOf_1 var isEqual$1 = isEqual_1 var some$1 = some_1 var includeArrays$1 = includeArrays_1 function isMatch$1(obj, source2) { var objKeys = keys$a(obj) var sourceKeys = keys$a(source2) if (sourceKeys.length) { if (includeArrays$1(objKeys, sourceKeys)) { return some$1(sourceKeys, function (key2) { return ( findIndexOf$2(objKeys, function (key1) { return key1 === key2 && isEqual$1(obj[key1], source2[key2]) }) > -1 ) }) } } else { return true } return isEqual$1(obj, source2) } var isMatch_1 = isMatch$1 var helperEqualCompare = helperEqualCompare_1 var helperDefaultCompare = helperDefaultCompare_1 var isFunction$a = isFunction_1$1 var isUndefined$5 = isUndefined_1 function isEqualWith$1(obj1, obj2, func) { if (isFunction$a(func)) { return helperEqualCompare( obj1, obj2, function (v12, v22, key2, obj12, obj22) { var result = func(v12, v22, key2, obj12, obj22) return isUndefined$5(result) ? helperDefaultCompare(v12, v22) : !!result }, func ) } return helperEqualCompare(obj1, obj2, helperDefaultCompare) } var isEqualWith_1 = isEqualWith$1 var isSymbol$4 = isSymbol_1 var isDate$5 = isDate_1 var isArray$d = isArray_1$1 var isRegExp$5 = isRegExp_1 var isError$1 = isError_1 var isNull$2 = isNull_1 function getType$1(obj) { if (isNull$2(obj)) { return 'null' } if (isSymbol$4(obj)) { return 'symbol' } if (isDate$5(obj)) { return 'date' } if (isArray$d(obj)) { return 'array' } if (isRegExp$5(obj)) { return 'regexp' } if (isError$1(obj)) { return 'error' } return typeof obj } var getType_1 = getType$1 var __uniqueId = 0 function uniqueId$1(prefix) { return [prefix, ++__uniqueId].join('') } var uniqueId_1 = uniqueId$1 var helperCreateiterateIndexOf = helperCreateiterateIndexOf_1 var findLastIndexOf$1 = helperCreateiterateIndexOf(function ( obj, iterate2, context2 ) { for (var len2 = obj.length - 1; len2 >= 0; len2--) { if (iterate2.call(context2, obj[len2], len2, obj)) { return len2 } } return -1 }) var findLastIndexOf_1 = findLastIndexOf$1 var isPlainObject$3 = isPlainObject_1 var isString$5 = isString_1 function toStringJSON$1(str) { if (isPlainObject$3(str)) { return str } else if (isString$5(str)) { try { return JSON.parse(str) } catch (e2) {} } return {} } var toStringJSON_1 = toStringJSON$1 var eqNull$2 = eqNull_1 function toJSONString$1(obj) { return eqNull$2(obj) ? '' : JSON.stringify(obj) } var toJSONString_1 = toJSONString$1 var helperCreateGetObjects = helperCreateGetObjects_1 var entries$1 = helperCreateGetObjects('entries', 2) var entries_1 = entries$1 var isFunction$9 = isFunction_1$1 var isArray$c = isArray_1$1 var each$l = each_1 var findIndexOf$1 = findIndexOf_1 function helperCreatePickOmit$2(case1, case2) { return function (obj, callback) { var item2, index2 var rest = {} var result = [] var context2 = this var args = arguments var len2 = args.length if (!isFunction$9(callback)) { for (index2 = 1; index2 < len2; index2++) { item2 = args[index2] result.push.apply(result, isArray$c(item2) ? item2 : [item2]) } callback = 0 } each$l(obj, function (val2, key2) { if ( ( callback ? callback.call(context2, val2, key2, obj) : findIndexOf$1(result, function (name2) { return name2 === key2 }) > -1 ) ? case1 : case2 ) { rest[key2] = val2 } }) return rest } } var helperCreatePickOmit_1 = helperCreatePickOmit$2 var helperCreatePickOmit$1 = helperCreatePickOmit_1 var pick$1 = helperCreatePickOmit$1(1, 0) var pick_1 = pick$1 var helperCreatePickOmit = helperCreatePickOmit_1 var omit$1 = helperCreatePickOmit(0, 1) var omit_1 = omit$1 var values$3 = values_1 function first$1(obj) { return values$3(obj)[0] } var first_1 = first$1 var values$2 = values_1 function last$2(obj) { var list2 = values$2(obj) return list2[list2.length - 1] } var last_1 = last$2 var staticHGKeyRE = staticHGKeyRE_1 var helperGetHGSKeys$1 = helperGetHGSKeys_1 var hasOwnProp$2 = hasOwnProp_1 function has$4(obj, property2) { if (obj) { if (hasOwnProp$2(obj, property2)) { return true } else { var prop, arrIndex, objProp, matchs, rest, isHas var props2 = helperGetHGSKeys$1(property2) var index2 = 0 var len2 = props2.length for (rest = obj; index2 < len2; index2++) { isHas = false prop = props2[index2] matchs = prop ? prop.match(staticHGKeyRE) : '' if (matchs) { arrIndex = matchs[1] objProp = matchs[2] if (arrIndex) { if (rest[arrIndex]) { if (hasOwnProp$2(rest[arrIndex], objProp)) { isHas = true rest = rest[arrIndex][objProp] } } } else { if (hasOwnProp$2(rest, objProp)) { isHas = true rest = rest[objProp] } } } else { if (hasOwnProp$2(rest, prop)) { isHas = true rest = rest[prop] } } if (isHas) { if (index2 === len2 - 1) { return true } } else { break } } } } return false } var has_1 = has$4 var staticParseInt$3 = staticParseInt_1 var helperGetHGSKeys = helperGetHGSKeys_1 var hasOwnProp$1 = hasOwnProp_1 var sKeyRE = /(.+)?\[(\d+)\]$/ function setDeepProps(obj, key2, isEnd, nextKey, value2) { if (obj[key2]) { if (isEnd) { obj[key2] = value2 } } else { var index2 var rest var currMatchs = key2 ? key2.match(sKeyRE) : null if (isEnd) { rest = value2 } else { var nextMatchs = nextKey ? nextKey.match(sKeyRE) : null if (nextMatchs && !nextMatchs[1]) { rest = new Array(staticParseInt$3(nextMatchs[2]) + 1) } else { rest = {} } } if (currMatchs) { if (currMatchs[1]) { index2 = staticParseInt$3(currMatchs[2]) if (obj[currMatchs[1]]) { if (isEnd) { obj[currMatchs[1]][index2] = rest } else { if (obj[currMatchs[1]][index2]) { rest = obj[currMatchs[1]][index2] } else { obj[currMatchs[1]][index2] = rest } } } else { obj[currMatchs[1]] = new Array(index2 + 1) obj[currMatchs[1]][index2] = rest } } else { obj[currMatchs[2]] = rest } } else { obj[key2] = rest } return rest } return obj[key2] } function set$5(obj, property2, value2) { if (obj) { if ( (obj[property2] || hasOwnProp$1(obj, property2)) && !isPrototypePolluted(property2) ) { obj[property2] = value2 } else { var rest = obj var props2 = helperGetHGSKeys(property2) var len2 = props2.length for (var index2 = 0; index2 < len2; index2++) { if (isPrototypePolluted(props2[index2])) { continue } var isEnd = index2 === len2 - 1 rest = setDeepProps( rest, props2[index2], isEnd, isEnd ? null : props2[index2 + 1], value2 ) } } } return obj } function isPrototypePolluted(key2) { return key2 === '__proto__' || key2 === 'constructor' || key2 === 'prototype' } var set_1 = set$5 var isEmpty$1 = isEmpty_1 var isObject$o = isObject_1$1 var isFunction$8 = isFunction_1$1 var property$1 = property_1 var each$k = each_1 function createiterateEmpty(iterate2) { return function () { return isEmpty$1(iterate2) } } function groupBy$2(obj, iterate2, context2) { var groupKey var result = {} if (obj) { if (iterate2 && isObject$o(iterate2)) { iterate2 = createiterateEmpty(iterate2) } else if (!isFunction$8(iterate2)) { iterate2 = property$1(iterate2) } each$k(obj, function (val2, key2) { groupKey = iterate2 ? iterate2.call(context2, val2, key2, obj) : val2 if (result[groupKey]) { result[groupKey].push(val2) } else { result[groupKey] = [val2] } }) } return result } var groupBy_1 = groupBy$2 var groupBy$1 = groupBy_1 var objectEach$1 = objectEach_1 function countBy$1(obj, iterate2, context2) { var result = groupBy$1(obj, iterate2, context2 || this) objectEach$1(result, function (item2, key2) { result[key2] = item2.length }) return result } var countBy_1 = countBy$1 function range$1(start2, stop2, step) { var index2, len2 var result = [] var args = arguments if (args.length < 2) { stop2 = args[0] start2 = 0 } index2 = start2 >> 0 len2 = stop2 >> 0 if (index2 < stop2) { step = step >> 0 || 1 for (; index2 < len2; index2 += step) { result.push(index2) } } return result } var range_1 = range$1 var keys$9 = keys_1$1 var slice$8 = slice_1 var includes$2 = includes_1 var arrayEach$6 = arrayEach_1 var assign$7 = assign_1 function destructuring$1(destination, sources) { if (destination && sources) { var rest = assign$7.apply(this, [{}].concat(slice$8(arguments, 1))) var restKeys = keys$9(rest) arrayEach$6(keys$9(destination), function (key2) { if (includes$2(restKeys, key2)) { destination[key2] = rest[key2] } }) } return destination } var destructuring_1 = destructuring$1 var helperCreateMinMax = helperCreateMinMax_1 var min$9 = helperCreateMinMax(function (rest, itemVal) { return rest > itemVal }) var min_1 = min$9 function helperNumberDecimal$4(numStr) { return (numStr.split('.')[1] || '').length } var helperNumberDecimal_1 = helperNumberDecimal$4 var staticParseInt$2 = staticParseInt_1 function helperStringRepeat$5(str, count2) { if (str.repeat) { return str.repeat(count2) } var list2 = isNaN(count2) ? [] : new Array(staticParseInt$2(count2)) return list2.join(str) + (list2.length > 0 ? str : '') } var helperStringRepeat_1 = helperStringRepeat$5 function helperNumberOffsetPoint$2(str, offsetIndex) { return ( str.substring(0, offsetIndex) + '.' + str.substring(offsetIndex, str.length) ) } var helperNumberOffsetPoint_1 = helperNumberOffsetPoint$2 var helperStringRepeat$4 = helperStringRepeat_1 var helperNumberOffsetPoint$1 = helperNumberOffsetPoint_1 function toNumberString$8(num2) { var rest = '' + num2 var scienceMatchs = rest.match( /^([-+]?)((\d+)|((\d+)?[.](\d+)?))e([-+]{1})([0-9]+)$/ ) if (scienceMatchs) { var isNegative = num2 < 0 var absFlag = isNegative ? '-' : '' var intNumStr = scienceMatchs[3] || '' var dIntNumStr = scienceMatchs[5] || '' var dFloatNumStr = scienceMatchs[6] || '' var sciencFlag = scienceMatchs[7] var scienceNumStr = scienceMatchs[8] var floatOffsetIndex = scienceNumStr - dFloatNumStr.length var intOffsetIndex = scienceNumStr - intNumStr.length var dIntOffsetIndex = scienceNumStr - dIntNumStr.length if (sciencFlag === '+') { if (intNumStr) { return absFlag + intNumStr + helperStringRepeat$4('0', scienceNumStr) } if (floatOffsetIndex > 0) { return ( absFlag + dIntNumStr + dFloatNumStr + helperStringRepeat$4('0', floatOffsetIndex) ) } return ( absFlag + dIntNumStr + helperNumberOffsetPoint$1(dFloatNumStr, scienceNumStr) ) } if (intNumStr) { if (intOffsetIndex > 0) { return ( absFlag + '0.' + helperStringRepeat$4('0', Math.abs(intOffsetIndex)) + intNumStr ) } return absFlag + helperNumberOffsetPoint$1(intNumStr, intOffsetIndex) } if (dIntOffsetIndex > 0) { return ( absFlag + '0.' + helperStringRepeat$4('0', Math.abs(dIntOffsetIndex)) + dIntNumStr + dFloatNumStr ) } return ( absFlag + helperNumberOffsetPoint$1(dIntNumStr, dIntOffsetIndex) + dFloatNumStr ) } return rest } var toNumberString_1 = toNumberString$8 var helperNumberDecimal$3 = helperNumberDecimal_1 var toNumberString$7 = toNumberString_1 function helperMultiply$2(multiplier, multiplicand) { var str1 = toNumberString$7(multiplier) var str2 = toNumberString$7(multiplicand) return ( (parseInt(str1.replace('.', '')) * parseInt(str2.replace('.', ''))) / Math.pow(10, helperNumberDecimal$3(str1) + helperNumberDecimal$3(str2)) ) } var helperMultiply_1 = helperMultiply$2 var helperMultiply$1 = helperMultiply_1 var toNumber$5 = toNumber_1 var toNumberString$6 = toNumberString_1 function helperCreateMathNumber$3(name2) { return function (num2, digits) { var numRest = toNumber$5(num2) var rest = numRest if (numRest) { digits = digits >> 0 var numStr = toNumberString$6(numRest) var nums = numStr.split('.') var intStr = nums[0] var floatStr = nums[1] || '' var fStr = floatStr.substring(0, digits + 1) var subRest = intStr + (fStr ? '.' + fStr : '') if (digits >= floatStr.length) { return toNumber$5(subRest) } subRest = numRest if (digits > 0) { var ratio = Math.pow(10, digits) rest = Math[name2](helperMultiply$1(subRest, ratio)) / ratio } else { rest = Math[name2](subRest) } } return rest } } var helperCreateMathNumber_1 = helperCreateMathNumber$3 var helperCreateMathNumber$2 = helperCreateMathNumber_1 var round$7 = helperCreateMathNumber$2('round') var round_1 = round$7 var helperCreateMathNumber$1 = helperCreateMathNumber_1 var ceil$3 = helperCreateMathNumber$1('ceil') var ceil_1 = ceil$3 var helperCreateMathNumber = helperCreateMathNumber_1 var floor$4 = helperCreateMathNumber('floor') var floor_1 = floor$4 var eqNull$1 = eqNull_1 var isNumber$8 = isNumber_1 var toNumberString$5 = toNumberString_1 function toValueString$e(obj) { if (isNumber$8(obj)) { return toNumberString$5(obj) } return '' + (eqNull$1(obj) ? '' : obj) } var toValueString_1 = toValueString$e var round$6 = round_1 var toValueString$d = toValueString_1 var helperStringRepeat$3 = helperStringRepeat_1 var helperNumberOffsetPoint = helperNumberOffsetPoint_1 function toFixed$3(num2, digits) { digits = digits >> 0 var str = toValueString$d(round$6(num2, digits)) var nums = str.split('.') var intStr = nums[0] var floatStr = nums[1] || '' var digitOffsetIndex = digits - floatStr.length if (digits) { if (digitOffsetIndex > 0) { return ( intStr + '.' + floatStr + helperStringRepeat$3('0', digitOffsetIndex) ) } return ( intStr + helperNumberOffsetPoint(floatStr, Math.abs(digitOffsetIndex)) ) } return intStr } var toFixed_1 = toFixed$3 var setupDefaults$5 = setupDefaults_1 var round$5 = round_1 var ceil$2 = ceil_1 var floor$3 = floor_1 var isNumber$7 = isNumber_1 var toValueString$c = toValueString_1 var toFixed$2 = toFixed_1 var toNumberString$4 = toNumberString_1 var assign$6 = assign_1 function commafy$1(num2, options2) { var opts = assign$6({}, setupDefaults$5.commafyOptions, options2) var optDigits = opts.digits var isNum = isNumber$7(num2) var rest, result, isNegative, intStr, floatStr if (isNum) { rest = (opts.ceil ? ceil$2 : opts.floor ? floor$3 : round$5)( num2, optDigits ) result = toNumberString$4( optDigits ? toFixed$2(rest, optDigits) : rest ).split('.') intStr = result[0] floatStr = result[1] isNegative = intStr && rest < 0 if (isNegative) { intStr = intStr.substring(1, intStr.length) } } else { rest = toValueString$c(num2).replace(/,/g, '') result = rest ? [rest] : [] intStr = result[0] } if (result.length) { return ( (isNegative ? '-' : '') + intStr.replace( new RegExp('(?=(?!(\\b))(.{' + (opts.spaceNumber || 3) + '})+$)', 'g'), opts.separator || ',' ) + (floatStr ? '.' + floatStr : '') ) } return rest } var commafy_1 = commafy$1 var staticParseInt$1 = staticParseInt_1 var helperCreateToNumber = helperCreateToNumber_1 var toInteger$1 = helperCreateToNumber(staticParseInt$1) var toInteger_1 = toInteger$1 var helperMultiply = helperMultiply_1 var toNumber$4 = toNumber_1 function multiply$3(num1, num2) { var multiplier = toNumber$4(num1) var multiplicand = toNumber$4(num2) return helperMultiply(multiplier, multiplicand) } var multiply_1 = multiply$3 var helperNumberDecimal$2 = helperNumberDecimal_1 var toNumberString$3 = toNumberString_1 var multiply$2 = multiply_1 function helperNumberAdd$2(addend, augend) { var str1 = toNumberString$3(addend) var str2 = toNumberString$3(augend) var ratio = Math.pow( 10, Math.max(helperNumberDecimal$2(str1), helperNumberDecimal$2(str2)) ) return (multiply$2(addend, ratio) + multiply$2(augend, ratio)) / ratio } var helperNumberAdd_1 = helperNumberAdd$2 var helperNumberAdd$1 = helperNumberAdd_1 var toNumber$3 = toNumber_1 function add$2(num1, num2) { return helperNumberAdd$1(toNumber$3(num1), toNumber$3(num2)) } var add_1 = add$2 var helperNumberDecimal$1 = helperNumberDecimal_1 var toNumberString$2 = toNumberString_1 var toNumber$2 = toNumber_1 var toFixed$1 = toFixed_1 function subtract$1(num1, num2) { var subtrahend = toNumber$2(num1) var minuend = toNumber$2(num2) var str1 = toNumberString$2(subtrahend) var str2 = toNumberString$2(minuend) var digit1 = helperNumberDecimal$1(str1) var digit2 = helperNumberDecimal$1(str2) var ratio = Math.pow(10, Math.max(digit1, digit2)) var precision = digit1 >= digit2 ? digit1 : digit2 return parseFloat( toFixed$1((subtrahend * ratio - minuend * ratio) / ratio, precision) ) } var subtract_1 = subtract$1 var helperNumberDecimal = helperNumberDecimal_1 var toNumberString$1 = toNumberString_1 var multiply$1 = multiply_1 function helperNumberDivide$2(divisor, dividend) { var str1 = toNumberString$1(divisor) var str2 = toNumberString$1(dividend) var divisorDecimal = helperNumberDecimal(str1) var dividendDecimal = helperNumberDecimal(str2) var powY = dividendDecimal - divisorDecimal var isMinus = powY < 0 var multiplicand = Math.pow(10, isMinus ? Math.abs(powY) : powY) return multiply$1( str1.replace('.', '') / str2.replace('.', ''), isMinus ? 1 / multiplicand : multiplicand ) } var helperNumberDivide_1 = helperNumberDivide$2 var helperNumberDivide$1 = helperNumberDivide_1 var toNumber$1 = toNumber_1 function divide$1(num1, num2) { return helperNumberDivide$1(toNumber$1(num1), toNumber$1(num2)) } var divide_1 = divide$1 var helperNumberAdd = helperNumberAdd_1 var isFunction$7 = isFunction_1$1 var each$j = each_1 var get$4 = get_1 function sum$3(array4, iterate2, context2) { var result = 0 each$j( array4, iterate2 ? isFunction$7(iterate2) ? function () { result = helperNumberAdd( result, iterate2.apply(context2, arguments) ) } : function (val2) { result = helperNumberAdd(result, get$4(val2, iterate2)) } : function (val2) { result = helperNumberAdd(result, val2) } ) return result } var sum_1 = sum$3 var helperNumberDivide = helperNumberDivide_1 var getSize$3 = getSize_1 var sum$2 = sum_1 function mean$1(array4, iterate2, context2) { return helperNumberDivide( sum$2(array4, iterate2, context2), getSize$3(array4) ) } var mean_1 = mean$1 var staticStrFirst$5 = 'first' var staticStrFirst_1 = staticStrFirst$5 var staticStrLast$4 = 'last' var staticStrLast_1 = staticStrLast$4 function helperGetDateFullYear$5(date4) { return date4.getFullYear() } var helperGetDateFullYear_1 = helperGetDateFullYear$5 var staticDayTime$5 = 864e5 var staticDayTime_1 = staticDayTime$5 function helperGetDateMonth$4(date4) { return date4.getMonth() } var helperGetDateMonth_1 = helperGetDateMonth$4 var isDate$4 = isDate_1 var helperGetDateTime$a = helperGetDateTime_1 function isValidDate$c(val2) { return isDate$4(val2) && !isNaN(helperGetDateTime$a(val2)) } var isValidDate_1 = isValidDate$c var staticStrFirst$4 = staticStrFirst_1 var staticStrLast$3 = staticStrLast_1 var staticDayTime$4 = staticDayTime_1 var helperGetDateFullYear$4 = helperGetDateFullYear_1 var helperGetDateTime$9 = helperGetDateTime_1 var helperGetDateMonth$3 = helperGetDateMonth_1 var toStringDate$b = toStringDate_1 var isValidDate$b = isValidDate_1 var isNumber$6 = isNumber_1 function getWhatMonth$5(date4, offsetMonth, offsetDay) { var monthNum = offsetMonth && !isNaN(offsetMonth) ? offsetMonth : 0 date4 = toStringDate$b(date4) if (isValidDate$b(date4)) { if (offsetDay === staticStrFirst$4) { return new Date( helperGetDateFullYear$4(date4), helperGetDateMonth$3(date4) + monthNum, 1 ) } else if (offsetDay === staticStrLast$3) { return new Date( helperGetDateTime$9( getWhatMonth$5(date4, monthNum + 1, staticStrFirst$4) ) - 1 ) } else if (isNumber$6(offsetDay)) { date4.setDate(offsetDay) } if (monthNum) { var currDate = date4.getDate() date4.setMonth(helperGetDateMonth$3(date4) + monthNum) if (currDate !== date4.getDate()) { date4.setDate(1) return new Date(helperGetDateTime$9(date4) - staticDayTime$4) } } } return date4 } var getWhatMonth_1 = getWhatMonth$5 var staticStrFirst$3 = staticStrFirst_1 var staticStrLast$2 = staticStrLast_1 var helperGetDateFullYear$3 = helperGetDateFullYear_1 var getWhatMonth$4 = getWhatMonth_1 var toStringDate$a = toStringDate_1 var isValidDate$a = isValidDate_1 function getWhatYear$4(date4, offset2, month) { var number4 date4 = toStringDate$a(date4) if (isValidDate$a(date4)) { if (offset2) { number4 = offset2 && !isNaN(offset2) ? offset2 : 0 date4.setFullYear(helperGetDateFullYear$3(date4) + number4) } if (month || !isNaN(month)) { if (month === staticStrFirst$3) { return new Date(helperGetDateFullYear$3(date4), 0, 1) } else if (month === staticStrLast$2) { date4.setMonth(11) return getWhatMonth$4(date4, 0, staticStrLast$2) } else { date4.setMonth(month) } } } return date4 } var getWhatYear_1 = getWhatYear$4 var getWhatMonth$3 = getWhatMonth_1 var toStringDate$9 = toStringDate_1 var isValidDate$9 = isValidDate_1 function getQuarterNumber(date4) { var month = date4.getMonth() if (month < 3) { return 1 } else if (month < 6) { return 2 } else if (month < 9) { return 3 } return 4 } function getWhatQuarter$1(date4, offset2, day) { var currMonth, monthOffset = offset2 && !isNaN(offset2) ? offset2 * 3 : 0 date4 = toStringDate$9(date4) if (isValidDate$9(date4)) { currMonth = (getQuarterNumber(date4) - 1) * 3 date4.setMonth(currMonth) return getWhatMonth$3(date4, monthOffset, day) } return date4 } var getWhatQuarter_1 = getWhatQuarter$1 var staticStrFirst$2 = staticStrFirst_1 var staticStrLast$1 = staticStrLast_1 var staticParseInt = staticParseInt_1 var helperGetDateFullYear$2 = helperGetDateFullYear_1 var helperGetDateMonth$2 = helperGetDateMonth_1 var helperGetDateTime$8 = helperGetDateTime_1 var toStringDate$8 = toStringDate_1 var isValidDate$8 = isValidDate_1 function getWhatDay$2(date4, offset2, mode2) { date4 = toStringDate$8(date4) if (isValidDate$8(date4) && !isNaN(offset2)) { date4.setDate(date4.getDate() + staticParseInt(offset2)) if (mode2 === staticStrFirst$2) { return new Date( helperGetDateFullYear$2(date4), helperGetDateMonth$2(date4), date4.getDate() ) } else if (mode2 === staticStrLast$1) { return new Date( helperGetDateTime$8(getWhatDay$2(date4, 1, staticStrFirst$2)) - 1 ) } } return date4 } var getWhatDay_1 = getWhatDay$2 function helperStringUpperCase$2(str) { return str.toUpperCase() } var helperStringUpperCase_1 = helperStringUpperCase$2 var staticDayTime$3 = staticDayTime_1 var staticWeekTime$2 = staticDayTime$3 * 7 var staticWeekTime_1 = staticWeekTime$2 var setupDefaults$4 = setupDefaults_1 var staticDayTime$2 = staticDayTime_1 var staticWeekTime$1 = staticWeekTime_1 var helperGetDateTime$7 = helperGetDateTime_1 var toStringDate$7 = toStringDate_1 var isValidDate$7 = isValidDate_1 var isNumber$5 = isNumber_1 function getWhatWeek$2(date4, offsetWeek, offsetDay, firstDay) { date4 = toStringDate$7(date4) if (isValidDate$7(date4)) { var hasCustomDay = isNumber$5(offsetDay) var hasStartDay = isNumber$5(firstDay) var whatDayTime = helperGetDateTime$7(date4) if (hasCustomDay || hasStartDay) { var viewStartDay = hasStartDay ? firstDay : setupDefaults$4.firstDayOfWeek var currentDay = date4.getDay() var customDay = hasCustomDay ? offsetDay : currentDay if (currentDay !== customDay) { var offsetNum = 0 if (viewStartDay > currentDay) { offsetNum = -(7 - viewStartDay + currentDay) } else if (viewStartDay < currentDay) { offsetNum = viewStartDay - currentDay } if (customDay > viewStartDay) { whatDayTime += ((customDay === 0 ? 7 : customDay) - viewStartDay + offsetNum) * staticDayTime$2 } else if (customDay < viewStartDay) { whatDayTime += (7 - viewStartDay + customDay + offsetNum) * staticDayTime$2 } else { whatDayTime += offsetNum * staticDayTime$2 } } } if (offsetWeek && !isNaN(offsetWeek)) { whatDayTime += offsetWeek * staticWeekTime$1 } return new Date(whatDayTime) } return date4 } var getWhatWeek_1 = getWhatWeek$2 var setupDefaults$3 = setupDefaults_1 var staticWeekTime = staticWeekTime_1 var isNumber$4 = isNumber_1 var isValidDate$6 = isValidDate_1 var getWhatWeek$1 = getWhatWeek_1 var helperGetDateTime$6 = helperGetDateTime_1 function helperCreateGetDateWeek$2(getStartDate) { return function (date4, firstDay) { var viewStartDay = isNumber$4(firstDay) ? firstDay : setupDefaults$3.firstDayOfWeek var targetDate = getWhatWeek$1(date4, 0, viewStartDay, viewStartDay) if (isValidDate$6(targetDate)) { var targetOffsetDate = new Date( targetDate.getFullYear(), targetDate.getMonth(), targetDate.getDate() ) var targerStartDate = getStartDate(targetDate) var targetFirstDay = targerStartDate.getDay() if (targetFirstDay > viewStartDay) { targerStartDate.setDate(7 - targetFirstDay + viewStartDay + 1) } if (targetFirstDay < viewStartDay) { targerStartDate.setDate(viewStartDay - targetFirstDay + 1) } return Math.floor( (helperGetDateTime$6(targetOffsetDate) - helperGetDateTime$6(targerStartDate)) / staticWeekTime + 1 ) } return NaN } } var helperCreateGetDateWeek_1 = helperCreateGetDateWeek$2 var helperCreateGetDateWeek$1 = helperCreateGetDateWeek_1 var getYearWeek$2 = helperCreateGetDateWeek$1(function (targetDate) { return new Date(targetDate.getFullYear(), 0, 1) }) var getYearWeek_1 = getYearWeek$2 var helperGetDateFullYear$1 = helperGetDateFullYear_1 var helperGetDateMonth$1 = helperGetDateMonth_1 function helperGetYMD$1(date4) { return new Date( helperGetDateFullYear$1(date4), helperGetDateMonth$1(date4), date4.getDate() ) } var helperGetYMD_1 = helperGetYMD$1 var helperGetDateTime$5 = helperGetDateTime_1 var helperGetYMD = helperGetYMD_1 function helperGetYMDTime$1(date4) { return helperGetDateTime$5(helperGetYMD(date4)) } var helperGetYMDTime_1 = helperGetYMDTime$1 var staticDayTime$1 = staticDayTime_1 var staticStrFirst$1 = staticStrFirst_1 var helperGetYMDTime = helperGetYMDTime_1 var getWhatYear$3 = getWhatYear_1 var toStringDate$6 = toStringDate_1 var isValidDate$5 = isValidDate_1 function getYearDay$2(date4) { date4 = toStringDate$6(date4) if (isValidDate$5(date4)) { return ( Math.floor( (helperGetYMDTime(date4) - helperGetYMDTime(getWhatYear$3(date4, 0, staticStrFirst$1))) / staticDayTime$1 ) + 1 ) } return NaN } var getYearDay_1 = getYearDay$2 var toValueString$b = toValueString_1 var isUndefined$4 = isUndefined_1 var helperStringRepeat$2 = helperStringRepeat_1 function padStart$2(str, targetLength, padString) { var rest = toValueString$b(str) targetLength = targetLength >> 0 padString = isUndefined$4(padString) ? ' ' : '' + padString if (rest.padStart) { return rest.padStart(targetLength, padString) } if (targetLength > rest.length) { targetLength -= rest.length if (targetLength > padString.length) { padString += helperStringRepeat$2( padString, targetLength / padString.length ) } return padString.slice(0, targetLength) + rest } return rest } var padStart_1 = padStart$2 var setupDefaults$2 = setupDefaults_1 var helperStringUpperCase$1 = helperStringUpperCase_1 var helperGetDateFullYear = helperGetDateFullYear_1 var helperGetDateMonth = helperGetDateMonth_1 var toStringDate$5 = toStringDate_1 var getYearWeek$1 = getYearWeek_1 var getYearDay$1 = getYearDay_1 var assign$5 = assign_1 var isValidDate$4 = isValidDate_1 var isFunction$6 = isFunction_1$1 var padStart$1 = padStart_1 function handleCustomTemplate(date4, formats2, match2, value2) { var format2 = formats2[match2] if (format2) { if (isFunction$6(format2)) { return format2(value2, match2, date4) } else { return format2[value2] } } return value2 } var dateFormatRE = /\[([^\]]+)]|y{2,4}|M{1,2}|d{1,2}|H{1,2}|h{1,2}|m{1,2}|s{1,2}|S{1,3}|Z{1,2}|W{1,2}|D{1,3}|[aAeEq]/g function toDateString$2(date4, format2, options2) { if (date4) { date4 = toStringDate$5(date4) if (isValidDate$4(date4)) { var result = format2 || setupDefaults$2.parseDateFormat || setupDefaults$2.formatString var hours = date4.getHours() var apm = hours < 12 ? 'am' : 'pm' var formats2 = assign$5( {}, setupDefaults$2.parseDateRules || setupDefaults$2.formatStringMatchs, options2 ? options2.formats : null ) var fy = function (match2, length2) { return ('' + helperGetDateFullYear(date4)).substr(4 - length2) } var fM = function (match2, length2) { return padStart$1(helperGetDateMonth(date4) + 1, length2, '0') } var fd2 = function (match2, length2) { return padStart$1(date4.getDate(), length2, '0') } var fH = function (match2, length2) { return padStart$1(hours, length2, '0') } var fh = function (match2, length2) { return padStart$1(hours <= 12 ? hours : hours - 12, length2, '0') } var fm = function (match2, length2) { return padStart$1(date4.getMinutes(), length2, '0') } var fs = function (match2, length2) { return padStart$1(date4.getSeconds(), length2, '0') } var fS = function (match2, length2) { return padStart$1(date4.getMilliseconds(), length2, '0') } var fZ = function (match2, length2) { var zoneHours = (date4.getTimezoneOffset() / 60) * -1 return handleCustomTemplate( date4, formats2, match2, (zoneHours >= 0 ? '+' : '-') + padStart$1(zoneHours, 2, '0') + (length2 === 1 ? ':' : '') + '00' ) } var fW = function (match2, length2) { return padStart$1( handleCustomTemplate( date4, formats2, match2, getYearWeek$1( date4, (options2 ? options2.firstDay : null) || setupDefaults$2.firstDayOfWeek ) ), length2, '0' ) } var fD = function (match2, length2) { return padStart$1( handleCustomTemplate(date4, formats2, match2, getYearDay$1(date4)), length2, '0' ) } var parseDates = { yyyy: fy, yy: fy, MM: fM, M: fM, dd: fd2, d: fd2, HH: fH, H: fH, hh: fh, h: fh, mm: fm, m: fm, ss: fs, s: fs, SSS: fS, S: fS, ZZ: fZ, Z: fZ, WW: fW, W: fW, DDD: fD, D: fD, a: function (match2) { return handleCustomTemplate(date4, formats2, match2, apm) }, A: function (match2) { return handleCustomTemplate( date4, formats2, match2, helperStringUpperCase$1(apm) ) }, e: function (match2) { return handleCustomTemplate(date4, formats2, match2, date4.getDay()) }, E: function (match2) { return handleCustomTemplate(date4, formats2, match2, date4.getDay()) }, q: function (match2) { return handleCustomTemplate( date4, formats2, match2, Math.floor((helperGetDateMonth(date4) + 3) / 3) ) }, } return result.replace(dateFormatRE, function (match2, skip) { return ( skip || (parseDates[match2] ? parseDates[match2](match2, match2.length) : match2) ) }) } return 'Invalid Date' } return '' } var toDateString_1 = toDateString$2 var helperGetDateTime$4 = helperGetDateTime_1 var helperNewDate$2 = helperNewDate_1 var now$3 = Date.now || function () { return helperGetDateTime$4(helperNewDate$2()) } var now_1 = now$3 var helperGetDateTime$3 = helperGetDateTime_1 var now$2 = now_1 var toStringDate$4 = toStringDate_1 var isDate$3 = isDate_1 var timestamp$1 = function (str, format2) { if (str) { var date4 = toStringDate$4(str, format2) return isDate$3(date4) ? helperGetDateTime$3(date4) : date4 } return now$2() } var timestamp_1 = timestamp$1 var toDateString$1 = toDateString_1 function isDateSame$1(date1, date22, format2) { if (date1 && date22) { date1 = toDateString$1(date1, format2) return date1 !== 'Invalid Date' && date1 === toDateString$1(date22, format2) } return false } var isDateSame_1 = isDateSame$1 var helperCreateGetDateWeek = helperCreateGetDateWeek_1 var getMonthWeek$1 = helperCreateGetDateWeek(function (targetDate) { return new Date(targetDate.getFullYear(), targetDate.getMonth(), 1) }) var getMonthWeek_1 = getMonthWeek$1 var getWhatYear$2 = getWhatYear_1 var toStringDate$3 = toStringDate_1 var isValidDate$3 = isValidDate_1 var isLeapYear$1 = isLeapYear_1 function getDayOfYear$1(date4, year) { date4 = toStringDate$3(date4) if (isValidDate$3(date4)) { return isLeapYear$1(getWhatYear$2(date4, year)) ? 366 : 365 } return NaN } var getDayOfYear_1 = getDayOfYear$1 var staticDayTime = staticDayTime_1 var staticStrFirst = staticStrFirst_1 var staticStrLast = staticStrLast_1 var helperGetDateTime$2 = helperGetDateTime_1 var getWhatMonth$2 = getWhatMonth_1 var toStringDate$2 = toStringDate_1 var isValidDate$2 = isValidDate_1 function getDayOfMonth$1(date4, month) { date4 = toStringDate$2(date4) if (isValidDate$2(date4)) { return ( Math.floor( (helperGetDateTime$2(getWhatMonth$2(date4, month, staticStrLast)) - helperGetDateTime$2(getWhatMonth$2(date4, month, staticStrFirst))) / staticDayTime ) + 1 ) } return NaN } var getDayOfMonth_1 = getDayOfMonth$1 var helperGetDateTime$1 = helperGetDateTime_1 var helperNewDate$1 = helperNewDate_1 var toStringDate$1 = toStringDate_1 var isValidDate$1 = isValidDate_1 var dateDiffRules = [ ['yyyy', 31536e6], ['MM', 2592e6], ['dd', 864e5], ['HH', 36e5], ['mm', 6e4], ['ss', 1e3], ['S', 0], ] function getDateDiff$1(startDate, endDate) { var startTime, endTime, item2, diffTime, len2, index2 var result = { done: false, time: 0 } startDate = toStringDate$1(startDate) endDate = endDate ? toStringDate$1(endDate) : helperNewDate$1() if (isValidDate$1(startDate) && isValidDate$1(endDate)) { startTime = helperGetDateTime$1(startDate) endTime = helperGetDateTime$1(endDate) if (startTime < endTime) { diffTime = result.time = endTime - startTime result.done = true for (index2 = 0, len2 = dateDiffRules.length; index2 < len2; index2++) { item2 = dateDiffRules[index2] if (diffTime >= item2[1]) { if (index2 === len2 - 1) { result[item2[0]] = diffTime || 0 } else { result[item2[0]] = Math.floor(diffTime / item2[1]) diffTime -= result[item2[0]] * item2[1] } } else { result[item2[0]] = 0 } } } } return result } var getDateDiff_1 = getDateDiff$1 var toValueString$a = toValueString_1 var isUndefined$3 = isUndefined_1 var helperStringRepeat$1 = helperStringRepeat_1 function padEnd$1(str, targetLength, padString) { var rest = toValueString$a(str) targetLength = targetLength >> 0 padString = isUndefined$3(padString) ? ' ' : '' + padString if (rest.padEnd) { return rest.padEnd(targetLength, padString) } if (targetLength > rest.length) { targetLength -= rest.length if (targetLength > padString.length) { padString += helperStringRepeat$1( padString, targetLength / padString.length ) } return rest + padString.slice(0, targetLength) } return rest } var padEnd_1 = padEnd$1 var toValueString$9 = toValueString_1 var helperStringRepeat = helperStringRepeat_1 function repeat$1(str, count2) { return helperStringRepeat(toValueString$9(str), count2) } var repeat_1 = repeat$1 var toValueString$8 = toValueString_1 function trimRight$3(str) { return str && str.trimRight ? str.trimRight() : toValueString$8(str).replace(/[\s\uFEFF\xA0]+$/g, '') } var trimRight_1 = trimRight$3 var toValueString$7 = toValueString_1 function trimLeft$3(str) { return str && str.trimLeft ? str.trimLeft() : toValueString$7(str).replace(/^[\s\uFEFF\xA0]+/g, '') } var trimLeft_1 = trimLeft$3 var trimRight$2 = trimRight_1 var trimLeft$2 = trimLeft_1 function trim$4(str) { return str && str.trim ? str.trim() : trimRight$2(trimLeft$2(str)) } var trim_1 = trim$4 var staticEscapeMap$2 = { '&': '&', '<': '<', '>': '>', '"': '"', "'": ''', '`': '`', } var staticEscapeMap_1 = staticEscapeMap$2 var toValueString$6 = toValueString_1 var keys$8 = keys_1$1 function helperFormatEscaper$2(dataMap) { var replaceRegexp = new RegExp('(?:' + keys$8(dataMap).join('|') + ')', 'g') return function (str) { return toValueString$6(str).replace(replaceRegexp, function (match2) { return dataMap[match2] }) } } var helperFormatEscaper_1 = helperFormatEscaper$2 var staticEscapeMap$1 = staticEscapeMap_1 var helperFormatEscaper$1 = helperFormatEscaper_1 var escape$2 = helperFormatEscaper$1(staticEscapeMap$1) var _escape = escape$2 var staticEscapeMap = staticEscapeMap_1 var helperFormatEscaper = helperFormatEscaper_1 var each$i = each_1 var unescapeMap = {} each$i(staticEscapeMap, function (item2, key2) { unescapeMap[staticEscapeMap[key2]] = key2 }) var unescape$2 = helperFormatEscaper(unescapeMap) var _unescape = unescape$2 function helperStringSubstring$2(str, start2, end2) { return str.substring(start2, end2) } var helperStringSubstring_1 = helperStringSubstring$2 function helperStringLowerCase$2(str) { return str.toLowerCase() } var helperStringLowerCase_1 = helperStringLowerCase$2 var toValueString$5 = toValueString_1 var helperStringSubstring$1 = helperStringSubstring_1 var helperStringUpperCase = helperStringUpperCase_1 var helperStringLowerCase$1 = helperStringLowerCase_1 var camelCacheMaps = {} function camelCase$1(str) { str = toValueString$5(str) if (camelCacheMaps[str]) { return camelCacheMaps[str] } var strLen = str.length var rest = str.replace(/([-]+)/g, function (text2, flag2, index2) { return index2 && index2 + flag2.length < strLen ? '-' : '' }) strLen = rest.length rest = rest .replace(/([A-Z]+)/g, function (text2, upper, index2) { var upperLen = upper.length upper = helperStringLowerCase$1(upper) if (index2) { if (upperLen > 2 && index2 + upperLen < strLen) { return ( helperStringUpperCase(helperStringSubstring$1(upper, 0, 1)) + helperStringSubstring$1(upper, 1, upperLen - 1) + helperStringUpperCase( helperStringSubstring$1(upper, upperLen - 1, upperLen) ) ) } return ( helperStringUpperCase(helperStringSubstring$1(upper, 0, 1)) + helperStringSubstring$1(upper, 1, upperLen) ) } else { if (upperLen > 1 && index2 + upperLen < strLen) { return ( helperStringSubstring$1(upper, 0, upperLen - 1) + helperStringUpperCase( helperStringSubstring$1(upper, upperLen - 1, upperLen) ) ) } } return upper }) .replace(/(-[a-zA-Z])/g, function (text2, upper) { return helperStringUpperCase( helperStringSubstring$1(upper, 1, upper.length) ) }) camelCacheMaps[str] = rest return rest } var camelCase_1 = camelCase$1 var toValueString$4 = toValueString_1 var helperStringSubstring = helperStringSubstring_1 var helperStringLowerCase = helperStringLowerCase_1 var kebabCacheMaps = {} function kebabCase$1(str) { str = toValueString$4(str) if (kebabCacheMaps[str]) { return kebabCacheMaps[str] } if (/^[A-Z]+$/.test(str)) { return helperStringLowerCase(str) } var rest = str .replace( /^([a-z])([A-Z]+)([a-z]+)$/, function (text2, prevLower, upper, nextLower) { var upperLen = upper.length if (upperLen > 1) { return ( prevLower + '-' + helperStringLowerCase( helperStringSubstring(upper, 0, upperLen - 1) ) + '-' + helperStringLowerCase( helperStringSubstring(upper, upperLen - 1, upperLen) ) + nextLower ) } return helperStringLowerCase(prevLower + '-' + upper + nextLower) } ) .replace(/^([A-Z]+)([a-z]+)?$/, function (text2, upper, nextLower) { var upperLen = upper.length return helperStringLowerCase( helperStringSubstring(upper, 0, upperLen - 1) + '-' + helperStringSubstring(upper, upperLen - 1, upperLen) + (nextLower || '') ) }) .replace( /([a-z]?)([A-Z]+)([a-z]?)/g, function (text2, prevLower, upper, nextLower, index2) { var upperLen = upper.length if (upperLen > 1) { if (prevLower) { prevLower += '-' } if (nextLower) { return ( (prevLower || '') + helperStringLowerCase( helperStringSubstring(upper, 0, upperLen - 1) ) + '-' + helperStringLowerCase( helperStringSubstring(upper, upperLen - 1, upperLen) ) + nextLower ) } } return ( (prevLower || '') + (index2 ? '-' : '') + helperStringLowerCase(upper) + (nextLower || '') ) } ) rest = rest.replace(/([-]+)/g, function (text2, flag2, index2) { return index2 && index2 + flag2.length < rest.length ? '-' : '' }) kebabCacheMaps[str] = rest return rest } var kebabCase_1 = kebabCase$1 var toValueString$3 = toValueString_1 function startsWith$1(str, val2, startIndex) { var rest = toValueString$3(str) return ( (arguments.length === 1 ? rest : rest.substring(startIndex)).indexOf( val2 ) === 0 ) } var startsWith_1 = startsWith$1 var toValueString$2 = toValueString_1 function endsWith$1(str, val2, startIndex) { var rest = toValueString$2(str) var argsLen = arguments.length return ( argsLen > 1 && (argsLen > 2 ? rest.substring(0, startIndex).indexOf(val2) === startIndex - 1 : rest.indexOf(val2) === rest.length - 1) ) } var endsWith_1 = endsWith$1 var setupDefaults$1 = setupDefaults_1 var toValueString$1 = toValueString_1 var trim$3 = trim_1 var get$3 = get_1 function template$2(str, args, options2) { return toValueString$1(str).replace( (options2 || setupDefaults$1).tmplRE || /\{{2}([.\w[\]\s]+)\}{2}/g, function (match2, key2) { return get$3(args, trim$3(key2)) } ) } var template_1 = template$2 var template$1 = template_1 function toFormatString$1(str, obj) { return template$1(str, obj, { tmplRE: /\{([.\w[\]\s]+)\}/g }) } var toFormatString_1 = toFormatString$1 function noop$4() {} var noop_1 = noop$4 var slice$7 = slice_1 function bind$8(callback, context2) { var args = slice$7(arguments, 2) return function () { return callback.apply(context2, slice$7(arguments).concat(args)) } } var bind_1 = bind$8 var slice$6 = slice_1 function once$1(callback, context2) { var done = false var rest = null var args = slice$6(arguments, 2) return function () { if (done) { return rest } rest = callback.apply(context2, slice$6(arguments).concat(args)) done = true return rest } } var once_1 = once$1 var slice$5 = slice_1 function after$1(count2, callback, context2) { var runCount = 0 var rests = [] return function () { var args = arguments runCount++ if (runCount <= count2) { rests.push(args[0]) } if (runCount >= count2) { callback.apply(context2, [rests].concat(slice$5(args))) } } } var after_1 = after$1 var slice$4 = slice_1 function before$1(count2, callback, context2) { var runCount = 0 var rests = [] context2 = context2 || this return function () { var args = arguments runCount++ if (runCount < count2) { rests.push(args[0]) callback.apply(context2, [rests].concat(slice$4(args))) } } } var before_1 = before$1 function throttle$3(callback, wait, options2) { var args, context2 var opts = options2 || {} var runFlag = false var timeout = 0 var optLeading = 'leading' in opts ? opts.leading : true var optTrailing = 'trailing' in opts ? opts.trailing : false var runFn = function () { { runFlag = true callback.apply(context2, args) timeout = setTimeout(endFn, wait) } } var endFn = function () { timeout = 0 if (!runFlag && optTrailing === true) { runFn() } } var cancelFn = function () { var rest = timeout !== 0 clearTimeout(timeout) args = null context2 = null runFlag = false timeout = 0 return rest } var throttled = function () { args = arguments context2 = this runFlag = false if (timeout === 0) { if (optLeading === true) { runFn() } else if (optTrailing === true) { timeout = setTimeout(endFn, wait) } } } throttled.cancel = cancelFn return throttled } var throttle_1 = throttle$3 function debounce$1(callback, wait, options2) { var args, context2 var opts = options2 || {} var runFlag = false var timeout = 0 var isLeading = typeof options2 === 'boolean' var optLeading = 'leading' in opts ? opts.leading : isLeading var optTrailing = 'trailing' in opts ? opts.trailing : !isLeading var runFn = function () { { runFlag = true timeout = 0 callback.apply(context2, args) } } var endFn = function () { if (optLeading === true) { timeout = 0 } if (!runFlag && optTrailing === true) { runFn() } } var cancelFn = function () { var rest = timeout !== 0 clearTimeout(timeout) args = null context2 = null timeout = 0 return rest } var debounced = function () { runFlag = false args = arguments context2 = this if (timeout === 0) { if (optLeading === true) { runFn() } } else { clearTimeout(timeout) } timeout = setTimeout(endFn, wait) } debounced.cancel = cancelFn return debounced } var debounce_1 = debounce$1 var slice$3 = slice_1 function delay$1(callback, wait) { var args = slice$3(arguments, 2) var context2 = this return setTimeout(function () { callback.apply(context2, args) }, wait) } var delay_1 = delay$1 var staticDecodeURIComponent$2 = decodeURIComponent var staticDecodeURIComponent_1 = staticDecodeURIComponent$2 var staticDecodeURIComponent$1 = staticDecodeURIComponent_1 var arrayEach$5 = arrayEach_1 var isString$4 = isString_1 function unserialize$2(str) { var items var result = {} if (str && isString$4(str)) { arrayEach$5(str.split('&'), function (param) { items = param.split('=') result[staticDecodeURIComponent$1(items[0])] = staticDecodeURIComponent$1( items[1] || '' ) }) } return result } var unserialize_1 = unserialize$2 var staticEncodeURIComponent$2 = encodeURIComponent var staticEncodeURIComponent_1 = staticEncodeURIComponent$2 var staticEncodeURIComponent$1 = staticEncodeURIComponent_1 var each$h = each_1 var isArray$b = isArray_1$1 var isNull$1 = isNull_1 var isUndefined$2 = isUndefined_1 var isPlainObject$2 = isPlainObject_1 function stringifyParams(resultVal, resultKey, isArr) { var _arr var result = [] each$h(resultVal, function (item2, key2) { _arr = isArray$b(item2) if (isPlainObject$2(item2) || _arr) { result = result.concat( stringifyParams(item2, resultKey + '[' + key2 + ']', _arr) ) } else { result.push( staticEncodeURIComponent$1( resultKey + '[' + (isArr ? '' : key2) + ']' ) + '=' + staticEncodeURIComponent$1(isNull$1(item2) ? '' : item2) ) } }) return result } function serialize$1(query) { var _arr var params2 = [] each$h(query, function (item2, key2) { if (!isUndefined$2(item2)) { _arr = isArray$b(item2) if (isPlainObject$2(item2) || _arr) { params2 = params2.concat(stringifyParams(item2, key2, _arr)) } else { params2.push( staticEncodeURIComponent$1(key2) + '=' + staticEncodeURIComponent$1(isNull$1(item2) ? '' : item2) ) } } }) return params2.join('&').replace(/%20/g, '+') } var serialize_1 = serialize$1 var staticStrUndefined$1 = staticStrUndefined_1 var staticLocation$4 = typeof location === staticStrUndefined$1 ? 0 : location var staticLocation_1 = staticLocation$4 var staticLocation$3 = staticLocation_1 function helperGetLocatOrigin$2() { return staticLocation$3 ? staticLocation$3.origin || staticLocation$3.protocol + '//' + staticLocation$3.host : '' } var helperGetLocatOrigin_1 = helperGetLocatOrigin$2 var staticLocation$2 = staticLocation_1 var unserialize$1 = unserialize_1 var helperGetLocatOrigin$1 = helperGetLocatOrigin_1 function parseURLQuery(uri) { return unserialize$1(uri.split('?')[1] || '') } function parseUrl$2(url2) { var hashs, portText, searchs, parsed var href = '' + url2 if (href.indexOf('//') === 0) { href = (staticLocation$2 ? staticLocation$2.protocol : '') + href } else if (href.indexOf('/') === 0) { href = helperGetLocatOrigin$1() + href } searchs = href.replace(/#.*/, '').match(/(\?.*)/) parsed = { href, hash: '', host: '', hostname: '', protocol: '', port: '', search: searchs && searchs[1] && searchs[1].length > 1 ? searchs[1] : '', } parsed.path = href .replace(/^([a-z0-9.+-]*:)\/\//, function (text2, protocol) { parsed.protocol = protocol return '' }) .replace(/^([a-z0-9.+-]*)(:\d+)?\/?/, function (text2, hostname, port2) { portText = port2 || '' parsed.port = portText.replace(':', '') parsed.hostname = hostname parsed.host = hostname + portText return '/' }) .replace(/(#.*)/, function (text2, hash2) { parsed.hash = hash2.length > 1 ? hash2 : '' return '' }) hashs = parsed.hash.match(/#((.*)\?|(.*))/) parsed.pathname = parsed.path.replace(/(\?|#.*).*/, '') parsed.origin = parsed.protocol + '//' + parsed.host parsed.hashKey = hashs ? hashs[2] || hashs[1] || '' : '' parsed.hashQuery = parseURLQuery(parsed.hash) parsed.searchQuery = parseURLQuery(parsed.search) return parsed } var parseUrl_1 = parseUrl$2 var staticLocation$1 = staticLocation_1 var helperGetLocatOrigin = helperGetLocatOrigin_1 var lastIndexOf$1 = lastIndexOf_1 function getBaseURL$1() { if (staticLocation$1) { var pathname = staticLocation$1.pathname var lastIndex = lastIndexOf$1(pathname, '/') + 1 return ( helperGetLocatOrigin() + (lastIndex === pathname.length ? pathname : pathname.substring(0, lastIndex)) ) } return '' } var getBaseURL_1 = getBaseURL$1 var staticLocation = staticLocation_1 var parseUrl$1 = parseUrl_1 function locat$1() { return staticLocation ? parseUrl$1(staticLocation.href) : {} } var locat_1 = locat$1 var setupDefaults = setupDefaults_1 var staticDocument$1 = staticDocument_1 var staticDecodeURIComponent = staticDecodeURIComponent_1 var staticEncodeURIComponent = staticEncodeURIComponent_1 var isArray$a = isArray_1$1 var isObject$n = isObject_1$1 var isDate$2 = isDate_1 var isUndefined$1 = isUndefined_1 var includes$1 = includes_1 var keys$7 = keys_1$1 var assign$4 = assign_1 var arrayEach$4 = arrayEach_1 var helperNewDate = helperNewDate_1 var helperGetDateTime = helperGetDateTime_1 var getWhatYear$1 = getWhatYear_1 var getWhatMonth$1 = getWhatMonth_1 var getWhatDay$1 = getWhatDay_1 function toCookieUnitTime(unit, expires) { var num2 = parseFloat(expires) var nowdate = helperNewDate() var time2 = helperGetDateTime(nowdate) switch (unit) { case 'y': return helperGetDateTime(getWhatYear$1(nowdate, num2)) case 'M': return helperGetDateTime(getWhatMonth$1(nowdate, num2)) case 'd': return helperGetDateTime(getWhatDay$1(nowdate, num2)) case 'h': case 'H': return time2 + num2 * 60 * 60 * 1e3 case 'm': return time2 + num2 * 60 * 1e3 case 's': return time2 + num2 * 1e3 } return time2 } function toCookieUTCString(date4) { return (isDate$2(date4) ? date4 : new Date(date4)).toUTCString() } function cookie$1(name2, value2, options2) { if (staticDocument$1) { var opts, expires, values2, result, cookies2, keyIndex var inserts = [] var args = arguments if (isArray$a(name2)) { inserts = name2 } else if (args.length > 1) { inserts = [assign$4({ name: name2, value: value2 }, options2)] } else if (isObject$n(name2)) { inserts = [name2] } if (inserts.length > 0) { arrayEach$4(inserts, function (obj) { opts = assign$4({}, setupDefaults.cookies, obj) values2 = [] if (opts.name) { expires = opts.expires values2.push( staticEncodeURIComponent(opts.name) + '=' + staticEncodeURIComponent( isObject$n(opts.value) ? JSON.stringify(opts.value) : opts.value ) ) if (expires) { if (isNaN(expires)) { expires = expires.replace( /^([0-9]+)(y|M|d|H|h|m|s)$/, function (text2, num2, unit) { return toCookieUTCString(toCookieUnitTime(unit, num2)) } ) } else if (/^[0-9]{11,13}$/.test(expires) || isDate$2(expires)) { expires = toCookieUTCString(expires) } else { expires = toCookieUTCString(toCookieUnitTime('d', expires)) } opts.expires = expires } arrayEach$4(['expires', 'path', 'domain', 'secure'], function (key2) { if (!isUndefined$1(opts[key2])) { values2.push( opts[key2] && key2 === 'secure' ? key2 : key2 + '=' + opts[key2] ) } }) } staticDocument$1.cookie = values2.join('; ') }) return true } else { result = {} cookies2 = staticDocument$1.cookie if (cookies2) { arrayEach$4(cookies2.split('; '), function (val2) { keyIndex = val2.indexOf('=') result[staticDecodeURIComponent(val2.substring(0, keyIndex))] = staticDecodeURIComponent(val2.substring(keyIndex + 1) || '') }) } return args.length === 1 ? result[name2] : result } } return false } function hasCookieItem(value2) { return includes$1(cookieKeys(), value2) } function getCookieItem(name2) { return cookie$1(name2) } function setCookieItem(name2, value2, options2) { cookie$1(name2, value2, options2) return cookie$1 } function removeCookieItem(name2, options2) { cookie$1( name2, '', assign$4({ expires: -1 }, setupDefaults.cookies, options2) ) } function cookieKeys() { return keys$7(cookie$1()) } function cookieJson() { return cookie$1() } assign$4(cookie$1, { has: hasCookieItem, set: setCookieItem, setItem: setCookieItem, get: getCookieItem, getItem: getCookieItem, remove: removeCookieItem, removeItem: removeCookieItem, keys: cookieKeys, getJSON: cookieJson, }) var cookie_1 = cookie$1 var staticStrUndefined = staticStrUndefined_1 var staticDocument = staticDocument_1 var staticWindow = staticWindow_1 var assign$3 = assign_1 var arrayEach$3 = arrayEach_1 function isBrowseStorage(storage2) { try { var testKey = '__xe_t' storage2.setItem(testKey, 1) storage2.removeItem(testKey) return true } catch (e2) { return false } } function isBrowseType(type4) { return navigator.userAgent.indexOf(type4) > -1 } function browse$2() { var $body, isChrome, isEdge var isMobile = false var isLocalStorage = false var isSessionStorage = false var result = { isNode: false, isMobile, isPC: false, isDoc: !!staticDocument, } if (!staticWindow && typeof process !== staticStrUndefined) { result.isNode = true } else { isEdge = isBrowseType('Edge') isChrome = isBrowseType('Chrome') isMobile = /(Android|webOS|iPhone|iPad|iPod|SymbianOS|BlackBerry|Windows Phone)/.test( navigator.userAgent ) if (result.isDoc) { $body = staticDocument.body || staticDocument.documentElement arrayEach$3(['webkit', 'khtml', 'moz', 'ms', 'o'], function (core2) { result['-' + core2] = !!$body[core2 + 'MatchesSelector'] }) } try { isLocalStorage = isBrowseStorage(staticWindow.localStorage) } catch (e2) {} try { isSessionStorage = isBrowseStorage(staticWindow.sessionStorage) } catch (e2) {} assign$3(result, { edge: isEdge, firefox: isBrowseType('Firefox'), msie: !isEdge && result['-ms'], safari: !isChrome && !isEdge && isBrowseType('Safari'), isMobile, isPC: !isMobile, isLocalStorage, isSessionStorage, }) } return result } var browse_1 = browse$2 var XEUtils = ctor var assign$2 = assign_1 var objectEach = objectEach_1 var lastObjectEach = lastObjectEach_1 var objectMap = objectMap_1 var merge$1 = merge_1 var map$2 = map_1 var some = some_1 var every = every_1 var includeArrays = includeArrays_1 var arrayEach$2 = arrayEach_1 var lastArrayEach = lastArrayEach_1 var uniq = uniq_1 var union = union_1 var toArray = toArray_1 var sortBy = sortBy_1 var orderBy = orderBy_1 var shuffle = shuffle_1 var sample = sample_1 var slice$2 = slice_1 var filter$1 = filter_1 var findKey = findKey_1 var includes = includes_1 var find$2 = find_1 var findLast = findLast_1 var reduce$1 = reduce_1 var copyWithin = copyWithin_1 var chunk = chunk_1 var zip = zip_1 var unzip = unzip_1 var zipObject = zipObject_1 var flatten = flatten_1 var pluck = pluck_1 var invoke = invoke_1 var toArrayTree = toArrayTree_1 var toTreeArray = toTreeArray_1 var findTree = findTree_1 var eachTree = eachTree_1 var mapTree = mapTree_1 var filterTree = filterTree_1 var searchTree = searchTree_1 var arrayIndexOf = arrayIndexOf_1 var arrayLastIndexOf = arrayLastIndexOf_1 var hasOwnProp = hasOwnProp_1 var isArray$9 = isArray_1$1 var isNull = isNull_1 var isNumberNaN = _isNaN var isUndefined = isUndefined_1 var isFunction$5 = isFunction_1$1 var isObject$m = isObject_1$1 var isString$3 = isString_1 var isPlainObject$1 = isPlainObject_1 var isLeapYear = isLeapYear_1 var isDate$1 = isDate_1 var eqNull = eqNull_1 var each$g = each_1 var forOf = forOf_1 var lastForOf = lastForOf_1 var indexOf$3 = indexOf_1 var lastIndexOf = lastIndexOf_1 var keys$6 = keys_1$1 var values$1 = values_1 var clone$7 = clone_1 var getSize$2 = getSize_1 var lastEach = lastEach_1 var remove = remove_1 var clear$3 = clear_1 var isNumberFinite = _isFinite var isFloat = isFloat_1 var isInteger = isInteger_1 var isBoolean$1 = isBoolean_1 var isNumber$3 = isNumber_1 var isRegExp$4 = isRegExp_1 var isError = isError_1 var isTypeError = isTypeError_1 var isEmpty = isEmpty_1 var isSymbol$3 = isSymbol_1 var isArguments$2 = isArguments_1$1 var isElement = isElement_1 var isDocument = isDocument_1 var isWindow = isWindow_1 var isFormData = isFormData_1 var isMap$2 = isMap_1$1 var isWeakMap = isWeakMap_1 var isSet$2 = isSet_1$1 var isWeakSet = isWeakSet_1 var isMatch = isMatch_1 var isEqual = isEqual_1 var isEqualWith = isEqualWith_1 var getType = getType_1 var uniqueId = uniqueId_1 var findIndexOf = findIndexOf_1 var findLastIndexOf = findLastIndexOf_1 var toStringJSON = toStringJSON_1 var toJSONString = toJSONString_1 var entries = entries_1 var pick = pick_1 var omit = omit_1 var first = first_1 var last$1 = last_1 var has$3 = has_1 var get$2 = get_1 var set$4 = set_1 var groupBy = groupBy_1 var countBy = countBy_1 var range = range_1 var destructuring = destructuring_1 var random$1 = random_1 var max$6 = max_1 var min$8 = min_1 var commafy = commafy_1 var round$4 = round_1 var ceil$1 = ceil_1 var floor$2 = floor_1 var toFixed = toFixed_1 var toInteger = toInteger_1 var toNumber = toNumber_1 var toNumberString = toNumberString_1 var add$1 = add_1 var subtract = subtract_1 var multiply = multiply_1 var divide = divide_1 var sum$1 = sum_1 var mean = mean_1 var getWhatYear = getWhatYear_1 var getWhatQuarter = getWhatQuarter_1 var getWhatMonth = getWhatMonth_1 var getWhatDay = getWhatDay_1 var toStringDate = toStringDate_1 var toDateString = toDateString_1 var now$1 = now_1 var timestamp = timestamp_1 var isValidDate = isValidDate_1 var isDateSame = isDateSame_1 var getWhatWeek = getWhatWeek_1 var getYearDay = getYearDay_1 var getYearWeek = getYearWeek_1 var getMonthWeek = getMonthWeek_1 var getDayOfYear = getDayOfYear_1 var getDayOfMonth = getDayOfMonth_1 var getDateDiff = getDateDiff_1 var padEnd = padEnd_1 var padStart = padStart_1 var repeat = repeat_1 var trim$2 = trim_1 var trimRight$1 = trimRight_1 var trimLeft$1 = trimLeft_1 var escape$1 = _escape var unescape$1 = _unescape var camelCase = camelCase_1 var kebabCase = kebabCase_1 var startsWith = startsWith_1 var endsWith = endsWith_1 var template = template_1 var toFormatString = toFormatString_1 var toValueString = toValueString_1 var noop$3 = noop_1 var property = property_1 var bind$7 = bind_1 var once = once_1 var after = after_1 var before = before_1 var throttle$2 = throttle_1 var debounce = debounce_1 var delay = delay_1 var unserialize = unserialize_1 var serialize = serialize_1 var parseUrl = parseUrl_1 var getBaseURL = getBaseURL_1 var locat = locat_1 var cookie = cookie_1 var browse$1 = browse_1 assign$2(XEUtils, { assign: assign$2, objectEach, lastObjectEach, objectMap, merge: merge$1, uniq, union, sortBy, orderBy, shuffle, sample, some, every, slice: slice$2, filter: filter$1, find: find$2, findLast, findKey, includes, arrayIndexOf, arrayLastIndexOf, map: map$2, reduce: reduce$1, copyWithin, chunk, zip, unzip, zipObject, flatten, toArray, includeArrays, pluck, invoke, arrayEach: arrayEach$2, lastArrayEach, toArrayTree, toTreeArray, findTree, eachTree, mapTree, filterTree, searchTree, hasOwnProp, eqNull, isNaN: isNumberNaN, isFinite: isNumberFinite, isUndefined, isArray: isArray$9, isFloat, isInteger, isFunction: isFunction$5, isBoolean: isBoolean$1, isString: isString$3, isNumber: isNumber$3, isRegExp: isRegExp$4, isObject: isObject$m, isPlainObject: isPlainObject$1, isDate: isDate$1, isError, isTypeError, isEmpty, isNull, isSymbol: isSymbol$3, isArguments: isArguments$2, isElement, isDocument, isWindow, isFormData, isMap: isMap$2, isWeakMap, isSet: isSet$2, isWeakSet, isLeapYear, isMatch, isEqual, isEqualWith, getType, uniqueId, getSize: getSize$2, indexOf: indexOf$3, lastIndexOf, findIndexOf, findLastIndexOf, toStringJSON, toJSONString, keys: keys$6, values: values$1, entries, pick, omit, first, last: last$1, each: each$g, forOf, lastForOf, lastEach, has: has$3, get: get$2, set: set$4, groupBy, countBy, clone: clone$7, clear: clear$3, remove, range, destructuring, random: random$1, min: min$8, max: max$6, commafy, round: round$4, ceil: ceil$1, floor: floor$2, toFixed, toNumber, toNumberString, toInteger, add: add$1, subtract, multiply, divide, sum: sum$1, mean, now: now$1, timestamp, isValidDate, isDateSame, toStringDate, toDateString, getWhatYear, getWhatQuarter, getWhatMonth, getWhatWeek, getWhatDay, getYearDay, getYearWeek, getMonthWeek, getDayOfYear, getDayOfMonth, getDateDiff, trim: trim$2, trimLeft: trimLeft$1, trimRight: trimRight$1, escape: escape$1, unescape: unescape$1, camelCase, kebabCase, repeat, padStart, padEnd, startsWith, endsWith, template, toFormatString, toString: toValueString, toValueString, noop: noop$3, property, bind: bind$7, once, after, before, throttle: throttle$2, debounce, delay, unserialize, serialize, parseUrl, getBaseURL, locat, browse: browse$1, cookie, }) var xeUtils = XEUtils var index_common = {} ;(function (exports2) { Object.defineProperty(exports2, '__esModule', { value: true, }) exports2['default'] = exports2.VXETablePluginElement = void 0 var _xeUtils = _interopRequireDefault(xeUtils) function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj } } function _defineProperty2(obj, key2, value2) { if (key2 in obj) { Object.defineProperty(obj, key2, { value: value2, enumerable: true, configurable: true, writable: true, }) } else { obj[key2] = value2 } return obj } function isEmptyValue2(cellValue) { return cellValue === null || cellValue === void 0 || cellValue === '' } function getModelProp(renderOpts) { return 'value' } function getModelEvent2(renderOpts) { return 'input' } function getChangeEvent2(renderOpts) { var type4 = 'change' switch (renderOpts.name) { case 'ElAutocomplete': type4 = 'select' break case 'ElInput': case 'ElInputNumber': type4 = 'input' break } return type4 } function parseDate2(value2, props2) { return value2 && props2.valueFormat ? _xeUtils['default'].toStringDate(value2, props2.valueFormat) : value2 } function getFormatDate2(value2, props2, defaultFormat) { return _xeUtils['default'].toDateString( parseDate2(value2, props2), props2.format || defaultFormat ) } function getFormatDates(values2, props2, separator, defaultFormat) { return _xeUtils['default'] .map(values2, function (date4) { return getFormatDate2(date4, props2, defaultFormat) }) .join(separator) } function equalDaterange(cellValue, data2, props2, defaultFormat) { cellValue = getFormatDate2(cellValue, props2, defaultFormat) return ( cellValue >= getFormatDate2(data2[0], props2, defaultFormat) && cellValue <= getFormatDate2(data2[1], props2, defaultFormat) ) } function getCellEditFilterProps2(renderOpts, params2, value2, defaultProps2) { var vSize = params2.$table.vSize return _xeUtils['default'].assign( vSize ? { size: vSize, } : {}, defaultProps2, renderOpts.props, _defineProperty2({}, getModelProp(), value2) ) } function getItemProps(renderOpts, params2, value2, defaultProps2) { var vSize = params2.$form.vSize return _xeUtils['default'].assign( vSize ? { size: vSize, } : {}, defaultProps2, renderOpts.props, _defineProperty2({}, getModelProp(), value2) ) } function formatText2(cellValue) { return '' + (isEmptyValue2(cellValue) ? '' : cellValue) } function getCellLabelVNs2(h2, renderOpts, params2, cellLabel) { var placeholder = renderOpts.placeholder return [ h2( 'span', { class: 'vxe-cell--label', }, placeholder && isEmptyValue2(cellLabel) ? [ h2( 'span', { class: 'vxe-cell--placeholder', }, formatText2(placeholder) ), ] : formatText2(cellLabel) ), ] } function getNativeOns(renderOpts, params2) { var nativeEvents = renderOpts.nativeEvents var nativeOns = {} _xeUtils['default'].objectEach(nativeEvents, function (func, key2) { nativeOns[key2] = function () { for ( var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++ ) { args[_key] = arguments[_key] } func.apply(void 0, [params2].concat(args)) } }) return nativeOns } function getOns(renderOpts, params2, inputFunc, changeFunc) { var events2 = renderOpts.events var modelEvent = getModelEvent2() var changeEvent = getChangeEvent2(renderOpts) var isSameEvent = changeEvent === modelEvent var ons = {} _xeUtils['default'].objectEach(events2, function (func, key2) { ons[key2] = function () { for ( var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++ ) { args[_key2] = arguments[_key2] } func.apply(void 0, [params2].concat(args)) } }) if (inputFunc) { ons[modelEvent] = function (targetEvnt) { inputFunc(targetEvnt) if (events2 && events2[modelEvent]) { events2[modelEvent](params2, targetEvnt) } if (isSameEvent && changeFunc) { changeFunc(targetEvnt) } } } if (!isSameEvent && changeFunc) { ons[changeEvent] = function () { for ( var _len3 = arguments.length, args = new Array(_len3), _key3 = 0; _key3 < _len3; _key3++ ) { args[_key3] = arguments[_key3] } changeFunc.apply(void 0, args) if (events2 && events2[changeEvent]) { events2[changeEvent].apply(events2, [params2].concat(args)) } } } return ons } function getEditOns2(renderOpts, params2) { var $table = params2.$table, row = params2.row, column = params2.column return getOns( renderOpts, params2, function (value2) { _xeUtils['default'].set(row, column.property, value2) }, function () { $table.updateStatus(params2) } ) } function getFilterOns2(renderOpts, params2, option2, changeFunc) { return getOns( renderOpts, params2, function (value2) { option2.data = value2 }, changeFunc ) } function getItemOns2(renderOpts, params2) { var $form = params2.$form, data2 = params2.data, property2 = params2.property return getOns( renderOpts, params2, function (value2) { _xeUtils['default'].set(data2, property2, value2) }, function () { $form.updateStatus(params2) } ) } function matchCascaderData(index2, list2, values2, labels) { var val2 = values2[index2] if (list2 && values2.length > index2) { _xeUtils['default'].each(list2, function (item2) { if (item2.value === val2) { labels.push(item2.label) matchCascaderData(++index2, item2.children, values2, labels) } }) } } function getSelectCellValue2(renderOpts, params2) { var _renderOpts$options = renderOpts.options, options2 = _renderOpts$options === void 0 ? [] : _renderOpts$options, optionGroups = renderOpts.optionGroups, _renderOpts$props = renderOpts.props, props2 = _renderOpts$props === void 0 ? {} : _renderOpts$props, _renderOpts$optionPro = renderOpts.optionProps, optionProps = _renderOpts$optionPro === void 0 ? {} : _renderOpts$optionPro, _renderOpts$optionGro = renderOpts.optionGroupProps, optionGroupProps = _renderOpts$optionGro === void 0 ? {} : _renderOpts$optionGro var row = params2.row, column = params2.column var $table = params2.$table var labelProp = optionProps.label || 'label' var valueProp = optionProps.value || 'value' var groupOptions = optionGroupProps.options || 'options' var cellValue = _xeUtils['default'].get(row, column.property) var colid = column.id var rest var cellData if (props2.filterable) { var fullAllDataRowMap = $table.fullAllDataRowMap var cacheCell = fullAllDataRowMap.has(row) if (cacheCell) { rest = fullAllDataRowMap.get(row) cellData = rest.cellData if (!cellData) { cellData = fullAllDataRowMap.get(row).cellData = {} } } if (rest && cellData[colid] && cellData[colid].value === cellValue) { return cellData[colid].label } } if (!isEmptyValue2(cellValue)) { var selectlabel = _xeUtils['default'] .map( props2.multiple ? cellValue : [cellValue], optionGroups ? function (value2) { var selectItem for (var index2 = 0; index2 < optionGroups.length; index2++) { selectItem = _xeUtils['default'].find( optionGroups[index2][groupOptions], function (item2) { return item2[valueProp] === value2 } ) if (selectItem) { break } } return selectItem ? selectItem[labelProp] : value2 } : function (value2) { var selectItem = _xeUtils['default'].find( options2, function (item2) { return item2[valueProp] === value2 } ) return selectItem ? selectItem[labelProp] : value2 } ) .join(', ') if (cellData && options2 && options2.length) { cellData[colid] = { value: cellValue, label: selectlabel, } } return selectlabel } return '' } function getCascaderCellValue(renderOpts, params2) { var _renderOpts$props2 = renderOpts.props, props2 = _renderOpts$props2 === void 0 ? {} : _renderOpts$props2 var row = params2.row, column = params2.column var cellValue = _xeUtils['default'].get(row, column.property) var values2 = cellValue || [] var labels = [] matchCascaderData(0, props2.options, values2, labels) return ( props2.showAllLevels === false ? labels.slice(labels.length - 1, labels.length) : labels ).join(' '.concat(props2.separator || '/', ' ')) } function getDatePickerCellValue(renderOpts, params2) { var _renderOpts$props3 = renderOpts.props, props2 = _renderOpts$props3 === void 0 ? {} : _renderOpts$props3 var row = params2.row, column = params2.column var _props$rangeSeparator = props2.rangeSeparator, rangeSeparator = _props$rangeSeparator === void 0 ? '-' : _props$rangeSeparator var cellValue = _xeUtils['default'].get(row, column.property) switch (props2.type) { case 'week': cellValue = getFormatDate2(cellValue, props2, 'yyyywWW') break case 'month': cellValue = getFormatDate2(cellValue, props2, 'yyyy-MM') break case 'year': cellValue = getFormatDate2(cellValue, props2, 'yyyy') break case 'dates': cellValue = getFormatDates(cellValue, props2, ', ', 'yyyy-MM-dd') break case 'daterange': cellValue = getFormatDates( cellValue, props2, ' '.concat(rangeSeparator, ' '), 'yyyy-MM-dd' ) break case 'datetimerange': cellValue = getFormatDates( cellValue, props2, ' '.concat(rangeSeparator, ' '), 'yyyy-MM-dd HH:ss:mm' ) break case 'monthrange': cellValue = getFormatDates( cellValue, props2, ' '.concat(rangeSeparator, ' '), 'yyyy-MM' ) break default: cellValue = getFormatDate2(cellValue, props2, 'yyyy-MM-dd') } return cellValue } function getTimePickerCellValue(renderOpts, params2) { var _renderOpts$props4 = renderOpts.props, props2 = _renderOpts$props4 === void 0 ? {} : _renderOpts$props4 var row = params2.row, column = params2.column var isRange = props2.isRange, _props$format = props2.format, format2 = _props$format === void 0 ? 'hh:mm:ss' : _props$format, _props$rangeSeparator2 = props2.rangeSeparator, rangeSeparator = _props$rangeSeparator2 === void 0 ? '-' : _props$rangeSeparator2 var cellValue = _xeUtils['default'].get(row, column.property) if (cellValue && isRange) { cellValue = _xeUtils['default'] .map(cellValue, function (date4) { return _xeUtils['default'].toDateString( parseDate2(date4, props2), format2 ) }) .join(' '.concat(rangeSeparator, ' ')) } return _xeUtils['default'].toDateString( parseDate2(cellValue, props2), format2 ) } function createEditRender(defaultProps2) { return function (h2, renderOpts, params2) { var row = params2.row, column = params2.column var attrs = renderOpts.attrs var cellValue = _xeUtils['default'].get(row, column.property) return [ h2(renderOpts.name, { attrs, props: getCellEditFilterProps2( renderOpts, params2, cellValue, defaultProps2 ), on: getEditOns2(renderOpts, params2), nativeOn: getNativeOns(renderOpts, params2), }), ] } } function defaultButtonEditRender2(h2, renderOpts, params2) { var attrs = renderOpts.attrs return [ h2( 'el-button', { attrs, props: getCellEditFilterProps2(renderOpts, params2, null), on: getOns(renderOpts, params2), nativeOn: getNativeOns(renderOpts, params2), }, cellText(h2, renderOpts.content) ), ] } function defaultButtonsEditRender2(h2, renderOpts, params2) { return renderOpts.children.map(function (childRenderOpts) { return defaultButtonEditRender2(h2, childRenderOpts, params2)[0] }) } function createFilterRender(defaultProps2) { return function (h2, renderOpts, params2) { var column = params2.column var name2 = renderOpts.name, attrs = renderOpts.attrs var nativeOn = getNativeOns(renderOpts, params2) return [ h2( 'div', { class: 'vxe-table--filter-element-wrapper', }, column.filters.map(function (option2, oIndex) { var optionValue = option2.data return h2(name2, { key: oIndex, attrs, props: getCellEditFilterProps2( renderOpts, params2, optionValue, defaultProps2 ), on: getFilterOns2(renderOpts, params2, option2, function () { handleConfirmFilter2(params2, !!option2.data, option2) }), nativeOn, }) }) ), ] } } function handleConfirmFilter2(params2, checked2, option2) { var $panel = params2.$panel $panel.changeOption({}, checked2, option2) } function defaultFuzzyFilterMethod(params2) { var option2 = params2.option, row = params2.row, column = params2.column var data2 = option2.data var cellValue = _xeUtils['default'].get(row, column.property) return _xeUtils['default'].toValueString(cellValue).indexOf(data2) > -1 } function defaultExactFilterMethod(params2) { var option2 = params2.option, row = params2.row, column = params2.column var data2 = option2.data var cellValue = _xeUtils['default'].get(row, column.property) return cellValue === data2 } function renderOptions(h2, options2, optionProps) { var labelProp = optionProps.label || 'label' var valueProp = optionProps.value || 'value' return _xeUtils['default'].map(options2, function (item2, oIndex) { return h2('el-option', { key: oIndex, props: { value: item2[valueProp], label: item2[labelProp], disabled: item2.disabled, }, }) }) } function cellText(h2, cellValue) { return [formatText2(cellValue)] } function createFormItemRender(defaultProps2) { return function (h2, renderOpts, params2) { var data2 = params2.data, property2 = params2.property var name2 = renderOpts.name var attrs = renderOpts.attrs var itemValue = _xeUtils['default'].get(data2, property2) return [ h2(name2, { attrs, props: getItemProps(renderOpts, params2, itemValue, defaultProps2), on: getItemOns2(renderOpts, params2), nativeOn: getNativeOns(renderOpts, params2), }), ] } } function defaultButtonItemRender2(h2, renderOpts, params2) { var attrs = renderOpts.attrs var props2 = getItemProps(renderOpts, params2, null) return [ h2( 'el-button', { attrs, props: props2, on: getOns(renderOpts, params2), nativeOn: getNativeOns(renderOpts, params2), }, cellText(h2, renderOpts.content || props2.content) ), ] } function defaultButtonsItemRender2(h2, renderOpts, params2) { return renderOpts.children.map(function (childRenderOpts) { return defaultButtonItemRender2(h2, childRenderOpts, params2)[0] }) } function createExportMethod(getExportCellValue) { return function (params2) { var row = params2.row, column = params2.column, options2 = params2.options return options2 && options2.original ? _xeUtils['default'].get(row, column.property) : getExportCellValue(column.editRender || column.cellRender, params2) } } function createFormItemRadioAndCheckboxRender() { return function (h2, renderOpts, params2) { var name2 = renderOpts.name, _renderOpts$options2 = renderOpts.options, options2 = _renderOpts$options2 === void 0 ? [] : _renderOpts$options2, _renderOpts$optionPro2 = renderOpts.optionProps, optionProps = _renderOpts$optionPro2 === void 0 ? {} : _renderOpts$optionPro2, attrs = renderOpts.attrs var data2 = params2.data, property2 = params2.property var labelProp = optionProps.label || 'label' var valueProp = optionProps.value || 'value' var itemValue = _xeUtils['default'].get(data2, property2) return [ h2( ''.concat(name2, 'Group'), { attrs, props: getItemProps(renderOpts, params2, itemValue), on: getItemOns2(renderOpts, params2), nativeOn: getNativeOns(renderOpts, params2), }, options2.map(function (option2, oIndex) { return h2( name2, { key: oIndex, props: { label: option2[valueProp], disabled: option2.disabled, }, }, option2[labelProp] ) }) ), ] } } function getEventTargetNode2(evnt, container, className) { var targetElem var target2 = evnt.target while (target2 && target2.nodeType && target2 !== document) { if ( className && target2.className && target2.className.split && target2.className.split(' ').indexOf(className) > -1 ) { targetElem = target2 } else if (target2 === container) { return { flag: className ? !!targetElem : true, container, targetElem, } } target2 = target2.parentNode } return { flag: false, } } function handleClearEvent(params2, e2) { var bodyElem = document.body var evnt = params2.$event || e2 if ( getEventTargetNode2(evnt, bodyElem, 'el-autocomplete-suggestion').flag || getEventTargetNode2(evnt, bodyElem, 'el-select-dropdown').flag || getEventTargetNode2(evnt, bodyElem, 'el-cascader__dropdown').flag || getEventTargetNode2(evnt, bodyElem, 'el-cascader-menus').flag || getEventTargetNode2(evnt, bodyElem, 'el-time-panel').flag || getEventTargetNode2(evnt, bodyElem, 'el-picker-panel').flag || getEventTargetNode2(evnt, bodyElem, 'el-color-dropdown').flag ) { return false } } var VXETablePluginElement2 = { install: function install3(vxetable) { if (!/^(2|3)\./.test(vxetable.version)) { // console.error("[vxe-table-plugin-element] Version vxe-table 3.x is required"); } vxetable.renderer.mixin({ ElAutocomplete: { autofocus: 'input.el-input__inner', renderDefault: createEditRender(), renderEdit: createEditRender(), renderFilter: createFilterRender(), defaultFilterMethod: defaultExactFilterMethod, renderItem: createFormItemRender(), renderItemContent: createFormItemRender(), }, ElInput: { autofocus: 'input.el-input__inner', renderDefault: createEditRender(), renderEdit: createEditRender(), renderFilter: createFilterRender(), defaultFilterMethod: defaultFuzzyFilterMethod, renderItem: createFormItemRender(), renderItemContent: createFormItemRender(), }, ElInputNumber: { autofocus: 'input.el-input__inner', renderDefault: createEditRender(), renderEdit: createEditRender(), renderFilter: createFilterRender(), defaultFilterMethod: defaultFuzzyFilterMethod, renderItem: createFormItemRender(), renderItemContent: createFormItemRender(), }, ElSelect: { renderEdit: function renderEdit(h2, renderOpts, params2) { var _renderOpts$options3 = renderOpts.options, options2 = _renderOpts$options3 === void 0 ? [] : _renderOpts$options3, optionGroups = renderOpts.optionGroups, _renderOpts$optionPro3 = renderOpts.optionProps, optionProps = _renderOpts$optionPro3 === void 0 ? {} : _renderOpts$optionPro3, _renderOpts$optionGro2 = renderOpts.optionGroupProps, optionGroupProps = _renderOpts$optionGro2 === void 0 ? {} : _renderOpts$optionGro2 var row = params2.row, column = params2.column var attrs = renderOpts.attrs var cellValue = _xeUtils['default'].get(row, column.property) var props2 = getCellEditFilterProps2(renderOpts, params2, cellValue) var on2 = getEditOns2(renderOpts, params2) var nativeOn = getNativeOns(renderOpts, params2) if (optionGroups) { var groupOptions = optionGroupProps.options || 'options' var groupLabel = optionGroupProps.label || 'label' return [ h2( 'el-select', { attrs, props: props2, on: on2, nativeOn, }, _xeUtils['default'].map( optionGroups, function (group, gIndex) { return h2( 'el-option-group', { key: gIndex, props: { label: group[groupLabel], }, }, renderOptions(h2, group[groupOptions], optionProps) ) } ) ), ] } return [ h2( 'el-select', { props: props2, attrs, on: on2, nativeOn, }, renderOptions(h2, options2, optionProps) ), ] }, renderCell: function renderCell(h2, renderOpts, params2) { return getCellLabelVNs2( h2, renderOpts, params2, getSelectCellValue2(renderOpts, params2) ) }, renderFilter: function renderFilter(h2, renderOpts, params2) { var _renderOpts$options4 = renderOpts.options, options2 = _renderOpts$options4 === void 0 ? [] : _renderOpts$options4, optionGroups = renderOpts.optionGroups, _renderOpts$optionPro4 = renderOpts.optionProps, optionProps = _renderOpts$optionPro4 === void 0 ? {} : _renderOpts$optionPro4, _renderOpts$optionGro3 = renderOpts.optionGroupProps, optionGroupProps = _renderOpts$optionGro3 === void 0 ? {} : _renderOpts$optionGro3 var groupOptions = optionGroupProps.options || 'options' var groupLabel = optionGroupProps.label || 'label' var column = params2.column var attrs = renderOpts.attrs var nativeOn = getNativeOns(renderOpts, params2) return [ h2( 'div', { class: 'vxe-table--filter-element-wrapper', }, optionGroups ? column.filters.map(function (option2, oIndex) { var optionValue = option2.data var props2 = getCellEditFilterProps2( renderOpts, params2, optionValue ) return h2( 'el-select', { key: oIndex, attrs, props: props2, on: getFilterOns2( renderOpts, params2, option2, function () { handleConfirmFilter2( params2, props2.multiple ? option2.data && option2.data.length > 0 : !_xeUtils['default'].eqNull(option2.data), option2 ) } ), nativeOn, }, _xeUtils['default'].map( optionGroups, function (group, gIndex) { return h2( 'el-option-group', { key: gIndex, props: { label: group[groupLabel], }, }, renderOptions( h2, group[groupOptions], optionProps ) ) } ) ) }) : column.filters.map(function (option2, oIndex) { var optionValue = option2.data var props2 = getCellEditFilterProps2( renderOpts, params2, optionValue ) return h2( 'el-select', { key: oIndex, attrs, props: props2, on: getFilterOns2( renderOpts, params2, option2, function () { handleConfirmFilter2( params2, props2.multiple ? option2.data && option2.data.length > 0 : !_xeUtils['default'].eqNull(option2.data), option2 ) } ), nativeOn, }, renderOptions(h2, options2, optionProps) ) }) ), ] }, defaultFilterMethod: function defaultFilterMethod(params2) { var option2 = params2.option, row = params2.row, column = params2.column var data2 = option2.data var property2 = column.property, renderOpts = column.filterRender var _renderOpts$props5 = renderOpts.props, props2 = _renderOpts$props5 === void 0 ? {} : _renderOpts$props5 var cellValue = _xeUtils['default'].get(row, property2) if (props2.multiple) { if (_xeUtils['default'].isArray(cellValue)) { return _xeUtils['default'].includeArrays(cellValue, data2) } return data2.indexOf(cellValue) > -1 } return cellValue == data2 }, renderItem: function renderItem(h2, renderOpts, params2) { var _renderOpts$options5 = renderOpts.options, options2 = _renderOpts$options5 === void 0 ? [] : _renderOpts$options5, optionGroups = renderOpts.optionGroups, _renderOpts$optionPro5 = renderOpts.optionProps, optionProps = _renderOpts$optionPro5 === void 0 ? {} : _renderOpts$optionPro5, _renderOpts$optionGro4 = renderOpts.optionGroupProps, optionGroupProps = _renderOpts$optionGro4 === void 0 ? {} : _renderOpts$optionGro4 var data2 = params2.data, property2 = params2.property var attrs = renderOpts.attrs var itemValue = _xeUtils['default'].get(data2, property2) var props2 = getItemProps(renderOpts, params2, itemValue) var on2 = getItemOns2(renderOpts, params2) var nativeOn = getNativeOns(renderOpts, params2) if (optionGroups) { var groupOptions = optionGroupProps.options || 'options' var groupLabel = optionGroupProps.label || 'label' return [ h2( 'el-select', { attrs, props: props2, on: on2, nativeOn, }, _xeUtils['default'].map( optionGroups, function (group, gIndex) { return h2( 'el-option-group', { props: { label: group[groupLabel], }, key: gIndex, }, renderOptions(h2, group[groupOptions], optionProps) ) } ) ), ] } return [ h2( 'el-select', { attrs, props: props2, on: on2, nativeOn, }, renderOptions(h2, options2, optionProps) ), ] }, renderItemContent: function renderItemContent( h2, renderOpts, params2 ) { var _renderOpts$options6 = renderOpts.options, options2 = _renderOpts$options6 === void 0 ? [] : _renderOpts$options6, optionGroups = renderOpts.optionGroups, _renderOpts$optionPro6 = renderOpts.optionProps, optionProps = _renderOpts$optionPro6 === void 0 ? {} : _renderOpts$optionPro6, _renderOpts$optionGro5 = renderOpts.optionGroupProps, optionGroupProps = _renderOpts$optionGro5 === void 0 ? {} : _renderOpts$optionGro5 var data2 = params2.data, property2 = params2.property var attrs = renderOpts.attrs var itemValue = _xeUtils['default'].get(data2, property2) var props2 = getItemProps(renderOpts, params2, itemValue) var on2 = getItemOns2(renderOpts, params2) var nativeOn = getNativeOns(renderOpts, params2) if (optionGroups) { var groupOptions = optionGroupProps.options || 'options' var groupLabel = optionGroupProps.label || 'label' return [ h2( 'el-select', { attrs, props: props2, on: on2, nativeOn, }, _xeUtils['default'].map( optionGroups, function (group, gIndex) { return h2( 'el-option-group', { props: { label: group[groupLabel], }, key: gIndex, }, renderOptions(h2, group[groupOptions], optionProps) ) } ) ), ] } return [ h2( 'el-select', { attrs, props: props2, on: on2, nativeOn, }, renderOptions(h2, options2, optionProps) ), ] }, cellExportMethod: createExportMethod(getSelectCellValue2), exportMethod: createExportMethod(getSelectCellValue2), }, ElCascader: { renderEdit: createEditRender(), renderCell: function renderCell(h2, renderOpts, params2) { return getCellLabelVNs2( h2, renderOpts, params2, getCascaderCellValue(renderOpts, params2) ) }, renderItem: createFormItemRender(), renderItemContent: createFormItemRender(), cellExportMethod: createExportMethod(getCascaderCellValue), exportMethod: createExportMethod(getCascaderCellValue), }, ElDatePicker: { renderEdit: createEditRender(), renderCell: function renderCell(h2, renderOpts, params2) { return getCellLabelVNs2( h2, renderOpts, params2, getDatePickerCellValue(renderOpts, params2) ) }, renderFilter: function renderFilter(h2, renderOpts, params2) { var column = params2.column var attrs = renderOpts.attrs var nativeOn = getNativeOns(renderOpts, params2) return [ h2( 'div', { class: 'vxe-table--filter-element-wrapper', }, column.filters.map(function (option2, oIndex) { var optionValue = option2.data return h2(renderOpts.name, { key: oIndex, attrs, props: getCellEditFilterProps2( renderOpts, params2, optionValue ), on: getFilterOns2( renderOpts, params2, option2, function () { handleConfirmFilter2(params2, !!option2.data, option2) } ), nativeOn, }) }) ), ] }, defaultFilterMethod: function defaultFilterMethod(params2) { var option2 = params2.option, row = params2.row, column = params2.column var data2 = option2.data var renderOpts = column.filterRender var _renderOpts$props6 = renderOpts.props, props2 = _renderOpts$props6 === void 0 ? {} : _renderOpts$props6 var cellValue = _xeUtils['default'].get(row, column.property) if (data2) { switch (props2.type) { case 'daterange': return equalDaterange(cellValue, data2, props2, 'yyyy-MM-dd') case 'datetimerange': return equalDaterange( cellValue, data2, props2, 'yyyy-MM-dd HH:ss:mm' ) case 'monthrange': return equalDaterange(cellValue, data2, props2, 'yyyy-MM') default: return cellValue === data2 } } return false }, renderItem: createFormItemRender(), renderItemContent: createFormItemRender(), cellExportMethod: createExportMethod(getDatePickerCellValue), exportMethod: createExportMethod(getDatePickerCellValue), }, ElTimePicker: { renderEdit: createEditRender(), renderCell: function renderCell(h2, renderOpts, params2) { return getCellLabelVNs2( h2, renderOpts, params2, getTimePickerCellValue(renderOpts, params2) ) }, renderItem: createFormItemRender(), renderItemContent: createFormItemRender(), cellExportMethod: createExportMethod(getTimePickerCellValue), exportMethod: createExportMethod(getTimePickerCellValue), }, ElTimeSelect: { renderEdit: createEditRender(), renderItem: createFormItemRender(), renderItemContent: createFormItemRender(), }, ElRate: { renderDefault: createEditRender(), renderEdit: createEditRender(), renderFilter: createFilterRender(), defaultFilterMethod: defaultExactFilterMethod, renderItem: createFormItemRender(), renderItemContent: createFormItemRender(), }, ElSwitch: { renderDefault: createEditRender(), renderEdit: createEditRender(), renderFilter: function renderFilter(h2, renderOpts, params2) { var column = params2.column var name2 = renderOpts.name, attrs = renderOpts.attrs var nativeOn = getNativeOns(renderOpts, params2) return [ h2( 'div', { class: 'vxe-table--filter-element-wrapper', }, column.filters.map(function (option2, oIndex) { var optionValue = option2.data return h2(name2, { key: oIndex, attrs, props: getCellEditFilterProps2( renderOpts, params2, optionValue ), on: getFilterOns2( renderOpts, params2, option2, function () { handleConfirmFilter2( params2, _xeUtils['default'].isBoolean(option2.data), option2 ) } ), nativeOn, }) }) ), ] }, defaultFilterMethod: defaultExactFilterMethod, renderItem: createFormItemRender(), renderItemContent: createFormItemRender(), }, ElSlider: { renderDefault: createEditRender(), renderEdit: createEditRender(), renderFilter: createFilterRender(), defaultFilterMethod: defaultExactFilterMethod, renderItem: createFormItemRender(), renderItemContent: createFormItemRender(), }, ElRadio: { renderItem: createFormItemRadioAndCheckboxRender(), renderItemContent: createFormItemRadioAndCheckboxRender(), }, ElCheckbox: { renderItem: createFormItemRadioAndCheckboxRender(), renderItemContent: createFormItemRadioAndCheckboxRender(), }, ElButton: { renderDefault: defaultButtonEditRender2, renderItem: defaultButtonItemRender2, renderItemContent: defaultButtonItemRender2, }, ElButtons: { renderDefault: defaultButtonsEditRender2, renderItem: defaultButtonsItemRender2, renderItemContent: defaultButtonsItemRender2, }, }) vxetable.interceptor.add('event.clearFilter', handleClearEvent) vxetable.interceptor.add('event.clearActived', handleClearEvent) vxetable.interceptor.add('event.clearAreas', handleClearEvent) }, } exports2.VXETablePluginElement = VXETablePluginElement2 if (typeof window !== 'undefined' && window.VXETable && window.VXETable.use) { window.VXETable.use(VXETablePluginElement2) } var _default2 = VXETablePluginElement2 exports2['default'] = _default2 })(index_common) var VXETablePluginElement = /* @__PURE__ */ getDefaultExportFromCjs(index_common) var style$2 = '' var iconPrefix = 'vxe-icon-' var GlobalConfig = { size: null, zIndex: 999, version: 0, emptyCell: '\u3000', table: { fit: true, showHeader: true, animat: true, delayHover: 250, autoResize: true, minHeight: 144, resizeConfig: { refreshDelay: 250, }, radioConfig: { strict: true, }, checkboxConfig: { strict: true, }, tooltipConfig: { enterable: true, }, validConfig: { showMessage: true, autoClear: true, message: 'inline', msgMode: 'single', }, columnConfig: { maxFixedSize: 4, }, sortConfig: { showIcon: true, }, filterConfig: { showIcon: true, }, treeConfig: { rowField: 'id', parentField: 'parentId', childrenField: 'children', hasChildField: 'hasChild', mapChildrenField: '_X_ROW_CHILD', indent: 20, showIcon: true, }, expandConfig: { showIcon: true, }, editConfig: { showIcon: true, showAsterisk: true, }, importConfig: { modes: ['insert', 'covering'], }, exportConfig: { modes: ['current', 'selected'], }, printConfig: { modes: ['current', 'selected'], }, mouseConfig: { extension: true, }, keyboardConfig: { isEsc: true, }, areaConfig: { selectCellByHeader: true, }, clipConfig: { isCopy: true, isCut: true, isPaste: true, }, fnrConfig: { isFind: true, isReplace: true, }, scrollX: { gt: 60, }, scrollY: { gt: 100, }, }, export: { types: {}, }, icon: { LOADING: iconPrefix + 'spinner roll vxe-loading--default-icon', TABLE_SORT_ASC: iconPrefix + 'caret-up', TABLE_SORT_DESC: iconPrefix + 'caret-down', TABLE_FILTER_NONE: iconPrefix + 'funnel', TABLE_FILTER_MATCH: iconPrefix + 'funnel', TABLE_EDIT: iconPrefix + 'edit', TABLE_HELP: iconPrefix + 'question-circle-fill', TABLE_TREE_LOADED: iconPrefix + 'spinner roll', TABLE_TREE_OPEN: iconPrefix + 'caret-right rotate90', TABLE_TREE_CLOSE: iconPrefix + 'caret-right', TABLE_EXPAND_LOADED: iconPrefix + 'spinner roll', TABLE_EXPAND_OPEN: iconPrefix + 'arrow-right rotate90', TABLE_EXPAND_CLOSE: iconPrefix + 'arrow-right', TABLE_CHECKBOX_CHECKED: iconPrefix + 'checkbox-checked', TABLE_CHECKBOX_UNCHECKED: iconPrefix + 'checkbox-unchecked', TABLE_CHECKBOX_INDETERMINATE: iconPrefix + 'checkbox-indeterminate', TABLE_RADIO_CHECKED: iconPrefix + 'radio-checked', TABLE_RADIO_UNCHECKED: iconPrefix + 'radio-unchecked', BUTTON_DROPDOWN: iconPrefix + 'arrow-down', BUTTON_LOADING: iconPrefix + 'spinner roll', SELECT_LOADED: iconPrefix + 'spinner roll', SELECT_OPEN: iconPrefix + 'caret-down rotate180', SELECT_CLOSE: iconPrefix + 'caret-down', PAGER_JUMP_PREV: iconPrefix + 'arrow-double-left', PAGER_JUMP_NEXT: iconPrefix + 'arrow-double-right', PAGER_PREV_PAGE: iconPrefix + 'arrow-left', PAGER_NEXT_PAGE: iconPrefix + 'arrow-right', PAGER_JUMP_MORE: iconPrefix + 'ellipsis-h', INPUT_CLEAR: iconPrefix + 'error-circle-fill', INPUT_PWD: iconPrefix + 'eye-fill', INPUT_SHOW_PWD: iconPrefix + 'eye-fill-close', INPUT_PREV_NUM: iconPrefix + 'caret-up', INPUT_NEXT_NUM: iconPrefix + 'caret-down', INPUT_DATE: iconPrefix + 'calendar', INPUT_SEARCH: iconPrefix + 'search', MODAL_ZOOM_IN: iconPrefix + 'square', MODAL_ZOOM_OUT: iconPrefix + 'maximize', MODAL_CLOSE: iconPrefix + 'close', MODAL_INFO: iconPrefix + 'info-circle-fill', MODAL_SUCCESS: iconPrefix + 'success-circle-fill', MODAL_WARNING: iconPrefix + 'warnion-circle-fill', MODAL_ERROR: iconPrefix + 'error-circle-fill', MODAL_QUESTION: iconPrefix + 'question-circle-fill', MODAL_LOADING: iconPrefix + 'spinner roll', TOOLBAR_TOOLS_REFRESH: iconPrefix + 'repeat', TOOLBAR_TOOLS_REFRESH_LOADING: iconPrefix + 'repeat roll', TOOLBAR_TOOLS_IMPORT: iconPrefix + 'upload', TOOLBAR_TOOLS_EXPORT: iconPrefix + 'download', TOOLBAR_TOOLS_PRINT: iconPrefix + 'print', TOOLBAR_TOOLS_FULLSCREEN: iconPrefix + 'fullscreen', TOOLBAR_TOOLS_MINIMIZE: iconPrefix + 'minimize', TOOLBAR_TOOLS_CUSTOM: iconPrefix + 'custom-column', TOOLBAR_TOOLS_FIXED_LEFT: iconPrefix + 'fixed-left', TOOLBAR_TOOLS_FIXED_LEFT_ACTIVED: iconPrefix + 'fixed-left-fill', TOOLBAR_TOOLS_FIXED_RIGHT: iconPrefix + 'fixed-right', TOOLBAR_TOOLS_FIXED_RIGHT_ACTIVED: iconPrefix + 'fixed-right-fill', FORM_PREFIX: iconPrefix + 'question-circle-fill', FORM_SUFFIX: iconPrefix + 'question-circle-fill', FORM_FOLDING: iconPrefix + 'arrow-up rotate180', FORM_UNFOLDING: iconPrefix + 'arrow-up', }, grid: { formConfig: { enabled: true, }, pagerConfig: { enabled: true, }, toolbarConfig: { enabled: true, }, proxyConfig: { enabled: true, autoLoad: true, message: true, props: { list: null, result: 'result', total: 'page.total', message: 'message', }, }, }, tooltip: { trigger: 'hover', theme: 'dark', enterDelay: 500, leaveDelay: 300, }, pager: {}, form: { validConfig: { showMessage: true, autoPos: true, }, tooltipConfig: { enterable: true, }, titleAsterisk: true, }, input: { startDate: new Date(1900, 0, 1), endDate: new Date(2100, 0, 1), startDay: 1, selectDay: 1, digits: 2, controls: true, }, textarea: {}, select: { multiCharOverflow: 8, }, toolbar: { custom: { allowFixed: true, showFooter: true, }, }, button: {}, radio: { strict: true, }, radioButton: { strict: true, }, radioGroup: { strict: true, }, checkbox: {}, switch: {}, modal: { top: 15, showHeader: true, minWidth: 340, minHeight: 140, lockView: true, mask: true, duration: 3e3, marginSize: 0, dblclickZoom: true, showTitleOverflow: true, animat: true, showClose: true, draggable: true, storageKey: 'VXE_MODAL_POSITION', }, list: { scrollY: { enabled: true, gt: 100, }, }, i18n: function (key2) { return key2 }, } function getLog(message2, params2) { return '[vxe-table v' .concat('4.5.12', '] ') .concat(GlobalConfig.i18n(message2, params2)) } function outLog(type4) { return function (message2, params2) { var msg = getLog(message2, params2) console[type4](msg) return msg } } var warnLog = outLog('warn') var errLog = outLog('error') var storeMap = {} var interceptor = { mixin: function (options2) { xeUtils.each(options2, function (callback, type4) { return interceptor.add(type4, callback) }) return interceptor }, get: function (type4) { return storeMap[type4] || [] }, add: function (type4, callback) { if (callback) { var eList = storeMap[type4] if (!eList) { eList = storeMap[type4] = [] } eList.push(callback) } return interceptor }, delete: function (type4, callback) { var eList = storeMap[type4] if (eList) { if (callback) { xeUtils.remove(eList, function (fn2) { return fn2 === callback }) } else { delete storeMap[type4] } } }, } var VXEFormatsStore = (function () { function VXEFormatsStore2() { this.store = {} } VXEFormatsStore2.prototype.mixin = function (options2) { var _this = this xeUtils.each(options2, function (item2, key2) { _this.add(key2, item2) }) return this } VXEFormatsStore2.prototype.has = function (name2) { return !!this.get(name2) } VXEFormatsStore2.prototype.get = function (name2) { return this.store[name2] } VXEFormatsStore2.prototype.add = function (name2, render2) { var conf = this.store[name2] if (xeUtils.isFunction(render2)) { render2 = { cellFormatMethod: render2, } } this.store[name2] = conf ? xeUtils.merge(conf, render2) : render2 return this } VXEFormatsStore2.prototype.delete = function (name2) { delete this.store[name2] } VXEFormatsStore2.prototype.forEach = function (callback) { xeUtils.objectEach(this.store, callback) } return VXEFormatsStore2 })() var formats = new VXEFormatsStore() var storeEl = null var storeId = 'z-index-manage' var storeMainKey = 'm' var storeSubKey = 's' var storeData = { m: 1e3, s: 1e3, } function getDom() { if (!storeEl) { if (typeof document !== 'undefined') { storeEl = document.getElementById(storeId) if (!storeEl) { storeEl = document.createElement('div') storeEl.id = storeId storeEl.style.display = 'none' document.body.appendChild(storeEl) setCurrent(storeData.m) setSubCurrent(storeData.s) } } } return storeEl } function createSetHandle(key2) { return function (value2) { if (value2) { value2 = Number(value2) storeData[key2] = value2 var doc = getDom() if (doc) { if (doc.dataset) { doc.dataset[key2] = value2 + '' } else { doc.setAttribute('data-' + key2, value2 + '') } } } return storeData[key2] } } var setCurrent = createSetHandle(storeMainKey) function createGetHandle(key2, nextMethod) { return function getCurrent2(currZindex) { var zIndex2 var doc = getDom() if (doc) { var domVal = doc.dataset ? doc.dataset[key2] : doc.getAttribute('data-' + key2) if (domVal) { zIndex2 = Number(domVal) } } if (!zIndex2) { zIndex2 = storeData[key2] } if (currZindex) { if (Number(currZindex) < zIndex2) { return nextMethod() } return currZindex } return zIndex2 } } var getCurrent = createGetHandle(storeMainKey, getNext) function getNext() { return setCurrent(getCurrent() + 1) } var setSubCurrent = createSetHandle(storeSubKey) var _getSubCurrent = createGetHandle(storeSubKey, getSubNext) function getSubCurrent() { return getCurrent() + _getSubCurrent() } function getSubNext() { setSubCurrent(_getSubCurrent() + 1) return getSubCurrent() } var DomZIndex = { setCurrent, getCurrent, getNext, setSubCurrent, getSubCurrent, getSubNext, } function isEnableConf(conf) { return conf && conf.enabled !== false } function isEmptyValue$1(cellValue) { return cellValue === null || cellValue === void 0 || cellValue === '' } function parseFile(file2) { var name2 = file2.name var tIndex = xeUtils.lastIndexOf(name2, '.') var type4 = name2.substring(tIndex + 1, name2.length).toLowerCase() var filename = name2.substring(0, tIndex) return { filename, type: type4 } } function nextZIndex() { return DomZIndex.getNext() } function getLastZIndex() { return DomZIndex.getCurrent() } function hasChildrenList(item2) { return item2 && item2.children && item2.children.length > 0 } function getFuncText(content2) { return content2 ? xeUtils.toValueString( GlobalConfig.translate ? GlobalConfig.translate('' + content2) : content2 ) : '' } function formatText(value2, placeholder) { return ( '' + (isEmptyValue$1(value2) ? placeholder ? GlobalConfig.emptyCell : '' : value2) ) } function eqEmptyValue(cellValue) { return cellValue === '' || xeUtils.eqNull(cellValue) } var ColumnInfo = (function () { function ColumnInfo2($xetable, _vm, _a2) { var _b2 = _a2 === void 0 ? {} : _a2, renderHeader = _b2.renderHeader, renderCell = _b2.renderCell, renderFooter = _b2.renderFooter, renderData = _b2.renderData var $xegrid = $xetable.xegrid var formatter2 = _vm.formatter var visible = xeUtils.isBoolean(_vm.visible) ? _vm.visible : true Object.assign(this, { type: _vm.type, property: _vm.field, field: _vm.field, title: _vm.title, width: _vm.width, minWidth: _vm.minWidth, maxWidth: _vm.maxWidth, resizable: _vm.resizable, fixed: _vm.fixed, align: _vm.align, headerAlign: _vm.headerAlign, footerAlign: _vm.footerAlign, showOverflow: _vm.showOverflow, showHeaderOverflow: _vm.showHeaderOverflow, showFooterOverflow: _vm.showFooterOverflow, className: _vm.className, headerClassName: _vm.headerClassName, footerClassName: _vm.footerClassName, formatter: formatter2, sortable: _vm.sortable, sortBy: _vm.sortBy, sortType: _vm.sortType, filters: toFilters(_vm.filters), filterMultiple: xeUtils.isBoolean(_vm.filterMultiple) ? _vm.filterMultiple : true, filterMethod: _vm.filterMethod, filterResetMethod: _vm.filterResetMethod, filterRecoverMethod: _vm.filterRecoverMethod, filterRender: _vm.filterRender, treeNode: _vm.treeNode, cellType: _vm.cellType, cellRender: _vm.cellRender, editRender: _vm.editRender, contentRender: _vm.contentRender, headerExportMethod: _vm.headerExportMethod, exportMethod: _vm.exportMethod, footerExportMethod: _vm.footerExportMethod, titleHelp: _vm.titleHelp, titlePrefix: _vm.titlePrefix, params: _vm.params, id: _vm.colId || xeUtils.uniqueId('col_'), parentId: null, visible, halfVisible: false, defaultVisible: visible, defaultFixed: _vm.fixed, checked: false, halfChecked: false, disabled: false, level: 1, rowSpan: 1, colSpan: 1, order: null, sortTime: 0, customOrder: 0, renderWidth: 0, renderHeight: 0, resizeWidth: 0, renderLeft: 0, renderArgs: [], model: {}, renderHeader: renderHeader || _vm.renderHeader, renderCell: renderCell || _vm.renderCell, renderFooter: renderFooter || _vm.renderFooter, renderData, slots: _vm.slots, }) if ($xegrid) { var computeProxyOpts = $xegrid.getComputeMaps().computeProxyOpts var proxyOpts = computeProxyOpts.value if (proxyOpts.beforeColumn) { proxyOpts.beforeColumn({ $grid: $xegrid, column: this }) } } } ColumnInfo2.prototype.getTitle = function () { return getFuncText( this.title || (this.type === 'seq' ? GlobalConfig.i18n('vxe.table.seqTitle') : '') ) } ColumnInfo2.prototype.getKey = function () { return this.field || (this.type ? 'type='.concat(this.type) : null) } ColumnInfo2.prototype.update = function (name2, value2) { if (name2 !== 'filters') { if (name2 === 'field') { this.property = value2 } this[name2] = value2 } } return ColumnInfo2 })() var reClsMap = {} var browse = xeUtils.browse() function getPropClass(property2, params2) { return property2 ? xeUtils.isFunction(property2) ? property2(params2) : property2 : '' } function getClsRE(cls) { if (!reClsMap[cls]) { reClsMap[cls] = new RegExp('(?:^|\\s)'.concat(cls, '(?!\\S)'), 'g') } return reClsMap[cls] } function getNodeOffset(elem, container, rest) { if (elem) { var parentElem = elem.parentNode rest.top += elem.offsetTop rest.left += elem.offsetLeft if ( parentElem && parentElem !== document.documentElement && parentElem !== document.body ) { rest.top -= parentElem.scrollTop rest.left -= parentElem.scrollLeft } if ( container && (elem === container || elem.offsetParent === container) ? 0 : elem.offsetParent ) { return getNodeOffset(elem.offsetParent, container, rest) } } return rest } function isPx(val2) { return val2 && /^\d+(px)?$/.test(val2) } function isScale(val2) { return val2 && /^\d+%$/.test(val2) } function hasClass(elem, cls) { return ( elem && elem.className && elem.className.match && elem.className.match(getClsRE(cls)) ) } function removeClass(elem, cls) { if (elem && hasClass(elem, cls)) { elem.className = elem.className.replace(getClsRE(cls), '') } } function addClass(elem, cls) { if (elem && !hasClass(elem, cls)) { removeClass(elem, cls) elem.className = ''.concat(elem.className, ' ').concat(cls) } } function getDomNode() { var documentElement = document.documentElement var bodyElem = document.body return { scrollTop: documentElement.scrollTop || bodyElem.scrollTop, scrollLeft: documentElement.scrollLeft || bodyElem.scrollLeft, visibleHeight: documentElement.clientHeight || bodyElem.clientHeight, visibleWidth: documentElement.clientWidth || bodyElem.clientWidth, } } function getOffsetHeight(elem) { return elem ? elem.offsetHeight : 0 } function getPaddingTopBottomSize(elem) { if (elem) { var computedStyle = getComputedStyle(elem) var paddingTop2 = xeUtils.toNumber(computedStyle.paddingTop) var paddingBottom2 = xeUtils.toNumber(computedStyle.paddingBottom) return paddingTop2 + paddingBottom2 } return 0 } function setScrollTop(elem, scrollTop) { if (elem) { elem.scrollTop = scrollTop } } function setScrollLeft(elem, scrollLeft) { if (elem) { elem.scrollLeft = scrollLeft } } function updateCellTitle(overflowElem, column) { var content2 = column.type === 'html' ? overflowElem.innerText : overflowElem.textContent if (overflowElem.getAttribute('title') !== content2) { overflowElem.setAttribute('title', content2) } } function getEventTargetNode(evnt, container, queryCls, queryMethod) { var targetElem var target2 = evnt.target.shadowRoot && evnt.composed ? evnt.composedPath()[0] || evnt.target : evnt.target while (target2 && target2.nodeType && target2 !== document) { if ( queryCls && hasClass(target2, queryCls) && (!queryMethod || queryMethod(target2)) ) { targetElem = target2 } else if (target2 === container) { return { flag: queryCls ? !!targetElem : true, container, targetElem } } target2 = target2.parentNode } return { flag: false } } function getOffsetPos(elem, container) { return getNodeOffset(elem, container, { left: 0, top: 0 }) } function getAbsolutePos(elem) { var bounding = elem.getBoundingClientRect() var boundingTop = bounding.top var boundingLeft = bounding.left var _a2 = getDomNode(), scrollTop = _a2.scrollTop, scrollLeft = _a2.scrollLeft, visibleHeight = _a2.visibleHeight, visibleWidth = _a2.visibleWidth return { boundingTop, top: scrollTop + boundingTop, boundingLeft, left: scrollLeft + boundingLeft, visibleHeight, visibleWidth, } } var scrollIntoViewIfNeeded = 'scrollIntoViewIfNeeded' var scrollIntoView = 'scrollIntoView' function scrollToView(elem) { if (elem) { if (elem[scrollIntoViewIfNeeded]) { elem[scrollIntoViewIfNeeded]() } else if (elem[scrollIntoView]) { elem[scrollIntoView]() } } } function isNodeElement(elem) { return elem && elem.nodeType === 1 } function restoreScrollLocation($xetable, scrollLeft, scrollTop) { var internalData = $xetable.internalData return $xetable.clearScroll().then(function () { if (scrollLeft || scrollTop) { internalData.lastScrollLeft = 0 internalData.lastScrollTop = 0 return $xetable.scrollTo(scrollLeft, scrollTop) } }) } function removeScrollListener(scrollElem) { if (scrollElem && scrollElem._onscroll) { scrollElem.onscroll = null } } function restoreScrollListener(scrollElem) { if (scrollElem && scrollElem._onscroll) { scrollElem.onscroll = scrollElem._onscroll } } function getRowUniqueId() { return xeUtils.uniqueId('row_') } function getRowkey($xetable) { var props2 = $xetable.props var computeRowOpts = $xetable.getComputeMaps().computeRowOpts var rowId = props2.rowId var rowOpts = computeRowOpts.value return rowId || rowOpts.keyField || '_X_ROW_KEY' } function getRowid($xetable, row) { var rowid = xeUtils.get(row, getRowkey($xetable)) return xeUtils.eqNull(rowid) ? '' : encodeURIComponent(rowid) } var handleFieldOrColumn = function ($xetable, fieldOrColumn) { if (fieldOrColumn) { return xeUtils.isString(fieldOrColumn) ? $xetable.getColumnByField(fieldOrColumn) : fieldOrColumn } return null } function getPaddingLeftRightSize(elem) { if (elem) { var computedStyle = getComputedStyle(elem) var paddingLeft2 = xeUtils.toNumber(computedStyle.paddingLeft) var paddingRight2 = xeUtils.toNumber(computedStyle.paddingRight) return paddingLeft2 + paddingRight2 } return 0 } function getElemenMarginWidth(elem) { if (elem) { var computedStyle = getComputedStyle(elem) var marginLeft2 = xeUtils.toNumber(computedStyle.marginLeft) var marginRight2 = xeUtils.toNumber(computedStyle.marginRight) return elem.offsetWidth + marginLeft2 + marginRight2 } return 0 } function queryCellElement(cell, selector2) { return cell.querySelector('.vxe-cell' + selector2) } function toFilters(filters) { if (filters && xeUtils.isArray(filters)) { return filters.map(function (_a2) { var label = _a2.label, value2 = _a2.value, data2 = _a2.data, resetValue = _a2.resetValue, checked2 = _a2.checked return { label, value: value2, data: data2, resetValue, checked: !!checked2, _checked: !!checked2, } }) } return filters } function toTreePathSeq(path) { return path .map(function (num2, i2) { return i2 % 2 === 0 ? Number(num2) + 1 : '.' }) .join('') } function getCellValue(row, column) { return xeUtils.get(row, column.field) } function setCellValue(row, column, value2) { return xeUtils.set(row, column.field, value2) } function getColReMinWidth(params2) { var $table = params2.$table, column = params2.column, cell = params2.cell var tableProps2 = $table.props var computeResizableOpts = $table.getComputeMaps().computeResizableOpts var resizableOpts = computeResizableOpts.value var reMinWidth = resizableOpts.minWidth if (reMinWidth) { var customMinWidth = xeUtils.isFunction(reMinWidth) ? reMinWidth(params2) : reMinWidth if (customMinWidth !== 'auto') { return Math.max(1, xeUtils.toNumber(customMinWidth)) } } var allColumnHeaderOverflow = tableProps2.showHeaderOverflow var showHeaderOverflow = column.showHeaderOverflow, colMinWidth = column.minWidth var headOverflow = xeUtils.isUndefined(showHeaderOverflow) || xeUtils.isNull(showHeaderOverflow) ? allColumnHeaderOverflow : showHeaderOverflow var showEllipsis = headOverflow === 'ellipsis' var showTitle = headOverflow === 'title' var showTooltip2 = headOverflow === true || headOverflow === 'tooltip' var hasEllipsis = showTitle || showTooltip2 || showEllipsis var minTitleWidth = xeUtils.floor( (xeUtils.toNumber(getComputedStyle(cell).fontSize) || 14) * 1.6 ) var paddingLeftRight = getPaddingLeftRightSize(cell) + getPaddingLeftRightSize(queryCellElement(cell, '')) var mWidth = minTitleWidth + paddingLeftRight if (hasEllipsis) { var checkboxIconWidth = getPaddingLeftRightSize( queryCellElement(cell, '--title>.vxe-cell--checkbox') ) var requiredIconWidth = getElemenMarginWidth( queryCellElement(cell, '>.vxe-cell--required-icon') ) var editIconWidth = getElemenMarginWidth( queryCellElement(cell, '>.vxe-cell--edit-icon') ) var helpIconWidth = getElemenMarginWidth( queryCellElement(cell, '>.vxe-cell-help-icon') ) var sortIconWidth = getElemenMarginWidth( queryCellElement(cell, '>.vxe-cell--sort') ) var filterIconWidth = getElemenMarginWidth( queryCellElement(cell, '>.vxe-cell--filter') ) mWidth += checkboxIconWidth + requiredIconWidth + editIconWidth + helpIconWidth + filterIconWidth + sortIconWidth } if (colMinWidth) { var refTableBody = $table.getRefMaps().refTableBody var tableBody = refTableBody.value var bodyElem = tableBody ? tableBody.$el : null if (bodyElem) { if (isScale(colMinWidth)) { var bodyWidth = bodyElem.clientWidth - 1 var meanWidth = bodyWidth / 100 return Math.max( mWidth, Math.floor(xeUtils.toInteger(colMinWidth) * meanWidth) ) } else if (isPx(colMinWidth)) { return Math.max(mWidth, xeUtils.toInteger(colMinWidth)) } } } return mWidth } function isColumnInfo(column) { return ( column && (column.constructor === ColumnInfo || column instanceof ColumnInfo) ) } function createColumn($xetable, options2, renderOptions) { return isColumnInfo(options2) ? options2 : reactive(new ColumnInfo($xetable, options2, renderOptions)) } function watchColumn($xetable, props2, column) { Object.keys(props2).forEach(function (name2) { watch$1( function () { return props2[name2] }, function (value2) { column.update(name2, value2) if ($xetable) { if (name2 === 'filters') { $xetable.setFilter(column, value2) $xetable.handleUpdateDataQueue() } else if ( ['visible', 'fixed', 'width', 'minWidth', 'maxWidth'].includes( name2 ) ) { $xetable.handleRefreshColumnQueue() } } } ) }) } function assemColumn($xetable, elem, column, colgroup) { var reactData = $xetable.reactData var staticColumns = reactData.staticColumns var parentElem = elem.parentNode var parentColumn = colgroup ? colgroup.column : null var parentCols = parentColumn ? parentColumn.children : staticColumns if (parentElem && parentCols) { parentCols.splice( xeUtils.arrayIndexOf(parentElem.children, elem), 0, column ) reactData.staticColumns = staticColumns.slice(0) } } function destroyColumn($xetable, column) { var reactData = $xetable.reactData var staticColumns = reactData.staticColumns var matchObj = xeUtils.findTree( staticColumns, function (item2) { return item2.id === column.id }, { children: 'children' } ) if (matchObj) { matchObj.items.splice(matchObj.index, 1) } reactData.staticColumns = staticColumns.slice(0) } function getRootColumn($xetable, column) { var internalData = $xetable.internalData var fullColumnIdData = internalData.fullColumnIdData if (!column) { return null } var parentColId = column.parentId while (fullColumnIdData[parentColId]) { var column_1 = fullColumnIdData[parentColId].column parentColId = column_1.parentId if (!parentColId) { return column_1 } } return column } function mergeBodyMethod(mergeList, _rowIndex, _columnIndex) { for (var mIndex = 0; mIndex < mergeList.length; mIndex++) { var _a2 = mergeList[mIndex], mergeRowIndex = _a2.row, mergeColIndex = _a2.col, mergeRowspan = _a2.rowspan, mergeColspan = _a2.colspan if ( mergeColIndex > -1 && mergeRowIndex > -1 && mergeRowspan && mergeColspan ) { if (mergeRowIndex === _rowIndex && mergeColIndex === _columnIndex) { return { rowspan: mergeRowspan, colspan: mergeColspan } } if ( _rowIndex >= mergeRowIndex && _rowIndex < mergeRowIndex + mergeRowspan && _columnIndex >= mergeColIndex && _columnIndex < mergeColIndex + mergeColspan ) { return { rowspan: 0, colspan: 0 } } } } } function clearTableDefaultStatus($xetable) { var props2 = $xetable.props, internalData = $xetable.internalData internalData.initStatus = false $xetable.clearSort() $xetable.clearCurrentRow() $xetable.clearCurrentColumn() $xetable.clearRadioRow() $xetable.clearRadioReserve() $xetable.clearCheckboxRow() $xetable.clearCheckboxReserve() $xetable.clearRowExpand() $xetable.clearTreeExpand() $xetable.clearTreeExpandReserve() if ($xetable.clearFilter) { $xetable.clearFilter() } if ($xetable.clearSelected && (props2.keyboardConfig || props2.mouseConfig)) { $xetable.clearSelected() } if ($xetable.clearCellAreas && props2.mouseConfig) { $xetable.clearCellAreas() $xetable.clearCopyCellArea() } return $xetable.clearScroll() } function clearTableAllStatus($xetable) { if ($xetable.clearFilter) { $xetable.clearFilter() } return clearTableDefaultStatus($xetable) } function rowToVisible($xetable, row) { var reactData = $xetable.reactData, internalData = $xetable.internalData var refTableBody = $xetable.getRefMaps().refTableBody var scrollYLoad = reactData.scrollYLoad var afterFullData = internalData.afterFullData, scrollYStore = internalData.scrollYStore var tableBody = refTableBody.value var bodyElem = tableBody ? tableBody.$el : null if (bodyElem) { var trElem = bodyElem.querySelector( '[rowid="'.concat(getRowid($xetable, row), '"]') ) if (trElem) { var bodyHeight = bodyElem.clientHeight var bodySrcollTop = bodyElem.scrollTop var trOffsetParent = trElem.offsetParent var trOffsetTop = trElem.offsetTop + (trOffsetParent ? trOffsetParent.offsetTop : 0) var trHeight = trElem.clientHeight if ( trOffsetTop < bodySrcollTop || trOffsetTop > bodySrcollTop + bodyHeight ) { return $xetable.scrollTo(null, trOffsetTop) } else if (trOffsetTop + trHeight >= bodyHeight + bodySrcollTop) { return $xetable.scrollTo(null, bodySrcollTop + trHeight) } } else { if (scrollYLoad) { return $xetable.scrollTo( null, (afterFullData.indexOf(row) - 1) * scrollYStore.rowHeight ) } } } return Promise.resolve() } function colToVisible($xetable, column) { var reactData = $xetable.reactData, internalData = $xetable.internalData var refTableBody = $xetable.getRefMaps().refTableBody var scrollXLoad = reactData.scrollXLoad var visibleColumn = internalData.visibleColumn var tableBody = refTableBody.value var bodyElem = tableBody ? tableBody.$el : null if (bodyElem) { var tdElem = bodyElem.querySelector('.'.concat(column.id)) if (tdElem) { var bodyWidth = bodyElem.clientWidth var bodySrcollLeft = bodyElem.scrollLeft var tdOffsetParent = tdElem.offsetParent var tdOffsetLeft = tdElem.offsetLeft + (tdOffsetParent ? tdOffsetParent.offsetLeft : 0) var tdWidth = tdElem.clientWidth if ( tdOffsetLeft < bodySrcollLeft || tdOffsetLeft > bodySrcollLeft + bodyWidth ) { return $xetable.scrollTo(tdOffsetLeft) } else if (tdOffsetLeft + tdWidth >= bodyWidth + bodySrcollLeft) { return $xetable.scrollTo(bodySrcollLeft + tdWidth) } } else { if (scrollXLoad) { var scrollLeft = 0 for (var index2 = 0; index2 < visibleColumn.length; index2++) { if (visibleColumn[index2] === column) { break } scrollLeft += visibleColumn[index2].renderWidth } return $xetable.scrollTo(scrollLeft) } } } return Promise.resolve() } function getOnName(type4) { return 'on' + type4.substring(0, 1).toLocaleUpperCase() + type4.substring(1) } function getSlotVNs(vns) { if (xeUtils.isArray(vns)) { return vns } return [vns] } var __assign$j = (globalThis && globalThis.__assign) || function () { __assign$j = Object.assign || function (t3) { for (var s2, i2 = 1, n2 = arguments.length; i2 < n2; i2++) { s2 = arguments[i2] for (var p2 in s2) if (Object.prototype.hasOwnProperty.call(s2, p2)) t3[p2] = s2[p2] } return t3 } return __assign$j.apply(this, arguments) } var __spreadArray$6 = (globalThis && globalThis.__spreadArray) || function (to, from, pack2) { if (pack2 || arguments.length === 2) for (var i2 = 0, l2 = from.length, ar2; i2 < l2; i2++) { if (ar2 || !(i2 in from)) { if (!ar2) ar2 = Array.prototype.slice.call(from, 0, i2) ar2[i2] = from[i2] } } return to.concat(ar2 || Array.prototype.slice.call(from)) } var componentDefaultModelProp = 'modelValue' var defaultCompProps = { transfer: true } function getModelEvent(renderOpts) { switch (renderOpts.name) { case 'input': case 'textarea': return 'input' } return 'update:modelValue' } function getChangeEvent(renderOpts) { switch (renderOpts.name) { case 'input': case 'textarea': case '$input': case '$textarea': return 'input' } return 'change' } function parseDate$1(value2, props2) { return value2 && props2.valueFormat ? xeUtils.toStringDate(value2, props2.valueFormat) : value2 } function getFormatDate(value2, props2, defaultFormat) { var _a2 = props2.dateConfig, dateConfig = _a2 === void 0 ? {} : _a2 return xeUtils.toDateString( parseDate$1(value2, props2), dateConfig.labelFormat || defaultFormat ) } function getLabelFormatDate(value2, props2) { return getFormatDate( value2, props2, GlobalConfig.i18n('vxe.input.date.labelFormat.'.concat(props2.type)) ) } function getComponentName(name2) { return 'vxe-'.concat(name2.replace('$', '')) } function getDefaultComponent(_a2) { var name2 = _a2.name return resolveComponent(getComponentName(name2)) } function handleConfirmFilter(params2, checked2, option2) { var $panel = params2.$panel $panel.changeOption({}, checked2, option2) } function getNativeAttrs(renderOpts) { var name2 = renderOpts.name, attrs = renderOpts.attrs if (name2 === 'input') { attrs = Object.assign({ type: 'text' }, attrs) } return attrs } function getInputImmediateModel(renderOpts) { var name2 = renderOpts.name, immediate = renderOpts.immediate, props2 = renderOpts.props if (!immediate) { if (name2 === '$input') { var type4 = (props2 || {}).type return !( !type4 || type4 === 'text' || type4 === 'number' || type4 === 'integer' || type4 === 'float' ) } if (name2 === 'input' || name2 === 'textarea' || name2 === '$textarea') { return false } return true } return immediate } function getCellEditProps(renderOpts, params2, value2, defaultProps2) { var _a2 return xeUtils.assign( { immediate: getInputImmediateModel(renderOpts) }, defaultCompProps, defaultProps2, renderOpts.props, ((_a2 = {}), (_a2[componentDefaultModelProp] = value2), _a2) ) } function getCellEditFilterProps(renderOpts, params2, value2, defaultProps2) { var _a2 return xeUtils.assign( {}, defaultCompProps, defaultProps2, renderOpts.props, ((_a2 = {}), (_a2[componentDefaultModelProp] = value2), _a2) ) } function getComponentFormItemProps(renderOpts, params2, value2, defaultProps2) { var _a2 return xeUtils.assign( {}, defaultCompProps, defaultProps2, renderOpts.props, ((_a2 = {}), (_a2[componentDefaultModelProp] = value2), _a2) ) } function isImmediateCell(renderOpts, params2) { return params2.$type === 'cell' || getInputImmediateModel(renderOpts) } function getCellLabelVNs(renderOpts, params2, cellLabel) { var placeholder = renderOpts.placeholder return [ h$4( 'span', { class: 'vxe-cell--label', }, placeholder && isEmptyValue$1(cellLabel) ? [ h$4( 'span', { class: 'vxe-cell--placeholder', }, formatText(getFuncText(placeholder), 1) ), ] : formatText(cellLabel, 1) ), ] } function getElementOns(renderOpts, params2, modelFunc, changeFunc) { var events2 = renderOpts.events var modelEvent = getModelEvent(renderOpts) var changeEvent = getChangeEvent(renderOpts) var isSameEvent = changeEvent === modelEvent var ons = {} if (events2) { xeUtils.objectEach(events2, function (func, key2) { ons[getOnName(key2)] = function () { var args = [] for (var _i = 0; _i < arguments.length; _i++) { args[_i] = arguments[_i] } func.apply(void 0, __spreadArray$6([params2], args, false)) } }) } if (modelFunc) { ons[getOnName(modelEvent)] = function (targetEvnt) { modelFunc(targetEvnt) if (isSameEvent && changeFunc) { changeFunc(targetEvnt) } if (events2 && events2[modelEvent]) { events2[modelEvent](params2, targetEvnt) } } } if (!isSameEvent && changeFunc) { ons[getOnName(changeEvent)] = function () { var args = [] for (var _i = 0; _i < arguments.length; _i++) { args[_i] = arguments[_i] } changeFunc.apply(void 0, args) if (events2 && events2[changeEvent]) { events2[changeEvent].apply( events2, __spreadArray$6([params2], args, false) ) } } } return ons } function getComponentOns(renderOpts, params2, modelFunc, changeFunc) { var events2 = renderOpts.events var modelEvent = getModelEvent(renderOpts) var changeEvent = getChangeEvent(renderOpts) var ons = {} xeUtils.objectEach(events2, function (func, key2) { ons[getOnName(key2)] = function () { var args = [] for (var _i = 0; _i < arguments.length; _i++) { args[_i] = arguments[_i] } func.apply(void 0, __spreadArray$6([params2], args, false)) } }) if (modelFunc) { ons[getOnName(modelEvent)] = function (targetEvnt) { modelFunc(targetEvnt) if (events2 && events2[modelEvent]) { events2[modelEvent](params2, targetEvnt) } } } if (changeFunc) { ons[getOnName(changeEvent)] = function () { var args = [] for (var _i = 0; _i < arguments.length; _i++) { args[_i] = arguments[_i] } changeFunc.apply(void 0, args) if (events2 && events2[changeEvent]) { events2[changeEvent].apply( events2, __spreadArray$6([params2], args, false) ) } } } return ons } function getEditOns(renderOpts, params2) { var $table = params2.$table, row = params2.row, column = params2.column var name2 = renderOpts.name var model = column.model var isImmediate = isImmediateCell(renderOpts, params2) return getComponentOns( renderOpts, params2, function (cellValue) { if (isImmediate) { setCellValue(row, column, cellValue) } else { model.update = true model.value = cellValue } }, function (eventParams) { if (!isImmediate && (name2 === '$input' || name2 === '$textarea')) { var cellValue = eventParams.value model.update = true model.value = cellValue $table.updateStatus(params2, cellValue) } else { $table.updateStatus(params2) } } ) } function getFilterOns(renderOpts, params2, option2) { return getComponentOns( renderOpts, params2, function (value2) { option2.data = value2 }, function () { handleConfirmFilter(params2, !xeUtils.eqNull(option2.data), option2) } ) } function getItemOns(renderOpts, params2) { var $form = params2.$form, data2 = params2.data, property2 = params2.property return getComponentOns( renderOpts, params2, function (value2) { xeUtils.set(data2, property2, value2) }, function () { $form.updateStatus(params2) } ) } function getNativeEditOns(renderOpts, params2) { var $table = params2.$table, row = params2.row, column = params2.column var model = column.model return getElementOns( renderOpts, params2, function (evnt) { var cellValue = evnt.target.value if (isImmediateCell(renderOpts, params2)) { setCellValue(row, column, cellValue) } else { model.update = true model.value = cellValue } }, function (evnt) { var cellValue = evnt.target.value $table.updateStatus(params2, cellValue) } ) } function getNativeFilterOns(renderOpts, params2, option2) { return getElementOns( renderOpts, params2, function (evnt) { option2.data = evnt.target.value }, function () { handleConfirmFilter(params2, !xeUtils.eqNull(option2.data), option2) } ) } function getNativeItemOns(renderOpts, params2) { var $form = params2.$form, data2 = params2.data, property2 = params2.property return getElementOns( renderOpts, params2, function (evnt) { var itemValue = evnt.target.value xeUtils.set(data2, property2, itemValue) }, function () { $form.updateStatus(params2) } ) } function nativeEditRender(renderOpts, params2) { var row = params2.row, column = params2.column var name2 = renderOpts.name var cellValue = isImmediateCell(renderOpts, params2) ? getCellValue(row, column) : column.model.value return [ h$4( name2, __assign$j( __assign$j( __assign$j( { class: 'vxe-default-'.concat(name2) }, getNativeAttrs(renderOpts) ), { value: cellValue } ), getNativeEditOns(renderOpts, params2) ) ), ] } function defaultEditRender(renderOpts, params2) { var row = params2.row, column = params2.column var cellValue = getCellValue(row, column) return [ h$4( getDefaultComponent(renderOpts), __assign$j( __assign$j({}, getCellEditProps(renderOpts, params2, cellValue)), getEditOns(renderOpts, params2) ) ), ] } function defaultButtonEditRender(renderOpts, params2) { return [ h$4( resolveComponent('vxe-button'), __assign$j( __assign$j({}, getCellEditProps(renderOpts, params2, null)), getComponentOns(renderOpts, params2) ) ), ] } function defaultButtonsEditRender(renderOpts, params2) { return renderOpts.children.map(function (childRenderOpts) { return defaultButtonEditRender(childRenderOpts, params2)[0] }) } function renderNativeOptgroups(renderOpts, params2, renderOptionsMethods) { var optionGroups = renderOpts.optionGroups, _a2 = renderOpts.optionGroupProps, optionGroupProps = _a2 === void 0 ? {} : _a2 var groupOptions = optionGroupProps.options || 'options' var groupLabel = optionGroupProps.label || 'label' return optionGroups.map(function (group, gIndex) { return h$4( 'optgroup', { key: gIndex, label: group[groupLabel], }, renderOptionsMethods(group[groupOptions], renderOpts, params2) ) }) } function renderNativeOptions(options2, renderOpts, params2) { var _a2 = renderOpts.optionProps, optionProps = _a2 === void 0 ? {} : _a2 var row = params2.row, column = params2.column var labelProp = optionProps.label || 'label' var valueProp = optionProps.value || 'value' var disabledProp = optionProps.disabled || 'disabled' var cellValue = isImmediateCell(renderOpts, params2) ? getCellValue(row, column) : column.model.value return options2.map(function (option2, oIndex) { return h$4( 'option', { key: oIndex, value: option2[valueProp], disabled: option2[disabledProp], selected: option2[valueProp] == cellValue, }, option2[labelProp] ) }) } function nativeFilterRender(renderOpts, params2) { var column = params2.column var name2 = renderOpts.name var attrs = getNativeAttrs(renderOpts) return column.filters.map(function (option2, oIndex) { return h$4( name2, __assign$j( __assign$j( __assign$j( { key: oIndex, class: 'vxe-default-'.concat(name2) }, attrs ), { value: option2.data } ), getNativeFilterOns(renderOpts, params2, option2) ) ) }) } function defaultFilterRender(renderOpts, params2) { var column = params2.column return column.filters.map(function (option2, oIndex) { var optionValue = option2.data return h$4( getDefaultComponent(renderOpts), __assign$j( __assign$j( { key: oIndex }, getCellEditFilterProps(renderOpts, renderOpts, optionValue) ), getFilterOns(renderOpts, params2, option2) ) ) }) } function handleFilterMethod(_a2) { var option2 = _a2.option, row = _a2.row, column = _a2.column var data2 = option2.data var cellValue = xeUtils.get(row, column.property) return cellValue == data2 } function nativeSelectEditRender(renderOpts, params2) { return [ h$4( 'select', __assign$j( __assign$j({ class: 'vxe-default-select' }, getNativeAttrs(renderOpts)), getNativeEditOns(renderOpts, params2) ), renderOpts.optionGroups ? renderNativeOptgroups(renderOpts, params2, renderNativeOptions) : renderNativeOptions(renderOpts.options, renderOpts, params2) ), ] } function defaultSelectEditRender(renderOpts, params2) { var row = params2.row, column = params2.column var options2 = renderOpts.options, optionProps = renderOpts.optionProps, optionGroups = renderOpts.optionGroups, optionGroupProps = renderOpts.optionGroupProps var cellValue = getCellValue(row, column) return [ h$4( getDefaultComponent(renderOpts), __assign$j( __assign$j( {}, getCellEditProps(renderOpts, params2, cellValue, { options: options2, optionProps, optionGroups, optionGroupProps, }) ), getEditOns(renderOpts, params2) ) ), ] } function getSelectCellValue(renderOpts, _a2) { var row = _a2.row, column = _a2.column var _b2 = renderOpts.props, props2 = _b2 === void 0 ? {} : _b2, options2 = renderOpts.options, optionGroups = renderOpts.optionGroups, _c2 = renderOpts.optionProps, optionProps = _c2 === void 0 ? {} : _c2, _d = renderOpts.optionGroupProps, optionGroupProps = _d === void 0 ? {} : _d var cellValue = xeUtils.get(row, column.property) var selectItem var labelProp = optionProps.label || 'label' var valueProp = optionProps.value || 'value' if (!isEmptyValue$1(cellValue)) { return xeUtils .map( props2.multiple ? cellValue : [cellValue], optionGroups ? function (value2) { var groupOptions = optionGroupProps.options || 'options' for (var index2 = 0; index2 < optionGroups.length; index2++) { selectItem = xeUtils.find( optionGroups[index2][groupOptions], function (item2) { return item2[valueProp] == value2 } ) if (selectItem) { break } } return selectItem ? selectItem[labelProp] : value2 } : function (value2) { selectItem = xeUtils.find(options2, function (item2) { return item2[valueProp] == value2 }) return selectItem ? selectItem[labelProp] : value2 } ) .join(', ') } return '' } function nativeItemRender(renderOpts, params2) { var data2 = params2.data, property2 = params2.property var name2 = renderOpts.name var attrs = getNativeAttrs(renderOpts) var itemValue = xeUtils.get(data2, property2) return [ h$4( name2, __assign$j( __assign$j(__assign$j({ class: 'vxe-default-'.concat(name2) }, attrs), { value: attrs && name2 === 'input' && (attrs.type === 'submit' || attrs.type === 'reset') ? null : itemValue, }), getNativeItemOns(renderOpts, params2) ) ), ] } function defaultItemRender(renderOpts, params2) { var data2 = params2.data, property2 = params2.property var itemValue = xeUtils.get(data2, property2) return [ h$4( getDefaultComponent(renderOpts), __assign$j( __assign$j( {}, getComponentFormItemProps(renderOpts, params2, itemValue) ), getItemOns(renderOpts, params2) ) ), ] } function defaultButtonItemRender(renderOpts, params2) { return [ h$4( resolveComponent('vxe-button'), __assign$j( __assign$j({}, getComponentFormItemProps(renderOpts, params2, null)), getComponentOns(renderOpts, params2) ) ), ] } function defaultButtonsItemRender(renderOpts, params2) { return renderOpts.children.map(function (childRenderOpts) { return defaultButtonItemRender(childRenderOpts, params2)[0] }) } function renderNativeFormOptions(options2, renderOpts, params2) { var data2 = params2.data, property2 = params2.property var _a2 = renderOpts.optionProps, optionProps = _a2 === void 0 ? {} : _a2 var labelProp = optionProps.label || 'label' var valueProp = optionProps.value || 'value' var disabledProp = optionProps.disabled || 'disabled' var cellValue = xeUtils.get(data2, property2) return options2.map(function (item2, oIndex) { return h$4( 'option', { key: oIndex, value: item2[valueProp], disabled: item2[disabledProp], selected: item2[valueProp] == cellValue, }, item2[labelProp] ) }) } function handleExportSelectMethod(params2) { var row = params2.row, column = params2.column, options2 = params2.options return options2.original ? getCellValue(row, column) : getSelectCellValue(column.editRender || column.cellRender, params2) } function defaultFormItemRadioAndCheckboxRender(renderOpts, params2) { var name2 = renderOpts.name, options2 = renderOpts.options, _a2 = renderOpts.optionProps, optionProps = _a2 === void 0 ? {} : _a2 var data2 = params2.data, property2 = params2.property var labelProp = optionProps.label || 'label' var valueProp = optionProps.value || 'value' var disabledProp = optionProps.disabled || 'disabled' var itemValue = xeUtils.get(data2, property2) var compName = getComponentName(name2) if (options2) { return [ h$4( resolveComponent(''.concat(compName, '-group')), __assign$j( __assign$j( {}, getComponentFormItemProps(renderOpts, params2, itemValue) ), getItemOns(renderOpts, params2) ), { default: function () { return options2.map(function (item2, index2) { return h$4(resolveComponent(compName), { key: index2, label: item2[valueProp], content: item2[labelProp], disabled: item2[disabledProp], }) }) }, } ), ] } return [ h$4( resolveComponent(compName), __assign$j( __assign$j( {}, getComponentFormItemProps(renderOpts, params2, itemValue) ), getItemOns(renderOpts, params2) ) ), ] } var renderMap = { input: { autofocus: 'input', renderEdit: nativeEditRender, renderDefault: nativeEditRender, renderFilter: nativeFilterRender, defaultFilterMethod: handleFilterMethod, renderItemContent: nativeItemRender, }, textarea: { autofocus: 'textarea', renderEdit: nativeEditRender, renderItemContent: nativeItemRender, }, select: { renderEdit: nativeSelectEditRender, renderDefault: nativeSelectEditRender, renderCell: function (renderOpts, params2) { return getCellLabelVNs( renderOpts, params2, getSelectCellValue(renderOpts, params2) ) }, renderFilter: function (renderOpts, params2) { var column = params2.column return column.filters.map(function (option2, oIndex) { return h$4( 'select', __assign$j( __assign$j( { key: oIndex, class: 'vxe-default-select' }, getNativeAttrs(renderOpts) ), getNativeFilterOns(renderOpts, params2, option2) ), renderOpts.optionGroups ? renderNativeOptgroups(renderOpts, params2, renderNativeOptions) : renderNativeOptions(renderOpts.options, renderOpts, params2) ) }) }, defaultFilterMethod: handleFilterMethod, renderItemContent: function (renderOpts, params2) { return [ h$4( 'select', __assign$j( __assign$j( { class: 'vxe-default-select' }, getNativeAttrs(renderOpts) ), getNativeItemOns(renderOpts, params2) ), renderOpts.optionGroups ? renderNativeOptgroups( renderOpts, params2, renderNativeFormOptions ) : renderNativeFormOptions(renderOpts.options, renderOpts, params2) ), ] }, cellExportMethod: handleExportSelectMethod, }, $input: { autofocus: '.vxe-input--inner', renderEdit: defaultEditRender, renderCell: function (renderOpts, params2) { var _a2 = renderOpts.props, props2 = _a2 === void 0 ? {} : _a2 var row = params2.row, column = params2.column var digits = props2.digits || GlobalConfig.input.digits var cellValue = xeUtils.get(row, column.property) if (cellValue) { switch (props2.type) { case 'date': case 'week': case 'month': case 'year': cellValue = getLabelFormatDate(cellValue, props2) break case 'float': cellValue = xeUtils.toFixed( xeUtils.floor(cellValue, digits), digits ) break } } return getCellLabelVNs(renderOpts, params2, cellValue) }, renderDefault: defaultEditRender, renderFilter: defaultFilterRender, defaultFilterMethod: handleFilterMethod, renderItemContent: defaultItemRender, }, $textarea: { autofocus: '.vxe-textarea--inner', renderItemContent: defaultItemRender, }, $button: { renderDefault: defaultButtonEditRender, renderItemContent: defaultButtonItemRender, }, $buttons: { renderDefault: defaultButtonsEditRender, renderItemContent: defaultButtonsItemRender, }, $select: { autofocus: '.vxe-input--inner', renderEdit: defaultSelectEditRender, renderDefault: defaultSelectEditRender, renderCell: function (renderOpts, params2) { return getCellLabelVNs( renderOpts, params2, getSelectCellValue(renderOpts, params2) ) }, renderFilter: function (renderOpts, params2) { var column = params2.column var options2 = renderOpts.options, optionProps = renderOpts.optionProps, optionGroups = renderOpts.optionGroups, optionGroupProps = renderOpts.optionGroupProps return column.filters.map(function (option2, oIndex) { var optionValue = option2.data return h$4( getDefaultComponent(renderOpts), __assign$j( __assign$j( { key: oIndex }, getCellEditFilterProps(renderOpts, params2, optionValue, { options: options2, optionProps, optionGroups, optionGroupProps, }) ), getFilterOns(renderOpts, params2, option2) ) ) }) }, defaultFilterMethod: handleFilterMethod, renderItemContent: function (renderOpts, params2) { var data2 = params2.data, property2 = params2.property var options2 = renderOpts.options, optionProps = renderOpts.optionProps, optionGroups = renderOpts.optionGroups, optionGroupProps = renderOpts.optionGroupProps var itemValue = xeUtils.get(data2, property2) return [ h$4( getDefaultComponent(renderOpts), __assign$j( __assign$j( {}, getComponentFormItemProps(renderOpts, params2, itemValue, { options: options2, optionProps, optionGroups, optionGroupProps, }) ), getItemOns(renderOpts, params2) ) ), ] }, cellExportMethod: handleExportSelectMethod, }, $radio: { autofocus: '.vxe-radio--input', renderItemContent: defaultFormItemRadioAndCheckboxRender, }, $checkbox: { autofocus: '.vxe-checkbox--input', renderItemContent: defaultFormItemRadioAndCheckboxRender, }, $switch: { autofocus: '.vxe-switch--button', renderEdit: defaultEditRender, renderDefault: defaultEditRender, renderItemContent: defaultItemRender, }, } var renderer = { mixin: function (opts) { xeUtils.each(opts, function (options2, name2) { return renderer.add(name2, options2) }) return renderer }, get: function (name2) { return renderMap[name2] || null }, add: function (name2, options2) { if (name2 && options2) { var renders_1 = renderMap[name2] if (renders_1) { Object.assign(renders_1, options2) } else { renderMap[name2] = options2 } } return renderer }, delete: function (name2) { delete renderMap[name2] return renderer }, } var VXECommandsStore = (function () { function VXECommandsStore2() { this.store = {} } VXECommandsStore2.prototype.mixin = function (options2) { var _this = this xeUtils.each(options2, function (item2, key2) { _this.add(key2, item2) }) return this } VXECommandsStore2.prototype.has = function (name2) { return !!this.get(name2) } VXECommandsStore2.prototype.get = function (name2) { return this.store[name2] } VXECommandsStore2.prototype.add = function (name2, render2) { var conf = this.store[name2] if (xeUtils.isFunction(render2)) { render2 = { commandMethod: render2, } } this.store[name2] = conf ? xeUtils.merge(conf, render2) : render2 return this } VXECommandsStore2.prototype.delete = function (name2) { delete this.store[name2] } VXECommandsStore2.prototype.forEach = function (callback) { xeUtils.objectEach(this.store, callback) } return VXECommandsStore2 })() var commands = new VXECommandsStore() var VXEMenusStore = (function () { function VXEMenusStore2() { this.store = {} } VXEMenusStore2.prototype.mixin = function (options2) { var _this = this xeUtils.each(options2, function (item2, key2) { _this.add(key2, item2) }) return this } VXEMenusStore2.prototype.has = function (name2) { return !!this.get(name2) } VXEMenusStore2.prototype.get = function (name2) { return this.store[name2] } VXEMenusStore2.prototype.add = function (name2, render2) { var conf = this.store[name2] if (xeUtils.isFunction(render2)) { render2 = { menuMethod: render2, } } this.store[name2] = conf ? xeUtils.merge(conf, render2) : render2 return this } VXEMenusStore2.prototype.delete = function (name2) { delete this.store[name2] } VXEMenusStore2.prototype.forEach = function (callback) { xeUtils.objectEach(this.store, callback) } return VXEMenusStore2 })() var menus = new VXEMenusStore() var Store = (function () { function Store3() { this.store = {} } Store3.prototype.mixin = function (options2) { var _this = this xeUtils.each(options2, function (item2, key2) { _this.add(key2, item2) }) return this } Store3.prototype.has = function (name2) { return !!this.get(name2) } Store3.prototype.get = function (name2) { return this.store[name2] } Store3.prototype.add = function (name2, render2) { var conf = this.store[name2] this.store[name2] = conf ? xeUtils.merge(conf, render2) : render2 return this } Store3.prototype.delete = function (name2) { delete this.store[name2] } Store3.prototype.forEach = function (callback) { xeUtils.objectEach(this.store, callback) } return Store3 })() var validators = new Store() var hooks = new Store() var config$X = function (options2) { if (options2 && options2.zIndex) { DomZIndex.setCurrent(options2.zIndex) } return xeUtils.merge(GlobalConfig, options2) } function getExportOrImpotType(types2, flag2) { var rest = [] xeUtils.objectEach(types2, function (val2, type4) { if (val2 === 0 || val2 === flag2) { rest.push(type4) } }) return rest } var installedPlugins = [] function use$1(Plugin, options2) { if (Plugin && Plugin.install) { if (installedPlugins.indexOf(Plugin) === -1) { Plugin.install(VXETable, options2) installedPlugins.push(Plugin) } } return VXETable } function t$4(key2, args) { return GlobalConfig.i18n(key2, args) } function _t$1(key2, args) { return key2 ? xeUtils.toValueString( GlobalConfig.translate ? GlobalConfig.translate(key2, args) : key2 ) : '' } var VXETableConfig = (function () { function VXETableConfig2() {} Object.defineProperty(VXETableConfig2.prototype, 'zIndex', { get: function () { return getLastZIndex() }, enumerable: false, configurable: true, }) Object.defineProperty(VXETableConfig2.prototype, 'nextZIndex', { get: function () { return nextZIndex() }, enumerable: false, configurable: true, }) Object.defineProperty(VXETableConfig2.prototype, 'exportTypes', { get: function () { return getExportOrImpotType(GlobalConfig.export.types, 1) }, enumerable: false, configurable: true, }) Object.defineProperty(VXETableConfig2.prototype, 'importTypes', { get: function () { return getExportOrImpotType(GlobalConfig.export.types, 2) }, enumerable: false, configurable: true, }) return VXETableConfig2 })() var globalConfs = new VXETableConfig() var v$1 = 'v4' var setup = config$X var globalStore = {} var VXETable = { v: v$1, version: '4.5.12', setup, globalStore, interceptor, renderer, commands, formats, validators, menus, hooks, use: use$1, t: t$4, _t: _t$1, config: config$X, globalConfs, } var PanelComponent$1 = defineComponent({ name: 'VxeTableFilter', props: { filterStore: Object, }, setup: function (props2) { var $xetable = inject('$xetable', {}) var tableReactData = $xetable.reactData, tableInternalData = $xetable.internalData var computeHasCheckOption = computed(function () { var filterStore = props2.filterStore return ( filterStore && filterStore.options.some(function (option2) { return option2.checked }) ) }) var filterCheckAllEvent = function (evnt, value2) { var filterStore = props2.filterStore filterStore.options.forEach(function (option2) { option2._checked = value2 option2.checked = value2 }) filterStore.isAllSelected = value2 filterStore.isIndeterminate = false } var confirmFilter = function (evnt) { var filterStore = props2.filterStore filterStore.options.forEach(function (option2) { option2.checked = option2._checked }) $xetable.confirmFilterEvent(evnt) } var changeRadioOption = function (evnt, checked2, item2) { var filterStore = props2.filterStore filterStore.options.forEach(function (option2) { option2._checked = false }) item2._checked = checked2 $xetable.checkFilterOptions() confirmFilter(evnt) } var resetFilter = function (evnt) { var filterStore = props2.filterStore $xetable.handleClearFilter(filterStore.column) $xetable.confirmFilterEvent(evnt) } var changeMultipleOption = function (evnt, checked2, item2) { item2._checked = checked2 $xetable.checkFilterOptions() } var changeOption = function (evnt, checked2, item2) { var filterStore = props2.filterStore if (filterStore.multiple) { changeMultipleOption(evnt, checked2, item2) } else { changeRadioOption(evnt, checked2, item2) } } var changeAllOption = function (evnt, checked2) { var filterStore = props2.filterStore if (filterStore.multiple) { filterCheckAllEvent(evnt, checked2) } else { resetFilter(evnt) } } var $panel = { changeRadioOption, changeMultipleOption, changeAllOption, changeOption, confirmFilter, resetFilter, } var renderOptions = function (filterRender, compConf) { var filterStore = props2.filterStore var column = filterStore.column, multiple = filterStore.multiple, maxHeight = filterStore.maxHeight var slots = column.slots var filterSlot = slots ? slots.filter : null var params2 = Object.assign({}, tableInternalData._currFilterParams, { $panel, $table: $xetable, }) if (filterSlot) { return [ h$4( 'div', { class: 'vxe-table--filter-template', }, $xetable.callSlot(filterSlot, params2) ), ] } else if (compConf && compConf.renderFilter) { return [ h$4( 'div', { class: 'vxe-table--filter-template', }, getSlotVNs(compConf.renderFilter(filterRender, params2)) ), ] } var isAllChecked = multiple ? filterStore.isAllSelected : !filterStore.options.some(function (item2) { return item2._checked }) var isAllIndeterminate = multiple && filterStore.isIndeterminate return [ h$4( 'ul', { class: 'vxe-table--filter-header', }, [ h$4( 'li', { class: [ 'vxe-table--filter-option', { 'is--checked': isAllChecked, 'is--indeterminate': isAllIndeterminate, }, ], title: GlobalConfig.i18n( multiple ? 'vxe.table.allTitle' : 'vxe.table.allFilter' ), onClick: function (evnt) { changeAllOption(evnt, !filterStore.isAllSelected) }, }, (multiple ? [ h$4('span', { class: [ 'vxe-checkbox--icon', isAllIndeterminate ? GlobalConfig.icon.TABLE_CHECKBOX_INDETERMINATE : isAllChecked ? GlobalConfig.icon.TABLE_CHECKBOX_CHECKED : GlobalConfig.icon.TABLE_CHECKBOX_UNCHECKED, ], }), ] : [] ).concat([ h$4( 'span', { class: 'vxe-checkbox--label', }, GlobalConfig.i18n('vxe.table.allFilter') ), ]) ), ] ), h$4( 'ul', { class: 'vxe-table--filter-body', style: maxHeight ? { maxHeight: ''.concat(maxHeight, 'px'), } : {}, }, filterStore.options.map(function (item2) { var isChecked = item2._checked return h$4( 'li', { class: [ 'vxe-table--filter-option', { 'is--checked': item2._checked, }, ], title: item2.label, onClick: function (evnt) { changeOption(evnt, !item2._checked, item2) }, }, (multiple ? [ h$4('span', { class: [ 'vxe-checkbox--icon', isChecked ? GlobalConfig.icon.TABLE_CHECKBOX_CHECKED : GlobalConfig.icon.TABLE_CHECKBOX_UNCHECKED, ], }), ] : [] ).concat([ h$4( 'span', { class: 'vxe-checkbox--label', }, formatText(item2.label, 1) ), ]) ) }) ), ] } var renderFooters = function () { var filterStore = props2.filterStore var column = filterStore.column, multiple = filterStore.multiple var hasCheckOption = computeHasCheckOption.value var filterRender = column.filterRender var compConf = filterRender ? VXETable.renderer.get(filterRender.name) : null var isDisabled = !hasCheckOption && !filterStore.isAllSelected && !filterStore.isIndeterminate return multiple && (!compConf || compConf.showFilterFooter !== false) ? [ h$4( 'div', { class: 'vxe-table--filter-footer', }, [ h$4( 'button', { class: { 'is--disabled': isDisabled, }, disabled: isDisabled, onClick: confirmFilter, }, GlobalConfig.i18n('vxe.table.confirmFilter') ), h$4( 'button', { onClick: resetFilter, }, GlobalConfig.i18n('vxe.table.resetFilter') ), ] ), ] : [] } var renderVN = function () { var filterStore = props2.filterStore var initStore = tableReactData.initStore var column = filterStore.column var filterRender = column ? column.filterRender : null var compConf = filterRender ? VXETable.renderer.get(filterRender.name) : null var filterClassName = compConf ? compConf.filterClassName : '' var params2 = Object.assign({}, tableInternalData._currFilterParams, { $panel, $table: $xetable, }) return h$4( 'div', { class: [ 'vxe-table--filter-wrapper', 'filter--prevent-default', getPropClass(filterClassName, params2), { 'is--animat': $xetable.props.animat, 'is--multiple': filterStore.multiple, 'is--active': filterStore.visible, }, ], style: filterStore.style, }, initStore.filter && filterStore.visible ? renderOptions(filterRender, compConf).concat(renderFooters()) : [] ) } return renderVN }, }) var __assign$i = (globalThis && globalThis.__assign) || function () { __assign$i = Object.assign || function (t3) { for (var s2, i2 = 1, n2 = arguments.length; i2 < n2; i2++) { s2 = arguments[i2] for (var p2 in s2) if (Object.prototype.hasOwnProperty.call(s2, p2)) t3[p2] = s2[p2] } return t3 } return __assign$i.apply(this, arguments) } var dynamicContainerElem var dynamicStore = reactive({ modals: [], }) var VxeDynamics = defineComponent({ setup: function () { return function () { var modals = dynamicStore.modals return h$4( 'div', { class: 'vxe-dynamics--modal', }, modals.map(function (item2) { return h$4(resolveComponent('vxe-modal'), item2) }) ) } }, }) var dynamicApp = createApp$1(VxeDynamics) function checkDynamic() { if (!dynamicContainerElem) { dynamicContainerElem = document.createElement('div') dynamicContainerElem.className = 'vxe-dynamics' document.body.appendChild(dynamicContainerElem) dynamicApp.mount(dynamicContainerElem) } } dynamicApp.component(PanelComponent$1.name, PanelComponent$1) var PanelComponent = defineComponent({ name: 'VxeTableContextMenu', setup: function (props2, context2) { var xID = xeUtils.uniqueId() var $xetable = inject('$xetable', {}) var tableReactData = $xetable.reactData var refElem = ref() var refMaps = { refElem, } var $xemenupanel = { xID, props: props2, context: context2, getRefMaps: function () { return refMaps }, } var renderVN = function () { var ctxMenuStore = tableReactData.ctxMenuStore var computeMenuOpts = $xetable.getComputeMaps().computeMenuOpts var menuOpts = computeMenuOpts.value return h$4( Teleport, { to: 'body', disabled: false, }, [ h$4( 'div', { ref: refElem, class: [ 'vxe-table--context-menu-wrapper', menuOpts.className, { 'is--visible': ctxMenuStore.visible, }, ], style: ctxMenuStore.style, }, ctxMenuStore.list.map(function (options2, gIndex) { return options2.every(function (item2) { return item2.visible === false }) ? createCommentVNode() : h$4( 'ul', { class: 'vxe-context-menu--option-wrapper', key: gIndex, }, options2.map(function (item2, index2) { var hasChildMenus = item2.children && item2.children.some(function (child) { return child.visible !== false }) return item2.visible === false ? null : h$4( 'li', { class: [ item2.className, { 'link--disabled': item2.disabled, 'link--active': item2 === ctxMenuStore.selected, }, ], key: ''.concat(gIndex, '_').concat(index2), }, [ h$4( 'a', { class: 'vxe-context-menu--link', onClick: function (evnt) { $xetable.ctxMenuLinkEvent(evnt, item2) }, onMouseover: function (evnt) { $xetable.ctxMenuMouseoverEvent(evnt, item2) }, onMouseout: function (evnt) { $xetable.ctxMenuMouseoutEvent(evnt, item2) }, }, [ h$4('i', { class: [ 'vxe-context-menu--link-prefix', item2.prefixIcon, ], }), h$4( 'span', { class: 'vxe-context-menu--link-content', }, getFuncText(item2.name) ), h$4('i', { class: [ 'vxe-context-menu--link-suffix', hasChildMenus ? item2.suffixIcon || 'suffix--haschild' : item2.suffixIcon, ], }), ] ), hasChildMenus ? h$4( 'ul', { class: [ 'vxe-table--context-menu-clild-wrapper', { 'is--show': item2 === ctxMenuStore.selected && ctxMenuStore.showChild, }, ], }, item2.children.map(function ( child, cIndex ) { return child.visible === false ? null : h$4( 'li', { class: [ child.className, { 'link--disabled': child.disabled, 'link--active': child === ctxMenuStore.selectChild, }, ], key: '' .concat(gIndex, '_') .concat(index2, '_') .concat(cIndex), }, [ h$4( 'a', { class: 'vxe-context-menu--link', onClick: function (evnt) { $xetable.ctxMenuLinkEvent( evnt, child ) }, onMouseover: function (evnt) { $xetable.ctxMenuMouseoverEvent( evnt, item2, child ) }, onMouseout: function (evnt) { $xetable.ctxMenuMouseoutEvent( evnt, item2 ) }, }, [ h$4('i', { class: [ 'vxe-context-menu--link-prefix', child.prefixIcon, ], }), h$4( 'span', { class: 'vxe-context-menu--link-content', }, getFuncText(child.name) ), ] ), ] ) }) ) : null, ] ) }) ) }) ), ] ) } $xemenupanel.renderVN = renderVN return $xemenupanel }, render: function () { return this.renderVN() }, }) var EVENT_KEYS = { F2: 'F2', ESCAPE: 'Escape', ENTER: 'Enter', TAB: 'Tab', DELETE: 'Delete', BACKSPACE: 'Backspace', SPACEBAR: ' ', CONTEXT_MENU: 'ContextMenu', ARROW_UP: 'ArrowUp', ARROW_DOWN: 'ArrowDown', ARROW_LEFT: 'ArrowLeft', ARROW_RIGHT: 'ArrowRight', PAGE_UP: 'PageUp', PAGE_DOWN: 'PageDown', } var convertEventKeys = { ' ': 'Spacebar', Apps: EVENT_KEYS.CONTEXT_MENU, Del: EVENT_KEYS.DELETE, Up: EVENT_KEYS.ARROW_UP, Down: EVENT_KEYS.ARROW_DOWN, Left: EVENT_KEYS.ARROW_LEFT, Right: EVENT_KEYS.ARROW_RIGHT, } var wheelName = browse.firefox ? 'DOMMouseScroll' : 'mousewheel' var eventStore$1 = [] var hasEventKey = function (evnt, targetKey) { var key2 = evnt.key targetKey = targetKey.toLowerCase() return key2 ? targetKey === key2.toLowerCase() || !!( convertEventKeys[key2] && convertEventKeys[key2].toLowerCase() === targetKey ) : false } function triggerEvent(evnt) { var isWheel = evnt.type === wheelName eventStore$1.forEach(function (_a2) { var type4 = _a2.type, cb = _a2.cb if (!evnt.cancelBubble) { if (type4 === evnt.type || (isWheel && type4 === 'mousewheel')) { cb(evnt) } } }) } var GlobalEvent = { on: function (comp, type4, cb) { eventStore$1.push({ comp, type: type4, cb }) }, off: function (comp, type4) { xeUtils.remove(eventStore$1, function (item2) { return item2.comp === comp && item2.type === type4 }) }, trigger: triggerEvent, eqKeypad: function (evnt, keyVal) { var key2 = evnt.key if (keyVal.toLowerCase() === key2.toLowerCase()) { return true } return false }, } if (browse.isDoc) { if (!browse.msie) { document.addEventListener('copy', triggerEvent, false) document.addEventListener('cut', triggerEvent, false) document.addEventListener('paste', triggerEvent, false) } document.addEventListener('keydown', triggerEvent, false) document.addEventListener('contextmenu', triggerEvent, false) window.addEventListener('mousedown', triggerEvent, false) window.addEventListener('blur', triggerEvent, false) window.addEventListener('resize', triggerEvent, false) window.addEventListener( wheelName, xeUtils.throttle(triggerEvent, 100, { leading: true, trailing: false }), { passive: true, capture: false } ) } var __assign$h = (globalThis && globalThis.__assign) || function () { __assign$h = Object.assign || function (t3) { for (var s2, i2 = 1, n2 = arguments.length; i2 < n2; i2++) { s2 = arguments[i2] for (var p2 in s2) if (Object.prototype.hasOwnProperty.call(s2, p2)) t3[p2] = s2[p2] } return t3 } return __assign$h.apply(this, arguments) } dynamicApp.component(PanelComponent.name, PanelComponent) var __assign$g = (globalThis && globalThis.__assign) || function () { __assign$g = Object.assign || function (t3) { for (var s2, i2 = 1, n2 = arguments.length; i2 < n2; i2++) { s2 = arguments[i2] for (var p2 in s2) if (Object.prototype.hasOwnProperty.call(s2, p2)) t3[p2] = s2[p2] } return t3 } return __assign$g.apply(this, arguments) } var __spreadArray$5 = (globalThis && globalThis.__spreadArray) || function (to, from, pack2) { if (pack2 || arguments.length === 2) for (var i2 = 0, l2 = from.length, ar2; i2 < l2; i2++) { if (ar2 || !(i2 in from)) { if (!ar2) ar2 = Array.prototype.slice.call(from, 0, i2) ar2[i2] = from[i2] } } return to.concat(ar2 || Array.prototype.slice.call(from)) } var tableEditMethodKeys = [ 'insert', 'insertAt', 'insertNextAt', 'remove', 'removeCheckboxRow', 'removeRadioRow', 'removeCurrentRow', 'getRecordset', 'getInsertRecords', 'getRemoveRecords', 'getUpdateRecords', 'getEditRecord', 'getActiveRecord', 'getSelectedCell', 'clearEdit', 'clearActived', 'clearSelected', 'isEditByRow', 'isActiveByRow', 'setEditRow', 'setActiveRow', 'setEditCell', 'setActiveCell', 'setSelectCell', ] var editHook = { setupTable: function ($xetable) { var props2 = $xetable.props, reactData = $xetable.reactData, internalData = $xetable.internalData var refElem = $xetable.getRefMaps().refElem var _a2 = $xetable.getComputeMaps(), computeMouseOpts = _a2.computeMouseOpts, computeEditOpts = _a2.computeEditOpts, computeCheckboxOpts = _a2.computeCheckboxOpts, computeTreeOpts = _a2.computeTreeOpts var editMethods = {} var editPrivateMethods = {} var getEditColumnModel = function (row, column) { var model = column.model, editRender = column.editRender if (editRender) { model.value = getCellValue(row, column) model.update = false } } var setEditColumnModel = function (row, column) { var model = column.model, editRender = column.editRender if (editRender && model.update) { setCellValue(row, column, model.value) model.update = false model.value = null } } var removeCellSelectedClass = function () { var el2 = refElem.value if (el2) { var cell = el2.querySelector('.col--selected') if (cell) { removeClass(cell, 'col--selected') } } } function syncActivedCell() { var editStore = reactData.editStore, tableColumn = reactData.tableColumn var editOpts = computeEditOpts.value var actived = editStore.actived var row = actived.row, column = actived.column if (row || column) { if (editOpts.mode === 'row') { tableColumn.forEach(function (column2) { return setEditColumnModel(row, column2) }) } else { setEditColumnModel(row, column) } } } function insertTreeRow(newRecords, isAppend) { var tableFullTreeData = internalData.tableFullTreeData, afterFullData = internalData.afterFullData, fullDataRowIdData = internalData.fullDataRowIdData, fullAllDataRowIdData = internalData.fullAllDataRowIdData var treeOpts = computeTreeOpts.value var rowField = treeOpts.rowField, parentField = treeOpts.parentField, mapChildrenField = treeOpts.mapChildrenField var childrenField = treeOpts.children || treeOpts.childrenField var funcName = isAppend ? 'push' : 'unshift' newRecords.forEach(function (item2) { var parentRowId = item2[parentField] var rowid = getRowid($xetable, item2) var matchObj = parentRowId ? xeUtils.findTree( tableFullTreeData, function (item3) { return parentRowId === item3[rowField] }, { children: mapChildrenField } ) : null if (matchObj) { var parentRow = matchObj.item var parentRest = fullAllDataRowIdData[getRowid($xetable, parentRow)] var parentLevel = parentRest ? parentRest.level : 0 var parentChilds = parentRow[childrenField] var mapChilds = parentRow[mapChildrenField] if (!xeUtils.isArray(parentChilds)) { parentChilds = parentRow[childrenField] = [] } if (!xeUtils.isArray(mapChilds)) { mapChilds = parentRow[childrenField] = [] } parentChilds[funcName](item2) mapChilds[funcName](item2) var rest = { row: item2, rowid, seq: -1, index: -1, _index: -1, $index: -1, items: parentChilds, parent, level: parentLevel + 1, } fullDataRowIdData[rowid] = rest fullAllDataRowIdData[rowid] = rest } else { afterFullData[funcName](item2) tableFullTreeData[funcName](item2) var rest = { row: item2, rowid, seq: -1, index: -1, _index: -1, $index: -1, items: tableFullTreeData, parent: null, level: 0, } fullDataRowIdData[rowid] = rest fullAllDataRowIdData[rowid] = rest } }) } var handleInsertRowAt = function (records, row, isInsertNextRow) { var treeConfig = props2.treeConfig var mergeList = reactData.mergeList, editStore = reactData.editStore var tableFullTreeData = internalData.tableFullTreeData, afterFullData = internalData.afterFullData, tableFullData = internalData.tableFullData, fullDataRowIdData = internalData.fullDataRowIdData, fullAllDataRowIdData = internalData.fullAllDataRowIdData var treeOpts = computeTreeOpts.value var transform3 = treeOpts.transform, rowField = treeOpts.rowField, mapChildrenField = treeOpts.mapChildrenField var childrenField = treeOpts.children || treeOpts.childrenField if (!xeUtils.isArray(records)) { records = [records] } var newRecords = reactive( $xetable.defineField( records.map(function (record) { var _a3 return Object.assign( treeConfig && transform3 ? ((_a3 = {}), (_a3[mapChildrenField] = []), (_a3[childrenField] = []), _a3) : {}, record ) }) ) ) if (!row) { if (treeConfig && transform3) { insertTreeRow(newRecords, false) } else { afterFullData.unshift.apply(afterFullData, newRecords) tableFullData.unshift.apply(tableFullData, newRecords) mergeList.forEach(function (mergeItem) { var mergeRowIndex = mergeItem.row if (mergeRowIndex > 0) { mergeItem.row = mergeRowIndex + newRecords.length } }) } } else { if (row === -1) { if (treeConfig && transform3) { insertTreeRow(newRecords, true) } else { afterFullData.push.apply(afterFullData, newRecords) tableFullData.push.apply(tableFullData, newRecords) mergeList.forEach(function (mergeItem) { var mergeRowIndex = mergeItem.row, mergeRowspan = mergeItem.rowspan if (mergeRowIndex + mergeRowspan > afterFullData.length) { mergeItem.rowspan = mergeRowspan + newRecords.length } }) } } else { if (treeConfig && transform3) { var matchMapObj_1 = xeUtils.findTree( tableFullTreeData, function (item2) { return row[rowField] === item2[rowField] }, { children: mapChildrenField } ) if (matchMapObj_1) { var parentRow_1 = matchMapObj_1.parent var parentMapChilds_1 = parentRow_1 ? parentRow_1[mapChildrenField] : tableFullTreeData var parentRest = fullAllDataRowIdData[getRowid($xetable, parentRow_1)] var parentLevel_1 = parentRest ? parentRest.level : 0 newRecords.forEach(function (item2, i2) { var rowid = getRowid($xetable, item2) if (parentRow_1) { item2[treeOpts.parentField] = parentRow_1[rowField] } var targetIndex2 = matchMapObj_1.index + i2 if (isInsertNextRow) { targetIndex2 = targetIndex2 + 1 } parentMapChilds_1.splice(targetIndex2, 0, item2) var rest = { row: item2, rowid, seq: -1, index: -1, _index: -1, $index: -1, items: parentMapChilds_1, parent: parentRow_1, level: parentLevel_1 + 1, } fullDataRowIdData[rowid] = rest fullAllDataRowIdData[rowid] = rest }) if (parentRow_1) { var matchObj = xeUtils.findTree( tableFullTreeData, function (item2) { return row[rowField] === item2[rowField] }, { children: childrenField } ) if (matchObj) { var parentChilds = matchObj.items var targetIndex = matchObj.index if (isInsertNextRow) { targetIndex = targetIndex + 1 } parentChilds.splice.apply( parentChilds, __spreadArray$5([targetIndex, 0], newRecords, false) ) } } } else { insertTreeRow(newRecords, true) } } else { if (treeConfig) { throw new Error(getLog('vxe.error.noTree', ['insert'])) } var afIndex_1 = -1 if (xeUtils.isNumber(row)) { if (row < afterFullData.length) { afIndex_1 = row } } else { afIndex_1 = $xetable.findRowIndexOf(afterFullData, row) } if (isInsertNextRow) { afIndex_1 = Math.max(afterFullData.length, afIndex_1 + 1) } if (afIndex_1 === -1) { throw new Error(errLog('vxe.error.unableInsert')) } afterFullData.splice.apply( afterFullData, __spreadArray$5([afIndex_1, 0], newRecords, false) ) tableFullData.splice.apply( tableFullData, __spreadArray$5( [$xetable.findRowIndexOf(tableFullData, row), 0], newRecords, false ) ) mergeList.forEach(function (mergeItem) { var mergeRowIndex = mergeItem.row, mergeRowspan = mergeItem.rowspan if (mergeRowIndex > afIndex_1) { mergeItem.row = mergeRowIndex + newRecords.length } else if (mergeRowIndex + mergeRowspan > afIndex_1) { mergeItem.rowspan = mergeRowspan + newRecords.length } }) } } } var insertMaps = editStore.insertMaps newRecords.forEach(function (newRow) { var rowid = getRowid($xetable, newRow) insertMaps[rowid] = newRow }) $xetable.cacheRowMap() $xetable.updateScrollYStatus() $xetable.handleTableData(treeConfig && transform3) if (!(treeConfig && transform3)) { $xetable.updateAfterDataIndex() } $xetable.updateFooter() $xetable.checkSelectionStatus() if (reactData.scrollYLoad) { $xetable.updateScrollYSpace() } return nextTick() .then(function () { $xetable.updateCellAreas() return $xetable.recalculate() }) .then(function () { return { row: newRecords.length ? newRecords[newRecords.length - 1] : null, rows: newRecords, } }) } editMethods = { insert: function (records) { return handleInsertRowAt(records, null) }, insertAt: function (records, row) { return handleInsertRowAt(records, row) }, insertNextAt: function (records, row) { return handleInsertRowAt(records, row, true) }, remove: function (rows) { var treeConfig = props2.treeConfig var mergeList = reactData.mergeList, editStore = reactData.editStore, selectCheckboxMaps = reactData.selectCheckboxMaps var tableFullTreeData = internalData.tableFullTreeData, afterFullData = internalData.afterFullData, tableFullData = internalData.tableFullData var checkboxOpts = computeCheckboxOpts.value var treeOpts = computeTreeOpts.value var transform3 = treeOpts.transform, mapChildrenField = treeOpts.mapChildrenField var childrenField = treeOpts.children || treeOpts.childrenField var actived = editStore.actived, removeMaps = editStore.removeMaps, insertMaps = editStore.insertMaps var checkField = checkboxOpts.checkField var delList = [] if (!rows) { rows = tableFullData } else if (!xeUtils.isArray(rows)) { rows = [rows] } rows.forEach(function (row) { if (!$xetable.isInsertByRow(row)) { var rowid = getRowid($xetable, row) removeMaps[rowid] = row } }) if (!checkField) { var selectRowMaps_1 = __assign$g({}, selectCheckboxMaps) rows.forEach(function (row) { var rowid = getRowid($xetable, row) if (selectRowMaps_1[rowid]) { delete selectRowMaps_1[rowid] } }) reactData.selectCheckboxMaps = selectRowMaps_1 } if (tableFullData === rows) { rows = delList = tableFullData.slice(0) internalData.tableFullData = [] internalData.afterFullData = [] $xetable.clearMergeCells() } else { if (treeConfig && transform3) { rows.forEach(function (row) { var rowid = getRowid($xetable, row) var matchMapObj = xeUtils.findTree( tableFullTreeData, function (item2) { return rowid === getRowid($xetable, item2) }, { children: mapChildrenField } ) if (matchMapObj) { var rItems = matchMapObj.items.splice(matchMapObj.index, 1) delList.push(rItems[0]) } var matchObj = xeUtils.findTree( tableFullTreeData, function (item2) { return rowid === getRowid($xetable, item2) }, { children: childrenField } ) if (matchObj) { matchObj.items.splice(matchObj.index, 1) } var afIndex = $xetable.findRowIndexOf(afterFullData, row) if (afIndex > -1) { afterFullData.splice(afIndex, 1) } }) } else { rows.forEach(function (row) { var tfIndex = $xetable.findRowIndexOf(tableFullData, row) if (tfIndex > -1) { var rItems = tableFullData.splice(tfIndex, 1) delList.push(rItems[0]) } var afIndex = $xetable.findRowIndexOf(afterFullData, row) if (afIndex > -1) { mergeList.forEach(function (mergeItem) { var mergeRowIndex = mergeItem.row, mergeRowspan = mergeItem.rowspan if (mergeRowIndex > afIndex) { mergeItem.row = mergeRowIndex - 1 } else if (mergeRowIndex + mergeRowspan > afIndex) { mergeItem.rowspan = mergeRowspan - 1 } }) afterFullData.splice(afIndex, 1) } }) } } if (actived.row && $xetable.findRowIndexOf(rows, actived.row) > -1) { editMethods.clearEdit() } rows.forEach(function (row) { var rowid = getRowid($xetable, row) if (insertMaps[rowid]) { delete insertMaps[rowid] } }) $xetable.updateFooter() $xetable.cacheRowMap() $xetable.handleTableData(treeConfig && transform3) if (!(treeConfig && transform3)) { $xetable.updateAfterDataIndex() } $xetable.checkSelectionStatus() if (reactData.scrollYLoad) { $xetable.updateScrollYSpace() } return nextTick() .then(function () { $xetable.updateCellAreas() return $xetable.recalculate() }) .then(function () { return { row: delList.length ? delList[delList.length - 1] : null, rows: delList, } }) }, removeCheckboxRow: function () { return editMethods .remove($xetable.getCheckboxRecords()) .then(function (params2) { $xetable.clearCheckboxRow() return params2 }) }, removeRadioRow: function () { var radioRecord = $xetable.getRadioRecord() return editMethods.remove(radioRecord || []).then(function (params2) { $xetable.clearRadioRow() return params2 }) }, removeCurrentRow: function () { var currentRecord = $xetable.getCurrentRecord() return editMethods.remove(currentRecord || []).then(function (params2) { $xetable.clearCurrentRow() return params2 }) }, getRecordset: function () { return { insertRecords: editMethods.getInsertRecords(), removeRecords: editMethods.getRemoveRecords(), updateRecords: editMethods.getUpdateRecords(), } }, getInsertRecords: function () { var editStore = reactData.editStore var fullAllDataRowIdData = internalData.fullAllDataRowIdData var insertMaps = editStore.insertMaps var insertRecords = [] xeUtils.each(insertMaps, function (row, rowid) { if (fullAllDataRowIdData[rowid]) { insertRecords.push(row) } }) return insertRecords }, getRemoveRecords: function () { var editStore = reactData.editStore var removeMaps = editStore.removeMaps var removeRecords = [] xeUtils.each(removeMaps, function (row) { removeRecords.push(row) }) return removeRecords }, getUpdateRecords: function () { var keepSource = props2.keepSource, treeConfig = props2.treeConfig var tableFullData = internalData.tableFullData var treeOpts = computeTreeOpts.value if (keepSource) { syncActivedCell() if (treeConfig) { return xeUtils.filterTree( tableFullData, function (row) { return $xetable.isUpdateByRow(row) }, treeOpts ) } return tableFullData.filter(function (row) { return $xetable.isUpdateByRow(row) }) } return [] }, getActiveRecord: function () { return this.getEditRecord() }, getEditRecord: function () { var editStore = reactData.editStore var afterFullData = internalData.afterFullData var el2 = refElem.value var _a3 = editStore.actived, args = _a3.args, row = _a3.row if ( args && $xetable.findRowIndexOf(afterFullData, row) > -1 && el2.querySelectorAll('.vxe-body--column.col--actived').length ) { return Object.assign({}, args) } return null }, getSelectedCell: function () { var editStore = reactData.editStore var _a3 = editStore.selected, args = _a3.args, column = _a3.column if (args && column) { return Object.assign({}, args) } return null }, clearActived: function (evnt) { return this.clearEdit(evnt) }, clearEdit: function (evnt) { var editStore = reactData.editStore var actived = editStore.actived var row = actived.row, column = actived.column if (row || column) { syncActivedCell() actived.args = null actived.row = null actived.column = null $xetable.updateFooter() $xetable.dispatchEvent( 'edit-closed', { row, rowIndex: $xetable.getRowIndex(row), $rowIndex: $xetable.getVMRowIndex(row), column, columnIndex: $xetable.getColumnIndex(column), $columnIndex: $xetable.getVMColumnIndex(column), }, evnt || null ) } if (GlobalConfig.cellVaildMode === 'obsolete') { if ($xetable.clearValidate) { return $xetable.clearValidate() } } return nextTick() }, clearSelected: function () { var editStore = reactData.editStore var selected = editStore.selected selected.row = null selected.column = null removeCellSelectedClass() return nextTick() }, isActiveByRow: function (row) { return this.isEditByRow(row) }, isEditByRow: function (row) { var editStore = reactData.editStore return editStore.actived.row === row }, setActiveRow: function (row) { return editMethods.setEditRow(row) }, setEditRow: function (row) { var visibleColumn = internalData.visibleColumn return $xetable.setEditCell( row, xeUtils.find(visibleColumn, function (column) { return isEnableConf(column.editRender) }) ) }, setActiveCell: function (row, fieldOrColumn) { return editMethods.setEditCell(row, fieldOrColumn) }, setEditCell: function (row, fieldOrColumn) { var editConfig = props2.editConfig var column = xeUtils.isString(fieldOrColumn) ? $xetable.getColumnByField(fieldOrColumn) : fieldOrColumn if ( row && column && isEnableConf(editConfig) && isEnableConf(column.editRender) ) { return $xetable.scrollToRow(row, column).then(function () { var cell = $xetable.getCell(row, column) if (cell) { editPrivateMethods.handleActived({ row, rowIndex: $xetable.getRowIndex(row), column, columnIndex: $xetable.getColumnIndex(column), cell, $table: $xetable, }) internalData._lastCallTime = Date.now() } return nextTick() }) } return nextTick() }, setSelectCell: function (row, fieldOrColumn) { var tableData2 = reactData.tableData var editOpts = computeEditOpts.value var column = xeUtils.isString(fieldOrColumn) ? $xetable.getColumnByField(fieldOrColumn) : fieldOrColumn if (row && column && editOpts.trigger !== 'manual') { var rowIndex = $xetable.findRowIndexOf(tableData2, row) if (rowIndex > -1 && column) { var cell = $xetable.getCell(row, column) var params2 = { row, rowIndex, column, columnIndex: $xetable.getColumnIndex(column), cell, } $xetable.handleSelected(params2, {}) } } return nextTick() }, } editPrivateMethods = { handleActived: function (params2, evnt) { var editConfig = props2.editConfig, mouseConfig = props2.mouseConfig var editStore = reactData.editStore, tableColumn = reactData.tableColumn var editOpts = computeEditOpts.value var mode2 = editOpts.mode var actived = editStore.actived var row = params2.row, column = params2.column var editRender = column.editRender var cell = params2.cell || $xetable.getCell(row, column) var beforeEditMethod = editOpts.beforeEditMethod || editOpts.activeMethod params2.cell = cell if (isEnableConf(editConfig) && isEnableConf(editRender) && cell) { if ( actived.row !== row || (mode2 === 'cell' ? actived.column !== column : false) ) { var type4 = 'edit-disabled' if ( !beforeEditMethod || beforeEditMethod( __assign$g(__assign$g({}, params2), { $table: $xetable }) ) ) { if (mouseConfig) { editMethods.clearSelected() if ($xetable.clearCellAreas) { $xetable.clearCellAreas() $xetable.clearCopyCellArea() } } $xetable.closeTooltip() if (actived.column) { editMethods.clearEdit(evnt) } type4 = 'edit-actived' column.renderHeight = cell.offsetHeight actived.args = params2 actived.row = row actived.column = column if (mode2 === 'row') { tableColumn.forEach(function (column2) { return getEditColumnModel(row, column2) }) } else { getEditColumnModel(row, column) } nextTick(function () { editPrivateMethods.handleFocus(params2, evnt) }) } $xetable.dispatchEvent( type4, { row, rowIndex: $xetable.getRowIndex(row), $rowIndex: $xetable.getVMRowIndex(row), column, columnIndex: $xetable.getColumnIndex(column), $columnIndex: $xetable.getVMColumnIndex(column), }, evnt ) } else { var oldColumn = actived.column if (mouseConfig) { editMethods.clearSelected() if ($xetable.clearCellAreas) { $xetable.clearCellAreas() $xetable.clearCopyCellArea() } } if (oldColumn !== column) { var oldModel = oldColumn.model if (oldModel.update) { setCellValue(row, oldColumn, oldModel.value) } if ($xetable.clearValidate) { $xetable.clearValidate(row, column) } } column.renderHeight = cell.offsetHeight actived.args = params2 actived.column = column setTimeout(function () { editPrivateMethods.handleFocus(params2, evnt) }) } $xetable.focus() } return nextTick() }, handleFocus: function (params2) { var row = params2.row, column = params2.column, cell = params2.cell var editRender = column.editRender if (isEnableConf(editRender)) { var compRender = renderer.get(editRender.name) var autofocus = editRender.autofocus, autoselect = editRender.autoselect var inputElem = void 0 if (!autofocus && compRender) { autofocus = compRender.autofocus } if (!autoselect && compRender) { autoselect = compRender.autoselect } if (xeUtils.isFunction(autofocus)) { inputElem = autofocus.call(this, params2) } else if (autofocus) { inputElem = cell.querySelector(autofocus) if (inputElem) { inputElem.focus() } } if (inputElem) { if (autoselect) { inputElem.select() } else { if (browse.msie) { var textRange = inputElem.createTextRange() textRange.collapse(false) textRange.select() } } } else { $xetable.scrollToRow(row, column) } } }, handleSelected: function (params2, evnt) { var mouseConfig = props2.mouseConfig var editStore = reactData.editStore var mouseOpts = computeMouseOpts.value var editOpts = computeEditOpts.value var actived = editStore.actived, selected = editStore.selected var row = params2.row, column = params2.column var isMouseSelected = mouseConfig && mouseOpts.selected var selectMethod = function () { if ( isMouseSelected && (selected.row !== row || selected.column !== column) ) { if ( actived.row !== row || (editOpts.mode === 'cell' ? actived.column !== column : false) ) { editMethods.clearEdit(evnt) editMethods.clearSelected() if ($xetable.clearCellAreas) { $xetable.clearCellAreas() $xetable.clearCopyCellArea() } selected.args = params2 selected.row = row selected.column = column if (isMouseSelected) { editPrivateMethods.addCellSelectedClass() } $xetable.focus() if (evnt) { $xetable.dispatchEvent('cell-selected', params2, evnt) } } } return nextTick() } return selectMethod() }, addCellSelectedClass: function () { var editStore = reactData.editStore var selected = editStore.selected var row = selected.row, column = selected.column removeCellSelectedClass() if (row && column) { var cell = $xetable.getCell(row, column) if (cell) { addClass(cell, 'col--selected') } } }, } return __assign$g(__assign$g({}, editMethods), editPrivateMethods) }, setupGrid: function ($xegrid) { return $xegrid.extendTableMethods(tableEditMethodKeys) }, } var VxeModuleEdit = { install: function () { VXETable.hooks.add('$tableEdit', editHook) }, } var Edit = VxeModuleEdit function useSize(props2) { var xesize = inject('xesize', null) var computeSize = computed(function () { return props2.size || (xesize ? xesize.value : null) }) provide('xesize', computeSize) return computeSize } var VxeButtonComponent = defineComponent({ name: 'VxeButton', props: { type: String, className: [String, Function], popupClassName: [String, Function], size: { type: String, default: function () { return GlobalConfig.button.size || GlobalConfig.size }, }, name: [String, Number], content: String, placement: String, status: String, icon: String, round: Boolean, circle: Boolean, disabled: Boolean, loading: Boolean, destroyOnClose: Boolean, transfer: { type: Boolean, default: function () { return GlobalConfig.button.transfer }, }, }, emits: ['click', 'dropdown-click'], setup: function (props2, context2) { var slots = context2.slots, emit2 = context2.emit var xID = xeUtils.uniqueId() var computeSize = useSize(props2) var reactData = reactive({ inited: false, showPanel: false, animatVisible: false, panelIndex: 0, panelStyle: {}, panelPlacement: '', }) var internalData = { showTime: null, } var refElem = ref() var refButton = ref() var refBtnPanel = ref() var refMaps = { refElem, } var $xebutton = { xID, props: props2, context: context2, reactData, internalData, getRefMaps: function () { return refMaps }, } var buttonMethods = {} var computeIsFormBtn = computed(function () { var type4 = props2.type if (type4) { return ['submit', 'reset', 'button'].indexOf(type4) > -1 } return false }) var computeBtnType = computed(function () { var type4 = props2.type return type4 && type4 === 'text' ? type4 : 'button' }) var updateZindex = function () { if (reactData.panelIndex < getLastZIndex()) { reactData.panelIndex = nextZIndex() } } var updatePlacement = function () { return nextTick().then(function () { var transfer = props2.transfer, placement = props2.placement var panelIndex = reactData.panelIndex var targetElem = refButton.value var panelElem = refBtnPanel.value if (panelElem && targetElem) { var targetHeight = targetElem.offsetHeight var targetWidth = targetElem.offsetWidth var panelHeight = panelElem.offsetHeight var panelWidth = panelElem.offsetWidth var marginSize = 5 var panelStyle = { zIndex: panelIndex, } var _a2 = getAbsolutePos(targetElem), top_1 = _a2.top, left2 = _a2.left, boundingTop = _a2.boundingTop, visibleHeight = _a2.visibleHeight, visibleWidth = _a2.visibleWidth var panelPlacement = 'bottom' if (transfer) { var btnLeft = left2 + targetWidth - panelWidth var btnTop = top_1 + targetHeight if (placement === 'top') { panelPlacement = 'top' btnTop = top_1 - panelHeight } else if (!placement) { if ( boundingTop + targetHeight + panelHeight + marginSize > visibleHeight ) { panelPlacement = 'top' btnTop = top_1 - panelHeight } if (btnTop < marginSize) { panelPlacement = 'bottom' btnTop = top_1 + targetHeight } } if (btnLeft + panelWidth + marginSize > visibleWidth) { btnLeft -= btnLeft + panelWidth + marginSize - visibleWidth } if (btnLeft < marginSize) { btnLeft = marginSize } Object.assign(panelStyle, { left: ''.concat(btnLeft, 'px'), right: 'auto', top: ''.concat(btnTop, 'px'), minWidth: ''.concat(targetWidth, 'px'), }) } else { if (placement === 'top') { panelPlacement = 'top' panelStyle.bottom = ''.concat(targetHeight, 'px') } else if (!placement) { if (boundingTop + targetHeight + panelHeight > visibleHeight) { if (boundingTop - targetHeight - panelHeight > marginSize) { panelPlacement = 'top' panelStyle.bottom = ''.concat(targetHeight, 'px') } } } } reactData.panelStyle = panelStyle reactData.panelPlacement = panelPlacement return nextTick() } }) } var clickEvent = function (evnt) { buttonMethods.dispatchEvent('click', { $event: evnt }, evnt) } var mousedownDropdownEvent = function (evnt) { var isLeftBtn = evnt.button === 0 if (isLeftBtn) { evnt.stopPropagation() } } var clickDropdownEvent = function (evnt) { var dropdownElem = evnt.currentTarget var panelElem = refBtnPanel.value var _a2 = getEventTargetNode(evnt, dropdownElem, 'vxe-button'), flag2 = _a2.flag, targetElem = _a2.targetElem if (flag2) { if (panelElem) { panelElem.dataset.active = 'N' } reactData.showPanel = false setTimeout(function () { if (!panelElem || panelElem.dataset.active !== 'Y') { reactData.animatVisible = false } }, 350) buttonMethods.dispatchEvent( 'dropdown-click', { name: targetElem.getAttribute('name'), $event: evnt }, evnt ) } } var mouseenterEvent = function () { var panelElem = refBtnPanel.value if (panelElem) { panelElem.dataset.active = 'Y' reactData.animatVisible = true setTimeout(function () { if (panelElem.dataset.active === 'Y') { reactData.showPanel = true updateZindex() updatePlacement() setTimeout(function () { if (reactData.showPanel) { updatePlacement() } }, 50) } }, 20) } } var mouseenterTargetEvent = function () { var panelElem = refBtnPanel.value if (panelElem) { panelElem.dataset.active = 'Y' if (!reactData.inited) { reactData.inited = true } internalData.showTime = setTimeout(function () { if (panelElem.dataset.active === 'Y') { mouseenterEvent() } else { reactData.animatVisible = false } }, 250) } } var closePanel = function () { var panelElem = refBtnPanel.value clearTimeout(internalData.showTime) if (panelElem) { panelElem.dataset.active = 'N' setTimeout(function () { if (panelElem.dataset.active !== 'Y') { reactData.showPanel = false setTimeout(function () { if (panelElem.dataset.active !== 'Y') { reactData.animatVisible = false } }, 350) } }, 100) } else { reactData.animatVisible = false reactData.showPanel = false } } var mouseleaveEvent = function () { closePanel() } var renderContent = function () { var content2 = props2.content, icon = props2.icon, loading2 = props2.loading var contVNs = [] if (loading2) { contVNs.push( h$4('i', { class: [ 'vxe-button--loading-icon', GlobalConfig.icon.BUTTON_LOADING, ], }) ) } else if (slots.icon) { contVNs.push( h$4( 'span', { class: 'vxe-button--custom-icon', }, slots.icon({}) ) ) } else if (icon) { contVNs.push( h$4('i', { class: ['vxe-button--icon', icon], }) ) } if (slots.default) { contVNs.push( h$4( 'span', { class: 'vxe-button--content', }, slots.default({}) ) ) } else if (content2) { contVNs.push( h$4( 'span', { class: 'vxe-button--content', }, getFuncText(content2) ) ) } return contVNs } buttonMethods = { dispatchEvent: function (type4, params2, evnt) { emit2( type4, Object.assign({ $button: $xebutton, $event: evnt }, params2) ) }, focus: function () { var btnElem = refButton.value btnElem.focus() return nextTick() }, blur: function () { var btnElem = refButton.value btnElem.blur() return nextTick() }, } Object.assign($xebutton, buttonMethods) onMounted(function () { GlobalEvent.on($xebutton, 'mousewheel', function (evnt) { var panelElem = refBtnPanel.value if (reactData.showPanel && !getEventTargetNode(evnt, panelElem).flag) { closePanel() } }) }) onUnmounted(function () { GlobalEvent.off($xebutton, 'mousewheel') }) var renderVN = function () { var _a2, _b2, _c2, _d var className = props2.className, popupClassName = props2.popupClassName, transfer = props2.transfer, type4 = props2.type, round2 = props2.round, circle = props2.circle, destroyOnClose = props2.destroyOnClose, status = props2.status, name2 = props2.name, disabled = props2.disabled, loading2 = props2.loading var inited = reactData.inited, showPanel = reactData.showPanel var isFormBtn = computeIsFormBtn.value var btnType = computeBtnType.value var vSize = computeSize.value if (slots.dropdowns) { return h$4( 'div', { ref: refElem, class: [ 'vxe-button--dropdown', className ? xeUtils.isFunction(className) ? className({ $button: $xebutton }) : className : '', ((_a2 = {}), (_a2['size--'.concat(vSize)] = vSize), (_a2['is--active'] = showPanel), _a2), ], }, [ h$4( 'button', { ref: refButton, class: [ 'vxe-button', 'type--'.concat(btnType), ((_b2 = {}), (_b2['size--'.concat(vSize)] = vSize), (_b2['theme--'.concat(status)] = status), (_b2['is--round'] = round2), (_b2['is--circle'] = circle), (_b2['is--disabled'] = disabled || loading2), (_b2['is--loading'] = loading2), _b2), ], name: name2, type: isFormBtn ? type4 : 'button', disabled: disabled || loading2, onMouseenter: mouseenterTargetEvent, onMouseleave: mouseleaveEvent, onClick: clickEvent, }, renderContent().concat([ h$4('i', { class: 'vxe-button--dropdown-arrow '.concat( GlobalConfig.icon.BUTTON_DROPDOWN ), }), ]) ), h$4( Teleport, { to: 'body', disabled: transfer ? !inited : true, }, [ h$4( 'div', { ref: refBtnPanel, class: [ 'vxe-button--dropdown-panel', popupClassName ? xeUtils.isFunction(popupClassName) ? popupClassName({ $button: $xebutton }) : popupClassName : '', ((_c2 = {}), (_c2['size--'.concat(vSize)] = vSize), (_c2['animat--leave'] = reactData.animatVisible), (_c2['animat--enter'] = showPanel), _c2), ], placement: reactData.panelPlacement, style: reactData.panelStyle, }, inited ? [ h$4( 'div', { class: 'vxe-button--dropdown-wrapper', onMousedown: mousedownDropdownEvent, onClick: clickDropdownEvent, onMouseenter: mouseenterEvent, onMouseleave: mouseleaveEvent, }, destroyOnClose && !showPanel ? [] : slots.dropdowns({}) ), ] : [] ), ] ), ] ) } return h$4( 'button', { ref: refButton, class: [ 'vxe-button', 'type--'.concat(btnType), ((_d = {}), (_d['size--'.concat(vSize)] = vSize), (_d['theme--'.concat(status)] = status), (_d['is--round'] = round2), (_d['is--circle'] = circle), (_d['is--disabled'] = disabled || loading2), (_d['is--loading'] = loading2), _d), ], name: name2, type: isFormBtn ? type4 : 'button', disabled: disabled || loading2, onClick: clickEvent, }, renderContent() ) } $xebutton.renderVN = renderVN return $xebutton }, render: function () { return this.renderVN() }, }) var VxeLoadingComponent = defineComponent({ name: 'VxeLoading', props: { modelValue: Boolean, icon: String, text: String, }, setup: function (props2, _a2) { var slots = _a2.slots var computeLoadingIcon = computed(function () { return props2.icon || GlobalConfig.icon.LOADING }) var computeLoadingText = computed(function () { var loadingText = GlobalConfig.loadingText return ( props2.text || (loadingText === null ? loadingText : GlobalConfig.i18n('vxe.loading.text')) ) }) return function () { var loadingIcon = computeLoadingIcon.value var loadingText = computeLoadingText.value return h$4( 'div', { class: [ 'vxe-loading', { 'is--visible': props2.modelValue, }, ], }, slots.default ? [ h$4( 'div', { class: 'vxe-loading--warpper', }, slots.default({}) ), ] : [ h$4( 'div', { class: 'vxe-loading--chunk', }, [ loadingIcon ? h$4('i', { class: loadingIcon, }) : h$4('div', { class: 'vxe-loading--spinner', }), loadingText ? h$4( 'div', { class: 'vxe-loading--text', }, ''.concat(loadingText) ) : null, ] ), ] ) } }, }) var VxeLoading = Object.assign(VxeLoadingComponent, { install: function (app2) { app2.component(VxeLoadingComponent.name, VxeLoadingComponent) }, }) var __assign$f = (globalThis && globalThis.__assign) || function () { __assign$f = Object.assign || function (t3) { for (var s2, i2 = 1, n2 = arguments.length; i2 < n2; i2++) { s2 = arguments[i2] for (var p2 in s2) if (Object.prototype.hasOwnProperty.call(s2, p2)) t3[p2] = s2[p2] } return t3 } return __assign$f.apply(this, arguments) } var allActivedModals = [] var msgQueue = [] var VxeModalComponent = defineComponent({ name: 'VxeModal', props: { modelValue: Boolean, id: String, type: { type: String, default: 'modal' }, loading: { type: Boolean, default: null }, status: String, iconStatus: String, className: String, top: { type: [Number, String], default: function () { return GlobalConfig.modal.top }, }, position: [String, Object], title: String, duration: { type: [Number, String], default: function () { return GlobalConfig.modal.duration }, }, message: [Number, String], content: [Number, String], cancelButtonText: { type: String, default: function () { return GlobalConfig.modal.cancelButtonText }, }, confirmButtonText: { type: String, default: function () { return GlobalConfig.modal.confirmButtonText }, }, lockView: { type: Boolean, default: function () { return GlobalConfig.modal.lockView }, }, lockScroll: Boolean, mask: { type: Boolean, default: function () { return GlobalConfig.modal.mask }, }, maskClosable: { type: Boolean, default: function () { return GlobalConfig.modal.maskClosable }, }, escClosable: { type: Boolean, default: function () { return GlobalConfig.modal.escClosable }, }, resize: Boolean, showHeader: { type: Boolean, default: function () { return GlobalConfig.modal.showHeader }, }, showFooter: { type: Boolean, default: function () { return GlobalConfig.modal.showFooter }, }, showZoom: Boolean, showClose: { type: Boolean, default: function () { return GlobalConfig.modal.showClose }, }, dblclickZoom: { type: Boolean, default: function () { return GlobalConfig.modal.dblclickZoom }, }, width: [Number, String], height: [Number, String], minWidth: { type: [Number, String], default: function () { return GlobalConfig.modal.minWidth }, }, minHeight: { type: [Number, String], default: function () { return GlobalConfig.modal.minHeight }, }, zIndex: Number, marginSize: { type: [Number, String], default: function () { return GlobalConfig.modal.marginSize }, }, fullscreen: Boolean, draggable: { type: Boolean, default: function () { return GlobalConfig.modal.draggable }, }, remember: { type: Boolean, default: function () { return GlobalConfig.modal.remember }, }, destroyOnClose: { type: Boolean, default: function () { return GlobalConfig.modal.destroyOnClose }, }, showTitleOverflow: { type: Boolean, default: function () { return GlobalConfig.modal.showTitleOverflow }, }, transfer: { type: Boolean, default: function () { return GlobalConfig.modal.transfer }, }, storage: { type: Boolean, default: function () { return GlobalConfig.modal.storage }, }, storageKey: { type: String, default: function () { return GlobalConfig.modal.storageKey }, }, animat: { type: Boolean, default: function () { return GlobalConfig.modal.animat }, }, size: { type: String, default: function () { return GlobalConfig.modal.size || GlobalConfig.size }, }, beforeHideMethod: { type: Function, default: function () { return GlobalConfig.modal.beforeHideMethod }, }, slots: Object, }, emits: [ 'update:modelValue', 'show', 'hide', 'before-hide', 'close', 'confirm', 'cancel', 'zoom', ], setup: function (props2, context2) { var slots = context2.slots, emit2 = context2.emit var xID = xeUtils.uniqueId() var computeSize = useSize(props2) var reactData = reactive({ inited: false, visible: false, contentVisible: false, modalTop: 0, modalZindex: 0, zoomLocat: null, firstOpen: true, }) var refElem = ref() var refModalBox = ref() var refConfirmBtn = ref() var refCancelBtn = ref() var refMaps = { refElem, } var $xemodal = { xID, props: props2, context: context2, reactData, getRefMaps: function () { return refMaps }, } var modalMethods = {} var computeIsMsg = computed(function () { return props2.type === 'message' }) var getBox = function () { var boxElem = refModalBox.value return boxElem } var recalculate = function () { var width = props2.width, height = props2.height var boxElem = getBox() boxElem.style.width = ''.concat( width ? (isNaN(width) ? width : ''.concat(width, 'px')) : '' ) boxElem.style.height = ''.concat( height ? (isNaN(height) ? height : ''.concat(height, 'px')) : '' ) return nextTick() } var updateZindex = function () { var zIndex2 = props2.zIndex var modalZindex = reactData.modalZindex if (zIndex2) { reactData.modalZindex = zIndex2 } else if (modalZindex < getLastZIndex()) { reactData.modalZindex = nextZIndex() } } var updatePosition = function () { return nextTick().then(function () { var position2 = props2.position var marginSize = xeUtils.toNumber(props2.marginSize) var boxElem = getBox() var clientVisibleWidth = document.documentElement.clientWidth || document.body.clientWidth var clientVisibleHeight = document.documentElement.clientHeight || document.body.clientHeight var isPosCenter = position2 === 'center' var _a2 = xeUtils.isString(position2) ? { top: position2, left: position2 } : Object.assign({}, position2), top2 = _a2.top, left2 = _a2.left var topCenter = isPosCenter || top2 === 'center' var leftCenter = isPosCenter || left2 === 'center' var posTop = '' var posLeft = '' if (left2 && !leftCenter) { posLeft = isNaN(left2) ? left2 : ''.concat(left2, 'px') } else { posLeft = ''.concat( Math.max( marginSize, clientVisibleWidth / 2 - boxElem.offsetWidth / 2 ), 'px' ) } if (top2 && !topCenter) { posTop = isNaN(top2) ? top2 : ''.concat(top2, 'px') } else { posTop = ''.concat( Math.max( marginSize, clientVisibleHeight / 2 - boxElem.offsetHeight / 2 ), 'px' ) } boxElem.style.top = posTop boxElem.style.left = posLeft }) } var updateStyle2 = function () { nextTick(function () { var offsetTop = 0 msgQueue.forEach(function (comp) { var boxElem = comp.getBox() offsetTop += xeUtils.toNumber(comp.props.top) comp.reactData.modalTop = offsetTop offsetTop += boxElem.clientHeight }) }) } var removeMsgQueue = function () { if (msgQueue.indexOf($xemodal) > -1) { xeUtils.remove(msgQueue, function (comp) { return comp === $xemodal }) } updateStyle2() } var closeModal2 = function (type4) { var remember = props2.remember, beforeHideMethod = props2.beforeHideMethod var visible = reactData.visible var isMsg = computeIsMsg.value var params2 = { type: type4 } if (visible) { Promise.resolve(beforeHideMethod ? beforeHideMethod(params2) : null) .then(function (rest) { if (!xeUtils.isError(rest)) { if (isMsg) { removeMsgQueue() } reactData.contentVisible = false if (!remember) { reactData.zoomLocat = null } xeUtils.remove(allActivedModals, function (item2) { return item2 === $xemodal }) modalMethods.dispatchEvent('before-hide', params2) setTimeout(function () { reactData.visible = false emit2('update:modelValue', false) modalMethods.dispatchEvent('hide', params2) }, 200) } }) .catch(function (e2) { return e2 }) } return nextTick() } var closeEvent = function (evnt) { var type4 = 'close' modalMethods.dispatchEvent(type4, { type: type4 }, evnt) closeModal2(type4) } var confirmEvent = function (evnt) { var type4 = 'confirm' modalMethods.dispatchEvent(type4, { type: type4 }, evnt) closeModal2(type4) } var cancelEvent = function (evnt) { var type4 = 'cancel' modalMethods.dispatchEvent(type4, { type: type4 }, evnt) closeModal2(type4) } var getStorageMap = function (key2) { var version2 = GlobalConfig.version var rest = xeUtils.toStringJSON(localStorage.getItem(key2) || '') return rest && rest._v === version2 ? rest : { _v: version2 } } var hasPosStorage = function () { var id2 = props2.id, remember = props2.remember, storage2 = props2.storage, storageKey = props2.storageKey return !!(id2 && remember && storage2 && getStorageMap(storageKey)[id2]) } var restorePosStorage = function () { var id2 = props2.id, remember = props2.remember, storage2 = props2.storage, storageKey = props2.storageKey if (id2 && remember && storage2) { var posStorage = getStorageMap(storageKey)[id2] if (posStorage) { var boxElem = getBox() var _a2 = posStorage.split(','), left2 = _a2[0], top_1 = _a2[1], width = _a2[2], height = _a2[3], zoomLeft = _a2[4], zoomTop = _a2[5], zoomWidth = _a2[6], zoomHeight = _a2[7] if (left2) { boxElem.style.left = ''.concat(left2, 'px') } if (top_1) { boxElem.style.top = ''.concat(top_1, 'px') } if (width) { boxElem.style.width = ''.concat(width, 'px') } if (height) { boxElem.style.height = ''.concat(height, 'px') } if (zoomLeft && zoomTop) { reactData.zoomLocat = { left: zoomLeft, top: zoomTop, width: zoomWidth, height: zoomHeight, } } } } } var addMsgQueue = function () { if (msgQueue.indexOf($xemodal) === -1) { msgQueue.push($xemodal) } updateStyle2() } var savePosStorage = function () { var id2 = props2.id, remember = props2.remember, storage2 = props2.storage, storageKey = props2.storageKey var zoomLocat = reactData.zoomLocat if (id2 && remember && storage2) { var boxElem = getBox() var posStorageMap = getStorageMap(storageKey) posStorageMap[id2] = [ boxElem.style.left, boxElem.style.top, boxElem.style.width, boxElem.style.height, ] .concat( zoomLocat ? [ zoomLocat.left, zoomLocat.top, zoomLocat.width, zoomLocat.height, ] : [] ) .map(function (val2) { return val2 ? xeUtils.toNumber(val2) : '' }) .join(',') localStorage.setItem(storageKey, xeUtils.toJSONString(posStorageMap)) } } var maximize = function () { return nextTick().then(function () { if (!reactData.zoomLocat) { var marginSize = Math.max(0, xeUtils.toNumber(props2.marginSize)) var boxElem = getBox() var _a2 = getDomNode(), visibleHeight = _a2.visibleHeight, visibleWidth = _a2.visibleWidth reactData.zoomLocat = { top: boxElem.offsetTop, left: boxElem.offsetLeft, width: boxElem.offsetWidth + (boxElem.style.width ? 0 : 1), height: boxElem.offsetHeight + (boxElem.style.height ? 0 : 1), } Object.assign(boxElem.style, { top: ''.concat(marginSize, 'px'), left: ''.concat(marginSize, 'px'), width: ''.concat(visibleWidth - marginSize * 2, 'px'), height: ''.concat(visibleHeight - marginSize * 2, 'px'), }) savePosStorage() } }) } var openModal2 = function () { var duration2 = props2.duration, remember = props2.remember, showFooter = props2.showFooter var inited = reactData.inited, visible = reactData.visible var isMsg = computeIsMsg.value if (!inited) { reactData.inited = true } if (!visible) { if (!remember) { recalculate() } reactData.visible = true reactData.contentVisible = false updateZindex() allActivedModals.push($xemodal) setTimeout(function () { reactData.contentVisible = true nextTick(function () { if (showFooter) { var confirmBtn = refConfirmBtn.value var cancelBtn = refCancelBtn.value var operBtn = confirmBtn || cancelBtn if (operBtn) { operBtn.focus() } } var type4 = '' var params2 = { type: type4 } emit2('update:modelValue', true) modalMethods.dispatchEvent('show', params2) }) }, 10) if (isMsg) { addMsgQueue() if (duration2 !== -1) { setTimeout(function () { return closeModal2('close') }, xeUtils.toNumber(duration2)) } } else { nextTick(function () { var fullscreen = props2.fullscreen var firstOpen = reactData.firstOpen if (!remember || firstOpen) { updatePosition().then(function () { setTimeout(function () { return updatePosition() }, 20) }) } if (firstOpen) { reactData.firstOpen = false if (hasPosStorage()) { restorePosStorage() } else if (fullscreen) { nextTick(function () { return maximize() }) } } else { if (fullscreen) { nextTick(function () { return maximize() }) } } }) } } return nextTick() } var selfClickEvent = function (evnt) { var el2 = refElem.value if (props2.maskClosable && evnt.target === el2) { var type4 = 'mask' closeModal2(type4) } } var handleGlobalKeydownEvent = function (evnt) { var isEsc = hasEventKey(evnt, EVENT_KEYS.ESCAPE) if (isEsc) { var lastModal_1 = xeUtils.max(allActivedModals, function (item2) { return item2.reactData.modalZindex }) if (lastModal_1) { setTimeout(function () { if (lastModal_1 === $xemodal && lastModal_1.props.escClosable) { closeModal2('exit') } }, 10) } } } var isMaximized = function () { return !!reactData.zoomLocat } var revert = function () { return nextTick().then(function () { var zoomLocat = reactData.zoomLocat if (zoomLocat) { var boxElem = getBox() reactData.zoomLocat = null Object.assign(boxElem.style, { top: ''.concat(zoomLocat.top, 'px'), left: ''.concat(zoomLocat.left, 'px'), width: ''.concat(zoomLocat.width, 'px'), height: ''.concat(zoomLocat.height, 'px'), }) savePosStorage() } }) } var zoom = function () { if (reactData.zoomLocat) { return revert().then(function () { return isMaximized() }) } return maximize().then(function () { return isMaximized() }) } var toggleZoomEvent = function (evnt) { var zoomLocat = reactData.zoomLocat var params2 = { type: zoomLocat ? 'revert' : 'max' } return zoom().then(function () { modalMethods.dispatchEvent('zoom', params2, evnt) }) } var getPosition = function () { var isMsg = computeIsMsg.value if (!isMsg) { var boxElem = getBox() if (boxElem) { return { top: boxElem.offsetTop, left: boxElem.offsetLeft, } } } return null } var setPosition = function (top2, left2) { var isMsg = computeIsMsg.value if (!isMsg) { var boxElem = getBox() if (xeUtils.isNumber(top2)) { boxElem.style.top = ''.concat(top2, 'px') } if (xeUtils.isNumber(left2)) { boxElem.style.left = ''.concat(left2, 'px') } } return nextTick() } var boxMousedownEvent = function () { var modalZindex = reactData.modalZindex if ( allActivedModals.some(function (comp) { return ( comp.reactData.visible && comp.reactData.modalZindex > modalZindex ) }) ) { updateZindex() } } var mousedownEvent = function (evnt) { var remember = props2.remember, storage2 = props2.storage var zoomLocat = reactData.zoomLocat var marginSize = xeUtils.toNumber(props2.marginSize) var boxElem = getBox() if ( !zoomLocat && evnt.button === 0 && !getEventTargetNode(evnt, boxElem, 'trigger--btn').flag ) { evnt.preventDefault() var domMousemove_1 = document.onmousemove var domMouseup_1 = document.onmouseup var disX_1 = evnt.clientX - boxElem.offsetLeft var disY_1 = evnt.clientY - boxElem.offsetTop var _a2 = getDomNode(), visibleHeight_1 = _a2.visibleHeight, visibleWidth_1 = _a2.visibleWidth document.onmousemove = function (evnt2) { evnt2.preventDefault() var offsetWidth = boxElem.offsetWidth var offsetHeight = boxElem.offsetHeight var minX = marginSize var maxX = visibleWidth_1 - offsetWidth - marginSize - 1 var minY = marginSize var maxY = visibleHeight_1 - offsetHeight - marginSize - 1 var left2 = evnt2.clientX - disX_1 var top2 = evnt2.clientY - disY_1 if (left2 > maxX) { left2 = maxX } if (left2 < minX) { left2 = minX } if (top2 > maxY) { top2 = maxY } if (top2 < minY) { top2 = minY } boxElem.style.left = ''.concat(left2, 'px') boxElem.style.top = ''.concat(top2, 'px') boxElem.className = boxElem.className.replace(/\s?is--drag/, '') + ' is--drag' } document.onmouseup = function () { document.onmousemove = domMousemove_1 document.onmouseup = domMouseup_1 if (remember && storage2) { nextTick(function () { savePosStorage() }) } setTimeout(function () { boxElem.className = boxElem.className.replace(/\s?is--drag/, '') }, 50) } } } var dragEvent = function (evnt) { evnt.preventDefault() var remember = props2.remember, storage2 = props2.storage var _a2 = getDomNode(), visibleHeight = _a2.visibleHeight, visibleWidth = _a2.visibleWidth var marginSize = xeUtils.toNumber(props2.marginSize) var targetElem = evnt.target var type4 = targetElem.getAttribute('type') var minWidth = xeUtils.toNumber(props2.minWidth) var minHeight = xeUtils.toNumber(props2.minHeight) var maxWidth = visibleWidth var maxHeight = visibleHeight var boxElem = getBox() var domMousemove = document.onmousemove var domMouseup = document.onmouseup var clientWidth = boxElem.clientWidth var clientHeight = boxElem.clientHeight var disX = evnt.clientX var disY = evnt.clientY var offsetTop = boxElem.offsetTop var offsetLeft = boxElem.offsetLeft var params2 = { type: 'resize' } document.onmousemove = function (evnt2) { evnt2.preventDefault() var dragLeft var dragTop var width var height switch (type4) { case 'wl': dragLeft = disX - evnt2.clientX width = dragLeft + clientWidth if (offsetLeft - dragLeft > marginSize) { if (width > minWidth) { boxElem.style.width = ''.concat( width < maxWidth ? width : maxWidth, 'px' ) boxElem.style.left = ''.concat(offsetLeft - dragLeft, 'px') } } break case 'swst': dragLeft = disX - evnt2.clientX dragTop = disY - evnt2.clientY width = dragLeft + clientWidth height = dragTop + clientHeight if (offsetLeft - dragLeft > marginSize) { if (width > minWidth) { boxElem.style.width = ''.concat( width < maxWidth ? width : maxWidth, 'px' ) boxElem.style.left = ''.concat(offsetLeft - dragLeft, 'px') } } if (offsetTop - dragTop > marginSize) { if (height > minHeight) { boxElem.style.height = ''.concat( height < maxHeight ? height : maxHeight, 'px' ) boxElem.style.top = ''.concat(offsetTop - dragTop, 'px') } } break case 'swlb': dragLeft = disX - evnt2.clientX dragTop = evnt2.clientY - disY width = dragLeft + clientWidth height = dragTop + clientHeight if (offsetLeft - dragLeft > marginSize) { if (width > minWidth) { boxElem.style.width = ''.concat( width < maxWidth ? width : maxWidth, 'px' ) boxElem.style.left = ''.concat(offsetLeft - dragLeft, 'px') } } if (offsetTop + height + marginSize < visibleHeight) { if (height > minHeight) { boxElem.style.height = ''.concat( height < maxHeight ? height : maxHeight, 'px' ) } } break case 'st': dragTop = disY - evnt2.clientY height = clientHeight + dragTop if (offsetTop - dragTop > marginSize) { if (height > minHeight) { boxElem.style.height = ''.concat( height < maxHeight ? height : maxHeight, 'px' ) boxElem.style.top = ''.concat(offsetTop - dragTop, 'px') } } break case 'wr': dragLeft = evnt2.clientX - disX width = dragLeft + clientWidth if (offsetLeft + width + marginSize < visibleWidth) { if (width > minWidth) { boxElem.style.width = ''.concat( width < maxWidth ? width : maxWidth, 'px' ) } } break case 'sest': dragLeft = evnt2.clientX - disX dragTop = disY - evnt2.clientY width = dragLeft + clientWidth height = dragTop + clientHeight if (offsetLeft + width + marginSize < visibleWidth) { if (width > minWidth) { boxElem.style.width = ''.concat( width < maxWidth ? width : maxWidth, 'px' ) } } if (offsetTop - dragTop > marginSize) { if (height > minHeight) { boxElem.style.height = ''.concat( height < maxHeight ? height : maxHeight, 'px' ) boxElem.style.top = ''.concat(offsetTop - dragTop, 'px') } } break case 'selb': dragLeft = evnt2.clientX - disX dragTop = evnt2.clientY - disY width = dragLeft + clientWidth height = dragTop + clientHeight if (offsetLeft + width + marginSize < visibleWidth) { if (width > minWidth) { boxElem.style.width = ''.concat( width < maxWidth ? width : maxWidth, 'px' ) } } if (offsetTop + height + marginSize < visibleHeight) { if (height > minHeight) { boxElem.style.height = ''.concat( height < maxHeight ? height : maxHeight, 'px' ) } } break case 'sb': dragTop = evnt2.clientY - disY height = dragTop + clientHeight if (offsetTop + height + marginSize < visibleHeight) { if (height > minHeight) { boxElem.style.height = ''.concat( height < maxHeight ? height : maxHeight, 'px' ) } } break } boxElem.className = boxElem.className.replace(/\s?is--drag/, '') + ' is--drag' if (remember && storage2) { savePosStorage() } modalMethods.dispatchEvent('zoom', params2, evnt2) } document.onmouseup = function () { reactData.zoomLocat = null document.onmousemove = domMousemove document.onmouseup = domMouseup setTimeout(function () { boxElem.className = boxElem.className.replace(/\s?is--drag/, '') }, 50) } } var renderTitles = function () { var _a2 = props2.slots, propSlots = _a2 === void 0 ? {} : _a2, showClose = props2.showClose, showZoom = props2.showZoom, title = props2.title var zoomLocat = reactData.zoomLocat var titleSlot = slots.title || propSlots.title var cornerSlot = slots.corner || propSlots.corner var titVNs = [ h$4( 'div', { class: 'vxe-modal--header-title', }, titleSlot ? getSlotVNs(titleSlot({ $modal: $xemodal })) : title ? getFuncText(title) : GlobalConfig.i18n('vxe.alert.title') ), ] var rightVNs = [] if (cornerSlot) { rightVNs.push( h$4( 'span', { class: 'vxe-modal--corner-warpper', }, getSlotVNs(cornerSlot({ $modal: $xemodal })) ) ) } if (showZoom) { rightVNs.push( h$4('i', { class: [ 'vxe-modal--zoom-btn', 'trigger--btn', zoomLocat ? GlobalConfig.icon.MODAL_ZOOM_OUT : GlobalConfig.icon.MODAL_ZOOM_IN, ], title: GlobalConfig.i18n( 'vxe.modal.zoom'.concat(zoomLocat ? 'Out' : 'In') ), onClick: toggleZoomEvent, }) ) } if (showClose) { rightVNs.push( h$4('i', { class: [ 'vxe-modal--close-btn', 'trigger--btn', GlobalConfig.icon.MODAL_CLOSE, ], title: GlobalConfig.i18n('vxe.modal.close'), onClick: closeEvent, }) ) } titVNs.push( h$4( 'div', { class: 'vxe-modal--header-right', }, rightVNs ) ) return titVNs } var renderHeaders = function () { var _a2 = props2.slots, propSlots = _a2 === void 0 ? {} : _a2, showZoom = props2.showZoom, draggable2 = props2.draggable var isMsg = computeIsMsg.value var headerSlot = slots.header || propSlots.header var headVNs = [] if (props2.showHeader) { var headerOns = {} if (draggable2) { headerOns.onMousedown = mousedownEvent } if (showZoom && props2.dblclickZoom && props2.type === 'modal') { headerOns.onDblclick = toggleZoomEvent } headVNs.push( h$4( 'div', __assign$f( { class: [ 'vxe-modal--header', { 'is--draggable': draggable2, 'is--ellipsis': !isMsg && props2.showTitleOverflow, }, ], }, headerOns ), headerSlot ? !reactData.inited || (props2.destroyOnClose && !reactData.visible) ? [] : getSlotVNs(headerSlot({ $modal: $xemodal })) : renderTitles() ) ) } return headVNs } var renderBodys = function () { var _a2 = props2.slots, propSlots = _a2 === void 0 ? {} : _a2, status = props2.status, message2 = props2.message var content2 = props2.content || message2 var isMsg = computeIsMsg.value var defaultSlot = slots.default || propSlots.default var contVNs = [] if (status) { contVNs.push( h$4( 'div', { class: 'vxe-modal--status-wrapper', }, [ h$4('i', { class: [ 'vxe-modal--status-icon', props2.iconStatus || GlobalConfig.icon[ 'MODAL_'.concat(status).toLocaleUpperCase() ], ], }), ] ) ) } contVNs.push( h$4( 'div', { class: 'vxe-modal--content', }, defaultSlot ? !reactData.inited || (props2.destroyOnClose && !reactData.visible) ? [] : getSlotVNs(defaultSlot({ $modal: $xemodal })) : getFuncText(content2) ) ) if (!isMsg) { contVNs.push( h$4(VxeLoading, { class: 'vxe-modal--loading', modelValue: props2.loading, }) ) } return [ h$4( 'div', { class: 'vxe-modal--body', }, contVNs ), ] } var renderBtns = function () { var type4 = props2.type var btnVNs = [] if (type4 === 'confirm') { btnVNs.push( h$4(VxeButtonComponent, { ref: refCancelBtn, content: props2.cancelButtonText || GlobalConfig.i18n('vxe.button.cancel'), onClick: cancelEvent, }) ) } btnVNs.push( h$4(VxeButtonComponent, { ref: refConfirmBtn, status: 'primary', content: props2.confirmButtonText || GlobalConfig.i18n('vxe.button.confirm'), onClick: confirmEvent, }) ) return btnVNs } var renderFooters = function () { var _a2 = props2.slots, propSlots = _a2 === void 0 ? {} : _a2 var isMsg = computeIsMsg.value var footerSlot = slots.footer || propSlots.footer var footVNs = [] if (props2.showFooter) { footVNs.push( h$4( 'div', { class: 'vxe-modal--footer', }, footerSlot ? !reactData.inited || (props2.destroyOnClose && !reactData.visible) ? [] : getSlotVNs(footerSlot({ $modal: $xemodal })) : renderBtns() ) ) } if (!isMsg && props2.resize) { footVNs.push( h$4( 'span', { class: 'vxe-modal--resize', }, ['wl', 'wr', 'swst', 'sest', 'st', 'swlb', 'selb', 'sb'].map( function (type4) { return h$4('span', { class: ''.concat(type4, '-resize'), type: type4, onMousedown: dragEvent, }) } ) ) ) } return footVNs } modalMethods = { dispatchEvent: function (type4, params2, evnt) { emit2(type4, Object.assign({ $modal: $xemodal, $event: evnt }, params2)) }, open: openModal2, close: function () { return closeModal2('close') }, getBox, getPosition, setPosition, isMaximized, zoom, maximize, revert, } Object.assign($xemodal, modalMethods) watch$1(function () { return props2.width }, recalculate) watch$1(function () { return props2.height }, recalculate) watch$1( function () { return props2.modelValue }, function (value2) { if (value2) { openModal2() } else { closeModal2('model') } } ) onMounted(function () { nextTick(function () { if (props2.storage && !props2.id) { errLog('vxe.error.reqProp', ['modal.id']) } if (props2.modelValue) { openModal2() } recalculate() }) if (props2.escClosable) { GlobalEvent.on($xemodal, 'keydown', handleGlobalKeydownEvent) } }) onUnmounted(function () { GlobalEvent.off($xemodal, 'keydown') removeMsgQueue() }) var renderVN = function () { var _a2 var className = props2.className, type4 = props2.type, animat = props2.animat, loading2 = props2.loading, status = props2.status, lockScroll = props2.lockScroll, lockView = props2.lockView, mask = props2.mask, resize = props2.resize var inited = reactData.inited, zoomLocat = reactData.zoomLocat, modalTop = reactData.modalTop, contentVisible = reactData.contentVisible, visible = reactData.visible var vSize = computeSize.value return h$4( Teleport, { to: 'body', disabled: props2.transfer ? !inited : true, }, [ h$4( 'div', { ref: refElem, class: [ 'vxe-modal--wrapper', 'type--'.concat(type4), className || '', ((_a2 = {}), (_a2['size--'.concat(vSize)] = vSize), (_a2['status--'.concat(status)] = status), (_a2['is--animat'] = animat), (_a2['lock--scroll'] = lockScroll), (_a2['lock--view'] = lockView), (_a2['is--resize'] = resize), (_a2['is--mask'] = mask), (_a2['is--maximize'] = zoomLocat), (_a2['is--visible'] = contentVisible), (_a2['is--active'] = visible), (_a2['is--loading'] = loading2), _a2), ], style: { zIndex: reactData.modalZindex, top: modalTop ? ''.concat(modalTop, 'px') : null, }, onClick: selfClickEvent, }, [ h$4( 'div', { ref: refModalBox, class: 'vxe-modal--box', onMousedown: boxMousedownEvent, }, renderHeaders().concat(renderBodys(), renderFooters()) ), ] ), ] ) } $xemodal.renderVN = renderVN return $xemodal }, render: function () { return this.renderVN() }, }) function toStringTimeDate(str) { if (str) { var rest = new Date() var h2 = 0 var m2 = 0 var s2 = 0 if (xeUtils.isDate(str)) { h2 = str.getHours() m2 = str.getMinutes() s2 = str.getSeconds() } else { str = xeUtils.toValueString(str) var parses = str.match(/^(\d{1,2})(:(\d{1,2}))?(:(\d{1,2}))?/) if (parses) { h2 = xeUtils.toNumber(parses[1]) m2 = xeUtils.toNumber(parses[3]) s2 = xeUtils.toNumber(parses[5]) } } rest.setHours(h2) rest.setMinutes(m2) rest.setSeconds(s2) return rest } return new Date('') } function getDateQuarter(date4) { var month = date4.getMonth() if (month < 3) { return 1 } else if (month < 6) { return 2 } else if (month < 9) { return 3 } return 4 } function handleNumber(val2) { return xeUtils.isString(val2) ? val2.replace(/,/g, '') : val2 } function toFloatValueFixed(inputValue, digitsValue) { if (/^-/.test('' + inputValue)) { return xeUtils.toFixed(xeUtils.ceil(inputValue, digitsValue), digitsValue) } return xeUtils.toFixed(xeUtils.floor(inputValue, digitsValue), digitsValue) } var __spreadArray$4 = (globalThis && globalThis.__spreadArray) || function (to, from, pack2) { if (pack2 || arguments.length === 2) for (var i2 = 0, l2 = from.length, ar2; i2 < l2; i2++) { if (ar2 || !(i2 in from)) { if (!ar2) ar2 = Array.prototype.slice.call(from, 0, i2) ar2[i2] = from[i2] } } return to.concat(ar2 || Array.prototype.slice.call(from)) } var yearSize = 12 var monthSize = 20 var quarterSize = 8 var VxeInputConstructor = defineComponent({ name: 'VxeInput', props: { modelValue: [String, Number, Date], immediate: { type: Boolean, default: true }, name: String, type: { type: String, default: 'text' }, clearable: { type: Boolean, default: function () { return GlobalConfig.input.clearable }, }, readonly: Boolean, disabled: Boolean, placeholder: { type: String, default: function () { return xeUtils.eqNull(GlobalConfig.input.placeholder) ? GlobalConfig.i18n('vxe.base.pleaseInput') : GlobalConfig.input.placeholder }, }, maxlength: [String, Number], autocomplete: { type: String, default: 'off' }, align: String, form: String, className: String, size: { type: String, default: function () { return GlobalConfig.input.size || GlobalConfig.size }, }, multiple: Boolean, showWordCount: Boolean, countMethod: Function, min: { type: [String, Number], default: null }, max: { type: [String, Number], default: null }, step: [String, Number], exponential: { type: Boolean, default: function () { return GlobalConfig.input.exponential }, }, controls: { type: Boolean, default: function () { return GlobalConfig.input.controls }, }, digits: { type: [String, Number], default: function () { return GlobalConfig.input.digits }, }, startDate: { type: [String, Number, Date], default: function () { return GlobalConfig.input.startDate }, }, endDate: { type: [String, Number, Date], default: function () { return GlobalConfig.input.endDate }, }, minDate: [String, Number, Date], maxDate: [String, Number, Date], startWeek: Number, startDay: { type: [String, Number], default: function () { return GlobalConfig.input.startDay }, }, labelFormat: { type: String, default: function () { return GlobalConfig.input.labelFormat }, }, valueFormat: { type: String, default: function () { return GlobalConfig.input.valueFormat }, }, editable: { type: Boolean, default: true }, festivalMethod: { type: Function, default: function () { return GlobalConfig.input.festivalMethod }, }, disabledMethod: { type: Function, default: function () { return GlobalConfig.input.disabledMethod }, }, selectDay: { type: [String, Number], default: function () { return GlobalConfig.input.selectDay }, }, prefixIcon: String, suffixIcon: String, placement: String, transfer: { type: Boolean, default: function () { return GlobalConfig.input.transfer }, }, }, emits: [ 'update:modelValue', 'input', 'change', 'keydown', 'keyup', 'wheel', 'click', 'focus', 'blur', 'clear', 'search-click', 'toggle-visible', 'prev-number', 'next-number', 'prefix-click', 'suffix-click', 'date-prev', 'date-today', 'date-next', ], setup: function (props2, context2) { var slots = context2.slots, emit2 = context2.emit var $xeform = inject('$xeform', null) var $xeformiteminfo = inject('$xeformiteminfo', null) var xID = xeUtils.uniqueId() var computeSize = useSize(props2) var reactData = reactive({ inited: false, panelIndex: 0, showPwd: false, visiblePanel: false, animatVisible: false, panelStyle: null, panelPlacement: '', isActivated: false, inputValue: props2.modelValue, datetimePanelValue: null, datePanelValue: null, datePanelLabel: '', datePanelType: 'day', selectMonth: null, currentDate: null, }) var refElem = ref() var refInputTarget = ref() var refInputPanel = ref() var refInputTimeBody = ref() var refMaps = { refElem, refInput: refInputTarget, } var $xeinput = { xID, props: props2, context: context2, reactData, getRefMaps: function () { return refMaps }, } var inputMethods = {} var parseDate2 = function (value2, format2) { var type4 = props2.type if (type4 === 'time') { return toStringTimeDate(value2) } return xeUtils.toStringDate(value2, format2) } var computeIsDateTimeType = computed(function () { var type4 = props2.type return type4 === 'time' || type4 === 'datetime' }) var computeIsNumType = computed(function () { return ['number', 'integer', 'float'].indexOf(props2.type) > -1 }) var computeInputCount = computed(function () { return xeUtils.getSize(reactData.inputValue) }) var computeIsCountError = computed(function () { var inputCount = computeInputCount.value return props2.maxlength && inputCount > xeUtils.toNumber(props2.maxlength) }) var computeIsDatePickerType = computed(function () { var isDateTimeType = computeIsDateTimeType.value return ( isDateTimeType || ['date', 'week', 'month', 'quarter', 'year'].indexOf(props2.type) > -1 ) }) var computeIsPawdType = computed(function () { return props2.type === 'password' }) var computeIsSearchType = computed(function () { return props2.type === 'search' }) var computeDigitsValue = computed(function () { return xeUtils.toInteger(props2.digits) || 1 }) var computeStepValue = computed(function () { var type4 = props2.type var digitsValue = computeDigitsValue.value var step = props2.step if (type4 === 'integer') { return xeUtils.toInteger(step) || 1 } else if (type4 === 'float') { return xeUtils.toNumber(step) || 1 / Math.pow(10, digitsValue) } return xeUtils.toNumber(step) || 1 }) var computeIsClearable = computed(function () { var type4 = props2.type var isNumType = computeIsNumType.value var isDatePickerType = computeIsDatePickerType.value var isPawdType = computeIsPawdType.value return ( props2.clearable && (isPawdType || isNumType || isDatePickerType || type4 === 'text' || type4 === 'search') ) }) var computeDateStartTime = computed(function () { return props2.startDate ? xeUtils.toStringDate(props2.startDate) : null }) var computeDateEndTime = computed(function () { return props2.endDate ? xeUtils.toStringDate(props2.endDate) : null }) var computeSupportMultiples = computed(function () { return ['date', 'week', 'month', 'quarter', 'year'].includes(props2.type) }) var computeDateListValue = computed(function () { var modelValue = props2.modelValue, multiple = props2.multiple var isDatePickerType = computeIsDatePickerType.value var dateValueFormat = computeDateValueFormat.value if (multiple && modelValue && isDatePickerType) { return xeUtils .toValueString(modelValue) .split(',') .map(function (item2) { var date4 = parseDate2(item2, dateValueFormat) if (xeUtils.isValidDate(date4)) { return date4 } return null }) } return [] }) var computeDateMultipleValue = computed(function () { var dateListValue = computeDateListValue.value var dateValueFormat = computeDateValueFormat.value return dateListValue.map(function (date4) { return xeUtils.toDateString(date4, dateValueFormat) }) }) var computeDateMultipleLabel = computed(function () { var dateListValue = computeDateListValue.value var dateLabelFormat = computeDateLabelFormat.value return dateListValue .map(function (date4) { return xeUtils.toDateString(date4, dateLabelFormat) }) .join(', ') }) var computeDateValueFormat = computed(function () { var type4 = props2.type return type4 === 'time' ? 'HH:mm:ss' : props2.valueFormat || (type4 === 'datetime' ? 'yyyy-MM-dd HH:mm:ss' : 'yyyy-MM-dd') }) var computeDateValue = computed(function () { var modelValue = props2.modelValue var isDatePickerType = computeIsDatePickerType.value var dateValueFormat = computeDateValueFormat.value var val2 = null if (modelValue && isDatePickerType) { var date4 = parseDate2(modelValue, dateValueFormat) if (xeUtils.isValidDate(date4)) { val2 = date4 } } return val2 }) var computeIsDisabledPrevDateBtn = computed(function () { var dateStartTime = computeDateStartTime.value var selectMonth = reactData.selectMonth if (selectMonth && dateStartTime) { return selectMonth <= dateStartTime } return false }) var computeIsDisabledNextDateBtn = computed(function () { var dateEndTime = computeDateEndTime.value var selectMonth = reactData.selectMonth if (selectMonth && dateEndTime) { return selectMonth >= dateEndTime } return false }) var computeDateTimeLabel = computed(function () { var datetimePanelValue = reactData.datetimePanelValue if (datetimePanelValue) { return xeUtils.toDateString(datetimePanelValue, 'HH:mm:ss') } return '' }) var computeDateHMSTime = computed(function () { var dateValue = computeDateValue.value var isDateTimeType = computeIsDateTimeType.value return dateValue && isDateTimeType ? (dateValue.getHours() * 3600 + dateValue.getMinutes() * 60 + dateValue.getSeconds()) * 1e3 : 0 }) var computeDateLabelFormat = computed(function () { var isDatePickerType = computeIsDatePickerType.value if (isDatePickerType) { return ( props2.labelFormat || GlobalConfig.i18n('vxe.input.date.labelFormat.'.concat(props2.type)) ) } return null }) var computeYearList = computed(function () { var selectMonth = reactData.selectMonth, currentDate = reactData.currentDate var years = [] if (selectMonth && currentDate) { var currFullYear = currentDate.getFullYear() var selectFullYear = selectMonth.getFullYear() var startYearDate = new Date( selectFullYear - (selectFullYear % yearSize), 0, 1 ) for (var index2 = -4; index2 < yearSize + 4; index2++) { var date4 = xeUtils.getWhatYear(startYearDate, index2, 'first') var itemFullYear = date4.getFullYear() years.push({ date: date4, isCurrent: true, isPrev: index2 < 0, isNow: currFullYear === itemFullYear, isNext: index2 >= yearSize, year: itemFullYear, }) } } return years }) var computeSelectDatePanelLabel = computed(function () { var isDatePickerType = computeIsDatePickerType.value if (isDatePickerType) { var datePanelType = reactData.datePanelType, selectMonth = reactData.selectMonth var yearList = computeYearList.value var year = '' var month = void 0 if (selectMonth) { year = selectMonth.getFullYear() month = selectMonth.getMonth() + 1 } if (datePanelType === 'quarter') { return GlobalConfig.i18n('vxe.input.date.quarterLabel', [year]) } else if (datePanelType === 'month') { return GlobalConfig.i18n('vxe.input.date.monthLabel', [year]) } else if (datePanelType === 'year') { return yearList.length ? '' .concat(yearList[0].year, ' - ') .concat(yearList[yearList.length - 1].year) : '' } return GlobalConfig.i18n('vxe.input.date.dayLabel', [ year, month ? GlobalConfig.i18n('vxe.input.date.m'.concat(month)) : '-', ]) } return '' }) var computeFirstDayOfWeek = computed(function () { var startDay = props2.startDay, startWeek = props2.startWeek return xeUtils.toNumber( xeUtils.isNumber(startDay) || xeUtils.isString(startDay) ? startDay : startWeek ) }) var computeWeekDatas = computed(function () { var weeks = [] var isDatePickerType = computeIsDatePickerType.value if (isDatePickerType) { var sWeek = computeFirstDayOfWeek.value weeks.push(sWeek) for (var index2 = 0; index2 < 6; index2++) { if (sWeek >= 6) { sWeek = 0 } else { sWeek++ } weeks.push(sWeek) } } return weeks }) var computeDateHeaders = computed(function () { var isDatePickerType = computeIsDatePickerType.value if (isDatePickerType) { var weekDatas = computeWeekDatas.value return weekDatas.map(function (day) { return { value: day, label: GlobalConfig.i18n('vxe.input.date.weeks.w'.concat(day)), } }) } return [] }) var computeWeekHeaders = computed(function () { var isDatePickerType = computeIsDatePickerType.value if (isDatePickerType) { var dateHeaders = computeDateHeaders.value return [{ label: GlobalConfig.i18n('vxe.input.date.weeks.w') }].concat( dateHeaders ) } return [] }) var computeYearDatas = computed(function () { var yearList = computeYearList.value return xeUtils.chunk(yearList, 4) }) var computeQuarterList = computed(function () { var selectMonth = reactData.selectMonth, currentDate = reactData.currentDate var quarters = [] if (selectMonth && currentDate) { var currFullYear = currentDate.getFullYear() var currQuarter = getDateQuarter(currentDate) var firstYear = xeUtils.getWhatYear(selectMonth, 0, 'first') var selFullYear = firstYear.getFullYear() for (var index2 = -2; index2 < quarterSize - 2; index2++) { var date4 = xeUtils.getWhatQuarter(firstYear, index2) var itemFullYear = date4.getFullYear() var itemQuarter = getDateQuarter(date4) var isPrev = itemFullYear < selFullYear quarters.push({ date: date4, isPrev, isCurrent: itemFullYear === selFullYear, isNow: itemFullYear === currFullYear && itemQuarter === currQuarter, isNext: !isPrev && itemFullYear > selFullYear, quarter: itemQuarter, }) } } return quarters }) var computeQuarterDatas = computed(function () { var quarterList = computeQuarterList.value return xeUtils.chunk(quarterList, 2) }) var computeMonthList = computed(function () { var selectMonth = reactData.selectMonth, currentDate = reactData.currentDate var months = [] if (selectMonth && currentDate) { var currFullYear = currentDate.getFullYear() var currMonth = currentDate.getMonth() var selFullYear = xeUtils .getWhatYear(selectMonth, 0, 'first') .getFullYear() for (var index2 = -4; index2 < monthSize - 4; index2++) { var date4 = xeUtils.getWhatYear(selectMonth, 0, index2) var itemFullYear = date4.getFullYear() var itemMonth = date4.getMonth() var isPrev = itemFullYear < selFullYear months.push({ date: date4, isPrev, isCurrent: itemFullYear === selFullYear, isNow: itemFullYear === currFullYear && itemMonth === currMonth, isNext: !isPrev && itemFullYear > selFullYear, month: itemMonth, }) } } return months }) var computeMonthDatas = computed(function () { var monthList = computeMonthList.value return xeUtils.chunk(monthList, 4) }) var computeDayList = computed(function () { var selectMonth = reactData.selectMonth, currentDate = reactData.currentDate var days = [] if (selectMonth && currentDate) { var dateHMSTime = computeDateHMSTime.value var weekDatas = computeWeekDatas.value var currFullYear = currentDate.getFullYear() var currMonth = currentDate.getMonth() var currDate = currentDate.getDate() var selFullYear = selectMonth.getFullYear() var selMonth = selectMonth.getMonth() var selDay = selectMonth.getDay() var prevOffsetDate = -weekDatas.indexOf(selDay) var startDayDate = new Date( xeUtils.getWhatDay(selectMonth, prevOffsetDate).getTime() + dateHMSTime ) for (var index2 = 0; index2 < 42; index2++) { var date4 = xeUtils.getWhatDay(startDayDate, index2) var itemFullYear = date4.getFullYear() var itemMonth = date4.getMonth() var itemDate = date4.getDate() var isPrev = date4 < selectMonth days.push({ date: date4, isPrev, isCurrent: itemFullYear === selFullYear && itemMonth === selMonth, isNow: itemFullYear === currFullYear && itemMonth === currMonth && itemDate === currDate, isNext: !isPrev && selMonth !== itemMonth, label: itemDate, }) } } return days }) var computeDayDatas = computed(function () { var dayList = computeDayList.value return xeUtils.chunk(dayList, 7) }) var computeWeekDates = computed(function () { var dayDatas = computeDayDatas.value var firstDayOfWeek = computeFirstDayOfWeek.value return dayDatas.map(function (list2) { var firstItem = list2[0] var item2 = { date: firstItem.date, isWeekNumber: true, isPrev: false, isCurrent: false, isNow: false, isNext: false, label: xeUtils.getYearWeek(firstItem.date, firstDayOfWeek), } return [item2].concat(list2) }) }) var computeHourList = computed(function () { var list2 = [] var isDateTimeType = computeIsDateTimeType.value if (isDateTimeType) { for (var index2 = 0; index2 < 24; index2++) { list2.push({ value: index2, label: ('' + index2).padStart(2, '0'), }) } } return list2 }) var computeMinuteList = computed(function () { var list2 = [] var isDateTimeType = computeIsDateTimeType.value if (isDateTimeType) { for (var index2 = 0; index2 < 60; index2++) { list2.push({ value: index2, label: ('' + index2).padStart(2, '0'), }) } } return list2 }) var computeSecondList = computed(function () { var minuteList = computeMinuteList.value return minuteList }) var computeInpReadonly = computed(function () { var type4 = props2.type, readonly2 = props2.readonly, editable = props2.editable, multiple = props2.multiple return ( readonly2 || multiple || !editable || type4 === 'week' || type4 === 'quarter' ) }) var computeInputType = computed(function () { var type4 = props2.type var showPwd = reactData.showPwd var isNumType = computeIsNumType.value var isDatePickerType = computeIsDatePickerType.value var isPawdType = computeIsPawdType.value if ( isDatePickerType || isNumType || (isPawdType && showPwd) || type4 === 'number' ) { return 'text' } return type4 }) var computeInpPlaceholder = computed(function () { var placeholder = props2.placeholder if (placeholder) { return getFuncText(placeholder) } return '' }) var computeInpMaxlength = computed(function () { var maxlength = props2.maxlength var isNumType = computeIsNumType.value return isNumType && !xeUtils.toNumber(maxlength) ? 16 : maxlength }) var computeInpImmediate = computed(function () { var type4 = props2.type, immediate = props2.immediate return ( immediate || !( type4 === 'text' || type4 === 'number' || type4 === 'integer' || type4 === 'float' ) ) }) var computeNumValue = computed(function () { var type4 = props2.type var inputValue = reactData.inputValue var isNumType = computeIsNumType.value if (isNumType) { return type4 === 'integer' ? xeUtils.toInteger(handleNumber(inputValue)) : xeUtils.toNumber(handleNumber(inputValue)) } return 0 }) var computeIsDisabledSubtractNumber = computed(function () { var min3 = props2.min var inputValue = reactData.inputValue var isNumType = computeIsNumType.value var numValue = computeNumValue.value if ((inputValue || inputValue === 0) && isNumType && min3 !== null) { return numValue <= xeUtils.toNumber(min3) } return false }) var computeIsDisabledAddNumber = computed(function () { var max3 = props2.max var inputValue = reactData.inputValue var isNumType = computeIsNumType.value var numValue = computeNumValue.value if ((inputValue || inputValue === 0) && isNumType && max3 !== null) { return numValue >= xeUtils.toNumber(max3) } return false }) var getNumberValue = function (val2) { var type4 = props2.type, exponential = props2.exponential var inpMaxlength = computeInpMaxlength.value var digitsValue = computeDigitsValue.value var restVal = type4 === 'float' ? toFloatValueFixed(val2, digitsValue) : xeUtils.toValueString(val2) if ( exponential && (val2 === restVal || xeUtils.toValueString(val2).toLowerCase() === xeUtils.toNumber(restVal).toExponential()) ) { return val2 } return restVal.slice(0, inpMaxlength) } var triggerEvent2 = function (evnt) { var inputValue = reactData.inputValue inputMethods.dispatchEvent(evnt.type, { value: inputValue }, evnt) } var emitModel = function (value2, evnt) { reactData.inputValue = value2 emit2('update:modelValue', value2) inputMethods.dispatchEvent('input', { value: value2 }, evnt) if (xeUtils.toValueString(props2.modelValue) !== value2) { inputMethods.dispatchEvent('change', { value: value2 }, evnt) if ($xeform && $xeformiteminfo) { $xeform.triggerItemEvent( evnt, $xeformiteminfo.itemConfig.field, value2 ) } } } var emitInputEvent = function (value2, evnt) { var isDatePickerType = computeIsDatePickerType.value var inpImmediate = computeInpImmediate.value reactData.inputValue = value2 if (!isDatePickerType) { if (inpImmediate) { emitModel(value2, evnt) } else { inputMethods.dispatchEvent('input', { value: value2 }, evnt) } } } var inputEvent = function (evnt) { var inputElem = evnt.target var value2 = inputElem.value emitInputEvent(value2, evnt) } var changeEvent = function (evnt) { var inpImmediate = computeInpImmediate.value if (!inpImmediate) { triggerEvent2(evnt) } } var focusEvent = function (evnt) { reactData.isActivated = true var isDatePickerType = computeIsDatePickerType.value if (isDatePickerType) { datePickerOpenEvent(evnt) } triggerEvent2(evnt) } var clickPrefixEvent = function (evnt) { var disabled = props2.disabled if (!disabled) { var inputValue = reactData.inputValue inputMethods.dispatchEvent('prefix-click', { value: inputValue }, evnt) } } var hidePanelTimeout var hidePanel = function () { return new Promise(function (resolve2) { reactData.visiblePanel = false hidePanelTimeout = window.setTimeout(function () { reactData.animatVisible = false resolve2() }, 350) }) } var clearValueEvent = function (evnt, value2) { var type4 = props2.type var isNumType = computeIsNumType.value var isDatePickerType = computeIsDatePickerType.value if (isDatePickerType) { hidePanel() } if (isNumType || ['text', 'search', 'password'].indexOf(type4) > -1) { focus() } inputMethods.dispatchEvent('clear', { value: value2 }, evnt) } var clickSuffixEvent = function (evnt) { var disabled = props2.disabled if (!disabled) { if (hasClass(evnt.currentTarget, 'is--clear')) { emitModel('', evnt) clearValueEvent(evnt, '') } else { var inputValue = reactData.inputValue inputMethods.dispatchEvent( 'suffix-click', { value: inputValue }, evnt ) } } } var dateParseValue = function (value2) { var type4 = props2.type var valueFormat = props2.valueFormat var dateLabelFormat = computeDateLabelFormat.value var firstDayOfWeek = computeFirstDayOfWeek.value var dValue = null var dLabel = '' if (value2) { dValue = parseDate2(value2, valueFormat) } if (xeUtils.isValidDate(dValue)) { dLabel = xeUtils.toDateString(dValue, dateLabelFormat, { firstDay: firstDayOfWeek, }) if (dateLabelFormat && type4 === 'week') { var firstWeekDate = xeUtils.getWhatWeek( dValue, 0, firstDayOfWeek, firstDayOfWeek ) if (firstWeekDate.getFullYear() < dValue.getFullYear()) { var yyIndex = dateLabelFormat.indexOf('yyyy') if (yyIndex > -1) { var yyNum = Number(dLabel.substring(yyIndex, yyIndex + 4)) if (yyNum && !isNaN(yyNum)) { dLabel = dLabel.replace(''.concat(yyNum), ''.concat(yyNum - 1)) } } } } } else { dValue = null } reactData.datePanelValue = dValue reactData.datePanelLabel = dLabel } var changeValue = function () { var isDatePickerType = computeIsDatePickerType.value var inputValue = reactData.inputValue if (isDatePickerType) { dateParseValue(inputValue) reactData.inputValue = props2.multiple ? computeDateMultipleLabel.value : reactData.datePanelLabel } } var initValue = function () { var type4 = props2.type var inputValue = reactData.inputValue var isDatePickerType = computeIsDatePickerType.value var digitsValue = computeDigitsValue.value if (isDatePickerType) { changeValue() } else if (type4 === 'float') { if (inputValue) { var validValue = toFloatValueFixed(inputValue, digitsValue) if (inputValue !== validValue) { emitModel(validValue, { type: 'init' }) } } } } var vaildMaxNum = function (num2) { return ( props2.max === null || xeUtils.toNumber(num2) <= xeUtils.toNumber(props2.max) ) } var vaildMinNum = function (num2) { return ( props2.min === null || xeUtils.toNumber(num2) >= xeUtils.toNumber(props2.min) ) } var dateRevert = function () { reactData.inputValue = props2.multiple ? computeDateMultipleLabel.value : reactData.datePanelLabel } var dateCheckMonth = function (date4) { var month = xeUtils.getWhatMonth(date4, 0, 'first') if (!xeUtils.isEqual(month, reactData.selectMonth)) { reactData.selectMonth = month } } var dateChange = function (date4) { var modelValue = props2.modelValue, multiple = props2.multiple var datetimePanelValue = reactData.datetimePanelValue var isDateTimeType = computeIsDateTimeType.value var dateValueFormat = computeDateValueFormat.value var firstDayOfWeek = computeFirstDayOfWeek.value if (props2.type === 'week') { var sWeek = xeUtils.toNumber(props2.selectDay) date4 = xeUtils.getWhatWeek(date4, 0, sWeek, firstDayOfWeek) } else if (isDateTimeType) { date4.setHours(datetimePanelValue.getHours()) date4.setMinutes(datetimePanelValue.getMinutes()) date4.setSeconds(datetimePanelValue.getSeconds()) } var inpVal = xeUtils.toDateString(date4, dateValueFormat, { firstDay: firstDayOfWeek, }) dateCheckMonth(date4) if (multiple) { var dateMultipleValue = computeDateMultipleValue.value if (isDateTimeType) { var dateListValue = __spreadArray$4( [], computeDateListValue.value, true ) var datetimeRest_1 = [] var eqIndex = xeUtils.findIndexOf(dateListValue, function (val2) { return xeUtils.isDateSame(date4, val2, 'yyyyMMdd') }) if (eqIndex === -1) { dateListValue.push(date4) } else { dateListValue.splice(eqIndex, 1) } dateListValue.forEach(function (item2) { if (item2) { item2.setHours(datetimePanelValue.getHours()) item2.setMinutes(datetimePanelValue.getMinutes()) item2.setSeconds(datetimePanelValue.getSeconds()) datetimeRest_1.push(item2) } }) emitModel( datetimeRest_1 .map(function (date5) { return xeUtils.toDateString(date5, dateValueFormat) }) .join(','), { type: 'update' } ) } else { if ( dateMultipleValue.some(function (val2) { return xeUtils.isEqual(val2, inpVal) }) ) { emitModel( dateMultipleValue .filter(function (val2) { return !xeUtils.isEqual(val2, inpVal) }) .join(','), { type: 'update' } ) } else { emitModel(dateMultipleValue.concat([inpVal]).join(','), { type: 'update', }) } } } else { if (!xeUtils.isEqual(modelValue, inpVal)) { emitModel(inpVal, { type: 'update' }) } } } var afterCheckValue = function () { var type4 = props2.type, min3 = props2.min, max3 = props2.max, exponential = props2.exponential var inputValue = reactData.inputValue, datetimePanelValue = reactData.datetimePanelValue var isNumType = computeIsNumType.value var isDatePickerType = computeIsDatePickerType.value var dateLabelFormat = computeDateLabelFormat.value var inpReadonly = computeInpReadonly.value if (!inpReadonly) { if (isNumType) { if (inputValue) { var inpNumVal = type4 === 'integer' ? xeUtils.toInteger(handleNumber(inputValue)) : xeUtils.toNumber(handleNumber(inputValue)) if (!vaildMinNum(inpNumVal)) { inpNumVal = min3 } else if (!vaildMaxNum(inpNumVal)) { inpNumVal = max3 } if (exponential) { var inpStringVal = xeUtils.toValueString(inputValue).toLowerCase() if ( inpStringVal === xeUtils.toNumber(inpNumVal).toExponential() ) { inpNumVal = inpStringVal } } emitModel(getNumberValue(inpNumVal), { type: 'check' }) } } else if (isDatePickerType) { if (inputValue) { var inpDateVal = parseDate2(inputValue, dateLabelFormat) if (xeUtils.isValidDate(inpDateVal)) { if (type4 === 'time') { inpDateVal = xeUtils.toDateString(inpDateVal, dateLabelFormat) if (inputValue !== inpDateVal) { emitModel(inpDateVal, { type: 'check' }) } reactData.inputValue = inpDateVal } else { var isChange = false var firstDayOfWeek = computeFirstDayOfWeek.value if (type4 === 'datetime') { var dateValue = computeDateValue.value if ( inputValue !== xeUtils.toDateString(dateValue, dateLabelFormat) || inputValue !== xeUtils.toDateString(inpDateVal, dateLabelFormat) ) { isChange = true datetimePanelValue.setHours(inpDateVal.getHours()) datetimePanelValue.setMinutes(inpDateVal.getMinutes()) datetimePanelValue.setSeconds(inpDateVal.getSeconds()) } } else { isChange = true } reactData.inputValue = xeUtils.toDateString( inpDateVal, dateLabelFormat, { firstDay: firstDayOfWeek } ) if (isChange) { dateChange(inpDateVal) } } } else { dateRevert() } } else { emitModel('', { type: 'check' }) } } } } var blurEvent = function (evnt) { var inputValue = reactData.inputValue var inpImmediate = computeInpImmediate.value if (!inpImmediate) { emitModel(inputValue, evnt) } afterCheckValue() if (!reactData.visiblePanel) { reactData.isActivated = false } inputMethods.dispatchEvent('blur', { value: inputValue }, evnt) } var passwordToggleEvent = function (evnt) { var readonly2 = props2.readonly, disabled = props2.disabled var showPwd = reactData.showPwd if (!disabled && !readonly2) { reactData.showPwd = !showPwd } inputMethods.dispatchEvent( 'toggle-visible', { visible: reactData.showPwd }, evnt ) } var searchEvent = function (evnt) { inputMethods.dispatchEvent('search-click', {}, evnt) } var numberChange = function (isPlus, evnt) { var min3 = props2.min, max3 = props2.max, type4 = props2.type var inputValue = reactData.inputValue var stepValue = computeStepValue.value var numValue = type4 === 'integer' ? xeUtils.toInteger(handleNumber(inputValue)) : xeUtils.toNumber(handleNumber(inputValue)) var newValue = isPlus ? xeUtils.add(numValue, stepValue) : xeUtils.subtract(numValue, stepValue) var restNum if (!vaildMinNum(newValue)) { restNum = min3 } else if (!vaildMaxNum(newValue)) { restNum = max3 } else { restNum = newValue } emitInputEvent(getNumberValue(restNum), evnt) } var downbumTimeout var numberNextEvent = function (evnt) { var readonly2 = props2.readonly, disabled = props2.disabled var isDisabledSubtractNumber = computeIsDisabledSubtractNumber.value clearTimeout(downbumTimeout) if (!disabled && !readonly2 && !isDisabledSubtractNumber) { numberChange(false, evnt) } inputMethods.dispatchEvent('next-number', {}, evnt) } var numberDownNextEvent = function (evnt) { downbumTimeout = window.setTimeout(function () { numberNextEvent(evnt) numberDownNextEvent(evnt) }, 60) } var numberPrevEvent = function (evnt) { var readonly2 = props2.readonly, disabled = props2.disabled var isDisabledAddNumber = computeIsDisabledAddNumber.value clearTimeout(downbumTimeout) if (!disabled && !readonly2 && !isDisabledAddNumber) { numberChange(true, evnt) } inputMethods.dispatchEvent('prev-number', {}, evnt) } var numberKeydownEvent = function (evnt) { var isUpArrow = hasEventKey(evnt, EVENT_KEYS.ARROW_UP) var isDwArrow = hasEventKey(evnt, EVENT_KEYS.ARROW_DOWN) if (isUpArrow || isDwArrow) { evnt.preventDefault() if (isUpArrow) { numberPrevEvent(evnt) } else { numberNextEvent(evnt) } } } var keydownEvent = function (evnt) { var exponential = props2.exponential, controls = props2.controls var isNumType = computeIsNumType.value if (isNumType) { var isCtrlKey2 = evnt.ctrlKey var isShiftKey = evnt.shiftKey var isAltKey = evnt.altKey var keyCode = evnt.keyCode if ( !isCtrlKey2 && !isShiftKey && !isAltKey && (hasEventKey(evnt, EVENT_KEYS.SPACEBAR) || ((!exponential || keyCode !== 69) && keyCode >= 65 && keyCode <= 90) || (keyCode >= 186 && keyCode <= 188) || keyCode >= 191) ) { evnt.preventDefault() } if (controls) { numberKeydownEvent(evnt) } } triggerEvent2(evnt) } var keyupEvent = function (evnt) { triggerEvent2(evnt) } var numberStopDown = function () { clearTimeout(downbumTimeout) } var numberDownPrevEvent = function (evnt) { downbumTimeout = window.setTimeout(function () { numberPrevEvent(evnt) numberDownPrevEvent(evnt) }, 60) } var numberMousedownEvent = function (evnt) { numberStopDown() if (evnt.button === 0) { var isPrevNumber_1 = hasClass(evnt.currentTarget, 'is--prev') if (isPrevNumber_1) { numberPrevEvent(evnt) } else { numberNextEvent(evnt) } downbumTimeout = window.setTimeout(function () { if (isPrevNumber_1) { numberDownPrevEvent(evnt) } else { numberDownNextEvent(evnt) } }, 500) } } var wheelEvent = function (evnt) { var isNumType = computeIsNumType.value if (isNumType && props2.controls) { if (reactData.isActivated) { var delta = evnt.deltaY if (delta > 0) { numberNextEvent(evnt) } else if (delta < 0) { numberPrevEvent(evnt) } evnt.preventDefault() } } triggerEvent2(evnt) } var dateMonthHandle = function (date4, offsetMonth) { reactData.selectMonth = xeUtils.getWhatMonth(date4, offsetMonth, 'first') } var dateNowHandle = function () { var currentDate = xeUtils.getWhatDay(Date.now(), 0, 'first') reactData.currentDate = currentDate dateMonthHandle(currentDate, 0) } var dateToggleTypeEvent = function () { var datePanelType = reactData.datePanelType if (datePanelType === 'month' || datePanelType === 'quarter') { datePanelType = 'year' } else { datePanelType = 'month' } reactData.datePanelType = datePanelType } var datePrevEvent = function (evnt) { var type4 = props2.type var datePanelType = reactData.datePanelType, selectMonth = reactData.selectMonth var isDisabledPrevDateBtn = computeIsDisabledPrevDateBtn.value if (!isDisabledPrevDateBtn) { if (type4 === 'year') { reactData.selectMonth = xeUtils.getWhatYear( selectMonth, -yearSize, 'first' ) } else if (type4 === 'month' || type4 === 'quarter') { if (datePanelType === 'year') { reactData.selectMonth = xeUtils.getWhatYear( selectMonth, -yearSize, 'first' ) } else { reactData.selectMonth = xeUtils.getWhatYear( selectMonth, -1, 'first' ) } } else { if (datePanelType === 'year') { reactData.selectMonth = xeUtils.getWhatYear( selectMonth, -yearSize, 'first' ) } else if (datePanelType === 'month') { reactData.selectMonth = xeUtils.getWhatYear( selectMonth, -1, 'first' ) } else { reactData.selectMonth = xeUtils.getWhatMonth( selectMonth, -1, 'first' ) } } inputMethods.dispatchEvent('date-prev', { type: type4 }, evnt) } } var dateTodayMonthEvent = function (evnt) { dateNowHandle() if (!props2.multiple) { dateChange(reactData.currentDate) hidePanel() } inputMethods.dispatchEvent('date-today', { type: props2.type }, evnt) } var dateNextEvent = function (evnt) { var type4 = props2.type var datePanelType = reactData.datePanelType, selectMonth = reactData.selectMonth var isDisabledNextDateBtn = computeIsDisabledNextDateBtn.value if (!isDisabledNextDateBtn) { if (type4 === 'year') { reactData.selectMonth = xeUtils.getWhatYear( selectMonth, yearSize, 'first' ) } else if (type4 === 'month' || type4 === 'quarter') { if (datePanelType === 'year') { reactData.selectMonth = xeUtils.getWhatYear( selectMonth, yearSize, 'first' ) } else { reactData.selectMonth = xeUtils.getWhatYear(selectMonth, 1, 'first') } } else { if (datePanelType === 'year') { reactData.selectMonth = xeUtils.getWhatYear( selectMonth, yearSize, 'first' ) } else if (datePanelType === 'month') { reactData.selectMonth = xeUtils.getWhatYear(selectMonth, 1, 'first') } else { reactData.selectMonth = xeUtils.getWhatMonth( selectMonth, 1, 'first' ) } } inputMethods.dispatchEvent('date-next', { type: type4 }, evnt) } } var isDateDisabled = function (item2) { var disabledMethod = props2.disabledMethod var datePanelType = reactData.datePanelType return ( disabledMethod && disabledMethod({ type: datePanelType, viewType: datePanelType, date: item2.date, $input: $xeinput, }) ) } var dateSelectItem = function (date4) { var type4 = props2.type, multiple = props2.multiple var datePanelType = reactData.datePanelType if (type4 === 'month') { if (datePanelType === 'year') { reactData.datePanelType = 'month' dateCheckMonth(date4) } else { dateChange(date4) if (!multiple) { hidePanel() } } } else if (type4 === 'year') { dateChange(date4) if (!multiple) { hidePanel() } } else if (type4 === 'quarter') { if (datePanelType === 'year') { reactData.datePanelType = 'quarter' dateCheckMonth(date4) } else { dateChange(date4) if (!multiple) { hidePanel() } } } else { if (datePanelType === 'month') { reactData.datePanelType = type4 === 'week' ? type4 : 'day' dateCheckMonth(date4) } else if (datePanelType === 'year') { reactData.datePanelType = 'month' dateCheckMonth(date4) } else { dateChange(date4) if (!multiple) { hidePanel() } } } } var dateSelectEvent = function (item2) { if (!isDateDisabled(item2)) { dateSelectItem(item2.date) } } var dateMoveDay = function (offsetDay) { if (!isDateDisabled({ date: offsetDay })) { var dayList = computeDayList.value if ( !dayList.some(function (item2) { return xeUtils.isDateSame(item2.date, offsetDay, 'yyyyMMdd') }) ) { dateCheckMonth(offsetDay) } dateParseValue(offsetDay) } } var dateMoveYear = function (offsetYear) { if (!isDateDisabled({ date: offsetYear })) { var yearList = computeYearList.value if ( !yearList.some(function (item2) { return xeUtils.isDateSame(item2.date, offsetYear, 'yyyy') }) ) { dateCheckMonth(offsetYear) } dateParseValue(offsetYear) } } var dateMoveQuarter = function (offsetQuarter) { if (!isDateDisabled({ date: offsetQuarter })) { var quarterList = computeQuarterList.value if ( !quarterList.some(function (item2) { return xeUtils.isDateSame(item2.date, offsetQuarter, 'yyyyq') }) ) { dateCheckMonth(offsetQuarter) } dateParseValue(offsetQuarter) } } var dateMoveMonth = function (offsetMonth) { if (!isDateDisabled({ date: offsetMonth })) { var monthList = computeMonthList.value if ( !monthList.some(function (item2) { return xeUtils.isDateSame(item2.date, offsetMonth, 'yyyyMM') }) ) { dateCheckMonth(offsetMonth) } dateParseValue(offsetMonth) } } var dateMouseenterEvent = function (item2) { if (!isDateDisabled(item2)) { var datePanelType = reactData.datePanelType if (datePanelType === 'month') { dateMoveMonth(item2.date) } else if (datePanelType === 'quarter') { dateMoveQuarter(item2.date) } else if (datePanelType === 'year') { dateMoveYear(item2.date) } else { dateMoveDay(item2.date) } } } var updateTimePos = function (liElem) { if (liElem) { var height = liElem.offsetHeight var ulElem = liElem.parentNode ulElem.scrollTop = liElem.offsetTop - height * 4 } } var dateTimeChangeEvent = function (evnt) { reactData.datetimePanelValue = new Date( reactData.datetimePanelValue.getTime() ) updateTimePos(evnt.currentTarget) } var dateHourEvent = function (evnt, item2) { reactData.datetimePanelValue.setHours(item2.value) dateTimeChangeEvent(evnt) } var dateConfirmEvent = function () { var multiple = props2.multiple var datetimePanelValue = reactData.datetimePanelValue var dateValue = computeDateValue.value var isDateTimeType = computeIsDateTimeType.value if (isDateTimeType) { var dateValueFormat_1 = computeDateValueFormat.value if (multiple) { var dateMultipleValue = computeDateMultipleValue.value if (isDateTimeType) { var dateListValue = __spreadArray$4( [], computeDateListValue.value, true ) var datetimeRest_2 = [] dateListValue.forEach(function (item2) { if (item2) { item2.setHours(datetimePanelValue.getHours()) item2.setMinutes(datetimePanelValue.getMinutes()) item2.setSeconds(datetimePanelValue.getSeconds()) datetimeRest_2.push(item2) } }) emitModel( datetimeRest_2 .map(function (date4) { return xeUtils.toDateString(date4, dateValueFormat_1) }) .join(','), { type: 'update' } ) } else { emitModel(dateMultipleValue.join(','), { type: 'update' }) } } else { dateChange(dateValue || reactData.currentDate) } } hidePanel() } var dateMinuteEvent = function (evnt, item2) { reactData.datetimePanelValue.setMinutes(item2.value) dateTimeChangeEvent(evnt) } var dateSecondEvent = function (evnt, item2) { reactData.datetimePanelValue.setSeconds(item2.value) dateTimeChangeEvent(evnt) } var dateOffsetEvent = function (evnt) { var isActivated = reactData.isActivated, datePanelValue = reactData.datePanelValue, datePanelType = reactData.datePanelType if (isActivated) { evnt.preventDefault() var isLeftArrow = hasEventKey(evnt, EVENT_KEYS.ARROW_LEFT) var isUpArrow = hasEventKey(evnt, EVENT_KEYS.ARROW_UP) var isRightArrow = hasEventKey(evnt, EVENT_KEYS.ARROW_RIGHT) var isDwArrow = hasEventKey(evnt, EVENT_KEYS.ARROW_DOWN) if (datePanelType === 'year') { var offsetYear = xeUtils.getWhatYear( datePanelValue || Date.now(), 0, 'first' ) if (isLeftArrow) { offsetYear = xeUtils.getWhatYear(offsetYear, -1) } else if (isUpArrow) { offsetYear = xeUtils.getWhatYear(offsetYear, -4) } else if (isRightArrow) { offsetYear = xeUtils.getWhatYear(offsetYear, 1) } else if (isDwArrow) { offsetYear = xeUtils.getWhatYear(offsetYear, 4) } dateMoveYear(offsetYear) } else if (datePanelType === 'quarter') { var offsetQuarter = xeUtils.getWhatQuarter( datePanelValue || Date.now(), 0, 'first' ) if (isLeftArrow) { offsetQuarter = xeUtils.getWhatQuarter(offsetQuarter, -1) } else if (isUpArrow) { offsetQuarter = xeUtils.getWhatQuarter(offsetQuarter, -2) } else if (isRightArrow) { offsetQuarter = xeUtils.getWhatQuarter(offsetQuarter, 1) } else if (isDwArrow) { offsetQuarter = xeUtils.getWhatQuarter(offsetQuarter, 2) } dateMoveQuarter(offsetQuarter) } else if (datePanelType === 'month') { var offsetMonth = xeUtils.getWhatMonth( datePanelValue || Date.now(), 0, 'first' ) if (isLeftArrow) { offsetMonth = xeUtils.getWhatMonth(offsetMonth, -1) } else if (isUpArrow) { offsetMonth = xeUtils.getWhatMonth(offsetMonth, -4) } else if (isRightArrow) { offsetMonth = xeUtils.getWhatMonth(offsetMonth, 1) } else if (isDwArrow) { offsetMonth = xeUtils.getWhatMonth(offsetMonth, 4) } dateMoveMonth(offsetMonth) } else { var offsetDay = datePanelValue || xeUtils.getWhatDay(Date.now(), 0, 'first') var firstDayOfWeek = computeFirstDayOfWeek.value if (isLeftArrow) { offsetDay = xeUtils.getWhatDay(offsetDay, -1) } else if (isUpArrow) { offsetDay = xeUtils.getWhatWeek(offsetDay, -1, firstDayOfWeek) } else if (isRightArrow) { offsetDay = xeUtils.getWhatDay(offsetDay, 1) } else if (isDwArrow) { offsetDay = xeUtils.getWhatWeek(offsetDay, 1, firstDayOfWeek) } dateMoveDay(offsetDay) } } } var datePgOffsetEvent = function (evnt) { var isActivated = reactData.isActivated if (isActivated) { var isPgUp = hasEventKey(evnt, EVENT_KEYS.PAGE_UP) evnt.preventDefault() if (isPgUp) { datePrevEvent(evnt) } else { dateNextEvent(evnt) } } } var dateOpenPanel = function () { var type4 = props2.type var isDateTimeType = computeIsDateTimeType.value var dateValue = computeDateValue.value if (['year', 'quarter', 'month', 'week'].indexOf(type4) > -1) { reactData.datePanelType = type4 } else { reactData.datePanelType = 'day' } reactData.currentDate = xeUtils.getWhatDay(Date.now(), 0, 'first') if (dateValue) { dateMonthHandle(dateValue, 0) dateParseValue(dateValue) } else { dateNowHandle() } if (isDateTimeType) { reactData.datetimePanelValue = reactData.datePanelValue || xeUtils.getWhatDay(Date.now(), 0, 'first') nextTick(function () { var timeBodyElem = refInputTimeBody.value xeUtils.arrayEach( timeBodyElem.querySelectorAll('li.is--selected'), updateTimePos ) }) } } var updateZindex = function () { if (reactData.panelIndex < getLastZIndex()) { reactData.panelIndex = nextZIndex() } } var updatePlacement = function () { return nextTick().then(function () { var transfer = props2.transfer, placement = props2.placement var panelIndex = reactData.panelIndex var targetElem = refInputTarget.value var panelElem = refInputPanel.value if (targetElem && panelElem) { var targetHeight = targetElem.offsetHeight var targetWidth = targetElem.offsetWidth var panelHeight = panelElem.offsetHeight var panelWidth = panelElem.offsetWidth var marginSize = 5 var panelStyle = { zIndex: panelIndex, } var _a2 = getAbsolutePos(targetElem), boundingTop = _a2.boundingTop, boundingLeft = _a2.boundingLeft, visibleHeight = _a2.visibleHeight, visibleWidth = _a2.visibleWidth var panelPlacement = 'bottom' if (transfer) { var left2 = boundingLeft var top_1 = boundingTop + targetHeight if (placement === 'top') { panelPlacement = 'top' top_1 = boundingTop - panelHeight } else if (!placement) { if (top_1 + panelHeight + marginSize > visibleHeight) { panelPlacement = 'top' top_1 = boundingTop - panelHeight } if (top_1 < marginSize) { panelPlacement = 'bottom' top_1 = boundingTop + targetHeight } } if (left2 + panelWidth + marginSize > visibleWidth) { left2 -= left2 + panelWidth + marginSize - visibleWidth } if (left2 < marginSize) { left2 = marginSize } Object.assign(panelStyle, { left: ''.concat(left2, 'px'), top: ''.concat(top_1, 'px'), minWidth: ''.concat(targetWidth, 'px'), }) } else { if (placement === 'top') { panelPlacement = 'top' panelStyle.bottom = ''.concat(targetHeight, 'px') } else if (!placement) { if (boundingTop + targetHeight + panelHeight > visibleHeight) { if (boundingTop - targetHeight - panelHeight > marginSize) { panelPlacement = 'top' panelStyle.bottom = ''.concat(targetHeight, 'px') } } } } reactData.panelStyle = panelStyle reactData.panelPlacement = panelPlacement return nextTick() } }) } var showPanel = function () { var disabled = props2.disabled var visiblePanel = reactData.visiblePanel var isDatePickerType = computeIsDatePickerType.value if (!disabled && !visiblePanel) { if (!reactData.inited) { reactData.inited = true } clearTimeout(hidePanelTimeout) reactData.isActivated = true reactData.animatVisible = true if (isDatePickerType) { dateOpenPanel() } setTimeout(function () { reactData.visiblePanel = true }, 10) updateZindex() return updatePlacement() } return nextTick() } var datePickerOpenEvent = function (evnt) { var readonly2 = props2.readonly if (!readonly2) { evnt.preventDefault() showPanel() } } var clickEvent = function (evnt) { triggerEvent2(evnt) } var handleGlobalMousedownEvent = function (evnt) { var disabled = props2.disabled var visiblePanel = reactData.visiblePanel, isActivated = reactData.isActivated var isDatePickerType = computeIsDatePickerType.value var el2 = refElem.value var panelElem = refInputPanel.value if (!disabled && isActivated) { reactData.isActivated = getEventTargetNode(evnt, el2).flag || getEventTargetNode(evnt, panelElem).flag if (!reactData.isActivated) { if (isDatePickerType) { if (visiblePanel) { hidePanel() afterCheckValue() } } else { afterCheckValue() } } } } var handleGlobalKeydownEvent = function (evnt) { var clearable = props2.clearable, disabled = props2.disabled var visiblePanel = reactData.visiblePanel var isDatePickerType = computeIsDatePickerType.value if (!disabled) { var isTab = hasEventKey(evnt, EVENT_KEYS.TAB) var isDel = hasEventKey(evnt, EVENT_KEYS.DELETE) var isEsc = hasEventKey(evnt, EVENT_KEYS.ESCAPE) var isEnter = hasEventKey(evnt, EVENT_KEYS.ENTER) var isLeftArrow = hasEventKey(evnt, EVENT_KEYS.ARROW_LEFT) var isUpArrow = hasEventKey(evnt, EVENT_KEYS.ARROW_UP) var isRightArrow = hasEventKey(evnt, EVENT_KEYS.ARROW_RIGHT) var isDwArrow = hasEventKey(evnt, EVENT_KEYS.ARROW_DOWN) var isPgUp = hasEventKey(evnt, EVENT_KEYS.PAGE_UP) var isPgDn = hasEventKey(evnt, EVENT_KEYS.PAGE_DOWN) var operArrow = isLeftArrow || isUpArrow || isRightArrow || isDwArrow var isActivated = reactData.isActivated if (isTab) { if (isActivated) { afterCheckValue() } isActivated = false reactData.isActivated = isActivated } else if (operArrow) { if (isDatePickerType) { if (isActivated) { if (visiblePanel) { dateOffsetEvent(evnt) } else if (isUpArrow || isDwArrow) { datePickerOpenEvent(evnt) } } } } else if (isEnter) { if (isDatePickerType) { if (visiblePanel) { if (reactData.datePanelValue) { dateSelectItem(reactData.datePanelValue) } else { hidePanel() } } else if (isActivated) { datePickerOpenEvent(evnt) } } } else if (isPgUp || isPgDn) { if (isDatePickerType) { if (isActivated) { datePgOffsetEvent(evnt) } } } if (isTab || isEsc) { if (visiblePanel) { hidePanel() } } else if (isDel && clearable) { if (isActivated) { clearValueEvent(evnt, null) } } } } var handleGlobalMousewheelEvent = function (evnt) { var disabled = props2.disabled var visiblePanel = reactData.visiblePanel if (!disabled) { if (visiblePanel) { var panelElem = refInputPanel.value if (getEventTargetNode(evnt, panelElem).flag) { updatePlacement() } else { hidePanel() afterCheckValue() } } } } var handleGlobalBlurEvent = function () { var isActivated = reactData.isActivated, visiblePanel = reactData.visiblePanel if (visiblePanel) { hidePanel() afterCheckValue() } else if (isActivated) { afterCheckValue() } } var renderDateLabel = function (item2, label) { var festivalMethod = props2.festivalMethod if (festivalMethod) { var datePanelType = reactData.datePanelType var festivalRest = festivalMethod({ type: datePanelType, viewType: datePanelType, date: item2.date, $input: $xeinput, }) var festivalItem = festivalRest ? xeUtils.isString(festivalRest) ? { label: festivalRest } : festivalRest : {} var extraItem = festivalItem.extra ? xeUtils.isString(festivalItem.extra) ? { label: festivalItem.extra } : festivalItem.extra : null var labels = [ h$4( 'span', { class: [ 'vxe-input--date-label', { 'is-notice': festivalItem.notice, }, ], }, extraItem && extraItem.label ? [ h$4('span', label), h$4( 'span', { class: [ 'vxe-input--date-label--extra', extraItem.important ? 'is-important' : '', extraItem.className, ], style: extraItem.style, }, xeUtils.toValueString(extraItem.label) ), ] : label ), ] var festivalLabel = festivalItem.label if (festivalLabel) { var festivalLabels = xeUtils.toValueString(festivalLabel).split(',') labels.push( h$4( 'span', { class: [ 'vxe-input--date-festival', festivalItem.important ? 'is-important' : '', festivalItem.className, ], style: festivalItem.style, }, [ festivalLabels.length > 1 ? h$4( 'span', { class: [ 'vxe-input--date-festival--overlap', 'overlap--'.concat(festivalLabels.length), ], }, festivalLabels.map(function (label2) { return h$4('span', label2.substring(0, 3)) }) ) : h$4( 'span', { class: 'vxe-input--date-festival--label', }, festivalLabels[0].substring(0, 3) ), ] ) ) } return labels } return label } var renderDateDayTable = function () { var multiple = props2.multiple var datePanelType = reactData.datePanelType, datePanelValue = reactData.datePanelValue var dateValue = computeDateValue.value var dateHeaders = computeDateHeaders.value var dayDatas = computeDayDatas.value var dateListValue = computeDateListValue.value var matchFormat = 'yyyyMMdd' return [ h$4( 'table', { class: 'vxe-input--date-'.concat(datePanelType, '-view'), cellspacing: 0, cellpadding: 0, border: 0, }, [ h$4('thead', [ h$4( 'tr', dateHeaders.map(function (item2) { return h$4('th', item2.label) }) ), ]), h$4( 'tbody', dayDatas.map(function (rows) { return h$4( 'tr', rows.map(function (item2) { return h$4( 'td', { class: { 'is--prev': item2.isPrev, 'is--current': item2.isCurrent, 'is--now': item2.isNow, 'is--next': item2.isNext, 'is--disabled': isDateDisabled(item2), 'is--selected': multiple ? dateListValue.some(function (val2) { return xeUtils.isDateSame( val2, item2.date, matchFormat ) }) : xeUtils.isDateSame( dateValue, item2.date, matchFormat ), 'is--hover': xeUtils.isDateSame( datePanelValue, item2.date, matchFormat ), }, onClick: function () { return dateSelectEvent(item2) }, onMouseenter: function () { return dateMouseenterEvent(item2) }, }, renderDateLabel(item2, item2.label) ) }) ) }) ), ] ), ] } var renderDateWeekTable = function () { var multiple = props2.multiple var datePanelType = reactData.datePanelType, datePanelValue = reactData.datePanelValue var dateValue = computeDateValue.value var weekHeaders = computeWeekHeaders.value var weekDates = computeWeekDates.value var dateListValue = computeDateListValue.value var matchFormat = 'yyyyMMdd' return [ h$4( 'table', { class: 'vxe-input--date-'.concat(datePanelType, '-view'), cellspacing: 0, cellpadding: 0, border: 0, }, [ h$4('thead', [ h$4( 'tr', weekHeaders.map(function (item2) { return h$4('th', item2.label) }) ), ]), h$4( 'tbody', weekDates.map(function (rows) { var isSelected = multiple ? rows.some(function (item2) { return dateListValue.some(function (val2) { return xeUtils.isDateSame(val2, item2.date, matchFormat) }) }) : rows.some(function (item2) { return xeUtils.isDateSame( dateValue, item2.date, matchFormat ) }) var isHover2 = rows.some(function (item2) { return xeUtils.isDateSame( datePanelValue, item2.date, matchFormat ) }) return h$4( 'tr', rows.map(function (item2) { return h$4( 'td', { class: { 'is--prev': item2.isPrev, 'is--current': item2.isCurrent, 'is--now': item2.isNow, 'is--next': item2.isNext, 'is--disabled': isDateDisabled(item2), 'is--selected': isSelected, 'is--hover': isHover2, }, onClick: function () { return dateSelectEvent(item2) }, onMouseenter: function () { return dateMouseenterEvent(item2) }, }, renderDateLabel(item2, item2.label) ) }) ) }) ), ] ), ] } var renderDateMonthTable = function () { var multiple = props2.multiple var datePanelType = reactData.datePanelType, datePanelValue = reactData.datePanelValue var dateValue = computeDateValue.value var monthDatas = computeMonthDatas.value var dateListValue = computeDateListValue.value var matchFormat = 'yyyyMM' return [ h$4( 'table', { class: 'vxe-input--date-'.concat(datePanelType, '-view'), cellspacing: 0, cellpadding: 0, border: 0, }, [ h$4( 'tbody', monthDatas.map(function (rows) { return h$4( 'tr', rows.map(function (item2) { return h$4( 'td', { class: { 'is--prev': item2.isPrev, 'is--current': item2.isCurrent, 'is--now': item2.isNow, 'is--next': item2.isNext, 'is--disabled': isDateDisabled(item2), 'is--selected': multiple ? dateListValue.some(function (val2) { return xeUtils.isDateSame( val2, item2.date, matchFormat ) }) : xeUtils.isDateSame( dateValue, item2.date, matchFormat ), 'is--hover': xeUtils.isDateSame( datePanelValue, item2.date, matchFormat ), }, onClick: function () { return dateSelectEvent(item2) }, onMouseenter: function () { return dateMouseenterEvent(item2) }, }, renderDateLabel( item2, GlobalConfig.i18n( 'vxe.input.date.months.m'.concat(item2.month) ) ) ) }) ) }) ), ] ), ] } var renderDateQuarterTable = function () { var multiple = props2.multiple var datePanelType = reactData.datePanelType, datePanelValue = reactData.datePanelValue var dateValue = computeDateValue.value var quarterDatas = computeQuarterDatas.value var dateListValue = computeDateListValue.value var matchFormat = 'yyyyq' return [ h$4( 'table', { class: 'vxe-input--date-'.concat(datePanelType, '-view'), cellspacing: 0, cellpadding: 0, border: 0, }, [ h$4( 'tbody', quarterDatas.map(function (rows) { return h$4( 'tr', rows.map(function (item2) { return h$4( 'td', { class: { 'is--prev': item2.isPrev, 'is--current': item2.isCurrent, 'is--now': item2.isNow, 'is--next': item2.isNext, 'is--disabled': isDateDisabled(item2), 'is--selected': multiple ? dateListValue.some(function (val2) { return xeUtils.isDateSame( val2, item2.date, matchFormat ) }) : xeUtils.isDateSame( dateValue, item2.date, matchFormat ), 'is--hover': xeUtils.isDateSame( datePanelValue, item2.date, matchFormat ), }, onClick: function () { return dateSelectEvent(item2) }, onMouseenter: function () { return dateMouseenterEvent(item2) }, }, renderDateLabel( item2, GlobalConfig.i18n( 'vxe.input.date.quarters.q'.concat(item2.quarter) ) ) ) }) ) }) ), ] ), ] } var renderDateYearTable = function () { var multiple = props2.multiple var datePanelType = reactData.datePanelType, datePanelValue = reactData.datePanelValue var dateValue = computeDateValue.value var yearDatas = computeYearDatas.value var dateListValue = computeDateListValue.value var matchFormat = 'yyyy' return [ h$4( 'table', { class: 'vxe-input--date-'.concat(datePanelType, '-view'), cellspacing: 0, cellpadding: 0, border: 0, }, [ h$4( 'tbody', yearDatas.map(function (rows) { return h$4( 'tr', rows.map(function (item2) { return h$4( 'td', { class: { 'is--prev': item2.isPrev, 'is--current': item2.isCurrent, 'is--now': item2.isNow, 'is--next': item2.isNext, 'is--disabled': isDateDisabled(item2), 'is--selected': multiple ? dateListValue.some(function (val2) { return xeUtils.isDateSame( val2, item2.date, matchFormat ) }) : xeUtils.isDateSame( dateValue, item2.date, matchFormat ), 'is--hover': xeUtils.isDateSame( datePanelValue, item2.date, matchFormat ), }, onClick: function () { return dateSelectEvent(item2) }, onMouseenter: function () { return dateMouseenterEvent(item2) }, }, renderDateLabel(item2, item2.year) ) }) ) }) ), ] ), ] } var renderDateTable = function () { var datePanelType = reactData.datePanelType switch (datePanelType) { case 'week': return renderDateWeekTable() case 'month': return renderDateMonthTable() case 'quarter': return renderDateQuarterTable() case 'year': return renderDateYearTable() } return renderDateDayTable() } var renderDatePanel = function () { var multiple = props2.multiple var datePanelType = reactData.datePanelType var isDisabledPrevDateBtn = computeIsDisabledPrevDateBtn.value var isDisabledNextDateBtn = computeIsDisabledNextDateBtn.value var selectDatePanelLabel = computeSelectDatePanelLabel.value return [ h$4( 'div', { class: 'vxe-input--date-picker-header', }, [ h$4( 'div', { class: 'vxe-input--date-picker-type-wrapper', }, [ datePanelType === 'year' ? h$4( 'span', { class: 'vxe-input--date-picker-label', }, selectDatePanelLabel ) : h$4( 'span', { class: 'vxe-input--date-picker-btn', onClick: dateToggleTypeEvent, }, selectDatePanelLabel ), ] ), h$4( 'div', { class: 'vxe-input--date-picker-btn-wrapper', }, [ h$4( 'span', { class: [ 'vxe-input--date-picker-btn vxe-input--date-picker-prev-btn', { 'is--disabled': isDisabledPrevDateBtn, }, ], onClick: datePrevEvent, }, [ h$4('i', { class: 'vxe-icon-caret-left', }), ] ), h$4( 'span', { class: 'vxe-input--date-picker-btn vxe-input--date-picker-current-btn', onClick: dateTodayMonthEvent, }, [ h$4('i', { class: 'vxe-icon-dot', }), ] ), h$4( 'span', { class: [ 'vxe-input--date-picker-btn vxe-input--date-picker-next-btn', { 'is--disabled': isDisabledNextDateBtn, }, ], onClick: dateNextEvent, }, [ h$4('i', { class: 'vxe-icon-caret-right', }), ] ), multiple && computeSupportMultiples.value ? h$4( 'span', { class: 'vxe-input--date-picker-btn vxe-input--date-picker-confirm-btn', }, [ h$4( 'button', { class: 'vxe-input--date-picker-confirm', type: 'button', onClick: dateConfirmEvent, }, GlobalConfig.i18n('vxe.button.confirm') ), ] ) : null, ] ), ] ), h$4( 'div', { class: 'vxe-input--date-picker-body', }, renderDateTable() ), ] } var renderTimePanel = function () { var datetimePanelValue = reactData.datetimePanelValue var dateTimeLabel = computeDateTimeLabel.value var hourList = computeHourList.value var minuteList = computeMinuteList.value var secondList = computeSecondList.value return [ h$4( 'div', { class: 'vxe-input--time-picker-header', }, [ h$4( 'span', { class: 'vxe-input--time-picker-title', }, dateTimeLabel ), h$4( 'button', { class: 'vxe-input--time-picker-confirm', type: 'button', onClick: dateConfirmEvent, }, GlobalConfig.i18n('vxe.button.confirm') ), ] ), h$4( 'div', { ref: refInputTimeBody, class: 'vxe-input--time-picker-body', }, [ h$4( 'ul', { class: 'vxe-input--time-picker-hour-list', }, hourList.map(function (item2, index2) { return h$4( 'li', { key: index2, class: { 'is--selected': datetimePanelValue && datetimePanelValue.getHours() === item2.value, }, onClick: function (evnt) { return dateHourEvent(evnt, item2) }, }, item2.label ) }) ), h$4( 'ul', { class: 'vxe-input--time-picker-minute-list', }, minuteList.map(function (item2, index2) { return h$4( 'li', { key: index2, class: { 'is--selected': datetimePanelValue && datetimePanelValue.getMinutes() === item2.value, }, onClick: function (evnt) { return dateMinuteEvent(evnt, item2) }, }, item2.label ) }) ), h$4( 'ul', { class: 'vxe-input--time-picker-second-list', }, secondList.map(function (item2, index2) { return h$4( 'li', { key: index2, class: { 'is--selected': datetimePanelValue && datetimePanelValue.getSeconds() === item2.value, }, onClick: function (evnt) { return dateSecondEvent(evnt, item2) }, }, item2.label ) }) ), ] ), ] } var renderPanel = function () { var _a2 var type4 = props2.type, transfer = props2.transfer var inited = reactData.inited, animatVisible = reactData.animatVisible, visiblePanel = reactData.visiblePanel, panelPlacement = reactData.panelPlacement, panelStyle = reactData.panelStyle var vSize = computeSize.value var isDatePickerType = computeIsDatePickerType.value var renders = [] if (isDatePickerType) { if (type4 === 'datetime') { renders.push( h$4( 'div', { class: 'vxe-input--panel-layout-wrapper', }, [ h$4( 'div', { class: 'vxe-input--panel-left-wrapper', }, renderDatePanel() ), h$4( 'div', { class: 'vxe-input--panel-right-wrapper', }, renderTimePanel() ), ] ) ) } else if (type4 === 'time') { renders.push( h$4( 'div', { class: 'vxe-input--panel-wrapper', }, renderTimePanel() ) ) } else { renders.push( h$4( 'div', { class: 'vxe-input--panel-wrapper', }, renderDatePanel() ) ) } return h$4( Teleport, { to: 'body', disabled: transfer ? !inited : true, }, [ h$4( 'div', { ref: refInputPanel, class: [ 'vxe-table--ignore-clear vxe-input--panel', 'type--'.concat(type4), ((_a2 = {}), (_a2['size--'.concat(vSize)] = vSize), (_a2['is--transfer'] = transfer), (_a2['animat--leave'] = animatVisible), (_a2['animat--enter'] = visiblePanel), _a2), ], placement: panelPlacement, style: panelStyle, }, renders ), ] ) } return null } var renderNumberIcon = function () { var isDisabledAddNumber = computeIsDisabledAddNumber.value var isDisabledSubtractNumber = computeIsDisabledSubtractNumber.value return h$4( 'span', { class: 'vxe-input--number-suffix', }, [ h$4( 'span', { class: [ 'vxe-input--number-prev is--prev', { 'is--disabled': isDisabledAddNumber, }, ], onMousedown: numberMousedownEvent, onMouseup: numberStopDown, onMouseleave: numberStopDown, }, [ h$4('i', { class: [ 'vxe-input--number-prev-icon', GlobalConfig.icon.INPUT_PREV_NUM, ], }), ] ), h$4( 'span', { class: [ 'vxe-input--number-next is--next', { 'is--disabled': isDisabledSubtractNumber, }, ], onMousedown: numberMousedownEvent, onMouseup: numberStopDown, onMouseleave: numberStopDown, }, [ h$4('i', { class: [ 'vxe-input--number-next-icon', GlobalConfig.icon.INPUT_NEXT_NUM, ], }), ] ), ] ) } var renderDatePickerIcon = function () { return h$4( 'span', { class: 'vxe-input--date-picker-suffix', onClick: datePickerOpenEvent, }, [ h$4('i', { class: [ 'vxe-input--date-picker-icon', GlobalConfig.icon.INPUT_DATE, ], }), ] ) } var renderSearchIcon = function () { return h$4( 'span', { class: 'vxe-input--search-suffix', onClick: searchEvent, }, [ h$4('i', { class: ['vxe-input--search-icon', GlobalConfig.icon.INPUT_SEARCH], }), ] ) } var renderPasswordIcon = function () { var showPwd = reactData.showPwd return h$4( 'span', { class: 'vxe-input--password-suffix', onClick: passwordToggleEvent, }, [ h$4('i', { class: [ 'vxe-input--password-icon', showPwd ? GlobalConfig.icon.INPUT_SHOW_PWD : GlobalConfig.icon.INPUT_PWD, ], }), ] ) } var rendePrefixIcon = function () { var prefixIcon = props2.prefixIcon var prefixSlot = slots.prefix var icons = [] if (prefixSlot) { icons.push( h$4( 'span', { class: 'vxe-input--prefix-icon', }, prefixSlot({}) ) ) } else if (prefixIcon) { icons.push( h$4('i', { class: ['vxe-input--prefix-icon', prefixIcon], }) ) } return icons.length ? h$4( 'span', { class: 'vxe-input--prefix', onClick: clickPrefixEvent, }, icons ) : null } var renderSuffixIcon2 = function () { var disabled = props2.disabled, suffixIcon = props2.suffixIcon var inputValue = reactData.inputValue var suffixSlot = slots.suffix var isClearable = computeIsClearable.value var icons = [] if (suffixSlot) { icons.push( h$4( 'span', { class: 'vxe-input--suffix-icon', }, suffixSlot({}) ) ) } else if (suffixIcon) { icons.push( h$4('i', { class: ['vxe-input--suffix-icon', suffixIcon], }) ) } if (isClearable) { icons.push( h$4('i', { class: ['vxe-input--clear-icon', GlobalConfig.icon.INPUT_CLEAR], }) ) } return icons.length ? h$4( 'span', { class: [ 'vxe-input--suffix', { 'is--clear': isClearable && !disabled && !(inputValue === '' || xeUtils.eqNull(inputValue)), }, ], onClick: clickSuffixEvent, }, icons ) : null } var renderExtraSuffixIcon = function () { var controls = props2.controls var isNumType = computeIsNumType.value var isDatePickerType = computeIsDatePickerType.value var isPawdType = computeIsPawdType.value var isSearchType = computeIsSearchType.value var icons if (isPawdType) { icons = renderPasswordIcon() } else if (isNumType) { if (controls) { icons = renderNumberIcon() } } else if (isDatePickerType) { icons = renderDatePickerIcon() } else if (isSearchType) { icons = renderSearchIcon() } return icons ? h$4( 'span', { class: 'vxe-input--extra-suffix', }, [icons] ) : null } inputMethods = { dispatchEvent: function (type4, params2, evnt) { emit2(type4, Object.assign({ $input: $xeinput, $event: evnt }, params2)) }, focus: function () { var inputElem = refInputTarget.value reactData.isActivated = true inputElem.focus() return nextTick() }, blur: function () { var inputElem = refInputTarget.value inputElem.blur() reactData.isActivated = false return nextTick() }, select: function () { var inputElem = refInputTarget.value inputElem.select() reactData.isActivated = false return nextTick() }, showPanel, hidePanel, updatePlacement, } Object.assign($xeinput, inputMethods) watch$1( function () { return props2.modelValue }, function (val2) { reactData.inputValue = val2 changeValue() } ) watch$1( function () { return props2.type }, function () { Object.assign(reactData, { inputValue: props2.modelValue, datetimePanelValue: null, datePanelValue: null, datePanelLabel: '', datePanelType: 'day', selectMonth: null, currentDate: null, }) initValue() } ) watch$1(computeDateLabelFormat, function () { var isDatePickerType = computeIsDatePickerType.value if (isDatePickerType) { dateParseValue(reactData.datePanelValue) reactData.inputValue = props2.multiple ? computeDateMultipleLabel.value : reactData.datePanelLabel } }) nextTick(function () { GlobalEvent.on($xeinput, 'mousewheel', handleGlobalMousewheelEvent) GlobalEvent.on($xeinput, 'mousedown', handleGlobalMousedownEvent) GlobalEvent.on($xeinput, 'keydown', handleGlobalKeydownEvent) GlobalEvent.on($xeinput, 'blur', handleGlobalBlurEvent) }) onUnmounted(function () { numberStopDown() GlobalEvent.off($xeinput, 'mousewheel') GlobalEvent.off($xeinput, 'mousedown') GlobalEvent.off($xeinput, 'keydown') GlobalEvent.off($xeinput, 'blur') }) initValue() var renderVN = function () { var _a2 var className = props2.className, controls = props2.controls, type4 = props2.type, align = props2.align, showWordCount = props2.showWordCount, countMethod = props2.countMethod, name2 = props2.name, disabled = props2.disabled, readonly2 = props2.readonly, autocomplete = props2.autocomplete var inputValue = reactData.inputValue, visiblePanel = reactData.visiblePanel, isActivated = reactData.isActivated var vSize = computeSize.value var isCountError = computeIsCountError.value var inputCount = computeInputCount.value var isDatePickerType = computeIsDatePickerType.value var inpReadonly = computeInpReadonly.value var inpMaxlength = computeInpMaxlength.value var inputType = computeInputType.value var inpPlaceholder = computeInpPlaceholder.value var childs = [] var prefix = rendePrefixIcon() var suffix2 = renderSuffixIcon2() if (prefix) { childs.push(prefix) } childs.push( h$4('input', { ref: refInputTarget, class: 'vxe-input--inner', value: inputValue, name: name2, type: inputType, placeholder: inpPlaceholder, maxlength: inpMaxlength, readonly: inpReadonly, disabled, autocomplete, onKeydown: keydownEvent, onKeyup: keyupEvent, onWheel: wheelEvent, onClick: clickEvent, onInput: inputEvent, onChange: changeEvent, onFocus: focusEvent, onBlur: blurEvent, }) ) if (suffix2) { childs.push(suffix2) } childs.push(renderExtraSuffixIcon()) if (isDatePickerType) { childs.push(renderPanel()) } var isWordCount = false if (showWordCount && ['text', 'search'].includes(type4)) { isWordCount = true childs.push( h$4( 'span', { class: [ 'vxe-input--count', { 'is--error': isCountError, }, ], }, countMethod ? ''.concat(countMethod({ value: inputValue })) : '' .concat(inputCount) .concat(inpMaxlength ? '/'.concat(inpMaxlength) : '') ) ) } return h$4( 'div', { ref: refElem, class: [ 'vxe-input', 'type--'.concat(type4), className, ((_a2 = {}), (_a2['size--'.concat(vSize)] = vSize), (_a2['is--'.concat(align)] = align), (_a2['is--controls'] = controls), (_a2['is--prefix'] = !!prefix), (_a2['is--suffix'] = !!suffix2), (_a2['is--readonly'] = readonly2), (_a2['is--visivle'] = visiblePanel), (_a2['is--count'] = isWordCount), (_a2['is--disabled'] = disabled), (_a2['is--active'] = isActivated), _a2), ], }, childs ) } $xeinput.renderVN = renderVN return $xeinput }, render: function () { return this.renderVN() }, }) var VxeCheckboxComponent = defineComponent({ name: 'VxeCheckbox', props: { modelValue: [String, Number, Boolean], label: { type: [String, Number], default: null }, indeterminate: Boolean, title: [String, Number], checkedValue: { type: [String, Number, Boolean], default: true }, uncheckedValue: { type: [String, Number, Boolean], default: false }, content: [String, Number], disabled: Boolean, size: { type: String, default: function () { return GlobalConfig.checkbox.size || GlobalConfig.size }, }, }, emits: ['update:modelValue', 'change'], setup: function (props2, context2) { var slots = context2.slots, emit2 = context2.emit var $xeform = inject('$xeform', null) var $xeformiteminfo = inject('$xeformiteminfo', null) var xID = xeUtils.uniqueId() var $xecheckbox = { xID, props: props2, context: context2, } var checkboxMethods = {} var computeSize = useSize(props2) var $xecheckboxgroup = inject('$xecheckboxgroup', null) var computeIsChecked = computed(function () { if ($xecheckboxgroup) { return xeUtils.includes($xecheckboxgroup.props.modelValue, props2.label) } return props2.modelValue === props2.checkedValue }) var computeIsDisabled = computed(function () { if (props2.disabled) { return true } if ($xecheckboxgroup) { var groupProps = $xecheckboxgroup.props var computeIsMaximize = $xecheckboxgroup.getComputeMaps().computeIsMaximize var isMaximize = computeIsMaximize.value var isChecked = computeIsChecked.value return groupProps.disabled || (isMaximize && !isChecked) } return false }) var changeEvent = function (evnt) { var checkedValue = props2.checkedValue, uncheckedValue = props2.uncheckedValue var isDisabled = computeIsDisabled.value if (!isDisabled) { var checked2 = evnt.target.checked var value2 = checked2 ? checkedValue : uncheckedValue var params2 = { checked: checked2, value: value2, label: props2.label } if ($xecheckboxgroup) { $xecheckboxgroup.handleChecked(params2, evnt) } else { emit2('update:modelValue', value2) checkboxMethods.dispatchEvent('change', params2, evnt) if ($xeform && $xeformiteminfo) { $xeform.triggerItemEvent( evnt, $xeformiteminfo.itemConfig.field, value2 ) } } } } checkboxMethods = { dispatchEvent: function (type4, params2, evnt) { emit2( type4, Object.assign({ $checkbox: $xecheckbox, $event: evnt }, params2) ) }, } Object.assign($xecheckbox, checkboxMethods) var renderVN = function () { var _a2 var vSize = computeSize.value var isDisabled = computeIsDisabled.value var isChecked = computeIsChecked.value var indeterminate = props2.indeterminate return h$4( 'label', { class: [ 'vxe-checkbox', ((_a2 = {}), (_a2['size--'.concat(vSize)] = vSize), (_a2['is--indeterminate'] = indeterminate), (_a2['is--disabled'] = isDisabled), (_a2['is--checked'] = isChecked), _a2), ], title: props2.title, }, [ h$4('input', { class: 'vxe-checkbox--input', type: 'checkbox', disabled: isDisabled, checked: isChecked, onChange: changeEvent, }), h$4('span', { class: [ 'vxe-checkbox--icon', indeterminate ? 'vxe-icon-checkbox-indeterminate' : isChecked ? 'vxe-icon-checkbox-checked' : 'vxe-icon-checkbox-unchecked', ], }), h$4( 'span', { class: 'vxe-checkbox--label', }, slots.default ? slots.default({}) : getFuncText(props2.content) ), ] ) } $xecheckbox.renderVN = renderVN return $xecheckbox }, render: function () { return this.renderVN() }, }) function isOptionVisible(option2) { return option2.visible !== false } function getOptUniqueId() { return xeUtils.uniqueId('opt_') } var VxeSelectComponent = defineComponent({ name: 'VxeSelect', props: { modelValue: null, clearable: Boolean, placeholder: { type: String, default: function () { return xeUtils.eqNull(GlobalConfig.select.placeholder) ? GlobalConfig.i18n('vxe.base.pleaseSelect') : GlobalConfig.select.placeholder }, }, loading: Boolean, disabled: Boolean, multiple: Boolean, multiCharOverflow: { type: [Number, String], default: function () { return GlobalConfig.select.multiCharOverflow }, }, prefixIcon: String, placement: String, options: Array, optionProps: Object, optionGroups: Array, optionGroupProps: Object, optionConfig: Object, className: [String, Function], popupClassName: [String, Function], max: { type: [String, Number], default: null }, size: { type: String, default: function () { return GlobalConfig.select.size || GlobalConfig.size }, }, filterable: Boolean, filterMethod: Function, remote: Boolean, remoteMethod: Function, emptyText: String, optionId: { type: String, default: function () { return GlobalConfig.select.optionId }, }, optionKey: Boolean, transfer: { type: Boolean, default: function () { return GlobalConfig.select.transfer }, }, }, emits: ['update:modelValue', 'change', 'clear', 'blur', 'focus'], setup: function (props2, context2) { var slots = context2.slots, emit2 = context2.emit var $xeform = inject('$xeform', null) var $xeformiteminfo = inject('$xeformiteminfo', null) var xID = xeUtils.uniqueId() var computeSize = useSize(props2) var reactData = reactive({ inited: false, staticOptions: [], fullGroupList: [], fullOptionList: [], visibleGroupList: [], visibleOptionList: [], remoteValueList: [], panelIndex: 0, panelStyle: {}, panelPlacement: null, currentOption: null, currentValue: null, visiblePanel: false, animatVisible: false, isActivated: false, searchValue: '', searchLoading: false, }) var refElem = ref() var refInput = ref() var refInpSearch = ref() var refOptionWrapper = ref() var refOptionPanel = ref() var refMaps = { refElem, } var $xeselect = { xID, props: props2, context: context2, reactData, getRefMaps: function () { return refMaps }, } var selectMethods = {} var computePropsOpts = computed(function () { return props2.optionProps || {} }) var computeGroupPropsOpts = computed(function () { return props2.optionGroupProps || {} }) var computeLabelField = computed(function () { var propsOpts = computePropsOpts.value return propsOpts.label || 'label' }) var computeValueField = computed(function () { var propsOpts = computePropsOpts.value return propsOpts.value || 'value' }) var computeGroupLabelField = computed(function () { var groupPropsOpts = computeGroupPropsOpts.value return groupPropsOpts.label || 'label' }) var computeGroupOptionsField = computed(function () { var groupPropsOpts = computeGroupPropsOpts.value return groupPropsOpts.options || 'options' }) var computeIsMaximize = computed(function () { var modelValue = props2.modelValue, multiple = props2.multiple, max3 = props2.max if (multiple && max3) { return (modelValue ? modelValue.length : 0) >= xeUtils.toNumber(max3) } return false }) var computeOptionOpts = computed(function () { return Object.assign( {}, GlobalConfig.select.optionConfig, props2.optionConfig ) }) var computeIsGroup = computed(function () { return reactData.fullGroupList.some(function (item2) { return item2.options && item2.options.length }) }) var computeMultiMaxCharNum = computed(function () { return xeUtils.toNumber(props2.multiCharOverflow) }) var callSlot = function (slotFunc, params2) { if (slotFunc) { if (xeUtils.isString(slotFunc)) { slotFunc = slots[slotFunc] || null } if (xeUtils.isFunction(slotFunc)) { return getSlotVNs(slotFunc(params2)) } } return [] } var findOption = function (optionValue) { var fullOptionList = reactData.fullOptionList, fullGroupList = reactData.fullGroupList var isGroup2 = computeIsGroup.value var valueField = computeValueField.value if (isGroup2) { for (var gIndex = 0; gIndex < fullGroupList.length; gIndex++) { var group = fullGroupList[gIndex] if (group.options) { for (var index2 = 0; index2 < group.options.length; index2++) { var option2 = group.options[index2] if (optionValue === option2[valueField]) { return option2 } } } } } return fullOptionList.find(function (item2) { return optionValue === item2[valueField] }) } var getRemoteSelectLabel = function (value2) { var remoteValueList = reactData.remoteValueList var labelField = computeLabelField.value var remoteItem = remoteValueList.find(function (item3) { return value2 === item3.key }) var item2 = remoteItem ? remoteItem.result : null return xeUtils.toValueString(item2 ? item2[labelField] : value2) } var getSelectLabel = function (value2) { var labelField = computeLabelField.value var item2 = findOption(value2) return xeUtils.toValueString(item2 ? item2[labelField] : value2) } var computeSelectLabel = computed(function () { var modelValue = props2.modelValue, multiple = props2.multiple, remote = props2.remote var multiMaxCharNum = computeMultiMaxCharNum.value if (modelValue && multiple) { var vals = xeUtils.isArray(modelValue) ? modelValue : [modelValue] if (remote) { return vals .map(function (val2) { return getRemoteSelectLabel(val2) }) .join(', ') } return vals .map(function (val2) { var label = getSelectLabel(val2) if (multiMaxCharNum > 0 && label.length > multiMaxCharNum) { return ''.concat(label.substring(0, multiMaxCharNum), '...') } return label }) .join(', ') } if (remote) { return getRemoteSelectLabel(modelValue) } return getSelectLabel(modelValue) }) var getOptkey = function () { var optionOpts = computeOptionOpts.value return optionOpts.keyField || props2.optionId || '_X_OPTION_KEY' } var getOptid = function (option2) { var optid = option2[getOptkey()] return optid ? encodeURIComponent(optid) : '' } var refreshOption = function () { var filterable = props2.filterable, filterMethod = props2.filterMethod var fullOptionList = reactData.fullOptionList, fullGroupList = reactData.fullGroupList, searchValue = reactData.searchValue var isGroup2 = computeIsGroup.value var groupLabelField = computeGroupLabelField.value var labelField = computeLabelField.value if (isGroup2) { if (filterable && filterMethod) { reactData.visibleGroupList = fullGroupList.filter(function (group) { return ( isOptionVisible(group) && filterMethod({ group, option: null, searchValue }) ) }) } else if (filterable) { reactData.visibleGroupList = fullGroupList.filter(function (group) { return ( isOptionVisible(group) && (!searchValue || ''.concat(group[groupLabelField]).indexOf(searchValue) > -1) ) }) } else { reactData.visibleGroupList = fullGroupList.filter(isOptionVisible) } } else { if (filterable && filterMethod) { reactData.visibleOptionList = fullOptionList.filter(function ( option2 ) { return ( isOptionVisible(option2) && filterMethod({ group: null, option: option2, searchValue }) ) }) } else if (filterable) { reactData.visibleOptionList = fullOptionList.filter(function ( option2 ) { return ( isOptionVisible(option2) && (!searchValue || ''.concat(option2[labelField]).indexOf(searchValue) > -1) ) }) } else { reactData.visibleOptionList = fullOptionList.filter(isOptionVisible) } } return nextTick() } var cacheItemMap = function () { var fullOptionList = reactData.fullOptionList, fullGroupList = reactData.fullGroupList var groupOptionsField = computeGroupOptionsField.value var key2 = getOptkey() var handleOptis = function (item2) { if (!getOptid(item2)) { item2[key2] = getOptUniqueId() } } if (fullGroupList.length) { fullGroupList.forEach(function (group) { handleOptis(group) if (group[groupOptionsField]) { group[groupOptionsField].forEach(handleOptis) } }) } else if (fullOptionList.length) { fullOptionList.forEach(handleOptis) } refreshOption() } var setCurrentOption = function (option2) { var valueField = computeValueField.value if (option2) { reactData.currentOption = option2 reactData.currentValue = option2[valueField] } } var scrollToOption = function (option2, isAlignBottom) { return nextTick().then(function () { if (option2) { var optWrapperElem = refOptionWrapper.value var panelElem = refOptionPanel.value var optElem = panelElem.querySelector( "[optid='".concat(getOptid(option2), "']") ) if (optWrapperElem && optElem) { var wrapperHeight = optWrapperElem.offsetHeight var offsetPadding = 5 if (isAlignBottom) { if ( optElem.offsetTop + optElem.offsetHeight - optWrapperElem.scrollTop > wrapperHeight ) { optWrapperElem.scrollTop = optElem.offsetTop + optElem.offsetHeight - wrapperHeight } } else { if ( optElem.offsetTop + offsetPadding < optWrapperElem.scrollTop || optElem.offsetTop + offsetPadding > optWrapperElem.scrollTop + optWrapperElem.clientHeight ) { optWrapperElem.scrollTop = optElem.offsetTop - offsetPadding } } } } }) } var updateZindex = function () { if (reactData.panelIndex < getLastZIndex()) { reactData.panelIndex = nextZIndex() } } var updatePlacement = function () { return nextTick().then(function () { var transfer = props2.transfer, placement = props2.placement var panelIndex = reactData.panelIndex var el2 = refElem.value var panelElem = refOptionPanel.value if (panelElem && el2) { var targetHeight = el2.offsetHeight var targetWidth = el2.offsetWidth var panelHeight = panelElem.offsetHeight var panelWidth = panelElem.offsetWidth var marginSize = 5 var panelStyle = { zIndex: panelIndex, } var _a2 = getAbsolutePos(el2), boundingTop = _a2.boundingTop, boundingLeft = _a2.boundingLeft, visibleHeight = _a2.visibleHeight, visibleWidth = _a2.visibleWidth var panelPlacement = 'bottom' if (transfer) { var left2 = boundingLeft var top_1 = boundingTop + targetHeight if (placement === 'top') { panelPlacement = 'top' top_1 = boundingTop - panelHeight } else if (!placement) { if (top_1 + panelHeight + marginSize > visibleHeight) { panelPlacement = 'top' top_1 = boundingTop - panelHeight } if (top_1 < marginSize) { panelPlacement = 'bottom' top_1 = boundingTop + targetHeight } } if (left2 + panelWidth + marginSize > visibleWidth) { left2 -= left2 + panelWidth + marginSize - visibleWidth } if (left2 < marginSize) { left2 = marginSize } Object.assign(panelStyle, { left: ''.concat(left2, 'px'), top: ''.concat(top_1, 'px'), minWidth: ''.concat(targetWidth, 'px'), }) } else { if (placement === 'top') { panelPlacement = 'top' panelStyle.bottom = ''.concat(targetHeight, 'px') } else if (!placement) { if (boundingTop + targetHeight + panelHeight > visibleHeight) { if (boundingTop - targetHeight - panelHeight > marginSize) { panelPlacement = 'top' panelStyle.bottom = ''.concat(targetHeight, 'px') } } } } reactData.panelStyle = panelStyle reactData.panelPlacement = panelPlacement return nextTick() } }) } var hidePanelTimeout var showOptionPanel = function () { var loading2 = props2.loading, disabled = props2.disabled, filterable = props2.filterable if (!loading2 && !disabled) { clearTimeout(hidePanelTimeout) if (!reactData.inited) { reactData.inited = true } reactData.isActivated = true reactData.animatVisible = true if (filterable) { refreshOption() } setTimeout(function () { var modelValue = props2.modelValue, multiple = props2.multiple var currOption = findOption( multiple && modelValue ? modelValue[0] : modelValue ) reactData.visiblePanel = true if (currOption) { setCurrentOption(currOption) scrollToOption(currOption) } handleFocusSearch() }, 10) updateZindex() updatePlacement() } } var hideOptionPanel = function () { reactData.searchValue = '' reactData.searchLoading = false reactData.visiblePanel = false hidePanelTimeout = window.setTimeout(function () { reactData.animatVisible = false }, 350) } var changeEvent = function (evnt, selectValue) { if (selectValue !== props2.modelValue) { emit2('update:modelValue', selectValue) selectMethods.dispatchEvent('change', { value: selectValue }, evnt) if ($xeform && $xeformiteminfo) { $xeform.triggerItemEvent( evnt, $xeformiteminfo.itemConfig.field, selectValue ) } } } var clearValueEvent = function (evnt, selectValue) { reactData.remoteValueList = [] changeEvent(evnt, selectValue) selectMethods.dispatchEvent('clear', { value: selectValue }, evnt) } var clearEvent = function (params2, evnt) { clearValueEvent(evnt, null) hideOptionPanel() } var changeOptionEvent = function (evnt, selectValue, option2) { var modelValue = props2.modelValue, multiple = props2.multiple var remoteValueList = reactData.remoteValueList if (multiple) { var multipleValue = void 0 if (modelValue) { if (modelValue.indexOf(selectValue) === -1) { multipleValue = modelValue.concat([selectValue]) } else { multipleValue = modelValue.filter(function (val2) { return val2 !== selectValue }) } } else { multipleValue = [selectValue] } var remoteItem = remoteValueList.find(function (item2) { return item2.key === selectValue }) if (remoteItem) { remoteItem.result = option2 } else { remoteValueList.push({ key: selectValue, result: option2 }) } changeEvent(evnt, multipleValue) } else { reactData.remoteValueList = [{ key: selectValue, result: option2 }] changeEvent(evnt, selectValue) hideOptionPanel() } } var handleGlobalMousewheelEvent = function (evnt) { var disabled = props2.disabled var visiblePanel = reactData.visiblePanel if (!disabled) { if (visiblePanel) { var panelElem = refOptionPanel.value if (getEventTargetNode(evnt, panelElem).flag) { updatePlacement() } else { hideOptionPanel() } } } } var handleGlobalMousedownEvent = function (evnt) { var disabled = props2.disabled var visiblePanel = reactData.visiblePanel if (!disabled) { var el2 = refElem.value var panelElem = refOptionPanel.value reactData.isActivated = getEventTargetNode(evnt, el2).flag || getEventTargetNode(evnt, panelElem).flag if (visiblePanel && !reactData.isActivated) { hideOptionPanel() } } } var findOffsetOption = function (optionValue, isUpArrow) { var visibleOptionList = reactData.visibleOptionList, visibleGroupList = reactData.visibleGroupList var isGroup2 = computeIsGroup.value var valueField = computeValueField.value var groupOptionsField = computeGroupOptionsField.value var firstOption var prevOption var nextOption var currOption if (isGroup2) { for (var gIndex = 0; gIndex < visibleGroupList.length; gIndex++) { var group = visibleGroupList[gIndex] var groupOptionList = group[groupOptionsField] var isGroupDisabled = group.disabled if (groupOptionList) { for (var index2 = 0; index2 < groupOptionList.length; index2++) { var option2 = groupOptionList[index2] var isVisible2 = isOptionVisible(option2) var isDisabled = isGroupDisabled || option2.disabled if (!firstOption && !isDisabled) { firstOption = option2 } if (currOption) { if (isVisible2 && !isDisabled) { nextOption = option2 if (!isUpArrow) { return { offsetOption: nextOption } } } } if (optionValue === option2[valueField]) { currOption = option2 if (isUpArrow) { return { offsetOption: prevOption } } } else { if (isVisible2 && !isDisabled) { prevOption = option2 } } } } } } else { for (var index2 = 0; index2 < visibleOptionList.length; index2++) { var option2 = visibleOptionList[index2] var isDisabled = option2.disabled if (!firstOption && !isDisabled) { firstOption = option2 } if (currOption) { if (!isDisabled) { nextOption = option2 if (!isUpArrow) { return { offsetOption: nextOption } } } } if (optionValue === option2[valueField]) { currOption = option2 if (isUpArrow) { return { offsetOption: prevOption } } } else { if (!isDisabled) { prevOption = option2 } } } } return { firstOption } } var handleGlobalKeydownEvent = function (evnt) { var clearable = props2.clearable, disabled = props2.disabled var visiblePanel = reactData.visiblePanel, currentValue = reactData.currentValue, currentOption = reactData.currentOption if (!disabled) { var isTab = hasEventKey(evnt, EVENT_KEYS.TAB) var isEnter = hasEventKey(evnt, EVENT_KEYS.ENTER) var isEsc = hasEventKey(evnt, EVENT_KEYS.ESCAPE) var isUpArrow = hasEventKey(evnt, EVENT_KEYS.ARROW_UP) var isDwArrow = hasEventKey(evnt, EVENT_KEYS.ARROW_DOWN) var isDel = hasEventKey(evnt, EVENT_KEYS.DELETE) var isSpacebar = hasEventKey(evnt, EVENT_KEYS.SPACEBAR) if (isTab) { reactData.isActivated = false } if (visiblePanel) { if (isEsc || isTab) { hideOptionPanel() } else if (isEnter) { evnt.preventDefault() evnt.stopPropagation() changeOptionEvent(evnt, currentValue, currentOption) } else if (isUpArrow || isDwArrow) { evnt.preventDefault() var _a2 = findOffsetOption(currentValue, isUpArrow), firstOption = _a2.firstOption, offsetOption = _a2.offsetOption if (!offsetOption && !findOption(currentValue)) { offsetOption = firstOption } setCurrentOption(offsetOption) scrollToOption(offsetOption, isDwArrow) } else if (isSpacebar) { evnt.preventDefault() } } else if ( (isUpArrow || isDwArrow || isEnter || isSpacebar) && reactData.isActivated ) { evnt.preventDefault() showOptionPanel() } if (reactData.isActivated) { if (isDel && clearable) { clearValueEvent(evnt, null) } } } } var handleGlobalBlurEvent = function () { hideOptionPanel() } var handleFocusSearch = function () { if (props2.filterable) { nextTick(function () { var inpSearch = refInpSearch.value if (inpSearch) { inpSearch.focus() } }) } } var focusEvent = function (evnt) { if (!props2.disabled) { reactData.isActivated = true } selectMethods.dispatchEvent('focus', {}, evnt) } var blurEvent = function (evnt) { reactData.isActivated = false selectMethods.dispatchEvent('blur', {}, evnt) } var modelSearchEvent = function (value2) { reactData.searchValue = value2 } var focusSearchEvent = function () { reactData.isActivated = true } var keydownSearchEvent = function (params2) { var $event = params2.$event var isEnter = hasEventKey($event, EVENT_KEYS.ENTER) if (isEnter) { $event.preventDefault() $event.stopPropagation() } } var triggerSearchEvent = xeUtils.debounce( function () { var remote = props2.remote, remoteMethod = props2.remoteMethod var searchValue = reactData.searchValue if (remote && remoteMethod) { reactData.searchLoading = true Promise.resolve(remoteMethod({ searchValue })) .then(function () { return nextTick() }) .catch(function () { return nextTick() }) .finally(function () { reactData.searchLoading = false refreshOption() }) } else { refreshOption() } }, 350, { trailing: true } ) var togglePanelEvent = function (params2) { var $event = params2.$event $event.preventDefault() if (reactData.visiblePanel) { hideOptionPanel() } else { showOptionPanel() } } var checkOptionDisabled = function (isSelected, option2, group) { if (option2.disabled) { return true } if (group && group.disabled) { return true } var isMaximize = computeIsMaximize.value if (isMaximize && !isSelected) { return true } return false } var renderOption = function (list2, group) { var optionKey = props2.optionKey, modelValue = props2.modelValue, multiple = props2.multiple var currentValue = reactData.currentValue var optionOpts = computeOptionOpts.value var labelField = computeLabelField.value var valueField = computeValueField.value var isGroup2 = computeIsGroup.value var useKey = optionOpts.useKey return list2.map(function (option2, cIndex) { var slots2 = option2.slots, className = option2.className var optionValue = option2[valueField] var isSelected = multiple ? modelValue && modelValue.indexOf(optionValue) > -1 : modelValue === optionValue var isVisible2 = !isGroup2 || isOptionVisible(option2) var isDisabled = checkOptionDisabled(isSelected, option2, group) var optid = getOptid(option2) var defaultSlot = slots2 ? slots2.default : null return isVisible2 ? h$4( 'div', { key: useKey || optionKey ? optid : cIndex, class: [ 'vxe-select-option', className ? xeUtils.isFunction(className) ? className({ option: option2, $select: $xeselect }) : className : '', { 'is--disabled': isDisabled, 'is--selected': isSelected, 'is--hover': currentValue === optionValue, }, ], optid, onMousedown: function (evnt) { var isLeftBtn = evnt.button === 0 if (isLeftBtn) { evnt.stopPropagation() } }, onClick: function (evnt) { if (!isDisabled) { changeOptionEvent(evnt, optionValue, option2) } }, onMouseenter: function () { if (!isDisabled) { setCurrentOption(option2) } }, }, defaultSlot ? callSlot(defaultSlot, { option: option2, $select: $xeselect }) : formatText(getFuncText(option2[labelField])) ) : null }) } var renderOptgroup = function () { var optionKey = props2.optionKey var visibleGroupList = reactData.visibleGroupList var optionOpts = computeOptionOpts.value var groupLabelField = computeGroupLabelField.value var groupOptionsField = computeGroupOptionsField.value var useKey = optionOpts.useKey return visibleGroupList.map(function (group, gIndex) { var slots2 = group.slots, className = group.className var optid = getOptid(group) var isGroupDisabled = group.disabled var defaultSlot = slots2 ? slots2.default : null return h$4( 'div', { key: useKey || optionKey ? optid : gIndex, class: [ 'vxe-optgroup', className ? xeUtils.isFunction(className) ? className({ option: group, $select: $xeselect }) : className : '', { 'is--disabled': isGroupDisabled, }, ], optid, }, [ h$4( 'div', { class: 'vxe-optgroup--title', }, defaultSlot ? callSlot(defaultSlot, { option: group, $select: $xeselect }) : getFuncText(group[groupLabelField]) ), h$4( 'div', { class: 'vxe-optgroup--wrapper', }, renderOption(group[groupOptionsField] || [], group) ), ] ) }) } var renderOpts = function () { var visibleGroupList = reactData.visibleGroupList, visibleOptionList = reactData.visibleOptionList, searchLoading = reactData.searchLoading var isGroup2 = computeIsGroup.value if (searchLoading) { return [ h$4( 'div', { class: 'vxe-select--search-loading', }, [ h$4('i', { class: [ 'vxe-select--search-icon', GlobalConfig.icon.SELECT_LOADED, ], }), h$4( 'span', { class: 'vxe-select--search-text', }, GlobalConfig.i18n('vxe.select.loadingText') ), ] ), ] } if (isGroup2) { if (visibleGroupList.length) { return renderOptgroup() } } else { if (visibleOptionList.length) { return renderOption(visibleOptionList) } } return [ h$4( 'div', { class: 'vxe-select--empty-placeholder', }, props2.emptyText || GlobalConfig.i18n('vxe.select.emptyText') ), ] } selectMethods = { dispatchEvent: function (type4, params2, evnt) { emit2( type4, Object.assign({ $select: $xeselect, $event: evnt }, params2) ) }, isPanelVisible: function () { return reactData.visiblePanel }, togglePanel: function () { if (reactData.visiblePanel) { hideOptionPanel() } else { showOptionPanel() } return nextTick() }, hidePanel: function () { if (reactData.visiblePanel) { hideOptionPanel() } return nextTick() }, showPanel: function () { if (!reactData.visiblePanel) { showOptionPanel() } return nextTick() }, refreshOption, focus: function () { var $input = refInput.value reactData.isActivated = true $input.blur() return nextTick() }, blur: function () { var $input = refInput.value $input.blur() reactData.isActivated = false return nextTick() }, } Object.assign($xeselect, selectMethods) watch$1( function () { return reactData.staticOptions }, function (value2) { if ( value2.some(function (item2) { return item2.options && item2.options.length }) ) { reactData.fullOptionList = [] reactData.fullGroupList = value2 } else { reactData.fullGroupList = [] reactData.fullOptionList = value2 || [] } cacheItemMap() } ) watch$1( function () { return props2.options }, function (value2) { reactData.fullGroupList = [] reactData.fullOptionList = value2 || [] cacheItemMap() } ) watch$1( function () { return props2.optionGroups }, function (value2) { reactData.fullOptionList = [] reactData.fullGroupList = value2 || [] cacheItemMap() } ) onMounted(function () { nextTick(function () { var options2 = props2.options, optionGroups = props2.optionGroups if (optionGroups) { reactData.fullGroupList = optionGroups } else if (options2) { reactData.fullOptionList = options2 } cacheItemMap() }) GlobalEvent.on($xeselect, 'mousewheel', handleGlobalMousewheelEvent) GlobalEvent.on($xeselect, 'mousedown', handleGlobalMousedownEvent) GlobalEvent.on($xeselect, 'keydown', handleGlobalKeydownEvent) GlobalEvent.on($xeselect, 'blur', handleGlobalBlurEvent) }) onUnmounted(function () { GlobalEvent.off($xeselect, 'mousewheel') GlobalEvent.off($xeselect, 'mousedown') GlobalEvent.off($xeselect, 'keydown') GlobalEvent.off($xeselect, 'blur') }) var renderVN = function () { var _a2, _b2 var className = props2.className, popupClassName = props2.popupClassName, transfer = props2.transfer, disabled = props2.disabled, loading2 = props2.loading, filterable = props2.filterable var inited = reactData.inited, isActivated = reactData.isActivated, visiblePanel = reactData.visiblePanel var vSize = computeSize.value var selectLabel = computeSelectLabel.value var prefixSlot = slots.prefix return h$4( 'div', { ref: refElem, class: [ 'vxe-select', className ? xeUtils.isFunction(className) ? className({ $select: $xeselect }) : className : '', ((_a2 = {}), (_a2['size--'.concat(vSize)] = vSize), (_a2['is--visivle'] = visiblePanel), (_a2['is--disabled'] = disabled), (_a2['is--filter'] = filterable), (_a2['is--loading'] = loading2), (_a2['is--active'] = isActivated), _a2), ], }, [ h$4( 'div', { class: 'vxe-select-slots', ref: 'hideOption', }, slots.default ? slots.default({}) : [] ), h$4( VxeInputConstructor, { ref: refInput, clearable: props2.clearable, placeholder: props2.placeholder, readonly: true, disabled, type: 'text', prefixIcon: props2.prefixIcon, suffixIcon: loading2 ? GlobalConfig.icon.SELECT_LOADED : visiblePanel ? GlobalConfig.icon.SELECT_OPEN : GlobalConfig.icon.SELECT_CLOSE, modelValue: selectLabel, onClear: clearEvent, onClick: togglePanelEvent, onFocus: focusEvent, onBlur: blurEvent, onSuffixClick: togglePanelEvent, }, prefixSlot ? { prefix: function () { return prefixSlot({}) }, } : {} ), h$4( Teleport, { to: 'body', disabled: transfer ? !inited : true, }, [ h$4( 'div', { ref: refOptionPanel, class: [ 'vxe-table--ignore-clear vxe-select--panel', popupClassName ? xeUtils.isFunction(popupClassName) ? popupClassName({ $select: $xeselect }) : popupClassName : '', ((_b2 = {}), (_b2['size--'.concat(vSize)] = vSize), (_b2['is--transfer'] = transfer), (_b2['animat--leave'] = !loading2 && reactData.animatVisible), (_b2['animat--enter'] = !loading2 && visiblePanel), _b2), ], placement: reactData.panelPlacement, style: reactData.panelStyle, }, inited ? [ filterable ? h$4( 'div', { class: 'vxe-select-filter--wrapper', }, [ h$4(VxeInputConstructor, { ref: refInpSearch, class: 'vxe-select-filter--input', modelValue: reactData.searchValue, clearable: true, placeholder: GlobalConfig.i18n('vxe.select.search'), prefixIcon: GlobalConfig.icon.INPUT_SEARCH, 'onUpdate:modelValue': modelSearchEvent, onFocus: focusSearchEvent, onKeydown: keydownSearchEvent, onChange: triggerSearchEvent, onSearch: triggerSearchEvent, }), ] ) : createCommentVNode(), h$4( 'div', { ref: refOptionWrapper, class: 'vxe-select-option--wrapper', }, renderOpts() ), ] : [] ), ] ), ] ) } $xeselect.renderVN = renderVN provide('$xeselect', $xeselect) return $xeselect }, render: function () { return this.renderVN() }, }) var ExportPanelComponent = defineComponent({ name: 'VxeExportPanel', props: { defaultOptions: Object, storeData: Object, }, setup: function (props2) { var $xetable = inject('$xetable', {}) var _a2 = $xetable.getComputeMaps(), computeExportOpts = _a2.computeExportOpts, computePrintOpts = _a2.computePrintOpts var reactData = reactive({ isAll: false, isIndeterminate: false, loading: false, }) var xButtonConfirm = ref() var xInputFilename = ref() var xInputSheetname = ref() var computeCheckedAll = computed(function () { var storeData2 = props2.storeData return storeData2.columns.every(function (column) { return column.checked }) }) var computeShowSheet = computed(function () { var defaultOptions2 = props2.defaultOptions return ['html', 'xml', 'xlsx', 'pdf'].indexOf(defaultOptions2.type) > -1 }) var computeSupportMerge = computed(function () { var storeData2 = props2.storeData, defaultOptions2 = props2.defaultOptions return ( !defaultOptions2.original && defaultOptions2.mode === 'current' && (storeData2.isPrint || ['html', 'xlsx'].indexOf(defaultOptions2.type) > -1) ) }) var computeSupportStyle = computed(function () { var defaultOptions2 = props2.defaultOptions return ( !defaultOptions2.original && ['xlsx'].indexOf(defaultOptions2.type) > -1 ) }) var handleOptionCheck = function (column) { var storeData2 = props2.storeData var matchObj = xeUtils.findTree(storeData2.columns, function (item2) { return item2 === column }) if (matchObj && matchObj.parent) { var parent_1 = matchObj.parent if (parent_1.children && parent_1.children.length) { parent_1.checked = parent_1.children.every(function (column2) { return column2.checked }) parent_1.halfChecked = !parent_1.checked && parent_1.children.some(function (column2) { return column2.checked || column2.halfChecked }) handleOptionCheck(parent_1) } } } var checkStatus = function () { var storeData2 = props2.storeData var columns = storeData2.columns reactData.isAll = columns.every(function (column) { return column.disabled || column.checked }) reactData.isIndeterminate = !reactData.isAll && columns.some(function (column) { return !column.disabled && (column.checked || column.halfChecked) }) } var changeOption = function (column) { var isChecked = !column.checked xeUtils.eachTree([column], function (item2) { item2.checked = isChecked item2.halfChecked = false }) handleOptionCheck(column) checkStatus() } var allColumnEvent = function () { var storeData2 = props2.storeData var isAll = !reactData.isAll xeUtils.eachTree(storeData2.columns, function (column) { if (!column.disabled) { column.checked = isAll column.halfChecked = false } }) reactData.isAll = isAll checkStatus() } var showEvent = function () { nextTick(function () { var filenameInp = xInputFilename.value var sheetnameInp = xInputSheetname.value var confirmBtn = xButtonConfirm.value var targetElem = filenameInp || sheetnameInp || confirmBtn if (targetElem) { targetElem.focus() } }) checkStatus() } var getExportOption = function () { var storeData2 = props2.storeData, defaultOptions2 = props2.defaultOptions var hasMerge = storeData2.hasMerge, columns = storeData2.columns var checkedAll = computeCheckedAll.value var supportMerge = computeSupportMerge.value var expColumns = xeUtils.searchTree( columns, function (column) { return column.checked }, { children: 'children', mapChildren: 'childNodes', original: true } ) return Object.assign({}, defaultOptions2, { columns: expColumns, isMerge: hasMerge && supportMerge && checkedAll ? defaultOptions2.isMerge : false, }) } var printEvent = function () { var storeData2 = props2.storeData var printOpts = computePrintOpts.value storeData2.visible = false $xetable.print(Object.assign({}, printOpts, getExportOption())) } var exportEvent = function () { var storeData2 = props2.storeData var exportOpts = computeExportOpts.value reactData.loading = true $xetable .exportData(Object.assign({}, exportOpts, getExportOption())) .then(function () { reactData.loading = false storeData2.visible = false }) .catch(function () { reactData.loading = false }) } var cancelEvent = function () { var storeData2 = props2.storeData storeData2.visible = false } var confirmEvent = function () { var storeData2 = props2.storeData if (storeData2.isPrint) { printEvent() } else { exportEvent() } } var renderVN = function () { var defaultOptions2 = props2.defaultOptions, storeData2 = props2.storeData var isAllChecked = reactData.isAll, isAllIndeterminate = reactData.isIndeterminate var hasTree = storeData2.hasTree, hasMerge = storeData2.hasMerge, isPrint2 = storeData2.isPrint, hasColgroup = storeData2.hasColgroup var isHeader = defaultOptions2.isHeader var cols = [] var checkedAll = computeCheckedAll.value var showSheet = computeShowSheet.value var supportMerge = computeSupportMerge.value var supportStyle = computeSupportStyle.value xeUtils.eachTree(storeData2.columns, function (column) { var colTitle = formatText(column.getTitle(), 1) var isColGroup = column.children && column.children.length var isChecked = column.checked var indeterminate = column.halfChecked cols.push( h$4( 'li', { class: [ 'vxe-export--panel-column-option', 'level--'.concat(column.level), { 'is--group': isColGroup, 'is--checked': isChecked, 'is--indeterminate': indeterminate, 'is--disabled': column.disabled, }, ], title: colTitle, onClick: function () { if (!column.disabled) { changeOption(column) } }, }, [ h$4('span', { class: [ 'vxe-checkbox--icon', indeterminate ? GlobalConfig.icon.TABLE_CHECKBOX_INDETERMINATE : isChecked ? GlobalConfig.icon.TABLE_CHECKBOX_CHECKED : GlobalConfig.icon.TABLE_CHECKBOX_UNCHECKED, ], }), h$4( 'span', { class: 'vxe-checkbox--label', }, colTitle ), ] ) ) }) return h$4( VxeModalComponent, { modelValue: storeData2.visible, title: GlobalConfig.i18n( isPrint2 ? 'vxe.export.printTitle' : 'vxe.export.expTitle' ), width: 660, mask: true, lockView: true, showFooter: false, escClosable: true, maskClosable: true, loading: reactData.loading, 'onUpdate:modelValue': function (value2) { storeData2.visible = value2 }, onShow: showEvent, }, { default: function () { return h$4( 'div', { class: 'vxe-export--panel', }, [ h$4( 'table', { cellspacing: 0, cellpadding: 0, border: 0, }, [ h$4('tbody', [ [ isPrint2 ? createCommentVNode() : h$4('tr', [ h$4( 'td', GlobalConfig.i18n('vxe.export.expName') ), h$4('td', [ h$4(VxeInputConstructor, { ref: xInputFilename, modelValue: defaultOptions2.filename, type: 'text', clearable: true, placeholder: GlobalConfig.i18n( 'vxe.export.expNamePlaceholder' ), 'onUpdate:modelValue': function (value2) { defaultOptions2.filename = value2 }, }), ]), ]), isPrint2 ? createCommentVNode() : h$4('tr', [ h$4( 'td', GlobalConfig.i18n('vxe.export.expType') ), h$4('td', [ h$4(VxeSelectComponent, { modelValue: defaultOptions2.type, options: storeData2.typeList.map(function ( item2 ) { return { value: item2.value, label: GlobalConfig.i18n(item2.label), } }), 'onUpdate:modelValue': function (value2) { defaultOptions2.type = value2 }, }), ]), ]), isPrint2 || showSheet ? h$4('tr', [ h$4( 'td', GlobalConfig.i18n('vxe.export.expSheetName') ), h$4('td', [ h$4(VxeInputConstructor, { ref: xInputSheetname, modelValue: defaultOptions2.sheetName, type: 'text', clearable: true, placeholder: GlobalConfig.i18n( 'vxe.export.expSheetNamePlaceholder' ), 'onUpdate:modelValue': function (value2) { defaultOptions2.sheetName = value2 }, }), ]), ]) : createCommentVNode(), h$4('tr', [ h$4('td', GlobalConfig.i18n('vxe.export.expMode')), h$4('td', [ h$4(VxeSelectComponent, { modelValue: defaultOptions2.mode, options: storeData2.modeList.map(function ( item2 ) { return { value: item2.value, label: GlobalConfig.i18n(item2.label), } }), 'onUpdate:modelValue': function (value2) { defaultOptions2.mode = value2 }, }), ]), ]), h$4('tr', [ h$4('td', [ GlobalConfig.i18n('vxe.export.expColumn'), ]), h$4('td', [ h$4( 'div', { class: 'vxe-export--panel-column', }, [ h$4( 'ul', { class: 'vxe-export--panel-column-header', }, [ h$4( 'li', { class: [ 'vxe-export--panel-column-option', { 'is--checked': isAllChecked, 'is--indeterminate': isAllIndeterminate, }, ], title: GlobalConfig.i18n( 'vxe.table.allTitle' ), onClick: allColumnEvent, }, [ h$4('span', { class: [ 'vxe-checkbox--icon', isAllIndeterminate ? GlobalConfig.icon .TABLE_CHECKBOX_INDETERMINATE : isAllChecked ? GlobalConfig.icon .TABLE_CHECKBOX_CHECKED : GlobalConfig.icon .TABLE_CHECKBOX_UNCHECKED, ], }), h$4( 'span', { class: 'vxe-checkbox--label', }, GlobalConfig.i18n( 'vxe.export.expCurrentColumn' ) ), ] ), ] ), h$4( 'ul', { class: 'vxe-export--panel-column-body', }, cols ), ] ), ]), ]), h$4('tr', [ h$4('td', GlobalConfig.i18n('vxe.export.expOpts')), h$4('td', [ h$4( 'div', { class: 'vxe-export--panel-option-row', }, [ h$4(VxeCheckboxComponent, { modelValue: defaultOptions2.isHeader, title: GlobalConfig.i18n( 'vxe.export.expHeaderTitle' ), content: GlobalConfig.i18n( 'vxe.export.expOptHeader' ), 'onUpdate:modelValue': function (value2) { defaultOptions2.isHeader = value2 }, }), h$4(VxeCheckboxComponent, { modelValue: defaultOptions2.isFooter, disabled: !storeData2.hasFooter, title: GlobalConfig.i18n( 'vxe.export.expFooterTitle' ), content: GlobalConfig.i18n( 'vxe.export.expOptFooter' ), 'onUpdate:modelValue': function (value2) { defaultOptions2.isFooter = value2 }, }), h$4(VxeCheckboxComponent, { modelValue: defaultOptions2.original, title: GlobalConfig.i18n( 'vxe.export.expOriginalTitle' ), content: GlobalConfig.i18n( 'vxe.export.expOptOriginal' ), 'onUpdate:modelValue': function (value2) { defaultOptions2.original = value2 }, }), ] ), h$4( 'div', { class: 'vxe-export--panel-option-row', }, [ h$4(VxeCheckboxComponent, { modelValue: isHeader && hasColgroup && supportMerge ? defaultOptions2.isColgroup : false, title: GlobalConfig.i18n( 'vxe.export.expColgroupTitle' ), disabled: !isHeader || !hasColgroup || !supportMerge, content: GlobalConfig.i18n( 'vxe.export.expOptColgroup' ), 'onUpdate:modelValue': function (value2) { defaultOptions2.isColgroup = value2 }, }), h$4(VxeCheckboxComponent, { modelValue: hasMerge && supportMerge && checkedAll ? defaultOptions2.isMerge : false, title: GlobalConfig.i18n( 'vxe.export.expMergeTitle' ), disabled: !hasMerge || !supportMerge || !checkedAll, content: GlobalConfig.i18n( 'vxe.export.expOptMerge' ), 'onUpdate:modelValue': function (value2) { defaultOptions2.isMerge = value2 }, }), isPrint2 ? createCommentVNode() : h$4(VxeCheckboxComponent, { modelValue: supportStyle ? defaultOptions2.useStyle : false, disabled: !supportStyle, title: GlobalConfig.i18n( 'vxe.export.expUseStyleTitle' ), content: GlobalConfig.i18n( 'vxe.export.expOptUseStyle' ), 'onUpdate:modelValue': function (value2) { defaultOptions2.useStyle = value2 }, }), h$4(VxeCheckboxComponent, { modelValue: hasTree ? defaultOptions2.isAllExpand : false, disabled: !hasTree, title: GlobalConfig.i18n( 'vxe.export.expAllExpandTitle' ), content: GlobalConfig.i18n( 'vxe.export.expOptAllExpand' ), 'onUpdate:modelValue': function (value2) { defaultOptions2.isAllExpand = value2 }, }), ] ), ]), ]), ], ]), ] ), h$4( 'div', { class: 'vxe-export--panel-btns', }, [ h$4(VxeButtonComponent, { content: GlobalConfig.i18n('vxe.export.expCancel'), onClick: cancelEvent, }), h$4(VxeButtonComponent, { ref: xButtonConfirm, status: 'primary', content: GlobalConfig.i18n( isPrint2 ? 'vxe.export.expPrint' : 'vxe.export.expConfirm' ), onClick: confirmEvent, }), ] ), ] ) }, } ) } return renderVN }, }) var VxeRadioGroupComponent = defineComponent({ name: 'VxeRadioGroup', props: { modelValue: [String, Number, Boolean], disabled: Boolean, strict: { type: Boolean, default: function () { return GlobalConfig.radio.strict }, }, size: { type: String, default: function () { return GlobalConfig.radio.size || GlobalConfig.size }, }, }, emits: ['update:modelValue', 'change'], setup: function (props2, context2) { var slots = context2.slots, emit2 = context2.emit var $xeform = inject('$xeform', null) var $xeformiteminfo = inject('$xeformiteminfo', null) var xID = xeUtils.uniqueId() var $xeradiogroup = { xID, props: props2, context: context2, name: xeUtils.uniqueId('xegroup_'), } var radioGroupMethods = {} useSize(props2) var radioGroupPrivateMethods = { handleChecked: function (params2, evnt) { emit2('update:modelValue', params2.label) radioGroupMethods.dispatchEvent('change', params2) if ($xeform && $xeformiteminfo) { $xeform.triggerItemEvent( evnt, $xeformiteminfo.itemConfig.field, params2.label ) } }, } radioGroupMethods = { dispatchEvent: function (type4, params2, evnt) { emit2( type4, Object.assign({ $radioGroup: $xeradiogroup, $event: evnt }, params2) ) }, } var renderVN = function () { return h$4( 'div', { class: 'vxe-radio-group', }, slots.default ? slots.default({}) : [] ) } Object.assign($xeradiogroup, radioGroupPrivateMethods, { renderVN, dispatchEvent, }) provide('$xeradiogroup', $xeradiogroup) return renderVN }, }) var VxeRadioComponent = defineComponent({ name: 'VxeRadio', props: { modelValue: [String, Number, Boolean], label: { type: [String, Number, Boolean], default: null }, title: [String, Number], content: [String, Number], disabled: Boolean, name: String, strict: { type: Boolean, default: function () { return GlobalConfig.radio.strict }, }, size: { type: String, default: function () { return GlobalConfig.radio.size || GlobalConfig.size }, }, }, emits: ['update:modelValue', 'change'], setup: function (props2, context2) { var slots = context2.slots, emit2 = context2.emit var $xeform = inject('$xeform', null) var $xeformiteminfo = inject('$xeformiteminfo', null) var xID = xeUtils.uniqueId() var $xeradio = { xID, props: props2, context: context2, } var computeSize = useSize(props2) var $xeradiogroup = inject('$xeradiogroup', null) var radioMethods = {} var computeDisabled = computed(function () { return props2.disabled || ($xeradiogroup && $xeradiogroup.props.disabled) }) var computeName = computed(function () { return $xeradiogroup ? $xeradiogroup.name : props2.name }) var computeStrict = computed(function () { return $xeradiogroup ? $xeradiogroup.props.strict : props2.strict }) var computeChecked = computed(function () { var modelValue = props2.modelValue, label = props2.label return $xeradiogroup ? $xeradiogroup.props.modelValue === label : modelValue === label }) var handleValue2 = function (label, evnt) { if ($xeradiogroup) { $xeradiogroup.handleChecked({ label }, evnt) } else { emit2('update:modelValue', label) radioMethods.dispatchEvent('change', { label }, evnt) if ($xeform && $xeformiteminfo) { $xeform.triggerItemEvent( evnt, $xeformiteminfo.itemConfig.field, label ) } } } var changeEvent = function (evnt) { var isDisabled = computeDisabled.value if (!isDisabled) { handleValue2(props2.label, evnt) } } var clickEvent = function (evnt) { var isDisabled = computeDisabled.value var isStrict = computeStrict.value if (!isDisabled && !isStrict) { if ( props2.label === ($xeradiogroup ? $xeradiogroup.props.modelValue : props2.modelValue) ) { handleValue2(null, evnt) } } } radioMethods = { dispatchEvent: function (type4, params2, evnt) { emit2(type4, Object.assign({ $radio: $xeradio, $event: evnt }, params2)) }, } Object.assign($xeradio, radioMethods) var renderVN = function () { var _a2 var vSize = computeSize.value var isDisabled = computeDisabled.value var name2 = computeName.value var isChecked = computeChecked.value return h$4( 'label', { class: [ 'vxe-radio', ((_a2 = {}), (_a2['size--'.concat(vSize)] = vSize), (_a2['is--checked'] = isChecked), (_a2['is--disabled'] = isDisabled), _a2), ], title: props2.title, }, [ h$4('input', { class: 'vxe-radio--input', type: 'radio', name: name2, checked: isChecked, disabled: isDisabled, onChange: changeEvent, onClick: clickEvent, }), h$4('span', { class: [ 'vxe-radio--icon', isChecked ? 'vxe-icon-radio-checked' : 'vxe-icon-radio-unchecked', ], }), h$4( 'span', { class: 'vxe-radio--label', }, slots.default ? slots.default({}) : getFuncText(props2.content) ), ] ) } $xeradio.renderVN = renderVN return $xeradio }, render: function () { return this.renderVN() }, }) var ImportPanelComponent = defineComponent({ name: 'VxeImportPanel', props: { defaultOptions: Object, storeData: Object, }, setup: function (props2) { var $xetable = inject('$xetable', {}) var computeImportOpts = $xetable.getComputeMaps().computeImportOpts var reactData = reactive({ loading: false, }) var refFileBtn = ref() var computeSelectName = computed(function () { var storeData2 = props2.storeData return ''.concat(storeData2.filename, '.').concat(storeData2.type) }) var computeHasFile = computed(function () { var storeData2 = props2.storeData return storeData2.file && storeData2.type }) var computeParseTypeLabel = computed(function () { var storeData2 = props2.storeData var type4 = storeData2.type, typeList = storeData2.typeList if (type4) { var selectItem = xeUtils.find(typeList, function (item2) { return type4 === item2.value }) return selectItem ? GlobalConfig.i18n(selectItem.label) : '*.*' } return '*.'.concat( typeList .map(function (item2) { return item2.value }) .join(', *.') ) }) var clearFileEvent = function () { var storeData2 = props2.storeData Object.assign(storeData2, { filename: '', sheetName: '', type: '', }) } var selectFileEvent = function () { var storeData2 = props2.storeData, defaultOptions2 = props2.defaultOptions $xetable .readFile(defaultOptions2) .then(function (params2) { var file2 = params2.file Object.assign(storeData2, parseFile(file2), { file: file2 }) }) .catch(function (e2) { return e2 }) } var showEvent = function () { nextTick(function () { var targetElem = refFileBtn.value if (targetElem) { targetElem.focus() } }) } var cancelEvent = function () { var storeData2 = props2.storeData storeData2.visible = false } var importEvent = function () { var storeData2 = props2.storeData, defaultOptions2 = props2.defaultOptions var importOpts = computeImportOpts.value reactData.loading = true $xetable .importByFile( storeData2.file, Object.assign({}, importOpts, defaultOptions2) ) .then(function () { reactData.loading = false storeData2.visible = false }) .catch(function () { reactData.loading = false }) } var renderVN = function () { var defaultOptions2 = props2.defaultOptions, storeData2 = props2.storeData var selectName = computeSelectName.value var hasFile = computeHasFile.value var parseTypeLabel = computeParseTypeLabel.value return h$4( VxeModalComponent, { modelValue: storeData2.visible, title: GlobalConfig.i18n('vxe.import.impTitle'), width: 440, mask: true, lockView: true, showFooter: false, escClosable: true, maskClosable: true, loading: reactData.loading, 'onUpdate:modelValue': function (value2) { storeData2.visible = value2 }, onShow: showEvent, }, { default: function () { return h$4( 'div', { class: 'vxe-export--panel', }, [ h$4( 'table', { cellspacing: 0, cellpadding: 0, border: 0, }, [ h$4('tbody', [ h$4('tr', [ h$4('td', GlobalConfig.i18n('vxe.import.impFile')), h$4('td', [ hasFile ? h$4( 'div', { class: 'vxe-import-selected--file', title: selectName, }, [ h$4('span', selectName), h$4('i', { class: GlobalConfig.icon.INPUT_CLEAR, onClick: clearFileEvent, }), ] ) : h$4( 'button', { ref: refFileBtn, class: 'vxe-import-select--file', onClick: selectFileEvent, }, GlobalConfig.i18n('vxe.import.impSelect') ), ]), ]), h$4('tr', [ h$4('td', GlobalConfig.i18n('vxe.import.impType')), h$4('td', parseTypeLabel), ]), h$4('tr', [ h$4('td', GlobalConfig.i18n('vxe.import.impOpts')), h$4('td', [ h$4( VxeRadioGroupComponent, { modelValue: defaultOptions2.mode, 'onUpdate:modelValue': function (value2) { defaultOptions2.mode = value2 }, }, { default: function () { return storeData2.modeList.map(function ( item2 ) { return h$4(VxeRadioComponent, { label: item2.value, content: GlobalConfig.i18n(item2.label), }) }) }, } ), ]), ]), ]), ] ), h$4( 'div', { class: 'vxe-export--panel-btns', }, [ h$4(VxeButtonComponent, { content: GlobalConfig.i18n('vxe.import.impCancel'), onClick: cancelEvent, }), h$4(VxeButtonComponent, { status: 'primary', disabled: !hasFile, content: GlobalConfig.i18n('vxe.import.impConfirm'), onClick: importEvent, }), ] ), ] ) }, } ) } return renderVN }, }) dynamicApp.component(ExportPanelComponent.name, ExportPanelComponent) dynamicApp.component(ImportPanelComponent.name, ImportPanelComponent) var __assign$e = (globalThis && globalThis.__assign) || function () { __assign$e = Object.assign || function (t3) { for (var s2, i2 = 1, n2 = arguments.length; i2 < n2; i2++) { s2 = arguments[i2] for (var p2 in s2) if (Object.prototype.hasOwnProperty.call(s2, p2)) t3[p2] = s2[p2] } return t3 } return __assign$e.apply(this, arguments) } var Rule$1 = (function () { function Rule2(rule2) { Object.assign(this, { $options: rule2, required: rule2.required, min: rule2.min, max: rule2.max, type: rule2.type, pattern: rule2.pattern, validator: rule2.validator, trigger: rule2.trigger, maxWidth: rule2.maxWidth, }) } Object.defineProperty(Rule2.prototype, 'content', { get: function () { return getFuncText(this.$options.content || this.$options.message) }, enumerable: false, configurable: true, }) Object.defineProperty(Rule2.prototype, 'message', { get: function () { return this.content }, enumerable: false, configurable: true, }) return Rule2 })() var tableValidatorMethodKeys = ['fullValidate', 'validate', 'clearValidate'] var validatorHook = { setupTable: function ($xetable) { var props2 = $xetable.props, reactData = $xetable.reactData, internalData = $xetable.internalData var refValidTooltip = $xetable.getRefMaps().refValidTooltip var _a2 = $xetable.getComputeMaps(), computeValidOpts = _a2.computeValidOpts, computeTreeOpts = _a2.computeTreeOpts, computeEditOpts = _a2.computeEditOpts var validatorMethods = {} var validatorPrivateMethods = {} var validRuleErr var handleValidError = function (params2) { return new Promise(function (resolve2) { var validOpts = computeValidOpts.value if (validOpts.autoPos === false) { $xetable.dispatchEvent('valid-error', params2, null) resolve2() } else { $xetable .handleActived(params2, { type: 'valid-error', trigger: 'call' }) .then(function () { resolve2(validatorPrivateMethods.showValidTooltip(params2)) }) } }) } var handleErrMsgMode = function (validErrMaps) { var validOpts = computeValidOpts.value if (validOpts.msgMode === 'single') { var keys3 = Object.keys(validErrMaps) var resMaps = validErrMaps if (keys3.length) { var firstKey = keys3[0] resMaps[firstKey] = validErrMaps[firstKey] } return resMaps } return validErrMaps } var beginValidate = function (rows, cb, isFull) { var validRest = {} var editRules = props2.editRules, treeConfig = props2.treeConfig var afterFullData = internalData.afterFullData var treeOpts = computeTreeOpts.value var childrenField = treeOpts.children || treeOpts.childrenField var validOpts = computeValidOpts.value var vaildDatas if (rows === true) { vaildDatas = afterFullData } else if (rows) { if (xeUtils.isFunction(rows)) { cb = rows } else { vaildDatas = xeUtils.isArray(rows) ? rows : [rows] } } if (!vaildDatas) { if ($xetable.getInsertRecords) { vaildDatas = $xetable .getInsertRecords() .concat($xetable.getUpdateRecords()) } else { vaildDatas = [] } } var rowValids = [] internalData._lastCallTime = Date.now() validRuleErr = false validatorMethods.clearValidate() var validErrMaps = {} if (editRules) { var columns_1 = $xetable.getColumns() var handleVaild = function (row) { if (isFull || !validRuleErr) { var colVailds_1 = [] columns_1.forEach(function (column) { if ( (isFull || !validRuleErr) && xeUtils.has(editRules, column.property) ) { colVailds_1.push( validatorPrivateMethods .validCellRules('all', row, column) .catch(function (_a3) { var rule2 = _a3.rule, rules2 = _a3.rules var rest = { rule: rule2, rules: rules2, rowIndex: $xetable.getRowIndex(row), row, columnIndex: $xetable.getColumnIndex(column), column, field: column.property, $table: $xetable, } if (!validRest[column.property]) { validRest[column.property] = [] } validErrMaps[ '' .concat(getRowid($xetable, row), ':') .concat(column.id) ] = { column, row, rule: rule2, content: rule2.content, } validRest[column.property].push(rest) if (!isFull) { validRuleErr = true return Promise.reject(rest) } }) ) } }) rowValids.push(Promise.all(colVailds_1)) } } if (treeConfig) { xeUtils.eachTree(vaildDatas, handleVaild, { children: childrenField }) } else { vaildDatas.forEach(handleVaild) } return Promise.all(rowValids) .then(function () { var ruleProps = Object.keys(validRest) reactData.validErrorMaps = handleErrMsgMode(validErrMaps) return nextTick().then(function () { if (ruleProps.length) { return Promise.reject(validRest[ruleProps[0]][0]) } if (cb) { cb() } }) }) .catch(function (firstErrParams) { return new Promise(function (resolve2, reject2) { var finish = function () { nextTick(function () { if (cb) { cb(validRest) resolve2() } else { if (GlobalConfig.validToReject === 'obsolete') { reject2(validRest) } else { resolve2(validRest) } } }) } var posAndFinish = function () { firstErrParams.cell = $xetable.getCell( firstErrParams.row, firstErrParams.column ) scrollToView(firstErrParams.cell) handleValidError(firstErrParams).then(finish) } var row = firstErrParams.row var rowIndex = afterFullData.indexOf(row) var locatRow = rowIndex > 0 ? afterFullData[rowIndex - 1] : row if (validOpts.autoPos === false) { finish() } else { if (treeConfig) { $xetable.scrollToTreeRow(locatRow).then(posAndFinish) } else { $xetable.scrollToRow(locatRow).then(posAndFinish) } } }) }) } else { reactData.validErrorMaps = {} } return nextTick().then(function () { if (cb) { cb() } }) } validatorMethods = { fullValidate: function (rows, cb) { return beginValidate(rows, cb, true) }, validate: function (rows, cb) { return beginValidate(rows, cb) }, clearValidate: function (rows, fieldOrColumn) { var validErrorMaps = reactData.validErrorMaps var validTip = refValidTooltip.value var validOpts = computeValidOpts.value var rowList = xeUtils.isArray(rows) ? rows : rows ? [rows] : [] var colList = xeUtils.isArray(fieldOrColumn) ? fieldOrColumn : (fieldOrColumn ? [fieldOrColumn] : []).map(function (column) { return handleFieldOrColumn($xetable, column) }) var validErrMaps = {} if (validTip && validTip.reactData.visible) { validTip.close() } if (validOpts.msgMode === 'single') { reactData.validErrorMaps = {} return nextTick() } if (rowList.length && colList.length) { validErrMaps = Object.assign({}, validErrorMaps) rowList.forEach(function (row) { colList.forEach(function (column) { var vaildKey = '' .concat(getRowid($xetable, row), ':') .concat(column.id) if (validErrMaps[vaildKey]) { delete validErrMaps[vaildKey] } }) }) } else if (rowList.length) { var rowidList_1 = rowList.map(function (row) { return ''.concat(getRowid($xetable, row)) }) xeUtils.each(validErrorMaps, function (item2, key2) { if (rowidList_1.indexOf(key2.split(':')[0]) > -1) { validErrMaps[key2] = item2 } }) } else if (colList.length) { var colidList_1 = colList.map(function (column) { return ''.concat(column.id) }) xeUtils.each(validErrorMaps, function (item2, key2) { if (colidList_1.indexOf(key2.split(':')[1]) > -1) { validErrMaps[key2] = item2 } }) } reactData.validErrorMaps = validErrMaps return nextTick() }, } var validErrorRuleValue2 = function (rule2, val2) { var type4 = rule2.type, min3 = rule2.min, max3 = rule2.max, pattern4 = rule2.pattern var isNumType = type4 === 'number' var numVal = isNumType ? xeUtils.toNumber(val2) : xeUtils.getSize(val2) if (isNumType && isNaN(val2)) { return true } if (!xeUtils.eqNull(min3) && numVal < xeUtils.toNumber(min3)) { return true } if (!xeUtils.eqNull(max3) && numVal > xeUtils.toNumber(max3)) { return true } if ( pattern4 && !(xeUtils.isRegExp(pattern4) ? pattern4 : new RegExp(pattern4)).test( val2 ) ) { return true } return false } validatorPrivateMethods = { validCellRules: function (validType, row, column, val2) { var editRules = props2.editRules var field2 = column.field var errorRules = [] var syncVailds = [] if (field2 && editRules) { var rules_1 = xeUtils.get(editRules, field2) if (rules_1) { var cellValue_1 = xeUtils.isUndefined(val2) ? xeUtils.get(row, field2) : val2 rules_1.forEach(function (rule2) { var type4 = rule2.type, trigger2 = rule2.trigger, required4 = rule2.required, validator2 = rule2.validator if (validType === 'all' || !trigger2 || validType === trigger2) { if (validator2) { var validParams = { cellValue: cellValue_1, rule: rule2, rules: rules_1, row, rowIndex: $xetable.getRowIndex(row), column, columnIndex: $xetable.getColumnIndex(column), field: column.field, $table: $xetable, $grid: $xetable.xegrid, } var customValid = void 0 if (xeUtils.isString(validator2)) { var gvItem = VXETable.validators.get(validator2) if (gvItem) { if (gvItem.cellValidatorMethod) { customValid = gvItem.cellValidatorMethod(validParams) } } } else { customValid = validator2(validParams) } if (customValid) { if (xeUtils.isError(customValid)) { validRuleErr = true errorRules.push( new Rule$1({ type: 'custom', trigger: trigger2, content: customValid.message, rule: new Rule$1(rule2), }) ) } else if (customValid.catch) { syncVailds.push( customValid.catch(function (e2) { validRuleErr = true errorRules.push( new Rule$1({ type: 'custom', trigger: trigger2, content: e2 && e2.message ? e2.message : rule2.content || rule2.message, rule: new Rule$1(rule2), }) ) }) ) } } } else { var isArrType = type4 === 'array' var isArrVal = xeUtils.isArray(cellValue_1) var hasEmpty = true if (isArrType || isArrVal) { hasEmpty = !isArrVal || !cellValue_1.length } else if (xeUtils.isString(cellValue_1)) { hasEmpty = eqEmptyValue(cellValue_1.trim()) } else { hasEmpty = eqEmptyValue(cellValue_1) } if ( required4 ? hasEmpty || validErrorRuleValue2(rule2, cellValue_1) : !hasEmpty && validErrorRuleValue2(rule2, cellValue_1) ) { validRuleErr = true errorRules.push(new Rule$1(rule2)) } } } }) } } return Promise.all(syncVailds).then(function () { if (errorRules.length) { var rest = { rules: errorRules, rule: errorRules[0] } return Promise.reject(rest) } }) }, hasCellRules: function (type4, row, column) { var editRules = props2.editRules var field2 = column.field if (field2 && editRules) { var rules2 = xeUtils.get(editRules, field2) return ( rules2 && !!xeUtils.find(rules2, function (rule2) { return ( type4 === 'all' || !rule2.trigger || type4 === rule2.trigger ) }) ) } return false }, triggerValidate: function (type4) { var editConfig = props2.editConfig, editRules = props2.editRules var editStore = reactData.editStore var actived = editStore.actived var editOpts = computeEditOpts.value var validOpts = computeValidOpts.value if (editRules && validOpts.msgMode === 'single') { reactData.validErrorMaps = {} } if (editConfig && editRules && actived.row) { var _a3 = actived.args, row_1 = _a3.row, column_1 = _a3.column, cell_1 = _a3.cell if (validatorPrivateMethods.hasCellRules(type4, row_1, column_1)) { return validatorPrivateMethods .validCellRules(type4, row_1, column_1) .then(function () { if (editOpts.mode === 'row') { validatorMethods.clearValidate(row_1, column_1) } }) .catch(function (_a4) { var rule2 = _a4.rule if (!rule2.trigger || type4 === rule2.trigger) { var rest = { rule: rule2, row: row_1, column: column_1, cell: cell_1, } validatorPrivateMethods.showValidTooltip(rest) return Promise.reject(rest) } return Promise.resolve() }) } } return Promise.resolve() }, showValidTooltip: function (params2) { var _a3, _b2 var height = props2.height var tableData2 = reactData.tableData, validStore = reactData.validStore, validErrorMaps = reactData.validErrorMaps var validOpts = computeValidOpts.value var validTip = refValidTooltip.value validStore.visible = true if (validOpts.msgMode === 'single') { reactData.validErrorMaps = ((_a3 = {}), (_a3[ '' .concat(getRowid($xetable, params2.row), ':') .concat(params2.column.id) ] = { column: params2.column, row: params2.row, rule: params2.rule, content: params2.rule.content, }), _a3) } else { reactData.validErrorMaps = Object.assign( {}, validErrorMaps, ((_b2 = {}), (_b2[ '' .concat(getRowid($xetable, params2.row), ':') .concat(params2.column.id) ] = { column: params2.column, row: params2.row, rule: params2.rule, content: params2.rule.content, }), _b2) ) } $xetable.dispatchEvent('valid-error', params2, null) if (validTip) { var cell = params2.cell if ( validTip && (validOpts.message === 'tooltip' || (validOpts.message === 'default' && !height && tableData2.length < 2)) ) { return validTip.open(cell, params2.rule.content) } } return nextTick() }, } return __assign$e(__assign$e({}, validatorMethods), validatorPrivateMethods) }, setupGrid: function ($xegrid) { return $xegrid.extendTableMethods(tableValidatorMethodKeys) }, } var VxeModuleValidator = { install: function () { VXETable.hooks.add('$tableValidator', validatorHook) }, } var Validator = VxeModuleValidator var VxeIconComponent = defineComponent({ name: 'VxeIcon', props: { name: String, roll: Boolean, }, emits: ['click'], setup: function (props2, _a2) { var emit2 = _a2.emit var clickEvent = function (evnt) { emit2('click', { $event: evnt }) } return function () { return h$4('i', { class: ['vxe-icon-'.concat(props2.name), props2.roll ? 'roll' : ''], onClick: clickEvent, }) } }, }) var VxeIcon = Object.assign(VxeIconComponent, { install: function (app2) { app2.component(VxeIconComponent.name, VxeIconComponent) }, }) var Icon$2 = VxeIcon dynamicApp.component(VxeIcon.name, VxeIcon) var __assign$d = (globalThis && globalThis.__assign) || function () { __assign$d = Object.assign || function (t3) { for (var s2, i2 = 1, n2 = arguments.length; i2 < n2; i2++) { s2 = arguments[i2] for (var p2 in s2) if (Object.prototype.hasOwnProperty.call(s2, p2)) t3[p2] = s2[p2] } return t3 } return __assign$d.apply(this, arguments) } function renderHelpIcon(params2) { var $table = params2.$table, column = params2.column var titlePrefix = column.titlePrefix || column.titleHelp return titlePrefix ? [ h$4('i', { class: [ 'vxe-cell-help-icon', titlePrefix.icon || GlobalConfig.icon.TABLE_HELP, ], onMouseenter: function (evnt) { $table.triggerHeaderHelpEvent(evnt, params2) }, onMouseleave: function (evnt) { $table.handleTargetLeaveEvent(evnt) }, }), ] : [] } function renderTitleContent(params2, content2) { var $table = params2.$table, column = params2.column var props2 = $table.props, reactData = $table.reactData var computeTooltipOpts = $table.getComputeMaps().computeTooltipOpts var allColumnHeaderOverflow = props2.showHeaderOverflow var type4 = column.type, showHeaderOverflow = column.showHeaderOverflow var tooltipOpts = computeTooltipOpts.value var showAllTip = tooltipOpts.showAll var headOverflow = xeUtils.isUndefined(showHeaderOverflow) || xeUtils.isNull(showHeaderOverflow) ? allColumnHeaderOverflow : showHeaderOverflow var showTitle = headOverflow === 'title' var showTooltip2 = headOverflow === true || headOverflow === 'tooltip' var ons = {} if (showTitle || showTooltip2 || showAllTip) { ons.onMouseenter = function (evnt) { if (reactData._isResize) { return } if (showTitle) { updateCellTitle(evnt.currentTarget, column) } else if (showTooltip2 || showAllTip) { $table.triggerHeaderTooltipEvent(evnt, params2) } } } if (showTooltip2 || showAllTip) { ons.onMouseleave = function (evnt) { if (reactData._isResize) { return } if (showTooltip2 || showAllTip) { $table.handleTargetLeaveEvent(evnt) } } } return [ type4 === 'html' && xeUtils.isString(content2) ? h$4( 'span', __assign$d({ class: 'vxe-cell--title', innerHTML: content2 }, ons) ) : h$4( 'span', __assign$d({ class: 'vxe-cell--title' }, ons), getSlotVNs(content2) ), ] } function getFooterContent(params2) { var $table = params2.$table, column = params2.column, _columnIndex = params2._columnIndex, items = params2.items var slots = column.slots, editRender = column.editRender, cellRender = column.cellRender var renderOpts = editRender || cellRender var footerSlot = slots ? slots.footer : null if (footerSlot) { return $table.callSlot(footerSlot, params2) } if (renderOpts) { var compConf = VXETable.renderer.get(renderOpts.name) if (compConf && compConf.renderFooter) { return getSlotVNs(compConf.renderFooter(renderOpts, params2)) } } return [formatText(items[_columnIndex], 1)] } function getDefaultCellLabel(params2) { var $table = params2.$table, row = params2.row, column = params2.column return formatText($table.getCellLabel(row, column), 1) } var Cell$1 = { createColumn: function ($xetable, columnOpts) { var type4 = columnOpts.type, sortable = columnOpts.sortable, filters = columnOpts.filters, editRender = columnOpts.editRender, treeNode = columnOpts.treeNode var props2 = $xetable.props var editConfig = props2.editConfig var _a2 = $xetable.getComputeMaps(), computeEditOpts = _a2.computeEditOpts, computeCheckboxOpts = _a2.computeCheckboxOpts var checkboxOpts = computeCheckboxOpts.value var editOpts = computeEditOpts.value var renConfs = { renderHeader: Cell$1.renderDefaultHeader, renderCell: treeNode ? Cell$1.renderTreeCell : Cell$1.renderDefaultCell, renderFooter: Cell$1.renderDefaultFooter, } switch (type4) { case 'seq': renConfs.renderHeader = Cell$1.renderSeqHeader renConfs.renderCell = treeNode ? Cell$1.renderTreeIndexCell : Cell$1.renderSeqCell break case 'radio': renConfs.renderHeader = Cell$1.renderRadioHeader renConfs.renderCell = treeNode ? Cell$1.renderTreeRadioCell : Cell$1.renderRadioCell break case 'checkbox': renConfs.renderHeader = Cell$1.renderCheckboxHeader renConfs.renderCell = checkboxOpts.checkField ? treeNode ? Cell$1.renderTreeSelectionCellByProp : Cell$1.renderCheckboxCellByProp : treeNode ? Cell$1.renderTreeSelectionCell : Cell$1.renderCheckboxCell break case 'expand': renConfs.renderCell = Cell$1.renderExpandCell renConfs.renderData = Cell$1.renderExpandData break case 'html': renConfs.renderCell = treeNode ? Cell$1.renderTreeHTMLCell : Cell$1.renderHTMLCell if (filters && sortable) { renConfs.renderHeader = Cell$1.renderSortAndFilterHeader } else if (sortable) { renConfs.renderHeader = Cell$1.renderSortHeader } else if (filters) { renConfs.renderHeader = Cell$1.renderFilterHeader } break default: if (editConfig && editRender) { renConfs.renderHeader = Cell$1.renderEditHeader renConfs.renderCell = editOpts.mode === 'cell' ? treeNode ? Cell$1.renderTreeCellEdit : Cell$1.renderCellEdit : treeNode ? Cell$1.renderTreeRowEdit : Cell$1.renderRowEdit } else if (filters && sortable) { renConfs.renderHeader = Cell$1.renderSortAndFilterHeader } else if (sortable) { renConfs.renderHeader = Cell$1.renderSortHeader } else if (filters) { renConfs.renderHeader = Cell$1.renderFilterHeader } } return createColumn($xetable, columnOpts, renConfs) }, renderHeaderTitle: function (params2) { var $table = params2.$table, column = params2.column var slots = column.slots, editRender = column.editRender, cellRender = column.cellRender var renderOpts = editRender || cellRender var headerSlot = slots ? slots.header : null if (headerSlot) { return renderTitleContent(params2, $table.callSlot(headerSlot, params2)) } if (renderOpts) { var compConf = VXETable.renderer.get(renderOpts.name) if (compConf && compConf.renderHeader) { return renderTitleContent( params2, getSlotVNs(compConf.renderHeader(renderOpts, params2)) ) } } return renderTitleContent(params2, formatText(column.getTitle(), 1)) }, renderDefaultHeader: function (params2) { return renderHelpIcon(params2).concat(Cell$1.renderHeaderTitle(params2)) }, renderDefaultCell: function (params2) { var $table = params2.$table, row = params2.row, column = params2.column var slots = column.slots, editRender = column.editRender, cellRender = column.cellRender var renderOpts = editRender || cellRender var defaultSlot = slots ? slots.default : null if (defaultSlot) { return $table.callSlot(defaultSlot, params2) } if (renderOpts) { var funName = editRender ? 'renderCell' : 'renderDefault' var compConf = VXETable.renderer.get(renderOpts.name) var compFn = compConf ? compConf[funName] : null if (compFn) { return getSlotVNs( compFn( renderOpts, Object.assign({ $type: editRender ? 'edit' : 'cell' }, params2) ) ) } } var cellValue = $table.getCellLabel(row, column) var cellPlaceholder = editRender ? editRender.placeholder : '' return [ h$4( 'span', { class: 'vxe-cell--label', }, editRender && eqEmptyValue(cellValue) ? [ h$4( 'span', { class: 'vxe-cell--placeholder', }, formatText(getFuncText(cellPlaceholder), 1) ), ] : formatText(cellValue, 1) ), ] }, renderTreeCell: function (params2) { return Cell$1.renderTreeIcon(params2, Cell$1.renderDefaultCell(params2)) }, renderDefaultFooter: function (params2) { return [ h$4( 'span', { class: 'vxe-cell--item', }, getFooterContent(params2) ), ] }, renderTreeIcon: function (params2, cellVNodes) { var $table = params2.$table, isHidden2 = params2.isHidden var reactData = $table.reactData var computeTreeOpts = $table.getComputeMaps().computeTreeOpts var treeExpandedMaps = reactData.treeExpandedMaps, treeExpandLazyLoadedMaps = reactData.treeExpandLazyLoadedMaps var treeOpts = computeTreeOpts.value var row = params2.row, column = params2.column, level = params2.level var slots = column.slots var indent = treeOpts.indent, lazy = treeOpts.lazy, trigger2 = treeOpts.trigger, iconLoaded = treeOpts.iconLoaded, showIcon = treeOpts.showIcon, iconOpen = treeOpts.iconOpen, iconClose = treeOpts.iconClose var childrenField = treeOpts.children || treeOpts.childrenField var hasChildField = treeOpts.hasChild || treeOpts.hasChildField var rowChilds = row[childrenField] var iconSlot = slots ? slots.icon : null var hasLazyChilds = false var isAceived = false var isLazyLoaded = false var ons = {} if (iconSlot) { return $table.callSlot(iconSlot, params2) } if (!isHidden2) { var rowid = getRowid($table, row) isAceived = !!treeExpandedMaps[rowid] if (lazy) { isLazyLoaded = !!treeExpandLazyLoadedMaps[rowid] hasLazyChilds = row[hasChildField] } } if (!trigger2 || trigger2 === 'default') { ons.onClick = function (evnt) { evnt.stopPropagation() $table.triggerTreeExpandEvent(evnt, params2) } } return [ h$4( 'div', { class: [ 'vxe-cell--tree-node', { 'is--active': isAceived, }, ], style: { paddingLeft: ''.concat(level * indent, 'px'), }, }, [ showIcon && ((rowChilds && rowChilds.length) || hasLazyChilds) ? [ h$4( 'div', __assign$d({ class: 'vxe-tree--btn-wrapper' }, ons), [ h$4('i', { class: [ 'vxe-tree--node-btn', isLazyLoaded ? iconLoaded || GlobalConfig.icon.TABLE_TREE_LOADED : isAceived ? iconOpen || GlobalConfig.icon.TABLE_TREE_OPEN : iconClose || GlobalConfig.icon.TABLE_TREE_CLOSE, ], }), ] ), ] : null, h$4( 'div', { class: 'vxe-tree-cell', }, cellVNodes ), ] ), ] }, renderSeqHeader: function (params2) { var $table = params2.$table, column = params2.column var slots = column.slots var headerSlot = slots ? slots.header : null return renderTitleContent( params2, headerSlot ? $table.callSlot(headerSlot, params2) : formatText(column.getTitle(), 1) ) }, renderSeqCell: function (params2) { var $table = params2.$table, column = params2.column var props2 = $table.props var treeConfig = props2.treeConfig var computeSeqOpts = $table.getComputeMaps().computeSeqOpts var seqOpts = computeSeqOpts.value var slots = column.slots var defaultSlot = slots ? slots.default : null if (defaultSlot) { return $table.callSlot(defaultSlot, params2) } var seq = params2.seq var seqMethod = seqOpts.seqMethod return [ formatText( seqMethod ? seqMethod(params2) : treeConfig ? seq : (seqOpts.startIndex || 0) + seq, 1 ), ] }, renderTreeIndexCell: function (params2) { return Cell$1.renderTreeIcon(params2, Cell$1.renderSeqCell(params2)) }, renderRadioHeader: function (params2) { var $table = params2.$table, column = params2.column var slots = column.slots var headerSlot = slots ? slots.header : null var titleSlot = slots ? slots.title : null return renderTitleContent( params2, headerSlot ? $table.callSlot(headerSlot, params2) : [ h$4( 'span', { class: 'vxe-radio--label', }, titleSlot ? $table.callSlot(titleSlot, params2) : formatText(column.getTitle(), 1) ), ] ) }, renderRadioCell: function (params2) { var $table = params2.$table, column = params2.column, isHidden2 = params2.isHidden var reactData = $table.reactData var computeRadioOpts = $table.getComputeMaps().computeRadioOpts var selectRadioRow = reactData.selectRadioRow var radioOpts = computeRadioOpts.value var slots = column.slots var labelField = radioOpts.labelField, checkMethod = radioOpts.checkMethod, visibleMethod = radioOpts.visibleMethod var row = params2.row var defaultSlot = slots ? slots.default : null var radioSlot = slots ? slots.radio : null var isChecked = $table.eqRow(row, selectRadioRow) var isVisible2 = !visibleMethod || visibleMethod({ row }) var isDisabled = !!checkMethod var ons if (!isHidden2) { ons = { onClick: function (evnt) { if (!isDisabled && isVisible2) { evnt.stopPropagation() $table.triggerRadioRowEvent(evnt, params2) } }, } if (checkMethod) { isDisabled = !checkMethod({ row }) } } var radioParams = __assign$d(__assign$d({}, params2), { checked: isChecked, disabled: isDisabled, visible: isVisible2, }) if (radioSlot) { return $table.callSlot(radioSlot, radioParams) } var radioVNs = [] if (isVisible2) { radioVNs.push( h$4('span', { class: [ 'vxe-radio--icon', isChecked ? GlobalConfig.icon.TABLE_RADIO_CHECKED : GlobalConfig.icon.TABLE_RADIO_UNCHECKED, ], }) ) } if (defaultSlot || labelField) { radioVNs.push( h$4( 'span', { class: 'vxe-radio--label', }, defaultSlot ? $table.callSlot(defaultSlot, radioParams) : xeUtils.get(row, labelField) ) ) } return [ h$4( 'span', __assign$d( { class: [ 'vxe-cell--radio', { 'is--checked': isChecked, 'is--disabled': isDisabled, }, ], }, ons ), radioVNs ), ] }, renderTreeRadioCell: function (params2) { return Cell$1.renderTreeIcon(params2, Cell$1.renderRadioCell(params2)) }, renderCheckboxHeader: function (params2) { var $table = params2.$table, column = params2.column, isHidden2 = params2.isHidden var reactData = $table.reactData var _a2 = $table.getComputeMaps(), computeIsAllCheckboxDisabled = _a2.computeIsAllCheckboxDisabled, computeCheckboxOpts = _a2.computeCheckboxOpts var isAllCheckboxSelected = reactData.isAllSelected, isAllCheckboxIndeterminate = reactData.isIndeterminate var isAllCheckboxDisabled = computeIsAllCheckboxDisabled.value var slots = column.slots var headerSlot = slots ? slots.header : null var titleSlot = slots ? slots.title : null var checkboxOpts = computeCheckboxOpts.value var headerTitle = column.getTitle() var ons if (!isHidden2) { ons = { onClick: function (evnt) { if (!isAllCheckboxDisabled) { evnt.stopPropagation() $table.triggerCheckAllEvent(evnt, !isAllCheckboxSelected) } }, } } var checkboxParams = __assign$d(__assign$d({}, params2), { checked: isAllCheckboxSelected, disabled: isAllCheckboxDisabled, indeterminate: isAllCheckboxIndeterminate, }) if (headerSlot) { return renderTitleContent( checkboxParams, $table.callSlot(headerSlot, checkboxParams) ) } if ( checkboxOpts.checkStrictly ? !checkboxOpts.showHeader : checkboxOpts.showHeader === false ) { return renderTitleContent(checkboxParams, [ h$4( 'span', { class: 'vxe-checkbox--label', }, titleSlot ? $table.callSlot(titleSlot, checkboxParams) : headerTitle ), ]) } return renderTitleContent(checkboxParams, [ h$4( 'span', __assign$d( { class: [ 'vxe-cell--checkbox', { 'is--checked': isAllCheckboxSelected, 'is--disabled': isAllCheckboxDisabled, 'is--indeterminate': isAllCheckboxIndeterminate, }, ], title: GlobalConfig.i18n('vxe.table.allTitle'), }, ons ), [ h$4('span', { class: [ 'vxe-checkbox--icon', isAllCheckboxIndeterminate ? GlobalConfig.icon.TABLE_CHECKBOX_INDETERMINATE : isAllCheckboxSelected ? GlobalConfig.icon.TABLE_CHECKBOX_CHECKED : GlobalConfig.icon.TABLE_CHECKBOX_UNCHECKED, ], }), ].concat( titleSlot || headerTitle ? [ h$4( 'span', { class: 'vxe-checkbox--label', }, titleSlot ? $table.callSlot(titleSlot, checkboxParams) : headerTitle ), ] : [] ) ), ]) }, renderCheckboxCell: function (params2) { var $table = params2.$table, row = params2.row, column = params2.column, isHidden2 = params2.isHidden var props2 = $table.props, reactData = $table.reactData var treeConfig = props2.treeConfig var selectCheckboxMaps = reactData.selectCheckboxMaps, treeIndeterminateMaps = reactData.treeIndeterminateMaps var computeCheckboxOpts = $table.getComputeMaps().computeCheckboxOpts var checkboxOpts = computeCheckboxOpts.value var labelField = checkboxOpts.labelField, checkMethod = checkboxOpts.checkMethod, visibleMethod = checkboxOpts.visibleMethod var slots = column.slots var defaultSlot = slots ? slots.default : null var checkboxSlot = slots ? slots.checkbox : null var indeterminate = false var isChecked = false var isVisible2 = !visibleMethod || visibleMethod({ row }) var isDisabled = !!checkMethod var ons if (!isHidden2) { var rowid = getRowid($table, row) isChecked = !!selectCheckboxMaps[rowid] ons = { onClick: function (evnt) { if (!isDisabled && isVisible2) { evnt.stopPropagation() $table.triggerCheckRowEvent(evnt, params2, !isChecked) } }, } if (checkMethod) { isDisabled = !checkMethod({ row }) } if (treeConfig) { indeterminate = !!treeIndeterminateMaps[rowid] } } var checkboxParams = __assign$d(__assign$d({}, params2), { checked: isChecked, disabled: isDisabled, visible: isVisible2, indeterminate, }) if (checkboxSlot) { return $table.callSlot(checkboxSlot, checkboxParams) } var checkVNs = [] if (isVisible2) { checkVNs.push( h$4('span', { class: [ 'vxe-checkbox--icon', indeterminate ? GlobalConfig.icon.TABLE_CHECKBOX_INDETERMINATE : isChecked ? GlobalConfig.icon.TABLE_CHECKBOX_CHECKED : GlobalConfig.icon.TABLE_CHECKBOX_UNCHECKED, ], }) ) } if (defaultSlot || labelField) { checkVNs.push( h$4( 'span', { class: 'vxe-checkbox--label', }, defaultSlot ? $table.callSlot(defaultSlot, checkboxParams) : xeUtils.get(row, labelField) ) ) } return [ h$4( 'span', __assign$d( { class: [ 'vxe-cell--checkbox', { 'is--checked': isChecked, 'is--disabled': isDisabled, 'is--indeterminate': indeterminate, }, ], }, ons ), checkVNs ), ] }, renderTreeSelectionCell: function (params2) { return Cell$1.renderTreeIcon(params2, Cell$1.renderCheckboxCell(params2)) }, renderCheckboxCellByProp: function (params2) { var $table = params2.$table, row = params2.row, column = params2.column, isHidden2 = params2.isHidden var props2 = $table.props, reactData = $table.reactData var treeConfig = props2.treeConfig var treeIndeterminateMaps = reactData.treeIndeterminateMaps var computeCheckboxOpts = $table.getComputeMaps().computeCheckboxOpts var checkboxOpts = computeCheckboxOpts.value var labelField = checkboxOpts.labelField, checkField = checkboxOpts.checkField, checkMethod = checkboxOpts.checkMethod, visibleMethod = checkboxOpts.visibleMethod var indeterminateField = checkboxOpts.indeterminateField || checkboxOpts.halfField var slots = column.slots var defaultSlot = slots ? slots.default : null var checkboxSlot = slots ? slots.checkbox : null var isIndeterminate = false var isChecked = false var isVisible2 = !visibleMethod || visibleMethod({ row }) var isDisabled = !!checkMethod var ons if (!isHidden2) { var rowid = getRowid($table, row) isChecked = xeUtils.get(row, checkField) ons = { onClick: function (evnt) { if (!isDisabled && isVisible2) { evnt.stopPropagation() $table.triggerCheckRowEvent(evnt, params2, !isChecked) } }, } if (checkMethod) { isDisabled = !checkMethod({ row }) } if (treeConfig) { isIndeterminate = !!treeIndeterminateMaps[rowid] } } var checkboxParams = __assign$d(__assign$d({}, params2), { checked: isChecked, disabled: isDisabled, visible: isVisible2, indeterminate: isIndeterminate, }) if (checkboxSlot) { return $table.callSlot(checkboxSlot, checkboxParams) } var checkVNs = [] if (isVisible2) { checkVNs.push( h$4('span', { class: [ 'vxe-checkbox--icon', isIndeterminate ? GlobalConfig.icon.TABLE_CHECKBOX_INDETERMINATE : isChecked ? GlobalConfig.icon.TABLE_CHECKBOX_CHECKED : GlobalConfig.icon.TABLE_CHECKBOX_UNCHECKED, ], }) ) if (defaultSlot || labelField) { checkVNs.push( h$4( 'span', { class: 'vxe-checkbox--label', }, defaultSlot ? $table.callSlot(defaultSlot, checkboxParams) : xeUtils.get(row, labelField) ) ) } } return [ h$4( 'span', __assign$d( { class: [ 'vxe-cell--checkbox', { 'is--checked': isChecked, 'is--disabled': isDisabled, 'is--indeterminate': indeterminateField && !isChecked ? row[indeterminateField] : isIndeterminate, }, ], }, ons ), checkVNs ), ] }, renderTreeSelectionCellByProp: function (params2) { return Cell$1.renderTreeIcon( params2, Cell$1.renderCheckboxCellByProp(params2) ) }, renderExpandCell: function (params2) { var $table = params2.$table, isHidden2 = params2.isHidden, row = params2.row, column = params2.column var reactData = $table.reactData var rowExpandedMaps = reactData.rowExpandedMaps, rowExpandLazyLoadedMaps = reactData.rowExpandLazyLoadedMaps var computeExpandOpts = $table.getComputeMaps().computeExpandOpts var expandOpts = computeExpandOpts.value var lazy = expandOpts.lazy, labelField = expandOpts.labelField, iconLoaded = expandOpts.iconLoaded, showIcon = expandOpts.showIcon, iconOpen = expandOpts.iconOpen, iconClose = expandOpts.iconClose, visibleMethod = expandOpts.visibleMethod var slots = column.slots var defaultSlot = slots ? slots.default : null var iconSlot = slots ? slots.icon : null var isAceived = false var isLazyLoaded = false if (iconSlot) { return $table.callSlot(iconSlot, params2) } if (!isHidden2) { var rowid = getRowid($table, row) isAceived = !!rowExpandedMaps[rowid] if (lazy) { isLazyLoaded = !!rowExpandLazyLoadedMaps[rowid] } } return [ showIcon && (!visibleMethod || visibleMethod(params2)) ? h$4( 'span', { class: [ 'vxe-table--expanded', { 'is--active': isAceived, }, ], onClick: function (evnt) { evnt.stopPropagation() $table.triggerRowExpandEvent(evnt, params2) }, }, [ h$4('i', { class: [ 'vxe-table--expand-btn', isLazyLoaded ? iconLoaded || GlobalConfig.icon.TABLE_EXPAND_LOADED : isAceived ? iconOpen || GlobalConfig.icon.TABLE_EXPAND_OPEN : iconClose || GlobalConfig.icon.TABLE_EXPAND_CLOSE, ], }), ] ) : null, defaultSlot || labelField ? h$4( 'span', { class: 'vxe-table--expand-label', }, defaultSlot ? $table.callSlot(defaultSlot, params2) : xeUtils.get(row, labelField) ) : null, ] }, renderExpandData: function (params2) { var $table = params2.$table, column = params2.column var slots = column.slots, contentRender = column.contentRender var contentSlot = slots ? slots.content : null if (contentSlot) { return $table.callSlot(contentSlot, params2) } if (contentRender) { var compConf = VXETable.renderer.get(contentRender.name) if (compConf && compConf.renderExpand) { return getSlotVNs(compConf.renderExpand(contentRender, params2)) } } return [] }, renderHTMLCell: function (params2) { var $table = params2.$table, column = params2.column var slots = column.slots var defaultSlot = slots ? slots.default : null if (defaultSlot) { return $table.callSlot(defaultSlot, params2) } return [ h$4('span', { class: 'vxe-cell--html', innerHTML: getDefaultCellLabel(params2), }), ] }, renderTreeHTMLCell: function (params2) { return Cell$1.renderTreeIcon(params2, Cell$1.renderHTMLCell(params2)) }, renderSortAndFilterHeader: function (params2) { return Cell$1.renderDefaultHeader(params2) .concat(Cell$1.renderSortIcon(params2)) .concat(Cell$1.renderFilterIcon(params2)) }, renderSortHeader: function (params2) { return Cell$1.renderDefaultHeader(params2).concat( Cell$1.renderSortIcon(params2) ) }, renderSortIcon: function (params2) { var $table = params2.$table, column = params2.column var computeSortOpts = $table.getComputeMaps().computeSortOpts var sortOpts = computeSortOpts.value var showIcon = sortOpts.showIcon, iconAsc = sortOpts.iconAsc, iconDesc = sortOpts.iconDesc var order2 = column.order return showIcon ? [ h$4( 'span', { class: 'vxe-cell--sort', }, [ h$4('i', { class: [ 'vxe-sort--asc-btn', iconAsc || GlobalConfig.icon.TABLE_SORT_ASC, { 'sort--active': order2 === 'asc', }, ], title: GlobalConfig.i18n('vxe.table.sortAsc'), onClick: function (evnt) { evnt.stopPropagation() $table.triggerSortEvent(evnt, column, 'asc') }, }), h$4('i', { class: [ 'vxe-sort--desc-btn', iconDesc || GlobalConfig.icon.TABLE_SORT_DESC, { 'sort--active': order2 === 'desc', }, ], title: GlobalConfig.i18n('vxe.table.sortDesc'), onClick: function (evnt) { evnt.stopPropagation() $table.triggerSortEvent(evnt, column, 'desc') }, }), ] ), ] : [] }, renderFilterHeader: function (params2) { return Cell$1.renderDefaultHeader(params2).concat( Cell$1.renderFilterIcon(params2) ) }, renderFilterIcon: function (params2) { var $table = params2.$table, column = params2.column, hasFilter = params2.hasFilter var reactData = $table.reactData var filterStore = reactData.filterStore var computeFilterOpts = $table.getComputeMaps().computeFilterOpts var filterOpts = computeFilterOpts.value var showIcon = filterOpts.showIcon, iconNone = filterOpts.iconNone, iconMatch = filterOpts.iconMatch return showIcon ? [ h$4( 'span', { class: [ 'vxe-cell--filter', { 'is--active': filterStore.visible && filterStore.column === column, }, ], }, [ h$4('i', { class: [ 'vxe-filter--btn', hasFilter ? iconMatch || GlobalConfig.icon.TABLE_FILTER_MATCH : iconNone || GlobalConfig.icon.TABLE_FILTER_NONE, ], title: GlobalConfig.i18n('vxe.table.filter'), onClick: function (evnt) { if ($table.triggerFilterEvent) { $table.triggerFilterEvent(evnt, params2.column, params2) } }, }), ] ), ] : [] }, renderEditHeader: function (params2) { var $table = params2.$table, column = params2.column var props2 = $table.props var computeEditOpts = $table.getComputeMaps().computeEditOpts var editConfig = props2.editConfig, editRules = props2.editRules var editOpts = computeEditOpts.value var sortable = column.sortable, filters = column.filters, editRender = column.editRender var isRequired = false if (editRules) { var columnRules = xeUtils.get(editRules, column.field) if (columnRules) { isRequired = columnRules.some(function (rule2) { return rule2.required }) } } return ( isEnableConf(editConfig) ? [ isRequired && editOpts.showAsterisk ? h$4('i', { class: 'vxe-cell--required-icon', }) : null, isEnableConf(editRender) && editOpts.showIcon ? h$4('i', { class: [ 'vxe-cell--edit-icon', editOpts.icon || GlobalConfig.icon.TABLE_EDIT, ], }) : null, ] : [] ) .concat(Cell$1.renderDefaultHeader(params2)) .concat(sortable ? Cell$1.renderSortIcon(params2) : []) .concat(filters ? Cell$1.renderFilterIcon(params2) : []) }, renderRowEdit: function (params2) { var $table = params2.$table, column = params2.column var reactData = $table.reactData var editStore = reactData.editStore var actived = editStore.actived var editRender = column.editRender return Cell$1.runRenderer( params2, isEnableConf(editRender) && actived && actived.row === params2.row ) }, renderTreeRowEdit: function (params2) { return Cell$1.renderTreeIcon(params2, Cell$1.renderRowEdit(params2)) }, renderCellEdit: function (params2) { var $table = params2.$table, column = params2.column var reactData = $table.reactData var editStore = reactData.editStore var actived = editStore.actived var editRender = column.editRender return Cell$1.runRenderer( params2, isEnableConf(editRender) && actived && actived.row === params2.row && actived.column === params2.column ) }, renderTreeCellEdit: function (params2) { return Cell$1.renderTreeIcon(params2, Cell$1.renderCellEdit(params2)) }, runRenderer: function (params2, isEdit) { var $table = params2.$table, column = params2.column var slots = column.slots, editRender = column.editRender, formatter2 = column.formatter var defaultSlot = slots ? slots.default : null var editSlot = slots ? slots.edit : null var compConf = VXETable.renderer.get(editRender.name) if (isEdit) { if (editSlot) { return $table.callSlot(editSlot, params2) } if (compConf && compConf.renderEdit) { return getSlotVNs( compConf.renderEdit( editRender, Object.assign({ $type: 'edit' }, params2) ) ) } return [] } if (defaultSlot) { return $table.callSlot(defaultSlot, params2) } if (formatter2) { return [ h$4( 'span', { class: 'vxe-cell--label', }, getDefaultCellLabel(params2) ), ] } return Cell$1.renderDefaultCell(params2) }, } var columnProps = { colId: [String, Number], type: String, field: String, title: String, width: [Number, String], minWidth: [Number, String], maxWidth: [Number, String], resizable: { type: Boolean, default: null }, fixed: String, align: String, headerAlign: String, footerAlign: String, showOverflow: { type: [Boolean, String], default: null }, showHeaderOverflow: { type: [Boolean, String], default: null }, showFooterOverflow: { type: [Boolean, String], default: null }, className: [String, Function], headerClassName: [String, Function], footerClassName: [String, Function], formatter: [Function, Array, String], sortable: Boolean, sortBy: [String, Function], sortType: String, filters: { type: Array, default: null }, filterMultiple: { type: Boolean, default: true }, filterMethod: Function, filterResetMethod: Function, filterRecoverMethod: Function, filterRender: Object, treeNode: Boolean, visible: { type: Boolean, default: null }, headerExportMethod: Function, exportMethod: Function, footerExportMethod: Function, titleHelp: Object, titlePrefix: Object, cellType: String, cellRender: Object, editRender: Object, contentRender: Object, params: Object, } var VxeTableColumnComponent = defineComponent({ name: 'VxeColumn', props: columnProps, setup: function (props2, _a2) { var slots = _a2.slots var refElem = ref() var $xetable = inject('$xetable', {}) var colgroup = inject('xecolgroup', null) var column = Cell$1.createColumn($xetable, props2) column.slots = slots provide('$xegrid', null) watchColumn($xetable, props2, column) onMounted(function () { assemColumn($xetable, refElem.value, column, colgroup) }) onUnmounted(function () { destroyColumn($xetable, column) }) var renderVN = function () { return h$4('div', { ref: refElem, }) } return renderVN }, }) var VxeColumn = Object.assign(VxeTableColumnComponent, { install: function (app2) { app2.component(VxeTableColumnComponent.name, VxeTableColumnComponent) app2.component('VxeTableColumn', VxeTableColumnComponent) }, }) var Column = VxeColumn dynamicApp.component(VxeTableColumnComponent.name, VxeTableColumnComponent) dynamicApp.component('VxeTableColumn', VxeTableColumnComponent) var VxeTableColgroupComponent = defineComponent({ name: 'VxeColgroup', props: columnProps, setup: function (props2, _a2) { var slots = _a2.slots var refElem = ref() var $xetable = inject('$xetable', {}) var colgroup = inject('xecolgroup', null) var column = Cell$1.createColumn($xetable, props2) var columnSlots = {} if (slots.header) { columnSlots.header = slots.header } var xecolumn = { column } column.slots = columnSlots column.children = [] provide('xecolgroup', xecolumn) provide('$xegrid', null) watchColumn($xetable, props2, column) onMounted(function () { assemColumn($xetable, refElem.value, column, colgroup) }) onUnmounted(function () { destroyColumn($xetable, column) }) var renderVN = function () { return h$4( 'div', { ref: refElem, }, slots.default ? slots.default() : [] ) } return renderVN }, }) Object.assign(VxeTableColgroupComponent, { install: function (app2) { app2.component(VxeTableColgroupComponent.name, VxeTableColgroupComponent) app2.component('VxeTableColgroup', VxeTableColgroupComponent) }, }) dynamicApp.component(VxeTableColgroupComponent.name, VxeTableColgroupComponent) dynamicApp.component('VxeTableColgroup', VxeTableColgroupComponent) var tableProps = { id: String, data: Array, height: [Number, String], minHeight: { type: [Number, String], default: function () { return GlobalConfig.table.minHeight }, }, maxHeight: [Number, String], resizable: { type: Boolean, default: function () { return GlobalConfig.table.resizable }, }, stripe: { type: Boolean, default: function () { return GlobalConfig.table.stripe }, }, border: { type: [Boolean, String], default: function () { return GlobalConfig.table.border }, }, round: { type: Boolean, default: function () { return GlobalConfig.table.round }, }, size: { type: String, default: function () { return GlobalConfig.table.size || GlobalConfig.size }, }, fit: { type: Boolean, default: function () { return GlobalConfig.table.fit }, }, loading: Boolean, align: { type: String, default: function () { return GlobalConfig.table.align }, }, headerAlign: { type: String, default: function () { return GlobalConfig.table.headerAlign }, }, footerAlign: { type: String, default: function () { return GlobalConfig.table.footerAlign }, }, showHeader: { type: Boolean, default: function () { return GlobalConfig.table.showHeader }, }, highlightCurrentRow: { type: Boolean, default: function () { return GlobalConfig.table.highlightCurrentRow }, }, highlightHoverRow: { type: Boolean, default: function () { return GlobalConfig.table.highlightHoverRow }, }, highlightCurrentColumn: { type: Boolean, default: function () { return GlobalConfig.table.highlightCurrentColumn }, }, highlightHoverColumn: { type: Boolean, default: function () { return GlobalConfig.table.highlightHoverColumn }, }, highlightCell: Boolean, showFooter: Boolean, footerMethod: Function, rowClassName: [String, Function], cellClassName: [String, Function], headerRowClassName: [String, Function], headerCellClassName: [String, Function], footerRowClassName: [String, Function], footerCellClassName: [String, Function], cellStyle: [Object, Function], headerCellStyle: [Object, Function], footerCellStyle: [Object, Function], rowStyle: [Object, Function], headerRowStyle: [Object, Function], footerRowStyle: [Object, Function], mergeCells: Array, mergeFooterItems: Array, spanMethod: Function, footerSpanMethod: Function, showOverflow: { type: [Boolean, String], default: function () { return GlobalConfig.table.showOverflow }, }, showHeaderOverflow: { type: [Boolean, String], default: function () { return GlobalConfig.table.showHeaderOverflow }, }, showFooterOverflow: { type: [Boolean, String], default: function () { return GlobalConfig.table.showFooterOverflow }, }, columnKey: Boolean, rowKey: Boolean, rowId: { type: String, default: function () { return GlobalConfig.table.rowId }, }, zIndex: Number, emptyText: { type: String, default: function () { return GlobalConfig.table.emptyText }, }, keepSource: { type: Boolean, default: function () { return GlobalConfig.table.keepSource }, }, autoResize: { type: Boolean, default: function () { return GlobalConfig.table.autoResize }, }, syncResize: [Boolean, String, Number], resizeConfig: Object, columnConfig: Object, rowConfig: Object, resizableConfig: Object, seqConfig: Object, sortConfig: Object, filterConfig: Object, radioConfig: Object, checkboxConfig: Object, tooltipConfig: Object, exportConfig: Object, importConfig: Object, printConfig: Object, expandConfig: Object, treeConfig: Object, menuConfig: Object, mouseConfig: Object, areaConfig: Object, keyboardConfig: Object, clipConfig: Object, fnrConfig: Object, editConfig: Object, validConfig: Object, editRules: Object, loadingConfig: Object, emptyRender: Object, customConfig: Object, scrollX: Object, scrollY: Object, animat: { type: Boolean, default: function () { return GlobalConfig.table.animat }, }, delayHover: { type: Number, default: function () { return GlobalConfig.table.delayHover }, }, params: Object, } var tableEmits = [ 'update:data', 'keydown-start', 'keydown', 'keydown-end', 'paste', 'copy', 'cut', 'current-change', 'radio-change', 'checkbox-change', 'checkbox-all', 'checkbox-range-start', 'checkbox-range-change', 'checkbox-range-end', 'checkbox-range-select', 'cell-click', 'cell-dblclick', 'cell-menu', 'cell-mouseenter', 'cell-mouseleave', 'cell-selected', 'header-cell-click', 'header-cell-dblclick', 'header-cell-menu', 'footer-cell-click', 'footer-cell-dblclick', 'footer-cell-menu', 'clear-merge', 'sort-change', 'clear-sort', 'filter-change', 'filter-visible', 'clear-filter', 'resizable-change', 'toggle-row-expand', 'toggle-tree-expand', 'menu-click', 'edit-closed', 'edit-actived', 'edit-disabled', 'valid-error', 'scroll', 'custom', 'change-fnr', 'open-fnr', 'fnr-change', 'fnr-find', 'fnr-find-all', 'fnr-replace', 'fnr-replace-all', 'cell-area-copy', 'cell-area-cut', 'cell-area-paste', 'cell-area-merge', 'clear-cell-area-merge', 'header-cell-area-selection', 'cell-area-selection-start', 'cell-area-selection-drag', 'cell-area-selection-end', 'cell-area-extension-start', 'cell-area-extension-drag', 'cell-area-extension-end', 'cell-area-selection-all-start', 'cell-area-selection-all-end', 'cell-area-arrows-start', 'cell-area-arrows-end', 'active-cell-change-start', 'active-cell-change-end', ] var __assign$c = (globalThis && globalThis.__assign) || function () { __assign$c = Object.assign || function (t3) { for (var s2, i2 = 1, n2 = arguments.length; i2 < n2; i2++) { s2 = arguments[i2] for (var p2 in s2) if (Object.prototype.hasOwnProperty.call(s2, p2)) t3[p2] = s2[p2] } return t3 } return __assign$c.apply(this, arguments) } var __spreadArray$3 = (globalThis && globalThis.__spreadArray) || function (to, from, pack2) { if (pack2 || arguments.length === 2) for (var i2 = 0, l2 = from.length, ar2; i2 < l2; i2++) { if (ar2 || !(i2 in from)) { if (!ar2) ar2 = Array.prototype.slice.call(from, 0, i2) ar2[i2] = from[i2] } } return to.concat(ar2 || Array.prototype.slice.call(from)) } var tableComponentPropKeys = Object.keys(tableProps) var tableComponentMethodKeys = [ 'clearAll', 'syncData', 'updateData', 'loadData', 'reloadData', 'reloadRow', 'loadColumn', 'reloadColumn', 'getRowNode', 'getColumnNode', 'getRowIndex', 'getVTRowIndex', 'getVMRowIndex', 'getColumnIndex', 'getVTColumnIndex', 'getVMColumnIndex', 'createData', 'createRow', 'revertData', 'clearData', 'isInsertByRow', 'isUpdateByRow', 'getColumns', 'getColumnById', 'getColumnByField', 'getTableColumn', 'getData', 'getCheckboxRecords', 'getParentRow', 'getRowSeq', 'getRowById', 'getRowid', 'getTableData', 'setColumnFixed', 'clearColumnFixed', 'setColumnWidth', 'getColumnWidth', 'hideColumn', 'showColumn', 'resetColumn', 'refreshColumn', 'refreshScroll', 'recalculate', 'closeTooltip', 'isAllCheckboxChecked', 'isAllCheckboxIndeterminate', 'getCheckboxIndeterminateRecords', 'setCheckboxRow', 'isCheckedByCheckboxRow', 'isIndeterminateByCheckboxRow', 'toggleCheckboxRow', 'setAllCheckboxRow', 'getRadioReserveRecord', 'clearRadioReserve', 'getCheckboxReserveRecords', 'clearCheckboxReserve', 'toggleAllCheckboxRow', 'clearCheckboxRow', 'setCurrentRow', 'isCheckedByRadioRow', 'setRadioRow', 'clearCurrentRow', 'clearRadioRow', 'getCurrentRecord', 'getRadioRecord', 'getCurrentColumn', 'setCurrentColumn', 'clearCurrentColumn', 'sort', 'clearSort', 'isSort', 'getSortColumns', 'closeFilter', 'isFilter', 'isActiveFilterByColumn', 'isRowExpandLoaded', 'clearRowExpandLoaded', 'reloadRowExpand', 'reloadRowExpand', 'toggleRowExpand', 'setAllRowExpand', 'setRowExpand', 'isExpandByRow', 'clearRowExpand', 'clearRowExpandReserve', 'getRowExpandRecords', 'getTreeExpandRecords', 'isTreeExpandLoaded', 'clearTreeExpandLoaded', 'reloadTreeExpand', 'reloadTreeChilds', 'toggleTreeExpand', 'setAllTreeExpand', 'setTreeExpand', 'isTreeExpandByRow', 'clearTreeExpand', 'clearTreeExpandReserve', 'getScroll', 'scrollTo', 'scrollToRow', 'scrollToColumn', 'clearScroll', 'updateFooter', 'updateStatus', 'setMergeCells', 'removeInsertRow', 'removeMergeCells', 'getMergeCells', 'clearMergeCells', 'setMergeFooterItems', 'removeMergeFooterItems', 'getMergeFooterItems', 'clearMergeFooterItems', 'openTooltip', 'focus', 'blur', 'connect', ] var gridComponentEmits = __spreadArray$3( __spreadArray$3([], tableEmits, true), [ 'page-change', 'form-submit', 'form-submit-invalid', 'form-reset', 'form-collapse', 'form-toggle-collapse', 'proxy-query', 'proxy-delete', 'proxy-save', 'toolbar-button-click', 'toolbar-tool-click', 'zoom', ], false ) var VxeGridComponent = defineComponent({ name: 'VxeGrid', props: __assign$c(__assign$c({}, tableProps), { columns: Array, pagerConfig: Object, proxyConfig: Object, toolbarConfig: Object, formConfig: Object, zoomConfig: Object, size: { type: String, default: function () { return GlobalConfig.grid.size || GlobalConfig.size }, }, }), emits: gridComponentEmits, setup: function (props2, context2) { var slots = context2.slots, emit2 = context2.emit var xID = xeUtils.uniqueId() var instance = getCurrentInstance() var computeSize = useSize(props2) var reactData = reactive({ tableLoading: false, proxyInited: false, isZMax: false, tableData: [], pendingRecords: [], filterData: [], formData: {}, sortData: [], tZindex: 0, tablePage: { total: 0, pageSize: GlobalConfig.pager.pageSize || 10, currentPage: 1, }, }) var refElem = ref() var refTable = ref() var refForm = ref() var refToolbar = ref() var refPager = ref() var refFormWrapper = ref() var refToolbarWrapper = ref() var refTopWrapper = ref() var refBottomWrapper = ref() var refPagerWrapper = ref() var extendTableMethods = function (methodKeys) { var funcs = {} methodKeys.forEach(function (name2) { funcs[name2] = function () { var args = [] for (var _i = 0; _i < arguments.length; _i++) { args[_i] = arguments[_i] } var $xetable = refTable.value if ($xetable && $xetable[name2]) { return $xetable[name2].apply($xetable, args) } } }) return funcs } var gridExtendTableMethods = extendTableMethods(tableComponentMethodKeys) tableComponentMethodKeys.forEach(function (name2) { gridExtendTableMethods[name2] = function () { var args = [] for (var _i = 0; _i < arguments.length; _i++) { args[_i] = arguments[_i] } var $xetable = refTable.value if ($xetable && $xetable[name2]) { return $xetable && $xetable[name2].apply($xetable, args) } } }) var computeProxyOpts = computed(function () { return Object.assign( {}, GlobalConfig.grid.proxyConfig, props2.proxyConfig ) }) var computeIsMsg = computed(function () { var proxyOpts = computeProxyOpts.value return proxyOpts.message !== false }) var computePagerOpts = computed(function () { return Object.assign( {}, GlobalConfig.grid.pagerConfig, props2.pagerConfig ) }) var computeFormOpts = computed(function () { return Object.assign({}, GlobalConfig.grid.formConfig, props2.formConfig) }) var computeToolbarOpts = computed(function () { return Object.assign( {}, GlobalConfig.grid.toolbarConfig, props2.toolbarConfig ) }) var computeZoomOpts = computed(function () { return Object.assign({}, GlobalConfig.grid.zoomConfig, props2.zoomConfig) }) var computeStyles2 = computed(function () { return reactData.isZMax ? { zIndex: reactData.tZindex } : null }) var computeTableExtendProps = computed(function () { var rest = {} var gridProps = props2 tableComponentPropKeys.forEach(function (key2) { rest[key2] = gridProps[key2] }) return rest }) var refMaps = { refElem, refTable, refForm, refToolbar, refPager, } var computeMaps = { computeProxyOpts, computePagerOpts, computeFormOpts, computeToolbarOpts, computeZoomOpts, } var $xegrid = { xID, props: props2, context: context2, instance, reactData, getRefMaps: function () { return refMaps }, getComputeMaps: function () { return computeMaps }, } var gridMethods = {} var handleRowClassName = function (params2) { var pendingRecords = reactData.pendingRecords var rowClassName = props2.rowClassName var clss = [] if ( pendingRecords.some(function (item2) { return item2 === params2.row }) ) { clss.push('row--pending') } clss.push( rowClassName ? xeUtils.isFunction(rowClassName) ? rowClassName(params2) : rowClassName : '' ) return clss } var handleBeforeEditMethod = function (params2) { var editConfig = props2.editConfig var pendingRecords = reactData.pendingRecords var $xetable = refTable.value var beforeEditMethod = editConfig ? editConfig.beforeEditMethod || editConfig.activeMethod : null if ($xetable.findRowIndexOf(pendingRecords, params2.row) === -1) { return ( !beforeEditMethod || beforeEditMethod( __assign$c(__assign$c({}, params2), { $grid: $xegrid }) ) ) } return false } var computeTableProps = computed(function () { var seqConfig = props2.seqConfig, pagerConfig = props2.pagerConfig, loading2 = props2.loading, editConfig = props2.editConfig, proxyConfig = props2.proxyConfig var isZMax = reactData.isZMax, tableLoading = reactData.tableLoading, tablePage = reactData.tablePage, tableData2 = reactData.tableData var tableExtendProps = computeTableExtendProps.value var proxyOpts = computeProxyOpts.value var pagerOpts = computePagerOpts.value var tableProps2 = Object.assign({}, tableExtendProps) if (isZMax) { if (tableExtendProps.maxHeight) { tableProps2.maxHeight = 'auto' } else { tableProps2.height = 'auto' } } if (proxyConfig && isEnableConf(proxyOpts)) { tableProps2.loading = loading2 || tableLoading tableProps2.data = tableData2 tableProps2.rowClassName = handleRowClassName if (pagerConfig && proxyOpts.seq && isEnableConf(pagerOpts)) { tableProps2.seqConfig = Object.assign({}, seqConfig, { startIndex: (tablePage.currentPage - 1) * tablePage.pageSize, }) } } if (editConfig) { tableProps2.editConfig = Object.assign({}, editConfig, { beforeEditMethod: handleBeforeEditMethod, }) } return tableProps2 }) var initToolbar = function () { var toolbarOpts = computeToolbarOpts.value if (props2.toolbarConfig && isEnableConf(toolbarOpts)) { nextTick(function () { var $xetable = refTable.value var $xetoolbar = refToolbar.value if ($xetable && $xetoolbar) { $xetable.connect($xetoolbar) } }) } } var initPages = function () { var tablePage = reactData.tablePage var pagerConfig = props2.pagerConfig var pagerOpts = computePagerOpts.value var currentPage2 = pagerOpts.currentPage, pageSize = pagerOpts.pageSize if (pagerConfig && isEnableConf(pagerOpts)) { if (currentPage2) { tablePage.currentPage = currentPage2 } if (pageSize) { tablePage.pageSize = pageSize } } } var triggerPendingEvent = function (code2) { var pendingRecords = reactData.pendingRecords var isMsg = computeIsMsg.value var $xetable = refTable.value var selectRecords = $xetable.getCheckboxRecords() if (selectRecords.length) { var plus_1 = [] var minus_1 = [] selectRecords.forEach(function (data2) { if ( pendingRecords.some(function (item2) { return data2 === item2 }) ) { minus_1.push(data2) } else { plus_1.push(data2) } }) if (minus_1.length) { reactData.pendingRecords = pendingRecords .filter(function (item2) { return $xetable.findRowIndexOf(minus_1, item2) === -1 }) .concat(plus_1) } else if (plus_1.length) { reactData.pendingRecords = pendingRecords.concat(plus_1) } gridExtendTableMethods.clearCheckboxRow() } else { if (isMsg) { VXETable.modal.message({ id: code2, content: GlobalConfig.i18n('vxe.grid.selectOneRecord'), status: 'warning', }) } } } var getRespMsg = function (rest, defaultMsg) { var proxyOpts = computeProxyOpts.value var _a2 = proxyOpts.props, proxyProps = _a2 === void 0 ? {} : _a2 var msg if (rest && proxyProps.message) { msg = xeUtils.get(rest, proxyProps.message) } return msg || GlobalConfig.i18n(defaultMsg) } var handleDeleteRow = function (code2, alertKey, callback) { var isMsg = computeIsMsg.value var selectRecords = gridExtendTableMethods.getCheckboxRecords() if (isMsg) { if (selectRecords.length) { return VXETable.modal .confirm({ id: 'cfm_'.concat(code2), content: GlobalConfig.i18n(alertKey), escClosable: true, }) .then(function (type4) { if (type4 === 'confirm') { return callback() } }) } else { VXETable.modal.message({ id: 'msg_'.concat(code2), content: GlobalConfig.i18n('vxe.grid.selectOneRecord'), status: 'warning', }) } } else { if (selectRecords.length) { callback() } } return Promise.resolve() } var pageChangeEvent = function (params2) { var proxyConfig = props2.proxyConfig var tablePage = reactData.tablePage var currentPage2 = params2.currentPage, pageSize = params2.pageSize var proxyOpts = computeProxyOpts.value tablePage.currentPage = currentPage2 tablePage.pageSize = pageSize gridMethods.dispatchEvent('page-change', params2) if (proxyConfig && isEnableConf(proxyOpts)) { gridMethods.commitProxy('query').then(function (rest) { gridMethods.dispatchEvent('proxy-query', rest, params2.$event) }) } } var sortChangeEvent = function (params2) { var $xetable = refTable.value var proxyConfig = props2.proxyConfig var computeSortOpts = $xetable.getComputeMaps().computeSortOpts var proxyOpts = computeProxyOpts.value var sortOpts = computeSortOpts.value if (sortOpts.remote) { reactData.sortData = params2.sortList if (proxyConfig && isEnableConf(proxyOpts)) { reactData.tablePage.currentPage = 1 gridMethods.commitProxy('query').then(function (rest) { gridMethods.dispatchEvent('proxy-query', rest, params2.$event) }) } } gridMethods.dispatchEvent('sort-change', params2) } var filterChangeEvent = function (params2) { var $xetable = refTable.value var proxyConfig = props2.proxyConfig var computeFilterOpts = $xetable.getComputeMaps().computeFilterOpts var proxyOpts = computeProxyOpts.value var filterOpts = computeFilterOpts.value if (filterOpts.remote) { reactData.filterData = params2.filterList if (proxyConfig && isEnableConf(proxyOpts)) { reactData.tablePage.currentPage = 1 gridMethods.commitProxy('query').then(function (rest) { gridMethods.dispatchEvent('proxy-query', rest, params2.$event) }) } } gridMethods.dispatchEvent('filter-change', params2) } var submitFormEvent = function (params2) { var proxyConfig = props2.proxyConfig var proxyOpts = computeProxyOpts.value if (proxyConfig && isEnableConf(proxyOpts)) { gridMethods.commitProxy('reload').then(function (rest) { gridMethods.dispatchEvent( 'proxy-query', __assign$c(__assign$c({}, rest), { isReload: true }), params2.$event ) }) } gridMethods.dispatchEvent('form-submit', params2) } var resetFormEvent = function (params2) { var proxyConfig = props2.proxyConfig var proxyOpts = computeProxyOpts.value if (proxyConfig && isEnableConf(proxyOpts)) { gridMethods.commitProxy('reload').then(function (rest) { gridMethods.dispatchEvent( 'proxy-query', __assign$c(__assign$c({}, rest), { isReload: true }), params2.$event ) }) } gridMethods.dispatchEvent('form-reset', params2) } var submitInvalidEvent = function (params2) { gridMethods.dispatchEvent('form-submit-invalid', params2) } var collapseEvent = function (params2) { nextTick(function () { return gridExtendTableMethods.recalculate(true) }) gridMethods.dispatchEvent('form-toggle-collapse', params2) gridMethods.dispatchEvent('form-collapse', params2) } var handleZoom = function (isMax) { var isZMax = reactData.isZMax if (isMax ? !isZMax : isZMax) { reactData.isZMax = !isZMax if (reactData.tZindex < getLastZIndex()) { reactData.tZindex = nextZIndex() } } return nextTick() .then(function () { return gridExtendTableMethods.recalculate(true) }) .then(function () { return reactData.isZMax }) } var getFuncSlot = function (optSlots, slotKey) { var funcSlot = optSlots[slotKey] if (funcSlot) { if (xeUtils.isString(funcSlot)) { if (slots[funcSlot]) { return slots[funcSlot] } } else { return funcSlot } } return null } var renderForms = function () { var formConfig = props2.formConfig, proxyConfig = props2.proxyConfig var formData = reactData.formData var proxyOpts = computeProxyOpts.value var formOpts = computeFormOpts.value var restVNs = [] if ((formConfig && isEnableConf(formOpts)) || slots.form) { var slotVNs = [] if (slots.form) { slotVNs = slots.form({ $grid: $xegrid }) } else { if (formOpts.items) { var formSlots_1 = {} if (!formOpts.inited) { formOpts.inited = true var beforeItem_1 = proxyOpts.beforeItem if (proxyOpts && beforeItem_1) { formOpts.items.forEach(function (item2) { beforeItem_1({ $grid: $xegrid, item: item2 }) }) } } formOpts.items.forEach(function (item2) { xeUtils.each(item2.slots, function (func) { if (!xeUtils.isFunction(func)) { if (slots[func]) { formSlots_1[func] = slots[func] } } }) }) slotVNs.push( h$4( resolveComponent('vxe-form'), __assign$c( __assign$c( { ref: refForm }, Object.assign({}, formOpts, { data: proxyConfig && isEnableConf(proxyOpts) && proxyOpts.form ? formData : formOpts.data, }) ), { onSubmit: submitFormEvent, onReset: resetFormEvent, onSubmitInvalid: submitInvalidEvent, onCollapse: collapseEvent, } ), formSlots_1 ) ) } } restVNs.push( h$4( 'div', { ref: refFormWrapper, class: 'vxe-grid--form-wrapper', }, slotVNs ) ) } return restVNs } var renderToolbars = function () { var toolbarConfig = props2.toolbarConfig var toolbarOpts = computeToolbarOpts.value var restVNs = [] if ((toolbarConfig && isEnableConf(toolbarOpts)) || slots.toolbar) { var slotVNs = [] if (slots.toolbar) { slotVNs = slots.toolbar({ $grid: $xegrid }) } else { var toolbarOptSlots = toolbarOpts.slots var buttonsSlot = void 0 var toolsSlot = void 0 var toolbarSlots = {} if (toolbarOptSlots) { buttonsSlot = getFuncSlot(toolbarOptSlots, 'buttons') toolsSlot = getFuncSlot(toolbarOptSlots, 'tools') if (buttonsSlot) { toolbarSlots.buttons = buttonsSlot } if (toolsSlot) { toolbarSlots.tools = toolsSlot } } slotVNs.push( h$4( resolveComponent('vxe-toolbar'), __assign$c({ ref: refToolbar }, toolbarOpts), toolbarSlots ) ) } restVNs.push( h$4( 'div', { ref: refToolbarWrapper, class: 'vxe-grid--toolbar-wrapper', }, slotVNs ) ) } return restVNs } var renderTops = function () { if (slots.top) { return [ h$4( 'div', { ref: refTopWrapper, class: 'vxe-grid--top-wrapper', }, slots.top({ $grid: $xegrid }) ), ] } return [] } var tableCompEvents = {} tableEmits.forEach(function (name2) { var type4 = xeUtils.camelCase('on-'.concat(name2)) tableCompEvents[type4] = function () { var args = [] for (var _i = 0; _i < arguments.length; _i++) { args[_i] = arguments[_i] } return emit2.apply(void 0, __spreadArray$3([name2], args, false)) } }) var renderTables = function () { var proxyConfig = props2.proxyConfig var tableProps2 = computeTableProps.value var proxyOpts = computeProxyOpts.value var tableOns = Object.assign({}, tableCompEvents) var emptySlot = slots.empty var loadingSlot = slots.loading if (proxyConfig && isEnableConf(proxyOpts)) { if (proxyOpts.sort) { tableOns.onSortChange = sortChangeEvent } if (proxyOpts.filter) { tableOns.onFilterChange = filterChangeEvent } } var slotObj = {} if (emptySlot) { slotObj.empty = function () { return emptySlot({}) } } if (loadingSlot) { slotObj.loading = function () { return loadingSlot({}) } } return [ h$4( resolveComponent('vxe-table'), __assign$c(__assign$c({ ref: refTable }, tableProps2), tableOns), slotObj ), ] } var renderBottoms = function () { if (slots.bottom) { return [ h$4( 'div', { ref: refBottomWrapper, class: 'vxe-grid--bottom-wrapper', }, slots.bottom({ $grid: $xegrid }) ), ] } return [] } var renderPagers = function () { var proxyConfig = props2.proxyConfig, pagerConfig = props2.pagerConfig var proxyOpts = computeProxyOpts.value var pagerOpts = computePagerOpts.value var restVNs = [] if ((pagerConfig && isEnableConf(pagerOpts)) || slots.pager) { var slotVNs = [] if (slots.pager) { slotVNs = slots.pager({ $grid: $xegrid }) } else { var pagerOptSlots = pagerOpts.slots var pagerSlots = {} var leftSlot = void 0 var rightSlot = void 0 if (pagerOptSlots) { leftSlot = getFuncSlot(pagerOptSlots, 'left') rightSlot = getFuncSlot(pagerOptSlots, 'right') if (leftSlot) { pagerSlots.left = leftSlot } if (rightSlot) { pagerSlots.right = rightSlot } } slotVNs.push( h$4( resolveComponent('vxe-pager'), __assign$c( __assign$c( __assign$c({ ref: refPager }, pagerOpts), proxyConfig && isEnableConf(proxyOpts) ? reactData.tablePage : {} ), { onPageChange: pageChangeEvent } ), pagerSlots ) ) } restVNs.push( h$4( 'div', { ref: refPagerWrapper, class: 'vxe-grid--pager-wrapper', }, slotVNs ) ) } return restVNs } var initProxy = function () { var proxyConfig = props2.proxyConfig, formConfig = props2.formConfig var proxyInited = reactData.proxyInited var proxyOpts = computeProxyOpts.value var formOpts = computeFormOpts.value if (proxyConfig && isEnableConf(proxyOpts)) { if ( formConfig && isEnableConf(formOpts) && proxyOpts.form && formOpts.items ) { var formData_1 = {} formOpts.items.forEach(function (item2) { var field2 = item2.field, itemRender = item2.itemRender if (field2) { var itemValue = null if (itemRender) { var defaultValue = itemRender.defaultValue if (xeUtils.isFunction(defaultValue)) { itemValue = defaultValue({ item: item2 }) } else if (!xeUtils.isUndefined(defaultValue)) { itemValue = defaultValue } } formData_1[field2] = itemValue } }) reactData.formData = formData_1 } if (!proxyInited) { reactData.proxyInited = true if (proxyOpts.autoLoad !== false) { nextTick() .then(function () { return gridMethods.commitProxy('_init') }) .then(function (rest) { gridMethods.dispatchEvent( 'proxy-query', __assign$c(__assign$c({}, rest), { isInited: true }), new Event('init') ) }) } } } } gridMethods = { dispatchEvent: function (type4, params2, evnt) { emit2(type4, Object.assign({ $grid: $xegrid, $event: evnt }, params2)) }, commitProxy: function (proxyTarget) { var args = [] for (var _i = 1; _i < arguments.length; _i++) { args[_i - 1] = arguments[_i] } var toolbarConfig = props2.toolbarConfig, pagerConfig = props2.pagerConfig, editRules = props2.editRules var tablePage = reactData.tablePage, formData = reactData.formData var isMsg = computeIsMsg.value var proxyOpts = computeProxyOpts.value var pagerOpts = computePagerOpts.value var toolbarOpts = computeToolbarOpts.value var beforeQuery = proxyOpts.beforeQuery, afterQuery = proxyOpts.afterQuery, beforeDelete = proxyOpts.beforeDelete, afterDelete = proxyOpts.afterDelete, beforeSave = proxyOpts.beforeSave, afterSave = proxyOpts.afterSave, _a2 = proxyOpts.ajax, ajax = _a2 === void 0 ? {} : _a2, _b2 = proxyOpts.props, proxyProps = _b2 === void 0 ? {} : _b2 var $xetable = refTable.value var button = null var code2 = null if (xeUtils.isString(proxyTarget)) { var buttons = toolbarOpts.buttons var matchObj = toolbarConfig && isEnableConf(toolbarOpts) && buttons ? xeUtils.findTree( buttons, function (item2) { return item2.code === proxyTarget }, { children: 'dropdowns' } ) : null button = matchObj ? matchObj.item : null code2 = proxyTarget } else { button = proxyTarget code2 = button.code } var btnParams = button ? button.params : null switch (code2) { case 'insert': return $xetable.insert({}) case 'insert_actived': return $xetable.insert({}).then(function (_a3) { var row = _a3.row return $xetable.setEditRow(row) }) case 'mark_cancel': triggerPendingEvent(code2) break case 'remove': return handleDeleteRow( code2, 'vxe.grid.removeSelectRecord', function () { return $xetable.removeCheckboxRow() } ) case 'import': $xetable.importData(btnParams) break case 'open_import': $xetable.openImport(btnParams) break case 'export': $xetable.exportData(btnParams) break case 'open_export': $xetable.openExport(btnParams) break case 'reset_custom': return $xetable.resetColumn(true) case '_init': case 'reload': case 'query': { var ajaxMethods = ajax.query if (ajaxMethods) { var isInited = code2 === '_init' var isReload = code2 === 'reload' var sortList2 = [] var filterList2 = [] var pageParams = {} if (pagerConfig) { if (isInited || isReload) { tablePage.currentPage = 1 } if (isEnableConf(pagerOpts)) { pageParams = __assign$c({}, tablePage) } } if (isInited) { var computeSortOpts = $xetable.getComputeMaps().computeSortOpts var sortOpts = computeSortOpts.value var defaultSort = sortOpts.defaultSort if (defaultSort) { if (!xeUtils.isArray(defaultSort)) { defaultSort = [defaultSort] } sortList2 = defaultSort.map(function (item2) { return { field: item2.field, property: item2.field, order: item2.order, } }) } filterList2 = $xetable.getCheckedFilters() } else { if (isReload) { reactData.pendingRecords = [] $xetable.clearAll() } else { sortList2 = $xetable.getSortColumns() filterList2 = $xetable.getCheckedFilters() } } var commitParams = { code: code2, button, isInited, isReload, $grid: $xegrid, page: pageParams, sort: sortList2.length ? sortList2[0] : {}, sorts: sortList2, filters: filterList2, form: formData, options: ajaxMethods, } reactData.sortData = sortList2 reactData.filterData = filterList2 reactData.tableLoading = true var applyArgs_1 = [commitParams].concat(args) return Promise.resolve( (beforeQuery || ajaxMethods).apply(void 0, applyArgs_1) ) .then(function (rest) { reactData.tableLoading = false if (rest) { if (pagerConfig && isEnableConf(pagerOpts)) { var total2 = xeUtils.get(rest, proxyProps.total || 'page.total') || 0 tablePage.total = xeUtils.toNumber(total2) reactData.tableData = xeUtils.get(rest, proxyProps.result || 'result') || [] var pageCount = Math.max( Math.ceil(total2 / tablePage.pageSize), 1 ) if (tablePage.currentPage > pageCount) { tablePage.currentPage = pageCount } } else { reactData.tableData = (proxyProps.list ? xeUtils.get(rest, proxyProps.list) : rest) || [] } } else { reactData.tableData = [] } if (afterQuery) { afterQuery.apply(void 0, applyArgs_1) } return { status: true } }) .catch(function () { reactData.tableLoading = false return { status: false } }) } break } case 'delete': { var ajaxMethods_1 = ajax.delete if (ajaxMethods_1) { var selectRecords_1 = gridExtendTableMethods.getCheckboxRecords() var removeRecords_1 = selectRecords_1.filter(function (row) { return !$xetable.isInsertByRow(row) }) var body = { removeRecords: removeRecords_1 } var commitParams = { $grid: $xegrid, code: code2, button, body, form: formData, options: ajaxMethods_1, } var applyArgs_2 = [commitParams].concat(args) if (selectRecords_1.length) { return handleDeleteRow( code2, 'vxe.grid.deleteSelectRecord', function () { if (!removeRecords_1.length) { return $xetable.remove(selectRecords_1) } reactData.tableLoading = true return Promise.resolve( (beforeDelete || ajaxMethods_1).apply(void 0, applyArgs_2) ) .then(function (rest) { reactData.tableLoading = false reactData.pendingRecords = reactData.pendingRecords.filter(function (row) { return ( $xetable.findRowIndexOf(removeRecords_1, row) === -1 ) }) if (isMsg) { VXETable.modal.message({ content: getRespMsg(rest, 'vxe.grid.delSuccess'), status: 'success', }) } if (afterDelete) { afterDelete.apply(void 0, applyArgs_2) } else { gridMethods.commitProxy('query') } return { status: true } }) .catch(function (rest) { reactData.tableLoading = false if (isMsg) { VXETable.modal.message({ id: code2, content: getRespMsg(rest, 'vxe.grid.operError'), status: 'error', }) } return { status: false } }) } ) } else { if (isMsg) { VXETable.modal.message({ id: code2, content: GlobalConfig.i18n('vxe.grid.selectOneRecord'), status: 'warning', }) } } } break } case 'save': { var ajaxMethods_2 = ajax.save if (ajaxMethods_2) { var body_1 = Object.assign( { pendingRecords: reactData.pendingRecords }, $xetable.getRecordset() ) var insertRecords_1 = body_1.insertRecords, removeRecords_2 = body_1.removeRecords, updateRecords_1 = body_1.updateRecords, pendingRecords_1 = body_1.pendingRecords var commitParams = { $grid: $xegrid, code: code2, button, body: body_1, form: formData, options: ajaxMethods_2, } var applyArgs_3 = [commitParams].concat(args) if (insertRecords_1.length) { body_1.pendingRecords = pendingRecords_1.filter(function (row) { return $xetable.findRowIndexOf(insertRecords_1, row) === -1 }) } if (pendingRecords_1.length) { body_1.insertRecords = insertRecords_1.filter(function (row) { return $xetable.findRowIndexOf(pendingRecords_1, row) === -1 }) } var restPromise = Promise.resolve() if (editRules) { restPromise = $xetable.validate( body_1.insertRecords.concat(updateRecords_1) ) } return restPromise.then(function (errMap) { if (errMap) { return } if ( body_1.insertRecords.length || removeRecords_2.length || updateRecords_1.length || body_1.pendingRecords.length ) { reactData.tableLoading = true return Promise.resolve( (beforeSave || ajaxMethods_2).apply(void 0, applyArgs_3) ) .then(function (rest) { reactData.tableLoading = false reactData.pendingRecords = [] if (isMsg) { VXETable.modal.message({ content: getRespMsg(rest, 'vxe.grid.saveSuccess'), status: 'success', }) } if (afterSave) { afterSave.apply(void 0, applyArgs_3) } else { gridMethods.commitProxy('query') } return { status: true } }) .catch(function (rest) { reactData.tableLoading = false if (isMsg) { VXETable.modal.message({ id: code2, content: getRespMsg(rest, 'vxe.grid.operError'), status: 'error', }) } return { status: false } }) } else { if (isMsg) { VXETable.modal.message({ id: code2, content: GlobalConfig.i18n('vxe.grid.dataUnchanged'), status: 'info', }) } } }) } break } default: { var gCommandOpts = VXETable.commands.get(code2) if (gCommandOpts) { if (gCommandOpts.commandMethod) { gCommandOpts.commandMethod.apply( gCommandOpts, __spreadArray$3( [{ code: code2, button, $grid: $xegrid, $table: $xetable }], args, false ) ) } } } } return nextTick() }, zoom: function () { if (reactData.isZMax) { return gridMethods.revert() } return gridMethods.maximize() }, isMaximized: function () { return reactData.isZMax }, maximize: function () { return handleZoom(true) }, revert: function () { return handleZoom() }, getFormItems: function (itemIndex) { var formOpts = computeFormOpts.value var formConfig = props2.formConfig var items = formOpts.items var itemList = [] xeUtils.eachTree( formConfig && isEnableConf(formOpts) && items ? items : [], function (item2) { itemList.push(item2) }, { children: 'children' } ) return xeUtils.isUndefined(itemIndex) ? itemList : itemList[itemIndex] }, getPendingRecords: function () { return reactData.pendingRecords }, getProxyInfo: function () { if (props2.proxyConfig) { var sortData2 = reactData.sortData return { data: reactData.tableData, filter: reactData.filterData, form: reactData.formData, sort: sortData2.length ? sortData2[0] : {}, sorts: sortData2, pager: reactData.tablePage, pendingRecords: reactData.pendingRecords, } } return null }, } var gridPrivateMethods = { extendTableMethods, callSlot: function (slotFunc, params2) { if (slotFunc) { if (xeUtils.isString(slotFunc)) { slotFunc = slots[slotFunc] || null } if (xeUtils.isFunction(slotFunc)) { return getSlotVNs(slotFunc(params2)) } } return [] }, getExcludeHeight: function () { var height = props2.height var isZMax = reactData.isZMax var el2 = refElem.value var formWrapper = refFormWrapper.value var toolbarWrapper = refToolbarWrapper.value var topWrapper = refTopWrapper.value var bottomWrapper = refBottomWrapper.value var pagerWrapper = refPagerWrapper.value var parentPaddingSize = isZMax || height !== 'auto' ? 0 : getPaddingTopBottomSize(el2.parentNode) return ( parentPaddingSize + getPaddingTopBottomSize(el2) + getOffsetHeight(formWrapper) + getOffsetHeight(toolbarWrapper) + getOffsetHeight(topWrapper) + getOffsetHeight(bottomWrapper) + getOffsetHeight(pagerWrapper) ) }, getParentHeight: function () { var el2 = refElem.value if (el2) { return ( (reactData.isZMax ? getDomNode().visibleHeight : xeUtils.toNumber(getComputedStyle(el2.parentNode).height)) - gridPrivateMethods.getExcludeHeight() ) } return 0 }, triggerToolbarCommitEvent: function (params2, evnt) { var code2 = params2.code return gridMethods.commitProxy(params2, evnt).then(function (rest) { if ( code2 && rest && rest.status && ['query', 'reload', 'delete', 'save'].includes(code2) ) { gridMethods.dispatchEvent( code2 === 'delete' || code2 === 'save' ? 'proxy-'.concat(code2) : 'proxy-query', __assign$c(__assign$c({}, rest), { isReload: code2 === 'reload', }), evnt ) } }) }, triggerToolbarBtnEvent: function (button, evnt) { gridPrivateMethods.triggerToolbarCommitEvent(button, evnt) gridMethods.dispatchEvent( 'toolbar-button-click', { code: button.code, button }, evnt ) }, triggerToolbarTolEvent: function (tool, evnt) { gridPrivateMethods.triggerToolbarCommitEvent(tool, evnt) gridMethods.dispatchEvent('toolbar-tool-click', { code: tool.code, tool, $event: evnt, }) }, triggerZoomEvent: function (evnt) { gridMethods.zoom() gridMethods.dispatchEvent( 'zoom', { type: reactData.isZMax ? 'max' : 'revert' }, evnt ) }, } Object.assign( $xegrid, gridExtendTableMethods, gridMethods, gridPrivateMethods ) var columnFlag = ref(0) watch$1( function () { return props2.columns ? props2.columns.length : -1 }, function () { columnFlag.value++ } ) watch$1( function () { return props2.columns }, function () { columnFlag.value++ } ) watch$1(columnFlag, function () { nextTick(function () { return $xegrid.loadColumn(props2.columns || []) }) }) watch$1( function () { return props2.toolbarConfig }, function () { initToolbar() } ) watch$1( function () { return props2.pagerConfig }, function () { initPages() } ) watch$1( function () { return props2.proxyConfig }, function () { initProxy() } ) var handleGlobalKeydownEvent = function (evnt) { var zoomOpts = computeZoomOpts.value var isEsc = hasEventKey(evnt, EVENT_KEYS.ESCAPE) if (isEsc && reactData.isZMax && zoomOpts.escRestore !== false) { gridPrivateMethods.triggerZoomEvent(evnt) } } VXETable.hooks.forEach(function (options2) { var setupGrid = options2.setupGrid if (setupGrid) { var hookRest = setupGrid($xegrid) if (hookRest && xeUtils.isObject(hookRest)) { Object.assign($xegrid, hookRest) } } }) initPages() onMounted(function () { nextTick(function () { var data2 = props2.data, columns = props2.columns, proxyConfig = props2.proxyConfig var proxyOpts = computeProxyOpts.value var formOpts = computeFormOpts.value if ( isEnableConf(proxyConfig) && (data2 || (proxyOpts.form && formOpts.data)) ) { errLog('vxe.error.errConflicts', ['grid.data', 'grid.proxy-config']) } if (columns && columns.length) { $xegrid.loadColumn(columns) } initToolbar() }) GlobalEvent.on($xegrid, 'keydown', handleGlobalKeydownEvent) }) onUnmounted(function () { GlobalEvent.off($xegrid, 'keydown') }) nextTick(function () { initProxy() }) var renderVN = function () { var _a2 var vSize = computeSize.value var styles = computeStyles2.value return h$4( 'div', { ref: refElem, class: [ 'vxe-grid', ((_a2 = {}), (_a2['size--'.concat(vSize)] = vSize), (_a2['is--animat'] = !!props2.animat), (_a2['is--round'] = props2.round), (_a2['is--maximize'] = reactData.isZMax), (_a2['is--loading'] = props2.loading || reactData.tableLoading), _a2), ], style: styles, }, renderForms().concat( renderToolbars(), renderTops(), renderTables(), renderBottoms(), renderPagers() ) ) } $xegrid.renderVN = renderVN provide('$xegrid', $xegrid) return $xegrid }, render: function () { return this.renderVN() }, }) var VxeGrid = Object.assign(VxeGridComponent, { install: function (app2) { app2.component(VxeGridComponent.name, VxeGridComponent) }, }) var Grid$4 = VxeGrid dynamicApp.component(VxeGridComponent.name, VxeGridComponent) var __assign$b = (globalThis && globalThis.__assign) || function () { __assign$b = Object.assign || function (t3) { for (var s2, i2 = 1, n2 = arguments.length; i2 < n2; i2++) { s2 = arguments[i2] for (var p2 in s2) if (Object.prototype.hasOwnProperty.call(s2, p2)) t3[p2] = s2[p2] } return t3 } return __assign$b.apply(this, arguments) } var VxeToolbarComponent = defineComponent({ name: 'VxeToolbar', props: { loading: Boolean, refresh: [Boolean, Object], import: [Boolean, Object], export: [Boolean, Object], print: [Boolean, Object], zoom: [Boolean, Object], custom: [Boolean, Object], buttons: { type: Array, default: function () { return GlobalConfig.toolbar.buttons }, }, tools: { type: Array, default: function () { return GlobalConfig.toolbar.tools }, }, perfect: { type: Boolean, default: function () { return GlobalConfig.toolbar.perfect }, }, size: { type: String, default: function () { return GlobalConfig.toolbar.size || GlobalConfig.size }, }, className: [String, Function], }, emits: ['button-click', 'tool-click'], setup: function (props2, context2) { var slots = context2.slots, emit2 = context2.emit var xID = xeUtils.uniqueId() var computeSize = useSize(props2) var reactData = reactive({ isRefresh: false, columns: [], }) var refElem = ref() var refCustomWrapper = ref() var customStore = reactive({ isAll: false, isIndeterminate: false, activeBtn: false, activeWrapper: false, visible: false, }) var refMaps = { refElem, } var $xetoolbar = { xID, props: props2, context: context2, reactData, getRefMaps: function () { return refMaps }, } var toolbarMethods = {} var $xegrid = inject('$xegrid', null) var $xetable var computeRefreshOpts = computed(function () { return Object.assign({}, GlobalConfig.toolbar.refresh, props2.refresh) }) var computeImportOpts = computed(function () { return Object.assign({}, GlobalConfig.toolbar.import, props2.import) }) var computeExportOpts = computed(function () { return Object.assign({}, GlobalConfig.toolbar.export, props2.export) }) var computePrintOpts = computed(function () { return Object.assign({}, GlobalConfig.toolbar.print, props2.print) }) var computeZoomOpts = computed(function () { return Object.assign({}, GlobalConfig.toolbar.zoom, props2.zoom) }) var computeCustomOpts = computed(function () { return Object.assign({}, GlobalConfig.toolbar.custom, props2.custom) }) var checkTable = function () { if ($xetable) { return true } errLog('vxe.error.barUnableLink') } var checkCustomStatus = function () { var columns = reactData.columns var computeTableCustomOpts = $xetable.getComputeMaps().computeCustomOpts var tableCustomOpts = computeTableCustomOpts.value var checkMethod = tableCustomOpts.checkMethod customStore.isAll = columns.every(function (column) { return ( (checkMethod ? !checkMethod({ column }) : false) || column.visible ) }) customStore.isIndeterminate = !customStore.isAll && columns.some(function (column) { return ( (!checkMethod || checkMethod({ column })) && (column.visible || column.halfVisible) ) }) } var showCustom = function () { customStore.visible = true checkCustomStatus() } var handleTableCustom = function () { $xetable.handleCustom() } var closeCustom = function () { var custom = props2.custom var customOpts = computeCustomOpts.value if (customStore.visible) { customStore.visible = false if (custom && !customOpts.immediate) { handleTableCustom() } } } var emitCustomEvent = function (type4, evnt) { var comp = $xegrid || $xetable comp.dispatchEvent('custom', { type: type4 }, evnt) } var confirmCustomEvent = function (evnt) { closeCustom() emitCustomEvent('confirm', evnt) } var customOpenEvent = function (evnt) { if (checkTable()) { if (!customStore.visible) { showCustom() emitCustomEvent('open', evnt) } } } var customColseEvent = function (evnt) { if (customStore.visible) { closeCustom() emitCustomEvent('close', evnt) } } var resetCustomEvent = function (evnt) { $xetable.resetColumn(true) closeCustom() emitCustomEvent('reset', evnt) } var handleOptionCheck = function (column) { var columns = reactData.columns var matchObj = xeUtils.findTree(columns, function (item2) { return item2 === column }) if (matchObj && matchObj.parent) { var parent_1 = matchObj.parent if (parent_1.children && parent_1.children.length) { parent_1.visible = parent_1.children.every(function (column2) { return column2.visible }) parent_1.halfVisible = !parent_1.visible && parent_1.children.some(function (column2) { return column2.visible || column2.halfVisible }) handleOptionCheck(parent_1) } } } var changeCheckboxOption = function (column) { var isChecked = !column.visible var customOpts = computeCustomOpts.value xeUtils.eachTree([column], function (item2) { item2.visible = isChecked item2.halfVisible = false }) handleOptionCheck(column) if (props2.custom && customOpts.immediate) { handleTableCustom() } checkCustomStatus() } var changeFixedOption = function (column, colFixed) { var computeIsMaxFixedColumn = $xetable.getComputeMaps().computeIsMaxFixedColumn var isMaxFixedColumn = computeIsMaxFixedColumn.value if (column.fixed === colFixed) { $xetable.clearColumnFixed(column) } else { if (!isMaxFixedColumn || column.fixed) { $xetable.setColumnFixed(column, colFixed) } } } var allCustomEvent = function () { var columns = reactData.columns var computeTableCustomOpts = $xetable.getComputeMaps().computeCustomOpts var tableCustomOpts = computeTableCustomOpts.value var checkMethod = tableCustomOpts.checkMethod var isAll = !customStore.isAll xeUtils.eachTree(columns, function (column) { if (!checkMethod || checkMethod({ column })) { column.visible = isAll column.halfVisible = false } }) customStore.isAll = isAll checkCustomStatus() } var handleGlobalMousedownEvent = function (evnt) { var customWrapperElem = refCustomWrapper.value if (!getEventTargetNode(evnt, customWrapperElem).flag) { customColseEvent(evnt) } } var handleGlobalBlurEvent = function (evnt) { customColseEvent(evnt) } var handleClickSettingEvent = function (evnt) { if (customStore.visible) { customColseEvent(evnt) } else { customOpenEvent(evnt) } } var handleMouseenterSettingEvent = function (evnt) { customStore.activeBtn = true customOpenEvent(evnt) } var handleMouseleaveSettingEvent = function (evnt) { customStore.activeBtn = false setTimeout(function () { if (!customStore.activeBtn && !customStore.activeWrapper) { customColseEvent(evnt) } }, 300) } var handleWrapperMouseenterEvent = function (evnt) { customStore.activeWrapper = true customOpenEvent(evnt) } var handleWrapperMouseleaveEvent = function (evnt) { customStore.activeWrapper = false setTimeout(function () { if (!customStore.activeBtn && !customStore.activeWrapper) { customColseEvent(evnt) } }, 300) } var refreshEvent = function (evnt) { var isRefresh = reactData.isRefresh var refreshOpts = computeRefreshOpts.value if (!isRefresh) { var queryMethod = refreshOpts.queryMethod || refreshOpts.query if (queryMethod) { reactData.isRefresh = true try { Promise.resolve(queryMethod({})) .catch(function (e2) { return e2 }) .then(function () { reactData.isRefresh = false }) } catch (e2) { reactData.isRefresh = false } } else if ($xegrid) { reactData.isRefresh = true $xegrid .triggerToolbarCommitEvent( { code: refreshOpts.code || 'reload' }, evnt ) .catch(function (e2) { return e2 }) .then(function () { reactData.isRefresh = false }) } } } var zoomEvent = function (evnt) { if ($xegrid) { $xegrid.triggerZoomEvent(evnt) } } var btnEvent = function (evnt, item2) { var code2 = item2.code if (code2) { if ($xegrid) { $xegrid.triggerToolbarBtnEvent(item2, evnt) } else { var gCommandOpts = VXETable.commands.get(code2) var params2 = { code: code2, button: item2, $table: $xetable, $grid: $xegrid, $event: evnt, } if (gCommandOpts) { if (gCommandOpts.commandMethod) { gCommandOpts.commandMethod(params2) } } $xetoolbar.dispatchEvent('button-click', params2, evnt) } } } var tolEvent = function (evnt, item2) { var code2 = item2.code if (code2) { if ($xegrid) { $xegrid.triggerToolbarTolEvent(item2, evnt) } else { var gCommandOpts = VXETable.commands.get(code2) var params2 = { code: code2, tool: item2, $table: $xetable, $grid: $xegrid, $event: evnt, } if (gCommandOpts) { if (gCommandOpts.commandMethod) { gCommandOpts.commandMethod(params2) } } $xetoolbar.dispatchEvent('tool-click', params2, evnt) } } } var importEvent = function () { if (checkTable()) { $xetable.openImport() } } var exportEvent = function () { if (checkTable()) { $xetable.openExport() } } var printEvent = function () { if (checkTable()) { $xetable.openPrint() } } var renderDropdowns = function (item2, isBtn) { var dropdowns = item2.dropdowns var downVNs = [] if (dropdowns) { return dropdowns.map(function (child, index2) { if (child.visible === false) { return createCommentVNode() } return h$4(resolveComponent('vxe-button'), { key: index2, disabled: child.disabled, loading: child.loading, type: child.type, icon: child.icon, circle: child.circle, round: child.round, status: child.status, content: child.name, onClick: function (evnt) { return isBtn ? btnEvent(evnt, child) : tolEvent(evnt, child) }, }) }) } return downVNs } var renderBtns = function () { var buttons = props2.buttons var buttonsSlot = slots.buttons if (buttonsSlot) { return getSlotVNs(buttonsSlot({ $grid: $xegrid, $table: $xetable })) } var btnVNs = [] if (buttons) { buttons.forEach(function (item2) { var dropdowns = item2.dropdowns, buttonRender = item2.buttonRender if (item2.visible !== false) { var compConf = buttonRender ? VXETable.renderer.get(buttonRender.name) : null if (buttonRender && compConf && compConf.renderToolbarButton) { var toolbarButtonClassName = compConf.toolbarButtonClassName var params2 = { $grid: $xegrid, $table: $xetable, button: item2 } btnVNs.push( h$4( 'span', { class: [ 'vxe-button--item', toolbarButtonClassName ? xeUtils.isFunction(toolbarButtonClassName) ? toolbarButtonClassName(params2) : toolbarButtonClassName : '', ], }, getSlotVNs( compConf.renderToolbarButton(buttonRender, params2) ) ) ) } else { btnVNs.push( h$4( resolveComponent('vxe-button'), { disabled: item2.disabled, loading: item2.loading, type: item2.type, icon: item2.icon, circle: item2.circle, round: item2.round, status: item2.status, content: item2.name, destroyOnClose: item2.destroyOnClose, placement: item2.placement, transfer: item2.transfer, onClick: function (evnt) { return btnEvent(evnt, item2) }, }, dropdowns && dropdowns.length ? { dropdowns: function () { return renderDropdowns(item2, true) }, } : {} ) ) } } }) } return btnVNs } var renderRightTools = function () { var tools2 = props2.tools var toolsSlot = slots.tools if (toolsSlot) { return getSlotVNs(toolsSlot({ $grid: $xegrid, $table: $xetable })) } var btnVNs = [] if (tools2) { tools2.forEach(function (item2) { var dropdowns = item2.dropdowns, toolRender = item2.toolRender if (item2.visible !== false) { var compConf = toolRender ? VXETable.renderer.get(toolRender.name) : null if (toolRender && compConf && compConf.renderToolbarTool) { var toolbarToolClassName = compConf.toolbarToolClassName var params2 = { $grid: $xegrid, $table: $xetable, tool: item2 } btnVNs.push( h$4( 'span', { class: [ 'vxe-tool--item', toolbarToolClassName ? xeUtils.isFunction(toolbarToolClassName) ? toolbarToolClassName(params2) : toolbarToolClassName : '', ], }, getSlotVNs(compConf.renderToolbarTool(toolRender, params2)) ) ) } else { btnVNs.push( h$4( resolveComponent('vxe-button'), { disabled: item2.disabled, loading: item2.loading, type: item2.type, icon: item2.icon, circle: item2.circle, round: item2.round, status: item2.status, content: item2.name, destroyOnClose: item2.destroyOnClose, placement: item2.placement, transfer: item2.transfer, onClick: function (evnt) { return tolEvent(evnt, item2) }, }, dropdowns && dropdowns.length ? { dropdowns: function () { return renderDropdowns(item2, false) }, } : {} ) ) } } }) } return btnVNs } var renderCustoms = function () { var columns = reactData.columns var customOpts = computeCustomOpts.value var isMaxFixedColumn = true var colVNs = [] var customBtnOns = {} var customWrapperOns = {} var checkMethod if ($xetable) { var _a2 = $xetable.getComputeMaps(), computeTableCustomOpts = _a2.computeCustomOpts, computeIsMaxFixedColumn = _a2.computeIsMaxFixedColumn var tableCustomOpts = computeTableCustomOpts.value checkMethod = tableCustomOpts.checkMethod isMaxFixedColumn = computeIsMaxFixedColumn.value } if (customOpts.trigger === 'manual'); else if (customOpts.trigger === 'hover') { customBtnOns.onMouseenter = handleMouseenterSettingEvent customBtnOns.onMouseleave = handleMouseleaveSettingEvent customWrapperOns.onMouseenter = handleWrapperMouseenterEvent customWrapperOns.onMouseleave = handleWrapperMouseleaveEvent } else { customBtnOns.onClick = handleClickSettingEvent } xeUtils.eachTree( columns, function (column, index2, items, path, parent2) { var colTitle = formatText(column.getTitle(), 1) var colKey = column.getKey() var isColGroup = column.children && column.children.length var isDisabled = checkMethod ? !checkMethod({ column }) : false if (isColGroup || colKey) { var isChecked = column.visible var isIndeterminate = column.halfVisible colVNs.push( h$4( 'li', { class: [ 'vxe-custom--option', 'level--'.concat(column.level), { 'is--group': isColGroup, }, ], }, [ h$4( 'div', { title: colTitle, class: [ 'vxe-custom--checkbox-option', { 'is--checked': isChecked, 'is--indeterminate': isIndeterminate, 'is--disabled': isDisabled, }, ], onClick: function () { if (!isDisabled) { changeCheckboxOption(column) } }, }, [ h$4('span', { class: [ 'vxe-checkbox--icon', isIndeterminate ? GlobalConfig.icon.TABLE_CHECKBOX_INDETERMINATE : isChecked ? GlobalConfig.icon.TABLE_CHECKBOX_CHECKED : GlobalConfig.icon.TABLE_CHECKBOX_UNCHECKED, ], }), h$4( 'span', { class: 'vxe-checkbox--label', }, colTitle ), ] ), !parent2 && customOpts.allowFixed ? h$4( 'div', { class: 'vxe-custom--fixed-option', }, [ h$4('span', { class: [ 'vxe-custom--fixed-left-option', column.fixed === 'left' ? GlobalConfig.icon .TOOLBAR_TOOLS_FIXED_LEFT_ACTIVED : GlobalConfig.icon.TOOLBAR_TOOLS_FIXED_LEFT, { 'is--checked': column.fixed === 'left', 'is--disabled': isMaxFixedColumn && !column.fixed, }, ], title: GlobalConfig.i18n( column.fixed === 'left' ? 'vxe.toolbar.cancelfixed' : 'vxe.toolbar.fixedLeft' ), onClick: function () { changeFixedOption(column, 'left') }, }), h$4('span', { class: [ 'vxe-custom--fixed-right-option', column.fixed === 'right' ? GlobalConfig.icon .TOOLBAR_TOOLS_FIXED_RIGHT_ACTIVED : GlobalConfig.icon.TOOLBAR_TOOLS_FIXED_RIGHT, { 'is--checked': column.fixed === 'right', 'is--disabled': isMaxFixedColumn && !column.fixed, }, ], title: GlobalConfig.i18n( column.fixed === 'right' ? 'vxe.toolbar.cancelfixed' : 'vxe.toolbar.fixedRight' ), onClick: function () { changeFixedOption(column, 'right') }, }), ] ) : null, ] ) ) } } ) var isAllChecked = customStore.isAll var isAllIndeterminate = customStore.isIndeterminate return h$4( 'div', { class: [ 'vxe-custom--wrapper', { 'is--active': customStore.visible, }, ], ref: refCustomWrapper, }, [ h$4( resolveComponent('vxe-button'), __assign$b( { circle: true, icon: customOpts.icon || GlobalConfig.icon.TOOLBAR_TOOLS_CUSTOM, title: GlobalConfig.i18n('vxe.toolbar.custom'), }, customBtnOns ) ), h$4( 'div', { class: 'vxe-custom--option-wrapper', }, [ h$4( 'ul', { class: 'vxe-custom--header', }, [ h$4( 'li', { class: 'vxe-custom--option', }, [ h$4( 'div', { class: [ 'vxe-custom--checkbox-option', { 'is--checked': isAllChecked, 'is--indeterminate': isAllIndeterminate, }, ], title: GlobalConfig.i18n('vxe.table.allTitle'), onClick: allCustomEvent, }, [ h$4('span', { class: [ 'vxe-checkbox--icon', isAllIndeterminate ? GlobalConfig.icon.TABLE_CHECKBOX_INDETERMINATE : isAllChecked ? GlobalConfig.icon.TABLE_CHECKBOX_CHECKED : GlobalConfig.icon.TABLE_CHECKBOX_UNCHECKED, ], }), h$4( 'span', { class: 'vxe-checkbox--label', }, GlobalConfig.i18n('vxe.toolbar.customAll') ), ] ), ] ), ] ), h$4( 'ul', __assign$b({ class: 'vxe-custom--body' }, customWrapperOns), colVNs ), customOpts.showFooter || customOpts.isFooter ? h$4( 'div', { class: 'vxe-custom--footer', }, [ h$4( 'button', { class: 'btn--reset', onClick: resetCustomEvent, }, customOpts.resetButtonText || GlobalConfig.i18n('vxe.toolbar.customRestore') ), h$4( 'button', { class: 'btn--confirm', onClick: confirmCustomEvent, }, customOpts.confirmButtonText || GlobalConfig.i18n('vxe.toolbar.customConfirm') ), ] ) : null, ] ), ] ) } toolbarMethods = { dispatchEvent: function (type4, params2, evnt) { emit2( type4, Object.assign({ $toolbar: $xetoolbar, $event: evnt }, params2) ) }, syncUpdate: function (params2) { var collectColumn = params2.collectColumn $xetable = params2.$table reactData.columns = collectColumn }, } Object.assign($xetoolbar, toolbarMethods) onMounted(function () { GlobalEvent.on($xetoolbar, 'mousedown', handleGlobalMousedownEvent) GlobalEvent.on($xetoolbar, 'blur', handleGlobalBlurEvent) }) onUnmounted(function () { GlobalEvent.off($xetoolbar, 'mousedown') GlobalEvent.off($xetoolbar, 'blur') }) nextTick(function () { var refresh2 = props2.refresh var refreshOpts = computeRefreshOpts.value var queryMethod = refreshOpts.queryMethod || refreshOpts.query if (refresh2 && !$xegrid && !queryMethod) { warnLog('vxe.error.notFunc', ['queryMethod']) } computeCustomOpts.value }) var renderVN = function () { var _a2 var perfect = props2.perfect, loading2 = props2.loading, refresh2 = props2.refresh, zoom = props2.zoom, custom = props2.custom, className = props2.className var vSize = computeSize.value var refreshOpts = computeRefreshOpts.value var importOpts = computeImportOpts.value var exportOpts = computeExportOpts.value var printOpts = computePrintOpts.value var zoomOpts = computeZoomOpts.value return h$4( 'div', { ref: refElem, class: [ 'vxe-toolbar', className ? xeUtils.isFunction(className) ? className({ $toolbar: $xetoolbar }) : className : '', ((_a2 = {}), (_a2['size--'.concat(vSize)] = vSize), (_a2['is--perfect'] = perfect), (_a2['is--loading'] = loading2), _a2), ], }, [ h$4( 'div', { class: 'vxe-buttons--wrapper', }, renderBtns() ), h$4( 'div', { class: 'vxe-tools--wrapper', }, renderRightTools() ), h$4( 'div', { class: 'vxe-tools--operate', }, [ props2.import ? h$4(resolveComponent('vxe-button'), { circle: true, icon: importOpts.icon || GlobalConfig.icon.TOOLBAR_TOOLS_IMPORT, title: GlobalConfig.i18n('vxe.toolbar.import'), onClick: importEvent, }) : createCommentVNode(), props2.export ? h$4(resolveComponent('vxe-button'), { circle: true, icon: exportOpts.icon || GlobalConfig.icon.TOOLBAR_TOOLS_EXPORT, title: GlobalConfig.i18n('vxe.toolbar.export'), onClick: exportEvent, }) : createCommentVNode(), props2.print ? h$4(resolveComponent('vxe-button'), { circle: true, icon: printOpts.icon || GlobalConfig.icon.TOOLBAR_TOOLS_PRINT, title: GlobalConfig.i18n('vxe.toolbar.print'), onClick: printEvent, }) : createCommentVNode(), refresh2 ? h$4(resolveComponent('vxe-button'), { circle: true, icon: reactData.isRefresh ? refreshOpts.iconLoading || GlobalConfig.icon.TOOLBAR_TOOLS_REFRESH_LOADING : refreshOpts.icon || GlobalConfig.icon.TOOLBAR_TOOLS_REFRESH, title: GlobalConfig.i18n('vxe.toolbar.refresh'), onClick: refreshEvent, }) : createCommentVNode(), zoom && $xegrid ? h$4(resolveComponent('vxe-button'), { circle: true, icon: $xegrid.isMaximized() ? zoomOpts.iconOut || GlobalConfig.icon.TOOLBAR_TOOLS_MINIMIZE : zoomOpts.iconIn || GlobalConfig.icon.TOOLBAR_TOOLS_FULLSCREEN, title: GlobalConfig.i18n( 'vxe.toolbar.zoom'.concat( $xegrid.isMaximized() ? 'Out' : 'In' ) ), onClick: zoomEvent, }) : createCommentVNode(), custom ? renderCustoms() : createCommentVNode(), ] ), ] ) } $xetoolbar.renderVN = renderVN return $xetoolbar }, render: function () { return this.renderVN() }, }) Object.assign(VxeToolbarComponent, { install: function (app2) { app2.component(VxeToolbarComponent.name, VxeToolbarComponent) }, }) dynamicApp.component(VxeToolbarComponent.name, VxeToolbarComponent) var __assign$a = (globalThis && globalThis.__assign) || function () { __assign$a = Object.assign || function (t3) { for (var s2, i2 = 1, n2 = arguments.length; i2 < n2; i2++) { s2 = arguments[i2] for (var p2 in s2) if (Object.prototype.hasOwnProperty.call(s2, p2)) t3[p2] = s2[p2] } return t3 } return __assign$a.apply(this, arguments) } var VxePagerComponent = defineComponent({ name: 'VxePager', props: { size: { type: String, default: function () { return GlobalConfig.pager.size || GlobalConfig.size }, }, layouts: { type: Array, default: function () { return ( GlobalConfig.pager.layouts || [ 'PrevJump', 'PrevPage', 'Jump', 'PageCount', 'NextPage', 'NextJump', 'Sizes', 'Total', ] ) }, }, currentPage: { type: Number, default: 1 }, loading: Boolean, pageSize: { type: Number, default: function () { return GlobalConfig.pager.pageSize || 10 }, }, total: { type: Number, default: 0 }, pagerCount: { type: Number, default: function () { return GlobalConfig.pager.pagerCount || 7 }, }, pageSizes: { type: Array, default: function () { return GlobalConfig.pager.pageSizes || [10, 15, 20, 50, 100] }, }, align: { type: String, default: function () { return GlobalConfig.pager.align }, }, border: { type: Boolean, default: function () { return GlobalConfig.pager.border }, }, background: { type: Boolean, default: function () { return GlobalConfig.pager.background }, }, perfect: { type: Boolean, default: function () { return GlobalConfig.pager.perfect }, }, autoHidden: { type: Boolean, default: function () { return GlobalConfig.pager.autoHidden }, }, transfer: { type: Boolean, default: function () { return GlobalConfig.pager.transfer }, }, className: [String, Function], iconPrevPage: String, iconJumpPrev: String, iconJumpNext: String, iconNextPage: String, iconJumpMore: String, }, emits: ['update:pageSize', 'update:currentPage', 'page-change'], setup: function (props2, context2) { var slots = context2.slots, emit2 = context2.emit var xID = xeUtils.uniqueId() var computeSize = useSize(props2) var $xegrid = inject('$xegrid', null) var reactData = reactive({ inpCurrPage: props2.currentPage, }) var refElem = ref() var refMaps = { refElem, } var $xepager = { xID, props: props2, context: context2, getRefMaps: function () { return refMaps }, } var pagerMethods = {} var pagerPrivateMethods = {} var getPageCount = function (total2, size) { return Math.max(Math.ceil(total2 / size), 1) } var computePageCount = computed(function () { return getPageCount(props2.total, props2.pageSize) }) var jumpPageEvent = function (evnt, currentPage2) { emit2('update:currentPage', currentPage2) if (evnt && currentPage2 !== props2.currentPage) { pagerMethods.dispatchEvent( 'page-change', { type: 'current', pageSize: props2.pageSize, currentPage: currentPage2, }, evnt ) } } var changeCurrentPage = function (currentPage2, evnt) { emit2('update:currentPage', currentPage2) if (evnt && currentPage2 !== props2.currentPage) { pagerMethods.dispatchEvent( 'page-change', { type: 'current', pageSize: props2.pageSize, currentPage: currentPage2, }, evnt ) } } var triggerJumpEvent = function (evnt) { var inputElem = evnt.target var inpValue = xeUtils.toInteger(inputElem.value) var pageCount = computePageCount.value var current2 = inpValue <= 0 ? 1 : inpValue >= pageCount ? pageCount : inpValue var currPage = xeUtils.toValueString(current2) inputElem.value = currPage reactData.inpCurrPage = currPage changeCurrentPage(current2, evnt) } var computeNumList = computed(function () { var pagerCount = props2.pagerCount var pageCount = computePageCount.value var len2 = pageCount > pagerCount ? pagerCount - 2 : pagerCount var rest = [] for (var index2 = 0; index2 < len2; index2++) { rest.push(index2) } return rest }) var computeOffsetNumber = computed(function () { return Math.floor((props2.pagerCount - 2) / 2) }) var computeSizeList = computed(function () { return props2.pageSizes.map(function (item2) { if (xeUtils.isNumber(item2)) { return { value: item2, label: ''.concat(GlobalConfig.i18n('vxe.pager.pagesize', [item2])), } } return __assign$a({ value: '', label: '' }, item2) }) }) var handlePrevPage = function (evnt) { var currentPage2 = props2.currentPage var pageCount = computePageCount.value if (currentPage2 > 1) { changeCurrentPage( Math.min(pageCount, Math.max(currentPage2 - 1, 1)), evnt ) } } var handleNextPage = function (evnt) { var currentPage2 = props2.currentPage var pageCount = computePageCount.value if (currentPage2 < pageCount) { changeCurrentPage(Math.min(pageCount, currentPage2 + 1), evnt) } } var handlePrevJump = function (evnt) { var numList = computeNumList.value changeCurrentPage(Math.max(props2.currentPage - numList.length, 1), evnt) } var handleNextJump = function (evnt) { var pageCount = computePageCount.value var numList = computeNumList.value changeCurrentPage( Math.min(props2.currentPage + numList.length, pageCount), evnt ) } var pageSizeEvent = function (params2) { var value2 = params2.value var pageSize = xeUtils.toNumber(value2) var pageCount = getPageCount(props2.total, pageSize) var currentPage2 = props2.currentPage if (currentPage2 > pageCount) { currentPage2 = pageCount emit2('update:currentPage', pageCount) } emit2('update:pageSize', pageSize) pagerMethods.dispatchEvent('page-change', { type: 'size', pageSize, currentPage: currentPage2, }) } var jumpInputEvent = function (evnt) { var inputElem = evnt.target reactData.inpCurrPage = inputElem.value } var jumpKeydownEvent = function (evnt) { if (hasEventKey(evnt, EVENT_KEYS.ENTER)) { triggerJumpEvent(evnt) } else if (hasEventKey(evnt, EVENT_KEYS.ARROW_UP)) { evnt.preventDefault() handleNextPage(evnt) } else if (hasEventKey(evnt, EVENT_KEYS.ARROW_DOWN)) { evnt.preventDefault() handlePrevPage(evnt) } } var renderPrevPage = function () { return h$4( 'button', { class: [ 'vxe-pager--prev-btn', { 'is--disabled': props2.currentPage <= 1, }, ], type: 'button', title: GlobalConfig.i18n('vxe.pager.prevPage'), onClick: handlePrevPage, }, [ h$4('i', { class: [ 'vxe-pager--btn-icon', props2.iconPrevPage || GlobalConfig.icon.PAGER_PREV_PAGE, ], }), ] ) } var renderPrevJump = function (tagName) { return h$4( tagName || 'button', { class: [ 'vxe-pager--jump-prev', { 'is--fixed': !tagName, 'is--disabled': props2.currentPage <= 1, }, ], type: 'button', title: GlobalConfig.i18n('vxe.pager.prevJump'), onClick: handlePrevJump, }, [ tagName ? h$4('i', { class: [ 'vxe-pager--jump-more-icon', props2.iconJumpMore || GlobalConfig.icon.PAGER_JUMP_MORE, ], }) : null, h$4('i', { class: [ 'vxe-pager--jump-icon', props2.iconJumpPrev || GlobalConfig.icon.PAGER_JUMP_PREV, ], }), ] ) } var renderNextJump = function (tagName) { var pageCount = computePageCount.value return h$4( tagName || 'button', { class: [ 'vxe-pager--jump-next', { 'is--fixed': !tagName, 'is--disabled': props2.currentPage >= pageCount, }, ], type: 'button', title: GlobalConfig.i18n('vxe.pager.nextJump'), onClick: handleNextJump, }, [ tagName ? h$4('i', { class: [ 'vxe-pager--jump-more-icon', props2.iconJumpMore || GlobalConfig.icon.PAGER_JUMP_MORE, ], }) : null, h$4('i', { class: [ 'vxe-pager--jump-icon', props2.iconJumpNext || GlobalConfig.icon.PAGER_JUMP_NEXT, ], }), ] ) } var renderNextPage = function () { var pageCount = computePageCount.value return h$4( 'button', { class: [ 'vxe-pager--next-btn', { 'is--disabled': props2.currentPage >= pageCount, }, ], type: 'button', title: GlobalConfig.i18n('vxe.pager.nextPage'), onClick: handleNextPage, }, [ h$4('i', { class: [ 'vxe-pager--btn-icon', props2.iconNextPage || GlobalConfig.icon.PAGER_NEXT_PAGE, ], }), ] ) } var renderNumber = function (showJump) { var currentPage2 = props2.currentPage, pagerCount = props2.pagerCount var nums = [] var pageCount = computePageCount.value var numList = computeNumList.value var offsetNumber = computeOffsetNumber.value var isOv = pageCount > pagerCount var isLt = isOv && currentPage2 > offsetNumber + 1 var isGt = isOv && currentPage2 < pageCount - offsetNumber var startNumber = 1 if (isOv) { if (currentPage2 >= pageCount - offsetNumber) { startNumber = Math.max(pageCount - numList.length + 1, 1) } else { startNumber = Math.max(currentPage2 - offsetNumber, 1) } } if (showJump && isLt) { nums.push( h$4( 'button', { class: 'vxe-pager--num-btn', type: 'button', onClick: function (evnt) { return jumpPageEvent(evnt, 1) }, }, 1 ), renderPrevJump('span') ) } numList.forEach(function (item2, index2) { var number4 = startNumber + index2 if (number4 <= pageCount) { nums.push( h$4( 'button', { key: number4, class: [ 'vxe-pager--num-btn', { 'is--active': currentPage2 === number4, }, ], type: 'button', onClick: function (evnt) { return jumpPageEvent(evnt, number4) }, }, number4 ) ) } }) if (showJump && isGt) { nums.push( renderNextJump('button'), h$4( 'button', { class: 'vxe-pager--num-btn', type: 'button', onClick: function (evnt) { return jumpPageEvent(evnt, pageCount) }, }, pageCount ) ) } return h$4( 'span', { class: 'vxe-pager--btn-wrapper', }, nums ) } var renderJumpNumber = function () { return renderNumber(true) } var renderSizes = function () { var sizeList = computeSizeList.value return h$4(resolveComponent('vxe-select'), { class: 'vxe-pager--sizes', modelValue: props2.pageSize, placement: 'top', transfer: props2.transfer, options: sizeList, onChange: pageSizeEvent, }) } var renderJump = function (isFull) { return h$4( 'span', { class: 'vxe-pager--jump', }, [ isFull ? h$4( 'span', { class: 'vxe-pager--goto-text', }, GlobalConfig.i18n('vxe.pager.goto') ) : null, h$4('input', { class: 'vxe-pager--goto', value: reactData.inpCurrPage, type: 'text', autocomplete: 'off', onInput: jumpInputEvent, onKeydown: jumpKeydownEvent, onBlur: triggerJumpEvent, }), isFull ? h$4( 'span', { class: 'vxe-pager--classifier-text', }, GlobalConfig.i18n('vxe.pager.pageClassifier') ) : null, ] ) } var renderFullJump = function () { return renderJump(true) } var renderPageCount = function () { var pageCount = computePageCount.value return h$4( 'span', { class: 'vxe-pager--count', }, [ h$4('span', { class: 'vxe-pager--separator', }), h$4('span', pageCount), ] ) } var renderTotal = function () { return h$4( 'span', { class: 'vxe-pager--total', }, GlobalConfig.i18n('vxe.pager.total', [props2.total]) ) } pagerMethods = { dispatchEvent: function (type4, params2, evnt) { emit2(type4, Object.assign({ $pager: $xepager, $event: evnt }, params2)) }, prevPage: function () { handlePrevPage() return nextTick() }, nextPage: function () { handleNextPage() return nextTick() }, prevJump: function () { handlePrevJump() return nextTick() }, nextJump: function () { handleNextJump() return nextTick() }, } pagerPrivateMethods = { handlePrevPage, handleNextPage, handlePrevJump, handleNextJump, } Object.assign($xepager, pagerMethods, pagerPrivateMethods) watch$1( function () { return props2.currentPage }, function (value2) { reactData.inpCurrPage = value2 } ) var renderVN = function () { var _a2 var align = props2.align, layouts = props2.layouts, className = props2.className var childNodes = [] var vSize = computeSize.value var pageCount = computePageCount.value if (slots.left) { childNodes.push( h$4( 'span', { class: 'vxe-pager--left-wrapper', }, slots.left({ $grid: $xegrid }) ) ) } layouts.forEach(function (name2) { var renderFn switch (name2) { case 'PrevPage': renderFn = renderPrevPage break case 'PrevJump': renderFn = renderPrevJump break case 'Number': renderFn = renderNumber break case 'JumpNumber': renderFn = renderJumpNumber break case 'NextJump': renderFn = renderNextJump break case 'NextPage': renderFn = renderNextPage break case 'Sizes': renderFn = renderSizes break case 'FullJump': renderFn = renderFullJump break case 'Jump': renderFn = renderJump break case 'PageCount': renderFn = renderPageCount break case 'Total': renderFn = renderTotal break } if (renderFn) { childNodes.push(renderFn()) } }) if (slots.right) { childNodes.push( h$4( 'span', { class: 'vxe-pager--right-wrapper', }, slots.right({ $grid: $xegrid }) ) ) } return h$4( 'div', { ref: refElem, class: [ 'vxe-pager', className ? xeUtils.isFunction(className) ? className({ $pager: $xepager }) : className : '', ((_a2 = {}), (_a2['size--'.concat(vSize)] = vSize), (_a2['align--'.concat(align)] = align), (_a2['is--border'] = props2.border), (_a2['is--background'] = props2.background), (_a2['is--perfect'] = props2.perfect), (_a2['is--hidden'] = props2.autoHidden && pageCount === 1), (_a2['is--loading'] = props2.loading), _a2), ], }, [ h$4( 'div', { class: 'vxe-pager--wrapper', }, childNodes ), ] ) } $xepager.renderVN = renderVN return $xepager }, render: function () { return this.renderVN() }, }) Object.assign(VxePagerComponent, { install: function (app2) { app2.component(VxePagerComponent.name, VxePagerComponent) }, }) dynamicApp.component(VxePagerComponent.name, VxePagerComponent) Object.assign(VxeCheckboxComponent, { install: function (app2) { app2.component(VxeCheckboxComponent.name, VxeCheckboxComponent) }, }) dynamicApp.component(VxeCheckboxComponent.name, VxeCheckboxComponent) var VxeCheckboxGroupComponent = defineComponent({ name: 'VxeCheckboxGroup', props: { modelValue: Array, disabled: Boolean, max: { type: [String, Number], default: null }, size: { type: String, default: function () { return GlobalConfig.checkbox.size || GlobalConfig.size }, }, }, emits: ['update:modelValue', 'change'], setup: function (props2, context2) { var slots = context2.slots, emit2 = context2.emit var $xeform = inject('$xeform', null) var $xeformiteminfo = inject('$xeformiteminfo', null) var xID = xeUtils.uniqueId() var computeIsMaximize = computed(function () { var modelValue = props2.modelValue, max3 = props2.max if (max3) { return (modelValue ? modelValue.length : 0) >= xeUtils.toNumber(max3) } return false }) var computeMaps = { computeIsMaximize, } var $xecheckboxgroup = { xID, props: props2, context: context2, getComputeMaps: function () { return computeMaps }, } useSize(props2) var checkboxGroupMethods = { dispatchEvent: function (type4, params2, evnt) { emit2( type4, Object.assign( { $checkboxGroup: $xecheckboxgroup, $event: evnt }, params2 ) ) }, } var checkboxGroupPrivateMethods = { handleChecked: function (params2, evnt) { var checked2 = params2.checked, label = params2.label var checklist = props2.modelValue || [] var checkIndex = checklist.indexOf(label) if (checked2) { if (checkIndex === -1) { checklist.push(label) } } else { checklist.splice(checkIndex, 1) } emit2('update:modelValue', checklist) $xecheckboxgroup.dispatchEvent( 'change', Object.assign({ checklist }, params2), evnt ) if ($xeform && $xeformiteminfo) { $xeform.triggerItemEvent( evnt, $xeformiteminfo.itemConfig.field, checklist ) } }, } Object.assign( $xecheckboxgroup, checkboxGroupMethods, checkboxGroupPrivateMethods ) var renderVN = function () { return h$4( 'div', { class: 'vxe-checkbox-group', }, slots.default ? slots.default({}) : [] ) } $xecheckboxgroup.renderVN = renderVN provide('$xecheckboxgroup', $xecheckboxgroup) return renderVN }, }) Object.assign(VxeCheckboxGroupComponent, { install: function (app2) { app2.component(VxeCheckboxGroupComponent.name, VxeCheckboxGroupComponent) }, }) dynamicApp.component(VxeCheckboxGroupComponent.name, VxeCheckboxGroupComponent) Object.assign(VxeRadioComponent, { install: function (app2) { app2.component(VxeRadioComponent.name, VxeRadioComponent) }, }) dynamicApp.component(VxeRadioComponent.name, VxeRadioComponent) Object.assign(VxeRadioGroupComponent, { install: function (app2) { app2.component(VxeRadioGroupComponent.name, VxeRadioGroupComponent) }, }) dynamicApp.component(VxeRadioGroupComponent.name, VxeRadioGroupComponent) var VxeRadioButtonComponent = defineComponent({ name: 'VxeRadioButton', props: { modelValue: [String, Number, Boolean], label: { type: [String, Number, Boolean], default: null }, title: [String, Number], content: [String, Number], disabled: Boolean, strict: { type: Boolean, default: function () { return GlobalConfig.radioButton.strict }, }, size: { type: String, default: function () { return GlobalConfig.radioButton.size || GlobalConfig.size }, }, }, emits: ['update:modelValue', 'change'], setup: function (props2, context2) { var slots = context2.slots, emit2 = context2.emit var $xeform = inject('$xeform', null) var $xeformiteminfo = inject('$xeformiteminfo', null) var xID = xeUtils.uniqueId() var computeSize = useSize(props2) var $xeradiobutton = { xID, props: props2, context: context2, } var radioButtonMethods = {} var $xeradiogroup = inject('$xeradiogroup', null) var computeDisabled = computed(function () { return props2.disabled || ($xeradiogroup && $xeradiogroup.props.disabled) }) var computeName = computed(function () { return $xeradiogroup ? $xeradiogroup.name : null }) var computeStrict = computed(function () { return $xeradiogroup ? $xeradiogroup.props.strict : props2.strict }) var computeChecked = computed(function () { var modelValue = props2.modelValue, label = props2.label return $xeradiogroup ? $xeradiogroup.props.modelValue === label : modelValue === label }) radioButtonMethods = { dispatchEvent: function (type4, params2, evnt) { emit2( type4, Object.assign({ $radioButton: $xeradiobutton, $event: evnt }, params2) ) }, } Object.assign($xeradiobutton, radioButtonMethods) var handleValue2 = function (label, evnt) { if ($xeradiogroup) { $xeradiogroup.handleChecked({ label }, evnt) } else { emit2('update:modelValue', label) radioButtonMethods.dispatchEvent('change', { label }, evnt) if ($xeform && $xeformiteminfo) { $xeform.triggerItemEvent( evnt, $xeformiteminfo.itemConfig.field, label ) } } } var changeEvent = function (evnt) { var isDisabled = computeDisabled.value if (!isDisabled) { handleValue2(props2.label, evnt) } } var clickEvent = function (evnt) { var isDisabled = computeDisabled.value var isStrict = computeStrict.value if (!isDisabled && !isStrict) { if ( props2.label === ($xeradiogroup ? $xeradiogroup.props.modelValue : props2.modelValue) ) { handleValue2(null, evnt) } } } var renderVN = function () { var _a2 var vSize = computeSize.value var isDisabled = computeDisabled.value var name2 = computeName.value var checked2 = computeChecked.value return h$4( 'label', { class: [ 'vxe-radio', 'vxe-radio-button', ((_a2 = {}), (_a2['size--'.concat(vSize)] = vSize), (_a2['is--disabled'] = isDisabled), _a2), ], title: props2.title, }, [ h$4('input', { class: 'vxe-radio--input', type: 'radio', name: name2, checked: checked2, disabled: isDisabled, onChange: changeEvent, onClick: clickEvent, }), h$4( 'span', { class: 'vxe-radio--label', }, slots.default ? slots.default({}) : getFuncText(props2.content) ), ] ) } Object.assign($xeradiobutton, { renderVN, dispatchEvent, }) return renderVN }, }) Object.assign(VxeRadioButtonComponent, { install: function (app2) { app2.component(VxeRadioButtonComponent.name, VxeRadioButtonComponent) }, }) dynamicApp.component(VxeRadioButtonComponent.name, VxeRadioButtonComponent) var VxeInput = Object.assign(VxeInputConstructor, { install: function (app2) { app2.component(VxeInputConstructor.name, VxeInputConstructor) }, }) var Input$1 = VxeInput dynamicApp.component(VxeInputConstructor.name, VxeInputConstructor) var autoTxtElem var VxeTextareaComponent = defineComponent({ name: 'VxeTextarea', props: { modelValue: [String, Number], className: String, immediate: { type: Boolean, default: true }, name: String, readonly: Boolean, disabled: Boolean, placeholder: { type: String, default: function () { return xeUtils.eqNull(GlobalConfig.textarea.placeholder) ? GlobalConfig.i18n('vxe.base.pleaseInput') : GlobalConfig.textarea.placeholder }, }, maxlength: [String, Number], rows: { type: [String, Number], default: 2 }, cols: { type: [String, Number], default: null }, showWordCount: Boolean, countMethod: Function, autosize: [Boolean, Object], form: String, resize: { type: String, default: function () { return GlobalConfig.textarea.resize }, }, size: { type: String, default: function () { return GlobalConfig.textarea.size || GlobalConfig.size }, }, }, emits: [ 'update:modelValue', 'input', 'keydown', 'keyup', 'click', 'change', 'focus', 'blur', ], setup: function (props2, context2) { var emit2 = context2.emit var $xeform = inject('$xeform', null) var $xeformiteminfo = inject('$xeformiteminfo', null) var xID = xeUtils.uniqueId() var computeSize = useSize(props2) var reactData = reactive({ inputValue: props2.modelValue, }) var refElem = ref() var refTextarea = ref() var refMaps = { refElem, refTextarea, } var $xetextarea = { xID, props: props2, context: context2, reactData, getRefMaps: function () { return refMaps }, } var textareaMethods = {} var computeInputCount = computed(function () { return xeUtils.getSize(reactData.inputValue) }) var computeIsCountError = computed(function () { var inputCount = computeInputCount.value return props2.maxlength && inputCount > xeUtils.toNumber(props2.maxlength) }) var computeSizeOpts = computed(function () { return Object.assign( { minRows: 1, maxRows: 10 }, GlobalConfig.textarea.autosize, props2.autosize ) }) var updateAutoTxt = function () { var size = props2.size, autosize = props2.autosize var inputValue = reactData.inputValue if (autosize) { if (!autoTxtElem) { autoTxtElem = document.createElement('div') } if (!autoTxtElem.parentNode) { document.body.appendChild(autoTxtElem) } var textElem = refTextarea.value var textStyle = getComputedStyle(textElem) autoTxtElem.className = [ 'vxe-textarea--autosize', size ? 'size--'.concat(size) : '', ].join(' ') autoTxtElem.style.width = ''.concat(textElem.clientWidth, 'px') autoTxtElem.style.padding = textStyle.padding autoTxtElem.innerHTML = ('' + (inputValue || '\u3000')).replace( /\n$/, '\n\u3000' ) } } var handleResize = function () { if (props2.autosize) { nextTick(function () { var sizeOpts = computeSizeOpts.value var minRows = sizeOpts.minRows, maxRows = sizeOpts.maxRows var textElem = refTextarea.value var sizeHeight = autoTxtElem.clientHeight var textStyle = getComputedStyle(textElem) var lineHeight2 = xeUtils.toNumber(textStyle.lineHeight) var paddingTop2 = xeUtils.toNumber(textStyle.paddingTop) var paddingBottom2 = xeUtils.toNumber(textStyle.paddingBottom) var borderTopWidth2 = xeUtils.toNumber(textStyle.borderTopWidth) var borderBottomWidth2 = xeUtils.toNumber(textStyle.borderBottomWidth) var intervalHeight = paddingTop2 + paddingBottom2 + borderTopWidth2 + borderBottomWidth2 var rowNum = (sizeHeight - intervalHeight) / lineHeight2 var textRows = rowNum && /[0-9]/.test('' + rowNum) ? rowNum : Math.floor(rowNum) + 1 var vaildRows = textRows if (textRows < minRows) { vaildRows = minRows } else if (textRows > maxRows) { vaildRows = maxRows } textElem.style.height = ''.concat( vaildRows * lineHeight2 + intervalHeight, 'px' ) }) } } var triggerEvent2 = function (evnt) { var value2 = reactData.inputValue $xetextarea.dispatchEvent(evnt.type, { value: value2 }, evnt) } var emitUpdate = function (value2, evnt) { reactData.inputValue = value2 emit2('update:modelValue', value2) if (xeUtils.toValueString(props2.modelValue) !== value2) { textareaMethods.dispatchEvent('change', { value: value2 }, evnt) if ($xeform && $xeformiteminfo) { $xeform.triggerItemEvent( evnt, $xeformiteminfo.itemConfig.field, value2 ) } } } var inputEvent = function (evnt) { var immediate = props2.immediate var textElem = evnt.target var value2 = textElem.value reactData.inputValue = value2 if (immediate) { emitUpdate(value2, evnt) } $xetextarea.dispatchEvent('input', { value: value2 }, evnt) handleResize() } var changeEvent = function (evnt) { var immediate = props2.immediate if (immediate) { triggerEvent2(evnt) } else { emitUpdate(reactData.inputValue, evnt) } } var blurEvent = function (evnt) { var immediate = props2.immediate var inputValue = reactData.inputValue if (!immediate) { emitUpdate(inputValue, evnt) } $xetextarea.dispatchEvent('blur', { value: inputValue }, evnt) } textareaMethods = { dispatchEvent: function (type4, params2, evnt) { emit2( type4, Object.assign({ $textarea: $xetextarea, $event: evnt }, params2) ) }, focus: function () { var textElem = refTextarea.value textElem.focus() return nextTick() }, blur: function () { var textElem = refTextarea.value textElem.blur() return nextTick() }, } Object.assign($xetextarea, textareaMethods) watch$1( function () { return props2.modelValue }, function (val2) { reactData.inputValue = val2 updateAutoTxt() } ) nextTick(function () { var autosize = props2.autosize if (autosize) { updateAutoTxt() handleResize() } }) var renderVN = function () { var _a2 var className = props2.className, resize = props2.resize, placeholder = props2.placeholder, disabled = props2.disabled, maxlength = props2.maxlength, autosize = props2.autosize, showWordCount = props2.showWordCount, countMethod = props2.countMethod, rows = props2.rows, cols = props2.cols var inputValue = reactData.inputValue var vSize = computeSize.value var isCountError = computeIsCountError.value var inputCount = computeInputCount.value return h$4( 'div', { ref: refElem, class: [ 'vxe-textarea', className, ((_a2 = {}), (_a2['size--'.concat(vSize)] = vSize), (_a2['is--autosize'] = autosize), (_a2['is--count'] = showWordCount), (_a2['is--disabled'] = disabled), (_a2['def--rows'] = !xeUtils.eqNull(rows)), (_a2['def--cols'] = !xeUtils.eqNull(cols)), _a2), ], }, [ h$4('textarea', { ref: refTextarea, class: 'vxe-textarea--inner', value: inputValue, name: props2.name, placeholder: placeholder ? getFuncText(placeholder) : null, maxlength, readonly: props2.readonly, disabled, rows, cols, style: resize ? { resize, } : null, onInput: inputEvent, onChange: changeEvent, onKeydown: triggerEvent2, onKeyup: triggerEvent2, onClick: triggerEvent2, onFocus: triggerEvent2, onBlur: blurEvent, }), showWordCount ? h$4( 'span', { class: [ 'vxe-textarea--count', { 'is--error': isCountError, }, ], }, countMethod ? ''.concat(countMethod({ value: inputValue })) : '' .concat(inputCount) .concat(maxlength ? '/'.concat(maxlength) : '') ) : null, ] ) } $xetextarea.renderVN = renderVN return $xetextarea }, render: function () { return this.renderVN() }, }) Object.assign(VxeTextareaComponent, { install: function (app2) { app2.component(VxeTextareaComponent.name, VxeTextareaComponent) }, }) dynamicApp.component(VxeTextareaComponent.name, VxeTextareaComponent) Object.assign(VxeButtonComponent, { install: function (app2) { app2.component(VxeButtonComponent.name, VxeButtonComponent) }, }) dynamicApp.component(VxeButtonComponent.name, VxeButtonComponent) var __assign$9 = (globalThis && globalThis.__assign) || function () { __assign$9 = Object.assign || function (t3) { for (var s2, i2 = 1, n2 = arguments.length; i2 < n2; i2++) { s2 = arguments[i2] for (var p2 in s2) if (Object.prototype.hasOwnProperty.call(s2, p2)) t3[p2] = s2[p2] } return t3 } return __assign$9.apply(this, arguments) } function openModal(options2) { checkDynamic() return new Promise(function (resolve2) { if ( options2 && options2.id && allActivedModals.some(function (comp) { return comp.props.id === options2.id }) ) { resolve2('exist') } else { var _onHide_1 = options2.onHide var modalOpts_1 = Object.assign(options2, { key: xeUtils.uniqueId(), modelValue: true, onHide: function (params2) { var modalList = dynamicStore.modals if (_onHide_1) { _onHide_1(params2) } dynamicStore.modals = modalList.filter(function (item2) { return item2.key !== modalOpts_1.key }) resolve2(params2.type) }, }) dynamicStore.modals.push(modalOpts_1) } }) } function getModal(id2) { return xeUtils.find(allActivedModals, function ($modal) { return $modal.props.id === id2 }) } function closeModal(id2) { var modals = id2 ? [getModal(id2)] : allActivedModals var restPromises = [] modals.forEach(function ($modal) { if ($modal) { restPromises.push($modal.close()) } }) return Promise.all(restPromises) } function handleOpen(defOpts, content2, title, options2) { var opts if (xeUtils.isObject(content2)) { opts = content2 } else { opts = { content: xeUtils.toValueString(content2), title } } return openModal( __assign$9(__assign$9(__assign$9({}, defOpts), options2), opts) ) } function openAlert(content2, title, options2) { return handleOpen( { type: 'alert', showFooter: true, }, content2, title, options2 ) } function openConfirm(content2, title, options2) { return handleOpen( { type: 'confirm', status: 'question', showFooter: true, }, content2, title, options2 ) } function openMessage(content2, options2) { return handleOpen( { type: 'message', mask: false, lockView: false, showHeader: false, }, content2, '', options2 ) } var ModalController = { get: getModal, close: closeModal, open: openModal, alert: openAlert, confirm: openConfirm, message: openMessage, } Object.assign(VxeModalComponent, { install: function (app2) { app2.component(VxeModalComponent.name, VxeModalComponent) VXETable.modal = ModalController }, }) dynamicApp.component(VxeModalComponent.name, VxeModalComponent) var __assign$8 = (globalThis && globalThis.__assign) || function () { __assign$8 = Object.assign || function (t3) { for (var s2, i2 = 1, n2 = arguments.length; i2 < n2; i2++) { s2 = arguments[i2] for (var p2 in s2) if (Object.prototype.hasOwnProperty.call(s2, p2)) t3[p2] = s2[p2] } return t3 } return __assign$8.apply(this, arguments) } var __spreadArray$2 = (globalThis && globalThis.__spreadArray) || function (to, from, pack2) { if (pack2 || arguments.length === 2) for (var i2 = 0, l2 = from.length, ar2; i2 < l2; i2++) { if (ar2 || !(i2 in from)) { if (!ar2) ar2 = Array.prototype.slice.call(from, 0, i2) ar2[i2] = from[i2] } } return to.concat(ar2 || Array.prototype.slice.call(from)) } var VxeTooltipComponent = defineComponent({ name: 'VxeTooltip', props: { modelValue: Boolean, size: { type: String, default: function () { return GlobalConfig.tooltip.size || GlobalConfig.size }, }, trigger: { type: String, default: function () { return GlobalConfig.tooltip.trigger }, }, theme: { type: String, default: function () { return GlobalConfig.tooltip.theme }, }, content: { type: [String, Number], default: null }, useHTML: Boolean, zIndex: [String, Number], popupClassName: [String, Function], isArrow: { type: Boolean, default: true }, enterable: Boolean, enterDelay: { type: Number, default: function () { return GlobalConfig.tooltip.enterDelay }, }, leaveDelay: { type: Number, default: function () { return GlobalConfig.tooltip.leaveDelay }, }, }, emits: ['update:modelValue'], setup: function (props2, context2) { var slots = context2.slots, emit2 = context2.emit var xID = xeUtils.uniqueId() var computeSize = useSize(props2) var reactData = reactive({ target: null, isUpdate: false, visible: false, tipContent: '', tipActive: false, tipTarget: null, tipZindex: 0, tipStore: { style: {}, placement: '', arrowStyle: {}, }, }) var refElem = ref() var refMaps = { refElem, } var $xetooltip = { xID, props: props2, context: context2, reactData, getRefMaps: function () { return refMaps }, } var tooltipMethods = {} var updateTipStyle = function () { var tipTarget = reactData.tipTarget, tipStore = reactData.tipStore if (tipTarget) { var _a2 = getDomNode(), scrollTop = _a2.scrollTop, scrollLeft = _a2.scrollLeft, visibleWidth = _a2.visibleWidth var _b2 = getAbsolutePos(tipTarget), top_1 = _b2.top, left2 = _b2.left var el2 = refElem.value var marginSize = 6 var offsetHeight = el2.offsetHeight var offsetWidth = el2.offsetWidth var tipLeft = left2 var tipTop = top_1 - offsetHeight - marginSize tipLeft = Math.max( marginSize, left2 + Math.floor((tipTarget.offsetWidth - offsetWidth) / 2) ) if (tipLeft + offsetWidth + marginSize > scrollLeft + visibleWidth) { tipLeft = scrollLeft + visibleWidth - offsetWidth - marginSize } if (top_1 - offsetHeight < scrollTop + marginSize) { tipStore.placement = 'bottom' tipTop = top_1 + tipTarget.offsetHeight + marginSize } tipStore.style.top = ''.concat(tipTop, 'px') tipStore.style.left = ''.concat(tipLeft, 'px') tipStore.arrowStyle.left = ''.concat( left2 - tipLeft + tipTarget.offsetWidth / 2, 'px' ) } } var updateValue = function (value2) { if (value2 !== reactData.visible) { reactData.visible = value2 reactData.isUpdate = true emit2('update:modelValue', value2) } } var updateZindex = function () { if (reactData.tipZindex < getLastZIndex()) { reactData.tipZindex = nextZIndex() } } var clickEvent = function () { if (reactData.visible) { tooltipMethods.close() } else { tooltipMethods.open() } } var targetMouseenterEvent = function () { tooltipMethods.open() } var targetMouseleaveEvent = function () { var trigger2 = props2.trigger, enterable = props2.enterable, leaveDelay = props2.leaveDelay reactData.tipActive = false if (enterable && trigger2 === 'hover') { setTimeout(function () { if (!reactData.tipActive) { tooltipMethods.close() } }, leaveDelay) } else { tooltipMethods.close() } } var wrapperMouseenterEvent = function () { reactData.tipActive = true } var wrapperMouseleaveEvent = function () { var trigger2 = props2.trigger, enterable = props2.enterable, leaveDelay = props2.leaveDelay reactData.tipActive = false if (enterable && trigger2 === 'hover') { setTimeout(function () { if (!reactData.tipActive) { tooltipMethods.close() } }, leaveDelay) } } var showTip = function () { var tipStore = reactData.tipStore var el2 = refElem.value if (el2) { var parentNode2 = el2.parentNode if (!parentNode2) { document.body.appendChild(el2) } } updateValue(true) updateZindex() tipStore.placement = 'top' tipStore.style = { width: 'auto', left: 0, top: 0, zIndex: props2.zIndex || reactData.tipZindex, } tipStore.arrowStyle = { left: '50%' } return tooltipMethods.updatePlacement() } var showDelayTip = xeUtils.debounce( function () { if (reactData.tipActive) { showTip() } }, props2.enterDelay, { leading: false, trailing: true } ) tooltipMethods = { dispatchEvent: function (type4, params2, evnt) { emit2( type4, Object.assign({ $tooltip: $xetooltip, $event: evnt }, params2) ) }, open: function (target2, content2) { return tooltipMethods.toVisible(target2 || reactData.target, content2) }, close: function () { reactData.tipTarget = null reactData.tipActive = false Object.assign(reactData.tipStore, { style: {}, placement: '', arrowStyle: null, }) updateValue(false) return nextTick() }, toVisible: function (target2, content2) { if (target2) { var trigger2 = props2.trigger, enterDelay = props2.enterDelay reactData.tipActive = true reactData.tipTarget = target2 if (content2) { reactData.tipContent = content2 } if (enterDelay && trigger2 === 'hover') { showDelayTip() } else { return showTip() } } return nextTick() }, updatePlacement: function () { return nextTick().then(function () { var tipTarget = reactData.tipTarget var el2 = refElem.value if (tipTarget && el2) { updateTipStyle() return nextTick().then(updateTipStyle) } }) }, isActived: function () { return reactData.tipActive }, setActived: function (actived) { reactData.tipActive = !!actived }, } Object.assign($xetooltip, tooltipMethods) watch$1( function () { return props2.content }, function () { reactData.tipContent = props2.content } ) watch$1( function () { return props2.modelValue }, function () { if (!reactData.isUpdate) { if (props2.modelValue) { tooltipMethods.open() } else { tooltipMethods.close() } } reactData.isUpdate = false } ) onMounted(function () { nextTick(function () { var trigger2 = props2.trigger, content2 = props2.content, modelValue = props2.modelValue var wrapperElem = refElem.value var parentNode2 = wrapperElem.parentNode if (parentNode2) { reactData.tipContent = content2 reactData.tipZindex = nextZIndex() xeUtils.arrayEach(wrapperElem.children, function (elem, index2) { if (index2 > 1) { parentNode2.insertBefore(elem, wrapperElem) if (!reactData.target) { reactData.target = elem } } }) parentNode2.removeChild(wrapperElem) var target2 = reactData.target if (target2) { if (trigger2 === 'hover') { target2.onmouseenter = targetMouseenterEvent target2.onmouseleave = targetMouseleaveEvent } else if (trigger2 === 'click') { target2.onclick = clickEvent } } if (modelValue) { tooltipMethods.open() } } }) }) onBeforeUnmount(function () { var trigger2 = props2.trigger var target2 = reactData.target var wrapperElem = refElem.value if (wrapperElem) { var parentNode2 = wrapperElem.parentNode if (parentNode2) { parentNode2.removeChild(wrapperElem) } } if (target2) { if (trigger2 === 'hover') { target2.onmouseenter = null target2.onmouseleave = null } else if (trigger2 === 'click') { target2.onclick = null } } }) var renderContent = function () { var useHTML = props2.useHTML var tipContent = reactData.tipContent var contentSlot = slots.content if (contentSlot) { return h$4( 'div', { key: 1, class: 'vxe-table--tooltip-content', }, getSlotVNs(contentSlot({})) ) } if (useHTML) { return h$4('div', { key: 2, class: 'vxe-table--tooltip-content', innerHTML: tipContent, }) } return h$4( 'div', { key: 3, class: 'vxe-table--tooltip-content', }, formatText(tipContent) ) } var renderVN = function () { var _a2 var popupClassName = props2.popupClassName, theme2 = props2.theme, isArrow = props2.isArrow, enterable = props2.enterable var tipActive = reactData.tipActive, visible = reactData.visible, tipStore = reactData.tipStore var defaultSlot = slots.default var vSize = computeSize.value var ons if (enterable) { ons = { onMouseenter: wrapperMouseenterEvent, onMouseleave: wrapperMouseleaveEvent, } } return h$4( 'div', __assign$8( { ref: refElem, class: [ 'vxe-table--tooltip-wrapper', 'theme--'.concat(theme2), popupClassName ? xeUtils.isFunction(popupClassName) ? popupClassName({ $tooltip: $xetooltip }) : popupClassName : '', ((_a2 = {}), (_a2['size--'.concat(vSize)] = vSize), (_a2['placement--'.concat(tipStore.placement)] = tipStore.placement), (_a2['is--enterable'] = enterable), (_a2['is--visible'] = visible), (_a2['is--arrow'] = isArrow), (_a2['is--actived'] = tipActive), _a2), ], style: tipStore.style, }, ons ), __spreadArray$2( [ renderContent(), h$4('div', { class: 'vxe-table--tooltip-arrow', style: tipStore.arrowStyle, }), ], defaultSlot ? getSlotVNs(defaultSlot({})) : [], true ) ) } $xetooltip.renderVN = renderVN return $xetooltip }, render: function () { return this.renderVN() }, }) var VxeTooltip = Object.assign(VxeTooltipComponent, { install: function (app2) { VXETable.tooltip = true app2.component(VxeTooltipComponent.name, VxeTooltipComponent) }, }) var Tooltip = VxeTooltip dynamicApp.component(VxeTooltipComponent.name, VxeTooltipComponent) var ItemInfo = (function () { function ItemInfo2($xeform, item2) { Object.assign(this, { id: xeUtils.uniqueId('item_'), title: item2.title, field: item2.field, span: item2.span, align: item2.align, titleAlign: item2.titleAlign, titleWidth: item2.titleWidth, titleColon: item2.titleColon, titleAsterisk: item2.titleAsterisk, titlePrefix: item2.titlePrefix, titleSuffix: item2.titleSuffix, titleOverflow: item2.titleOverflow, showTitle: item2.showTitle, resetValue: item2.resetValue, visibleMethod: item2.visibleMethod, visible: item2.visible, folding: item2.folding, collapseNode: item2.collapseNode, className: item2.className, contentClassName: item2.contentClassName, contentStyle: item2.contentStyle, titleClassName: item2.titleClassName, titleStyle: item2.titleStyle, itemRender: item2.itemRender, showError: false, errRule: null, slots: item2.slots, children: [], }) } ItemInfo2.prototype.update = function (name2, value2) { this[name2] = value2 } return ItemInfo2 })() function isFormItem(item2) { return item2 instanceof ItemInfo } function createItem($xeform, _vm) { return isFormItem(_vm) ? _vm : new ItemInfo($xeform, _vm) } function handleFieldOrItem($xeform, fieldOrItem) { if (fieldOrItem) { return xeUtils.isString(fieldOrItem) ? $xeform.getItemByField(fieldOrItem) : fieldOrItem } return null } function isHiddenItem($xeform, formItem) { var reactData = $xeform.reactData var collapseAll = reactData.collapseAll var folding = formItem.folding, visible = formItem.visible return visible === false || (folding && collapseAll) } function isActivetem($xeform, formItem) { var visibleMethod = formItem.visibleMethod, itemRender = formItem.itemRender, visible = formItem.visible, field2 = formItem.field if (visible === false) { return visible } var compConf = isEnableConf(itemRender) ? VXETable.renderer.get(itemRender.name) : null if (!visibleMethod && compConf && compConf.itemVisibleMethod) { visibleMethod = compConf.itemVisibleMethod } if (!visibleMethod) { return true } var data2 = $xeform.props.data return visibleMethod({ data: data2, field: field2, property: field2, item: formItem, $form: $xeform, $grid: $xeform.xegrid, }) } function watchItem(props2, formItem) { Object.keys(props2).forEach(function (name2) { watch$1( function () { return props2[name2] }, function (value2) { formItem.update(name2, value2) } ) }) } function assemItem($xeform, el2, formItem, formGather) { var reactData = $xeform.reactData var staticItems = reactData.staticItems var parentElem = el2.parentNode var parentItem = formGather ? formGather.formItem : null var parentItems = parentItem ? parentItem.children : staticItems if (parentElem) { parentItems.splice( xeUtils.arrayIndexOf(parentElem.children, el2), 0, formItem ) reactData.staticItems = staticItems.slice(0) } } function destroyItem($xeform, formItem) { var reactData = $xeform.reactData var staticItems = reactData.staticItems var index2 = xeUtils.findIndexOf(staticItems, function (item2) { return item2.id === formItem.id }) if (index2 > -1) { staticItems.splice(index2, 1) } reactData.staticItems = staticItems.slice(0) } var __assign$7 = (globalThis && globalThis.__assign) || function () { __assign$7 = Object.assign || function (t3) { for (var s2, i2 = 1, n2 = arguments.length; i2 < n2; i2++) { s2 = arguments[i2] for (var p2 in s2) if (Object.prototype.hasOwnProperty.call(s2, p2)) t3[p2] = s2[p2] } return t3 } return __assign$7.apply(this, arguments) } function renderPrefixIcon(titlePrefix) { return h$4( 'span', { class: 'vxe-form--item-title-prefix', }, [ h$4('i', { class: titlePrefix.icon || GlobalConfig.icon.FORM_PREFIX, }), ] ) } function renderSuffixIcon(titleSuffix) { return h$4( 'span', { class: 'vxe-form--item-title-suffix', }, [ h$4('i', { class: titleSuffix.icon || GlobalConfig.icon.FORM_SUFFIX, }), ] ) } function renderTitle($xeform, item2) { var data2 = $xeform.props.data var computeTooltipOpts = $xeform.getComputeMaps().computeTooltipOpts var slots = item2.slots, field2 = item2.field, itemRender = item2.itemRender, titlePrefix = item2.titlePrefix, titleSuffix = item2.titleSuffix var tooltipOpts = computeTooltipOpts.value var compConf = isEnableConf(itemRender) ? VXETable.renderer.get(itemRender.name) : null var params2 = { data: data2, field: field2, property: field2, item: item2, $form: $xeform, $grid: $xeform.xegrid, } var titleSlot = slots ? slots.title : null var contVNs = [] var titVNs = [] if (titlePrefix) { titVNs.push( titlePrefix.content || titlePrefix.message ? h$4( resolveComponent('vxe-tooltip'), __assign$7(__assign$7(__assign$7({}, tooltipOpts), titlePrefix), { content: getFuncText(titlePrefix.content || titlePrefix.message), }), { default: function () { return renderPrefixIcon(titlePrefix) }, } ) : renderPrefixIcon(titlePrefix) ) } titVNs.push( h$4( 'span', { class: 'vxe-form--item-title-label', }, compConf && compConf.renderItemTitle ? getSlotVNs(compConf.renderItemTitle(itemRender, params2)) : titleSlot ? $xeform.callSlot(titleSlot, params2) : getFuncText(item2.title) ) ) contVNs.push( h$4( 'div', { class: 'vxe-form--item-title-content', }, titVNs ) ) var fixVNs = [] if (titleSuffix) { fixVNs.push( titleSuffix.content || titleSuffix.message ? h$4( resolveComponent('vxe-tooltip'), __assign$7(__assign$7(__assign$7({}, tooltipOpts), titleSuffix), { content: getFuncText(titleSuffix.content || titleSuffix.message), }), { default: function () { return renderSuffixIcon(titleSuffix) }, } ) : renderSuffixIcon(titleSuffix) ) } contVNs.push( h$4( 'div', { class: 'vxe-form--item-title-postfix', }, fixVNs ) ) return contVNs } var __assign$6 = (globalThis && globalThis.__assign) || function () { __assign$6 = Object.assign || function (t3) { for (var s2, i2 = 1, n2 = arguments.length; i2 < n2; i2++) { s2 = arguments[i2] for (var p2 in s2) if (Object.prototype.hasOwnProperty.call(s2, p2)) t3[p2] = s2[p2] } return t3 } return __assign$6.apply(this, arguments) } var VxeFormConfigItem = defineComponent({ name: 'VxeFormConfigItem', props: { itemConfig: Object, }, setup: function (props2) { var $xeform = inject('$xeform', {}) var xeformiteminfo = { itemConfig: props2.itemConfig } provide('$xeformiteminfo', xeformiteminfo) provide('$xeformgather', null) var renderVN = function () { var reactData = $xeform.reactData var _a2 = $xeform.props, data2 = _a2.data, rules2 = _a2.rules, allSpan = _a2.span, allAlign = _a2.align, allTitleAlign = _a2.titleAlign, allTitleWidth = _a2.titleWidth, allTitleColon = _a2.titleColon, allTitleAsterisk = _a2.titleAsterisk, allTitleOverflow = _a2.titleOverflow, allVertical = _a2.vertical var computeValidOpts = $xeform.getComputeMaps().computeValidOpts var item2 = props2.itemConfig var collapseAll = reactData.collapseAll var validOpts = computeValidOpts.value var slots = item2.slots, title = item2.title, visible = item2.visible, folding = item2.folding, field2 = item2.field, collapseNode = item2.collapseNode, itemRender = item2.itemRender, showError = item2.showError, errRule = item2.errRule, className = item2.className, titleOverflow = item2.titleOverflow, vertical = item2.vertical, children = item2.children, showTitle = item2.showTitle, contentClassName = item2.contentClassName, contentStyle = item2.contentStyle, titleClassName = item2.titleClassName, titleStyle = item2.titleStyle var compConf = isEnableConf(itemRender) ? VXETable.renderer.get(itemRender.name) : null var itemClassName = compConf ? compConf.itemClassName : '' var itemStyle = compConf ? compConf.itemStyle : null var itemContentClassName = compConf ? compConf.itemContentClassName : '' var itemContentStyle = compConf ? compConf.itemContentStyle : null var itemTitleClassName = compConf ? compConf.itemTitleClassName : '' var itemTitleStyle = compConf ? compConf.itemTitleStyle : null var defaultSlot = slots ? slots.default : null var titleSlot = slots ? slots.title : null var span = item2.span || allSpan var align = item2.align || allAlign var titleAlign = xeUtils.eqNull(item2.titleAlign) ? allTitleAlign : item2.titleAlign var titleWidth = xeUtils.eqNull(item2.titleWidth) ? allTitleWidth : item2.titleWidth var titleColon = xeUtils.eqNull(item2.titleColon) ? allTitleColon : item2.titleColon var titleAsterisk = xeUtils.eqNull(item2.titleAsterisk) ? allTitleAsterisk : item2.titleAsterisk var itemOverflow = xeUtils.isUndefined(titleOverflow) || xeUtils.isNull(titleOverflow) ? allTitleOverflow : titleOverflow var itemVertical = xeUtils.isUndefined(vertical) || xeUtils.isNull(vertical) ? allVertical : vertical var ovEllipsis = itemOverflow === 'ellipsis' var ovTitle = itemOverflow === 'title' var ovTooltip = itemOverflow === true || itemOverflow === 'tooltip' var hasEllipsis = ovTitle || ovTooltip || ovEllipsis var params2 = { data: data2, field: field2, property: field2, item: item2, $form: $xeform, $grid: $xeform.xegrid, } if (visible === false) { return createCommentVNode() } var isRequired = false if (rules2) { var itemRules = rules2[field2] if (itemRules) { isRequired = itemRules.some(function (rule2) { return rule2.required }) } } var isGather = children && children.length > 0 if (isGather) { var childVNs = children.map(function (childItem, index2) { return h$4(VxeFormConfigItem, { key: index2, itemConfig: childItem, }) }) return childVNs.length ? h$4( 'div', { class: [ 'vxe-form--gather vxe-row', item2.id, span ? 'vxe-col--'.concat(span, ' is--span') : '', className ? xeUtils.isFunction(className) ? className(params2) : className : '', ], }, childVNs ) : createCommentVNode() } var contentVNs = [] if (defaultSlot) { contentVNs = $xeform.callSlot(defaultSlot, params2) } else if (compConf && compConf.renderItemContent) { contentVNs = getSlotVNs(compConf.renderItemContent(itemRender, params2)) } else if (field2) { contentVNs = [xeUtils.toValueString(xeUtils.get(data2, field2))] } if (collapseNode) { contentVNs.push( h$4( 'div', { class: 'vxe-form--item-trigger-node', onClick: $xeform.toggleCollapseEvent, }, [ h$4( 'span', { class: 'vxe-form--item-trigger-text', }, collapseAll ? GlobalConfig.i18n('vxe.form.unfolding') : GlobalConfig.i18n('vxe.form.folding') ), h$4('i', { class: [ 'vxe-form--item-trigger-icon', collapseAll ? GlobalConfig.icon.FORM_FOLDING : GlobalConfig.icon.FORM_UNFOLDING, ], }), ] ) ) } if (errRule && validOpts.showMessage) { contentVNs.push( h$4( 'div', { class: 'vxe-form--item-valid', style: errRule.maxWidth ? { width: ''.concat(errRule.maxWidth, 'px'), } : null, }, errRule.content ) ) } var ons = ovTooltip ? { onMouseenter: function (evnt) { $xeform.triggerTitleTipEvent(evnt, params2) }, onMouseleave: $xeform.handleTitleTipLeaveEvent, } : {} return h$4( 'div', { class: [ 'vxe-form--item', item2.id, span ? 'vxe-col--'.concat(span, ' is--span') : '', className ? xeUtils.isFunction(className) ? className(params2) : className : '', itemClassName ? xeUtils.isFunction(itemClassName) ? itemClassName(params2) : itemClassName : '', { 'is--title': title, 'is--colon': titleColon, 'is--vertical': itemVertical, 'is--asterisk': titleAsterisk, 'is--required': isRequired, 'is--hidden': folding && collapseAll, 'is--active': isActivetem($xeform, item2), 'is--error': showError, }, ], style: xeUtils.isFunction(itemStyle) ? itemStyle(params2) : itemStyle, }, [ h$4( 'div', { class: 'vxe-form--item-inner', }, [ showTitle !== false && (title || titleSlot) ? h$4( 'div', __assign$6( { class: [ 'vxe-form--item-title', titleAlign ? 'align--'.concat(titleAlign) : '', hasEllipsis ? 'is--ellipsis' : '', itemTitleClassName ? xeUtils.isFunction(itemTitleClassName) ? itemTitleClassName(params2) : itemTitleClassName : '', titleClassName ? xeUtils.isFunction(titleClassName) ? titleClassName(params2) : titleClassName : '', ], style: Object.assign( {}, xeUtils.isFunction(itemTitleStyle) ? itemTitleStyle(params2) : itemTitleStyle, xeUtils.isFunction(titleStyle) ? titleStyle(params2) : titleStyle, titleWidth ? { width: isNaN(titleWidth) ? titleWidth : ''.concat(titleWidth, 'px'), } : null ), title: ovTitle ? getFuncText(title) : null, }, ons ), renderTitle($xeform, item2) ) : null, h$4( 'div', { class: [ 'vxe-form--item-content', align ? 'align--'.concat(align) : '', itemContentClassName ? xeUtils.isFunction(itemContentClassName) ? itemContentClassName(params2) : itemContentClassName : '', contentClassName ? xeUtils.isFunction(contentClassName) ? contentClassName(params2) : contentClassName : '', ], style: Object.assign( {}, xeUtils.isFunction(itemContentStyle) ? itemContentStyle(params2) : itemContentStyle, xeUtils.isFunction(contentStyle) ? contentStyle(params2) : contentStyle ), }, contentVNs ), ] ), ] ) } var $xeformconfigitem = { renderVN, } return $xeformconfigitem }, render: function () { return this.renderVN() }, }) var __assign$5 = (globalThis && globalThis.__assign) || function () { __assign$5 = Object.assign || function (t3) { for (var s2, i2 = 1, n2 = arguments.length; i2 < n2; i2++) { s2 = arguments[i2] for (var p2 in s2) if (Object.prototype.hasOwnProperty.call(s2, p2)) t3[p2] = s2[p2] } return t3 } return __assign$5.apply(this, arguments) } var Rule = (function () { function Rule2(rule2) { Object.assign(this, { $options: rule2, required: rule2.required, min: rule2.min, max: rule2.min, type: rule2.type, pattern: rule2.pattern, validator: rule2.validator, trigger: rule2.trigger, maxWidth: rule2.maxWidth, }) } Object.defineProperty(Rule2.prototype, 'content', { get: function () { return getFuncText(this.$options.content || this.$options.message) }, enumerable: false, configurable: true, }) Object.defineProperty(Rule2.prototype, 'message', { get: function () { return this.content }, enumerable: false, configurable: true, }) return Rule2 })() var validErrorRuleValue = function (rule2, val2) { var type4 = rule2.type, min3 = rule2.min, max3 = rule2.max, pattern4 = rule2.pattern var isNumType = type4 === 'number' var numVal = isNumType ? xeUtils.toNumber(val2) : xeUtils.getSize(val2) if (isNumType && isNaN(val2)) { return true } if (!xeUtils.eqNull(min3) && numVal < xeUtils.toNumber(min3)) { return true } if (!xeUtils.eqNull(max3) && numVal > xeUtils.toNumber(max3)) { return true } if ( pattern4 && !(xeUtils.isRegExp(pattern4) ? pattern4 : new RegExp(pattern4)).test(val2) ) { return true } return false } function getResetValue(value2, resetValue) { if (xeUtils.isArray(value2)) { resetValue = [] } return resetValue } var VxeFormComponent = defineComponent({ name: 'VxeForm', props: { collapseStatus: { type: Boolean, default: true }, loading: Boolean, data: Object, size: { type: String, default: function () { return GlobalConfig.form.size || GlobalConfig.size }, }, span: { type: [String, Number], default: function () { return GlobalConfig.form.span }, }, align: { type: String, default: function () { return GlobalConfig.form.align }, }, titleAlign: { type: String, default: function () { return GlobalConfig.form.titleAlign }, }, titleWidth: { type: [String, Number], default: function () { return GlobalConfig.form.titleWidth }, }, titleColon: { type: Boolean, default: function () { return GlobalConfig.form.titleColon }, }, titleAsterisk: { type: Boolean, default: function () { return GlobalConfig.form.titleAsterisk }, }, titleOverflow: { type: [Boolean, String], default: null }, vertical: { type: Boolean, default: null, }, className: [String, Function], readonly: Boolean, items: Array, rules: Object, preventSubmit: { type: Boolean, default: function () { return GlobalConfig.form.preventSubmit }, }, validConfig: Object, tooltipConfig: Object, customLayout: { type: Boolean, default: function () { return GlobalConfig.form.customLayout }, }, }, emits: [ 'update:collapseStatus', 'collapse', 'toggle-collapse', 'submit', 'submit-invalid', 'reset', ], setup: function (props2, context2) { var hasUseTooltip = VXETable.tooltip var slots = context2.slots, emit2 = context2.emit var xID = xeUtils.uniqueId() var computeSize = useSize(props2) var reactData = reactive({ collapseAll: props2.collapseStatus, staticItems: [], formItems: [], }) var internalData = reactive({ tooltipTimeout: null, tooltipStore: { item: null, visible: false, }, }) var $xegrid = inject('$xegrid', null) var refElem = ref() var refTooltip = ref() var formMethods = {} var computeValidOpts = computed(function () { return Object.assign( {}, GlobalConfig.form.validConfig, props2.validConfig ) }) var computeTooltipOpts = computed(function () { return Object.assign( {}, GlobalConfig.tooltip, GlobalConfig.form.tooltipConfig, props2.tooltipConfig ) }) var refMaps = { refElem, } var computeMaps = { computeSize, computeValidOpts, computeTooltipOpts, } var $xeform = { xID, props: props2, context: context2, reactData, xegrid: $xegrid, getRefMaps: function () { return refMaps }, getComputeMaps: function () { return computeMaps }, } var callSlot = function (slotFunc, params2) { if (slotFunc) { if (xeUtils.isString(slotFunc)) { slotFunc = slots[slotFunc] || null } if (xeUtils.isFunction(slotFunc)) { return getSlotVNs(slotFunc(params2)) } } return [] } var loadItem = function (list2) { if (list2.length) { reactData.staticItems = xeUtils.mapTree( list2, function (item2) { return createItem($xeform, item2) }, { children: 'children' } ) } return nextTick() } var getItems = function () { var itemList = [] xeUtils.eachTree( reactData.formItems, function (item2) { itemList.push(item2) }, { children: 'children' } ) return itemList } var getItemByField = function (field2) { var rest = xeUtils.findTree( reactData.formItems, function (item2) { return item2.field === field2 }, { children: 'children' } ) return rest ? rest.item : null } var getCollapseStatus = function () { return reactData.collapseAll } var toggleCollapse = function () { var status = !getCollapseStatus() reactData.collapseAll = status emit2('update:collapseStatus', status) return nextTick() } var toggleCollapseEvent = function (evnt) { toggleCollapse() var status = getCollapseStatus() formMethods.dispatchEvent( 'toggle-collapse', { status, collapse: status, data: props2.data }, evnt ) formMethods.dispatchEvent( 'collapse', { status, collapse: status, data: props2.data }, evnt ) } var clearValidate = function (fieldOrItem) { if (fieldOrItem) { var fields = fieldOrItem if (!xeUtils.isArray(fieldOrItem)) { fields = [fieldOrItem] } fields.forEach(function (field2) { if (field2) { var item2 = handleFieldOrItem($xeform, field2) if (item2) { item2.showError = false } } }) } else { getItems().forEach(function (item2) { item2.showError = false }) } return nextTick() } var reset2 = function () { var data2 = props2.data var itemList = getItems() if (data2) { itemList.forEach(function (item2) { var field2 = item2.field, resetValue = item2.resetValue, itemRender = item2.itemRender if (isEnableConf(itemRender)) { var compConf = VXETable.renderer.get(itemRender.name) if (compConf && compConf.itemResetMethod) { compConf.itemResetMethod({ data: data2, field: field2, property: field2, item: item2, $form: $xeform, $grid: $xeform.xegrid, }) } else if (field2) { xeUtils.set( data2, field2, resetValue === null ? getResetValue(xeUtils.get(data2, field2), void 0) : xeUtils.clone(resetValue, true) ) } } }) } return clearValidate() } var resetEvent = function (evnt) { evnt.preventDefault() reset2() formMethods.dispatchEvent('reset', { data: props2.data }, evnt) } var handleFocus = function (fields) { var el2 = refElem.value for (var i2 = 0; i2 < fields.length; i2++) { var property2 = fields[i2] var item2 = getItemByField(property2) if (item2 && isEnableConf(item2.itemRender)) { var itemRender = item2.itemRender var compConf = VXETable.renderer.get(itemRender.name) var inputElem = null if (!i2) { scrollToView(el2.querySelector('.'.concat(item2.id))) } if (itemRender.autofocus) { inputElem = el2.querySelector( '.'.concat(item2.id, ' ').concat(itemRender.autofocus) ) } if (!inputElem && compConf && compConf.autofocus) { inputElem = el2.querySelector( '.'.concat(item2.id, ' ').concat(compConf.autofocus) ) } if (inputElem) { inputElem.focus() break } } } } var validItemRules = function (validType, fields, val2) { var data2 = props2.data, formRules = props2.rules var errorMaps = {} if (!xeUtils.isArray(fields)) { fields = [fields] } return Promise.all( fields.map(function (property2) { var errorRules = [] var syncVailds = [] if (property2 && formRules) { var rules_1 = xeUtils.get(formRules, property2) if (rules_1) { var itemValue_1 = xeUtils.isUndefined(val2) ? xeUtils.get(data2, property2) : val2 rules_1.forEach(function (rule2) { var type4 = rule2.type, trigger2 = rule2.trigger, required4 = rule2.required, validator2 = rule2.validator if ( validType === 'all' || !trigger2 || validType === trigger2 ) { if (validator2) { var validParams = { itemValue: itemValue_1, rule: rule2, rules: rules_1, data: data2, field: property2, property: property2, $form: $xeform, } var customValid = void 0 if (xeUtils.isString(validator2)) { var gvItem = VXETable.validators.get(validator2) if (gvItem) { if (gvItem.itemValidatorMethod) { customValid = gvItem.itemValidatorMethod(validParams) } } } else { customValid = validator2(validParams) } if (customValid) { if (xeUtils.isError(customValid)) { errorRules.push( new Rule({ type: 'custom', trigger: trigger2, content: customValid.message, rule: new Rule(rule2), }) ) } else if (customValid.catch) { syncVailds.push( customValid.catch(function (e2) { errorRules.push( new Rule({ type: 'custom', trigger: trigger2, content: e2 ? e2.message : rule2.content || rule2.message, rule: new Rule(rule2), }) ) }) ) } } } else { var isArrType = type4 === 'array' var isArrVal = xeUtils.isArray(itemValue_1) var hasEmpty = true if (isArrType || isArrVal) { hasEmpty = !isArrVal || !itemValue_1.length } else if (xeUtils.isString(itemValue_1)) { hasEmpty = eqEmptyValue(itemValue_1.trim()) } else { hasEmpty = eqEmptyValue(itemValue_1) } if ( required4 ? hasEmpty || validErrorRuleValue(rule2, itemValue_1) : !hasEmpty && validErrorRuleValue(rule2, itemValue_1) ) { errorRules.push(new Rule(rule2)) } } } }) } } return Promise.all(syncVailds).then(function () { if (errorRules.length) { errorMaps[property2] = errorRules.map(function (rule2) { return { $form: $xeform, rule: rule2, data: data2, field: property2, property: property2, } }) } }) }) ).then(function () { if (!xeUtils.isEmpty(errorMaps)) { return Promise.reject(errorMaps) } }) } var showErrTime var beginValidate = function (itemList, type4, callback) { var data2 = props2.data, formRules = props2.rules var validOpts = computeValidOpts.value var validRest = {} var validFields = [] var itemValids = [] clearTimeout(showErrTime) if (data2 && formRules) { itemList.forEach(function (item2) { var field2 = item2.field if ( field2 && !isHiddenItem($xeform, item2) && isActivetem($xeform, item2) ) { itemValids.push( validItemRules(type4 || 'all', field2) .then(function () { item2.errRule = null }) .catch(function (errorMaps) { var rest = errorMaps[field2] if (!validRest[field2]) { validRest[field2] = [] } validRest[field2].push(rest) validFields.push(field2) item2.errRule = rest[0].rule return Promise.reject(rest) }) ) } }) return Promise.all(itemValids) .then(function () { if (callback) { callback() } }) .catch(function () { return new Promise(function (resolve2) { showErrTime = window.setTimeout(function () { itemList.forEach(function (item2) { if (item2.errRule) { item2.showError = true } }) }, 20) if (validOpts.autoPos !== false) { nextTick(function () { handleFocus(validFields) }) } if (callback) { callback(validRest) resolve2() } else { resolve2(validRest) } }) }) } if (callback) { callback() } return Promise.resolve() } var validate = function (callback) { clearValidate() return beginValidate(getItems(), '', callback) } var validateField = function (fieldOrItem, callback) { var fields = [] if (xeUtils.isArray(fieldOrItem)) { fields = fieldOrItem } else { fields = [fieldOrItem] } return beginValidate( fields.map(function (field2) { return handleFieldOrItem($xeform, field2) }), '', callback ) } var submitEvent = function (evnt) { evnt.preventDefault() if (!props2.preventSubmit) { clearValidate() beginValidate(getItems()).then(function (errMap) { if (errMap) { formMethods.dispatchEvent( 'submit-invalid', { data: props2.data, errMap }, evnt ) } else { formMethods.dispatchEvent('submit', { data: props2.data }, evnt) } }) } } var closeTooltip = function () { var tooltipStore = internalData.tooltipStore var $tooltip = refTooltip.value if (tooltipStore.visible) { Object.assign(tooltipStore, { item: null, visible: false, }) if ($tooltip) { $tooltip.close() } } return nextTick() } var triggerTitleTipEvent = function (evnt, params2) { var item2 = params2.item var tooltipStore = internalData.tooltipStore var $tooltip = refTooltip.value var overflowElem = evnt.currentTarget.children[0] var content2 = (overflowElem.textContent || '').trim() var isCellOverflow = overflowElem.scrollWidth > overflowElem.clientWidth clearTimeout(internalData.tooltipTimeout) if (tooltipStore.item !== item2) { closeTooltip() } if (content2 && isCellOverflow) { Object.assign(tooltipStore, { item: item2, visible: true, }) if ($tooltip) { $tooltip.open(overflowElem, content2) } } } var handleTitleTipLeaveEvent = function () { var tooltipOpts = computeTooltipOpts.value var $tooltip = refTooltip.value if ($tooltip) { $tooltip.setActived(false) } if (tooltipOpts.enterable) { internalData.tooltipTimeout = setTimeout(function () { $tooltip = refTooltip.value if ($tooltip && !$tooltip.isActived()) { closeTooltip() } }, tooltipOpts.leaveDelay) } else { closeTooltip() } } var triggerItemEvent = function (evnt, field2, itemValue) { if (field2) { return validItemRules( evnt ? (['blur'].includes(evnt.type) ? 'blur' : 'change') : 'all', field2, itemValue ) .then(function () { clearValidate(field2) }) .catch(function (errorMaps) { var rest = errorMaps[field2] var item2 = getItemByField(field2) if (rest && item2) { item2.showError = true item2.errRule = rest[0].rule } }) } return nextTick() } var updateStatus = function (scope, itemValue) { var field2 = scope.field return triggerItemEvent(new Event('change'), field2, itemValue) } formMethods = { dispatchEvent: function (type4, params2, evnt) { emit2( type4, Object.assign( { $form: $xeform, $grid: $xegrid, $event: evnt }, params2 ) ) }, reset: reset2, validate, validateField, clearValidate, updateStatus, toggleCollapse, getItems, getItemByField, closeTooltip, } var formPrivateMethods = { callSlot, triggerItemEvent, toggleCollapseEvent, triggerTitleTipEvent, handleTitleTipLeaveEvent, } Object.assign($xeform, formMethods, formPrivateMethods) var staticItemFlag = ref(0) watch$1( function () { return reactData.staticItems.length }, function () { staticItemFlag.value++ } ) watch$1( function () { return reactData.staticItems }, function () { staticItemFlag.value++ } ) watch$1(staticItemFlag, function () { reactData.formItems = reactData.staticItems }) var itemFlag = ref(0) watch$1( function () { return props2.items ? props2.items.length : -1 }, function () { itemFlag.value++ } ) watch$1( function () { return props2.items }, function () { itemFlag.value++ } ) watch$1(itemFlag, function () { loadItem(props2.items || []) }) watch$1( function () { return props2.collapseStatus }, function (value2) { reactData.collapseAll = !!value2 } ) onMounted(function () { nextTick(function () { loadItem(props2.items || []) }) }) var renderVN = function () { var _a2 var loading2 = props2.loading, className = props2.className, data2 = props2.data, customLayout = props2.customLayout var formItems = reactData.formItems var vSize = computeSize.value var tooltipOpts = computeTooltipOpts.value var defaultSlot = slots.default return h$4( 'form', { ref: refElem, class: [ 'vxe-form', className ? xeUtils.isFunction(className) ? className({ items: formItems, data: data2, $form: $xeform }) : className : '', ((_a2 = {}), (_a2['size--'.concat(vSize)] = vSize), (_a2['is--loading'] = loading2), _a2), ], onSubmit: submitEvent, onReset: resetEvent, }, [ h$4( 'div', { class: 'vxe-form--wrapper vxe-row', }, customLayout ? defaultSlot ? defaultSlot({}) : [] : formItems.map(function (item2, index2) { return h$4(VxeFormConfigItem, { key: index2, itemConfig: item2, }) }) ), h$4( 'div', { class: 'vxe-form-slots', ref: 'hideItem', }, customLayout ? [] : defaultSlot ? defaultSlot({}) : [] ), h$4(VxeLoading, { class: 'vxe-form--loading', modelValue: loading2, }), hasUseTooltip ? h$4( resolveComponent('vxe-tooltip'), __assign$5({ ref: refTooltip }, tooltipOpts) ) : createCommentVNode(), ] ) } $xeform.renderVN = renderVN provide('$xeform', $xeform) provide('$xeformgather', null) provide('$xeformitem', null) provide('$xeformiteminfo', null) return $xeform }, render: function () { return this.renderVN() }, }) Object.assign(VxeFormComponent, { install: function (app2) { app2.component(VxeFormComponent.name, VxeFormComponent) }, }) dynamicApp.component(VxeFormComponent.name, VxeFormComponent) var __assign$4 = (globalThis && globalThis.__assign) || function () { __assign$4 = Object.assign || function (t3) { for (var s2, i2 = 1, n2 = arguments.length; i2 < n2; i2++) { s2 = arguments[i2] for (var p2 in s2) if (Object.prototype.hasOwnProperty.call(s2, p2)) t3[p2] = s2[p2] } return t3 } return __assign$4.apply(this, arguments) } var formItemProps = { title: String, field: String, span: [String, Number], align: String, titleAlign: { type: String, default: null, }, titleWidth: { type: [String, Number], default: null, }, titleColon: { type: Boolean, default: null, }, titleAsterisk: { type: Boolean, default: null, }, showTitle: { type: Boolean, default: true, }, vertical: { type: Boolean, default: null, }, className: [String, Function], contentClassName: [String, Function], contentStyle: [Object, Function], titleClassName: [String, Function], titleStyle: [Object, Function], titleOverflow: { type: [Boolean, String], default: null, }, titlePrefix: Object, titleSuffix: Object, resetValue: { default: null }, visibleMethod: Function, visible: { type: Boolean, default: null }, folding: Boolean, collapseNode: Boolean, itemRender: Object, } var VxeFormItemComponent = defineComponent({ name: 'VxeFormItem', props: formItemProps, setup: function (props2, _a2) { var slots = _a2.slots var refElem = ref() var $xeform = inject('$xeform', {}) var formGather = inject('$xeformgather', null) var formItem = reactive(createItem($xeform, props2)) var xeformitem = { formItem } var xeformiteminfo = { itemConfig: formItem } formItem.slots = slots provide('$xeformiteminfo', xeformiteminfo) provide('$xeformitem', xeformitem) provide('$xeformgather', null) watchItem(props2, formItem) onMounted(function () { assemItem($xeform, refElem.value, formItem, formGather) }) onUnmounted(function () { destroyItem($xeform, formItem) }) var renderItem = function ($xeform2, item2) { var props3 = $xeform2.props, reactData = $xeform2.reactData var data2 = props3.data, rules2 = props3.rules, allTitleAlign = props3.titleAlign, allTitleWidth = props3.titleWidth, allTitleColon = props3.titleColon, allTitleAsterisk = props3.titleAsterisk, allTitleOverflow = props3.titleOverflow, allVertical = props3.vertical var collapseAll = reactData.collapseAll var computeValidOpts = $xeform2.getComputeMaps().computeValidOpts var validOpts = computeValidOpts.value var slots2 = item2.slots, title = item2.title, visible = item2.visible, folding = item2.folding, field2 = item2.field, collapseNode = item2.collapseNode, itemRender = item2.itemRender, showError = item2.showError, errRule = item2.errRule, className = item2.className, titleOverflow = item2.titleOverflow, vertical = item2.vertical, showTitle = item2.showTitle, contentClassName = item2.contentClassName, contentStyle = item2.contentStyle, titleClassName = item2.titleClassName, titleStyle = item2.titleStyle var compConf = isEnableConf(itemRender) ? VXETable.renderer.get(itemRender.name) : null var itemClassName = compConf ? compConf.itemClassName : '' var itemStyle = compConf ? compConf.itemStyle : null var itemContentClassName = compConf ? compConf.itemContentClassName : '' var itemContentStyle = compConf ? compConf.itemContentStyle : null var itemTitleClassName = compConf ? compConf.itemTitleClassName : '' var itemTitleStyle = compConf ? compConf.itemTitleStyle : null var defaultSlot = slots2 ? slots2.default : null var titleSlot = slots2 ? slots2.title : null var span = item2.span || props3.span var align = item2.align || props3.align var titleAlign = xeUtils.eqNull(item2.titleAlign) ? allTitleAlign : item2.titleAlign var titleWidth = xeUtils.eqNull(item2.titleWidth) ? allTitleWidth : item2.titleWidth var titleColon = xeUtils.eqNull(item2.titleColon) ? allTitleColon : item2.titleColon var titleAsterisk = xeUtils.eqNull(item2.titleAsterisk) ? allTitleAsterisk : item2.titleAsterisk var itemOverflow = xeUtils.isUndefined(titleOverflow) || xeUtils.isNull(titleOverflow) ? allTitleOverflow : titleOverflow var itemVertical = xeUtils.isUndefined(vertical) || xeUtils.isNull(vertical) ? allVertical : vertical var ovEllipsis = itemOverflow === 'ellipsis' var ovTitle = itemOverflow === 'title' var ovTooltip = itemOverflow === true || itemOverflow === 'tooltip' var hasEllipsis = ovTitle || ovTooltip || ovEllipsis var params2 = { data: data2, field: field2, property: field2, item: item2, $form: $xeform2, $grid: $xeform2.xegrid, } var isRequired = false if (visible === false) { return createCommentVNode() } if (rules2) { var itemRules = rules2[field2] if (itemRules) { isRequired = itemRules.some(function (rule2) { return rule2.required }) } } var contentVNs = [] if (defaultSlot) { contentVNs = $xeform2.callSlot(defaultSlot, params2) } else if (compConf && compConf.renderItemContent) { contentVNs = getSlotVNs(compConf.renderItemContent(itemRender, params2)) } else if (field2) { contentVNs = [''.concat(xeUtils.get(data2, field2))] } if (collapseNode) { contentVNs.push( h$4( 'div', { class: 'vxe-form--item-trigger-node', onClick: $xeform2.toggleCollapseEvent, }, [ h$4( 'span', { class: 'vxe-form--item-trigger-text', }, collapseAll ? GlobalConfig.i18n('vxe.form.unfolding') : GlobalConfig.i18n('vxe.form.folding') ), h$4('i', { class: [ 'vxe-form--item-trigger-icon', collapseAll ? GlobalConfig.icon.FORM_FOLDING : GlobalConfig.icon.FORM_UNFOLDING, ], }), ] ) ) } if (errRule && validOpts.showMessage) { contentVNs.push( h$4( 'div', { class: 'vxe-form--item-valid', style: errRule.maxWidth ? { width: ''.concat(errRule.maxWidth, 'px'), } : null, }, errRule.message ) ) } var ons = ovTooltip ? { onMouseenter: function (evnt) { $xeform2.triggerTitleTipEvent(evnt, params2) }, onMouseleave: $xeform2.handleTitleTipLeaveEvent, } : {} return h$4( 'div', { ref: refElem, class: [ 'vxe-form--item', item2.id, span ? 'vxe-col--'.concat(span, ' is--span') : '', className ? xeUtils.isFunction(className) ? className(params2) : className : '', itemClassName ? xeUtils.isFunction(itemClassName) ? itemClassName(params2) : itemClassName : '', { 'is--title': title, 'is--colon': titleColon, 'is--vertical': itemVertical, 'is--asterisk': titleAsterisk, 'is--required': isRequired, 'is--hidden': folding && collapseAll, 'is--active': isActivetem($xeform2, item2), 'is--error': showError, }, ], style: xeUtils.isFunction(itemStyle) ? itemStyle(params2) : itemStyle, }, [ h$4( 'div', { class: 'vxe-form--item-inner', }, [ showTitle !== false && (title || titleSlot) ? h$4( 'div', __assign$4( { class: [ 'vxe-form--item-title', titleAlign ? 'align--'.concat(titleAlign) : '', hasEllipsis ? 'is--ellipsis' : '', itemTitleClassName ? xeUtils.isFunction(itemTitleClassName) ? itemTitleClassName(params2) : itemTitleClassName : '', titleClassName ? xeUtils.isFunction(titleClassName) ? titleClassName(params2) : titleClassName : '', ], style: Object.assign( {}, xeUtils.isFunction(itemTitleStyle) ? itemTitleStyle(params2) : itemTitleStyle, xeUtils.isFunction(titleStyle) ? titleStyle(params2) : titleStyle, titleWidth ? { width: isNaN(titleWidth) ? titleWidth : ''.concat(titleWidth, 'px'), } : null ), title: ovTitle ? getFuncText(title) : null, }, ons ), renderTitle($xeform2, item2) ) : null, h$4( 'div', { class: [ 'vxe-form--item-content', align ? 'align--'.concat(align) : '', itemContentClassName ? xeUtils.isFunction(itemContentClassName) ? itemContentClassName(params2) : itemContentClassName : '', contentClassName ? xeUtils.isFunction(contentClassName) ? contentClassName(params2) : contentClassName : '', ], style: Object.assign( {}, xeUtils.isFunction(itemContentStyle) ? itemContentStyle(params2) : itemContentStyle, xeUtils.isFunction(contentStyle) ? contentStyle(params2) : contentStyle ), }, contentVNs ), ] ), ] ) } var renderVN = function () { var formProps2 = $xeform ? $xeform.props : null return formProps2 && formProps2.customLayout ? renderItem($xeform, formItem) : h$4('div', { ref: refElem, }) } var $xeformitem = { renderVN, } return $xeformitem }, render: function () { return this.renderVN() }, }) Object.assign(VxeFormItemComponent, { install: function (app2) { app2.component(VxeFormItemComponent.name, VxeFormItemComponent) }, }) dynamicApp.component(VxeFormItemComponent.name, VxeFormItemComponent) var VxeFormGatherComponent = defineComponent({ name: 'VxeFormGather', props: formItemProps, setup: function (props2, _a2) { var slots = _a2.slots var refElem = ref() var $xeform = inject('$xeform', {}) var formGather = inject('$xeformgather', null) var defaultSlot = slots.default var formItem = reactive(createItem($xeform, props2)) var xeformitem = { formItem } var xeformiteminfo = { itemConfig: formItem } formItem.children = [] provide('$xeformiteminfo', xeformiteminfo) provide('$xeformgather', xeformitem) provide('$xeformitem', null) watchItem(props2, formItem) onMounted(function () { assemItem($xeform, refElem.value, formItem, formGather) }) onUnmounted(function () { destroyItem($xeform, formItem) }) var renderVN = function () { return h$4( 'div', { ref: refElem, }, defaultSlot ? defaultSlot() : [] ) } var $xeformgather = { renderVN, } return $xeformgather }, render: function () { return this.renderVN() }, }) Object.assign(VxeFormGatherComponent, { install: function (app2) { app2.component(VxeFormGatherComponent.name, VxeFormGatherComponent) }, }) dynamicApp.component(VxeFormGatherComponent.name, VxeFormGatherComponent) var VxeSelect = Object.assign(VxeSelectComponent, { install: function (app2) { app2.component(VxeSelectComponent.name, VxeSelectComponent) }, }) var Select$1 = VxeSelect dynamicApp.component(VxeSelectComponent.name, VxeSelectComponent) var OptionInfo = (function () { function OptionInfo2($xeselect, _vm) { Object.assign(this, { id: xeUtils.uniqueId('option_'), value: _vm.value, label: _vm.label, visible: _vm.visible, className: _vm.className, disabled: _vm.disabled, }) } OptionInfo2.prototype.update = function (name2, value2) { this[name2] = value2 } return OptionInfo2 })() function isOption(option2) { return option2 instanceof OptionInfo } function createOption($xeselect, _vm) { return isOption(_vm) ? _vm : new OptionInfo($xeselect, _vm) } function watchOption(props2, option2) { Object.keys(props2).forEach(function (name2) { watch$1( function () { return props2[name2] }, function (value2) { option2.update(name2, value2) } ) }) } function assemOption($xeselect, el2, option2, optgroup) { var reactData = $xeselect.reactData var staticOptions = reactData.staticOptions var parentElem = el2.parentNode var parentOption = optgroup ? optgroup.option : null var parentCols = parentOption ? parentOption.options : staticOptions if (parentElem && parentCols) { parentCols.splice( xeUtils.arrayIndexOf(parentElem.children, el2), 0, option2 ) reactData.staticOptions = staticOptions.slice(0) } } function destroyOption($xeselect, option2) { var reactData = $xeselect.reactData var staticOptions = reactData.staticOptions var matchObj = xeUtils.findTree( staticOptions, function (item2) { return item2.id === option2.id }, { children: 'options' } ) if (matchObj) { matchObj.items.splice(matchObj.index, 1) } reactData.staticOptions = staticOptions.slice(0) } var VxeOptgroupComponent = defineComponent({ name: 'VxeOptgroup', props: { label: { type: [String, Number, Boolean], default: '' }, visible: { type: Boolean, default: null }, className: [String, Function], disabled: Boolean, }, setup: function (props2, _a2) { var slots = _a2.slots var elem = ref() var $xeselect = inject('$xeselect', {}) var option2 = createOption($xeselect, props2) var xeoption = { option: option2 } option2.options = [] provide('xeoptgroup', xeoption) watchOption(props2, option2) onMounted(function () { assemOption($xeselect, elem.value, option2) }) onUnmounted(function () { destroyOption($xeselect, option2) }) return function () { return h$4( 'div', { ref: elem, }, slots.default ? slots.default() : [] ) } }, }) var VxeOptgroup = Object.assign(VxeOptgroupComponent, { install: function (app2) { app2.component(VxeOptgroupComponent.name, VxeOptgroupComponent) }, }) var Optgroup = VxeOptgroup dynamicApp.component(VxeOptgroupComponent.name, VxeOptgroupComponent) var VxeOptionComponent = defineComponent({ name: 'VxeOption', props: { value: null, label: { type: [String, Number, Boolean], default: '' }, visible: { type: Boolean, default: null }, className: [String, Function], disabled: Boolean, }, setup: function (props2, _a2) { var slots = _a2.slots var elem = ref() var $xeselect = inject('$xeselect', {}) var optgroup = inject('xeoptgroup', null) var option2 = createOption($xeselect, props2) option2.slots = slots watchOption(props2, option2) onMounted(function () { assemOption($xeselect, elem.value, option2, optgroup) }) onUnmounted(function () { destroyOption($xeselect, option2) }) return function () { return h$4('div', { ref: elem, }) } }, }) var VxeOption = Object.assign(VxeOptionComponent, { install: function (app2) { app2.component(VxeOptionComponent.name, VxeOptionComponent) }, }) var Option = VxeOption dynamicApp.component(VxeOptionComponent.name, VxeOptionComponent) var VxeSwitchComponent = defineComponent({ name: 'VxeSwitch', props: { modelValue: [String, Number, Boolean], disabled: Boolean, size: { type: String, default: function () { return GlobalConfig.switch.size || GlobalConfig.size }, }, openLabel: String, closeLabel: String, openValue: { type: [String, Number, Boolean], default: true }, closeValue: { type: [String, Number, Boolean], default: false }, openIcon: String, closeIcon: String, }, emits: ['update:modelValue', 'change', 'focus', 'blur'], setup: function (props2, context2) { var emit2 = context2.emit var $xeform = inject('$xeform', null) var $xeformiteminfo = inject('$xeformiteminfo', null) var xID = xeUtils.uniqueId() var computeSize = useSize(props2) var reactData = reactive({ isActivated: false, hasAnimat: false, offsetLeft: 0, }) var $xeswitch = { xID, props: props2, context: context2, reactData, } var refButton = ref() var switchMethods = {} var computeOnShowLabel = computed(function () { return getFuncText(props2.openLabel) }) var computeOffShowLabel = computed(function () { return getFuncText(props2.closeLabel) }) var computeIsChecked = computed(function () { return props2.modelValue === props2.openValue }) var _atimeout var clickEvent = function (evnt) { if (!props2.disabled) { var isChecked = computeIsChecked.value clearTimeout(_atimeout) var value2 = isChecked ? props2.closeValue : props2.openValue reactData.hasAnimat = true emit2('update:modelValue', value2) switchMethods.dispatchEvent('change', { value: value2 }, evnt) if ($xeform && $xeformiteminfo) { $xeform.triggerItemEvent( evnt, $xeformiteminfo.itemConfig.field, value2 ) } _atimeout = setTimeout(function () { reactData.hasAnimat = false }, 400) } } var focusEvent = function (evnt) { reactData.isActivated = true switchMethods.dispatchEvent('focus', { value: props2.modelValue }, evnt) } var blurEvent = function (evnt) { reactData.isActivated = false switchMethods.dispatchEvent('blur', { value: props2.modelValue }, evnt) } switchMethods = { dispatchEvent: function (type4, params2, evnt) { emit2( type4, Object.assign({ $switch: $xeswitch, $event: evnt }, params2) ) }, focus: function () { var btnElem = refButton.value reactData.isActivated = true btnElem.focus() return nextTick() }, blur: function () { var btnElem = refButton.value btnElem.blur() reactData.isActivated = false return nextTick() }, } Object.assign($xeswitch, switchMethods) var renderVN = function () { var _a2 var disabled = props2.disabled, openIcon = props2.openIcon, closeIcon = props2.closeIcon var isChecked = computeIsChecked.value var vSize = computeSize.value var onShowLabel = computeOnShowLabel.value var offShowLabel = computeOffShowLabel.value return h$4( 'div', { class: [ 'vxe-switch', isChecked ? 'is--on' : 'is--off', ((_a2 = {}), (_a2['size--'.concat(vSize)] = vSize), (_a2['is--disabled'] = disabled), (_a2['is--animat'] = reactData.hasAnimat), _a2), ], }, [ h$4( 'button', { ref: refButton, class: 'vxe-switch--button', type: 'button', disabled, onClick: clickEvent, onFocus: focusEvent, onBlur: blurEvent, }, [ h$4( 'span', { class: 'vxe-switch--label vxe-switch--label-on', }, [ openIcon ? h$4('i', { class: ['vxe-switch--label-icon', openIcon], }) : createCommentVNode(), onShowLabel, ] ), h$4( 'span', { class: 'vxe-switch--label vxe-switch--label-off', }, [ closeIcon ? h$4('i', { class: ['vxe-switch--label-icon', closeIcon], }) : createCommentVNode(), offShowLabel, ] ), h$4('span', { class: 'vxe-switch--icon', }), ] ), ] ) } $xeswitch.renderVN = renderVN return $xeswitch }, render: function () { return this.renderVN() }, }) Object.assign(VxeSwitchComponent, { install: function (app2) { app2.component(VxeSwitchComponent.name, VxeSwitchComponent) }, }) dynamicApp.component(VxeSwitchComponent.name, VxeSwitchComponent) var resizeTimeout var eventStore = [] var defaultInterval = 500 function eventHandle() { if (eventStore.length) { eventStore.forEach(function (item2) { item2.tarList.forEach(function (observer) { var target2 = observer.target, width = observer.width, heighe = observer.heighe var clientWidth = target2.clientWidth var clientHeight = target2.clientHeight var rWidth = clientWidth && width !== clientWidth var rHeight = clientHeight && heighe !== clientHeight if (rWidth || rHeight) { observer.width = clientWidth observer.heighe = clientHeight setTimeout(item2.callback) } }) }) eventListener$1() } } function eventListener$1() { clearTimeout(resizeTimeout) resizeTimeout = setTimeout( eventHandle, GlobalConfig.resizeInterval || defaultInterval ) } var XEResizeObserver = (function () { function XEResizeObserver2(callback) { this.tarList = [] this.callback = callback } XEResizeObserver2.prototype.observe = function (target2) { var _this = this if (target2) { var tarList = this.tarList if ( !tarList.some(function (observer) { return observer.target === target2 }) ) { tarList.push({ target: target2, width: target2.clientWidth, heighe: target2.clientHeight, }) } if (!eventStore.length) { eventListener$1() } if ( !eventStore.some(function (item2) { return item2 === _this }) ) { eventStore.push(this) } } } XEResizeObserver2.prototype.unobserve = function (target2) { xeUtils.remove(eventStore, function (item2) { return item2.tarList.some(function (observer) { return observer.target === target2 }) }) } XEResizeObserver2.prototype.disconnect = function () { var _this = this xeUtils.remove(eventStore, function (item2) { return item2 === _this }) } return XEResizeObserver2 })() function createResizeEvent(callback) { if (window.ResizeObserver) { return new window.ResizeObserver(callback) } return new XEResizeObserver(callback) } var VxeListComponent = defineComponent({ name: 'VxeList', props: { data: Array, height: [Number, String], maxHeight: [Number, String], loading: Boolean, className: [String, Function], size: { type: String, default: function () { return GlobalConfig.list.size || GlobalConfig.size }, }, autoResize: { type: Boolean, default: function () { return GlobalConfig.list.autoResize }, }, syncResize: [Boolean, String, Number], scrollY: Object, }, emits: ['scroll'], setup: function (props2, context2) { var slots = context2.slots, emit2 = context2.emit var xID = xeUtils.uniqueId() var computeSize = useSize(props2) var reactData = reactive({ scrollYLoad: false, bodyHeight: 0, rowHeight: 0, topSpaceHeight: 0, items: [], }) var refElem = ref() var refVirtualWrapper = ref() var refVirtualBody = ref() var internalData = { fullData: [], lastScrollLeft: 0, lastScrollTop: 0, scrollYStore: { startIndex: 0, endIndex: 0, visibleSize: 0, offsetSize: 0, rowHeight: 0, }, } var refMaps = { refElem, } var $xelist = { xID, props: props2, context: context2, reactData, internalData, getRefMaps: function () { return refMaps }, } var listMethods = {} var computeSYOpts = computed(function () { return Object.assign({}, GlobalConfig.list.scrollY, props2.scrollY) }) var computeStyles2 = computed(function () { var height = props2.height, maxHeight = props2.maxHeight var style2 = {} if (height) { style2.height = ''.concat( isNaN(height) ? height : ''.concat(height, 'px') ) } else if (maxHeight) { style2.height = 'auto' style2.maxHeight = ''.concat( isNaN(maxHeight) ? maxHeight : ''.concat(maxHeight, 'px') ) } return style2 }) var updateYSpace = function () { var scrollYLoad = reactData.scrollYLoad var scrollYStore = internalData.scrollYStore, fullData = internalData.fullData reactData.bodyHeight = scrollYLoad ? fullData.length * scrollYStore.rowHeight : 0 reactData.topSpaceHeight = scrollYLoad ? Math.max(scrollYStore.startIndex * scrollYStore.rowHeight, 0) : 0 } var handleData = function () { var scrollYLoad = reactData.scrollYLoad var fullData = internalData.fullData, scrollYStore = internalData.scrollYStore reactData.items = scrollYLoad ? fullData.slice(scrollYStore.startIndex, scrollYStore.endIndex) : fullData.slice(0) return nextTick() } var updateYData = function () { handleData() updateYSpace() } var computeScrollLoad = function () { return nextTick().then(function () { var scrollYLoad = reactData.scrollYLoad var scrollYStore = internalData.scrollYStore var virtualBodyElem = refVirtualBody.value var sYOpts = computeSYOpts.value var rowHeight = 0 var firstItemElem if (virtualBodyElem) { if (sYOpts.sItem) { firstItemElem = virtualBodyElem.querySelector(sYOpts.sItem) } if (!firstItemElem) { firstItemElem = virtualBodyElem.children[0] } } if (firstItemElem) { rowHeight = firstItemElem.offsetHeight } rowHeight = Math.max(20, rowHeight) scrollYStore.rowHeight = rowHeight if (scrollYLoad) { var scrollBodyElem = refVirtualWrapper.value var visibleYSize = Math.max( 8, Math.ceil(scrollBodyElem.clientHeight / rowHeight) ) var offsetYSize = sYOpts.oSize ? xeUtils.toNumber(sYOpts.oSize) : browse.edge ? 10 : 0 scrollYStore.offsetSize = offsetYSize scrollYStore.visibleSize = visibleYSize scrollYStore.endIndex = Math.max( scrollYStore.startIndex, visibleYSize + offsetYSize, scrollYStore.endIndex ) updateYData() } else { updateYSpace() } reactData.rowHeight = rowHeight }) } var clearScroll = function () { var scrollBodyElem = refVirtualWrapper.value if (scrollBodyElem) { scrollBodyElem.scrollTop = 0 } return nextTick() } var scrollTo = function (scrollLeft, scrollTop) { var scrollBodyElem = refVirtualWrapper.value if (xeUtils.isNumber(scrollLeft)) { scrollBodyElem.scrollLeft = scrollLeft } if (xeUtils.isNumber(scrollTop)) { scrollBodyElem.scrollTop = scrollTop } if (reactData.scrollYLoad) { return new Promise(function (resolve2) { setTimeout(function () { nextTick(function () { resolve2() }) }, 50) }) } return nextTick() } var refreshScroll = function () { var lastScrollLeft = internalData.lastScrollLeft, lastScrollTop = internalData.lastScrollTop return clearScroll().then(function () { if (lastScrollLeft || lastScrollTop) { internalData.lastScrollLeft = 0 internalData.lastScrollTop = 0 return scrollTo(lastScrollLeft, lastScrollTop) } }) } var recalculate = function () { var el2 = refElem.value if (el2.clientWidth && el2.clientHeight) { return computeScrollLoad() } return Promise.resolve() } var loadYData = function (evnt) { var scrollYStore = internalData.scrollYStore var startIndex = scrollYStore.startIndex, endIndex = scrollYStore.endIndex, visibleSize = scrollYStore.visibleSize, offsetSize = scrollYStore.offsetSize, rowHeight = scrollYStore.rowHeight var scrollBodyElem = evnt.target var scrollTop = scrollBodyElem.scrollTop var toVisibleIndex = Math.floor(scrollTop / rowHeight) var offsetStartIndex = Math.max(0, toVisibleIndex - 1 - offsetSize) var offsetEndIndex = toVisibleIndex + visibleSize + offsetSize if ( toVisibleIndex <= startIndex || toVisibleIndex >= endIndex - visibleSize - 1 ) { if (startIndex !== offsetStartIndex || endIndex !== offsetEndIndex) { scrollYStore.startIndex = offsetStartIndex scrollYStore.endIndex = offsetEndIndex updateYData() } } } var scrollEvent = function (evnt) { var scrollBodyElem = evnt.target var scrollTop = scrollBodyElem.scrollTop var scrollLeft = scrollBodyElem.scrollLeft var isX = scrollLeft !== internalData.lastScrollLeft var isY = scrollTop !== internalData.lastScrollTop internalData.lastScrollTop = scrollTop internalData.lastScrollLeft = scrollLeft if (reactData.scrollYLoad) { loadYData(evnt) } listMethods.dispatchEvent( 'scroll', { scrollLeft, scrollTop, isX, isY }, evnt ) } listMethods = { dispatchEvent: function (type4, params2, evnt) { emit2(type4, Object.assign({ $list: $xelist, $event: evnt }, params2)) }, loadData: function (datas) { var scrollYStore = internalData.scrollYStore var sYOpts = computeSYOpts.value var fullData = datas || [] Object.assign(scrollYStore, { startIndex: 0, endIndex: 1, visibleSize: 0, }) internalData.fullData = fullData reactData.scrollYLoad = !!sYOpts.enabled && sYOpts.gt > -1 && (sYOpts.gt === 0 || sYOpts.gt <= fullData.length) handleData() return computeScrollLoad().then(function () { refreshScroll() }) }, reloadData: function (datas) { clearScroll() return listMethods.loadData(datas) }, recalculate, scrollTo, refreshScroll, clearScroll, } Object.assign($xelist, listMethods) var dataFlag = ref(0) watch$1( function () { return props2.data ? props2.data.length : -1 }, function () { dataFlag.value++ } ) watch$1( function () { return props2.data }, function () { dataFlag.value++ } ) watch$1(dataFlag, function () { listMethods.loadData(props2.data || []) }) watch$1( function () { return props2.syncResize }, function (value2) { if (value2) { recalculate() nextTick(function () { return setTimeout(function () { return recalculate() }) }) } } ) onActivated(function () { recalculate().then(function () { return refreshScroll() }) }) var resizeObserver nextTick(function () { GlobalEvent.on($xelist, 'resize', function () { recalculate() }) if (props2.autoResize) { var el2 = refElem.value resizeObserver = createResizeEvent(function () { return recalculate() }) resizeObserver.observe(el2) } listMethods.loadData(props2.data || []) }) onUnmounted(function () { if (resizeObserver) { resizeObserver.disconnect() } GlobalEvent.off($xelist, 'resize') }) var renderVN = function () { var _a2 var className = props2.className, loading2 = props2.loading var bodyHeight = reactData.bodyHeight, topSpaceHeight = reactData.topSpaceHeight, items = reactData.items var vSize = computeSize.value var styles = computeStyles2.value return h$4( 'div', { ref: refElem, class: [ 'vxe-list', className ? xeUtils.isFunction(className) ? className({ $list: $xelist }) : className : '', ((_a2 = {}), (_a2['size--'.concat(vSize)] = vSize), (_a2['is--loading'] = loading2), _a2), ], }, [ h$4( 'div', { ref: refVirtualWrapper, class: 'vxe-list--virtual-wrapper', style: styles, onScroll: scrollEvent, }, [ h$4('div', { class: 'vxe-list--y-space', style: { height: bodyHeight ? ''.concat(bodyHeight, 'px') : '', }, }), h$4( 'div', { ref: refVirtualBody, class: 'vxe-list--body', style: { marginTop: topSpaceHeight ? ''.concat(topSpaceHeight, 'px') : '', }, }, slots.default ? slots.default({ items, $list: $xelist }) : [] ), ] ), h$4(VxeLoading, { class: 'vxe-list--loading', modelValue: loading2, }), ] ) } $xelist.renderVN = renderVN return $xelist }, render: function () { return this.renderVN() }, }) var VxeList = Object.assign(VxeListComponent, { install: function (app2) { app2.component(VxeListComponent.name, VxeListComponent) }, }) var List = VxeList dynamicApp.component(VxeListComponent.name, VxeListComponent) var VxePulldownComponent = defineComponent({ name: 'VxePulldown', props: { modelValue: Boolean, disabled: Boolean, placement: String, size: { type: String, default: function () { return GlobalConfig.size }, }, className: [String, Function], popupClassName: [String, Function], destroyOnClose: Boolean, transfer: Boolean, }, emits: ['update:modelValue', 'hide-panel'], setup: function (props2, context2) { var slots = context2.slots, emit2 = context2.emit var xID = xeUtils.uniqueId() var computeSize = useSize(props2) var reactData = reactive({ inited: false, panelIndex: 0, panelStyle: null, panelPlacement: null, visiblePanel: false, animatVisible: false, isActivated: false, }) var refElem = ref() var refPulldowContent = ref() var refPulldowPnanel = ref() var refMaps = { refElem, } var $xepulldown = { xID, props: props2, context: context2, reactData, getRefMaps: function () { return refMaps }, } var pulldownMethods = {} var updateZindex = function () { if (reactData.panelIndex < getLastZIndex()) { reactData.panelIndex = nextZIndex() } } var isPanelVisible = function () { return reactData.visiblePanel } var updatePlacement = function () { return nextTick().then(function () { var transfer = props2.transfer, placement = props2.placement var panelIndex = reactData.panelIndex, visiblePanel = reactData.visiblePanel if (visiblePanel) { var targetElem = refPulldowContent.value var panelElem = refPulldowPnanel.value if (panelElem && targetElem) { var targetHeight = targetElem.offsetHeight var targetWidth = targetElem.offsetWidth var panelHeight = panelElem.offsetHeight var panelWidth = panelElem.offsetWidth var marginSize = 5 var panelStyle = { zIndex: panelIndex, } var _a2 = getAbsolutePos(targetElem), boundingTop = _a2.boundingTop, boundingLeft = _a2.boundingLeft, visibleHeight = _a2.visibleHeight, visibleWidth = _a2.visibleWidth var panelPlacement = 'bottom' if (transfer) { var left2 = boundingLeft var top_1 = boundingTop + targetHeight if (placement === 'top') { panelPlacement = 'top' top_1 = boundingTop - panelHeight } else if (!placement) { if (top_1 + panelHeight + marginSize > visibleHeight) { panelPlacement = 'top' top_1 = boundingTop - panelHeight } if (top_1 < marginSize) { panelPlacement = 'bottom' top_1 = boundingTop + targetHeight } } if (left2 + panelWidth + marginSize > visibleWidth) { left2 -= left2 + panelWidth + marginSize - visibleWidth } if (left2 < marginSize) { left2 = marginSize } Object.assign(panelStyle, { left: ''.concat(left2, 'px'), top: ''.concat(top_1, 'px'), minWidth: ''.concat(targetWidth, 'px'), }) } else { if (placement === 'top') { panelPlacement = 'top' panelStyle.bottom = ''.concat(targetHeight, 'px') } else if (!placement) { if (boundingTop + targetHeight + panelHeight > visibleHeight) { if (boundingTop - targetHeight - panelHeight > marginSize) { panelPlacement = 'top' panelStyle.bottom = ''.concat(targetHeight, 'px') } } } } reactData.panelStyle = panelStyle reactData.panelPlacement = panelPlacement } } return nextTick() }) } var hidePanelTimeout var showPanel = function () { if (!reactData.inited) { reactData.inited = true } return new Promise(function (resolve2) { if (!props2.disabled) { clearTimeout(hidePanelTimeout) reactData.isActivated = true reactData.animatVisible = true setTimeout(function () { reactData.visiblePanel = true emit2('update:modelValue', true) updatePlacement() setTimeout(function () { resolve2(updatePlacement()) }, 40) }, 10) updateZindex() } else { nextTick(function () { resolve2() }) } }) } var hidePanel = function () { reactData.visiblePanel = false emit2('update:modelValue', false) return new Promise(function (resolve2) { if (reactData.animatVisible) { hidePanelTimeout = window.setTimeout(function () { reactData.animatVisible = false nextTick(function () { resolve2() }) }, 350) } else { nextTick(function () { resolve2() }) } }) } var togglePanel = function () { if (reactData.visiblePanel) { return hidePanel() } return showPanel() } var handleGlobalMousewheelEvent = function (evnt) { var disabled = props2.disabled var visiblePanel = reactData.visiblePanel var panelElem = refPulldowPnanel.value if (!disabled) { if (visiblePanel) { if (getEventTargetNode(evnt, panelElem).flag) { updatePlacement() } else { hidePanel() pulldownMethods.dispatchEvent('hide-panel', {}, evnt) } } } } var handleGlobalMousedownEvent = function (evnt) { var disabled = props2.disabled var visiblePanel = reactData.visiblePanel var el2 = refElem.value var panelElem = refPulldowPnanel.value if (!disabled) { reactData.isActivated = getEventTargetNode(evnt, el2).flag || getEventTargetNode(evnt, panelElem).flag if (visiblePanel && !reactData.isActivated) { hidePanel() pulldownMethods.dispatchEvent('hide-panel', {}, evnt) } } } var handleGlobalBlurEvent = function (evnt) { if (reactData.visiblePanel) { reactData.isActivated = false hidePanel() pulldownMethods.dispatchEvent('hide-panel', {}, evnt) } } pulldownMethods = { dispatchEvent: function (type4, params2, evnt) { emit2( type4, Object.assign({ $pulldown: $xepulldown, $event: evnt }, params2) ) }, isPanelVisible, togglePanel, showPanel, hidePanel, } Object.assign($xepulldown, pulldownMethods) watch$1( function () { return props2.modelValue }, function (value2) { if (value2) { showPanel() } else { hidePanel() } } ) nextTick(function () { GlobalEvent.on($xepulldown, 'mousewheel', handleGlobalMousewheelEvent) GlobalEvent.on($xepulldown, 'mousedown', handleGlobalMousedownEvent) GlobalEvent.on($xepulldown, 'blur', handleGlobalBlurEvent) }) onUnmounted(function () { GlobalEvent.off($xepulldown, 'mousewheel') GlobalEvent.off($xepulldown, 'mousedown') GlobalEvent.off($xepulldown, 'blur') }) var renderVN = function () { var _a2, _b2 var className = props2.className, popupClassName = props2.popupClassName, destroyOnClose = props2.destroyOnClose, transfer = props2.transfer, disabled = props2.disabled var inited = reactData.inited, isActivated = reactData.isActivated, animatVisible = reactData.animatVisible, visiblePanel = reactData.visiblePanel, panelStyle = reactData.panelStyle, panelPlacement = reactData.panelPlacement var vSize = computeSize.value return h$4( 'div', { ref: refElem, class: [ 'vxe-pulldown', className ? xeUtils.isFunction(className) ? className({ $pulldown: $xepulldown }) : className : '', ((_a2 = {}), (_a2['size--'.concat(vSize)] = vSize), (_a2['is--visivle'] = visiblePanel), (_a2['is--disabled'] = disabled), (_a2['is--active'] = isActivated), _a2), ], }, [ h$4( 'div', { ref: refPulldowContent, class: 'vxe-pulldown--content', }, slots.default ? slots.default({ $pulldown: $xepulldown }) : [] ), h$4( Teleport, { to: 'body', disabled: transfer ? !inited : true, }, [ h$4( 'div', { ref: refPulldowPnanel, class: [ 'vxe-table--ignore-clear vxe-pulldown--panel', popupClassName ? xeUtils.isFunction(popupClassName) ? popupClassName({ $pulldown: $xepulldown }) : popupClassName : '', ((_b2 = {}), (_b2['size--'.concat(vSize)] = vSize), (_b2['is--transfer'] = transfer), (_b2['animat--leave'] = animatVisible), (_b2['animat--enter'] = visiblePanel), _b2), ], placement: panelPlacement, style: panelStyle, }, slots.dropdown ? [ h$4( 'div', { class: 'vxe-pulldown--wrapper', }, !inited || (destroyOnClose && !visiblePanel && !animatVisible) ? [] : slots.dropdown({ $pulldown: $xepulldown }) ), ] : [] ), ] ), ] ) } $xepulldown.renderVN = renderVN return $xepulldown }, render: function () { return this.renderVN() }, }) Object.assign(VxePulldownComponent, { install: function (app2) { app2.component(VxePulldownComponent.name, VxePulldownComponent) }, }) dynamicApp.component(VxePulldownComponent.name, VxePulldownComponent) var __assign$3 = (globalThis && globalThis.__assign) || function () { __assign$3 = Object.assign || function (t3) { for (var s2, i2 = 1, n2 = arguments.length; i2 < n2; i2++) { s2 = arguments[i2] for (var p2 in s2) if (Object.prototype.hasOwnProperty.call(s2, p2)) t3[p2] = s2[p2] } return t3 } return __assign$3.apply(this, arguments) } var __spreadArray$1 = (globalThis && globalThis.__spreadArray) || function (to, from, pack2) { if (pack2 || arguments.length === 2) for (var i2 = 0, l2 = from.length, ar2; i2 < l2; i2++) { if (ar2 || !(i2 in from)) { if (!ar2) ar2 = Array.prototype.slice.call(from, 0, i2) ar2[i2] = from[i2] } } return to.concat(ar2 || Array.prototype.slice.call(from)) } var renderType$2 = 'body' var lineOffsetSizes = { mini: 3, small: 2, medium: 1, } var TableBodyComponent = defineComponent({ name: 'VxeTableBody', props: { tableData: Array, tableColumn: Array, fixedColumn: Array, fixedType: { type: String, default: null }, }, setup: function (props2) { var $xetable = inject('$xetable', {}) var xesize = inject('xesize', null) var xID = $xetable.xID, tableProps2 = $xetable.props, tableContext = $xetable.context, tableReactData = $xetable.reactData, tableInternalData = $xetable.internalData var _a2 = $xetable.getRefMaps(), refTableHeader = _a2.refTableHeader, refTableBody = _a2.refTableBody, refTableFooter = _a2.refTableFooter, refTableLeftBody = _a2.refTableLeftBody, refTableRightBody = _a2.refTableRightBody, refValidTooltip = _a2.refValidTooltip var _b2 = $xetable.getComputeMaps(), computeEditOpts = _b2.computeEditOpts, computeMouseOpts = _b2.computeMouseOpts, computeSYOpts = _b2.computeSYOpts, computeEmptyOpts = _b2.computeEmptyOpts, computeKeyboardOpts = _b2.computeKeyboardOpts, computeTooltipOpts = _b2.computeTooltipOpts, computeRadioOpts = _b2.computeRadioOpts, computeExpandOpts = _b2.computeExpandOpts, computeTreeOpts = _b2.computeTreeOpts, computeCheckboxOpts = _b2.computeCheckboxOpts, computeValidOpts = _b2.computeValidOpts, computeRowOpts = _b2.computeRowOpts, computeColumnOpts = _b2.computeColumnOpts var refElem = ref() var refBodyTable = ref() var refBodyColgroup = ref() var refBodyTBody = ref() var refBodyXSpace = ref() var refBodyYSpace = ref() var refBodyEmptyBlock = ref() var getOffsetSize = function () { if (xesize) { var vSize = xesize.value if (vSize) { return lineOffsetSizes[vSize] || 0 } } return 0 } var isVMScrollProcess = function () { var delayHover = tableProps2.delayHover var lastScrollTime = tableReactData.lastScrollTime, _isResize = tableReactData._isResize return !!( _isResize || (lastScrollTime && Date.now() < lastScrollTime + delayHover) ) } var countTreeExpand = function (prevRow, params2) { var count2 = 1 if (!prevRow) { return count2 } var treeOpts = computeTreeOpts.value var childrenField = treeOpts.children || treeOpts.childrenField var rowChildren = prevRow[childrenField] if (rowChildren && $xetable.isTreeExpandByRow(prevRow)) { for (var index2 = 0; index2 < rowChildren.length; index2++) { count2 += countTreeExpand(rowChildren[index2]) } } return count2 } var calcTreeLine = function (params2, items, rIndex) { var expandSize = 1 if (rIndex) { expandSize = countTreeExpand(items[rIndex - 1]) } return ( tableReactData.rowHeight * expandSize - (rIndex ? 1 : 12 - getOffsetSize()) ) } var renderLine = function (params2) { var row = params2.row, column = params2.column var treeConfig = tableProps2.treeConfig var treeOpts = computeTreeOpts.value var slots = column.slots, treeNode = column.treeNode var fullAllDataRowIdData = tableInternalData.fullAllDataRowIdData var rowid = getRowid($xetable, row) var rest = fullAllDataRowIdData[rowid] var rLevel = 0 var rIndex = 0 var items = [] if (rest) { rLevel = rest.level rIndex = rest._index items = rest.items } if (slots && slots.line) { return $xetable.callSlot(slots.line, params2) } if (treeConfig && treeNode && (treeOpts.showLine || treeOpts.line)) { return [ h$4( 'div', { class: 'vxe-tree--line-wrapper', }, [ h$4('div', { class: 'vxe-tree--line', style: { height: ''.concat(calcTreeLine(params2, items, rIndex), 'px'), left: ''.concat( rLevel * treeOpts.indent + (rLevel ? 2 - getOffsetSize() : 0) + 16, 'px' ), }, }), ] ), ] } return [] } var renderColumn = function ( seq, rowid, fixedType, rowLevel, row, rowIndex, $rowIndex, _rowIndex, column, $columnIndex, columns, items ) { var _a3 var columnKey2 = tableProps2.columnKey, height = tableProps2.height, allColumnOverflow = tableProps2.showOverflow, allCellClassName = tableProps2.cellClassName, cellStyle = tableProps2.cellStyle, allAlign = tableProps2.align, spanMethod = tableProps2.spanMethod, mouseConfig = tableProps2.mouseConfig, editConfig = tableProps2.editConfig, editRules = tableProps2.editRules, tooltipConfig = tableProps2.tooltipConfig var tableData2 = tableReactData.tableData, overflowX = tableReactData.overflowX, scrollYLoad = tableReactData.scrollYLoad, currentColumn = tableReactData.currentColumn, mergeList = tableReactData.mergeList, editStore = tableReactData.editStore, isAllOverflow = tableReactData.isAllOverflow, validErrorMaps = tableReactData.validErrorMaps var afterFullData = tableInternalData.afterFullData var validOpts = computeValidOpts.value var checkboxOpts = computeCheckboxOpts.value var editOpts = computeEditOpts.value var tooltipOpts = computeTooltipOpts.value var rowOpts = computeRowOpts.value var sYOpts = computeSYOpts.value var columnOpts = computeColumnOpts.value var type4 = column.type, cellRender = column.cellRender, editRender = column.editRender, align = column.align, showOverflow = column.showOverflow, className = column.className, treeNode = column.treeNode var actived = editStore.actived var scrollYRHeight = sYOpts.rHeight var rowHeight = rowOpts.height var renderOpts = editRender || cellRender var compConf = renderOpts ? VXETable.renderer.get(renderOpts.name) : null var compCellClassName = compConf ? compConf.cellClassName : '' var compCellStyle = compConf ? compConf.cellStyle : '' var showAllTip = tooltipOpts.showAll var columnIndex = $xetable.getColumnIndex(column) var _columnIndex = $xetable.getVTColumnIndex(column) var isEdit = isEnableConf(editRender) var fixedHiddenColumn = fixedType ? column.fixed !== fixedType : column.fixed && overflowX var cellOverflow = xeUtils.isUndefined(showOverflow) || xeUtils.isNull(showOverflow) ? allColumnOverflow : showOverflow var showEllipsis = cellOverflow === 'ellipsis' var showTitle = cellOverflow === 'title' var showTooltip2 = cellOverflow === true || cellOverflow === 'tooltip' var hasEllipsis = showTitle || showTooltip2 || showEllipsis var isDirty var tdOns = {} var cellAlign = align || allAlign var errorValidItem = validErrorMaps[''.concat(rowid, ':').concat(column.id)] var showValidTip = editRules && validOpts.showMessage && (validOpts.message === 'default' ? height || tableData2.length > 1 : validOpts.message === 'inline') var attrs = { colid: column.id } var params2 = { $table: $xetable, $grid: $xetable.xegrid, seq, rowid, row, rowIndex, $rowIndex, _rowIndex, column, columnIndex, $columnIndex, _columnIndex, fixed: fixedType, type: renderType$2, isHidden: fixedHiddenColumn, level: rowLevel, visibleData: afterFullData, data: tableData2, items, } if (scrollYLoad && !hasEllipsis) { showEllipsis = hasEllipsis = true } if (showTitle || showTooltip2 || showAllTip || tooltipConfig) { tdOns.onMouseenter = function (evnt) { if (isVMScrollProcess()) { return } if (showTitle) { updateCellTitle(evnt.currentTarget, column) } else if (showTooltip2 || showAllTip) { $xetable.triggerBodyTooltipEvent(evnt, params2) } $xetable.dispatchEvent( 'cell-mouseenter', Object.assign({ cell: evnt.currentTarget }, params2), evnt ) } } if (showTooltip2 || showAllTip || tooltipConfig) { tdOns.onMouseleave = function (evnt) { if (isVMScrollProcess()) { return } if (showTooltip2 || showAllTip) { $xetable.handleTargetLeaveEvent(evnt) } $xetable.dispatchEvent( 'cell-mouseleave', Object.assign({ cell: evnt.currentTarget }, params2), evnt ) } } if (checkboxOpts.range || mouseConfig) { tdOns.onMousedown = function (evnt) { $xetable.triggerCellMousedownEvent(evnt, params2) } } tdOns.onClick = function (evnt) { $xetable.triggerCellClickEvent(evnt, params2) } tdOns.onDblclick = function (evnt) { $xetable.triggerCellDblclickEvent(evnt, params2) } if (mergeList.length) { var spanRest = mergeBodyMethod(mergeList, _rowIndex, _columnIndex) if (spanRest) { var rowspan = spanRest.rowspan, colspan = spanRest.colspan if (!rowspan || !colspan) { return null } if (rowspan > 1) { attrs.rowspan = rowspan } if (colspan > 1) { attrs.colspan = colspan } } } else if (spanMethod) { var _b3 = spanMethod(params2) || {}, _c2 = _b3.rowspan, rowspan = _c2 === void 0 ? 1 : _c2, _d = _b3.colspan, colspan = _d === void 0 ? 1 : _d if (!rowspan || !colspan) { return null } if (rowspan > 1) { attrs.rowspan = rowspan } if (colspan > 1) { attrs.colspan = colspan } } if (fixedHiddenColumn && mergeList) { if (attrs.colspan > 1 || attrs.rowspan > 1) { fixedHiddenColumn = false } } if ( !fixedHiddenColumn && editConfig && (editRender || cellRender) && (editOpts.showStatus || editOpts.showUpdateStatus) ) { isDirty = $xetable.isUpdateByRow(row, column.field) } var tdVNs = [] if ( fixedHiddenColumn && (allColumnOverflow ? isAllOverflow : allColumnOverflow) ) { tdVNs.push( h$4('div', { class: [ 'vxe-cell', { 'c--title': showTitle, 'c--tooltip': showTooltip2, 'c--ellipsis': showEllipsis, }, ], style: { maxHeight: hasEllipsis && (scrollYRHeight || rowHeight) ? ''.concat(scrollYRHeight || rowHeight, 'px') : '', }, }) ) } else { tdVNs.push.apply( tdVNs, __spreadArray$1( __spreadArray$1([], renderLine(params2), false), [ h$4( 'div', { class: [ 'vxe-cell', { 'c--title': showTitle, 'c--tooltip': showTooltip2, 'c--ellipsis': showEllipsis, }, ], style: { maxHeight: hasEllipsis && (scrollYRHeight || rowHeight) ? ''.concat(scrollYRHeight || rowHeight, 'px') : '', }, title: showTitle ? $xetable.getCellLabel(row, column) : null, }, column.renderCell(params2) ), ], false ) ) if (showValidTip && errorValidItem) { tdVNs.push( h$4( 'div', { class: 'vxe-cell--valid', style: errorValidItem.rule && errorValidItem.rule.maxWidth ? { width: ''.concat(errorValidItem.rule.maxWidth, 'px'), } : null, }, [ h$4( 'span', { class: 'vxe-cell--valid-msg', }, errorValidItem.content ), ] ) ) } } return h$4( 'td', __assign$3( __assign$3( __assign$3( { class: [ 'vxe-body--column', column.id, ((_a3 = {}), (_a3['col--'.concat(cellAlign)] = cellAlign), (_a3['col--'.concat(type4)] = type4), (_a3['col--last'] = $columnIndex === columns.length - 1), (_a3['col--tree-node'] = treeNode), (_a3['col--edit'] = isEdit), (_a3['col--ellipsis'] = hasEllipsis), (_a3['fixed--hidden'] = fixedHiddenColumn), (_a3['col--dirty'] = isDirty), (_a3['col--actived'] = editConfig && isEdit && actived.row === row && (actived.column === column || editOpts.mode === 'row')), (_a3['col--valid-error'] = !!errorValidItem), (_a3['col--current'] = currentColumn === column), _a3), getPropClass(compCellClassName, params2), getPropClass(className, params2), getPropClass(allCellClassName, params2), ], key: columnKey2 || columnOpts.useKey ? column.id : $columnIndex, }, attrs ), { style: Object.assign( { height: hasEllipsis && (scrollYRHeight || rowHeight) ? ''.concat(scrollYRHeight || rowHeight, 'px') : '', }, xeUtils.isFunction(compCellStyle) ? compCellStyle(params2) : compCellStyle, xeUtils.isFunction(cellStyle) ? cellStyle(params2) : cellStyle ), } ), tdOns ), tdVNs ) } var renderRows = function (fixedType, tableData2, tableColumn) { var stripe = tableProps2.stripe, rowKey = tableProps2.rowKey, highlightHoverRow = tableProps2.highlightHoverRow, rowClassName = tableProps2.rowClassName, rowStyle = tableProps2.rowStyle, allColumnOverflow = tableProps2.showOverflow, editConfig = tableProps2.editConfig, treeConfig = tableProps2.treeConfig var hasFixedColumn = tableReactData.hasFixedColumn, treeExpandedMaps = tableReactData.treeExpandedMaps, scrollYLoad = tableReactData.scrollYLoad, rowExpandedMaps = tableReactData.rowExpandedMaps, expandColumn = tableReactData.expandColumn, selectRadioRow = tableReactData.selectRadioRow var fullAllDataRowIdData = tableInternalData.fullAllDataRowIdData var checkboxOpts = computeCheckboxOpts.value var radioOpts = computeRadioOpts.value var treeOpts = computeTreeOpts.value var editOpts = computeEditOpts.value var rowOpts = computeRowOpts.value var transform3 = treeOpts.transform var childrenField = treeOpts.children || treeOpts.childrenField var rows = [] tableData2.forEach(function (row, $rowIndex) { var trOn = {} var rowIndex = $rowIndex rowIndex = $xetable.getRowIndex(row) if (rowOpts.isHover || highlightHoverRow) { trOn.onMouseenter = function (evnt) { if (isVMScrollProcess()) { return } $xetable.triggerHoverEvent(evnt, { row, rowIndex }) } trOn.onMouseleave = function () { if (isVMScrollProcess()) { return } $xetable.clearHoverRow() } } var rowid = getRowid($xetable, row) var rest = fullAllDataRowIdData[rowid] var rowLevel = 0 var seq = -1 var _rowIndex = 0 if (rest) { rowLevel = rest.level seq = rest.seq _rowIndex = rest._index } var params2 = { $table: $xetable, seq, rowid, fixed: fixedType, type: renderType$2, level: rowLevel, row, rowIndex, $rowIndex, _rowIndex, } var isExpandRow = expandColumn && !!rowExpandedMaps[rowid] var isExpandTree = false var rowChildren = [] var isNewRow = false if (editConfig) { isNewRow = $xetable.isInsertByRow(row) } if (treeConfig && !scrollYLoad && !transform3) { rowChildren = row[childrenField] isExpandTree = rowChildren && rowChildren.length && !!treeExpandedMaps[rowid] } rows.push( h$4( 'tr', __assign$3( { class: [ 'vxe-body--row', treeConfig ? 'row--level-'.concat(rowLevel) : '', { 'row--stripe': stripe && ($xetable.getVTRowIndex(row) + 1) % 2 === 0, 'is--new': isNewRow, 'is--expand-row': isExpandRow, 'is--expand-tree': isExpandTree, 'row--new': isNewRow && (editOpts.showStatus || editOpts.showInsertStatus), 'row--radio': radioOpts.highlight && $xetable.eqRow(selectRadioRow, row), 'row--checked': checkboxOpts.highlight && $xetable.isCheckedByCheckboxRow(row), }, getPropClass(rowClassName, params2), ], rowid, style: rowStyle ? xeUtils.isFunction(rowStyle) ? rowStyle(params2) : rowStyle : null, key: rowKey || rowOpts.useKey || treeConfig ? rowid : $rowIndex, }, trOn ), tableColumn.map(function (column, $columnIndex) { return renderColumn( seq, rowid, fixedType, rowLevel, row, rowIndex, $rowIndex, _rowIndex, column, $columnIndex, tableColumn, tableData2 ) }) ) ) if (isExpandRow) { var expandOpts = computeExpandOpts.value var expandHeight = expandOpts.height var cellStyle = {} if (expandHeight) { cellStyle.height = ''.concat(expandHeight, 'px') } if (treeConfig) { cellStyle.paddingLeft = ''.concat( rowLevel * treeOpts.indent + 30, 'px' ) } var showOverflow = expandColumn.showOverflow var hasEllipsis = xeUtils.isUndefined(showOverflow) || xeUtils.isNull(showOverflow) ? allColumnOverflow : showOverflow var expandParams = { $table: $xetable, seq, column: expandColumn, fixed: fixedType, type: renderType$2, level: rowLevel, row, rowIndex, $rowIndex, _rowIndex, } rows.push( h$4( 'tr', __assign$3( { class: 'vxe-body--expanded-row', key: 'expand_'.concat(rowid), style: rowStyle ? xeUtils.isFunction(rowStyle) ? rowStyle(expandParams) : rowStyle : null, }, trOn ), [ h$4( 'td', { class: { 'vxe-body--expanded-column': 1, 'fixed--hidden': fixedType && !hasFixedColumn, 'col--ellipsis': hasEllipsis, }, colspan: tableColumn.length, }, [ h$4( 'div', { class: { 'vxe-body--expanded-cell': 1, 'is--ellipsis': expandHeight, }, style: cellStyle, }, [expandColumn.renderData(expandParams)] ), ] ), ] ) ) } if (isExpandTree) { rows.push.apply(rows, renderRows(fixedType, rowChildren, tableColumn)) } }) return rows } var scrollProcessTimeout var syncBodyScroll = function (fixedType, scrollTop, elem1, elem2) { if (elem1 || elem2) { if (elem1) { removeScrollListener(elem1) elem1.scrollTop = scrollTop } if (elem2) { removeScrollListener(elem2) elem2.scrollTop = scrollTop } clearTimeout(scrollProcessTimeout) scrollProcessTimeout = setTimeout(function () { restoreScrollListener(elem1) restoreScrollListener(elem2) tableReactData.lastScrollTime = Date.now() }, 300) } } var scrollEvent = function (evnt) { var fixedType = props2.fixedType var highlightHoverRow = tableProps2.highlightHoverRow var scrollXLoad = tableReactData.scrollXLoad, scrollYLoad = tableReactData.scrollYLoad var elemStore = tableInternalData.elemStore, lastScrollTop = tableInternalData.lastScrollTop, lastScrollLeft = tableInternalData.lastScrollLeft var rowOpts = computeRowOpts.value var tableHeader = refTableHeader.value var tableBody = refTableBody.value var tableFooter = refTableFooter.value var leftBody = refTableLeftBody.value var rightBody = refTableRightBody.value var validTip = refValidTooltip.value var scrollBodyElem = refElem.value var headerElem = tableHeader ? tableHeader.$el : null var footerElem = tableFooter ? tableFooter.$el : null var bodyElem = tableBody.$el var leftElem = leftBody ? leftBody.$el : null var rightElem = rightBody ? rightBody.$el : null var bodyYRef = elemStore['main-body-ySpace'] var bodyYElem = bodyYRef ? bodyYRef.value : null var bodyXRef = elemStore['main-body-xSpace'] var bodyXElem = bodyXRef ? bodyXRef.value : null var bodyHeight = scrollYLoad && bodyYElem ? bodyYElem.clientHeight : bodyElem.clientHeight var bodyWidth = scrollXLoad && bodyXElem ? bodyXElem.clientWidth : bodyElem.clientWidth var scrollTop = scrollBodyElem.scrollTop var scrollLeft = bodyElem.scrollLeft var isRollX = scrollLeft !== lastScrollLeft var isRollY = scrollTop !== lastScrollTop tableInternalData.lastScrollTop = scrollTop tableInternalData.lastScrollLeft = scrollLeft tableReactData.lastScrollTime = Date.now() if (rowOpts.isHover || highlightHoverRow) { $xetable.clearHoverRow() } if (leftElem && fixedType === 'left') { scrollTop = leftElem.scrollTop syncBodyScroll(fixedType, scrollTop, bodyElem, rightElem) } else if (rightElem && fixedType === 'right') { scrollTop = rightElem.scrollTop syncBodyScroll(fixedType, scrollTop, bodyElem, leftElem) } else { if (isRollX) { if (headerElem) { headerElem.scrollLeft = bodyElem.scrollLeft } if (footerElem) { footerElem.scrollLeft = bodyElem.scrollLeft } } if (leftElem || rightElem) { $xetable.checkScrolling() if (isRollY) { syncBodyScroll(fixedType, scrollTop, leftElem, rightElem) } } } if (scrollXLoad && isRollX) { $xetable.triggerScrollXEvent(evnt) } if (scrollYLoad && isRollY) { $xetable.triggerScrollYEvent(evnt) } if (isRollX && validTip && validTip.reactData.visible) { validTip.updatePlacement() } $xetable.dispatchEvent( 'scroll', { type: renderType$2, fixed: fixedType, scrollTop, scrollLeft, scrollHeight: bodyElem.scrollHeight, scrollWidth: bodyElem.scrollWidth, bodyHeight, bodyWidth, isX: isRollX, isY: isRollY, }, evnt ) } var wheelTime var wheelYSize = 0 var wheelYInterval = 0 var wheelYTotal = 0 var isPrevWheelTop = false var handleWheel = function (evnt, isTopWheel, deltaTop, isRollX, isRollY) { var elemStore = tableInternalData.elemStore var scrollXLoad = tableReactData.scrollXLoad, scrollYLoad = tableReactData.scrollYLoad var tableBody = refTableBody.value var leftBody = refTableLeftBody.value var rightBody = refTableRightBody.value var leftElem = leftBody ? leftBody.$el : null var rightElem = rightBody ? rightBody.$el : null var bodyElem = tableBody.$el var bodyYRef = elemStore['main-body-ySpace'] var bodyYElem = bodyYRef ? bodyYRef.value : null var bodyXRef = elemStore['main-body-xSpace'] var bodyXElem = bodyXRef ? bodyXRef.value : null var bodyHeight = scrollYLoad && bodyYElem ? bodyYElem.clientHeight : bodyElem.clientHeight var bodyWidth = scrollXLoad && bodyXElem ? bodyXElem.clientWidth : bodyElem.clientWidth var remainSize = isPrevWheelTop === isTopWheel ? Math.max(0, wheelYSize - wheelYTotal) : 0 isPrevWheelTop = isTopWheel wheelYSize = Math.abs( isTopWheel ? deltaTop - remainSize : deltaTop + remainSize ) wheelYInterval = 0 wheelYTotal = 0 clearTimeout(wheelTime) var handleSmooth = function () { if (wheelYTotal < wheelYSize) { var fixedType = props2.fixedType wheelYInterval = Math.max(5, Math.floor(wheelYInterval * 1.5)) wheelYTotal = wheelYTotal + wheelYInterval if (wheelYTotal > wheelYSize) { wheelYInterval = wheelYInterval - (wheelYTotal - wheelYSize) } var scrollTop = bodyElem.scrollTop, clientHeight = bodyElem.clientHeight, scrollHeight = bodyElem.scrollHeight var targerTop = scrollTop + wheelYInterval * (isTopWheel ? -1 : 1) bodyElem.scrollTop = targerTop if (leftElem) { leftElem.scrollTop = targerTop } if (rightElem) { rightElem.scrollTop = targerTop } if ( isTopWheel ? targerTop < scrollHeight - clientHeight : targerTop >= 0 ) { wheelTime = setTimeout(handleSmooth, 10) } $xetable.dispatchEvent( 'scroll', { type: renderType$2, fixed: fixedType, scrollTop: bodyElem.scrollTop, scrollLeft: bodyElem.scrollLeft, scrollHeight: bodyElem.scrollHeight, scrollWidth: bodyElem.scrollWidth, bodyHeight, bodyWidth, isX: isRollX, isY: isRollY, }, evnt ) } } handleSmooth() } var wheelEvent = function (evnt) { var deltaY = evnt.deltaY, deltaX = evnt.deltaX var highlightHoverRow = tableProps2.highlightHoverRow var scrollYLoad = tableReactData.scrollYLoad var lastScrollTop = tableInternalData.lastScrollTop, lastScrollLeft = tableInternalData.lastScrollLeft var rowOpts = computeRowOpts.value var tableBody = refTableBody.value var scrollBodyElem = refElem.value var bodyElem = tableBody.$el var deltaTop = deltaY var deltaLeft = deltaX var isTopWheel = deltaTop < 0 if ( isTopWheel ? scrollBodyElem.scrollTop <= 0 : scrollBodyElem.scrollTop >= scrollBodyElem.scrollHeight - scrollBodyElem.clientHeight ) { return } var scrollTop = scrollBodyElem.scrollTop + deltaTop var scrollLeft = bodyElem.scrollLeft + deltaLeft var isRollX = scrollLeft !== lastScrollLeft var isRollY = scrollTop !== lastScrollTop if (isRollY) { evnt.preventDefault() tableInternalData.lastScrollTop = scrollTop tableInternalData.lastScrollLeft = scrollLeft tableReactData.lastScrollTime = Date.now() if (rowOpts.isHover || highlightHoverRow) { $xetable.clearHoverRow() } handleWheel(evnt, isTopWheel, deltaTop, isRollX, isRollY) if (scrollYLoad) { $xetable.triggerScrollYEvent(evnt) } } } onMounted(function () { nextTick(function () { var fixedType = props2.fixedType var elemStore = tableInternalData.elemStore var prefix = ''.concat(fixedType || 'main', '-body-') var el2 = refElem.value elemStore[''.concat(prefix, 'wrapper')] = refElem elemStore[''.concat(prefix, 'table')] = refBodyTable elemStore[''.concat(prefix, 'colgroup')] = refBodyColgroup elemStore[''.concat(prefix, 'list')] = refBodyTBody elemStore[''.concat(prefix, 'xSpace')] = refBodyXSpace elemStore[''.concat(prefix, 'ySpace')] = refBodyYSpace elemStore[''.concat(prefix, 'emptyBlock')] = refBodyEmptyBlock el2.onscroll = scrollEvent el2._onscroll = scrollEvent }) }) onBeforeUnmount(function () { var el2 = refElem.value clearTimeout(wheelTime) if (el2) { el2._onscroll = null el2.onscroll = null } }) onUnmounted(function () { var fixedType = props2.fixedType var elemStore = tableInternalData.elemStore var prefix = ''.concat(fixedType || 'main', '-body-') elemStore[''.concat(prefix, 'wrapper')] = null elemStore[''.concat(prefix, 'table')] = null elemStore[''.concat(prefix, 'colgroup')] = null elemStore[''.concat(prefix, 'list')] = null elemStore[''.concat(prefix, 'xSpace')] = null elemStore[''.concat(prefix, 'ySpace')] = null elemStore[''.concat(prefix, 'emptyBlock')] = null }) var renderVN = function () { var fixedColumn = props2.fixedColumn, fixedType = props2.fixedType, tableColumn = props2.tableColumn var keyboardConfig = tableProps2.keyboardConfig, allColumnOverflow = tableProps2.showOverflow, spanMethod = tableProps2.spanMethod, mouseConfig = tableProps2.mouseConfig var tableData2 = tableReactData.tableData, mergeList = tableReactData.mergeList, scrollYLoad = tableReactData.scrollYLoad, isAllOverflow = tableReactData.isAllOverflow var visibleColumn = tableInternalData.visibleColumn var slots = tableContext.slots var sYOpts = computeSYOpts.value var emptyOpts = computeEmptyOpts.value var keyboardOpts = computeKeyboardOpts.value var mouseOpts = computeMouseOpts.value if (fixedType) { if ( !tableReactData.expandColumn && (scrollYLoad || (allColumnOverflow ? isAllOverflow : allColumnOverflow)) ) { if ( !mergeList.length && !spanMethod && !(keyboardConfig && keyboardOpts.isMerge) ) { tableColumn = fixedColumn } else { tableColumn = visibleColumn } } else { tableColumn = visibleColumn } } var emptyContent if (slots.empty) { emptyContent = $xetable.callSlot(slots.empty, { $table: $xetable, $grid: $xetable.xegrid, }) } else { var compConf = emptyOpts.name ? VXETable.renderer.get(emptyOpts.name) : null var renderEmpty = compConf ? compConf.renderEmpty : null if (renderEmpty) { emptyContent = getSlotVNs( renderEmpty(emptyOpts, { $table: $xetable }) ) } else { emptyContent = tableProps2.emptyText || GlobalConfig.i18n('vxe.table.emptyText') } } return h$4( 'div', __assign$3( { ref: refElem, class: [ 'vxe-table--body-wrapper', fixedType ? 'fixed-'.concat(fixedType, '--wrapper') : 'body--wrapper', ], xid: xID, }, sYOpts.mode === 'wheel' ? { onWheel: wheelEvent } : {} ), [ fixedType ? createCommentVNode() : h$4('div', { ref: refBodyXSpace, class: 'vxe-body--x-space', }), h$4('div', { ref: refBodyYSpace, class: 'vxe-body--y-space', }), h$4( 'table', { ref: refBodyTable, class: 'vxe-table--body', xid: xID, cellspacing: 0, cellpadding: 0, border: 0, }, [ h$4( 'colgroup', { ref: refBodyColgroup, }, tableColumn.map(function (column, $columnIndex) { return h$4('col', { name: column.id, key: $columnIndex, }) }) ), h$4( 'tbody', { ref: refBodyTBody, }, renderRows(fixedType, tableData2, tableColumn) ), ] ), h$4('div', { class: 'vxe-table--checkbox-range', }), mouseConfig && mouseOpts.area ? h$4( 'div', { class: 'vxe-table--cell-area', }, [ h$4( 'span', { class: 'vxe-table--cell-main-area', }, mouseOpts.extension ? [ h$4('span', { class: 'vxe-table--cell-main-area-btn', onMousedown: function (evnt) { $xetable.triggerCellExtendMousedownEvent(evnt, { $table: $xetable, fixed: fixedType, type: renderType$2, }) }, }), ] : [] ), h$4('span', { class: 'vxe-table--cell-copy-area', }), h$4('span', { class: 'vxe-table--cell-extend-area', }), h$4('span', { class: 'vxe-table--cell-multi-area', }), h$4('span', { class: 'vxe-table--cell-active-area', }), ] ) : null, !fixedType ? h$4( 'div', { class: 'vxe-table--empty-block', ref: refBodyEmptyBlock, }, [ h$4( 'div', { class: 'vxe-table--empty-content', }, emptyContent ), ] ) : null, ] ) } return renderVN }, }) var getAllColumns = function (columns, parentColumn) { var result = [] columns.forEach(function (column) { column.parentId = parentColumn ? parentColumn.id : null if (column.visible) { if ( column.children && column.children.length && column.children.some(function (column2) { return column2.visible }) ) { result.push(column) result.push.apply(result, getAllColumns(column.children, column)) } else { result.push(column) } } }) return result } var convertToRows = function (originColumns) { var maxLevel = 1 var traverse = function (column, parent2) { if (parent2) { column.level = parent2.level + 1 if (maxLevel < column.level) { maxLevel = column.level } } if ( column.children && column.children.length && column.children.some(function (column2) { return column2.visible }) ) { var colSpan_1 = 0 column.children.forEach(function (subColumn) { if (subColumn.visible) { traverse(subColumn, column) colSpan_1 += subColumn.colSpan } }) column.colSpan = colSpan_1 } else { column.colSpan = 1 } } originColumns.forEach(function (column) { column.level = 1 traverse(column) }) var rows = [] for (var i2 = 0; i2 < maxLevel; i2++) { rows.push([]) } var allColumns = getAllColumns(originColumns) allColumns.forEach(function (column) { if ( column.children && column.children.length && column.children.some(function (column2) { return column2.visible }) ) { column.rowSpan = 1 } else { column.rowSpan = maxLevel - column.level + 1 } rows[column.level - 1].push(column) }) return rows } var __assign$2 = (globalThis && globalThis.__assign) || function () { __assign$2 = Object.assign || function (t3) { for (var s2, i2 = 1, n2 = arguments.length; i2 < n2; i2++) { s2 = arguments[i2] for (var p2 in s2) if (Object.prototype.hasOwnProperty.call(s2, p2)) t3[p2] = s2[p2] } return t3 } return __assign$2.apply(this, arguments) } var renderType$1 = 'header' var VxeTableHeader = defineComponent({ name: 'VxeTableHeader', props: { tableData: Array, tableColumn: Array, tableGroupColumn: Array, fixedColumn: Array, fixedType: { type: String, default: null }, }, setup: function (props2) { var $xetable = inject('$xetable', {}) var xID = $xetable.xID, tableProps2 = $xetable.props, tableReactData = $xetable.reactData, tableInternalData = $xetable.internalData var _a2 = $xetable.getRefMaps(), tableRefElem = _a2.refElem, refTableBody = _a2.refTableBody, refLeftContainer = _a2.refLeftContainer, refRightContainer = _a2.refRightContainer, refCellResizeBar = _a2.refCellResizeBar var computeColumnOpts = $xetable.getComputeMaps().computeColumnOpts var headerColumn = ref([]) var refElem = ref() var refHeaderTable = ref() var refHeaderColgroup = ref() var refHeaderTHead = ref() var refHeaderXSpace = ref() var refHeaderBorderRepair = ref() var uploadColumn = function () { var isGroup2 = tableReactData.isGroup headerColumn.value = isGroup2 ? convertToRows(props2.tableGroupColumn) : [] } var resizeMousedown = function (evnt, params2) { var column = params2.column var fixedType = props2.fixedType var tableBody = refTableBody.value var leftContainerElem = refLeftContainer.value var rightContainerElem = refRightContainer.value var resizeBarElem = refCellResizeBar.value var dragClientX = evnt.clientX var wrapperElem = refElem.value var dragBtnElem = evnt.target var cell = (params2.cell = dragBtnElem.parentNode) var dragLeft = 0 var tableBodyElem = tableBody.$el var pos = getOffsetPos(dragBtnElem, wrapperElem) var dragBtnWidth = dragBtnElem.clientWidth var dragBtnOffsetWidth = Math.floor(dragBtnWidth / 2) var minInterval = getColReMinWidth(params2) - dragBtnOffsetWidth var dragMinLeft = pos.left - cell.clientWidth + dragBtnWidth + minInterval var dragPosLeft = pos.left + dragBtnOffsetWidth var domMousemove = document.onmousemove var domMouseup = document.onmouseup var isLeftFixed = fixedType === 'left' var isRightFixed = fixedType === 'right' var tableEl = tableRefElem.value var fixedOffsetWidth = 0 if (isLeftFixed || isRightFixed) { var siblingProp = isLeftFixed ? 'nextElementSibling' : 'previousElementSibling' var tempCellElem = cell[siblingProp] while (tempCellElem) { if (hasClass(tempCellElem, 'fixed--hidden')) { break } else if (!hasClass(tempCellElem, 'col--group')) { fixedOffsetWidth += tempCellElem.offsetWidth } tempCellElem = tempCellElem[siblingProp] } if (isRightFixed && rightContainerElem) { dragPosLeft = rightContainerElem.offsetLeft + fixedOffsetWidth } } var updateEvent = function (evnt2) { evnt2.stopPropagation() evnt2.preventDefault() var offsetX = evnt2.clientX - dragClientX var left2 = dragPosLeft + offsetX var scrollLeft = fixedType ? 0 : tableBodyElem.scrollLeft if (isLeftFixed) { left2 = Math.min( left2, (rightContainerElem ? rightContainerElem.offsetLeft : tableBodyElem.clientWidth) - fixedOffsetWidth - minInterval ) } else if (isRightFixed) { dragMinLeft = (leftContainerElem ? leftContainerElem.clientWidth : 0) + fixedOffsetWidth + minInterval left2 = Math.min(left2, dragPosLeft + cell.clientWidth - minInterval) } else { dragMinLeft = Math.max(tableBodyElem.scrollLeft, dragMinLeft) } dragLeft = Math.max(left2, dragMinLeft) resizeBarElem.style.left = ''.concat(dragLeft - scrollLeft, 'px') } tableReactData._isResize = true addClass(tableEl, 'drag--resize') resizeBarElem.style.display = 'block' document.onmousemove = updateEvent document.onmouseup = function (evnt2) { document.onmousemove = domMousemove document.onmouseup = domMouseup var resizeWidth = column.renderWidth + (isRightFixed ? dragPosLeft - dragLeft : dragLeft - dragPosLeft) column.resizeWidth = resizeWidth resizeBarElem.style.display = 'none' tableReactData._isResize = false tableInternalData._lastResizeTime = Date.now() $xetable.analyColumnWidth() $xetable.recalculate(true).then(function () { $xetable.saveCustomResizable() $xetable.updateCellAreas() $xetable.dispatchEvent( 'resizable-change', __assign$2(__assign$2({}, params2), { resizeWidth }), evnt2 ) }) removeClass(tableEl, 'drag--resize') } updateEvent(evnt) if ($xetable.closeMenu) { $xetable.closeMenu() } } watch$1(function () { return props2.tableColumn }, uploadColumn) onMounted(function () { nextTick(function () { var fixedType = props2.fixedType var internalData = $xetable.internalData var elemStore = internalData.elemStore var prefix = ''.concat(fixedType || 'main', '-header-') elemStore[''.concat(prefix, 'wrapper')] = refElem elemStore[''.concat(prefix, 'table')] = refHeaderTable elemStore[''.concat(prefix, 'colgroup')] = refHeaderColgroup elemStore[''.concat(prefix, 'list')] = refHeaderTHead elemStore[''.concat(prefix, 'xSpace')] = refHeaderXSpace elemStore[''.concat(prefix, 'repair')] = refHeaderBorderRepair uploadColumn() }) }) onUnmounted(function () { var fixedType = props2.fixedType var internalData = $xetable.internalData var elemStore = internalData.elemStore var prefix = ''.concat(fixedType || 'main', '-header-') elemStore[''.concat(prefix, 'wrapper')] = null elemStore[''.concat(prefix, 'table')] = null elemStore[''.concat(prefix, 'colgroup')] = null elemStore[''.concat(prefix, 'list')] = null elemStore[''.concat(prefix, 'xSpace')] = null elemStore[''.concat(prefix, 'repair')] = null }) var renderVN = function () { var fixedType = props2.fixedType, fixedColumn = props2.fixedColumn, tableColumn = props2.tableColumn var resizable = tableProps2.resizable, border = tableProps2.border, columnKey2 = tableProps2.columnKey, headerRowClassName = tableProps2.headerRowClassName, headerCellClassName = tableProps2.headerCellClassName, headerRowStyle2 = tableProps2.headerRowStyle, headerCellStyle = tableProps2.headerCellStyle, allColumnHeaderOverflow = tableProps2.showHeaderOverflow, allHeaderAlign = tableProps2.headerAlign, allAlign = tableProps2.align, mouseConfig = tableProps2.mouseConfig var isGroup2 = tableReactData.isGroup, currentColumn = tableReactData.currentColumn, scrollXLoad = tableReactData.scrollXLoad, overflowX = tableReactData.overflowX, scrollbarWidth = tableReactData.scrollbarWidth var visibleColumn = tableInternalData.visibleColumn var columnOpts = computeColumnOpts.value var headerGroups = headerColumn.value var renderColumnList = tableColumn if (isGroup2) { renderColumnList = visibleColumn } else { if (fixedType) { if (scrollXLoad || allColumnHeaderOverflow) { renderColumnList = fixedColumn } } headerGroups = [renderColumnList] } return h$4( 'div', { ref: refElem, class: [ 'vxe-table--header-wrapper', fixedType ? 'fixed-'.concat(fixedType, '--wrapper') : 'body--wrapper', ], xid: xID, }, [ fixedType ? createCommentVNode() : h$4('div', { ref: refHeaderXSpace, class: 'vxe-body--x-space', }), h$4( 'table', { ref: refHeaderTable, class: 'vxe-table--header', xid: xID, cellspacing: 0, cellpadding: 0, border: 0, }, [ h$4( 'colgroup', { ref: refHeaderColgroup, }, renderColumnList .map(function (column, $columnIndex) { return h$4('col', { name: column.id, key: $columnIndex, }) }) .concat( scrollbarWidth ? [ h$4('col', { name: 'col_gutter', }), ] : [] ) ), h$4( 'thead', { ref: refHeaderTHead, }, headerGroups.map(function (cols, $rowIndex) { return h$4( 'tr', { class: [ 'vxe-header--row', headerRowClassName ? xeUtils.isFunction(headerRowClassName) ? headerRowClassName({ $table: $xetable, $rowIndex, fixed: fixedType, type: renderType$1, }) : headerRowClassName : '', ], style: headerRowStyle2 ? xeUtils.isFunction(headerRowStyle2) ? headerRowStyle2({ $table: $xetable, $rowIndex, fixed: fixedType, type: renderType$1, }) : headerRowStyle2 : null, }, cols .map(function (column, $columnIndex) { var _a3 var type4 = column.type, showHeaderOverflow = column.showHeaderOverflow, headerAlign = column.headerAlign, align = column.align, headerClassName = column.headerClassName var isColGroup = column.children && column.children.length var fixedHiddenColumn = fixedType ? column.fixed !== fixedType && !isColGroup : !!column.fixed && overflowX var headOverflow = xeUtils.isUndefined(showHeaderOverflow) || xeUtils.isNull(showHeaderOverflow) ? allColumnHeaderOverflow : showHeaderOverflow var headAlign = headerAlign || align || allHeaderAlign || allAlign var showEllipsis = headOverflow === 'ellipsis' var showTitle = headOverflow === 'title' var showTooltip2 = headOverflow === true || headOverflow === 'tooltip' var hasEllipsis = showTitle || showTooltip2 || showEllipsis var hasFilter = column.filters && column.filters.some(function (item2) { return item2.checked }) var columnIndex = $xetable.getColumnIndex(column) var _columnIndex = $xetable.getVTColumnIndex(column) var params2 = { $table: $xetable, $grid: $xetable.xegrid, $rowIndex, column, columnIndex, $columnIndex, _columnIndex, fixed: fixedType, type: renderType$1, isHidden: fixedHiddenColumn, hasFilter, } var thOns = { onClick: function (evnt) { return $xetable.triggerHeaderCellClickEvent( evnt, params2 ) }, onDblclick: function (evnt) { return $xetable.triggerHeaderCellDblclickEvent( evnt, params2 ) }, } if (scrollXLoad && !hasEllipsis) { showEllipsis = hasEllipsis = true } if (mouseConfig) { thOns.onMousedown = function (evnt) { return $xetable.triggerHeaderCellMousedownEvent( evnt, params2 ) } } return h$4( 'th', __assign$2( __assign$2( { class: [ 'vxe-header--column', column.id, ((_a3 = {}), (_a3['col--'.concat(headAlign)] = headAlign), (_a3['col--'.concat(type4)] = type4), (_a3['col--last'] = $columnIndex === cols.length - 1), (_a3['col--fixed'] = column.fixed), (_a3['col--group'] = isColGroup), (_a3['col--ellipsis'] = hasEllipsis), (_a3['fixed--hidden'] = fixedHiddenColumn), (_a3['is--sortable'] = column.sortable), (_a3['col--filter'] = !!column.filters), (_a3['is--filter-active'] = hasFilter), (_a3['col--current'] = currentColumn === column), _a3), headerClassName ? xeUtils.isFunction(headerClassName) ? headerClassName(params2) : headerClassName : '', headerCellClassName ? xeUtils.isFunction(headerCellClassName) ? headerCellClassName(params2) : headerCellClassName : '', ], colid: column.id, colspan: column.colSpan > 1 ? column.colSpan : null, rowspan: column.rowSpan > 1 ? column.rowSpan : null, style: headerCellStyle ? xeUtils.isFunction(headerCellStyle) ? headerCellStyle(params2) : headerCellStyle : null, }, thOns ), { key: columnKey2 || columnOpts.useKey || isColGroup ? column.id : $columnIndex, } ), [ h$4( 'div', { class: [ 'vxe-cell', { 'c--title': showTitle, 'c--tooltip': showTooltip2, 'c--ellipsis': showEllipsis, }, ], }, column.renderHeader(params2) ), !fixedHiddenColumn && !isColGroup && (xeUtils.isBoolean(column.resizable) ? column.resizable : columnOpts.resizable || resizable) ? h$4('div', { class: [ 'vxe-resizable', { 'is--line': !border || border === 'none', }, ], onMousedown: function (evnt) { return resizeMousedown(evnt, params2) }, }) : null, ] ) }) .concat( scrollbarWidth ? [ h$4('th', { class: 'vxe-header--gutter col--gutter', }), ] : [] ) ) }) ), ] ), h$4('div', { ref: refHeaderBorderRepair, class: 'vxe-table--header-border-line', }), ] ) } return renderVN }, }) var Header$6 = Object.assign(VxeTableHeader, { install: function (app2) { app2.component(VxeTableHeader.name, VxeTableHeader) }, }) dynamicApp.component(VxeTableHeader.name, VxeTableHeader) var __assign$1 = (globalThis && globalThis.__assign) || function () { __assign$1 = Object.assign || function (t3) { for (var s2, i2 = 1, n2 = arguments.length; i2 < n2; i2++) { s2 = arguments[i2] for (var p2 in s2) if (Object.prototype.hasOwnProperty.call(s2, p2)) t3[p2] = s2[p2] } return t3 } return __assign$1.apply(this, arguments) } var renderType = 'footer' function mergeFooterMethod(mergeFooterList, _rowIndex, _columnIndex) { for (var mIndex = 0; mIndex < mergeFooterList.length; mIndex++) { var _a2 = mergeFooterList[mIndex], mergeRowIndex = _a2.row, mergeColIndex = _a2.col, mergeRowspan = _a2.rowspan, mergeColspan = _a2.colspan if ( mergeColIndex > -1 && mergeRowIndex > -1 && mergeRowspan && mergeColspan ) { if (mergeRowIndex === _rowIndex && mergeColIndex === _columnIndex) { return { rowspan: mergeRowspan, colspan: mergeColspan } } if ( _rowIndex >= mergeRowIndex && _rowIndex < mergeRowIndex + mergeRowspan && _columnIndex >= mergeColIndex && _columnIndex < mergeColIndex + mergeColspan ) { return { rowspan: 0, colspan: 0 } } } } } var VxeTableFooterComponent = defineComponent({ name: 'VxeTableFooter', props: { footerTableData: { type: Array, default: function () { return [] }, }, tableColumn: { type: Array, default: function () { return [] }, }, fixedColumn: { type: Array, default: function () { return [] }, }, fixedType: { type: String, default: null }, }, setup: function (props2) { var $xetable = inject('$xetable', {}) var xID = $xetable.xID, tableProps2 = $xetable.props, tableReactData = $xetable.reactData, tableInternalData = $xetable.internalData var _a2 = $xetable.getRefMaps(), refTableHeader = _a2.refTableHeader, refTableBody = _a2.refTableBody, refValidTooltip = _a2.refValidTooltip var _b2 = $xetable.getComputeMaps(), computeTooltipOpts = _b2.computeTooltipOpts, computeColumnOpts = _b2.computeColumnOpts var refElem = ref() var refFooterTable = ref() var refFooterColgroup = ref() var refFooterTFoot = ref() var refFooterXSpace = ref() var scrollEvent = function (evnt) { var fixedType = props2.fixedType var scrollXLoad = tableReactData.scrollXLoad var lastScrollLeft = tableInternalData.lastScrollLeft var validTip = refValidTooltip.value var tableHeader = refTableHeader.value var tableBody = refTableBody.value var headerElem = tableHeader ? tableHeader.$el : null var footerElem = refElem.value var bodyElem = tableBody.$el var scrollLeft = footerElem.scrollLeft var isX = scrollLeft !== lastScrollLeft tableInternalData.lastScrollLeft = scrollLeft tableReactData.lastScrollTime = Date.now() if (headerElem) { headerElem.scrollLeft = scrollLeft } if (bodyElem) { bodyElem.scrollLeft = scrollLeft } if (scrollXLoad && isX) { $xetable.triggerScrollXEvent(evnt) } if (isX && validTip && validTip.reactData.visible) { validTip.updatePlacement() } $xetable.dispatchEvent( 'scroll', { type: renderType, fixed: fixedType, scrollTop: bodyElem.scrollTop, scrollLeft, isX, isY: false, }, evnt ) } onMounted(function () { nextTick(function () { var fixedType = props2.fixedType var elemStore = tableInternalData.elemStore var prefix = ''.concat(fixedType || 'main', '-footer-') elemStore[''.concat(prefix, 'wrapper')] = refElem elemStore[''.concat(prefix, 'table')] = refFooterTable elemStore[''.concat(prefix, 'colgroup')] = refFooterColgroup elemStore[''.concat(prefix, 'list')] = refFooterTFoot elemStore[''.concat(prefix, 'xSpace')] = refFooterXSpace }) }) onUnmounted(function () { var fixedType = props2.fixedType var elemStore = tableInternalData.elemStore var prefix = ''.concat(fixedType || 'main', '-footer-') elemStore[''.concat(prefix, 'wrapper')] = null elemStore[''.concat(prefix, 'table')] = null elemStore[''.concat(prefix, 'colgroup')] = null elemStore[''.concat(prefix, 'list')] = null elemStore[''.concat(prefix, 'xSpace')] = null }) var renderVN = function () { var fixedType = props2.fixedType, fixedColumn = props2.fixedColumn, tableColumn = props2.tableColumn, footerTableData = props2.footerTableData var footerRowClassName = tableProps2.footerRowClassName, footerCellClassName = tableProps2.footerCellClassName, footerRowStyle = tableProps2.footerRowStyle, footerCellStyle = tableProps2.footerCellStyle, allFooterAlign = tableProps2.footerAlign, footerSpanMethod = tableProps2.footerSpanMethod, allAlign = tableProps2.align, columnKey2 = tableProps2.columnKey, allColumnFooterOverflow = tableProps2.showFooterOverflow var visibleColumn = tableInternalData.visibleColumn var scrollXLoad = tableReactData.scrollXLoad, overflowX = tableReactData.overflowX, scrollbarWidth = tableReactData.scrollbarWidth, currentColumn = tableReactData.currentColumn, mergeFooterList = tableReactData.mergeFooterList var tooltipOpts = computeTooltipOpts.value var columnOpts = computeColumnOpts.value if (fixedType) { if ( !tableReactData.expandColumn && (scrollXLoad || allColumnFooterOverflow) ) { if (!mergeFooterList.length || !footerSpanMethod) { tableColumn = fixedColumn } else { tableColumn = visibleColumn } } else { tableColumn = visibleColumn } } return h$4( 'div', { ref: refElem, class: [ 'vxe-table--footer-wrapper', fixedType ? 'fixed-'.concat(fixedType, '--wrapper') : 'body--wrapper', ], xid: xID, onScroll: scrollEvent, }, [ fixedType ? createCommentVNode() : h$4('div', { ref: refFooterXSpace, class: 'vxe-body--x-space', }), h$4( 'table', { ref: refFooterTable, class: 'vxe-table--footer', xid: xID, cellspacing: 0, cellpadding: 0, border: 0, }, [ h$4( 'colgroup', { ref: refFooterColgroup, }, tableColumn .map(function (column, $columnIndex) { return h$4('col', { name: column.id, key: $columnIndex, }) }) .concat( scrollbarWidth ? [ h$4('col', { name: 'col_gutter', }), ] : [] ) ), h$4( 'tfoot', { ref: refFooterTFoot, }, footerTableData.map(function (list2, _rowIndex) { var $rowIndex = _rowIndex return h$4( 'tr', { class: [ 'vxe-footer--row', footerRowClassName ? xeUtils.isFunction(footerRowClassName) ? footerRowClassName({ $table: $xetable, _rowIndex, $rowIndex, fixed: fixedType, type: renderType, }) : footerRowClassName : '', ], style: footerRowStyle ? xeUtils.isFunction(footerRowStyle) ? footerRowStyle({ $table: $xetable, _rowIndex, $rowIndex, fixed: fixedType, type: renderType, }) : footerRowStyle : null, }, tableColumn .map(function (column, $columnIndex) { var _a3 var type4 = column.type, showFooterOverflow = column.showFooterOverflow, footerAlign = column.footerAlign, align = column.align, footerClassName = column.footerClassName var showAllTip = tooltipOpts.showAll var isColGroup = column.children && column.children.length var fixedHiddenColumn = fixedType ? column.fixed !== fixedType && !isColGroup : column.fixed && overflowX var footOverflow = xeUtils.isUndefined(showFooterOverflow) || xeUtils.isNull(showFooterOverflow) ? allColumnFooterOverflow : showFooterOverflow var footAlign = footerAlign || align || allFooterAlign || allAlign var showEllipsis = footOverflow === 'ellipsis' var showTitle = footOverflow === 'title' var showTooltip2 = footOverflow === true || footOverflow === 'tooltip' var hasEllipsis = showTitle || showTooltip2 || showEllipsis var attrs = { colid: column.id } var tfOns = {} var columnIndex = $xetable.getColumnIndex(column) var _columnIndex = $xetable.getVTColumnIndex(column) var itemIndex = _columnIndex var params2 = { $table: $xetable, $grid: $xetable.xegrid, _rowIndex, $rowIndex, column, columnIndex, $columnIndex, _columnIndex, itemIndex, items: list2, fixed: fixedType, type: renderType, data: footerTableData, } if (scrollXLoad && !hasEllipsis) { showEllipsis = hasEllipsis = true } if (showTitle || showTooltip2 || showAllTip) { tfOns.onMouseenter = function (evnt) { if (showTitle) { updateCellTitle(evnt.currentTarget, column) } else if (showTooltip2 || showAllTip) { $xetable.triggerFooterTooltipEvent(evnt, params2) } } } if (showTooltip2 || showAllTip) { tfOns.onMouseleave = function (evnt) { if (showTooltip2 || showAllTip) { $xetable.handleTargetLeaveEvent(evnt) } } } tfOns.onClick = function (evnt) { $xetable.dispatchEvent( 'footer-cell-click', Object.assign( { cell: evnt.currentTarget }, params2 ), evnt ) } tfOns.onDblclick = function (evnt) { $xetable.dispatchEvent( 'footer-cell-dblclick', Object.assign( { cell: evnt.currentTarget }, params2 ), evnt ) } if (mergeFooterList.length) { var spanRest = mergeFooterMethod( mergeFooterList, _rowIndex, _columnIndex ) if (spanRest) { var rowspan = spanRest.rowspan, colspan = spanRest.colspan if (!rowspan || !colspan) { return null } if (rowspan > 1) { attrs.rowspan = rowspan } if (colspan > 1) { attrs.colspan = colspan } } } else if (footerSpanMethod) { var _b3 = footerSpanMethod(params2) || {}, _c2 = _b3.rowspan, rowspan = _c2 === void 0 ? 1 : _c2, _d = _b3.colspan, colspan = _d === void 0 ? 1 : _d if (!rowspan || !colspan) { return null } if (rowspan > 1) { attrs.rowspan = rowspan } if (colspan > 1) { attrs.colspan = colspan } } return h$4( 'td', __assign$1( __assign$1( __assign$1( __assign$1( { class: [ 'vxe-footer--column', column.id, ((_a3 = {}), (_a3['col--'.concat(footAlign)] = footAlign), (_a3['col--'.concat(type4)] = type4), (_a3['col--last'] = $columnIndex === tableColumn.length - 1), (_a3['fixed--hidden'] = fixedHiddenColumn), (_a3['col--ellipsis'] = hasEllipsis), (_a3['col--current'] = currentColumn === column), _a3), getPropClass(footerClassName, params2), getPropClass( footerCellClassName, params2 ), ], }, attrs ), { style: footerCellStyle ? xeUtils.isFunction(footerCellStyle) ? footerCellStyle(params2) : footerCellStyle : null, } ), tfOns ), { key: columnKey2 || columnOpts.useKey ? column.id : $columnIndex, } ), [ h$4( 'div', { class: [ 'vxe-cell', { 'c--title': showTitle, 'c--tooltip': showTooltip2, 'c--ellipsis': showEllipsis, }, ], }, column.renderFooter(params2) ), ] ) }) .concat( scrollbarWidth ? [ h$4('td', { class: 'vxe-footer--gutter col--gutter', }), ] : [] ) ) }) ), ] ), ] ) } return renderVN }, }) var Footer$2 = Object.assign(VxeTableFooterComponent, { install: function (app2) { app2.component(VxeTableFooterComponent.name, VxeTableFooterComponent) }, }) dynamicApp.component(VxeTableFooterComponent.name, VxeTableFooterComponent) var __assign = (globalThis && globalThis.__assign) || function () { __assign = Object.assign || function (t3) { for (var s2, i2 = 1, n2 = arguments.length; i2 < n2; i2++) { s2 = arguments[i2] for (var p2 in s2) if (Object.prototype.hasOwnProperty.call(s2, p2)) t3[p2] = s2[p2] } return t3 } return __assign.apply(this, arguments) } var __spreadArray = (globalThis && globalThis.__spreadArray) || function (to, from, pack2) { if (pack2 || arguments.length === 2) for (var i2 = 0, l2 = from.length, ar2; i2 < l2; i2++) { if (ar2 || !(i2 in from)) { if (!ar2) ar2 = Array.prototype.slice.call(from, 0, i2) ar2[i2] = from[i2] } } return to.concat(ar2 || Array.prototype.slice.call(from)) } var isWebkit = browse['-webkit'] && !browse.edge var resizableStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_WIDTH' var visibleStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_VISIBLE' var fixedStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_FIXED' var orderStorageKey = 'VXE_TABLE_CUSTOM_COLUMN_ORDER' var VxeTableComponent = defineComponent({ name: 'VxeTable', props: tableProps, emits: tableEmits, setup: function (props2, context2) { var slots = context2.slots, emit2 = context2.emit var hasUseTooltip = VXETable.tooltip var xID = xeUtils.uniqueId() var computeSize = useSize(props2) var instance = getCurrentInstance() var reactData = reactive({ staticColumns: [], tableGroupColumn: [], tableColumn: [], tableData: [], scrollXLoad: false, scrollYLoad: false, overflowY: true, overflowX: false, scrollbarWidth: 0, scrollbarHeight: 0, lastScrollTime: 0, rowHeight: 0, parentHeight: 0, isGroup: false, isAllOverflow: false, isAllSelected: false, isIndeterminate: false, selectCheckboxMaps: {}, currentRow: null, currentColumn: null, selectRadioRow: null, footerTableData: [], expandColumn: null, treeNodeColumn: null, hasFixedColumn: false, rowExpandedMaps: {}, rowExpandLazyLoadedMaps: {}, treeExpandedMaps: {}, treeExpandLazyLoadedMaps: {}, treeIndeterminateMaps: {}, mergeList: [], mergeFooterList: [], upDataFlag: 0, reColumnFlag: 0, initStore: { filter: false, import: false, export: false, }, filterStore: { isAllSelected: false, isIndeterminate: false, style: null, options: [], column: null, multiple: false, visible: false, maxHeight: null, }, columnStore: { leftList: [], centerList: [], rightList: [], resizeList: [], pxList: [], pxMinList: [], scaleList: [], scaleMinList: [], autoList: [], }, ctxMenuStore: { selected: null, visible: false, showChild: false, selectChild: null, list: [], style: null, }, editStore: { indexs: { columns: [], }, titles: { columns: [], }, selected: { row: null, column: null, }, copyed: { cut: false, rows: [], columns: [], }, actived: { row: null, column: null, }, insertMaps: {}, removeMaps: {}, }, tooltipStore: { row: null, column: null, content: null, visible: false, currOpts: null, }, validStore: { visible: false, }, validErrorMaps: {}, importStore: { inited: false, file: null, type: '', modeList: [], typeList: [], filename: '', visible: false, }, importParams: { mode: '', types: null, message: true, }, exportStore: { inited: false, name: '', modeList: [], typeList: [], columns: [], isPrint: false, hasFooter: false, hasMerge: false, hasTree: false, hasColgroup: false, visible: false, }, exportParams: { filename: '', sheetName: '', mode: '', type: '', isColgroup: false, isMerge: false, isAllExpand: false, useStyle: false, original: false, message: true, isHeader: false, isFooter: false, }, scrollVMLoading: false, _isResize: false, }) var internalData = { tZindex: 0, elemStore: {}, scrollXStore: { offsetSize: 0, visibleSize: 0, startIndex: 0, endIndex: 0, }, scrollYStore: { rowHeight: 0, offsetSize: 0, visibleSize: 0, startIndex: 0, endIndex: 0, }, tableWidth: 0, tableHeight: 0, headerHeight: 0, footerHeight: 0, customHeight: 0, customMinHeight: 0, customMaxHeight: 0, hoverRow: null, lastScrollLeft: 0, lastScrollTop: 0, radioReserveRow: null, checkboxReserveRowMap: {}, rowExpandedReserveRowMap: {}, treeExpandedReserveRowMap: {}, treeIndeterminateRowMaps: {}, tableFullData: [], afterFullData: [], afterTreeFullData: [], afterFullRowMaps: {}, tableFullTreeData: [], tableSynchData: [], tableSourceData: [], collectColumn: [], tableFullColumn: [], visibleColumn: [], fullAllDataRowIdData: {}, sourceDataRowIdData: {}, fullDataRowIdData: {}, fullColumnIdData: {}, fullColumnFieldData: {}, inited: false, tooltipTimeout: null, initStatus: false, isActivated: false, } var tableMethods = {} var tablePrivateMethods = {} var refElem = ref() var refTooltip = ref() var refCommTooltip = ref() var refValidTooltip = ref() var refTableFilter = ref() var refTableMenu = ref() var refTableHeader = ref() var refTableBody = ref() var refTableFooter = ref() var refTableLeftHeader = ref() var refTableLeftBody = ref() var refTableLeftFooter = ref() var refTableRightHeader = ref() var refTableRightBody = ref() var refTableRightFooter = ref() var refLeftContainer = ref() var refRightContainer = ref() var refCellResizeBar = ref() var refEmptyPlaceholder = ref() var $xegrid = inject('$xegrid', null) var $xetoolbar var computeValidOpts = computed(function () { return Object.assign( {}, GlobalConfig.table.validConfig, props2.validConfig ) }) var computeSXOpts = computed(function () { return Object.assign({}, GlobalConfig.table.scrollX, props2.scrollX) }) var computeSYOpts = computed(function () { return Object.assign({}, GlobalConfig.table.scrollY, props2.scrollY) }) var computeRowHeightMaps = computed(function () { return { default: 48, medium: 44, small: 40, mini: 36, } }) var computeColumnOpts = computed(function () { return Object.assign( {}, GlobalConfig.table.columnConfig, props2.columnConfig ) }) var computeRowOpts = computed(function () { return Object.assign({}, GlobalConfig.table.rowConfig, props2.rowConfig) }) var computeResizeleOpts = computed(function () { return Object.assign( {}, GlobalConfig.table.resizeConfig, props2.resizeConfig ) }) var computeResizableOpts = computed(function () { return Object.assign( {}, GlobalConfig.table.resizableConfig, props2.resizableConfig ) }) var computeSeqOpts = computed(function () { return Object.assign( { startIndex: 0 }, GlobalConfig.table.seqConfig, props2.seqConfig ) }) var computeRadioOpts = computed(function () { return Object.assign( {}, GlobalConfig.table.radioConfig, props2.radioConfig ) }) var computeCheckboxOpts = computed(function () { return Object.assign( {}, GlobalConfig.table.checkboxConfig, props2.checkboxConfig ) }) var computeTooltipOpts = ref() computeTooltipOpts = computed(function () { return Object.assign( {}, GlobalConfig.tooltip, GlobalConfig.table.tooltipConfig, props2.tooltipConfig ) }) var computeTipConfig = computed(function () { var tooltipStore = reactData.tooltipStore var tooltipOpts = computeTooltipOpts.value return __assign(__assign({}, tooltipOpts), tooltipStore.currOpts) }) var computeValidTipOpts = computed(function () { var tooltipOpts = computeTooltipOpts.value return Object.assign({ isArrow: false }, tooltipOpts) }) var computeEditOpts = computed(function () { return Object.assign({}, GlobalConfig.table.editConfig, props2.editConfig) }) var computeSortOpts = computed(function () { return Object.assign( { orders: ['asc', 'desc', null] }, GlobalConfig.table.sortConfig, props2.sortConfig ) }) var computeFilterOpts = computed(function () { return Object.assign( {}, GlobalConfig.table.filterConfig, props2.filterConfig ) }) var computeMouseOpts = computed(function () { return Object.assign( {}, GlobalConfig.table.mouseConfig, props2.mouseConfig ) }) var computeAreaOpts = computed(function () { return Object.assign({}, GlobalConfig.table.areaConfig, props2.areaConfig) }) var computeKeyboardOpts = computed(function () { return Object.assign( {}, GlobalConfig.table.keyboardConfig, props2.keyboardConfig ) }) var computeClipOpts = computed(function () { return Object.assign({}, GlobalConfig.table.clipConfig, props2.clipConfig) }) var computeFNROpts = computed(function () { return Object.assign({}, GlobalConfig.table.fnrConfig, props2.fnrConfig) }) var computeMenuOpts = computed(function () { return Object.assign({}, GlobalConfig.table.menuConfig, props2.menuConfig) }) var computeHeaderMenu = computed(function () { var menuOpts = computeMenuOpts.value var headerOpts = menuOpts.header return headerOpts && headerOpts.options ? headerOpts.options : [] }) var computeBodyMenu = computed(function () { var menuOpts = computeMenuOpts.value var bodyOpts = menuOpts.body return bodyOpts && bodyOpts.options ? bodyOpts.options : [] }) var computeFooterMenu = computed(function () { var menuOpts = computeMenuOpts.value var footerOpts = menuOpts.footer return footerOpts && footerOpts.options ? footerOpts.options : [] }) var computeIsMenu = computed(function () { var menuOpts = computeMenuOpts.value var headerMenu = computeHeaderMenu.value var bodyMenu = computeBodyMenu.value var footerMenu = computeFooterMenu.value return !!( props2.menuConfig && isEnableConf(menuOpts) && (headerMenu.length || bodyMenu.length || footerMenu.length) ) }) var computeMenuList = computed(function () { var ctxMenuStore = reactData.ctxMenuStore var rest = [] ctxMenuStore.list.forEach(function (list2) { list2.forEach(function (item2) { rest.push(item2) }) }) return rest }) var computeExportOpts = computed(function () { return Object.assign( {}, GlobalConfig.table.exportConfig, props2.exportConfig ) }) var computeImportOpts = computed(function () { return Object.assign( {}, GlobalConfig.table.importConfig, props2.importConfig ) }) var computePrintOpts = computed(function () { return Object.assign( {}, GlobalConfig.table.printConfig, props2.printConfig ) }) var computeExpandOpts = computed(function () { return Object.assign( {}, GlobalConfig.table.expandConfig, props2.expandConfig ) }) var computeTreeOpts = computed(function () { return Object.assign({}, GlobalConfig.table.treeConfig, props2.treeConfig) }) var computeEmptyOpts = computed(function () { return Object.assign( {}, GlobalConfig.table.emptyRender, props2.emptyRender ) }) var computeLoadingOpts = computed(function () { return Object.assign( {}, GlobalConfig.table.loadingConfig, props2.loadingConfig ) }) var computeCellOffsetWidth = computed(function () { return props2.border ? Math.max( 2, Math.ceil(reactData.scrollbarWidth / reactData.tableColumn.length) ) : 1 }) var computeCustomOpts = computed(function () { return Object.assign( {}, GlobalConfig.table.customConfig, props2.customConfig ) }) var computeFixedColumnSize = computed(function () { var tableFullColumn = internalData.tableFullColumn var fixedSize = 0 tableFullColumn.forEach(function (column) { if (column.fixed) { fixedSize++ } }) return fixedSize }) var computeIsMaxFixedColumn = computed(function () { var fixedColumnSize = computeFixedColumnSize.value var columnOpts = computeColumnOpts.value var maxFixedSize = columnOpts.maxFixedSize if (maxFixedSize) { return fixedColumnSize >= maxFixedSize } return false }) var computeTableBorder = computed(function () { var border = props2.border if (border === true) { return 'full' } if (border) { return border } return 'default' }) var computeIsAllCheckboxDisabled = computed(function () { props2.treeConfig var tableData2 = reactData.tableData var tableFullData = internalData.tableFullData var checkboxOpts = computeCheckboxOpts.value var strict = checkboxOpts.strict, checkMethod = checkboxOpts.checkMethod if (strict) { if (tableData2.length || tableFullData.length) { if (checkMethod) { return tableFullData.every(function (row) { return !checkMethod({ row }) }) } return false } return true } return false }) var refMaps = { refElem, refTooltip, refValidTooltip, refTableFilter, refTableMenu, refTableHeader, refTableBody, refTableFooter, refTableLeftHeader, refTableLeftBody, refTableLeftFooter, refTableRightHeader, refTableRightBody, refTableRightFooter, refLeftContainer, refRightContainer, refCellResizeBar, } var computeMaps = { computeSize, computeValidOpts, computeSXOpts, computeSYOpts, computeColumnOpts, computeRowOpts, computeResizeleOpts, computeResizableOpts, computeSeqOpts, computeRadioOpts, computeCheckboxOpts, computeTooltipOpts, computeEditOpts, computeSortOpts, computeFilterOpts, computeMouseOpts, computeAreaOpts, computeKeyboardOpts, computeClipOpts, computeFNROpts, computeHeaderMenu, computeBodyMenu, computeFooterMenu, computeIsMenu, computeMenuOpts, computeExportOpts, computeImportOpts, computePrintOpts, computeExpandOpts, computeTreeOpts, computeEmptyOpts, computeLoadingOpts, computeCustomOpts, computeFixedColumnSize, computeIsMaxFixedColumn, computeIsAllCheckboxDisabled, } var $xetable = { xID, props: props2, context: context2, instance, reactData, internalData, getRefMaps: function () { return refMaps }, getComputeMaps: function () { return computeMaps }, xegrid: $xegrid, } var eqCellValue = function (row1, row2, field2) { var val1 = xeUtils.get(row1, field2) var val2 = xeUtils.get(row2, field2) if (eqEmptyValue(val1) && eqEmptyValue(val2)) { return true } if (xeUtils.isString(val1) || xeUtils.isNumber(val1)) { return '' + val1 === '' + val2 } return xeUtils.isEqual(val1, val2) } var getNextSortOrder = function (column) { var sortOpts = computeSortOpts.value var orders = sortOpts.orders var currOrder = column.order || null var oIndex = orders.indexOf(currOrder) + 1 return orders[oIndex < orders.length ? oIndex : 0] } var getCustomStorageMap = function (key2) { var version2 = GlobalConfig.version var rest = xeUtils.toStringJSON(localStorage.getItem(key2) || '') return rest && rest._v === version2 ? rest : { _v: version2 } } var getRecoverRowMaps = function (keyMaps) { var fullAllDataRowIdData = internalData.fullAllDataRowIdData var restKeys = {} xeUtils.each(keyMaps, function (row, rowid) { if (fullAllDataRowIdData[rowid]) { restKeys[rowid] = row } }) return restKeys } var handleReserveRow = function (reserveRowMap) { var fullDataRowIdData = internalData.fullDataRowIdData var reserveList = [] xeUtils.each(reserveRowMap, function (item2, rowid) { if ( fullDataRowIdData[rowid] && $xetable.findRowIndexOf(reserveList, fullDataRowIdData[rowid].row) === -1 ) { reserveList.push(fullDataRowIdData[rowid].row) } }) return reserveList } var computeVirtualX = function () { var visibleColumn = internalData.visibleColumn var tableBody = refTableBody.value var tableBodyElem = tableBody ? tableBody.$el : null if (tableBodyElem) { var scrollLeft = tableBodyElem.scrollLeft, clientWidth = tableBodyElem.clientWidth var endWidth = scrollLeft + clientWidth var toVisibleIndex = -1 var cWidth = 0 var visibleSize = 0 for ( var colIndex = 0, colLen = visibleColumn.length; colIndex < colLen; colIndex++ ) { cWidth += visibleColumn[colIndex].renderWidth if (toVisibleIndex === -1 && scrollLeft < cWidth) { toVisibleIndex = colIndex } if (toVisibleIndex >= 0) { visibleSize++ if (cWidth > endWidth) { break } } } return { toVisibleIndex: Math.max(0, toVisibleIndex), visibleSize: Math.max(8, visibleSize), } } return { toVisibleIndex: 0, visibleSize: 8 } } var computeVirtualY = function () { var tableHeader = refTableHeader.value var tableBody = refTableBody.value var tableBodyElem = tableBody ? tableBody.$el : null var vSize = computeSize.value var rowHeightMaps = computeRowHeightMaps.value if (tableBodyElem) { var tableHeaderElem = tableHeader ? tableHeader.$el : null var rowHeight = 0 var firstTrElem = void 0 firstTrElem = tableBodyElem.querySelector('tr') if (!firstTrElem && tableHeaderElem) { firstTrElem = tableHeaderElem.querySelector('tr') } if (firstTrElem) { rowHeight = firstTrElem.clientHeight } if (!rowHeight) { rowHeight = rowHeightMaps[vSize || 'default'] } var visibleSize = Math.max( 8, Math.ceil(tableBodyElem.clientHeight / rowHeight) + 2 ) return { rowHeight, visibleSize } } return { rowHeight: 0, visibleSize: 8 } } var calculateMergerOffserIndex = function (list2, offsetItem, type4) { for (var mcIndex = 0, len2 = list2.length; mcIndex < len2; mcIndex++) { var mergeItem = list2[mcIndex] var startIndex = offsetItem.startIndex, endIndex = offsetItem.endIndex var mergeStartIndex = mergeItem[type4] var mergeSpanNumber = mergeItem[type4 + 'span'] var mergeEndIndex = mergeStartIndex + mergeSpanNumber if (mergeStartIndex < startIndex && startIndex < mergeEndIndex) { offsetItem.startIndex = mergeStartIndex } if (mergeStartIndex < endIndex && endIndex < mergeEndIndex) { offsetItem.endIndex = mergeEndIndex } if ( offsetItem.startIndex !== startIndex || offsetItem.endIndex !== endIndex ) { mcIndex = -1 } } } var setMerges = function (merges, mList, rowList) { if (merges) { var treeConfig = props2.treeConfig var visibleColumn_1 = internalData.visibleColumn if (!xeUtils.isArray(merges)) { merges = [merges] } if (treeConfig && merges.length) { errLog('vxe.error.noTree', ['merge-cells | merge-footer-items']) } merges.forEach(function (item2) { var row = item2.row, col = item2.col, rowspan = item2.rowspan, colspan = item2.colspan if (rowList && xeUtils.isNumber(row)) { row = rowList[row] } if (xeUtils.isNumber(col)) { col = visibleColumn_1[col] } if ( (rowList ? row : xeUtils.isNumber(row)) && col && (rowspan || colspan) ) { rowspan = xeUtils.toNumber(rowspan) || 1 colspan = xeUtils.toNumber(colspan) || 1 if (rowspan > 1 || colspan > 1) { var mcIndex = xeUtils.findIndexOf(mList, function (item3) { return ( (item3._row === row || getRowid($xetable, item3._row) === getRowid($xetable, row)) && (item3._col.id === col || item3._col.id === col.id) ) }) var mergeItem = mList[mcIndex] if (mergeItem) { mergeItem.rowspan = rowspan mergeItem.colspan = colspan mergeItem._rowspan = rowspan mergeItem._colspan = colspan } else { var mergeRowIndex = rowList ? $xetable.findRowIndexOf(rowList, row) : row var mergeColIndex = tableMethods.getVTColumnIndex(col) mList.push({ row: mergeRowIndex, col: mergeColIndex, rowspan, colspan, _row: row, _col: col, _rowspan: rowspan, _colspan: colspan, }) } } } }) } } var removeMerges = function (merges, mList, rowList) { var rest = [] if (merges) { var treeConfig = props2.treeConfig var visibleColumn_2 = internalData.visibleColumn if (!xeUtils.isArray(merges)) { merges = [merges] } if (treeConfig && merges.length) { errLog('vxe.error.noTree', ['merge-cells | merge-footer-items']) } merges.forEach(function (item2) { var row = item2.row, col = item2.col if (rowList && xeUtils.isNumber(row)) { row = rowList[row] } if (xeUtils.isNumber(col)) { col = visibleColumn_2[col] } var mcIndex = xeUtils.findIndexOf(mList, function (item3) { return ( (item3._row === row || getRowid($xetable, item3._row) === getRowid($xetable, row)) && (item3._col.id === col || item3._col.id === col.id) ) }) if (mcIndex > -1) { var rItems = mList.splice(mcIndex, 1) rest.push(rItems[0]) } }) } return rest } var clearAllSort = function () { var tableFullColumn = internalData.tableFullColumn tableFullColumn.forEach(function (column) { column.order = null }) } var calcHeight = function (key2) { var parentHeight = reactData.parentHeight var val2 = props2[key2] var num2 = 0 if (val2) { if (val2 === 'auto') { num2 = parentHeight } else { var excludeHeight = $xetable.getExcludeHeight() if (isScale(val2)) { num2 = Math.floor( ((xeUtils.toInteger(val2) || 1) / 100) * parentHeight ) } else { num2 = xeUtils.toNumber(val2) } num2 = Math.max(40, num2 - excludeHeight) } } return num2 } var restoreCustomStorage = function () { var id2 = props2.id, customConfig = props2.customConfig var collectColumn = internalData.collectColumn var customOpts = computeCustomOpts.value var storage2 = customOpts.storage var isCustomResizable = storage2 === true || (storage2 && storage2.resizable) var isCustomVisible = storage2 === true || (storage2 && storage2.visible) var isCustomFixed = storage2 === true || (storage2 && storage2.fixed) var isCustomOrder = storage2 === true || (storage2 && storage2.order) if ( customConfig && (isCustomResizable || isCustomVisible || isCustomFixed || isCustomOrder) ) { var customMap_1 = {} if (!id2) { errLog('vxe.error.reqProp', ['id']) return } if (isCustomResizable) { var columnWidthStorage = getCustomStorageMap(resizableStorageKey)[id2] if (columnWidthStorage) { xeUtils.each(columnWidthStorage, function (resizeWidth, colKey) { customMap_1[colKey] = { resizeWidth } }) } } if (isCustomFixed) { var columnFixedStorage = getCustomStorageMap(fixedStorageKey)[id2] if (columnFixedStorage) { var colFixeds = columnFixedStorage.split(',') colFixeds.forEach(function (fixConf) { var _a2 = fixConf.split('|'), colKey = _a2[0], fixed = _a2[1] if (customMap_1[colKey]) { customMap_1[colKey].fixed = fixed } else { customMap_1[colKey] = { fixed } } }) } } if (isCustomOrder) { getCustomStorageMap(orderStorageKey)[id2] } if (isCustomVisible) { var columnVisibleStorage = getCustomStorageMap(visibleStorageKey)[id2] if (columnVisibleStorage) { var colVisibles = columnVisibleStorage.split('|') var colHides = colVisibles[0] ? colVisibles[0].split(',') : [] var colShows = colVisibles[1] ? colVisibles[1].split(',') : [] colHides.forEach(function (colKey) { if (customMap_1[colKey]) { customMap_1[colKey].visible = false } else { customMap_1[colKey] = { visible: false } } }) colShows.forEach(function (colKey) { if (customMap_1[colKey]) { customMap_1[colKey].visible = true } else { customMap_1[colKey] = { visible: true } } }) } } var keyMap_1 = {} xeUtils.eachTree(collectColumn, function (column) { var colKey = column.getKey() if (colKey) { keyMap_1[colKey] = column } }) xeUtils.each(customMap_1, function (_a2, colKey) { var visible = _a2.visible, resizeWidth = _a2.resizeWidth, fixed = _a2.fixed, order2 = _a2.order var column = keyMap_1[colKey] if (column) { if (xeUtils.isNumber(resizeWidth)) { column.resizeWidth = resizeWidth } if (xeUtils.isBoolean(visible)) { column.visible = visible } if (fixed) { column.fixed = fixed } if (order2) { column.customOrder = order2 } } }) } } var cacheColumnMap = function () { var tableFullColumn = internalData.tableFullColumn, collectColumn = internalData.collectColumn var fullColumnIdData = (internalData.fullColumnIdData = {}) var fullColumnFieldData = (internalData.fullColumnFieldData = {}) computeMouseOpts.value computeColumnOpts.value computeRowOpts.value var isGroup2 = collectColumn.some(hasChildrenList) var isAllOverflow = !!props2.showOverflow var expandColumn var treeNodeColumn var handleFunc = function (column, index2, items, path, parent2) { var colid = column.id, field2 = column.field column.fixed var type4 = column.type, treeNode = column.treeNode var rest = { column, colid, index: index2, items, parent: parent2 } if (field2) { fullColumnFieldData[field2] = rest } if (treeNode) { if (!treeNodeColumn) { treeNodeColumn = column } } else if (type4 === 'expand') { if (!expandColumn) { expandColumn = column } } if (isAllOverflow && column.showOverflow === false) { isAllOverflow = false } if (fullColumnIdData[colid]) { errLog('vxe.error.colRepet', ['colId', colid]) } fullColumnIdData[colid] = rest } if (isGroup2) { xeUtils.eachTree( collectColumn, function (column, index2, items, path, parent2, nodes) { column.level = nodes.length handleFunc(column, index2, items, path, parent2) } ) } else { tableFullColumn.forEach(handleFunc) } reactData.isGroup = isGroup2 reactData.treeNodeColumn = treeNodeColumn reactData.expandColumn = expandColumn reactData.isAllOverflow = isAllOverflow } var updateHeight = function () { internalData.customHeight = calcHeight('height') internalData.customMinHeight = calcHeight('minHeight') internalData.customMaxHeight = calcHeight('maxHeight') } var autoCellWidth = function () { var tableHeader = refTableHeader.value var tableBody = refTableBody.value var tableFooter = refTableFooter.value var bodyElem = tableBody ? tableBody.$el : null var headerElem = tableHeader ? tableHeader.$el : null var footerElem = tableFooter ? tableFooter.$el : null if (!bodyElem) { return } var tableWidth = 0 var minCellWidth = 40 var bodyWidth = bodyElem.clientWidth - 1 var remainWidth = bodyWidth var meanWidth = remainWidth / 100 var fit = props2.fit var columnStore = reactData.columnStore var resizeList = columnStore.resizeList, pxMinList = columnStore.pxMinList, pxList = columnStore.pxList, scaleList = columnStore.scaleList, scaleMinList = columnStore.scaleMinList, autoList = columnStore.autoList pxMinList.forEach(function (column) { var minWidth = xeUtils.toInteger(column.minWidth) tableWidth += minWidth column.renderWidth = minWidth }) scaleMinList.forEach(function (column) { var scaleWidth = Math.floor( xeUtils.toInteger(column.minWidth) * meanWidth ) tableWidth += scaleWidth column.renderWidth = scaleWidth }) scaleList.forEach(function (column) { var scaleWidth = Math.floor(xeUtils.toInteger(column.width) * meanWidth) tableWidth += scaleWidth column.renderWidth = scaleWidth }) pxList.forEach(function (column) { var width = xeUtils.toInteger(column.width) tableWidth += width column.renderWidth = width }) resizeList.forEach(function (column) { var width = xeUtils.toInteger(column.resizeWidth) tableWidth += width column.renderWidth = width }) remainWidth -= tableWidth meanWidth = remainWidth > 0 ? Math.floor( remainWidth / (scaleMinList.length + pxMinList.length + autoList.length) ) : 0 if (fit) { if (remainWidth > 0) { scaleMinList.concat(pxMinList).forEach(function (column) { tableWidth += meanWidth column.renderWidth += meanWidth }) } } else { meanWidth = minCellWidth } autoList.forEach(function (column) { var width = Math.max(meanWidth, minCellWidth) column.renderWidth = width tableWidth += width }) if (fit) { var dynamicList = scaleList .concat(scaleMinList) .concat(pxMinList) .concat(autoList) var dynamicSize = dynamicList.length - 1 if (dynamicSize > 0) { var odiffer = bodyWidth - tableWidth if (odiffer > 0) { while (odiffer > 0 && dynamicSize >= 0) { odiffer-- dynamicList[dynamicSize--].renderWidth++ } tableWidth = bodyWidth } } } var tableHeight = bodyElem.offsetHeight var overflowY = bodyElem.scrollHeight > bodyElem.clientHeight var scrollbarWidth = 0 if (overflowY) { scrollbarWidth = Math.max( bodyElem.offsetWidth - bodyElem.clientWidth, 0 ) } reactData.scrollbarWidth = scrollbarWidth reactData.overflowY = overflowY internalData.tableWidth = tableWidth internalData.tableHeight = tableHeight var headerHeight = 0 if (headerElem) { headerHeight = headerElem.clientHeight nextTick(function () { if ( headerElem && bodyElem && headerElem.scrollLeft !== bodyElem.scrollLeft ) { headerElem.scrollLeft = bodyElem.scrollLeft } }) } internalData.headerHeight = headerHeight var overflowX = false var footerHeight = 0 var scrollbarHeight = 0 if (footerElem) { footerHeight = footerElem.offsetHeight overflowX = tableWidth > footerElem.clientWidth if (overflowX) { scrollbarHeight = Math.max(footerHeight - footerElem.clientHeight, 0) } } else { overflowX = tableWidth > bodyWidth if (overflowX) { scrollbarHeight = Math.max(tableHeight - bodyElem.clientHeight, 0) } } internalData.footerHeight = footerHeight reactData.overflowX = overflowX reactData.scrollbarHeight = scrollbarHeight updateHeight() reactData.parentHeight = Math.max( internalData.headerHeight + footerHeight + 20, tablePrivateMethods.getParentHeight() ) if (overflowX) { tablePrivateMethods.checkScrolling() } } var getOrderField = function (column) { var sortBy2 = column.sortBy, sortType = column.sortType return function (row) { var cellValue if (sortBy2) { cellValue = xeUtils.isFunction(sortBy2) ? sortBy2({ row, column }) : xeUtils.get(row, sortBy2) } else { cellValue = tablePrivateMethods.getCellLabel(row, column) } if (!sortType || sortType === 'auto') { return isNaN(cellValue) ? cellValue : xeUtils.toNumber(cellValue) } else if (sortType === 'number') { return xeUtils.toNumber(cellValue) } else if (sortType === 'string') { return xeUtils.toValueString(cellValue) } return cellValue } } var updateAfterDataIndex = function () { var treeConfig = props2.treeConfig var afterFullData = internalData.afterFullData, fullDataRowIdData = internalData.fullDataRowIdData, fullAllDataRowIdData = internalData.fullAllDataRowIdData var afterTreeFullData = internalData.afterTreeFullData var treeOpts = computeTreeOpts.value var childrenField = treeOpts.children || treeOpts.childrenField var fullMaps = {} if (treeConfig) { xeUtils.eachTree( afterTreeFullData, function (row, index2, items, path) { var rowid = getRowid($xetable, row) var allrest = fullAllDataRowIdData[rowid] var seq = path .map(function (num2, i2) { return i2 % 2 === 0 ? Number(num2) + 1 : '.' }) .join('') if (allrest) { allrest.seq = seq allrest._index = index2 } else { var rest = { row, rowid, seq, index: -1, $index: -1, _index: index2, items: [], parent: null, level: 0, } fullAllDataRowIdData[rowid] = rest fullDataRowIdData[rowid] = rest } fullMaps[rowid] = row }, { children: treeOpts.transform ? treeOpts.mapChildrenField : childrenField, } ) } else { afterFullData.forEach(function (row, index2) { var rowid = getRowid($xetable, row) var allrest = fullAllDataRowIdData[rowid] var seq = index2 + 1 if (allrest) { allrest.seq = seq allrest._index = index2 } else { var rest = { row, rowid, seq, index: -1, $index: -1, _index: index2, items: [], parent: null, level: 0, } fullAllDataRowIdData[rowid] = rest fullDataRowIdData[rowid] = rest } fullMaps[rowid] = row }) } internalData.afterFullRowMaps = fullMaps } var handleVirtualTreeToList = function () { var treeConfig = props2.treeConfig var treeExpandedMaps = reactData.treeExpandedMaps var treeOpts = computeTreeOpts.value if (treeConfig && treeOpts.transform) { var fullData_1 = [] var expandMaps_1 = {} xeUtils.eachTree( internalData.afterTreeFullData, function (row, index2, items, path, parent2) { var rowid = getRowid($xetable, row) var parentRowid = getRowid($xetable, parent2) if ( !parent2 || (expandMaps_1[parentRowid] && treeExpandedMaps[parentRowid]) ) { expandMaps_1[rowid] = 1 fullData_1.push(row) } }, { children: treeOpts.mapChildrenField } ) internalData.afterFullData = fullData_1 updateScrollYStatus(fullData_1) return fullData_1 } return internalData.afterFullData } var updateAfterFullData = function () { var treeConfig = props2.treeConfig var tableFullColumn = internalData.tableFullColumn, tableFullData = internalData.tableFullData, tableFullTreeData = internalData.tableFullTreeData var filterOpts = computeFilterOpts.value var sortOpts = computeSortOpts.value var treeOpts = computeTreeOpts.value var transform3 = treeOpts.transform var allRemoteFilter = filterOpts.remote, allFilterMethod = filterOpts.filterMethod var allRemoteSort = sortOpts.remote, allSortMethod = sortOpts.sortMethod, sortMultiple = sortOpts.multiple, chronological = sortOpts.chronological var tableData2 = [] var tableTree = [] if (!allRemoteFilter || !allRemoteSort) { var filterColumns_1 = [] var orderColumns_1 = [] tableFullColumn.forEach(function (column) { var field2 = column.field, sortable = column.sortable, order2 = column.order, filters = column.filters if (!allRemoteFilter && filters && filters.length) { var valueList_1 = [] var itemList_1 = [] filters.forEach(function (item2) { if (item2.checked) { itemList_1.push(item2) valueList_1.push(item2.value) } }) if (itemList_1.length) { filterColumns_1.push({ column, valueList: valueList_1, itemList: itemList_1, }) } } if (!allRemoteSort && sortable && order2) { orderColumns_1.push({ column, field: field2, property: field2, order: order2, sortTime: column.sortTime, }) } }) if (sortMultiple && chronological && orderColumns_1.length > 1) { orderColumns_1 = xeUtils.orderBy(orderColumns_1, 'sortTime') } if (!allRemoteFilter && filterColumns_1.length) { var handleFilter = function (row) { return filterColumns_1.every(function (_a2) { var column = _a2.column, valueList = _a2.valueList, itemList = _a2.itemList var filterMethod = column.filterMethod, filterRender = column.filterRender var compConf = filterRender ? VXETable.renderer.get(filterRender.name) : null var compFilterMethod = compConf ? compConf.filterMethod : null var defaultFilterMethod = compConf ? compConf.defaultFilterMethod : null var cellValue = getCellValue(row, column) if (filterMethod) { return itemList.some(function (item2) { return filterMethod({ value: item2.value, option: item2, cellValue, row, column, $table: $xetable, }) }) } else if (compFilterMethod) { return itemList.some(function (item2) { return compFilterMethod({ value: item2.value, option: item2, cellValue, row, column, $table: $xetable, }) }) } else if (allFilterMethod) { return allFilterMethod({ options: itemList, values: valueList, cellValue, row, column, }) } else if (defaultFilterMethod) { return itemList.some(function (item2) { return defaultFilterMethod({ value: item2.value, option: item2, cellValue, row, column, $table: $xetable, }) }) } return valueList.indexOf(xeUtils.get(row, column.field)) > -1 }) } if (treeConfig && transform3) { tableTree = xeUtils.searchTree( tableFullTreeData, handleFilter, __assign(__assign({}, treeOpts), { original: true }) ) tableData2 = tableTree } else { tableData2 = treeConfig ? tableFullTreeData.filter(handleFilter) : tableFullData.filter(handleFilter) tableTree = tableData2 } } else { if (treeConfig && transform3) { tableTree = xeUtils.searchTree( tableFullTreeData, function () { return true }, __assign(__assign({}, treeOpts), { original: true }) ) tableData2 = tableTree } else { tableData2 = treeConfig ? tableFullTreeData.slice(0) : tableFullData.slice(0) tableTree = tableData2 } } if (!allRemoteSort && orderColumns_1.length) { if (treeConfig && transform3) { if (allSortMethod) { var sortRests = allSortMethod({ data: tableTree, sortList: orderColumns_1, $table: $xetable, }) tableTree = xeUtils.isArray(sortRests) ? sortRests : tableTree } else { tableTree = xeUtils.orderBy( tableTree, orderColumns_1.map(function (_a2) { var column = _a2.column, order2 = _a2.order return [getOrderField(column), order2] }) ) } tableData2 = tableTree } else { if (allSortMethod) { var sortRests = allSortMethod({ data: tableData2, sortList: orderColumns_1, $table: $xetable, }) tableData2 = xeUtils.isArray(sortRests) ? sortRests : tableData2 } else { tableData2 = xeUtils.orderBy( tableData2, orderColumns_1.map(function (_a2) { var column = _a2.column, order2 = _a2.order return [getOrderField(column), order2] }) ) } tableTree = tableData2 } } } else { if (treeConfig && transform3) { tableTree = xeUtils.searchTree( tableFullTreeData, function () { return true }, __assign(__assign({}, treeOpts), { original: true }) ) tableData2 = tableTree } else { tableData2 = treeConfig ? tableFullTreeData.slice(0) : tableFullData.slice(0) tableTree = tableData2 } } internalData.afterFullData = tableData2 internalData.afterTreeFullData = tableTree updateAfterDataIndex() } var updateStyle2 = function () { var border = props2.border, showFooter = props2.showFooter, allColumnOverflow = props2.showOverflow, allColumnHeaderOverflow = props2.showHeaderOverflow, allColumnFooterOverflow = props2.showFooterOverflow, mouseConfig = props2.mouseConfig, spanMethod = props2.spanMethod, footerSpanMethod = props2.footerSpanMethod, keyboardConfig = props2.keyboardConfig var isGroup2 = reactData.isGroup, currentRow = reactData.currentRow, tableColumn = reactData.tableColumn, scrollXLoad = reactData.scrollXLoad, scrollYLoad = reactData.scrollYLoad, scrollbarWidth = reactData.scrollbarWidth, scrollbarHeight = reactData.scrollbarHeight, columnStore = reactData.columnStore, editStore = reactData.editStore, mergeList = reactData.mergeList, mergeFooterList = reactData.mergeFooterList, isAllOverflow = reactData.isAllOverflow var visibleColumn = internalData.visibleColumn, fullColumnIdData = internalData.fullColumnIdData, tableHeight = internalData.tableHeight, tableWidth = internalData.tableWidth, headerHeight = internalData.headerHeight, footerHeight = internalData.footerHeight, elemStore = internalData.elemStore, customHeight = internalData.customHeight, customMinHeight = internalData.customMinHeight, customMaxHeight = internalData.customMaxHeight var containerList = ['main', 'left', 'right'] var emptyPlaceholderElem = refEmptyPlaceholder.value var cellOffsetWidth = computeCellOffsetWidth.value var mouseOpts = computeMouseOpts.value var keyboardOpts = computeKeyboardOpts.value var bodyWrapperRef = elemStore['main-body-wrapper'] var bodyWrapperElem = bodyWrapperRef ? bodyWrapperRef.value : null if (emptyPlaceholderElem) { emptyPlaceholderElem.style.top = ''.concat(headerHeight, 'px') emptyPlaceholderElem.style.height = bodyWrapperElem ? ''.concat(bodyWrapperElem.offsetHeight - scrollbarHeight, 'px') : '' } if (customHeight > 0) { if (showFooter) { customHeight += scrollbarHeight } } containerList.forEach(function (name2, index2) { var fixedType = index2 > 0 ? name2 : '' var layoutList2 = ['header', 'body', 'footer'] var isFixedLeft = fixedType === 'left' var fixedColumn = [] var fixedWrapperElem if (fixedType) { fixedColumn = isFixedLeft ? columnStore.leftList : columnStore.rightList fixedWrapperElem = isFixedLeft ? refLeftContainer.value : refRightContainer.value } layoutList2.forEach(function (layout2) { var wrapperRef = elemStore[''.concat(name2, '-').concat(layout2, '-wrapper')] var wrapperElem = wrapperRef ? wrapperRef.value : null var tableRef = elemStore[''.concat(name2, '-').concat(layout2, '-table')] var tableElem = tableRef ? tableRef.value : null if (layout2 === 'header') { var tWidth = tableWidth var renderColumnList = tableColumn if (isGroup2) { renderColumnList = visibleColumn } else { if (fixedType) { if (scrollXLoad || allColumnHeaderOverflow) { renderColumnList = fixedColumn } } } tWidth = renderColumnList.reduce(function (previous, column) { return previous + column.renderWidth }, 0) if (tableElem) { tableElem.style.width = tWidth ? ''.concat(tWidth + scrollbarWidth, 'px') : '' } var repairRef = elemStore[''.concat(name2, '-').concat(layout2, '-repair')] var repairElem = repairRef ? repairRef.value : null if (repairElem) { repairElem.style.width = ''.concat(tableWidth, 'px') } var listRef = elemStore[''.concat(name2, '-').concat(layout2, '-list')] var listElem = listRef ? listRef.value : null if (isGroup2 && listElem) { xeUtils.arrayEach( listElem.querySelectorAll('.col--group'), function (thElem) { var colNode = tableMethods.getColumnNode(thElem) if (colNode) { var column_1 = colNode.item var showHeaderOverflow = column_1.showHeaderOverflow var cellOverflow = xeUtils.isBoolean(showHeaderOverflow) ? showHeaderOverflow : allColumnHeaderOverflow var showEllipsis = cellOverflow === 'ellipsis' var showTitle = cellOverflow === 'title' var showTooltip2 = cellOverflow === true || cellOverflow === 'tooltip' var hasEllipsis = showTitle || showTooltip2 || showEllipsis var childWidth_1 = 0 var countChild_1 = 0 if (hasEllipsis) { xeUtils.eachTree( column_1.children, function (item2) { if (!item2.children || !column_1.children.length) { countChild_1++ } childWidth_1 += item2.renderWidth }, { children: 'children' } ) } thElem.style.width = hasEllipsis ? ''.concat( childWidth_1 - countChild_1 - (border ? 2 : 0), 'px' ) : '' } } ) } } else if (layout2 === 'body') { var emptyBlockRef = elemStore[''.concat(name2, '-').concat(layout2, '-emptyBlock')] var emptyBlockElem = emptyBlockRef ? emptyBlockRef.value : null if (isNodeElement(wrapperElem)) { var bodyMaxHeight = 0 var bodyMinHeight = customMinHeight - headerHeight - footerHeight if (customMaxHeight) { bodyMaxHeight = customMaxHeight - headerHeight - footerHeight if (fixedType) { bodyMaxHeight -= showFooter ? 0 : scrollbarHeight } bodyMaxHeight = Math.max(bodyMinHeight, bodyMaxHeight) wrapperElem.style.maxHeight = ''.concat(bodyMaxHeight, 'px') } if (customHeight) { var bodyHeight = customHeight - headerHeight - footerHeight if (fixedType) { bodyHeight -= showFooter ? 0 : scrollbarHeight } if (bodyMaxHeight) { bodyHeight = Math.min(bodyMaxHeight, bodyHeight) } wrapperElem.style.height = ''.concat( Math.max(bodyMinHeight, bodyHeight), 'px' ) } else { wrapperElem.style.height = '' } wrapperElem.style.minHeight = ''.concat(bodyMinHeight, 'px') } if (fixedWrapperElem) { if (isNodeElement(wrapperElem)) { wrapperElem.style.top = ''.concat(headerHeight, 'px') } fixedWrapperElem.style.height = ''.concat( (customHeight > 0 ? customHeight - headerHeight - footerHeight : tableHeight) + headerHeight + footerHeight - scrollbarHeight * (showFooter ? 2 : 1), 'px' ) fixedWrapperElem.style.width = ''.concat( fixedColumn.reduce( function (previous, column) { return previous + column.renderWidth }, isFixedLeft ? 0 : scrollbarWidth ), 'px' ) } var tWidth = tableWidth var renderColumnList = tableColumn if (fixedType) { if ( !reactData.expandColumn && (scrollYLoad || (allColumnOverflow ? isAllOverflow : allColumnOverflow)) ) { if ( !mergeList.length && !spanMethod && !(keyboardConfig && keyboardOpts.isMerge) ) { renderColumnList = fixedColumn } else { renderColumnList = visibleColumn } } else { renderColumnList = visibleColumn } } tWidth = renderColumnList.reduce(function (previous, column) { return previous + column.renderWidth }, 0) if (tableElem) { tableElem.style.width = tWidth ? ''.concat(tWidth, 'px') : '' tableElem.style.paddingRight = scrollbarWidth && fixedType && (browse['-moz'] || browse.safari) ? ''.concat(scrollbarWidth, 'px') : '' } if (emptyBlockElem) { emptyBlockElem.style.width = tWidth ? ''.concat(tWidth, 'px') : '' } } else if (layout2 === 'footer') { var tWidth = tableWidth var renderColumnList = tableColumn if (fixedType) { if ( !reactData.expandColumn && (scrollXLoad || allColumnFooterOverflow) ) { if (!mergeFooterList.length || !footerSpanMethod) { renderColumnList = fixedColumn } else { renderColumnList = visibleColumn } } else { renderColumnList = visibleColumn } } tWidth = renderColumnList.reduce(function (previous, column) { return previous + column.renderWidth }, 0) if (isNodeElement(wrapperElem)) { if (fixedWrapperElem) { wrapperElem.style.top = ''.concat( customHeight > 0 ? customHeight - footerHeight : tableHeight + headerHeight, 'px' ) } wrapperElem.style.marginTop = ''.concat( -Math.max(1, scrollbarHeight), 'px' ) } if (tableElem) { tableElem.style.width = tWidth ? ''.concat(tWidth + scrollbarWidth, 'px') : '' } } var colgroupRef = elemStore[''.concat(name2, '-').concat(layout2, '-colgroup')] var colgroupElem = colgroupRef ? colgroupRef.value : null if (colgroupElem) { xeUtils.arrayEach(colgroupElem.children, function (colElem) { var colid = colElem.getAttribute('name') if (colid === 'col_gutter') { colElem.style.width = ''.concat(scrollbarWidth, 'px') } if (fullColumnIdData[colid]) { var column_2 = fullColumnIdData[colid].column var showHeaderOverflow = column_2.showHeaderOverflow, showFooterOverflow = column_2.showFooterOverflow, showOverflow = column_2.showOverflow var cellOverflow = void 0 colElem.style.width = ''.concat(column_2.renderWidth, 'px') if (layout2 === 'header') { cellOverflow = xeUtils.isUndefined(showHeaderOverflow) || xeUtils.isNull(showHeaderOverflow) ? allColumnHeaderOverflow : showHeaderOverflow } else if (layout2 === 'footer') { cellOverflow = xeUtils.isUndefined(showFooterOverflow) || xeUtils.isNull(showFooterOverflow) ? allColumnFooterOverflow : showFooterOverflow } else { cellOverflow = xeUtils.isUndefined(showOverflow) || xeUtils.isNull(showOverflow) ? allColumnOverflow : showOverflow } var showEllipsis = cellOverflow === 'ellipsis' var showTitle = cellOverflow === 'title' var showTooltip2 = cellOverflow === true || cellOverflow === 'tooltip' var hasEllipsis_1 = showTitle || showTooltip2 || showEllipsis var listRef2 = elemStore[''.concat(name2, '-').concat(layout2, '-list')] var listElem2 = listRef2 ? listRef2.value : null if (scrollYLoad && !hasEllipsis_1) { hasEllipsis_1 = true } if (listElem2) { xeUtils.arrayEach( listElem2.querySelectorAll('.'.concat(column_2.id)), function (elem) { var colspan = parseInt(elem.getAttribute('colspan') || 1) var cellElem = elem.querySelector('.vxe-cell') var colWidth = column_2.renderWidth if (cellElem) { if (colspan > 1) { var columnIndex = tableMethods.getColumnIndex(column_2) for (var index_1 = 1; index_1 < colspan; index_1++) { var nextColumn = tableMethods.getColumns( columnIndex + index_1 ) if (nextColumn) { colWidth += nextColumn.renderWidth } } } cellElem.style.width = hasEllipsis_1 ? ''.concat( colWidth - cellOffsetWidth * colspan, 'px' ) : '' } } ) } } }) } }) }) if (currentRow) { tableMethods.setCurrentRow(currentRow) } if ( mouseConfig && mouseOpts.selected && editStore.selected.row && editStore.selected.column ) { $xetable.addCellSelectedClass() } return nextTick() } var checkValidate = function (type4) { if ($xetable.triggerValidate) { return $xetable.triggerValidate(type4) } return nextTick() } var handleChangeCell = function (evnt, params2) { checkValidate('blur') .catch(function (e2) { return e2 }) .then(function () { $xetable .handleActived(params2, evnt) .then(function () { return checkValidate('change') }) .catch(function (e2) { return e2 }) }) } var handleDefaultSort = function () { var sortConfig = props2.sortConfig if (sortConfig) { var sortOpts = computeSortOpts.value var defaultSort = sortOpts.defaultSort if (defaultSort) { if (!xeUtils.isArray(defaultSort)) { defaultSort = [defaultSort] } if (defaultSort.length) { ;(sortConfig.multiple ? defaultSort : defaultSort.slice(0, 1) ).forEach(function (item2, index2) { var field2 = item2.field, order2 = item2.order if (field2 && order2) { var column = tableMethods.getColumnByField(field2) if (column && column.sortable) { column.order = order2 column.sortTime = Date.now() + index2 } } }) if (!sortOpts.remote) { tablePrivateMethods.handleTableData(true).then(updateStyle2) } } } } } var handleDefaultSelectionChecked = function () { var checkboxConfig = props2.checkboxConfig if (checkboxConfig) { var fullDataRowIdData_1 = internalData.fullDataRowIdData var checkboxOpts = computeCheckboxOpts.value var checkAll = checkboxOpts.checkAll, checkRowKeys = checkboxOpts.checkRowKeys if (checkAll) { handleCheckedAllCheckboxRow(true, true) } else if (checkRowKeys) { var defSelection_1 = [] checkRowKeys.forEach(function (rowid) { if (fullDataRowIdData_1[rowid]) { defSelection_1.push(fullDataRowIdData_1[rowid].row) } }) handleCheckedCheckboxRow(defSelection_1, true, true) } } } var handleDefaultRadioChecked = function () { var _a2 var radioConfig = props2.radioConfig if (radioConfig) { var fullDataRowIdData = internalData.fullDataRowIdData var radioOpts = computeRadioOpts.value var rowid = radioOpts.checkRowKey, reserve = radioOpts.reserve if (rowid) { if (fullDataRowIdData[rowid]) { handleCheckedRadioRow(fullDataRowIdData[rowid].row, true) } if (reserve) { var rowkey = getRowkey($xetable) internalData.radioReserveRow = ((_a2 = {}), (_a2[rowkey] = rowid), _a2) } } } } var handleDefaultRowExpand = function () { var expandConfig = props2.expandConfig if (expandConfig) { var fullDataRowIdData_2 = internalData.fullDataRowIdData var expandOpts = computeExpandOpts.value var expandAll = expandOpts.expandAll, expandRowKeys = expandOpts.expandRowKeys if (expandAll) { tableMethods.setAllRowExpand(true) } else if (expandRowKeys) { var defExpandeds_1 = [] expandRowKeys.forEach(function (rowid) { if (fullDataRowIdData_2[rowid]) { defExpandeds_1.push(fullDataRowIdData_2[rowid].row) } }) tableMethods.setRowExpand(defExpandeds_1, true) } } } var handleRadioReserveRow = function (row) { var radioOpts = computeRadioOpts.value if (radioOpts.reserve) { internalData.radioReserveRow = row } } var handleCheckboxReserveRow = function (row, checked2) { var checkboxReserveRowMap = internalData.checkboxReserveRowMap var checkboxOpts = computeCheckboxOpts.value if (checkboxOpts.reserve) { var rowid = getRowid($xetable, row) if (checked2) { checkboxReserveRowMap[rowid] = row } else if (checkboxReserveRowMap[rowid]) { delete checkboxReserveRowMap[rowid] } } } var handleCheckedRadioRow = function (row, isForce) { var radioOpts = computeRadioOpts.value var checkMethod = radioOpts.checkMethod if (row && (isForce || !checkMethod || checkMethod({ row }))) { reactData.selectRadioRow = row handleRadioReserveRow(row) } return nextTick() } var handleCheckedCheckboxRow = function (rows, value2, isForce) { if (rows && !xeUtils.isArray(rows)) { rows = [rows] } rows.forEach(function (row) { return tablePrivateMethods.handleSelectRow({ row }, !!value2, isForce) }) return nextTick() } var handleCheckedAllCheckboxRow = function (value2, isForce) { var treeConfig = props2.treeConfig var selectCheckboxMaps = reactData.selectCheckboxMaps var afterFullData = internalData.afterFullData, afterFullRowMaps = internalData.afterFullRowMaps, checkboxReserveRowMap = internalData.checkboxReserveRowMap var treeOpts = computeTreeOpts.value var childrenField = treeOpts.children || treeOpts.childrenField var checkboxOpts = computeCheckboxOpts.value var checkField = checkboxOpts.checkField, reserve = checkboxOpts.reserve, checkStrictly = checkboxOpts.checkStrictly, checkMethod = checkboxOpts.checkMethod var indeterminateField = checkboxOpts.indeterminateField || checkboxOpts.halfField var selectRowMaps = {} if (!treeConfig) { xeUtils.each(selectCheckboxMaps, function (row, rowid) { if (!afterFullRowMaps[rowid]) { selectRowMaps[rowid] = row } }) } if (checkStrictly) { reactData.isAllSelected = value2 } else { if (checkField) { var checkValFn = function (row) { if (isForce || !checkMethod || checkMethod({ row })) { if (value2) { selectRowMaps[getRowid($xetable, row)] = row } xeUtils.set(row, checkField, value2) } if (treeConfig && indeterminateField) { xeUtils.set(row, indeterminateField, false) } } if (treeConfig) { xeUtils.eachTree(afterFullData, checkValFn, { children: childrenField, }) } else { afterFullData.forEach(checkValFn) } } else { if (treeConfig) { if (value2) { xeUtils.eachTree( afterFullData, function (row) { if (isForce || !checkMethod || checkMethod({ row })) { selectRowMaps[getRowid($xetable, row)] = row } }, { children: childrenField } ) } else { if (!isForce && checkMethod) { xeUtils.eachTree( afterFullData, function (row) { var rowid = getRowid($xetable, row) if (checkMethod({ row }) ? 0 : selectCheckboxMaps[rowid]) { selectRowMaps[rowid] = row } }, { children: childrenField } ) } } } else { if (value2) { if (!isForce && checkMethod) { afterFullData.forEach(function (row) { var rowid = getRowid($xetable, row) if (selectCheckboxMaps[rowid] || checkMethod({ row })) { selectRowMaps[rowid] = row } }) } else { afterFullData.forEach(function (row) { selectRowMaps[getRowid($xetable, row)] = row }) } } else { if (!isForce && checkMethod) { afterFullData.forEach(function (row) { var rowid = getRowid($xetable, row) if (checkMethod({ row }) ? 0 : selectCheckboxMaps[rowid]) { selectRowMaps[rowid] = row } }) } } } } if (reserve) { if (value2) { xeUtils.each(selectRowMaps, function (row, rowid) { checkboxReserveRowMap[rowid] = row }) } else { afterFullData.forEach(function (row) { return handleCheckboxReserveRow(row, false) }) } } reactData.selectCheckboxMaps = checkField ? {} : selectRowMaps } reactData.treeIndeterminateMaps = {} internalData.treeIndeterminateRowMaps = {} tablePrivateMethods.checkSelectionStatus() return nextTick() } var handleReserveStatus = function () { var treeConfig = props2.treeConfig var expandColumn = reactData.expandColumn, currentRow = reactData.currentRow, selectCheckboxMaps = reactData.selectCheckboxMaps, selectRadioRow = reactData.selectRadioRow, rowExpandedMaps = reactData.rowExpandedMaps, treeExpandedMaps = reactData.treeExpandedMaps var fullDataRowIdData = internalData.fullDataRowIdData, fullAllDataRowIdData = internalData.fullAllDataRowIdData, radioReserveRow = internalData.radioReserveRow var expandOpts = computeExpandOpts.value var treeOpts = computeTreeOpts.value var radioOpts = computeRadioOpts.value var checkboxOpts = computeCheckboxOpts.value if ( selectRadioRow && !fullAllDataRowIdData[getRowid($xetable, selectRadioRow)] ) { reactData.selectRadioRow = null } if (radioOpts.reserve && radioReserveRow) { var rowid = getRowid($xetable, radioReserveRow) if (fullDataRowIdData[rowid]) { handleCheckedRadioRow(fullDataRowIdData[rowid].row, true) } } reactData.selectCheckboxMaps = getRecoverRowMaps(selectCheckboxMaps) if (checkboxOpts.reserve) { handleCheckedCheckboxRow( handleReserveRow(internalData.checkboxReserveRowMap), true, true ) } if (currentRow && !fullAllDataRowIdData[getRowid($xetable, currentRow)]) { reactData.currentRow = null } reactData.rowExpandedMaps = expandColumn ? getRecoverRowMaps(rowExpandedMaps) : {} if (expandColumn && expandOpts.reserve) { tableMethods.setRowExpand( handleReserveRow(internalData.rowExpandedReserveRowMap), true ) } reactData.treeExpandedMaps = treeConfig ? getRecoverRowMaps(treeExpandedMaps) : {} if (treeConfig && treeOpts.reserve) { tableMethods.setTreeExpand( handleReserveRow(internalData.treeExpandedReserveRowMap), true ) } } var handleDefaultTreeExpand = function () { var treeConfig = props2.treeConfig if (treeConfig) { var tableFullData_1 = internalData.tableFullData var treeOpts = computeTreeOpts.value var expandAll = treeOpts.expandAll, expandRowKeys = treeOpts.expandRowKeys var childrenField_1 = treeOpts.children || treeOpts.childrenField if (expandAll) { tableMethods.setAllTreeExpand(true) } else if (expandRowKeys) { var defExpandeds_2 = [] var rowkey_1 = getRowkey($xetable) expandRowKeys.forEach(function (rowid) { var matchObj = xeUtils.findTree( tableFullData_1, function (item2) { return rowid === xeUtils.get(item2, rowkey_1) }, { children: childrenField_1 } ) if (matchObj) { defExpandeds_2.push(matchObj.item) } }) tableMethods.setTreeExpand(defExpandeds_2, true) } } } var handleAsyncTreeExpandChilds = function (row) { var treeOpts = computeTreeOpts.value var checkboxOpts = computeCheckboxOpts.value var transform3 = treeOpts.transform, loadMethod = treeOpts.loadMethod var checkStrictly = checkboxOpts.checkStrictly return new Promise(function (resolve2) { if (loadMethod) { var treeExpandLazyLoadedMaps_1 = reactData.treeExpandLazyLoadedMaps var fullAllDataRowIdData = internalData.fullAllDataRowIdData var rowid_1 = getRowid($xetable, row) var rest_1 = fullAllDataRowIdData[rowid_1] treeExpandLazyLoadedMaps_1[rowid_1] = row loadMethod({ $table: $xetable, row }) .then(function (childRecords) { rest_1.treeLoaded = true if (treeExpandLazyLoadedMaps_1[rowid_1]) { delete treeExpandLazyLoadedMaps_1[rowid_1] } if (!xeUtils.isArray(childRecords)) { childRecords = [] } if (childRecords) { return tableMethods .loadTreeChildren(row, childRecords) .then(function (childRows) { var treeExpandedMaps = reactData.treeExpandedMaps if (childRows.length && !treeExpandedMaps[rowid_1]) { treeExpandedMaps[rowid_1] = row } if ( !checkStrictly && tableMethods.isCheckedByCheckboxRow(row) ) { handleCheckedCheckboxRow(childRows, true) } return nextTick().then(function () { if (transform3) { return tablePrivateMethods.handleTableData() } }) }) } }) .catch(function () { var treeExpandLazyLoadedMaps = reactData.treeExpandLazyLoadedMaps rest_1.treeLoaded = false if (treeExpandLazyLoadedMaps[rowid_1]) { delete treeExpandLazyLoadedMaps[rowid_1] } }) .finally(function () { nextTick() .then(function () { return tableMethods.recalculate() }) .then(function () { return resolve2() }) }) } else { resolve2() } }) } var handleTreeExpandReserve = function (row, expanded) { var treeExpandedReserveRowMap = internalData.treeExpandedReserveRowMap var treeOpts = computeTreeOpts.value if (treeOpts.reserve) { var rowid = getRowid($xetable, row) if (expanded) { treeExpandedReserveRowMap[rowid] = row } else if (treeExpandedReserveRowMap[rowid]) { delete treeExpandedReserveRowMap[rowid] } } } var handleAsyncRowExpand = function (row) { return new Promise(function (resolve2) { var expandOpts = computeExpandOpts.value var loadMethod = expandOpts.loadMethod if (loadMethod) { var fullAllDataRowIdData = internalData.fullAllDataRowIdData var rowExpandLazyLoadedMaps = reactData.rowExpandLazyLoadedMaps var rowid_2 = getRowid($xetable, row) var rest_2 = fullAllDataRowIdData[rowid_2] rowExpandLazyLoadedMaps[rowid_2] = row loadMethod({ $table: $xetable, row, rowIndex: tableMethods.getRowIndex(row), $rowIndex: tableMethods.getVMRowIndex(row), }) .then(function () { var rowExpandedMaps = reactData.rowExpandedMaps rest_2.expandLoaded = true rowExpandedMaps[rowid_2] = row }) .catch(function () { rest_2.expandLoaded = false }) .finally(function () { var rowExpandLazyLoadedMaps2 = reactData.rowExpandLazyLoadedMaps if (rowExpandLazyLoadedMaps2[rowid_2]) { delete rowExpandLazyLoadedMaps2[rowid_2] } nextTick() .then(function () { return tableMethods.recalculate() }) .then(function () { return resolve2() }) }) } else { resolve2() } }) } var handleRowExpandReserve = function (row, expanded) { var rowExpandedReserveRowMap = internalData.rowExpandedReserveRowMap var expandOpts = computeExpandOpts.value if (expandOpts.reserve) { var rowid = getRowid($xetable, row) if (expanded) { rowExpandedReserveRowMap[rowid] = row } else if (rowExpandedReserveRowMap[rowid]) { delete rowExpandedReserveRowMap[rowid] } } } var handleDefaultMergeCells = function () { var mergeCells = props2.mergeCells if (mergeCells) { tableMethods.setMergeCells(mergeCells) } } var handleDefaultMergeFooterItems = function () { var mergeFooterItems = props2.mergeFooterItems if (mergeFooterItems) { tableMethods.setMergeFooterItems(mergeFooterItems) } } var computeScrollLoad = function () { return nextTick().then(function () { var scrollXLoad = reactData.scrollXLoad, scrollYLoad = reactData.scrollYLoad var scrollXStore = internalData.scrollXStore, scrollYStore = internalData.scrollYStore var sYOpts = computeSYOpts.value var sXOpts = computeSXOpts.value if (scrollXLoad) { var visibleXSize = computeVirtualX().visibleSize var offsetXSize = sXOpts.oSize ? xeUtils.toNumber(sXOpts.oSize) : browse.edge ? 5 : 0 scrollXStore.offsetSize = offsetXSize scrollXStore.visibleSize = visibleXSize scrollXStore.endIndex = Math.max( scrollXStore.startIndex + scrollXStore.visibleSize + offsetXSize, scrollXStore.endIndex ) tablePrivateMethods.updateScrollXData() } else { tablePrivateMethods.updateScrollXSpace() } var _a2 = computeVirtualY(), rowHeight = _a2.rowHeight, visibleYSize = _a2.visibleSize scrollYStore.rowHeight = rowHeight if (scrollYLoad) { var offsetYSize = sYOpts.oSize ? xeUtils.toNumber(sYOpts.oSize) : browse.edge ? 10 : 0 scrollYStore.offsetSize = offsetYSize scrollYStore.visibleSize = visibleYSize scrollYStore.endIndex = Math.max( scrollYStore.startIndex + visibleYSize + offsetYSize, scrollYStore.endIndex ) tablePrivateMethods.updateScrollYData() } else { tablePrivateMethods.updateScrollYSpace() } reactData.rowHeight = rowHeight nextTick(updateStyle2) }) } var loadTableData = function (datas) { var keepSource = props2.keepSource, treeConfig = props2.treeConfig var editStore = reactData.editStore, oldScrollYLoad = reactData.scrollYLoad var scrollYStore = internalData.scrollYStore, scrollXStore = internalData.scrollXStore, lastScrollLeft = internalData.lastScrollLeft, lastScrollTop = internalData.lastScrollTop var treeOpts = computeTreeOpts.value var transform3 = treeOpts.transform var childrenField = treeOpts.children || treeOpts.childrenField var treeData = [] var fullData = reactive(datas ? datas.slice(0) : []) if (treeConfig) { if (transform3) { treeData = xeUtils.toArrayTree(fullData, { key: treeOpts.rowField, parentKey: treeOpts.parentField, children: childrenField, mapChildren: treeOpts.mapChildrenField, }) fullData = treeData.slice(0) } else { treeData = fullData.slice(0) } } scrollYStore.startIndex = 0 scrollYStore.endIndex = 1 scrollXStore.startIndex = 0 scrollXStore.endIndex = 1 reactData.scrollVMLoading = false editStore.insertMaps = {} editStore.removeMaps = {} var sYLoad = updateScrollYStatus(fullData) reactData.scrollYLoad = sYLoad internalData.tableFullData = fullData internalData.tableFullTreeData = treeData tablePrivateMethods.cacheRowMap(true) internalData.tableSynchData = datas if (keepSource) { tablePrivateMethods.cacheSourceMap(fullData) } if ($xetable.clearCellAreas && props2.mouseConfig) { $xetable.clearCellAreas() $xetable.clearCopyCellArea() } tableMethods.clearMergeCells() tableMethods.clearMergeFooterItems() tablePrivateMethods.handleTableData(true) tableMethods.updateFooter() return nextTick() .then(function () { updateHeight() updateStyle2() }) .then(function () { computeScrollLoad() }) .then(function () { if (sYLoad) { scrollYStore.endIndex = scrollYStore.visibleSize } handleReserveStatus() tablePrivateMethods.checkSelectionStatus() return new Promise(function (resolve2) { nextTick() .then(function () { return tableMethods.recalculate() }) .then(function () { var targetScrollLeft = lastScrollLeft var targetScrollTop = lastScrollTop var sXOpts = computeSXOpts.value var sYOpts = computeSYOpts.value if (sXOpts.scrollToLeftOnChange) { targetScrollLeft = 0 } if (sYOpts.scrollToTopOnChange) { targetScrollTop = 0 } if (oldScrollYLoad === sYLoad) { restoreScrollLocation( $xetable, targetScrollLeft, targetScrollTop ).then(resolve2) } else { setTimeout(function () { return restoreScrollLocation( $xetable, targetScrollLeft, targetScrollTop ).then(resolve2) }) } }) }) }) } var handleLoadDefaults = function () { handleDefaultSelectionChecked() handleDefaultRadioChecked() handleDefaultRowExpand() handleDefaultTreeExpand() handleDefaultMergeCells() handleDefaultMergeFooterItems() nextTick(function () { return setTimeout(function () { return tableMethods.recalculate() }) }) } var handleInitDefaults = function () { handleDefaultSort() } var handleTableColumn = function () { var scrollXLoad = reactData.scrollXLoad var visibleColumn = internalData.visibleColumn, scrollXStore = internalData.scrollXStore, fullColumnIdData = internalData.fullColumnIdData var tableColumn = scrollXLoad ? visibleColumn.slice(scrollXStore.startIndex, scrollXStore.endIndex) : visibleColumn.slice(0) tableColumn.forEach(function (column, $index) { var colid = column.id var rest = fullColumnIdData[colid] if (rest) { rest.$index = $index } }) reactData.tableColumn = tableColumn } var loadScrollXData = function () { var mergeList = reactData.mergeList, mergeFooterList = reactData.mergeFooterList var scrollXStore = internalData.scrollXStore var startIndex = scrollXStore.startIndex, endIndex = scrollXStore.endIndex, offsetSize = scrollXStore.offsetSize var _a2 = computeVirtualX(), toVisibleIndex = _a2.toVisibleIndex, visibleSize = _a2.visibleSize var offsetItem = { startIndex: Math.max(0, toVisibleIndex - 1 - offsetSize), endIndex: toVisibleIndex + visibleSize + offsetSize, } calculateMergerOffserIndex( mergeList.concat(mergeFooterList), offsetItem, 'col' ) var offsetStartIndex = offsetItem.startIndex, offsetEndIndex = offsetItem.endIndex if ( toVisibleIndex <= startIndex || toVisibleIndex >= endIndex - visibleSize - 1 ) { if (startIndex !== offsetStartIndex || endIndex !== offsetEndIndex) { scrollXStore.startIndex = offsetStartIndex scrollXStore.endIndex = offsetEndIndex tablePrivateMethods.updateScrollXData() } } tableMethods.closeTooltip() } var getColumnList = function (columns) { var result = [] columns.forEach(function (column) { result.push.apply( result, column.children && column.children.length ? getColumnList(column.children) : [column] ) }) return result } var parseColumns = function () { var leftList = [] var centerList = [] var rightList = [] var isGroup2 = reactData.isGroup, columnStore = reactData.columnStore var sXOpts = computeSXOpts.value var collectColumn = internalData.collectColumn, tableFullColumn = internalData.tableFullColumn, scrollXStore = internalData.scrollXStore, fullColumnIdData = internalData.fullColumnIdData if (isGroup2) { var leftGroupList_1 = [] var centerGroupList_1 = [] var rightGroupList_1 = [] xeUtils.eachTree( collectColumn, function (column, index2, items, path, parent2) { var isColGroup = hasChildrenList(column) if (parent2 && parent2.fixed) { column.fixed = parent2.fixed } if (parent2 && column.fixed !== parent2.fixed) { errLog('vxe.error.groupFixed') } if (isColGroup) { column.visible = !!xeUtils.findTree( column.children, function (subColumn) { return hasChildrenList(subColumn) ? false : subColumn.visible } ) } else if (column.visible) { if (column.fixed === 'left') { leftList.push(column) } else if (column.fixed === 'right') { rightList.push(column) } else { centerList.push(column) } } } ) collectColumn.forEach(function (column) { if (column.visible) { if (column.fixed === 'left') { leftGroupList_1.push(column) } else if (column.fixed === 'right') { rightGroupList_1.push(column) } else { centerGroupList_1.push(column) } } }) reactData.tableGroupColumn = leftGroupList_1 .concat(centerGroupList_1) .concat(rightGroupList_1) } else { tableFullColumn.forEach(function (column) { if (column.visible) { if (column.fixed === 'left') { leftList.push(column) } else if (column.fixed === 'right') { rightList.push(column) } else { centerList.push(column) } } }) } var visibleColumn = leftList.concat(centerList).concat(rightList) var scrollXLoad = !!sXOpts.enabled && sXOpts.gt > -1 && (sXOpts.gt === 0 || sXOpts.gt < tableFullColumn.length) reactData.hasFixedColumn = leftList.length > 0 || rightList.length > 0 Object.assign(columnStore, { leftList, centerList, rightList }) if (scrollXLoad) { var visibleSize = computeVirtualX().visibleSize scrollXStore.startIndex = 0 scrollXStore.endIndex = visibleSize scrollXStore.visibleSize = visibleSize } if ( visibleColumn.length !== internalData.visibleColumn.length || !internalData.visibleColumn.every(function (column, index2) { return column === visibleColumn[index2] }) ) { tableMethods.clearMergeCells() tableMethods.clearMergeFooterItems() } reactData.scrollXLoad = scrollXLoad visibleColumn.forEach(function (column, index2) { var colid = column.id var rest = fullColumnIdData[colid] if (rest) { rest._index = index2 } }) internalData.visibleColumn = visibleColumn handleTableColumn() return tableMethods .updateFooter() .then(function () { return tableMethods.recalculate() }) .then(function () { tableMethods.updateCellAreas() return tableMethods.recalculate() }) } var handleColumn = function (collectColumn) { internalData.collectColumn = collectColumn var tableFullColumn = getColumnList(collectColumn) internalData.tableFullColumn = tableFullColumn cacheColumnMap() restoreCustomStorage() parseColumns().then(function () { if (reactData.scrollXLoad) { loadScrollXData() } }) tableMethods.clearMergeCells() tableMethods.clearMergeFooterItems() tablePrivateMethods.handleTableData(true) return nextTick().then(function () { if ($xetoolbar) { $xetoolbar.syncUpdate({ collectColumn, $table: $xetable }) } return tableMethods.recalculate() }) } var updateScrollYStatus = function (fullData) { var treeConfig = props2.treeConfig var sYOpts = computeSYOpts.value var treeOpts = computeTreeOpts.value var transform3 = treeOpts.transform var allList = fullData || internalData.tableFullData var scrollYLoad = (transform3 || !treeConfig) && !!sYOpts.enabled && sYOpts.gt > -1 && (sYOpts.gt === 0 || sYOpts.gt < allList.length) reactData.scrollYLoad = scrollYLoad return scrollYLoad } var handleBaseTreeExpand = function (rows, expanded) { var treeExpandedMaps = reactData.treeExpandedMaps, treeExpandLazyLoadedMaps = reactData.treeExpandLazyLoadedMaps, treeNodeColumn = reactData.treeNodeColumn var treeTempExpandedMaps = __assign({}, treeExpandedMaps) var fullAllDataRowIdData = internalData.fullAllDataRowIdData, tableFullData = internalData.tableFullData var treeOpts = computeTreeOpts.value var reserve = treeOpts.reserve, lazy = treeOpts.lazy, accordion = treeOpts.accordion, toggleMethod = treeOpts.toggleMethod var childrenField = treeOpts.children || treeOpts.childrenField var hasChildField = treeOpts.hasChild || treeOpts.hasChildField var result = [] var columnIndex = tableMethods.getColumnIndex(treeNodeColumn) var $columnIndex = tableMethods.getVMColumnIndex(treeNodeColumn) var validRows = toggleMethod ? rows.filter(function (row) { return toggleMethod({ $table: $xetable, expanded, column: treeNodeColumn, columnIndex, $columnIndex, row, }) }) : rows if (accordion) { validRows = validRows.length ? [validRows[validRows.length - 1]] : [] var matchObj = xeUtils.findTree( tableFullData, function (item2) { return item2 === validRows[0] }, { children: childrenField } ) if (matchObj) { matchObj.items.forEach(function (item2) { var rowid = getRowid($xetable, item2) if (treeTempExpandedMaps[rowid]) { delete treeTempExpandedMaps[rowid] } }) } } if (expanded) { validRows.forEach(function (row) { var rowid = getRowid($xetable, row) if (!treeTempExpandedMaps[rowid]) { var rest = fullAllDataRowIdData[rowid] var isLoad = lazy && row[hasChildField] && !rest.treeLoaded && !treeExpandLazyLoadedMaps[rowid] if (isLoad) { result.push(handleAsyncTreeExpandChilds(row)) } else { if (row[childrenField] && row[childrenField].length) { treeTempExpandedMaps[rowid] = row } } } }) } else { validRows.forEach(function (item2) { var rowid = getRowid($xetable, item2) if (treeTempExpandedMaps[rowid]) { delete treeTempExpandedMaps[rowid] } }) } if (reserve) { validRows.forEach(function (row) { return handleTreeExpandReserve(row, expanded) }) } reactData.treeExpandedMaps = treeTempExpandedMaps return Promise.all(result).then(function () { return tableMethods.recalculate() }) } var handleVirtualTreeExpand = function (rows, expanded) { return handleBaseTreeExpand(rows, expanded) .then(function () { handleVirtualTreeToList() return tablePrivateMethods.handleTableData() }) .then(function () { return tableMethods.recalculate() }) } var loadScrollYData = function (evnt) { var mergeList = reactData.mergeList var scrollYStore = internalData.scrollYStore var startIndex = scrollYStore.startIndex, endIndex = scrollYStore.endIndex, visibleSize = scrollYStore.visibleSize, offsetSize = scrollYStore.offsetSize, rowHeight = scrollYStore.rowHeight var scrollBodyElem = evnt.currentTarget || evnt.target var scrollTop = scrollBodyElem.scrollTop var toVisibleIndex = Math.floor(scrollTop / rowHeight) var offsetItem = { startIndex: Math.max(0, toVisibleIndex - 1 - offsetSize), endIndex: toVisibleIndex + visibleSize + offsetSize, } calculateMergerOffserIndex(mergeList, offsetItem, 'row') var offsetStartIndex = offsetItem.startIndex, offsetEndIndex = offsetItem.endIndex if ( toVisibleIndex <= startIndex || toVisibleIndex >= endIndex - visibleSize - 1 ) { if (startIndex !== offsetStartIndex || endIndex !== offsetEndIndex) { scrollYStore.startIndex = offsetStartIndex scrollYStore.endIndex = offsetEndIndex tablePrivateMethods.updateScrollYData() } } } var createGetRowCacheProp = function (prop) { return function (row) { var fullAllDataRowIdData = internalData.fullAllDataRowIdData if (row) { var rowid = getRowid($xetable, row) var rest = fullAllDataRowIdData[rowid] if (rest) { return rest[prop] } } return -1 } } var createGetColumnCacheProp = function (prop) { return function (column) { var fullColumnIdData = internalData.fullColumnIdData if (column) { var rest = fullColumnIdData[column.id] if (rest) { return rest[prop] } } return -1 } } var debounceScrollY = xeUtils.debounce( function (evnt) { loadScrollYData(evnt) }, 20, { leading: false, trailing: true } ) var keyCtxTimeout tableMethods = { dispatchEvent: function (type4, params2, evnt) { emit2( type4, Object.assign( { $table: $xetable, $grid: $xegrid, $event: evnt }, params2 ) ) }, clearAll: function () { return clearTableAllStatus($xetable) }, syncData: function () { warnLog('vxe.error.delFunc', ['syncData', 'getData']) return nextTick().then(function () { reactData.tableData = [] emit2('update:data', internalData.tableFullData) return nextTick() }) }, updateData: function () { var scrollXLoad = reactData.scrollXLoad, scrollYLoad = reactData.scrollYLoad return tablePrivateMethods .handleTableData(true) .then(function () { tableMethods.updateFooter() if (scrollXLoad || scrollYLoad) { if (scrollXLoad) { tablePrivateMethods.updateScrollXSpace() } if (scrollYLoad) { tablePrivateMethods.updateScrollYSpace() } return tableMethods.refreshScroll() } }) .then(function () { tableMethods.updateCellAreas() return tableMethods.recalculate(true) }) .then(function () { setTimeout(function () { return $xetable.recalculate() }, 50) }) }, loadData: function (datas) { var inited = internalData.inited, initStatus = internalData.initStatus return loadTableData(datas).then(function () { internalData.inited = true internalData.initStatus = true if (!initStatus) { handleLoadDefaults() } if (!inited) { handleInitDefaults() } return tableMethods.recalculate() }) }, reloadData: function (datas) { var inited = internalData.inited return tableMethods .clearAll() .then(function () { internalData.inited = true internalData.initStatus = true return loadTableData(datas) }) .then(function () { handleLoadDefaults() if (!inited) { handleInitDefaults() } return tableMethods.recalculate() }) }, reloadRow: function (row, record, field2) { var keepSource = props2.keepSource var tableData2 = reactData.tableData var tableSourceData = internalData.tableSourceData if (keepSource) { var rowIndex = tableMethods.getRowIndex(row) var oRow = tableSourceData[rowIndex] if (oRow && row) { if (field2) { var newValue = xeUtils.get(record || row, field2) xeUtils.set(row, field2, newValue) xeUtils.set(oRow, field2, newValue) } else { var newRecord = xeUtils.clone(__assign({}, record), true) xeUtils.destructuring(oRow, Object.assign(row, newRecord)) } } reactData.tableData = tableData2.slice(0) } return nextTick() }, loadTreeChildren: function (row, childRecords) { var keepSource = props2.keepSource var tableSourceData = internalData.tableSourceData, fullDataRowIdData = internalData.fullDataRowIdData, fullAllDataRowIdData = internalData.fullAllDataRowIdData, sourceDataRowIdData = internalData.sourceDataRowIdData var treeOpts = computeTreeOpts.value var transform3 = treeOpts.transform, mapChildrenField = treeOpts.mapChildrenField var childrenField = treeOpts.children || treeOpts.childrenField var parentRest = fullAllDataRowIdData[getRowid($xetable, row)] var parentLevel = parentRest ? parentRest.level : 0 return tableMethods.createData(childRecords).then(function (rows) { if (keepSource) { var rowid_3 = getRowid($xetable, row) var matchObj = xeUtils.findTree( tableSourceData, function (item2) { return rowid_3 === getRowid($xetable, item2) }, { children: childrenField } ) if (matchObj) { matchObj.item[childrenField] = xeUtils.clone(rows, true) } rows.forEach(function (childRow) { var rowid = getRowid($xetable, childRow) sourceDataRowIdData[rowid] = xeUtils.clone(childRow, true) }) } xeUtils.eachTree( rows, function (childRow, index2, items, path, parent2, nodes) { var rowid = getRowid($xetable, childRow) var rest = { row: childRow, rowid, seq: -1, index: index2, _index: -1, $index: -1, items, parent: parent2, level: parentLevel + nodes.length, } fullDataRowIdData[rowid] = rest fullAllDataRowIdData[rowid] = rest }, { children: childrenField } ) row[childrenField] = rows if (transform3) { row[mapChildrenField] = rows } updateAfterDataIndex() return rows }) }, loadColumn: function (columns) { var collectColumn = xeUtils.mapTree(columns, function (column) { return reactive(Cell$1.createColumn($xetable, column)) }) return handleColumn(collectColumn) }, reloadColumn: function (columns) { return tableMethods.clearAll().then(function () { return tableMethods.loadColumn(columns) }) }, getRowNode: function (tr2) { if (tr2) { var fullAllDataRowIdData = internalData.fullAllDataRowIdData var rowid = tr2.getAttribute('rowid') if (rowid) { var rest = fullAllDataRowIdData[rowid] if (rest) { return { rowid: rest.rowid, item: rest.row, index: rest.index, items: rest.items, parent: rest.parent, } } } } return null }, getColumnNode: function (cell) { if (cell) { var fullColumnIdData = internalData.fullColumnIdData var colid = cell.getAttribute('colid') if (colid) { var rest = fullColumnIdData[colid] if (rest) { return { colid: rest.colid, item: rest.column, index: rest.index, items: rest.items, parent: rest.parent, } } } } return null }, getRowSeq: createGetRowCacheProp('seq'), getRowIndex: createGetRowCacheProp('index'), getVTRowIndex: createGetRowCacheProp('_index'), getVMRowIndex: createGetRowCacheProp('$index'), getColumnIndex: createGetColumnCacheProp('index'), getVTColumnIndex: createGetColumnCacheProp('_index'), getVMColumnIndex: createGetColumnCacheProp('$index'), createData: function (records) { return nextTick().then(function () { return reactive(tablePrivateMethods.defineField(records)) }) }, createRow: function (records) { var isArr = xeUtils.isArray(records) if (!isArr) { records = [records || {}] } return tableMethods.createData(records).then(function (rows) { return isArr ? rows : rows[0] }) }, revertData: function (rows, field2) { var keepSource = props2.keepSource var tableSourceData = internalData.tableSourceData, sourceDataRowIdData = internalData.sourceDataRowIdData if (!keepSource) { return nextTick() } var targetRows = rows if (rows) { if (!xeUtils.isArray(rows)) { targetRows = [rows] } } else { targetRows = xeUtils.toArray($xetable.getUpdateRecords()) } if (targetRows.length) { targetRows.forEach(function (row) { if (!tableMethods.isInsertByRow(row)) { var rowid = getRowid($xetable, row) var oRow = sourceDataRowIdData[rowid] if (oRow && row) { if (field2) { xeUtils.set( row, field2, xeUtils.clone(xeUtils.get(oRow, field2), true) ) } else { xeUtils.destructuring(row, xeUtils.clone(oRow, true)) } } } }) } if (rows) { return nextTick() } return tableMethods.reloadData(tableSourceData) }, clearData: function (rows, field2) { var tableFullData = internalData.tableFullData, visibleColumn = internalData.visibleColumn if (!arguments.length) { rows = tableFullData } else if (rows && !xeUtils.isArray(rows)) { rows = [rows] } if (field2) { rows.forEach(function (row) { return xeUtils.set(row, field2, null) }) } else { rows.forEach(function (row) { visibleColumn.forEach(function (column) { if (column.field) { setCellValue(row, column, null) } }) }) } return nextTick() }, isInsertByRow: function (row) { var editStore = reactData.editStore var rowid = getRowid($xetable, row) return editStore.insertMaps[rowid] }, removeInsertRow: function () { var editStore = reactData.editStore editStore.insertMaps = {} return $xetable.remove($xetable.getInsertRecords()) }, isUpdateByRow: function (row, field2) { var keepSource = props2.keepSource var tableFullColumn = internalData.tableFullColumn, fullDataRowIdData = internalData.fullDataRowIdData, sourceDataRowIdData = internalData.sourceDataRowIdData if (keepSource) { var rowid = getRowid($xetable, row) if (!fullDataRowIdData[rowid]) { return false } var oRow = sourceDataRowIdData[rowid] if (oRow) { if (arguments.length > 1) { return !eqCellValue(oRow, row, field2) } for ( var index2 = 0, len2 = tableFullColumn.length; index2 < len2; index2++ ) { var property2 = tableFullColumn[index2].field if (property2 && !eqCellValue(oRow, row, property2)) { return true } } } } return false }, getColumns: function (columnIndex) { var columns = internalData.visibleColumn return xeUtils.isUndefined(columnIndex) ? columns.slice(0) : columns[columnIndex] }, getColumnById: function (colid) { var fullColumnIdData = internalData.fullColumnIdData return fullColumnIdData[colid] ? fullColumnIdData[colid].column : null }, getColumnByField: function (field2) { var fullColumnFieldData = internalData.fullColumnFieldData return fullColumnFieldData[field2] ? fullColumnFieldData[field2].column : null }, getTableColumn: function () { return { collectColumn: internalData.collectColumn.slice(0), fullColumn: internalData.tableFullColumn.slice(0), visibleColumn: internalData.visibleColumn.slice(0), tableColumn: reactData.tableColumn.slice(0), } }, getData: function (rowIndex) { var tableSynchData = props2.data || internalData.tableSynchData return xeUtils.isUndefined(rowIndex) ? tableSynchData.slice(0) : tableSynchData[rowIndex] }, getCheckboxRecords: function (isFull) { var treeConfig = props2.treeConfig var tableFullData = internalData.tableFullData, afterFullData = internalData.afterFullData, afterTreeFullData = internalData.afterTreeFullData, tableFullTreeData = internalData.tableFullTreeData, fullDataRowIdData = internalData.fullDataRowIdData, afterFullRowMaps = internalData.afterFullRowMaps var treeOpts = computeTreeOpts.value var checkboxOpts = computeCheckboxOpts.value var transform3 = treeOpts.transform, mapChildrenField = treeOpts.mapChildrenField var checkField = checkboxOpts.checkField var childrenField = treeOpts.children || treeOpts.childrenField var rowList = [] var currTableData = isFull ? transform3 ? tableFullTreeData : tableFullData : transform3 ? afterTreeFullData : afterFullData if (checkField) { if (treeConfig) { rowList = xeUtils.filterTree( currTableData, function (row) { return xeUtils.get(row, checkField) }, { children: transform3 ? mapChildrenField : childrenField } ) } else { rowList = currTableData.filter(function (row) { return xeUtils.get(row, checkField) }) } } else { var selectCheckboxMaps = reactData.selectCheckboxMaps xeUtils.each(selectCheckboxMaps, function (row, rowid) { if (isFull ? fullDataRowIdData[rowid] : afterFullRowMaps[rowid]) { rowList.push(row) } }) } return rowList }, getParentRow: function (rowOrRowid) { var treeConfig = props2.treeConfig var fullDataRowIdData = internalData.fullDataRowIdData if (rowOrRowid && treeConfig) { var rowid = void 0 if (xeUtils.isString(rowOrRowid)) { rowid = rowOrRowid } else { rowid = getRowid($xetable, rowOrRowid) } if (rowid) { return fullDataRowIdData[rowid] ? fullDataRowIdData[rowid].parent : null } } return null }, getRowById: function (cellValue) { var fullDataRowIdData = internalData.fullDataRowIdData var rowid = xeUtils.eqNull(cellValue) ? '' : encodeURIComponent(cellValue) return fullDataRowIdData[rowid] ? fullDataRowIdData[rowid].row : null }, getRowid: function (row) { return getRowid($xetable, row) }, getTableData: function () { var tableData2 = reactData.tableData, footerTableData = reactData.footerTableData var tableFullData = internalData.tableFullData, afterFullData = internalData.afterFullData return { fullData: tableFullData.slice(0), visibleData: afterFullData.slice(0), tableData: tableData2.slice(0), footerData: footerTableData.slice(0), } }, setColumnFixed: function (fieldOrColumn, fixed) { var column = handleFieldOrColumn($xetable, fieldOrColumn) var targetColumn = getRootColumn($xetable, column) var isMaxFixedColumn = computeIsMaxFixedColumn.value if (targetColumn && targetColumn.fixed !== fixed) { if (!targetColumn.fixed && isMaxFixedColumn) { if (VXETable.modal) { VXETable.modal.message({ status: 'error', content: GlobalConfig.i18n('vxe.table.maxFixedCol'), }) } return nextTick() } xeUtils.eachTree([targetColumn], function (column2) { column2.fixed = fixed }) tablePrivateMethods.saveCustomFixed() return tableMethods.refreshColumn() } return nextTick() }, clearColumnFixed: function (fieldOrColumn) { var column = handleFieldOrColumn($xetable, fieldOrColumn) var targetColumn = getRootColumn($xetable, column) if (targetColumn && targetColumn.fixed) { xeUtils.eachTree([targetColumn], function (column2) { column2.fixed = null }) tablePrivateMethods.saveCustomFixed() return tableMethods.refreshColumn() } return nextTick() }, hideColumn: function (fieldOrColumn) { var column = handleFieldOrColumn($xetable, fieldOrColumn) if (column && column.visible) { column.visible = false return tablePrivateMethods.handleCustom() } return nextTick() }, showColumn: function (fieldOrColumn) { var column = handleFieldOrColumn($xetable, fieldOrColumn) if (column && !column.visible) { column.visible = true return tablePrivateMethods.handleCustom() } return nextTick() }, setColumnWidth: function (fieldOrColumn, width) { var column = handleFieldOrColumn($xetable, fieldOrColumn) if (column) { var colWidth = xeUtils.toInteger(width) var rdWidth = colWidth if (isScale(width)) { var tableBody = refTableBody.value var bodyElem = tableBody ? tableBody.$el : null var bodyWidth = bodyElem ? bodyElem.clientWidth - 1 : 0 rdWidth = Math.floor(colWidth * bodyWidth) } column.renderWidth = rdWidth } return nextTick() }, getColumnWidth: function (fieldOrColumn) { var column = handleFieldOrColumn($xetable, fieldOrColumn) if (column) { return column.renderWidth } return 0 }, resetColumn: function (options2) { var collectColumn = internalData.collectColumn var customOpts = computeCustomOpts.value var checkMethod = customOpts.checkMethod var opts = Object.assign( { visible: true, resizable: options2 === true, fixed: options2 === true, }, options2 ) xeUtils.eachTree(collectColumn, function (column) { if (opts.resizable) { column.resizeWidth = 0 } if (opts.fixed) { column.fixed = column.defaultFixed } if (!checkMethod || checkMethod({ column })) { column.visible = column.defaultVisible } }) if (opts.resizable) { tablePrivateMethods.saveCustomResizable(true) } if (opts.fixed) { tablePrivateMethods.saveCustomFixed() } return tablePrivateMethods.handleCustom() }, refreshColumn: function () { return parseColumns() .then(function () { return tableMethods.refreshScroll() }) .then(function () { return tableMethods.recalculate() }) }, refreshScroll: function () { var lastScrollLeft = internalData.lastScrollLeft, lastScrollTop = internalData.lastScrollTop var tableBody = refTableBody.value var tableFooter = refTableFooter.value var leftBody = refTableLeftBody.value var rightBody = refTableRightBody.value var tableBodyElem = tableBody ? tableBody.$el : null var leftBodyElem = leftBody ? leftBody.$el : null var rightBodyElem = rightBody ? rightBody.$el : null var tableFooterElem = tableFooter ? tableFooter.$el : null return new Promise(function (resolve2) { if (lastScrollLeft || lastScrollTop) { return restoreScrollLocation( $xetable, lastScrollLeft, lastScrollTop ) .then() .then(function () { setTimeout(resolve2, 30) }) } setScrollTop(tableBodyElem, lastScrollTop) setScrollTop(leftBodyElem, lastScrollTop) setScrollTop(rightBodyElem, lastScrollTop) setScrollLeft(tableFooterElem, lastScrollLeft) setTimeout(resolve2, 30) }) }, recalculate: function (refull) { autoCellWidth() if (refull === true) { return computeScrollLoad().then(function () { autoCellWidth() return computeScrollLoad() }) } return computeScrollLoad() }, openTooltip: function (target2, content2) { var $commTip = refCommTooltip.value if ($commTip) { return $commTip.open(target2, content2) } return nextTick() }, closeTooltip: function () { var tooltipStore = reactData.tooltipStore var $tooltip = refTooltip.value var $commTip = refCommTooltip.value if (tooltipStore.visible) { Object.assign(tooltipStore, { row: null, column: null, content: null, visible: false, }) if ($tooltip) { $tooltip.close() } } if ($commTip) { $commTip.close() } return nextTick() }, isAllCheckboxChecked: function () { return reactData.isAllSelected }, isAllCheckboxIndeterminate: function () { return !reactData.isAllSelected && reactData.isIndeterminate }, getCheckboxIndeterminateRecords: function (isFull) { var treeConfig = props2.treeConfig var fullDataRowIdData = internalData.fullDataRowIdData var treeIndeterminateMaps = reactData.treeIndeterminateMaps if (treeConfig) { var fullRest_1 = [] var defRest_1 = [] xeUtils.each(treeIndeterminateMaps, function (item2, rowid) { if (item2) { fullRest_1.push(item2) if (fullDataRowIdData[rowid]) { defRest_1.push(item2) } } }) if (isFull) { return fullRest_1 } return defRest_1 } return [] }, setCheckboxRow: function (rows, value2) { return handleCheckedCheckboxRow(rows, value2, true) }, isCheckedByCheckboxRow: function (row) { var selectCheckboxMaps = reactData.selectCheckboxMaps var checkboxOpts = computeCheckboxOpts.value var checkField = checkboxOpts.checkField if (checkField) { return xeUtils.get(row, checkField) } return !!selectCheckboxMaps[getRowid($xetable, row)] }, isIndeterminateByCheckboxRow: function (row) { var treeIndeterminateMaps = reactData.treeIndeterminateMaps return ( !!treeIndeterminateMaps[getRowid($xetable, row)] && !tableMethods.isCheckedByCheckboxRow(row) ) }, toggleCheckboxRow: function (row) { var selectCheckboxMaps = reactData.selectCheckboxMaps var checkboxOpts = computeCheckboxOpts.value var checkField = checkboxOpts.checkField var value2 = checkField ? !xeUtils.get(row, checkField) : !selectCheckboxMaps[getRowid($xetable, row)] tablePrivateMethods.handleSelectRow({ row }, value2, true) return nextTick() }, setAllCheckboxRow: function (value2) { return handleCheckedAllCheckboxRow(value2, true) }, getRadioReserveRecord: function (isFull) { var treeConfig = props2.treeConfig var fullDataRowIdData = internalData.fullDataRowIdData, radioReserveRow = internalData.radioReserveRow, afterFullData = internalData.afterFullData var radioOpts = computeRadioOpts.value var treeOpts = computeTreeOpts.value var childrenField = treeOpts.children || treeOpts.childrenField if (radioOpts.reserve && radioReserveRow) { var rowid_4 = getRowid($xetable, radioReserveRow) if (isFull) { if (!fullDataRowIdData[rowid_4]) { return radioReserveRow } } else { var rowkey_2 = getRowkey($xetable) if (treeConfig) { var matchObj = xeUtils.findTree( afterFullData, function (row) { return rowid_4 === xeUtils.get(row, rowkey_2) }, { children: childrenField } ) if (matchObj) { return radioReserveRow } } else { if ( !afterFullData.some(function (row) { return rowid_4 === xeUtils.get(row, rowkey_2) }) ) { return radioReserveRow } } } } return null }, clearRadioReserve: function () { internalData.radioReserveRow = null return nextTick() }, getCheckboxReserveRecords: function (isFull) { var treeConfig = props2.treeConfig var afterFullData = internalData.afterFullData, fullDataRowIdData = internalData.fullDataRowIdData, checkboxReserveRowMap = internalData.checkboxReserveRowMap var checkboxOpts = computeCheckboxOpts.value var treeOpts = computeTreeOpts.value var childrenField = treeOpts.children || treeOpts.childrenField var reserveSelection = [] if (checkboxOpts.reserve) { var afterFullIdMaps_1 = {} if (treeConfig) { xeUtils.eachTree( afterFullData, function (row) { afterFullIdMaps_1[getRowid($xetable, row)] = 1 }, { children: childrenField } ) } else { afterFullData.forEach(function (row) { afterFullIdMaps_1[getRowid($xetable, row)] = 1 }) } xeUtils.each(checkboxReserveRowMap, function (oldRow, oldRowid) { if (oldRow) { if (isFull) { if (!fullDataRowIdData[oldRowid]) { reserveSelection.push(oldRow) } } else { if (!afterFullIdMaps_1[oldRowid]) { reserveSelection.push(oldRow) } } } }) } return reserveSelection }, clearCheckboxReserve: function () { internalData.checkboxReserveRowMap = {} return nextTick() }, toggleAllCheckboxRow: function () { tablePrivateMethods.triggerCheckAllEvent(null, !reactData.isAllSelected) return nextTick() }, clearCheckboxRow: function () { var treeConfig = props2.treeConfig var tableFullData = internalData.tableFullData var treeOpts = computeTreeOpts.value var childrenField = treeOpts.children || treeOpts.childrenField var checkboxOpts = computeCheckboxOpts.value var checkField = checkboxOpts.checkField, reserve = checkboxOpts.reserve var indeterminateField = checkboxOpts.indeterminateField || checkboxOpts.halfField if (checkField) { var handleClearChecked = function (item2) { if (treeConfig && indeterminateField) { xeUtils.set(item2, indeterminateField, false) } xeUtils.set(item2, checkField, false) } if (treeConfig) { xeUtils.eachTree(tableFullData, handleClearChecked, { children: childrenField, }) } else { tableFullData.forEach(handleClearChecked) } } if (reserve) { tableFullData.forEach(function (row) { return handleCheckboxReserveRow(row, false) }) } reactData.isAllSelected = false reactData.isIndeterminate = false reactData.selectCheckboxMaps = {} reactData.treeIndeterminateMaps = {} return nextTick() }, setCurrentRow: function (row) { var rowOpts = computeRowOpts.value var el2 = refElem.value tableMethods.clearCurrentRow() reactData.currentRow = row if (rowOpts.isCurrent || props2.highlightCurrentRow) { if (el2) { xeUtils.arrayEach( el2.querySelectorAll( '[rowid="'.concat(getRowid($xetable, row), '"]') ), function (elem) { return addClass(elem, 'row--current') } ) } } return nextTick() }, isCheckedByRadioRow: function (row) { return $xetable.eqRow(reactData.selectRadioRow, row) }, setRadioRow: function (row) { return handleCheckedRadioRow(row, true) }, clearCurrentRow: function () { var el2 = refElem.value reactData.currentRow = null internalData.hoverRow = null if (el2) { xeUtils.arrayEach( el2.querySelectorAll('.row--current'), function (elem) { return removeClass(elem, 'row--current') } ) } return nextTick() }, clearRadioRow: function () { reactData.selectRadioRow = null return nextTick() }, getCurrentRecord: function () { var rowOpts = computeRowOpts.value return rowOpts.isCurrent || props2.highlightCurrentRow ? reactData.currentRow : null }, getRadioRecord: function (isFull) { var fullDataRowIdData = internalData.fullDataRowIdData, afterFullRowMaps = internalData.afterFullRowMaps var selectRadioRow = reactData.selectRadioRow if (selectRadioRow) { var rowid = getRowid($xetable, selectRadioRow) if (isFull) { if (!fullDataRowIdData[rowid]) { return selectRadioRow } } else { if (afterFullRowMaps[rowid]) { return selectRadioRow } } } return null }, getCurrentColumn: function () { var columnOpts = computeColumnOpts.value return columnOpts.isCurrent || props2.highlightCurrentColumn ? reactData.currentColumn : null }, setCurrentColumn: function (fieldOrColumn) { var column = handleFieldOrColumn($xetable, fieldOrColumn) if (column) { tableMethods.clearCurrentColumn() reactData.currentColumn = column } return nextTick() }, clearCurrentColumn: function () { reactData.currentColumn = null return nextTick() }, sort: function (sortConfs, sortOrder) { var sortOpts = computeSortOpts.value var multiple = sortOpts.multiple, remote = sortOpts.remote, orders = sortOpts.orders if (sortConfs) { if (xeUtils.isString(sortConfs)) { sortConfs = [{ field: sortConfs, order: sortOrder }] } } if (!xeUtils.isArray(sortConfs)) { sortConfs = [sortConfs] } if (sortConfs.length) { if (!multiple) { clearAllSort() } ;(multiple ? sortConfs : [sortConfs[0]]).forEach(function ( confs, index2 ) { var field2 = confs.field, order2 = confs.order var column = field2 if (xeUtils.isString(field2)) { column = tableMethods.getColumnByField(field2) } if (column && column.sortable) { if (orders.indexOf(order2) === -1) { order2 = getNextSortOrder(column) } if (column.order !== order2) { column.order = order2 } column.sortTime = Date.now() + index2 } }) if (!remote) { tablePrivateMethods.handleTableData(true) } return nextTick().then(function () { tableMethods.updateCellAreas() return updateStyle2() }) } return nextTick() }, clearSort: function (fieldOrColumn) { var sortOpts = computeSortOpts.value if (fieldOrColumn) { var column = handleFieldOrColumn($xetable, fieldOrColumn) if (column) { column.order = null } } else { clearAllSort() } if (!sortOpts.remote) { tablePrivateMethods.handleTableData(true) } return nextTick().then(updateStyle2) }, isSort: function (fieldOrColumn) { if (fieldOrColumn) { var column = handleFieldOrColumn($xetable, fieldOrColumn) return column ? column.sortable && !!column.order : false } return tableMethods.getSortColumns().length > 0 }, getSortColumns: function () { var sortOpts = computeSortOpts.value var multiple = sortOpts.multiple, chronological = sortOpts.chronological var sortList2 = [] var tableFullColumn = internalData.tableFullColumn tableFullColumn.forEach(function (column) { var field2 = column.field, order2 = column.order if (column.sortable && order2) { sortList2.push({ column, field: field2, property: field2, order: order2, sortTime: column.sortTime, }) } }) if (multiple && chronological && sortList2.length > 1) { return xeUtils.orderBy(sortList2, 'sortTime') } return sortList2 }, closeFilter: function () { var filterStore = reactData.filterStore var column = filterStore.column, visible = filterStore.visible Object.assign(filterStore, { isAllSelected: false, isIndeterminate: false, options: [], visible: false, }) if (visible) { $xetable.dispatchEvent( 'filter-visible', { column, property: column.field, field: column.field, filterList: $xetable.getCheckedFilters(), visible: false, }, null ) } return nextTick() }, isActiveFilterByColumn: function (fieldOrColumn) { var column = handleFieldOrColumn($xetable, fieldOrColumn) if (column) { return ( column.filters && column.filters.some(function (option2) { return option2.checked }) ) } return $xetable.getCheckedFilters().length > 0 }, isFilter: function (fieldOrColumn) { return tableMethods.isActiveFilterByColumn(fieldOrColumn) }, isRowExpandLoaded: function (row) { var fullAllDataRowIdData = internalData.fullAllDataRowIdData var rest = fullAllDataRowIdData[getRowid($xetable, row)] return rest && !!rest.expandLoaded }, clearRowExpandLoaded: function (row) { var rowExpandLazyLoadedMaps = reactData.rowExpandLazyLoadedMaps var fullAllDataRowIdData = internalData.fullAllDataRowIdData var expandOpts = computeExpandOpts.value var lazy = expandOpts.lazy var rowid = getRowid($xetable, row) var rest = fullAllDataRowIdData[rowid] if (lazy && rest) { rest.expandLoaded = false delete rowExpandLazyLoadedMaps[rowid] } return nextTick() }, reloadRowExpand: function (row) { var rowExpandLazyLoadedMaps = reactData.rowExpandLazyLoadedMaps var expandOpts = computeExpandOpts.value var lazy = expandOpts.lazy var rowid = getRowid($xetable, row) if (lazy && !rowExpandLazyLoadedMaps[rowid]) { tableMethods.clearRowExpandLoaded(row).then(function () { return handleAsyncRowExpand(row) }) } return nextTick() }, reloadExpandContent: function (row) { return tableMethods.reloadRowExpand(row) }, toggleRowExpand: function (row) { return tableMethods.setRowExpand(row, !tableMethods.isExpandByRow(row)) }, setAllRowExpand: function (expanded) { var treeOpts = computeTreeOpts.value var tableFullData = internalData.tableFullData, tableFullTreeData = internalData.tableFullTreeData var childrenField = treeOpts.children || treeOpts.childrenField var expandedRows = [] if (props2.treeConfig) { xeUtils.eachTree( tableFullTreeData, function (row) { expandedRows.push(row) }, { children: childrenField } ) } else { expandedRows = tableFullData } return tableMethods.setRowExpand(expandedRows, expanded) }, setRowExpand: function (rows, expanded) { var rowExpandedMaps = reactData.rowExpandedMaps, rowExpandLazyLoadedMaps = reactData.rowExpandLazyLoadedMaps, column = reactData.expandColumn var fullAllDataRowIdData = internalData.fullAllDataRowIdData var rExpandedMaps = __assign({}, rowExpandedMaps) var expandOpts = computeExpandOpts.value var reserve = expandOpts.reserve, lazy = expandOpts.lazy, accordion = expandOpts.accordion, toggleMethod = expandOpts.toggleMethod var lazyRests = [] var columnIndex = tableMethods.getColumnIndex(column) var $columnIndex = tableMethods.getVMColumnIndex(column) if (rows) { if (!xeUtils.isArray(rows)) { rows = [rows] } if (accordion) { rExpandedMaps = {} rows = rows.slice(rows.length - 1, rows.length) } var validRows = toggleMethod ? rows.filter(function (row) { return toggleMethod({ $table: $xetable, expanded, column, columnIndex, $columnIndex, row, rowIndex: tableMethods.getRowIndex(row), $rowIndex: tableMethods.getVMRowIndex(row), }) }) : rows if (expanded) { validRows.forEach(function (row) { var rowid = getRowid($xetable, row) if (!rExpandedMaps[rowid]) { var rest = fullAllDataRowIdData[rowid] var isLoad = lazy && !rest.expandLoaded && !rowExpandLazyLoadedMaps[rowid] if (isLoad) { lazyRests.push(handleAsyncRowExpand(row)) } else { rExpandedMaps[rowid] = row } } }) } else { validRows.forEach(function (item2) { var rowid = getRowid($xetable, item2) if (rExpandedMaps[rowid]) { delete rExpandedMaps[rowid] } }) } if (reserve) { validRows.forEach(function (row) { return handleRowExpandReserve(row, expanded) }) } } reactData.rowExpandedMaps = rExpandedMaps return Promise.all(lazyRests).then(function () { return tableMethods.recalculate() }) }, isExpandByRow: function (row) { var rowExpandedMaps = reactData.rowExpandedMaps var rowid = getRowid($xetable, row) return !!rowExpandedMaps[rowid] }, clearRowExpand: function () { var tableFullData = internalData.tableFullData var expandOpts = computeExpandOpts.value var reserve = expandOpts.reserve var expList = tableMethods.getRowExpandRecords() reactData.rowExpandedMaps = {} if (reserve) { tableFullData.forEach(function (row) { return handleRowExpandReserve(row, false) }) } return nextTick().then(function () { if (expList.length) { tableMethods.recalculate() } }) }, clearRowExpandReserve: function () { internalData.rowExpandedReserveRowMap = {} return nextTick() }, getRowExpandRecords: function () { var rest = [] xeUtils.each(reactData.rowExpandedMaps, function (item2) { if (item2) { rest.push(item2) } }) return rest }, getTreeExpandRecords: function () { var rest = [] xeUtils.each(reactData.treeExpandedMaps, function (item2) { if (item2) { rest.push(item2) } }) return rest }, isTreeExpandLoaded: function (row) { var fullAllDataRowIdData = internalData.fullAllDataRowIdData var rest = fullAllDataRowIdData[getRowid($xetable, row)] return rest && !!rest.treeLoaded }, clearTreeExpandLoaded: function (row) { var treeExpandedMaps = reactData.treeExpandedMaps var fullAllDataRowIdData = internalData.fullAllDataRowIdData var treeOpts = computeTreeOpts.value var transform3 = treeOpts.transform, lazy = treeOpts.lazy var rowid = getRowid($xetable, row) var rest = fullAllDataRowIdData[rowid] if (lazy && rest) { rest.treeLoaded = false if (treeExpandedMaps[rowid]) { delete treeExpandedMaps[rowid] } } if (transform3) { handleVirtualTreeToList() return tablePrivateMethods.handleTableData() } return nextTick() }, reloadTreeExpand: function (row) { var treeExpandLazyLoadedMaps = reactData.treeExpandLazyLoadedMaps var treeOpts = computeTreeOpts.value var hasChildField = treeOpts.hasChild || treeOpts.hasChildField var transform3 = treeOpts.transform, lazy = treeOpts.lazy var rowid = getRowid($xetable, row) if (lazy && row[hasChildField] && !treeExpandLazyLoadedMaps[rowid]) { tableMethods .clearTreeExpandLoaded(row) .then(function () { return handleAsyncTreeExpandChilds(row) }) .then(function () { if (transform3) { handleVirtualTreeToList() return tablePrivateMethods.handleTableData() } }) .then(function () { return tableMethods.recalculate() }) } return nextTick() }, reloadTreeChilds: function (row) { return tableMethods.reloadTreeExpand(row) }, toggleTreeExpand: function (row) { return tableMethods.setTreeExpand( row, !tableMethods.isTreeExpandByRow(row) ) }, setAllTreeExpand: function (expanded) { var tableFullData = internalData.tableFullData var treeOpts = computeTreeOpts.value var transform3 = treeOpts.transform, lazy = treeOpts.lazy var childrenField = treeOpts.children || treeOpts.childrenField var expandeds = [] xeUtils.eachTree( tableFullData, function (row) { var rowChildren = row[childrenField] if (lazy || (rowChildren && rowChildren.length)) { expandeds.push(row) } }, { children: childrenField } ) return tableMethods .setTreeExpand(expandeds, expanded) .then(function () { if (transform3) { handleVirtualTreeToList() return tableMethods.recalculate() } }) }, setTreeExpand: function (rows, expanded) { var treeOpts = computeTreeOpts.value var transform3 = treeOpts.transform if (rows) { if (!xeUtils.isArray(rows)) { rows = [rows] } if (rows.length) { if (transform3) { return handleVirtualTreeExpand(rows, expanded) } else { return handleBaseTreeExpand(rows, expanded) } } } return nextTick() }, isTreeExpandByRow: function (row) { var treeExpandedMaps = reactData.treeExpandedMaps return !!treeExpandedMaps[getRowid($xetable, row)] }, clearTreeExpand: function () { var tableFullTreeData = internalData.tableFullTreeData var treeOpts = computeTreeOpts.value var childrenField = treeOpts.children || treeOpts.childrenField var transform3 = treeOpts.transform, reserve = treeOpts.reserve var expList = tableMethods.getTreeExpandRecords() reactData.treeExpandedMaps = {} if (reserve) { xeUtils.eachTree( tableFullTreeData, function (row) { return handleTreeExpandReserve(row, false) }, { children: childrenField } ) } return tablePrivateMethods .handleTableData() .then(function () { if (transform3) { handleVirtualTreeToList() return tablePrivateMethods.handleTableData() } }) .then(function () { if (expList.length) { return tableMethods.recalculate() } }) }, clearTreeExpandReserve: function () { internalData.treeExpandedReserveRowMap = {} return nextTick() }, getScroll: function () { var scrollXLoad = reactData.scrollXLoad, scrollYLoad = reactData.scrollYLoad var tableBody = refTableBody.value var bodyElem = tableBody.$el return { virtualX: scrollXLoad, virtualY: scrollYLoad, scrollTop: bodyElem.scrollTop, scrollLeft: bodyElem.scrollLeft, } }, scrollTo: function (scrollLeft, scrollTop) { var tableBody = refTableBody.value var tableFooter = refTableFooter.value var rightBody = refTableRightBody.value var tableBodyElem = tableBody ? tableBody.$el : null var rightBodyElem = rightBody ? rightBody.$el : null var tableFooterElem = tableFooter ? tableFooter.$el : null if (xeUtils.isNumber(scrollLeft)) { setScrollLeft(tableFooterElem || tableBodyElem, scrollLeft) } if (xeUtils.isNumber(scrollTop)) { setScrollTop(rightBodyElem || tableBodyElem, scrollTop) } if (reactData.scrollXLoad || reactData.scrollYLoad) { return new Promise(function (resolve2) { setTimeout(function () { nextTick(function () { resolve2() }) }, 50) }) } return nextTick() }, scrollToRow: function (row, fieldOrColumn) { var rest = [] if (row) { if (props2.treeConfig) { rest.push(tablePrivateMethods.scrollToTreeRow(row)) } else { rest.push(rowToVisible($xetable, row)) } } if (fieldOrColumn) { rest.push(tableMethods.scrollToColumn(fieldOrColumn)) } return Promise.all(rest) }, scrollToColumn: function (fieldOrColumn) { var fullColumnIdData = internalData.fullColumnIdData var column = handleFieldOrColumn($xetable, fieldOrColumn) if (column && fullColumnIdData[column.id]) { return colToVisible($xetable, column) } return nextTick() }, clearScroll: function () { var scrollXStore = internalData.scrollXStore, scrollYStore = internalData.scrollYStore var tableBody = refTableBody.value var tableFooter = refTableFooter.value var rightBody = refTableRightBody.value var tableBodyElem = tableBody ? tableBody.$el : null var rightBodyElem = rightBody ? rightBody.$el : null var tableFooterElem = tableFooter ? tableFooter.$el : null if (rightBodyElem) { restoreScrollListener(rightBodyElem) rightBodyElem.scrollTop = 0 } if (tableFooterElem) { tableFooterElem.scrollLeft = 0 } if (tableBodyElem) { restoreScrollListener(tableBodyElem) tableBodyElem.scrollTop = 0 tableBodyElem.scrollLeft = 0 } scrollXStore.startIndex = 0 scrollYStore.startIndex = 0 return nextTick() }, updateFooter: function () { var showFooter = props2.showFooter, footerMethod = props2.footerMethod var visibleColumn = internalData.visibleColumn, afterFullData = internalData.afterFullData if (showFooter && footerMethod) { reactData.footerTableData = visibleColumn.length ? footerMethod({ columns: visibleColumn, data: afterFullData, $table: $xetable, $grid: $xegrid, }) : [] } return nextTick() }, updateStatus: function (slotParams, cellValue) { var customVal = !xeUtils.isUndefined(cellValue) return nextTick().then(function () { var editRules = props2.editRules var validStore = reactData.validStore var tableBody = refTableBody.value if (slotParams && tableBody && editRules) { var row_1 = slotParams.row, column_3 = slotParams.column var type4 = 'change' if ($xetable.hasCellRules) { if ($xetable.hasCellRules(type4, row_1, column_3)) { var cell_1 = tablePrivateMethods.getCell(row_1, column_3) if (cell_1) { return $xetable .validCellRules(type4, row_1, column_3, cellValue) .then(function () { if (customVal && validStore.visible) { setCellValue(row_1, column_3, cellValue) } $xetable.clearValidate(row_1, column_3) }) .catch(function (_a2) { var rule2 = _a2.rule if (customVal) { setCellValue(row_1, column_3, cellValue) } $xetable.showValidTooltip({ rule: rule2, row: row_1, column: column_3, cell: cell_1, }) }) } } } } }) }, setMergeCells: function (merges) { if (props2.spanMethod) { errLog('vxe.error.errConflicts', ['merge-cells', 'span-method']) } setMerges(merges, reactData.mergeList, internalData.afterFullData) return nextTick().then(function () { return tableMethods.updateCellAreas() }) }, removeMergeCells: function (merges) { if (props2.spanMethod) { errLog('vxe.error.errConflicts', ['merge-cells', 'span-method']) } var rest = removeMerges( merges, reactData.mergeList, internalData.afterFullData ) return nextTick().then(function () { tableMethods.updateCellAreas() return rest }) }, getMergeCells: function () { return reactData.mergeList.slice(0) }, clearMergeCells: function () { reactData.mergeList = [] return nextTick() }, setMergeFooterItems: function (merges) { if (props2.footerSpanMethod) { errLog('vxe.error.errConflicts', [ 'merge-footer-items', 'footer-span-method', ]) } setMerges(merges, reactData.mergeFooterList) return nextTick().then(function () { return tableMethods.updateCellAreas() }) }, removeMergeFooterItems: function (merges) { if (props2.footerSpanMethod) { errLog('vxe.error.errConflicts', [ 'merge-footer-items', 'footer-span-method', ]) } var rest = removeMerges(merges, reactData.mergeFooterList) return nextTick().then(function () { tableMethods.updateCellAreas() return rest }) }, getMergeFooterItems: function () { return reactData.mergeFooterList.slice(0) }, clearMergeFooterItems: function () { reactData.mergeFooterList = [] return nextTick() }, updateCellAreas: function () { var mouseConfig = props2.mouseConfig var mouseOpts = computeMouseOpts.value if (mouseConfig && mouseOpts.area && $xetable.handleUpdateCellAreas) { return $xetable.handleUpdateCellAreas() } return nextTick() }, focus: function () { internalData.isActivated = true return nextTick() }, blur: function () { internalData.isActivated = false return nextTick() }, connect: function ($toolbar) { if ($toolbar) { $xetoolbar = $toolbar $xetoolbar.syncUpdate({ collectColumn: internalData.collectColumn, $table: $xetable, }) } else { errLog('vxe.error.barUnableLink') } return nextTick() }, } var handleGlobalMousedownEvent = function (evnt) { var editStore = reactData.editStore, ctxMenuStore = reactData.ctxMenuStore, filterStore = reactData.filterStore var mouseConfig = props2.mouseConfig, editRules = props2.editRules var el2 = refElem.value var editOpts = computeEditOpts.value var validOpts = computeValidOpts.value var actived = editStore.actived var $validTooltip = refValidTooltip.value var tableFilter = refTableFilter.value var tableMenu = refTableMenu.value if (tableFilter) { if (getEventTargetNode(evnt, el2, 'vxe-cell--filter').flag); else if (getEventTargetNode(evnt, tableFilter.$el).flag); else { if ( !getEventTargetNode(evnt, document.body, 'vxe-table--ignore-clear') .flag ) { tablePrivateMethods.preventEvent( evnt, 'event.clearFilter', filterStore.args, tableMethods.closeFilter ) } } } if (actived.row) { if (!(editOpts.autoClear === false)) { var cell = actived.args.cell if (!cell || !getEventTargetNode(evnt, cell).flag) { if ( $validTooltip && getEventTargetNode(evnt, $validTooltip.$el).flag ); else if ( !internalData._lastCallTime || internalData._lastCallTime + 50 < Date.now() ) { if ( !getEventTargetNode( evnt, document.body, 'vxe-table--ignore-clear' ).flag ) { tablePrivateMethods.preventEvent( evnt, 'event.clearActived', actived.args, function () { var isClear if (editOpts.mode === 'row') { var rowTargetNode = getEventTargetNode( evnt, el2, 'vxe-body--row' ) var rowNodeRest = rowTargetNode.flag ? tableMethods.getRowNode(rowTargetNode.targetElem) : null isClear = rowNodeRest ? !$xetable.eqRow(rowNodeRest.item, actived.args.row) : false } else { isClear = !getEventTargetNode(evnt, el2, 'col--edit').flag } if (!isClear) { isClear = getEventTargetNode( evnt, el2, 'vxe-header--row' ).flag } if (!isClear) { isClear = getEventTargetNode( evnt, el2, 'vxe-footer--row' ).flag } if (!isClear && props2.height && !reactData.overflowY) { var bodyWrapperElem = evnt.target if ( hasClass(bodyWrapperElem, 'vxe-table--body-wrapper') ) { isClear = evnt.offsetY < bodyWrapperElem.clientHeight } } if (isClear || !getEventTargetNode(evnt, el2).flag) { setTimeout(function () { return $xetable.clearEdit(evnt) }) } } ) } } } } } else if (mouseConfig) { if ( !getEventTargetNode(evnt, el2).flag && !( $xegrid && getEventTargetNode(evnt, $xegrid.getRefMaps().refElem.value).flag ) && !( tableMenu && getEventTargetNode(evnt, tableMenu.getRefMaps().refElem.value).flag ) && !( $xetoolbar && getEventTargetNode(evnt, $xetoolbar.getRefMaps().refElem.value).flag ) ) { $xetable.clearSelected() if ($xetable.clearCellAreas) { if ( !getEventTargetNode( evnt, document.body, 'vxe-table--ignore-areas-clear' ).flag ) { tablePrivateMethods.preventEvent( evnt, 'event.clearAreas', {}, function () { $xetable.clearCellAreas() $xetable.clearCopyCellArea() } ) } } } } if ($xetable.closeMenu) { if ( ctxMenuStore.visible && tableMenu && !getEventTargetNode(evnt, tableMenu.getRefMaps().refElem.value).flag ) { $xetable.closeMenu() } } var isActivated = getEventTargetNode( evnt, $xegrid ? $xegrid.getRefMaps().refElem.value : el2 ).flag if (!isActivated && editRules && validOpts.autoClear) { reactData.validErrorMaps = {} } internalData.isActivated = isActivated } var handleGlobalBlurEvent = function () { tableMethods.closeFilter() if ($xetable.closeMenu) { $xetable.closeMenu() } } var handleGlobalMousewheelEvent = function () { tableMethods.closeTooltip() if ($xetable.closeMenu) { $xetable.closeMenu() } } var keydownEvent = function (evnt) { var mouseConfig = props2.mouseConfig, keyboardConfig = props2.keyboardConfig var filterStore = reactData.filterStore, ctxMenuStore = reactData.ctxMenuStore, editStore = reactData.editStore var mouseOpts = computeMouseOpts.value var keyboardOpts = computeKeyboardOpts.value var actived = editStore.actived var isEsc = hasEventKey(evnt, EVENT_KEYS.ESCAPE) if (isEsc) { tablePrivateMethods.preventEvent( evnt, 'event.keydown', null, function () { tableMethods.dispatchEvent('keydown-start', {}, evnt) if ( keyboardConfig && mouseConfig && mouseOpts.area && $xetable.handleKeyboardEvent ) { $xetable.handleKeyboardEvent(evnt) } else if ( actived.row || filterStore.visible || ctxMenuStore.visible ) { evnt.stopPropagation() if ($xetable.closeMenu) { $xetable.closeMenu() } tableMethods.closeFilter() if (keyboardConfig && keyboardOpts.isEsc) { if (actived.row) { var params_1 = actived.args $xetable.clearEdit(evnt) if (mouseOpts.selected) { nextTick(function () { return $xetable.handleSelected(params_1, evnt) }) } } } } tableMethods.dispatchEvent('keydown', {}, evnt) tableMethods.dispatchEvent('keydown-end', {}, evnt) } ) } } var handleGlobalKeydownEvent = function (evnt) { if (internalData.isActivated) { tablePrivateMethods.preventEvent( evnt, 'event.keydown', null, function () { var mouseConfig = props2.mouseConfig, keyboardConfig = props2.keyboardConfig, treeConfig = props2.treeConfig, editConfig = props2.editConfig, highlightCurrentRow = props2.highlightCurrentRow var ctxMenuStore = reactData.ctxMenuStore, editStore = reactData.editStore, currentRow = reactData.currentRow var isMenu = computeIsMenu.value var bodyMenu = computeBodyMenu.value var keyboardOpts = computeKeyboardOpts.value var mouseOpts = computeMouseOpts.value var editOpts = computeEditOpts.value var treeOpts = computeTreeOpts.value var menuList = computeMenuList.value var rowOpts = computeRowOpts.value var selected = editStore.selected, actived = editStore.actived var childrenField = treeOpts.children || treeOpts.childrenField var keyCode = evnt.keyCode var isEsc = hasEventKey(evnt, EVENT_KEYS.ESCAPE) var isBack = hasEventKey(evnt, EVENT_KEYS.BACKSPACE) var isTab = hasEventKey(evnt, EVENT_KEYS.TAB) var isEnter = hasEventKey(evnt, EVENT_KEYS.ENTER) var isSpacebar = hasEventKey(evnt, EVENT_KEYS.SPACEBAR) var isLeftArrow = hasEventKey(evnt, EVENT_KEYS.ARROW_LEFT) var isUpArrow = hasEventKey(evnt, EVENT_KEYS.ARROW_UP) var isRightArrow = hasEventKey(evnt, EVENT_KEYS.ARROW_RIGHT) var isDwArrow = hasEventKey(evnt, EVENT_KEYS.ARROW_DOWN) var isDel = hasEventKey(evnt, EVENT_KEYS.DELETE) var isF2 = hasEventKey(evnt, EVENT_KEYS.F2) var isContextMenu = hasEventKey(evnt, EVENT_KEYS.CONTEXT_MENU) var hasMetaKey = evnt.metaKey var hasCtrlKey = evnt.ctrlKey var hasShiftKey = evnt.shiftKey var isAltKey = evnt.altKey var operArrow = isLeftArrow || isUpArrow || isRightArrow || isDwArrow var operCtxMenu = isMenu && ctxMenuStore.visible && (isEnter || isSpacebar || operArrow) var isEditStatus = isEnableConf(editConfig) && actived.column && actived.row var params2 if (operCtxMenu) { evnt.preventDefault() if ( ctxMenuStore.showChild && hasChildrenList(ctxMenuStore.selected) ) { $xetable.moveCtxMenu( evnt, ctxMenuStore, 'selectChild', isLeftArrow, false, ctxMenuStore.selected.children ) } else { $xetable.moveCtxMenu( evnt, ctxMenuStore, 'selected', isRightArrow, true, menuList ) } } else if ( keyboardConfig && mouseConfig && mouseOpts.area && $xetable.handleKeyboardEvent ) { $xetable.handleKeyboardEvent(evnt) } else if (isEsc) { if ($xetable.closeMenu) { $xetable.closeMenu() } tableMethods.closeFilter() if (keyboardConfig && keyboardOpts.isEsc) { if (actived.row) { var params_2 = actived.args $xetable.clearEdit(evnt) if (mouseOpts.selected) { nextTick(function () { return $xetable.handleSelected(params_2, evnt) }) } } } } else if ( isSpacebar && keyboardConfig && keyboardOpts.isChecked && selected.row && selected.column && (selected.column.type === 'checkbox' || selected.column.type === 'radio') ) { evnt.preventDefault() if (selected.column.type === 'checkbox') { tablePrivateMethods.handleToggleCheckRowEvent( evnt, selected.args ) } else { tablePrivateMethods.triggerRadioRowEvent(evnt, selected.args) } } else if (isF2 && isEnableConf(editConfig)) { if (!isEditStatus) { if (selected.row && selected.column) { evnt.preventDefault() $xetable.handleActived(selected.args, evnt) } } } else if (isContextMenu) { internalData._keyCtx = selected.row && selected.column && bodyMenu.length clearTimeout(keyCtxTimeout) keyCtxTimeout = setTimeout(function () { internalData._keyCtx = false }, 1e3) } else if ( isEnter && !isAltKey && keyboardConfig && keyboardOpts.isEnter && (selected.row || actived.row || (treeConfig && (rowOpts.isCurrent || highlightCurrentRow) && currentRow)) ) { if (hasCtrlKey) { if (actived.row) { params2 = actived.args $xetable.clearEdit(evnt) if (mouseOpts.selected) { nextTick(function () { return $xetable.handleSelected(params2, evnt) }) } } } else { if (selected.row || actived.row) { var targetArgs = selected.row ? selected.args : actived.args if (hasShiftKey) { if (keyboardOpts.enterToTab) { $xetable.moveTabSelected(targetArgs, hasShiftKey, evnt) } else { $xetable.moveSelected( targetArgs, isLeftArrow, true, isRightArrow, false, evnt ) } } else { if (keyboardOpts.enterToTab) { $xetable.moveTabSelected(targetArgs, hasShiftKey, evnt) } else { $xetable.moveSelected( targetArgs, isLeftArrow, false, isRightArrow, true, evnt ) } } } else if ( treeConfig && (rowOpts.isCurrent || highlightCurrentRow) && currentRow ) { var childrens = currentRow[childrenField] if (childrens && childrens.length) { evnt.preventDefault() var targetRow_1 = childrens[0] params2 = { $table: $xetable, row: targetRow_1, rowIndex: tableMethods.getRowIndex(targetRow_1), $rowIndex: tableMethods.getVMRowIndex(targetRow_1), } tableMethods .setTreeExpand(currentRow, true) .then(function () { return tableMethods.scrollToRow(targetRow_1) }) .then(function () { return tablePrivateMethods.triggerCurrentRowEvent( evnt, params2 ) }) } } } } else if (operArrow && keyboardConfig && keyboardOpts.isArrow) { if (!isEditStatus) { if (selected.row && selected.column) { $xetable.moveSelected( selected.args, isLeftArrow, isUpArrow, isRightArrow, isDwArrow, evnt ) } else if ( (isUpArrow || isDwArrow) && (rowOpts.isCurrent || highlightCurrentRow) ) { $xetable.moveCurrentRow(isUpArrow, isDwArrow, evnt) } } } else if (isTab && keyboardConfig && keyboardOpts.isTab) { if (selected.row || selected.column) { $xetable.moveTabSelected(selected.args, hasShiftKey, evnt) } else if (actived.row || actived.column) { $xetable.moveTabSelected(actived.args, hasShiftKey, evnt) } } else if ( keyboardConfig && isEnableConf(editConfig) && (isDel || (treeConfig && (rowOpts.isCurrent || highlightCurrentRow) && currentRow ? isBack && keyboardOpts.isArrow : isBack)) ) { if (!isEditStatus) { var delMethod = keyboardOpts.delMethod, backMethod = keyboardOpts.backMethod if (keyboardOpts.isDel && (selected.row || selected.column)) { if (delMethod) { delMethod({ row: selected.row, rowIndex: tableMethods.getRowIndex(selected.row), column: selected.column, columnIndex: tableMethods.getColumnIndex(selected.column), $table: $xetable, }) } else { setCellValue(selected.row, selected.column, null) } if (isBack) { if (backMethod) { backMethod({ row: selected.row, rowIndex: tableMethods.getRowIndex(selected.row), column: selected.column, columnIndex: tableMethods.getColumnIndex( selected.column ), $table: $xetable, }) } else { $xetable.handleActived(selected.args, evnt) } } else if (isDel) { tableMethods.updateFooter() } } else if ( isBack && keyboardOpts.isArrow && treeConfig && (rowOpts.isCurrent || highlightCurrentRow) && currentRow ) { var parentRow_1 = xeUtils.findTree( internalData.afterFullData, function (item2) { return item2 === currentRow }, { children: childrenField } ).parent if (parentRow_1) { evnt.preventDefault() params2 = { $table: $xetable, row: parentRow_1, rowIndex: tableMethods.getRowIndex(parentRow_1), $rowIndex: tableMethods.getVMRowIndex(parentRow_1), } tableMethods .setTreeExpand(parentRow_1, false) .then(function () { return tableMethods.scrollToRow(parentRow_1) }) .then(function () { return tablePrivateMethods.triggerCurrentRowEvent( evnt, params2 ) }) } } } } else if ( keyboardConfig && isEnableConf(editConfig) && keyboardOpts.isEdit && !hasCtrlKey && !hasMetaKey && (isSpacebar || (keyCode >= 48 && keyCode <= 57) || (keyCode >= 65 && keyCode <= 90) || (keyCode >= 96 && keyCode <= 111) || (keyCode >= 186 && keyCode <= 192) || (keyCode >= 219 && keyCode <= 222)) ) { var editMethod = keyboardOpts.editMethod if ( selected.column && selected.row && isEnableConf(selected.column.editRender) ) { var beforeEditMethod = editOpts.beforeEditMethod || editOpts.activeMethod if ( !beforeEditMethod || beforeEditMethod( __assign(__assign({}, selected.args), { $table: $xetable }) ) ) { if (editMethod) { editMethod({ row: selected.row, rowIndex: tableMethods.getRowIndex(selected.row), column: selected.column, columnIndex: tableMethods.getColumnIndex(selected.column), $table: $xetable, $grid: $xegrid, }) } else { setCellValue(selected.row, selected.column, null) $xetable.handleActived(selected.args, evnt) } } } } tableMethods.dispatchEvent('keydown', {}, evnt) } ) } } var handleGlobalPasteEvent = function (evnt) { var keyboardConfig = props2.keyboardConfig, mouseConfig = props2.mouseConfig var editStore = reactData.editStore, filterStore = reactData.filterStore var isActivated = internalData.isActivated var mouseOpts = computeMouseOpts.value var keyboardOpts = computeKeyboardOpts.value var actived = editStore.actived if (isActivated && !filterStore.visible) { if (!(actived.row || actived.column)) { if ( keyboardConfig && keyboardOpts.isClip && mouseConfig && mouseOpts.area && $xetable.handlePasteCellAreaEvent ) { $xetable.handlePasteCellAreaEvent(evnt) } } tableMethods.dispatchEvent('paste', {}, evnt) } } var handleGlobalCopyEvent = function (evnt) { var keyboardConfig = props2.keyboardConfig, mouseConfig = props2.mouseConfig var editStore = reactData.editStore, filterStore = reactData.filterStore var isActivated = internalData.isActivated var mouseOpts = computeMouseOpts.value var keyboardOpts = computeKeyboardOpts.value var actived = editStore.actived if (isActivated && !filterStore.visible) { if (!(actived.row || actived.column)) { if ( keyboardConfig && keyboardOpts.isClip && mouseConfig && mouseOpts.area && $xetable.handleCopyCellAreaEvent ) { $xetable.handleCopyCellAreaEvent(evnt) } } tableMethods.dispatchEvent('copy', {}, evnt) } } var handleGlobalCutEvent = function (evnt) { var keyboardConfig = props2.keyboardConfig, mouseConfig = props2.mouseConfig var editStore = reactData.editStore, filterStore = reactData.filterStore var isActivated = internalData.isActivated var mouseOpts = computeMouseOpts.value var keyboardOpts = computeKeyboardOpts.value var actived = editStore.actived if (isActivated && !filterStore.visible) { if (!(actived.row || actived.column)) { if ( keyboardConfig && keyboardOpts.isClip && mouseConfig && mouseOpts.area && $xetable.handleCutCellAreaEvent ) { $xetable.handleCutCellAreaEvent(evnt) } } tableMethods.dispatchEvent('cut', {}, evnt) } } var handleGlobalResizeEvent = function () { if ($xetable.closeMenu) { $xetable.closeMenu() } tableMethods.updateCellAreas() tableMethods.recalculate(true) } var handleTargetEnterEvent = function (isClear) { var $tooltip = refTooltip.value clearTimeout(internalData.tooltipTimeout) if (isClear) { tableMethods.closeTooltip() } else { if ($tooltip) { $tooltip.setActived(true) } } } var handleTooltip = function (evnt, cell, overflowElem, tipElem, params2) { params2.cell = cell var tooltipStore = reactData.tooltipStore var tooltipOpts = computeTooltipOpts.value var column = params2.column, row = params2.row var showAll2 = tooltipOpts.showAll, contentMethod = tooltipOpts.contentMethod var customContent = contentMethod ? contentMethod(params2) : null var useCustom = contentMethod && !xeUtils.eqNull(customContent) var content2 = useCustom ? customContent : xeUtils .toString( column.type === 'html' ? overflowElem.innerText : overflowElem.textContent ) .trim() var isCellOverflow = overflowElem.scrollWidth > overflowElem.clientWidth if (content2 && (showAll2 || useCustom || isCellOverflow)) { Object.assign(tooltipStore, { row, column, visible: true, currOpts: null, }) nextTick(function () { var $tooltip = refTooltip.value if ($tooltip) { $tooltip.open( isCellOverflow ? overflowElem : tipElem || overflowElem, formatText(content2) ) } }) } return nextTick() } tablePrivateMethods = { getSetupOptions: function () { return GlobalConfig }, updateAfterDataIndex, callSlot: function (slotFunc, params2) { if (slotFunc) { if ($xegrid) { return $xegrid.callSlot(slotFunc, params2) } if (xeUtils.isFunction(slotFunc)) { return getSlotVNs(slotFunc(params2)) } } return [] }, getParentElem: function () { var el2 = refElem.value if ($xegrid) { var gridEl = $xegrid.getRefMaps().refElem.value return gridEl ? gridEl.parentNode : null } return el2 ? el2.parentNode : null }, getParentHeight: function () { var height = props2.height var el2 = refElem.value if (el2) { var parentElem = el2.parentNode var parentPaddingSize = height === 'auto' ? getPaddingTopBottomSize(parentElem) : 0 return Math.floor( $xegrid ? $xegrid.getParentHeight() : xeUtils.toNumber(getComputedStyle(parentElem).height) - parentPaddingSize ) } return 0 }, getExcludeHeight: function () { return $xegrid ? $xegrid.getExcludeHeight() : 0 }, defineField: function (records) { var treeConfig = props2.treeConfig var expandOpts = computeExpandOpts.value var treeOpts = computeTreeOpts.value var radioOpts = computeRadioOpts.value var checkboxOpts = computeCheckboxOpts.value var childrenField = treeOpts.children || treeOpts.childrenField var rowkey = getRowkey($xetable) if (!xeUtils.isArray(records)) { records = [records] } return records.map(function (record) { internalData.tableFullColumn.forEach(function (column) { var field2 = column.field, editRender = column.editRender if (field2 && !xeUtils.has(record, field2) && !record[field2]) { var cellValue = null if (editRender) { var defaultValue = editRender.defaultValue if (xeUtils.isFunction(defaultValue)) { cellValue = defaultValue({ column }) } else if (!xeUtils.isUndefined(defaultValue)) { cellValue = defaultValue } } xeUtils.set(record, field2, cellValue) } }) var otherFields = [ radioOpts.labelField, checkboxOpts.checkField, checkboxOpts.labelField, expandOpts.labelField, ] otherFields.forEach(function (key2) { if (key2 && eqEmptyValue(xeUtils.get(record, key2))) { xeUtils.set(record, key2, null) } }) if ( treeConfig && treeOpts.lazy && xeUtils.isUndefined(record[childrenField]) ) { record[childrenField] = null } if (eqEmptyValue(xeUtils.get(record, rowkey))) { xeUtils.set(record, rowkey, getRowUniqueId()) } return record }) }, handleTableData: function (force) { var scrollYLoad = reactData.scrollYLoad var scrollYStore = internalData.scrollYStore, fullDataRowIdData = internalData.fullDataRowIdData var fullList = internalData.afterFullData if (force) { updateAfterFullData() fullList = handleVirtualTreeToList() } var tableData2 = scrollYLoad ? fullList.slice(scrollYStore.startIndex, scrollYStore.endIndex) : fullList.slice(0) tableData2.forEach(function (row, $index) { var rowid = getRowid($xetable, row) var rest = fullDataRowIdData[rowid] if (rest) { rest.$index = $index } }) reactData.tableData = tableData2 return nextTick() }, cacheRowMap: function (isSource) { var treeConfig = props2.treeConfig var treeOpts = computeTreeOpts.value var fullDataRowIdData = internalData.fullDataRowIdData, fullAllDataRowIdData = internalData.fullAllDataRowIdData, tableFullData = internalData.tableFullData, tableFullTreeData = internalData.tableFullTreeData var childrenField = treeOpts.children || treeOpts.childrenField var hasChildField = treeOpts.hasChild || treeOpts.hasChildField var rowkey = getRowkey($xetable) var isLazy = treeConfig && treeOpts.lazy var handleRow = function (row, index2, items, path, parent2, nodes) { var rowid = getRowid($xetable, row) var seq = treeConfig && path ? toTreePathSeq(path) : index2 + 1 var level = nodes ? nodes.length - 1 : 0 if (eqEmptyValue(rowid)) { rowid = getRowUniqueId() xeUtils.set(row, rowkey, rowid) } if ( isLazy && row[hasChildField] && xeUtils.isUndefined(row[childrenField]) ) { row[childrenField] = null } var rest = { row, rowid, seq, index: treeConfig && parent2 ? -1 : index2, _index: -1, $index: -1, items, parent: parent2, level, } if (isSource) { fullDataRowIdData[rowid] = rest } fullAllDataRowIdData[rowid] = rest } if (isSource) { fullDataRowIdData = internalData.fullDataRowIdData = {} } fullAllDataRowIdData = internalData.fullAllDataRowIdData = {} if (treeConfig) { xeUtils.eachTree(tableFullTreeData, handleRow, { children: childrenField, }) } else { tableFullData.forEach(handleRow) } }, cacheSourceMap: function (fullData) { var treeConfig = props2.treeConfig var treeOpts = computeTreeOpts.value var sourceDataRowIdData = internalData.sourceDataRowIdData var sourceData = xeUtils.clone(fullData, true) var rowkey = getRowkey($xetable) sourceDataRowIdData = internalData.sourceDataRowIdData = {} var handleSourceRow = function (row) { var rowid = getRowid($xetable, row) if (eqEmptyValue(rowid)) { rowid = getRowUniqueId() xeUtils.set(row, rowkey, rowid) } sourceDataRowIdData[rowid] = row } if (treeConfig) { var childrenField = treeOpts.children || treeOpts.childrenField xeUtils.eachTree(sourceData, handleSourceRow, { children: treeOpts.transform ? treeOpts.mapChildrenField : childrenField, }) } else { sourceData.forEach(handleSourceRow) } internalData.tableSourceData = sourceData }, analyColumnWidth: function () { var tableFullColumn = internalData.tableFullColumn var columnOpts = computeColumnOpts.value var defaultWidth = columnOpts.width, defaultMinWidth = columnOpts.minWidth var resizeList = [] var pxList = [] var pxMinList = [] var scaleList = [] var scaleMinList = [] var autoList = [] tableFullColumn.forEach(function (column) { if (defaultWidth && !column.width) { column.width = defaultWidth } if (defaultMinWidth && !column.minWidth) { column.minWidth = defaultMinWidth } if (column.visible) { if (column.resizeWidth) { resizeList.push(column) } else if (isPx(column.width)) { pxList.push(column) } else if (isScale(column.width)) { scaleList.push(column) } else if (isPx(column.minWidth)) { pxMinList.push(column) } else if (isScale(column.minWidth)) { scaleMinList.push(column) } else { autoList.push(column) } } }) Object.assign(reactData.columnStore, { resizeList, pxList, pxMinList, scaleList, scaleMinList, autoList, }) }, saveCustomResizable: function (isReset) { var id2 = props2.id, customConfig = props2.customConfig var customOpts = computeCustomOpts.value var collectColumn = internalData.collectColumn var storage2 = customOpts.storage var isResizable = storage2 === true || (storage2 && storage2.resizable) if (customConfig && isResizable) { var columnWidthStorageMap = getCustomStorageMap(resizableStorageKey) var columnWidthStorage_1 if (!id2) { errLog('vxe.error.reqProp', ['id']) return } if (!isReset) { columnWidthStorage_1 = xeUtils.isPlainObject( columnWidthStorageMap[id2] ) ? columnWidthStorageMap[id2] : {} xeUtils.eachTree(collectColumn, function (column) { if (column.resizeWidth) { var colKey = column.getKey() if (colKey) { columnWidthStorage_1[colKey] = column.renderWidth } } }) } columnWidthStorageMap[id2] = xeUtils.isEmpty(columnWidthStorage_1) ? void 0 : columnWidthStorage_1 localStorage.setItem( resizableStorageKey, xeUtils.toJSONString(columnWidthStorageMap) ) } }, saveCustomFixed: function () { var id2 = props2.id, customConfig = props2.customConfig var collectColumn = internalData.collectColumn var customOpts = computeCustomOpts.value var storage2 = customOpts.storage var isCustomFixed = storage2 === true || (storage2 && storage2.fixed) if (customConfig && isCustomFixed) { var columnFixedStorageMap = getCustomStorageMap(fixedStorageKey) var colFixeds_1 = [] if (!id2) { errLog('vxe.error.reqProp', ['id']) return } xeUtils.eachTree(collectColumn, function (column) { if (column.fixed && column.fixed !== column.defaultFixed) { var colKey = column.getKey() if (colKey) { colFixeds_1.push(''.concat(colKey, '|').concat(column.fixed)) } } }) columnFixedStorageMap[id2] = colFixeds_1.join(',') || void 0 localStorage.setItem( fixedStorageKey, xeUtils.toJSONString(columnFixedStorageMap) ) } }, saveCustomVisible: function () { var id2 = props2.id, customConfig = props2.customConfig var collectColumn = internalData.collectColumn var customOpts = computeCustomOpts.value var checkMethod = customOpts.checkMethod, storage2 = customOpts.storage var isCustomVisible = storage2 === true || (storage2 && storage2.visible) if (customConfig && isCustomVisible) { var columnVisibleStorageMap = getCustomStorageMap(visibleStorageKey) var colHides_1 = [] var colShows_1 = [] if (!id2) { errLog('vxe.error.reqProp', ['id']) return } xeUtils.eachTree(collectColumn, function (column) { if (!checkMethod || checkMethod({ column })) { if (!column.visible && column.defaultVisible) { var colKey = column.getKey() if (colKey) { colHides_1.push(colKey) } } else if (column.visible && !column.defaultVisible) { var colKey = column.getKey() if (colKey) { colShows_1.push(colKey) } } } }) columnVisibleStorageMap[id2] = [colHides_1.join(',')] .concat(colShows_1.length ? [colShows_1.join(',')] : []) .join('|') || void 0 localStorage.setItem( visibleStorageKey, xeUtils.toJSONString(columnVisibleStorageMap) ) } }, handleCustom: function () { tablePrivateMethods.saveCustomVisible() tablePrivateMethods.analyColumnWidth() return tableMethods.refreshColumn() }, handleUpdateDataQueue: function () { reactData.upDataFlag++ }, handleRefreshColumnQueue: function () { reactData.reColumnFlag++ }, preventEvent: function (evnt, type4, args, next, end2) { var evntList = VXETable.interceptor.get(type4) var rest if ( !evntList.some(function (func) { return ( func( Object.assign( { $grid: $xegrid, $table: $xetable, $event: evnt }, args ) ) === false ) }) ) { if (next) { rest = next() } } if (end2) { end2() } return rest }, checkSelectionStatus: function () { var treeConfig = props2.treeConfig var selectCheckboxMaps = reactData.selectCheckboxMaps, treeIndeterminateMaps = reactData.treeIndeterminateMaps var afterFullData = internalData.afterFullData var checkboxOpts = computeCheckboxOpts.value var checkField = checkboxOpts.checkField, checkStrictly = checkboxOpts.checkStrictly, checkMethod = checkboxOpts.checkMethod var indeterminateField = checkboxOpts.indeterminateField || checkboxOpts.halfField if (!checkStrictly) { var disableRows_1 = [] var checkRows_1 = [] var isAllResolve = false var isAllSelected = false var isIndeterminate = false if (checkField) { isAllResolve = afterFullData.every( checkMethod ? function (row) { if (!checkMethod({ row })) { disableRows_1.push(row) return true } if (xeUtils.get(row, checkField)) { checkRows_1.push(row) return true } return false } : function (row) { return xeUtils.get(row, checkField) } ) isAllSelected = isAllResolve && afterFullData.length !== disableRows_1.length if (treeConfig) { if (indeterminateField) { isIndeterminate = !isAllSelected && afterFullData.some(function (row) { return ( xeUtils.get(row, checkField) || xeUtils.get(row, indeterminateField) || !!treeIndeterminateMaps[getRowid($xetable, row)] ) }) } else { isIndeterminate = !isAllSelected && afterFullData.some(function (row) { return ( xeUtils.get(row, checkField) || !!treeIndeterminateMaps[getRowid($xetable, row)] ) }) } } else { if (indeterminateField) { isIndeterminate = !isAllSelected && afterFullData.some(function (row) { return ( xeUtils.get(row, checkField) || xeUtils.get(row, indeterminateField) ) }) } else { isIndeterminate = !isAllSelected && afterFullData.some(function (row) { return xeUtils.get(row, checkField) }) } } } else { isAllResolve = afterFullData.every( checkMethod ? function (row) { if (!checkMethod({ row })) { disableRows_1.push(row) return true } if (selectCheckboxMaps[getRowid($xetable, row)]) { checkRows_1.push(row) return true } return false } : function (row) { return selectCheckboxMaps[getRowid($xetable, row)] } ) isAllSelected = isAllResolve && afterFullData.length !== disableRows_1.length if (treeConfig) { isIndeterminate = !isAllSelected && afterFullData.some(function (row) { var itemRid = getRowid($xetable, row) return ( treeIndeterminateMaps[itemRid] || selectCheckboxMaps[itemRid] ) }) } else { isIndeterminate = !isAllSelected && afterFullData.some(function (row) { return selectCheckboxMaps[getRowid($xetable, row)] }) } } reactData.isAllSelected = isAllSelected reactData.isIndeterminate = isIndeterminate } }, handleSelectRow: function (_a2, value2, isForce) { var row = _a2.row var treeConfig = props2.treeConfig var selectCheckboxMaps = reactData.selectCheckboxMaps, treeIndeterminateMaps = reactData.treeIndeterminateMaps var selectRowMaps = __assign({}, selectCheckboxMaps) var afterFullData = internalData.afterFullData var treeOpts = computeTreeOpts.value var childrenField = treeOpts.children || treeOpts.childrenField var checkboxOpts = computeCheckboxOpts.value var checkField = checkboxOpts.checkField, checkStrictly = checkboxOpts.checkStrictly, checkMethod = checkboxOpts.checkMethod var indeterminateField = checkboxOpts.indeterminateField || checkboxOpts.halfField var rowid = getRowid($xetable, row) if (checkField) { if (treeConfig && !checkStrictly) { if (value2 === -1) { if (!treeIndeterminateMaps[rowid]) { if (indeterminateField) { xeUtils.set(row, indeterminateField, true) } treeIndeterminateMaps[rowid] = row } xeUtils.set(row, checkField, false) } else { xeUtils.eachTree( [row], function (item2) { if ( $xetable.eqRow(item2, row) || isForce || !checkMethod || checkMethod({ row: item2 }) ) { xeUtils.set(item2, checkField, value2) if (indeterminateField) { xeUtils.set(row, indeterminateField, false) } delete treeIndeterminateMaps[getRowid($xetable, item2)] handleCheckboxReserveRow(row, value2) } }, { children: childrenField } ) } var matchObj = xeUtils.findTree( afterFullData, function (item2) { return $xetable.eqRow(item2, row) }, { children: childrenField } ) if (matchObj && matchObj.parent) { var parentStatus = void 0 var vItems_1 = [] var vItemMaps_1 = {} if (!isForce && checkMethod) { matchObj.items.forEach(function (item2) { if (checkMethod({ row: item2 })) { var itemRid = getRowid($xetable, item2) vItemMaps_1[itemRid] = item2 vItems_1.push(item2) } }) } else { matchObj.items.forEach(function (item2) { var itemRid = getRowid($xetable, item2) vItemMaps_1[itemRid] = item2 vItems_1.push(item2) }) } var indeterminatesItem = xeUtils.find( matchObj.items, function (item2) { return !!treeIndeterminateMaps[getRowid($xetable, item2)] } ) if (indeterminatesItem) { parentStatus = -1 } else { var selectItems_1 = [] matchObj.items.forEach(function (item2) { if (xeUtils.get(item2, checkField)) { selectItems_1.push(item2) } }) parentStatus = selectItems_1.filter(function (item2) { return vItemMaps_1[getRowid($xetable, item2)] }).length === vItems_1.length ? true : selectItems_1.length || value2 === -1 ? -1 : false } reactData.selectCheckboxMaps = selectRowMaps return tablePrivateMethods.handleSelectRow( { row: matchObj.parent }, parentStatus, isForce ) } } else { if (isForce || !checkMethod || checkMethod({ row })) { xeUtils.set(row, checkField, value2) handleCheckboxReserveRow(row, value2) } } } else { if (treeConfig && !checkStrictly) { if (value2 === -1) { if (!treeIndeterminateMaps[rowid]) { if (indeterminateField) { xeUtils.set(row, indeterminateField, true) } treeIndeterminateMaps[rowid] = row } if (selectRowMaps[rowid]) { delete selectRowMaps[rowid] } } else { xeUtils.eachTree( [row], function (item2) { var itemRid = getRowid($xetable, item2) if ( $xetable.eqRow(item2, row) || isForce || !checkMethod || checkMethod({ row: item2 }) ) { if (value2) { selectRowMaps[itemRid] = item2 } else { if (selectRowMaps[itemRid]) { delete selectRowMaps[itemRid] } } if (indeterminateField) { xeUtils.set(row, indeterminateField, false) } delete treeIndeterminateMaps[getRowid($xetable, item2)] handleCheckboxReserveRow(row, value2) } }, { children: childrenField } ) } var matchObj = xeUtils.findTree( afterFullData, function (item2) { return $xetable.eqRow(item2, row) }, { children: childrenField } ) if (matchObj && matchObj.parent) { var parentStatus = void 0 var vItems_2 = [] var vItemMaps_2 = {} if (!isForce && checkMethod) { matchObj.items.forEach(function (item2) { if (checkMethod({ row: item2 })) { var itemRid = getRowid($xetable, item2) vItemMaps_2[itemRid] = item2 vItems_2.push(item2) } }) } else { matchObj.items.forEach(function (item2) { var itemRid = getRowid($xetable, item2) vItemMaps_2[itemRid] = item2 vItems_2.push(item2) }) } var indeterminatesItem = xeUtils.find( matchObj.items, function (item2) { return !!treeIndeterminateMaps[getRowid($xetable, item2)] } ) if (indeterminatesItem) { parentStatus = -1 } else { var selectItems_2 = [] matchObj.items.forEach(function (item2) { var itemRid = getRowid($xetable, item2) if (selectRowMaps[itemRid]) { selectItems_2.push(item2) } }) parentStatus = selectItems_2.filter(function (item2) { return vItemMaps_2[getRowid($xetable, item2)] }).length === vItems_2.length ? true : selectItems_2.length || value2 === -1 ? -1 : false } reactData.selectCheckboxMaps = selectRowMaps return tablePrivateMethods.handleSelectRow( { row: matchObj.parent }, parentStatus, isForce ) } } else { if (isForce || !checkMethod || checkMethod({ row })) { if (value2) { if (!selectRowMaps[rowid]) { selectRowMaps[rowid] = row } } else { if (selectRowMaps[rowid]) { delete selectRowMaps[rowid] } } handleCheckboxReserveRow(row, value2) } } } reactData.selectCheckboxMaps = selectRowMaps tablePrivateMethods.checkSelectionStatus() }, triggerHeaderHelpEvent: function (evnt, params2) { var column = params2.column var titlePrefix = column.titlePrefix || column.titleHelp if (titlePrefix.content || titlePrefix.message) { var tooltipStore = reactData.tooltipStore var content_1 = getFuncText( titlePrefix.content || titlePrefix.message ) handleTargetEnterEvent(true) tooltipStore.visible = true tooltipStore.currOpts = __assign(__assign({}, titlePrefix), { content: null, }) nextTick(function () { var $tooltip = refTooltip.value if ($tooltip) { $tooltip.open(evnt.currentTarget, content_1) } }) } }, triggerHeaderTooltipEvent: function (evnt, params2) { var tooltipStore = reactData.tooltipStore var column = params2.column var titleElem = evnt.currentTarget handleTargetEnterEvent(true) if (tooltipStore.column !== column || !tooltipStore.visible) { handleTooltip(evnt, titleElem, titleElem, null, params2) } }, triggerBodyTooltipEvent: function (evnt, params2) { var editConfig = props2.editConfig var editStore = reactData.editStore var tooltipStore = reactData.tooltipStore var editOpts = computeEditOpts.value var actived = editStore.actived var row = params2.row, column = params2.column var cell = evnt.currentTarget handleTargetEnterEvent( tooltipStore.column !== column || tooltipStore.row !== row ) if (column.editRender && isEnableConf(editConfig)) { if (editOpts.mode === 'row' && actived.row === row) { return } if (actived.row === row && actived.column === column) { return } } if ( tooltipStore.column !== column || tooltipStore.row !== row || !tooltipStore.visible ) { var overflowElem = void 0 var tipElem = void 0 if (column.treeNode) { overflowElem = cell.querySelector('.vxe-tree-cell') if (column.type === 'html') { tipElem = cell.querySelector('.vxe-cell--html') } } else { tipElem = cell.querySelector( column.type === 'html' ? '.vxe-cell--html' : '.vxe-cell--label' ) } handleTooltip( evnt, cell, overflowElem || cell.children[0], tipElem, params2 ) } }, triggerFooterTooltipEvent: function (evnt, params2) { var column = params2.column var tooltipStore = reactData.tooltipStore var cell = evnt.currentTarget handleTargetEnterEvent( tooltipStore.column !== column || !!tooltipStore.row ) if (tooltipStore.column !== column || !tooltipStore.visible) { handleTooltip( evnt, cell, cell.querySelector('.vxe-cell--item') || cell.children[0], null, params2 ) } }, handleTargetLeaveEvent: function () { var tooltipOpts = computeTooltipOpts.value var $tooltip = refTooltip.value if ($tooltip) { $tooltip.setActived(false) } if (tooltipOpts.enterable) { internalData.tooltipTimeout = setTimeout(function () { $tooltip = refTooltip.value if ($tooltip && !$tooltip.isActived()) { tableMethods.closeTooltip() } }, tooltipOpts.leaveDelay) } else { tableMethods.closeTooltip() } }, triggerHeaderCellClickEvent: function (evnt, params2) { var _lastResizeTime = internalData._lastResizeTime var sortOpts = computeSortOpts.value var columnOpts = computeColumnOpts.value var column = params2.column var cell = evnt.currentTarget var triggerResizable = _lastResizeTime && _lastResizeTime > Date.now() - 300 var triggerSort = getEventTargetNode(evnt, cell, 'vxe-cell--sort').flag var triggerFilter = getEventTargetNode( evnt, cell, 'vxe-cell--filter' ).flag if ( sortOpts.trigger === 'cell' && !(triggerResizable || triggerSort || triggerFilter) ) { tablePrivateMethods.triggerSortEvent( evnt, column, getNextSortOrder(column) ) } tableMethods.dispatchEvent( 'header-cell-click', Object.assign( { triggerResizable, triggerSort, triggerFilter, cell }, params2 ), evnt ) if (columnOpts.isCurrent || props2.highlightCurrentColumn) { tableMethods.setCurrentColumn(column) } }, triggerHeaderCellDblclickEvent: function (evnt, params2) { tableMethods.dispatchEvent( 'header-cell-dblclick', Object.assign({ cell: evnt.currentTarget }, params2), evnt ) }, triggerCellClickEvent: function (evnt, params2) { var highlightCurrentRow = props2.highlightCurrentRow, editConfig = props2.editConfig var editStore = reactData.editStore var expandOpts = computeExpandOpts.value var editOpts = computeEditOpts.value var treeOpts = computeTreeOpts.value var radioOpts = computeRadioOpts.value var checkboxOpts = computeCheckboxOpts.value var rowOpts = computeRowOpts.value var actived = editStore.actived var row = params2.row, column = params2.column var type4 = column.type, treeNode = column.treeNode var isRadioType = type4 === 'radio' var isCheckboxType = type4 === 'checkbox' var isExpandType = type4 === 'expand' var cell = evnt.currentTarget var triggerRadio = isRadioType && getEventTargetNode(evnt, cell, 'vxe-cell--radio').flag var triggerCheckbox = isCheckboxType && getEventTargetNode(evnt, cell, 'vxe-cell--checkbox').flag var triggerTreeNode = treeNode && getEventTargetNode(evnt, cell, 'vxe-tree--btn-wrapper').flag var triggerExpandNode = isExpandType && getEventTargetNode(evnt, cell, 'vxe-table--expanded').flag params2 = Object.assign( { cell, triggerRadio, triggerCheckbox, triggerTreeNode, triggerExpandNode, }, params2 ) if (!triggerCheckbox && !triggerRadio) { if ( !triggerExpandNode && (expandOpts.trigger === 'row' || (isExpandType && expandOpts.trigger === 'cell')) ) { tablePrivateMethods.triggerRowExpandEvent(evnt, params2) } if ( treeOpts.trigger === 'row' || (treeNode && treeOpts.trigger === 'cell') ) { tablePrivateMethods.triggerTreeExpandEvent(evnt, params2) } } if (!triggerTreeNode) { if (!triggerExpandNode) { if (rowOpts.isCurrent || highlightCurrentRow) { if (!triggerCheckbox && !triggerRadio) { tablePrivateMethods.triggerCurrentRowEvent(evnt, params2) } } if ( !triggerRadio && (radioOpts.trigger === 'row' || (isRadioType && radioOpts.trigger === 'cell')) ) { tablePrivateMethods.triggerRadioRowEvent(evnt, params2) } if ( !triggerCheckbox && (checkboxOpts.trigger === 'row' || (isCheckboxType && checkboxOpts.trigger === 'cell')) ) { tablePrivateMethods.handleToggleCheckRowEvent(evnt, params2) } } if (isEnableConf(editConfig)) { if (editOpts.trigger === 'manual') { if ( actived.args && actived.row === row && column !== actived.column ) { handleChangeCell(evnt, params2) } } else if ( !actived.args || row !== actived.row || column !== actived.column ) { if (editOpts.trigger === 'click') { handleChangeCell(evnt, params2) } else if (editOpts.trigger === 'dblclick') { if (editOpts.mode === 'row' && actived.row === row) { handleChangeCell(evnt, params2) } } } } } tableMethods.dispatchEvent('cell-click', params2, evnt) }, triggerCellDblclickEvent: function (evnt, params2) { var editConfig = props2.editConfig var editStore = reactData.editStore var editOpts = computeEditOpts.value var actived = editStore.actived var cell = evnt.currentTarget params2 = Object.assign({ cell }, params2) if (isEnableConf(editConfig) && editOpts.trigger === 'dblclick') { if (!actived.args || evnt.currentTarget !== actived.args.cell) { if (editOpts.mode === 'row') { checkValidate('blur') .catch(function (e2) { return e2 }) .then(function () { $xetable .handleActived(params2, evnt) .then(function () { return checkValidate('change') }) .catch(function (e2) { return e2 }) }) } else if (editOpts.mode === 'cell') { $xetable .handleActived(params2, evnt) .then(function () { return checkValidate('change') }) .catch(function (e2) { return e2 }) } } } tableMethods.dispatchEvent('cell-dblclick', params2, evnt) }, handleToggleCheckRowEvent: function (evnt, params2) { var selectCheckboxMaps = reactData.selectCheckboxMaps var checkboxOpts = computeCheckboxOpts.value var checkField = checkboxOpts.checkField var row = params2.row var value2 = false if (checkField) { value2 = !xeUtils.get(row, checkField) } else { value2 = !selectCheckboxMaps[getRowid($xetable, row)] } if (evnt) { tablePrivateMethods.triggerCheckRowEvent(evnt, params2, value2) } else { tablePrivateMethods.handleSelectRow(params2, value2) } }, triggerCheckRowEvent: function (evnt, params2, value2) { var checkboxOpts = computeCheckboxOpts.value var row = params2.row var afterFullData = internalData.afterFullData var checkMethod = checkboxOpts.checkMethod if (checkboxOpts.isShiftKey && evnt.shiftKey && !props2.treeConfig) { var checkboxRecords = tableMethods.getCheckboxRecords() if (checkboxRecords.length) { var firstRow = checkboxRecords[0] var _rowIndex = tableMethods.getVTRowIndex(row) var _firstRowIndex = tableMethods.getVTRowIndex(firstRow) if (_rowIndex !== _firstRowIndex) { tableMethods.setAllCheckboxRow(false) var rangeRows = _rowIndex < _firstRowIndex ? afterFullData.slice(_rowIndex, _firstRowIndex + 1) : afterFullData.slice(_firstRowIndex, _rowIndex + 1) handleCheckedCheckboxRow(rangeRows, true, false) tableMethods.dispatchEvent( 'checkbox-range-select', Object.assign({ rangeRecords: rangeRows }, params2), evnt ) return } } } if (!checkMethod || checkMethod({ row })) { tablePrivateMethods.handleSelectRow(params2, value2) tableMethods.dispatchEvent( 'checkbox-change', Object.assign( { records: tableMethods.getCheckboxRecords(), reserves: tableMethods.getCheckboxReserveRecords(), indeterminates: tableMethods.getCheckboxIndeterminateRecords(), checked: value2, }, params2 ), evnt ) } }, triggerCheckAllEvent: function (evnt, value2) { handleCheckedAllCheckboxRow(value2) if (evnt) { tableMethods.dispatchEvent( 'checkbox-all', { records: tableMethods.getCheckboxRecords(), reserves: tableMethods.getCheckboxReserveRecords(), indeterminates: tableMethods.getCheckboxIndeterminateRecords(), checked: value2, }, evnt ) } }, triggerRadioRowEvent: function (evnt, params2) { var oldValue = reactData.selectRadioRow var row = params2.row var radioOpts = computeRadioOpts.value var newValue = row var isChange = oldValue !== newValue if (isChange) { handleCheckedRadioRow(newValue) } else if (!radioOpts.strict) { isChange = oldValue === newValue if (isChange) { newValue = null tableMethods.clearRadioRow() } } if (isChange) { tableMethods.dispatchEvent( 'radio-change', __assign({ oldValue, newValue }, params2), evnt ) } }, triggerCurrentRowEvent: function (evnt, params2) { var oldValue = reactData.currentRow var newValue = params2.row var isChange = oldValue !== newValue tableMethods.setCurrentRow(newValue) if (isChange) { tableMethods.dispatchEvent( 'current-change', __assign({ oldValue, newValue }, params2), evnt ) } }, triggerRowExpandEvent: function (evnt, params2) { var rowExpandLazyLoadedMaps = reactData.rowExpandLazyLoadedMaps, column = reactData.expandColumn var expandOpts = computeExpandOpts.value var row = params2.row var lazy = expandOpts.lazy var rowid = getRowid($xetable, row) if (!lazy || !rowExpandLazyLoadedMaps[rowid]) { var expanded = !tableMethods.isExpandByRow(row) var columnIndex = tableMethods.getColumnIndex(column) var $columnIndex = tableMethods.getVMColumnIndex(column) tableMethods.setRowExpand(row, expanded) tableMethods.dispatchEvent( 'toggle-row-expand', { expanded, column, columnIndex, $columnIndex, row, rowIndex: tableMethods.getRowIndex(row), $rowIndex: tableMethods.getVMRowIndex(row), }, evnt ) } }, triggerTreeExpandEvent: function (evnt, params2) { var treeExpandLazyLoadedMaps = reactData.treeExpandLazyLoadedMaps var treeOpts = computeTreeOpts.value var row = params2.row, column = params2.column var lazy = treeOpts.lazy var rowid = getRowid($xetable, row) if (!lazy || !treeExpandLazyLoadedMaps[rowid]) { var expanded = !tableMethods.isTreeExpandByRow(row) var columnIndex = tableMethods.getColumnIndex(column) var $columnIndex = tableMethods.getVMColumnIndex(column) tableMethods.setTreeExpand(row, expanded) tableMethods.dispatchEvent( 'toggle-tree-expand', { expanded, column, columnIndex, $columnIndex, row }, evnt ) } }, triggerSortEvent: function (evnt, column, order2) { var mouseConfig = props2.mouseConfig var sortOpts = computeSortOpts.value var mouseOpts = computeMouseOpts.value var field2 = column.field, sortable = column.sortable if (sortable) { if (!order2 || column.order === order2) { tableMethods.clearSort(sortOpts.multiple ? column : null) } else { tableMethods.sort({ field: field2, order: order2 }) } var params2 = { $table: $xetable, $event: evnt, column, field: field2, property: field2, order: column.order, sortList: tableMethods.getSortColumns(), sortTime: column.sortTime, } if (mouseConfig && mouseOpts.area && $xetable.handleSortEvent) { return $xetable.handleSortEvent(evnt, params2) } tableMethods.dispatchEvent('sort-change', params2, evnt) } }, triggerScrollXEvent: function () { loadScrollXData() }, triggerScrollYEvent: function (evnt) { var scrollYStore = internalData.scrollYStore var adaptive = scrollYStore.adaptive, offsetSize = scrollYStore.offsetSize, visibleSize = scrollYStore.visibleSize if (isWebkit && adaptive && offsetSize * 2 + visibleSize <= 40) { loadScrollYData(evnt) } else { debounceScrollY(evnt) } }, scrollToTreeRow: function (row) { var treeConfig = props2.treeConfig var tableFullData = internalData.tableFullData var rests = [] if (treeConfig) { var treeOpts = computeTreeOpts.value var childrenField = treeOpts.children || treeOpts.childrenField var matchObj = xeUtils.findTree( tableFullData, function (item2) { return $xetable.eqRow(item2, row) }, { children: childrenField } ) if (matchObj) { var nodes_1 = matchObj.nodes nodes_1.forEach(function (row2, index2) { if ( index2 < nodes_1.length - 1 && !tableMethods.isTreeExpandByRow(row2) ) { rests.push(tableMethods.setTreeExpand(row2, true)) } }) } } return Promise.all(rests).then(function () { return rowToVisible($xetable, row) }) }, updateScrollYStatus, updateScrollXSpace: function () { var isGroup2 = reactData.isGroup, scrollXLoad = reactData.scrollXLoad, scrollbarWidth = reactData.scrollbarWidth var visibleColumn = internalData.visibleColumn, scrollXStore = internalData.scrollXStore, elemStore = internalData.elemStore, tableWidth = internalData.tableWidth var tableHeader = refTableHeader.value var tableBody = refTableBody.value var tableFooter = refTableFooter.value var tableBodyElem = tableBody ? tableBody.$el : null if (tableBodyElem) { var tableHeaderElem = tableHeader ? tableHeader.$el : null var tableFooterElem = tableFooter ? tableFooter.$el : null var headerElem = tableHeaderElem ? tableHeaderElem.querySelector('.vxe-table--header') : null var bodyElem = tableBodyElem.querySelector('.vxe-table--body') var footerElem = tableFooterElem ? tableFooterElem.querySelector('.vxe-table--footer') : null var leftSpaceWidth = visibleColumn .slice(0, scrollXStore.startIndex) .reduce(function (previous, column) { return previous + column.renderWidth }, 0) var marginLeft2 = '' if (scrollXLoad) { marginLeft2 = ''.concat(leftSpaceWidth, 'px') } if (headerElem) { headerElem.style.marginLeft = isGroup2 ? '' : marginLeft2 } bodyElem.style.marginLeft = marginLeft2 if (footerElem) { footerElem.style.marginLeft = marginLeft2 } var containerList = ['main'] containerList.forEach(function (name2) { var layoutList2 = ['header', 'body', 'footer'] layoutList2.forEach(function (layout2) { var xSpaceRef = elemStore[''.concat(name2, '-').concat(layout2, '-xSpace')] var xSpaceElem = xSpaceRef ? xSpaceRef.value : null if (xSpaceElem) { xSpaceElem.style.width = scrollXLoad ? ''.concat( tableWidth + (layout2 === 'header' ? scrollbarWidth : 0), 'px' ) : '' } }) }) nextTick(updateStyle2) } }, updateScrollYSpace: function () { var scrollYLoad = reactData.scrollYLoad var scrollYStore = internalData.scrollYStore, elemStore = internalData.elemStore, afterFullData = internalData.afterFullData var startIndex = scrollYStore.startIndex, rowHeight = scrollYStore.rowHeight var bodyHeight = afterFullData.length * rowHeight var topSpaceHeight = Math.max(0, startIndex * rowHeight) var containerList = ['main', 'left', 'right'] var marginTop2 = '' var ySpaceHeight = '' if (scrollYLoad) { marginTop2 = ''.concat(topSpaceHeight, 'px') ySpaceHeight = ''.concat(bodyHeight, 'px') } containerList.forEach(function (name2) { var layoutList2 = ['header', 'body', 'footer'] var tableRef = elemStore[''.concat(name2, '-body-table')] var tableElem = tableRef ? tableRef.value : null if (tableElem) { tableElem.style.marginTop = marginTop2 } layoutList2.forEach(function (layout2) { var ySpaceRef = elemStore[''.concat(name2, '-').concat(layout2, '-ySpace')] var ySpaceElem = ySpaceRef ? ySpaceRef.value : null if (ySpaceElem) { ySpaceElem.style.height = ySpaceHeight } }) }) nextTick(updateStyle2) }, updateScrollXData: function () { nextTick(function () { handleTableColumn() tablePrivateMethods.updateScrollXSpace() }) }, updateScrollYData: function () { nextTick(function () { tablePrivateMethods.handleTableData() tablePrivateMethods.updateScrollYSpace() }) }, checkScrolling: function () { var leftContainerElem = refLeftContainer.value var rightContainerElem = refRightContainer.value var tableBody = refTableBody.value var bodyElem = tableBody ? tableBody.$el : null if (bodyElem) { if (leftContainerElem) { if (bodyElem.scrollLeft > 0) { addClass(leftContainerElem, 'scrolling--middle') } else { removeClass(leftContainerElem, 'scrolling--middle') } } if (rightContainerElem) { if ( bodyElem.clientWidth < bodyElem.scrollWidth - Math.ceil(bodyElem.scrollLeft) ) { addClass(rightContainerElem, 'scrolling--middle') } else { removeClass(rightContainerElem, 'scrolling--middle') } } } }, updateZindex: function () { if (props2.zIndex) { internalData.tZindex = props2.zIndex } else if (internalData.tZindex < getLastZIndex()) { internalData.tZindex = nextZIndex() } }, handleCheckedCheckboxRow, triggerHoverEvent: function (evnt, _a2) { var row = _a2.row tablePrivateMethods.setHoverRow(row) }, setHoverRow: function (row) { var rowid = getRowid($xetable, row) var el2 = refElem.value tablePrivateMethods.clearHoverRow() if (el2) { xeUtils.arrayEach( el2.querySelectorAll('[rowid="'.concat(rowid, '"]')), function (elem) { return addClass(elem, 'row--hover') } ) } internalData.hoverRow = row }, clearHoverRow: function () { var el2 = refElem.value if (el2) { xeUtils.arrayEach( el2.querySelectorAll('.vxe-body--row.row--hover'), function (elem) { return removeClass(elem, 'row--hover') } ) } internalData.hoverRow = null }, getCell: function (row, column) { var rowid = getRowid($xetable, row) var tableBody = refTableBody.value var leftBody = refTableLeftBody.value var rightBody = refTableRightBody.value var bodyElem if (column.fixed) { if (column.fixed === 'left') { if (leftBody) { bodyElem = leftBody.$el } } else { if (rightBody) { bodyElem = rightBody.$el } } } if (!bodyElem) { bodyElem = tableBody.$el } if (bodyElem) { return bodyElem.querySelector( '.vxe-body--row[rowid="'.concat(rowid, '"] .').concat(column.id) ) } return null }, getCellLabel: function (row, column) { var formatter2 = column.formatter var cellValue = getCellValue(row, column) var cellLabel = cellValue if (formatter2) { var formatData = void 0 var fullAllDataRowIdData = internalData.fullAllDataRowIdData var rowid = getRowid($xetable, row) var colid = column.id var rest = fullAllDataRowIdData[rowid] if (rest) { formatData = rest.formatData if (!formatData) { formatData = fullAllDataRowIdData[rowid].formatData = {} } if (rest && formatData[colid]) { if (formatData[colid].value === cellValue) { return formatData[colid].label } } } var formatParams = { cellValue, row, rowIndex: tableMethods.getRowIndex(row), column, columnIndex: tableMethods.getColumnIndex(column), } if (xeUtils.isString(formatter2)) { var gFormatOpts = VXETable.formats.get(formatter2) cellLabel = gFormatOpts && gFormatOpts.cellFormatMethod ? gFormatOpts.cellFormatMethod(formatParams) : '' } else if (xeUtils.isArray(formatter2)) { var gFormatOpts = VXETable.formats.get(formatter2[0]) cellLabel = gFormatOpts && gFormatOpts.cellFormatMethod ? gFormatOpts.cellFormatMethod.apply( gFormatOpts, __spreadArray([formatParams], formatter2.slice(1), false) ) : '' } else { cellLabel = formatter2(formatParams) } if (formatData) { formatData[colid] = { value: cellValue, label: cellLabel } } } return cellLabel }, findRowIndexOf: function (list2, row) { return row ? xeUtils.findIndexOf(list2, function (item2) { return $xetable.eqRow(item2, row) }) : -1 }, eqRow: function (row1, row2) { if (row1 && row2) { if (row1 === row2) { return true } return getRowid($xetable, row1) === getRowid($xetable, row2) } return false }, } Object.assign($xetable, tableMethods, tablePrivateMethods) var renderFixed = function (fixedType) { var showHeader = props2.showHeader, showFooter = props2.showFooter var tableData2 = reactData.tableData, tableColumn = reactData.tableColumn, tableGroupColumn = reactData.tableGroupColumn, columnStore = reactData.columnStore, footerTableData = reactData.footerTableData var isFixedLeft = fixedType === 'left' var fixedColumn = isFixedLeft ? columnStore.leftList : columnStore.rightList return h$4( 'div', { ref: isFixedLeft ? refLeftContainer : refRightContainer, class: 'vxe-table--fixed-'.concat(fixedType, '-wrapper'), }, [ showHeader ? h$4(Header$6, { ref: isFixedLeft ? refTableLeftHeader : refTableRightHeader, fixedType, tableData: tableData2, tableColumn, tableGroupColumn, fixedColumn, }) : createCommentVNode(), h$4(TableBodyComponent, { ref: isFixedLeft ? refTableLeftBody : refTableRightBody, fixedType, tableData: tableData2, tableColumn, fixedColumn, }), showFooter ? h$4(Footer$2, { ref: isFixedLeft ? refTableLeftFooter : refTableRightFooter, footerTableData, tableColumn, fixedColumn, fixedType, }) : createCommentVNode(), ] ) } var renderEmptyContenet = function () { var emptyOpts = computeEmptyOpts.value var params2 = { $table: $xetable } if (slots.empty) { return slots.empty(params2) } else { var compConf = emptyOpts.name ? VXETable.renderer.get(emptyOpts.name) : null var renderEmpty = compConf ? compConf.renderEmpty : null if (renderEmpty) { return getSlotVNs(renderEmpty(emptyOpts, params2)) } } return ( getFuncText(props2.emptyText) || GlobalConfig.i18n('vxe.table.emptyText') ) } function handleUupdateResize() { var el2 = refElem.value if (el2 && el2.clientWidth && el2.clientHeight) { tableMethods.recalculate() } } var dataFlag = ref(0) watch$1( function () { return props2.data ? props2.data.length : -1 }, function () { dataFlag.value++ } ) watch$1( function () { return props2.data }, function () { dataFlag.value++ } ) watch$1(dataFlag, function () { var inited = internalData.inited, initStatus = internalData.initStatus loadTableData(props2.data || []).then(function () { reactData.scrollXLoad reactData.scrollYLoad reactData.expandColumn internalData.inited = true internalData.initStatus = true if (!initStatus) { handleLoadDefaults() } if (!inited) { handleInitDefaults() } tableMethods.recalculate() }) }) var staticColumnFlag = ref(0) watch$1( function () { return reactData.staticColumns.length }, function () { staticColumnFlag.value++ } ) watch$1( function () { return reactData.staticColumns }, function () { staticColumnFlag.value++ } ) watch$1(staticColumnFlag, function () { handleColumn(reactData.staticColumns) }) var tableColumnFlag = ref(0) watch$1( function () { return reactData.tableColumn.length }, function () { tableColumnFlag.value++ } ) watch$1( function () { return reactData.tableColumn }, function () { tableColumnFlag.value++ } ) watch$1(tableColumnFlag, function () { tablePrivateMethods.analyColumnWidth() }) watch$1( function () { return reactData.upDataFlag }, function () { nextTick(function () { tableMethods.updateData() }) } ) watch$1( function () { return reactData.reColumnFlag }, function () { nextTick(function () { tableMethods.refreshColumn() }) } ) watch$1( function () { return props2.showHeader }, function () { nextTick(function () { tableMethods.recalculate(true).then(function () { return tableMethods.refreshScroll() }) }) } ) watch$1( function () { return props2.showFooter }, function () { nextTick(function () { tableMethods.recalculate(true).then(function () { return tableMethods.refreshScroll() }) }) } ) watch$1( function () { return props2.height }, function () { nextTick(function () { return tableMethods.recalculate(true) }) } ) watch$1( function () { return props2.maxHeight }, function () { nextTick(function () { return tableMethods.recalculate(true) }) } ) watch$1( function () { return props2.syncResize }, function (value2) { if (value2) { handleUupdateResize() nextTick(function () { handleUupdateResize() setTimeout(function () { return handleUupdateResize() }) }) } } ) var mergeCellFlag = ref(0) watch$1( function () { return props2.mergeCells ? props2.mergeCells.length : -1 }, function () { mergeCellFlag.value++ } ) watch$1( function () { return props2.mergeCells }, function () { mergeCellFlag.value++ } ) watch$1(mergeCellFlag, function () { tableMethods.clearMergeCells() nextTick(function () { if (props2.mergeCells) { tableMethods.setMergeCells(props2.mergeCells) } }) }) var mergeFooterItemFlag = ref(0) watch$1( function () { return props2.mergeFooterItems ? props2.mergeFooterItems.length : -1 }, function () { mergeFooterItemFlag.value++ } ) watch$1( function () { return props2.mergeFooterItems }, function () { mergeFooterItemFlag.value++ } ) watch$1(mergeFooterItemFlag, function () { tableMethods.clearMergeFooterItems() nextTick(function () { if (props2.mergeFooterItems) { tableMethods.setMergeFooterItems(props2.mergeFooterItems) } }) }) VXETable.hooks.forEach(function (options2) { var setupTable = options2.setupTable if (setupTable) { var hookRest = setupTable($xetable) if (hookRest && xeUtils.isObject(hookRest)) { Object.assign($xetable, hookRest) } } }) tablePrivateMethods.preventEvent(null, 'created', { $table: $xetable }) var resizeObserver onActivated(function () { tableMethods.recalculate().then(function () { return tableMethods.refreshScroll() }) tablePrivateMethods.preventEvent(null, 'activated', { $table: $xetable }) }) onDeactivated(function () { internalData.isActivated = false tablePrivateMethods.preventEvent(null, 'deactivated', { $table: $xetable, }) }) onMounted(function () { nextTick(function () { var data2 = props2.data props2.treeConfig props2.showOverflow var scrollXStore = internalData.scrollXStore, scrollYStore = internalData.scrollYStore var sYOpts = computeSYOpts.value computeEditOpts.value computeTreeOpts.value computeRadioOpts.value computeCheckboxOpts.value computeExpandOpts.value computeRowOpts.value Object.assign(scrollYStore, { startIndex: 0, endIndex: 0, visibleSize: 0, adaptive: sYOpts.adaptive !== false, }) Object.assign(scrollXStore, { startIndex: 0, endIndex: 0, visibleSize: 0, }) loadTableData(data2 || []).then(function () { if (data2 && data2.length) { internalData.inited = true internalData.initStatus = true handleLoadDefaults() handleInitDefaults() } updateStyle2() }) if (props2.autoResize) { var resizeOpts = computeResizeleOpts.value var refreshDelay = resizeOpts.refreshDelay var el2 = refElem.value var parentEl2 = tablePrivateMethods.getParentElem() var handleOptimizeResize_1 = refreshDelay ? xeUtils.throttle( function () { return tableMethods.recalculate(true) }, refreshDelay, { leading: true, trailing: true } ) : null resizeObserver = createResizeEvent( handleOptimizeResize_1 ? function () { if (props2.autoResize) { requestAnimationFrame(handleOptimizeResize_1) } } : function () { if (props2.autoResize) { tableMethods.recalculate(true) } } ) if (el2) { resizeObserver.observe(el2) } if (parentEl2) { resizeObserver.observe(parentEl2) } } }) GlobalEvent.on($xetable, 'paste', handleGlobalPasteEvent) GlobalEvent.on($xetable, 'copy', handleGlobalCopyEvent) GlobalEvent.on($xetable, 'cut', handleGlobalCutEvent) GlobalEvent.on($xetable, 'mousedown', handleGlobalMousedownEvent) GlobalEvent.on($xetable, 'blur', handleGlobalBlurEvent) GlobalEvent.on($xetable, 'mousewheel', handleGlobalMousewheelEvent) GlobalEvent.on($xetable, 'keydown', handleGlobalKeydownEvent) GlobalEvent.on($xetable, 'resize', handleGlobalResizeEvent) if ($xetable.handleGlobalContextmenuEvent) { GlobalEvent.on( $xetable, 'contextmenu', $xetable.handleGlobalContextmenuEvent ) } tablePrivateMethods.preventEvent(null, 'mounted', { $table: $xetable }) }) onBeforeUnmount(function () { if (resizeObserver) { resizeObserver.disconnect() } tableMethods.closeFilter() if ($xetable.closeMenu) { $xetable.closeMenu() } tablePrivateMethods.preventEvent(null, 'beforeUnmount', { $table: $xetable, }) }) onUnmounted(function () { GlobalEvent.off($xetable, 'paste') GlobalEvent.off($xetable, 'copy') GlobalEvent.off($xetable, 'cut') GlobalEvent.off($xetable, 'mousedown') GlobalEvent.off($xetable, 'blur') GlobalEvent.off($xetable, 'mousewheel') GlobalEvent.off($xetable, 'keydown') GlobalEvent.off($xetable, 'resize') GlobalEvent.off($xetable, 'contextmenu') tablePrivateMethods.preventEvent(null, 'unmounted', { $table: $xetable }) }) var renderVN = function () { var _a2 var loading2 = props2.loading, stripe = props2.stripe, showHeader = props2.showHeader, height = props2.height, treeConfig = props2.treeConfig, mouseConfig = props2.mouseConfig, showFooter = props2.showFooter, highlightCell = props2.highlightCell, highlightHoverRow = props2.highlightHoverRow, highlightHoverColumn = props2.highlightHoverColumn, editConfig = props2.editConfig, editRules = props2.editRules var isGroup2 = reactData.isGroup, overflowX = reactData.overflowX, overflowY = reactData.overflowY, scrollXLoad = reactData.scrollXLoad, scrollYLoad = reactData.scrollYLoad, scrollbarHeight = reactData.scrollbarHeight, tableData2 = reactData.tableData, tableColumn = reactData.tableColumn, tableGroupColumn = reactData.tableGroupColumn, footerTableData = reactData.footerTableData, initStore = reactData.initStore, columnStore = reactData.columnStore, filterStore = reactData.filterStore var leftList = columnStore.leftList, rightList = columnStore.rightList var loadingSlot = slots.loading var tipConfig = computeTipConfig.value var validOpts = computeValidOpts.value var treeOpts = computeTreeOpts.value var rowOpts = computeRowOpts.value var columnOpts = computeColumnOpts.value var vSize = computeSize.value var tableBorder = computeTableBorder.value var mouseOpts = computeMouseOpts.value var validTipOpts = computeValidTipOpts.value var loadingOpts = computeLoadingOpts.value var isMenu = computeIsMenu.value return h$4( 'div', { ref: refElem, class: [ 'vxe-table', 'vxe-table--render-default', 'tid_'.concat(xID), 'border--'.concat(tableBorder), ((_a2 = {}), (_a2['size--'.concat(vSize)] = vSize), (_a2['vaild-msg--'.concat(validOpts.msgMode)] = !!editRules), (_a2['vxe-editable'] = !!editConfig), (_a2['old-cell-valid'] = editRules && GlobalConfig.cellVaildMode === 'obsolete'), (_a2['cell--highlight'] = highlightCell), (_a2['cell--selected'] = mouseConfig && mouseOpts.selected), (_a2['cell--area'] = mouseConfig && mouseOpts.area), (_a2['row--highlight'] = rowOpts.isHover || highlightHoverRow), (_a2['column--highlight'] = columnOpts.isHover || highlightHoverColumn), (_a2['is--header'] = showHeader), (_a2['is--footer'] = showFooter), (_a2['is--group'] = isGroup2), (_a2['is--tree-line'] = treeConfig && (treeOpts.showLine || treeOpts.line)), (_a2['is--fixed-left'] = leftList.length), (_a2['is--fixed-right'] = rightList.length), (_a2['is--animat'] = !!props2.animat), (_a2['is--round'] = props2.round), (_a2['is--stripe'] = !treeConfig && stripe), (_a2['is--loading'] = loading2), (_a2['is--empty'] = !loading2 && !tableData2.length), (_a2['is--scroll-y'] = overflowY), (_a2['is--scroll-x'] = overflowX), (_a2['is--virtual-x'] = scrollXLoad), (_a2['is--virtual-y'] = scrollYLoad), _a2), ], onKeydown: keydownEvent, }, [ h$4( 'div', { class: 'vxe-table-slots', }, slots.default ? slots.default({}) : [] ), h$4( 'div', { class: 'vxe-table--render-wrapper', }, [ h$4( 'div', { class: 'vxe-table--main-wrapper', }, [ showHeader ? h$4(Header$6, { ref: refTableHeader, tableData: tableData2, tableColumn, tableGroupColumn, }) : createCommentVNode(), h$4(TableBodyComponent, { ref: refTableBody, tableData: tableData2, tableColumn, }), showFooter ? h$4(Footer$2, { ref: refTableFooter, footerTableData, tableColumn, }) : createCommentVNode(), ] ), h$4( 'div', { class: 'vxe-table--fixed-wrapper', }, [ leftList && leftList.length && overflowX ? renderFixed('left') : createCommentVNode(), rightList && rightList.length && overflowX ? renderFixed('right') : createCommentVNode(), ] ), ] ), h$4( 'div', { ref: refEmptyPlaceholder, class: 'vxe-table--empty-placeholder', }, [ h$4( 'div', { class: 'vxe-table--empty-content', }, renderEmptyContenet() ), ] ), h$4('div', { class: 'vxe-table--border-line', }), h$4('div', { ref: refCellResizeBar, class: 'vxe-table--resizable-bar', style: overflowX ? { 'padding-bottom': ''.concat(scrollbarHeight, 'px'), } : null, }), h$4( VxeLoading, { class: 'vxe-table--loading', modelValue: loading2, icon: loadingOpts.icon, text: loadingOpts.text, }, loadingSlot ? { default: function () { return loadingSlot({ $table: $xetable, $grid: $xegrid }) }, } : {} ), initStore.filter ? h$4(resolveComponent('vxe-table-filter'), { ref: refTableFilter, filterStore, }) : createCommentVNode(), initStore.import && props2.importConfig ? h$4(resolveComponent('vxe-import-panel'), { defaultOptions: reactData.importParams, storeData: reactData.importStore, }) : createCommentVNode(), initStore.export && (props2.exportConfig || props2.printConfig) ? h$4(resolveComponent('vxe-export-panel'), { defaultOptions: reactData.exportParams, storeData: reactData.exportStore, }) : createCommentVNode(), isMenu ? h$4(resolveComponent('vxe-table-context-menu'), { ref: refTableMenu, }) : createCommentVNode(), hasUseTooltip ? h$4(resolveComponent('vxe-tooltip'), { ref: refCommTooltip, isArrow: false, enterable: false, }) : createCommentVNode(), hasUseTooltip && props2.editRules && validOpts.showMessage && (validOpts.message === 'default' ? !height : validOpts.message === 'tooltip') ? h$4( resolveComponent('vxe-tooltip'), __assign( { ref: refValidTooltip, class: [ { 'old-cell-valid': editRules && GlobalConfig.cellVaildMode === 'obsolete', }, 'vxe-table--valid-error', ], }, validOpts.message === 'tooltip' || tableData2.length === 1 ? validTipOpts : {} ) ) : createCommentVNode(), hasUseTooltip ? h$4( resolveComponent('vxe-tooltip'), __assign({ ref: refTooltip }, tipConfig) ) : createCommentVNode(), ] ) } $xetable.renderVN = renderVN provide('xecolgroup', null) provide('$xetable', $xetable) return $xetable }, render: function () { return this.renderVN() }, }) var VxeTable = Object.assign(VxeTableComponent, { install: function (app2) { app2.component(VxeTableComponent.name, VxeTableComponent) }, }) var Table$4 = VxeTable dynamicApp.component(VxeTableComponent.name, VxeTableComponent) var zhCN$1 = { vxe: { base: { pleaseInput: '\u8BF7\u8F93\u5165', pleaseSelect: '\u8BF7\u9009\u62E9', }, loading: { text: '\u52A0\u8F7D\u4E2D...', }, error: { groupFixed: '\u5982\u679C\u4F7F\u7528\u5206\u7EC4\u8868\u5934\uFF0C\u56FA\u5B9A\u5217\u5FC5\u987B\u6309\u7EC4\u8BBE\u7F6E', groupMouseRange: '\u5206\u7EC4\u8868\u5934\u4E0E "{0}" \u4E0D\u80FD\u540C\u65F6\u4F7F\u7528\uFF0C\u8FD9\u53EF\u80FD\u4F1A\u51FA\u73B0\u9519\u8BEF', groupTag: '\u5206\u7EC4\u5217\u5934\u5E94\u8BE5\u4F7F\u7528 "{0}" \u800C\u4E0D\u662F "{1}"\uFF0C\u8FD9\u53EF\u80FD\u4F1A\u51FA\u73B0\u9519\u8BEF', scrollErrProp: '\u542F\u7528\u865A\u62DF\u6EDA\u52A8\u540E\u4E0D\u652F\u6301\u8BE5\u53C2\u6570 "{0}"', errConflicts: '\u53C2\u6570 "{0}" \u4E0E "{1}" \u6709\u51B2\u7A81', unableInsert: '\u65E0\u6CD5\u63D2\u5165\u5230\u6307\u5B9A\u4F4D\u7F6E\uFF0C\u8BF7\u68C0\u67E5\u53C2\u6570\u662F\u5426\u6B63\u786E', useErr: '\u5B89\u88C5 "{0}" \u6A21\u5757\u65F6\u53D1\u751F\u9519\u8BEF\uFF0C\u53EF\u80FD\u987A\u5E8F\u4E0D\u6B63\u786E\uFF0C\u4F9D\u8D56\u7684\u6A21\u5757\u9700\u8981\u5728 Table \u4E4B\u524D\u5B89\u88C5', barUnableLink: '\u5DE5\u5177\u680F\u65E0\u6CD5\u5173\u8054\u8868\u683C', expandContent: '\u5C55\u5F00\u884C\u7684\u63D2\u69FD\u5E94\u8BE5\u662F "content"\uFF0C\u8BF7\u68C0\u67E5\u662F\u5426\u6B63\u786E', reqModule: '\u7F3A\u5C11 "{0}" \u6A21\u5757', reqProp: '\u7F3A\u5C11\u5FC5\u8981\u7684 "{0}" \u53C2\u6570\uFF0C\u8FD9\u53EF\u80FD\u4F1A\u5BFC\u81F4\u51FA\u73B0\u9519\u8BEF', emptyProp: '\u53C2\u6570 "{0}" \u4E0D\u5141\u8BB8\u4E3A\u7A7A', errProp: '\u4E0D\u652F\u6301\u7684\u53C2\u6570 "{0}"\uFF0C\u53EF\u80FD\u4E3A "{1}"', colRepet: 'column.{0}="{1}" \u91CD\u590D\u4E86\uFF0C\u8FD9\u53EF\u80FD\u4F1A\u5BFC\u81F4\u67D0\u4E9B\u529F\u80FD\u65E0\u6CD5\u4F7F\u7528', notFunc: '\u65B9\u6CD5 "{0}" \u4E0D\u5B58\u5728', errFunc: '\u53C2\u6570 "{0}" \u4E0D\u662F\u4E00\u4E2A\u65B9\u6CD5', notValidators: '\u5168\u5C40\u6821\u9A8C "{0}" \u4E0D\u5B58\u5728', notFormats: '\u5168\u5C40\u683C\u5F0F\u5316 "{0}" \u4E0D\u5B58\u5728', notCommands: '\u5168\u5C40\u6307\u4EE4 "{0}" \u4E0D\u5B58\u5728', notSlot: '\u63D2\u69FD "{0}" \u4E0D\u5B58\u5728', noTree: '\u6811\u7ED3\u6784\u4E0D\u652F\u6301 "{0}"', notProp: '\u4E0D\u652F\u6301\u7684\u53C2\u6570 "{0}"', checkProp: '\u5F53\u6570\u636E\u91CF\u8FC7\u5927\u65F6\u53EF\u80FD\u4F1A\u5BFC\u81F4\u590D\u9009\u6846\u5361\u987F\uFF0C\u5EFA\u8BAE\u8BBE\u7F6E\u53C2\u6570 "{0}" \u63D0\u5347\u6E32\u67D3\u901F\u5EA6', coverProp: '"{0}" \u7684\u53C2\u6570 "{1}" \u88AB\u8986\u76D6\uFF0C\u8FD9\u53EF\u80FD\u4F1A\u51FA\u73B0\u9519\u8BEF', delFunc: '\u65B9\u6CD5 "{0}" \u5DF2\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528 "{1}"', delProp: '\u53C2\u6570 "{0}" \u5DF2\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528 "{1}"', delEvent: '\u4E8B\u4EF6 "{0}" \u5DF2\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528 "{1}"', removeProp: '\u53C2\u6570 "{0}" \u5DF2\u5E9F\u5F03\uFF0C\u4E0D\u5EFA\u8BAE\u4F7F\u7528\uFF0C\u8FD9\u53EF\u80FD\u4F1A\u5BFC\u81F4\u51FA\u73B0\u9519\u8BEF', errFormat: '\u5168\u5C40\u7684\u683C\u5F0F\u5316\u5185\u5BB9\u5E94\u8BE5\u4F7F\u7528 "VXETable.formats" \u5B9A\u4E49\uFF0C\u6302\u8F7D "formatter={0}" \u7684\u65B9\u5F0F\u5DF2\u4E0D\u5EFA\u8BAE\u4F7F\u7528', notType: '\u4E0D\u652F\u6301\u7684\u6587\u4EF6\u7C7B\u578B "{0}"', notExp: '\u8BE5\u6D4F\u89C8\u5668\u4E0D\u652F\u6301\u5BFC\u5165/\u5BFC\u51FA\u529F\u80FD', impFields: '\u5BFC\u5165\u5931\u8D25\uFF0C\u8BF7\u68C0\u67E5\u5B57\u6BB5\u540D\u548C\u6570\u636E\u683C\u5F0F\u662F\u5426\u6B63\u786E', treeNotImp: '\u6811\u8868\u683C\u4E0D\u652F\u6301\u5BFC\u5165', }, renderer: { search: '\u641C\u7D22', cases: { equal: '\u7B49\u4E8E', unequal: '\u4E0D\u7B49\u4E8E', gt: '\u5927\u4E8E', ge: '\u5927\u4E8E\u6216\u7B49\u4E8E', lt: '\u5C0F\u4E8E', le: '\u5C0F\u4E8E\u6216\u7B49\u4E8E', begin: '\u5F00\u5934\u662F', notbegin: '\u5F00\u5934\u4E0D\u662F', endin: '\u7ED3\u5C3E\u662F', notendin: '\u7ED3\u5C3E\u4E0D\u662F', include: '\u5305\u542B', exclude: '\u4E0D\u5305\u542B', between: '\u4ECB\u4E8E', custom: '\u81EA\u5B9A\u4E49\u7B5B\u9009', insensitive: '\u4E0D\u533A\u5206\u5927\u5C0F\u5199', isSensitive: '\u533A\u5206\u5927\u5C0F\u5199', }, combination: { menus: { clearSort: '\u6E05\u9664\u6392\u5E8F', sortAsc: '\u5347\u5E8F', sortDesc: '\u964D\u5E8F', fixedColumn: '\u9501\u5B9A\u5217', fixedGroup: '\u9501\u5B9A\u7EC4', cancelFixed: '\u53D6\u6D88\u9501\u5B9A', fixedLeft: '\u9501\u5B9A\u5DE6\u4FA7', fixedRight: '\u9501\u5B9A\u53F3\u4FA7', clearFilter: '\u6E05\u9664\u7B5B\u9009', textOption: '\u6587\u672C\u7B5B\u9009', numberOption: '\u6570\u503C\u7B5B\u9009', }, popup: { title: '\u81EA\u5B9A\u4E49\u7B5B\u9009\u7684\u65B9\u5F0F', currColumnTitle: '\u5F53\u524D\u5217\uFF1A', and: '\u4E0E', or: '\u6216', describeHtml: '\u53EF\u7528 ? \u4EE3\u8868\u5355\u4E2A\u5B57\u7B26
\u7528 * \u4EE3\u8868\u4EFB\u610F\u591A\u4E2A\u5B57\u7B26', }, empty: '(\u7A7A\u767D)', notData: '\u65E0\u5339\u914D\u9879', }, }, pro: { area: { mergeErr: '\u65E0\u6CD5\u5BF9\u5408\u5E76\u5355\u5143\u683C\u8FDB\u884C\u8BE5\u64CD\u4F5C', multiErr: '\u65E0\u6CD5\u5BF9\u591A\u91CD\u9009\u62E9\u533A\u57DF\u8FDB\u884C\u8BE5\u64CD\u4F5C', extendErr: '\u5982\u679C\u5EF6\u4F38\u7684\u533A\u57DF\u5305\u542B\u88AB\u5408\u5E76\u7684\u5355\u5143\u683C\uFF0C\u6240\u6709\u5408\u5E76\u7684\u5355\u5143\u683C\u9700\u5927\u5C0F\u76F8\u540C', pasteMultiErr: '\u65E0\u6CD5\u7C98\u8D34\uFF0C\u9700\u8981\u76F8\u540C\u5927\u5C0F\u7684\u590D\u5236\u7684\u533A\u57DF\u548C\u7C98\u8D34\u7684\u533A\u57DF\u624D\u80FD\u6267\u884C\u6B64\u64CD\u4F5C', }, fnr: { title: '\u67E5\u627E\u548C\u66FF\u6362', findLabel: '\u67E5\u627E', replaceLabel: '\u66FF\u6362', findTitle: '\u67E5\u627E\u5185\u5BB9\uFF1A', replaceTitle: '\u66FF\u6362\u4E3A\uFF1A', tabs: { find: '\u67E5\u627E', replace: '\u66FF\u6362', }, filter: { re: '\u6B63\u5219\u8868\u8FBE\u5F0F', whole: '\u5168\u8BCD\u5339\u914D', sensitive: '\u533A\u5206\u5927\u5C0F\u5199', }, btns: { findNext: '\u67E5\u627E\u4E0B\u4E00\u4E2A', findAll: '\u67E5\u627E\u5168\u90E8', replace: '\u66FF\u6362', replaceAll: '\u66FF\u6362\u5168\u90E8', cancel: '\u53D6\u6D88', }, header: { seq: '#', cell: '\u5355\u5143\u683C', value: '\u503C', }, empty: '(\u7A7A\u503C)', reError: '\u65E0\u6548\u7684\u6B63\u5219\u8868\u8FBE\u5F0F', recordCount: '\u5DF2\u627E\u5230 {0} \u4E2A\u5355\u5143\u683C', notCell: '\u627E\u4E0D\u5230\u5339\u914D\u7684\u5355\u5143\u683C', replaceSuccess: '\u6210\u529F\u66FF\u6362 {0} \u4E2A\u5355\u5143\u683C', }, }, table: { emptyText: '\u6682\u65E0\u6570\u636E', allTitle: '\u5168\u9009/\u53D6\u6D88', seqTitle: '#', confirmFilter: '\u7B5B\u9009', resetFilter: '\u91CD\u7F6E', allFilter: '\u5168\u90E8', sortAsc: '\u5347\u5E8F\uFF1A\u6700\u4F4E\u5230\u6700\u9AD8', sortDesc: '\u964D\u5E8F\uFF1A\u6700\u9AD8\u5230\u6700\u4F4E', filter: '\u5BF9\u6240\u9009\u7684\u5217\u542F\u7528\u7B5B\u9009', impSuccess: '\u6210\u529F\u5BFC\u5165 {0} \u6761\u8BB0\u5F55', expLoading: '\u6B63\u5728\u5BFC\u51FA\u4E2D', expSuccess: '\u5BFC\u51FA\u6210\u529F', expFilename: '\u5BFC\u51FA_{0}', expOriginFilename: '\u5BFC\u51FA_\u6E90_{0}', customTitle: '\u5217\u8BBE\u7F6E', customAll: '\u5168\u90E8', customConfirm: '\u786E\u8BA4', customRestore: '\u91CD\u7F6E', maxFixedCol: '\u6700\u5927\u56FA\u5B9A\u5217\u7684\u6570\u91CF\u4E0D\u80FD\u8D85\u8FC7 {0} \u4E2A', }, grid: { selectOneRecord: '\u8BF7\u81F3\u5C11\u9009\u62E9\u4E00\u6761\u8BB0\u5F55\uFF01', deleteSelectRecord: '\u60A8\u786E\u5B9A\u8981\u5220\u9664\u6240\u9009\u8BB0\u5F55\u5417\uFF1F', removeSelectRecord: '\u60A8\u786E\u5B9A\u8981\u79FB\u9664\u6240\u9009\u8BB0\u5F55\u5417\uFF1F', dataUnchanged: '\u6570\u636E\u672A\u6539\u52A8\uFF01', delSuccess: '\u6210\u529F\u5220\u9664\u6240\u9009\u8BB0\u5F55\uFF01', saveSuccess: '\u4FDD\u5B58\u6210\u529F\uFF01', operError: '\u53D1\u751F\u9519\u8BEF\uFF0C\u64CD\u4F5C\u5931\u8D25\uFF01', }, select: { search: '\u641C\u7D22', loadingText: '\u52A0\u8F7D\u4E2D', emptyText: '\u6682\u65E0\u6570\u636E', }, pager: { goto: '\u524D\u5F80', pagesize: '{0}\u6761/\u9875', total: '\u5171 {0} \u6761\u8BB0\u5F55', pageClassifier: '\u9875', prevPage: '\u4E0A\u4E00\u9875', nextPage: '\u4E0B\u4E00\u9875', prevJump: '\u5411\u4E0A\u8DF3\u9875', nextJump: '\u5411\u4E0B\u8DF3\u9875', }, alert: { title: '\u6D88\u606F\u63D0\u793A', }, button: { confirm: '\u786E\u8BA4', cancel: '\u53D6\u6D88', }, import: { modes: { covering: '\u8986\u76D6', insert: '\u65B0\u589E', }, impTitle: '\u5BFC\u5165\u6570\u636E', impFile: '\u6587\u4EF6\u540D', impSelect: '\u9009\u62E9\u6587\u4EF6', impType: '\u6587\u4EF6\u7C7B\u578B', impOpts: '\u53C2\u6570\u8BBE\u7F6E', impConfirm: '\u5BFC\u5165', impCancel: '\u53D6\u6D88', }, export: { types: { csv: 'CSV (\u9017\u53F7\u5206\u9694)(*.csv)', html: '\u7F51\u9875(*.html)', xml: 'XML \u6570\u636E(*.xml)', txt: '\u6587\u672C\u6587\u4EF6(\u5236\u8868\u7B26\u5206\u9694)(*.txt)', xls: 'Excel 97-2003 \u5DE5\u4F5C\u7C3F(*.xls)', xlsx: 'Excel \u5DE5\u4F5C\u7C3F(*.xlsx)', pdf: 'PDF (*.pdf)', }, modes: { current: '\u5F53\u524D\u6570\u636E\uFF08\u5F53\u524D\u9875\u7684\u6570\u636E\uFF09', selected: '\u9009\u4E2D\u6570\u636E\uFF08\u5F53\u524D\u9875\u9009\u4E2D\u7684\u6570\u636E\uFF09', all: '\u5168\u91CF\u6570\u636E\uFF08\u5305\u62EC\u6240\u6709\u5206\u9875\u7684\u6570\u636E\uFF09', }, printTitle: '\u6253\u5370\u6570\u636E', expTitle: '\u5BFC\u51FA\u6570\u636E', expName: '\u6587\u4EF6\u540D', expNamePlaceholder: '\u8BF7\u8F93\u5165\u6587\u4EF6\u540D', expSheetName: '\u6807\u9898', expSheetNamePlaceholder: '\u8BF7\u8F93\u5165\u6807\u9898', expType: '\u4FDD\u5B58\u7C7B\u578B', expMode: '\u9009\u62E9\u6570\u636E', expCurrentColumn: '\u5168\u90E8\u5B57\u6BB5', expColumn: '\u9009\u62E9\u5B57\u6BB5', expOpts: '\u53C2\u6570\u8BBE\u7F6E', expOptHeader: '\u8868\u5934', expHeaderTitle: '\u662F\u5426\u9700\u8981\u8868\u5934', expOptFooter: '\u8868\u5C3E', expFooterTitle: '\u662F\u5426\u9700\u8981\u8868\u5C3E', expOptColgroup: '\u5206\u7EC4\u8868\u5934', expColgroupTitle: '\u5982\u679C\u5B58\u5728\uFF0C\u5219\u652F\u6301\u5E26\u6709\u5206\u7EC4\u7ED3\u6784\u7684\u8868\u5934', expOptMerge: '\u5408\u5E76', expMergeTitle: '\u5982\u679C\u5B58\u5728\uFF0C\u5219\u652F\u6301\u5E26\u6709\u5408\u5E76\u7ED3\u6784\u7684\u5355\u5143\u683C', expOptAllExpand: '\u5C55\u5F00\u5C42\u7EA7', expAllExpandTitle: '\u5982\u679C\u5B58\u5728\uFF0C\u5219\u652F\u6301\u5C06\u5E26\u6709\u5C42\u7EA7\u7ED3\u6784\u7684\u6570\u636E\u5168\u90E8\u5C55\u5F00', expOptUseStyle: '\u6837\u5F0F', expUseStyleTitle: '\u5982\u679C\u5B58\u5728\uFF0C\u5219\u652F\u6301\u5E26\u6837\u5F0F\u7684\u5355\u5143\u683C', expOptOriginal: '\u6E90\u6570\u636E', expOriginalTitle: '\u5982\u679C\u4E3A\u6E90\u6570\u636E\uFF0C\u5219\u652F\u6301\u5BFC\u5165\u5230\u8868\u683C\u4E2D', expPrint: '\u6253\u5370', expConfirm: '\u5BFC\u51FA', expCancel: '\u53D6\u6D88', }, modal: { zoomIn: '\u6700\u5927\u5316', zoomOut: '\u8FD8\u539F', close: '\u5173\u95ED', }, form: { folding: '\u6536\u8D77', unfolding: '\u5C55\u5F00', }, toolbar: { import: '\u5BFC\u5165', export: '\u5BFC\u51FA', print: '\u6253\u5370', refresh: '\u5237\u65B0', zoomIn: '\u5168\u5C4F', zoomOut: '\u8FD8\u539F', custom: '\u5217\u8BBE\u7F6E', customAll: '\u5168\u90E8', customConfirm: '\u786E\u8BA4', customRestore: '\u91CD\u7F6E', fixedLeft: '\u56FA\u5B9A\u5728\u5DE6\u4FA7', fixedRight: '\u56FA\u5B9A\u5728\u53F3\u4FA7', cancelfixed: '\u53D6\u6D88\u56FA\u5B9A', }, input: { date: { m1: '01 \u6708', m2: '02 \u6708', m3: '03 \u6708', m4: '04 \u6708', m5: '05 \u6708', m6: '06 \u6708', m7: '07 \u6708', m8: '08 \u6708', m9: '09 \u6708', m10: '10 \u6708', m11: '11 \u6708', m12: '12 \u6708', quarterLabel: '{0} \u5E74', monthLabel: '{0} \u5E74', dayLabel: '{0} \u5E74 {1}', labelFormat: { date: 'yyyy-MM-dd', time: 'HH:mm:ss', datetime: 'yyyy-MM-dd HH:mm:ss', week: 'yyyy \u5E74\u7B2C WW \u5468', month: 'yyyy-MM', quarter: 'yyyy \u5E74\u7B2C q \u5B63\u5EA6', year: 'yyyy', }, weeks: { w: '\u5468', w0: '\u5468\u65E5', w1: '\u5468\u4E00', w2: '\u5468\u4E8C', w3: '\u5468\u4E09', w4: '\u5468\u56DB', w5: '\u5468\u4E94', w6: '\u5468\u516D', }, months: { m0: '\u4E00\u6708', m1: '\u4E8C\u6708', m2: '\u4E09\u6708', m3: '\u56DB\u6708', m4: '\u4E94\u6708', m5: '\u516D\u6708', m6: '\u4E03\u6708', m7: '\u516B\u6708', m8: '\u4E5D\u6708', m9: '\u5341\u6708', m10: '\u5341\u4E00\u6708', m11: '\u5341\u4E8C\u6708', }, quarters: { q1: '\u7B2C\u4E00\u5B63\u5EA6', q2: '\u7B2C\u4E8C\u5B63\u5EA6', q3: '\u7B2C\u4E09\u5B63\u5EA6', q4: '\u7B2C\u56DB\u5B63\u5EA6', }, }, }, }, } setup({ i18n: function (key2, args) { return xeUtils.toFormatString(xeUtils.get(zhCN$1, key2), args) }, }) var style$1 = '' var zhCN = {} Object.defineProperty(zhCN, '__esModule', { value: true, }) var default_1 = (zhCN.default = void 0) var _default = { vxe: { base: { pleaseInput: '\u8BF7\u8F93\u5165', pleaseSelect: '\u8BF7\u9009\u62E9', }, loading: { text: '\u52A0\u8F7D\u4E2D...', }, error: { groupFixed: '\u5982\u679C\u4F7F\u7528\u5206\u7EC4\u8868\u5934\uFF0C\u56FA\u5B9A\u5217\u5FC5\u987B\u6309\u7EC4\u8BBE\u7F6E', groupMouseRange: '\u5206\u7EC4\u8868\u5934\u4E0E "{0}" \u4E0D\u80FD\u540C\u65F6\u4F7F\u7528\uFF0C\u8FD9\u53EF\u80FD\u4F1A\u51FA\u73B0\u9519\u8BEF', groupTag: '\u5206\u7EC4\u5217\u5934\u5E94\u8BE5\u4F7F\u7528 "{0}" \u800C\u4E0D\u662F "{1}"\uFF0C\u8FD9\u53EF\u80FD\u4F1A\u51FA\u73B0\u9519\u8BEF', scrollErrProp: '\u542F\u7528\u865A\u62DF\u6EDA\u52A8\u540E\u4E0D\u652F\u6301\u8BE5\u53C2\u6570 "{0}"', errConflicts: '\u53C2\u6570 "{0}" \u4E0E "{1}" \u6709\u51B2\u7A81', unableInsert: '\u65E0\u6CD5\u63D2\u5165\u5230\u6307\u5B9A\u4F4D\u7F6E\uFF0C\u8BF7\u68C0\u67E5\u53C2\u6570\u662F\u5426\u6B63\u786E', useErr: '\u5B89\u88C5 "{0}" \u6A21\u5757\u65F6\u53D1\u751F\u9519\u8BEF\uFF0C\u53EF\u80FD\u987A\u5E8F\u4E0D\u6B63\u786E\uFF0C\u4F9D\u8D56\u7684\u6A21\u5757\u9700\u8981\u5728 Table \u4E4B\u524D\u5B89\u88C5', barUnableLink: '\u5DE5\u5177\u680F\u65E0\u6CD5\u5173\u8054\u8868\u683C', expandContent: '\u5C55\u5F00\u884C\u7684\u63D2\u69FD\u5E94\u8BE5\u662F "content"\uFF0C\u8BF7\u68C0\u67E5\u662F\u5426\u6B63\u786E', reqModule: '\u7F3A\u5C11 "{0}" \u6A21\u5757', reqProp: '\u7F3A\u5C11\u5FC5\u8981\u7684 "{0}" \u53C2\u6570\uFF0C\u8FD9\u53EF\u80FD\u4F1A\u5BFC\u81F4\u51FA\u73B0\u9519\u8BEF', emptyProp: '\u53C2\u6570 "{0}" \u4E0D\u5141\u8BB8\u4E3A\u7A7A', errProp: '\u4E0D\u652F\u6301\u7684\u53C2\u6570 "{0}"\uFF0C\u53EF\u80FD\u4E3A "{1}"', colRepet: 'column.{0}="{1}" \u91CD\u590D\u4E86\uFF0C\u8FD9\u53EF\u80FD\u4F1A\u5BFC\u81F4\u67D0\u4E9B\u529F\u80FD\u65E0\u6CD5\u4F7F\u7528', notFunc: '\u65B9\u6CD5 "{0}" \u4E0D\u5B58\u5728', errFunc: '\u53C2\u6570 "{0}" \u4E0D\u662F\u4E00\u4E2A\u65B9\u6CD5', notValidators: '\u5168\u5C40\u6821\u9A8C "{0}" \u4E0D\u5B58\u5728', notFormats: '\u5168\u5C40\u683C\u5F0F\u5316 "{0}" \u4E0D\u5B58\u5728', notCommands: '\u5168\u5C40\u6307\u4EE4 "{0}" \u4E0D\u5B58\u5728', notSlot: '\u63D2\u69FD "{0}" \u4E0D\u5B58\u5728', noTree: '\u6811\u7ED3\u6784\u4E0D\u652F\u6301 "{0}"', notProp: '\u4E0D\u652F\u6301\u7684\u53C2\u6570 "{0}"', checkProp: '\u5F53\u6570\u636E\u91CF\u8FC7\u5927\u65F6\u53EF\u80FD\u4F1A\u5BFC\u81F4\u590D\u9009\u6846\u5361\u987F\uFF0C\u5EFA\u8BAE\u8BBE\u7F6E\u53C2\u6570 "{0}" \u63D0\u5347\u6E32\u67D3\u901F\u5EA6', coverProp: '"{0}" \u7684\u53C2\u6570 "{1}" \u88AB\u8986\u76D6\uFF0C\u8FD9\u53EF\u80FD\u4F1A\u51FA\u73B0\u9519\u8BEF', delFunc: '\u65B9\u6CD5 "{0}" \u5DF2\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528 "{1}"', delProp: '\u53C2\u6570 "{0}" \u5DF2\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528 "{1}"', delEvent: '\u4E8B\u4EF6 "{0}" \u5DF2\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528 "{1}"', removeProp: '\u53C2\u6570 "{0}" \u5DF2\u5E9F\u5F03\uFF0C\u4E0D\u5EFA\u8BAE\u4F7F\u7528\uFF0C\u8FD9\u53EF\u80FD\u4F1A\u5BFC\u81F4\u51FA\u73B0\u9519\u8BEF', errFormat: '\u5168\u5C40\u7684\u683C\u5F0F\u5316\u5185\u5BB9\u5E94\u8BE5\u4F7F\u7528 "VXETable.formats" \u5B9A\u4E49\uFF0C\u6302\u8F7D "formatter={0}" \u7684\u65B9\u5F0F\u5DF2\u4E0D\u5EFA\u8BAE\u4F7F\u7528', notType: '\u4E0D\u652F\u6301\u7684\u6587\u4EF6\u7C7B\u578B "{0}"', notExp: '\u8BE5\u6D4F\u89C8\u5668\u4E0D\u652F\u6301\u5BFC\u5165/\u5BFC\u51FA\u529F\u80FD', impFields: '\u5BFC\u5165\u5931\u8D25\uFF0C\u8BF7\u68C0\u67E5\u5B57\u6BB5\u540D\u548C\u6570\u636E\u683C\u5F0F\u662F\u5426\u6B63\u786E', treeNotImp: '\u6811\u8868\u683C\u4E0D\u652F\u6301\u5BFC\u5165', }, renderer: { search: '\u641C\u7D22', cases: { equal: '\u7B49\u4E8E', unequal: '\u4E0D\u7B49\u4E8E', gt: '\u5927\u4E8E', ge: '\u5927\u4E8E\u6216\u7B49\u4E8E', lt: '\u5C0F\u4E8E', le: '\u5C0F\u4E8E\u6216\u7B49\u4E8E', begin: '\u5F00\u5934\u662F', notbegin: '\u5F00\u5934\u4E0D\u662F', endin: '\u7ED3\u5C3E\u662F', notendin: '\u7ED3\u5C3E\u4E0D\u662F', include: '\u5305\u542B', exclude: '\u4E0D\u5305\u542B', between: '\u4ECB\u4E8E', custom: '\u81EA\u5B9A\u4E49\u7B5B\u9009', insensitive: '\u4E0D\u533A\u5206\u5927\u5C0F\u5199', isSensitive: '\u533A\u5206\u5927\u5C0F\u5199', }, combination: { menus: { clearSort: '\u6E05\u9664\u6392\u5E8F', sortAsc: '\u5347\u5E8F', sortDesc: '\u964D\u5E8F', fixedColumn: '\u9501\u5B9A\u5217', fixedGroup: '\u9501\u5B9A\u7EC4', cancelFixed: '\u53D6\u6D88\u9501\u5B9A', fixedLeft: '\u9501\u5B9A\u5DE6\u4FA7', fixedRight: '\u9501\u5B9A\u53F3\u4FA7', clearFilter: '\u6E05\u9664\u7B5B\u9009', textOption: '\u6587\u672C\u7B5B\u9009', numberOption: '\u6570\u503C\u7B5B\u9009', }, popup: { title: '\u81EA\u5B9A\u4E49\u7B5B\u9009\u7684\u65B9\u5F0F', currColumnTitle: '\u5F53\u524D\u5217\uFF1A', and: '\u4E0E', or: '\u6216', describeHtml: '\u53EF\u7528 ? \u4EE3\u8868\u5355\u4E2A\u5B57\u7B26
\u7528 * \u4EE3\u8868\u4EFB\u610F\u591A\u4E2A\u5B57\u7B26', }, empty: '(\u7A7A\u767D)', notData: '\u65E0\u5339\u914D\u9879', }, }, pro: { area: { mergeErr: '\u65E0\u6CD5\u5BF9\u5408\u5E76\u5355\u5143\u683C\u8FDB\u884C\u8BE5\u64CD\u4F5C', multiErr: '\u65E0\u6CD5\u5BF9\u591A\u91CD\u9009\u62E9\u533A\u57DF\u8FDB\u884C\u8BE5\u64CD\u4F5C', extendErr: '\u5982\u679C\u5EF6\u4F38\u7684\u533A\u57DF\u5305\u542B\u88AB\u5408\u5E76\u7684\u5355\u5143\u683C\uFF0C\u6240\u6709\u5408\u5E76\u7684\u5355\u5143\u683C\u9700\u5927\u5C0F\u76F8\u540C', pasteMultiErr: '\u65E0\u6CD5\u7C98\u8D34\uFF0C\u9700\u8981\u76F8\u540C\u5927\u5C0F\u7684\u590D\u5236\u7684\u533A\u57DF\u548C\u7C98\u8D34\u7684\u533A\u57DF\u624D\u80FD\u6267\u884C\u6B64\u64CD\u4F5C', }, fnr: { title: '\u67E5\u627E\u548C\u66FF\u6362', findLabel: '\u67E5\u627E', replaceLabel: '\u66FF\u6362', findTitle: '\u67E5\u627E\u5185\u5BB9\uFF1A', replaceTitle: '\u66FF\u6362\u4E3A\uFF1A', tabs: { find: '\u67E5\u627E', replace: '\u66FF\u6362', }, filter: { re: '\u6B63\u5219\u8868\u8FBE\u5F0F', whole: '\u5168\u8BCD\u5339\u914D', sensitive: '\u533A\u5206\u5927\u5C0F\u5199', }, btns: { findNext: '\u67E5\u627E\u4E0B\u4E00\u4E2A', findAll: '\u67E5\u627E\u5168\u90E8', replace: '\u66FF\u6362', replaceAll: '\u66FF\u6362\u5168\u90E8', cancel: '\u53D6\u6D88', }, header: { seq: '#', cell: '\u5355\u5143\u683C', value: '\u503C', }, empty: '(\u7A7A\u503C)', reError: '\u65E0\u6548\u7684\u6B63\u5219\u8868\u8FBE\u5F0F', recordCount: '\u5DF2\u627E\u5230 {0} \u4E2A\u5355\u5143\u683C', notCell: '\u627E\u4E0D\u5230\u5339\u914D\u7684\u5355\u5143\u683C', replaceSuccess: '\u6210\u529F\u66FF\u6362 {0} \u4E2A\u5355\u5143\u683C', }, }, table: { emptyText: '\u6682\u65E0\u6570\u636E', allTitle: '\u5168\u9009/\u53D6\u6D88', seqTitle: '#', confirmFilter: '\u7B5B\u9009', resetFilter: '\u91CD\u7F6E', allFilter: '\u5168\u90E8', sortAsc: '\u5347\u5E8F\uFF1A\u6700\u4F4E\u5230\u6700\u9AD8', sortDesc: '\u964D\u5E8F\uFF1A\u6700\u9AD8\u5230\u6700\u4F4E', filter: '\u5BF9\u6240\u9009\u7684\u5217\u542F\u7528\u7B5B\u9009', impSuccess: '\u6210\u529F\u5BFC\u5165 {0} \u6761\u8BB0\u5F55', expLoading: '\u6B63\u5728\u5BFC\u51FA\u4E2D', expSuccess: '\u5BFC\u51FA\u6210\u529F', expFilename: '\u5BFC\u51FA_{0}', expOriginFilename: '\u5BFC\u51FA_\u6E90_{0}', customTitle: '\u5217\u8BBE\u7F6E', customAll: '\u5168\u90E8', customConfirm: '\u786E\u8BA4', customRestore: '\u91CD\u7F6E', maxFixedCol: '\u6700\u5927\u56FA\u5B9A\u5217\u7684\u6570\u91CF\u4E0D\u80FD\u8D85\u8FC7 {0} \u4E2A', }, grid: { selectOneRecord: '\u8BF7\u81F3\u5C11\u9009\u62E9\u4E00\u6761\u8BB0\u5F55\uFF01', deleteSelectRecord: '\u60A8\u786E\u5B9A\u8981\u5220\u9664\u6240\u9009\u8BB0\u5F55\u5417\uFF1F', removeSelectRecord: '\u60A8\u786E\u5B9A\u8981\u79FB\u9664\u6240\u9009\u8BB0\u5F55\u5417\uFF1F', dataUnchanged: '\u6570\u636E\u672A\u6539\u52A8\uFF01', delSuccess: '\u6210\u529F\u5220\u9664\u6240\u9009\u8BB0\u5F55\uFF01', saveSuccess: '\u4FDD\u5B58\u6210\u529F\uFF01', operError: '\u53D1\u751F\u9519\u8BEF\uFF0C\u64CD\u4F5C\u5931\u8D25\uFF01', }, select: { search: '\u641C\u7D22', loadingText: '\u52A0\u8F7D\u4E2D', emptyText: '\u6682\u65E0\u6570\u636E', }, pager: { goto: '\u524D\u5F80', pagesize: '{0}\u6761/\u9875', total: '\u5171 {0} \u6761\u8BB0\u5F55', pageClassifier: '\u9875', prevPage: '\u4E0A\u4E00\u9875', nextPage: '\u4E0B\u4E00\u9875', prevJump: '\u5411\u4E0A\u8DF3\u9875', nextJump: '\u5411\u4E0B\u8DF3\u9875', }, alert: { title: '\u6D88\u606F\u63D0\u793A', }, button: { confirm: '\u786E\u8BA4', cancel: '\u53D6\u6D88', }, import: { modes: { covering: '\u8986\u76D6', insert: '\u65B0\u589E', }, impTitle: '\u5BFC\u5165\u6570\u636E', impFile: '\u6587\u4EF6\u540D', impSelect: '\u9009\u62E9\u6587\u4EF6', impType: '\u6587\u4EF6\u7C7B\u578B', impOpts: '\u53C2\u6570\u8BBE\u7F6E', impConfirm: '\u5BFC\u5165', impCancel: '\u53D6\u6D88', }, export: { types: { csv: 'CSV (\u9017\u53F7\u5206\u9694)(*.csv)', html: '\u7F51\u9875(*.html)', xml: 'XML \u6570\u636E(*.xml)', txt: '\u6587\u672C\u6587\u4EF6(\u5236\u8868\u7B26\u5206\u9694)(*.txt)', xls: 'Excel 97-2003 \u5DE5\u4F5C\u7C3F(*.xls)', xlsx: 'Excel \u5DE5\u4F5C\u7C3F(*.xlsx)', pdf: 'PDF (*.pdf)', }, modes: { current: '\u5F53\u524D\u6570\u636E\uFF08\u5F53\u524D\u9875\u7684\u6570\u636E\uFF09', selected: '\u9009\u4E2D\u6570\u636E\uFF08\u5F53\u524D\u9875\u9009\u4E2D\u7684\u6570\u636E\uFF09', all: '\u5168\u91CF\u6570\u636E\uFF08\u5305\u62EC\u6240\u6709\u5206\u9875\u7684\u6570\u636E\uFF09', }, printTitle: '\u6253\u5370\u6570\u636E', expTitle: '\u5BFC\u51FA\u6570\u636E', expName: '\u6587\u4EF6\u540D', expNamePlaceholder: '\u8BF7\u8F93\u5165\u6587\u4EF6\u540D', expSheetName: '\u6807\u9898', expSheetNamePlaceholder: '\u8BF7\u8F93\u5165\u6807\u9898', expType: '\u4FDD\u5B58\u7C7B\u578B', expMode: '\u9009\u62E9\u6570\u636E', expCurrentColumn: '\u5168\u90E8\u5B57\u6BB5', expColumn: '\u9009\u62E9\u5B57\u6BB5', expOpts: '\u53C2\u6570\u8BBE\u7F6E', expOptHeader: '\u8868\u5934', expHeaderTitle: '\u662F\u5426\u9700\u8981\u8868\u5934', expOptFooter: '\u8868\u5C3E', expFooterTitle: '\u662F\u5426\u9700\u8981\u8868\u5C3E', expOptColgroup: '\u5206\u7EC4\u8868\u5934', expColgroupTitle: '\u5982\u679C\u5B58\u5728\uFF0C\u5219\u652F\u6301\u5E26\u6709\u5206\u7EC4\u7ED3\u6784\u7684\u8868\u5934', expOptMerge: '\u5408\u5E76', expMergeTitle: '\u5982\u679C\u5B58\u5728\uFF0C\u5219\u652F\u6301\u5E26\u6709\u5408\u5E76\u7ED3\u6784\u7684\u5355\u5143\u683C', expOptAllExpand: '\u5C55\u5F00\u5C42\u7EA7', expAllExpandTitle: '\u5982\u679C\u5B58\u5728\uFF0C\u5219\u652F\u6301\u5C06\u5E26\u6709\u5C42\u7EA7\u7ED3\u6784\u7684\u6570\u636E\u5168\u90E8\u5C55\u5F00', expOptUseStyle: '\u6837\u5F0F', expUseStyleTitle: '\u5982\u679C\u5B58\u5728\uFF0C\u5219\u652F\u6301\u5E26\u6837\u5F0F\u7684\u5355\u5143\u683C', expOptOriginal: '\u6E90\u6570\u636E', expOriginalTitle: '\u5982\u679C\u4E3A\u6E90\u6570\u636E\uFF0C\u5219\u652F\u6301\u5BFC\u5165\u5230\u8868\u683C\u4E2D', expPrint: '\u6253\u5370', expConfirm: '\u5BFC\u51FA', expCancel: '\u53D6\u6D88', }, modal: { zoomIn: '\u6700\u5927\u5316', zoomOut: '\u8FD8\u539F', close: '\u5173\u95ED', }, form: { folding: '\u6536\u8D77', unfolding: '\u5C55\u5F00', }, toolbar: { import: '\u5BFC\u5165', export: '\u5BFC\u51FA', print: '\u6253\u5370', refresh: '\u5237\u65B0', zoomIn: '\u5168\u5C4F', zoomOut: '\u8FD8\u539F', custom: '\u5217\u8BBE\u7F6E', customAll: '\u5168\u90E8', customConfirm: '\u786E\u8BA4', customRestore: '\u91CD\u7F6E', fixedLeft: '\u56FA\u5B9A\u5728\u5DE6\u4FA7', fixedRight: '\u56FA\u5B9A\u5728\u53F3\u4FA7', cancelfixed: '\u53D6\u6D88\u56FA\u5B9A', }, input: { date: { m1: '01 \u6708', m2: '02 \u6708', m3: '03 \u6708', m4: '04 \u6708', m5: '05 \u6708', m6: '06 \u6708', m7: '07 \u6708', m8: '08 \u6708', m9: '09 \u6708', m10: '10 \u6708', m11: '11 \u6708', m12: '12 \u6708', quarterLabel: '{0} \u5E74', monthLabel: '{0} \u5E74', dayLabel: '{0} \u5E74 {1}', labelFormat: { date: 'yyyy-MM-dd', time: 'HH:mm:ss', datetime: 'yyyy-MM-dd HH:mm:ss', week: 'yyyy \u5E74\u7B2C WW \u5468', month: 'yyyy-MM', quarter: 'yyyy \u5E74\u7B2C q \u5B63\u5EA6', year: 'yyyy', }, weeks: { w: '\u5468', w0: '\u5468\u65E5', w1: '\u5468\u4E00', w2: '\u5468\u4E8C', w3: '\u5468\u4E09', w4: '\u5468\u56DB', w5: '\u5468\u4E94', w6: '\u5468\u516D', }, months: { m0: '\u4E00\u6708', m1: '\u4E8C\u6708', m2: '\u4E09\u6708', m3: '\u56DB\u6708', m4: '\u4E94\u6708', m5: '\u516D\u6708', m6: '\u4E03\u6708', m7: '\u516B\u6708', m8: '\u4E5D\u6708', m9: '\u5341\u6708', m10: '\u5341\u4E00\u6708', m11: '\u5341\u4E8C\u6708', }, quarters: { q1: '\u7B2C\u4E00\u5B63\u5EA6', q2: '\u7B2C\u4E8C\u5B63\u5EA6', q3: '\u7B2C\u4E09\u5B63\u5EA6', q4: '\u7B2C\u56DB\u5B63\u5EA6', }, }, }, }, } default_1 = zhCN.default = _default var vxeTable = '' VXETable.use(VXETablePluginElement) VXETable.setup({ version: 0, zIndex: 2800, table: { autoResize: true, }, tooltipConfig: { enterable: true, }, }) VXETable.setup({ i18n: (key2, args) => xeUtils.toFormatString(xeUtils.get(default_1, key2), args), }) function useTable(app2) { app2 .use(Header$6) .use(Icon$2) .use(Column) .use(Edit) .use(Validator) .use(Table$4) .use(Tooltip) .use(Grid$4) .use(List) .use(Input$1) .use(Select$1) .use(Optgroup) .use(Option) } function listenStart() { log({ flag: '\u{1F680}', type: 'start', }) log({ flag: '\u{1F7E2}', type: 'location', href: location.href, }) } function listenWindowEvents() { const windowEventTypeList = [ 'load', 'beforeunload', 'unload', 'pageshow', 'pagehide', 'visibilitychange', 'resize', 'hashchange', 'close', 'abort', ] for (const type4 of windowEventTypeList) { addEventListener( type4, function () { log({ flag: '\u{1F7E1}', type: type4, visibilityState: document.visibilityState, href: location.href, innerWidth, innerHeight, }) }, true ) } } function listenErrorEvents() { const errorEventTypeList = ['error', 'unhandledrejection'] for (const type4 of errorEventTypeList) { addEventListener( type4, function (e2) { logError$1(type4, e2) }, true ) } } function listenKeyboardMouseEvents() { const mouseEventTypeList = [ 'keydown', 'keyup', 'mousedown', 'mouseup', 'dragstart', 'dragend', 'drop', 'touchstart', 'touchend', ] for (const type4 of mouseEventTypeList) { addEventListener( type4, function (e2) { const node2 = e2.target if (!(node2 instanceof HTMLElement)) return log({ flag: '\u26AB', type: type4, textContent: node2.textContent?.trim().slice(0, 10) || '', el: getCssSelector(node2), ...(e2 instanceof KeyboardEvent ? { key: e2.key } : null), ...(e2 instanceof MouseEvent ? { button: e2.button } : null), }) }, true ) } } function listenXMLHttpRequest() { const XMLHttpRequest2 = globalThis.XMLHttpRequest globalThis.XMLHttpRequest = class extends XMLHttpRequest2 { __info__ = {} open(...args) { this.__info__ = { method: arguments[0], url: arguments[1], xhrId: Date.now(), } return super.open(...args) } setRequestHeader(...args) { this.__info__ = { ...this.__info__, headers: { ...this.__info__.headers, [arguments[0]]: arguments[1], }, } return super.setRequestHeader(...args) } send(...args) { this.__info__ = { ...this.__info__, body: arguments[0], } log({ flag: '\u{1F535}', type: 'xhr', ...this.__info__, }) this.addEventListener( 'load', () => { let response = this.response try { response = JSON.parse(response) } catch {} log({ flag: this.status < 400 ? '\u{1F535}' : '\u{1F534}', type: 'xhr.response', status: this.status, url: this.__info__.url, statusText: this.statusText, response, headers: this.getAllResponseHeaders() .split(/\r?\n/g) .filter(Boolean), xhrId: this.__info__.xhrId, }) }, { once: true } ) this.addEventListener( 'error', (e2) => { logError$1('xhr.error', e2, { url: this.__info__.url, xhrId: this.__info__.xhrId, }) }, { once: true } ) return super.send(...args) } } } function listenFetch() { const fetch2 = globalThis.fetch globalThis.fetch = function () { const promise2 = fetch2.apply(this, arguments) const info = { method: arguments[1]?.method || 'GET', url: arguments[0], body: arguments[1]?.body, fetchId: Date.now(), } log({ flag: '\u{1F535}', type: 'fetch', ...info, }) promise2 .then(async (res) => { let response = await res.clone().text() try { response = JSON.parse(response) } catch {} log({ flag: res.status < 400 ? '\u{1F535}' : '\u{1F534}', type: 'fetch.response', status: res.status, url: info.url, statusText: res.statusText, response, headers: (function () { const map2 = {} res.headers.forEach((v4, k2) => { map2[k2] = v4 }) return map2 })(), fetchId: info.fetchId, }) }) .catch((reason) => { logError$1('fetch.error', reason, { url: info.url, reason, fetchId: info.fetchId, }) }) return promise2 } } function listenWebSocket() { const WebSocket2 = globalThis.WebSocket globalThis.WebSocket = class extends WebSocket2 { constructor(...args) { super(...args) const events2 = ['open', 'error', 'close'] for (const type4 of events2) { this.addEventListener(type4, function () { log({ flag: '\u{1F7E4}', type: 'WebSocket', event: type4, url: args[0], ...(args[1] ? { protocols: args[1] } : null), }) }) } } } } function getCssSelector(node2) { if (!node2) return '' if (node2 === document.body) return 'body' const s2 = `${node2.localName}#${node2.id || void 0}.${node2.classList[0]}` .replace(/#undefined/, '') .replace(/(\.)undefined/, '') return getCssSelector(node2.parentElement) + ' > ' + s2 } let db let dbp = new Promise((rs2) => { const dbr = indexedDB.open('log') dbr.onupgradeneeded = function () { dbr.result.createObjectStore('store', { autoIncrement: true, }) } dbr.onsuccess = () => { rs2(dbr.result) } dbr.onerror = (e2) => { console.warn(e2) rs2(void 0) } dbr.onblocked = (e2) => { console.warn(e2) rs2(void 0) } setTimeout(() => { rs2(void 0) }, 500) }).then((res) => { db = res return db }) const runId = getTimeString() const sessionId = (sessionStorage['_logSessionId_'] = sessionStorage['_logSessionId_'] || runId) function getTimeString(date4 = new Date()) { return `${date4.toLocaleString()}.${String(date4.getMilliseconds()).padStart( 3, '0' )}` } async function log(info) { const date4 = new Date() setTimeout(async () => { await dbp if (!db) return try { const item2 = { time: getTimeString(date4), ...info, runId, sessionId, } const transaction = db.transaction('store', 'readwrite') transaction.onerror = function (e2) { console.error(e2) } const store2 = transaction.objectStore('store') store2.add(item2) const max3 = 5e3 const count2 = store2.count() count2.onsuccess = function () { if (count2.result > max3) { const keys3 = store2.getAllKeys(void 0, 10) keys3.onsuccess = function () { for (const key2 of keys3.result) { store2.delete(key2) } } } } } catch (e2) { console.error(e2) } }) } function logError$1(type4, e2, info = {}) { log({ flag: '\u{1F534}', type: type4, ...(e2 instanceof ErrorEvent ? { message: e2.message } : null), ...(e2 instanceof PromiseRejectionEvent ? { message: e2.reason } : null), ...(e2 instanceof ErrorEvent ? { stack: e2.error?.stack } : null), ...info, }) } listenStart() listenWindowEvents() listenErrorEvents() listenKeyboardMouseEvents() listenXMLHttpRequest() listenFetch() listenWebSocket() var font = '' var index$n = '' var rewriteBase = '' var rewriteElement = '' var rewriteElementSelect = '' var element_overwrite = '' var iconfont = '' ;(window._iconfont_svg_string_3273823 = ''), (function (h2) { var c2 = (c2 = document.getElementsByTagName('script'))[c2.length - 1], l2 = c2.getAttribute('data-injectcss'), c2 = c2.getAttribute('data-disable-injectsvg') if (!c2) { var i2, a2, z2, o2, v4, t3 = function (c3, l3) { l3.parentNode.insertBefore(c3, l3) } if (l2 && !h2.__iconfont__svg__cssinject__) { h2.__iconfont__svg__cssinject__ = true try { document.write( '' ) } catch (c3) { console && console.log(c3) } } ;(i2 = function () { var c3, l3 = document.createElement('div') ;(l3.innerHTML = h2._iconfont_svg_string_3273823), (l3 = l3.getElementsByTagName('svg')[0]) && (l3.setAttribute('aria-hidden', 'true'), (l3.style.position = 'absolute'), (l3.style.width = 0), (l3.style.height = 0), (l3.style.overflow = 'hidden'), (l3 = l3), (c3 = document.body).firstChild ? t3(l3, c3.firstChild) : c3.appendChild(l3)) }), document.addEventListener ? ~['complete', 'loaded', 'interactive'].indexOf(document.readyState) ? setTimeout(i2, 0) : ((a2 = function () { document.removeEventListener('DOMContentLoaded', a2, false), i2() }), document.addEventListener('DOMContentLoaded', a2, false)) : document.attachEvent && ((z2 = i2), (o2 = h2.document), (v4 = false), s2(), (o2.onreadystatechange = function () { 'complete' == o2.readyState && ((o2.onreadystatechange = null), m2()) })) } function m2() { v4 || ((v4 = true), z2()) } function s2() { try { o2.documentElement.doScroll('left') } catch (c3) { return void setTimeout(s2, 50) } m2() } })(window) var waves = '' const context = '@@wavesContext' function colorRgb(color2) { var reg = /^#([0-9a-fA-f]{3}|[0-9a-fA-f]{6})$/ if (reg.test(color2)) { if (color2.length === 4) { var colorNew = '#' for (var i2 = 1; i2 < 4; i2 += 1) { colorNew += color2.slice(i2, i2 + 1).concat(color2.slice(i2, i2 + 1)) } color2 = colorNew } var colorChange2 = [] for (var n2 = 1; n2 < 7; n2 += 2) { colorChange2.push(parseInt('0x' + color2.slice(n2, n2 + 2))) } return 'RGB(' + colorChange2.join(',') + ')' } else { return color2 } } function colorChange(color2, alpha) { let rgbaVal = '' if (/^#/.test(color2)) { colorChange(colorRgb(color2), alpha) } else if (/^(rgba|RGBA)/.test(color2)) { rgbaVal = color2.substring(5, color2.lastIndexOf(',')) } else if (/^(rgb|RGB)/.test(color2)) { rgbaVal = color2.substring(4, color2.length - 1) } return `rgba(${rgbaVal},${alpha})` } function handleClick(el2, binding) { function handle(e2) { const customOpts = Object.assign({}, binding.value) const opts = Object.assign( { ele: el2, type: 'hit', color: colorChange(window.getComputedStyle(el2).color, 0.3), }, customOpts ) const target2 = opts.ele if (target2) { target2.style.position = 'relative' target2.style.overflow = 'hidden' const rect = target2.getBoundingClientRect() let ripple = target2.querySelector('.waves-ripple') if (!ripple) { ripple = document.createElement('span') ripple.className = 'waves-ripple' ripple.style.height = ripple.style.width = Math.max(rect.width, rect.height) + 'px' target2.appendChild(ripple) } else { ripple.className = 'waves-ripple' } switch (opts.type) { case 'center': ripple.style.top = rect.height / 2 - ripple.offsetHeight / 2 + 'px' ripple.style.left = rect.width / 2 - ripple.offsetWidth / 2 + 'px' break default: ripple.style.top = (e2.pageY - rect.top - ripple.offsetHeight / 2 - document.documentElement.scrollTop || document.body.scrollTop) + 'px' ripple.style.left = (e2.pageX - rect.left - ripple.offsetWidth / 2 - document.documentElement.scrollLeft || document.body.scrollLeft) + 'px' } ripple.style.backgroundColor = opts.color ripple.className = 'waves-ripple z-active' if (!el2[context]) { el2[context] = { removeHandle: handle, } } else { el2[context].removeHandle = handle } return false } } return handle } var directives = (app2) => { app2.directive('waves', { mounted(el2, binding) { el2.addEventListener('click', handleClick(el2, binding), false) }, unmounted(el2, binding) { el2?.removeEventListener('click', handleClick(el2, binding), false) }, }) } var track = (app2) => { let uploadServerTimer const uploadTimeout = 1e3 * 60 * 10 let cleanup = () => {} app2.directive('track', { mounted(el2, binding) { let { arg, value: value2 } = binding el2.setAttribute('mountedTimeStamp', new Date().getTime()) if (arg === 'page') { userBehaviorAnalysis({ ...value2, action: 'Enter' }) } cleanup = useEventListener(window, 'unload', async () => { let durationSpan = (new Date().getTime() - el2.getAttribute('mountedTimeStamp')) / 1e3 await userBehaviorAnalysis({ ...value2, durationSpan, action: 'Leave', }) }) function startUploadServerTimer() { uploadServerTimer = setTimeout(async () => { let durationSpan = (new Date().getTime() - el2.getAttribute('mountedTimeStamp')) / 1e3 el2.setAttribute('mountedTimeStamp', new Date().getTime()) await userBehaviorAnalysis({ ...value2, durationSpan, action: 'Leave', }) startUploadServerTimer() }, uploadTimeout) } startUploadServerTimer() }, unmounted(el2, binding) { clearTimeout(uploadServerTimer) cleanup() let { arg, value: value2 } = binding let durationSpan = 0 if (arg === 'page') { durationSpan = (new Date().getTime() - el2.getAttribute('mountedTimeStamp')) / 1e3 userBehaviorAnalysis({ ...value2, durationSpan, action: 'Leave', }) } }, updated(el2, binding) { let { arg, value: value2, oldValue } = binding if (arg === 'page') { if (lodash.isEqual(oldValue, value2)) return let durationSpan = 0 if (arg === 'page') { durationSpan = (new Date().getTime() - el2.getAttribute('mountedTimeStamp')) / 1e3 userBehaviorAnalysis({ ...oldValue, durationSpan, action: 'Leave', }) el2.setAttribute('mountedTimeStamp', new Date().getTime()) userBehaviorAnalysis({ ...value2, action: 'Enter' }) } } }, }) } function isClickOutsideElement(targetElement, outsideElementSelector) { return ( targetElement.classList.contains(outsideElementSelector) || targetElement.closest(outsideElementSelector) ) } const draggable = { mounted: function (el2, binding) { el2.style.position = 'absolute' let disX let disY const handleMouseDown = function (e2) { if (isClickOutsideElement(e2.target, binding.value.exclude)) return disX = e2.pageX - el2.offsetLeft disY = e2.pageY - el2.offsetTop document.body.style.userSelect = 'none' document.addEventListener('mousemove', handleMouseMove) document.addEventListener('mouseup', handleMouseUp) } const handleMouseMove = function (e2) { let x2 = e2.pageX - disX let y2 = e2.pageY - disY const maxX = parseInt(window.getComputedStyle(el2.parentNode).width) - parseInt(window.getComputedStyle(el2).width) const maxY = parseInt(window.getComputedStyle(el2.parentNode).height) - parseInt(window.getComputedStyle(el2).height) if (x2 < 0) { x2 = 0 } else if (x2 > maxX) { x2 = maxX } if (y2 < 0) { y2 = 0 } else if (y2 > maxY) { y2 = maxY } el2.style.left = x2 + 'px' el2.style.top = y2 + 'px' } const handleMouseUp = function () { document.removeEventListener('mousemove', handleMouseMove) document.removeEventListener('mouseup', handleMouseUp) document.body.style.userSelect = '' } el2.addEventListener('mousedown', handleMouseDown) el2.handleMouseDown = handleMouseDown }, beforeUnmount: function (el2) { const handleMouseDown = el2.handleMouseDown el2.removeEventListener('mousedown', handleMouseDown) el2.removeEventListener('mousedown', el2.handleMouseDown) }, } var draggable$1 = (app2) => { app2.directive('draggable', draggable) } function addMouseHover() { let timer2 = null let isExecute = false addEventListener( 'mouseover', (e2) => { if (!isExecute) { timer2 = setTimeout(() => { isExecute = true e2.target?.dispatchEvent(new MouseEvent('hover', { bubbles: true })) }, 1e3) } }, true ) addEventListener( 'mouseout', () => { clearTimeout(timer2) isExecute = false }, true ) } function addMouseLongPress() { let timer2 = null let isExecute = false addEventListener( 'mousedown', (e2) => { if (!isExecute) { timer2 = setTimeout(() => { isExecute = true e2.target?.dispatchEvent( new CustomEvent('mouselongpress', { bubbles: true }) ) }, 1e3) } }, true ) addEventListener( 'mouseup', () => { clearTimeout(timer2) isExecute = false }, true ) } function createGlobalEvent() { addMouseHover() addMouseLongPress() } const state$5 = reactive({ init: true, SettingItemModel: '', accordion: false, }) var SettingItem_vue_vue_type_style_index_0_scoped_true_lang = '' const _hoisted_1$5_ = { class: 'setting-item' } const _hoisted_2$4X = /* @__PURE__ */ createTextVNode('settingItemCollapse') const _hoisted_3$4u = /* @__PURE__ */ createTextVNode('settingItem') const _sfc_main$73 = /* @__PURE__ */ defineComponent({ props: { title: { default: '', }, fold: { type: Boolean, default: false, }, }, setup(__props2) { const props2 = __props2 const initSelect = () => { if (state$5.accordion) { if (props2.title && !state$5.SettingItemModel) { state$5.SettingItemModel = props2.title } } else { if (props2.title && !props2.fold) { if (Array.isArray(state$5.SettingItemModel)) { state$5.SettingItemModel.push(props2.title) } else { state$5.SettingItemModel = [props2.title] } } } } watch$1( () => state$5.init, (val2) => { if (val2) { initSelect() setTimeout(() => { state$5.init = false }) } }, { immediate: true, } ) return (_ctx, _cache) => { const _component_el_collapse_item = resolveComponent('el-collapse-item') const _component_el_collapse = resolveComponent('el-collapse') return ( openBlock(), createElementBlock('div', _hoisted_1$5_, [ props2.title ? (openBlock(), createBlock( _component_el_collapse, { key: 0, modelValue: unref(state$5).SettingItemModel, 'onUpdate:modelValue': _cache[0] || (_cache[0] = ($event) => (unref(state$5).SettingItemModel = $event)), accordion: unref(state$5).accordion, }, { default: withCtx(() => [ createVNode$1( _component_el_collapse_item, { title: props2.title, name: props2.title, }, { title: withCtx(() => [ renderSlot(_ctx.$slots, 'title', {}, void 0, true), ]), default: withCtx(() => [ renderSlot( _ctx.$slots, 'default', {}, () => [_hoisted_2$4X], true ), ]), _: 3, }, 8, ['title', 'name'] ), ]), _: 3, }, 8, ['modelValue', 'accordion'] )) : renderSlot( _ctx.$slots, 'default', { key: 1 }, () => [_hoisted_3$4u], true ), ]) ) } }, }) var SettingItem$1 = /* @__PURE__ */ _export_sfc(_sfc_main$73, [ ['__scopeId', 'data-v-777a3fcb'], ]) var SettingItem$2 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: SettingItem$1, }, Symbol.toStringTag, { value: 'Module' } ) ) const __default__$2 = defineComponent({ name: 'SettingItem', }) const _sfc_main$72 = /* @__PURE__ */ defineComponent({ ...__default__$2, setup(__props2) { return (_ctx, _cache) => { return ( openBlock(), createBlock(SettingItem$1, null, { default: withCtx(() => [renderSlot(_ctx.$slots, 'default')]), _: 3, }) ) } }, }) var SettingItem = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: _sfc_main$72, }, Symbol.toStringTag, { value: 'Module' } ) ) var Filter_vue_vue_type_style_index_0_scoped_true_lang$1 = '' var Filter_vue_vue_type_style_index_1_lang = '' const _hoisted_1$5Z = { class: 'title' } const _sfc_main$71 = /* @__PURE__ */ defineComponent({ props: { filterData: null, styleB: { type: Boolean }, size: null, noLanguage: { type: Boolean }, }, emits: ['search', 'clear'], setup(__props2, { emit: emit2 }) { const $props2 = __props2 const selectPopoverClass = computed(() => { if (app.running) { return 'cms-el-select__popper cms-el-select__popper--light' } else { return 'cms-el-select__popper' } }) const usedTypes = [ { value: 0, label: '\u6240\u6709\u53D8\u91CF', }, { value: 1, label: '\u5DF2\u4F7F\u7528\u53D8\u91CF', }, { value: 2, label: '\u672A\u4F7F\u7528\u53D8\u91CF', }, ] let filterData = ref($props2.filterData) filterData.value ??= { dataTypes: [], usedType: 0, keyword: '', } const search2 = () => emit2('search') const clear2 = () => emit2('clear') const input = useDebounceFn(() => { search2() }, 500) return (_ctx, _cache) => { const _component_el_checkbox = resolveComponent('el-checkbox') const _component_el_checkbox_group = resolveComponent('el-checkbox-group') const _component_el_option = resolveComponent('el-option') const _component_el_select = resolveComponent('el-select') const _component_el_input = resolveComponent('el-input') return ( openBlock(), createElementBlock( 'div', { class: normalizeClass([ 'varsFilter', { styleB: $props2?.styleB, small: $props2?.size == 'small' }, ]), }, [ createElementVNode( 'span', _hoisted_1$5Z, toDisplayString$1( unref(Language$1).toLanguage( '\u7B5B\u9009', $props2?.noLanguage ) ) + '\uFF1A', 1 ), createVNode$1( _component_el_checkbox_group, { class: 'search-filter', modelValue: filterData.value.dataTypes, 'onUpdate:modelValue': _cache[0] || (_cache[0] = ($event) => (filterData.value.dataTypes = $event)), onChange: search2, }, { default: withCtx(() => [ (openBlock(true), createElementBlock( Fragment, null, renderList(unref(Variable).typeClassifyMap, (v4, k2) => { return ( openBlock(), createBlock( _component_el_checkbox, { key: k2, label: v4.value, }, { default: withCtx(() => [ createTextVNode( toDisplayString$1( unref(Language$1).toLanguage( k2, $props2?.noLanguage ) ), 1 ), ]), _: 2, }, 1032, ['label'] ) ) }), 128 )), ]), _: 1, }, 8, ['modelValue'] ), createVNode$1( _component_el_select, { class: 'cms-el-select search-select', 'popper-class': selectPopoverClass.value, modelValue: filterData.value.usedType, 'onUpdate:modelValue': _cache[1] || (_cache[1] = ($event) => (filterData.value.usedType = $event)), onChange: search2, }, { default: withCtx(() => [ (openBlock(), createElementBlock( Fragment, null, renderList(usedTypes, (item2) => { return createVNode$1( _component_el_option, { key: item2.value, value: item2.value, label: unref(Language$1).toLanguage( item2.label, $props2?.noLanguage ), }, null, 8, ['value', 'label'] ) }), 64 )), ]), _: 1, }, 8, ['popper-class', 'modelValue'] ), createVNode$1( _component_el_input, { class: 'cms-el-input search-input', placeholder: unref(Language$1).toLanguage( '\u8BF7\u8F93\u5165\u5173\u952E\u8BCD', $props2?.noLanguage ), modelValue: filterData.value.keyword, 'onUpdate:modelValue': _cache[2] || (_cache[2] = ($event) => (filterData.value.keyword = $event)), modelModifiers: { lazy: true }, onInput: unref(input), clearable: '', }, null, 8, ['placeholder', 'modelValue', 'onInput'] ), createElementVNode( 'button', { class: normalizeClass([ 'cms-btn', $props2?.styleB ? 'btn-data-plain primary' : 'btn-screen-btn btn-reset', ]), onClick: clear2, }, toDisplayString$1( unref(Language$1).toLanguage( '\u6E05\u9664', $props2?.noLanguage ) ), 3 ), ], 2 ) ) } }, }) var Filter$2 = /* @__PURE__ */ _export_sfc(_sfc_main$71, [ ['__scopeId', 'data-v-1ffde41e'], ]) var Filter$3 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: Filter$2, }, Symbol.toStringTag, { value: 'Module' } ) ) class Node$1 { nodeKey = 'id' key = new Date().getTime() + '' data = {} level = 1 expanded = true visible = true get id() { return this.data[this.nodeKey] } get label() { return this.data.name } props = { children: 'children', } get children() { return this.data[this.props.children] || [] } get isLeaf() { return this.children.length === 0 } parent constructor(object4) { Object.assign(this, object4) if (!this[this.nodeKey]) { this[this.nodeKey] = this.data[this.nodeKey] } } toggleExpand() { this.expanded = !this.expanded } isOffspring(targetNodeId) { const loop = (childList) => { for (const child of childList) { if (child.id === targetNodeId) { return true } const rs2 = loop(child.children) if (rs2) { return rs2 } } } return loop(this.children) } } var TreeNode_vue_vue_type_style_index_0_scoped_true_lang = '' const _hoisted_1$5Y = ['draggable', 'onDragend'] const _hoisted_2$4W = ['onClick'] const _hoisted_3$4t = { class: 'custom-tree-node' } const _hoisted_4$3V = { class: 'tree-node-icon' } const _hoisted_5$3w = { class: 'tree-node-label' } const _sfc_main$70 = /* @__PURE__ */ defineComponent({ props: { node: null, data: null, nodeKey: null, indent: null, currentNode: null, draggable: { type: Boolean }, props: null, refLine: null, allowDrop: null, virtualTreeRef: null, OMTList: null, itemSize: null, expandOnClickNode: { type: Boolean }, selectNodes: null, }, emits: [ 'toggleExpand', 'nodeClick', 'nodeDragStart', 'nodeDrop', 'nodeSelect', ], setup(__props2, { emit: emit2 }) { const $props2 = __props2 const data2 = ref($props2.data) const node2 = ref($props2.node) const props2 = ref($props2.props) const refLine = ref($props2.refLine) const OMTList = ref($props2.OMTList) let nodeRef = ref() let expandRef = ref() function toggleExpand() { node2.value.toggleExpand() emit2('toggleExpand', data2.value[$props2.nodeKey]) } function NodeClick(event) { emit2('nodeSelect', node2.value, data2.value, event.ctrlKey) emit2('nodeClick', node2.value, data2.value) if ($props2.expandOnClickNode) { toggleExpand() } } function handleDragStart(event) { refLine.value.draggingNode = node2.value event.dataTransfer && (event.dataTransfer.effectAllowed = 'move') emit2('nodeDragStart', node2.value) } function handleDragOver(event) { event.preventDefault() let nodeKey = $props2.nodeKey let isOff = refLine.value.draggingNode.isOffspring(node2.value[nodeKey]) if ( (refLine.value.draggingNode && node2.value[nodeKey] === refLine.value.draggingNode[nodeKey]) || (refLine.value.draggingNode && isOff) ) { refLine.value.dropType = 'none' return } let dropPrev = true, dropInner = true, dropNext = true if (typeof $props2.allowDrop === 'function') { dropPrev = $props2.allowDrop( refLine.value.draggingNode, node2.value, 'before' ) dropInner = $props2.allowDrop( refLine.value.draggingNode, node2.value, 'inner' ) dropNext = $props2.allowDrop( refLine.value.draggingNode, node2.value, 'after' ) } event.dataTransfer && (event.dataTransfer.dropEffect = dropPrev || dropInner || dropNext ? 'move' : 'none') if (dropPrev || dropInner || dropNext) { refLine.value.targetNode = node2.value } if ( refLine.value.targetNode === null || refLine.value.draggingNode === null ) return let indicatorTop = 0, drop_config = refLine.value.draggingNode, nodeIndex = ( refLine.value.draggingNode.parent?.[props2.value.children] ?? OMTList.value ).findIndex((item2) => item2[nodeKey] === node2.value[nodeKey]), targetIndex = ( refLine.value.targetNode.parent?.[props2.value.children] ?? OMTList.value ).findIndex( (item2) => item2[nodeKey] === refLine.value.targetNode[nodeKey] ) if ( targetIndex + 1 === nodeIndex && node2.value.parent === drop_config.parent ) { dropNext = false } if (node2.value.expanded && !node2.value.isLeaf) { dropNext = false } if ( targetIndex - 1 === nodeIndex && node2.value.parent === drop_config.parent ) { dropPrev = false } if (drop_config[nodeKey] === refLine.value.targetNode.parent?.[nodeKey]) { dropInner = false } const treePosition = $props2.virtualTreeRef.getBoundingClientRect() const targetPosition = nodeRef.value?.getBoundingClientRect() const iconPosition = expandRef.value?.getBoundingClientRect() const position2 = event.clientY - (targetPosition?.top || 0) const prevPercent = dropPrev ? dropInner ? 0.25 : dropNext ? 0.45 : 1 : -1 const nextPercent = dropNext ? dropInner ? 0.75 : dropPrev ? 0.55 : 0 : 1 if ( position2 < (targetPosition?.height || $props2.itemSize) * prevPercent ) { refLine.value.dropType = 'before' indicatorTop = (iconPosition?.top || 0) - treePosition.top } else if ( position2 > (targetPosition?.height || $props2.itemSize) * nextPercent ) { refLine.value.dropType = 'after' indicatorTop = (iconPosition?.bottom || 0) - treePosition.top } else if (dropInner) { refLine.value.dropType = 'inner' } else { refLine.value.dropType = 'none' } refLine.value.left = (iconPosition?.right || 0) - treePosition.left refLine.value.top = indicatorTop } function handleDragEnd2() { let { dropType, targetNode, draggingNode } = refLine.value if (dropType === 'none' || !targetNode || !draggingNode) return let nodeKey = $props2.nodeKey let parentList = targetNode.parent?.[props2.value.children] ?? OMTList.value let targetNodeIndex = parentList.findIndex( (item2) => item2[nodeKey] === targetNode[nodeKey] ) let dragParentList = draggingNode.parent?.[props2.value.children] ?? OMTList.value let dragNodeIndex = dragParentList.findIndex( (item2) => item2[nodeKey] === draggingNode[nodeKey] ) dragParentList.splice(dragNodeIndex, 1) let index2 = (draggingNode.parent?.[nodeKey] === targetNode.parent?.[nodeKey] && dragNodeIndex > targetNodeIndex) || draggingNode.parent?.[nodeKey] !== targetNode.parent?.[nodeKey] ? targetNodeIndex + 1 : targetNodeIndex if (dropType === 'before') { parentList.splice(index2 - 1, 0, draggingNode.data) } else if (dropType === 'after') { parentList.splice(index2, 0, draggingNode.data) } else if (dropType === 'inner') { if (!targetNode.data[props2.value.children]) { targetNode.data[props2.value.children] = [] } targetNode.data[props2.value.children].unshift(draggingNode.data) } emit2('nodeDrop', draggingNode, targetNode, dropType) refLine.value.dropType = 'none' } function handleDrop(event) { event.preventDefault() } return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { ref_key: 'nodeRef', ref: nodeRef, class: normalizeClass([ 'tree-node-content', { 'is-select': __props2.selectNodes.includes(node2.value), 'is-current': __props2.currentNode?.[__props2.nodeKey] === node2.value[__props2.nodeKey], 'is-inner-drop': refLine.value.dropType === 'inner' && refLine.value.targetNode && refLine.value.targetNode[__props2.nodeKey] === node2.value[__props2.nodeKey], }, ]), style: normalizeStyle$1({ 'padding-left': (node2.value.level - 1) * __props2.indent + 'px', height: $props2.itemSize + 'px', }), draggable: __props2.draggable, onClick: NodeClick, onDragstart: _cache[0] || (_cache[0] = withModifiers( ($event) => handleDragStart($event), ['stop'] )), onDragover: _cache[1] || (_cache[1] = withModifiers( ($event) => handleDragOver($event), ['stop'] )), onDragend: withModifiers(handleDragEnd2, ['stop']), onDrop: handleDrop, }, [ createElementVNode( 'i', { ref_key: 'expandRef', ref: expandRef, class: normalizeClass([ 'tree-node__expand-icon', { expanded: !node2.value.expanded, 'icon-xiala2': !node2.value.isLeaf, }, ]), onClick: withModifiers(toggleExpand, ['stop']), }, null, 10, _hoisted_2$4W ), createElementVNode('div', _hoisted_3$4t, [ renderSlot( _ctx.$slots, 'default', { data: data2.value, node: node2.value, }, () => [ createElementVNode('div', _hoisted_4$3V, [ createElementVNode( 'i', { class: normalizeClass([ 'iconfont', data2.value[$props2.props.children].length == 0 ? 'icon-yemian' : 'icon-wenjianjia', ]), }, null, 2 ), ]), createElementVNode( 'div', _hoisted_5$3w, toDisplayString$1(node2.value.label), 1 ), ], true ), ]), ], 46, _hoisted_1$5Y ) ) } }, }) var TreeNode$1 = /* @__PURE__ */ _export_sfc(_sfc_main$70, [ ['__scopeId', 'data-v-8d5a7524'], ]) var TreeNode$2 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: TreeNode$1, }, Symbol.toStringTag, { value: 'Module' } ) ) var VirtualTree_vue_vue_type_style_index_0_scoped_true_lang = '' const _hoisted_1$5X = { key: 0, class: 'tree__empty-block', } const _hoisted_2$4V = { class: 'tree__empty-text' } const _sfc_main$6$ = /* @__PURE__ */ defineComponent({ props: { data: { default: () => [] }, nodeKey: { default: 'id' }, props: { default: () => { return { label: 'name', children: 'children', } }, }, emptyText: { default: '\u6682\u65E0\u6570\u636E' }, defaultExpandAll: { type: Boolean, default: true }, defaultExpandedKeys: { default: () => [] }, currentNodeKey: null, draggable: { type: Boolean, default: true }, indent: { default: 18 }, filterText: { default: '' }, expandOnClickNode: { type: Boolean, default: false }, allowDrop: { type: Function, default: () => true }, itemSize: { default: 28 }, multiple: { type: Boolean, default: false }, parentNodeKey: null, }, emits: [ 'nodeClick', 'nodeDragStart', 'nodeDrop', 'toggleExpand', 'select', 'scroll', ], setup(__props2, { expose, emit: emit2 }) { const $props2 = __props2 let modelValueCopy = ref($props2.data) let defaultExpandAll = ref($props2.defaultExpandAll) let props2 = ref($props2.props) let reDrawKey = ref('') let itemSize2 = ref($props2.itemSize) let startIndex = ref(0) let visibleCount = ref(20) let startOffset = ref(0) let phantomHeight = ref(100) let expandedKeys = ref( /* @__PURE__ */ new Set([...$props2.defaultExpandedKeys]) ) let nodeMapList = {} onMounted(() => { setVisibleCount() }) function findIsVisible(node2) { let isVisible2 = false if (node2.name.includes($props2.filterText)) return true const getVisible = (node22) => { if (!node22) return for (const item2 of node22) { if (item2.name.includes($props2.filterText)) { isVisible2 = true return } getVisible(item2[props2.value.children]) } } getVisible(node2[props2.value.children]) return isVisible2 } function getViewData( dataList2, filterText = '', expandAll = defaultExpandAll.value ) { let children = props2.value.children let nodeKey = $props2.nodeKey let viewData = [] let visibleIdx = 0 const recursionModelValue = ( dataList22, level = 1, parentNode2 = dataList22 ) => { for (const item2 of dataList22) { if (visibleCount.value <= viewData.length) { return } if (!nodeMapList[item2[nodeKey]]) { let node22 = { nodeKey, id: item2[nodeKey], node: new Node$1({ parent: parentNode2, level, ...$props2, data: item2, expanded: expandAll || expandedKeys.value.has(item2[nodeKey]), }), } nodeMapList[item2[nodeKey]] = node22 } let node2 = nodeMapList[item2[nodeKey]].node node2.level = level node2.parent = parentNode2 node2.data = item2 node2.visible = findIsVisible(item2) if (node2.visible) { visibleIdx++ if (visibleIdx >= startIndex.value) { viewData.push(nodeMapList[item2[nodeKey]]) } } if (item2[children]?.length > 0 && node2.visible && node2.expanded) { recursionModelValue(item2[children], level + 1, item2) } } } recursionModelValue(dataList2) defaultExpandAll.value = false getPhantomHeight() modelValueCopy.value = dataList2 return viewData } function getPhantomHeight() { let len2 = 0 let children = props2.value.children const getLength = (dataList2) => { len2 += dataList2.filter((item2) => findIsVisible(item2)).length dataList2.forEach((item2) => { let node2 = nodeMapList[item2[$props2.nodeKey]]?.node if ( item2[children]?.length > 0 && findIsVisible(item2) && (node2?.expanded ?? true) ) { getLength(item2[children]) } }) } getLength(modelValueCopy.value) phantomHeight.value = len2 * itemSize2.value + itemSize2.value startOffset.value = startOffset.value > phantomHeight.value ? 0 : startOffset.value } let virtualTreeRef = ref() let virtualTreeListRef = ref() const getStartIndex = (scrollTop) => { return Math.floor(scrollTop / itemSize2.value) } const getStartOffset = (startIndex2) => { return startIndex2 * itemSize2.value } function handleScroll2() { let scrollTop = virtualTreeRef.value.scrollTop startIndex.value = getStartIndex(scrollTop) startOffset.value = getStartOffset(startIndex.value) emit2('scroll') } const toggleExpand = (id2) => { expandedKeys.value.has(id2) ? expandedKeys.value.delete(id2) : expandedKeys.value.add(id2) update3() emit2('toggleExpand', expandedKeys.value) } let refLine = reactive({ top: 0, left: 0, dropType: 'none', draggingNode: null, targetNode: null, prevNode: null, }) const nodeDragStart = (node2) => { emit2('nodeDragStart', node2) } const handleDragEnd2 = (draggingNode, targetNode, dropType) => { emit2('nodeDrop', draggingNode, targetNode, dropType) } function update3() { reDrawKey.value = new Date() } let currentNode = ref(null) let selectNodes = ref([]) function nodeClick(node2, data2) { currentNode.value = node2 emit2('nodeClick', node2, data2) } function nodeSelect(node2, data2, ctrlKey) { if (ctrlKey && $props2.multiple) { const index2 = selectNodes.value.findIndex( (nodeItem) => nodeItem === node2 ) if (index2 === -1) { selectNodes.value.push(node2) } else { selectNodes.value.splice(index2, 1) } } else { selectNodes.value = [node2] } const datas = selectNodes.value.map((node22) => node22.data) emit2('select', datas, selectNodes.value) } function filter2(val2) { getViewData(modelValueCopy.value, val2, defaultExpandAll.value) } function setCurrentKey(key2) { const node2 = getNodeById2(key2) if (node2) { currentNode.value = node2 selectNodes.value = [node2] emit2('select', selectNodes.value) return true } return false } function clearSelectNodes() { selectNodes.value.length = 0 emit2('select', selectNodes.value) } function getCurrentNode() { return currentNode.value } function getNodeById2(id2) { return nodeMapList[id2]?.node } function setVisibleCount() { visibleCount.value = Math.ceil(virtualTreeRef.value.clientHeight / itemSize2.value) + 5 } const _setVisibleCount = lodash$2.exports.debounce(setVisibleCount, 200, { leading: true, }) useResizeObserver(virtualTreeRef, _setVisibleCount) function createNode2(dataItem) { let nodeKey = $props2.nodeKey if (!nodeMapList[dataItem[nodeKey]]) { let node2 = { nodeKey, id: dataItem[nodeKey], node: new Node$1({ parent: null, level: 1, ...$props2, data: dataItem, expanded: true, }), } nodeMapList[dataItem[nodeKey]] = node2 } return nodeMapList[dataItem[nodeKey]].node } function parentExpand(node2) { const parent2 = node2.parent if (!parent2) return if (!(parent2 instanceof Array)) { const parentId = parent2.id let parentNode2 = getNodeById2(parentId) if (!parentNode2) return parentNode2.expanded = true if (!expandedKeys.value.has(parentId)) { expandedKeys.value.add(parentId) } parentExpand(parentNode2) } } function getTargetPosition(id2) { let index2 = 0 let children = props2.value.children let hasFound = false function findIndexFromVisibleNodes(dataList2, id22) { for (const dataItem of dataList2) { if (findIsVisible(dataItem) && !hasFound) { index2++ } if (id22 === dataItem.id) { hasFound = true return index2 } let node2 = nodeMapList[dataItem[$props2.nodeKey]]?.node if ( dataItem[children]?.length > 0 && findIsVisible(dataItem) && (node2?.expanded ?? true) ) { findIndexFromVisibleNodes(dataItem[children], id22) } } return index2 } const targetIndex = findIndexFromVisibleNodes($props2.data, id2) return (targetIndex + 1) * $props2.itemSize } function findParents(dataItem) { if (!$props2.parentNodeKey) return [] let result = [] let parent2 = dataItem while (parent2) { parent2 = parent2[$props2.parentNodeKey] if (parent2) { result.unshift(parent2) } } if (result[0] && !$props2.data.includes(result[0])) { result.shift() } return result } function scrollTo(dataItem) { if (!$props2.parentNodeKey) return const id2 = dataItem[$props2.nodeKey] let node2 = getNodeById2(id2) if (node2) { parentExpand(node2) } else { const parents = findParents(dataItem) for (const parentDataItem of parents) { const parentNode2 = createNode2(parentDataItem) parentNode2.expanded = true const parentId = parentNode2.id if (!expandedKeys.value.has(parentId)) { expandedKeys.value.add(parentId) } } } const position2 = getTargetPosition(id2) const targetScrollTop = Math.max( position2 - virtualTreeRef.value.offsetHeight, 0 ) virtualTreeRef.value.scrollTop = targetScrollTop update3() emit2('toggleExpand', expandedKeys.value) } expose({ update: update3, filter: filter2, getCurrentNode, getNodeById: getNodeById2, setCurrentKey, clearSelectNodes, scrollTo, }) return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { class: 'virtual-tree', ref_key: 'virtualTreeRef', ref: virtualTreeRef, onScroll: handleScroll2, }, [ createElementVNode( 'div', { class: 'list-phantom', style: normalizeStyle$1({ height: phantomHeight.value + 'px' }), }, null, 4 ), (openBlock(), createElementBlock( 'div', { class: 'virtual-tree-list', key: reDrawKey.value, ref_key: 'virtualTreeListRef', ref: virtualTreeListRef, style: normalizeStyle$1({ transform: `translate3d(0, ${startOffset.value}px, 0)`, }), }, [ __props2.data.length === 0 ? (openBlock(), createElementBlock('div', _hoisted_1$5X, [ createElementVNode( 'span', _hoisted_2$4V, toDisplayString$1(__props2.emptyText), 1 ), ])) : createCommentVNode('', true), (openBlock(true), createElementBlock( Fragment, null, renderList( getViewData( __props2.data, __props2.filterText, $props2.defaultExpandAll ), (item2) => { return ( openBlock(), createBlock( TreeNode$1, { node: item2.node, key: item2.id, data: item2.node.data, draggable: __props2.draggable, nodeKey: __props2.nodeKey, props: props2.value, itemSize: itemSize2.value, indent: __props2.indent, currentNode: currentNode.value, expandOnClickNode: __props2.expandOnClickNode, allowDrop: __props2.allowDrop, virtualTreeRef: unref(virtualTreeListRef), OMTList: __props2.data, selectNodes: selectNodes.value, onToggleExpand: toggleExpand, onNodeClick: nodeClick, refLine: unref(refLine), onNodeDragStart: nodeDragStart, onNodeDrop: handleDragEnd2, onNodeSelect: nodeSelect, }, { default: withCtx(() => [ renderSlot( _ctx.$slots, 'default', { node: item2.node, data: item2.node.data, }, void 0, true ), ]), _: 2, }, 1032, [ 'node', 'data', 'draggable', 'nodeKey', 'props', 'itemSize', 'indent', 'currentNode', 'expandOnClickNode', 'allowDrop', 'virtualTreeRef', 'OMTList', 'selectNodes', 'refLine', ] ) ) } ), 128 )), withDirectives( createElementVNode( 'div', { class: 'tree__drop-indicator', style: normalizeStyle$1({ left: unref(refLine).left + 'px', top: unref(refLine).top + 'px', }), }, null, 4 ), [ [ vShow, ['before', 'after'].includes(unref(refLine).dropType), ], ] ), ], 4 )), ], 544 ) ) } }, }) var VirtualTree = /* @__PURE__ */ _export_sfc(_sfc_main$6$, [ ['__scopeId', 'data-v-7955664c'], ]) var VirtualTree$1 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: VirtualTree, }, Symbol.toStringTag, { value: 'Module' } ) ) let state$4 = reactive({ activeNode: null, activeNodeTunnel: null, protocolInfos: null, protocolInfo: null, dataTypes: [], debugging: false, saveAction: 0, filterData: { dataTypes: [], usedType: 0, keyword: '', }, tableData: [], totalList: [], unSaveList: [], unSaveListStorageKeys: [], checkedList: [], groupList: [], }) const validFailRowClass = 'valid-fail-row' const validFailCellClass = 'valid-fail-cell' const validRules = ref({ testField: [ { required: true, message: '\u53D8\u91CF\u540D\u5FC5\u987B\u586B\u5199' }, { pattern: /^[0-9]{0,3}$/, message: '\u53D8\u91CF\u540D\u683C\u5F0F\u9519\u8BEF\uFF0C\u8BF7\u8F93\u5165\u4E2D\u6587\u3001\u5B57\u6BCD\u3001\u6570\u5B57\u3001\u4E0B\u5212\u7EBF\u4E2D\u7684\u4E00\u79CD\u6216\u591A\u79CD\uFF0C\u4E14\u4E0D\u80FD\u4EE5\u6570\u5B57\u5F00\u5934', }, { customValidator({ value: value2 }) { if (value2 && !['Develop', 'Test', 'Designer', 'PM'].includes(value2)) { return '\u8F93\u5165\u4E0D\u6B63\u786E' } }, }, ], name: [ { required: true, message: '\u53D8\u91CF\u540D\u5FC5\u987B\u586B\u5199' }, { customValidator({ value: value2 }) { if (!Variable.isVarName(value2)) { return '\u53D8\u91CF\u540D\u683C\u5F0F\u9519\u8BEF\uFF0C\u8BF7\u8F93\u5165\u4E2D\u6587\u3001\u5B57\u6BCD\u3001\u6570\u5B57\u3001\u4E0B\u5212\u7EBF\u4E2D\u7684\u4E00\u79CD\u6216\u591A\u79CD\uFF0C\u4E14\u4E0D\u80FD\u4EE5\u6570\u5B57\u5F00\u5934' } }, }, ], interval: [ { required: true, message: '\u91C7\u96C6\u95F4\u9694\u5FC5\u987B\u586B\u5199', }, { customValidator({ value: value2 }) { if (value2 < 10) { return '\u91C7\u96C6\u95F4\u9694\u4E0D\u53EF\u5C0F\u4E8E10ms' } if (value2 > 1e4) { return '\u91C7\u96C6\u95F4\u9694\u4E0D\u53EF\u5927\u4E8E10000ms' } }, }, ], address: [ { required: true, message: '\u53D8\u91CF\u5730\u5740\u5FC5\u987B\u586B\u5199', }, { customValidator({ value: value2 }) { const rule2 = state$4.protocolInfo?.protocalAddressRule if (rule2) { const reg = new RegExp(rule2) if (!reg.test(value2)) { return '\u53D8\u91CF\u5730\u5740\u4E0D\u6B63\u786E\uFF0C\u8BF7\u91CD\u65B0\u8F93\u5165' } } }, }, ], stringLength: [ { customValidator({ value: value2, row }) { if ( Variable.checkTypeClassify('\u5B57\u7B26\u4E32', { label: row.typeName, }) ) { if (!value2) { return '\u5B57\u7B26\u4E32\u957F\u5EA6\u5FC5\u987B\u586B\u5199' } if (value2 < 1 || value2 > 255) { return '\u5B57\u7B26\u957F\u5EA6\u4E3A1\u81F3255\u4E4B\u95F4\u7684\u6574\u6570' } } }, }, ], zoom: [ { customValidator({ value: value2, row }) { if ( Variable.checkTypeClassify(['\u6574\u578B', '\u6D6E\u70B9\u578B'], { label: row.typeName, }) ) { if (value2 <= 0) { return '\u7F29\u653E\u6BD4\u9700\u5927\u4E8E0' } } }, }, ], digit: [ { customValidator({ value: value2, row }) { if ( Variable.checkTypeClassify(['\u6574\u578B', '\u6D6E\u70B9\u578B'], { label: row.typeName, }) ) { if (value2 && value2 < 0) { return '\u5C0F\u6570\u4F4D\u6570\u9700\u5927\u4E8E\u7B49\u4E8E0' } } }, }, ], readWriteRule: [ { customValidator({ value: value2, row }) { if ( Variable.checkTypeClassify(['\u6574\u578B', '\u6D6E\u70B9\u578B'], { label: row.typeName, }) ) { if (!value2) { return '\u8BFB\u5199\u89C4\u5219\u5FC5\u987B\u9009\u62E9' } } }, }, ], setValue: [ { customValidator({ value: value2, row }) { if (row.initType == 1 && !value2) { return '\u521D\u59CB\u503C\u5FC5\u987B\u586B\u5199' } }, }, ], }) const cellValidator = async (row, field2) => { const value2 = row[field2] const rules2 = validRules.value[field2] if (!rules2) return '' row.validFail = false row.validFailMsg ??= { [field2]: '' } row.validFailMsg[field2] = '' let msg = '' for (let rule2 of rules2) { if (rule2.required && !value2) { msg = rule2.message } if (!msg && rule2.pattern) { if (!rule2.pattern.test(value2)) { msg = rule2.message } } if (!msg && rule2.customValidator) { const errMsg = await rule2.customValidator({ value: value2, row }) if (errMsg) { msg = errMsg } } } if (msg) { row['validFail'] = true row['validFailMsg'][field2] = msg } else { row['validFail'] = Object.values(row['validFailMsg']).some( (e2) => e2.length != 0 ) } return msg } const rowValidator = async (row) => { if (!state$4.activeNodeTunnel?.type) { return false } let commonKeys = columnKey['-1'] let configKeys = columnKey[state$4.activeNodeTunnel?.type || 1] for (let key2 of [...commonKeys, ...configKeys]) { await cellValidator(row, key2) } return row?.validFail ? false : true } const limitNumber = (val2) => { val2 = val2.replace(/[^\d.]/g, '') val2 = val2.replace(/\.{2,}/g, '.') val2 = val2.replace('.', '$#$').replace(/\./g, '').replace('$#$', '.') if (val2.indexOf('.') === 0 && val2 !== '') { val2 = '0' + val2 } else if (val2.indexOf('.') < 0 && val2 !== '') { val2 = parseFloat(val2) + '' } return val2 } const limitPIntNum = (value2) => { return (value2 + '').replace(/[^\d]+/g, '') } const getTargetNode = (key2, value2, list2, childrenLabel = 'children') => { let target2 = {} const recursion = (list22) => { if (target2.index) return for (let item2 of list22) { if (item2[key2] === value2) { target2 = item2 break } if (item2?.[childrenLabel]?.length) { recursion(item2[childrenLabel]) } } } recursion(list2) if (target2[key2]) return target2 return null } let varsUnSaveData = {} const varsUnSaveDataKey = 'varsUnSaveData' const getVarsUnSaveData = () => { varsUnSaveData = JSON.parse(localStorage.getItem(varsUnSaveDataKey) + '') || {} } const setVarUnSaveData = (activeNodeKey) => { const projectId = Session.get('X-Project') const data2 = varsUnSaveData[projectId] || {} !state$4.unSaveList?.length ? delete data2[activeNodeKey] : (data2[activeNodeKey] = state$4.unSaveList) !Object.keys(data2)?.length ? delete varsUnSaveData[projectId] : (varsUnSaveData[projectId] = data2) localStorage.setItem(varsUnSaveDataKey, JSON.stringify(varsUnSaveData)) } const clearVarUnSaveData = (activeNodeKey) => { const projectId = Session.get('X-Project') if (activeNodeKey) { state$4.unSaveList = [] setVarUnSaveData(activeNodeKey) } else { delete varsUnSaveData[projectId] localStorage.setItem(varsUnSaveDataKey, JSON.stringify(varsUnSaveData)) } } const storageUnSaveRow = () => { if (!state$4.activeNode) return setVarUnSaveData(state$4.activeNode.index) getUnSaveListStorageKeys() app.current.project.moduleSavedStatusMap.Variable = state$4.unSaveList.length ? 'unsaved' : 'saved' } const getUnSaveListStorageKeys = () => { if (!Object.keys(varsUnSaveData)?.length) { getVarsUnSaveData() } const projectId = Session.get('X-Project') state$4.unSaveListStorageKeys = Object.keys(varsUnSaveData?.[projectId] || {}) } const getTableData$1 = async () => { if (!state$4.activeNode || !state$4.activeNodeTunnel) return const { index: index2, groupId = null } = state$4.activeNode const { tunnelId, type: type4 } = state$4.activeNodeTunnel let params2 = { groupId, ...state$4.filterData, } const res = (await request.post( `/api/v1/variable/tunnel/${tunnelId}/tag/query`, params2 )) || [] res.forEach((e2) => { if (e2?.config) { Object.assign(e2, { ...e2.config }) } }) state$4.tableData = [...res] const projectId = Session.get('X-Project') state$4.unSaveList = varsUnSaveData?.[projectId]?.[index2] || [] state$4.unSaveList.forEach((item2) => { if (item2?.['checked']) item2['checked'] = false let idx = 0 let isHas = state$4.tableData.filter((v4, i2) => { if (v4.id === item2.id) { idx = i2 return v4.id === item2.id } }).length > 0 if (isHas) { state$4.tableData.splice(idx, 1, item2) } else { if (state$4.filterData.usedType !== 1) { state$4.tableData.push(item2) } } }) if (state$4.checkedList.length) { const checkedIds = state$4.checkedList.map((e2) => e2.id) const checkedList = [] state$4.tableData.forEach((e2) => { if (checkedIds.includes(e2.id)) { e2.checked = true checkedList.push(e2) } }) state$4.checkedList = [...checkedList] } if (type4 === 2) return res state$4.unSaveList.forEach((e2) => { setTimeout(() => { rowValidator(e2) }) }) return res } const innerTunnelDataType = () => { const dataTypes = [] for (let [k2, v4] of Object.entries(Variable.types)) { if (Number(k2) <= 15) { dataTypes.push(v4.label) } } return dataTypes } const initStateData = async () => { state$4.tableData = [] state$4.totalList = [] state$4.unSaveList = [] state$4.checkedList = [] state$4.groupList = [] state$4.dataTypes = [] state$4.protocolInfo = null if (!state$4.activeNode || !state$4.activeNodeTunnel) return const { config: config2, tunnelId } = state$4.activeNodeTunnel if (config2) { if (!state$4.protocolInfos) { const rs2 = await request.get('/api/v1/variable/tunnel/io/protocol') state$4.protocolInfos = rs2.infos } if (!state$4.protocolInfos) return state$4.protocolInfo = state$4.protocolInfos[config2.protocol] const { protocalDataType = [] } = state$4.protocolInfo const findDateType = (model) => protocalDataType.find((e2) => e2.dependon == model)?.type if (protocalDataType.length === 1) { state$4.dataTypes = findDateType('*') } else if (protocalDataType.length > 1) { state$4.dataTypes = findDateType(config2.model) || findDateType('*') } } if (!state$4.dataTypes?.length) { state$4.dataTypes = innerTunnelDataType() } getGroupData(tunnelId) } const getGroupData = async (tunnelId) => { const res = await request.get(`/api/v1/variable/tunnel/${tunnelId}/group`, { silent: true, }) state$4.groupList = [...res] } const columnKey = { '-1': [ 'name', 'description', 'typeName', 'groupId', 'archiveSetting', 'historicBriefMsg', 'historicGroupId', 'historicGroupName', ], 1: [ 'address', 'readWriteMode', 'interval', 'stringLength', 'zoom', 'digit', 'readWriteRule', ], 2: ['scopeType'], 3: ['initType', 'setValue'], 4: ['expression'], 5: ['mappingVariable', 'readWriteMode'], } const createRow = (rows, tunnelType) => { const arr = [] rows.forEach((item2) => { let obj = {} let config2 = {} let configKeys = columnKey[tunnelType] let commonKeys = columnKey['-1'] for (let [k2, v4] of Object.entries(item2)) { if (commonKeys.includes(k2)) { obj[k2] = v4 } if (configKeys.includes(k2)) { config2[k2] = v4 } } obj.config = config2 if ((item2.id + '').indexOf('new_') == -1) obj.id = item2.id arr.push(obj) }) return arr } const delTableData = async () => { let ids = [] state$4.checkedList.forEach((item2) => { if (typeof item2.id == 'number') { ids.push(item2.id) } state$4.tableData.splice(state$4.tableData.indexOf(item2), 1) state$4.totalList.splice(state$4.totalList.indexOf(item2), 1) state$4.unSaveList.splice(state$4.unSaveList.indexOf(item2), 1) }) if (ids.length) { if (!state$4.activeNodeTunnel) return let tunnelId = state$4.activeNodeTunnel.tunnelId await request.delete(`/api/v1/variable/tunnel/${tunnelId}/tag`, { data: ids, }) } } const saveHistoricArchive = async () => { let historicArchiveList = [] state$4.unSaveList.forEach((item2) => { if (item2.archiveSetting) { historicArchiveList.push({ ...item2.archiveSetting, varId: item2.id, groupId: item2.historicGroupId, }) } }) if (historicArchiveList.length) { await request.put( `/api/v1/historicarchive/var/archivesetting`, historicArchiveList ) } } const saveTableData = async () => { if (!state$4.activeNode || !state$4.activeNodeTunnel) return app.current.project.moduleSavedStatusMap.Variable = 'saving' let { tunnelId, type: type4 } = state$4.activeNodeTunnel if (type4 == 2) { await saveHistoricArchive() app.current.project.moduleSavedStatusMap.Variable = 'saved' return Promise.resolve(true) } let alert2 = '' for (let item2 of state$4.unSaveList) { if (!alert2 && !(await rowValidator(item2))) { alert2 = '\u6821\u9A8C\u5931\u8D25' } else { setTimeout(() => { rowValidator(item2) }) } } if (alert2) { toast(alert2, 'error') return Promise.reject(alert2) } return new Promise((resolve2) => { initUtils.debouncedFn(async () => { let addList = [] let modifyList = [] state$4.unSaveList.forEach((item2) => { let obj = {} let config2 = {} if (!type4) return let configKeys = columnKey[type4] let commonKeys = columnKey['-1'] for (let [k2, v4] of Object.entries(item2)) { if (commonKeys.includes(k2)) { obj[k2] = v4 } if (configKeys.includes(k2)) { config2[k2] = v4 } } obj.config = config2 const seq = state$4.tableData.findIndex((e2) => e2 == item2) obj.index = seq == -1 ? null : seq + 1 if ((item2.id + '').indexOf('new_') >= 0) { addList.push(obj) } else { obj.id = item2.id obj.sort = item2['sort'] modifyList.push(obj) } }) let promise1 = request .post(`/api/v1/variable/tunnel/${tunnelId}/tag`, addList) .then((res) => { if (res && res.length) { res.forEach((e2) => { let idx = state$4.tableData.findIndex((t3) => t3.name === e2.name) if (idx >= 0) { state$4.tableData[idx].id = e2.id state$4.tableData[idx]['sort'] = e2.sort } }) } }) let promise2 = request.put( `/api/v1/variable/tunnel/${tunnelId}/tag`, modifyList ) await Promise.all([promise1, promise2]) await saveHistoricArchive() app.current.project.moduleSavedStatusMap.Variable = 'saved' return resolve2(true) }) }) } const exportFile = async (mode2, tunnelId, groupId, name2) => { let params2 = { mode: mode2, } if (tunnelId !== null) { params2['targetTunnelId'] = tunnelId } if (groupId !== null) { params2['targetGroupId'] = groupId } return await request({ responseType: 'blob', url: `/api/v1/variable/export`, method: 'get', params: params2, }).then((res) => { initUtils.downFile(res, `${name2 || ''}\u53D8\u91CF.xlsx`) }) } function alert$1(msg) { return new Promise((rs2) => { ElMessageBox.alert(msg).finally(rs2) }) } async function confirm(message2, options2 = {}) { return await ElMessageBox.confirm(message2, Language$1._t('\u63D0\u793A'), { confirmButtonText: Language$1._t('\u786E\u8BA4'), cancelButtonText: Language$1._t('\u53D6\u6D88'), center: true, customClass: 'cms-el-message-box', ...options2, }) .then(() => { return true }) .catch(() => { return false }) } window.alert = alert$1 var EllipsisTooltip_vue_vue_type_style_index_0_scoped_true_lang = '' const _hoisted_1$5W = [ 'title', 'data-tooltip-disabled', 'data-tooltip-effect', 'data-tooltip-placement', 'data-tooltip-popper-class', 'data-tooltip-raw-content', ] const _sfc_main$6_ = /* @__PURE__ */ defineComponent({ props: { width: { default: '' }, content: { default: '' }, tooltipContent: { default: '' }, effect: { default: 'dark' }, placement: { default: 'top-start' }, popperClass: { default: '' }, disabled: { type: Boolean, default: false }, rawContent: { type: Boolean, default: false }, }, setup(__props2) { const props2 = __props2 let visible = ref(false) const contentRef = ref() const mouseover = function () { visible.value = contentRef.value.offsetWidth > contentRef.value.parentNode.offsetWidth ? true : false } const mouseleave = function () { visible.value = false } return (_ctx, _cache) => { return ( openBlock(), createElementBlock( 'div', { class: 'content', style: normalizeStyle$1({ width: props2.width }), onMouseover: mouseover, onMouseleave: mouseleave, title: props2.tooltipContent ? props2.tooltipContent : props2.content, 'data-tooltip-disabled': !unref(visible), 'data-tooltip-effect': props2.effect, 'data-tooltip-placement': props2.placement, 'data-tooltip-popper-class': props2.popperClass, 'data-tooltip-raw-content': props2.rawContent, }, [ createElementVNode( 'span', { ref_key: 'contentRef', ref: contentRef, }, [ renderSlot( _ctx.$slots, 'content', {}, () => [createTextVNode(toDisplayString$1(props2.content), 1)], true ), ], 512 ), ], 44, _hoisted_1$5W ) ) } }, }) var EllipsisTooltip = /* @__PURE__ */ _export_sfc(_sfc_main$6_, [ ['__scopeId', 'data-v-ccbf35f2'], ]) var EllipsisTooltip$1 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: EllipsisTooltip, }, Symbol.toStringTag, { value: 'Module' } ) ) var IOTunnelDriveTree_vue_vue_type_style_index_0_scoped_true_lang = '' const _withScopeId$3m = (n2) => ( pushScopeId('data-v-47ff0912'), (n2 = n2()), popScopeId(), n2 ) const _hoisted_1$5V = ['disabled'] const _hoisted_2$4U = { class: 'search' } const _hoisted_3$4s = /* @__PURE__ */ _withScopeId$3m(() => /* @__PURE__ */ createElementVNode( 'div', { class: 'title' }, [ /* @__PURE__ */ createElementVNode('i', { class: 'iconfont icon-tongdaoqudong drive-icon', }), /* @__PURE__ */ createTextVNode('\u901A\u9053\u9A71\u52A8'), ], -1 ) ) const _hoisted_4$3U = { class: 'tree' } const _hoisted_5$3v = { class: 'icon', 'aria-hidden': 'true', } const _hoisted_6$38 = ['xlink:href'] const _hoisted_7$2N = { class: 'title' } const _sfc_main$6Z = /* @__PURE__ */ defineComponent({ props: { treeData: null, activeNodeIndex: null, disabled: { type: Boolean }, }, emits: ['nodeClick'], setup(__props2, { expose, emit: emit2 }) { const $props2 = __props2 const folderNodes = ['suppilers', 'models', 'protocols'] let activeNode = ref() const nodeClick = (node2) => { if ($props2?.disabled) return if (folderNodes.includes(node2.nodeType)) return emit2('nodeClick', node2) } const setActiveNode = (node2) => { activeNode.value = node2 } const treeRef = ref() const filterText = ref('') watch$1(filterText, (val2) => { treeRef.value.filter(val2) }) const filterNode = (value2, data2) => { if (!value2) return true return data2.name.includes(value2) } expose({ setActiveNode, }) return (_ctx, _cache) => { const _component_el_input = resolveComponent('el-input') const _component_ElTree = resolveComponent('ElTree') return ( openBlock(), createElementBlock( 'div', { class: normalizeClass([ 'channelDriver', { disabled: $props2?.disabled }, ]), disabled: $props2?.disabled, }, [ createElementVNode('div', _hoisted_2$4U, [ _hoisted_3$4s, createVNode$1( _component_el_input, { class: 'cms-el-input-x-search drive-search-input', 'suffix-icon': unref(search), modelValue: filterText.value, 'onUpdate:modelValue': _cache[0] || (_cache[0] = ($event) => (filterText.value = $event)), placeholder: '\u641C\u7D22', }, null, 8, ['suffix-icon', 'modelValue'] ), ]), createElementVNode('div', _hoisted_4$3U, [ createVNode$1( _component_ElTree, { ref_key: 'treeRef', ref: treeRef, class: 'cms_el_tree_x', 'default-expand-all': false, 'default-expanded-keys': [$props2.activeNodeIndex], data: __props2.treeData, 'node-key': 'index', props: { label: 'name' }, 'filter-node-method': filterNode, onNodeClick: nodeClick, }, { default: withCtx(({ data: data2 }) => [ createElementVNode( 'div', { class: normalizeClass([ 'node flex', { 'node-folder': folderNodes.includes(data2.nodeType), 'node-current': data2 === activeNode.value || data2.index === $props2.activeNodeIndex, }, ]), style: { width: 'calc(100% - 24px)' }, }, [ (openBlock(), createElementBlock('svg', _hoisted_5$3v, [ createElementVNode( 'use', { 'xlink:href': folderNodes.includes(data2.nodeType) ? '#icon-tongdaoqudongdiyiceng' : '#icon-tongdaoqudongdisanceng', }, null, 8, _hoisted_6$38 ), ])), createElementVNode('div', _hoisted_7$2N, [ createVNode$1( EllipsisTooltip, { width: '100%', content: data2.name, }, null, 8, ['content'] ), ]), ], 2 ), ]), _: 1, }, 8, ['default-expanded-keys', 'data'] ), ]), ], 10, _hoisted_1$5V ) ) } }, }) var IOTunnelDriveTree = /* @__PURE__ */ _export_sfc(_sfc_main$6Z, [ ['__scopeId', 'data-v-47ff0912'], ]) var IOTunnelDriveTree$1 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: IOTunnelDriveTree, }, Symbol.toStringTag, { value: 'Module' } ) ) const _hoisted_1$5U = { class: 'form-table' } const _sfc_main$6Y = /* @__PURE__ */ defineComponent({ props: { data: null, }, emits: ['update:data'], setup(__props2, { expose, emit: emit2 }) { const $props2 = __props2 let data2 = ref($props2?.data) data2.value ??= { type: '', oldValue: '', newValue: '', prefix: '', suffix: '', } function change2() { emit2('update:data', data2.value) } const configTypes = [ { value: '', label: '\u8BF7\u9009\u62E9' }, { value: '0', label: '\u53D8\u91CF\u540D\u79F0\u66FF\u6362' }, { value: '1', label: '\u6DFB\u52A0\u524D\u7F00' }, { value: '2', label: '\u6DFB\u52A0\u540E\u7F00' }, ] const getConfigData = () => data2.value const getConfigResult = () => { let oldValue = '' let newValue = '' if (data2.value.type == '0') { oldValue = data2.value.oldValue newValue = data2.value.newValue } if (data2.value.type == '1') { newValue = data2.value.prefix } if (data2.value.type == '2') { newValue = data2.value.suffix } return { rule: Number(data2.value.type), oldValue, newValue, } } const requireValid = () => { let alert2 = '' if (!data2.value.type) alert2 = '\u8BF7\u9009\u62E9\u53D8\u91CF\u540D\u79F0\u5904\u7406' if ( data2.value.type == '0' && (!data2.value.oldValue || !data2.value.newValue) ) alert2 = '\u8BF7\u586B\u5199\u539F/\u65B0\u540D\u79F0' if (data2.value.type == '1' && !data2.value.prefix) alert2 = '\u8BF7\u586B\u5199\u524D\u7F00\u540D\u79F0' if (data2.value.type == '2' && !data2.value.suffix) alert2 = '\u8BF7\u586B\u5199\u540E\u7F00\u540D\u79F0' if (alert2) { toast(alert2, 'error') return false } return true } expose({ getConfigResult, getConfigData, requireValid, }) return (_ctx, _cache) => { const _component_el_option = resolveComponent('el-option') const _component_el_select = resolveComponent('el-select') const _component_el_form_item = resolveComponent('el-form-item') const _component_el_input = resolveComponent('el-input') const _component_el_form = resolveComponent('el-form') return ( openBlock(), createBlock( _component_el_form, { onSubmit: _cache[5] || (_cache[5] = withModifiers(() => {}, ['prevent'])), 'label-width': 'auto', 'label-position': 'left', class: 'cms-el-form', }, { default: withCtx(() => [ createElementVNode('div', _hoisted_1$5U, [ createVNode$1( _component_el_form_item, { label: '\u53D8\u91CF\u540D\u79F0\u5904\u7406\uFF1A' }, { default: withCtx(() => [ createVNode$1( _component_el_select, { class: 'cms-el-select', 'popper-class': 'cms-el-select_check', modelValue: data2.value.type, 'onUpdate:modelValue': _cache[0] || (_cache[0] = ($event) => (data2.value.type = $event)), placeholder: '\u8BF7\u9009\u62E9', onChange: change2, }, { default: withCtx(() => [ (openBlock(), createElementBlock( Fragment, null, renderList(configTypes, (item2) => { return createVNode$1( _component_el_option, { key: item2.value, value: item2.value, label: item2.label, }, null, 8, ['value', 'label'] ) }), 64 )), ]), _: 1, }, 8, ['modelValue'] ), ]), _: 1, } ), withDirectives( createVNode$1( _component_el_form_item, { label: '\u539F\u540D\u79F0\uFF1A' }, { default: withCtx(() => [ createVNode$1( _component_el_input, { modelValue: data2.value.oldValue, 'onUpdate:modelValue': _cache[1] || (_cache[1] = ($event) => (data2.value.oldValue = $event)), placeholder: '\u8BF7\u8F93\u5165', }, null, 8, ['modelValue'] ), ]), _: 1, }, 512 ), [[vShow, data2.value.type == '0']] ), withDirectives( createVNode$1( _component_el_form_item, { label: '\u65B0\u540D\u79F0\uFF1A' }, { default: withCtx(() => [ createVNode$1( _component_el_input, { modelValue: data2.value.newValue, 'onUpdate:modelValue': _cache[2] || (_cache[2] = ($event) => (data2.value.newValue = $event)), placeholder: '\u8BF7\u8F93\u5165', }, null, 8, ['modelValue'] ), ]), _: 1, }, 512 ), [[vShow, data2.value.type == '0']] ), withDirectives( createVNode$1( _component_el_form_item, { label: '\u524D\u7F00\u540D\u79F0\uFF1A' }, { default: withCtx(() => [ createVNode$1( _component_el_input, { modelValue: data2.value.prefix, 'onUpdate:modelValue': _cache[3] || (_cache[3] = ($event) => (data2.value.prefix = $event)), placeholder: '\u8BF7\u8F93\u5165', }, null, 8, ['modelValue'] ), ]), _: 1, }, 512 ), [[vShow, data2.value.type == '1']] ), withDirectives( createVNode$1( _component_el_form_item, { label: '\u540E\u7F00\u540D\u79F0\uFF1A' }, { default: withCtx(() => [ createVNode$1( _component_el_input, { modelValue: data2.value.suffix, 'onUpdate:modelValue': _cache[4] || (_cache[4] = ($event) => (data2.value.suffix = $event)), placeholder: '\u8BF7\u8F93\u5165', }, null, 8, ['modelValue'] ), ]), _: 1, }, 512 ), [[vShow, data2.value.type == '2']] ), ]), ]), _: 1, } ) ) } }, }) var VarNameConfig = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: _sfc_main$6Y, }, Symbol.toStringTag, { value: 'Module' } ) ) var IOTunnelOperate_vue_vue_type_style_index_0_scoped_true_lang = '' var IOTunnelOperate_vue_vue_type_style_index_1_scoped_true_lang = '' const _withScopeId$3l = (n2) => ( pushScopeId('data-v-0d9952d3'), (n2 = n2()), popScopeId(), n2 ) const _hoisted_1$5T = { class: 'dialog-content io-channel' } const _hoisted_2$4T = { class: 'info' } const _hoisted_3$4r = /* @__PURE__ */ _withScopeId$3l(() => /* @__PURE__ */ createElementVNode( 'p', { class: 'title' }, [ /* @__PURE__ */ createElementVNode( 'span', null, '\u901A\u9053\u4FE1\u606F' ), ], -1 ) ) const _hoisted_4$3T = { class: 'title tabs' } const _hoisted_5$3u = ['onClick'] const _hoisted_6$37 = { key: 0, class: 'empty-setting', } const _hoisted_7$2M = { key: 0, class: 'subtitle', } const _hoisted_8$2t = { class: 'el-dialog__footer', style: { 'margin-top': '0' }, } const _hoisted_9$2h = /* @__PURE__ */ createTextVNode('\u53D6\u6D88') const _hoisted_10$23 = /* @__PURE__ */ createTextVNode('\u786E\u5B9A') const _hoisted_11$1V = /* @__PURE__ */ createTextVNode('\u786E\u5B9A') const _hoisted_12$1P = /* @__PURE__ */ createTextVNode('\u53D6\u6D88') const _hoisted_13$1D = /* @__PURE__ */ createTextVNode('\u786E\u5B9A') const _sfc_main$6X = /* @__PURE__ */ defineComponent({ props: { title: null, operate: null, data: null, }, emits: ['confirm', 'update:modelValue'], setup(__props2, { emit: emit2 }) { const $props2 = __props2 const driveTreeRef = ref() const varNameConfigRef = ref() const close2 = () => { emit2('update:modelValue', false) } const confirm$1 = async () => { if (!activeNodeIndex.value) { toast('\u8BF7\u9009\u62E9\u901A\u9053\u9A71\u52A8', 'error') return } const configParameters = {} for (let [k2, v4] of Object.entries(parameters.value)) { configParameters[k2] = v4.value } const keys3 = activeNodeIndex.value.split('::') const params2 = { parentId: null, type: 1, name: form2.value.name, description: form2.value.description, config: { suppiler: keys3[0], model: keys3[1], protocol: keys3[2], parameters: configParameters, }, } let msg = '' let resp = null const { operate, data: data2 } = $props2 if (operate == 'create') { params2['copyConfig'] = null resp = await request.post('/api/v1/variable/tunnel', params2) msg = '\u65B0\u589E\u6210\u529F' } if (operate == 'copy') { const res = varNameConfigRef.value?.getConfigResult() params2['copyConfig'] = { copyFromId: data2.tunnelId, ...res, } resp = await request.post('/api/v1/variable/tunnel', params2) msg = '\u521B\u5EFA\u526F\u672C\u6210\u529F' } if (operate == 'edit') { resp = await request.put( `/api/v1/variable/tunnel/${data2.tunnelId}`, params2 ) msg = '\u7F16\u8F91\u6210\u529F' } toast(msg, 'success') emit2('confirm', resp, operate) close2() } const tabs2 = ['base', 'adv'] let currentTab = ref('base') let form2 = ref({ name: '', description: '', }) let varNameConfig = reactive({ visible: false, toggle() { varNameConfig.visible = !varNameConfig.visible }, confirm() { if (varNameConfigRef.value?.requireValid()) { confirm$1() } }, }) const renderForm = computed(() => { if (!activeNodeKey.value || !protocolInfo.value[activeNodeKey.value]) { return [ { moduleName: '', moduleParams: [], }, ] } if (currentTab.value == 'base') { return [ { moduleName: '', moduleParams: protocolInfo.value[activeNodeKey.value].protocalParams, }, ] } else { return protocolInfo.value[activeNodeKey.value].advancedParams } }) let parameters = ref({}) let parametersDefault = {} const createParameters = (protocolKey) => { const { protocalParams, advancedParams } = protocolInfo.value[protocolKey] const obj = {} const addAttr = (item2) => { switch (item2.type) { case 'value': obj[item2.key] = { name: item2.name, value: item2?.valueRule?.defaultValue || '', rule: item2?.valueRule?.rule || '', } break case 'select': obj[item2.key] = { name: item2.name, value: item2?.selectValue || item2?.selectValues?.[0], } break case 'switch': obj[item2.key] = { name: item2.name, value: false, } break default: obj[item2.key] = { name: item2.name, value: '', } } } for (let item2 of protocalParams) { addAttr(item2) } for (let item2 of advancedParams) { for (let subitem of item2.moduleParams) { addAttr(subitem) } } return obj } const checkParametersChange = (data2, defaultData2) => { let fill = false for (let [k2, v4] of Object.entries(defaultData2)) { if (data2[k2].value !== v4.value) { fill = true return fill } } return fill } let activeNodeIndex = ref('') let activeNodeKey = ref('') const nodeSwitch = (node2) => { driveTreeRef.value?.setActiveNode(node2) activeNodeIndex.value = node2.index activeNodeKey.value = node2.key parameters.value = createParameters(node2.key) parametersDefault = JSON.parse(JSON.stringify(parameters.value)) } const nodeClick = async (node2) => { const isFill = checkParametersChange(parameters.value, parametersDefault) if (!isFill) { nodeSwitch(node2) } else { if ( await confirm( '\u662F\u5426\u5207\u6362\u9A71\u52A8\uFF0C\u5207\u6362\u9A71\u52A8\u4F1A\u4E22\u5931\u5F53\u524D\u914D\u7F6E\uFF1F' ) ) { nodeSwitch(node2) } } } const changeNodeField = (data2) => { let list2 = lodash.cloneDeep(data2) const recursion = (list22) => { for (let i2 = 0; i2 < list22.length; i2++) { let item2 = list22[i2] if (item2.suppilers) { item2.children = item2.suppilers item2.nodeType = 'suppilers' if (!item2.name) item2.name = item2.type if (!item2.key) item2.key = item2.type if (!item2.index) item2.index = item2.key + Math.random() delete item2.suppilers } if (item2.models) { item2.children = item2.models item2.nodeType = 'models' if (!item2.index) item2.index = item2.key + Math.random() delete item2.models } if (item2.protocols) { if (item2.protocols.find((e2) => e2.isShow === true)) { item2.nodeType = 'protocols' item2.children = item2.protocols if (!item2.index) item2.index = item2.key + Math.random() } else { item2.nodeType = 'protocol' item2.index = item2.protocols[0].index } delete item2.protocols } if (item2.isShow === true || item2.isShow === false) { item2.nodeType = 'protocol' } if (item2.children && item2.children.length) { recursion(item2.children) } } } recursion(list2) return list2 } let protocolTree = ref([]) let protocolInfo = ref() const getProtocol = async () => { const { infos, tree } = await request.get( '/api/v1/variable/tunnel/io/protocol' ) protocolTree.value = tree?.length ? changeNodeField(tree) : [] protocolInfo.value = infos } onBeforeMount(async () => { await getProtocol() if ($props2.operate == 'create'); else { const { data: data2 } = $props2 if (!data2.config) return const { suppiler, model, protocol, parameters: params2 } = data2.config const index2 = [suppiler, model, protocol].join('::') const node2 = getTargetNode('index', index2, protocolTree.value) nodeSwitch(node2) form2.value.name = data2.name for (let [key2, value2] of Object.entries(params2)) { parameters.value[key2].value = value2 } const resp = await request.get( `/api/v1/variable/tunnel/${data2.tunnelId}` ) form2.value.description = resp.description } }) return (_ctx, _cache) => { const _component_el_input = resolveComponent('el-input') const _component_el_form_item = resolveComponent('el-form-item') const _component_el_option = resolveComponent('el-option') const _component_el_select = resolveComponent('el-select') const _component_el_switch = resolveComponent('el-switch') const _component_el_form = resolveComponent('el-form') const _component_el_button = resolveComponent('el-button') const _component_el_dialog = resolveComponent('el-dialog') return ( openBlock(), createBlock( _component_el_dialog, { 'custom-class': 'cms-el-dialog', width: '940px', 'append-to-body': '', 'close-on-click-modal': false, title: $props2.title, onClose: close2, }, { default: withCtx(() => [ createElementVNode('div', _hoisted_1$5T, [ createVNode$1( IOTunnelDriveTree, { ref_key: 'driveTreeRef', ref: driveTreeRef, class: 'drive-tree', disabled: $props2.operate != 'create', activeNodeIndex: activeNodeIndex.value, treeData: protocolTree.value, onNodeClick: nodeClick, }, null, 8, ['disabled', 'activeNodeIndex', 'treeData'] ), createElementVNode('div', _hoisted_2$4T, [ createVNode$1( _component_el_form, { inline: true, onSubmit: _cache[2] || (_cache[2] = withModifiers(() => {}, ['prevent'])), 'label-width': 'auto', 'label-position': 'right', class: 'cms-el-form info-form', }, { default: withCtx(() => [ _hoisted_3$4r, createElementVNode('div', null, [ createVNode$1( _component_el_form_item, { label: '\u901A\u9053\u540D\u79F0\uFF1A', 'label-width': '90px', }, { default: withCtx(() => [ createVNode$1( _component_el_input, { modelValue: form2.value.name, 'onUpdate:modelValue': _cache[0] || (_cache[0] = ($event) => (form2.value.name = $event)), placeholder: '\u8BF7\u8F93\u5165\u901A\u9053\u540D\u79F0', }, null, 8, ['modelValue'] ), ]), _: 1, } ), createVNode$1( _component_el_form_item, { label: '\u901A\u9053\u63CF\u8FF0\uFF1A', 'label-width': '90px', }, { default: withCtx(() => [ createVNode$1( _component_el_input, { modelValue: form2.value.description, 'onUpdate:modelValue': _cache[1] || (_cache[1] = ($event) => (form2.value.description = $event)), placeholder: '\u8BF7\u8F93\u5165\u901A\u9053\u63CF\u8FF0', }, null, 8, ['modelValue'] ), ]), _: 1, } ), ]), createElementVNode('p', _hoisted_4$3T, [ (openBlock(true), createElementBlock( Fragment, null, renderList(unref(tabs2), (item2) => { return ( openBlock(), createElementBlock( 'span', { key: item2, onClick: () => (currentTab.value = item2), class: normalizeClass({ active: currentTab.value == item2, }), }, toDisplayString$1( item2 == 'base' ? '\u57FA\u7840\u914D\u7F6E' : '\u9AD8\u7EA7\u914D\u7F6E' ), 11, _hoisted_5$3u ) ) }), 128 )), ]), !unref(renderForm).length ? (openBlock(), createElementBlock( 'p', _hoisted_6$37, '\u6682\u65E0\u76F8\u5173\u914D\u7F6E' )) : (openBlock(true), createElementBlock( Fragment, { key: 1 }, renderList(unref(renderForm), (m2, i2) => { return ( openBlock(), createElementBlock('div', { key: i2 }, [ m2.moduleName ? (openBlock(), createElementBlock( 'strong', _hoisted_7$2M, toDisplayString$1(m2.moduleName), 1 )) : createCommentVNode('', true), createElementVNode('div', null, [ (openBlock(true), createElementBlock( Fragment, null, renderList(m2.moduleParams, (item2) => { return ( openBlock(), createBlock( _component_el_form_item, { key: item2.key, label: item2.name + '\uFF1A', name: item2.key, }, { default: withCtx(() => [ item2.type == 'select' ? (openBlock(), createBlock( _component_el_select, { key: 0, modelValue: parameters.value[ item2.key ].value, 'onUpdate:modelValue': ($event) => (parameters.value[ item2.key ].value = $event), class: 'cms-el-select', 'popper-class': 'cms-el-select__popper', placeholder: ' ', }, { default: withCtx( () => [ (openBlock(true), createElementBlock( Fragment, null, renderList( item2.selectValues, (opt) => { return ( openBlock(), createBlock( _component_el_option, { key: opt, value: opt, label: opt, }, null, 8, [ 'value', 'label', ] ) ) } ), 128 )), ] ), _: 2, }, 1032, [ 'modelValue', 'onUpdate:modelValue', ] )) : createCommentVNode( '', true ), item2.type == 'value' ? (openBlock(), createBlock( _component_el_input, { key: 1, class: 'cms-el-input', modelValue: parameters.value[ item2.key ].value, 'onUpdate:modelValue': ($event) => (parameters.value[ item2.key ].value = $event), placeholder: '\u8BF7\u8F93\u5165' + item2.name, }, createSlots({ _: 2 }, [ item2.unit ? { name: 'append', fn: withCtx( () => [ createTextVNode( toDisplayString$1( item2.unit ), 1 ), ] ), } : void 0, ]), 1032, [ 'modelValue', 'onUpdate:modelValue', 'placeholder', ] )) : createCommentVNode( '', true ), item2.type == 'switch' ? (openBlock(), createBlock( _component_el_switch, { key: 2, modelValue: parameters.value[ item2.key ].value, 'onUpdate:modelValue': ($event) => (parameters.value[ item2.key ].value = $event), }, null, 8, [ 'modelValue', 'onUpdate:modelValue', ] )) : createCommentVNode( '', true ), ]), _: 2, }, 1032, ['label', 'name'] ) ) }), 128 )), ]), ]) ) }), 128 )), ]), _: 1, } ), ]), ]), createElementVNode('div', _hoisted_8$2t, [ createVNode$1( _component_el_button, { class: 'btn', onClick: close2, }, { default: withCtx(() => [_hoisted_9$2h]), _: 1, } ), $props2.operate == 'copy' ? (openBlock(), createBlock( _component_el_button, { key: 0, class: 'btn btn-submit', type: 'primary', onClick: unref(varNameConfig).toggle, }, { default: withCtx(() => [_hoisted_10$23]), _: 1, }, 8, ['onClick'] )) : (openBlock(), createBlock( _component_el_button, { key: 1, class: 'btn btn-submit', type: 'primary', onClick: confirm$1, }, { default: withCtx(() => [_hoisted_11$1V]), _: 1, } )), ]), createVNode$1( _component_el_dialog, { 'custom-class': 'cms-el-dialog', width: '450px', 'append-to-body': '', modelValue: unref(varNameConfig).visible, 'onUpdate:modelValue': _cache[3] || (_cache[3] = ($event) => (unref(varNameConfig).visible = $event)), 'close-on-click-modal': false, title: $props2.title, }, { footer: withCtx(() => [ createVNode$1( _component_el_button, { class: 'btn', onClick: unref(varNameConfig).toggle, }, { default: withCtx(() => [_hoisted_12$1P]), _: 1, }, 8, ['onClick'] ), createVNode$1( _component_el_button, { class: 'btn btn-submit', type: 'primary', onClick: unref(varNameConfig).confirm, }, { default: withCtx(() => [_hoisted_13$1D]), _: 1, }, 8, ['onClick'] ), ]), default: withCtx(() => [ $props2.operate == 'copy' ? (openBlock(), createBlock( _sfc_main$6Y, { key: 0, ref_key: 'varNameConfigRef', ref: varNameConfigRef, style: { padding: '0 20px' }, }, null, 512 )) : createCommentVNode('', true), ]), _: 1, }, 8, ['modelValue', 'title'] ), ]), _: 1, }, 8, ['title'] ) ) } }, }) var IOTunnelOperateDialog = /* @__PURE__ */ _export_sfc(_sfc_main$6X, [ ['__scopeId', 'data-v-0d9952d3'], ]) var IOTunnelOperate = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: IOTunnelOperateDialog, }, Symbol.toStringTag, { value: 'Module' } ) ) const _hoisted_1$5S = { class: 'dialog-content' } const _hoisted_2$4S = { class: 'el-dialog__footer' } const _hoisted_3$4q = /* @__PURE__ */ createTextVNode('\u53D6\u6D88') const _hoisted_4$3S = /* @__PURE__ */ createTextVNode('\u786E\u5B9A') const _sfc_main$6W = /* @__PURE__ */ defineComponent({ props: { title: null, operate: null, data: null, }, emits: ['confirm', 'update:modelValue'], setup(__props2, { emit: emit2 }) { const $props2 = __props2 const varNameConfigRef = ref() const close2 = () => { emit2('update:modelValue', false) } const channelTypes = [ { value: '3', label: '\u5185\u90E8\u53D8\u91CF' }, { value: '5', label: 'I/O\u6620\u5C04' }, { value: '4', label: '\u903B\u8F91\u53D8\u91CF' }, ] let form2 = ref({ type: '', name: '', description: '', }) const confirm2 = async () => { if (!Number(form2.value.type)) return toast( '\u901A\u9053\u7C7B\u578B\u4E0D\u80FD\u4E3A\u7A7A', 'error' ) const params2 = { ...form2.value, type: Number(form2.value.type), config: null, } let msg = '' let resp = null const { operate, data: data2 } = $props2 if (operate == 'create') { resp = await request.post('/api/v1/variable/tunnel', params2) msg = '\u65B0\u589E\u6210\u529F' } if (operate == 'copy') { if (!varNameConfigRef.value?.requireValid()) return const res = varNameConfigRef.value?.getConfigResult() params2['copyConfig'] = { copyFromId: data2.tunnelId, ...res, } resp = await request.post('/api/v1/variable/tunnel', params2) msg = '\u521B\u5EFA\u526F\u672C\u6210\u529F' } if (operate == 'edit') { resp = await request.put( `/api/v1/variable/tunnel/${data2.tunnelId}`, params2 ) msg = '\u7F16\u8F91\u6210\u529F' } toast(msg, 'success') emit2('confirm', resp, operate) close2() } onMounted(async () => { const { operate, data: data2 } = $props2 if (operate == 'edit' || operate == 'copy') { form2.value.name = data2.name form2.value.type = data2.type + '' const resp = await request.get( `/api/v1/variable/tunnel/${data2.tunnelId}` ) form2.value.description = resp.description } }) return (_ctx, _cache) => { const _component_el_input = resolveComponent('el-input') const _component_el_form_item = resolveComponent('el-form-item') const _component_el_option = resolveComponent('el-option') const _component_el_select = resolveComponent('el-select') const _component_el_form = resolveComponent('el-form') const _component_el_button = resolveComponent('el-button') const _component_el_dialog = resolveComponent('el-dialog') return ( openBlock(), createBlock( _component_el_dialog, { 'custom-class': 'cms-el-dialog', width: '450px', 'close-on-click-modal': false, title: $props2.title, 'append-to-body': '', onClose: close2, }, { default: withCtx(() => [ createElementVNode('div', _hoisted_1$5S, [ createVNode$1( _component_el_form, { onSubmit: _cache[3] || (_cache[3] = withModifiers(() => {}, ['prevent'])), 'label-width': '110px', 'label-position': 'left', class: 'cms-el-form', }, { default: withCtx(() => [ createVNode$1( _component_el_form_item, { label: '\u901A\u9053\u540D\u79F0\uFF1A' }, { default: withCtx(() => [ createVNode$1( _component_el_input, { modelValue: form2.value.name, 'onUpdate:modelValue': _cache[0] || (_cache[0] = ($event) => (form2.value.name = $event)), placeholder: '\u8BF7\u8F93\u5165\u901A\u9053\u540D\u79F0', }, null, 8, ['modelValue'] ), ]), _: 1, } ), $props2.operate == 'create' ? (openBlock(), createBlock( _component_el_form_item, { key: 0, label: '\u901A\u9053\u7C7B\u578B\uFF1A', }, { default: withCtx(() => [ createVNode$1( _component_el_select, { class: 'cms-el-select', 'popper-class': 'cms-el-select_check', modelValue: form2.value.type, 'onUpdate:modelValue': _cache[1] || (_cache[1] = ($event) => (form2.value.type = $event)), placeholder: '\u8BF7\u9009\u62E9', }, { default: withCtx(() => [ (openBlock(), createElementBlock( Fragment, null, renderList(channelTypes, (item2) => { return createVNode$1( _component_el_option, { key: item2.value, value: item2.value, label: item2.label, }, null, 8, ['value', 'label'] ) }), 64 )), ]), _: 1, }, 8, ['modelValue'] ), ]), _: 1, } )) : createCommentVNode('', true), createVNode$1( _component_el_form_item, { label: '\u901A\u9053\u63CF\u8FF0\uFF1A' }, { default: withCtx(() => [ createVNode$1( _component_el_input, { modelValue: form2.value.description, 'onUpdate:modelValue': _cache[2] || (_cache[2] = ($event) => (form2.value.description = $event)), placeholder: '\u8BF7\u8F93\u5165\u901A\u9053\u63CF\u8FF0', }, null, 8, ['modelValue'] ), ]), _: 1, } ), ]), _: 1, } ), $props2.operate == 'copy' ? (openBlock(), createBlock( _sfc_main$6Y, { key: 0, ref_key: 'varNameConfigRef', ref: varNameConfigRef, }, null, 512 )) : createCommentVNode('', true), ]), createElementVNode('div', _hoisted_2$4S, [ createVNode$1( _component_el_button, { class: 'btn', onClick: close2, }, { default: withCtx(() => [_hoisted_3$4q]), _: 1, } ), createVNode$1( _component_el_button, { class: 'btn btn-submit', type: 'primary', onClick: confirm2, }, { default: withCtx(() => [_hoisted_4$3S]), _: 1, } ), ]), ]), _: 1, }, 8, ['title'] ) ) } }, }) var InnerTunnelOperate = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: _sfc_main$6W, }, Symbol.toStringTag, { value: 'Module' } ) ) const _hoisted_1$5R = { class: 'dialog-content' } const _hoisted_2$4R = { class: 'el-dialog__footer' } const _hoisted_3$4p = /* @__PURE__ */ createTextVNode('\u53D6\u6D88') const _hoisted_4$3R = /* @__PURE__ */ createTextVNode('\u786E\u5B9A') const _sfc_main$6V = /* @__PURE__ */ defineComponent({ props: { title: null, operate: null, node: null, data: null, }, emits: ['confirm', 'update:modelValue'], setup(__props2, { emit: emit2 }) { const $props2 = __props2 const varNameConfigRef = ref() const close2 = () => { emit2('update:modelValue', false) } let name2 = ref('') let address = ref('') const confirm2 = async () => { const params2 = { type: 1, name: name2.value, config: { address: address.value }, } let msg = '' let resp = null const { operate, data: data2, node: node2 } = $props2 if (operate == 'create') { params2['parentId'] = data2.tunnelId resp = await request.post('/api/v1/variable/tunnel', params2) msg = '\u65B0\u589E\u6210\u529F' } if (operate == 'copy') { if (!varNameConfigRef.value?.requireValid()) return const res = varNameConfigRef.value?.getConfigResult() params2['parentId'] = node2.parent.tunnelId params2['copyConfig'] = { copyFromId: data2.tunnelId, ...res, } resp = await request.post('/api/v1/variable/tunnel', params2) msg = '\u521B\u5EFA\u526F\u672C\u6210\u529F' } if (operate == 'edit') { params2['parentId'] = node2.parent.tunnelId resp = await request.put( `/api/v1/variable/tunnel/${data2.tunnelId}`, params2 ) msg = '\u7F16\u8F91\u6210\u529F' } toast(msg, 'success') emit2('confirm', resp, operate) close2() } onMounted(() => { const { operate, data: data2 } = $props2 if (operate == 'edit' || operate == 'copy') { name2.value = data2.name address.value = data2.config?.address || '' } }) return (_ctx, _cache) => { const _component_el_input = resolveComponent('el-input') const _component_el_form_item = resolveComponent('el-form-item') const _component_el_form = resolveComponent('el-form') const _component_el_button = resolveComponent('el-button') const _component_el_dialog = resolveComponent('el-dialog') return ( openBlock(), createBlock( _component_el_dialog, { 'custom-class': 'cms-el-dialog', width: '450px', title: $props2.title, 'close-on-click-modal': false, 'append-to-body': '', onClose: close2, }, { default: withCtx(() => [ createElementVNode('div', _hoisted_1$5R, [ createVNode$1( _component_el_form, { onSubmit: _cache[2] || (_cache[2] = withModifiers(() => {}, ['prevent'])), 'label-width': '110px', 'label-position': 'left', class: 'cms-el-form', }, { default: withCtx(() => [ createVNode$1( _component_el_form_item, { label: '\u7AD9\u70B9\u540D\u79F0\uFF1A' }, { default: withCtx(() => [ createVNode$1( _component_el_input, { modelValue: name2.value, 'onUpdate:modelValue': _cache[0] || (_cache[0] = ($event) => (name2.value = $event)), placeholder: '\u8BF7\u8F93\u5165', }, null, 8, ['modelValue'] ), ]), _: 1, } ), createVNode$1( _component_el_form_item, { label: 'Addr\u7AD9\u53F7\uFF1A' }, { default: withCtx(() => [ createVNode$1( _component_el_input, { modelValue: address.value, 'onUpdate:modelValue': _cache[1] || (_cache[1] = ($event) => (address.value = $event)), placeholder: '\u8BF7\u8F93\u5165', }, null, 8, ['modelValue'] ), ]), _: 1, } ), ]), _: 1, } ), $props2.operate == 'copy' ? (openBlock(), createBlock( _sfc_main$6Y, { key: 0, ref_key: 'varNameConfigRef', ref: varNameConfigRef, }, null, 512 )) : createCommentVNode('', true), ]), createElementVNode('div', _hoisted_2$4R, [ createVNode$1( _component_el_button, { class: 'btn', onClick: close2, }, { default: withCtx(() => [_hoisted_3$4p]), _: 1, } ), createVNode$1( _component_el_button, { class: 'btn btn-submit', type: 'primary', onClick: confirm2, }, { default: withCtx(() => [_hoisted_4$3R]), _: 1, } ), ]), ]), _: 1, }, 8, ['title'] ) ) } }, }) var SUBTunnelOperate = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: _sfc_main$6V, }, Symbol.toStringTag, { value: 'Module' } ) ) const _hoisted_1$5Q = { class: 'dialog-content' } const _hoisted_2$4Q = { class: 'el-dialog__footer' } const _hoisted_3$4o = /* @__PURE__ */ createTextVNode('\u53D6\u6D88') const _hoisted_4$3Q = /* @__PURE__ */ createTextVNode('\u786E\u5B9A') const _sfc_main$6U = /* @__PURE__ */ defineComponent({ props: { title: null, operate: null, node: null, data: null, }, emits: ['confirm', 'update:modelValue'], setup(__props2, { emit: emit2 }) { const $props2 = __props2 const varNameConfigRef = ref() const close2 = () => { emit2('update:modelValue', false) } let name2 = ref('') const confirm2 = async () => { let msg = '' let resp = null const { operate, data: data2, node: node2 } = $props2 if (operate == 'create') { resp = await request.post( `/api/v1/variable/tunnel/${data2.tunnelId}/group`, { name: name2.value } ) msg = '\u65B0\u589E\u6210\u529F' } if (operate == 'copy') { if (!varNameConfigRef.value?.requireValid()) return const res = varNameConfigRef.value?.getConfigResult() const params2 = { name: name2.value, copyConfig: { copyFromId: $props2.data.groupId, ...res, }, } resp = await request.post( `/api/v1/variable/tunnel/${node2.parent.tunnelId}/group`, params2 ) msg = '\u521B\u5EFA\u526F\u672C\u6210\u529F' } if (operate == 'edit') { resp = await request.put( `/api/v1/variable/tunnel/${node2.parent.tunnelId}/group/${data2.groupId}`, { name: name2.value, } ) msg = '\u7F16\u8F91\u6210\u529F' } toast(msg, 'success') emit2('confirm', resp, operate) close2() } onMounted(() => { const { operate, data: data2 } = $props2 if (operate == 'edit' || operate == 'copy') { name2.value = data2.name } }) return (_ctx, _cache) => { const _component_el_input = resolveComponent('el-input') const _component_el_form_item = resolveComponent('el-form-item') const _component_el_form = resolveComponent('el-form') const _component_el_button = resolveComponent('el-button') const _component_el_dialog = resolveComponent('el-dialog') return ( openBlock(), createBlock( _component_el_dialog, { 'custom-class': 'cms-el-dialog', width: '450px', 'append-to-body': '', 'close-on-click-modal': false, title: $props2.title, onClose: close2, }, { default: withCtx(() => [ createElementVNode('div', _hoisted_1$5Q, [ createVNode$1( _component_el_form, { onSubmit: _cache[1] || (_cache[1] = withModifiers(() => {}, ['prevent'])), 'label-width': '110px', 'label-position': 'left', class: 'cms-el-form', }, { default: withCtx(() => [ createVNode$1( _component_el_form_item, { label: '\u53D8\u91CF\u7EC4\u540D\u79F0\uFF1A' }, { default: withCtx(() => [ createVNode$1( _component_el_input, { modelValue: name2.value, 'onUpdate:modelValue': _cache[0] || (_cache[0] = ($event) => (name2.value = $event)), placeholder: '\u8BF7\u8F93\u5165', }, null, 8, ['modelValue'] ), ]), _: 1, } ), ]), _: 1, } ), $props2.operate == 'copy' ? (openBlock(), createBlock( _sfc_main$6Y, { key: 0, ref_key: 'varNameConfigRef', ref: varNameConfigRef, }, null, 512 )) : createCommentVNode('', true), ]), createElementVNode('div', _hoisted_2$4Q, [ createVNode$1( _component_el_button, { class: 'btn', onClick: close2, }, { default: withCtx(() => [_hoisted_3$4o]), _: 1, } ), createVNode$1( _component_el_button, { class: 'btn btn-submit', type: 'primary', onClick: confirm2, }, { default: withCtx(() => [_hoisted_4$3Q]), _: 1, } ), ]), ]), _: 1, }, 8, ['title'] ) ) } }, }) var VarGroupOperate = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: _sfc_main$6U, }, Symbol.toStringTag, { value: 'Module' } ) ) var ImportFile_vue_vue_type_style_index_0_scoped_true_lang$1 = '' const _withScopeId$3k = (n2) => ( pushScopeId('data-v-003ab8ee'), (n2 = n2()), popScopeId(), n2 ) const _hoisted_1$5P = { class: 'dialog-content' } const _hoisted_2$4P = { class: 'use' } const _hoisted_3$4n = /* @__PURE__ */ createTextVNode( ' \u5BFC\u5165\u65B9\u5F0F\uFF1A ' ) const _hoisted_4$3P = /* @__PURE__ */ _withScopeId$3k(() => /* @__PURE__ */ createElementVNode( 'i', { class: 'iconfont icon-tishi1 tips', title: '1.\u8986\u76D6\u5BFC\u5165\uFF0C\u5220\u9664\u540C\u540D\u8282\u70B9\u7684\u6570\u636E\uFF0C\u4EE5\u5BFC\u5165\u6587\u4EF6\u7684\u6570\u636E\u4E3A\u51C6\uFF1B
2.\u66F4\u65B0\u5BFC\u5165\uFF0C\u4E0D\u5B58\u5728\u7684\u6570\u636E\u5219\u65B0\u589E\uFF0C\u5B58\u5728\u7684\u6570\u636E\u5219\u66F4\u65B0\u914D\u7F6E\uFF1B', 'data-tooltip-placement': 'right-start', 'data-tooltip-raw-content': '', }, null, -1 ) ) const _hoisted_5$3t = { class: 'el-dialog__footer' } const _hoisted_6$36 = /* @__PURE__ */ createTextVNode('\u53D6\u6D88') const _hoisted_7$2L = /* @__PURE__ */ createTextVNode('\u786E\u5B9A') const _sfc_main$6T = /* @__PURE__ */ defineComponent({ props: { mode: null, tunnelId: null, groupId: null, }, emits: ['success', 'update:modelValue'], setup(__props2, { emit: emit2 }) { const props2 = __props2 const close2 = () => { emit2('update:modelValue', false) } let use3 = ref('') const uploaderRef = ref() const confirm2 = () => { if (!use3.value) return toast('\u8BF7\u9009\u62E9\u5BFC\u5165\u65B9\u5F0F', 'error') uploaderRef.value?.click() } const resetFile = () => { if (uploaderRef.value?.value) uploaderRef.value.value = '' } const selectFile = (event) => { const target2 = event.target const file2 = target2.files[0] let formData = new FormData() formData.set('file', file2) const replace2 = use3.value == '1' ? true : false formData.set('mode', props2.mode + '') formData.set('replace', replace2 + '') if (props2.tunnelId !== null) { formData.set('targetTunnelId', props2.tunnelId + '') } if (props2.groupId !== null) { formData.set('targetGroupId', props2.groupId + '') } return request({ url: `/api/v1/variable/import`, method: 'post', data: formData, }) .then(() => { toast('\u5BFC\u5165\u6210\u529F', 'success') emit2('success', props2.mode, replace2) close2() }) .finally(() => { resetFile() }) } return (_ctx, _cache) => { const _component_el_option = resolveComponent('el-option') const _component_el_select = resolveComponent('el-select') const _component_el_button = resolveComponent('el-button') const _component_el_dialog = resolveComponent('el-dialog') return ( openBlock(), createBlock( _component_el_dialog, { 'append-to-body': '', 'close-on-click-modal': false, title: '\u5BFC\u5165', 'custom-class': 'cms-el-dialog', width: '450px', onClose: close2, }, { default: withCtx(() => [ createElementVNode('div', _hoisted_1$5P, [ createElementVNode('div', _hoisted_2$4P, [ _hoisted_3$4n, createVNode$1( _component_el_select, { modelValue: use3.value, 'onUpdate:modelValue': _cache[0] || (_cache[0] = ($event) => (use3.value = $event)), class: 'cms-el-select', 'popper-class': 'cms-el-select__popper', placeholder: '\u8BF7\u9009\u62E9', style: { width: '240px' }, }, { default: withCtx(() => [ createVNode$1(_component_el_option, { key: '0', value: '', label: '\u8BF7\u9009\u62E9', }), createVNode$1(_component_el_option, { key: '1', value: '1', label: '\u8986\u76D6\u5BFC\u5165', }), createVNode$1(_component_el_option, { key: '2', value: '2', label: '\u66F4\u65B0\u5BFC\u5165', }), ]), _: 1, }, 8, ['modelValue'] ), _hoisted_4$3P, ]), createElementVNode( 'input', { ref_key: 'uploaderRef', ref: uploaderRef, class: 'uploader', type: 'file', accept: '.xlsx', onChange: selectFile, }, null, 544 ), ]), createElementVNode('div', _hoisted_5$3t, [ createVNode$1( _component_el_button, { class: 'btn', onClick: close2, }, { default: withCtx(() => [_hoisted_6$36]), _: 1, } ), createVNode$1( _component_el_button, { class: 'btn btn-submit', type: 'primary', onClick: confirm2, }, { default: withCtx(() => [_hoisted_7$2L]), _: 1, } ), ]), ]), _: 1, } ) ) } }, }) var ImportFileDialog = /* @__PURE__ */ _export_sfc(_sfc_main$6T, [ ['__scopeId', 'data-v-003ab8ee'], ]) var ImportFile$2 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: ImportFileDialog, }, Symbol.toStringTag, { value: 'Module' } ) ) var Sidebar_vue_vue_type_style_index_0_scoped_true_lang$5 = '' var Sidebar_vue_vue_type_style_index_1_lang = '' const _withScopeId$3j = (n2) => ( pushScopeId('data-v-64d00d6d'), (n2 = n2()), popScopeId(), n2 ) const _hoisted_1$5O = { class: 'title' } const _hoisted_2$4O = ['disabled', 'onClick'] const _hoisted_3$4m = { key: 0, class: 'search flex', } const _hoisted_4$3O = ['title'] const _hoisted_5$3s = { class: 'tree' } const _hoisted_6$35 = { class: 'tree-node-icon' } const _hoisted_7$2K = ['title'] const _hoisted_8$2s = { key: 0, class: 'icon', 'aria-hidden': 'true', } const _hoisted_9$2g = { key: 0, 'xlink:href': '#icon-jinyong', fill: '#fff', } const _hoisted_10$22 = { key: 0, 'xlink:href': '#icon-zhengchang', } const _hoisted_11$1U = { key: 1, 'xlink:href': '#icon-lixianzhuangtai', } const _hoisted_12$1O = { class: 'title flex' } const _hoisted_13$1C = { key: 0, class: 'tree-node-unsave', } const _hoisted_14$1q = { key: 0, class: 'btn', } const _hoisted_15$1l = /* @__PURE__ */ _withScopeId$3j(() => /* @__PURE__ */ createElementVNode( 'i', { class: 'iconfont icon-gengduo menu' }, null, -1 ) ) const _hoisted_16$1j = /* @__PURE__ */ createTextVNode( ' \u6DFB\u52A0\u7AD9\u70B9 ' ) const _hoisted_17$1b = /* @__PURE__ */ createTextVNode( ' \u6DFB\u52A0\u53D8\u91CF\u7EC4 ' ) const _hoisted_18$13 = /* @__PURE__ */ createTextVNode( ' \u521B\u5EFA\u526F\u672C ' ) const _hoisted_19$_ = /* @__PURE__ */ createTextVNode(' \u7F16\u8F91 ') const _hoisted_20$U = /* @__PURE__ */ createTextVNode(' \u5220\u9664 ') const _hoisted_21$K = /* @__PURE__ */ createTextVNode(' \u5BFC\u5165 ') const _hoisted_22$I = /* @__PURE__ */ createTextVNode(' \u5BFC\u51FA ') const _hoisted_23$E = /* @__PURE__ */ createTextVNode(' \u542F\u7528 ') const _hoisted_24$C = /* @__PURE__ */ createTextVNode(' \u7981\u7528 ') const _sfc_main$6S = /* @__PURE__ */ defineComponent({ props: { styleB: { type: Boolean }, uneditable: { type: Boolean }, disabledChannelIndex: null, autoSelectFirstNode: { type: Boolean }, filterData: null, noLanguage: { type: Boolean }, }, emits: ['delete', 'nodeClick', 'tabSwitch'], setup(__props2, { expose, emit: emit2 }) { const $props2 = __props2 onMounted(async () => { await getTreeData2() getUnSaveListStorageKeys() if ($props2.autoSelectFirstNode) { selectFirstNode() } }) const treeRef = ref() const operationMap = { create: '\u65B0\u589E', edit: '\u7F16\u8F91', copy: '\u590D\u5236', } const channelTabs = ['IO\u901A\u9053', '\u5185\u90E8\u901A\u9053'] let activeTab2 = ref('IO\u901A\u9053') const tabChange = async (tab) => { if (tab === activeTab2.value) return activeTab2.value = tab await getTreeData2() activeNode.value = null nodeClick(null, null) emit2('tabSwitch') } const _getTreeData = useDebounceFn(() => { getTreeData2() }, 500) watch$1( () => $props2.filterData.keyword, () => { _getTreeData() }, { deep: true, } ) watch$1( () => [$props2.filterData.dataTypes, $props2.filterData.usedType], () => { getTreeData2() }, { deep: true, } ) let treeData = ref([]) let activeNode = ref(null) let updateVirtualTree = ref(false) const getNodeIcon = (treeType, type4 = 0, typeTag) => { if (treeType == 'group') return 'icon-bianliangzuzijiedian' if (type4 == 2) return 'icon-xitongbianliang' if (type4 == 3) return 'icon-neibubianliang' if (type4 == 4) return 'icon-luojibianliang' if (type4 == 5) return 'icon-IOyingshebianliang' if (type4 == 1) { if (typeTag == 'TCP') return 'icon-TCPfujiedian' if (typeTag == 'COM') return 'icon-chuankoufujiedian' if (typeTag == 'SUB') return 'icon-zhandianzijiedian1' } } const getTunnelNodeState = (name2) => { return Variable.getByName(`State_${name2}`)?.value } const isStorageIndex = (index2) => { return state$4.unSaveListStorageKeys.includes(index2) } const selectFirstNode = () => { const data2 = treeData.value[0] if (!data2) return const node2 = { parent: treeData.value } nodeClick(node2, data2) } const nodeClick = (node2, data2, reQuery = false) => { if ( data2 === activeNode.value && activeNode.value !== null && reQuery == false ) return activeNode.value = data2 const cloneData = JSON.parse(JSON.stringify(data2)) const cloneParent = JSON.parse(JSON.stringify(node2?.parent || {})) let activeNodeTunnel = null if (data2 && node2) { if (data2?.treeType == 'group') { if (['TCP', 'COM'].includes(cloneParent.typeTag)) { activeNodeTunnel = cloneParent } if (cloneParent.typeTag == 'SUB') { activeNodeTunnel = cloneParent let tunnelConfig = {} for (let item2 of treeData.value) { const t3 = item2?.childs?.find( (e2) => e2.tunnelId === cloneParent.tunnelId ) if (t3) { tunnelConfig = item2.config break } } if (activeNodeTunnel) activeNodeTunnel['config'] = tunnelConfig } if (cloneParent.typeTag === null) { activeNodeTunnel = cloneParent } } else { if (['TCP', 'COM'].includes(data2.typeTag || '')) { activeNodeTunnel = data2 } if (data2.typeTag == 'SUB') { activeNodeTunnel = cloneData if (activeNodeTunnel) activeNodeTunnel['config'] = cloneParent.config } if (data2.typeTag === null) { activeNodeTunnel = cloneData } } } emit2('nodeClick', data2, activeNodeTunnel, treeData.value.length) } const getTreeData2 = async () => { const treeMode = channelTabs.indexOf(activeTab2.value) + 1 const params2 = { treeMode, ...$props2.filterData, } const resp = await request.post(`/api/v1/variable/tunnel/tree`, params2) treeData.value = resp nextTick(() => { updateVirtualTree.value = true }) } const isHightLight = ref(false) const hightLight = (isActive) => { isHightLight.value = isActive if (isActive) { setTimeout(() => { isHightLight.value = false }, 1500) } } const filterText = ref('') let operatingNode = ref() let operatingNodeData = ref() const handleCommand = (params2) => { let { type: type4, node: node2, data: data2 } = params2 operatingNode.value = node2 operatingNodeData.value = data2 const fun = { createVarGroup() { varGroupConfig.open('create') }, createAddressGroup() { SUBTunnelConfig.open('create') }, copy() { if (['COM', 'TCP', null].includes(data2.typeTag)) { createTunnelOpen('copy') } if (data2.typeTag == 'SUB') { SUBTunnelConfig.open('copy') } if (data2.typeTag === void 0) { varGroupConfig.open('copy') } }, edit: () => { if (['COM', 'TCP', null].includes(data2.typeTag)) { createTunnelOpen('edit') } if (data2.typeTag == 'SUB') { SUBTunnelConfig.open('edit') } if (data2.typeTag === void 0) { varGroupConfig.open('edit') } }, delete: () => { deleteNode2(data2, node2) }, importNode() { const { mode: mode2, tunnelId, groupId } = createImportExportParams() Object.assign(importFileConfig, { visible: true, mode: mode2, tunnelId, groupId, }) }, exportNode() { const { mode: mode2, tunnelId, groupId, name: name2, } = createImportExportParams() exportFile(mode2, tunnelId, groupId, name2).then(() => { toast('\u5BFC\u51FA\u6210\u529F', 'success') }) }, enable() { switchNode(data2, 'enable') }, disabled() { switchNode(data2, 'disable') }, } fun[type4]() } const deleteNode2 = async (data2, node2) => { let msg = '\u662F\u5426\u5220\u9664\u8282\u70B9' let url2 = `/api/v1/variable/tunnel/${node2.parent.tunnelId}/group/${data2.groupId}` const isTunnel = ['COM', 'TCP', null].includes(data2.typeTag) const isSubTunnel = data2.typeTag == 'SUB' if (isTunnel) msg = '\u5220\u9664\u901A\u9053\u5C06\u5220\u9664\u901A\u9053\u4E0B\u6240\u6709\u8282\u70B9\uFF0C\u662F\u5426\u5220\u9664\uFF1F' if (isSubTunnel) msg = '\u5220\u9664\u7AD9\u70B9\u5C06\u5220\u9664\u4E0B\u6240\u6709\u8282\u70B9\uFF0C\u662F\u5426\u5220\u9664\uFF1F' if (isTunnel || isSubTunnel) { url2 = `/api/v1/variable/tunnel/${data2.tunnelId}` } if (await confirm(msg)) { await request.delete(url2) toast('\u5220\u9664\u6210\u529F', 'success') const list2 = isTunnel ? treeData.value : node2.parent.childs const idx = list2.findIndex((item2) => item2.index === data2.index) list2.splice(idx, 1) if ( data2.index === activeNode.value?.index || (data2?.childs && getTargetNode( 'index', activeNode.value?.index, data2?.childs, 'childs' )) ) { activeNode.value = null nodeClick(null, null) } } } const switchNode = async (data2, operation2) => { initUtils.debouncedFn(async () => { await request.put( `/api/v1/variable/tunnel/${data2.tunnelId}/${operation2}` ) data2.enable = operation2 == 'enable' ? true : false }) } const createSubTunnelOpen = () => { operatingNode.value = treeRef.value?.getCurrentNode() operatingNodeData.value = operatingNode.value.data SUBTunnelConfig.open('create') } const createTunnelOpen = (action = 'create') => { activeTab2.value == 'IO\u901A\u9053' ? IOTunnelConfig.open(action) : innerTunnelConfig.open(action) } const tunnelOperateConfirm = async () => { getTreeData2() } const innerTunnelConfig = reactive({ visible: false, title: '', operate: 'create', open(operate) { Object.assign(innerTunnelConfig, { operate, visible: true, title: `${operationMap[operate]}\u901A\u9053`, }) }, }) const IOTunnelConfig = reactive({ visible: false, title: '', operate: 'create', open(operate) { Object.assign(IOTunnelConfig, { operate, visible: true, title: `${operationMap[operate]}\u901A\u9053`, }) }, }) const SUBTunnelConfig = reactive({ visible: false, title: '', operate: 'create', open(operate) { Object.assign(SUBTunnelConfig, { operate, visible: true, title: operate == 'create' ? '\u6DFB\u52A0\u7AD9\u70B9' : `${operationMap[operate]}\u7AD9\u70B9`, }) }, }) const varGroupConfig = reactive({ visible: false, title: '', operate: 'create', open(operate) { Object.assign(varGroupConfig, { operate, visible: true, title: operate == 'create' ? '\u6DFB\u52A0\u53D8\u91CF\u7EC4' : `${operationMap[operate]}\u53D8\u91CF\u7EC4`, }) }, confirm() { getTreeData2() const tunnelId = state$4.activeNodeTunnel?.tunnelId if (tunnelId) { getGroupData(tunnelId) } }, }) const importFileConfig = reactive({ visible: false, mode: 0, tunnelId: null, groupId: null, }) const createImportExportParams = () => { const { treeType, tunnelId = 0, groupId = 0, name: name2, } = operatingNodeData.value const mode2 = treeType == 'tunnel' ? 1 : 2 const tId = treeType == 'tunnel' ? tunnelId : operatingNode.value.parent.tunnelId const gId = treeType == 'tunnel' ? null : groupId return { mode: mode2, tunnelId: tId, groupId: gId, name: name2, } } const importFileSuccess = async (mode2, replace2) => { await getTreeData2() const updateModuleSavedStatus = () => { app.current.project.moduleSavedStatusMap.Variable = 'saved' } if (replace2) { if (mode2 == 0) { clearVarUnSaveData() updateModuleSavedStatus() } else { const recursion = (item2) => { if (item2.index) { clearVarUnSaveData(item2.index) } if (item2?.childs?.length) { recursion(item2.childs) } } recursion(operatingNodeData.value) } getUnSaveListStorageKeys() } if (!activeNode.value) return if ( replace2 && !getTargetNode( 'index', activeNode.value.index, treeData.value, 'childs' ) ) { activeNode.value = null nodeClick(null, null) updateModuleSavedStatus() return } const activeTreeNode = treeRef.value?.getCurrentNode() nodeClick(activeTreeNode, activeNode.value, true) } expose({ hightLight, createTunnelOpen, createSubTunnelOpen, selectFirstNode, importFileSuccess, }) return (_ctx, _cache) => { const _component_el_input = resolveComponent('el-input') const _component_el_dropdown_item = resolveComponent('el-dropdown-item') const _component_el_dropdown_menu = resolveComponent('el-dropdown-menu') const _component_el_dropdown = resolveComponent('el-dropdown') return ( openBlock(), createElementBlock( 'div', { class: normalizeClass([ 'varsSidebar styleA', { styleB: $props2?.styleB, 'hight-light': isHightLight.value }, ]), }, [ createElementVNode('div', _hoisted_1$5O, [ (openBlock(true), createElementBlock( Fragment, null, renderList(unref(channelTabs), (item2, i2) => { return ( openBlock(), createElementBlock( 'button', { key: item2, disabled: $props2?.disabledChannelIndex === i2, class: normalizeClass({ active: item2 == activeTab2.value, }), onClick: ($event) => tabChange(item2), }, toDisplayString$1( unref(Language$1).toLanguage(item2, $props2?.noLanguage) ), 11, _hoisted_2$4O ) ) }), 128 )), ]), !$props2?.styleB ? (openBlock(), createElementBlock('div', _hoisted_3$4m, [ createVNode$1( _component_el_input, { class: 'cms-el-input-x-search', 'suffix-icon': unref(search), modelValue: filterText.value, 'onUpdate:modelValue': _cache[0] || (_cache[0] = ($event) => (filterText.value = $event)), placeholder: '\u641C\u7D22', }, null, 8, ['suffix-icon', 'modelValue'] ), createElementVNode( 'i', { class: 'iconfont icon-tianjiahuamian', title: `\u6DFB\u52A0${activeTab2.value}`, onClick: _cache[1] || (_cache[1] = ($event) => createTunnelOpen('create')), }, null, 8, _hoisted_4$3O ), ])) : createCommentVNode('', true), createElementVNode('div', _hoisted_5$3s, [ updateVirtualTree.value ? (openBlock(), createBlock( VirtualTree, { key: 0, ref_key: 'treeRef', ref: treeRef, data: treeData.value, itemSize: 32, class: 'cms-el-tree', nodeKey: 'index', draggable: false, emptyText: unref(Language$1).toLanguage( '\u6682\u65E0\u6570\u636E', $props2?.noLanguage ), filterText: filterText.value, props: { children: 'childs', }, onNodeClick: nodeClick, }, { default: withCtx(({ node: node2, data: data2 }) => [ createElementVNode( 'div', { class: normalizeClass([ 'custom-tree-node flex', { 'node-current': data2.index === activeNode.value?.index, }, ]), disabled: true, }, [ createElementVNode('div', _hoisted_6$35, [ createElementVNode( 'i', { class: normalizeClass([ 'iconfont', getNodeIcon( data2.treeType, data2.type, data2.typeTag ), ]), }, null, 2 ), createElementVNode( 'div', { class: 'node-icon-status', title: data2.status === 3 ? data2.errorMsg : null, 'data-tooltip-placement': 'top', }, [ ['COM', 'TCP'].includes(data2.typeTag) ? (openBlock(), createElementBlock('svg', _hoisted_8$2s, [ data2.enable === false ? (openBlock(), createElementBlock( 'use', _hoisted_9$2g )) : (openBlock(), createElementBlock( Fragment, { key: 1 }, [ getTunnelNodeState( data2.name ) === true ? (openBlock(), createElementBlock( 'use', _hoisted_10$22 )) : createCommentVNode( '', true ), getTunnelNodeState( data2.name ) === false ? (openBlock(), createElementBlock( 'use', _hoisted_11$1U )) : createCommentVNode( '', true ), ], 64 )), ])) : createCommentVNode('', true), ], 8, _hoisted_7$2K ), ]), $props2?.uneditable ? (openBlock(), createBlock( EllipsisTooltip, { key: 0, width: '100%', content: !$props2?.noLanguage && data2.name == '\u7CFB\u7EDF\u53D8\u91CF' ? `${_ctx._t(data2.name)}` : data2.name, class: 'title', }, null, 8, ['content'] )) : (openBlock(), createElementBlock( Fragment, { key: 1 }, [ createElementVNode('div', _hoisted_12$1O, [ createVNode$1( EllipsisTooltip, { width: '100%', content: data2.name, }, null, 8, ['content'] ), data2.typeTag != 'COM' && isStorageIndex(data2.index) ? (openBlock(), createElementBlock( 'div', _hoisted_13$1C, ' \u672A\u4FDD\u5B58 ' )) : createCommentVNode('', true), ]), data2?.type != 2 ? (openBlock(), createElementBlock( 'div', _hoisted_14$1q, [ createVNode$1( _component_el_dropdown, { trigger: 'hover', onCommand: handleCommand, teleported: false, }, { dropdown: withCtx(() => [ createVNode$1( _component_el_dropdown_menu, null, { default: withCtx(() => [ data2.typeTag == 'COM' ? (openBlock(), createBlock( _component_el_dropdown_item, { key: 0, command: { type: 'createAddressGroup', node: node2, data: data2, }, }, { default: withCtx( () => [ _hoisted_16$1j, ] ), _: 2, }, 1032, ['command'] )) : createCommentVNode( '', true ), [ 'TCP', 'SUB', null, ].includes( data2.typeTag ) ? (openBlock(), createBlock( _component_el_dropdown_item, { key: 1, command: { type: 'createVarGroup', node: node2, data: data2, }, }, { default: withCtx( () => [ _hoisted_17$1b, ] ), _: 2, }, 1032, ['command'] )) : createCommentVNode( '', true ), createVNode$1( _component_el_dropdown_item, { command: { type: 'copy', node: node2, data: data2, }, }, { default: withCtx( () => [ _hoisted_18$13, ] ), _: 2, }, 1032, ['command'] ), createVNode$1( _component_el_dropdown_item, { command: { type: 'edit', node: node2, data: data2, }, }, { default: withCtx( () => [ _hoisted_19$_, ] ), _: 2, }, 1032, ['command'] ), createVNode$1( _component_el_dropdown_item, { class: 'item_delete', command: { type: 'delete', node: node2, data: data2, }, }, { default: withCtx( () => [ _hoisted_20$U, ] ), _: 2, }, 1032, ['command'] ), createVNode$1( _component_el_dropdown_item, { command: { type: 'importNode', node: node2, data: data2, }, }, { default: withCtx( () => [ _hoisted_21$K, ] ), _: 2, }, 1032, ['command'] ), createVNode$1( _component_el_dropdown_item, { command: { type: 'exportNode', node: node2, data: data2, }, }, { default: withCtx( () => [ _hoisted_22$I, ] ), _: 2, }, 1032, ['command'] ), ['COM', 'TCP'].includes( data2.typeTag ) ? (openBlock(), createBlock( _component_el_dropdown_item, { key: 2, command: { type: 'enable', node: node2, data: data2, }, }, { default: withCtx( () => [ _hoisted_23$E, ] ), _: 2, }, 1032, ['command'] )) : createCommentVNode( '', true ), ['COM', 'TCP'].includes( data2.typeTag ) ? (openBlock(), createBlock( _component_el_dropdown_item, { key: 3, command: { type: 'disabled', node: node2, data: data2, }, }, { default: withCtx( () => [ _hoisted_24$C, ] ), _: 2, }, 1032, ['command'] )) : createCommentVNode( '', true ), ]), _: 2, }, 1024 ), ]), default: withCtx(() => [ _hoisted_15$1l, ]), _: 2, }, 1024 ), ] )) : createCommentVNode('', true), ], 64 )), ], 2 ), ]), _: 1, }, 8, ['data', 'emptyText', 'filterText'] )) : createCommentVNode('', true), ]), unref(IOTunnelConfig).visible ? (openBlock(), createBlock( IOTunnelOperateDialog, { key: 1, modelValue: unref(IOTunnelConfig).visible, 'onUpdate:modelValue': _cache[2] || (_cache[2] = ($event) => (unref(IOTunnelConfig).visible = $event)), title: unref(IOTunnelConfig).title, operate: unref(IOTunnelConfig).operate, data: operatingNodeData.value, onConfirm: tunnelOperateConfirm, }, null, 8, ['modelValue', 'title', 'operate', 'data'] )) : createCommentVNode('', true), unref(innerTunnelConfig).visible ? (openBlock(), createBlock( _sfc_main$6W, { key: 2, modelValue: unref(innerTunnelConfig).visible, 'onUpdate:modelValue': _cache[3] || (_cache[3] = ($event) => (unref(innerTunnelConfig).visible = $event)), title: unref(innerTunnelConfig).title, operate: unref(innerTunnelConfig).operate, data: operatingNodeData.value, onConfirm: tunnelOperateConfirm, }, null, 8, ['modelValue', 'title', 'operate', 'data'] )) : createCommentVNode('', true), unref(SUBTunnelConfig).visible ? (openBlock(), createBlock( _sfc_main$6V, { key: 3, modelValue: unref(SUBTunnelConfig).visible, 'onUpdate:modelValue': _cache[4] || (_cache[4] = ($event) => (unref(SUBTunnelConfig).visible = $event)), title: unref(SUBTunnelConfig).title, operate: unref(SUBTunnelConfig).operate, node: operatingNode.value, data: operatingNodeData.value, onConfirm: tunnelOperateConfirm, }, null, 8, ['modelValue', 'title', 'operate', 'node', 'data'] )) : createCommentVNode('', true), unref(varGroupConfig).visible ? (openBlock(), createBlock( _sfc_main$6U, { key: 4, modelValue: unref(varGroupConfig).visible, 'onUpdate:modelValue': _cache[5] || (_cache[5] = ($event) => (unref(varGroupConfig).visible = $event)), title: unref(varGroupConfig).title, operate: unref(varGroupConfig).operate, node: operatingNode.value, data: operatingNodeData.value, onConfirm: unref(varGroupConfig).confirm, }, null, 8, [ 'modelValue', 'title', 'operate', 'node', 'data', 'onConfirm', ] )) : createCommentVNode('', true), unref(importFileConfig).visible ? (openBlock(), createBlock( ImportFileDialog, { key: 5, modelValue: unref(importFileConfig).visible, 'onUpdate:modelValue': _cache[6] || (_cache[6] = ($event) => (unref(importFileConfig).visible = $event)), mode: unref(importFileConfig).mode, tunnelId: unref(importFileConfig).tunnelId, groupId: unref(importFileConfig).groupId, onSuccess: importFileSuccess, }, null, 8, ['modelValue', 'mode', 'tunnelId', 'groupId'] )) : createCommentVNode('', true), ], 2 ) ) } }, }) var Sidebar$a = /* @__PURE__ */ _export_sfc(_sfc_main$6S, [ ['__scopeId', 'data-v-64d00d6d'], ]) var Sidebar$b = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: Sidebar$a, }, Symbol.toStringTag, { value: 'Module' } ) ) var VarReferenceConfig_vue_vue_type_style_index_0_scoped_true_lang = '' var VarReferenceConfig_vue_vue_type_style_index_1_scoped_true_lang = '' const _hoisted_1$5N = { class: 'varUseConfig' } const _hoisted_2$4N = { class: 'content' } const _hoisted_3$4l = { class: 'table' } const _sfc_main$6R = /* @__PURE__ */ defineComponent({ props: { showConfig: { type: Boolean, default: false, }, configData: { type: Object, default: () => { return { key: 'id', } }, }, isMultiple: { type: Boolean, default: false, }, defaultCheckKey: { type: Array, default: () => [], }, data: { type: Object, default: () => ({ id: '', name: '', }), }, filterType: { type: Array, default: () => [], }, size: { type: String, }, disabledChannelIndex: { type: Number, }, disabledNames: { type: Array, default: () => [], }, autoSelectFirstNode: { type: Boolean, default: true, }, defaultDataTypes: { type: Array, default: () => [], }, isConfigureHistory: { type: Boolean, default: false, }, filterClientVariables: { type: Boolean, default: false, }, noLanguage: { type: Boolean, default: false, }, }, emits: ['cancel', 'confirm', 'changeName', 'cellClick'], setup(__props2, { expose, emit: emit2 }) { const props2 = __props2 const SidebarCom = ref() const tableTooltipConfig = { enterable: true, contentMethod: ({ column, row }) => { const { property: property2 } = column return Language$1.toLanguage(row[property2], props2?.noLanguage) }, } const tableRef = ref() let tableData2 = ref([]) const filterData = ref({ dataTypes: props2.defaultDataTypes, usedType: 0, keyword: '', }) const clearFilterData = () => { filterData.value.dataTypes = [] filterData.value.usedType = 0 filterData.value.keyword = '' } let activeNode = ref(null) let activeNodeTunnel = ref(null) const nodeClick = (data2, activeNodeTunnelData) => { activeNode.value = data2 activeNodeTunnel.value = activeNodeTunnelData init2() } const clear2 = () => { clearFilterData() search2() } const search2 = async () => { const records = getRecords() const cloneRecords = JSON.parse(JSON.stringify(records)) await getData() if (cloneRecords.length) { const unContainList = [] cloneRecords.forEach((row) => { const index2 = tableData2.value.findIndex((f2) => f2.id === row.id) if (index2 == -1) { unContainList.push(row) } }) tableData2.value.unshift(...unContainList) if (!props2.isMultiple) { tableRef.value?.setRadioRow(cloneRecords[0]) } else { const cloneRecordIds = cloneRecords.map((e2) => e2.id) tableData2.value.forEach((e2) => { if (cloneRecordIds.includes(e2.id)) { e2['checked'] = true } }) } tableRef.value?.loadData(tableData2.value) } } const getData = async () => { tableData2.value = [] if (!activeNode.value || !activeNodeTunnel.value) return false let tunnelId = activeNodeTunnel.value?.tunnelId let params2 = { isConfigureHistory: props2.isConfigureHistory, groupId: activeNode.value.groupId || null, ...filterData.value, } const res = await request.post( `/api/v1/variable/tunnel/${tunnelId}/tag/query`, params2 ) if (props2.filterClientVariables && res?.length) { for (let i2 = res.length - 1; i2 >= 0; i2--) { if (res[i2]?.config?.scopeType == 1) { res.splice(i2, 1) } } } res.forEach((item2) => { if ( props2.filterType.length && !props2.filterType.includes(item2.type) ) { return } tableData2.value.push(item2) }) tableRef?.value?.loadData(tableData2.value) } const initialIndex = ref(null) const init2 = async () => { if ( props2.showConfig && JSON.stringify(props2.configData.data) !== '{}' ) { initialIndex.value = props2.configData.data.findIndex( (f2) => f2[props2.configData.key || 'id'] === props2.configData.currentRow[props2.configData.key || 'id'] ) } await getData() if (props2.data?.name) { updateRecordsByKey('name', props2.data.name) } if (props2.defaultCheckKey?.length && props2.isMultiple) { tableData2.value.forEach((e2) => { if (props2.defaultCheckKey.includes(e2.id)) { e2['checked'] = true } }) tableRef.value?.loadData(tableData2.value) } } const reset2 = () => { clearFilterData() tableRef.value?.clearRadioRow() tableRef.value?.clearCheckboxRow() } const cancel2 = () => { emit2('cancel') } const confirm2 = () => { const records = getRecords() emit2('confirm', records, initialIndex.value) } const config2 = async () => { const records = getRecords() if (!records.length) { ElMessage.warning( Language$1.toLanguage( '\u8BF7\u5148\u52FE\u9009\u6570\u636E', props2?.noLanguage ) ) return } emit2('changeName', initialIndex.value, records) await getData() if (props2.data?.name) { updateRecordsByKey('name', props2.data.name) } let dataList2 = props2.configData.data let variableKey = props2.configData?.variableKey if (variableKey && initialIndex.value + 1 < dataList2.length) { const name2 = dataList2[initialIndex.value + 1][variableKey] updateRecordsByKey('name', name2) } initialIndex.value++ if (initialIndex.value > props2.configData.data.length - 1) { ElMessage.warning( Language$1.toLanguage( '\u5DF2\u914D\u7F6E\u5230\u6700\u540E\u4E00\u6761\u6570\u636E', props2?.noLanguage ) ) initialIndex.value = props2.configData.data.length - 1 } } const getRecords = () => { if (props2.isMultiple) { return tableRef.value?.getCheckboxRecords() } else { const radio2 = tableRef.value?.getRadioRecord() return radio2 ? [radio2] : [] } } const updateRecords = (row) => { if (!props2.isMultiple) { tableRef.value?.setRadioRow(row) } else { const records = tableRef.value?.getCheckboxRecords() const check2 = records.indexOf(row) == -1 tableRef.value?.setCheckboxRow(row, check2) } } const updateRecordsByKey = (key2, value2) => { const row = tableData2.value.find((f2) => f2[key2] === value2) if (row) { updateRecords(row) } } const cellClick = ({ row }) => { updateRecords(row) emit2('cellClick', row) } expose({ reset: reset2, init: init2, cancel: cancel2, confirm: confirm2, config: config2, selectFirstNode: () => SidebarCom.value.selectFirstNode(), }) return (_ctx, _cache) => { const _component_vxe_column = resolveComponent('vxe-column') const _component_vxe_table = resolveComponent('vxe-table') return ( openBlock(), createElementBlock('div', _hoisted_1$5N, [ createVNode$1( Filter$2, { filterData: filterData.value, styleB: true, size: __props2.size, noLanguage: props2.noLanguage, onSearch: search2, onClear: clear2, }, null, 8, ['filterData', 'size', 'noLanguage'] ), createElementVNode('div', _hoisted_2$4N, [ createVNode$1( Sidebar$a, { class: 'sidebar', ref_key: 'SidebarCom', ref: SidebarCom, styleB: true, uneditable: true, disabledChannelIndex: __props2.disabledChannelIndex, autoSelectFirstNode: __props2.autoSelectFirstNode, filterData: filterData.value, noLanguage: props2.noLanguage, onNodeClick: nodeClick, }, null, 8, [ 'disabledChannelIndex', 'autoSelectFirstNode', 'filterData', 'noLanguage', ] ), createElementVNode('div', _hoisted_3$4l, [ createVNode$1( _component_vxe_table, { border: '', ref_key: 'tableRef', ref: tableRef, class: 'cms-vxe-table cms-vxe-table-min', height: '100%', 'show-overflow': 'tooltip', 'tooltip-config': tableTooltipConfig, 'column-config': { resizable: true }, 'row-config': { keyField: 'id', isCurrent: true }, 'row-class-name': ({ row }) => { return props2.disabledNames.includes(row.name) ? 'disabled-row' : '' }, 'checkbox-config': { checkRowKeys: props2.defaultCheckKey, checkField: 'checked', highlight: true, }, data: tableData2.value, onCellClick: cellClick, onCheckboxChange: cellClick, 'empty-text': unref(Language$1).toLanguage( '\u6682\u65E0\u6570\u636E', props2?.noLanguage ), }, { default: withCtx(() => [ createVNode$1( _component_vxe_column, { type: __props2.isMultiple ? 'checkbox' : 'radio', width: __props2.isMultiple ? '45' : '0', resizable: false, align: 'center', }, null, 8, ['type', 'width'] ), createVNode$1( _component_vxe_column, { type: 'seq', title: unref(Language$1).toLanguage( '\u5E8F\u53F7', props2?.noLanguage ), width: '100', }, null, 8, ['title'] ), createVNode$1( _component_vxe_column, { field: 'name', title: unref(Language$1).toLanguage( '\u53D8\u91CF\u540D', props2?.noLanguage ), 'max-width': '205', }, null, 8, ['title'] ), createVNode$1( _component_vxe_column, { field: 'description', title: unref(Language$1).toLanguage( '\u53D8\u91CF\u63CF\u8FF0', props2?.noLanguage ), 'max-width': '155', }, null, 8, ['title'] ), createVNode$1( _component_vxe_column, { field: 'typeName', title: unref(Language$1).toLanguage( '\u6570\u636E\u7C7B\u578B', props2?.noLanguage ), resizable: false, }, { default: withCtx(({ row }) => [ createTextVNode( toDisplayString$1( unref(Language$1).toLanguage( row.typeName, props2?.noLanguage ) ), 1 ), ]), _: 1, }, 8, ['title'] ), ]), _: 1, }, 8, ['row-class-name', 'checkbox-config', 'data', 'empty-text'] ), ]), ]), ]) ) } }, }) var VarReferenceConfig = /* @__PURE__ */ _export_sfc(_sfc_main$6R, [ ['__scopeId', 'data-v-7e77d54e'], ]) var VarReferenceConfig$1 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: VarReferenceConfig, }, Symbol.toStringTag, { value: 'Module' } ) ) var functionDialogVariate_vue_vue_type_style_index_0_lang = '' const _hoisted_1$5M = { class: 'dialog-content', style: { height: '650px' }, } const _sfc_main$6Q = /* @__PURE__ */ defineComponent({ props: { visible: { type: Boolean }, isAppendToBody: { type: Boolean, default: true }, showConfig: { type: Boolean }, configData: null, isMultiple: { type: Boolean }, defaultCheckKey: null, data: null, dialogClose: { type: Function, default: () => {} }, dialogConfirm: { type: Function, default: () => {} }, dialogChangeName: { type: Function, default: () => {} }, filterType: null, disabledChannelIndex: null, autoSelectFirstNode: { type: Boolean }, disabledNames: null, defaultDataTypes: null, isConfigureHistory: { type: Boolean }, filterClientVariables: { type: Boolean }, noLanguage: { type: Boolean }, }, emits: ['cancel', 'confirm', 'changeName', 'cellClick'], setup(__props2, { emit: emit2 }) { const $props2 = __props2 const varUseRef = ref(null) const customDialogClass = computed(() => { if (app.running) { return 'cms-el-dialog cms-el-dialog__light' } else { return 'cms-el-dialog' } }) const show = computed({ get: () => $props2.visible, set: (val2) => val2, }) const opened = () => { setTimeout(() => { varUseRef.value?.selectFirstNode() }, 300) } const cancelHandle = () => { varUseRef.value?.cancel() } const cancel2 = () => { emit2('cancel') $props2.dialogClose() varUseRef.value?.reset() } const confirmHandle = () => { varUseRef.value?.confirm() } const confirm2 = (selectRows, index2) => { emit2('confirm', selectRows) $props2.dialogConfirm(selectRows, index2) } const configHandle = () => { varUseRef.value?.config() } const changeName = (index2, selectRows) => { emit2('changeName', index2, selectRows) $props2.dialogChangeName({ index: index2, rowList: selectRows, }) } const cellClick = (row) => { emit2('cellClick', row) } return (_ctx, _cache) => { const _component_el_button = resolveComponent('el-button') const _component_el_dialog = resolveComponent('el-dialog') return ( openBlock(), createBlock( _component_el_dialog, { modelValue: unref(show), 'onUpdate:modelValue': _cache[0] || (_cache[0] = ($event) => isRef(show) ? (show.value = $event) : null), title: unref(Language$1).toLanguage( '\u5173\u8054\u53D8\u91CF', $props2?.noLanguage ), 'append-to-body': $props2?.isAppendToBody, 'close-on-click-modal': false, 'custom-class': customDialogClass.value, width: '1110px', onOpened: opened, onClose: cancel2, }, { footer: withCtx(() => [ $props2.showConfig ? (openBlock(), createElementBlock( 'button', { key: 0, class: 'btn btn_config', onClick: configHandle, }, toDisplayString$1( unref(Language$1).toLanguage( '\u786E\u8BA4\u5E76\u914D\u7F6E\u4E0B\u4E00\u9879', $props2?.noLanguage ) ), 1 )) : createCommentVNode('', true), createVNode$1( _component_el_button, { class: 'btn btn-cancel', onClick: cancelHandle, }, { default: withCtx(() => [ createTextVNode( toDisplayString$1( unref(Language$1).toLanguage( '\u53D6\u6D88', $props2?.noLanguage ) ), 1 ), ]), _: 1, } ), createVNode$1( _component_el_button, { class: 'btn btn-submit', type: 'primary', onClick: confirmHandle, }, { default: withCtx(() => [ createTextVNode( toDisplayString$1( unref(Language$1).toLanguage( '\u786E\u5B9A', $props2?.noLanguage ) ), 1 ), ]), _: 1, } ), ]), default: withCtx(() => [ createElementVNode('div', _hoisted_1$5M, [ createVNode$1( VarReferenceConfig, { ref_key: 'varUseRef', ref: varUseRef, showConfig: $props2?.showConfig, configData: $props2?.configData, isMultiple: $props2?.isMultiple, defaultCheckKey: $props2?.defaultCheckKey, defaultDataTypes: $props2?.defaultDataTypes, data: $props2?.data, filterType: $props2?.filterType, disabledChannelIndex: $props2?.disabledChannelIndex, autoSelectFirstNode: false, disabledNames: $props2?.disabledNames, isConfigureHistory: $props2?.isConfigureHistory, filterClientVariables: $props2?.filterClientVariables, noLanguage: $props2?.noLanguage, onCancel: cancel2, onConfirm: confirm2, onChangeName: changeName, onCellClick: cellClick, }, null, 8, [ 'showConfig', 'configData', 'isMultiple', 'defaultCheckKey', 'defaultDataTypes', 'data', 'filterType', 'disabledChannelIndex', 'disabledNames', 'isConfigureHistory', 'filterClientVariables', 'noLanguage', ] ), ]), ]), _: 1, }, 8, ['modelValue', 'title', 'append-to-body', 'custom-class'] ) ) } }, }) var functionDialogVariate = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, default: _sfc_main$6Q, }, Symbol.toStringTag, { value: 'Module' } ) ) const createVariableDialog = (options2 = {}) => { const mountNode = document.createElement('div') function close2() { Instance.unmount() document.body.removeChild(mountNode) } const Instance = createApp$1(_sfc_main$6Q, { visible: true, ...options2, dialogClose: close2, dialogConfirm: (data2, initialIndex) => { options2.dialogConfirm?.(data2, initialIndex) close2() }, dialogChangeName: (data2) => { options2.dialogChangeName?.(data2) }, }) document.body.appendChild(mountNode) Instance.config.globalProperties.t = Language$1.t Instance.config.globalProperties._t = Language$1._t Instance.use(useTable).use(installer).mount(mountNode) return Instance } function openVariableDialog({ currentVariable = {}, isMultiple: isMultiple2 = false, defaultCheckKey = [], showConfig = false, configData = {}, defaultDataTypes = [], }) { let selectDataList = [] return new Promise((resolve2) => { createVariableDialog({ data: currentVariable, isMultiple: isMultiple2, defaultCheckKey, showConfig, configData, defaultDataTypes, dialogConfirm(data2, initialIndex) { if (showConfig) { selectDataList.push({ index: initialIndex, row: data2, }) let res = { data: !isMultiple2 ? data2[0] : data2, selectDataList, } resolve2(res) } else { if (!isMultiple2) resolve2(data2[0]) resolve2(data2) } }, dialogChangeName(selectData) { if (!showConfig) return let { index: index2, rowList } = selectData let row = rowList[0] selectDataList.push({ index: index2, row, }) let dataList2 = configData.data let variableKey = configData.variableKey dataList2[index2][variableKey] = row.name }, }) }) } class Resource { id = '' name = '\u5957\u4EF6' cover = '' canvasNode = new CanvasNode$1({ id: '', is: 'Img', props: { filename: '', }, style: {}, blocks: [], }) constructor(json) { Object.assign(this, json) this.canvasNode = new CanvasNode$1(this.canvasNode) this.canvasNode.style.position = 'unset' this.canvasNode.style.left = 'unset' this.canvasNode.style.top = 'unset' } static getImages(nodes) { const str = JSON.stringify(nodes) const reg = /[^/\\()'"`.,\s]+?(\.jpg|\.jpeg|\.png|\.gif|\.svg)/gi const res = str.match(reg) if (!res) return null return [...new Set(res)] } } var __glob_0_12 = /* @__PURE__ */ Object.freeze( /* @__PURE__ */ Object.defineProperty( { __proto__: null, Resource, }, Symbol.toStringTag, { value: 'Module' } ) ) const moduleMap = { '../models/App.ts': __glob_0_0, '../models/Base.ts': __glob_0_1, '../models/Block.ts': __glob_0_2, '../models/CanvasNode.ts': __glob_0_3, '../models/Client.ts': __glob_0_4, '../models/Config.ts': __glob_0_5, '../models/Expression.ts': __glob_0_6, '../models/Language.ts': __glob_0_7, '../models/Page.ts': __glob_0_8, '../models/PageHistory.ts': __glob_0_9, '../models/PageManager.ts': __glob_0_10, '../models/Project.ts': __glob_0_11, '../models/Resource.ts': __glob_0_12, '../models/Socket.ts': __glob_0_13, '../models/Variable.ts': __glob_0_14, '../models/Widget.ts': __glob_0_15, '../models/index.ts': __glob_0_16, } const models$1 = new Proxy( {}, { get(object4, name2) { if (object4[name2]) return object4[name2] for (const fileName in moduleMap) { const module2 = moduleMap[fileName] for (const key2 in module2) { if (key2 === name2) { const model = module2[key2] object4[name2] = model return model } } } }, } ) window.models = models$1 const packs = new Proxy( {}, { get(object4, key2) { if (object4[key2]) return object4[key2] const map2 = { '@element-plus/icons-vue': () => Promise.resolve().then(function () { return index$s }), '@vueuse/core': () => Promise.resolve().then(function () { return index$q }), '@vueuse/shared': () => Promise.resolve().then(function () { return index$t }), axios: () => Promise.resolve().then(function () { return index$p }), 'crypto-js': () => Promise.resolve().then(function () { return index$1 }), dayjs: () => Promise.resolve().then(function () { return dayjs_min }), 'element-plus': () => Promise.resolve().then(function () { return ElementPlus }), echarts: () => Promise.resolve().then(function () { return index }), html2canvas: () => Promise.resolve().then(function () { return html2canvas_esm }), jszip: () => Promise.resolve().then(function () { return jszip_min }), lodash: () => Promise.resolve().then(function () { return lodash$1 }), vue: () => import('vue'), 'vue-i18n': () => Promise.resolve().then(function () { return vueI18n }), 'vue-router': () => Promise.resolve().then(function () { return vueRouter }), vuex: () => Promise.resolve().then(function () { return vuex_esmBundler }), } const packPromise = map2[key2]?.() object4[key2] = packPromise return packPromise }, } ) const name = 'syc-cms' const version$5 = '2.2.1' const scripts = { dev: 'vite --host', open: 'vite --host --open', build: 'vite build', 'build:update-icon': 'npm run update-icon && npm run build', 'build:sdk': 'vite build --config=vite.sdk.config.ts', 'build:sdk-npm:publish': 'npm run build:sdk && npm run npm:publish', 'npm:publish': 'npm whoami && npm publish', serve: 'vite preview --host --port=8888', 'build-serve': 'npm run build && npm run serve', 'vue-tsc': 'vue-tsc --noEmit', test: 'jest', 'update-icon': 'node update-iconfont.js', } const main = 'dist/sdk/sdk.es.js' const files = ['dist/sdk/'] const dependencies$1 = { '@element-plus/icons-vue': '^1.1.4', '@microsoft/signalr': '^6.0.6', '@vue/cli-service': '^5.0.4', '@vueuse/core': '^9.6.0', '@vueuse/shared': '^8.9.4', axios: '^0.24.0', 'crypto-js': '^4.1.1', dayjs: '^1.11.6', echarts: '^5.3.0', 'element-plus': '2.1.8', 'html-to-image': '^1.11.11', html2canvas: '^1.4.1', jsencrypt: '^3.2.1', jspdf: '^2.5.1', jszip: '^3.10.1', keyboardjs: '^2.6.4', lodash: '^4.17.21', nprogress: '^0.2.0', 'path-browserify': '^1.0.1', 'print-js': '^1.6.0', sortablejs: '^1.15.0', vue: '3.2.31', 'vue-i18n': '^9.1.9', 'vue-router': '^4.0.11', vuex: '^4.0.2', 'vxe-table': '^4.2.0', 'vxe-table-plugin-element': '^1.11.4', 'xe-utils': '^3.5.4', } const devDependencies = { '@babel/preset-typescript': '^7.16.7', '@jest/globals': '^27.5.1', '@types/crypto-js': '^4.1.1', '@types/jest': '^27.4.1', '@types/keyboardjs': '^2.5.0', '@types/lodash': '^4.14.181', '@types/node': '^16.11.26', '@types/sortablejs': '^1.13.0', '@typescript-eslint/eslint-plugin': '^5.12.1', '@typescript-eslint/parser': '^5.12.1', '@vitejs/plugin-vue': '^2.3.3', '@vue/compiler-sfc': '^3.2.31', 'babel-eslint': '^10.1.0', compressing: '^1.9.0', eslint: '^8.12.0', 'eslint-config-airbnb': '^19.0.4', 'eslint-plugin-import': '^2.25.4', 'eslint-plugin-vue': '^8.5.0', 'eslint-plugin-vue-libs': '^4.0.0', jest: '^27.5.1', puppeteer: '^20.2.1', request: '^2.88.2', sass: '^1.49.9', 'ts-jest': '^27.1.3', typescript: '^4.5.5', 'unplugin-auto-import': '^0.5.11', 'unplugin-element-plus': '^0.1.3', 'unplugin-vue-components': '^0.17.21', vite: '^2.8.0', 'vite-plugin-style-import': '^2.0.0', 'vue-eslint-parser': '^8.3.0', 'vue-tsc': '^0.3.0', } var package_ = { name, version: version$5, scripts, main, files, dependencies: dependencies$1, devDependencies, } createGlobalEvent() new App() const modules = { '../components/left-menu.vue': () => Promise.resolve().then(function () { return leftMenu$1 }), '../components/scaling-zoom.vue': () => Promise.resolve().then(function () { return scalingZoom }), '../components/theme-menu.vue': () => Promise.resolve().then(function () { return themeMenu }), '../views/404NotFound.vue': () => Promise.resolve().then(function () { return _404NotFound$1 }), '../components/AsyncComponent/AsyncComponent.vue': () => Promise.resolve().then(function () { return AsyncComponent }), '../components/DialogPage/DialogPage.vue': () => Promise.resolve().then(function () { return DialogPage$2 }), '../components/EllipsisTooltip/EllipsisTooltip.vue': () => Promise.resolve().then(function () { return EllipsisTooltip$1 }), '../components/MiniPagesMenu/MiniPagesMenu.vue': () => Promise.resolve().then(function () { return MiniPagesMenu$1 }), '../components/TitleTooltip/TitleTooltip.vue': () => Promise.resolve().then(function () { return TitleTooltip }), '../components/VirtualKeyboard/VirtualKeyboard.vue': () => Promise.resolve().then(function () { return VirtualKeyboard$1 }), '../components/VirtualTree/TreeNode.vue': () => Promise.resolve().then(function () { return TreeNode$2 }), '../components/VirtualTree/VirtualTree.vue': () => Promise.resolve().then(function () { return VirtualTree$1 }), '../components/collapse/collapse.vue': () => Promise.resolve().then(function () { return collapse$1 }), '../components/component-styles/module-appearance.vue': () => Promise.resolve().then(function () { return moduleAppearance$1 }), '../components/component-styles/module-function.vue': () => Promise.resolve().then(function () { return moduleFunction$1 }), '../components/component-styles/module-opacity.vue': () => Promise.resolve().then(function () { return moduleOpacity$1 }), '../components/component-styles/module-permission.vue': () => Promise.resolve().then(function () { return modulePermission$1 }), '../components/component-styles/module-position.vue': () => Promise.resolve().then(function () { return modulePosition$1 }), '../components/component-styles/module-text.vue': () => Promise.resolve().then(function () { return moduleText$1 }), '../components/component-styles/module-title.vue': () => Promise.resolve().then(function () { return moduleTitle$1 }), '../components/gallery/GalleryMaterial.vue': () => Promise.resolve().then(function () { return GalleryMaterial$1 }), '../components/gallery/OfficialMaterial.vue': () => Promise.resolve().then(function () { return OfficialMaterial$1 }), '../components/gallery/gallery.vue': () => Promise.resolve().then(function () { return gallery }), '../views/Frame/Frame.vue': () => Promise.resolve().then(function () { return Frame$1 }), '../views/Frame/Header.vue': () => Promise.resolve().then(function () { return Header$5 }), '../views/Project/Project.vue': () => Promise.resolve().then(function () { return Project$1 }), '../views/Projects/Projects.vue': () => Promise.resolve().then(function () { return Projects$1 }), '../views/Run/Run.vue': () => Promise.resolve().then(function () { return Run$1 }), '../views/picture-management/index.vue': () => Promise.resolve().then(function () { return index$a }), '../components/component-styles/function-dialogs/function-dialog-btn.vue': () => Promise.resolve().then(function () { return functionDialogBtn$1 }), '../components/component-styles/function-dialogs/function-dialog-variate.vue': () => Promise.resolve().then(function () { return functionDialogVariate }), '../components/component-styles/function-dialogs/function-dialog.vue': () => Promise.resolve().then(function () { return functionDialog$1 }), '../components/component-styles/function-items/function-input-precision.vue': () => Promise.resolve().then(function () { return functionInputPrecision }), '../components/component-styles/function-items/function-input-range.vue': () => Promise.resolve().then(function () { return functionInputRange }), '../components/component-styles/function-items/function-jump-page.vue': () => Promise.resolve().then(function () { return functionJumpPage }), '../components/component-styles/function-items/function-popup.vue': () => Promise.resolve().then(function () { return functionPopup$1 }), '../components/component-styles/function-items/function-relate-variable.vue': () => Promise.resolve().then(function () { return functionRelateVariable }), '../components/component-styles/function-items/function-send-variable.vue': () => Promise.resolve().then(function () { return functionSendVariable$1 }), '../components/component-styles/function-items/function-show-dialog.vue': () => Promise.resolve().then(function () { return functionShowDialog }), '../components/component-styles/function-items/function-tree.vue': () => Promise.resolve().then(function () { return functionTree$1 }), '../components/gallery/component/PanelLayout.vue': () => Promise.resolve().then(function () { return PanelLayout$3 }), '../components/picture-management/picture-production/component-event.vue': () => Promise.resolve().then(function () { return componentEvent }), '../components/picture-management/picture-production/component-object.vue': () => Promise.resolve().then(function () { return componentObject }), '../components/picture-management/picture-production/component-style.vue': () => Promise.resolve().then(function () { return componentStyle }), '../components/picture-management/picture-production/drag-choose-component-box.vue': () => Promise.resolve().then(function () { return dragChooseComponentBox$1 }), '../components/picture-management/picture-production/picture-header.vue': () => Promise.resolve().then(function () { return pictureHeader }), '../components/picture-management/picture-production/project-page.vue': () => Promise.resolve().then(function () { return projectPage }), '../components/picture-management/variable-management/add-device-form.vue': () => Promise.resolve().then(function () { return addDeviceForm }), '../components/picture-management/variable-management/add-device-group-form.vue': () => Promise.resolve().then(function () { return addDeviceGroupForm }), '../components/picture-management/variable-management/address-config.vue': () => Promise.resolve().then(function () { return addressConfig }), '../components/picture-management/variable-management/associated-variable.vue': () => Promise.resolve().then(function () { return associatedVariable }), '../components/picture-management/variable-management/compoment-table-inner.vue': () => Promise.resolve().then(function () { return compomentTableInner }), '../components/picture-management/variable-management/compoment-table.vue': () => Promise.resolve().then(function () { return compomentTable }), '../components/picture-management/variable-management/compoment-ztree-inner.vue': () => Promise.resolve().then(function () { return compomentZtreeInner }), '../components/picture-management/variable-management/compoment-ztree.vue': () => Promise.resolve().then(function () { return compomentZtree }), '../components/picture-management/variable-management/history-archive.vue': () => Promise.resolve().then(function () { return historyArchive }), '../views/Project/Alarm/Alarm.vue': () => Promise.resolve().then(function () { return Alarm$1 }), '../views/Project/Basis/Basis.vue': () => Promise.resolve().then(function () { return Basis$1 }), '../views/Project/Connection/Connection.vue': () => Promise.resolve().then(function () { return Connection$1 }), '../views/Project/Data/Data.vue': () => Promise.resolve().then(function () { return Data$1 }), '../views/Project/History/History.vue': () => Promise.resolve().then(function () { return History$3 }), '../views/Project/Lang/Lang.vue': () => Promise.resolve().then(function () { return Lang$1 }), '../views/Project/Pages/Pages.vue': () => Promise.resolve().then(function () { return Pages$1 }), '../views/Project/Vars/Vars.vue': () => Promise.resolve().then(function () { return Vars$1 }), '../views/Projects/components/BackupDialog.vue': () => Promise.resolve().then(function () { return BackupDialog$1 }), '../views/Projects/components/CreateProjectDialog.vue': () => Promise.resolve().then(function () { return CreateProjectDialog$1 }), '../views/Projects/components/HandleProjectConflict.vue': () => Promise.resolve().then(function () { return HandleProjectConflict$1 }), '../views/Projects/components/ModifyLevel.vue': () => Promise.resolve().then(function () { return ModifyLevel$1 }), '../views/Projects/components/RecoveryDataDialog.vue': () => Promise.resolve().then(function () { return RecoveryDataDialog$1 }), '../views/Projects/components/RenameDialog.vue': () => Promise.resolve().then(function () { return RenameDialog$1 }), '../views/Projects/components/TipDialog.vue': () => Promise.resolve().then(function () { return TipDialog$1 }), '../views/Projects/components/VersionUpdate.vue': () => Promise.resolve().then(function () { return VersionUpdate$1 }), '../views/Projects/components/createFolderDialog.vue': () => Promise.resolve().then(function () { return createFolderDialog }), '../views/Run/AuthorizeInfo/AuthorizeInfo.vue': () => Promise.resolve().then(function () { return AuthorizeInfo$1 }), '../views/Run/AuthorizeInfo/UnauthorizedLabel.vue': () => Promise.resolve().then(function () { return UnauthorizedLabel$1 }), '../views/Run/Menu/Menu.vue': () => Promise.resolve().then(function () { return Menu$1 }), '../views/Run/RunSetting/RunSetting.vue': () => Promise.resolve().then(function () { return RunSetting$1 }), '../views/picture-management/picture-production/index.vue': () => Promise.resolve().then(function () { return index$7 }), '../views/picture-management/resources-management/index.vue': () => Promise.resolve().then(function () { return index$5 }), '../views/picture-management/variable-management/index.vue': () => Promise.resolve().then(function () { return index$3 }), '../components/picture-management/picture-production/component-box/index.vue': () => Promise.resolve().then(function () { return index$8 }), '../views/Project/Alarm/Sidebar/Sidebar.vue': () => Promise.resolve().then(function () { return Sidebar$1 }), '../views/Project/Alarm/components/AlarmTable.vue': () => Promise.resolve().then(function () { return AlarmTable$1 }), '../views/Project/Alarm/components/SelectAlarmTypes.vue': () => Promise.resolve().then(function () { return SelectAlarmTypes$1 }), '../views/Project/Basis/Classes/Classes.vue': () => Promise.resolve().then(function () { return Classes$1 }), '../views/Project/Connection/EditorForm/ChoiceField.vue': () => Promise.resolve().then(function () { return ChoiceField$2 }), '../views/Project/Connection/EditorForm/ChoiceFieldDialog.vue': () => Promise.resolve().then(function () { return ChoiceFieldDialog$1 }), '../views/Project/Connection/EditorForm/EditorForm.vue': () => Promise.resolve().then(function () { return EditorForm$1 }), '../views/Project/Connection/EditorForm/Filter.vue': () => Promise.resolve().then(function () { return Filter }), '../views/Project/Connection/EditorForm/MappingTable.vue': () => Promise.resolve().then(function () { return MappingTable }), '../views/Project/Connection/EditorForm/Sort.vue': () => Promise.resolve().then(function () { return Sort }), '../views/Project/Connection/EditorForm/TriggerSetting.vue': () => Promise.resolve().then(function () { return TriggerSetting$2 }), '../views/Project/Connection/EditorForm/TriggerSettingConfig.vue': () => Promise.resolve().then(function () { return TriggerSettingConfig$1 }), '../views/Project/Connection/EditorForm/VarTable.vue': () => Promise.resolve().then(function () { return VarTable }), '../views/Project/Connection/EditorForm/dataBaseTable.vue': () => Promise.resolve().then(function () { return dataBaseTable }), '../views/Project/Connection/EditorTable/EditorTable.vue': () => Promise.resolve().then(function () { return EditorTable$1 }), '../views/Project/Connection/Sidebar/Sidebar.vue': () => Promise.resolve().then(function () { return Sidebar$5 }), '../views/Project/Data/DataAggregation/DataAggregation.vue': () => Promise.resolve().then(function () { return DataAggregation }), '../views/Project/Data/Sidebar/Sidebar.vue': () => Promise.resolve().then(function () { return Sidebar$3 }), '../views/Project/Data/VariableTag/VariableTag.vue': () => Promise.resolve().then(function () { return VariableTag }), '../views/Project/Data/components/Header.vue': () => Promise.resolve().then(function () { return Header$1 }), '../views/Project/History/Dialog/HistoryConfig.vue': () => Promise.resolve().then(function () { return HistoryConfig }), '../views/Project/History/Dialog/MoveFolder.vue': () => Promise.resolve().then(function () { return MoveFolder$1 }), '../views/Project/History/Dialog/StorageSet.vue': () => Promise.resolve().then(function () { return StorageSet }), '../views/Project/History/Dialog/Tip.vue': () => Promise.resolve().then(function () { return Tip }), '../views/Project/History/HistoryList/HistoryList.vue': () => Promise.resolve().then(function () { return HistoryList$1 }), '../views/Project/History/Table/Table.vue': () => Promise.resolve().then(function () { return Table$1 }), '../views/Project/History/components/DataBackup.vue': () => Promise.resolve().then(function () { return DataBackup }), '../views/Project/History/components/HistoryDialog.vue': () => Promise.resolve().then(function () { return HistoryDialog }), '../views/Project/History/components/TriggerFrequency.vue': () => Promise.resolve().then(function () { return TriggerFrequency$3 }), '../views/Project/Lang/ContentTable/ContentTable.vue': () => Promise.resolve().then(function () { return ContentTable$1 }), '../views/Project/Lang/Sidebar/Sidebar.vue': () => Promise.resolve().then(function () { return Sidebar$7 }), '../views/Project/Pages/Editor/Editor.vue': () => Promise.resolve().then(function () { return Editor$1 }), '../views/Project/Pages/Sidebar/Sidebar.vue': () => Promise.resolve().then(function () { return Sidebar$9 }), '../views/Project/Pages/Viewer/Viewer.vue': () => Promise.resolve().then(function () { return Viewer$1 }), '../views/Project/Vars/Header/Header.vue': () => Promise.resolve().then(function () { return Header$3 }), '../views/Project/Vars/Sidebar/Sidebar.vue': () => Promise.resolve().then(function () { return Sidebar$b }), '../views/Project/Vars/Table/Table.vue': () => Promise.resolve().then(function () { return Table$3 }), '../views/Project/Vars/components/ReadWriteInput.vue': () => Promise.resolve().then(function () { return ReadWriteInput$1 }), '../views/Project/Vars/components/VarReferenceConfig.vue': () => Promise.resolve().then(function () { return VarReferenceConfig$1 }), '../views/Run/Menu/Login/Login.vue': () => Promise.resolve().then(function () { return Login$1 }), '../views/Run/Menu/User/User.vue': () => Promise.resolve().then(function () { return User$1 }), '../components/picture-management/picture-production/component-box/component/default-module.vue': () => Promise.resolve().then(function () { return defaultModule }), '../components/picture-management/picture-production/component-box/component/run-module.vue': () => Promise.resolve().then(function () { return runModule$1 }), '../components/picture-management/picture-production/component-box/component/standard-controls.vue': () => Promise.resolve().then(function () { return standardControls }), '../views/Project/Alarm/Sidebar/components/AlarmLevelsConf.vue': () => Promise.resolve().then(function () { return AlarmLevelsConf$1 }), '../views/Project/Alarm/Sidebar/components/AlarmRecordsConf.vue': () => Promise.resolve().then(function () { return AlarmRecordsConf$1 }), '../views/Project/Alarm/Sidebar/components/AlarmTypeConf.vue': () => Promise.resolve().then(function () { return AlarmTypeConf$1 }), '../views/Project/Alarm/Sidebar/components/AlarmTypesConf.vue': () => Promise.resolve().then(function () { return AlarmTypesConf$1 }), '../views/Project/Alarm/Sidebar/components/SheetCreateDialog.vue': () => Promise.resolve().then(function () { return SheetCreateDialog$1 }), '../views/Project/Connection/EditorTable/components/ModifyRowsConfig.vue': () => Promise.resolve().then(function () { return ModifyRowsConfig$1 }), '../views/Project/Connection/Sidebar/components/CreateConnection.vue': () => Promise.resolve().then(function () { return CreateConnection$1 }), '../views/Project/Connection/Sidebar/components/CreateData.vue': () => Promise.resolve().then(function () { return CreateData }), '../views/Project/Connection/Sidebar/components/SqlConfigDialog.vue': () => Promise.resolve().then(function () { return SqlConfigDialog$1 }), '../views/Project/Connection/Sidebar/components/databaseConfig.vue': () => Promise.resolve().then(function () { return databaseConfig$1 }), '../views/Project/Connection/Sidebar/components/previewDatabaseTable.vue': () => Promise.resolve().then(function () { return previewDatabaseTable }), '../views/Project/Connection/Sidebar/components/selectDataTable.vue': () => Promise.resolve().then(function () { return selectDataTable$1 }), '../views/Project/Data/DataAggregation/components/ChoiceField.vue': () => Promise.resolve().then(function () { return ChoiceField$1 }), '../views/Project/Data/DataAggregation/components/FieldConfig.vue': () => Promise.resolve().then(function () { return FieldConfig$1 }), '../views/Project/Data/DataAggregation/components/FilterConditions.vue': () => Promise.resolve().then(function () { return FilterConditions$1 }), '../views/Project/Data/DataAggregation/components/TriggerConfig.vue': () => Promise.resolve().then(function () { return TriggerConfig$1 }), '../views/Project/Data/Sidebar/components/SheetCreateDialog.vue': () => Promise.resolve().then(function () { return SheetCreateDialog$3 }), '../views/Project/Data/VariableTag/components/ExpConfigDialog.vue': () => Promise.resolve().then(function () { return ExpConfigDialog$4 }), '../views/Project/Data/VariableTag/components/FieldType.vue': () => Promise.resolve().then(function () { return FieldType$1 }), '../views/Project/Data/VariableTag/components/FormulaConfigDialog.vue': () => Promise.resolve().then(function () { return FormulaConfigDialog$1 }), '../views/Project/Data/VariableTag/components/InputCode.vue': () => Promise.resolve().then(function () { return InputCode$1 }), '../views/Project/Data/VariableTag/components/RelevanceButton.vue': () => Promise.resolve().then(function () { return RelevanceButton$1 }), '../views/Project/Data/VariableTag/components/TriggerFrequency.vue': () => Promise.resolve().then(function () { return TriggerFrequency$1 }), '../views/Project/Data/VariableTag/components/TriggerSetting.vue': () => Promise.resolve().then(function () { return TriggerSetting$1 }), '../views/Project/Data/VariableTag/components/cacheSetting.vue': () => Promise.resolve().then(function () { return cacheSetting }), '../views/Project/Data/VariableTag/components/noDataButton.vue': () => Promise.resolve().then(function () { return noDataButton$1 }), '../views/Project/Data/VariableTag/components/storageSetting.vue': () => Promise.resolve().then(function () { return storageSetting$1 }), '../views/Project/Lang/ContentTable/components/ExportFile.vue': () => Promise.resolve().then(function () { return ExportFile }), '../views/Project/Lang/ContentTable/components/ImportFile.vue': () => Promise.resolve().then(function () { return ImportFile$1 }), '../views/Project/Lang/Sidebar/components/CmsSwitch.vue': () => Promise.resolve().then(function () { return CmsSwitch$1 }), '../views/Project/Lang/Sidebar/components/CreateDialog.vue': () => Promise.resolve().then(function () { return CreateDialog$1 }), '../views/Project/Pages/Editor/Board/Board.vue': () => Promise.resolve().then(function () { return Board$1 }), '../views/Project/Pages/Editor/Empty/Empty.vue': () => Promise.resolve().then(function () { return Empty$1 }), '../views/Project/Pages/Editor/Settings/Settings.vue': () => Promise.resolve().then(function () { return Settings$1 }), '../views/Project/Pages/Editor/Tab/Tab.vue': () => Promise.resolve().then(function () { return Tab$1 }), '../views/Project/Pages/Sidebar/CanvasNodeList/CanvasNodeList.vue': () => Promise.resolve().then(function () { return CanvasNodeList$1 }), '../views/Project/Pages/Sidebar/PageList/PageList.vue': () => Promise.resolve().then(function () { return PageList$1 }), '../views/Project/Vars/Header/components/Filter.vue': () => Promise.resolve().then(function () { return Filter$3 }), '../views/Project/Vars/Sidebar/components/IOTunnelDriveTree.vue': () => Promise.resolve().then(function () { return IOTunnelDriveTree$1 }), '../views/Project/Vars/Sidebar/components/IOTunnelOperate.vue': () => Promise.resolve().then(function () { return IOTunnelOperate }), '../views/Project/Vars/Sidebar/components/InnerTunnelOperate.vue': () => Promise.resolve().then(function () { return InnerTunnelOperate }), '../views/Project/Vars/Sidebar/components/SUBTunnelOperate.vue': () => Promise.resolve().then(function () { return SUBTunnelOperate }), '../views/Project/Vars/Sidebar/components/VarGroupOperate.vue': () => Promise.resolve().then(function () { return VarGroupOperate }), '../views/Project/Vars/Sidebar/components/VarNameConfig.vue': () => Promise.resolve().then(function () { return VarNameConfig }), '../views/Project/Vars/Table/components/ImportFile.vue': () => Promise.resolve().then(function () { return ImportFile$2 }), '../views/Project/Vars/Table/components/VarAddressConfig.vue': () => Promise.resolve().then(function () { return VarAddressConfig }), '../views/Project/Vars/Table/components/VarBatchCreate.vue': () => Promise.resolve().then(function () { return VarBatchCreate }), '../views/Project/Vars/Table/components/VarBatchIssue.vue': () => Promise.resolve().then(function () { return VarBatchIssue }), '../views/Project/Vars/Table/components/VarBatchModify.vue': () => Promise.resolve().then(function () { return VarBatchModify }), '../views/Project/Vars/Table/components/VarHistoricArchiveConfig.vue': () => Promise.resolve().then(function () { return VarHistoricArchiveConfig$1 }), '../views/Project/Vars/Table/components/VarReferenceListCheck.vue': () => Promise.resolve().then(function () { return VarReferenceListCheck }), '../views/Project/Pages/Editor/Board/ApplicationResource/ApplicationResource.vue': () => Promise.resolve().then(function () { return ApplicationResource$1 }), '../views/Project/Pages/Editor/Board/Canvas/Canvas.vue': () => Promise.resolve().then(function () { return Canvas$1 }), '../views/Project/Pages/Editor/Board/Canvas/CanvasNode.vue': () => Promise.resolve().then(function () { return CanvasNode }), '../views/Project/Pages/Editor/Board/History/History.vue': () => Promise.resolve().then(function () { return History$1 }), '../views/Project/Pages/Editor/Board/Selector/Resizer.vue': () => Promise.resolve().then(function () { return Resizer$1 }), '../views/Project/Pages/Editor/Board/Selector/Selected.vue': () => Promise.resolve().then(function () { return Selected$1 }), '../views/Project/Pages/Editor/Board/Selector/Selector.vue': () => Promise.resolve().then(function () { return Selector$1 }), '../views/Project/Pages/Editor/Board/Toolbar/LanguageSelect.vue': () => Promise.resolve().then(function () { return LanguageSelect$1 }), '../views/Project/Pages/Editor/Board/Toolbar/Toolbar.vue': () => Promise.resolve().then(function () { return Toolbar$1 }), '../views/Project/Pages/Editor/Board/Toolbar/ZoomSelect.vue': () => Promise.resolve().then(function () { return ZoomSelect$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/Icon.vue': () => Promise.resolve().then(function () { return Icon$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/WidgetLib.vue': () => Promise.resolve().then(function () { return WidgetLib$1 }), '../views/Project/Pages/Editor/Board/Zoom/Zoom.vue': () => Promise.resolve().then(function () { return Zoom$1 }), '../views/Project/Pages/Editor/Settings/Events/Events.vue': () => Promise.resolve().then(function () { return Events$1 }), '../views/Project/Pages/Editor/Settings/Style/Style.vue': () => Promise.resolve().then(function () { return Style$1 }), '../views/Project/Pages/Editor/Settings/WidgetSettings/InputSettings.vue': () => Promise.resolve().then(function () { return InputSettings$1 }), '../views/Project/Pages/Editor/Settings/WidgetSettings/Permission.vue': () => Promise.resolve().then(function () { return Permission$1 }), '../views/Project/Pages/Editor/Settings/WidgetSettings/WidgetSettings.vue': () => Promise.resolve().then(function () { return WidgetSettings$1 }), '../views/Project/Pages/Editor/Settings/components/SettingItem.vue': () => Promise.resolve().then(function () { return SettingItem$2 }), '../views/Project/Pages/Editor/Board/ApplicationResource/Panels/PanelContent.vue': () => Promise.resolve().then(function () { return PanelContent$1 }), '../views/Project/Pages/Editor/Board/ApplicationResource/Panels/PanelLayout.vue': () => Promise.resolve().then(function () { return PanelLayout$1 }), '../views/Project/Pages/Editor/Settings/Events/components/ActionPopover.vue': () => Promise.resolve().then(function () { return ActionPopover$1 }), '../views/Project/Pages/Editor/Settings/Events/components/ActionSetting.vue': () => Promise.resolve().then(function () { return ActionSetting$1 }), '../views/Project/Pages/Editor/Settings/Events/components/ActionTargetPopover.vue': () => Promise.resolve().then(function () { return ActionTargetPopover$1 }), '../views/Project/Pages/Editor/Settings/Events/components/AlarmRecoverySetting.vue': () => Promise.resolve().then(function () { return AlarmRecoverySetting$1 }), '../views/Project/Pages/Editor/Settings/Events/components/AlarmSetting.vue': () => Promise.resolve().then(function () { return AlarmSetting$1 }), '../views/Project/Pages/Editor/Settings/Events/components/ConditionSetting.vue': () => Promise.resolve().then(function () { return ConditionSetting$1 }), '../views/Project/Pages/Editor/Settings/Events/components/EventPopover.vue': () => Promise.resolve().then(function () { return EventPopover$1 }), '../views/Project/Pages/Editor/Settings/Events/components/EventSettings.vue': () => Promise.resolve().then(function () { return EventSettings }), '../views/Project/Pages/Editor/Settings/Events/components/ExpConfigDialog.vue': () => Promise.resolve().then(function () { return ExpConfigDialog$3 }), '../views/Project/Pages/Editor/Settings/Events/components/Footer.vue': () => Promise.resolve().then(function () { return Footer$1 }), '../views/Project/Pages/Editor/Settings/Events/components/OnBroadcastSetting.vue': () => Promise.resolve().then(function () { return OnBroadcastSetting$1 }), '../views/Project/Pages/Editor/Settings/Events/components/Popover.vue': () => Promise.resolve().then(function () { return Popover$1 }), '../views/Project/Pages/Editor/Settings/Events/components/TimerSetting.vue': () => Promise.resolve().then(function () { return TimerSetting$1 }), '../views/Project/Pages/Editor/Settings/Events/components/VarConditionConfig.vue': () => Promise.resolve().then(function () { return VarConditionConfig$1 }), '../views/Project/Pages/Editor/Settings/Style/components/AppearanceSettings.vue': () => Promise.resolve().then(function () { return AppearanceSettings$1 }), '../views/Project/Pages/Editor/Settings/Style/components/BackgroundImageSetting.vue': () => Promise.resolve().then(function () { return BackgroundImageSetting$1 }), '../views/Project/Pages/Editor/Settings/Style/components/TextSettings.vue': () => Promise.resolve().then(function () { return TextSettings$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/A/A.settings.vue': () => Promise.resolve().then(function () { return __glob_2_0$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/A/A.vue': () => Promise.resolve().then(function () { return __glob_2_1$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Button/Button.settings.vue': () => Promise.resolve().then(function () { return __glob_2_2$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Button/Button.vue': () => Promise.resolve().then(function () { return __glob_2_3$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/Chart.settings.vue': () => Promise.resolve().then(function () { return __glob_2_4$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/Chart.vue': () => Promise.resolve().then(function () { return __glob_2_5$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartBar/ChartBar.settings.vue': () => Promise.resolve().then(function () { return __glob_2_6$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartBar/ChartBar.vue': () => Promise.resolve().then(function () { return __glob_2_7$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartBar/SetChart.vue': () => Promise.resolve().then(function () { return __glob_2_8$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartBarHorizontal/ChartBarHorizontal.settings.vue': () => Promise.resolve().then(function () { return __glob_2_9$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartBarHorizontal/ChartBarHorizontal.vue': () => Promise.resolve().then(function () { return __glob_2_10 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartBarHorizontalStacked/ChartBarHorizontalStacked.settings.vue': () => Promise.resolve().then(function () { return __glob_2_11 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartBarHorizontalStacked/ChartBarHorizontalStacked.vue': () => Promise.resolve().then(function () { return __glob_2_12 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartBarStacked/ChartBarStacked.settings.vue': () => Promise.resolve().then(function () { return __glob_2_13 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartBarStacked/ChartBarStacked.vue': () => Promise.resolve().then(function () { return __glob_2_14 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartCard/ChartCard.settings.vue': () => Promise.resolve().then(function () { return __glob_2_15 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartCard/ChartCard.vue': () => Promise.resolve().then(function () { return __glob_2_16 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLine/ChartLine.settings.vue': () => Promise.resolve().then(function () { return __glob_2_17 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLine/ChartLine.vue': () => Promise.resolve().then(function () { return __glob_2_18 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLine/SetChart.vue': () => Promise.resolve().then(function () { return __glob_2_19 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineArea/ChartLineArea.settings.vue': () => Promise.resolve().then(function () { return __glob_2_20 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineArea/ChartLineArea.vue': () => Promise.resolve().then(function () { return __glob_2_21 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineAreaStacked/ChartLineAreaStacked.settings.vue': () => Promise.resolve().then(function () { return __glob_2_22 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineAreaStacked/ChartLineAreaStacked.vue': () => Promise.resolve().then(function () { return __glob_2_23 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrend/Chart.vue': () => Promise.resolve().then(function () { return __glob_2_24 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrend/ChartLineTrend.settings.vue': () => Promise.resolve().then(function () { return __glob_2_25 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrend/ChartLineTrend.vue': () => Promise.resolve().then(function () { return __glob_2_26 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrendConfig/ChartLineTrendConfig.settings.vue': () => Promise.resolve().then(function () { return __glob_2_27 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrendConfig/ChartLineTrendConfig.vue': () => Promise.resolve().then(function () { return __glob_2_28 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartMixed/ChartMixed.settings.vue': () => Promise.resolve().then(function () { return __glob_2_29 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartMixed/ChartMixed.vue': () => Promise.resolve().then(function () { return __glob_2_30 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartPie/ChartPie.settings.vue': () => Promise.resolve().then(function () { return __glob_2_31 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartPie/ChartPie.vue': () => Promise.resolve().then(function () { return __glob_2_32 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartPie/Label.vue': () => Promise.resolve().then(function () { return __glob_2_33 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartPie/SetChart.vue': () => Promise.resolve().then(function () { return __glob_2_34 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartPieRing/ChartPieRing.settings.vue': () => Promise.resolve().then(function () { return __glob_2_35 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartPieRing/ChartPieRing.vue': () => Promise.resolve().then(function () { return __glob_2_36 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartPieRing/SetChart.vue': () => Promise.resolve().then(function () { return __glob_2_37 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartPieRose/ChartPieRose.settings.vue': () => Promise.resolve().then(function () { return __glob_2_38 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartPieRose/ChartPieRose.vue': () => Promise.resolve().then(function () { return __glob_2_39 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartTable/ChartTable.settings.vue': () => Promise.resolve().then(function () { return __glob_2_40 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartTable/ChartTable.vue': () => Promise.resolve().then(function () { return __glob_2_41 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Circle/Circle.settings.vue': () => Promise.resolve().then(function () { return __glob_2_42 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Circle/Circle.vue': () => Promise.resolve().then(function () { return __glob_2_43 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ControlButton/ControlButton.settings.vue': () => Promise.resolve().then(function () { return __glob_2_44 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ControlButton/ControlButton.vue': () => Promise.resolve().then(function () { return __glob_2_45 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DateRange/DateRange.settings.vue': () => Promise.resolve().then(function () { return __glob_2_46 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DateRange/DateRange.vue': () => Promise.resolve().then(function () { return __glob_2_47 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropDownList/DropDownList.settings.vue': () => Promise.resolve().then(function () { return __glob_2_48 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropDownList/DropDownList.vue': () => Promise.resolve().then(function () { return __glob_2_49 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropdownMenu/DropdownMenu.settings.vue': () => Promise.resolve().then(function () { return __glob_2_50 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropdownMenu/DropdownMenu.vue': () => Promise.resolve().then(function () { return __glob_2_51 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropdownMenuVertical/DropdownMenuVertical.settings.vue': () => Promise.resolve().then(function () { return __glob_2_52 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropdownMenuVertical/DropdownMenuVertical.vue': () => Promise.resolve().then(function () { return __glob_2_53 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropdownMenuVertical2/DropdownMenuVertical2.settings.vue': () => Promise.resolve().then(function () { return __glob_2_54 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropdownMenuVertical2/DropdownMenuVertical2.vue': () => Promise.resolve().then(function () { return __glob_2_55 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Dynamic/Dynamic.settings.vue': () => Promise.resolve().then(function () { return __glob_2_56 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DynamicCircle/DynamicCircle.settings.vue': () => Promise.resolve().then(function () { return __glob_2_57 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DynamicCircle/DynamicCircle.vue': () => Promise.resolve().then(function () { return __glob_2_58 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DynamicImg/DynamicImg.settings.vue': () => Promise.resolve().then(function () { return __glob_2_59 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DynamicImg/DynamicImg.vue': () => Promise.resolve().then(function () { return __glob_2_60 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DynamicRect/DynamicRect.settings.vue': () => Promise.resolve().then(function () { return __glob_2_61 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DynamicRect/DynamicRect.vue': () => Promise.resolve().then(function () { return __glob_2_62 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DynamicText/DynamicText.settings.vue': () => Promise.resolve().then(function () { return __glob_2_63 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DynamicText/DynamicText.vue': () => Promise.resolve().then(function () { return __glob_2_64 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Exp/Exp.settings.vue': () => Promise.resolve().then(function () { return __glob_2_65 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Exp/Exp.vue': () => Promise.resolve().then(function () { return __glob_2_66 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ExportButton/ExportButton.settings.vue': () => Promise.resolve().then(function () { return __glob_2_67 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ExportButton/ExportButton.vue': () => Promise.resolve().then(function () { return __glob_2_68 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Group/Group.settings.vue': () => Promise.resolve().then(function () { return __glob_2_69 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Group/Group.vue': () => Promise.resolve().then(function () { return __glob_2_70 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Img/Img.settings.vue': () => Promise.resolve().then(function () { return __glob_2_71 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Img/Img.vue': () => Promise.resolve().then(function () { return __glob_2_72 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Input/Input.settings.vue': () => Promise.resolve().then(function () { return __glob_2_73 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Input/Input.vue': () => Promise.resolve().then(function () { return __glob_2_74 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/JogButton/JogButton.settings.vue': () => Promise.resolve().then(function () { return __glob_2_75 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/JogButton/JogButton.vue': () => Promise.resolve().then(function () { return __glob_2_76 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/JumpButton/JumpButton.settings.vue': () => Promise.resolve().then(function () { return __glob_2_77 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/JumpButton/JumpButton.vue': () => Promise.resolve().then(function () { return __glob_2_78 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Language/Language.settings.vue': () => Promise.resolve().then(function () { return __glob_2_79 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Language/Language.vue': () => Promise.resolve().then(function () { return __glob_2_80 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Line/Line.settings.vue': () => Promise.resolve().then(function () { return __glob_2_81 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Line/Line.vue': () => Promise.resolve().then(function () { return __glob_2_82 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/LogManage/LogManage.settings.vue': () => Promise.resolve().then(function () { return __glob_2_83 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/LogManage/LogManage.vue': () => Promise.resolve().then(function () { return __glob_2_84 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Login/Login.settings.vue': () => Promise.resolve().then(function () { return __glob_2_85 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Login/Login.vue': () => Promise.resolve().then(function () { return __glob_2_86 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/NumberFilter/NumberFilter.settings.vue': () => Promise.resolve().then(function () { return __glob_2_87 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/NumberFilter/NumberFilter.vue': () => Promise.resolve().then(function () { return __glob_2_88 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/NumberInput/NumberInput.settings.vue': () => Promise.resolve().then(function () { return __glob_2_89 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/NumberInput/NumberInput.vue': () => Promise.resolve().then(function () { return __glob_2_90 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/NumberShow/NumberShow.settings.vue': () => Promise.resolve().then(function () { return __glob_2_91 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/NumberShow/NumberShow.vue': () => Promise.resolve().then(function () { return __glob_2_92 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PageFrame/PageFrame.settings.vue': () => Promise.resolve().then(function () { return __glob_2_93 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PageFrame/PageFrame.vue': () => Promise.resolve().then(function () { return __glob_2_94 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PageList/PageList.settings.vue': () => Promise.resolve().then(function () { return __glob_2_95 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PageList/PageList.vue': () => Promise.resolve().then(function () { return __glob_2_96 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PermissionManage/PermissionManage.settings.vue': () => Promise.resolve().then(function () { return __glob_2_97 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PermissionManage/PermissionManage.vue': () => Promise.resolve().then(function () { return __glob_2_98 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PopupWindowButton/PopupWindowButton.settings.vue': () => Promise.resolve().then(function () { return __glob_2_99 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PopupWindowButton/PopupWindowButton.vue': () => Promise.resolve().then(function () { return __glob_2_100 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ReadWriteInput/ReadWriteInput.settings.vue': () => Promise.resolve().then(function () { return __glob_2_101 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ReadWriteInput/ReadWriteInput.vue': () => Promise.resolve().then(function () { return __glob_2_102 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Rect/Rect.settings.vue': () => Promise.resolve().then(function () { return __glob_2_103 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Rect/Rect.vue': () => Promise.resolve().then(function () { return __glob_2_104 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/RouterLink/RouterLink.settings.vue': () => Promise.resolve().then(function () { return __glob_2_105 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/RouterLink/RouterLink.vue': () => Promise.resolve().then(function () { return __glob_2_106 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ShutdownButton/ShutdownButton.settings.vue': () => Promise.resolve().then(function () { return __glob_2_107 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ShutdownButton/ShutdownButton.vue': () => Promise.resolve().then(function () { return __glob_2_108 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/StaticText/StaticText.settings.vue': () => Promise.resolve().then(function () { return __glob_2_109 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/StaticText/StaticText.vue': () => Promise.resolve().then(function () { return __glob_2_110 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/SwitchButton/SwitchButton.settings.vue': () => Promise.resolve().then(function () { return __glob_2_111 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/SwitchButton/SwitchButton.vue': () => Promise.resolve().then(function () { return __glob_2_112 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/TextInput/TextInput.settings.vue': () => Promise.resolve().then(function () { return __glob_2_113 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/TextInput/TextInput.vue': () => Promise.resolve().then(function () { return __glob_2_114 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/UserInformation/UserInformation.settings.vue': () => Promise.resolve().then(function () { return __glob_2_115 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/UserInformation/UserInformation.vue': () => Promise.resolve().then(function () { return __glob_2_116 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/VarList/VarList.settings.vue': () => Promise.resolve().then(function () { return __glob_2_117 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/VarList/VarList.vue': () => Promise.resolve().then(function () { return __glob_2_118 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/VirtualKeyboardButton/VirtualKeyboardButton.settings.vue': () => Promise.resolve().then(function () { return __glob_2_119 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/VirtualKeyboardButton/VirtualKeyboardButton.vue': () => Promise.resolve().then(function () { return __glob_2_120 }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/ExpConfigDialog.vue': () => Promise.resolve().then(function () { return ExpConfigDialog$1 }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/charts.vue': () => Promise.resolve().then(function () { return charts }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/checkbox.vue': () => Promise.resolve().then(function () { return checkbox }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/checkboxGroup.vue': () => Promise.resolve().then(function () { return checkboxGroup$1 }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/color.vue': () => Promise.resolve().then(function () { return color }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/currentPage.vue': () => Promise.resolve().then(function () { return currentPage }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/date.vue': () => Promise.resolve().then(function () { return date }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/file.vue': () => Promise.resolve().then(function () { return file }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/image.vue': () => Promise.resolve().then(function () { return image }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/number.vue': () => Promise.resolve().then(function () { return number$1 }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/page.vue': () => Promise.resolve().then(function () { return page }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/radio.vue': () => Promise.resolve().then(function () { return radio }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/select.vue': () => Promise.resolve().then(function () { return select }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/slide.vue': () => Promise.resolve().then(function () { return slide }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/text.vue': () => Promise.resolve().then(function () { return text }), '../views/Project/Pages/Editor/Settings/Events/components/argumentBlock/variableName.vue': () => Promise.resolve().then(function () { return variableName }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Button/settings/ConfirmBoxSetting.vue': () => Promise.resolve().then(function () { return ConfirmBoxSetting$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrendConfig/components/CurveAnalysis.vue': () => Promise.resolve().then(function () { return CurveAnalysis }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrendConfig/components/CurveDefine.vue': () => Promise.resolve().then(function () { return CurveDefine }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrendConfig/components/EditCurveGroup.vue': () => Promise.resolve().then(function () { return EditCurveGroup$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartTable/components/TableColumn.vue': () => Promise.resolve().then(function () { return TableColumn$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DateRange/controller/ControllerIcon.vue': () => Promise.resolve().then(function () { return ControllerIcon }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DateRange/controller/DateRangeIcon.vue': () => Promise.resolve().then(function () { return DateRangeIcon$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DateRange/settings/ControllerCharts.vue': () => Promise.resolve().then(function () { return ControllerCharts$5 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropdownMenu/components/function-tree.vue': () => Promise.resolve().then(function () { return functionTree$3 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropdownMenu/components/menu-style.vue': () => Promise.resolve().then(function () { return menuStyle }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropdownMenu/components/styleSetting.vue': () => Promise.resolve().then(function () { return styleSetting }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/DropdownMenu/components/type.vue': () => Promise.resolve().then(function () { return type }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Dynamic/components/Condition.vue': () => Promise.resolve().then(function () { return Condition$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Dynamic/components/StatusItem.vue': () => Promise.resolve().then(function () { return StatusItem$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ExportButton/settings/ControllerCharts.vue': () => Promise.resolve().then(function () { return ControllerCharts$3 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/LogManage/components/DeviceLog.vue': () => Promise.resolve().then(function () { return DeviceLog }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/LogManage/components/LoginLog.vue': () => Promise.resolve().then(function () { return LoginLog }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/LogManage/components/ModuleLog.vue': () => Promise.resolve().then(function () { return ModuleLog }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Login/components/Shadow.vue': () => Promise.resolve().then(function () { return Shadow$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Login/components/ShapeConfiguration.vue': () => Promise.resolve().then(function () { return ShapeConfiguration$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Login/components/TextConfiguration.vue': () => Promise.resolve().then(function () { return TextConfiguration$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PermissionManage/components/RoleManage.vue': () => Promise.resolve().then(function () { return RoleManage }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PermissionManage/components/UserManage.vue': () => Promise.resolve().then(function () { return UserManage }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/SwitchButton/components/Switch.vue': () => Promise.resolve().then(function () { return Switch$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/other/StyleConditionsDialog.vue': () => Promise.resolve().then(function () { return StyleConditionsDialog$2 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/Data.vue': () => Promise.resolve().then(function () { return Data$5 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/DataDimissions.vue': () => Promise.resolve().then(function () { return DataDimissions$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/DataFeildConfig.vue': () => Promise.resolve().then(function () { return DataFeildConfig$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/DataIndexes.vue': () => Promise.resolve().then(function () { return DataIndexes$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/DataZoom.vue': () => Promise.resolve().then(function () { return DataZoom$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/DataZoomConfig.vue': () => Promise.resolve().then(function () { return DataZoomConfig$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/Grid.vue': () => Promise.resolve().then(function () { return Grid$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/Label.vue': () => Promise.resolve().then(function () { return Label$2 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/Legend.vue': () => Promise.resolve().then(function () { return Legend$3 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/LegendColor.vue': () => Promise.resolve().then(function () { return LegendColor$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/MarkLineConfig.vue': () => Promise.resolve().then(function () { return MarkLineConfig$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/Padding.vue': () => Promise.resolve().then(function () { return Padding$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/QueryConditions.vue': () => Promise.resolve().then(function () { return QueryConditions$5 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/StyleConditions.vue': () => Promise.resolve().then(function () { return StyleConditions$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/Title.vue': () => Promise.resolve().then(function () { return Title$3 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/Toolbox.vue': () => Promise.resolve().then(function () { return Toolbox }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/Type.vue': () => Promise.resolve().then(function () { return Type$4 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/XAxis.vue': () => Promise.resolve().then(function () { return XAxis$3 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/YAxis.vue': () => Promise.resolve().then(function () { return YAxis$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/Chart/components/settings/_.vue': () => Promise.resolve().then(function () { return _ }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartCard/components/settings/Dialog.vue': () => Promise.resolve().then(function () { return Dialog$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartCard/components/settings/LabelSettings.vue': () => Promise.resolve().then(function () { return LabelSettings$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrend/components/settings/Legend.vue': () => Promise.resolve().then(function () { return Legend$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrend/components/settings/QueryConditions.vue': () => Promise.resolve().then(function () { return QueryConditions$3 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrend/components/settings/SetChart.vue': () => Promise.resolve().then(function () { return SetChart$3 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrend/components/settings/Toolbar.vue': () => Promise.resolve().then(function () { return Toolbar$5 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartLineTrend/components/settings/XAxis.vue': () => Promise.resolve().then(function () { return XAxis$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartTable/components/settings/Dialog.vue': () => Promise.resolve().then(function () { return Dialog$3 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/ChartTable/components/settings/HeaderSettingDialog.vue': () => Promise.resolve().then(function () { return HeaderSettingDialog$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PermissionManage/components/dialogs/ManageDialog.vue': () => Promise.resolve().then(function () { return ManageDialog }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PermissionManage/components/dialogs/ResetDialog.vue': () => Promise.resolve().then(function () { return ResetDialog$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PermissionManage/components/dialogs/RoleDialog.vue': () => Promise.resolve().then(function () { return RoleDialog$1 }), '../views/Project/Pages/Editor/Board/WidgetLib/widgets/PermissionManage/components/dialogs/UserDialog.vue': () => Promise.resolve().then(function () { return UserDialog }), } const sdk = { version: version$5, launch() { const vueApp = createApp$1(AppView) vueApp.use(draggable$1) vueApp.use(track) vueApp.use(directives) vueApp.use(router$1) vueApp.use(store$5) vueApp.use(useTable) vueApp.use(installer) vueApp.mixin({ beforeCreate() { Object.assign(this, { window, console, alert, }) }, }) vueApp.config.globalProperties.t = Language$1.t vueApp.config.globalProperties._t = Language$1._t vueApp.mount('#app') return vueApp }, models: models$1, importAsync(path) { const packPromise = packs[path] if (packPromise) return packPromise if (/\.vue$/i.test(path)) { const vuePath = path.replace(/^@\//, '') const module2 = modules[`../${vuePath}`] if (module2) { return defineAsyncComponent(module2) } else { throw new Error(`Not Found ${path}`) } } }, components: { SettingItem: _sfc_main$72, }, utils: { request, userInfo, openVariableDialog, }, lib: { Vue, ElementPlus: installer, useTable, }, packs, request, baseURL, userInfo, userBehaviorAnalysis, } window.sdk = sdk setTimeout(async () => { const projectId = sessionStorage.getItem('X-Project') const project = new Project$2({ id: projectId + '', }) app.current.project = project app.dataeventSocket = new Socket({ url: `/hubs/v1/dataevent`, name: '\u5168\u5C40\u4E8B\u4EF6', }) await app.dataeventSocket.start() await accessSocketInVision() models$1.Variable.start() }, 0) /*! @license DOMPurify 2.4.7 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/2.4.7/LICENSE */ function _typeof$2(obj) { '@babel/helpers - typeof' return ( (_typeof$2 = 'function' == typeof Symbol && 'symbol' == typeof Symbol.iterator ? function (obj2) { return typeof obj2 } : function (obj2) { return obj2 && 'function' == typeof Symbol && obj2.constructor === Symbol && obj2 !== Symbol.prototype ? 'symbol' : typeof obj2 }), _typeof$2(obj) ) } function _setPrototypeOf(o2, p2) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf2(o3, p3) { o3.__proto__ = p3 return o3 } return _setPrototypeOf(o2, p2) } function _isNativeReflectConstruct() { if (typeof Reflect === 'undefined' || !Reflect.construct) return false if (Reflect.construct.sham) return false if (typeof Proxy === 'function') return true try { Boolean.prototype.valueOf.call( Reflect.construct(Boolean, [], function () {}) ) return true } catch (e2) { return false } } function _construct(Parent, args, Class) { if (_isNativeReflectConstruct()) { _construct = Reflect.construct } else { _construct = function _construct2(Parent2, args2, Class2) { var a2 = [null] a2.push.apply(a2, args2) var Constructor = Function.bind.apply(Parent2, a2) var instance = new Constructor() if (Class2) _setPrototypeOf(instance, Class2.prototype) return instance } } return _construct.apply(null, arguments) } function _toConsumableArray(arr) { return ( _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread() ) } function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr) } function _iterableToArray(iter) { if ( (typeof Symbol !== 'undefined' && iter[Symbol.iterator] != null) || iter['@@iterator'] != null ) return Array.from(iter) } function _unsupportedIterableToArray(o2, minLen) { if (!o2) return if (typeof o2 === 'string') return _arrayLikeToArray(o2, minLen) var n2 = Object.prototype.toString.call(o2).slice(8, -1) if (n2 === 'Object' && o2.constructor) n2 = o2.constructor.name if (n2 === 'Map' || n2 === 'Set') return Array.from(o2) if (n2 === 'Arguments' || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n2)) return _arrayLikeToArray(o2, minLen) } function _arrayLikeToArray(arr, len2) { if (len2 == null || len2 > arr.length) len2 = arr.length for (var i2 = 0, arr2 = new Array(len2); i2 < len2; i2++) arr2[i2] = arr[i2] return arr2 } function _nonIterableSpread() { throw new TypeError( 'Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.' ) } var hasOwnProperty$c = Object.hasOwnProperty, setPrototypeOf$2 = Object.setPrototypeOf, isFrozen = Object.isFrozen, getPrototypeOf$2 = Object.getPrototypeOf, getOwnPropertyDescriptor$5 = Object.getOwnPropertyDescriptor var freeze = Object.freeze, seal = Object.seal, create$6 = Object.create var _ref = typeof Reflect !== 'undefined' && Reflect, apply$5 = _ref.apply, construct$1 = _ref.construct if (!apply$5) { apply$5 = function apply2(fun, thisValue, args) { return fun.apply(thisValue, args) } } if (!freeze) { freeze = function freeze2(x2) { return x2 } } if (!seal) { seal = function seal2(x2) { return x2 } } if (!construct$1) { construct$1 = function construct2(Func, args) { return _construct(Func, _toConsumableArray(args)) } } var arrayForEach = unapply(Array.prototype.forEach) var arrayPop = unapply(Array.prototype.pop) var arrayPush$3 = unapply(Array.prototype.push) var stringToLowerCase = unapply(String.prototype.toLowerCase) var stringToString = unapply(String.prototype.toString) var stringMatch = unapply(String.prototype.match) var stringReplace = unapply(String.prototype.replace) var stringIndexOf$2 = unapply(String.prototype.indexOf) var stringTrim$1 = unapply(String.prototype.trim) var regExpTest = unapply(RegExp.prototype.test) var typeErrorCreate = unconstruct(TypeError) function unapply(func) { return function (thisArg) { for ( var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++ ) { args[_key - 1] = arguments[_key] } return apply$5(func, thisArg, args) } } function unconstruct(func) { return function () { for ( var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++ ) { args[_key2] = arguments[_key2] } return construct$1(func, args) } } function addToSet(set2, array4, transformCaseFunc) { var _transformCaseFunc transformCaseFunc = (_transformCaseFunc = transformCaseFunc) !== null && _transformCaseFunc !== void 0 ? _transformCaseFunc : stringToLowerCase if (setPrototypeOf$2) { setPrototypeOf$2(set2, null) } var l2 = array4.length while (l2--) { var element = array4[l2] if (typeof element === 'string') { var lcElement = transformCaseFunc(element) if (lcElement !== element) { if (!isFrozen(array4)) { array4[l2] = lcElement } element = lcElement } } set2[element] = true } return set2 } function clone$6(object4) { var newObject = create$6(null) var property2 for (property2 in object4) { if (apply$5(hasOwnProperty$c, object4, [property2]) === true) { newObject[property2] = object4[property2] } } return newObject } function lookupGetter(object4, prop) { while (object4 !== null) { var desc = getOwnPropertyDescriptor$5(object4, prop) if (desc) { if (desc.get) { return unapply(desc.get) } if (typeof desc.value === 'function') { return unapply(desc.value) } } object4 = getPrototypeOf$2(object4) } function fallbackValue(element) { console.warn('fallback value for', element) return null } return fallbackValue } var html$1$1 = freeze([ 'a', 'abbr', 'acronym', 'address', 'area', 'article', 'aside', 'audio', 'b', 'bdi', 'bdo', 'big', 'blink', 'blockquote', 'body', 'br', 'button', 'canvas', 'caption', 'center', 'cite', 'code', 'col', 'colgroup', 'content', 'data', 'datalist', 'dd', 'decorator', 'del', 'details', 'dfn', 'dialog', 'dir', 'div', 'dl', 'dt', 'element', 'em', 'fieldset', 'figcaption', 'figure', 'font', 'footer', 'form', 'h1', 'h2', 'h3', 'h4', 'h5', 'h6', 'head', 'header', 'hgroup', 'hr', 'html', 'i', 'img', 'input', 'ins', 'kbd', 'label', 'legend', 'li', 'main', 'map', 'mark', 'marquee', 'menu', 'menuitem', 'meter', 'nav', 'nobr', 'ol', 'optgroup', 'option', 'output', 'p', 'picture', 'pre', 'progress', 'q', 'rp', 'rt', 'ruby', 's', 'samp', 'section', 'select', 'shadow', 'small', 'source', 'spacer', 'span', 'strike', 'strong', 'style', 'sub', 'summary', 'sup', 'table', 'tbody', 'td', 'template', 'textarea', 'tfoot', 'th', 'thead', 'time', 'tr', 'track', 'tt', 'u', 'ul', 'var', 'video', 'wbr', ]) var svg$1 = freeze([ 'svg', 'a', 'altglyph', 'altglyphdef', 'altglyphitem', 'animatecolor', 'animatemotion', 'animatetransform', 'circle', 'clippath', 'defs', 'desc', 'ellipse', 'filter', 'font', 'g', 'glyph', 'glyphref', 'hkern', 'image', 'line', 'lineargradient', 'marker', 'mask', 'metadata', 'mpath', 'path', 'pattern', 'polygon', 'polyline', 'radialgradient', 'rect', 'stop', 'style', 'switch', 'symbol', 'text', 'textpath', 'title', 'tref', 'tspan', 'view', 'vkern', ]) var svgFilters = freeze([ 'feBlend', 'feColorMatrix', 'feComponentTransfer', 'feComposite', 'feConvolveMatrix', 'feDiffuseLighting', 'feDisplacementMap', 'feDistantLight', 'feFlood', 'feFuncA', 'feFuncB', 'feFuncG', 'feFuncR', 'feGaussianBlur', 'feImage', 'feMerge', 'feMergeNode', 'feMorphology', 'feOffset', 'fePointLight', 'feSpecularLighting', 'feSpotLight', 'feTile', 'feTurbulence', ]) var svgDisallowed = freeze([ 'animate', 'color-profile', 'cursor', 'discard', 'fedropshadow', 'font-face', 'font-face-format', 'font-face-name', 'font-face-src', 'font-face-uri', 'foreignobject', 'hatch', 'hatchpath', 'mesh', 'meshgradient', 'meshpatch', 'meshrow', 'missing-glyph', 'script', 'set', 'solidcolor', 'unknown', 'use', ]) var mathMl$1 = freeze([ 'math', 'menclose', 'merror', 'mfenced', 'mfrac', 'mglyph', 'mi', 'mlabeledtr', 'mmultiscripts', 'mn', 'mo', 'mover', 'mpadded', 'mphantom', 'mroot', 'mrow', 'ms', 'mspace', 'msqrt', 'mstyle', 'msub', 'msup', 'msubsup', 'mtable', 'mtd', 'mtext', 'mtr', 'munder', 'munderover', ]) var mathMlDisallowed = freeze([ 'maction', 'maligngroup', 'malignmark', 'mlongdiv', 'mscarries', 'mscarry', 'msgroup', 'mstack', 'msline', 'msrow', 'semantics', 'annotation', 'annotation-xml', 'mprescripts', 'none', ]) var text$1 = freeze(['#text']) var html$3 = freeze([ 'accept', 'action', 'align', 'alt', 'autocapitalize', 'autocomplete', 'autopictureinpicture', 'autoplay', 'background', 'bgcolor', 'border', 'capture', 'cellpadding', 'cellspacing', 'checked', 'cite', 'class', 'clear', 'color', 'cols', 'colspan', 'controls', 'controlslist', 'coords', 'crossorigin', 'datetime', 'decoding', 'default', 'dir', 'disabled', 'disablepictureinpicture', 'disableremoteplayback', 'download', 'draggable', 'enctype', 'enterkeyhint', 'face', 'for', 'headers', 'height', 'hidden', 'high', 'href', 'hreflang', 'id', 'inputmode', 'integrity', 'ismap', 'kind', 'label', 'lang', 'list', 'loading', 'loop', 'low', 'max', 'maxlength', 'media', 'method', 'min', 'minlength', 'multiple', 'muted', 'name', 'nonce', 'noshade', 'novalidate', 'nowrap', 'open', 'optimum', 'pattern', 'placeholder', 'playsinline', 'poster', 'preload', 'pubdate', 'radiogroup', 'readonly', 'rel', 'required', 'rev', 'reversed', 'role', 'rows', 'rowspan', 'spellcheck', 'scope', 'selected', 'shape', 'size', 'sizes', 'span', 'srclang', 'start', 'src', 'srcset', 'step', 'style', 'summary', 'tabindex', 'title', 'translate', 'type', 'usemap', 'valign', 'value', 'width', 'xmlns', 'slot', ]) var svg = freeze([ 'accent-height', 'accumulate', 'additive', 'alignment-baseline', 'ascent', 'attributename', 'attributetype', 'azimuth', 'basefrequency', 'baseline-shift', 'begin', 'bias', 'by', 'class', 'clip', 'clippathunits', 'clip-path', 'clip-rule', 'color', 'color-interpolation', 'color-interpolation-filters', 'color-profile', 'color-rendering', 'cx', 'cy', 'd', 'dx', 'dy', 'diffuseconstant', 'direction', 'display', 'divisor', 'dur', 'edgemode', 'elevation', 'end', 'fill', 'fill-opacity', 'fill-rule', 'filter', 'filterunits', 'flood-color', 'flood-opacity', 'font-family', 'font-size', 'font-size-adjust', 'font-stretch', 'font-style', 'font-variant', 'font-weight', 'fx', 'fy', 'g1', 'g2', 'glyph-name', 'glyphref', 'gradientunits', 'gradienttransform', 'height', 'href', 'id', 'image-rendering', 'in', 'in2', 'k', 'k1', 'k2', 'k3', 'k4', 'kerning', 'keypoints', 'keysplines', 'keytimes', 'lang', 'lengthadjust', 'letter-spacing', 'kernelmatrix', 'kernelunitlength', 'lighting-color', 'local', 'marker-end', 'marker-mid', 'marker-start', 'markerheight', 'markerunits', 'markerwidth', 'maskcontentunits', 'maskunits', 'max', 'mask', 'media', 'method', 'mode', 'min', 'name', 'numoctaves', 'offset', 'operator', 'opacity', 'order', 'orient', 'orientation', 'origin', 'overflow', 'paint-order', 'path', 'pathlength', 'patterncontentunits', 'patterntransform', 'patternunits', 'points', 'preservealpha', 'preserveaspectratio', 'primitiveunits', 'r', 'rx', 'ry', 'radius', 'refx', 'refy', 'repeatcount', 'repeatdur', 'restart', 'result', 'rotate', 'scale', 'seed', 'shape-rendering', 'specularconstant', 'specularexponent', 'spreadmethod', 'startoffset', 'stddeviation', 'stitchtiles', 'stop-color', 'stop-opacity', 'stroke-dasharray', 'stroke-dashoffset', 'stroke-linecap', 'stroke-linejoin', 'stroke-miterlimit', 'stroke-opacity', 'stroke', 'stroke-width', 'style', 'surfacescale', 'systemlanguage', 'tabindex', 'targetx', 'targety', 'transform', 'transform-origin', 'text-anchor', 'text-decoration', 'text-rendering', 'textlength', 'type', 'u1', 'u2', 'unicode', 'values', 'viewbox', 'visibility', 'version', 'vert-adv-y', 'vert-origin-x', 'vert-origin-y', 'width', 'word-spacing', 'wrap', 'writing-mode', 'xchannelselector', 'ychannelselector', 'x', 'x1', 'x2', 'xmlns', 'y', 'y1', 'y2', 'z', 'zoomandpan', ]) var mathMl = freeze([ 'accent', 'accentunder', 'align', 'bevelled', 'close', 'columnsalign', 'columnlines', 'columnspan', 'denomalign', 'depth', 'dir', 'display', 'displaystyle', 'encoding', 'fence', 'frame', 'height', 'href', 'id', 'largeop', 'length', 'linethickness', 'lspace', 'lquote', 'mathbackground', 'mathcolor', 'mathsize', 'mathvariant', 'maxsize', 'minsize', 'movablelimits', 'notation', 'numalign', 'open', 'rowalign', 'rowlines', 'rowspacing', 'rowspan', 'rspace', 'rquote', 'scriptlevel', 'scriptminsize', 'scriptsizemultiplier', 'selection', 'separator', 'separators', 'stretchy', 'subscriptshift', 'supscriptshift', 'symmetric', 'voffset', 'width', 'xmlns', ]) var xml = freeze([ 'xlink:href', 'xml:id', 'xlink:title', 'xml:space', 'xmlns:xlink', ]) var MUSTACHE_EXPR = seal(/\{\{[\w\W]*|[\w\W]*\}\}/gm) var ERB_EXPR = seal(/<%[\w\W]*|[\w\W]*%>/gm) var TMPLIT_EXPR = seal(/\${[\w\W]*}/gm) var DATA_ATTR = seal(/^data-[\-\w.\u00B7-\uFFFF]/) var ARIA_ATTR = seal(/^aria-[\-\w]+$/) var IS_ALLOWED_URI = seal( /^(?:(?:(?:f|ht)tps?|mailto|tel|callto|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i ) var IS_SCRIPT_OR_DATA = seal(/^(?:\w+script|data):/i) var ATTR_WHITESPACE = seal( /[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g ) var DOCTYPE_NAME = seal(/^html$/i) var getGlobal = function getGlobal2() { return typeof window === 'undefined' ? null : window } var _createTrustedTypesPolicy = function _createTrustedTypesPolicy2( trustedTypes, document2 ) { if ( _typeof$2(trustedTypes) !== 'object' || typeof trustedTypes.createPolicy !== 'function' ) { return null } var suffix2 = null var ATTR_NAME = 'data-tt-policy-suffix' if ( document2.currentScript && document2.currentScript.hasAttribute(ATTR_NAME) ) { suffix2 = document2.currentScript.getAttribute(ATTR_NAME) } var policyName = 'dompurify' + (suffix2 ? '#' + suffix2 : '') try { return trustedTypes.createPolicy(policyName, { createHTML: function createHTML(html2) { return html2 }, createScriptURL: function createScriptURL(scriptUrl) { return scriptUrl }, }) } catch (_2) { console.warn('TrustedTypes policy ' + policyName + ' could not be created.') return null } } function createDOMPurify() { var window2 = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : getGlobal() var DOMPurify = function DOMPurify2(root2) { return createDOMPurify(root2) } DOMPurify.version = '2.4.7' DOMPurify.removed = [] if (!window2 || !window2.document || window2.document.nodeType !== 9) { DOMPurify.isSupported = false return DOMPurify } var originalDocument = window2.document var document2 = window2.document var DocumentFragment = window2.DocumentFragment, HTMLTemplateElement = window2.HTMLTemplateElement, Node2 = window2.Node, Element2 = window2.Element, NodeFilter2 = window2.NodeFilter, _window$NamedNodeMap = window2.NamedNodeMap, NamedNodeMap = _window$NamedNodeMap === void 0 ? window2.NamedNodeMap || window2.MozNamedAttrMap : _window$NamedNodeMap, HTMLFormElement = window2.HTMLFormElement, DOMParser2 = window2.DOMParser, trustedTypes = window2.trustedTypes var ElementPrototype = Element2.prototype var cloneNode2 = lookupGetter(ElementPrototype, 'cloneNode') var getNextSibling = lookupGetter(ElementPrototype, 'nextSibling') var getChildNodes2 = lookupGetter(ElementPrototype, 'childNodes') var getParentNode2 = lookupGetter(ElementPrototype, 'parentNode') if (typeof HTMLTemplateElement === 'function') { var template2 = document2.createElement('template') if (template2.content && template2.content.ownerDocument) { document2 = template2.content.ownerDocument } } var trustedTypesPolicy = _createTrustedTypesPolicy( trustedTypes, originalDocument ) var emptyHTML = trustedTypesPolicy ? trustedTypesPolicy.createHTML('') : '' var _document = document2, implementation = _document.implementation, createNodeIterator = _document.createNodeIterator, createDocumentFragment = _document.createDocumentFragment, getElementsByTagName = _document.getElementsByTagName var importNode = originalDocument.importNode var documentMode = {} try { documentMode = clone$6(document2).documentMode ? document2.documentMode : {} } catch (_2) {} var hooks2 = {} DOMPurify.isSupported = typeof getParentNode2 === 'function' && implementation && implementation.createHTMLDocument !== void 0 && documentMode !== 9 var MUSTACHE_EXPR$1 = MUSTACHE_EXPR, ERB_EXPR$1 = ERB_EXPR, TMPLIT_EXPR$1 = TMPLIT_EXPR, DATA_ATTR$1 = DATA_ATTR, ARIA_ATTR$1 = ARIA_ATTR, IS_SCRIPT_OR_DATA$1 = IS_SCRIPT_OR_DATA, ATTR_WHITESPACE$1 = ATTR_WHITESPACE var IS_ALLOWED_URI$1 = IS_ALLOWED_URI var ALLOWED_TAGS = null var DEFAULT_ALLOWED_TAGS = addToSet( {}, [].concat( _toConsumableArray(html$1$1), _toConsumableArray(svg$1), _toConsumableArray(svgFilters), _toConsumableArray(mathMl$1), _toConsumableArray(text$1) ) ) var ALLOWED_ATTR = null var DEFAULT_ALLOWED_ATTR = addToSet( {}, [].concat( _toConsumableArray(html$3), _toConsumableArray(svg), _toConsumableArray(mathMl), _toConsumableArray(xml) ) ) var CUSTOM_ELEMENT_HANDLING = Object.seal( Object.create(null, { tagNameCheck: { writable: true, configurable: false, enumerable: true, value: null, }, attributeNameCheck: { writable: true, configurable: false, enumerable: true, value: null, }, allowCustomizedBuiltInElements: { writable: true, configurable: false, enumerable: true, value: false, }, }) ) var FORBID_TAGS = null var FORBID_ATTR = null var ALLOW_ARIA_ATTR = true var ALLOW_DATA_ATTR = true var ALLOW_UNKNOWN_PROTOCOLS = false var ALLOW_SELF_CLOSE_IN_ATTR = true var SAFE_FOR_TEMPLATES = false var WHOLE_DOCUMENT = false var SET_CONFIG = false var FORCE_BODY = false var RETURN_DOM = false var RETURN_DOM_FRAGMENT = false var RETURN_TRUSTED_TYPE = false var SANITIZE_DOM = true var SANITIZE_NAMED_PROPS = false var SANITIZE_NAMED_PROPS_PREFIX = 'user-content-' var KEEP_CONTENT = true var IN_PLACE = false var USE_PROFILES = {} var FORBID_CONTENTS = null var DEFAULT_FORBID_CONTENTS = addToSet({}, [ 'annotation-xml', 'audio', 'colgroup', 'desc', 'foreignobject', 'head', 'iframe', 'math', 'mi', 'mn', 'mo', 'ms', 'mtext', 'noembed', 'noframes', 'noscript', 'plaintext', 'script', 'style', 'svg', 'template', 'thead', 'title', 'video', 'xmp', ]) var DATA_URI_TAGS = null var DEFAULT_DATA_URI_TAGS = addToSet({}, [ 'audio', 'video', 'img', 'source', 'image', 'track', ]) var URI_SAFE_ATTRIBUTES = null var DEFAULT_URI_SAFE_ATTRIBUTES = addToSet({}, [ 'alt', 'class', 'for', 'id', 'label', 'name', 'pattern', 'placeholder', 'role', 'summary', 'title', 'value', 'style', 'xmlns', ]) var MATHML_NAMESPACE = 'http://www.w3.org/1998/Math/MathML' var SVG_NAMESPACE = 'http://www.w3.org/2000/svg' var HTML_NAMESPACE = 'http://www.w3.org/1999/xhtml' var NAMESPACE = HTML_NAMESPACE var IS_EMPTY_INPUT = false var ALLOWED_NAMESPACES = null var DEFAULT_ALLOWED_NAMESPACES = addToSet( {}, [MATHML_NAMESPACE, SVG_NAMESPACE, HTML_NAMESPACE], stringToString ) var PARSER_MEDIA_TYPE var SUPPORTED_PARSER_MEDIA_TYPES = ['application/xhtml+xml', 'text/html'] var DEFAULT_PARSER_MEDIA_TYPE = 'text/html' var transformCaseFunc var CONFIG = null var formElement = document2.createElement('form') var isRegexOrFunction = function isRegexOrFunction2(testValue) { return testValue instanceof RegExp || testValue instanceof Function } var _parseConfig = function _parseConfig2(cfg) { if (CONFIG && CONFIG === cfg) { return } if (!cfg || _typeof$2(cfg) !== 'object') { cfg = {} } cfg = clone$6(cfg) PARSER_MEDIA_TYPE = SUPPORTED_PARSER_MEDIA_TYPES.indexOf(cfg.PARSER_MEDIA_TYPE) === -1 ? (PARSER_MEDIA_TYPE = DEFAULT_PARSER_MEDIA_TYPE) : (PARSER_MEDIA_TYPE = cfg.PARSER_MEDIA_TYPE) transformCaseFunc = PARSER_MEDIA_TYPE === 'application/xhtml+xml' ? stringToString : stringToLowerCase ALLOWED_TAGS = 'ALLOWED_TAGS' in cfg ? addToSet({}, cfg.ALLOWED_TAGS, transformCaseFunc) : DEFAULT_ALLOWED_TAGS ALLOWED_ATTR = 'ALLOWED_ATTR' in cfg ? addToSet({}, cfg.ALLOWED_ATTR, transformCaseFunc) : DEFAULT_ALLOWED_ATTR ALLOWED_NAMESPACES = 'ALLOWED_NAMESPACES' in cfg ? addToSet({}, cfg.ALLOWED_NAMESPACES, stringToString) : DEFAULT_ALLOWED_NAMESPACES URI_SAFE_ATTRIBUTES = 'ADD_URI_SAFE_ATTR' in cfg ? addToSet( clone$6(DEFAULT_URI_SAFE_ATTRIBUTES), cfg.ADD_URI_SAFE_ATTR, transformCaseFunc ) : DEFAULT_URI_SAFE_ATTRIBUTES DATA_URI_TAGS = 'ADD_DATA_URI_TAGS' in cfg ? addToSet( clone$6(DEFAULT_DATA_URI_TAGS), cfg.ADD_DATA_URI_TAGS, transformCaseFunc ) : DEFAULT_DATA_URI_TAGS FORBID_CONTENTS = 'FORBID_CONTENTS' in cfg ? addToSet({}, cfg.FORBID_CONTENTS, transformCaseFunc) : DEFAULT_FORBID_CONTENTS FORBID_TAGS = 'FORBID_TAGS' in cfg ? addToSet({}, cfg.FORBID_TAGS, transformCaseFunc) : {} FORBID_ATTR = 'FORBID_ATTR' in cfg ? addToSet({}, cfg.FORBID_ATTR, transformCaseFunc) : {} USE_PROFILES = 'USE_PROFILES' in cfg ? cfg.USE_PROFILES : false ALLOW_ARIA_ATTR = cfg.ALLOW_ARIA_ATTR !== false ALLOW_DATA_ATTR = cfg.ALLOW_DATA_ATTR !== false ALLOW_UNKNOWN_PROTOCOLS = cfg.ALLOW_UNKNOWN_PROTOCOLS || false ALLOW_SELF_CLOSE_IN_ATTR = cfg.ALLOW_SELF_CLOSE_IN_ATTR !== false SAFE_FOR_TEMPLATES = cfg.SAFE_FOR_TEMPLATES || false WHOLE_DOCUMENT = cfg.WHOLE_DOCUMENT || false RETURN_DOM = cfg.RETURN_DOM || false RETURN_DOM_FRAGMENT = cfg.RETURN_DOM_FRAGMENT || false RETURN_TRUSTED_TYPE = cfg.RETURN_TRUSTED_TYPE || false FORCE_BODY = cfg.FORCE_BODY || false SANITIZE_DOM = cfg.SANITIZE_DOM !== false SANITIZE_NAMED_PROPS = cfg.SANITIZE_NAMED_PROPS || false KEEP_CONTENT = cfg.KEEP_CONTENT !== false IN_PLACE = cfg.IN_PLACE || false IS_ALLOWED_URI$1 = cfg.ALLOWED_URI_REGEXP || IS_ALLOWED_URI$1 NAMESPACE = cfg.NAMESPACE || HTML_NAMESPACE CUSTOM_ELEMENT_HANDLING = cfg.CUSTOM_ELEMENT_HANDLING || {} if ( cfg.CUSTOM_ELEMENT_HANDLING && isRegexOrFunction(cfg.CUSTOM_ELEMENT_HANDLING.tagNameCheck) ) { CUSTOM_ELEMENT_HANDLING.tagNameCheck = cfg.CUSTOM_ELEMENT_HANDLING.tagNameCheck } if ( cfg.CUSTOM_ELEMENT_HANDLING && isRegexOrFunction(cfg.CUSTOM_ELEMENT_HANDLING.attributeNameCheck) ) { CUSTOM_ELEMENT_HANDLING.attributeNameCheck = cfg.CUSTOM_ELEMENT_HANDLING.attributeNameCheck } if ( cfg.CUSTOM_ELEMENT_HANDLING && typeof cfg.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements === 'boolean' ) { CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements = cfg.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements } if (SAFE_FOR_TEMPLATES) { ALLOW_DATA_ATTR = false } if (RETURN_DOM_FRAGMENT) { RETURN_DOM = true } if (USE_PROFILES) { ALLOWED_TAGS = addToSet({}, _toConsumableArray(text$1)) ALLOWED_ATTR = [] if (USE_PROFILES.html === true) { addToSet(ALLOWED_TAGS, html$1$1) addToSet(ALLOWED_ATTR, html$3) } if (USE_PROFILES.svg === true) { addToSet(ALLOWED_TAGS, svg$1) addToSet(ALLOWED_ATTR, svg) addToSet(ALLOWED_ATTR, xml) } if (USE_PROFILES.svgFilters === true) { addToSet(ALLOWED_TAGS, svgFilters) addToSet(ALLOWED_ATTR, svg) addToSet(ALLOWED_ATTR, xml) } if (USE_PROFILES.mathMl === true) { addToSet(ALLOWED_TAGS, mathMl$1) addToSet(ALLOWED_ATTR, mathMl) addToSet(ALLOWED_ATTR, xml) } } if (cfg.ADD_TAGS) { if (ALLOWED_TAGS === DEFAULT_ALLOWED_TAGS) { ALLOWED_TAGS = clone$6(ALLOWED_TAGS) } addToSet(ALLOWED_TAGS, cfg.ADD_TAGS, transformCaseFunc) } if (cfg.ADD_ATTR) { if (ALLOWED_ATTR === DEFAULT_ALLOWED_ATTR) { ALLOWED_ATTR = clone$6(ALLOWED_ATTR) } addToSet(ALLOWED_ATTR, cfg.ADD_ATTR, transformCaseFunc) } if (cfg.ADD_URI_SAFE_ATTR) { addToSet(URI_SAFE_ATTRIBUTES, cfg.ADD_URI_SAFE_ATTR, transformCaseFunc) } if (cfg.FORBID_CONTENTS) { if (FORBID_CONTENTS === DEFAULT_FORBID_CONTENTS) { FORBID_CONTENTS = clone$6(FORBID_CONTENTS) } addToSet(FORBID_CONTENTS, cfg.FORBID_CONTENTS, transformCaseFunc) } if (KEEP_CONTENT) { ALLOWED_TAGS['#text'] = true } if (WHOLE_DOCUMENT) { addToSet(ALLOWED_TAGS, ['html', 'head', 'body']) } if (ALLOWED_TAGS.table) { addToSet(ALLOWED_TAGS, ['tbody']) delete FORBID_TAGS.tbody } if (freeze) { freeze(cfg) } CONFIG = cfg } var MATHML_TEXT_INTEGRATION_POINTS = addToSet({}, [ 'mi', 'mo', 'mn', 'ms', 'mtext', ]) var HTML_INTEGRATION_POINTS = addToSet({}, [ 'foreignobject', 'desc', 'title', 'annotation-xml', ]) var COMMON_SVG_AND_HTML_ELEMENTS = addToSet({}, [ 'title', 'style', 'font', 'a', 'script', ]) var ALL_SVG_TAGS = addToSet({}, svg$1) addToSet(ALL_SVG_TAGS, svgFilters) addToSet(ALL_SVG_TAGS, svgDisallowed) var ALL_MATHML_TAGS = addToSet({}, mathMl$1) addToSet(ALL_MATHML_TAGS, mathMlDisallowed) var _checkValidNamespace = function _checkValidNamespace2(element) { var parent2 = getParentNode2(element) if (!parent2 || !parent2.tagName) { parent2 = { namespaceURI: NAMESPACE, tagName: 'template', } } var tagName = stringToLowerCase(element.tagName) var parentTagName = stringToLowerCase(parent2.tagName) if (!ALLOWED_NAMESPACES[element.namespaceURI]) { return false } if (element.namespaceURI === SVG_NAMESPACE) { if (parent2.namespaceURI === HTML_NAMESPACE) { return tagName === 'svg' } if (parent2.namespaceURI === MATHML_NAMESPACE) { return ( tagName === 'svg' && (parentTagName === 'annotation-xml' || MATHML_TEXT_INTEGRATION_POINTS[parentTagName]) ) } return Boolean(ALL_SVG_TAGS[tagName]) } if (element.namespaceURI === MATHML_NAMESPACE) { if (parent2.namespaceURI === HTML_NAMESPACE) { return tagName === 'math' } if (parent2.namespaceURI === SVG_NAMESPACE) { return tagName === 'math' && HTML_INTEGRATION_POINTS[parentTagName] } return Boolean(ALL_MATHML_TAGS[tagName]) } if (element.namespaceURI === HTML_NAMESPACE) { if ( parent2.namespaceURI === SVG_NAMESPACE && !HTML_INTEGRATION_POINTS[parentTagName] ) { return false } if ( parent2.namespaceURI === MATHML_NAMESPACE && !MATHML_TEXT_INTEGRATION_POINTS[parentTagName] ) { return false } return ( !ALL_MATHML_TAGS[tagName] && (COMMON_SVG_AND_HTML_ELEMENTS[tagName] || !ALL_SVG_TAGS[tagName]) ) } if ( PARSER_MEDIA_TYPE === 'application/xhtml+xml' && ALLOWED_NAMESPACES[element.namespaceURI] ) { return true } return false } var _forceRemove = function _forceRemove2(node2) { arrayPush$3(DOMPurify.removed, { element: node2, }) try { node2.parentNode.removeChild(node2) } catch (_2) { try { node2.outerHTML = emptyHTML } catch (_3) { node2.remove() } } } var _removeAttribute = function _removeAttribute2(name2, node2) { try { arrayPush$3(DOMPurify.removed, { attribute: node2.getAttributeNode(name2), from: node2, }) } catch (_2) { arrayPush$3(DOMPurify.removed, { attribute: null, from: node2, }) } node2.removeAttribute(name2) if (name2 === 'is' && !ALLOWED_ATTR[name2]) { if (RETURN_DOM || RETURN_DOM_FRAGMENT) { try { _forceRemove(node2) } catch (_2) {} } else { try { node2.setAttribute(name2, '') } catch (_2) {} } } } var _initDocument = function _initDocument2(dirty) { var doc var leadingWhitespace if (FORCE_BODY) { dirty = '' + dirty } else { var matches2 = stringMatch(dirty, /^[\r\n\t ]+/) leadingWhitespace = matches2 && matches2[0] } if ( PARSER_MEDIA_TYPE === 'application/xhtml+xml' && NAMESPACE === HTML_NAMESPACE ) { dirty = '' + dirty + '' } var dirtyPayload = trustedTypesPolicy ? trustedTypesPolicy.createHTML(dirty) : dirty if (NAMESPACE === HTML_NAMESPACE) { try { doc = new DOMParser2().parseFromString(dirtyPayload, PARSER_MEDIA_TYPE) } catch (_2) {} } if (!doc || !doc.documentElement) { doc = implementation.createDocument(NAMESPACE, 'template', null) try { doc.documentElement.innerHTML = IS_EMPTY_INPUT ? emptyHTML : dirtyPayload } catch (_2) {} } var body = doc.body || doc.documentElement if (dirty && leadingWhitespace) { body.insertBefore( document2.createTextNode(leadingWhitespace), body.childNodes[0] || null ) } if (NAMESPACE === HTML_NAMESPACE) { return getElementsByTagName.call(doc, WHOLE_DOCUMENT ? 'html' : 'body')[0] } return WHOLE_DOCUMENT ? doc.documentElement : body } var _createIterator = function _createIterator2(root2) { return createNodeIterator.call( root2.ownerDocument || root2, root2, NodeFilter2.SHOW_ELEMENT | NodeFilter2.SHOW_COMMENT | NodeFilter2.SHOW_TEXT, null, false ) } var _isClobbered = function _isClobbered2(elm) { return ( elm instanceof HTMLFormElement && (typeof elm.nodeName !== 'string' || typeof elm.textContent !== 'string' || typeof elm.removeChild !== 'function' || !(elm.attributes instanceof NamedNodeMap) || typeof elm.removeAttribute !== 'function' || typeof elm.setAttribute !== 'function' || typeof elm.namespaceURI !== 'string' || typeof elm.insertBefore !== 'function' || typeof elm.hasChildNodes !== 'function') ) } var _isNode = function _isNode2(object4) { return _typeof$2(Node2) === 'object' ? object4 instanceof Node2 : object4 && _typeof$2(object4) === 'object' && typeof object4.nodeType === 'number' && typeof object4.nodeName === 'string' } var _executeHook = function _executeHook2(entryPoint, currentNode, data2) { if (!hooks2[entryPoint]) { return } arrayForEach(hooks2[entryPoint], function (hook) { hook.call(DOMPurify, currentNode, data2, CONFIG) }) } var _sanitizeElements = function _sanitizeElements2(currentNode) { var content2 _executeHook('beforeSanitizeElements', currentNode, null) if (_isClobbered(currentNode)) { _forceRemove(currentNode) return true } if (regExpTest(/[\u0080-\uFFFF]/, currentNode.nodeName)) { _forceRemove(currentNode) return true } var tagName = transformCaseFunc(currentNode.nodeName) _executeHook('uponSanitizeElement', currentNode, { tagName, allowedTags: ALLOWED_TAGS, }) if ( currentNode.hasChildNodes() && !_isNode(currentNode.firstElementChild) && (!_isNode(currentNode.content) || !_isNode(currentNode.content.firstElementChild)) && regExpTest(/<[/\w]/g, currentNode.innerHTML) && regExpTest(/<[/\w]/g, currentNode.textContent) ) { _forceRemove(currentNode) return true } if ( tagName === 'select' && regExpTest(/