shu-c-view
Version:
rollup 打包vue组件库框架
7 lines (6 loc) • 25.6 kB
JavaScript
/*!
* shu-c-view v1.2.88
* (c) 2024-12-13
* @license MIT
*/
;Object.defineProperty(exports,"__esModule",{value:!0});var t=require("lodash/isArray"),e=require("lodash/isEmpty"),n=require("lodash/find"),r=require("lodash/get");function o(t){return t&&"object"==typeof t&&"default"in t?t.default:t}var i,c,a=o(t),u=o(e),s=o(n),l=o(r),f="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},p=function(t){try{return!!t()}catch(t){return!0}},g=!p((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]})),d=!p((function(){var t=function(){}.bind();return"function"!=typeof t||t.hasOwnProperty("prototype")})),v=d,h=Function.prototype,y=h.call,b=v&&h.bind.bind(y,y),m=v?b:function(t){return function(){return y.apply(t,arguments)}},S=function(t){return null==t},x=S,w=TypeError,_=function(t){if(x(t))throw w("Can't call method on "+t);return t},O=_,E=Object,I=function(t){return E(O(t))},j=I,k=m({}.hasOwnProperty),R=Object.hasOwn||function(t,e){return k(j(t),e)},C=g,P=R,T=Function.prototype,M=C&&Object.getOwnPropertyDescriptor,$=P(T,"name"),A={EXISTS:$,PROPER:$&&"something"===function(){}.name,CONFIGURABLE:$&&(!C||C&&M(T,"name").configurable)},z={},V=function(t){return t&&t.Math==Math&&t},D=V("object"==typeof globalThis&&globalThis)||V("object"==typeof window&&window)||V("object"==typeof self&&self)||V("object"==typeof f&&f)||function(){return this}()||Function("return this")(),F="object"==typeof document&&document.all,L={all:F,IS_HTMLDDA:void 0===F&&void 0!==F},N=L.all,U=L.IS_HTMLDDA?function(t){return"function"==typeof t||t===N}:function(t){return"function"==typeof t},q=U,B=L.all,K=L.IS_HTMLDDA?function(t){return"object"==typeof t?null!==t:q(t)||t===B}:function(t){return"object"==typeof t?null!==t:q(t)},Y=K,W=D.document,X=Y(W)&&Y(W.createElement),G=function(t){return X?W.createElement(t):{}},H=G,J=!g&&!p((function(){return 7!=Object.defineProperty(H("div"),"a",{get:function(){return 7}}).a})),Q=g&&p((function(){return 42!=Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype})),Z=K,tt=String,et=TypeError,nt=function(t){if(Z(t))return t;throw et(tt(t)+" is not an object")},rt=d,ot=Function.prototype.call,it=rt?ot.bind(ot):function(){return ot.apply(ot,arguments)},ct=D,at=U,ut=function(t){return at(t)?t:void 0},st=function(t,e){return arguments.length<2?ut(ct[t]):ct[t]&&ct[t][e]},lt=m({}.isPrototypeOf),ft=D,pt=st("navigator","userAgent")||"",gt=ft.process,dt=ft.Deno,vt=gt&>.versions||dt&&dt.version,ht=vt&&vt.v8;ht&&(c=(i=ht.split("."))[0]>0&&i[0]<4?1:+(i[0]+i[1])),!c&&pt&&(!(i=pt.match(/Edge\/(\d+)/))||i[1]>=74)&&(i=pt.match(/Chrome\/(\d+)/))&&(c=+i[1]);var yt=c,bt=p,mt=!!Object.getOwnPropertySymbols&&!bt((function(){var t=Symbol();return!String(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&yt&&yt<41})),St=mt&&!Symbol.sham&&"symbol"==typeof Symbol.iterator,xt=st,wt=U,_t=lt,Ot=Object,Et=St?function(t){return"symbol"==typeof t}:function(t){var e=xt("Symbol");return wt(e)&&_t(e.prototype,Ot(t))},It=String,jt=U,kt=function(t){try{return It(t)}catch(t){return"Object"}},Rt=TypeError,Ct=function(t){if(jt(t))return t;throw Rt(kt(t)+" is not a function")},Pt=S,Tt=function(t,e){var n=t[e];return Pt(n)?void 0:Ct(n)},Mt=it,$t=U,At=K,zt=TypeError,Vt={exports:{}},Dt=D,Ft=Object.defineProperty,Lt=function(t,e){try{Ft(Dt,t,{value:e,configurable:!0,writable:!0})}catch(n){Dt[t]=e}return e},Nt=Lt,Ut=D["__core-js_shared__"]||Nt("__core-js_shared__",{}),qt=Ut;(Vt.exports=function(t,e){return qt[t]||(qt[t]=void 0!==e?e:{})})("versions",[]).push({version:"3.26.1",mode:"global",copyright:"© 2014-2022 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.26.1/LICENSE",source:"https://github.com/zloirock/core-js"});var Bt=m,Kt=0,Yt=Math.random(),Wt=Bt(1..toString),Xt=function(t){return"Symbol("+(void 0===t?"":t)+")_"+Wt(++Kt+Yt,36)},Gt=D,Ht=Vt.exports,Jt=R,Qt=Xt,Zt=mt,te=St,ee=Ht("wks"),ne=Gt.Symbol,re=ne&&ne.for,oe=te?ne:ne&&ne.withoutSetter||Qt,ie=function(t){if(!Jt(ee,t)||!Zt&&"string"!=typeof ee[t]){var e="Symbol."+t;Zt&&Jt(ne,t)?ee[t]=ne[t]:ee[t]=te&&re?re(e):oe(e)}return ee[t]},ce=it,ae=K,ue=Et,se=Tt,le=function(t,e){var n,r;if("string"===e&&$t(n=t.toString)&&!At(r=Mt(n,t)))return r;if($t(n=t.valueOf)&&!At(r=Mt(n,t)))return r;if("string"!==e&&$t(n=t.toString)&&!At(r=Mt(n,t)))return r;throw zt("Can't convert object to primitive value")},fe=TypeError,pe=ie("toPrimitive"),ge=function(t,e){if(!ae(t)||ue(t))return t;var n,r=se(t,pe);if(r){if(void 0===e&&(e="default"),n=ce(r,t,e),!ae(n)||ue(n))return n;throw fe("Can't convert object to primitive value")}return void 0===e&&(e="number"),le(t,e)},de=Et,ve=function(t){var e=ge(t,"string");return de(e)?e:e+""},he=g,ye=J,be=Q,me=nt,Se=ve,xe=TypeError,we=Object.defineProperty,_e=Object.getOwnPropertyDescriptor;z.f=he?be?function(t,e,n){if(me(t),e=Se(e),me(n),"function"==typeof t&&"prototype"===e&&"value"in n&&"writable"in n&&!n.writable){var r=_e(t,e);r&&r.writable&&(t[e]=n.value,n={configurable:"configurable"in n?n.configurable:r.configurable,enumerable:"enumerable"in n?n.enumerable:r.enumerable,writable:!1})}return we(t,e,n)}:we:function(t,e,n){if(me(t),e=Se(e),me(n),ye)try{return we(t,e,n)}catch(t){}if("get"in n||"set"in n)throw xe("Accessors not supported");return"value"in n&&(t[e]=n.value),t};var Oe=g,Ee=A.EXISTS,Ie=m,je=z.f,ke=Function.prototype,Re=Ie(ke.toString),Ce=/function\b(?:\s|\/\*[\S\s]*?\*\/|\/\/[^\n\r]*[\n\r]+)*([^\s(/]*)/,Pe=Ie(Ce.exec);Oe&&!Ee&&je(ke,"name",{configurable:!0,get:function(){try{return Pe(Ce,Re(this))[1]}catch(t){return""}}});var Te={},Me={},$e={}.propertyIsEnumerable,Ae=Object.getOwnPropertyDescriptor,ze=Ae&&!$e.call({1:2},1);Me.f=ze?function(t){var e=Ae(this,t);return!!e&&e.enumerable}:$e;var Ve=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}},De=m,Fe=De({}.toString),Le=De("".slice),Ne=function(t){return Le(Fe(t),8,-1)},Ue=p,qe=Ne,Be=Object,Ke=m("".split),Ye=Ue((function(){return!Be("z").propertyIsEnumerable(0)}))?function(t){return"String"==qe(t)?Ke(t,""):Be(t)}:Be,We=_,Xe=function(t){return Ye(We(t))},Ge=g,He=it,Je=Me,Qe=Ve,Ze=Xe,tn=ve,en=R,nn=J,rn=Object.getOwnPropertyDescriptor;Te.f=Ge?rn:function(t,e){if(t=Ze(t),e=tn(e),nn)try{return rn(t,e)}catch(t){}if(en(t,e))return Qe(!He(Je.f,t,e),t[e])};var on=z,cn=Ve,an=g?function(t,e,n){return on.f(t,e,cn(1,n))}:function(t,e,n){return t[e]=n,t},un={exports:{}},sn=U,ln=Ut,fn=m(Function.toString);sn(ln.inspectSource)||(ln.inspectSource=function(t){return fn(t)});var pn,gn,dn,vn=ln.inspectSource,hn=U,yn=D.WeakMap,bn=hn(yn)&&/native code/.test(String(yn)),mn=Vt.exports,Sn=Xt,xn=mn("keys"),wn=function(t){return xn[t]||(xn[t]=Sn(t))},_n={},On=bn,En=D,In=K,jn=an,kn=R,Rn=Ut,Cn=wn,Pn=_n,Tn=En.TypeError,Mn=En.WeakMap;if(On||Rn.state){var $n=Rn.state||(Rn.state=new Mn);$n.get=$n.get,$n.has=$n.has,$n.set=$n.set,pn=function(t,e){if($n.has(t))throw Tn("Object already initialized");return e.facade=t,$n.set(t,e),e},gn=function(t){return $n.get(t)||{}},dn=function(t){return $n.has(t)}}else{var An=Cn("state");Pn[An]=!0,pn=function(t,e){if(kn(t,An))throw Tn("Object already initialized");return e.facade=t,jn(t,An,e),e},gn=function(t){return kn(t,An)?t[An]:{}},dn=function(t){return kn(t,An)}}var zn={set:pn,get:gn,has:dn,enforce:function(t){return dn(t)?gn(t):pn(t,{})},getterFor:function(t){return function(e){var n;if(!In(e)||(n=gn(e)).type!==t)throw Tn("Incompatible receiver, "+t+" required");return n}}},Vn=p,Dn=U,Fn=R,Ln=g,Nn=A.CONFIGURABLE,Un=vn,qn=zn.enforce,Bn=zn.get,Kn=Object.defineProperty,Yn=Ln&&!Vn((function(){return 8!==Kn((function(){}),"length",{value:8}).length})),Wn=String(String).split("String"),Xn=un.exports=function(t,e,n){"Symbol("===String(e).slice(0,7)&&(e="["+String(e).replace(/^Symbol\(([^)]*)\)/,"$1")+"]"),n&&n.getter&&(e="get "+e),n&&n.setter&&(e="set "+e),(!Fn(t,"name")||Nn&&t.name!==e)&&(Ln?Kn(t,"name",{value:e,configurable:!0}):t.name=e),Yn&&n&&Fn(n,"arity")&&t.length!==n.arity&&Kn(t,"length",{value:n.arity});try{n&&Fn(n,"constructor")&&n.constructor?Ln&&Kn(t,"prototype",{writable:!1}):t.prototype&&(t.prototype=void 0)}catch(t){}var r=qn(t);return Fn(r,"source")||(r.source=Wn.join("string"==typeof e?e:"")),t};Function.prototype.toString=Xn((function(){return Dn(this)&&Bn(this).source||Un(this)}),"toString");var Gn=U,Hn=z,Jn=un.exports,Qn=Lt,Zn=function(t,e,n,r){r||(r={});var o=r.enumerable,i=void 0!==r.name?r.name:e;if(Gn(n)&&Jn(n,i,r),r.global)o?t[e]=n:Qn(e,n);else{try{r.unsafe?t[e]&&(o=!0):delete t[e]}catch(t){}o?t[e]=n:Hn.f(t,e,{value:n,enumerable:!1,configurable:!r.nonConfigurable,writable:!r.nonWritable})}return t},tr={},er=Math.ceil,nr=Math.floor,rr=Math.trunc||function(t){var e=+t;return(e>0?nr:er)(e)},or=function(t){var e=+t;return e!=e||0===e?0:rr(e)},ir=or,cr=Math.max,ar=Math.min,ur=or,sr=Math.min,lr=function(t){return t>0?sr(ur(t),9007199254740991):0},fr=lr,pr=Xe,gr=function(t,e){var n=ir(t);return n<0?cr(n+e,0):ar(n,e)},dr=function(t){return fr(t.length)},vr=function(t){return function(e,n,r){var o,i=pr(e),c=dr(i),a=gr(r,c);if(t&&n!=n){for(;c>a;)if((o=i[a++])!=o)return!0}else for(;c>a;a++)if((t||a in i)&&i[a]===n)return t||a||0;return!t&&-1}},hr={includes:vr(!0),indexOf:vr(!1)},yr=R,br=Xe,mr=hr.indexOf,Sr=_n,xr=m([].push),wr=function(t,e){var n,r=br(t),o=0,i=[];for(n in r)!yr(Sr,n)&&yr(r,n)&&xr(i,n);for(;e.length>o;)yr(r,n=e[o++])&&(~mr(i,n)||xr(i,n));return i},_r=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],Or=wr,Er=_r.concat("length","prototype");tr.f=Object.getOwnPropertyNames||function(t){return Or(t,Er)};var Ir={};Ir.f=Object.getOwnPropertySymbols;var jr=st,kr=tr,Rr=Ir,Cr=nt,Pr=m([].concat),Tr=jr("Reflect","ownKeys")||function(t){var e=kr.f(Cr(t)),n=Rr.f;return n?Pr(e,n(t)):e},Mr=R,$r=Tr,Ar=Te,zr=z,Vr=p,Dr=U,Fr=/#|\.prototype\./,Lr=function(t,e){var n=Ur[Nr(t)];return n==Br||n!=qr&&(Dr(e)?Vr(e):!!e)},Nr=Lr.normalize=function(t){return String(t).replace(Fr,".").toLowerCase()},Ur=Lr.data={},qr=Lr.NATIVE="N",Br=Lr.POLYFILL="P",Kr=Lr,Yr=D,Wr=Te.f,Xr=an,Gr=Zn,Hr=Lt,Jr=function(t,e,n){for(var r=$r(e),o=zr.f,i=Ar.f,c=0;c<r.length;c++){var a=r[c];Mr(t,a)||n&&Mr(n,a)||o(t,a,i(e,a))}},Qr=Kr,Zr=function(t,e){var n,r,o,i,c,a=t.target,u=t.global,s=t.stat;if(n=u?Yr:s?Yr[a]||Hr(a,{}):(Yr[a]||{}).prototype)for(r in e){if(i=e[r],o=t.dontCallGetSet?(c=Wr(n,r))&&c.value:n[r],!Qr(u?r:a+(s?".":"#")+r,t.forced)&&void 0!==o){if(typeof i==typeof o)continue;Jr(i,o)}(t.sham||o&&o.sham)&&Xr(i,"sham",!0),Gr(n,r,i,t)}},to={};to[ie("toStringTag")]="z";var eo="[object z]"===String(to),no=U,ro=Ne,oo=ie("toStringTag"),io=Object,co="Arguments"==ro(function(){return arguments}()),ao=eo?ro:function(t){var e,n,r;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(n=function(t,e){try{return t[e]}catch(t){}}(e=io(t),oo))?n:co?ro(e):"Object"==(r=ro(e))&&no(e.callee)?"Arguments":r},uo=String,so=function(t){if("Symbol"===ao(t))throw TypeError("Cannot convert a Symbol value to a string");return uo(t)},lo=nt,fo=function(){var t=lo(this),e="";return t.hasIndices&&(e+="d"),t.global&&(e+="g"),t.ignoreCase&&(e+="i"),t.multiline&&(e+="m"),t.dotAll&&(e+="s"),t.unicode&&(e+="u"),t.unicodeSets&&(e+="v"),t.sticky&&(e+="y"),e},po=p,go=D.RegExp,vo=po((function(){var t=go("a","y");return t.lastIndex=2,null!=t.exec("abcd")})),ho=vo||po((function(){return!go("a","y").sticky})),yo=vo||po((function(){var t=go("^r","gy");return t.lastIndex=2,null!=t.exec("str")})),bo={BROKEN_CARET:yo,MISSED_STICKY:ho,UNSUPPORTED_Y:vo},mo={},So=wr,xo=_r,wo=Object.keys||function(t){return So(t,xo)},_o=g,Oo=Q,Eo=z,Io=nt,jo=Xe,ko=wo;mo.f=_o&&!Oo?Object.defineProperties:function(t,e){Io(t);for(var n,r=jo(e),o=ko(e),i=o.length,c=0;i>c;)Eo.f(t,n=o[c++],r[n]);return t};var Ro,Co=st("document","documentElement"),Po=nt,To=mo,Mo=_r,$o=_n,Ao=Co,zo=G,Vo=wn("IE_PROTO"),Do=function(){},Fo=function(t){return"<script>"+t+"<\/script>"},Lo=function(t){t.write(Fo("")),t.close();var e=t.parentWindow.Object;return t=null,e},No=function(){try{Ro=new ActiveXObject("htmlfile")}catch(t){}var t,e;No="undefined"!=typeof document?document.domain&&Ro?Lo(Ro):((e=zo("iframe")).style.display="none",Ao.appendChild(e),e.src=String("javascript:"),(t=e.contentWindow.document).open(),t.write(Fo("document.F=Object")),t.close(),t.F):Lo(Ro);for(var n=Mo.length;n--;)delete No.prototype[Mo[n]];return No()};$o[Vo]=!0;var Uo=Object.create||function(t,e){var n;return null!==t?(Do.prototype=Po(t),n=new Do,Do.prototype=null,n[Vo]=t):n=No(),void 0===e?n:To.f(n,e)},qo=p,Bo=D.RegExp,Ko=qo((function(){var t=Bo(".","s");return!(t.dotAll&&t.exec("\n")&&"s"===t.flags)})),Yo=p,Wo=D.RegExp,Xo=Yo((function(){var t=Wo("(?<a>b)","g");return"b"!==t.exec("b").groups.a||"bc"!=="b".replace(t,"$<a>c")})),Go=it,Ho=m,Jo=so,Qo=fo,Zo=bo,ti=Vt.exports,ei=Uo,ni=zn.get,ri=Ko,oi=Xo,ii=ti("native-string-replace",String.prototype.replace),ci=RegExp.prototype.exec,ai=ci,ui=Ho("".charAt),si=Ho("".indexOf),li=Ho("".replace),fi=Ho("".slice),pi=function(){var t=/a/,e=/b*/g;return Go(ci,t,"a"),Go(ci,e,"a"),0!==t.lastIndex||0!==e.lastIndex}(),gi=Zo.BROKEN_CARET,di=void 0!==/()??/.exec("")[1];(pi||di||gi||ri||oi)&&(ai=function(t){var e,n,r,o,i,c,a,u=this,s=ni(u),l=Jo(t),f=s.raw;if(f)return f.lastIndex=u.lastIndex,e=Go(ai,f,l),u.lastIndex=f.lastIndex,e;var p=s.groups,g=gi&&u.sticky,d=Go(Qo,u),v=u.source,h=0,y=l;if(g&&(d=li(d,"y",""),-1===si(d,"g")&&(d+="g"),y=fi(l,u.lastIndex),u.lastIndex>0&&(!u.multiline||u.multiline&&"\n"!==ui(l,u.lastIndex-1))&&(v="(?: "+v+")",y=" "+y,h++),n=new RegExp("^(?:"+v+")",d)),di&&(n=new RegExp("^"+v+"$(?!\\s)",d)),pi&&(r=u.lastIndex),o=Go(ci,g?n:u,y),g?o?(o.input=fi(o.input,h),o[0]=fi(o[0],h),o.index=u.lastIndex,u.lastIndex+=o[0].length):u.lastIndex=0:pi&&o&&(u.lastIndex=u.global?o.index+o[0].length:r),di&&o&&o.length>1&&Go(ii,o[0],n,(function(){for(i=1;i<arguments.length-2;i++)void 0===arguments[i]&&(o[i]=void 0)})),o&&p)for(o.groups=c=ei(null),i=0;i<p.length;i++)c[(a=p[i])[0]]=o[a[1]];return o});var vi=ai;Zr({target:"RegExp",proto:!0,forced:/./.exec!==vi},{exec:vi});var hi,yi,bi=Zr,mi=it,Si=U,xi=nt,wi=so,_i=(hi=!1,(yi=/[ac]/).exec=function(){return hi=!0,/./.exec.apply(this,arguments)},!0===yi.test("abc")&&hi),Oi=/./.test;bi({target:"RegExp",proto:!0,forced:!_i},{test:function(t){var e=xi(this),n=wi(t),r=e.exec;if(!Si(r))return mi(Oi,e,n);var o=mi(r,e,n);return null!==o&&(xi(o),!0)}});var Ei=d,Ii=Function.prototype,ji=Ii.apply,ki=Ii.call,Ri="object"==typeof Reflect&&Reflect.apply||(Ei?ki.bind(ji):function(){return ki.apply(ji,arguments)}),Ci=Ne,Pi=m,Ti=function(t){if("Function"===Ci(t))return Pi(t)},Mi=Zn,$i=vi,Ai=p,zi=ie,Vi=an,Di=zi("species"),Fi=RegExp.prototype,Li=m,Ni=or,Ui=so,qi=_,Bi=Li("".charAt),Ki=Li("".charCodeAt),Yi=Li("".slice),Wi=function(t){return function(e,n){var r,o,i=Ui(qi(e)),c=Ni(n),a=i.length;return c<0||c>=a?t?"":void 0:(r=Ki(i,c))<55296||r>56319||c+1===a||(o=Ki(i,c+1))<56320||o>57343?t?Bi(i,c):r:t?Yi(i,c,c+2):o-56320+(r-55296<<10)+65536}},Xi={codeAt:Wi(!1),charAt:Wi(!0)}.charAt,Gi=m,Hi=I,Ji=Math.floor,Qi=Gi("".charAt),Zi=Gi("".replace),tc=Gi("".slice),ec=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,nc=/\$([$&'`]|\d{1,2})/g,rc=it,oc=nt,ic=U,cc=Ne,ac=vi,uc=TypeError,sc=Ri,lc=it,fc=m,pc=function(t,e,n,r){var o=zi(t),i=!Ai((function(){var e={};return e[o]=function(){return 7},7!=""[t](e)})),c=i&&!Ai((function(){var e=!1,n=/a/;return"split"===t&&((n={}).constructor={},n.constructor[Di]=function(){return n},n.flags="",n[o]=/./[o]),n.exec=function(){return e=!0,null},n[o](""),!e}));if(!i||!c||n){var a=Ti(/./[o]),u=e(o,""[t],(function(t,e,n,r,o){var c=Ti(t),u=e.exec;return u===$i||u===Fi.exec?i&&!o?{done:!0,value:a(e,n,r)}:{done:!0,value:c(n,e,r)}:{done:!1}}));Mi(String.prototype,t,u[0]),Mi(Fi,o,u[1])}r&&Vi(Fi[o],"sham",!0)},gc=p,dc=nt,vc=U,hc=S,yc=or,bc=lr,mc=so,Sc=_,xc=function(t,e,n){return e+(n?Xi(t,e).length:1)},wc=Tt,_c=function(t,e,n,r,o,i){var c=n+t.length,a=r.length,u=nc;return void 0!==o&&(o=Hi(o),u=ec),Zi(i,u,(function(i,u){var s;switch(Qi(u,0)){case"$":return"$";case"&":return t;case"`":return tc(e,0,n);case"'":return tc(e,c);case"<":s=o[tc(u,1,-1)];break;default:var l=+u;if(0===l)return i;if(l>a){var f=Ji(l/10);return 0===f?i:f<=a?void 0===r[f-1]?Qi(u,1):r[f-1]+Qi(u,1):i}s=r[l-1]}return void 0===s?"":s}))},Oc=function(t,e){var n=t.exec;if(ic(n)){var r=rc(n,t,e);return null!==r&&oc(r),r}if("RegExp"===cc(t))return rc(ac,t,e);throw uc("RegExp#exec called on incompatible receiver")},Ec=ie("replace"),Ic=Math.max,jc=Math.min,kc=fc([].concat),Rc=fc([].push),Cc=fc("".indexOf),Pc=fc("".slice),Tc="$0"==="a".replace(/./,"$0"),Mc=!!/./[Ec]&&""===/./[Ec]("a","$0"),$c=!gc((function(){var t=/./;return t.exec=function(){var t=[];return t.groups={a:"7"},t},"7"!=="".replace(t,"$<a>")}));pc("replace",(function(t,e,n){var r=Mc?"$":"$0";return[function(t,n){var r=Sc(this),o=hc(t)?void 0:wc(t,Ec);return o?lc(o,t,r,n):lc(e,mc(r),t,n)},function(t,o){var i=dc(this),c=mc(t);if("string"==typeof o&&-1===Cc(o,r)&&-1===Cc(o,"$<")){var a=n(e,i,c,o);if(a.done)return a.value}var u=vc(o);u||(o=mc(o));var s=i.global;if(s){var l=i.unicode;i.lastIndex=0}for(var f=[];;){var p=Oc(i,c);if(null===p)break;if(Rc(f,p),!s)break;""===mc(p[0])&&(i.lastIndex=xc(c,bc(i.lastIndex),l))}for(var g,d="",v=0,h=0;h<f.length;h++){for(var y=mc((p=f[h])[0]),b=Ic(jc(yc(p.index),c.length),0),m=[],S=1;S<p.length;S++)Rc(m,void 0===(g=p[S])?g:String(g));var x=p.groups;if(u){var w=kc([y],m,b,c);void 0!==x&&Rc(w,x);var _=mc(sc(o,void 0,w))}else _=_c(y,c,b,m,x,o);b>=v&&(d+=Pc(c,v,b)+_,v=b+y.length)}return d+Pc(c,v)}]}),!$c||!Tc||Mc);var Ac=U,zc=String,Vc=TypeError,Dc=m,Fc=nt,Lc=function(t){if("object"==typeof t||Ac(t))return t;throw Vc("Can't set "+zc(t)+" as a prototype")},Nc=Object.setPrototypeOf||("__proto__"in{}?function(){var t,e=!1,n={};try{(t=Dc(Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set))(n,[]),e=n instanceof Array}catch(t){}return function(n,r){return Fc(n),Lc(r),e?t(n,r):n.__proto__=r,n}}():void 0),Uc=U,qc=K,Bc=Nc,Kc=K,Yc=Ne,Wc=ie("match"),Xc=it,Gc=R,Hc=lt,Jc=fo,Qc=RegExp.prototype,Zc=function(t){var e=t.flags;return void 0!==e||"flags"in Qc||Gc(t,"flags")||!Hc(Qc,t)?e:Xc(Jc,t)},ta=z.f,ea=st,na=z,ra=g,oa=ie("species"),ia=g,ca=D,aa=m,ua=Kr,sa=function(t,e,n){var r,o;return Bc&&Uc(r=e.constructor)&&r!==n&&qc(o=r.prototype)&&o!==n.prototype&&Bc(t,o),t},la=an,fa=tr.f,pa=lt,ga=function(t){var e;return Kc(t)&&(void 0!==(e=t[Wc])?!!e:"RegExp"==Yc(t))},da=so,va=Zc,ha=bo,ya=function(t,e,n){n in t||ta(t,n,{configurable:!0,get:function(){return e[n]},set:function(t){e[n]=t}})},ba=Zn,ma=p,Sa=R,xa=zn.enforce,wa=function(t){var e=ea(t),n=na.f;ra&&e&&!e[oa]&&n(e,oa,{configurable:!0,get:function(){return this}})},_a=Ko,Oa=Xo,Ea=ie("match"),Ia=ca.RegExp,ja=Ia.prototype,ka=ca.SyntaxError,Ra=aa(ja.exec),Ca=aa("".charAt),Pa=aa("".replace),Ta=aa("".indexOf),Ma=aa("".slice),$a=/^\?<[^\s\d!#%&*+<=>@^][^\s!#%&*+<=>@^]*>/,Aa=/a/g,za=/a/g,Va=new Ia(Aa)!==Aa,Da=ha.MISSED_STICKY,Fa=ha.UNSUPPORTED_Y,La=ia&&(!Va||Da||_a||Oa||ma((function(){return za[Ea]=!1,Ia(Aa)!=Aa||Ia(za)==za||"/a/i"!=Ia(Aa,"i")})));if(ua("RegExp",La)){for(var Na=function(t,e){var n,r,o,i,c,a,u=pa(ja,this),s=ga(t),l=void 0===e,f=[],p=t;if(!u&&s&&l&&t.constructor===Na)return t;if((s||pa(ja,t))&&(t=t.source,l&&(e=va(p))),t=void 0===t?"":da(t),e=void 0===e?"":da(e),p=t,_a&&"dotAll"in Aa&&(r=!!e&&Ta(e,"s")>-1)&&(e=Pa(e,/s/g,"")),n=e,Da&&"sticky"in Aa&&(o=!!e&&Ta(e,"y")>-1)&&Fa&&(e=Pa(e,/y/g,"")),Oa&&(i=function(t){for(var e,n=t.length,r=0,o="",i=[],c={},a=!1,u=!1,s=0,l="";r<=n;r++){if("\\"===(e=Ca(t,r)))e+=Ca(t,++r);else if("]"===e)a=!1;else if(!a)switch(!0){case"["===e:a=!0;break;case"("===e:Ra($a,Ma(t,r+1))&&(r+=2,u=!0),o+=e,s++;continue;case">"===e&&u:if(""===l||Sa(c,l))throw new ka("Invalid capture group name");c[l]=!0,i[i.length]=[l,s],u=!1,l="";continue}u?l+=e:o+=e}return[o,i]}(t),t=i[0],f=i[1]),c=sa(Ia(t,e),u?this:ja,Na),(r||o||f.length)&&(a=xa(c),r&&(a.dotAll=!0,a.raw=Na(function(t){for(var e,n=t.length,r=0,o="",i=!1;r<=n;r++)"\\"!==(e=Ca(t,r))?i||"."!==e?("["===e?i=!0:"]"===e&&(i=!1),o+=e):o+="[\\s\\S]":o+=e+Ca(t,++r);return o}(t),n)),o&&(a.sticky=!0),f.length&&(a.groups=f)),t!==p)try{la(c,"source",""===p?"(?:)":p)}catch(t){}return c},Ua=fa(Ia),qa=0;Ua.length>qa;)ya(Na,Ia,Ua[qa++]);ja.constructor=Na,Na.prototype=ja,ba(ca,"RegExp",Na,{constructor:!0})}wa("RegExp");var Ba=un.exports,Ka=z,Ya=g,Wa=bo.MISSED_STICKY,Xa=Ne,Ga=function(t,e,n){return n.get&&Ba(n.get,e,{getter:!0}),n.set&&Ba(n.set,e,{setter:!0}),Ka.f(t,e,n)},Ha=zn.get,Ja=RegExp.prototype,Qa=TypeError;Ya&&Wa&&Ga(Ja,"sticky",{configurable:!0,get:function(){if(this!==Ja){if("RegExp"===Xa(this))return!!Ha(this).sticky;throw Qa("Incompatible receiver, RegExp required")}}});var Za=A.PROPER,tu=Zn,eu=nt,nu=so,ru=p,ou=Zc,iu=RegExp.prototype.toString,cu=ru((function(){return"/a/b"!=iu.call({source:"a",flags:"b"})})),au=Za&&"toString"!=iu.name;(cu||au)&&tu(RegExp.prototype,"toString",(function(){var t=eu(this);return"/"+nu(t.source)+"/"+nu(ou(t))}),{unsafe:!0});function uu(t,e,n,r,o,i,c,a,u,s){"boolean"!=typeof c&&(u=a,a=c,c=!1);const l="function"==typeof n?n.options:n;let f;if(t&&t.render&&(l.render=t.render,l.staticRenderFns=t.staticRenderFns,l._compiled=!0,o&&(l.functional=!0)),r&&(l._scopeId=r),i?(f=function(t){(t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),e&&e.call(this,u(t)),t&&t._registeredComponents&&t._registeredComponents.add(i)},l._ssrRegister=f):e&&(f=c?function(t){e.call(this,s(t,this.$root.$options.shadowRoot))}:function(t){e.call(this,a(t))}),f)if(l.functional){const t=l.render;l.render=function(e,n){return f.call(n),t(e,n)}}else{const t=l.beforeCreate;l.beforeCreate=t?[].concat(t,f):[f]}return n}const su={name:"BaseIconPicker",model:{prop:"value",event:"iconVal"},props:{width:{type:String},value:[String,Object],iconList:{type:Array,default:()=>[]},size:{type:String,default:"16px"},bgModelVal:{type:String,default:"light",validator:t=>["dark","light"].includes(t)}},data(){return{inputVal:this.value,visible:!1,svgIconList:[],otherIcons:[],pngIcons:[],bgModel:this.bgModelVal}},computed:{isImg(){return/\.(gif|png|jpg|jpeg|webp|svg|psd|bmp|tif)$/.test(this.inputVal)}},watch:{value(t){this.inputVal=t},bgModelVal(t){this.bgModel=t}},methods:{inputChange(){},choose(t,e){t="svg"===e?`svg-${t.name}`:e?`${e}-${t}`:t,this.$emit("iconVal",t),this.visible=!1},svgStr2Str:(t,e)=>t.replace(e,""),findSvg(t){const e=s(this.svgIconList,(e=>e.name===t));return l(e,"component")},onClear(){this.inputVal.length>0&&this.$emit("iconVal","")},addSvgComponent(t=[]){this.svgIconList=t},addIcons(t=[]){this.otherIcons=t},addPngIcons(t=[]){this.pngIcons=t}}};var lu=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("div",{staticClass:"base-icon-picker",class:{"base-icon-picker--dark":"dark"===t.bgModel},style:{width:t.width}},[n("el-input",{attrs:{type:"text",readonly:!0,clearable:""},model:{value:t.inputVal,callback:function(e){t.inputVal=e},expression:"inputVal"}},[n("el-popover",{attrs:{slot:"prepend",placement:"right",width:"350",trigger:"click","popper-class":"base-icon-picker-popper"},slot:"prepend",model:{value:t.visible,callback:function(e){t.visible=e},expression:"visible"}},[n("div",[n("el-switch",{attrs:{"active-value":"dark","inactive-value":"light"},model:{value:t.bgModel,callback:function(e){t.bgModel=e},expression:"bgModel"}})],1),t._v(" "),n("div",{staticClass:"icon-tab-outer",class:{"icon-tab-outer--dark":"dark"===t.bgModel}},[t._l(t.otherIcons,(function(e,r){return n("i",{key:r+"-a",staticClass:"font-icon",class:e,style:{"font-size":t.size},on:{click:function(n){return t.choose(e,"other-icon")}}})})),t._v(" "),t._l(t.pngIcons,(function(e,r){return n("i",{key:r+"-b",staticClass:"font-icon",on:{click:function(n){return t.choose(e)}}},[n("img",{style:{width:t.size,height:t.size},attrs:{src:e,alt:""}})])})),t._v(" "),t._l(t.iconList,(function(e,r){return n("base-svg-icon",{key:r,attrs:{iconname:e,size:t.size},on:{click:function(n){return t.choose(e,"symbol")}}})})),t._v(" "),t._l(t.svgIconList,(function(e,r){return n("i",{key:r+"-c",on:{click:function(n){return t.choose(e,"svg")}}},[n(e.component,{tag:"component",style:{width:t.size,height:t.size}})],1)}))],2),t._v(" "),n("el-button",{class:{"base-icon-picker__img":t.inputVal},attrs:{slot:"reference"},slot:"reference"},[t.inputVal?[t.isImg?n("i",{staticClass:"font-icon"},[n("img",{style:{width:t.size,height:t.size},attrs:{src:t.inputVal,alt:""}})]):-1!=t.otherIcons.indexOf(t.svgStr2Str(t.inputVal,"other-icon-"))?n("i",{staticClass:"font-icon",class:t.svgStr2Str(t.inputVal,"other-icon-"),style:{"font-size":t.size}}):t.inputVal.includes("svg-")?n(t.findSvg(t.svgStr2Str(t.inputVal,"svg-")),{tag:"component",style:{width:t.size,height:t.size}}):n("base-svg-icon",{attrs:{iconname:t.svgStr2Str(t.inputVal,"symbol-"),size:t.size}})]:n("span",[n("span",{staticClass:"icon-placeolder"},[t._v("请选择")])])],2)],1),t._v(" "),n("i",{staticClass:"el-input__icon el-icon-circle-close clear-icon",attrs:{slot:"suffix"},on:{click:t.onClear},slot:"suffix"})],1)],1)};lu._withStripped=!0;const fu=uu({render:lu,staticRenderFns:[]},undefined,su,undefined,false,undefined,!1,void 0,void 0,void 0);fu.install=function(t,e){var n;if(n="按需加载独立组件:"+fu.name,"development"!==process.env.NODE_ENV&&"dev"!==process.env.NODE_ENV||console.warn(n),a(e)&&!u(e))for(var r=0;r<e.length;r++)e[r].name!==fu.name&&t.use(e[r]);t.component(fu.name,fu)},exports.BaseIconPicker=fu;