easy-soft-utility 2.3.11 → 2.3.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/es/index.js CHANGED
@@ -1 +1 @@
1
- import t from"node-cache";import n from"lodash/isBoolean";import r from"lodash/isDate";import e from"lodash/isEqual";import o from"lodash/isFunction";import a from"lodash/isNull";import i from"lodash/isNumber";import u from"lodash/isObject";import c from"lodash/isString";import l from"lodash/isUndefined";import s from"lodash/replace";import f from"lodash/assign";import d from"lodash/assignWith";import h from"lodash/difference";import g from"lodash/dropRight";import m from"lodash/endsWith";import v from"lodash/filter";import p from"lodash/find";import y from"lodash/findIndex";import w from"lodash/first";import b from"lodash/floor";import A from"lodash/forEach";import x from"lodash/get";import S from"lodash/gte";import M from"lodash/map";import D from"lodash/memoize";import C from"lodash/remove";import E from"lodash/reverse";import O from"lodash/round";import I from"lodash/set";import j from"lodash/size";import k from"lodash/sortBy";import N from"lodash/sortedUniq";import T from"lodash/split";import P from"lodash/startsWith";import Y from"lodash/trim";import F from"lodash/uniqBy";import B from"lodash/toNumber";import H from"lodash/toString";import U from"object-hash";import W from"dayjs";import{stringify as L,parse as R}from"qs";var K,Q="function"==typeof atob,G="function"==typeof btoa,J="function"==typeof Buffer,V="function"==typeof TextDecoder?new TextDecoder:void 0,z="function"==typeof TextEncoder?new TextEncoder:void 0,q=Array.prototype.slice.call("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="),Z=(K={},q.forEach((function(t,n){return K[t]=n})),K),$=/^(?:[A-Za-z\d+\/]{4})*?(?:[A-Za-z\d+\/]{2}(?:==)?|[A-Za-z\d+\/]{3}=?)?$/,X=String.fromCharCode.bind(String),_="function"==typeof Uint8Array.from?Uint8Array.from.bind(Uint8Array):function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(t){return t};return new Uint8Array(Array.prototype.slice.call(t,0).map(n))},tt=function(t){return t.replace(/=/g,"").replace(/[+\/]/g,(function(t){return"+"==t?"-":"_"}))},nt=function(t){return t.replace(/[^A-Za-z0-9\+\/]/g,"")},rt=G?function(t){return btoa(t)}:J?function(t){return Buffer.from(t,"binary").toString("base64")}:function(t){for(var n,r,e,o,a="",i=t.length%3,u=0;u<t.length;){if((r=t.charCodeAt(u++))>255||(e=t.charCodeAt(u++))>255||(o=t.charCodeAt(u++))>255)throw new TypeError("invalid character found");a+=q[(n=r<<16|e<<8|o)>>18&63]+q[n>>12&63]+q[n>>6&63]+q[63&n]}return i?a.slice(0,i-3)+"===".substring(i):a},et=J?function(t){return Buffer.from(t).toString("base64")}:function(t){for(var n=[],r=0,e=t.length;r<e;r+=4096)n.push(X.apply(null,t.subarray(r,r+4096)));return rt(n.join(""))},ot=function(t){if(t.length<2)return(n=t.charCodeAt(0))<128?t:n<2048?X(192|n>>>6)+X(128|63&n):X(224|n>>>12&15)+X(128|n>>>6&63)+X(128|63&n);var n=65536+1024*(t.charCodeAt(0)-55296)+(t.charCodeAt(1)-56320);return X(240|n>>>18&7)+X(128|n>>>12&63)+X(128|n>>>6&63)+X(128|63&n)},at=/[\uD800-\uDBFF][\uDC00-\uDFFFF]|[^\x00-\x7F]/g,it=J?function(t){return Buffer.from(t,"utf8").toString("base64")}:z?function(t){return et(z.encode(t))}:function(t){return rt(t.replace(at,ot))},ut=/[\xC0-\xDF][\x80-\xBF]|[\xE0-\xEF][\x80-\xBF]{2}|[\xF0-\xF7][\x80-\xBF]{3}/g,ct=function(t){switch(t.length){case 4:var n=((7&t.charCodeAt(0))<<18|(63&t.charCodeAt(1))<<12|(63&t.charCodeAt(2))<<6|63&t.charCodeAt(3))-65536;return X(55296+(n>>>10))+X(56320+(1023&n));case 3:return X((15&t.charCodeAt(0))<<12|(63&t.charCodeAt(1))<<6|63&t.charCodeAt(2));default:return X((31&t.charCodeAt(0))<<6|63&t.charCodeAt(1))}},lt=Q?function(t){return atob(nt(t))}:J?function(t){return Buffer.from(t,"base64").toString("binary")}:function(t){if(t=t.replace(/\s+/g,""),!$.test(t))throw new TypeError("malformed base64.");t+="==".slice(2-(3&t.length));for(var n,r,e,o="",a=0;a<t.length;)n=Z[t.charAt(a++)]<<18|Z[t.charAt(a++)]<<12|(r=Z[t.charAt(a++)])<<6|(e=Z[t.charAt(a++)]),o+=64===r?X(n>>16&255):64===e?X(n>>16&255,n>>8&255):X(n>>16&255,n>>8&255,255&n);return o},st=J?function(t){return _(Buffer.from(t,"base64"))}:function(t){return _(lt(t),(function(t){return t.charCodeAt(0)}))},ft=J?function(t){return Buffer.from(t,"base64").toString("utf8")}:V?function(t){return V.decode(st(t))}:function(t){return lt(t).replace(ut,ct)},dt=function(t){return ft(nt(t.replace(/[-_]/g,(function(t){return"-"==t?"+":"/"}))))};function ht(t){return dt(t)}function gt(t){return function(t){var n=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return n?tt(it(t)):it(t)}(t)}function mt(t){return 1*t<10?"0".concat(t):t}function vt(t){return vt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},vt(t)}function pt(t){var n=function(t,n){if("object"!==vt(t)||null===t)return t;var r=t[Symbol.toPrimitive];if(void 0!==r){var e=r.call(t,n||"default");if("object"!==vt(e))return e;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===n?String:Number)(t)}(t,"string");return"symbol"===vt(n)?n:String(n)}function yt(t,n,r){return(n=pt(n))in t?Object.defineProperty(t,n,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[n]=r,t}function wt(t,n){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var e=Object.getOwnPropertySymbols(t);n&&(e=e.filter((function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable}))),r.push.apply(r,e)}return r}function bt(t){for(var n=1;n<arguments.length;n++){var r=null!=arguments[n]?arguments[n]:{};n%2?wt(Object(r),!0).forEach((function(n){yt(t,n,r[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):wt(Object(r)).forEach((function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(r,n))}))}return t}function At(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;return x(t,n,r)}function xt(t,n){return O(t,n)}function St(t,n,r){return m(t,n,r)}function Mt(t){return N(t)}function Dt(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1e3;return T(t,n,r)}function Ct(t,n){return f(t,n)}function Et(t,n,r){return d(t,n,r)}function Ot(t){return E(t)}function It(t,n){return A(t,n)}function jt(t,n){return S(t,n)}function kt(t){return D(t)}function Nt(t,n){return b(t,n)}function Tt(t){return w(t)}function Pt(t,n){return P(t,n)}function Yt(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1;return g(t,n)}function Ft(t,n){return F(t,n)}function Bt(t){return Y(t)}function Ht(t,n,r){return s(t,n,r)}function Ut(t,n){return C(t,n)}function Wt(t,n){return M(t,n)}function Lt(t,n,r){return I(t,n,r)}function Rt(t){return j(t)}function Kt(t,n){return h(t,n)}function Qt(t,n){return v(t,n)}function Gt(t,n){return k(t,n)}function Jt(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;return y(t,n,r)}function Vt(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;return p(t,n,r)}function zt(t){return rn(t)}function qt(t){var n="".concat(rn(t)?null:t).match(/^(\d{1,4})(-|\/)(\d{1,2})\2(\d{1,2})$/);if(null==n)return!1;var r=new Date(n[1],n[3]-1,n[4]);return r.getFullYear()===parseInt(n[1],10)&&r.getMonth()+1===parseInt(n[3],10)&&r.getDate()===parseInt(n[4],10)}function Zt(t){return i(t)}function $t(t){var n="".concat(rn(t)?null:t);if(""===n)return!1;return new RegExp(/^([1-9][\d]{0,15}|0)(\.[\d]{1,2})?$/).test(n)}function Xt(t,n){return e(t,n)}function _t(t,n){return JSON.stringify(t||{})===JSON.stringify(n||{})}function tn(t){return o(t)}function nn(t){return n(t)}function rn(t){return l(t)}function en(t){return a(t)}function on(t){return r(t)}function an(t){return c(t)}function un(t){return Array.isArray(t)}function cn(t){return u(t)}function ln(t){return null!==t&&"object"===vt(t)&&!un(t)}function sn(t){return ln(t)&&tn(t.then)&&tn(t.catch)}function fn(t){return new RegExp(/(http|https):\/\/([\w.]+\/?)\S*/).test(t)}function dn(t){return new RegExp(/(data):image\/([\w.]+\/?)\S*/).test(t)}function hn(t){return""===Bt(s(t||""," ",""))}function gn(t,n){var r=!1;return un(t)?(t.some((function(t){return t===n&&(r=!0,!0)})),r):r}var mn="easy-soft-utility",vn={WEAPP:"WEAPP",WEB:"WEB",RN:"RN",SWAN:"SWAN",ALIPAY:"ALIPAY",TT:"TT",QQ:"QQ",JD:"JD",UNKNOWN:"UNKNOWN"},pn={loadApiPath:"",firstLoadSuccess:!1,loadSuccess:!1,registering:!1,dataLoading:!1,reloading:!1,searching:!1,refreshing:!1,paging:!1,processing:!1,dispatchComplete:!0,metaData:null,metaExtra:null,metaListData:[],metaOriginalData:null,urlParams:null,externalData:null},yn={dataLoading:!0},wn={get:"GET",post:"POST",put:"PUT",delete:"DELETE",trace:"TRACE",connect:"CONNECT"},bn="0",An=0,xn="1970-01-01 00:00",Sn={number:"number",datetime:"datetime",string:"string",moment:"moment",money:"money",array:"array",boolean:"boolean"},Mn={money:"money",datetime:"datetime",chineseMoney:"chineseMoney",percentage:"percentage"},Dn={yearMonthDayHourMinuteSecond:"YYYY-MM-DD HH:mm:ss",yearMonthDayHourMinute:"YYYY-MM-DD HH:mm",yearMonthDay:"YYYY-MM-DD",yearMonth:"YYYY-MM",year:"YYYY",monthDayHourMinuteSecond:"YYYY-MM-DD HH:mm:ss",monthDayHourMinute:"MM-DD HH:mm",monthDay:"MM-DD",hourMinute:"HH:mm",hourMinuteSecond:"HH:mm:ss",month:"MM",day:"DD",hour:"HH",minute:"mm",second:"ss"},Cn={moveUp:"moveUp",moveDown:"moveDown"},En={no:"0",yes:"1"},On={no:0,yes:1},In={trace:"trace",debug:"debug",warn:"warn",error:"error",info:"info",config:"config",execute:"execute"},jn={auto:"auto",text:"text",object:"object"},kn={success:"success",error:"error",info:"info",warning:"warning",warn:"warn",open:"open"},Nn=bt({},kn),Tn=bt({},kn),Pn="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGQAAABLCAYAAACGGCK3AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAA0SURBVHhe7cExAQAAAMKg9U9tDQ8gAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAIA3NXV7AAHfw7zWAAAAAElFTkSuQmCC",Yn=Pn;function Fn(t){return U(t,{algorithm:"sha1"})}function Bn(t){return U(t,{algorithm:"md5"})}function Hn(t,n){var r=Math.pow(10,n+1),e=Math.floor(Un(t)*r);return 10*Math.round(e/10)/r}function Un(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,r=B(t),e=Number.isNaN(r)?0:r;return null==(n||null)?e:Hn(e,n)}function Wn(t,n,r){if(!Zt(t))throw new Error("value must be number value");var e=Un(t);return void 0!==n&&(e=Math.max(t,n)),void 0!==r&&(e=Math.min(e,r)),e}function Ln(t){return $t(t)?parseFloat(t,10):0}function Rn(t){return"".concat(Ln(1e3*Un(t)/10),"%")}function Kn(t){return H(t)}function Qn(t){return!!t}function Gn(t){return Kn(t).toUpperCase()}function Jn(t){return Kn(t).toLowerCase()}function Vn(t){if(null==(t||null))return null;if(on(t))return t;if(an(t)&&t.indexOf("T")<0){var n=t.replace(/\-/g,"/");return new Date(n)}return new Date(t)}function zn(t){return sn(t)?t:Promise.resolve(t)}function qn(t,n){return xt(t,n)}function Zn(t){var n=t.target,r=t.convert;if(tn(r))return r(n);if(an(r))switch(r){case Sn.number:return Un(n);case Sn.datetime:return Vn(n);case Sn.string:return Kn(n);case Sn.money:return Ln(n);case Sn.array:return null==(n||null)?[]:un(n)?n:[n];default:return n}return n}function $n(t,n){(null==n||n>t.length)&&(n=t.length);for(var r=0,e=new Array(n);r<n;r++)e[r]=t[r];return e}function Xn(t,n){if(t){if("string"==typeof t)return $n(t,n);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?$n(t,n):void 0}}function _n(t){return function(t){if(Array.isArray(t))return $n(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||Xn(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function tr(t){return new Function("return ".concat(t))()}function nr(){var t=navigator.userAgent;return{trident:t.indexOf("Trident")>-1,presto:t.indexOf("Presto")>-1,webKit:t.indexOf("AppleWebKit")>-1,gecko:t.indexOf("Gecko")>-1&&-1===t.indexOf("KHTML"),mobile:!!t.match(/AppleWebKit.*Mobile.*/),ios:!!t.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/),android:t.indexOf("Android")>-1||t.indexOf("Linux")>-1,iPhone:t.indexOf("iPhone")>-1,iPad:t.indexOf("iPad")>-1,webApp:-1===t.indexOf("Safari")}}function rr(){var t;return{versions:nr(),language:(null!==(t=navigator.browserLanguage||navigator.language)&&void 0!==t?t:"").toLowerCase()}}function er(t){var n=t.seed,r=t.min||0;return r+(9301*n+49297)%233280/233280*((t.max||1)-r)}function or(t){return null==t?null:JSON.parse(JSON.stringify(t))}function ar(t,n,r){var e=[];return null!=t&&(e=_n(t)),null!=r&&(e=[].concat(_n(e),_n(r))),null!=n&&(e=[n].concat(_n(e))),e}function ir(t,n,r,e,o){var a=e,i=void 0===r?null:r;return null!=n&&("function"==typeof convertValue?a.initialValue=o(t)||i:a.initialValue=t||i),a}function ur(t,n,r){var e=null;return null==n||(r||[]).forEach((function(r){r[t]===n&&(e=r)})),e}function cr(){var t,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:8,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:16,e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz".split(""),o=[],a=0;if(r=r||e.length,n)for(a=0;a<n;a++)o[a]=e[0|Math.random()*r];else for(o[8]=o[13]=o[18]=o[23]="-",o[14]="4",a=0;a<36;a++)o[a]||(t=0|16*Math.random(),o[a]=e[19===a?3&t|8:t]);return o.join("")}function lr(t){var n=t.pageNo,r=t.pageSize,e=t.total;return!((e||0)<=0)&&(n||0)*(r||0)<(e||0)}function sr(){return"development"===process.env.NODE_ENV}function fr(t){return Object.keys(t).map((function(n){return t[n]})).join(",")}function dr(t,n){for(var r=arguments.length,e=new Array(r>2?r-2:0),o=2;o<r;o++)e[o-2]=arguments[o];var a=[t].concat(e).filter((function(t){return an(t)&&!hn(t)}));return"".concat(a.join("::"),"::").concat(hn(n)?"":n)}var hr="loggerAssist",gr={loggerDisplaySwitchPromptSetInformationComplete:!1,loggerDisplaySwitchSetComplete:!1,display:!1},mr={config:"#F8C471",execute:"#C39BD3",info:"#89ca78",warn:"#ff4f49",debug:"#00768f",trace:"#596032"};function vr(t){var n=t.text,r=t.color,e=void 0===r?"":r,o=t.dataDescription,a=void 0===o?"":o,i=t.ancillaryInformation,u=void 0===i?"":i,c=function(t,n){return"".concat(Kn(t)).concat(hn(n)?"":" -> ".concat(n))}(an(n)?n:JSON.stringify(n),u);hn(vr)||console.log("%c%s","color:".concat(e,";"),"".concat(hn(a)?"":"[".concat(Gn(a),"] ")).concat(c))}function pr(t){var n=t.data,r=t.color,e=void 0===r?"":r,o=t.dataDescription,a=void 0===o?"":o,i=t.ancillaryInformation;vr({text:"check the following object data",color:e,dataDescription:a,ancillaryInformation:void 0===i?"":i}),console.log(n)}function yr(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:jn.auto,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:In.debug,e=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"",o=Or();if(!gr.loggerDisplaySwitchSetComplete&&!gr.loggerDisplaySwitchPromptSetInformationComplete){var a=dr(mn,"logData -> logger display switch default is false, if want to display log, please set it before first log, use setLoggerDisplaySwitch to set it, this message only show once",hr);vr({text:a,color:"#08BBEE",dataDescription:"hint",ancillaryInformation:""});try{throw new Error("please set use setLoggerDisplaySwitch")}catch(t){console.error(t)}gr.loggerDisplaySwitchPromptSetInformationComplete=!0}if(o||r===In.error){var i=null==(n||null)||hn(n)?jn.auto:n;if(!gn([jn.auto,jn.text,jn.object],i))throw new Error("Invalid log display mode -> ".concat(i));if(i===jn.auto&&(i=an(t)?jn.text:jn.object),r===In.error){if(i===jn.text){var u="error -> ".concat(t).concat(hn(e)?"":", ".concat(Gn(e)),".");console.error(u)}i===jn.object&&console.error({error:t})}o&&(r===In.trace&&(i===jn.text&&vr({text:t,color:mr.trace,dataDescription:"trace",ancillaryInformation:e}),i===jn.object&&pr({data:t,color:mr.trace,dataDescription:"trace",ancillaryInformation:e})),r===In.debug&&(i===jn.text&&vr({text:t,color:mr.debug,dataDescription:"debug",ancillaryInformation:e}),i===jn.object&&pr({data:t,color:mr.debug,dataDescription:"debug",ancillaryInformation:e})),r===In.warn&&(i===jn.text&&vr({text:t,color:mr.warn,dataDescription:"warn",ancillaryInformation:e}),i===jn.object&&pr({data:t,color:mr.warn,dataDescription:"warn",ancillaryInformation:e})),r===In.info&&(i===jn.text&&vr({text:t,color:mr.info,dataDescription:"info",ancillaryInformation:e}),i===jn.object&&pr({data:t,color:mr.info,dataDescription:"info",ancillaryInformation:e})),r===In.execute&&(i===jn.text&&vr({text:t,color:mr.execute,dataDescription:"execute",ancillaryInformation:e}),i===jn.object&&pr({data:t,color:mr.execute,dataDescription:"execute",ancillaryInformation:e})),r===In.config&&(i===jn.text&&vr({text:t,color:mr.config,dataDescription:"config",ancillaryInformation:e}),i===jn.object&&pr({data:t,color:mr.config,dataDescription:"config",ancillaryInformation:e})))}}function wr(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";an(t)?Cr(t,In.warn,n):Er(t,In.warn,n)}function br(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";an(t)?Cr(t,In.info,n):Er(t,In.info,n)}function Ar(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";an(t)?Cr(t,In.config,n):Er(t,In.config,n)}function xr(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";an(t)?Cr(t,In.trace,n):Er(t,In.trace,n)}function Sr(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";an(t)?Cr(t,In.debug,n):Er(t,In.debug,n)}function Mr(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";an(t)?Cr(t,In.execute,n):Er(t,In.execute,n)}function Dr(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";an(t)?Cr(t,In.error,n):Er(t,In.error,n)}function Cr(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:In.trace,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"";yr(t,jn.text,n,r)}function Er(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:In.trace,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"";yr(t,jn.object,n,r)}function Or(){return Qn(gr.display)}function Ir(t){sr()&&vr({text:"setLoggerDisplaySwitch",color:mr.execute,dataDescription:"execute",ancillaryInformation:""}),gr.display=Qn(t),gr.loggerDisplaySwitchSetComplete=!0}var jr={mountComplete:!1,target:null};function kr(n){if(Mr("setCacheMount"),!cn(n))throw Sr(n),new Error(dr(mn,"setCacheMount -> cache mount target must be a object, current type is ".concat(vt(n)),"cacheAssist"));null==(n.localRuntimeCache||null)&&(n.localRuntimeCache=new t),jr.target=n,jr.mountComplete=!0,br("setCacheMount -> cache mount success.")}function Nr(t){if(hn(t))throw new Error("checkKey -> cache key is null or empty.");if(!an(t)&&!Zt(t))throw Dr(t),new Error("checkKey -> cache key must be string or number,you can check it in console.")}function Tr(){if(!jr.mountComplete||!jr.target||!jr.target.localRuntimeCache)throw new Error("getCachePool -> please use setCacheMount function to set cache mount target before get it.");return jr.target.localRuntimeCache}function Pr(t){var n=t.key,r=Tr();if(null==r)throw new Error("cache pool not exist");return r.has(n)}function Yr(t){var n=t.key,r=t.value,e=t.expiration,o=void 0===e?0:e;Nr(n);var a=Tr();if(null==a)throw new Error("cache pool not exist");return a.set(n,r,o)}function Fr(t){if(!un(t))throw new Error("setMultiCache: list must be array");if(t.length<=0)return!0;var n=[];if(t.forEach((function(t){var r=bt(bt({},{key:"",value:"",expiration:0}),t),e=r.key,o=r.value,a=r.expiration;hn(e)||(Nr(e),n.push({key:e,value:o,ttl:a}))})),n.length<=0)return!1;var r=Tr();if(null==r)throw new Error("cache pool not exist");return r.mset(n)}function Br(t){var n=t.key,r=Tr();if(null==r)throw new Error("cache pool not exist");return r.getTtl(n)}function Hr(t){var n=t.key,r=t.expiration,e=Tr();if(null==e)throw new Error("cache pool not exist");return e.ttl(n,r)}function Ur(t){var n=t.key,r=Tr();if(null==r)throw new Error("cache pool not exist");return r.get(n)}function Wr(){var t=Tr();if(null==t)throw new Error("cache pool not exist");return t.keys()}function Lr(t){if(!un(t))throw new Error("getMultiCache: list must be array");var n=Tr();if(null==n)throw new Error("cache pool not exist");return n.mget(t)}function Rr(t){var n=t.key,r=Tr();if(null==r)throw new Error("cache pool not exist");return r.take(n)}function Kr(t){var n=t.key;Nr(n);var r=Tr();if(null==r)throw new Error("cache pool not exist");return r.del(n)}function Qr(t){if(!un(t))throw new Error("deleteMultiCache: list must be array");var n=Tr();if(null==n)throw new Error("cache pool not exist");return n.del(t)}function Gr(){var t=Tr();if(null==t)throw new Error("cache pool not exist");return t.flushAll()}function Jr(){var t=Tr();if(null==t)throw new Error("cache pool not exist");return t.getStats()}function Vr(t,n){return function(t){if(Array.isArray(t))return t}(t)||function(t,n){var r=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=r){var e,o,a,i,u=[],c=!0,l=!1;try{if(a=(r=r.call(t)).next,0===n){if(Object(r)!==r)return;c=!1}else for(;!(c=(e=a.call(r)).done)&&(u.push(e.value),u.length!==n);c=!0);}catch(t){l=!0,o=t}finally{try{if(!c&&null!=r.return&&(i=r.return(),Object(i)!==i))return}finally{if(l)throw o}}return u}}(t,n)||Xn(t,n)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function zr(t){var n=t.seed;return"#".concat("00000".concat((16777216*er({seed:n})<<0).toString(16)).substring(-6))}function qr(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"RGB",r=arguments.length>2&&void 0!==arguments[2]&&arguments[2],e=/^#([0-9a-fA-f]{3}|[0-9a-fA-f]{6})$/,o=(null!=t?t:"").toLowerCase();if(e.test(o)){if(4===o.length){for(var a="#",i=1;i<4;i+=1)a+=o.slice(i,i+1).concat(o.slice(i,i+1));o=a}for(var u=[],c=1;c<7;c+=2)u.push(parseInt("0x"+o.slice(c,c+2)));return n?"".concat(n,"(").concat(u.join(","),")"):r?u:u.join(",")}return Dr("Invalid hex color -> ".concat(t)),o}function Zr(t){var n=t.progress,r=t.startColor,e=t.endColor,o=qr(r,null,!0),a=qr(e,null,!0),i=Vr(o,3),u=i[0],c=i[1],l=i[2],s=Vr(a,3),f=s[0],d=s[1],h=s[2],g=[(u+Math.round((f-u)*n)).toString(16),(c+Math.round((d-c)*n)).toString(16),(l+Math.round((h-l)*n)).toString(16)];return"#".concat(g.join("").toUpperCase())}function $r(t){var n=t.direct,r=t.list,e=void 0===r?[]:r,o=Zt(n)?"".concat(n,"deg"):n;return"linear-gradient(".concat(o,", ").concat(e.join(),")")}function Xr(t,n){var r=Vn(t);return r.setHours(r.getHours()+n)}function _r(t,n){var r=Vn(t);return r.setMinutes(r.getMinutes()+n)}function te(t,n){var r=Vn(t);return r.setSeconds(r.getSeconds()+n)}function ne(){return new Date}function re(t,n){var r=t.getTime(),e=(n.getTime()-r)/1e3,o=parseInt(e/86400),a=parseInt((e-24*o*60*60)/3600),i=parseInt((e-24*o*60*60-60*a*60)/60);return{day:o,hour:a,minute:i,second:e-24*o*60*60-60*a*60-60*i}}var ee=function(t,n,r){var e=Vn(t),o=n?Vn(n):new Date,a=o.getTime()-e.getTime();return"second"===r&&a/1e3||"minute"===r&&a/1e3/60||"hour"===r&&a/1e3/60/60||"day"===r&&a/1e3/60/60/24||"week"===r&&a/1e3/60/60/24/7||"month"===r&&oe(e,o)||"quarter"===r&&oe(e,o)/3||"year"===r&&oe(e,o)/12||a},oe=function(t,n){var r=Vn(t),e=Vn(n);return 12*(r.getFullYear()-e.getFullYear())+r.getMonth()-e.getMonth()};function ae(t){var n=t.data;return W(n).day()}function ie(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],n=W().day();if(!t)return n;var r="";switch(Un(n)){case 0:r="日";break;case 1:r="一";break;case 2:r="二";break;case 3:r="三";break;case 4:r="四";break;case 5:r="五";break;case 6:r="六";break;default:r=""}return hn(r)?"":"星期".concat(r)}function ue(t){var n=t.data,r=t.places,e=void 0===r?2:r,o=t.thousand,a=void 0===o?",":o,i=t.decimal;return ce({data:n,places:e,symbol:"",thousand:a,decimal:void 0===i?".":i})}function ce(t){var n=t.data,r=t.places,e=void 0===r?2:r,o=t.symbol,a=void 0===o?"¥":o,i=t.thousand,u=void 0===i?",":i,c=t.decimal,l=void 0===c?".":c,s=n||0,f=isNaN(e=Math.abs(e))?2:e,d=void 0!==a?a:"¥",h=u||",",g=l||".",m=s<0?"-":"",v=parseInt(s=Math.abs(+s||0).toFixed(f),10)+"",p=v.length;return d+m+((p=p>3?p%3:0)?v.substr(0,p)+h:"")+v.substr(p).replace(/(\d{3})(?=\d)/g,a+"1"+h)+(f?g+Math.abs(s-Un(v)).toFixed(f).slice(2):"")}function le(t){var n,r,e,o=t.target,a=["零","壹","贰","叁","肆","伍","陆","柒","捌","玖"],i=["","拾","佰","仟"],u=["","万","亿","兆"],c=["角","分","毫","厘"],l="";if(""===o)return"";if((o=parseFloat(o))>=1e15)return"超出最大处理数字";if(0===o)return l=a[0]+"元";if(-1===(o=o.toString()).indexOf("."))n=o,r="";else{var s=Vr(e=o.split("."),2);n=s[0],r=s[1],r=e[1].substr(0,4)}if(parseInt(n,10)>0){for(var f=0,d=n.length,h=0;h<d;h+=1){var g=n.substr(h,1),m=d-h-1,v=m/4,p=m%4;"0"===g?f+=1:(f>0&&(l+=a[0]),f=0,l+=a[parseInt(g,10)]+i[p]),0===p&&f<4&&(l+=u[v])}l+="元"}if(""!==r)for(var y=r.length,w=0;w<y;w+=1){var b=r.substr(w,1);"0"!==b&&(l+=a[Number(b)]+c[w])}return""===l&&(l+=a[0]+"元"),l}function se(t){var n=t.data,r=t.fmt,e=void 0===r?Dn.yearMonthDayHourMinuteSecond:r;return null==(n||null)?"":W(n).format(e)}function fe(t){var n=t.target,r=t.format,e=t.option,o=void 0===e?{}:e;if(tn(r))return r(n);if(an(r))switch(r){case Mn.money:return ce({data:n});case Mn.datetime:return se({data:n});case Mn.chineseMoney:return le({target:n,option:o});case Mn.percentage:return"".concat(qn(100*n,1),"%");default:return n}return n}function de(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},e=bt(bt({},{second:["刚刚","片刻后"],seconds:["%d 秒前","%d 秒后"],minute:["大约 1 分钟前","大约 1 分钟后"],minutes:["%d 分钟前","%d 分钟后"],hour:["大约 1 小时前","大约 1 小时后"],hours:["%d 小时前","%d 小时后"],day:["1 天前","1 天后"],days:["%d 天前","%d 天后"],month:["大约 1 个月前","大约 1 个月后"],months:["%d 月前","%d 月后"],year:["大约 1 年前","大约 1 年后"],years:["%d 年前","%d 年后"]}),r||{}),o=ee(t,n),a=o<0?1:0,i=Math.abs(o)/1e3,u=i/60,c=u/60,l=c/24,s=l/365,f=function(t,n){return t.replace(/%d/i,n)};return i<10&&f(e.second[a],parseInt(i))||i<45&&f(e.seconds[a],parseInt(i))||i<90&&f(e.minute[a],1)||u<45&&f(e.minutes[a],parseInt(u))||u<90&&f(e.hour[a],1)||c<24&&f(e.hours[a],parseInt(c))||c<42&&f(e.day[a],1)||l<30&&f(e.days[a],parseInt(l))||l<45&&f(e.month[a],1)||l<365&&f(e.months[a],parseInt(l/30))||s<1.5&&f(e.year[a],1)||f(e.years[a],parseInt(s))}function he(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return de(t,ne(),n)}function ge(t){return hn(t.text||null)&&wr(dr(mn,"checkMessagePromptData option text disallow empty","loggerAssist")),!0}var me={showOpenMessage:function(t){var n=t.text;t.duration,t.onClose,br({text:n})},showInfoMessage:function(t){var n=t.text;t.duration,t.onClose,br({text:n})},showSuccessMessage:function(t){var n=t.text;t.duration,t.onClose,br({text:n})},showWarnMessage:function(t){var n=t.text;t.duration,t.onClose,wr(n)},showWarningMessage:function(t){var n=t.text;t.duration,t.onClose,wr(n)},showErrorMessage:function(t){var n=t.text;t.duration,t.onClose,Dr(n)}};function ve(t){me.showOpenMessage=t}function pe(t){me.showInfoMessage=t}function ye(t){me.showSuccessMessage=t}function we(t){me.showWarnMessage=t}function be(t){me.showWarningMessage=t}function Ae(t){me.showErrorMessage=t}function xe(t){var n=t.text,r=t.duration,e=void 0===r?1500:r,o=t.onClose,a=void 0===o?function(){}:o;tn(me.showOpenMessage)&&(ge({text:n}),me.showOpenMessage({text:n,duration:e,onClose:a}))}function Se(t){var n=t.text,r=t.duration,e=void 0===r?1500:r,o=t.onClose,a=void 0===o?function(){}:o;tn(me.showInfoMessage)&&(ge({text:n}),me.showInfoMessage({text:n,duration:e,onClose:a}))}function Me(t){var n=t.text,r=t.duration,e=void 0===r?1500:r,o=t.onClose,a=void 0===o?function(){}:o;tn(me.showSuccessMessage)&&(ge({text:n}),me.showSuccessMessage({text:n,duration:e,onClose:a}))}function De(t){var n=t.text,r=t.duration,e=void 0===r?1500:r,o=t.onClose,a=void 0===o?function(){}:o;tn(me.showWarnMessage)&&(ge({text:n}),me.showWarnMessage({text:n,duration:e,onClose:a}))}function Ce(t){var n=t.text,r=t.duration,e=void 0===r?1500:r,o=t.onClose,a=void 0===o?function(){}:o;tn(me.showWarningMessage)&&(ge({text:n}),me.showWarningMessage({text:n,duration:e,onClose:a}))}function Ee(t){var n=t.text,r=t.duration,e=void 0===r?1500:r,o=t.onClose,a=void 0===o?function(){}:o;tn(me.showErrorMessage)&&(ge({text:n}),me.showErrorMessage({text:n,duration:e,onClose:a}))}function Oe(t){Ee({text:t})}function Ie(t){var n=t.text,r=t.showStack,e=void 0===r||r;try{if(hn(n||"")||(Ee({text:n}),Dr({text:n})),e)throw new Error("".concat(hn(n||"")?"":"".concat(Kn(n),", "),"call stack:"))}catch(t){console.log(t.stack)}}function je(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"...";return t&&t.length>n?"".concat(Kn(t).substring(0,n)).concat(r):Kn(t)}function ke(t,n,r,e){var o=Kn(t),a=(t||"").length;a>0&&(r>=0||e>=0)&&(o=r>=a||e>=a||(r||0)+(e||0)>=a?t:t.substr(0,r)+n+t.substr(a-e,e));return o||""}function Ne(t,n){for(var r=(new Date).getTime();!((new Date).getTime()-r>t););tn(n)&&n()}function Te(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;if(rn(t))return r;if(null==t)return r;if(!an(n)){var e="getPathValue Function param path must be string";return Ie({message:e}),null}var o=At(t,n,r);return rn(r)||en(r)?o:o||r}function Pe(t,n){if(!an(t))throw new Error("removeEndMatch only use for string target");if(!an(n))throw new Error("removeEndMatch only use for string match");if(hn(t))return t;if(hn(n))return t;var r=t.lastIndexOf(n);return r>=0&&t.length===r+n.length?t.substr(r,n.length):t}function Ye(t,n){if(!an(t))throw new Error("removeEndMatch only use for string source");if(!an(n))throw new Error("removeEndMatch only use for string target");if(hn(t))return t;if(hn(n))return t;var r=t.lastIndexOf(n);return r>=0?t.substr(r,n.length):t}function Fe(t){var n=t.data,r=t.key,e=t.defaultValue,o=void 0===e?null:e,a=t.convert,i=void 0===a?null:a,u=t.convertBuilder,c=void 0===u?null:u,l=t.format,s=void 0===l?null:l,f=t.formatBuilder,d=void 0===f?null:f,h=Te(n,r,o),g=h;return null==(c||null)&&null==(i||null)||(g=tn(c)?Zn({target:h,convert:c}):Zn({target:h,convert:i})),null==(d||null)&&null==(s||null)||(g=tn(d)?fe({target:g,format:d}):fe({target:g,format:s})),g}function Be(t){var n=t.operate,r=t.item,e=t.list,o=t.key,a=t.sortInitialValue,i=void 0===a?0:a;if(null==(r||null))return e;var u=[],c=[],l=[];if((e||[]).length<=1){return De({message:"无需排序!"}),e}var s=Fe({data:r,key:o,convert:Sn.number});switch((e||[]).forEach((function(t){var n=Fe({data:t,key:o,convert:Sn.number});n<s&&u.push(t),n>s&&c.push(t)})),n){case Cn.moveUp:if(s===i){return De({message:"已经排在首位!"}),e}(u||[]).forEach((function(t,n){if(n<u.length-1)l.push(t);else{var e=r;e[o]-=1,l.push(e);var a=t;a[o]+=1,l.push(a)}})),l=l.concat(c);break;case Cn.moveDown:if(s===(e||[]).length+i-1){return De({message:"已经排在末位!"}),e}l=l.concat(u),(c||[]).forEach((function(t,n){if(0===n){var e=t;e[o]-=1,l.push(e);var a=r;a[o]+=1,l.push(a)}else l.push(t)}));break;default:De({message:"不符合的操作, 允许的操作为['".concat(Cn.moveUp,"','").concat(Cn.moveDown,"']!")})}return l}function He(t){var n=t.list,r=void 0===n?[]:n,e=t.convert,o=void 0===e?null:e,a=t.recursiveKey,i=void 0===a?"children":a;return(un(r)?r:[r]).map((function(t){return Ue({data:t,convert:o,target:i})}))}function Ue(t){var n=t.data,r=t.convert,e=void 0===r?null:r,o=t.recursiveKey,a=void 0===o?"children":o;if(!tn(e))return n;var i=e(n),u=n[a],c=[];return un(u)&&(c=u.map((function(t){return Ue({data:t,convert:e,target:a})}))),i[a]=c,i}function We(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,e=Vt(t,n,r);return!rn(e)}function Le(){function t(t,n){return rn(n)?t:n}for(var n=Ct({},arguments.length<=0?void 0:arguments[0]),r=1;r<arguments.length;r++)n=Et(n,r<0||arguments.length<=r?void 0:arguments[r],t);return n}function Re(t){if(t&&"object"===vt(t)){var n="";return Object.keys(t).forEach((function(r){var e,o=(null!==(e=r.replace(/([A-Z])/g,"-$1"))&&void 0!==e?e:"").toLowerCase();n+="".concat(o,":").concat(t[r],";")})),n}return t&&"string"==typeof t?t:""}function Ke(t,n){return t&&"object"===vt(t)&&n&&"object"===vt(n)?Object.assign({},t,n):Re(t)+Re(n)}function Qe(t,n){var r=t;for(var e in n)n.hasOwnProperty(e)&&(r[e]=n[e]);return r}var Ge="htmlAssist";function Je(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:5,e=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0;if(!Zt(t))return t;if(!Zt(n)||n<=0)throw new Error(dr(mn,"pxToRem -> root value must be number and greater than 0, current root value [".concat(n,"] is invalid"),Ge));var o=parseFloat(t);if(o<e)return t;var a=Un(o/n,r);return 0===a?"0":a+"rem"}var Ve="localStorageAssist",ze={getStorage:function(t){Dr(dr(mn,"setStorageGetter need config, use setStorageGetter to set it",Ve))},setStorage:function(t,n){Dr(dr(mn,"setStorageSetter need config, use setStorageSetter to set it",Ve))},removeStorage:function(t){Dr(dr(mn,"setStorageRemover need config, use setStorageRemover to set it",Ve))},flushStorage:function(){Dr(dr(mn,"setStorageFlusher need config, use setStorageFlusher to set it",Ve))}};function qe(t){ze.getStorage=t}function Ze(t){ze.setStorage=t}function $e(t){ze.removeStorage=t}function Xe(t){ze.flushStorage=t}function _e(t){try{return ze.getStorage(t)}catch(n){throw Dr({key:t,e:n}),n}}function to(t){var n=_e(t);return hn(n)?null:JSON.parse(n||"{}")}function no(t,n){ze.setStorage(t,n)}function ro(t,n){ze.setStorage(t,JSON.stringify(n||{}))}function eo(t){ze.removeStorage(t)}function oo(){ze.flushStorage()}var ao=function(t){var n=t.text;t.duration,t.onClose,br({text:n})};var io="nearestLocalhostNotify";function uo(){var t=to(io);return null==(t||null)||null==(t.nearestTime||null)?null:t||null}function co(){return ro(io,{nearestTime:parseInt((new Date).getTime()/1e3,10)})}function lo(){eo(io)}function so(t){var n=t.text,r=!1,e=0,o=uo()||null;null==o?r=!0:e=o.nearestTime||0;var a=parseInt((new Date).getTime()/1e3,10);try{if(e+30<a&&(r=!0),r){var i="当前接口域名: ".concat(n,". ");!function(t){var n=t.text,r=t.duration,e=void 0===r?1500:r,o=t.onClose,a=void 0===o?function(){}:o;tn(ao)&&ao({text:n,duration:e,onClose:a})}({text:i}),Cr({message:i}),co()}}catch(t){yr(t)}}function fo(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",r=L(t);if(hn(n))return r;if(hn(r))return n;var e=n.lastIndexOf("?")>=0?"&":"?";return"".concat(n).concat(e).concat(r)}function ho(t){return R(t)}function go(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"";return"请".concat(n||"输入").concat(t).concat(hn(r)?"":",".concat(r))}function mo(t){var n=t.label,r=t.name,e=t.helper,o="",a="",i="";if(an(n))o=n;else{wr({label:n,name:r,helper:e}),Ie({message:"label必须为文本"})}if(an(r))a=r;else{wr({label:n,name:r,helper:e}),Ie({message:"name必须为文本"})}if(an(e))i=e;else{wr({label:n,name:r,helper:e}),Ie({message:"helper必须为文本"})}return{label:o,name:a,helper:i}}function vo(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"注: ";return"".concat(n).concat(t,". ")}export{Xr as addHour,_r as addMinute,te as addSecond,Ct as assign,Et as assignWith,Qe as attachPropertiesToComponent,go as buildFieldDescription,vo as buildFieldHelper,Zr as buildHexColor,$r as buildLinearGradient,dr as buildPromptModuleInfo,fo as buildQueryStringify,qr as buildRGBColorFromHexColor,zr as buildRandomHexColor,Re as buildStringStyle,jr as cacheMountTarget,ee as calculateDateInterval,oe as calculateMonthInterval,re as calculateTimeInterval,We as checkExist,mo as checkFromConfig,lr as checkHasMore,gn as checkInCollection,ge as checkMessagePromptData,hn as checkStringIsNullOrWhiteSpace,sr as checkWhetherDevelopmentEnvironment,or as cloneWithoutMethod,Sn as convertCollection,Je as convertPixelToRem,Dn as datetimeFormat,ht as decodeBase64,Kr as deleteCache,Qr as deleteMultiCache,Kt as difference,pr as displayObjectMessage,vr as displayTextMessage,Yt as dropRight,je as ellipsis,xn as emptyDatetime,gt as encodeBase64,St as endsWith,vn as envCollection,Yn as errorImage,tr as evil,Qt as filter,Vt as find,Jt as findIndex,Tt as first,mt as fixedZero,Nt as floor,Gr as flushAllCache,oo as flushLocalStorage,It as forEach,Mn as formatCollection,de as formatDateInterval,he as formatDateIntervalWithNow,se as formatDatetime,ue as formatDecimal,ce as formatMoney,le as formatMoneyToChinese,fe as formatTarget,At as get,rr as getBrowserInfo,nr as getBrowserVersion,Ur as getCache,Tr as getCachePool,ae as getDayOfWeek,Br as getExpiration,cr as getGuid,to as getJsonFromLocalStorage,Or as getLoggerDisplaySwitch,Lr as getMultiCache,uo as getNearestLocalhostNotifyCache,ne as getNow,Te as getPathValue,_e as getStringFromLocalStorage,ie as getTodayOfWeek,fr as getValue,Fe as getValueByKey,jt as gte,Pr as hasCache,un as isArray,nn as isBoolean,on as isDate,qt as isDatetime,Xt as isEqual,_t as isEqualBySerialize,tn as isFunction,dn as isImageBase4,zt as isInvalid,$t as isMoney,en as isNull,Zt as isNumber,cn as isObject,ln as isPlainObject,sn as isPromise,an as isString,rn as isUndefined,fn as isUrl,Wr as keys,ze as localStorageAssist,mr as logColorCollection,Ar as logConfig,yr as logData,Sr as logDebug,jn as logDisplay,Dr as logError,Mr as logExecute,br as logInfo,In as logLevel,Er as logObject,Cr as logText,xr as logTrace,wr as logWarn,gr as loggerSwitch,Wt as map,kt as memoize,Le as mergeProps,Ke as mergeStyle,me as messagePromptAssist,Tn as messageTypeCollection,Nn as notificationTypeCollection,ho as parseQueryString,ar as refitCommonData,ir as refitFieldDecoratorOption,Pe as removeEndMatch,Ut as removeFromArray,Ye as removeLastMatch,eo as removeLocalStorage,lo as removeNearestLocalhostNotifyCache,Ht as replace,ke as replaceWithKeep,wn as requestMethod,Ot as reverse,xt as round,ro as saveJsonToLocalStorage,no as saveStringToLocalStorage,ur as searchFromList,er as seededRandom,Lt as set,Yr as setCache,kr as setCacheMount,Ae as setErrorMessageDisplayMonitor,Hr as setExpiration,pe as setInfoMessageDisplayMonitor,Ir as setLoggerDisplaySwitch,Fr as setMultiCache,co as setNearestLocalhostNotifyCache,ve as setOpenMessageDisplayMonitor,Xe as setStorageFlusher,qe as setStorageGetter,$e as setStorageRemover,Ze as setStorageSetter,ye as setSuccessMessageDisplayMonitor,we as setWarnMessageDisplayMonitor,be as setWarningMessageDisplayMonitor,Oe as showError,Ee as showErrorMessage,Se as showInfoMessage,xe as showOpenMessage,Ie as showRuntimeError,Me as showSuccessMessage,De as showWarnMessage,Ce as showWarningMessage,Rt as size,Ne as sleep,Gt as sortBy,Be as sortCollectionByKey,Cn as sortOperate,Mt as sortedUnique,Dt as split,Pt as startsWith,Jr as statisticsCache,Rr as takeCache,Zn as to,Qn as toBoolean,Wn as toBoundary,Vn as toDatetime,Jn as toLower,Bn as toMd5,Ln as toMoney,Un as toNumber,Rn as toPercentage,zn as toPromise,qn as toRound,Fn as toSha1,Kn as toString,Gn as toUpper,Ue as transformData,He as transformListData,Pn as transparentImage,Bt as trim,so as trySendNearestLocalhostNotify,yn as underlyingExtensionState,pn as underlyingState,Ft as uniqBy,On as whetherNumber,En as whetherString,An as zeroInt,bn as zeroString};
1
+ import t from"node-cache";import e from"lodash/isBoolean";import n from"lodash/isDate";import r from"lodash/isEqual";import o from"lodash/isFunction";import a from"lodash/isNull";import i from"lodash/isNumber";import u from"lodash/isObject";import c from"lodash/isString";import l from"lodash/isUndefined";import s from"lodash/replace";import f from"lodash/assign";import d from"lodash/assignWith";import h from"lodash/difference";import m from"lodash/dropRight";import g from"lodash/endsWith";import v from"lodash/filter";import p from"lodash/find";import y from"lodash/findIndex";import w from"lodash/first";import b from"lodash/floor";import x from"lodash/forEach";import A from"lodash/get";import S from"lodash/gte";import M from"lodash/map";import D from"lodash/memoize";import C from"lodash/remove";import E from"lodash/reverse";import I from"lodash/round";import O from"lodash/set";import j from"lodash/size";import k from"lodash/sortBy";import N from"lodash/sortedUniq";import T from"lodash/split";import P from"lodash/startsWith";import F from"lodash/trim";import Y from"lodash/uniqBy";import B from"lodash/toNumber";import H from"lodash/toString";import U from"object-hash";import W from"dayjs";import{stringify as L,parse as R}from"qs";var K,Q="function"==typeof atob,G="function"==typeof btoa,J="function"==typeof Buffer,V="function"==typeof TextDecoder?new TextDecoder:void 0,z="function"==typeof TextEncoder?new TextEncoder:void 0,q=Array.prototype.slice.call("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="),Z=(K={},q.forEach((function(t,e){return K[t]=e})),K),$=/^(?:[A-Za-z\d+\/]{4})*?(?:[A-Za-z\d+\/]{2}(?:==)?|[A-Za-z\d+\/]{3}=?)?$/,X=String.fromCharCode.bind(String),_="function"==typeof Uint8Array.from?Uint8Array.from.bind(Uint8Array):function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(t){return t};return new Uint8Array(Array.prototype.slice.call(t,0).map(e))},tt=function(t){return t.replace(/=/g,"").replace(/[+\/]/g,(function(t){return"+"==t?"-":"_"}))},et=function(t){return t.replace(/[^A-Za-z0-9\+\/]/g,"")},nt=G?function(t){return btoa(t)}:J?function(t){return Buffer.from(t,"binary").toString("base64")}:function(t){for(var e,n,r,o,a="",i=t.length%3,u=0;u<t.length;){if((n=t.charCodeAt(u++))>255||(r=t.charCodeAt(u++))>255||(o=t.charCodeAt(u++))>255)throw new TypeError("invalid character found");a+=q[(e=n<<16|r<<8|o)>>18&63]+q[e>>12&63]+q[e>>6&63]+q[63&e]}return i?a.slice(0,i-3)+"===".substring(i):a},rt=J?function(t){return Buffer.from(t).toString("base64")}:function(t){for(var e=[],n=0,r=t.length;n<r;n+=4096)e.push(X.apply(null,t.subarray(n,n+4096)));return nt(e.join(""))},ot=function(t){if(t.length<2)return(e=t.charCodeAt(0))<128?t:e<2048?X(192|e>>>6)+X(128|63&e):X(224|e>>>12&15)+X(128|e>>>6&63)+X(128|63&e);var e=65536+1024*(t.charCodeAt(0)-55296)+(t.charCodeAt(1)-56320);return X(240|e>>>18&7)+X(128|e>>>12&63)+X(128|e>>>6&63)+X(128|63&e)},at=/[\uD800-\uDBFF][\uDC00-\uDFFFF]|[^\x00-\x7F]/g,it=J?function(t){return Buffer.from(t,"utf8").toString("base64")}:z?function(t){return rt(z.encode(t))}:function(t){return nt(t.replace(at,ot))},ut=/[\xC0-\xDF][\x80-\xBF]|[\xE0-\xEF][\x80-\xBF]{2}|[\xF0-\xF7][\x80-\xBF]{3}/g,ct=function(t){switch(t.length){case 4:var e=((7&t.charCodeAt(0))<<18|(63&t.charCodeAt(1))<<12|(63&t.charCodeAt(2))<<6|63&t.charCodeAt(3))-65536;return X(55296+(e>>>10))+X(56320+(1023&e));case 3:return X((15&t.charCodeAt(0))<<12|(63&t.charCodeAt(1))<<6|63&t.charCodeAt(2));default:return X((31&t.charCodeAt(0))<<6|63&t.charCodeAt(1))}},lt=Q?function(t){return atob(et(t))}:J?function(t){return Buffer.from(t,"base64").toString("binary")}:function(t){if(t=t.replace(/\s+/g,""),!$.test(t))throw new TypeError("malformed base64.");t+="==".slice(2-(3&t.length));for(var e,n,r,o="",a=0;a<t.length;)e=Z[t.charAt(a++)]<<18|Z[t.charAt(a++)]<<12|(n=Z[t.charAt(a++)])<<6|(r=Z[t.charAt(a++)]),o+=64===n?X(e>>16&255):64===r?X(e>>16&255,e>>8&255):X(e>>16&255,e>>8&255,255&e);return o},st=J?function(t){return _(Buffer.from(t,"base64"))}:function(t){return _(lt(t),(function(t){return t.charCodeAt(0)}))},ft=J?function(t){return Buffer.from(t,"base64").toString("utf8")}:V?function(t){return V.decode(st(t))}:function(t){return lt(t).replace(ut,ct)},dt=function(t){return ft(et(t.replace(/[-_]/g,(function(t){return"-"==t?"+":"/"}))))};function ht(t){return dt(t)}function mt(t){return function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return e?tt(it(t)):it(t)}(t)}function gt(t){return 1*t<10?"0".concat(t):t}function vt(t){return vt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},vt(t)}function pt(t){var e=function(t,e){if("object"!==vt(t)||null===t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var r=n.call(t,e||"default");if("object"!==vt(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"===vt(e)?e:String(e)}function yt(t,e,n){return(e=pt(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function wt(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function bt(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?wt(Object(n),!0).forEach((function(e){yt(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):wt(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function xt(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;return A(t,e,n)}function At(t,e){return I(t,e)}function St(t,e,n){return g(t,e,n)}function Mt(t){return N(t)}function Dt(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1e3;return T(t,e,n)}function Ct(t,e){return f(t,e)}function Et(t,e,n){return d(t,e,n)}function It(t){return E(t)}function Ot(t,e){return x(t,e)}function jt(t,e){return S(t,e)}function kt(t){return D(t)}function Nt(t,e){return b(t,e)}function Tt(t){return w(t)}function Pt(t,e){return P(t,e)}function Ft(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1;return m(t,e)}function Yt(t,e){return Y(t,e)}function Bt(t){return F(t)}function Ht(t,e,n){return s(t,e,n)}function Ut(t,e){return C(t,e)}function Wt(t,e){return M(t,e)}function Lt(t,e,n){return O(t,e,n)}function Rt(t){return j(t)}function Kt(t,e){return h(t,e)}function Qt(t,e){return v(t,e)}function Gt(t,e){return k(t,e)}function Jt(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;return y(t,e,n)}function Vt(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;return p(t,e,n)}function zt(t){return ne(t)}function qt(t){var e="".concat(ne(t)?null:t).match(/^(\d{1,4})(-|\/)(\d{1,2})\2(\d{1,2})$/);if(null==e)return!1;var n=new Date(e[1],e[3]-1,e[4]);return n.getFullYear()===parseInt(e[1],10)&&n.getMonth()+1===parseInt(e[3],10)&&n.getDate()===parseInt(e[4],10)}function Zt(t){return i(t)}function $t(t){var e="".concat(ne(t)?null:t);if(""===e)return!1;return new RegExp(/^([1-9][\d]{0,15}|0)(\.[\d]{1,2})?$/).test(e)}function Xt(t,e){return r(t,e)}function _t(t,e){return JSON.stringify(t||{})===JSON.stringify(e||{})}function te(t){return o(t)}function ee(t){return e(t)}function ne(t){return l(t)}function re(t){return a(t)}function oe(t){return n(t)}function ae(t){return c(t)}function ie(t){return Array.isArray(t)}function ue(t){return u(t)}function ce(t){return null!==t&&"object"===vt(t)&&!ie(t)}function le(t){return ce(t)&&te(t.then)&&te(t.catch)}function se(t){return new RegExp(/(http|https):\/\/([\w.]+\/?)\S*/).test(t)}function fe(t){return new RegExp(/(data):image\/([\w.]+\/?)\S*/).test(t)}function de(t){return""===Bt(s(t||""," ",""))}function he(t,e){var n=!1;return ie(t)?(t.some((function(t){return t===e&&(n=!0,!0)})),n):n}var me="easy-soft-utility",ge={WEAPP:"WEAPP",WEB:"WEB",RN:"RN",SWAN:"SWAN",ALIPAY:"ALIPAY",TT:"TT",QQ:"QQ",JD:"JD",UNKNOWN:"UNKNOWN"},ve={loadApiPath:"",firstLoadSuccess:!1,loadSuccess:!1,registering:!1,dataLoading:!1,reloading:!1,searching:!1,refreshing:!1,paging:!1,processing:!1,dispatchComplete:!0,metaData:null,metaExtra:null,metaListData:[],metaOriginalData:null,urlParams:null,externalData:null},pe={dataLoading:!0},ye={get:"GET",post:"POST",put:"PUT",delete:"DELETE",trace:"TRACE",connect:"CONNECT"},we="0",be=0,xe="1970-01-01 00:00",Ae={number:"number",datetime:"datetime",string:"string",moment:"moment",money:"money",array:"array",boolean:"boolean"},Se={money:"money",datetime:"datetime",chineseMoney:"chineseMoney",percentage:"percentage"},Me={yearMonthDayHourMinuteSecond:"YYYY-MM-DD HH:mm:ss",yearMonthDayHourMinute:"YYYY-MM-DD HH:mm",yearMonthDay:"YYYY-MM-DD",yearMonth:"YYYY-MM",year:"YYYY",monthDayHourMinuteSecond:"YYYY-MM-DD HH:mm:ss",monthDayHourMinute:"MM-DD HH:mm",monthDay:"MM-DD",hourMinute:"HH:mm",hourMinuteSecond:"HH:mm:ss",month:"MM",day:"DD",hour:"HH",minute:"mm",second:"ss"},De={moveUp:"moveUp",moveDown:"moveDown"},Ce={no:"0",yes:"1"},Ee={no:0,yes:1},Ie={trace:"trace",debug:"debug",warn:"warn",error:"error",exception:"exception",info:"info",config:"config",execute:"execute",stack:"stack"},Oe={auto:"auto",text:"text",object:"object"},je={success:"success",error:"error",info:"info",warning:"warning",warn:"warn",open:"open"},ke=bt({},je),Ne=bt({},je),Te="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGQAAABLCAYAAACGGCK3AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAA0SURBVHhe7cExAQAAAMKg9U9tDQ8gAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAIA3NXV7AAHfw7zWAAAAAElFTkSuQmCC",Pe=Te;function Fe(t){return U(t,{algorithm:"sha1"})}function Ye(t){return U(t,{algorithm:"md5"})}function Be(t,e){var n=Math.pow(10,e+1),r=Math.floor(He(t)*n);return 10*Math.round(r/10)/n}function He(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=B(t),r=Number.isNaN(n)?0:n;return null==(e||null)?r:Be(r,e)}function Ue(t,e,n){if(!Zt(t))throw new Error("value must be number value");var r=He(t);return void 0!==e&&(r=Math.max(t,e)),void 0!==n&&(r=Math.min(r,n)),r}function We(t){return $t(t)?parseFloat(t,10):0}function Le(t){return"".concat(We(1e3*He(t)/10),"%")}function Re(t){return H(t)}function Ke(t){return!!t}function Qe(t){return Re(t).toUpperCase()}function Ge(t){return Re(t).toLowerCase()}function Je(t){if(null==(t||null))return null;if(oe(t))return t;if(ae(t)&&t.indexOf("T")<0){var e=t.replace(/\-/g,"/");return new Date(e)}return new Date(t)}function Ve(t){return le(t)?t:Promise.resolve(t)}function ze(t,e){return At(t,e)}function qe(t){var e=t.target,n=t.convert;if(te(n))return n(e);if(ae(n))switch(n){case Ae.number:return He(e);case Ae.datetime:return Je(e);case Ae.string:return Re(e);case Ae.money:return We(e);case Ae.array:return null==(e||null)?[]:ie(e)?e:[e];default:return e}return e}function Ze(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function $e(t,e){if(t){if("string"==typeof t)return Ze(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Ze(t,e):void 0}}function Xe(t){return function(t){if(Array.isArray(t))return Ze(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||$e(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function _e(t){return new Function("return ".concat(t))()}function tn(){var t=navigator.userAgent;return{trident:t.indexOf("Trident")>-1,presto:t.indexOf("Presto")>-1,webKit:t.indexOf("AppleWebKit")>-1,gecko:t.indexOf("Gecko")>-1&&-1===t.indexOf("KHTML"),mobile:!!t.match(/AppleWebKit.*Mobile.*/),ios:!!t.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/),android:t.indexOf("Android")>-1||t.indexOf("Linux")>-1,iPhone:t.indexOf("iPhone")>-1,iPad:t.indexOf("iPad")>-1,webApp:-1===t.indexOf("Safari")}}function en(){var t;return{versions:tn(),language:(null!==(t=navigator.browserLanguage||navigator.language)&&void 0!==t?t:"").toLowerCase()}}function nn(t){var e=t.seed,n=t.min||0;return n+(9301*e+49297)%233280/233280*((t.max||1)-n)}function rn(t){return null==t?null:JSON.parse(JSON.stringify(t))}function on(t,e,n){var r=[];return null!=t&&(r=Xe(t)),null!=n&&(r=[].concat(Xe(r),Xe(n))),null!=e&&(r=[e].concat(Xe(r))),r}function an(t,e,n,r,o){var a=r,i=void 0===n?null:n;return null!=e&&("function"==typeof convertValue?a.initialValue=o(t)||i:a.initialValue=t||i),a}function un(t,e,n){var r=null;return null==e||(n||[]).forEach((function(n){n[t]===e&&(r=n)})),r}function cn(){var t,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:8,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:16,r="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz".split(""),o=[],a=0;if(n=n||r.length,e)for(a=0;a<e;a++)o[a]=r[0|Math.random()*n];else for(o[8]=o[13]=o[18]=o[23]="-",o[14]="4",a=0;a<36;a++)o[a]||(t=0|16*Math.random(),o[a]=r[19===a?3&t|8:t]);return o.join("")}function ln(t){var e=t.pageNo,n=t.pageSize,r=t.total;return!((r||0)<=0)&&(e||0)*(n||0)<(r||0)}function sn(){return"development"===process.env.NODE_ENV}function fn(t){return Object.keys(t).map((function(e){return t[e]})).join(",")}function dn(t,e){for(var n=arguments.length,r=new Array(n>2?n-2:0),o=2;o<n;o++)r[o-2]=arguments[o];var a=[t].concat(r).filter((function(t){return ae(t)&&!de(t)}));return"".concat(a.join("::"),"::").concat(de(e)?"":e)}var hn="loggerAssist",mn={loggerDisplaySwitchPromptSetInformationComplete:!1,loggerDisplaySwitchSetComplete:!1,display:!1},gn={config:"#F8C471",execute:"#C39BD3",info:"#89CA78",warn:"#F16F17",debug:"#00768F",trace:"#596032",error:"#E33F3E",exception:"#DC428E",stack:"#81977c"};function vn(t){var e=t.text,n=t.color,r=void 0===n?"":n,o=t.dataDescription,a=void 0===o?"":o,i=t.ancillaryInformation,u=void 0===i?"":i,c=function(t,e){return"".concat(Re(t)).concat(de(e)?"":" -> ".concat(e))}(ae(e)?e:JSON.stringify(e),u);de(vn)||console.log("%c%s","color:".concat(r,";"),"".concat(de(a)?"":"[".concat(Qe(a),"] ")).concat(c))}function pn(t){var e=t.data,n=t.color,r=void 0===n?"":n,o=t.dataDescription,a=void 0===o?"":o,i=t.ancillaryInformation;vn({text:"check the following object data",color:r,dataDescription:a,ancillaryInformation:void 0===i?"":i}),console.log(e)}function yn(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Oe.auto,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Ie.debug,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"",o=jn();if(!mn.loggerDisplaySwitchSetComplete&&!mn.loggerDisplaySwitchPromptSetInformationComplete){var a=dn(me,"logData -> logger display switch default is false, if want to display log, please set it before first log, use setLoggerDisplaySwitch to set it, this message only show once",hn);vn({text:a,color:"#08BBEE",dataDescription:"hint",ancillaryInformation:""});try{throw new Error("please set use setLoggerDisplaySwitch")}catch(t){console.error(t)}mn.loggerDisplaySwitchPromptSetInformationComplete=!0}if(o||n===Ie.exception){var i=null==(e||null)||de(e)?Oe.auto:e;if(!he([Oe.auto,Oe.text,Oe.object],i))throw new Error("Invalid log display mode -> ".concat(i));if(i===Oe.auto&&(i=ae(t)?Oe.text:Oe.object),n!==Ie.exception){if(o){if(n===Ie.trace&&(i===Oe.text&&vn({text:t,color:gn.trace,dataDescription:"trace",ancillaryInformation:r}),i===Oe.object&&pn({data:t,color:gn.trace,dataDescription:"trace",ancillaryInformation:r})),n===Ie.debug&&(i===Oe.text&&vn({text:t,color:gn.debug,dataDescription:"debug",ancillaryInformation:r}),i===Oe.object&&pn({data:t,color:gn.debug,dataDescription:"debug",ancillaryInformation:r})),n===Ie.warn&&(i===Oe.text&&vn({text:t,color:gn.warn,dataDescription:"warn",ancillaryInformation:r}),i===Oe.object&&pn({data:t,color:gn.warn,dataDescription:"warn",ancillaryInformation:r})),n===Ie.info&&(i===Oe.text&&vn({text:t,color:gn.info,dataDescription:"info",ancillaryInformation:r}),i===Oe.object&&pn({data:t,color:gn.info,dataDescription:"info",ancillaryInformation:r})),n===Ie.execute&&(i===Oe.text&&vn({text:t,color:gn.execute,dataDescription:"execute",ancillaryInformation:r}),i===Oe.object&&pn({data:t,color:gn.execute,dataDescription:"execute",ancillaryInformation:r})),n===Ie.config&&(i===Oe.text&&vn({text:t,color:gn.config,dataDescription:"config",ancillaryInformation:r}),i===Oe.object&&pn({data:t,color:gn.config,dataDescription:"config",ancillaryInformation:r})),n===Ie.stack){i===Oe.text&&vn({text:t,color:gn.stack,dataDescription:"stack",ancillaryInformation:r}),i===Oe.object&&pn({data:t,color:gn.stack,dataDescription:"stack",ancillaryInformation:r});try{throw new Error("stack call trace as bellow")}catch(t){var u=t.stack;console.log(Ht(u,"Error:","Stack:"))}}n===Ie.error&&(i===Oe.text&&vn({text:t,color:gn.error,dataDescription:"error",ancillaryInformation:r}),i===Oe.object&&pn({data:t,color:gn.error,dataDescription:"error",ancillaryInformation:r}))}}else{i===Oe.text&&vn({text:t,color:gn.exception,dataDescription:"exception",ancillaryInformation:r}),i===Oe.object&&pn({data:t,color:gn.exception,dataDescription:"exception",ancillaryInformation:r});try{throw new Error("an error occur, check the above error message, the stack information is as follows")}catch(t){console.error(t)}}}}function wn(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";ae(t)?In(t,Ie.warn,e):On(t,Ie.warn,e)}function bn(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";ae(t)?In(t,Ie.info,e):On(t,Ie.info,e)}function xn(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";ae(t)?In(t,Ie.config,e):On(t,Ie.config,e)}function An(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";ae(t)?In(t,Ie.stack,e):On(t,Ie.stack,e)}function Sn(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";ae(t)?In(t,Ie.trace,e):On(t,Ie.trace,e)}function Mn(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";ae(t)?In(t,Ie.debug,e):On(t,Ie.debug,e)}function Dn(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";ae(t)?In(t,Ie.execute,e):On(t,Ie.execute,e)}function Cn(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";ae(t)?In(t,Ie.error,e):On(t,Ie.error,e)}function En(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";ae(t)?In(t,Ie.exception,e):On(t,Ie.exception,e)}function In(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Ie.trace,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"";yn(t,Oe.text,e,n)}function On(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Ie.trace,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"";yn(t,Oe.object,e,n)}function jn(){return Ke(mn.display)}function kn(t){sn()&&vn({text:"setLoggerDisplaySwitch",color:gn.execute,dataDescription:"execute",ancillaryInformation:""}),mn.display=Ke(t),mn.loggerDisplaySwitchSetComplete=!0}var Nn={mountComplete:!1,target:null};function Tn(e){if(Dn("setCacheMount"),!ue(e))throw Mn(e),new Error(dn(me,"setCacheMount -> cache mount target must be a object, current type is ".concat(vt(e)),"cacheAssist"));null==(e.localRuntimeCache||null)&&(e.localRuntimeCache=new t),Nn.target=e,Nn.mountComplete=!0,bn("setCacheMount -> cache mount success.")}function Pn(t){return de(t)?(En("checkKey -> cache key is null or empty"),!1):!(!ae(t)&&!Zt(t))||(En("cache key must be string or number, current type id ".concat(vt(t))),!1)}function Fn(){if(!Nn.mountComplete||!Nn.target||!Nn.target.localRuntimeCache)throw new Error("getCachePool -> please use setCacheMount function to set cache mount target before get it.");return Nn.target.localRuntimeCache}function Yn(t){var e=t.key,n=Fn();if(null==n)throw new Error("cache pool not exist");return n.has(e)}function Bn(t){var e=t.key,n=t.value,r=t.expiration,o=void 0===r?0:r;if(Pn(e)){var a=Fn();if(null==a)throw new Error("cache pool not exist");return a.set(e,n,o)}}function Hn(t){if(!ie(t))throw new Error("setMultiCache: list must be array");if(t.length<=0)return!0;var e=[];if(t.forEach((function(t){var n=bt(bt({},{key:"",value:"",expiration:0}),t),r=n.key,o=n.value,a=n.expiration;if(!de(r)){if(!Pn(r))return;e.push({key:r,value:o,ttl:a})}})),e.length<=0)return!1;var n=Fn();if(null==n)throw new Error("cache pool not exist");return n.mset(e)}function Un(t){var e=t.key,n=Fn();if(null==n)throw new Error("cache pool not exist");return n.getTtl(e)}function Wn(t){var e=t.key,n=t.expiration,r=Fn();if(null==r)throw new Error("cache pool not exist");return r.ttl(e,n)}function Ln(t){var e=t.key,n=Fn();if(null==n)throw new Error("cache pool not exist");return n.get(e)}function Rn(){var t=Fn();if(null==t)throw new Error("cache pool not exist");return t.keys()}function Kn(t){if(!ie(t))throw new Error("getMultiCache: list must be array");var e=Fn();if(null==e)throw new Error("cache pool not exist");return e.mget(t)}function Qn(t){var e=t.key,n=Fn();if(null==n)throw new Error("cache pool not exist");return n.take(e)}function Gn(t){var e=t.key;if(Pn(e)){var n=Fn();if(null==n)throw new Error("cache pool not exist");return n.del(e)}}function Jn(t){if(!ie(t))throw new Error("deleteMultiCache: list must be array");var e=Fn();if(null==e)throw new Error("cache pool not exist");return e.del(t)}function Vn(){var t=Fn();if(null==t)throw new Error("cache pool not exist");return t.flushAll()}function zn(){var t=Fn();if(null==t)throw new Error("cache pool not exist");return t.getStats()}function qn(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,o,a,i,u=[],c=!0,l=!1;try{if(a=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=a.call(n)).done)&&(u.push(r.value),u.length!==e);c=!0);}catch(t){l=!0,o=t}finally{try{if(!c&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(l)throw o}}return u}}(t,e)||$e(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Zn(t){var e=t.seed;return"#".concat("00000".concat((16777216*nn({seed:e})<<0).toString(16)).substring(-6))}function $n(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"RGB",n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=/^#([0-9a-fA-f]{3}|[0-9a-fA-f]{6})$/,o=(null!=t?t:"").toLowerCase();if(r.test(o)){if(4===o.length){for(var a="#",i=1;i<4;i+=1)a+=o.slice(i,i+1).concat(o.slice(i,i+1));o=a}for(var u=[],c=1;c<7;c+=2)u.push(parseInt("0x"+o.slice(c,c+2)));return e?"".concat(e,"(").concat(u.join(","),")"):n?u:u.join(",")}return En("Invalid hex color -> ".concat(t)),o}function Xn(t){var e=t.progress,n=t.startColor,r=t.endColor,o=$n(n,null,!0),a=$n(r,null,!0),i=qn(o,3),u=i[0],c=i[1],l=i[2],s=qn(a,3),f=s[0],d=s[1],h=s[2],m=[(u+Math.round((f-u)*e)).toString(16),(c+Math.round((d-c)*e)).toString(16),(l+Math.round((h-l)*e)).toString(16)];return"#".concat(m.join("").toUpperCase())}function _n(t){var e=t.direct,n=t.list,r=void 0===n?[]:n,o=Zt(e)?"".concat(e,"deg"):e;return"linear-gradient(".concat(o,", ").concat(r.join(),")")}function tr(t,e){var n=Je(t);return n.setHours(n.getHours()+e)}function er(t,e){var n=Je(t);return n.setMinutes(n.getMinutes()+e)}function nr(t,e){var n=Je(t);return n.setSeconds(n.getSeconds()+e)}function rr(){return new Date}function or(t,e){var n=t.getTime(),r=(e.getTime()-n)/1e3,o=parseInt(r/86400),a=parseInt((r-24*o*60*60)/3600),i=parseInt((r-24*o*60*60-60*a*60)/60);return{day:o,hour:a,minute:i,second:r-24*o*60*60-60*a*60-60*i}}var ar=function(t,e,n){var r=Je(t),o=e?Je(e):new Date,a=o.getTime()-r.getTime();return"second"===n&&a/1e3||"minute"===n&&a/1e3/60||"hour"===n&&a/1e3/60/60||"day"===n&&a/1e3/60/60/24||"week"===n&&a/1e3/60/60/24/7||"month"===n&&ir(r,o)||"quarter"===n&&ir(r,o)/3||"year"===n&&ir(r,o)/12||a},ir=function(t,e){var n=Je(t),r=Je(e);return 12*(n.getFullYear()-r.getFullYear())+n.getMonth()-r.getMonth()};function ur(t){var e=t.data;return W(e).day()}function cr(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],e=W().day();if(!t)return e;var n="";switch(He(e)){case 0:n="日";break;case 1:n="一";break;case 2:n="二";break;case 3:n="三";break;case 4:n="四";break;case 5:n="五";break;case 6:n="六";break;default:n=""}return de(n)?"":"星期".concat(n)}function lr(t){var e=t.data,n=t.places,r=void 0===n?2:n,o=t.thousand,a=void 0===o?",":o,i=t.decimal;return sr({data:e,places:r,symbol:"",thousand:a,decimal:void 0===i?".":i})}function sr(t){var e=t.data,n=t.places,r=void 0===n?2:n,o=t.symbol,a=void 0===o?"¥":o,i=t.thousand,u=void 0===i?",":i,c=t.decimal,l=void 0===c?".":c,s=e||0,f=isNaN(r=Math.abs(r))?2:r,d=void 0!==a?a:"¥",h=u||",",m=l||".",g=s<0?"-":"",v=parseInt(s=Math.abs(+s||0).toFixed(f),10)+"",p=v.length;return d+g+((p=p>3?p%3:0)?v.substr(0,p)+h:"")+v.substr(p).replace(/(\d{3})(?=\d)/g,a+"1"+h)+(f?m+Math.abs(s-He(v)).toFixed(f).slice(2):"")}function fr(t){var e,n,r,o=t.target,a=["零","壹","贰","叁","肆","伍","陆","柒","捌","玖"],i=["","拾","佰","仟"],u=["","万","亿","兆"],c=["角","分","毫","厘"],l="";if(""===o)return"";if((o=parseFloat(o))>=1e15)return"超出最大处理数字";if(0===o)return l=a[0]+"元";if(-1===(o=o.toString()).indexOf("."))e=o,n="";else{var s=qn(r=o.split("."),2);e=s[0],n=s[1],n=r[1].substr(0,4)}if(parseInt(e,10)>0){for(var f=0,d=e.length,h=0;h<d;h+=1){var m=e.substr(h,1),g=d-h-1,v=g/4,p=g%4;"0"===m?f+=1:(f>0&&(l+=a[0]),f=0,l+=a[parseInt(m,10)]+i[p]),0===p&&f<4&&(l+=u[v])}l+="元"}if(""!==n)for(var y=n.length,w=0;w<y;w+=1){var b=n.substr(w,1);"0"!==b&&(l+=a[Number(b)]+c[w])}return""===l&&(l+=a[0]+"元"),l}function dr(t){var e=t.data,n=t.fmt,r=void 0===n?Me.yearMonthDayHourMinuteSecond:n;return null==(e||null)?"":W(e).format(r)}function hr(t){var e=t.target,n=t.format,r=t.option,o=void 0===r?{}:r;if(te(n))return n(e);if(ae(n))switch(n){case Se.money:return sr({data:e});case Se.datetime:return dr({data:e});case Se.chineseMoney:return fr({target:e,option:o});case Se.percentage:return"".concat(ze(100*e,1),"%");default:return e}return e}function mr(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=bt(bt({},{second:["刚刚","片刻后"],seconds:["%d 秒前","%d 秒后"],minute:["大约 1 分钟前","大约 1 分钟后"],minutes:["%d 分钟前","%d 分钟后"],hour:["大约 1 小时前","大约 1 小时后"],hours:["%d 小时前","%d 小时后"],day:["1 天前","1 天后"],days:["%d 天前","%d 天后"],month:["大约 1 个月前","大约 1 个月后"],months:["%d 月前","%d 月后"],year:["大约 1 年前","大约 1 年后"],years:["%d 年前","%d 年后"]}),n||{}),o=ar(t,e),a=o<0?1:0,i=Math.abs(o)/1e3,u=i/60,c=u/60,l=c/24,s=l/365,f=function(t,e){return t.replace(/%d/i,e)};return i<10&&f(r.second[a],parseInt(i))||i<45&&f(r.seconds[a],parseInt(i))||i<90&&f(r.minute[a],1)||u<45&&f(r.minutes[a],parseInt(u))||u<90&&f(r.hour[a],1)||c<24&&f(r.hours[a],parseInt(c))||c<42&&f(r.day[a],1)||l<30&&f(r.days[a],parseInt(l))||l<45&&f(r.month[a],1)||l<365&&f(r.months[a],parseInt(l/30))||s<1.5&&f(r.year[a],1)||f(r.years[a],parseInt(s))}function gr(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return mr(t,rr(),e)}function vr(t){return de(t.text||null)&&wn(dn(me,"checkMessagePromptData option text disallow empty","loggerAssist")),!0}var pr={showOpenMessage:function(t){var e=t.text;t.duration,t.onClose,bn({text:e})},showInfoMessage:function(t){var e=t.text;t.duration,t.onClose,bn({text:e})},showSuccessMessage:function(t){var e=t.text;t.duration,t.onClose,bn({text:e})},showWarnMessage:function(t){var e=t.text;t.duration,t.onClose,wn(e)},showWarningMessage:function(t){var e=t.text;t.duration,t.onClose,wn(e)},showErrorMessage:function(t){var e=t.text;t.duration,t.onClose,Cn(e)},setErrorMessageDisplayMonitorComplete:!1};function yr(t){pr.showOpenMessage=t}function wr(t){pr.showInfoMessage=t}function br(t){pr.showSuccessMessage=t}function xr(t){pr.showWarnMessage=t}function Ar(t){pr.showWarningMessage=t}function Sr(t){pr.showErrorMessage=t,pr.setErrorMessageDisplayMonitorComplete=!0}function Mr(t){Dr({text:t})}function Dr(t){var e=t.text,n=t.duration,r=void 0===n?1500:n,o=t.onClose,a=void 0===o?function(){}:o;te(pr.showOpenMessage)&&(vr({text:e}),pr.showOpenMessage({text:e,duration:r,onClose:a}))}function Cr(t){Er({text:t})}function Er(t){var e=t.text,n=t.duration,r=void 0===n?1500:n,o=t.onClose,a=void 0===o?function(){}:o;te(pr.showInfoMessage)&&(vr({text:e}),pr.showInfoMessage({text:e,duration:r,onClose:a}))}function Ir(t){Or({text:t})}function Or(t){var e=t.text,n=t.duration,r=void 0===n?1500:n,o=t.onClose,a=void 0===o?function(){}:o;te(pr.showSuccessMessage)&&(vr({text:e}),pr.showSuccessMessage({text:e,duration:r,onClose:a}))}function jr(t){kr({text:t})}function kr(t){var e=t.text,n=t.duration,r=void 0===n?1500:n,o=t.onClose,a=void 0===o?function(){}:o;te(pr.showWarnMessage)&&(vr({text:e}),pr.showWarnMessage({text:e,duration:r,onClose:a}))}function Nr(t){Tr({text:t})}function Tr(t){var e=t.text,n=t.duration,r=void 0===n?1500:n,o=t.onClose,a=void 0===o?function(){}:o;te(pr.showWarningMessage)&&(vr({text:e}),pr.showWarningMessage({text:e,duration:r,onClose:a}))}function Pr(t){Fr({text:t})}function Fr(t){var e=t.text,n=t.duration,r=void 0===n?1500:n,o=t.onClose,a=void 0===o?function(){}:o;te(pr.showErrorMessage)&&(vr({text:e}),pr.showErrorMessage({text:e,duration:r,onClose:a}))}function Yr(t){Br({text:t})}function Br(t){var e=t.text;de(e||"")||(pr.setErrorMessageDisplayMonitorComplete&&Fr({text:e}),En({text:e}))}function Hr(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"...";return t&&t.length>e?"".concat(Re(t).substring(0,e)).concat(n):Re(t)}function Ur(t,e,n,r){var o=Re(t),a=(t||"").length;a>0&&(n>=0||r>=0)&&(o=n>=a||r>=a||(n||0)+(r||0)>=a?t:t.substr(0,n)+e+t.substr(a-r,r));return o||""}function Wr(t,e){for(var n=(new Date).getTime();!((new Date).getTime()-n>t););te(e)&&e()}function Lr(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;if(ne(t))return n;if(null==t)return n;if(!ae(e)){var r="getPathValue Function param path must be string";return Br({message:r}),null}var o=xt(t,e,n);return ne(n)||re(n)?o:o||n}function Rr(t,e){if(!ae(t))throw new Error("removeEndMatch only use for string target");if(!ae(e))throw new Error("removeEndMatch only use for string match");if(de(t))return t;if(de(e))return t;var n=t.lastIndexOf(e);return n>=0&&t.length===n+e.length?t.substr(n,e.length):t}function Kr(t,e){if(!ae(t))throw new Error("removeEndMatch only use for string source");if(!ae(e))throw new Error("removeEndMatch only use for string target");if(de(t))return t;if(de(e))return t;var n=t.lastIndexOf(e);return n>=0?t.substr(n,e.length):t}function Qr(t){var e=t.data,n=t.key,r=t.defaultValue,o=void 0===r?null:r,a=t.convert,i=void 0===a?null:a,u=t.convertBuilder,c=void 0===u?null:u,l=t.format,s=void 0===l?null:l,f=t.formatBuilder,d=void 0===f?null:f,h=Lr(e,n,o),m=h;return null==(c||null)&&null==(i||null)||(m=te(c)?qe({target:h,convert:c}):qe({target:h,convert:i})),null==(d||null)&&null==(s||null)||(m=te(d)?hr({target:m,format:d}):hr({target:m,format:s})),m}function Gr(t){var e=t.operate,n=t.item,r=t.list,o=t.key,a=t.sortInitialValue,i=void 0===a?0:a;if(null==(n||null))return r;var u=[],c=[],l=[];if((r||[]).length<=1){return kr({message:"无需排序!"}),r}var s=Qr({data:n,key:o,convert:Ae.number});switch((r||[]).forEach((function(t){var e=Qr({data:t,key:o,convert:Ae.number});e<s&&u.push(t),e>s&&c.push(t)})),e){case De.moveUp:if(s===i){return kr({message:"已经排在首位!"}),r}(u||[]).forEach((function(t,e){if(e<u.length-1)l.push(t);else{var r=n;r[o]-=1,l.push(r);var a=t;a[o]+=1,l.push(a)}})),l=l.concat(c);break;case De.moveDown:if(s===(r||[]).length+i-1){return kr({message:"已经排在末位!"}),r}l=l.concat(u),(c||[]).forEach((function(t,e){if(0===e){var r=t;r[o]-=1,l.push(r);var a=n;a[o]+=1,l.push(a)}else l.push(t)}));break;default:kr({message:"不符合的操作, 允许的操作为['".concat(De.moveUp,"','").concat(De.moveDown,"']!")})}return l}function Jr(t){var e=t.list,n=void 0===e?[]:e,r=t.convert,o=void 0===r?null:r,a=t.recursiveKey,i=void 0===a?"children":a;return(ie(n)?n:[n]).map((function(t){return Vr({data:t,convert:o,target:i})}))}function Vr(t){var e=t.data,n=t.convert,r=void 0===n?null:n,o=t.recursiveKey,a=void 0===o?"children":o;if(!te(r))return e;var i=r(e),u=e[a],c=[];return ie(u)&&(c=u.map((function(t){return Vr({data:t,convert:r,target:a})}))),i[a]=c,i}function zr(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,r=Vt(t,e,n);return!ne(r)}function qr(){function t(t,e){return ne(e)?t:e}for(var e=Ct({},arguments.length<=0?void 0:arguments[0]),n=1;n<arguments.length;n++)e=Et(e,n<0||arguments.length<=n?void 0:arguments[n],t);return e}function Zr(t){if(t&&"object"===vt(t)){var e="";return Object.keys(t).forEach((function(n){var r,o=(null!==(r=n.replace(/([A-Z])/g,"-$1"))&&void 0!==r?r:"").toLowerCase();e+="".concat(o,":").concat(t[n],";")})),e}return t&&"string"==typeof t?t:""}function $r(t,e){return t&&"object"===vt(t)&&e&&"object"===vt(e)?Object.assign({},t,e):Zr(t)+Zr(e)}function Xr(t,e){var n=t;for(var r in e)e.hasOwnProperty(r)&&(n[r]=e[r]);return n}var _r="htmlAssist";function to(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:5,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0;if(!Zt(t))return t;if(!Zt(e)||e<=0)throw new Error(dn(me,"pxToRem -> root value must be number and greater than 0, current root value [".concat(e,"] is invalid"),_r));var o=parseFloat(t);if(o<r)return t;var a=He(o/e,n);return 0===a?"0":a+"rem"}var eo="localStorageAssist",no={getStorage:function(t){En(dn(me,"setStorageGetter need config, use setStorageGetter to set it",eo))},setStorage:function(t,e){En(dn(me,"setStorageSetter need config, use setStorageSetter to set it",eo))},removeStorage:function(t){En(dn(me,"setStorageRemover need config, use setStorageRemover to set it",eo))},flushStorage:function(){En(dn(me,"setStorageFlusher need config, use setStorageFlusher to set it",eo))}};function ro(t){no.getStorage=t}function oo(t){no.setStorage=t}function ao(t){no.removeStorage=t}function io(t){no.flushStorage=t}function uo(t){try{return no.getStorage(t)}catch(e){throw En({key:t,e:e}),e}}function co(t){var e=uo(t);return de(e)?null:JSON.parse(e||"{}")}function lo(t,e){no.setStorage(t,e)}function so(t,e){no.setStorage(t,JSON.stringify(e||{}))}function fo(t){no.removeStorage(t)}function ho(){no.flushStorage()}var mo=function(t){var e=t.text;t.duration,t.onClose,bn({text:e})};var go="nearestLocalhostNotify";function vo(){var t=co(go);return null==(t||null)||null==(t.nearestTime||null)?null:t||null}function po(){return so(go,{nearestTime:parseInt((new Date).getTime()/1e3,10)})}function yo(){fo(go)}function wo(t){var e=t.text,n=!1,r=0,o=vo()||null;null==o?n=!0:r=o.nearestTime||0;var a=parseInt((new Date).getTime()/1e3,10);try{if(r+30<a&&(n=!0),n){var i="当前接口域名: ".concat(e,". ");!function(t){var e=t.text,n=t.duration,r=void 0===n?1500:n,o=t.onClose,a=void 0===o?function(){}:o;te(mo)&&mo({text:e,duration:r,onClose:a})}({text:i}),In({message:i}),po()}}catch(t){yn(t)}}function bo(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=L(t);if(de(e))return n;if(de(n))return e;var r=e.lastIndexOf("?")>=0?"&":"?";return"".concat(e).concat(r).concat(n)}function xo(t){return R(t)}function Ao(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"";return"请".concat(e||"输入").concat(t).concat(de(n)?"":",".concat(n))}function So(t){var e=t.label,n=t.name,r=t.helper,o="",a="",i="";if(ae(e))o=e;else{wn({label:e,name:n,helper:r}),Br({message:"label必须为文本"})}if(ae(n))a=n;else{wn({label:e,name:n,helper:r}),Br({message:"name必须为文本"})}if(ae(r))i=r;else{wn({label:e,name:n,helper:r}),Br({message:"helper必须为文本"})}return{label:o,name:a,helper:i}}function Mo(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"注: ";return"".concat(e).concat(t,". ")}export{tr as addHour,er as addMinute,nr as addSecond,Ct as assign,Et as assignWith,Xr as attachPropertiesToComponent,Ao as buildFieldDescription,Mo as buildFieldHelper,Xn as buildHexColor,_n as buildLinearGradient,dn as buildPromptModuleInfo,bo as buildQueryStringify,$n as buildRGBColorFromHexColor,Zn as buildRandomHexColor,Zr as buildStringStyle,Nn as cacheMountTarget,ar as calculateDateInterval,ir as calculateMonthInterval,or as calculateTimeInterval,zr as checkExist,So as checkFromConfig,ln as checkHasMore,he as checkInCollection,vr as checkMessagePromptData,de as checkStringIsNullOrWhiteSpace,sn as checkWhetherDevelopmentEnvironment,rn as cloneWithoutMethod,Ae as convertCollection,to as convertPixelToRem,Me as datetimeFormat,ht as decodeBase64,Gn as deleteCache,Jn as deleteMultiCache,Kt as difference,pn as displayObjectMessage,vn as displayTextMessage,Ft as dropRight,Hr as ellipsis,xe as emptyDatetime,mt as encodeBase64,St as endsWith,ge as envCollection,Pe as errorImage,_e as evil,Qt as filter,Vt as find,Jt as findIndex,Tt as first,gt as fixedZero,Nt as floor,Vn as flushAllCache,ho as flushLocalStorage,Ot as forEach,Se as formatCollection,mr as formatDateInterval,gr as formatDateIntervalWithNow,dr as formatDatetime,lr as formatDecimal,sr as formatMoney,fr as formatMoneyToChinese,hr as formatTarget,xt as get,en as getBrowserInfo,tn as getBrowserVersion,Ln as getCache,Fn as getCachePool,ur as getDayOfWeek,Un as getExpiration,cn as getGuid,co as getJsonFromLocalStorage,jn as getLoggerDisplaySwitch,Kn as getMultiCache,vo as getNearestLocalhostNotifyCache,rr as getNow,Lr as getPathValue,uo as getStringFromLocalStorage,cr as getTodayOfWeek,fn as getValue,Qr as getValueByKey,jt as gte,Yn as hasCache,ie as isArray,ee as isBoolean,oe as isDate,qt as isDatetime,Xt as isEqual,_t as isEqualBySerialize,te as isFunction,fe as isImageBase4,zt as isInvalid,$t as isMoney,re as isNull,Zt as isNumber,ue as isObject,ce as isPlainObject,le as isPromise,ae as isString,ne as isUndefined,se as isUrl,Rn as keys,no as localStorageAssist,gn as logColorCollection,xn as logConfig,yn as logData,Mn as logDebug,Oe as logDisplay,Cn as logError,En as logException,Dn as logExecute,bn as logInfo,Ie as logLevel,On as logObject,An as logStack,In as logText,Sn as logTrace,wn as logWarn,mn as loggerSwitch,Wt as map,kt as memoize,qr as mergeProps,$r as mergeStyle,pr as messagePromptAssist,Ne as messageTypeCollection,ke as notificationTypeCollection,xo as parseQueryString,on as refitCommonData,an as refitFieldDecoratorOption,Rr as removeEndMatch,Ut as removeFromArray,Kr as removeLastMatch,fo as removeLocalStorage,yo as removeNearestLocalhostNotifyCache,Ht as replace,Ur as replaceWithKeep,ye as requestMethod,It as reverse,At as round,so as saveJsonToLocalStorage,lo as saveStringToLocalStorage,un as searchFromList,nn as seededRandom,Lt as set,Bn as setCache,Tn as setCacheMount,Sr as setErrorMessageDisplayMonitor,Wn as setExpiration,wr as setInfoMessageDisplayMonitor,kn as setLoggerDisplaySwitch,Hn as setMultiCache,po as setNearestLocalhostNotifyCache,yr as setOpenMessageDisplayMonitor,io as setStorageFlusher,ro as setStorageGetter,ao as setStorageRemover,oo as setStorageSetter,br as setSuccessMessageDisplayMonitor,xr as setWarnMessageDisplayMonitor,Ar as setWarningMessageDisplayMonitor,Fr as showErrorMessage,Er as showInfoMessage,Dr as showOpenMessage,Br as showRuntimeError,Pr as showSimpleErrorMessage,Cr as showSimpleInfoMessage,Mr as showSimpleOpenMessage,Yr as showSimpleRuntimeError,Ir as showSimpleSuccessMessage,jr as showSimpleWarnMessage,Nr as showSimpleWarningMessage,Or as showSuccessMessage,kr as showWarnMessage,Tr as showWarningMessage,Rt as size,Wr as sleep,Gt as sortBy,Gr as sortCollectionByKey,De as sortOperate,Mt as sortedUnique,Dt as split,Pt as startsWith,zn as statisticsCache,Qn as takeCache,qe as to,Ke as toBoolean,Ue as toBoundary,Je as toDatetime,Ge as toLower,Ye as toMd5,We as toMoney,He as toNumber,Le as toPercentage,Ve as toPromise,ze as toRound,Fe as toSha1,Re as toString,Qe as toUpper,Vr as transformData,Jr as transformListData,Te as transparentImage,Bt as trim,wo as trySendNearestLocalhostNotify,pe as underlyingExtensionState,ve as underlyingState,Yt as uniqBy,Ee as whetherNumber,Ce as whetherString,be as zeroInt,we as zeroString};
@@ -20,7 +20,7 @@ export function setCache({ key, value, expiration }: {
20
20
  key: any;
21
21
  value: any;
22
22
  expiration?: number | undefined;
23
- }): boolean;
23
+ }): boolean | undefined;
24
24
  /**
25
25
  * Sets multiple key val pairs. It is possible to define a ttl (seconds). Returns true on success.
26
26
  */
@@ -65,7 +65,7 @@ export function takeCache({ key }: {
65
65
  */
66
66
  export function deleteCache({ key }: {
67
67
  key: any;
68
- }): number;
68
+ }): number | undefined;
69
69
  /**
70
70
  * Delete multiple keys. Returns the number of deleted entries. A delete will never fail.
71
71
  */
@@ -107,9 +107,11 @@ export namespace logLevel {
107
107
  export const debug: string;
108
108
  export const warn: string;
109
109
  export const error: string;
110
+ export const exception: string;
110
111
  export const info: string;
111
112
  export const config: string;
112
113
  export const execute: string;
114
+ export const stack: string;
113
115
  }
114
116
  export namespace logDisplay {
115
117
  const auto: string;
@@ -52,6 +52,12 @@ export function logInfo(data: string | Object, ancillaryInformation?: string): v
52
52
  * @param {String} ancillaryInformation when ancillary Information not empty, it will be display
53
53
  */
54
54
  export function logConfig(data: string | Object, ancillaryInformation?: string): void;
55
+ /**
56
+ * Log stack message, default ancillaryInformation is empty string
57
+ * @param {String|Object} data the data will be display
58
+ * @param {String} ancillaryInformation when ancillary Information not empty, it will be display
59
+ */
60
+ export function logStack(data: string | Object, ancillaryInformation?: string): void;
55
61
  /**
56
62
  * Log trace message, default ancillaryInformation is empty string
57
63
  * @param {String|Object} data the data will be display
@@ -76,6 +82,12 @@ export function logExecute(data: string | Object, ancillaryInformation?: string)
76
82
  * @param {String} ancillaryInformation when ancillary Information not empty, it will be display
77
83
  */
78
84
  export function logError(data: string | Object, ancillaryInformation?: string): void;
85
+ /**
86
+ * Log error message, default ancillaryInformation is empty string
87
+ * @param {String|Object} data the data will be display
88
+ * @param {String} ancillaryInformation when ancillary Information not empty, it will be display
89
+ */
90
+ export function logException(data: string | Object, ancillaryInformation?: string): void;
79
91
  /**
80
92
  * Log text message, default level is logLevel.trace, default ancillaryInformation is empty string
81
93
  * @param {String} text the text will be display
@@ -111,4 +123,7 @@ export namespace logColorCollection {
111
123
  const warn: string;
112
124
  const debug: string;
113
125
  const trace: string;
126
+ const error: string;
127
+ const exception: string;
128
+ const stack: string;
114
129
  }
@@ -3,83 +3,146 @@ export function checkMessagePromptData({ text }: {
3
3
  }): boolean;
4
4
  /**
5
5
  * Set the open message display monitor
6
+ * @param {Function} callbackMonitor customize message display
6
7
  */
7
- export function setOpenMessageDisplayMonitor(callbackMonitor: any): void;
8
+ export function setOpenMessageDisplayMonitor(callbackMonitor: Function): void;
8
9
  /**
9
10
  * Set the info message display monitor
11
+ * @param {Function} callbackMonitor customize message display
10
12
  */
11
- export function setInfoMessageDisplayMonitor(callbackMonitor: any): void;
13
+ export function setInfoMessageDisplayMonitor(callbackMonitor: Function): void;
12
14
  /**
13
15
  * Set the warn message display monitor
16
+ * @param {Function} callbackMonitor customize message display
14
17
  */
15
- export function setSuccessMessageDisplayMonitor(callbackMonitor: any): void;
18
+ export function setSuccessMessageDisplayMonitor(callbackMonitor: Function): void;
16
19
  /**
17
20
  * Set the warn message display monitor
21
+ * @param {Function} callbackMonitor customize message display
18
22
  */
19
- export function setWarnMessageDisplayMonitor(callbackMonitor: any): void;
23
+ export function setWarnMessageDisplayMonitor(callbackMonitor: Function): void;
20
24
  /**
21
25
  * Set the warning message display monitor
26
+ * @param {Function} callbackMonitor customize message display
22
27
  */
23
- export function setWarningMessageDisplayMonitor(callbackMonitor: any): void;
28
+ export function setWarningMessageDisplayMonitor(callbackMonitor: Function): void;
24
29
  /**
25
30
  * Set the error message display monitor
31
+ * @param {Function} callbackMonitor customize message display
26
32
  */
27
- export function setErrorMessageDisplayMonitor(callbackMonitor: any): void;
33
+ export function setErrorMessageDisplayMonitor(callbackMonitor: Function): void;
34
+ /**
35
+ * Show simple text open message with display monitor
36
+ * @param {String} text simple text message
37
+ */
38
+ export function showSimpleOpenMessage(text: string): void;
28
39
  /**
29
40
  * Show open message with display monitor
41
+ * @param {Object} option message option
42
+ * @param {String} option.text message text
43
+ * @param {Number} option.duration message duration time, default is 1500
44
+ * @param {Function} option.onClose onClose callback
30
45
  */
31
46
  export function showOpenMessage({ text, duration, onClose }: {
32
- text: any;
33
- duration?: number | undefined;
34
- onClose?: (() => void) | undefined;
47
+ text: string;
48
+ duration: number;
49
+ onClose: Function;
35
50
  }): void;
51
+ /**
52
+ * Show simple text info message with display monitor
53
+ * @param {String} text simple text message
54
+ */
55
+ export function showSimpleInfoMessage(text: string): void;
36
56
  /**
37
57
  * Show info message with display monitor
58
+ * @param {Object} option message option
59
+ * @param {String} option.text message text
60
+ * @param {Number} option.duration message duration time, default is 1500
61
+ * @param {Function} option.onClose onClose callback
38
62
  */
39
63
  export function showInfoMessage({ text, duration, onClose }: {
40
- text: any;
41
- duration?: number | undefined;
42
- onClose?: (() => void) | undefined;
64
+ text: string;
65
+ duration: number;
66
+ onClose: Function;
43
67
  }): void;
68
+ /**
69
+ * Show simple text success message with display monitor
70
+ * @param {String} text simple text message
71
+ */
72
+ export function showSimpleSuccessMessage(text: string): void;
44
73
  /**
45
74
  * Show success message with display monitor
75
+ * @param {Object} option message option
76
+ * @param {String} option.text message text
77
+ * @param {Number} option.duration message duration time, default is 1500
78
+ * @param {Function} option.onClose onClose callback
46
79
  */
47
80
  export function showSuccessMessage({ text, duration, onClose, }: {
48
- text: any;
49
- duration?: number | undefined;
50
- onClose?: (() => void) | undefined;
81
+ text: string;
82
+ duration: number;
83
+ onClose: Function;
51
84
  }): void;
85
+ /**
86
+ * Show simple text warn message with display monitor
87
+ * @param {String} text simple text message
88
+ */
89
+ export function showSimpleWarnMessage(text: string): void;
52
90
  /**
53
91
  * Show warn message with display monitor
92
+ * @param {Object} option message option
93
+ * @param {String} option.text message text
94
+ * @param {Number} option.duration message duration time, default is 1500
95
+ * @param {Function} option.onClose onClose callback
54
96
  */
55
97
  export function showWarnMessage({ text, duration, onClose }: {
56
- text: any;
57
- duration?: number | undefined;
58
- onClose?: (() => void) | undefined;
98
+ text: string;
99
+ duration: number;
100
+ onClose: Function;
59
101
  }): void;
102
+ /**
103
+ * Show simple text warning message with display monitor
104
+ * @param {String} text simple text message
105
+ */
106
+ export function showSimpleWarningMessage(text: string): void;
60
107
  /**
61
108
  * Show warning message with display monitor
109
+ * @param {Object} option message option
110
+ * @param {String} option.text message text
111
+ * @param {Number} option.duration message duration time, default is 1500
112
+ * @param {Function} option.onClose onClose callback
62
113
  */
63
114
  export function showWarningMessage({ text, duration, onClose, }: {
64
- text: any;
65
- duration?: number | undefined;
66
- onClose?: (() => void) | undefined;
115
+ text: string;
116
+ duration: number;
117
+ onClose: Function;
67
118
  }): void;
119
+ /**
120
+ * Show simple text error message with display monitor
121
+ * @param {String} text simple text message
122
+ */
123
+ export function showSimpleErrorMessage(text: string): void;
68
124
  /**
69
125
  * Show error message with display monitor
126
+ * @param {Object} option message option
127
+ * @param {String} option.text message text
128
+ * @param {Number} option.duration message duration time, default is 1500
129
+ * @param {Function} option.onClose onClose callback
70
130
  */
71
131
  export function showErrorMessage({ text, duration, onClose, }: {
72
- text: any;
73
- duration?: number | undefined;
74
- onClose?: (() => void) | undefined;
132
+ text: string;
133
+ duration: number;
134
+ onClose: Function;
75
135
  }): void;
76
- export function showError(text: any): void;
136
+ /**
137
+ * Show simple runtime error message with display monitor
138
+ * @param {String} text simple text message
139
+ */
140
+ export function showSimpleRuntimeError(text: string): void;
77
141
  /**
78
142
  * Show runtime error
79
143
  */
80
- export function showRuntimeError({ text, showStack }: {
144
+ export function showRuntimeError({ text }: {
81
145
  text: any;
82
- showStack?: boolean | undefined;
83
146
  }): void;
84
147
  export namespace messagePromptAssist {
85
148
  function showOpenMessage({ text, duration, onClose }: {
@@ -112,4 +175,5 @@ export namespace messagePromptAssist {
112
175
  duration?: number | undefined;
113
176
  onClose?: (() => void) | undefined;
114
177
  }): void;
178
+ const setErrorMessageDisplayMonitorComplete: boolean;
115
179
  }
@@ -22,6 +22,10 @@ export function setWarningNotificationDisplayMonitor(callbackMonitor: any): void
22
22
  * Set the error notification display monitor
23
23
  */
24
24
  export function setErrorNotificationDisplayMonitor(callbackMonitor: any): void;
25
+ /**
26
+ * Show simple text info notification with display monitor
27
+ */
28
+ export function showSimpleOpenNotification(text: any): void;
25
29
  /**
26
30
  * Show open notification with display monitor
27
31
  */
@@ -30,6 +34,10 @@ export function showOpenNotification({ text, duration, onClose, }: {
30
34
  duration?: number | undefined;
31
35
  onClose?: (() => void) | undefined;
32
36
  }): void;
37
+ /**
38
+ * Show simple text info notification with display monitor
39
+ */
40
+ export function showSimpleInfoNotification(text: any): void;
33
41
  /**
34
42
  * Show info notification with display monitor
35
43
  */
@@ -38,6 +46,10 @@ export function showInfoNotification({ text, duration, onClose, }: {
38
46
  duration?: number | undefined;
39
47
  onClose?: (() => void) | undefined;
40
48
  }): void;
49
+ /**
50
+ * Show simple text success notification with display monitor
51
+ */
52
+ export function showSimpleSuccessNotification(text: any): void;
41
53
  /**
42
54
  * Show success notification with display monitor
43
55
  */
@@ -46,6 +58,10 @@ export function showSuccessNotification({ text, duration, onClose, }: {
46
58
  duration?: number | undefined;
47
59
  onClose?: (() => void) | undefined;
48
60
  }): void;
61
+ /**
62
+ * Show simple text warn notification with display monitor
63
+ */
64
+ export function showSimpleWarnNotification(text: any): void;
49
65
  /**
50
66
  * Show warn notification with display monitor
51
67
  */
@@ -54,6 +70,10 @@ export function showWarnNotification({ text, duration, onClose, }: {
54
70
  duration?: number | undefined;
55
71
  onClose?: (() => void) | undefined;
56
72
  }): void;
73
+ /**
74
+ * Show simple text warning notification with display monitor
75
+ */
76
+ export function showSimpleWarningNotification(text: any): void;
57
77
  /**
58
78
  * Show warning notification with display monitor
59
79
  */
@@ -62,6 +82,10 @@ export function showWarningNotification({ text, duration, onClose, }: {
62
82
  duration?: number | undefined;
63
83
  onClose?: (() => void) | undefined;
64
84
  }): void;
85
+ /**
86
+ * Show simple text error notification with display monitor
87
+ */
88
+ export function showSimpleErrorNotification(text: any): void;
65
89
  /**
66
90
  * Show error notification with display monitor
67
91
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "easy-soft-utility",
3
- "version": "2.3.11",
3
+ "version": "2.3.13",
4
4
  "private": false,
5
5
  "description": "easy-soft-utility",
6
6
  "keywords": [
@@ -123,5 +123,5 @@
123
123
  "stylelint-declaration-block-no-ignored-properties": "^2.6.0",
124
124
  "webpack": "^5.75.0"
125
125
  },
126
- "gitHead": "acab0628bcbadbabb6f0b0b162894136271a477a"
126
+ "gitHead": "07b46b2bdf935b3bdcd4f05ed443752c18cbc160"
127
127
  }