UNPKG

webpack-closure-compiler

Version:
23 lines 11.3 kB
function W(m,n){function r(){}r.prototype=n.prototype;m.prototype=new r;m.prototype.constructor=m;for(var e in n)if(Object.defineProperties){var h=Object.getOwnPropertyDescriptor(n,e);h&&Object.defineProperty(m,e,h)}else m[e]=n[e]} (function(m){function n(e){if(r[e])return r[e].l;var h=r[e]={Y:e,Z:!1,l:{}};m[e].call(h.l,h,h.l,n);h.Z=!0;return h.l}var r={};n.ra=m;n.la=r;n.Y=function(e){return e};n.H=function(e,h){n.P(e)||Object.defineProperty(e,"a",{configurable:!1,enumerable:!0,get:h})};n.n=function(e){var h=e&&e.ca?function(){return e["default"]}:function(){return e};n.H(h,h);return h};n.P=function(e){return Object.prototype.hasOwnProperty.call(e,"a")};n.qa="";return n(n.ua=2)})([function(m){(function(n,r){m.l=r()})(this,function(){function n(c){return 40< String(c).length||-1!==String(c).indexOf("\n")||-1!==String(c).indexOf("\x3c")}function r(c){return L[c]||c}function e(c,e){for(var f in e)c[f]=e[f];return c}function h(c,y,f,D,u){var t=c||P,q=t.nodeName,B=t.attributes,K=t.children,x=!1;y=y||{};f=f||{};var t=f.wa,I="string"===typeof t?t:"\t";if(null==c||!1===c)return"";if(!q)return String(c).replace(/[<>"&]/g,r);if("function"===typeof q)if(x=!0,f.$&&(D||!1===f.xa)){c=q.prototype;if(!(c=q.displayName||q.name||c&&(c.displayName||c.name))&&(c=(Function.prototype.toString.call(q).match(/^\s*function\s+([^\( ]+)/)|| P)[1],!c)){c=-1;for(D=O.length;D--;)if(O[D]===q){c=D;break}0>c&&(c=O.push(q)-1);c="UnnamedComponent"+c}q=c}else return t=c.nodeName.W,u=e({},t||c.attributes),t&&e(u,c.attributes),c.children&&(u.children=c.children),q.prototype&&"function"===typeof q.prototype.h?(t=new q(u,y),t.j=t.da=!0,t.g=u,t.context=y,t.v&&t.v(),u=t.h(t.g,t.state,t.context),t.w&&(y=e(e({},y),t.w()))):u=q(u,y),h(u,y,f,!1!==f.Aa);c="";D=void 0;if(B){var J=S(B);f&&!0===f.Ba&&J.sort();for(var G=0;G<J.length;G++){var p=J[G],k=B[p]; if("children"!==p&&(f&&f.ea||"key"!==p&&"ref"!==p)){if("className"===p){if(B["class"])continue;p="class"}else u&&p.match(/^xlink\:?(.+)/)&&(p=p.toLowerCase().replace(/^xlink\:?(.+)/,"xlink:$1"));if("class"===p&&k&&"object"===typeof k){var E=void 0,v="";for(E in k)k[E]&&(v&&(v+=" "),v+=E);k=v}else if("style"===p&&k&&"object"===typeof k){E=void 0;v="";for(E in k){var z=k[E];null!=z&&(v&&(v+=" "),v+=Q(E),v+=": ",v+=z,"number"!==typeof z||m[E]||(v+="px"),v+=";")}k=v||void 0}if((E=f.N&&f.N(p,k,y,f,x))|| ""===E)c+=E;else if("dangerouslySetInnerHTML"===p)D=k&&k.K;else if((k||0===k||""===k)&&"function"!==typeof k){if(!0===k||""===k)if(k=p,!f||!f.xml){c+=" "+p;continue}c+=" "+p+'\x3d"'+String(k).replace(/[<>"&]/g,r)+'"'}}}}B=c.replace(/^\n\s*/," ");B===c||~B.indexOf("\n")?t&&~c.indexOf("\n")&&(c+="\n"):c=B;c="\x3c"+q+c+"\x3e";-1<R.indexOf(q)&&(c=c.replace(/>$/," /\x3e"));if(D)t&&n(D)&&(D="\n"+I+String(D).replace(/(\n+)/g,"$1"+(I||"\t"))),c+=D;else{x=K&&K.length;B=[];D=~c.indexOf("\n");for(J=0;J<x;J++)G= K[J],null!=G&&!1!==G&&(G=h(G,y,f,!0,"svg"===q?!0:"foreignObject"===q?!1:u),!D&&t&&n(G)&&(D=!0),G&&B.push(G));if(t&&D)for(y=B.length;y--;)B[y]="\n"+I+String(B[y]).replace(/(\n+)/g,"$1"+(I||"\t"));if(B.length)c+=B.join("");else if(f&&f.xml)return c.substring(0,c.length-1)+" /\x3e"}if(f.sa||-1===R.indexOf(q))t&&~c.indexOf("\n")&&(c+="\n"),c+="\x3c/"+q+"\x3e";return c}var m={fa:1,ga:1,ia:1,ma:1,flex:1,flexGrow:1,oa:1,flexShrink:1,na:1,fontWeight:1,ta:1,lineHeight:1,opacity:1,order:1,orphans:1,Ca:1,widows:1, zIndex:1,zoom:1},L={"\x3c":"\x26lt;","\x3e":"\x26gt;",'"':"\x26quot;","\x26":"\x26amp;"},S=Object.keys||function(c){var e=[],f;for(f in c)c.hasOwnProperty(f)&&e.push(f);return e},Q=function(c){var e=1>=arguments.length||void 0===arguments[1]?{}:arguments[1];return function(f){return e[f]||(e[f]=c(f))}}(function(c){return c.replace(/([A-Z])/g,"-$1").toLowerCase()}),T={$:!0},O=[],P={},R="area base br col embed hr img input link meta param source track wbr".split(" ");h.h=h;h.H=function(c,e){return h(c, e,T)};return h})},function(m,n){function r(){}function e(a,b){var c=J,g,d,l;for(l=arguments.length;2<l--;)I.push(arguments[l]);b&&null!=b.children&&(I.length||I.push(b.children),delete b.children);for(;I.length;)if((d=I.pop())&&void 0!==d.pop)for(l=d.length;l--;)I.push(d[l]);else{"boolean"===typeof d&&(d=null);if(l="function"!==typeof a)null==d?d="":"number"===typeof d?d=String(d):"string"!==typeof d&&(l=!1);l&&g?c[c.length-1]+=d:c===J?c=[d]:c.push(d);g=l}g=new r;g.nodeName=a;g.children=c;g.attributes= null==b?void 0:b;g.key=null==b?void 0:b.key;void 0!==x.ba&&x.ba(g);return g}function h(a,b){for(var c in b)a[c]=b[c];return a}function M(a){!a.s&&(a.s=!0)&&1==k.push(a)&&(x.ka||G)(L)}function L(){var a,b=k;for(k=[];a=b.pop();)a.s&&q(a)}function S(a){var b=h({},a.attributes);b.children=a.children;a=a.nodeName.W;if(void 0!==a)for(var c in a)void 0===b[c]&&(b[c]=a[c]);return b}function Q(a){var b=a.parentNode;b&&b.removeChild(a)}function T(a,b,c,g,d){"className"===b&&(b="class");if("key"!==b)if("ref"=== b)c&&c(null),g&&g(a);else if("class"!==b||d)if("style"===b){if(g&&"string"!==typeof g&&"string"!==typeof c||(a.style.cssText=g||""),g&&"object"===typeof g){if("string"!==typeof c)for(var l in c)l in g||(a.style[l]="");for(l in g)a.style[l]="number"===typeof g[l]&&!1===p.test(l)?g[l]+"px":g[l]}}else if("dangerouslySetInnerHTML"===b)g&&(a.innerHTML=g.K||"");else if("o"==b[0]&&"n"==b[1])d=b!==(b=b.replace(/Capture$/,"")),b=b.toLowerCase().substring(2),g?c||a.addEventListener(b,O,d):a.removeEventListener(b, O,d),(a.F||(a.F={}))[b]=g;else if("list"!==b&&"type"!==b&&!d&&b in a){try{a[b]=null==g?"":g}catch(X){}null!=g&&!1!==g||a.removeAttribute(b)}else c=d&&b!==(b=b.replace(/^xlink\:?/,"")),null==g||!1===g?c?a.removeAttributeNS("http://www.w3.org/1999/xlink",b.toLowerCase()):a.removeAttribute(b):"function"!==typeof g&&(c?a.setAttributeNS("http://www.w3.org/1999/xlink",b.toLowerCase(),g):a.setAttribute(b,g));else a.className=g||""}function O(a){return this.F[a.type](x.event&&x.event(a)||a)}function P(){for(var a;a= E.pop();)x.L&&x.L(a),a.R&&a.R()}function R(a,b,e,g,d,l){v++||(z=null!=d&&void 0!==d.va,U=!!a&&!("__preactattr_"in a));a=c(a,b,e,g,l);d&&a.parentNode!==d&&d.appendChild(a);--v||(U=!1,l||P());return a}function c(a,b,e,g,d){var l=a,f=z;if(null==b||"boolean"===typeof b)b="";if("string"===typeof b||"number"===typeof b)return a&&void 0!==a.splitText&&a.parentNode&&(!a.b||d)?a.nodeValue!=b&&(a.nodeValue=b):(l=document.createTextNode(b),a&&(a.parentNode&&a.parentNode.replaceChild(l,a),y(a,!0))),l.__preactattr_= !0,l;d=b.nodeName;if("function"===typeof d){var f=a,h=b,l=b=f&&f.b,n=f,w=b&&f.u===h.nodeName,k=w;for(a=S(h);b&&!k&&(b=b.G);)k=b.constructor===h.nodeName;b&&k&&(!g||b.b)?(t(b,a,3,e,g),f=b.c):(l&&!w&&(B(l),f=n=null),b=D(h.nodeName,a,e),f&&!b.f&&(b.f=f,n=null),t(b,a,1,e,g),f=b.c,n&&f!==n&&(n.b=null,y(n,!1)));return f}z="svg"===d?!0:"foreignObject"===d?!1:z;d=String(d);if(!a||a.I!==d&&a.nodeName.toLowerCase()!==d.toLowerCase())if(l=d,d=z?document.createElementNS("http://www.w3.org/2000/svg",l):document.createElement(l), d.I=l,l=d,a){for(;a.firstChild;)l.appendChild(a.firstChild);a.parentNode&&a.parentNode.replaceChild(l,a);y(a,!0)}var q=l.firstChild;a=l.__preactattr_;d=b.children;if(null==a){a=l.__preactattr_={};for(var N=l.attributes,r=N.length;r--;)a[N[r].name]=N[r].value}if(!U&&d&&1===d.length&&"string"===typeof d[0]&&null!=q&&void 0!==q.splitText&&null==q.nextSibling)q.nodeValue!=d[0]&&(q.nodeValue=d[0]);else if(d&&d.length||null!=q){var q=l,N=U||null!=a.ja,r=q.childNodes,m=[],A={},x=0,C=0,p=r.length,v=0,E=d? d.length:0,H;if(p)for(k=0;k<p;k++){var F=r[k],u=F.__preactattr_;H=E&&u?F.b?F.b.D:u.key:null;if(null!=H)x++,A[H]=F;else if(u||(void 0!==F.splitText?N?F.nodeValue.trim():1:N))m[v++]=F}if(E)for(k=0;k<E;k++){p=d[k];w=null;H=p.key;if(null!=H)x&&void 0!==A[H]&&(w=A[H],A[H]=void 0,x--);else if(!w&&C<v)for(H=C;H<v;H++){if(F=void 0!==m[H])if(F=n=m[H],"string"===typeof p||"number"===typeof p)F=void 0!==F.splitText;else if("string"===typeof p.nodeName){if(u=!F.u)u=p.nodeName,u=F.I===u||F.nodeName.toLowerCase()=== u.toLowerCase();F=u}else F=N||F.u===p.nodeName;if(F){w=n;m[H]=void 0;H===v-1&&v--;H===C&&C++;break}}w=c(w,p,e,g);p=r[k];w&&w!==q&&w!==p&&(p?w===p.nextSibling?Q(p):q.insertBefore(w,p):q.appendChild(w))}if(x)for(k in A)void 0!==A[k]&&y(A[k],!1);for(;C<=v;)void 0!==(w=m[v--])&&y(w,!1)}e=l;g=b.attributes;b=a;for(h in b)g&&null!=g[h]||null==b[h]||T(e,h,b[h],b[h]=void 0,z);for(h in g)"children"===h||"innerHTML"===h||h in b&&g[h]===("value"===h||"checked"===h?e[h]:b[h])||T(e,h,b[h],b[h]=g[h],z);z=f;return l} function y(a,b){var c=a.b;c?B(c):(null!=a.__preactattr_&&a.__preactattr_.m&&a.__preactattr_.m(null),!1!==b&&null!=a.__preactattr_||Q(a),f(a))}function f(a){for(a=a.lastChild;a;){var b=a.previousSibling;y(a,!0);a=b}}function D(a,b,c){var g=V[a.name],d;a.prototype&&a.prototype.h?(d=new a(b,c),K.call(d,b,c)):(d=new K(b,c),d.constructor=a,d.h=u);if(g)for(b=g.length;b--;)if(g[b].constructor===a){d.f=g[b].f;g.splice(b,1);break}return d}function u(a,b,c){return this.constructor(a,c)}function t(a,b,c,g,d){a.j|| (a.j=!0,(a.o=b.m)&&delete b.m,(a.D=b.key)&&delete b.key,!a.c||d?a.v&&a.v():a.T&&a.T(b,g),g&&g!==a.context&&(a.A||(a.A=a.context),a.context=g),a.B||(a.B=a.g),a.g=b,a.j=!1,0!==c&&(1!==c&&!1===x.Da&&a.c?M(a):q(a,1,d)),a.o&&a.o(a))}function q(a,b,c,g){if(!a.j){var d=a.g,e=a.state,f=a.context,k=a.B||d,n=a.C||e,p=a.A||f,r=a.c,w=a.f,m=r||w,u=a.b,G=!1,A;r&&(a.g=k,a.state=n,a.context=p,2!==b&&a.aa&&!1===a.aa(d,e,f)?G=!0:a.V&&a.V(d,e,f),a.g=d,a.state=e,a.context=f);a.B=a.C=a.A=a.f=null;a.s=!1;if(!G){d=a.h(d, e,f);a.w&&(f=h(h({},f),a.w()));var e=d&&d.nodeName,z,C;if("function"===typeof e)C=S(d),(A=u)&&A.constructor===e&&C.key==A.D?t(A,C,1,f,!1):(z=A,a.b=A=D(e,C,f),A.f=A.f||w,A.G=a,t(A,C,0,f,!1),q(A,1,c,!0)),C=A.c;else{w=m;if(z=u)w=a.b=null;if(m||1===b)w&&(w.b=null),C=R(w,d,f,c||!r,m&&m.parentNode,!0)}m&&C!==m&&A!==u&&(f=m.parentNode)&&C!==f&&(f.replaceChild(C,m),z||(m.b=null,y(m,!1)));z&&B(z);if((a.c=C)&&!g){for(z=m=a;z=z.G;)(m=z).c=C;C.b=m;C.u=m.constructor}}!r||c?E.unshift(a):G||(a.S&&a.S(k,n,p),x.M&& x.M(a));if(null!=a.i)for(;a.i.length;)a.i.pop().call(a);v||g||P()}}function B(a){x.O&&x.O(a);var b=a.c;a.j=!0;a.U&&a.U();a.c=null;var c=a.b;c?B(c):b&&(b.__preactattr_&&b.__preactattr_.m&&b.__preactattr_.m(null),a.f=b,Q(b),c=a.constructor.name,(V[c]||(V[c]=[])).push(a),f(b));a.o&&a.o(null)}function K(a,b){this.s=!0;this.context=b;this.g=a;this.state=this.state||{}}var x={},I=[],J=[],G="function"==typeof Promise?Promise.resolve().then.bind(Promise.resolve()):setTimeout,p=/acit|ex(?:s|g|n|p|$)|rph|ows|mnc|ntw|ine[ch]|zoo|^ord/i, k=[],E=[],v=0,z=!1,U=!1,V={};h(K.prototype,{za:function(a,b){var c=this.state;this.C||(this.C=h({},c));h(c,"function"===typeof a?a(c,this.g):a);b&&(this.i=this.i||[]).push(b);M(this)},pa:function(a){a&&(this.i=this.i||[]).push(a);q(this,2)},h:function(){}});n.a={X:e,createElement:e,ha:function(a,b){return e(a.nodeName,h(h({},a.attributes),b),2<arguments.length?[].slice.call(arguments,2):a.children)},J:K,h:function(a,b,c){return R(c,a,{},!1,b,!1)},ya:L,options:x}},function(m,n,r){function e(e){return L.apply(this, arguments)||this}function h(e){return M("h1",null,e.children)}Object.defineProperty(n,"__esModule",{value:!0});m=r(1);n=r(0);r=r.n(n);m=m.a;var M=m.X,L=m.J;W(e,L);e.prototype.h=function(){return M("div",null,M(h,null,"Hello, world!"))};console.log(r()(M(e)))}]);